From 7dfa9a35b8f7a25e1b69d8699c0549eeee83f298 Mon Sep 17 00:00:00 2001 From: Methode Date: Sat, 12 Sep 2026 05:12:18 -0700 Subject: [PATCH 01/24] [verified] Refactor selected Sendov proofs with module-level preservation gates --- Sendov/Common/Sinh.lean | 87 +++++++------- Sendov/FiniteRange/Degree80_100.lean | 173 ++------------------------- Sendov/FiniteRange/Degree8_9.lean | 29 ++--- 3 files changed, 62 insertions(+), 227 deletions(-) diff --git a/Sendov/Common/Sinh.lean b/Sendov/Common/Sinh.lean index efa0873..1febaf8 100644 --- a/Sendov/Common/Sinh.lean +++ b/Sendov/Common/Sinh.lean @@ -123,6 +123,20 @@ private lemma hasDerivAt_Sf (u₃ u₂ u₁ u₀ v₄ v₃ v₂ v₁ v₀ w₃ w ring exact (((he2.mul hu).sub (he1.mul hv)).sub hw).congr_deriv (by ring) +/-- One step of the derivative descent for `Sf`: its value at zero is `u₀ - v₀ - w₀`, +and its derivative stays in the same family. This packages the analytic argument once; +the numbered steps below only check the coefficient recurrence. -/ +private lemma nonneg_Sf_of_deriv + {u₃ u₂ u₁ u₀ v₄ v₃ v₂ v₁ v₀ w₃ w₂ w₁ w₀ : ℝ} + (h0 : u₀ - v₀ - w₀ = 0) + (hd : ∀ z, 0 ≤ z → + 0 ≤ Sf (2 * u₃) (2 * u₂ + 3 * u₃) (2 * u₁ + 2 * u₂) (2 * u₀ + u₁) + v₄ (v₃ + 4 * v₄) (v₂ + 3 * v₃) (v₁ + 2 * v₂) (v₀ + v₁) + 0 (3 * w₃) (2 * w₂) w₁ z) + {y : ℝ} (hy : 0 ≤ y) : 0 ≤ Sf u₃ u₂ u₁ u₀ v₄ v₃ v₂ v₁ v₀ w₃ w₂ w₁ w₀ y := by + exact nonneg_of_deriv (hasDerivAt_Sf u₃ u₂ u₁ u₀ v₄ v₃ v₂ v₁ v₀ w₃ w₂ w₁ w₀) + (by simpa [Sf] using h0) hd hy + /-- The base of the induction, `Φ⁽⁸⁾ ≥ 0`. Three terms of the exponential series leave a polynomial with every coefficient positive. -/ private lemma step8 (y : ℝ) (hy : 0 ≤ y) : @@ -143,61 +157,52 @@ private lemma step8 (y : ℝ) (hy : 0 ≤ y) : private lemma step7 (y : ℝ) (hy : 0 ≤ y) : 0 ≤ Sf 128 64 (-320) 1440 1 28 268 1064 1440 0 0 0 0 y := by - refine nonneg_of_deriv (g := Sf 256 512 (-512) 2560 1 32 352 1600 2504 0 0 0 0) - (fun z => ?_) ?_ step8 hy - · exact (hasDerivAt_Sf 128 64 (-320) 1440 1 28 268 1064 1440 0 0 0 0 z).congr_deriv - (by grind [Sf]) - · simp only [Sf] - norm_num + refine nonneg_Sf_of_deriv (by norm_num) ?_ hy + intro z hz + convert step8 z hz using 1 + norm_num private lemma step6 (y : ℝ) (hy : 0 ≤ y) : 0 ≤ Sf 64 (-64) (-96) 768 1 24 196 672 768 0 0 0 0 y := by - refine nonneg_of_deriv (g := Sf 128 64 (-320) 1440 1 28 268 1064 1440 0 0 0 0) - (fun z => ?_) ?_ step7 hy - · exact (hasDerivAt_Sf 64 (-64) (-96) 768 1 24 196 672 768 0 0 0 0 z).congr_deriv (by grind [Sf]) - · simp only [Sf] - norm_num + refine nonneg_Sf_of_deriv (by norm_num) ?_ hy + intro z hz + convert step7 z hz using 1 + norm_num private lemma step5 (y : ℝ) (hy : 0 ≤ y) : 0 ≤ Sf 32 (-80) 32 368 1 20 136 400 368 0 0 0 0 y := by - refine nonneg_of_deriv (g := Sf 64 (-64) (-96) 768 1 24 196 672 768 0 0 0 0) - (fun z => ?_) ?_ step6 hy - · exact (hasDerivAt_Sf 32 (-80) 32 368 1 20 136 400 368 0 0 0 0 z).congr_deriv (by grind [Sf]) - · simp only [Sf] - norm_num + refine nonneg_Sf_of_deriv (by norm_num) ?_ hy + intro z hz + convert step6 z hz using 1 + norm_num private lemma step4 (y : ℝ) (hy : 0 ≤ y) : 0 ≤ Sf 16 (-64) 80 144 1 16 88 224 144 0 0 0 0 y := by - refine nonneg_of_deriv (g := Sf 32 (-80) 32 368 1 20 136 400 368 0 0 0 0) - (fun z => ?_) ?_ step5 hy - · exact (hasDerivAt_Sf 16 (-64) 80 144 1 16 88 224 144 0 0 0 0 z).congr_deriv (by grind [Sf]) - · simp only [Sf] - norm_num + refine nonneg_Sf_of_deriv (by norm_num) ?_ hy + intro z hz + convert step5 z hz using 1 + norm_num private lemma step3 (y : ℝ) (hy : 0 ≤ y) : 0 ≤ Sf 8 (-44) 84 30 1 12 52 120 24 0 0 0 6 y := by - refine nonneg_of_deriv (g := Sf 16 (-64) 80 144 1 16 88 224 144 0 0 0 0) - (fun z => ?_) ?_ step4 hy - · exact (hasDerivAt_Sf 8 (-44) 84 30 1 12 52 120 24 0 0 0 6 z).congr_deriv (by grind [Sf]) - · simp only [Sf] - norm_num + refine nonneg_Sf_of_deriv (by norm_num) ?_ hy + intro z hz + convert step4 z hz using 1 + norm_num private lemma step2 (y : ℝ) (hy : 0 ≤ y) : 0 ≤ Sf 4 (-28) 70 (-20) 1 8 28 64 (-40) 0 0 6 20 y := by - refine nonneg_of_deriv (g := Sf 8 (-44) 84 30 1 12 52 120 24 0 0 0 6) - (fun z => ?_) ?_ step3 hy - · exact (hasDerivAt_Sf 4 (-28) 70 (-20) 1 8 28 64 (-40) 0 0 6 20 z).congr_deriv (by grind [Sf]) - · simp only [Sf] - norm_num + refine nonneg_Sf_of_deriv (by norm_num) ?_ hy + intro z hz + convert step3 z hz using 1 + norm_num private lemma step1 (y : ℝ) (hy : 0 ≤ y) : 0 ≤ Sf 2 (-17) 52 (-36) 1 4 16 32 (-72) 0 3 20 36 y := by - refine nonneg_of_deriv (g := Sf 4 (-28) 70 (-20) 1 8 28 64 (-40) 0 0 6 20) - (fun z => ?_) ?_ step2 hy - · exact (hasDerivAt_Sf 2 (-17) 52 (-36) 1 4 16 32 (-72) 0 3 20 36 z).congr_deriv (by grind [Sf]) - · simp only [Sf] - norm_num + refine nonneg_Sf_of_deriv (by norm_num) ?_ hy + intro z hz + convert step2 z hz using 1 + norm_num private lemma step0 (y : ℝ) (hy : 0 ≤ y) : 0 ≤ Sf 1 (-10) 36 (-36) 1 0 16 0 (-72) 1 10 36 36 y := by - refine nonneg_of_deriv (g := Sf 2 (-17) 52 (-36) 1 4 16 32 (-72) 0 3 20 36) - (fun z => ?_) ?_ step1 hy - · exact (hasDerivAt_Sf 1 (-10) 36 (-36) 1 0 16 0 (-72) 1 10 36 36 z).congr_deriv (by grind [Sf]) - · simp only [Sf] - norm_num + refine nonneg_Sf_of_deriv (by norm_num) ?_ hy + intro z hz + convert step1 z hz using 1 + norm_num /-- The algebraic bridge: `Φ(2h) = 16 e^{2h} G(h)`. -/ private lemma Sf_eq (h : ℝ) : diff --git a/Sendov/FiniteRange/Degree80_100.lean b/Sendov/FiniteRange/Degree80_100.lean index 7a26a67..24f652d 100644 --- a/Sendov/FiniteRange/Degree80_100.lean +++ b/Sendov/FiniteRange/Degree80_100.lean @@ -88,173 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 25811606424535915506326543401482443660479168162161070878750987845784640947537512918254143661443967851841624182260454 + 336370345330350208165234204307830830778265112065902973986047706784620119812179101529287799329664970700047233908530028 * α + 2135490323710205451177831007886434323850910269893926405766449302023972016567372609179660983528148958829173461437058426 * α ^ 2 + 8800193380808665214547458427848614541537421741398394617093689631071556593600442609061272206311515066984302690924269000 * α ^ 3 + 26462827687725576351409435396337556001601266481763435312645957683742611763538244106923991390112640216709155823432046446 * α ^ 4 + 61890317824100182817489513892770080906362674388551785381427868354803942587321704313688072997460165545388054174413205140 * α ^ 5 + 117172359697259929763030783557189322339080300100874585985220084088882745103145230216047487779174956161518920280447603674 * α ^ 6 + 184544739027532874709347195849421533711097651533181291373211062330869431152671413319813999120439419738468174182904364464 * α ^ 7 + 246608145764613286789878656386710073720610930090411123420903881172229605185065434892818764890373842116194248634263756798 * α ^ 8 + 283763693487574246430404620051411555790859557853657413692053633072552222818811355084552210214522447497912164915857007772 * α ^ 9 + 284375388167493337786979561808634395465424553508941556573930507406581722477890971264427055005741911794482115087411543730 * α ^ 10 + 250434456333498778687253731739220273422355020504490227298836915758303181227856673748711052077418442551670601820448469608 * α ^ 11 + 195186376833089073717511924197741339564583901408375396552289751612744737294639334816437871802096096044647044024483571528 * α ^ 12 + 135403325876044028593166865189418922031634343539481341612266706224679843802900374983571701066935649917189903585957861976 * α ^ 13 + 83987295633438700092517506437803590415296544388998812046873276158407316217262430264254188896692746403373298520205212844 * α ^ 14 + 46749761312162043935912318982126078666828249385834636225082169910759646501503433598091545864589766997203234619939545928 * α ^ 15 + 23418772546685983831264607439067708954491960164074800112819444923487497120280358300648725634717312663795784508649665131 * α ^ 16 + 10580616042971700828358189370081401738808367070894586162364463432933276777181125840333157268302229461101124643546709974 * α ^ 17 + 4318183659819981488074693370040938716545728929617703773317165795943654804101138834083140850940446923358733078548068645 * α ^ 18 + 1593587693765014079746102214238987350113694708675138266157201007419844029857283186926010079342854945184589138949560164 * α ^ 19 + 532047925009422644797257472015181516662587259482075864085888807106871007422932953581727885439598490014141304896691047 * α ^ 20 + 160701892364069140905358669813546549814319510910544697552500165178091918076856803958923921001593977227161490804746106 * α ^ 21 + 43889653627121057923774311030558057038777866396589839090993605786486211704353490599487695285745585770243180871001173 * α ^ 22 + 10827357706237228452243490602525886439138079007606319319715720331950005385599610283148806774807521304374526909486664 * α ^ 23 + 2408842256812625932290911263046890728148322122703071503064745543954110106028352314896838503963205885454006647328032 * α ^ 24 + 482237450846393383131287501498018968499665598348674814673101519961867723893846884326467389187302292657246662111488 * α ^ 25 + 86620744735037078123451064351322751112466467920961355862225908103410633498456796660448573578914072648246281297272 * α ^ 26 + 13908651519349479073873240534072463905809010212400405416347877534040408226391579668251784782713336166212519013104 * α ^ 27 + 1987136509055095540850907316692328719109975779097323211935130132295635949953814198439654077152611676110556260102 * α ^ 28 + 251138932516361376722297645486554574796035287318555929793528638706264274506637419055880639659286763175005448076 * α ^ 29 + 27871094123052914818399316975765472111564288696313684416212667809570265754686721498698986614959173244385297518 * α ^ 30 + 2690865047909357054511239261296500605261094896849533507003089976244070348637842057420543829564694293947173400 * α ^ 31 + 223291370726238703406997118812607738047342804101888528968918478200237656608670127439529056632663807296136083 * α ^ 32 + 15669985331287744715848606174054829999776651533612117903292549399606649200386705738963593063781305669960598 * α ^ 33 + 909073729758232176167878755737698432102154655242833248859457302905520734577946123899448989405380991348941 * α ^ 34 + 42091260471451636997926921594629293230252747899173824918202060597101883618323097768155200270442748875668 * α ^ 35 + 1450861895455204845787988647170733163350496179912678839329200986510884388428173389320127180407765638551 * α ^ 36 + 19698279579096177164787018164158789132912466550646401885212259058865017062230215250892367283766302154 * α ^ 37 - 57652053317489414390572934832324830300466266131622345505450510286650133357321127488185831111381791595 * α ^ 38 + 735839726136777192033003352499083088738558026604488978404480341017143472486567180936350888710307864 * α ^ 39 - 4556557091452941380040035385055147646930930624200910749123957637499614710015132762550103799821048 * α ^ 40 - 133385784303410256278801057965454595590178412725438433339158980224721485193506478868247418219456 * α ^ 41 - 3423096723020314850982421385371010756189634167048478694293828864372204445633272936186470719904 * α ^ 42 - 69804839903958953293946387520015029557798645931631581080348037608367532112774187909634522240 * α ^ 43 - 865452330871186953510596734828786492278941181396935228550729318386099014534564956306824064 * α ^ 44 + 6798618471243250403976624728656397719531634223766543816506986827945697172779099788420608 * α ^ 45 + 788561506471686257274486905164229697457259305541495354329419768350740667053416558054144 * α ^ 46 + 27404388758747154771370930189376580679701159098426606936627216153391035767084433846272 * α ^ 47 + 646649551478726098614980210707984819816807233831805276746361716798674738190577340416 * α ^ 48 + 11211130515851440319438235357551475100839553634180130203899774136494056161035911168 * α ^ 49 + 130654761491363390209265527305244677484674002463471732106539824077702885812797440 * α ^ 50 + 357370958717189390935129396104908992248522307474545437642970135644954582646784 * α ^ 51 - 29181736810016345568442240720495430859483450421903151495150669166766787592192 * α ^ 52 - 955989844135526470691849812345208816075517571032312722273829147296013484032 * α ^ 53 - 19693589749621923555627023816809550207524792367857705784556171741361864704 * α ^ 54 - 319527958823219288171919301676630081495413277792849934402743906350399488 * α ^ 55 - 4359916692864270231911575583538878442433933182393484084715401339994112 * α ^ 56 - 51487996872395271018065603117315986670053043845988016897449388933120 * α ^ 57 - 534287852041371238607889671805075544881560005268660814584293097472 * α ^ 58 - 4914742088163302214038533958003066516795399439930469941648556032 * α ^ 59 - 40286770643795091951577560453084774722804729349509280681689088 * α ^ 60 - 295170417808439805757992973335875121127546339919271705968640 * α ^ 61 - 1935804396482191076314681386409043851261791712104853536768 * α ^ 62 - 11366432523474642581662414816114955814707861565858643968 * α ^ 63 - 59703170845283859723339853111711322814822346376871936 * α ^ 64 - 280018128137086019618307155094771953353132297158656 * α ^ 65 - 1169385347161959260160465901639985114274911485952 * α ^ 66 - 4331161143994110763407260197680039459865755648 * α ^ 67 - 14153828793218044771011521216530198581739520 * α ^ 68 - 40537586126827346928475190951612417835008 * α ^ 69 - 100883783567908658123954038279633895424 * α ^ 70 - 215746527094612923562575346607849472 * α ^ 71 - 390762372880065519809958474940416 * α ^ 72 - 587839886222327464463148515328 * α ^ 73 - 714822291149465741724483584 * α ^ 74 - 675179423113136706682880 * α ^ 75 - 464818794079734202368 * α ^ 76 - 207493237324120064 * α ^ 77 - 45079976738816 * α ^ 78 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 25811606424535915506326543401482443660479168162161070878750987845784640947537512918254143661443967851841624182260454 * (17 - α) ^ 78 := - mul_nonneg (by norm_num) (pow_nonneg hu 78) - have h1 : (0:ℝ) ≤ 7731601171729754948302451858548754728747882021768914086305388067309744030714970733621715794196933994344449662661325888 * α ^ 1 * (17 - α) ^ 77 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 77) - have h2 : (0:ℝ) ≤ 1134977739682559152144183344552781855394081041684581420063129512966886926387568279248276946977482731207073356960903835128 * α ^ 2 * (17 - α) ^ 76 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 76) - have h3 : (0:ℝ) ≤ 108834637037659199091355921419729186300121822584927223690221434809345565260667023227379040139264943526676297937882231816944 * α ^ 3 * (17 - α) ^ 75 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 75) - have h4 : (0:ℝ) ≤ 7666861356053587141879051542023151513155253675338534070219208289734940750831143744550245239925873313943561985580954527982616 * α ^ 4 * (17 - α) ^ 74 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 74) - have h5 : (0:ℝ) ≤ 423077887233518864483787884707532169136310014420797711374285732639883356220901878487666885430844058504013013662258662655409024 * α ^ 5 * (17 - α) ^ 73 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 73) - have h6 : (0:ℝ) ≤ 19043789756155440424344440725874751801324872083267566506068169098722085040014291705260338415543274194102043673327180400129929832 * α ^ 6 * (17 - α) ^ 72 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 72) - have h7 : (0:ℝ) ≤ 718947188407260825753518059058500078605524217441449955961763119488742316279761434573371789300650648290365793225194740365639829248 * α ^ 7 * (17 - α) ^ 71 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 71) - have h8 : (0:ℝ) ≤ 23229944260791702898096600141389848573573933604759267334016067683455922366132699662001188778646003391197287922373361993488875467772 * α ^ 8 * (17 - α) ^ 70 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 70) - have h9 : (0:ℝ) ≤ 652356286335394807010040506322513589425276848772982033180582110575315337819948577150432209238058606495049799638171924460488723115728 * α ^ 9 * (17 - α) ^ 69 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 69) - have h10 : (0:ℝ) ≤ 16115244618115471773154398428945842467530527293496478962865411951374999566160962962621541576431428483629410984630108362973322526046352 * α ^ 10 * (17 - α) ^ 68 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 68) - have h11 : (0:ℝ) ≤ 353590213705899227670735133595068406610777044757491438541768497813388671143323439181516543806998722646874310797601900004357046159618416 * α ^ 11 * (17 - α) ^ 67 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 67) - have h12 : (0:ℝ) ≤ 6945545366374205473681219757999841297413797165201420435841487238189483615527433260434909542451873571311839418856181380505673028690189834 * α ^ 12 * (17 - α) ^ 66 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 66) - have h13 : (0:ℝ) ≤ 122943429683776586616098034509418349763379413100200501385374144116228404023652411356804056379171036434910191105635835310497125437439368616 * α ^ 13 * (17 - α) ^ 65 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 65) - have h14 : (0:ℝ) ≤ 1971943361675961854095978497179540085473722438976489160404258526153302499359290412285125679239602051452003303294340674036438891755271461344 * α ^ 14 * (17 - α) ^ 64 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 64) - have h15 : (0:ℝ) ≤ 28794613849932432807185452777239504156831844265536120723695409096275314438957801587812894208037520422020805646713238048377079475740273188040 * α ^ 15 * (17 - α) ^ 63 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 63) - have h16 : (0:ℝ) ≤ 384328560383502952032438759151017028938946671283519542604007361014389867788722109711367554903315805912734859044701209907625689918745997497675 * α ^ 16 * (17 - α) ^ 62 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 62) - have h17 : (0:ℝ) ≤ 4705189064883150340603293176324983232690962514057066121441689655603425308970643761709274220489500917477746179322066734647863357743464493676520 * α ^ 17 * (17 - α) ^ 61 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 61) - have h18 : (0:ℝ) ≤ 52996214890563273796160643818818348185528424059725114966862380369319342813162215520720537479664066314153467772804561608859372679443782254992220 * α ^ 18 * (17 - α) ^ 60 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 60) - have h19 : (0:ℝ) ≤ 550617253247385218427009607064332121441409621321669095638902982534390077955117952713512591688404159855259550612508039696237055140143912070148080 * α ^ 19 * (17 - α) ^ 59 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 59) - have h20 : (0:ℝ) ≤ 5289254261689909642998694788883801072432560837908488801188757508626280600068147475966012413534329068218714313264686298658627525464990766966507480 * α ^ 20 * (17 - α) ^ 58 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 58) - have h21 : (0:ℝ) ≤ 47071723811940484288699822861559515707560341788285556322087973575337149744998528596195569152380487445854405880284205334835719251975349528608895960 * α ^ 21 * (17 - α) ^ 57 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 57) - have h22 : (0:ℝ) ≤ 388797566873530668184175407886161066305517869569175948336046190337058590155012538967688933864691298489884730691529378580953514253496007438959580140 * α ^ 22 * (17 - α) ^ 56 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 56) - have h23 : (0:ℝ) ≤ 2985179603519724471752085802643613314281923391910045186703182258691770626157427630859816171548924404331298520035371797680826375874045307985095169160 * α ^ 23 * (17 - α) ^ 55 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 55) - have h24 : (0:ℝ) ≤ 21335697765899092801522874710986881769845405599093285192366939176739104568310936178280383293402533817032054113166202401026875457402502001299016941965 * α ^ 24 * (17 - α) ^ 54 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 54) - have h25 : (0:ℝ) ≤ 142124309577284830558031748098405686449899656084274181428411809022465874914849955156662717515516567844716088626134776657964597427502198457271981932744 * α ^ 25 * (17 - α) ^ 53 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 53) - have h26 : (0:ℝ) ≤ 883340987406927324886485469060737975106344280304169568718286595798294963628744880539858577253973934458679980792763078663809587077960963632717815152096 * α ^ 26 * (17 - α) ^ 52 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 52) - have h27 : (0:ℝ) ≤ 5127488920008786553466393714789905427388213762697569627668475082844096754564454348757229349829628841608199919978811602705936439756284569017181261626624 * α ^ 27 * (17 - α) ^ 51 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 51) - have h28 : (0:ℝ) ≤ 27820537271116488598533849210418200371695645263092839593736637431588817343110855564285745636333362483896532668071984474388396970246448477332845548675696 * α ^ 28 * (17 - α) ^ 50 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 50) - have h29 : (0:ℝ) ≤ 141199792955232750444991232388282777593870842150187857240279059394142520379652599318770827523191507794494653442014857111518160506592547548123217567703264 * α ^ 29 * (17 - α) ^ 49 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 49) - have h30 : (0:ℝ) ≤ 670800231791884784143046690550307121328633658472928365947843469281367978857427131528889056504264285777346962640789773628915428849835988530657823235764048 * α ^ 30 * (17 - α) ^ 48 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 48) - have h31 : (0:ℝ) ≤ 2984619384354511629107356504926848471696327337771023943436513427949142667105830054851593100735343248824065325292573736440802608827461183426769246769291552 * α ^ 31 * (17 - α) ^ 47 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 47) - have h32 : (0:ℝ) ≤ 12443245301685101113004238920453035362065480822223920063453295700954394658154324530222082866216981544902180469303864185921832037521423470739534568240530698 * α ^ 32 * (17 - α) ^ 46 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 46) - have h33 : (0:ℝ) ≤ 48630498545566508730887646850031839032254744413887093356079449812021579883240090827460324033575160396265167473696926411553805741150177366589537208618389312 * α ^ 33 * (17 - α) ^ 45 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 45) - have h34 : (0:ℝ) ≤ 178224283616173729873597347832665682938537443237014013583101955743465983895935219727459727536113766122912311165368553083312822196229416994722881465788897608 * α ^ 34 * (17 - α) ^ 44 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 44) - have h35 : (0:ℝ) ≤ 612680644790166184991917379793912279464385512434753774369824036938764938304766938235637731701416442390635006960662151462757565543096111536600700611590433104 * α ^ 35 * (17 - α) ^ 43 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 43) - have h36 : (0:ℝ) ≤ 1976111675207627574170813927131479302618451807610755803915352844606204227936969836964454024080255606582154150762724021578810678171015308008029327160761230036 * α ^ 36 * (17 - α) ^ 42 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 42) - have h37 : (0:ℝ) ≤ 5981029220510678070817415728895653202641308066347103599758984876348600755271333269460791392164878746120136312582494705765569069531832293963655323002573446064 * α ^ 37 * (17 - α) ^ 41 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 41) - have h38 : (0:ℝ) ≤ 16989543154359445469457986390510733383994704572611451201272330066228088393042712150225004932550683152805630464909266619414416501639238958482074875942132768616 * α ^ 38 * (17 - α) ^ 40 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 38)) (pow_nonneg hu 40) - have h39 : (0:ℝ) ≤ 45296105880774016543608993638859556610721433636610042456973317141222907592128054856106393044377927691870302622862352603383769755644737397448590274359670368944 * α ^ 39 * (17 - α) ^ 39 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 39)) (pow_nonneg hu 39) - have h40 : (0:ℝ) ≤ 113350571234050534076326107126518287982410454182311080227306939093496067875998083564452872849439161949940409925105928531974054521742151944897862268669201061520 * α ^ 40 * (17 - α) ^ 38 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 40)) (pow_nonneg hu 38) - have h41 : (0:ℝ) ≤ 266231157835868807500470306762042513611189637040966950733290536030191636687157078964587562059672497373973922906293139029665558703936748610317140546883955859680 * α ^ 41 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 41)) (pow_nonneg hu 37) - have h42 : (0:ℝ) ≤ 586858197296154628798446528461843998024068971134701870886809269117315332250708613879369916177860732342900319979198468207186334042554992489311324197461026564960 * α ^ 42 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 42)) (pow_nonneg hu 36) - have h43 : (0:ℝ) ≤ 1213922719117161670068732317088234253543419578795181021310311760507171888098020651110360608663151069102950683003635002998812668248827290683460647339113637593920 * α ^ 43 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 43)) (pow_nonneg hu 35) - have h44 : (0:ℝ) ≤ 2355882656955618145368440772792310544302184458306643829069873721060849050791043491096322023978836887243291929862008841402040135117369951147006375023758607414630 * α ^ 44 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 44)) (pow_nonneg hu 34) - have h45 : (0:ℝ) ≤ 4288620425723236042270245525821460550276787699330226001900869309698399107377083284501409207640281375703914610994654965609663507351571250965113379319161632928200 * α ^ 45 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 45)) (pow_nonneg hu 33) - have h46 : (0:ℝ) ≤ 7320707928796224459121297405137632144399624953401924235118562284160734706017732510625383671234631311037891028803627184501344210399941335731279835946303059679200 * α ^ 46 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 46)) (pow_nonneg hu 32) - have h47 : (0:ℝ) ≤ 11713899213743447915704134395332202117298482214292060770979810663078726380483695637745416926561937897954981745807583035850470327859420144985559683638576277883400 * α ^ 47 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 47)) (pow_nonneg hu 31) - have h48 : (0:ℝ) ≤ 17561942867533342398436880431957294329537588050449243474998468656204324106460768754190028781389060814644401148893175783608534017391500137587346401404729767961775 * α ^ 48 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 48)) (pow_nonneg hu 30) - have h49 : (0:ℝ) ≤ 24657037500931233931100038936709405139583850503696185642594534868113339647480541733889215934553454050856843493087316935868401534155234466743591899388039722825000 * α ^ 49 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 49)) (pow_nonneg hu 29) - have h50 : (0:ℝ) ≤ 32399766183005623339431502134384903673258583171905972220491732685551275126382181817021974632337480906159861245942216595446130287593916379360777739204014519763740 * α ^ 50 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 50)) (pow_nonneg hu 28) - have h51 : (0:ℝ) ≤ 39816869923705792061452702806451616229648477329837692188071941553276215504100718506084662900753752185561490136348790335058840343832503703423988939862391056305232 * α ^ 51 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 51)) (pow_nonneg hu 27) - have h52 : (0:ℝ) ≤ 45725596948318007559653827457799417148215312861758852406937933348972792240139365978502472349006051930446814676684606316211695543376347509599898036528286933085224 * α ^ 52 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 52)) (pow_nonneg hu 26) - have h53 : (0:ℝ) ≤ 49023805818598732375036617236844617864434596645116211451566972339635320087833097798204901700925015829301327369649045560010979770125252618435350703761516463073848 * α ^ 53 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 53)) (pow_nonneg hu 25) - have h54 : (0:ℝ) ≤ 49015998485968580948941115202148896246224655491148535539418948950288060451674238170130060593823432628223618516376352101072100358750709310490151188159024541427052 * α ^ 54 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 54)) (pow_nonneg hu 24) - have h55 : (0:ℝ) ≤ 45647022194403892164725670688230786593406330796296866532743501180312044777291667628466008426907011381782621245185421119984904334692872397917622931589975159950376 * α ^ 55 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 55)) (pow_nonneg hu 23) - have h56 : (0:ℝ) ≤ 39538178387322663214678107833346063706962357676818250082020803464382411757712672815180178231414974228300278324399692737955948708504923951831175084051680088175165 * α ^ 56 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 56)) (pow_nonneg hu 22) - have h57 : (0:ℝ) ≤ 31801899439090094777334950705334813338730886166159685008908427150218448246372446469199745436135611138307188820293411565869844276004036024233170865193572905525320 * α ^ 57 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 57)) (pow_nonneg hu 21) - have h58 : (0:ℝ) ≤ 23709975953138035217254879474127618178276877789282349375912411789239026737801814945663600235688954031236781561111671014867771739568818009667175830050625483670800 * α ^ 58 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 58)) (pow_nonneg hu 20) - have h59 : (0:ℝ) ≤ 16351417027375290237568460048941744283542362032677807325524002415873874456253818166492303955129235315728196511827486827201910640986408449258178453972071138841280 * α ^ 59 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 59)) (pow_nonneg hu 19) - have h60 : (0:ℝ) ≤ 10406661000804048469244285454442048401950551096021855689021431743408141364929640862344616974092488532662628383447959199105412832327366951066981956912776793272828 * α ^ 60 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 60)) (pow_nonneg hu 18) - have h61 : (0:ℝ) ≤ 6096044218883636648858638385299408772703826861168771488836313560232401989614872890471308028293712697562093239071809816669597593582410767226213878470560164105360 * α ^ 61 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 61)) (pow_nonneg hu 17) - have h62 : (0:ℝ) ≤ 3276846591075729012589755509945912260769516795393912260645693976533757884223032498368536502265562067479892796636427846477439354731388021106706514152220778103040 * α ^ 62 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 62)) (pow_nonneg hu 16) - have h63 : (0:ℝ) ≤ 1610794513834802575152755949091561602421721957898331237110261276182871154723607727539375914584552916560724124724924463417208104868865606317263016841364405825680 * α ^ 63 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 63)) (pow_nonneg hu 15) - have h64 : (0:ℝ) ≤ 721246729451681999848797234165823691040492879910986098969913863731997028544659333437426233091222522940845475324110626012544305358208410635315439163726896332470 * α ^ 64 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 64)) (pow_nonneg hu 14) - have h65 : (0:ℝ) ≤ 292822391376166813009638824792532072858861097043830666638215128792614436289145455232446359525025830476319501900465615628266091285776053359537792998581547295600 * α ^ 65 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 65)) (pow_nonneg hu 13) - have h66 : (0:ℝ) ≤ 107224012150816902001912227507553282916599557139225796253173519533916191353535425807887044534914331713036619424330904015814415822193999401215526600838512604840 * α ^ 66 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 66)) (pow_nonneg hu 12) - have h67 : (0:ℝ) ≤ 35191006165935842226308618125286667631304103617509372764131233521722150894012101410223152943777334278979699369241450735115442948195848108495015472586714890880 * α ^ 67 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 67)) (pow_nonneg hu 11) - have h68 : (0:ℝ) ≤ 10275267801259336459300721782985532390900842929751059267873958488400935538863318074454099079440422678680619531094605908728254236555735059631933624997615828260 * α ^ 68 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 68)) (pow_nonneg hu 10) - have h69 : (0:ℝ) ≤ 2645336786640622909024119594938504328204268908990167832700614571718874779959845931540799248941313778802020955617601042505306160484123987291058458612715400640 * α ^ 69 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 69)) (pow_nonneg hu 9) - have h70 : (0:ℝ) ≤ 593906665872865965150458489550777045487297564791632460724893427149867065488464014938181589464594007951273185164028728407261435342265396855306832150409931320 * α ^ 70 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 70)) (pow_nonneg hu 8) - have h71 : (0:ℝ) ≤ 114690263695272628709900519325805172252624298016857930148989306502982113118510158582594826209607467459228127771008256970868516723274528081539115152119985440 * α ^ 71 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 71)) (pow_nonneg hu 7) - have h72 : (0:ℝ) ≤ 18716846109423476071035991682553676602728521782795818848220231089640237632710705010278610380508724798549109713393602376467223809385880736717949117062987530 * α ^ 72 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 72)) (pow_nonneg hu 6) - have h73 : (0:ℝ) ≤ 2521536870830508163836030824568047223988339893444693792826398274518701446642999471126321332113161322019782540488604986950909127037746871670766269501360960 * α ^ 73 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 73)) (pow_nonneg hu 5) - have h74 : (0:ℝ) ≤ 271493817296270881805641386430241155441908017852388246927155500054431367358594643258294586467756369131577116044199352316870588393438911740552090772405440 * α ^ 74 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 74)) (pow_nonneg hu 4) - have h75 : (0:ℝ) ≤ 22279566970411804598533929895269272846291071572877769238590666634237638229153811201206324018077221933863978836996195706320785275148859533443992017146000 * α ^ 75 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 75)) (pow_nonneg hu 3) - have h76 : (0:ℝ) ≤ 1291912491540789931050578781552895013123449146872856063262109993503327217135399912381220941445555078359565379700265238460988056930139111470428573934100 * α ^ 76 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 76)) (pow_nonneg hu 2) - have h77 : (0:ℝ) ≤ 46088990360704592332570841005323881782750533628800932523924974522918510553541700882043059731976492164473134284830339681303220274485070007892391252000 * α ^ 77 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 77)) (pow_nonneg hu 1) - have h78 : (0:ℝ) ≤ 725258734923967308075393848591202551763398627116692128836036203184259468021639559495815066910705200892668021559827725204513110094309349741193210000 * α ^ 78 := - mul_nonneg (by norm_num) (pow_nonneg hα 78) have hid : (17 : ℝ) ^ 78 * (25811606424535915506326543401482443660479168162161070878750987845784640947537512918254143661443967851841624182260454 + 336370345330350208165234204307830830778265112065902973986047706784620119812179101529287799329664970700047233908530028 * α + 2135490323710205451177831007886434323850910269893926405766449302023972016567372609179660983528148958829173461437058426 * α ^ 2 + 8800193380808665214547458427848614541537421741398394617093689631071556593600442609061272206311515066984302690924269000 * α ^ 3 + 26462827687725576351409435396337556001601266481763435312645957683742611763538244106923991390112640216709155823432046446 * α ^ 4 + 61890317824100182817489513892770080906362674388551785381427868354803942587321704313688072997460165545388054174413205140 * α ^ 5 + 117172359697259929763030783557189322339080300100874585985220084088882745103145230216047487779174956161518920280447603674 * α ^ 6 + 184544739027532874709347195849421533711097651533181291373211062330869431152671413319813999120439419738468174182904364464 * α ^ 7 + 246608145764613286789878656386710073720610930090411123420903881172229605185065434892818764890373842116194248634263756798 * α ^ 8 + 283763693487574246430404620051411555790859557853657413692053633072552222818811355084552210214522447497912164915857007772 * α ^ 9 + 284375388167493337786979561808634395465424553508941556573930507406581722477890971264427055005741911794482115087411543730 * α ^ 10 + 250434456333498778687253731739220273422355020504490227298836915758303181227856673748711052077418442551670601820448469608 * α ^ 11 + 195186376833089073717511924197741339564583901408375396552289751612744737294639334816437871802096096044647044024483571528 * α ^ 12 + 135403325876044028593166865189418922031634343539481341612266706224679843802900374983571701066935649917189903585957861976 * α ^ 13 + 83987295633438700092517506437803590415296544388998812046873276158407316217262430264254188896692746403373298520205212844 * α ^ 14 + 46749761312162043935912318982126078666828249385834636225082169910759646501503433598091545864589766997203234619939545928 * α ^ 15 + 23418772546685983831264607439067708954491960164074800112819444923487497120280358300648725634717312663795784508649665131 * α ^ 16 + 10580616042971700828358189370081401738808367070894586162364463432933276777181125840333157268302229461101124643546709974 * α ^ 17 + 4318183659819981488074693370040938716545728929617703773317165795943654804101138834083140850940446923358733078548068645 * α ^ 18 + 1593587693765014079746102214238987350113694708675138266157201007419844029857283186926010079342854945184589138949560164 * α ^ 19 + 532047925009422644797257472015181516662587259482075864085888807106871007422932953581727885439598490014141304896691047 * α ^ 20 + 160701892364069140905358669813546549814319510910544697552500165178091918076856803958923921001593977227161490804746106 * α ^ 21 + 43889653627121057923774311030558057038777866396589839090993605786486211704353490599487695285745585770243180871001173 * α ^ 22 + 10827357706237228452243490602525886439138079007606319319715720331950005385599610283148806774807521304374526909486664 * α ^ 23 + 2408842256812625932290911263046890728148322122703071503064745543954110106028352314896838503963205885454006647328032 * α ^ 24 + 482237450846393383131287501498018968499665598348674814673101519961867723893846884326467389187302292657246662111488 * α ^ 25 + 86620744735037078123451064351322751112466467920961355862225908103410633498456796660448573578914072648246281297272 * α ^ 26 + 13908651519349479073873240534072463905809010212400405416347877534040408226391579668251784782713336166212519013104 * α ^ 27 + 1987136509055095540850907316692328719109975779097323211935130132295635949953814198439654077152611676110556260102 * α ^ 28 + 251138932516361376722297645486554574796035287318555929793528638706264274506637419055880639659286763175005448076 * α ^ 29 + 27871094123052914818399316975765472111564288696313684416212667809570265754686721498698986614959173244385297518 * α ^ 30 + 2690865047909357054511239261296500605261094896849533507003089976244070348637842057420543829564694293947173400 * α ^ 31 + 223291370726238703406997118812607738047342804101888528968918478200237656608670127439529056632663807296136083 * α ^ 32 + 15669985331287744715848606174054829999776651533612117903292549399606649200386705738963593063781305669960598 * α ^ 33 + 909073729758232176167878755737698432102154655242833248859457302905520734577946123899448989405380991348941 * α ^ 34 + 42091260471451636997926921594629293230252747899173824918202060597101883618323097768155200270442748875668 * α ^ 35 + 1450861895455204845787988647170733163350496179912678839329200986510884388428173389320127180407765638551 * α ^ 36 + 19698279579096177164787018164158789132912466550646401885212259058865017062230215250892367283766302154 * α ^ 37 - 57652053317489414390572934832324830300466266131622345505450510286650133357321127488185831111381791595 * α ^ 38 + 735839726136777192033003352499083088738558026604488978404480341017143472486567180936350888710307864 * α ^ 39 - 4556557091452941380040035385055147646930930624200910749123957637499614710015132762550103799821048 * α ^ 40 - 133385784303410256278801057965454595590178412725438433339158980224721485193506478868247418219456 * α ^ 41 - 3423096723020314850982421385371010756189634167048478694293828864372204445633272936186470719904 * α ^ 42 - 69804839903958953293946387520015029557798645931631581080348037608367532112774187909634522240 * α ^ 43 - 865452330871186953510596734828786492278941181396935228550729318386099014534564956306824064 * α ^ 44 + 6798618471243250403976624728656397719531634223766543816506986827945697172779099788420608 * α ^ 45 + 788561506471686257274486905164229697457259305541495354329419768350740667053416558054144 * α ^ 46 + 27404388758747154771370930189376580679701159098426606936627216153391035767084433846272 * α ^ 47 + 646649551478726098614980210707984819816807233831805276746361716798674738190577340416 * α ^ 48 + 11211130515851440319438235357551475100839553634180130203899774136494056161035911168 * α ^ 49 + 130654761491363390209265527305244677484674002463471732106539824077702885812797440 * α ^ 50 + 357370958717189390935129396104908992248522307474545437642970135644954582646784 * α ^ 51 - 29181736810016345568442240720495430859483450421903151495150669166766787592192 * α ^ 52 - 955989844135526470691849812345208816075517571032312722273829147296013484032 * α ^ 53 - 19693589749621923555627023816809550207524792367857705784556171741361864704 * α ^ 54 - 319527958823219288171919301676630081495413277792849934402743906350399488 * α ^ 55 - 4359916692864270231911575583538878442433933182393484084715401339994112 * α ^ 56 - 51487996872395271018065603117315986670053043845988016897449388933120 * α ^ 57 - 534287852041371238607889671805075544881560005268660814584293097472 * α ^ 58 - 4914742088163302214038533958003066516795399439930469941648556032 * α ^ 59 - 40286770643795091951577560453084774722804729349509280681689088 * α ^ 60 - 295170417808439805757992973335875121127546339919271705968640 * α ^ 61 - 1935804396482191076314681386409043851261791712104853536768 * α ^ 62 - 11366432523474642581662414816114955814707861565858643968 * α ^ 63 - 59703170845283859723339853111711322814822346376871936 * α ^ 64 - 280018128137086019618307155094771953353132297158656 * α ^ 65 - 1169385347161959260160465901639985114274911485952 * α ^ 66 - 4331161143994110763407260197680039459865755648 * α ^ 67 - 14153828793218044771011521216530198581739520 * α ^ 68 - 40537586126827346928475190951612417835008 * α ^ 69 - 100883783567908658123954038279633895424 * α ^ 70 - 215746527094612923562575346607849472 * α ^ 71 - 390762372880065519809958474940416 * α ^ 72 - 587839886222327464463148515328 * α ^ 73 - 714822291149465741724483584 * α ^ 74 - 675179423113136706682880 * α ^ 75 - 464818794079734202368 * α ^ 76 - 207493237324120064 * α ^ 77 - 45079976738816 * α ^ 78) = 25811606424535915506326543401482443660479168162161070878750987845784640947537512918254143661443967851841624182260454 * (17 - α) ^ 78 + 7731601171729754948302451858548754728747882021768914086305388067309744030714970733621715794196933994344449662661325888 * α ^ 1 * (17 - α) ^ 77 + 1134977739682559152144183344552781855394081041684581420063129512966886926387568279248276946977482731207073356960903835128 * α ^ 2 * (17 - α) ^ 76 + 108834637037659199091355921419729186300121822584927223690221434809345565260667023227379040139264943526676297937882231816944 * α ^ 3 * (17 - α) ^ 75 + 7666861356053587141879051542023151513155253675338534070219208289734940750831143744550245239925873313943561985580954527982616 * α ^ 4 * (17 - α) ^ 74 + 423077887233518864483787884707532169136310014420797711374285732639883356220901878487666885430844058504013013662258662655409024 * α ^ 5 * (17 - α) ^ 73 + 19043789756155440424344440725874751801324872083267566506068169098722085040014291705260338415543274194102043673327180400129929832 * α ^ 6 * (17 - α) ^ 72 + 718947188407260825753518059058500078605524217441449955961763119488742316279761434573371789300650648290365793225194740365639829248 * α ^ 7 * (17 - α) ^ 71 + 23229944260791702898096600141389848573573933604759267334016067683455922366132699662001188778646003391197287922373361993488875467772 * α ^ 8 * (17 - α) ^ 70 + 652356286335394807010040506322513589425276848772982033180582110575315337819948577150432209238058606495049799638171924460488723115728 * α ^ 9 * (17 - α) ^ 69 + 16115244618115471773154398428945842467530527293496478962865411951374999566160962962621541576431428483629410984630108362973322526046352 * α ^ 10 * (17 - α) ^ 68 + 353590213705899227670735133595068406610777044757491438541768497813388671143323439181516543806998722646874310797601900004357046159618416 * α ^ 11 * (17 - α) ^ 67 + 6945545366374205473681219757999841297413797165201420435841487238189483615527433260434909542451873571311839418856181380505673028690189834 * α ^ 12 * (17 - α) ^ 66 + 122943429683776586616098034509418349763379413100200501385374144116228404023652411356804056379171036434910191105635835310497125437439368616 * α ^ 13 * (17 - α) ^ 65 + 1971943361675961854095978497179540085473722438976489160404258526153302499359290412285125679239602051452003303294340674036438891755271461344 * α ^ 14 * (17 - α) ^ 64 + 28794613849932432807185452777239504156831844265536120723695409096275314438957801587812894208037520422020805646713238048377079475740273188040 * α ^ 15 * (17 - α) ^ 63 + 384328560383502952032438759151017028938946671283519542604007361014389867788722109711367554903315805912734859044701209907625689918745997497675 * α ^ 16 * (17 - α) ^ 62 + 4705189064883150340603293176324983232690962514057066121441689655603425308970643761709274220489500917477746179322066734647863357743464493676520 * α ^ 17 * (17 - α) ^ 61 + 52996214890563273796160643818818348185528424059725114966862380369319342813162215520720537479664066314153467772804561608859372679443782254992220 * α ^ 18 * (17 - α) ^ 60 + 550617253247385218427009607064332121441409621321669095638902982534390077955117952713512591688404159855259550612508039696237055140143912070148080 * α ^ 19 * (17 - α) ^ 59 + 5289254261689909642998694788883801072432560837908488801188757508626280600068147475966012413534329068218714313264686298658627525464990766966507480 * α ^ 20 * (17 - α) ^ 58 + 47071723811940484288699822861559515707560341788285556322087973575337149744998528596195569152380487445854405880284205334835719251975349528608895960 * α ^ 21 * (17 - α) ^ 57 + 388797566873530668184175407886161066305517869569175948336046190337058590155012538967688933864691298489884730691529378580953514253496007438959580140 * α ^ 22 * (17 - α) ^ 56 + 2985179603519724471752085802643613314281923391910045186703182258691770626157427630859816171548924404331298520035371797680826375874045307985095169160 * α ^ 23 * (17 - α) ^ 55 + 21335697765899092801522874710986881769845405599093285192366939176739104568310936178280383293402533817032054113166202401026875457402502001299016941965 * α ^ 24 * (17 - α) ^ 54 + 142124309577284830558031748098405686449899656084274181428411809022465874914849955156662717515516567844716088626134776657964597427502198457271981932744 * α ^ 25 * (17 - α) ^ 53 + 883340987406927324886485469060737975106344280304169568718286595798294963628744880539858577253973934458679980792763078663809587077960963632717815152096 * α ^ 26 * (17 - α) ^ 52 + 5127488920008786553466393714789905427388213762697569627668475082844096754564454348757229349829628841608199919978811602705936439756284569017181261626624 * α ^ 27 * (17 - α) ^ 51 + 27820537271116488598533849210418200371695645263092839593736637431588817343110855564285745636333362483896532668071984474388396970246448477332845548675696 * α ^ 28 * (17 - α) ^ 50 + 141199792955232750444991232388282777593870842150187857240279059394142520379652599318770827523191507794494653442014857111518160506592547548123217567703264 * α ^ 29 * (17 - α) ^ 49 + 670800231791884784143046690550307121328633658472928365947843469281367978857427131528889056504264285777346962640789773628915428849835988530657823235764048 * α ^ 30 * (17 - α) ^ 48 + 2984619384354511629107356504926848471696327337771023943436513427949142667105830054851593100735343248824065325292573736440802608827461183426769246769291552 * α ^ 31 * (17 - α) ^ 47 + 12443245301685101113004238920453035362065480822223920063453295700954394658154324530222082866216981544902180469303864185921832037521423470739534568240530698 * α ^ 32 * (17 - α) ^ 46 + 48630498545566508730887646850031839032254744413887093356079449812021579883240090827460324033575160396265167473696926411553805741150177366589537208618389312 * α ^ 33 * (17 - α) ^ 45 + 178224283616173729873597347832665682938537443237014013583101955743465983895935219727459727536113766122912311165368553083312822196229416994722881465788897608 * α ^ 34 * (17 - α) ^ 44 + 612680644790166184991917379793912279464385512434753774369824036938764938304766938235637731701416442390635006960662151462757565543096111536600700611590433104 * α ^ 35 * (17 - α) ^ 43 + 1976111675207627574170813927131479302618451807610755803915352844606204227936969836964454024080255606582154150762724021578810678171015308008029327160761230036 * α ^ 36 * (17 - α) ^ 42 + 5981029220510678070817415728895653202641308066347103599758984876348600755271333269460791392164878746120136312582494705765569069531832293963655323002573446064 * α ^ 37 * (17 - α) ^ 41 + 16989543154359445469457986390510733383994704572611451201272330066228088393042712150225004932550683152805630464909266619414416501639238958482074875942132768616 * α ^ 38 * (17 - α) ^ 40 + 45296105880774016543608993638859556610721433636610042456973317141222907592128054856106393044377927691870302622862352603383769755644737397448590274359670368944 * α ^ 39 * (17 - α) ^ 39 + 113350571234050534076326107126518287982410454182311080227306939093496067875998083564452872849439161949940409925105928531974054521742151944897862268669201061520 * α ^ 40 * (17 - α) ^ 38 + 266231157835868807500470306762042513611189637040966950733290536030191636687157078964587562059672497373973922906293139029665558703936748610317140546883955859680 * α ^ 41 * (17 - α) ^ 37 + 586858197296154628798446528461843998024068971134701870886809269117315332250708613879369916177860732342900319979198468207186334042554992489311324197461026564960 * α ^ 42 * (17 - α) ^ 36 + 1213922719117161670068732317088234253543419578795181021310311760507171888098020651110360608663151069102950683003635002998812668248827290683460647339113637593920 * α ^ 43 * (17 - α) ^ 35 + 2355882656955618145368440772792310544302184458306643829069873721060849050791043491096322023978836887243291929862008841402040135117369951147006375023758607414630 * α ^ 44 * (17 - α) ^ 34 + 4288620425723236042270245525821460550276787699330226001900869309698399107377083284501409207640281375703914610994654965609663507351571250965113379319161632928200 * α ^ 45 * (17 - α) ^ 33 + 7320707928796224459121297405137632144399624953401924235118562284160734706017732510625383671234631311037891028803627184501344210399941335731279835946303059679200 * α ^ 46 * (17 - α) ^ 32 + 11713899213743447915704134395332202117298482214292060770979810663078726380483695637745416926561937897954981745807583035850470327859420144985559683638576277883400 * α ^ 47 * (17 - α) ^ 31 + 17561942867533342398436880431957294329537588050449243474998468656204324106460768754190028781389060814644401148893175783608534017391500137587346401404729767961775 * α ^ 48 * (17 - α) ^ 30 + 24657037500931233931100038936709405139583850503696185642594534868113339647480541733889215934553454050856843493087316935868401534155234466743591899388039722825000 * α ^ 49 * (17 - α) ^ 29 + 32399766183005623339431502134384903673258583171905972220491732685551275126382181817021974632337480906159861245942216595446130287593916379360777739204014519763740 * α ^ 50 * (17 - α) ^ 28 + 39816869923705792061452702806451616229648477329837692188071941553276215504100718506084662900753752185561490136348790335058840343832503703423988939862391056305232 * α ^ 51 * (17 - α) ^ 27 + 45725596948318007559653827457799417148215312861758852406937933348972792240139365978502472349006051930446814676684606316211695543376347509599898036528286933085224 * α ^ 52 * (17 - α) ^ 26 + 49023805818598732375036617236844617864434596645116211451566972339635320087833097798204901700925015829301327369649045560010979770125252618435350703761516463073848 * α ^ 53 * (17 - α) ^ 25 + 49015998485968580948941115202148896246224655491148535539418948950288060451674238170130060593823432628223618516376352101072100358750709310490151188159024541427052 * α ^ 54 * (17 - α) ^ 24 + 45647022194403892164725670688230786593406330796296866532743501180312044777291667628466008426907011381782621245185421119984904334692872397917622931589975159950376 * α ^ 55 * (17 - α) ^ 23 + 39538178387322663214678107833346063706962357676818250082020803464382411757712672815180178231414974228300278324399692737955948708504923951831175084051680088175165 * α ^ 56 * (17 - α) ^ 22 + 31801899439090094777334950705334813338730886166159685008908427150218448246372446469199745436135611138307188820293411565869844276004036024233170865193572905525320 * α ^ 57 * (17 - α) ^ 21 + 23709975953138035217254879474127618178276877789282349375912411789239026737801814945663600235688954031236781561111671014867771739568818009667175830050625483670800 * α ^ 58 * (17 - α) ^ 20 + 16351417027375290237568460048941744283542362032677807325524002415873874456253818166492303955129235315728196511827486827201910640986408449258178453972071138841280 * α ^ 59 * (17 - α) ^ 19 + 10406661000804048469244285454442048401950551096021855689021431743408141364929640862344616974092488532662628383447959199105412832327366951066981956912776793272828 * α ^ 60 * (17 - α) ^ 18 + 6096044218883636648858638385299408772703826861168771488836313560232401989614872890471308028293712697562093239071809816669597593582410767226213878470560164105360 * α ^ 61 * (17 - α) ^ 17 + 3276846591075729012589755509945912260769516795393912260645693976533757884223032498368536502265562067479892796636427846477439354731388021106706514152220778103040 * α ^ 62 * (17 - α) ^ 16 + 1610794513834802575152755949091561602421721957898331237110261276182871154723607727539375914584552916560724124724924463417208104868865606317263016841364405825680 * α ^ 63 * (17 - α) ^ 15 + 721246729451681999848797234165823691040492879910986098969913863731997028544659333437426233091222522940845475324110626012544305358208410635315439163726896332470 * α ^ 64 * (17 - α) ^ 14 + 292822391376166813009638824792532072858861097043830666638215128792614436289145455232446359525025830476319501900465615628266091285776053359537792998581547295600 * α ^ 65 * (17 - α) ^ 13 + 107224012150816902001912227507553282916599557139225796253173519533916191353535425807887044534914331713036619424330904015814415822193999401215526600838512604840 * α ^ 66 * (17 - α) ^ 12 + 35191006165935842226308618125286667631304103617509372764131233521722150894012101410223152943777334278979699369241450735115442948195848108495015472586714890880 * α ^ 67 * (17 - α) ^ 11 + 10275267801259336459300721782985532390900842929751059267873958488400935538863318074454099079440422678680619531094605908728254236555735059631933624997615828260 * α ^ 68 * (17 - α) ^ 10 + 2645336786640622909024119594938504328204268908990167832700614571718874779959845931540799248941313778802020955617601042505306160484123987291058458612715400640 * α ^ 69 * (17 - α) ^ 9 + 593906665872865965150458489550777045487297564791632460724893427149867065488464014938181589464594007951273185164028728407261435342265396855306832150409931320 * α ^ 70 * (17 - α) ^ 8 + 114690263695272628709900519325805172252624298016857930148989306502982113118510158582594826209607467459228127771008256970868516723274528081539115152119985440 * α ^ 71 * (17 - α) ^ 7 + 18716846109423476071035991682553676602728521782795818848220231089640237632710705010278610380508724798549109713393602376467223809385880736717949117062987530 * α ^ 72 * (17 - α) ^ 6 + 2521536870830508163836030824568047223988339893444693792826398274518701446642999471126321332113161322019782540488604986950909127037746871670766269501360960 * α ^ 73 * (17 - α) ^ 5 + 271493817296270881805641386430241155441908017852388246927155500054431367358594643258294586467756369131577116044199352316870588393438911740552090772405440 * α ^ 74 * (17 - α) ^ 4 + 22279566970411804598533929895269272846291071572877769238590666634237638229153811201206324018077221933863978836996195706320785275148859533443992017146000 * α ^ 75 * (17 - α) ^ 3 + 1291912491540789931050578781552895013123449146872856063262109993503327217135399912381220941445555078359565379700265238460988056930139111470428573934100 * α ^ 76 * (17 - α) ^ 2 + 46088990360704592332570841005323881782750533628800932523924974522918510553541700882043059731976492164473134284830339681303220274485070007892391252000 * α ^ 77 * (17 - α) ^ 1 + 725258734923967308075393848591202551763398627116692128836036203184259468021639559495815066910705200892668021559827725204513110094309349741193210000 * α ^ 78 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 25811606424535915506326543401482443660479168162161070878750987845784640947537512918254143661443967851841624182260454 * (17 - α) ^ 78 := - mul_pos (by norm_num) (pow_pos (by linarith) 78) - linarith - · have hpos : (0 : ℝ) < 725258734923967308075393848591202551763398627116692128836036203184259468021639559495815066910705200892668021559827725204513110094309349741193210000 * α ^ 78 := - mul_pos (by norm_num) (pow_pos (by linarith) 78) - linarith + -- The Bernstein summands are nonnegative. If α > 0 the last one is positive; + -- at α = 0 the first one is positive. No per-coefficient hypotheses are needed. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 78)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree8_9.lean b/Sendov/FiniteRange/Degree8_9.lean index 9f97817..33482ec 100644 --- a/Sendov/FiniteRange/Degree8_9.lean +++ b/Sendov/FiniteRange/Degree8_9.lean @@ -88,29 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 4) : 0 < 656208 + 407736 * α - 877827 * α ^ 2 + 621074 * α ^ 3 - 39267 * α ^ 4 - 5436 * α ^ 5 - 180 * α ^ 6 := by have hu : (0 : ℝ) ≤ 4 - α := by linarith - have h0 : (0:ℝ) ≤ 656208 * (4 - α) ^ 6 := - mul_nonneg (by norm_num) (pow_nonneg hu 6) - have h1 : (0:ℝ) ≤ 5568192 * α ^ 1 * (4 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 5) - have h2 : (0:ℝ) ≤ 3952608 * α ^ 2 * (4 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 4) - have h3 : (0:ℝ) ≤ 13001408 * α ^ 3 * (4 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 3) - have h4 : (0:ℝ) ≤ 51075024 * α ^ 4 * (4 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 2) - have h5 : (0:ℝ) ≤ 49486080 * α ^ 5 * (4 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 1) - have h6 : (0:ℝ) ≤ 11634560 * α ^ 6 := - mul_nonneg (by norm_num) (pow_nonneg hα 6) have hid : (4 : ℝ) ^ 6 * (656208 + 407736 * α - 877827 * α ^ 2 + 621074 * α ^ 3 - 39267 * α ^ 4 - 5436 * α ^ 5 - 180 * α ^ 6) = 656208 * (4 - α) ^ 6 + 5568192 * α ^ 1 * (4 - α) ^ 5 + 3952608 * α ^ 2 * (4 - α) ^ 4 + 13001408 * α ^ 3 * (4 - α) ^ 3 + 51075024 * α ^ 4 * (4 - α) ^ 2 + 49486080 * α ^ 5 * (4 - α) ^ 1 + 11634560 * α ^ 6 := by ring - rcases le_total α (4 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 656208 * (4 - α) ^ 6 := - mul_pos (by norm_num) (pow_pos (by linarith) 6) - linarith - · have hpos : (0 : ℝ) < 11634560 * α ^ 6 := - mul_pos (by norm_num) (pow_pos (by linarith) 6) - linarith + -- The Bernstein summands are nonnegative. If α > 0 the last one is positive; + -- at α = 0 the first one is positive. No per-coefficient hypotheses are needed. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (4 : ℝ) ^ 6)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 4 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget From c90d0281e0782d2694b50c02b05a1433ca98a629 Mon Sep 17 00:00:00 2001 From: Methode Date: Sat, 12 Sep 2026 08:26:21 -0700 Subject: [PATCH 02/24] [verified] Compress active certificate family and scalar proof plumbing --- Sendov/Analytic/Defect.lean | 20 +--- Sendov/FiniteRange/Degree10_11.lean | 33 ++---- Sendov/FiniteRange/Degree12_13.lean | 37 ++----- Sendov/FiniteRange/Degree14_15.lean | 41 ++------ Sendov/FiniteRange/Degree16_18.lean | 45 ++------ Sendov/FiniteRange/Degree18_20.lean | 49 ++------- Sendov/FiniteRange/Degree20_22.lean | 53 ++-------- Sendov/FiniteRange/Degree22_24.lean | 57 ++--------- Sendov/FiniteRange/Degree24_26.lean | 61 ++--------- Sendov/FiniteRange/Degree26_27.lean | 65 ++---------- Sendov/FiniteRange/Degree28_29.lean | 69 ++----------- Sendov/FiniteRange/Degree30_31.lean | 73 ++----------- Sendov/FiniteRange/Degree32_33.lean | 77 ++------------ Sendov/FiniteRange/Degree34_35.lean | 81 ++------------- Sendov/FiniteRange/Degree36_37.lean | 85 ++-------------- Sendov/FiniteRange/Degree38_39.lean | 89 ++-------------- Sendov/FiniteRange/Degree40_41.lean | 93 ++--------------- Sendov/FiniteRange/Degree42_43.lean | 97 ++---------------- Sendov/FiniteRange/Degree44_45.lean | 101 ++---------------- Sendov/FiniteRange/Degree46_47.lean | 105 ++----------------- Sendov/FiniteRange/Degree48_49.lean | 109 ++------------------ Sendov/FiniteRange/Degree50_51.lean | 113 ++------------------ Sendov/FiniteRange/Degree52_53.lean | 117 ++------------------- Sendov/FiniteRange/Degree54_55.lean | 121 ++-------------------- Sendov/FiniteRange/Degree56_58.lean | 125 ++--------------------- Sendov/FiniteRange/Degree58_60.lean | 129 ++--------------------- Sendov/FiniteRange/Degree60_63.lean | 133 ++---------------------- Sendov/FiniteRange/Degree64_69.lean | 141 ++----------------------- Sendov/FiniteRange/Degree6_6.lean | 25 ++--- Sendov/FiniteRange/Degree70_79.lean | 153 ++-------------------------- Sendov/Reduction/Alpha17.lean | 55 +++++----- scripts/emit_batch.py | 24 ++--- 32 files changed, 276 insertions(+), 2300 deletions(-) diff --git a/Sendov/Analytic/Defect.lean b/Sendov/Analytic/Defect.lean index 28be48b..d5edb34 100644 --- a/Sendov/Analytic/Defect.lean +++ b/Sendov/Analytic/Defect.lean @@ -47,24 +47,14 @@ open Multiset /-! ### Products of norms -/ lemma prod_norm_nonneg (s : Multiset ℂ) : 0 ≤ (s.map (fun z => ‖z‖)).prod := by - refine Multiset.prod_nonneg ?_ - intro y hy - obtain ⟨z, _, rfl⟩ := Multiset.mem_map.1 hy - exact norm_nonneg z + exact Multiset.prod_map_nonneg (fun z _ => norm_nonneg z) lemma prod_norm_le_one : ∀ (s : Multiset ℂ), (∀ z ∈ s, ‖z‖ ≤ 1) → (s.map (fun z => ‖z‖)).prod ≤ 1 := by - intro s - induction s using Multiset.induction_on with - | empty => intro _; simp - | cons w t ih => - intro hs - have hw : ‖w‖ ≤ 1 := hs w (mem_cons_self w t) - have ht : ∀ z ∈ t, ‖z‖ ≤ 1 := fun z hz => hs z (mem_cons_of_mem hz) - have hIH := ih ht - have hP0 : 0 ≤ (t.map (fun z => ‖z‖)).prod := prod_norm_nonneg t - simp only [Multiset.map_cons, Multiset.prod_cons] - nlinarith [norm_nonneg w] + intro s hs + simpa [normHom] using + (Multiset.prod_map_le_pow_card (f := (normHom : ℂ →*₀ ℝ)) + (fun z _ => norm_nonneg z) hs) /-! ### The pointwise fact -/ diff --git a/Sendov/FiniteRange/Degree10_11.lean b/Sendov/FiniteRange/Degree10_11.lean index 521c64b..fafaeed 100644 --- a/Sendov/FiniteRange/Degree10_11.lean +++ b/Sendov/FiniteRange/Degree10_11.lean @@ -88,33 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 5) : 0 < 32349375 + 39180105 * α + 10086687 * α ^ 2 - 24445935 * α ^ 3 + 11871036 * α ^ 4 - 351846 * α ^ 5 - 81598 * α ^ 6 - 4664 * α ^ 7 - 88 * α ^ 8 := by have hu : (0 : ℝ) ≤ 5 - α := by linarith - have h0 : (0:ℝ) ≤ 32349375 * (5 - α) ^ 8 := - mul_nonneg (by norm_num) (pow_nonneg hu 8) - have h1 : (0:ℝ) ≤ 454695525 * α ^ 1 * (5 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 7) - have h2 : (0:ℝ) ≤ 2529253350 * α ^ 2 * (5 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 6) - have h3 : (0:ℝ) ≤ 4382737200 * α ^ 3 * (5 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 5) - have h4 : (0:ℝ) ≤ 5044170375 * α ^ 4 * (5 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 4) - have h5 : (0:ℝ) ≤ 11732079375 * α ^ 5 * (5 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 3) - have h6 : (0:ℝ) ≤ 18187642400 * α ^ 6 * (5 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 2) - have h7 : (0:ℝ) ≤ 11329113600 * α ^ 7 * (5 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 1) - have h8 : (0:ℝ) ≤ 2070835200 * α ^ 8 := - mul_nonneg (by norm_num) (pow_nonneg hα 8) have hid : (5 : ℝ) ^ 8 * (32349375 + 39180105 * α + 10086687 * α ^ 2 - 24445935 * α ^ 3 + 11871036 * α ^ 4 - 351846 * α ^ 5 - 81598 * α ^ 6 - 4664 * α ^ 7 - 88 * α ^ 8) = 32349375 * (5 - α) ^ 8 + 454695525 * α ^ 1 * (5 - α) ^ 7 + 2529253350 * α ^ 2 * (5 - α) ^ 6 + 4382737200 * α ^ 3 * (5 - α) ^ 5 + 5044170375 * α ^ 4 * (5 - α) ^ 4 + 11732079375 * α ^ 5 * (5 - α) ^ 3 + 18187642400 * α ^ 6 * (5 - α) ^ 2 + 11329113600 * α ^ 7 * (5 - α) ^ 1 + 2070835200 * α ^ 8 := by ring - rcases le_total α (5 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 32349375 * (5 - α) ^ 8 := - mul_pos (by norm_num) (pow_pos (by linarith) 8) - linarith - · have hpos : (0 : ℝ) < 2070835200 * α ^ 8 := - mul_pos (by norm_num) (pow_pos (by linarith) 8) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (5 : ℝ) ^ 8)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 5 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree12_13.lean b/Sendov/FiniteRange/Degree12_13.lean index 332837f..ba5f96e 100644 --- a/Sendov/FiniteRange/Degree12_13.lean +++ b/Sendov/FiniteRange/Degree12_13.lean @@ -88,37 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 6) : 0 < 67214552328 + 108758874312 * α + 64248083658 * α ^ 2 + 8893434528 * α ^ 3 - 26471207052 * α ^ 4 + 9402730740 * α ^ 5 - 77587159 * α ^ 6 - 46242248 * α ^ 7 - 3634800 * α ^ 8 - 118976 * α ^ 9 - 1456 * α ^ 10 := by have hu : (0 : ℝ) ≤ 6 - α := by linarith - have h0 : (0:ℝ) ≤ 67214552328 * (6 - α) ^ 10 := - mul_nonneg (by norm_num) (pow_nonneg hu 10) - have h1 : (0:ℝ) ≤ 1324698769152 * α ^ 1 * (6 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 9) - have h2 : (0:ℝ) ≤ 11210565079296 * α ^ 2 * (6 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 8) - have h3 : (0:ℝ) ≤ 51982093082304 * α ^ 3 * (6 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 7) - have h4 : (0:ℝ) ≤ 112831785636336 * α ^ 4 * (6 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 6) - have h5 : (0:ℝ) ≤ 136300060037952 * α ^ 5 * (6 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 5) - have h6 : (0:ℝ) ≤ 172834300408608 * α ^ 6 * (6 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 4) - have h7 : (0:ℝ) ≤ 277236880276032 * α ^ 7 * (6 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 3) - have h8 : (0:ℝ) ≤ 281516219316936 * α ^ 8 * (6 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 2) - have h9 : (0:ℝ) ≤ 131510134768320 * α ^ 9 * (6 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 1) - have h10 : (0:ℝ) ≤ 19805743188000 * α ^ 10 := - mul_nonneg (by norm_num) (pow_nonneg hα 10) have hid : (6 : ℝ) ^ 10 * (67214552328 + 108758874312 * α + 64248083658 * α ^ 2 + 8893434528 * α ^ 3 - 26471207052 * α ^ 4 + 9402730740 * α ^ 5 - 77587159 * α ^ 6 - 46242248 * α ^ 7 - 3634800 * α ^ 8 - 118976 * α ^ 9 - 1456 * α ^ 10) = 67214552328 * (6 - α) ^ 10 + 1324698769152 * α ^ 1 * (6 - α) ^ 9 + 11210565079296 * α ^ 2 * (6 - α) ^ 8 + 51982093082304 * α ^ 3 * (6 - α) ^ 7 + 112831785636336 * α ^ 4 * (6 - α) ^ 6 + 136300060037952 * α ^ 5 * (6 - α) ^ 5 + 172834300408608 * α ^ 6 * (6 - α) ^ 4 + 277236880276032 * α ^ 7 * (6 - α) ^ 3 + 281516219316936 * α ^ 8 * (6 - α) ^ 2 + 131510134768320 * α ^ 9 * (6 - α) ^ 1 + 19805743188000 * α ^ 10 := by ring - rcases le_total α (6 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 67214552328 * (6 - α) ^ 10 := - mul_pos (by norm_num) (pow_pos (by linarith) 10) - linarith - · have hpos : (0 : ℝ) < 19805743188000 * α ^ 10 := - mul_pos (by norm_num) (pow_pos (by linarith) 10) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (6 : ℝ) ^ 10)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 6 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree14_15.lean b/Sendov/FiniteRange/Degree14_15.lean index 8512f1d..86f5a93 100644 --- a/Sendov/FiniteRange/Degree14_15.lean +++ b/Sendov/FiniteRange/Degree14_15.lean @@ -88,41 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 7) : 0 < 4540012290450 + 9000770719122 * α + 7217967952260 * α ^ 2 + 2789503991820 * α ^ 3 + 226924812075 * α ^ 4 - 867448623285 * α ^ 5 + 235182487819 * α ^ 6 + 1315276135 * α ^ 7 - 765536900 * α ^ 8 - 78585080 * α ^ 9 - 3463520 * α ^ 10 - 74480 * α ^ 11 - 640 * α ^ 12 := by have hu : (0 : ℝ) ≤ 7 - α := by linarith - have h0 : (0:ℝ) ≤ 4540012290450 * (7 - α) ^ 12 := - mul_nonneg (by norm_num) (pow_nonneg hu 12) - have h1 : (0:ℝ) ≤ 117485542519254 * α ^ 1 * (7 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 11) - have h2 : (0:ℝ) ≤ 1346380586202834 * α ^ 2 * (7 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 10) - have h3 : (0:ℝ) ≤ 8957703596562630 * α ^ 3 * (7 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 9) - have h4 : (0:ℝ) ≤ 37714860895632375 * α ^ 4 * (7 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 8) - have h5 : (0:ℝ) ≤ 91053479724275985 * α ^ 5 * (7 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 7) - have h6 : (0:ℝ) ≤ 128817765797828254 * α ^ 6 * (7 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 6) - have h7 : (0:ℝ) ≤ 133833540832996984 * α ^ 7 * (7 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 5) - have h8 : (0:ℝ) ≤ 161773229978174745 * α ^ 8 * (7 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 4) - have h9 : (0:ℝ) ≤ 197834312331965435 * α ^ 9 * (7 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 3) - have h10 : (0:ℝ) ≤ 152113356071582990 * α ^ 10 * (7 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 2) - have h11 : (0:ℝ) ≤ 57359456154000000 * α ^ 11 * (7 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 1) - have h12 : (0:ℝ) ≤ 7376986416800000 * α ^ 12 := - mul_nonneg (by norm_num) (pow_nonneg hα 12) have hid : (7 : ℝ) ^ 12 * (4540012290450 + 9000770719122 * α + 7217967952260 * α ^ 2 + 2789503991820 * α ^ 3 + 226924812075 * α ^ 4 - 867448623285 * α ^ 5 + 235182487819 * α ^ 6 + 1315276135 * α ^ 7 - 765536900 * α ^ 8 - 78585080 * α ^ 9 - 3463520 * α ^ 10 - 74480 * α ^ 11 - 640 * α ^ 12) = 4540012290450 * (7 - α) ^ 12 + 117485542519254 * α ^ 1 * (7 - α) ^ 11 + 1346380586202834 * α ^ 2 * (7 - α) ^ 10 + 8957703596562630 * α ^ 3 * (7 - α) ^ 9 + 37714860895632375 * α ^ 4 * (7 - α) ^ 8 + 91053479724275985 * α ^ 5 * (7 - α) ^ 7 + 128817765797828254 * α ^ 6 * (7 - α) ^ 6 + 133833540832996984 * α ^ 7 * (7 - α) ^ 5 + 161773229978174745 * α ^ 8 * (7 - α) ^ 4 + 197834312331965435 * α ^ 9 * (7 - α) ^ 3 + 152113356071582990 * α ^ 10 * (7 - α) ^ 2 + 57359456154000000 * α ^ 11 * (7 - α) ^ 1 + 7376986416800000 * α ^ 12 := by ring - rcases le_total α (7 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 4540012290450 * (7 - α) ^ 12 := - mul_pos (by norm_num) (pow_pos (by linarith) 12) - linarith - · have hpos : (0 : ℝ) < 7376986416800000 * α ^ 12 := - mul_pos (by norm_num) (pow_pos (by linarith) 12) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (7 : ℝ) ^ 12)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 7 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree16_18.lean b/Sendov/FiniteRange/Degree16_18.lean index 574753f..133a663 100644 --- a/Sendov/FiniteRange/Degree16_18.lean +++ b/Sendov/FiniteRange/Degree16_18.lean @@ -88,45 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17 / 2) : 0 < 308547940078125 + 716274580556250 * α + 701075142421875 * α ^ 2 + 366034929547500 * α ^ 3 + 98713082723625 * α ^ 4 - 785317395690 * α ^ 5 - 34202916258669 * α ^ 6 + 6366700041480 * α ^ 7 + 121732471512 * α ^ 8 - 9494954208 * α ^ 9 - 1551607200 * α ^ 10 - 87661568 * α ^ 11 - 2586240 * α ^ 12 - 39936 * α ^ 13 - 256 * α ^ 14 := by have hu : (0 : ℝ) ≤ 17 - 2 * α := by linarith - have h0 : (0:ℝ) ≤ 308547940078125 * (17 - 2 * α) ^ 14 := - mul_nonneg (by norm_num) (pow_nonneg hu 14) - have h1 : (0:ℝ) ≤ 20816010191643750 * α ^ 1 * (17 - 2 * α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 13) - have h2 : (0:ℝ) ≤ 631515530954221875 * α ^ 2 * (17 - 2 * α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 12) - have h3 : (0:ℝ) ≤ 11358598773482842500 * α ^ 3 * (17 - 2 * α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 11) - have h4 : (0:ℝ) ≤ 134099015737057493625 * α ^ 4 * (17 - 2 * α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 10) - have h5 : (0:ℝ) ≤ 1075072539293623306170 * α ^ 5 * (17 - 2 * α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 9) - have h6 : (0:ℝ) ≤ 5177641117293101872899 * α ^ 6 * (17 - 2 * α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 8) - have h7 : (0:ℝ) ≤ 13260545037504883513944 * α ^ 7 * (17 - 2 * α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 7) - have h8 : (0:ℝ) ≤ 13392270163441462237560 * α ^ 8 * (17 - 2 * α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 6) - have h9 : (0:ℝ) ≤ 934363054464939802080 * α ^ 9 * (17 - 2 * α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 5) - have h10 : (0:ℝ) ≤ 56141276222621229749280 * α ^ 10 * (17 - 2 * α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 4) - have h11 : (0:ℝ) ≤ 269593608305522330908544 * α ^ 11 * (17 - 2 * α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 3) - have h12 : (0:ℝ) ≤ 451523429099140347738624 * α ^ 12 * (17 - 2 * α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 2) - have h13 : (0:ℝ) ≤ 320966535936278232000000 * α ^ 13 * (17 - 2 * α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 1) - have h14 : (0:ℝ) ≤ 72913603873782672000000 * α ^ 14 := - mul_nonneg (by norm_num) (pow_nonneg hα 14) have hid : (17 : ℝ) ^ 14 * (308547940078125 + 716274580556250 * α + 701075142421875 * α ^ 2 + 366034929547500 * α ^ 3 + 98713082723625 * α ^ 4 - 785317395690 * α ^ 5 - 34202916258669 * α ^ 6 + 6366700041480 * α ^ 7 + 121732471512 * α ^ 8 - 9494954208 * α ^ 9 - 1551607200 * α ^ 10 - 87661568 * α ^ 11 - 2586240 * α ^ 12 - 39936 * α ^ 13 - 256 * α ^ 14) = 308547940078125 * (17 - 2 * α) ^ 14 + 20816010191643750 * α ^ 1 * (17 - 2 * α) ^ 13 + 631515530954221875 * α ^ 2 * (17 - 2 * α) ^ 12 + 11358598773482842500 * α ^ 3 * (17 - 2 * α) ^ 11 + 134099015737057493625 * α ^ 4 * (17 - 2 * α) ^ 10 + 1075072539293623306170 * α ^ 5 * (17 - 2 * α) ^ 9 + 5177641117293101872899 * α ^ 6 * (17 - 2 * α) ^ 8 + 13260545037504883513944 * α ^ 7 * (17 - 2 * α) ^ 7 + 13392270163441462237560 * α ^ 8 * (17 - 2 * α) ^ 6 + 934363054464939802080 * α ^ 9 * (17 - 2 * α) ^ 5 + 56141276222621229749280 * α ^ 10 * (17 - 2 * α) ^ 4 + 269593608305522330908544 * α ^ 11 * (17 - 2 * α) ^ 3 + 451523429099140347738624 * α ^ 12 * (17 - 2 * α) ^ 2 + 320966535936278232000000 * α ^ 13 * (17 - 2 * α) ^ 1 + 72913603873782672000000 * α ^ 14 := by ring - rcases le_total α (17 / (2 * 2)) with h | h - · have hpos : (0 : ℝ) < 308547940078125 * (17 - 2 * α) ^ 14 := - mul_pos (by norm_num) (pow_pos (by linarith) 14) - linarith - · have hpos : (0 : ℝ) < 72913603873782672000000 * α ^ 14 := - mul_pos (by norm_num) (pow_pos (by linarith) 14) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 14)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - 2 * α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree18_20.lean b/Sendov/FiniteRange/Degree18_20.lean index 6d02331..ecf63f3 100644 --- a/Sendov/FiniteRange/Degree18_20.lean +++ b/Sendov/FiniteRange/Degree18_20.lean @@ -88,49 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 19 / 2) : 0 < 1996938880799635773 + 5327542416376042533 * α + 6168567333266685756 * α ^ 2 + 4015726419901684032 * α ^ 3 + 1568562341575363317 * α ^ 4 + 336439630979056719 * α ^ 5 - 5059047712773960 * α ^ 6 - 94154641040290584 * α ^ 7 + 14305270642714822 * α ^ 8 + 337895936432856 * α ^ 9 - 7990669279488 * α ^ 10 - 2592154628256 * α ^ 11 - 177335477376 * α ^ 12 - 6421337472 * α ^ 13 - 134803968 * α ^ 14 - 1555968 * α ^ 15 - 7680 * α ^ 16 := by have hu : (0 : ℝ) ≤ 19 - 2 * α := by linarith - have h0 : (0:ℝ) ≤ 1996938880799635773 * (19 - 2 * α) ^ 16 := - mul_nonneg (by norm_num) (pow_nonneg hu 16) - have h1 : (0:ℝ) ≤ 165125350096733152863 * α ^ 1 * (19 - 2 * α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 15) - have h2 : (0:ℝ) ≤ 6222082647427442972766 * α ^ 2 * (19 - 2 * α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 14) - have h3 : (0:ℝ) ≤ 141355820787428498073516 * α ^ 3 * (19 - 2 * α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 13) - have h4 : (0:ℝ) ≤ 2157735283869217913370909 * α ^ 4 * (19 - 2 * α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 12) - have h5 : (0:ℝ) ≤ 23307179713209861652797525 * α ^ 5 * (19 - 2 * α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 11) - have h6 : (0:ℝ) ≤ 181491504176132704398182238 * α ^ 6 * (19 - 2 * α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 10) - have h7 : (0:ℝ) ≤ 947234591820259386271884708 * α ^ 7 * (19 - 2 * α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 9) - have h8 : (0:ℝ) ≤ 3056114849066116568052366478 * α ^ 8 * (19 - 2 * α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 8) - have h9 : (0:ℝ) ≤ 5409419472435810969555104008 * α ^ 9 * (19 - 2 * α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 7) - have h10 : (0:ℝ) ≤ 3773674627041183640344074704 * α ^ 10 * (19 - 2 * α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 6) - have h11 : (0:ℝ) ≤ 2563877062588931411214853312 * α ^ 11 * (19 - 2 * α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 5) - have h12 : (0:ℝ) ≤ 27502208508532453123433891776 * α ^ 12 * (19 - 2 * α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 4) - have h13 : (0:ℝ) ≤ 85133541744770676359382205696 * α ^ 13 * (19 - 2 * α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 3) - have h14 : (0:ℝ) ≤ 113617195875176526046213373440 * α ^ 14 * (19 - 2 * α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 2) - have h15 : (0:ℝ) ≤ 68841959775014032750000000000 * α ^ 15 * (19 - 2 * α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 1) - have h16 : (0:ℝ) ≤ 13908254927398975000000000000 * α ^ 16 := - mul_nonneg (by norm_num) (pow_nonneg hα 16) have hid : (19 : ℝ) ^ 16 * (1996938880799635773 + 5327542416376042533 * α + 6168567333266685756 * α ^ 2 + 4015726419901684032 * α ^ 3 + 1568562341575363317 * α ^ 4 + 336439630979056719 * α ^ 5 - 5059047712773960 * α ^ 6 - 94154641040290584 * α ^ 7 + 14305270642714822 * α ^ 8 + 337895936432856 * α ^ 9 - 7990669279488 * α ^ 10 - 2592154628256 * α ^ 11 - 177335477376 * α ^ 12 - 6421337472 * α ^ 13 - 134803968 * α ^ 14 - 1555968 * α ^ 15 - 7680 * α ^ 16) = 1996938880799635773 * (19 - 2 * α) ^ 16 + 165125350096733152863 * α ^ 1 * (19 - 2 * α) ^ 15 + 6222082647427442972766 * α ^ 2 * (19 - 2 * α) ^ 14 + 141355820787428498073516 * α ^ 3 * (19 - 2 * α) ^ 13 + 2157735283869217913370909 * α ^ 4 * (19 - 2 * α) ^ 12 + 23307179713209861652797525 * α ^ 5 * (19 - 2 * α) ^ 11 + 181491504176132704398182238 * α ^ 6 * (19 - 2 * α) ^ 10 + 947234591820259386271884708 * α ^ 7 * (19 - 2 * α) ^ 9 + 3056114849066116568052366478 * α ^ 8 * (19 - 2 * α) ^ 8 + 5409419472435810969555104008 * α ^ 9 * (19 - 2 * α) ^ 7 + 3773674627041183640344074704 * α ^ 10 * (19 - 2 * α) ^ 6 + 2563877062588931411214853312 * α ^ 11 * (19 - 2 * α) ^ 5 + 27502208508532453123433891776 * α ^ 12 * (19 - 2 * α) ^ 4 + 85133541744770676359382205696 * α ^ 13 * (19 - 2 * α) ^ 3 + 113617195875176526046213373440 * α ^ 14 * (19 - 2 * α) ^ 2 + 68841959775014032750000000000 * α ^ 15 * (19 - 2 * α) ^ 1 + 13908254927398975000000000000 * α ^ 16 := by ring - rcases le_total α (19 / (2 * 2)) with h | h - · have hpos : (0 : ℝ) < 1996938880799635773 * (19 - 2 * α) ^ 16 := - mul_pos (by norm_num) (pow_pos (by linarith) 16) - linarith - · have hpos : (0 : ℝ) < 13908254927398975000000000000 * α ^ 16 := - mul_pos (by norm_num) (pow_pos (by linarith) 16) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (19 : ℝ) ^ 16)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 19 - 2 * α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree20_22.lean b/Sendov/FiniteRange/Degree20_22.lean index 3379068..7c09215 100644 --- a/Sendov/FiniteRange/Degree20_22.lean +++ b/Sendov/FiniteRange/Degree20_22.lean @@ -88,53 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 21 / 2) : 0 < 721140310389707127738 + 2170180610909239016088 * α + 2889750967198268814324 * α ^ 2 + 2227128338977232972904 * α ^ 3 + 1085997068794302710391 * α ^ 4 + 339049376116278228288 * α ^ 5 + 60509700204282383346 * α ^ 6 - 1038039442012938636 * α ^ 7 - 14060791839010189905 * α ^ 8 + 1774506642858471852 * α ^ 9 + 45855210342618468 * α ^ 10 + 226538249017920 * α ^ 11 - 222291771124416 * α ^ 12 - 18538380993792 * α ^ 13 - 787852835840 * α ^ 14 - 20286313472 * α ^ 15 - 320448768 * α ^ 16 - 2874368 * α ^ 17 - 11264 * α ^ 18 := by have hu : (0 : ℝ) ≤ 21 - 2 * α := by linarith - have h0 : (0:ℝ) ≤ 721140310389707127738 * (21 - 2 * α) ^ 18 := - mul_nonneg (by norm_num) (pow_nonneg hu 18) - have h1 : (0:ℝ) ≤ 71534844003123475936416 * α ^ 1 * (21 - 2 * α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 17) - have h2 : (0:ℝ) ≤ 3265227002682133966779372 * α ^ 2 * (21 - 2 * α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 16) - have h3 : (0:ℝ) ≤ 90905348441621278719467208 * α ^ 3 * (21 - 2 * α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 15) - have h4 : (0:ℝ) ≤ 1724899809677710491069520311 * α ^ 4 * (21 - 2 * α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 14) - have h5 : (0:ℝ) ≤ 23603549699659251265167149604 * α ^ 5 * (21 - 2 * α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 13) - have h6 : (0:ℝ) ≤ 240138761499155563910895585654 * α ^ 6 * (21 - 2 * α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 12) - have h7 : (0:ℝ) ≤ 1837366344267267569709080196468 * α ^ 7 * (21 - 2 * α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 11) - have h8 : (0:ℝ) ≤ 10104702475479597929008103413095 * α ^ 8 * (21 - 2 * α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 10) - have h9 : (0:ℝ) ≤ 37641802639366180553916149163576 * α ^ 9 * (21 - 2 * α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 9) - have h10 : (0:ℝ) ≤ 88449061215859475411346373536264 * α ^ 10 * (21 - 2 * α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 8) - have h11 : (0:ℝ) ≤ 113640861426905556745222707601920 * α ^ 11 * (21 - 2 * α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 7) - have h12 : (0:ℝ) ≤ 55669273871103476657042199021792 * α ^ 12 * (21 - 2 * α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 6) - have h13 : (0:ℝ) ≤ 99281941699214882417362945572096 * α ^ 13 * (21 - 2 * α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 5) - have h14 : (0:ℝ) ≤ 654986082897929475911576119281408 * α ^ 14 * (21 - 2 * α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 4) - have h15 : (0:ℝ) ≤ 1538940561324052318678745687107584 * α ^ 15 * (21 - 2 * α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 3) - have h16 : (0:ℝ) ≤ 1719020178639381082845279983473152 * α ^ 16 * (21 - 2 * α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 2) - have h17 : (0:ℝ) ≤ 910135906460129539245476343896064 * α ^ 17 * (21 - 2 * α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 1) - have h18 : (0:ℝ) ≤ 165769381149578270034391223083008 * α ^ 18 := - mul_nonneg (by norm_num) (pow_nonneg hα 18) have hid : (21 : ℝ) ^ 18 * (721140310389707127738 + 2170180610909239016088 * α + 2889750967198268814324 * α ^ 2 + 2227128338977232972904 * α ^ 3 + 1085997068794302710391 * α ^ 4 + 339049376116278228288 * α ^ 5 + 60509700204282383346 * α ^ 6 - 1038039442012938636 * α ^ 7 - 14060791839010189905 * α ^ 8 + 1774506642858471852 * α ^ 9 + 45855210342618468 * α ^ 10 + 226538249017920 * α ^ 11 - 222291771124416 * α ^ 12 - 18538380993792 * α ^ 13 - 787852835840 * α ^ 14 - 20286313472 * α ^ 15 - 320448768 * α ^ 16 - 2874368 * α ^ 17 - 11264 * α ^ 18) = 721140310389707127738 * (21 - 2 * α) ^ 18 + 71534844003123475936416 * α ^ 1 * (21 - 2 * α) ^ 17 + 3265227002682133966779372 * α ^ 2 * (21 - 2 * α) ^ 16 + 90905348441621278719467208 * α ^ 3 * (21 - 2 * α) ^ 15 + 1724899809677710491069520311 * α ^ 4 * (21 - 2 * α) ^ 14 + 23603549699659251265167149604 * α ^ 5 * (21 - 2 * α) ^ 13 + 240138761499155563910895585654 * α ^ 6 * (21 - 2 * α) ^ 12 + 1837366344267267569709080196468 * α ^ 7 * (21 - 2 * α) ^ 11 + 10104702475479597929008103413095 * α ^ 8 * (21 - 2 * α) ^ 10 + 37641802639366180553916149163576 * α ^ 9 * (21 - 2 * α) ^ 9 + 88449061215859475411346373536264 * α ^ 10 * (21 - 2 * α) ^ 8 + 113640861426905556745222707601920 * α ^ 11 * (21 - 2 * α) ^ 7 + 55669273871103476657042199021792 * α ^ 12 * (21 - 2 * α) ^ 6 + 99281941699214882417362945572096 * α ^ 13 * (21 - 2 * α) ^ 5 + 654986082897929475911576119281408 * α ^ 14 * (21 - 2 * α) ^ 4 + 1538940561324052318678745687107584 * α ^ 15 * (21 - 2 * α) ^ 3 + 1719020178639381082845279983473152 * α ^ 16 * (21 - 2 * α) ^ 2 + 910135906460129539245476343896064 * α ^ 17 * (21 - 2 * α) ^ 1 + 165769381149578270034391223083008 * α ^ 18 := by ring - rcases le_total α (21 / (2 * 2)) with h | h - · have hpos : (0 : ℝ) < 721140310389707127738 * (21 - 2 * α) ^ 18 := - mul_pos (by norm_num) (pow_pos (by linarith) 18) - linarith - · have hpos : (0 : ℝ) < 165769381149578270034391223083008 * α ^ 18 := - mul_pos (by norm_num) (pow_pos (by linarith) 18) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (21 : ℝ) ^ 18)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 21 - 2 * α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree22_24.lean b/Sendov/FiniteRange/Degree22_24.lean index 9dea114..2a2e9ad 100644 --- a/Sendov/FiniteRange/Degree22_24.lean +++ b/Sendov/FiniteRange/Degree22_24.lean @@ -88,57 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 23 / 2) : 0 < 72676691260477709153931 + 243335498910644300539743 * α + 365647629606098581621152 * α ^ 2 + 324203560761134112575706 * α ^ 3 + 187220150267586036026391 * α ^ 4 + 72995868351568741088853 * α ^ 5 + 18997181712653091143742 * α ^ 6 + 2912276075526675669294 * α ^ 7 - 47524187765551795452 * α ^ 8 - 572344038827543054862 * α ^ 9 + 60958599043408078986 * α ^ 10 + 1608150216459380292 * α ^ 11 + 37160884428953616 * α ^ 12 - 4770728942909184 * α ^ 13 - 508194774105984 * α ^ 14 - 24843494479104 * α ^ 15 - 745526594304 * α ^ 16 - 14490071808 * α ^ 17 - 179034112 * α ^ 18 - 1285120 * α ^ 19 - 4096 * α ^ 20 := by have hu : (0 : ℝ) ≤ 23 - 2 * α := by linarith - have h0 : (0:ℝ) ≤ 72676691260477709153931 * (23 - 2 * α) ^ 20 := - mul_nonneg (by norm_num) (pow_nonneg hu 20) - have h1 : (0:ℝ) ≤ 8503784125363927278571329 * α ^ 1 * (23 - 2 * α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 19) - have h2 : (0:ℝ) ≤ 461337107467492327306312350 * α ^ 2 * (23 - 2 * α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 18) - have h3 : (0:ℝ) ≤ 15398943675157072979676921186 * α ^ 3 * (23 - 2 * α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 17) - have h4 : (0:ℝ) ≤ 353905086689575653155085657243 * α ^ 4 * (23 - 2 * α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 16) - have h5 : (0:ℝ) ≤ 5938058763785413089179396251875 * α ^ 5 * (23 - 2 * α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 15) - have h6 : (0:ℝ) ≤ 75246714147642299181739714271832 * α ^ 6 * (23 - 2 * α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 14) - have h7 : (0:ℝ) ≤ 734384442923791787182437424591542 * α ^ 7 * (23 - 2 * α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 13) - have h8 : (0:ℝ) ≤ 5562914983973677901584481691318984 * α ^ 8 * (23 - 2 * α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 12) - have h9 : (0:ℝ) ≤ 31773805113877239761694178561183806 * α ^ 9 * (23 - 2 * α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 11) - have h10 : (0:ℝ) ≤ 130856587563539007907893649077192702 * α ^ 10 * (23 - 2 * α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 10) - have h11 : (0:ℝ) ≤ 369427721563914607645637465073374604 * α ^ 11 * (23 - 2 * α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 9) - have h12 : (0:ℝ) ≤ 659851634553627022861170989844737856 * α ^ 12 * (23 - 2 * α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 8) - have h13 : (0:ℝ) ≤ 615817039503279914009940077569822464 * α ^ 13 * (23 - 2 * α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 7) - have h14 : (0:ℝ) ≤ 195270527269368587749778342774288064 * α ^ 14 * (23 - 2 * α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 6) - have h15 : (0:ℝ) ≤ 857988173853242270013037467185126784 * α ^ 15 * (23 - 2 * α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 5) - have h16 : (0:ℝ) ≤ 4220624235641254987215180793015588608 * α ^ 16 * (23 - 2 * α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 4) - have h17 : (0:ℝ) ≤ 8094967304722603824961003917794419968 * α ^ 17 * (23 - 2 * α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 3) - have h18 : (0:ℝ) ≤ 7807057971748984716263131834792835072 * α ^ 18 * (23 - 2 * α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 2) - have h19 : (0:ℝ) ≤ 3677240872883486972453388075862686720 * α ^ 19 * (23 - 2 * α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 1) - have h20 : (0:ℝ) ≤ 610286593660503076943530707277762560 * α ^ 20 := - mul_nonneg (by norm_num) (pow_nonneg hα 20) have hid : (23 : ℝ) ^ 20 * (72676691260477709153931 + 243335498910644300539743 * α + 365647629606098581621152 * α ^ 2 + 324203560761134112575706 * α ^ 3 + 187220150267586036026391 * α ^ 4 + 72995868351568741088853 * α ^ 5 + 18997181712653091143742 * α ^ 6 + 2912276075526675669294 * α ^ 7 - 47524187765551795452 * α ^ 8 - 572344038827543054862 * α ^ 9 + 60958599043408078986 * α ^ 10 + 1608150216459380292 * α ^ 11 + 37160884428953616 * α ^ 12 - 4770728942909184 * α ^ 13 - 508194774105984 * α ^ 14 - 24843494479104 * α ^ 15 - 745526594304 * α ^ 16 - 14490071808 * α ^ 17 - 179034112 * α ^ 18 - 1285120 * α ^ 19 - 4096 * α ^ 20) = 72676691260477709153931 * (23 - 2 * α) ^ 20 + 8503784125363927278571329 * α ^ 1 * (23 - 2 * α) ^ 19 + 461337107467492327306312350 * α ^ 2 * (23 - 2 * α) ^ 18 + 15398943675157072979676921186 * α ^ 3 * (23 - 2 * α) ^ 17 + 353905086689575653155085657243 * α ^ 4 * (23 - 2 * α) ^ 16 + 5938058763785413089179396251875 * α ^ 5 * (23 - 2 * α) ^ 15 + 75246714147642299181739714271832 * α ^ 6 * (23 - 2 * α) ^ 14 + 734384442923791787182437424591542 * α ^ 7 * (23 - 2 * α) ^ 13 + 5562914983973677901584481691318984 * α ^ 8 * (23 - 2 * α) ^ 12 + 31773805113877239761694178561183806 * α ^ 9 * (23 - 2 * α) ^ 11 + 130856587563539007907893649077192702 * α ^ 10 * (23 - 2 * α) ^ 10 + 369427721563914607645637465073374604 * α ^ 11 * (23 - 2 * α) ^ 9 + 659851634553627022861170989844737856 * α ^ 12 * (23 - 2 * α) ^ 8 + 615817039503279914009940077569822464 * α ^ 13 * (23 - 2 * α) ^ 7 + 195270527269368587749778342774288064 * α ^ 14 * (23 - 2 * α) ^ 6 + 857988173853242270013037467185126784 * α ^ 15 * (23 - 2 * α) ^ 5 + 4220624235641254987215180793015588608 * α ^ 16 * (23 - 2 * α) ^ 4 + 8094967304722603824961003917794419968 * α ^ 17 * (23 - 2 * α) ^ 3 + 7807057971748984716263131834792835072 * α ^ 18 * (23 - 2 * α) ^ 2 + 3677240872883486972453388075862686720 * α ^ 19 * (23 - 2 * α) ^ 1 + 610286593660503076943530707277762560 * α ^ 20 := by ring - rcases le_total α (23 / (2 * 2)) with h | h - · have hpos : (0 : ℝ) < 72676691260477709153931 * (23 - 2 * α) ^ 20 := - mul_pos (by norm_num) (pow_pos (by linarith) 20) - linarith - · have hpos : (0 : ℝ) < 610286593660503076943530707277762560 * α ^ 20 := - mul_pos (by norm_num) (pow_pos (by linarith) 20) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (23 : ℝ) ^ 20)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 23 - 2 * α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree24_26.lean b/Sendov/FiniteRange/Degree24_26.lean index be8f376..99b1625 100644 --- a/Sendov/FiniteRange/Degree24_26.lean +++ b/Sendov/FiniteRange/Degree24_26.lean @@ -88,61 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 25 / 2) : 0 < 874071004010582953643568750 + 3221297610086019399669004500 * α + 5386914463346812349691460974 * α ^ 2 + 5391225879978445091101054368 * α ^ 3 + 3582299145670361769507272658 * α ^ 4 + 1654127651781089540379647100 * α ^ 5 + 537462463626302644652842710 * α ^ 6 + 120043033655516749475390448 * α ^ 7 + 16184849120135434020794931 * α ^ 8 - 222784389930881498880726 * α ^ 9 - 2725770297915674501126913 * α ^ 10 + 248640476833385673099320 * α ^ 11 + 6386094327528944247792 * α ^ 12 + 230085309479261626272 * α ^ 13 - 10099884196228450032 * α ^ 14 - 1569527054513950464 * α ^ 15 - 87896838917715456 * α ^ 16 - 2989402709094912 * α ^ 17 - 67703370254592 * α ^ 18 - 1033617561600 * α ^ 19 - 10281172992 * α ^ 20 - 60432384 * α ^ 21 - 159744 * α ^ 22 := by have hu : (0 : ℝ) ≤ 25 - 2 * α := by linarith - have h0 : (0:ℝ) ≤ 874071004010582953643568750 * (25 - 2 * α) ^ 22 := - mul_nonneg (by norm_num) (pow_nonneg hu 22) - have h1 : (0:ℝ) ≤ 118991564428616134952042137500 * α ^ 1 * (25 - 2 * α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 21) - have h2 : (0:ℝ) ≤ 7556825637887856737376275358750 * α ^ 2 * (25 - 2 * α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 20) - have h3 : (0:ℝ) ≤ 297326570539550302672678360350000 * α ^ 3 * (25 - 2 * α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 19) - have h4 : (0:ℝ) ≤ 8118326774696702494364871859181250 * α ^ 4 * (25 - 2 * α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 18) - have h5 : (0:ℝ) ≤ 163302166743534227801697447509662500 * α ^ 5 * (25 - 2 * α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 17) - have h6 : (0:ℝ) ≤ 2507454163520304052153861436880993750 * α ^ 6 * (25 - 2 * α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 16) - have h7 : (0:ℝ) ≤ 30047259752690844282111594563558670000 * α ^ 7 * (25 - 2 * α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 15) - have h8 : (0:ℝ) ≤ 284787676890052141286070572033915521875 * α ^ 8 * (25 - 2 * α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 14) - have h9 : (0:ℝ) ≤ 2146769361227978442422195176181338368750 * α ^ 9 * (25 - 2 * α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 13) - have h10 : (0:ℝ) ≤ 12630679896438305929175193655858187184375 * α ^ 10 * (25 - 2 * α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 12) - have h11 : (0:ℝ) ≤ 56067735566028501096437207497525020350000 * α ^ 11 * (25 - 2 * α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 11) - have h12 : (0:ℝ) ≤ 180631480948809558078622444236010586285000 * α ^ 12 * (25 - 2 * α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 10) - have h13 : (0:ℝ) ≤ 400779538225462244119560623305257108200000 * α ^ 13 * (25 - 2 * α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 9) - have h14 : (0:ℝ) ≤ 552145957044674175745646853887912448300000 * α ^ 14 * (25 - 2 * α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 8) - have h15 : (0:ℝ) ≤ 348851941562555217823842842079415684800000 * α ^ 15 * (25 - 2 * α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 7) - have h16 : (0:ℝ) ≤ 38623525300380552283361811907759716000000 * α ^ 16 * (25 - 2 * α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 6) - have h17 : (0:ℝ) ≤ 822237191651812497627267691867773310080000 * α ^ 17 * (25 - 2 * α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 5) - have h18 : (0:ℝ) ≤ 3269244329154715153428677298597459316800000 * α ^ 18 * (25 - 2 * α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 4) - have h19 : (0:ℝ) ≤ 5333912969812883272270527401813990707200000 * α ^ 19 * (25 - 2 * α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 3) - have h20 : (0:ℝ) ≤ 4537960847197188659144322307990683712000000 * α ^ 20 * (25 - 2 * α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 2) - have h21 : (0:ℝ) ≤ 1927546466544754214336332480358954905600000 * α ^ 21 * (25 - 2 * α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 1) - have h22 : (0:ℝ) ≤ 294013599962108674661431900766763888640000 * α ^ 22 := - mul_nonneg (by norm_num) (pow_nonneg hα 22) have hid : (25 : ℝ) ^ 22 * (874071004010582953643568750 + 3221297610086019399669004500 * α + 5386914463346812349691460974 * α ^ 2 + 5391225879978445091101054368 * α ^ 3 + 3582299145670361769507272658 * α ^ 4 + 1654127651781089540379647100 * α ^ 5 + 537462463626302644652842710 * α ^ 6 + 120043033655516749475390448 * α ^ 7 + 16184849120135434020794931 * α ^ 8 - 222784389930881498880726 * α ^ 9 - 2725770297915674501126913 * α ^ 10 + 248640476833385673099320 * α ^ 11 + 6386094327528944247792 * α ^ 12 + 230085309479261626272 * α ^ 13 - 10099884196228450032 * α ^ 14 - 1569527054513950464 * α ^ 15 - 87896838917715456 * α ^ 16 - 2989402709094912 * α ^ 17 - 67703370254592 * α ^ 18 - 1033617561600 * α ^ 19 - 10281172992 * α ^ 20 - 60432384 * α ^ 21 - 159744 * α ^ 22) = 874071004010582953643568750 * (25 - 2 * α) ^ 22 + 118991564428616134952042137500 * α ^ 1 * (25 - 2 * α) ^ 21 + 7556825637887856737376275358750 * α ^ 2 * (25 - 2 * α) ^ 20 + 297326570539550302672678360350000 * α ^ 3 * (25 - 2 * α) ^ 19 + 8118326774696702494364871859181250 * α ^ 4 * (25 - 2 * α) ^ 18 + 163302166743534227801697447509662500 * α ^ 5 * (25 - 2 * α) ^ 17 + 2507454163520304052153861436880993750 * α ^ 6 * (25 - 2 * α) ^ 16 + 30047259752690844282111594563558670000 * α ^ 7 * (25 - 2 * α) ^ 15 + 284787676890052141286070572033915521875 * α ^ 8 * (25 - 2 * α) ^ 14 + 2146769361227978442422195176181338368750 * α ^ 9 * (25 - 2 * α) ^ 13 + 12630679896438305929175193655858187184375 * α ^ 10 * (25 - 2 * α) ^ 12 + 56067735566028501096437207497525020350000 * α ^ 11 * (25 - 2 * α) ^ 11 + 180631480948809558078622444236010586285000 * α ^ 12 * (25 - 2 * α) ^ 10 + 400779538225462244119560623305257108200000 * α ^ 13 * (25 - 2 * α) ^ 9 + 552145957044674175745646853887912448300000 * α ^ 14 * (25 - 2 * α) ^ 8 + 348851941562555217823842842079415684800000 * α ^ 15 * (25 - 2 * α) ^ 7 + 38623525300380552283361811907759716000000 * α ^ 16 * (25 - 2 * α) ^ 6 + 822237191651812497627267691867773310080000 * α ^ 17 * (25 - 2 * α) ^ 5 + 3269244329154715153428677298597459316800000 * α ^ 18 * (25 - 2 * α) ^ 4 + 5333912969812883272270527401813990707200000 * α ^ 19 * (25 - 2 * α) ^ 3 + 4537960847197188659144322307990683712000000 * α ^ 20 * (25 - 2 * α) ^ 2 + 1927546466544754214336332480358954905600000 * α ^ 21 * (25 - 2 * α) ^ 1 + 294013599962108674661431900766763888640000 * α ^ 22 := by ring - rcases le_total α (25 / (2 * 2)) with h | h - · have hpos : (0 : ℝ) < 874071004010582953643568750 * (25 - 2 * α) ^ 22 := - mul_pos (by norm_num) (pow_pos (by linarith) 22) - linarith - · have hpos : (0 : ℝ) < 294013599962108674661431900766763888640000 * α ^ 22 := - mul_pos (by norm_num) (pow_pos (by linarith) 22) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (25 : ℝ) ^ 22)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 25 - 2 * α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree26_27.lean b/Sendov/FiniteRange/Degree26_27.lean index 7004d58..240f9fc 100644 --- a/Sendov/FiniteRange/Degree26_27.lean +++ b/Sendov/FiniteRange/Degree26_27.lean @@ -88,65 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 13) : 0 < 750669183453805732727050781250 + 3020533706655215263366699218750 * α + 5564839729610338783264160156250 * α ^ 2 + 6204652935907732786560058593750 * α ^ 3 + 4659850847351595430480957031250 * α ^ 4 + 2480313988118708551463378906250 * α ^ 5 + 956953438533800725637460937500 * α ^ 6 + 267988469385291406396875000000 * α ^ 7 + 53061280626889862612388984375 * α ^ 8 + 6649776660279075672227540625 * α ^ 9 + 67029306131497703210255025 * α ^ 10 - 797547671168471728584421521 * α ^ 11 + 69793209950586805764791132 * α ^ 12 + 1582701213221515173844854 * α ^ 13 + 64909025019891545058702 * α ^ 14 - 1621590589357829572680 * α ^ 15 - 347824272218530328424 * α ^ 16 - 21365270620680629952 * α ^ 17 - 794207858493279744 * α ^ 18 - 20077534583212032 * α ^ 19 - 355351304655360 * α ^ 20 - 4364532094464 * α ^ 21 - 35609836032 * α ^ 22 - 174127104 * α ^ 23 - 387072 * α ^ 24 := by have hu : (0 : ℝ) ≤ 13 - α := by linarith - have h0 : (0:ℝ) ≤ 750669183453805732727050781250 * (13 - α) ^ 24 := - mul_nonneg (by norm_num) (pow_nonneg hu 24) - have h1 : (0:ℝ) ≤ 57282998589409136009216308593750 * α ^ 1 * (13 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 23) - have h2 : (0:ℝ) ≤ 2050782187227307000350952148437500 * α ^ 2 * (13 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 22) - have h3 : (0:ℝ) ≤ 45775586403380034332501220703125000 * α ^ 3 * (13 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 21) - have h4 : (0:ℝ) ≤ 714118209031145161147786743164062500 * α ^ 4 * (13 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 20) - have h5 : (0:ℝ) ≤ 8273284316298011107371657322265625000 * α ^ 5 * (13 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 19) - have h6 : (0:ℝ) ≤ 73835510530487101104526833122402343750 * α ^ 6 * (13 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 18) - have h7 : (0:ℝ) ≤ 519733885027019750587474273435957031250 * α ^ 7 * (13 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 17) - have h8 : (0:ℝ) ≤ 2930800059791589030908400058323199921875 * α ^ 8 * (13 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 16) - have h9 : (0:ℝ) ≤ 13372402464675670629912241174388163590625 * α ^ 9 * (13 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 15) - have h10 : (0:ℝ) ≤ 49616523603298906478895841666067082338100 * α ^ 10 * (13 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 14) - have h11 : (0:ℝ) ≤ 148533037390768639293168587946346173784998 * α ^ 11 * (13 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 13) - have h12 : (0:ℝ) ≤ 352390650499030404141412366217263718435741 * α ^ 12 * (13 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 12) - have h13 : (0:ℝ) ≤ 649782112359758546338767005837625709617885 * α ^ 13 * (13 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 11) - have h14 : (0:ℝ) ≤ 915968039619170700348192462171799252793910 * α ^ 14 * (13 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 10) - have h15 : (0:ℝ) ≤ 976506256524831093733472748853893192499190 * α ^ 15 * (13 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 9) - have h16 : (0:ℝ) ≤ 793928461670457408996135461409947476637907 * α ^ 16 * (13 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 8) - have h17 : (0:ℝ) ≤ 532094243038671655145113443710174863949229 * α ^ 17 * (13 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 7) - have h18 : (0:ℝ) ≤ 362157082250568977592235276631536616142420 * α ^ 18 * (13 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 6) - have h19 : (0:ℝ) ≤ 282315964683600802659165217851025305107370 * α ^ 19 * (13 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 5) - have h20 : (0:ℝ) ≤ 202899768509895477280344720514446057053655 * α ^ 20 * (13 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 4) - have h21 : (0:ℝ) ≤ 106150121400148174823355428864276604237047 * α ^ 21 * (13 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 3) - have h22 : (0:ℝ) ≤ 35288625801200476947393636186470118639744 * α ^ 22 * (13 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 2) - have h23 : (0:ℝ) ≤ 6423617838051124838400000000000000000000 * α ^ 23 * (13 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 1) - have h24 : (0:ℝ) ≤ 451304798929131929600000000000000000000 * α ^ 24 := - mul_nonneg (by norm_num) (pow_nonneg hα 24) have hid : (13 : ℝ) ^ 24 * (750669183453805732727050781250 + 3020533706655215263366699218750 * α + 5564839729610338783264160156250 * α ^ 2 + 6204652935907732786560058593750 * α ^ 3 + 4659850847351595430480957031250 * α ^ 4 + 2480313988118708551463378906250 * α ^ 5 + 956953438533800725637460937500 * α ^ 6 + 267988469385291406396875000000 * α ^ 7 + 53061280626889862612388984375 * α ^ 8 + 6649776660279075672227540625 * α ^ 9 + 67029306131497703210255025 * α ^ 10 - 797547671168471728584421521 * α ^ 11 + 69793209950586805764791132 * α ^ 12 + 1582701213221515173844854 * α ^ 13 + 64909025019891545058702 * α ^ 14 - 1621590589357829572680 * α ^ 15 - 347824272218530328424 * α ^ 16 - 21365270620680629952 * α ^ 17 - 794207858493279744 * α ^ 18 - 20077534583212032 * α ^ 19 - 355351304655360 * α ^ 20 - 4364532094464 * α ^ 21 - 35609836032 * α ^ 22 - 174127104 * α ^ 23 - 387072 * α ^ 24) = 750669183453805732727050781250 * (13 - α) ^ 24 + 57282998589409136009216308593750 * α ^ 1 * (13 - α) ^ 23 + 2050782187227307000350952148437500 * α ^ 2 * (13 - α) ^ 22 + 45775586403380034332501220703125000 * α ^ 3 * (13 - α) ^ 21 + 714118209031145161147786743164062500 * α ^ 4 * (13 - α) ^ 20 + 8273284316298011107371657322265625000 * α ^ 5 * (13 - α) ^ 19 + 73835510530487101104526833122402343750 * α ^ 6 * (13 - α) ^ 18 + 519733885027019750587474273435957031250 * α ^ 7 * (13 - α) ^ 17 + 2930800059791589030908400058323199921875 * α ^ 8 * (13 - α) ^ 16 + 13372402464675670629912241174388163590625 * α ^ 9 * (13 - α) ^ 15 + 49616523603298906478895841666067082338100 * α ^ 10 * (13 - α) ^ 14 + 148533037390768639293168587946346173784998 * α ^ 11 * (13 - α) ^ 13 + 352390650499030404141412366217263718435741 * α ^ 12 * (13 - α) ^ 12 + 649782112359758546338767005837625709617885 * α ^ 13 * (13 - α) ^ 11 + 915968039619170700348192462171799252793910 * α ^ 14 * (13 - α) ^ 10 + 976506256524831093733472748853893192499190 * α ^ 15 * (13 - α) ^ 9 + 793928461670457408996135461409947476637907 * α ^ 16 * (13 - α) ^ 8 + 532094243038671655145113443710174863949229 * α ^ 17 * (13 - α) ^ 7 + 362157082250568977592235276631536616142420 * α ^ 18 * (13 - α) ^ 6 + 282315964683600802659165217851025305107370 * α ^ 19 * (13 - α) ^ 5 + 202899768509895477280344720514446057053655 * α ^ 20 * (13 - α) ^ 4 + 106150121400148174823355428864276604237047 * α ^ 21 * (13 - α) ^ 3 + 35288625801200476947393636186470118639744 * α ^ 22 * (13 - α) ^ 2 + 6423617838051124838400000000000000000000 * α ^ 23 * (13 - α) ^ 1 + 451304798929131929600000000000000000000 * α ^ 24 := by ring - rcases le_total α (13 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 750669183453805732727050781250 * (13 - α) ^ 24 := - mul_pos (by norm_num) (pow_pos (by linarith) 24) - linarith - · have hpos : (0 : ℝ) < 451304798929131929600000000000000000000 * α ^ 24 := - mul_pos (by norm_num) (pow_pos (by linarith) 24) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (13 : ℝ) ^ 24)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 13 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree28_29.lean b/Sendov/FiniteRange/Degree28_29.lean index b4f2662..de10911 100644 --- a/Sendov/FiniteRange/Degree28_29.lean +++ b/Sendov/FiniteRange/Degree28_29.lean @@ -88,69 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 14) : 0 < 426450318135882438427115499581616 + 1858834576882378710373815569972592 * α + 3736799374885893548337894566091516 * α ^ 2 + 4586209917810757974592827719731488 * α ^ 3 + 3832530771213891318426391118558376 * α ^ 4 + 2301315780911216714788724083158840 * α ^ 5 + 1020320104787175718704940125987654 * α ^ 6 + 337351267574328588560584527446352 * α ^ 7 + 82684042360278469454015755593696 * α ^ 8 + 14571761439373687941870063150072 * α ^ 9 + 1651893249078514632421437650658 * α ^ 10 + 16915365961758038105007429024 * α ^ 11 - 175858786927760049854457800868 * α ^ 12 + 13481653528168191298544554836 * α ^ 13 + 281552860237833486968732937 * α ^ 14 + 14047072236623243173813992 * α ^ 15 - 9139934377157415820848 * α ^ 16 - 45943869853012600689984 * α ^ 17 - 3291728447735177292432 * α ^ 18 - 135117714229500881664 * α ^ 19 - 3776901841060823808 * α ^ 20 - 75424649382531072 * α ^ 21 - 1084454315870976 * α ^ 22 - 11022972807168 * α ^ 23 - 75437817856 * α ^ 24 - 312639488 * α ^ 25 - 593920 * α ^ 26 := by have hu : (0 : ℝ) ≤ 14 - α := by linarith - have h0 : (0:ℝ) ≤ 426450318135882438427115499581616 * (14 - α) ^ 26 := - mul_nonneg (by norm_num) (pow_nonneg hu 26) - have h1 : (0:ℝ) ≤ 37111392347886245344338420968738304 * α ^ 1 * (14 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 25) - have h2 : (0:ℝ) ≤ 1521601132780629476593875321808369536 * α ^ 2 * (14 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 24) - have h3 : (0:ℝ) ≤ 39078340323995248057144700994634782336 * α ^ 3 * (14 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 23) - have h4 : (0:ℝ) ≤ 705051187055396740500579766777381514208 * α ^ 4 * (14 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 22) - have h5 : (0:ℝ) ≤ 9500322353274936154789534542408692441472 * α ^ 5 * (14 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 21) - have h6 : (0:ℝ) ≤ 99235235865063211599523391118038843304768 * α ^ 6 * (14 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 20) - have h7 : (0:ℝ) ≤ 823320752785879259967748712211136296143232 * α ^ 7 * (14 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 19) - have h8 : (0:ℝ) ≤ 5515721851061510718162550472414882027285712 * α ^ 8 * (14 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 18) - have h9 : (0:ℝ) ≤ 30174754728220837604457187088268784920537216 * α ^ 9 * (14 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 17) - have h10 : (0:ℝ) ≤ 135797159637259310387481461578932353970581952 * α ^ 10 * (14 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 16) - have h11 : (0:ℝ) ≤ 504664886820509810760132037456041458875523328 * α ^ 11 * (14 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 15) - have h12 : (0:ℝ) ≤ 1540639091909534601865038875378381140958117952 * α ^ 12 * (14 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 14) - have h13 : (0:ℝ) ≤ 3809796887220625879921007425681056060029021952 * α ^ 13 * (14 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 13) - have h14 : (0:ℝ) ≤ 7501791404136392824573180146400956404327039616 * α ^ 14 * (14 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 12) - have h15 : (0:ℝ) ≤ 11572714929523078093880359132036853394473485056 * α ^ 15 * (14 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 11) - have h16 : (0:ℝ) ≤ 13789723758378925038095275082223262786347860304 * α ^ 16 * (14 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 10) - have h17 : (0:ℝ) ≤ 12582251901524132212672360901736009892398456576 * α ^ 17 * (14 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 9) - have h18 : (0:ℝ) ≤ 8935758721652166554311189913325631720840187136 * α ^ 18 * (14 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 8) - have h19 : (0:ℝ) ≤ 5484179813557289010393355638182801357129728128 * α ^ 19 * (14 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 7) - have h20 : (0:ℝ) ≤ 3657829613491729305512570847707150262111504864 * α ^ 20 * (14 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 6) - have h21 : (0:ℝ) ≤ 2783234625894929033925209345455919590486513536 * α ^ 21 * (14 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 5) - have h22 : (0:ℝ) ≤ 1864845683118524255504101199017909275287974464 * α ^ 22 * (14 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 4) - have h23 : (0:ℝ) ≤ 893973882849468086668452977297233134024522624 * α ^ 23 * (14 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 3) - have h24 : (0:ℝ) ≤ 272658852549522790950799560990477918176209712 * α ^ 24 * (14 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 2) - have h25 : (0:ℝ) ≤ 45835418967464600203531300713422486095708800 * α ^ 25 * (14 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 1) - have h26 : (0:ℝ) ≤ 3000012367952955673085245642674753894705600 * α ^ 26 := - mul_nonneg (by norm_num) (pow_nonneg hα 26) have hid : (14 : ℝ) ^ 26 * (426450318135882438427115499581616 + 1858834576882378710373815569972592 * α + 3736799374885893548337894566091516 * α ^ 2 + 4586209917810757974592827719731488 * α ^ 3 + 3832530771213891318426391118558376 * α ^ 4 + 2301315780911216714788724083158840 * α ^ 5 + 1020320104787175718704940125987654 * α ^ 6 + 337351267574328588560584527446352 * α ^ 7 + 82684042360278469454015755593696 * α ^ 8 + 14571761439373687941870063150072 * α ^ 9 + 1651893249078514632421437650658 * α ^ 10 + 16915365961758038105007429024 * α ^ 11 - 175858786927760049854457800868 * α ^ 12 + 13481653528168191298544554836 * α ^ 13 + 281552860237833486968732937 * α ^ 14 + 14047072236623243173813992 * α ^ 15 - 9139934377157415820848 * α ^ 16 - 45943869853012600689984 * α ^ 17 - 3291728447735177292432 * α ^ 18 - 135117714229500881664 * α ^ 19 - 3776901841060823808 * α ^ 20 - 75424649382531072 * α ^ 21 - 1084454315870976 * α ^ 22 - 11022972807168 * α ^ 23 - 75437817856 * α ^ 24 - 312639488 * α ^ 25 - 593920 * α ^ 26) = 426450318135882438427115499581616 * (14 - α) ^ 26 + 37111392347886245344338420968738304 * α ^ 1 * (14 - α) ^ 25 + 1521601132780629476593875321808369536 * α ^ 2 * (14 - α) ^ 24 + 39078340323995248057144700994634782336 * α ^ 3 * (14 - α) ^ 23 + 705051187055396740500579766777381514208 * α ^ 4 * (14 - α) ^ 22 + 9500322353274936154789534542408692441472 * α ^ 5 * (14 - α) ^ 21 + 99235235865063211599523391118038843304768 * α ^ 6 * (14 - α) ^ 20 + 823320752785879259967748712211136296143232 * α ^ 7 * (14 - α) ^ 19 + 5515721851061510718162550472414882027285712 * α ^ 8 * (14 - α) ^ 18 + 30174754728220837604457187088268784920537216 * α ^ 9 * (14 - α) ^ 17 + 135797159637259310387481461578932353970581952 * α ^ 10 * (14 - α) ^ 16 + 504664886820509810760132037456041458875523328 * α ^ 11 * (14 - α) ^ 15 + 1540639091909534601865038875378381140958117952 * α ^ 12 * (14 - α) ^ 14 + 3809796887220625879921007425681056060029021952 * α ^ 13 * (14 - α) ^ 13 + 7501791404136392824573180146400956404327039616 * α ^ 14 * (14 - α) ^ 12 + 11572714929523078093880359132036853394473485056 * α ^ 15 * (14 - α) ^ 11 + 13789723758378925038095275082223262786347860304 * α ^ 16 * (14 - α) ^ 10 + 12582251901524132212672360901736009892398456576 * α ^ 17 * (14 - α) ^ 9 + 8935758721652166554311189913325631720840187136 * α ^ 18 * (14 - α) ^ 8 + 5484179813557289010393355638182801357129728128 * α ^ 19 * (14 - α) ^ 7 + 3657829613491729305512570847707150262111504864 * α ^ 20 * (14 - α) ^ 6 + 2783234625894929033925209345455919590486513536 * α ^ 21 * (14 - α) ^ 5 + 1864845683118524255504101199017909275287974464 * α ^ 22 * (14 - α) ^ 4 + 893973882849468086668452977297233134024522624 * α ^ 23 * (14 - α) ^ 3 + 272658852549522790950799560990477918176209712 * α ^ 24 * (14 - α) ^ 2 + 45835418967464600203531300713422486095708800 * α ^ 25 * (14 - α) ^ 1 + 3000012367952955673085245642674753894705600 * α ^ 26 := by ring - rcases le_total α (14 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 426450318135882438427115499581616 * (14 - α) ^ 26 := - mul_pos (by norm_num) (pow_pos (by linarith) 26) - linarith - · have hpos : (0 : ℝ) < 3000012367952955673085245642674753894705600 * α ^ 26 := - mul_pos (by norm_num) (pow_pos (by linarith) 26) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (14 : ℝ) ^ 26)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 14 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree30_31.lean b/Sendov/FiniteRange/Degree30_31.lean index bc9875e..8ed1f00 100644 --- a/Sendov/FiniteRange/Degree30_31.lean +++ b/Sendov/FiniteRange/Degree30_31.lean @@ -88,73 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 15) : 0 < 586577450963685326737168897370707500 + 2753132994648490979146101875384719500 * α + 5996201651556610186353013706234776680 * α ^ 2 + 8030975436338556704707041798612128472 * α ^ 3 + 7388055615126493367424454764006350082 * α ^ 4 + 4936598337528514606768767094265091378 * α ^ 5 + 2469192037754886771172170203022293214 * α ^ 6 + 938102920031818441360780570553215590 * α ^ 7 + 271392183919032658980825616039479546 * α ^ 8 + 59155996945930238392567631443933866 * α ^ 9 + 9399459563896087929210688264754844 * α ^ 10 + 974977535533292148502665510758532 * α ^ 11 + 10861549420545366403779627757839 * α ^ 12 - 92622867478166716461279291384369 * α ^ 13 + 6300099969105231240951104525763 * α ^ 14 + 117642575887863777951373952647 * α ^ 15 + 6754895556059983986318667916 * α ^ 16 + 94553344499679709104836184 * α ^ 17 - 13437772607038842242965408 * α ^ 18 - 1178131104153353973775376 * α ^ 19 - 53368378574787271805184 * α ^ 20 - 1629770789867125896192 * α ^ 21 - 35941441812526263552 * α ^ 22 - 584181453145681152 * α ^ 23 - 6973783723783168 * α ^ 24 - 59692780623872 * α ^ 25 - 347727077376 * α ^ 26 - 1237127168 * α ^ 27 - 2031616 * α ^ 28 := by have hu : (0 : ℝ) ≤ 15 - α := by linarith - have h0 : (0:ℝ) ≤ 586577450963685326737168897370707500 * (15 - α) ^ 28 := - mul_nonneg (by norm_num) (pow_nonneg hu 28) - have h1 : (0:ℝ) ≤ 57721163546710553835832257257150602500 * α ^ 1 * (15 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 27) - have h2 : (0:ℝ) ≤ 2685890510897149191990249186639763585500 * α ^ 2 * (15 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 26) - have h3 : (0:ℝ) ≤ 78599194705430136604146587933476363108500 * α ^ 3 * (15 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 25) - have h4 : (0:ℝ) ≤ 1622909997175605567337562554410307661576250 * α ^ 4 * (15 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 24) - have h5 : (0:ℝ) ≤ 25146768623114737087640078167646014091973750 * α ^ 5 * (15 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 23) - have h6 : (0:ℝ) ≤ 303641086695050391528892238082119715503670000 * α ^ 6 * (15 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 22) - have h7 : (0:ℝ) ≤ 2929031512855517774498282614444762020783307500 * α ^ 7 * (15 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 21) - have h8 : (0:ℝ) ≤ 22961042451753622392989015501956773126769350000 * α ^ 8 * (15 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 20) - have h9 : (0:ℝ) ≤ 148033957973212624082175754920221815579937805000 * α ^ 9 * (15 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 19) - have h10 : (0:ℝ) ≤ 791520488598836900068848830160917234498844101250 * α ^ 10 * (15 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 18) - have h11 : (0:ℝ) ≤ 3529526175327511018680726743043836767850893061250 * α ^ 11 * (15 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 17) - have h12 : (0:ℝ) ≤ 13165011207751367740633403433981725749824494296875 * α ^ 12 * (15 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 16) - have h13 : (0:ℝ) ≤ 40931653416291075198328442361012806391694992643125 * α ^ 13 * (15 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 15) - have h14 : (0:ℝ) ≤ 104936099346045749439240355737362583910582002551250 * α ^ 14 * (15 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 14) - have h15 : (0:ℝ) ≤ 218605526114400884612386873561624396579818747067500 * α ^ 15 * (15 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 13) - have h16 : (0:ℝ) ≤ 364544768185120783615020401898669737526038946860625 * α ^ 16 * (15 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 12) - have h17 : (0:ℝ) ≤ 479686011445303946308298171035582326066907836556875 * α ^ 17 * (15 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 11) - have h18 : (0:ℝ) ≤ 491421915359135714614282850386451786914114000492500 * α ^ 18 * (15 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 10) - have h19 : (0:ℝ) ≤ 389161288470744666432388567554714822581024179398750 * α ^ 19 * (15 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 9) - have h20 : (0:ℝ) ≤ 244558897556532361649184200629954946613489703141875 * α ^ 20 * (15 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 8) - have h21 : (0:ℝ) ≤ 139992773266086273600697845417718983669371612533125 * α ^ 21 * (15 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 7) - have h22 : (0:ℝ) ≤ 93042859490049901489480348991956175393389715291250 * α ^ 22 * (15 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 6) - have h23 : (0:ℝ) ≤ 69299238884896976481539054996360074995454890772500 * α ^ 23 * (15 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 5) - have h24 : (0:ℝ) ≤ 43491785146541891064576495824222890234435540966875 * α ^ 24 * (15 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 4) - have h25 : (0:ℝ) ≤ 19249688128515085853018716648633058220873114065625 * α ^ 25 * (15 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 3) - have h26 : (0:ℝ) ≤ 5426365264657811094720994999869461719092174416250 * α ^ 26 * (15 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 2) - have h27 : (0:ℝ) ≤ 847744461331358174965504508366152817665302528000 * α ^ 27 * (15 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 1) - have h28 : (0:ℝ) ≤ 51950222508646395464079311308157550857404416000 * α ^ 28 := - mul_nonneg (by norm_num) (pow_nonneg hα 28) have hid : (15 : ℝ) ^ 28 * (586577450963685326737168897370707500 + 2753132994648490979146101875384719500 * α + 5996201651556610186353013706234776680 * α ^ 2 + 8030975436338556704707041798612128472 * α ^ 3 + 7388055615126493367424454764006350082 * α ^ 4 + 4936598337528514606768767094265091378 * α ^ 5 + 2469192037754886771172170203022293214 * α ^ 6 + 938102920031818441360780570553215590 * α ^ 7 + 271392183919032658980825616039479546 * α ^ 8 + 59155996945930238392567631443933866 * α ^ 9 + 9399459563896087929210688264754844 * α ^ 10 + 974977535533292148502665510758532 * α ^ 11 + 10861549420545366403779627757839 * α ^ 12 - 92622867478166716461279291384369 * α ^ 13 + 6300099969105231240951104525763 * α ^ 14 + 117642575887863777951373952647 * α ^ 15 + 6754895556059983986318667916 * α ^ 16 + 94553344499679709104836184 * α ^ 17 - 13437772607038842242965408 * α ^ 18 - 1178131104153353973775376 * α ^ 19 - 53368378574787271805184 * α ^ 20 - 1629770789867125896192 * α ^ 21 - 35941441812526263552 * α ^ 22 - 584181453145681152 * α ^ 23 - 6973783723783168 * α ^ 24 - 59692780623872 * α ^ 25 - 347727077376 * α ^ 26 - 1237127168 * α ^ 27 - 2031616 * α ^ 28) = 586577450963685326737168897370707500 * (15 - α) ^ 28 + 57721163546710553835832257257150602500 * α ^ 1 * (15 - α) ^ 27 + 2685890510897149191990249186639763585500 * α ^ 2 * (15 - α) ^ 26 + 78599194705430136604146587933476363108500 * α ^ 3 * (15 - α) ^ 25 + 1622909997175605567337562554410307661576250 * α ^ 4 * (15 - α) ^ 24 + 25146768623114737087640078167646014091973750 * α ^ 5 * (15 - α) ^ 23 + 303641086695050391528892238082119715503670000 * α ^ 6 * (15 - α) ^ 22 + 2929031512855517774498282614444762020783307500 * α ^ 7 * (15 - α) ^ 21 + 22961042451753622392989015501956773126769350000 * α ^ 8 * (15 - α) ^ 20 + 148033957973212624082175754920221815579937805000 * α ^ 9 * (15 - α) ^ 19 + 791520488598836900068848830160917234498844101250 * α ^ 10 * (15 - α) ^ 18 + 3529526175327511018680726743043836767850893061250 * α ^ 11 * (15 - α) ^ 17 + 13165011207751367740633403433981725749824494296875 * α ^ 12 * (15 - α) ^ 16 + 40931653416291075198328442361012806391694992643125 * α ^ 13 * (15 - α) ^ 15 + 104936099346045749439240355737362583910582002551250 * α ^ 14 * (15 - α) ^ 14 + 218605526114400884612386873561624396579818747067500 * α ^ 15 * (15 - α) ^ 13 + 364544768185120783615020401898669737526038946860625 * α ^ 16 * (15 - α) ^ 12 + 479686011445303946308298171035582326066907836556875 * α ^ 17 * (15 - α) ^ 11 + 491421915359135714614282850386451786914114000492500 * α ^ 18 * (15 - α) ^ 10 + 389161288470744666432388567554714822581024179398750 * α ^ 19 * (15 - α) ^ 9 + 244558897556532361649184200629954946613489703141875 * α ^ 20 * (15 - α) ^ 8 + 139992773266086273600697845417718983669371612533125 * α ^ 21 * (15 - α) ^ 7 + 93042859490049901489480348991956175393389715291250 * α ^ 22 * (15 - α) ^ 6 + 69299238884896976481539054996360074995454890772500 * α ^ 23 * (15 - α) ^ 5 + 43491785146541891064576495824222890234435540966875 * α ^ 24 * (15 - α) ^ 4 + 19249688128515085853018716648633058220873114065625 * α ^ 25 * (15 - α) ^ 3 + 5426365264657811094720994999869461719092174416250 * α ^ 26 * (15 - α) ^ 2 + 847744461331358174965504508366152817665302528000 * α ^ 27 * (15 - α) ^ 1 + 51950222508646395464079311308157550857404416000 * α ^ 28 := by ring - rcases le_total α (15 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 586577450963685326737168897370707500 * (15 - α) ^ 28 := - mul_pos (by norm_num) (pow_pos (by linarith) 28) - linarith - · have hpos : (0 : ℝ) < 51950222508646395464079311308157550857404416000 * α ^ 28 := - mul_pos (by norm_num) (pow_pos (by linarith) 28) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (15 : ℝ) ^ 28)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 15 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree32_33.lean b/Sendov/FiniteRange/Degree32_33.lean index ce699c6..2663e99 100644 --- a/Sendov/FiniteRange/Degree32_33.lean +++ b/Sendov/FiniteRange/Degree32_33.lean @@ -88,77 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 16) : 0 < 383977583360819576313951392966054557440 + 1930634984998770141470327139790256873760 * α + 4528139655529657241697903448404234220551 * α ^ 2 + 6571116743547522810411224078221219285242 * α ^ 3 + 6597373572981213714180223077765169741761 * α ^ 4 + 4853145290868457132481352533313124037136 * α ^ 5 + 2701279688513765542055333848381676518287 * α ^ 6 + 1157769823809425762972955166775789744790 * α ^ 7 + 384826365482239087514233918976406892725 * α ^ 8 + 98972460520277767374027328895457052524 * α ^ 9 + 19429030643214541979169516429755259903 * α ^ 10 + 2812337464920293963928011188383752346 * α ^ 11 + 269412053495826821775011955678389445 * α ^ 12 + 3352473026131557768885960806993016 * α ^ 13 - 22950931900671630187087717249723635 * α ^ 14 + 1401665499631441401236402118586466 * α ^ 15 + 22766380179065358125804378947555 * α ^ 16 + 1462014916628262060084862591156 * α ^ 17 + 35132359566977040523019407180 * α ^ 18 - 1604603346728872922022402944 * α ^ 19 - 192243388845480689610974960 * α ^ 20 - 9672937893957196503857344 * α ^ 21 - 320523259524150064257216 * α ^ 22 - 7695435702924730354176 * α ^ 23 - 138216454665665111296 * α ^ 24 - 1869603872239262720 * α ^ 25 - 18853950116959232 * α ^ 26 - 137859411329024 * α ^ 27 - 692050472960 * α ^ 28 - 2136915968 * α ^ 29 - 3063808 * α ^ 30 := by have hu : (0 : ℝ) ≤ 16 - α := by linarith - have h0 : (0:ℝ) ≤ 383977583360819576313951392966054557440 * (16 - α) ^ 30 := - mul_nonneg (by norm_num) (pow_nonneg hu 30) - have h1 : (0:ℝ) ≤ 42409487260804909552943776025625746703360 * α ^ 1 * (16 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 29) - have h2 : (0:ℝ) ≤ 2222048633616978115213463931594396882372096 * α ^ 2 * (16 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 28) - have h3 : (0:ℝ) ≤ 73473353083404174858760833498075355240412160 * α ^ 3 * (16 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 27) - have h4 : (0:ℝ) ≤ 1720652985002569694625940957603172487457959168 * α ^ 4 * (16 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 26) - have h5 : (0:ℝ) ≤ 30363605055601889844187715226554004982348216320 * α ^ 5 * (16 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 25) - have h6 : (0:ℝ) ≤ 419419313440566659766595274985269607940848110592 * α ^ 6 * (16 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 24) - have h7 : (0:ℝ) ≤ 4651028177520748697700758854373515125968713340928 * α ^ 7 * (16 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 23) - have h8 : (0:ℝ) ≤ 42137577409585697471273190015560150932516267552512 * α ^ 8 * (16 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 22) - have h9 : (0:ℝ) ≤ 315813162774288007921028011965819893459606590098432 * α ^ 9 * (16 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 21) - have h10 : (0:ℝ) ≤ 1975705535276134028928012252827490436823332026530304 * α ^ 10 * (16 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 20) - have h11 : (0:ℝ) ≤ 10382688588871544644830770347967881283088055308155904 * α ^ 11 * (16 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 19) - have h12 : (0:ℝ) ≤ 46032559619183787080156358678834876487940673091005696 * α ^ 12 * (16 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 18) - have h13 : (0:ℝ) ≤ 172591747559291476479103054798864248406917335500124160 * α ^ 13 * (16 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 17) - have h14 : (0:ℝ) ≤ 545974175950014920103132403616690663895819828147984384 * α ^ 14 * (16 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 16) - have h15 : (0:ℝ) ≤ 1445130613022938433929608617595105884579474631328108544 * α ^ 15 * (16 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 15) - have h16 : (0:ℝ) ≤ 3161509852911810407500355299058617164221708297980898560 * α ^ 16 * (16 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 14) - have h17 : (0:ℝ) ≤ 5640295189041616515165641512647513399952299862475037696 * α ^ 17 * (16 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 13) - have h18 : (0:ℝ) ≤ 8096357711013760274749679034695047723667449284765784576 * α ^ 18 * (16 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 12) - have h19 : (0:ℝ) ≤ 9222746840024741255973982987098297227268540123123805184 * α ^ 19 * (16 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 11) - have h20 : (0:ℝ) ≤ 8223039813167952720182093497637178426661494992975589120 * α ^ 20 * (16 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 10) - have h21 : (0:ℝ) ≤ 5704256351282499932163905647696347181598873537091336192 * α ^ 21 * (16 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 9) - have h22 : (0:ℝ) ≤ 3201419973312332497561890234813360990647765548239842304 * α ^ 22 * (16 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 8) - have h23 : (0:ℝ) ≤ 1740681060211180094425255735717618532157429256988792832 * α ^ 23 * (16 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 7) - have h24 : (0:ℝ) ≤ 1171781379026559228219387738006839365835033511446179072 * α ^ 24 * (16 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 6) - have h25 : (0:ℝ) ≤ 856349049543820949149124961191230752126749714115924992 * α ^ 25 * (16 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 5) - have h26 : (0:ℝ) ≤ 505504390045160314727256739583393494736411020808873472 * α ^ 26 * (16 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 4) - have h27 : (0:ℝ) ≤ 207885993237921287478858446074371829024853091294110720 * α ^ 27 * (16 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 3) - have h28 : (0:ℝ) ≤ 54498421679605652502910205539029441943284379111601920 * α ^ 28 * (16 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 2) - have h29 : (0:ℝ) ≤ 7954898798277651559977779244576588075469014026035200 * α ^ 29 * (16 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 1) - have h30 : (0:ℝ) ≤ 458384953904887998462676380172134968211581830656000 * α ^ 30 := - mul_nonneg (by norm_num) (pow_nonneg hα 30) have hid : (16 : ℝ) ^ 30 * (383977583360819576313951392966054557440 + 1930634984998770141470327139790256873760 * α + 4528139655529657241697903448404234220551 * α ^ 2 + 6571116743547522810411224078221219285242 * α ^ 3 + 6597373572981213714180223077765169741761 * α ^ 4 + 4853145290868457132481352533313124037136 * α ^ 5 + 2701279688513765542055333848381676518287 * α ^ 6 + 1157769823809425762972955166775789744790 * α ^ 7 + 384826365482239087514233918976406892725 * α ^ 8 + 98972460520277767374027328895457052524 * α ^ 9 + 19429030643214541979169516429755259903 * α ^ 10 + 2812337464920293963928011188383752346 * α ^ 11 + 269412053495826821775011955678389445 * α ^ 12 + 3352473026131557768885960806993016 * α ^ 13 - 22950931900671630187087717249723635 * α ^ 14 + 1401665499631441401236402118586466 * α ^ 15 + 22766380179065358125804378947555 * α ^ 16 + 1462014916628262060084862591156 * α ^ 17 + 35132359566977040523019407180 * α ^ 18 - 1604603346728872922022402944 * α ^ 19 - 192243388845480689610974960 * α ^ 20 - 9672937893957196503857344 * α ^ 21 - 320523259524150064257216 * α ^ 22 - 7695435702924730354176 * α ^ 23 - 138216454665665111296 * α ^ 24 - 1869603872239262720 * α ^ 25 - 18853950116959232 * α ^ 26 - 137859411329024 * α ^ 27 - 692050472960 * α ^ 28 - 2136915968 * α ^ 29 - 3063808 * α ^ 30) = 383977583360819576313951392966054557440 * (16 - α) ^ 30 + 42409487260804909552943776025625746703360 * α ^ 1 * (16 - α) ^ 29 + 2222048633616978115213463931594396882372096 * α ^ 2 * (16 - α) ^ 28 + 73473353083404174858760833498075355240412160 * α ^ 3 * (16 - α) ^ 27 + 1720652985002569694625940957603172487457959168 * α ^ 4 * (16 - α) ^ 26 + 30363605055601889844187715226554004982348216320 * α ^ 5 * (16 - α) ^ 25 + 419419313440566659766595274985269607940848110592 * α ^ 6 * (16 - α) ^ 24 + 4651028177520748697700758854373515125968713340928 * α ^ 7 * (16 - α) ^ 23 + 42137577409585697471273190015560150932516267552512 * α ^ 8 * (16 - α) ^ 22 + 315813162774288007921028011965819893459606590098432 * α ^ 9 * (16 - α) ^ 21 + 1975705535276134028928012252827490436823332026530304 * α ^ 10 * (16 - α) ^ 20 + 10382688588871544644830770347967881283088055308155904 * α ^ 11 * (16 - α) ^ 19 + 46032559619183787080156358678834876487940673091005696 * α ^ 12 * (16 - α) ^ 18 + 172591747559291476479103054798864248406917335500124160 * α ^ 13 * (16 - α) ^ 17 + 545974175950014920103132403616690663895819828147984384 * α ^ 14 * (16 - α) ^ 16 + 1445130613022938433929608617595105884579474631328108544 * α ^ 15 * (16 - α) ^ 15 + 3161509852911810407500355299058617164221708297980898560 * α ^ 16 * (16 - α) ^ 14 + 5640295189041616515165641512647513399952299862475037696 * α ^ 17 * (16 - α) ^ 13 + 8096357711013760274749679034695047723667449284765784576 * α ^ 18 * (16 - α) ^ 12 + 9222746840024741255973982987098297227268540123123805184 * α ^ 19 * (16 - α) ^ 11 + 8223039813167952720182093497637178426661494992975589120 * α ^ 20 * (16 - α) ^ 10 + 5704256351282499932163905647696347181598873537091336192 * α ^ 21 * (16 - α) ^ 9 + 3201419973312332497561890234813360990647765548239842304 * α ^ 22 * (16 - α) ^ 8 + 1740681060211180094425255735717618532157429256988792832 * α ^ 23 * (16 - α) ^ 7 + 1171781379026559228219387738006839365835033511446179072 * α ^ 24 * (16 - α) ^ 6 + 856349049543820949149124961191230752126749714115924992 * α ^ 25 * (16 - α) ^ 5 + 505504390045160314727256739583393494736411020808873472 * α ^ 26 * (16 - α) ^ 4 + 207885993237921287478858446074371829024853091294110720 * α ^ 27 * (16 - α) ^ 3 + 54498421679605652502910205539029441943284379111601920 * α ^ 28 * (16 - α) ^ 2 + 7954898798277651559977779244576588075469014026035200 * α ^ 29 * (16 - α) ^ 1 + 458384953904887998462676380172134968211581830656000 * α ^ 30 := by ring - rcases le_total α (16 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 383977583360819576313951392966054557440 * (16 - α) ^ 30 := - mul_pos (by norm_num) (pow_pos (by linarith) 30) - linarith - · have hpos : (0 : ℝ) < 458384953904887998462676380172134968211581830656000 * α ^ 30 := - mul_pos (by norm_num) (pow_pos (by linarith) 30) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (16 : ℝ) ^ 30)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 16 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree34_35.lean b/Sendov/FiniteRange/Degree34_35.lean index 689d536..93a5581 100644 --- a/Sendov/FiniteRange/Degree34_35.lean +++ b/Sendov/FiniteRange/Degree34_35.lean @@ -88,81 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 13399266531718143561671329774091404024125 + 71849885492802810816842838949259978576823 * α + 180538945319091116404922710783631485776255 * α ^ 2 + 282156930875912547195503056499665223632869 * α ^ 3 + 306955881947816717076752055353611201997433 * α ^ 4 + 246444353252723432574425088492703243027965 * α ^ 5 + 151019226036657912949719936683240321200053 * α ^ 6 + 72028327083715746440304318235594953916857 * α ^ 7 + 27007117326925331098314143315441103261561 * α ^ 8 + 7979024241553623900285784858349597089245 * α ^ 9 + 1847320854708526473676328223562198887417 * α ^ 10 + 329938708337757813561795624655269556461 * α ^ 11 + 43878641971714608549212527982241857715 * α ^ 12 + 3911666704610568428372170990877699643 * α ^ 13 + 54464632768848512857832724331386693 * α ^ 14 - 300202584430678770107735269889128119 * α ^ 15 + 16644540127319447720784804793743786 * α ^ 16 + 228891055611380679685401624709920 * α ^ 17 + 16200353115196577039237473724202 * α ^ 18 + 510663548855848557629648901888 * α ^ 19 - 6873476290889727146869228680 * α ^ 20 - 1591901557063130972106786240 * α ^ 21 - 90385492060860172817322528 * α ^ 22 - 3241298369821124224491264 * α ^ 23 - 83924819944658782911360 * α ^ 24 - 1639999868886062272512 * α ^ 25 - 24549687196522919424 * α ^ 26 - 281209623855906816 * α ^ 27 - 2429673447720960 * α ^ 28 - 15359508856832 * α ^ 29 - 67149078528 * α ^ 30 - 181665792 * α ^ 31 - 229376 * α ^ 32 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 13399266531718143561671329774091404024125 * (17 - α) ^ 32 := - mul_nonneg (by norm_num) (pow_nonneg hu 32) - have h1 : (0:ℝ) ≤ 1650224582392628377859810814908344564577991 * α ^ 1 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 31) - have h2 : (0:ℝ) ≤ 96686681051656613148087819110678844495289416 * α ^ 2 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 30) - have h3 : (0:ℝ) ≤ 3585943364127806535175218856650333719997862062 * α ^ 3 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 29) - have h4 : (0:ℝ) ≤ 94506835391773642943632702539240023655585239976 * α ^ 4 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 28) - have h5 : (0:ℝ) ≤ 1883536024491957754295155022173521798076402761306 * α ^ 5 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 27) - have h6 : (0:ℝ) ≤ 29498713431163207985062885810393117977995458611360 * α ^ 6 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 26) - have h7 : (0:ℝ) ≤ 372444567835409169626366992601449865136908523715554 * α ^ 7 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 25) - have h8 : (0:ℝ) ≤ 3859379869369491930046652624818040581445251700417436 * α ^ 8 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 24) - have h9 : (0:ℝ) ≤ 33247489122948312922756142978001205956348938877434094 * α ^ 9 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 23) - have h10 : (0:ℝ) ≤ 240361064800204816769332884725722337309385385508245284 * α ^ 10 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 22) - have h11 : (0:ℝ) ≤ 1468297579222476711150318215261328148465442277706125318 * α ^ 11 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 21) - have h12 : (0:ℝ) ≤ 7616476027067108231341929094010647728198437294881398882 * α ^ 12 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 20) - have h13 : (0:ℝ) ≤ 33663083667068151985435771538517917417846319467001398040 * α ^ 13 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 19) - have h14 : (0:ℝ) ≤ 127012191711700706943666066187667778984137340603569186202 * α ^ 14 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 18) - have h15 : (0:ℝ) ≤ 408483237363770470892000173862806063969919527704726536136 * α ^ 15 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 17) - have h16 : (0:ℝ) ≤ 1112699056508533083404960444025601114584826187986242644199 * α ^ 16 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 16) - have h17 : (0:ℝ) ≤ 2541228944450694617802464818664598037324243538753868594135 * α ^ 17 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 15) - have h18 : (0:ℝ) ≤ 4808963007779256297034335517823636520905050012269500452122 * α ^ 18 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 14) - have h19 : (0:ℝ) ≤ 7449105095546099705010373449780908551641339483192620776998 * α ^ 19 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 13) - have h20 : (0:ℝ) ≤ 9324511543492008692105399378290148512417024338959823894774 * α ^ 20 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 12) - have h21 : (0:ℝ) ≤ 9297740340616393778000297728009621202927136433782291562398 * α ^ 21 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 11) - have h22 : (0:ℝ) ≤ 7274130570772010006967162133652153552632813945113550333758 * α ^ 22 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 10) - have h23 : (0:ℝ) ≤ 4441828800293274983181495636158215106270810356077510048966 * α ^ 23 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 9) - have h24 : (0:ℝ) ≤ 2239471510489480023234027273281488727890334103099818233488 * α ^ 24 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 8) - have h25 : (0:ℝ) ≤ 1180013639374388482169007814986614403675247990630945641900 * α ^ 25 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 7) - have h26 : (0:ℝ) ≤ 818218224361787722039978747842931615637242518870584611650 * α ^ 26 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 6) - have h27 : (0:ℝ) ≤ 587927012852098590957570014487485323178262550641905003190 * α ^ 27 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 5) - have h28 : (0:ℝ) ≤ 327641901908612799526209846021045735379467528409310341680 * α ^ 28 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 4) - have h29 : (0:ℝ) ≤ 125868057563181650595391338568950934373772184543193971640 * α ^ 29 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 3) - have h30 : (0:ℝ) ≤ 30847873348677414400175155768102397838878364715388408640 * α ^ 30 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 2) - have h31 : (0:ℝ) ≤ 4226337377572378619631312225122710192128000000000000000 * α ^ 31 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 1) - have h32 : (0:ℝ) ≤ 229862066916150806363247669850238091264000000000000000 * α ^ 32 := - mul_nonneg (by norm_num) (pow_nonneg hα 32) have hid : (17 : ℝ) ^ 32 * (13399266531718143561671329774091404024125 + 71849885492802810816842838949259978576823 * α + 180538945319091116404922710783631485776255 * α ^ 2 + 282156930875912547195503056499665223632869 * α ^ 3 + 306955881947816717076752055353611201997433 * α ^ 4 + 246444353252723432574425088492703243027965 * α ^ 5 + 151019226036657912949719936683240321200053 * α ^ 6 + 72028327083715746440304318235594953916857 * α ^ 7 + 27007117326925331098314143315441103261561 * α ^ 8 + 7979024241553623900285784858349597089245 * α ^ 9 + 1847320854708526473676328223562198887417 * α ^ 10 + 329938708337757813561795624655269556461 * α ^ 11 + 43878641971714608549212527982241857715 * α ^ 12 + 3911666704610568428372170990877699643 * α ^ 13 + 54464632768848512857832724331386693 * α ^ 14 - 300202584430678770107735269889128119 * α ^ 15 + 16644540127319447720784804793743786 * α ^ 16 + 228891055611380679685401624709920 * α ^ 17 + 16200353115196577039237473724202 * α ^ 18 + 510663548855848557629648901888 * α ^ 19 - 6873476290889727146869228680 * α ^ 20 - 1591901557063130972106786240 * α ^ 21 - 90385492060860172817322528 * α ^ 22 - 3241298369821124224491264 * α ^ 23 - 83924819944658782911360 * α ^ 24 - 1639999868886062272512 * α ^ 25 - 24549687196522919424 * α ^ 26 - 281209623855906816 * α ^ 27 - 2429673447720960 * α ^ 28 - 15359508856832 * α ^ 29 - 67149078528 * α ^ 30 - 181665792 * α ^ 31 - 229376 * α ^ 32) = 13399266531718143561671329774091404024125 * (17 - α) ^ 32 + 1650224582392628377859810814908344564577991 * α ^ 1 * (17 - α) ^ 31 + 96686681051656613148087819110678844495289416 * α ^ 2 * (17 - α) ^ 30 + 3585943364127806535175218856650333719997862062 * α ^ 3 * (17 - α) ^ 29 + 94506835391773642943632702539240023655585239976 * α ^ 4 * (17 - α) ^ 28 + 1883536024491957754295155022173521798076402761306 * α ^ 5 * (17 - α) ^ 27 + 29498713431163207985062885810393117977995458611360 * α ^ 6 * (17 - α) ^ 26 + 372444567835409169626366992601449865136908523715554 * α ^ 7 * (17 - α) ^ 25 + 3859379869369491930046652624818040581445251700417436 * α ^ 8 * (17 - α) ^ 24 + 33247489122948312922756142978001205956348938877434094 * α ^ 9 * (17 - α) ^ 23 + 240361064800204816769332884725722337309385385508245284 * α ^ 10 * (17 - α) ^ 22 + 1468297579222476711150318215261328148465442277706125318 * α ^ 11 * (17 - α) ^ 21 + 7616476027067108231341929094010647728198437294881398882 * α ^ 12 * (17 - α) ^ 20 + 33663083667068151985435771538517917417846319467001398040 * α ^ 13 * (17 - α) ^ 19 + 127012191711700706943666066187667778984137340603569186202 * α ^ 14 * (17 - α) ^ 18 + 408483237363770470892000173862806063969919527704726536136 * α ^ 15 * (17 - α) ^ 17 + 1112699056508533083404960444025601114584826187986242644199 * α ^ 16 * (17 - α) ^ 16 + 2541228944450694617802464818664598037324243538753868594135 * α ^ 17 * (17 - α) ^ 15 + 4808963007779256297034335517823636520905050012269500452122 * α ^ 18 * (17 - α) ^ 14 + 7449105095546099705010373449780908551641339483192620776998 * α ^ 19 * (17 - α) ^ 13 + 9324511543492008692105399378290148512417024338959823894774 * α ^ 20 * (17 - α) ^ 12 + 9297740340616393778000297728009621202927136433782291562398 * α ^ 21 * (17 - α) ^ 11 + 7274130570772010006967162133652153552632813945113550333758 * α ^ 22 * (17 - α) ^ 10 + 4441828800293274983181495636158215106270810356077510048966 * α ^ 23 * (17 - α) ^ 9 + 2239471510489480023234027273281488727890334103099818233488 * α ^ 24 * (17 - α) ^ 8 + 1180013639374388482169007814986614403675247990630945641900 * α ^ 25 * (17 - α) ^ 7 + 818218224361787722039978747842931615637242518870584611650 * α ^ 26 * (17 - α) ^ 6 + 587927012852098590957570014487485323178262550641905003190 * α ^ 27 * (17 - α) ^ 5 + 327641901908612799526209846021045735379467528409310341680 * α ^ 28 * (17 - α) ^ 4 + 125868057563181650595391338568950934373772184543193971640 * α ^ 29 * (17 - α) ^ 3 + 30847873348677414400175155768102397838878364715388408640 * α ^ 30 * (17 - α) ^ 2 + 4226337377572378619631312225122710192128000000000000000 * α ^ 31 * (17 - α) ^ 1 + 229862066916150806363247669850238091264000000000000000 * α ^ 32 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 13399266531718143561671329774091404024125 * (17 - α) ^ 32 := - mul_pos (by norm_num) (pow_pos (by linarith) 32) - linarith - · have hpos : (0 : ℝ) < 229862066916150806363247669850238091264000000000000000 * α ^ 32 := - mul_pos (by norm_num) (pow_pos (by linarith) 32) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 32)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree36_37.lean b/Sendov/FiniteRange/Degree36_37.lean index dddc45b..e2df718 100644 --- a/Sendov/FiniteRange/Degree36_37.lean +++ b/Sendov/FiniteRange/Degree36_37.lean @@ -88,85 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 1340862494179159723457439116979158935546875000 + 7637969043915714340759947223349395751953125000 * α + 20469159372189815097433030931483526306152343750 * α ^ 2 + 34274361726863699928017616105749597900390625000 * α ^ 3 + 40158420010659405404629812835302538476562500000 * α ^ 4 + 34937401402816329855420946112276054381835937500 * α ^ 5 + 23367211725435618964676169025739806953662109375 * α ^ 6 + 12270122821734134505495363628244218847460937500 * α ^ 7 + 5119554315996410501630574472803506399777343750 * α ^ 8 + 1706085086162412699720364430591688420225000000 * α ^ 9 + 453657266969080072299236418096329864193140625 * α ^ 10 + 95512498825559724167251930963289431001100000 * α ^ 11 + 15651081746907280778533576463846724310987500 * α ^ 12 + 1925946170421648313592236215225863164072500 * α ^ 13 + 160780952585487184902439630853241164106375 * α ^ 14 + 2481149473011100292550908813010287159220 * α ^ 15 - 11166042731030257542258130633810209326742 * α ^ 16 + 567791382062622839648458479091876877544 * α ^ 17 + 6430218988186661251397393995576293933 * α ^ 18 + 498747834176692841464289681241746784 * α ^ 19 + 18702443537088721760797370916939480 * α ^ 20 + 57367909378421946482804755695328 * α ^ 21 - 35467391809924321679454804549376 * α ^ 22 - 2344076836762407866768807250432 * α ^ 23 - 91095016683709754039240857216 * α ^ 24 - 2528503186830718445641541120 * α ^ 25 - 53176733671797993730857984 * α ^ 26 - 866597180873027929669632 * α ^ 27 - 11005160172719761434624 * α ^ 28 - 108265710516964073472 * α ^ 29 - 810954254409318400 * α ^ 30 - 4477829562761216 * α ^ 31 - 17204805009408 * α ^ 32 - 41120301056 * α ^ 33 - 46071808 * α ^ 34 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 1340862494179159723457439116979158935546875000 * (17 - α) ^ 34 := - mul_nonneg (by norm_num) (pow_nonneg hu 34) - have h1 : (0:ℝ) ≤ 175434798548658574390472032774231131591796875000 * α ^ 1 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 33) - have h2 : (0:ℝ) ≤ 10952711551434080913184099676123058282165527343750 * α ^ 2 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 32) - have h3 : (0:ℝ) ≤ 434270856341448311475241819934694889103759765625000 * α ^ 3 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 31) - have h4 : (0:ℝ) ≤ 12278911436635306192132622790762987549533349609375000 * α ^ 4 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 30) - have h5 : (0:ℝ) ≤ 263557269216566555320865047728777428822756844726562500 * α ^ 5 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 29) - have h6 : (0:ℝ) ≤ 4463883671586096731770907085592494749976786136669921875 * α ^ 6 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 28) - have h7 : (0:ℝ) ≤ 61225965954407894273160354546600964058305754660156250000 * α ^ 7 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 27) - have h8 : (0:ℝ) ≤ 692587772613132439128122751366082049061109249880812500000 * α ^ 8 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 26) - have h9 : (0:ℝ) ≤ 6547796240902796556445336115711018473638408241918575000000 * α ^ 9 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 25) - have h10 : (0:ℝ) ≤ 52247549382615756077051379940154408637849061298491733812500 * α ^ 10 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 24) - have h11 : (0:ℝ) ≤ 354466647029909646510470656479599263564041502427407695300000 * α ^ 11 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 23) - have h12 : (0:ℝ) ≤ 2055889704738111710267568200183486826512215613684783110200000 * α ^ 12 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 22) - have h13 : (0:ℝ) ≤ 10234888840339768071474956793147766100757409148665132934370000 * α ^ 13 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 21) - have h14 : (0:ℝ) ≤ 43858398380617067829266771169258660902757314148335253721083000 * α ^ 14 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 20) - have h15 : (0:ℝ) ≤ 162055210405371666456160142527627828678422430377426835106958960 * α ^ 15 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 19) - have h16 : (0:ℝ) ≤ 516145320938971158929091669417239050325330885780111469198875088 * α ^ 16 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 18) - have h17 : (0:ℝ) ≤ 1412064392511895951084181534107896493318729250846824514725955712 * α ^ 17 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 17) - have h18 : (0:ℝ) ≤ 3296410975824492770073801068890863487757382337405699389044881152 * α ^ 18 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 16) - have h19 : (0:ℝ) ≤ 6510700656466073656283913487155596019027366109135146309819197400 * α ^ 19 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 15) - have h20 : (0:ℝ) ≤ 10778762671920232847172097564072974706837835927532659281695627000 * α ^ 20 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 14) - have h21 : (0:ℝ) ≤ 14812853870469700737370316477184138613188186623760145268072292500 * α ^ 21 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 13) - have h22 : (0:ℝ) ≤ 16720671608226908945079705353880617034286101018111021059080009375 * α ^ 22 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 12) - have h23 : (0:ℝ) ≤ 15317420704224111419919616448379092129752276964124634080685800000 * α ^ 23 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 11) - have h24 : (0:ℝ) ≤ 11238165133613859896218350103981386092933200214685034701456250000 * α ^ 24 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 10) - have h25 : (0:ℝ) ≤ 6544374325964212483346602292437892685413037367000381149781250000 * α ^ 25 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 9) - have h26 : (0:ℝ) ≤ 3087009276202780754337495361663231009012869918782181865781250000 * α ^ 26 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 8) - have h27 : (0:ℝ) ≤ 1334541850899219151104336491093618277155327063911213757812500000 * α ^ 27 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 7) - have h28 : (0:ℝ) ≤ 671021217962301496929047441300025617792685964844905141406250000 * α ^ 28 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 6) - have h29 : (0:ℝ) ≤ 390013014583991314611686405951849748841394880271566591796875000 * α ^ 29 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 5) - have h30 : (0:ℝ) ≤ 198126638262411132449557681354886342145672562882243054199218750 * α ^ 30 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 4) - have h31 : (0:ℝ) ≤ 72921376026239920902575443619361410154303245019324218750000000 * α ^ 31 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 3) - have h32 : (0:ℝ) ≤ 17546793780907574541651374555825605095190744540455322265625000 * α ^ 32 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 2) - have h33 : (0:ℝ) ≤ 2427279654890969862947772530516229556781067701712646484375000 * α ^ 33 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 1) - have h34 : (0:ℝ) ≤ 141776547693471981630558155006611207847406241325378417968750 * α ^ 34 := - mul_nonneg (by norm_num) (pow_nonneg hα 34) have hid : (17 : ℝ) ^ 34 * (1340862494179159723457439116979158935546875000 + 7637969043915714340759947223349395751953125000 * α + 20469159372189815097433030931483526306152343750 * α ^ 2 + 34274361726863699928017616105749597900390625000 * α ^ 3 + 40158420010659405404629812835302538476562500000 * α ^ 4 + 34937401402816329855420946112276054381835937500 * α ^ 5 + 23367211725435618964676169025739806953662109375 * α ^ 6 + 12270122821734134505495363628244218847460937500 * α ^ 7 + 5119554315996410501630574472803506399777343750 * α ^ 8 + 1706085086162412699720364430591688420225000000 * α ^ 9 + 453657266969080072299236418096329864193140625 * α ^ 10 + 95512498825559724167251930963289431001100000 * α ^ 11 + 15651081746907280778533576463846724310987500 * α ^ 12 + 1925946170421648313592236215225863164072500 * α ^ 13 + 160780952585487184902439630853241164106375 * α ^ 14 + 2481149473011100292550908813010287159220 * α ^ 15 - 11166042731030257542258130633810209326742 * α ^ 16 + 567791382062622839648458479091876877544 * α ^ 17 + 6430218988186661251397393995576293933 * α ^ 18 + 498747834176692841464289681241746784 * α ^ 19 + 18702443537088721760797370916939480 * α ^ 20 + 57367909378421946482804755695328 * α ^ 21 - 35467391809924321679454804549376 * α ^ 22 - 2344076836762407866768807250432 * α ^ 23 - 91095016683709754039240857216 * α ^ 24 - 2528503186830718445641541120 * α ^ 25 - 53176733671797993730857984 * α ^ 26 - 866597180873027929669632 * α ^ 27 - 11005160172719761434624 * α ^ 28 - 108265710516964073472 * α ^ 29 - 810954254409318400 * α ^ 30 - 4477829562761216 * α ^ 31 - 17204805009408 * α ^ 32 - 41120301056 * α ^ 33 - 46071808 * α ^ 34) = 1340862494179159723457439116979158935546875000 * (17 - α) ^ 34 + 175434798548658574390472032774231131591796875000 * α ^ 1 * (17 - α) ^ 33 + 10952711551434080913184099676123058282165527343750 * α ^ 2 * (17 - α) ^ 32 + 434270856341448311475241819934694889103759765625000 * α ^ 3 * (17 - α) ^ 31 + 12278911436635306192132622790762987549533349609375000 * α ^ 4 * (17 - α) ^ 30 + 263557269216566555320865047728777428822756844726562500 * α ^ 5 * (17 - α) ^ 29 + 4463883671586096731770907085592494749976786136669921875 * α ^ 6 * (17 - α) ^ 28 + 61225965954407894273160354546600964058305754660156250000 * α ^ 7 * (17 - α) ^ 27 + 692587772613132439128122751366082049061109249880812500000 * α ^ 8 * (17 - α) ^ 26 + 6547796240902796556445336115711018473638408241918575000000 * α ^ 9 * (17 - α) ^ 25 + 52247549382615756077051379940154408637849061298491733812500 * α ^ 10 * (17 - α) ^ 24 + 354466647029909646510470656479599263564041502427407695300000 * α ^ 11 * (17 - α) ^ 23 + 2055889704738111710267568200183486826512215613684783110200000 * α ^ 12 * (17 - α) ^ 22 + 10234888840339768071474956793147766100757409148665132934370000 * α ^ 13 * (17 - α) ^ 21 + 43858398380617067829266771169258660902757314148335253721083000 * α ^ 14 * (17 - α) ^ 20 + 162055210405371666456160142527627828678422430377426835106958960 * α ^ 15 * (17 - α) ^ 19 + 516145320938971158929091669417239050325330885780111469198875088 * α ^ 16 * (17 - α) ^ 18 + 1412064392511895951084181534107896493318729250846824514725955712 * α ^ 17 * (17 - α) ^ 17 + 3296410975824492770073801068890863487757382337405699389044881152 * α ^ 18 * (17 - α) ^ 16 + 6510700656466073656283913487155596019027366109135146309819197400 * α ^ 19 * (17 - α) ^ 15 + 10778762671920232847172097564072974706837835927532659281695627000 * α ^ 20 * (17 - α) ^ 14 + 14812853870469700737370316477184138613188186623760145268072292500 * α ^ 21 * (17 - α) ^ 13 + 16720671608226908945079705353880617034286101018111021059080009375 * α ^ 22 * (17 - α) ^ 12 + 15317420704224111419919616448379092129752276964124634080685800000 * α ^ 23 * (17 - α) ^ 11 + 11238165133613859896218350103981386092933200214685034701456250000 * α ^ 24 * (17 - α) ^ 10 + 6544374325964212483346602292437892685413037367000381149781250000 * α ^ 25 * (17 - α) ^ 9 + 3087009276202780754337495361663231009012869918782181865781250000 * α ^ 26 * (17 - α) ^ 8 + 1334541850899219151104336491093618277155327063911213757812500000 * α ^ 27 * (17 - α) ^ 7 + 671021217962301496929047441300025617792685964844905141406250000 * α ^ 28 * (17 - α) ^ 6 + 390013014583991314611686405951849748841394880271566591796875000 * α ^ 29 * (17 - α) ^ 5 + 198126638262411132449557681354886342145672562882243054199218750 * α ^ 30 * (17 - α) ^ 4 + 72921376026239920902575443619361410154303245019324218750000000 * α ^ 31 * (17 - α) ^ 3 + 17546793780907574541651374555825605095190744540455322265625000 * α ^ 32 * (17 - α) ^ 2 + 2427279654890969862947772530516229556781067701712646484375000 * α ^ 33 * (17 - α) ^ 1 + 141776547693471981630558155006611207847406241325378417968750 * α ^ 34 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 1340862494179159723457439116979158935546875000 * (17 - α) ^ 34 := - mul_pos (by norm_num) (pow_pos (by linarith) 34) - linarith - · have hpos : (0 : ℝ) < 141776547693471981630558155006611207847406241325378417968750 * α ^ 34 := - mul_pos (by norm_num) (pow_pos (by linarith) 34) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 34)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree38_39.lean b/Sendov/FiniteRange/Degree38_39.lean index 22c5ca8..afcef1f 100644 --- a/Sendov/FiniteRange/Degree38_39.lean +++ b/Sendov/FiniteRange/Degree38_39.lean @@ -88,89 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 263016241667210021671084890841481617690003189110 + 1586061041777522258785370750920508059260325100670 * α + 4515569002916763022083813591656453793545843463960 * α ^ 2 + 8064535450447153538886731843043227730967854436080 * α ^ 3 + 10124049292126400106014356225197947036232792604485 * α ^ 4 + 9486490487762873429871569630238934346081556621609 * α ^ 5 + 6875502816855646349457849536822502570739478645343 * α ^ 6 + 3940536916491738744952644524802984325688545318839 * α ^ 7 + 1810118648803944257004276579444295893576974412957 * α ^ 8 + 671223601039568220250335587923837679954504671929 * α ^ 9 + 201302327242382412835780103712068254297083069927 * α ^ 10 + 48665320464285286858138805925504857552220130935 * α ^ 11 + 9395447364524194147939717327946455319249576385 * α ^ 12 + 1422463731757903542558687467068487748999154005 * α ^ 13 + 162936488968328754409221779604516446092275015 * α ^ 14 + 12804246766409474561270894860455521523191007 * α ^ 15 + 216069416334011168489825518695466581657549 * α ^ 16 - 808211600142399392096627843592018139890543 * α ^ 17 + 38042736580603120168867477319356142859621 * α ^ 18 + 344373790265831271857444699712655317117 * α ^ 19 + 29315226870352164747186119924985775776 * α ^ 20 + 1247198097855472249813750976434442560 * α ^ 21 + 16662184536264199136681220318869840 * α ^ 22 - 1406905416514864930658623327447840 * α ^ 23 - 115154592405960528415597818779200 * α ^ 24 - 4877945634325956011421670432000 * α ^ 25 - 144681078013665355320791476480 * α ^ 26 - 3249838030348665967746429440 * α ^ 27 - 56982963376184696008104960 * α ^ 28 - 788738718851438284800000 * α ^ 29 - 8618882420705188376576 * α ^ 30 - 73677168662756319232 * α ^ 31 - 483260148118798336 * α ^ 32 - 2351449584959488 * α ^ 33 - 8003806560256 * α ^ 34 - 17023172608 * α ^ 35 - 17039360 * α ^ 36 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 263016241667210021671084890841481617690003189110 * (17 - α) ^ 36 := - mul_nonneg (by norm_num) (pow_nonneg hu 36) - have h1 : (0:ℝ) ≤ 36431622410237439179510358835941975244265641519350 * α ^ 1 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 35) - have h2 : (0:ℝ) ≤ 2414405993950912571012301206016550860739344205122390 * α ^ 2 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 34) - have h3 : (0:ℝ) ≤ 101911987093790495993891637162656810587351337884854450 * α ^ 3 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 33) - have h4 : (0:ℝ) ≤ 3077136529375910511818308139163370204204710108135348945 * α ^ 4 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 32) - have h5 : (0:ℝ) ≤ 70767700416372118022916506935148443513144214212984079433 * α ^ 5 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 31) - have h6 : (0:ℝ) ≤ 1288872796711775738410766166408400924167189843482363181510 * α ^ 6 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 30) - have h7 : (0:ℝ) ≤ 19083400748229222868616813579365546608706181811242799713442 * α ^ 7 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 29) - have h8 : (0:ℝ) ≤ 234010152840381946349380212378698061303021231207480935794380 * α ^ 8 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 28) - have h9 : (0:ℝ) ≤ 2409083298538233479330794311735295130068631390190510305345916 * α ^ 9 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 27) - have h10 : (0:ℝ) ≤ 21034199072421691415654588980184171455732743682853035936388736 * α ^ 10 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 26) - have h11 : (0:ℝ) ≤ 156965739060943279756832920952171731542118382822579555902264320 * α ^ 11 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 25) - have h12 : (0:ℝ) ≤ 1007013809256349634438976269863634909802444822788284670764336920 * α ^ 12 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 24) - have h13 : (0:ℝ) ≤ 5578883286717752179555968646363028277131383001091676680613578600 * α ^ 13 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 23) - have h14 : (0:ℝ) ≤ 26778108682132812026449907006307737451347925518376385819177842180 * α ^ 14 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 22) - have h15 : (0:ℝ) ≤ 111626866485074002051921408370316196620668741767980677786122726476 * α ^ 15 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 21) - have h16 : (0:ℝ) ≤ 404749936967515936812332395113162625848731824975287760415129552520 * α ^ 16 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 20) - have h17 : (0:ℝ) ≤ 1276851853339474854752478301460896841716394369316599334161708835864 * α ^ 17 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 19) - have h18 : (0:ℝ) ≤ 3498152021559931653758754395800484089136347016702124578632888785870 * α ^ 18 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 18) - have h19 : (0:ℝ) ≤ 8288489989122825212327334609599909543398390901155522489744660111602 * α ^ 19 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 17) - have h20 : (0:ℝ) ≤ 16882651085623904442176264117055333605492167285591363946133352298205 * α ^ 20 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 16) - have h21 : (0:ℝ) ≤ 29353791640642678379569945946711713118769355441603863420459332583845 * α ^ 21 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 15) - have h22 : (0:ℝ) ≤ 43236117652901827874516888436407546705327794671242323926919339677542 * α ^ 22 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 14) - have h23 : (0:ℝ) ≤ 53514417120286757722309232459981186747567529389425853874706900031330 * α ^ 23 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 13) - have h24 : (0:ℝ) ≤ 55160684404854002133844526815694799322288761295220210026216244417256 * α ^ 24 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 12) - have h25 : (0:ℝ) ≤ 46859199139271497704482066786546595457658791134521569883679868639464 * α ^ 25 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 11) - have h26 : (0:ℝ) ≤ 32418496139685480362601229821482044096981462148753646754741401291900 * α ^ 26 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 10) - have h27 : (0:ℝ) ≤ 18064228253690987870059860955691584275196341087334183534685080363332 * α ^ 27 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 9) - have h28 : (0:ℝ) ≤ 8116057087439008484605418610430390304640800612633036742729214781010 * α ^ 28 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 8) - have h29 : (0:ℝ) ≤ 3094097281163451800860397134053738271256213921040320763043485148866 * α ^ 29 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 7) - have h30 : (0:ℝ) ≤ 1174308203032074417716759573429346434013837010515376831055725367856 * α ^ 30 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 6) - have h31 : (0:ℝ) ≤ 514147619716779490199856234417204230784802425196644936366761384400 * α ^ 31 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 5) - have h32 : (0:ℝ) ≤ 225918222596880524574644194822909829140432799329070928335788308150 * α ^ 32 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 4) - have h33 : (0:ℝ) ≤ 78378867100425150377346627184325309287549636198734508005978549750 * α ^ 33 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 3) - have h34 : (0:ℝ) ≤ 18415214840638052851390630908893866826964214257262459916509597440 * α ^ 34 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 2) - have h35 : (0:ℝ) ≤ 2542392303855460193752438935467117379253704583645900859266878840 * α ^ 35 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 1) - have h36 : (0:ℝ) ≤ 152938893321252958580549098618153156123487784458433341017459200 * α ^ 36 := - mul_nonneg (by norm_num) (pow_nonneg hα 36) have hid : (17 : ℝ) ^ 36 * (263016241667210021671084890841481617690003189110 + 1586061041777522258785370750920508059260325100670 * α + 4515569002916763022083813591656453793545843463960 * α ^ 2 + 8064535450447153538886731843043227730967854436080 * α ^ 3 + 10124049292126400106014356225197947036232792604485 * α ^ 4 + 9486490487762873429871569630238934346081556621609 * α ^ 5 + 6875502816855646349457849536822502570739478645343 * α ^ 6 + 3940536916491738744952644524802984325688545318839 * α ^ 7 + 1810118648803944257004276579444295893576974412957 * α ^ 8 + 671223601039568220250335587923837679954504671929 * α ^ 9 + 201302327242382412835780103712068254297083069927 * α ^ 10 + 48665320464285286858138805925504857552220130935 * α ^ 11 + 9395447364524194147939717327946455319249576385 * α ^ 12 + 1422463731757903542558687467068487748999154005 * α ^ 13 + 162936488968328754409221779604516446092275015 * α ^ 14 + 12804246766409474561270894860455521523191007 * α ^ 15 + 216069416334011168489825518695466581657549 * α ^ 16 - 808211600142399392096627843592018139890543 * α ^ 17 + 38042736580603120168867477319356142859621 * α ^ 18 + 344373790265831271857444699712655317117 * α ^ 19 + 29315226870352164747186119924985775776 * α ^ 20 + 1247198097855472249813750976434442560 * α ^ 21 + 16662184536264199136681220318869840 * α ^ 22 - 1406905416514864930658623327447840 * α ^ 23 - 115154592405960528415597818779200 * α ^ 24 - 4877945634325956011421670432000 * α ^ 25 - 144681078013665355320791476480 * α ^ 26 - 3249838030348665967746429440 * α ^ 27 - 56982963376184696008104960 * α ^ 28 - 788738718851438284800000 * α ^ 29 - 8618882420705188376576 * α ^ 30 - 73677168662756319232 * α ^ 31 - 483260148118798336 * α ^ 32 - 2351449584959488 * α ^ 33 - 8003806560256 * α ^ 34 - 17023172608 * α ^ 35 - 17039360 * α ^ 36) = 263016241667210021671084890841481617690003189110 * (17 - α) ^ 36 + 36431622410237439179510358835941975244265641519350 * α ^ 1 * (17 - α) ^ 35 + 2414405993950912571012301206016550860739344205122390 * α ^ 2 * (17 - α) ^ 34 + 101911987093790495993891637162656810587351337884854450 * α ^ 3 * (17 - α) ^ 33 + 3077136529375910511818308139163370204204710108135348945 * α ^ 4 * (17 - α) ^ 32 + 70767700416372118022916506935148443513144214212984079433 * α ^ 5 * (17 - α) ^ 31 + 1288872796711775738410766166408400924167189843482363181510 * α ^ 6 * (17 - α) ^ 30 + 19083400748229222868616813579365546608706181811242799713442 * α ^ 7 * (17 - α) ^ 29 + 234010152840381946349380212378698061303021231207480935794380 * α ^ 8 * (17 - α) ^ 28 + 2409083298538233479330794311735295130068631390190510305345916 * α ^ 9 * (17 - α) ^ 27 + 21034199072421691415654588980184171455732743682853035936388736 * α ^ 10 * (17 - α) ^ 26 + 156965739060943279756832920952171731542118382822579555902264320 * α ^ 11 * (17 - α) ^ 25 + 1007013809256349634438976269863634909802444822788284670764336920 * α ^ 12 * (17 - α) ^ 24 + 5578883286717752179555968646363028277131383001091676680613578600 * α ^ 13 * (17 - α) ^ 23 + 26778108682132812026449907006307737451347925518376385819177842180 * α ^ 14 * (17 - α) ^ 22 + 111626866485074002051921408370316196620668741767980677786122726476 * α ^ 15 * (17 - α) ^ 21 + 404749936967515936812332395113162625848731824975287760415129552520 * α ^ 16 * (17 - α) ^ 20 + 1276851853339474854752478301460896841716394369316599334161708835864 * α ^ 17 * (17 - α) ^ 19 + 3498152021559931653758754395800484089136347016702124578632888785870 * α ^ 18 * (17 - α) ^ 18 + 8288489989122825212327334609599909543398390901155522489744660111602 * α ^ 19 * (17 - α) ^ 17 + 16882651085623904442176264117055333605492167285591363946133352298205 * α ^ 20 * (17 - α) ^ 16 + 29353791640642678379569945946711713118769355441603863420459332583845 * α ^ 21 * (17 - α) ^ 15 + 43236117652901827874516888436407546705327794671242323926919339677542 * α ^ 22 * (17 - α) ^ 14 + 53514417120286757722309232459981186747567529389425853874706900031330 * α ^ 23 * (17 - α) ^ 13 + 55160684404854002133844526815694799322288761295220210026216244417256 * α ^ 24 * (17 - α) ^ 12 + 46859199139271497704482066786546595457658791134521569883679868639464 * α ^ 25 * (17 - α) ^ 11 + 32418496139685480362601229821482044096981462148753646754741401291900 * α ^ 26 * (17 - α) ^ 10 + 18064228253690987870059860955691584275196341087334183534685080363332 * α ^ 27 * (17 - α) ^ 9 + 8116057087439008484605418610430390304640800612633036742729214781010 * α ^ 28 * (17 - α) ^ 8 + 3094097281163451800860397134053738271256213921040320763043485148866 * α ^ 29 * (17 - α) ^ 7 + 1174308203032074417716759573429346434013837010515376831055725367856 * α ^ 30 * (17 - α) ^ 6 + 514147619716779490199856234417204230784802425196644936366761384400 * α ^ 31 * (17 - α) ^ 5 + 225918222596880524574644194822909829140432799329070928335788308150 * α ^ 32 * (17 - α) ^ 4 + 78378867100425150377346627184325309287549636198734508005978549750 * α ^ 33 * (17 - α) ^ 3 + 18415214840638052851390630908893866826964214257262459916509597440 * α ^ 34 * (17 - α) ^ 2 + 2542392303855460193752438935467117379253704583645900859266878840 * α ^ 35 * (17 - α) ^ 1 + 152938893321252958580549098618153156123487784458433341017459200 * α ^ 36 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 263016241667210021671084890841481617690003189110 * (17 - α) ^ 36 := - mul_pos (by norm_num) (pow_pos (by linarith) 36) - linarith - · have hpos : (0 : ℝ) < 152938893321252958580549098618153156123487784458433341017459200 * α ^ 36 := - mul_pos (by norm_num) (pow_pos (by linarith) 36) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 36)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree40_41.lean b/Sendov/FiniteRange/Degree40_41.lean index e39615d..d7abd31 100644 --- a/Sendov/FiniteRange/Degree40_41.lean +++ b/Sendov/FiniteRange/Degree40_41.lean @@ -88,93 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 653328533869198792815460418567456328463360027860000 + 4157882298167732116226370617284188848212873011241200 * α + 12532182988010399386002617462745633312768152237121570 * α ^ 2 + 23778313854745445633723704693422676769304621097023060 * α ^ 3 + 31839691004956228828005033576674262680347642949789970 * α ^ 4 + 31966947875077850162540664582127534223677059725715480 * α ^ 5 + 24954452263842718944480719755732872419125467194310990 * α ^ 6 + 15498456398852386516930447507216103141023058978163900 * α ^ 7 + 7770525510255924837049186376423929043180641908035178 * α ^ 8 + 3172282421659051612506049390871943668830947112996128 * α ^ 9 + 1058580212642493803810630674822381941853484677345557 * α ^ 10 + 288603554681274589435804606029301359165948874522986 * α ^ 11 + 63964171378367904791712568423672278670444648520985 * α ^ 12 + 11403554558448059539985445321284291979921951939708 * α ^ 13 + 1604683068013899575897130419685118852646893739688 * α ^ 14 + 171973766788073602692262435759609700705097645552 * α ^ 15 + 12777319017916275759622043304057680904260665896 * α ^ 16 + 232511338229217727198624028718607742301689616 * α ^ 17 - 736152391583269859036039443814447014605197787 * α ^ 18 + 32344027389559443630831441714104468449897746 * α ^ 19 + 226192739078384191702850277844962783099369 * α ^ 20 + 21321388850847068435151126284573459826132 * α ^ 21 + 1002825060545767936823647697965569833484 * α ^ 22 + 20605096429138626101144518690493027136 * α ^ 23 - 588379321688541475027751329888140192 * α ^ 24 - 68916522458163479393324809629479808 * α ^ 25 - 3219999749177967431080752136593024 * α ^ 26 - 101984865798504570834320095942656 * α ^ 27 - 2433981075208899701339322164736 * α ^ 28 - 45526079756647968714698102784 * α ^ 29 - 678401876172921453922277376 * α ^ 30 - 8091691517611230731255808 * α ^ 31 - 76978691001245722632192 * α ^ 32 - 577480811034021101568 * α ^ 33 - 3345672064015171584 * α ^ 34 - 14456978064408576 * α ^ 35 - 43900332474368 * α ^ 36 - 83629441024 * α ^ 37 - 75235328 * α ^ 38 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 653328533869198792815460418567456328463360027860000 * (17 - α) ^ 38 := - mul_nonneg (by norm_num) (pow_nonneg hu 38) - have h1 : (0:ℝ) ≤ 95510483355881000102835796399394550901226522249780400 * α ^ 1 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 37) - have h2 : (0:ℝ) ≤ 6696398808392555675010412239258164611825635220184428530 * α ^ 2 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 36) - have h3 : (0:ℝ) ≤ 299794710667200193646561985461117827680016512752986934460 * α ^ 3 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 35) - have h4 : (0:ℝ) ≤ 9627257466437286352224279116990630228292750401872068624570 * α ^ 4 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 34) - have h5 : (0:ℝ) ≤ 236169626370579092102401540068424043031156213235832488824240 * α ^ 5 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 33) - have h6 : (0:ℝ) ≤ 4602580155935131911540977878848744873896752358859535239239310 * α ^ 6 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 32) - have h7 : (0:ℝ) ≤ 73167568636523068791230387895812989143995323139339741955173340 * α ^ 7 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 31) - have h8 : (0:ℝ) ≤ 966819100697307203780359917617580768148731765217116962982472158 * α ^ 8 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 30) - have h9 : (0:ℝ) ≤ 10767130098246849195301111459928119363029994766661588897784000776 * α ^ 9 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 29) - have h10 : (0:ℝ) ≤ 102122724502527454683682344439666460359467859469480457468195144927 * α ^ 10 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 28) - have h11 : (0:ℝ) ≤ 831548691595541121952529230262845541710942265958095940858036487578 * α ^ 11 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 27) - have h12 : (0:ℝ) ≤ 5848940149873603781228937217250745230319503456527981662700527649479 * α ^ 12 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 26) - have h13 : (0:ℝ) ≤ 35707752760626549856948044943531072922885702324271579224065621550616 * α ^ 13 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 25) - have h14 : (0:ℝ) ≤ 189904423378547635211179836338153464631558375737888355414680794292332 * α ^ 14 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 24) - have h15 : (0:ℝ) ≤ 882263986278123132234428133435096956146433318787491830406424008581944 * α ^ 15 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 23) - have h16 : (0:ℝ) ≤ 3587848295098893896231452077434369033403531934780731646206410657559996 * α ^ 16 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 22) - have h17 : (0:ℝ) ≤ 12789017524790293159146747559828714620914231030244750348653705133535680 * α ^ 17 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 21) - have h18 : (0:ℝ) ≤ 39978318616507844028720464128037031241214473591909362382585304014435338 * α ^ 18 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 20) - have h19 : (0:ℝ) ≤ 109503304419314521695778687533175441622403892877574691241529360322168236 * α ^ 19 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 19) - have h20 : (0:ℝ) ≤ 262146994169564092167982595241915300650038077337630821023247107830038522 * α ^ 20 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 18) - have h21 : (0:ℝ) ≤ 546246295187027447378330498619919154502317914469485801874390148357919248 * α ^ 21 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 17) - have h22 : (0:ℝ) ≤ 985534144714139122250483741567233765101065359192115038605404874832119258 * α ^ 22 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 16) - have h23 : (0:ℝ) ≤ 1530417579360385957788702153622880731287836667255896423677766156573103972 * α ^ 23 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 15) - have h24 : (0:ℝ) ≤ 2032430461020079853532514261208602767750794542173780707088682857868910994 * α ^ 24 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 14) - have h25 : (0:ℝ) ≤ 2292218444285680589433098519469973212042230727005845801142745772952622648 * α ^ 25 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 13) - have h26 : (0:ℝ) ≤ 2178219997541878792508669700595426088654476354491195218415916040098361367 * α ^ 26 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 12) - have h27 : (0:ℝ) ≤ 1727949063757596178243483752801428201813213932341449769191552685893782458 * α ^ 27 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 11) - have h28 : (0:ℝ) ≤ 1131913488897144192892030857095843493930963307289300925015925127269708335 * α ^ 28 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 10) - have h29 : (0:ℝ) ≤ 605118754195259451063140144378285109492445949756638818759841365239660040 * α ^ 29 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 9) - have h30 : (0:ℝ) ≤ 261880298008050145266750753761576086552682439953827145257817540609824860 * α ^ 30 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 8) - have h31 : (0:ℝ) ≤ 92875679601113717412714391333499851806464327195844345337907650773348120 * α ^ 31 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 7) - have h32 : (0:ℝ) ≤ 29072995044312488455979921670033751326475480533216429941625836322969708 * α ^ 32 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 6) - have h33 : (0:ℝ) ≤ 9369857362358365457781039003340826933535211191808499527159369766606160 * α ^ 33 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 5) - have h34 : (0:ℝ) ≤ 3266469696161126128466003284878933770066029563371692346986063283168790 * α ^ 34 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 4) - have h35 : (0:ℝ) ≤ 1021356923480101951479641774555034890704687659508130011121545901779380 * α ^ 35 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 3) - have h36 : (0:ℝ) ≤ 230938112747876039693246783422362329462732319382520584715540384755870 * α ^ 36 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 2) - have h37 : (0:ℝ) ≤ 31563581230674524529692712927313637685716918468331288776448654765600 * α ^ 37 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 1) - have h38 : (0:ℝ) ≤ 1919753133109689509058670629650134022172078593720565270277159571400 * α ^ 38 := - mul_nonneg (by norm_num) (pow_nonneg hα 38) have hid : (17 : ℝ) ^ 38 * (653328533869198792815460418567456328463360027860000 + 4157882298167732116226370617284188848212873011241200 * α + 12532182988010399386002617462745633312768152237121570 * α ^ 2 + 23778313854745445633723704693422676769304621097023060 * α ^ 3 + 31839691004956228828005033576674262680347642949789970 * α ^ 4 + 31966947875077850162540664582127534223677059725715480 * α ^ 5 + 24954452263842718944480719755732872419125467194310990 * α ^ 6 + 15498456398852386516930447507216103141023058978163900 * α ^ 7 + 7770525510255924837049186376423929043180641908035178 * α ^ 8 + 3172282421659051612506049390871943668830947112996128 * α ^ 9 + 1058580212642493803810630674822381941853484677345557 * α ^ 10 + 288603554681274589435804606029301359165948874522986 * α ^ 11 + 63964171378367904791712568423672278670444648520985 * α ^ 12 + 11403554558448059539985445321284291979921951939708 * α ^ 13 + 1604683068013899575897130419685118852646893739688 * α ^ 14 + 171973766788073602692262435759609700705097645552 * α ^ 15 + 12777319017916275759622043304057680904260665896 * α ^ 16 + 232511338229217727198624028718607742301689616 * α ^ 17 - 736152391583269859036039443814447014605197787 * α ^ 18 + 32344027389559443630831441714104468449897746 * α ^ 19 + 226192739078384191702850277844962783099369 * α ^ 20 + 21321388850847068435151126284573459826132 * α ^ 21 + 1002825060545767936823647697965569833484 * α ^ 22 + 20605096429138626101144518690493027136 * α ^ 23 - 588379321688541475027751329888140192 * α ^ 24 - 68916522458163479393324809629479808 * α ^ 25 - 3219999749177967431080752136593024 * α ^ 26 - 101984865798504570834320095942656 * α ^ 27 - 2433981075208899701339322164736 * α ^ 28 - 45526079756647968714698102784 * α ^ 29 - 678401876172921453922277376 * α ^ 30 - 8091691517611230731255808 * α ^ 31 - 76978691001245722632192 * α ^ 32 - 577480811034021101568 * α ^ 33 - 3345672064015171584 * α ^ 34 - 14456978064408576 * α ^ 35 - 43900332474368 * α ^ 36 - 83629441024 * α ^ 37 - 75235328 * α ^ 38) = 653328533869198792815460418567456328463360027860000 * (17 - α) ^ 38 + 95510483355881000102835796399394550901226522249780400 * α ^ 1 * (17 - α) ^ 37 + 6696398808392555675010412239258164611825635220184428530 * α ^ 2 * (17 - α) ^ 36 + 299794710667200193646561985461117827680016512752986934460 * α ^ 3 * (17 - α) ^ 35 + 9627257466437286352224279116990630228292750401872068624570 * α ^ 4 * (17 - α) ^ 34 + 236169626370579092102401540068424043031156213235832488824240 * α ^ 5 * (17 - α) ^ 33 + 4602580155935131911540977878848744873896752358859535239239310 * α ^ 6 * (17 - α) ^ 32 + 73167568636523068791230387895812989143995323139339741955173340 * α ^ 7 * (17 - α) ^ 31 + 966819100697307203780359917617580768148731765217116962982472158 * α ^ 8 * (17 - α) ^ 30 + 10767130098246849195301111459928119363029994766661588897784000776 * α ^ 9 * (17 - α) ^ 29 + 102122724502527454683682344439666460359467859469480457468195144927 * α ^ 10 * (17 - α) ^ 28 + 831548691595541121952529230262845541710942265958095940858036487578 * α ^ 11 * (17 - α) ^ 27 + 5848940149873603781228937217250745230319503456527981662700527649479 * α ^ 12 * (17 - α) ^ 26 + 35707752760626549856948044943531072922885702324271579224065621550616 * α ^ 13 * (17 - α) ^ 25 + 189904423378547635211179836338153464631558375737888355414680794292332 * α ^ 14 * (17 - α) ^ 24 + 882263986278123132234428133435096956146433318787491830406424008581944 * α ^ 15 * (17 - α) ^ 23 + 3587848295098893896231452077434369033403531934780731646206410657559996 * α ^ 16 * (17 - α) ^ 22 + 12789017524790293159146747559828714620914231030244750348653705133535680 * α ^ 17 * (17 - α) ^ 21 + 39978318616507844028720464128037031241214473591909362382585304014435338 * α ^ 18 * (17 - α) ^ 20 + 109503304419314521695778687533175441622403892877574691241529360322168236 * α ^ 19 * (17 - α) ^ 19 + 262146994169564092167982595241915300650038077337630821023247107830038522 * α ^ 20 * (17 - α) ^ 18 + 546246295187027447378330498619919154502317914469485801874390148357919248 * α ^ 21 * (17 - α) ^ 17 + 985534144714139122250483741567233765101065359192115038605404874832119258 * α ^ 22 * (17 - α) ^ 16 + 1530417579360385957788702153622880731287836667255896423677766156573103972 * α ^ 23 * (17 - α) ^ 15 + 2032430461020079853532514261208602767750794542173780707088682857868910994 * α ^ 24 * (17 - α) ^ 14 + 2292218444285680589433098519469973212042230727005845801142745772952622648 * α ^ 25 * (17 - α) ^ 13 + 2178219997541878792508669700595426088654476354491195218415916040098361367 * α ^ 26 * (17 - α) ^ 12 + 1727949063757596178243483752801428201813213932341449769191552685893782458 * α ^ 27 * (17 - α) ^ 11 + 1131913488897144192892030857095843493930963307289300925015925127269708335 * α ^ 28 * (17 - α) ^ 10 + 605118754195259451063140144378285109492445949756638818759841365239660040 * α ^ 29 * (17 - α) ^ 9 + 261880298008050145266750753761576086552682439953827145257817540609824860 * α ^ 30 * (17 - α) ^ 8 + 92875679601113717412714391333499851806464327195844345337907650773348120 * α ^ 31 * (17 - α) ^ 7 + 29072995044312488455979921670033751326475480533216429941625836322969708 * α ^ 32 * (17 - α) ^ 6 + 9369857362358365457781039003340826933535211191808499527159369766606160 * α ^ 33 * (17 - α) ^ 5 + 3266469696161126128466003284878933770066029563371692346986063283168790 * α ^ 34 * (17 - α) ^ 4 + 1021356923480101951479641774555034890704687659508130011121545901779380 * α ^ 35 * (17 - α) ^ 3 + 230938112747876039693246783422362329462732319382520584715540384755870 * α ^ 36 * (17 - α) ^ 2 + 31563581230674524529692712927313637685716918468331288776448654765600 * α ^ 37 * (17 - α) ^ 1 + 1919753133109689509058670629650134022172078593720565270277159571400 * α ^ 38 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 653328533869198792815460418567456328463360027860000 * (17 - α) ^ 38 := - mul_pos (by norm_num) (pow_pos (by linarith) 38) - linarith - · have hpos : (0 : ℝ) < 1919753133109689509058670629650134022172078593720565270277159571400 * α ^ 38 := - mul_pos (by norm_num) (pow_pos (by linarith) 38) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 38)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree42_43.lean b/Sendov/FiniteRange/Degree42_43.lean index 60c503f..eefe264 100644 --- a/Sendov/FiniteRange/Degree42_43.lean +++ b/Sendov/FiniteRange/Degree42_43.lean @@ -88,97 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 1280928413415314397834869540387070773955050164531041030 + 8579596886133703000731870831081948314922065693350883370 * α + 27292297105154921952287403075281892231896279402880100950 * α ^ 2 + 54824009941858550176912358984664841592247597016637905770 * α ^ 3 + 77993650469489645959523814188253045468476206212378807150 * α ^ 4 + 83524935090318289329452750100125758268073947901595075110 * α ^ 5 + 69864044339248988241671793073316243248508325653371578960 * α ^ 6 + 46735744905970337877740011413866843308996677044757141876 * α ^ 7 + 25392412342651970229153408582081225972535817324636108157 * α ^ 8 + 11314456845720888558092495939704512751963595258860145451 * α ^ 9 + 4156583831931947231874280330967249614130082308880369711 * α ^ 10 + 1260841374442113914894353137980805411382131606623222097 * α ^ 11 + 315103088046242389807187425423229491723179974811052320 * α ^ 12 + 64474796856269342035203905269807575254628539228620830 * α ^ 13 + 10677851103479065036063092086580878016800993639429844 * α ^ 14 + 1403715274370741006129430385190458757679221958797478 * α ^ 15 + 141371440744366093378881819780110077583832470458881 * α ^ 16 + 9967433380699679025437124999852577310642665327515 * α ^ 17 + 193067019640064558163668388981876117360705214251 * α ^ 18 - 526348205714148288340590540843861549545919252135 * α ^ 19 + 21747004181067783415574645835305370950903835816 * α ^ 20 + 112680245244072016728446540389593488784136590 * α ^ 21 + 11981738273725154350817268365041623637172994 * α ^ 22 + 613973728602142293085684365363276715529976 * α ^ 23 + 15948973394297291153786386954935347707464 * α ^ 24 - 107684213318232680083685034683113736832 * α ^ 25 - 31027964293347059199661593149947343808 * α ^ 26 - 1633467609886255958992085630289238016 * α ^ 27 - 55350060514047685232072125284311296 * α ^ 28 - 1399005645314407761350477999499264 * α ^ 29 - 27739113827411317709592921773056 * α ^ 30 - 440917774047260414297889849344 * α ^ 31 - 5667329623457291353154629632 * α ^ 32 - 58939961119748330433282048 * α ^ 33 - 492976521437911894081536 * α ^ 34 - 3273203375389549068288 * α ^ 35 - 16876898137105432576 * α ^ 36 - 65205684590477312 * α ^ 37 - 177752858296320 * α ^ 38 - 305048059904 * α ^ 39 - 247988224 * α ^ 40 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 1280928413415314397834869540387070773955050164531041030 * (17 - α) ^ 40 := - mul_nonneg (by norm_num) (pow_nonneg hu 40) - have h1 : (0:ℝ) ≤ 197090283600885526925836585743875952311877123368206658490 * α ^ 1 * (17 - α) ^ 39 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 39) - have h2 : (0:ℝ) ≤ 14574870761360362764007488091265713791496293430458196852260 * α ^ 2 * (17 - α) ^ 38 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 38) - have h3 : (0:ℝ) ≤ 689807122352331972850018568182567669403146541709879062869200 * α ^ 3 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 37) - have h4 : (0:ℝ) ≤ 23474981116788659940295903209229597513213621976643052103205180 * α ^ 4 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 36) - have h5 : (0:ℝ) ≤ 611866838450106888263269653882018737667714606579935222429231160 * α ^ 5 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 35) - have h6 : (0:ℝ) ≤ 12704966108874081414158869474590380254978128823530400951437383070 * α ^ 6 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 34) - have h7 : (0:ℝ) ≤ 215835205701475999098573854286109430455663338527171355584817462378 * α ^ 7 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 33) - have h8 : (0:ℝ) ≤ 3057463015648964051048726715818912718934404644565989436353377379661 * α ^ 8 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 32) - have h9 : (0:ℝ) ≤ 36627145478607558025819186137856364423514446441125420313957605902195 * α ^ 9 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 31) - have h10 : (0:ℝ) ≤ 375047859308149340518089344648422780629330440775991914316145068984356 * α ^ 10 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 30) - have h11 : (0:ℝ) ≤ 3309722847734299600989754701031358954177490834341008198660668294423486 * α ^ 11 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 29) - have h12 : (0:ℝ) ≤ 25334280905778547167991484601858053756995044929407956045911106763735047 * α ^ 12 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 28) - have h13 : (0:ℝ) ≤ 169053231472854221672538042658045160250622512820809581036739296186604987 * α ^ 13 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 27) - have h14 : (0:ℝ) ≤ 987295696101506016750123997135936935428967974131049275929891243289099020 * α ^ 14 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 26) - have h15 : (0:ℝ) ≤ 5061855600544715172298535944485508872496786942997547092399772690908724552 * α ^ 15 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 25) - have h16 : (0:ℝ) ≤ 22836459878606542127997069590698683872398300158025332179037971805498008466 * α ^ 16 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 24) - have h17 : (0:ℝ) ≤ 90815511641941473829215661492687510352960775737402151799341783414491782134 * α ^ 17 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 23) - have h18 : (0:ℝ) ≤ 318734183329134027469187419914043420985326381868548104315467322483762890280 * α ^ 18 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 22) - have h19 : (0:ℝ) ≤ 987849647539835196212635720362290798791340169209853062676349181616504012372 * α ^ 19 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 21) - have h20 : (0:ℝ) ≤ 2702794013053376717386235575702898281842016607777011413996179654284315020276 * α ^ 20 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 20) - have h21 : (0:ℝ) ≤ 6518481722287093687872286675516248686966900062551161802625983585543325193064 * α ^ 21 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 19) - have h22 : (0:ℝ) ≤ 13819577825963737277443482404663949106919306450306673694620269914296761836662 * α ^ 22 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 18) - have h23 : (0:ℝ) ≤ 25656213473396052436767203417861850495715135024347044339699650611836313451386 * α ^ 23 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 17) - have h24 : (0:ℝ) ≤ 41518212269954562717893522706197113635871186246049005811923337699275786209441 * α ^ 24 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 16) - have h25 : (0:ℝ) ≤ 58264237368783003337224503745095851911428895082867699051272864692889281810823 * α ^ 25 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 15) - have h26 : (0:ℝ) ≤ 70509961613749498938328718833682422186993284582226371629980357718310864201564 * α ^ 26 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 14) - have h27 : (0:ℝ) ≤ 73129293701134101287464321060861793455351594458440621340710860077426859412246 * α ^ 27 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 13) - have h28 : (0:ℝ) ≤ 64542036519874264738723665643239022405337439766598405390089713472010764525231 * α ^ 28 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 12) - have h29 : (0:ℝ) ≤ 48068721003017849550137162829500406726021869001249651041646233420511089834739 * α ^ 29 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 11) - have h30 : (0:ℝ) ≤ 29908472648708029501911019147420406642840298425192025295010509794183714590200 * α ^ 30 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 10) - have h31 : (0:ℝ) ≤ 15366480688785955559510007565183167290828149965129842034139827497171629495988 * α ^ 31 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 9) - have h32 : (0:ℝ) ≤ 6442852602434353997138149389259641709926610254417225973756279884877273521210 * α ^ 32 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 8) - have h33 : (0:ℝ) ≤ 2192109403287939599157040147405748715444730026475711367949290093543157305286 * α ^ 33 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 7) - have h34 : (0:ℝ) ≤ 617553044098254770008870419213467265211621023542309177891008000912439731428 * α ^ 34 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 6) - have h35 : (0:ℝ) ≤ 156511669279787056670653626987150971088769146525896634427590110835904143048 * α ^ 35 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 5) - have h36 : (0:ℝ) ≤ 40425174529035112350411546621406361023805738975780328231031555794395201242 * α ^ 36 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 4) - have h37 : (0:ℝ) ≤ 10426184083634003349248930440636043818034523209966796671645165924159912258 * α ^ 37 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 3) - have h38 : (0:ℝ) ≤ 2178083492795567226675987694618231233066113322011885814782838606188228664 * α ^ 38 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 38)) (pow_nonneg hu 2) - have h39 : (0:ℝ) ≤ 290493393201934314395217100992245864671975635874035159763234167124538720 * α ^ 39 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 39)) (pow_nonneg hu 1) - have h40 : (0:ℝ) ≤ 17674868145691221378279476901019271057432085542810612311003098402179200 * α ^ 40 := - mul_nonneg (by norm_num) (pow_nonneg hα 40) have hid : (17 : ℝ) ^ 40 * (1280928413415314397834869540387070773955050164531041030 + 8579596886133703000731870831081948314922065693350883370 * α + 27292297105154921952287403075281892231896279402880100950 * α ^ 2 + 54824009941858550176912358984664841592247597016637905770 * α ^ 3 + 77993650469489645959523814188253045468476206212378807150 * α ^ 4 + 83524935090318289329452750100125758268073947901595075110 * α ^ 5 + 69864044339248988241671793073316243248508325653371578960 * α ^ 6 + 46735744905970337877740011413866843308996677044757141876 * α ^ 7 + 25392412342651970229153408582081225972535817324636108157 * α ^ 8 + 11314456845720888558092495939704512751963595258860145451 * α ^ 9 + 4156583831931947231874280330967249614130082308880369711 * α ^ 10 + 1260841374442113914894353137980805411382131606623222097 * α ^ 11 + 315103088046242389807187425423229491723179974811052320 * α ^ 12 + 64474796856269342035203905269807575254628539228620830 * α ^ 13 + 10677851103479065036063092086580878016800993639429844 * α ^ 14 + 1403715274370741006129430385190458757679221958797478 * α ^ 15 + 141371440744366093378881819780110077583832470458881 * α ^ 16 + 9967433380699679025437124999852577310642665327515 * α ^ 17 + 193067019640064558163668388981876117360705214251 * α ^ 18 - 526348205714148288340590540843861549545919252135 * α ^ 19 + 21747004181067783415574645835305370950903835816 * α ^ 20 + 112680245244072016728446540389593488784136590 * α ^ 21 + 11981738273725154350817268365041623637172994 * α ^ 22 + 613973728602142293085684365363276715529976 * α ^ 23 + 15948973394297291153786386954935347707464 * α ^ 24 - 107684213318232680083685034683113736832 * α ^ 25 - 31027964293347059199661593149947343808 * α ^ 26 - 1633467609886255958992085630289238016 * α ^ 27 - 55350060514047685232072125284311296 * α ^ 28 - 1399005645314407761350477999499264 * α ^ 29 - 27739113827411317709592921773056 * α ^ 30 - 440917774047260414297889849344 * α ^ 31 - 5667329623457291353154629632 * α ^ 32 - 58939961119748330433282048 * α ^ 33 - 492976521437911894081536 * α ^ 34 - 3273203375389549068288 * α ^ 35 - 16876898137105432576 * α ^ 36 - 65205684590477312 * α ^ 37 - 177752858296320 * α ^ 38 - 305048059904 * α ^ 39 - 247988224 * α ^ 40) = 1280928413415314397834869540387070773955050164531041030 * (17 - α) ^ 40 + 197090283600885526925836585743875952311877123368206658490 * α ^ 1 * (17 - α) ^ 39 + 14574870761360362764007488091265713791496293430458196852260 * α ^ 2 * (17 - α) ^ 38 + 689807122352331972850018568182567669403146541709879062869200 * α ^ 3 * (17 - α) ^ 37 + 23474981116788659940295903209229597513213621976643052103205180 * α ^ 4 * (17 - α) ^ 36 + 611866838450106888263269653882018737667714606579935222429231160 * α ^ 5 * (17 - α) ^ 35 + 12704966108874081414158869474590380254978128823530400951437383070 * α ^ 6 * (17 - α) ^ 34 + 215835205701475999098573854286109430455663338527171355584817462378 * α ^ 7 * (17 - α) ^ 33 + 3057463015648964051048726715818912718934404644565989436353377379661 * α ^ 8 * (17 - α) ^ 32 + 36627145478607558025819186137856364423514446441125420313957605902195 * α ^ 9 * (17 - α) ^ 31 + 375047859308149340518089344648422780629330440775991914316145068984356 * α ^ 10 * (17 - α) ^ 30 + 3309722847734299600989754701031358954177490834341008198660668294423486 * α ^ 11 * (17 - α) ^ 29 + 25334280905778547167991484601858053756995044929407956045911106763735047 * α ^ 12 * (17 - α) ^ 28 + 169053231472854221672538042658045160250622512820809581036739296186604987 * α ^ 13 * (17 - α) ^ 27 + 987295696101506016750123997135936935428967974131049275929891243289099020 * α ^ 14 * (17 - α) ^ 26 + 5061855600544715172298535944485508872496786942997547092399772690908724552 * α ^ 15 * (17 - α) ^ 25 + 22836459878606542127997069590698683872398300158025332179037971805498008466 * α ^ 16 * (17 - α) ^ 24 + 90815511641941473829215661492687510352960775737402151799341783414491782134 * α ^ 17 * (17 - α) ^ 23 + 318734183329134027469187419914043420985326381868548104315467322483762890280 * α ^ 18 * (17 - α) ^ 22 + 987849647539835196212635720362290798791340169209853062676349181616504012372 * α ^ 19 * (17 - α) ^ 21 + 2702794013053376717386235575702898281842016607777011413996179654284315020276 * α ^ 20 * (17 - α) ^ 20 + 6518481722287093687872286675516248686966900062551161802625983585543325193064 * α ^ 21 * (17 - α) ^ 19 + 13819577825963737277443482404663949106919306450306673694620269914296761836662 * α ^ 22 * (17 - α) ^ 18 + 25656213473396052436767203417861850495715135024347044339699650611836313451386 * α ^ 23 * (17 - α) ^ 17 + 41518212269954562717893522706197113635871186246049005811923337699275786209441 * α ^ 24 * (17 - α) ^ 16 + 58264237368783003337224503745095851911428895082867699051272864692889281810823 * α ^ 25 * (17 - α) ^ 15 + 70509961613749498938328718833682422186993284582226371629980357718310864201564 * α ^ 26 * (17 - α) ^ 14 + 73129293701134101287464321060861793455351594458440621340710860077426859412246 * α ^ 27 * (17 - α) ^ 13 + 64542036519874264738723665643239022405337439766598405390089713472010764525231 * α ^ 28 * (17 - α) ^ 12 + 48068721003017849550137162829500406726021869001249651041646233420511089834739 * α ^ 29 * (17 - α) ^ 11 + 29908472648708029501911019147420406642840298425192025295010509794183714590200 * α ^ 30 * (17 - α) ^ 10 + 15366480688785955559510007565183167290828149965129842034139827497171629495988 * α ^ 31 * (17 - α) ^ 9 + 6442852602434353997138149389259641709926610254417225973756279884877273521210 * α ^ 32 * (17 - α) ^ 8 + 2192109403287939599157040147405748715444730026475711367949290093543157305286 * α ^ 33 * (17 - α) ^ 7 + 617553044098254770008870419213467265211621023542309177891008000912439731428 * α ^ 34 * (17 - α) ^ 6 + 156511669279787056670653626987150971088769146525896634427590110835904143048 * α ^ 35 * (17 - α) ^ 5 + 40425174529035112350411546621406361023805738975780328231031555794395201242 * α ^ 36 * (17 - α) ^ 4 + 10426184083634003349248930440636043818034523209966796671645165924159912258 * α ^ 37 * (17 - α) ^ 3 + 2178083492795567226675987694618231233066113322011885814782838606188228664 * α ^ 38 * (17 - α) ^ 2 + 290493393201934314395217100992245864671975635874035159763234167124538720 * α ^ 39 * (17 - α) ^ 1 + 17674868145691221378279476901019271057432085542810612311003098402179200 * α ^ 40 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 1280928413415314397834869540387070773955050164531041030 * (17 - α) ^ 40 := - mul_pos (by norm_num) (pow_pos (by linarith) 40) - linarith - · have hpos : (0 : ℝ) < 17674868145691221378279476901019271057432085542810612311003098402179200 * α ^ 40 := - mul_pos (by norm_num) (pow_pos (by linarith) 40) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 40)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree44_45.lean b/Sendov/FiniteRange/Degree44_45.lean index a2b26a6..ed88b9c 100644 --- a/Sendov/FiniteRange/Degree44_45.lean +++ b/Sendov/FiniteRange/Degree44_45.lean @@ -88,101 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 234355849074955263951049856572420428528087559257217338000 + 1647917825991745087828090979449220009324402935342213794192 * α + 5517259206635462357799308151379743852022400880405143709300 * α ^ 2 + 11697286850057325472448884282596125036178461096427071180160 * α ^ 3 + 17618194225546020573784427664650585416610740635319786403400 * α ^ 4 + 20046068608053045224231426681510601856273741292025591141480 * α ^ 5 + 17885461556571898483672892064956643539473640662999345701666 * α ^ 6 + 12820152657712533249363000294926617606868677915971896670240 * α ^ 7 + 7502523555651917287805352494007861019866814933742609160696 * α ^ 8 + 3622686298843516098851206612510488687148684155393129482472 * α ^ 9 + 1452571052316260978855070270500133585694231422375833061090 * α ^ 10 + 485064610274304784360415817487598469472479148412401415808 * α ^ 11 + 134868827326575807784515799657395435527619954194004227748 * α ^ 12 + 31113923159253038634767916248106358904477281041358348956 * α ^ 13 + 5912609861703141760519754094833940739302488844248812479 * α ^ 14 + 914297729950293095944937323513702712183136890515661088 * α ^ 15 + 112786258002906693411402876201621614411462995639363644 * α ^ 16 + 10715561597079704979556413609803278787797162405942296 * α ^ 17 + 719193622230655390355126847425184862615908011115060 * α ^ 18 + 14657836127065470780938993503699490899434597229512 * α ^ 19 - 34950338977013178639767569738567864677193896372240 * α ^ 20 + 1366801847725067991778952117668601561839569590900 * α ^ 21 + 4959220152208557382027853908303681091859164175 * α ^ 22 + 615471404273198116343750989411396892897296680 * α ^ 23 + 34101039377472481958974903669374217452733632 * α ^ 24 + 1034386808344405409707750019488517511355008 * α ^ 25 + 5291527796743143896670464285156657893296 * α ^ 26 - 1219504316386418556368987826914293621248 * α ^ 27 - 75185184777106907253176174218461272832 * α ^ 28 - 2739147805326680629369630717760523264 * α ^ 29 - 73210280752772515350101169959614464 * α ^ 30 - 1531828473996677645738094611644416 * α ^ 31 - 25792432980458262033466819153920 * α ^ 32 - 353823743440056079889063264256 * α ^ 33 - 3970096169377863374039531520 * α ^ 34 - 36356947826301657371639808 * α ^ 35 - 269616704004970519658496 * α ^ 36 - 1596209219881105096704 * α ^ 37 - 7373431975900938240 * α ^ 38 - 25626639771107328 * α ^ 39 - 63065268682752 * α ^ 40 - 98008301568 * α ^ 41 - 72351744 * α ^ 42 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 234355849074955263951049856572420428528087559257217338000 * (17 - α) ^ 42 := - mul_nonneg (by norm_num) (pow_nonneg hu 42) - have h1 : (0:ℝ) ≤ 37857548703007787579021640626678398156694527389620762697264 * α ^ 1 * (17 - α) ^ 41 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 41) - have h2 : (0:ℝ) ≤ 2944867021487431429882033394933706308696266088891073674557524 * α ^ 2 * (17 - α) ^ 40 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 40) - have h3 : (0:ℝ) ≤ 146910666364742997856783011317318114681608355643172977318910560 * α ^ 3 * (17 - α) ^ 39 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 39) - have h4 : (0:ℝ) ≤ 5281338930363712858347930254940637802165598810816949523191508760 * α ^ 4 * (17 - α) ^ 38 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 38) - have h5 : (0:ℝ) ≤ 145753437649734017761868379170413156812750014126479617274091172120 * α ^ 5 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 37) - have h6 : (0:ℝ) ≤ 3212433660877561136639288711614882650266994711330586733979437268666 * α ^ 6 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 36) - have h7 : (0:ℝ) ≤ 58080099103816679194960077966232290827409612456400212654077549294136 * α ^ 7 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 35) - have h8 : (0:ℝ) ≤ 878073000124467105754351061548458968812316660181611332798436479232076 * α ^ 8 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 34) - have h9 : (0:ℝ) ≤ 11259922048324651489289493311309309631891001644523667321376037356186888 * α ^ 9 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 33) - have h10 : (0:ℝ) ≤ 123812154859041152773858816918455744865935561732076455885319152132304488 * α ^ 10 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 32) - have h11 : (0:ℝ) ≤ 1177282729304429087196944522508776379491442707108602485795557386562286720 * α ^ 11 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 31) - have h12 : (0:ℝ) ≤ 9744718648999432569661305582435950678261853364124701152000275689844790852 * α ^ 12 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 30) - have h13 : (0:ℝ) ≤ 70584478999572099526210718832986814594230665767170003296124002517210218548 * α ^ 13 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 29) - have h14 : (0:ℝ) ≤ 449272053601042666671596079622675645227192899930246481044206503873022598127 * α ^ 14 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 28) - have h15 : (0:ℝ) ≤ 2521166194604692753878031098107876914463687672229082966575780993950448786492 * α ^ 15 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 27) - have h16 : (0:ℝ) ≤ 12505743633148390302761257035504316007036914113543301212072536616680265609966 * α ^ 16 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 26) - have h17 : (0:ℝ) ≤ 54941752319236926994034527846178330055107665824491889262114770438776772080688 * α ^ 17 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 25) - have h18 : (0:ℝ) ≤ 214108133336419833203656668659528095997912595237383503399365023725947428991765 * α ^ 18 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 24) - have h19 : (0:ℝ) ≤ 740907981283804161674373017608569262860463894016142577208923888370995315389936 * α ^ 19 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 23) - have h20 : (0:ℝ) ≤ 2278016136661934557373907941895735701975033136406032948359780173720186398978768 * α ^ 20 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 22) - have h21 : (0:ℝ) ≤ 6223044015900732285273426821948491350903940514086744466166738234457122088918648 * α ^ 21 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 21) - have h22 : (0:ℝ) ≤ 15091573130026048461544325185690904741676446061897994842743984569608882476868246 * α ^ 22 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 20) - have h23 : (0:ℝ) ≤ 32431472815063210198529045051946172792892281829735717630866526639188278809402520 * α ^ 23 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 19) - have h24 : (0:ℝ) ≤ 61589977160019028252201500272191461481719309803518295921163839432202796081677436 * α ^ 24 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 18) - have h25 : (0:ℝ) ≤ 103000834533491129063640284036092678067268542010637673258239410761540957030115384 * α ^ 25 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 17) - have h26 : (0:ℝ) ≤ 151071516679099175443820464035839365942459349434188215403085360254317550609833028 * α ^ 26 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 16) - have h27 : (0:ℝ) ≤ 193445346233280859296440806414848722181948957409609959791787404726401564917282096 * α ^ 27 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 15) - have h28 : (0:ℝ) ≤ 215172096945268414340053333093031776453400001175778749956470312358926404221592428 * α ^ 28 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 14) - have h29 : (0:ℝ) ≤ 206736790098352378662725797487880027357919714030453368776992727928497863099548756 * α ^ 29 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 13) - have h30 : (0:ℝ) ≤ 170462524827332695320086649521380810293612989490733605162878601757384672794284747 * α ^ 30 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 12) - have h31 : (0:ℝ) ≤ 119693210823537512228591503646550664793242492067851215311990782497984104429398428 * α ^ 31 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 11) - have h32 : (0:ℝ) ≤ 70908831093339465886818052612765873755388314931239009902767176459421394442785742 * α ^ 32 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 10) - have h33 : (0:ℝ) ≤ 35048237403311100028743507259452310464158209931947679191434306115144076602284800 * α ^ 33 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 9) - have h34 : (0:ℝ) ≤ 14268450259765073448679759926668655504802778135164107658390044566561421617189673 * α ^ 34 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 8) - have h35 : (0:ℝ) ≤ 4724185205300768110792705712599630650015863880955341087853206634323491488643616 * α ^ 35 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 7) - have h36 : (0:ℝ) ≤ 1265299135971789660909673234797601828374717278246484983747256160401664255750872 * α ^ 36 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 6) - have h37 : (0:ℝ) ≤ 280178539570804945484739775418806390334413870080009334057823189831955617940552 * α ^ 37 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 5) - have h38 : (0:ℝ) ≤ 55439566906689638975335374901816806066147146428085261656377329665751391494454 * α ^ 38 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 38)) (pow_nonneg hu 4) - have h39 : (0:ℝ) ≤ 10724868311110483392855160615399587116240195810586300982060213202048731748152 * α ^ 39 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 39)) (pow_nonneg hu 3) - have h40 : (0:ℝ) ≤ 1891608447746568174857958621996992326295338311284555046921110287910697380220 * α ^ 40 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 40)) (pow_nonneg hu 2) - have h41 : (0:ℝ) ≤ 236532288128129299669916971619583813438473071647279968567818223819695392000 * α ^ 41 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 41)) (pow_nonneg hu 1) - have h42 : (0:ℝ) ≤ 14180011930716980449379240294714564887587943224073955569876816155335397250 * α ^ 42 := - mul_nonneg (by norm_num) (pow_nonneg hα 42) have hid : (17 : ℝ) ^ 42 * (234355849074955263951049856572420428528087559257217338000 + 1647917825991745087828090979449220009324402935342213794192 * α + 5517259206635462357799308151379743852022400880405143709300 * α ^ 2 + 11697286850057325472448884282596125036178461096427071180160 * α ^ 3 + 17618194225546020573784427664650585416610740635319786403400 * α ^ 4 + 20046068608053045224231426681510601856273741292025591141480 * α ^ 5 + 17885461556571898483672892064956643539473640662999345701666 * α ^ 6 + 12820152657712533249363000294926617606868677915971896670240 * α ^ 7 + 7502523555651917287805352494007861019866814933742609160696 * α ^ 8 + 3622686298843516098851206612510488687148684155393129482472 * α ^ 9 + 1452571052316260978855070270500133585694231422375833061090 * α ^ 10 + 485064610274304784360415817487598469472479148412401415808 * α ^ 11 + 134868827326575807784515799657395435527619954194004227748 * α ^ 12 + 31113923159253038634767916248106358904477281041358348956 * α ^ 13 + 5912609861703141760519754094833940739302488844248812479 * α ^ 14 + 914297729950293095944937323513702712183136890515661088 * α ^ 15 + 112786258002906693411402876201621614411462995639363644 * α ^ 16 + 10715561597079704979556413609803278787797162405942296 * α ^ 17 + 719193622230655390355126847425184862615908011115060 * α ^ 18 + 14657836127065470780938993503699490899434597229512 * α ^ 19 - 34950338977013178639767569738567864677193896372240 * α ^ 20 + 1366801847725067991778952117668601561839569590900 * α ^ 21 + 4959220152208557382027853908303681091859164175 * α ^ 22 + 615471404273198116343750989411396892897296680 * α ^ 23 + 34101039377472481958974903669374217452733632 * α ^ 24 + 1034386808344405409707750019488517511355008 * α ^ 25 + 5291527796743143896670464285156657893296 * α ^ 26 - 1219504316386418556368987826914293621248 * α ^ 27 - 75185184777106907253176174218461272832 * α ^ 28 - 2739147805326680629369630717760523264 * α ^ 29 - 73210280752772515350101169959614464 * α ^ 30 - 1531828473996677645738094611644416 * α ^ 31 - 25792432980458262033466819153920 * α ^ 32 - 353823743440056079889063264256 * α ^ 33 - 3970096169377863374039531520 * α ^ 34 - 36356947826301657371639808 * α ^ 35 - 269616704004970519658496 * α ^ 36 - 1596209219881105096704 * α ^ 37 - 7373431975900938240 * α ^ 38 - 25626639771107328 * α ^ 39 - 63065268682752 * α ^ 40 - 98008301568 * α ^ 41 - 72351744 * α ^ 42) = 234355849074955263951049856572420428528087559257217338000 * (17 - α) ^ 42 + 37857548703007787579021640626678398156694527389620762697264 * α ^ 1 * (17 - α) ^ 41 + 2944867021487431429882033394933706308696266088891073674557524 * α ^ 2 * (17 - α) ^ 40 + 146910666364742997856783011317318114681608355643172977318910560 * α ^ 3 * (17 - α) ^ 39 + 5281338930363712858347930254940637802165598810816949523191508760 * α ^ 4 * (17 - α) ^ 38 + 145753437649734017761868379170413156812750014126479617274091172120 * α ^ 5 * (17 - α) ^ 37 + 3212433660877561136639288711614882650266994711330586733979437268666 * α ^ 6 * (17 - α) ^ 36 + 58080099103816679194960077966232290827409612456400212654077549294136 * α ^ 7 * (17 - α) ^ 35 + 878073000124467105754351061548458968812316660181611332798436479232076 * α ^ 8 * (17 - α) ^ 34 + 11259922048324651489289493311309309631891001644523667321376037356186888 * α ^ 9 * (17 - α) ^ 33 + 123812154859041152773858816918455744865935561732076455885319152132304488 * α ^ 10 * (17 - α) ^ 32 + 1177282729304429087196944522508776379491442707108602485795557386562286720 * α ^ 11 * (17 - α) ^ 31 + 9744718648999432569661305582435950678261853364124701152000275689844790852 * α ^ 12 * (17 - α) ^ 30 + 70584478999572099526210718832986814594230665767170003296124002517210218548 * α ^ 13 * (17 - α) ^ 29 + 449272053601042666671596079622675645227192899930246481044206503873022598127 * α ^ 14 * (17 - α) ^ 28 + 2521166194604692753878031098107876914463687672229082966575780993950448786492 * α ^ 15 * (17 - α) ^ 27 + 12505743633148390302761257035504316007036914113543301212072536616680265609966 * α ^ 16 * (17 - α) ^ 26 + 54941752319236926994034527846178330055107665824491889262114770438776772080688 * α ^ 17 * (17 - α) ^ 25 + 214108133336419833203656668659528095997912595237383503399365023725947428991765 * α ^ 18 * (17 - α) ^ 24 + 740907981283804161674373017608569262860463894016142577208923888370995315389936 * α ^ 19 * (17 - α) ^ 23 + 2278016136661934557373907941895735701975033136406032948359780173720186398978768 * α ^ 20 * (17 - α) ^ 22 + 6223044015900732285273426821948491350903940514086744466166738234457122088918648 * α ^ 21 * (17 - α) ^ 21 + 15091573130026048461544325185690904741676446061897994842743984569608882476868246 * α ^ 22 * (17 - α) ^ 20 + 32431472815063210198529045051946172792892281829735717630866526639188278809402520 * α ^ 23 * (17 - α) ^ 19 + 61589977160019028252201500272191461481719309803518295921163839432202796081677436 * α ^ 24 * (17 - α) ^ 18 + 103000834533491129063640284036092678067268542010637673258239410761540957030115384 * α ^ 25 * (17 - α) ^ 17 + 151071516679099175443820464035839365942459349434188215403085360254317550609833028 * α ^ 26 * (17 - α) ^ 16 + 193445346233280859296440806414848722181948957409609959791787404726401564917282096 * α ^ 27 * (17 - α) ^ 15 + 215172096945268414340053333093031776453400001175778749956470312358926404221592428 * α ^ 28 * (17 - α) ^ 14 + 206736790098352378662725797487880027357919714030453368776992727928497863099548756 * α ^ 29 * (17 - α) ^ 13 + 170462524827332695320086649521380810293612989490733605162878601757384672794284747 * α ^ 30 * (17 - α) ^ 12 + 119693210823537512228591503646550664793242492067851215311990782497984104429398428 * α ^ 31 * (17 - α) ^ 11 + 70908831093339465886818052612765873755388314931239009902767176459421394442785742 * α ^ 32 * (17 - α) ^ 10 + 35048237403311100028743507259452310464158209931947679191434306115144076602284800 * α ^ 33 * (17 - α) ^ 9 + 14268450259765073448679759926668655504802778135164107658390044566561421617189673 * α ^ 34 * (17 - α) ^ 8 + 4724185205300768110792705712599630650015863880955341087853206634323491488643616 * α ^ 35 * (17 - α) ^ 7 + 1265299135971789660909673234797601828374717278246484983747256160401664255750872 * α ^ 36 * (17 - α) ^ 6 + 280178539570804945484739775418806390334413870080009334057823189831955617940552 * α ^ 37 * (17 - α) ^ 5 + 55439566906689638975335374901816806066147146428085261656377329665751391494454 * α ^ 38 * (17 - α) ^ 4 + 10724868311110483392855160615399587116240195810586300982060213202048731748152 * α ^ 39 * (17 - α) ^ 3 + 1891608447746568174857958621996992326295338311284555046921110287910697380220 * α ^ 40 * (17 - α) ^ 2 + 236532288128129299669916971619583813438473071647279968567818223819695392000 * α ^ 41 * (17 - α) ^ 1 + 14180011930716980449379240294714564887587943224073955569876816155335397250 * α ^ 42 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 234355849074955263951049856572420428528087559257217338000 * (17 - α) ^ 42 := - mul_pos (by norm_num) (pow_pos (by linarith) 42) - linarith - · have hpos : (0 : ℝ) < 14180011930716980449379240294714564887587943224073955569876816155335397250 * α ^ 42 := - mul_pos (by norm_num) (pow_pos (by linarith) 42) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 42)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree46_47.lean b/Sendov/FiniteRange/Degree46_47.lean index 7ccc2a9..8b58e0e 100644 --- a/Sendov/FiniteRange/Degree46_47.lean +++ b/Sendov/FiniteRange/Degree46_47.lean @@ -88,105 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 842100496490164655863899050953513048577517889022827148437500 + 6202389537263705762292576691419085693567510900497436523437500 * α + 21800976172966131822633999416830068976610560420989990234375000 * α ^ 2 + 48647779340585710046299723714124054163748508466339111328125000 * α ^ 3 + 77335744367973576659808264003823907539197097243080139160156250 * α ^ 4 + 93163317164153721286069997796054376135656931010389709472656250 * α ^ 5 + 88315055516249458646175698818625653153167262528008728027343750 * α ^ 6 + 67525482393603249349320023657815936540710634750331726074218750 * α ^ 7 + 42343249160820224575714518101180101058857691214973571777343750 * α ^ 8 + 22022629774039619130278840067223760137223751259001110839843750 * α ^ 9 + 9569037722124326061646207068547925124389847238604876953125000 * α ^ 10 + 3487611243366543917723910686246986580789320695836231250000000 * α ^ 11 + 1067491157924455805861448662311325524405538803060341943359375 * α ^ 12 + 273968142184015848925560036581877108638855706237317490234375 * α ^ 13 + 58692019460587884114525551639474562464674600041476138671875 * α ^ 14 + 10411576695976844279717630513220926151802953315673888359375 * α ^ 15 + 1509986509025418223518044667529937663568415780777702125000 * α ^ 16 + 175469918947028739649743022943799878357086029596651812500 * α ^ 17 + 15779760028253605454031412572296146026014740194967383750 * α ^ 18 + 1010913062001619607789595546144718629262771585185507750 * α ^ 19 + 21462061397781700126941815631803690593259676260498115 * α ^ 20 - 45387057094906818237348334721211459766084329446075757 * α ^ 21 + 1689541722499339437202551579490531894232999398986279 * α ^ 22 + 3936001560036108693341101447415785391643174835443 * α ^ 23 + 607977630486171911031424776719828152869889423044 * α ^ 24 + 36336260809521268434231902077696447132341347400 * α ^ 25 + 1235785272488557483704068508469144496017205184 * α ^ 26 + 15739109405711750147519445570667095018389712 * α ^ 27 - 844836507113777181276666926325076953789696 * α ^ 28 - 65867488403154309232905535325099415940608 * α ^ 29 - 2603492828180830946162421054768504476160 * α ^ 30 - 73591830258372192880755514270838320128 * α ^ 31 - 1619902372241517858218483163123738624 * α ^ 32 - 28740854840777906929998653281886208 * α ^ 33 - 417683720829155224442216354095104 * α ^ 34 - 5006133645480122906718714101760 * α ^ 35 - 49524449888141405612129746944 * α ^ 36 - 402720876040696001365082112 * α ^ 37 - 2667361119757440577634304 * α ^ 38 - 14172645073027210739712 * α ^ 39 - 59000480246059499520 * α ^ 40 - 185464776902049792 * α ^ 41 - 414106827882496 * α ^ 42 - 585532178432 * α ^ 43 - 394264576 * α ^ 44 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 842100496490164655863899050953513048577517889022827148437500 * (17 - α) ^ 44 := - mul_nonneg (by norm_num) (pow_nonneg hu 44) - have h1 : (0:ℝ) ≤ 142493043979050242816985361996079030928058472425460815429687500 * α ^ 1 * (17 - α) ^ 43 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 43) - have h2 : (0:ℝ) ≤ 11631055935406676773424347895093264920192634352945327758789062500 * α ^ 2 * (17 - α) ^ 42 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 42) - have h3 : (0:ℝ) ≤ 609992449449811389379816851349777566641910911240855026245117187500 * α ^ 3 * (17 - α) ^ 41 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 41) - have h4 : (0:ℝ) ≤ 23098700643661062063264209577856576688439492919078299293518066406250 * α ^ 4 * (17 - α) ^ 40 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 40) - have h5 : (0:ℝ) ≤ 672886788673347303113646845460420332103897531976657897846984863281250 * α ^ 5 * (17 - α) ^ 39 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 39) - have h6 : (0:ℝ) ≤ 15689183510706334336751155501240168225930150393352115080165405273437500 * α ^ 6 * (17 - α) ^ 38 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 38) - have h7 : (0:ℝ) ≤ 300787141414416123262875017253530680535010772323084607526017456054687500 * α ^ 7 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 37) - have h8 : (0:ℝ) ≤ 4834082125229902229160089626065942580696829879116404068575523803710937500 * α ^ 8 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 36) - have h9 : (0:ℝ) ≤ 66072765878867110841147420893730369943336026053933255103129270288085937500 * α ^ 9 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 35) - have h10 : (0:ℝ) ≤ 776562148162541303792514188712949580055222798582046568076665765594238281250 * α ^ 10 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 34) - have h11 : (0:ℝ) ≤ 7916165993961948987449580340899456664926175109154616993743620562742089843750 * α ^ 11 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 33) - have h12 : (0:ℝ) ≤ 70468708978108892817571764541075442041839869106980895974143854170172216796875 * α ^ 12 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 32) - have h13 : (0:ℝ) ≤ 550782470594884966715313206866948703867564604566371289578563249171289130859375 * α ^ 13 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 31) - have h14 : (0:ℝ) ≤ 3796271005225225067290420328594083801226095054076152502460026076879075960937500 * α ^ 14 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 30) - have h15 : (0:ℝ) ≤ 23154951045516208632207010063622078794447604241421409800591507255675276447500000 * α ^ 15 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 29) - have h16 : (0:ℝ) ≤ 125329005241909283645244852767369785798817688336457585844713864177983765701578125 * α ^ 16 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 28) - have h17 : (0:ℝ) ≤ 603309363715139594521494665743634826511126981458830526026064579534478738308515625 * α ^ 17 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 27) - have h18 : (0:ℝ) ≤ 2587364175724392722746563574797525717547108337555060272594625213670122377224922500 * α ^ 18 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 26) - have h19 : (0:ℝ) ≤ 9898549256162510047261715675023148365372355380576229013767998580288842214641264500 * α ^ 19 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 25) - have h20 : (0:ℝ) ≤ 33813519196392670210313059666995142454669959269244976653953740675056602158569578990 * α ^ 20 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 24) - have h21 : (0:ℝ) ≤ 103196149479405719489529062495189947552780951823855220313054805583706227764000739366 * α ^ 21 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 23) - have h22 : (0:ℝ) ≤ 281414632953734490932383578025410664595174480569956516679000280734682217487402570284 * α ^ 22 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 22) - have h23 : (0:ℝ) ≤ 685395337547723093442698987180372896387216615945658732837662652249972601215820937644 * α ^ 23 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 21) - have h24 : (0:ℝ) ≤ 1489149662951024487101091584274360794704873551266921796745007333128807261864150039440 * α ^ 24 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 20) - have h25 : (0:ℝ) ≤ 2880717800764736562237157455028656259513844924473937460829052015392479287411749584000 * α ^ 25 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 19) - have h26 : (0:ℝ) ≤ 4948638359187857502444997471872385263341628692259466992165339970591851807662058176250 * α ^ 26 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 18) - have h27 : (0:ℝ) ≤ 7524808365437321671268164297839989387020638669389928036404610340476432390943699968750 * α ^ 27 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 17) - have h28 : (0:ℝ) ≤ 10090745730787017626963337198418905561056134794018935219523451765642743556242036084375 * α ^ 28 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 16) - have h29 : (0:ℝ) ≤ 11884304827785561031887161390332218762155951913733146752455369428108543693253527796875 * α ^ 29 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 15) - have h30 : (0:ℝ) ≤ 12236134768064187298824467090486239622825767135842989738867807258895895376319098437500 * α ^ 30 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 14) - have h31 : (0:ℝ) ≤ 10956342185947834383371522495075810215688468611001591955872795308997953700512875000000 * α ^ 31 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 13) - have h32 : (0:ℝ) ≤ 8480200760430773875569783935490297001453280452983110658282869458743468575057900390625 * α ^ 32 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 12) - have h33 : (0:ℝ) ≤ 5633029575677093237429398107221916268853414367970165464924058295269805975873642578125 * α ^ 33 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 11) - have h34 : (0:ℝ) ≤ 3183457062375806825326758077695313148081656523121607548560593992595734846529882812500 * α ^ 34 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 10) - have h35 : (0:ℝ) ≤ 1514534325584221507212883373649465749871038738085239693277104497573823324223632812500 * α ^ 35 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 9) - have h36 : (0:ℝ) ≤ 598855676703127526215866064910890958440342074461336641457617262869261681970214843750 * α ^ 36 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 8) - have h37 : (0:ℝ) ≤ 193895710320064143314152952928304080530489756415618625370542369927247228210449218750 * α ^ 37 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 7) - have h38 : (0:ℝ) ≤ 50633726898981387585795045476023804360885506077389009794334574956167921386718750000 * α ^ 38 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 38)) (pow_nonneg hu 6) - have h39 : (0:ℝ) ≤ 10572386406974364669523632230312278886927530949116535421326834315982454833984375000 * α ^ 39 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 39)) (pow_nonneg hu 5) - have h40 : (0:ℝ) ≤ 1792713553761047052220517000286370236664409834359847244425465316189674377441406250 * α ^ 40 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 40)) (pow_nonneg hu 4) - have h41 : (0:ℝ) ≤ 262340726959871612498380595594270897589647597255618313914727785960884094238281250 * α ^ 41 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 41)) (pow_nonneg hu 3) - have h42 : (0:ℝ) ≤ 34914711121164009908327832512530464932432901098435282301515528343963623046875000 * α ^ 42 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 42)) (pow_nonneg hu 2) - have h43 : (0:ℝ) ≤ 3721215228917653403021576873516894679349471790204206905261547785186767578125000 * α ^ 43 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 43)) (pow_nonneg hu 1) - have h44 : (0:ℝ) ≤ 210713180134643197170850407242377156075926959031893252124925369262695312500000 * α ^ 44 := - mul_nonneg (by norm_num) (pow_nonneg hα 44) have hid : (17 : ℝ) ^ 44 * (842100496490164655863899050953513048577517889022827148437500 + 6202389537263705762292576691419085693567510900497436523437500 * α + 21800976172966131822633999416830068976610560420989990234375000 * α ^ 2 + 48647779340585710046299723714124054163748508466339111328125000 * α ^ 3 + 77335744367973576659808264003823907539197097243080139160156250 * α ^ 4 + 93163317164153721286069997796054376135656931010389709472656250 * α ^ 5 + 88315055516249458646175698818625653153167262528008728027343750 * α ^ 6 + 67525482393603249349320023657815936540710634750331726074218750 * α ^ 7 + 42343249160820224575714518101180101058857691214973571777343750 * α ^ 8 + 22022629774039619130278840067223760137223751259001110839843750 * α ^ 9 + 9569037722124326061646207068547925124389847238604876953125000 * α ^ 10 + 3487611243366543917723910686246986580789320695836231250000000 * α ^ 11 + 1067491157924455805861448662311325524405538803060341943359375 * α ^ 12 + 273968142184015848925560036581877108638855706237317490234375 * α ^ 13 + 58692019460587884114525551639474562464674600041476138671875 * α ^ 14 + 10411576695976844279717630513220926151802953315673888359375 * α ^ 15 + 1509986509025418223518044667529937663568415780777702125000 * α ^ 16 + 175469918947028739649743022943799878357086029596651812500 * α ^ 17 + 15779760028253605454031412572296146026014740194967383750 * α ^ 18 + 1010913062001619607789595546144718629262771585185507750 * α ^ 19 + 21462061397781700126941815631803690593259676260498115 * α ^ 20 - 45387057094906818237348334721211459766084329446075757 * α ^ 21 + 1689541722499339437202551579490531894232999398986279 * α ^ 22 + 3936001560036108693341101447415785391643174835443 * α ^ 23 + 607977630486171911031424776719828152869889423044 * α ^ 24 + 36336260809521268434231902077696447132341347400 * α ^ 25 + 1235785272488557483704068508469144496017205184 * α ^ 26 + 15739109405711750147519445570667095018389712 * α ^ 27 - 844836507113777181276666926325076953789696 * α ^ 28 - 65867488403154309232905535325099415940608 * α ^ 29 - 2603492828180830946162421054768504476160 * α ^ 30 - 73591830258372192880755514270838320128 * α ^ 31 - 1619902372241517858218483163123738624 * α ^ 32 - 28740854840777906929998653281886208 * α ^ 33 - 417683720829155224442216354095104 * α ^ 34 - 5006133645480122906718714101760 * α ^ 35 - 49524449888141405612129746944 * α ^ 36 - 402720876040696001365082112 * α ^ 37 - 2667361119757440577634304 * α ^ 38 - 14172645073027210739712 * α ^ 39 - 59000480246059499520 * α ^ 40 - 185464776902049792 * α ^ 41 - 414106827882496 * α ^ 42 - 585532178432 * α ^ 43 - 394264576 * α ^ 44) = 842100496490164655863899050953513048577517889022827148437500 * (17 - α) ^ 44 + 142493043979050242816985361996079030928058472425460815429687500 * α ^ 1 * (17 - α) ^ 43 + 11631055935406676773424347895093264920192634352945327758789062500 * α ^ 2 * (17 - α) ^ 42 + 609992449449811389379816851349777566641910911240855026245117187500 * α ^ 3 * (17 - α) ^ 41 + 23098700643661062063264209577856576688439492919078299293518066406250 * α ^ 4 * (17 - α) ^ 40 + 672886788673347303113646845460420332103897531976657897846984863281250 * α ^ 5 * (17 - α) ^ 39 + 15689183510706334336751155501240168225930150393352115080165405273437500 * α ^ 6 * (17 - α) ^ 38 + 300787141414416123262875017253530680535010772323084607526017456054687500 * α ^ 7 * (17 - α) ^ 37 + 4834082125229902229160089626065942580696829879116404068575523803710937500 * α ^ 8 * (17 - α) ^ 36 + 66072765878867110841147420893730369943336026053933255103129270288085937500 * α ^ 9 * (17 - α) ^ 35 + 776562148162541303792514188712949580055222798582046568076665765594238281250 * α ^ 10 * (17 - α) ^ 34 + 7916165993961948987449580340899456664926175109154616993743620562742089843750 * α ^ 11 * (17 - α) ^ 33 + 70468708978108892817571764541075442041839869106980895974143854170172216796875 * α ^ 12 * (17 - α) ^ 32 + 550782470594884966715313206866948703867564604566371289578563249171289130859375 * α ^ 13 * (17 - α) ^ 31 + 3796271005225225067290420328594083801226095054076152502460026076879075960937500 * α ^ 14 * (17 - α) ^ 30 + 23154951045516208632207010063622078794447604241421409800591507255675276447500000 * α ^ 15 * (17 - α) ^ 29 + 125329005241909283645244852767369785798817688336457585844713864177983765701578125 * α ^ 16 * (17 - α) ^ 28 + 603309363715139594521494665743634826511126981458830526026064579534478738308515625 * α ^ 17 * (17 - α) ^ 27 + 2587364175724392722746563574797525717547108337555060272594625213670122377224922500 * α ^ 18 * (17 - α) ^ 26 + 9898549256162510047261715675023148365372355380576229013767998580288842214641264500 * α ^ 19 * (17 - α) ^ 25 + 33813519196392670210313059666995142454669959269244976653953740675056602158569578990 * α ^ 20 * (17 - α) ^ 24 + 103196149479405719489529062495189947552780951823855220313054805583706227764000739366 * α ^ 21 * (17 - α) ^ 23 + 281414632953734490932383578025410664595174480569956516679000280734682217487402570284 * α ^ 22 * (17 - α) ^ 22 + 685395337547723093442698987180372896387216615945658732837662652249972601215820937644 * α ^ 23 * (17 - α) ^ 21 + 1489149662951024487101091584274360794704873551266921796745007333128807261864150039440 * α ^ 24 * (17 - α) ^ 20 + 2880717800764736562237157455028656259513844924473937460829052015392479287411749584000 * α ^ 25 * (17 - α) ^ 19 + 4948638359187857502444997471872385263341628692259466992165339970591851807662058176250 * α ^ 26 * (17 - α) ^ 18 + 7524808365437321671268164297839989387020638669389928036404610340476432390943699968750 * α ^ 27 * (17 - α) ^ 17 + 10090745730787017626963337198418905561056134794018935219523451765642743556242036084375 * α ^ 28 * (17 - α) ^ 16 + 11884304827785561031887161390332218762155951913733146752455369428108543693253527796875 * α ^ 29 * (17 - α) ^ 15 + 12236134768064187298824467090486239622825767135842989738867807258895895376319098437500 * α ^ 30 * (17 - α) ^ 14 + 10956342185947834383371522495075810215688468611001591955872795308997953700512875000000 * α ^ 31 * (17 - α) ^ 13 + 8480200760430773875569783935490297001453280452983110658282869458743468575057900390625 * α ^ 32 * (17 - α) ^ 12 + 5633029575677093237429398107221916268853414367970165464924058295269805975873642578125 * α ^ 33 * (17 - α) ^ 11 + 3183457062375806825326758077695313148081656523121607548560593992595734846529882812500 * α ^ 34 * (17 - α) ^ 10 + 1514534325584221507212883373649465749871038738085239693277104497573823324223632812500 * α ^ 35 * (17 - α) ^ 9 + 598855676703127526215866064910890958440342074461336641457617262869261681970214843750 * α ^ 36 * (17 - α) ^ 8 + 193895710320064143314152952928304080530489756415618625370542369927247228210449218750 * α ^ 37 * (17 - α) ^ 7 + 50633726898981387585795045476023804360885506077389009794334574956167921386718750000 * α ^ 38 * (17 - α) ^ 6 + 10572386406974364669523632230312278886927530949116535421326834315982454833984375000 * α ^ 39 * (17 - α) ^ 5 + 1792713553761047052220517000286370236664409834359847244425465316189674377441406250 * α ^ 40 * (17 - α) ^ 4 + 262340726959871612498380595594270897589647597255618313914727785960884094238281250 * α ^ 41 * (17 - α) ^ 3 + 34914711121164009908327832512530464932432901098435282301515528343963623046875000 * α ^ 42 * (17 - α) ^ 2 + 3721215228917653403021576873516894679349471790204206905261547785186767578125000 * α ^ 43 * (17 - α) ^ 1 + 210713180134643197170850407242377156075926959031893252124925369262695312500000 * α ^ 44 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 842100496490164655863899050953513048577517889022827148437500 * (17 - α) ^ 44 := - mul_pos (by norm_num) (pow_pos (by linarith) 44) - linarith - · have hpos : (0 : ℝ) < 210713180134643197170850407242377156075926959031893252124925369262695312500000 * α ^ 44 := - mul_pos (by norm_num) (pow_pos (by linarith) 44) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 44)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree48_49.lean b/Sendov/FiniteRange/Degree48_49.lean index d8b3dd9..791e8cf 100644 --- a/Sendov/FiniteRange/Degree48_49.lean +++ b/Sendov/FiniteRange/Degree48_49.lean @@ -88,109 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 7591199764941595142535047667167496055166615766339109753578898560 + 58444846237165943551279131377341207077328035296269812484322869920 * α + 215183176025506919702531217941842711339737075266956526659211243010 * α ^ 2 + 504119825711981991953619761968878166062817925879996924390857878780 * α ^ 3 + 843499983730922829653379646526224878986727978586395545435732482710 * α ^ 4 + 1072503620634158239884244537293452959863774094675706145687308954160 * α ^ 5 + 1076446847966334979143656931502325139234331446767890824217309988610 * α ^ 6 + 874481274546832703168275213074859855200282043558515881767199205780 * α ^ 7 + 584940481506790593329950294203572360626072792868892731256510254790 * α ^ 8 + 325988305644965786771400276568642744850196724125639486229759912680 * α ^ 9 + 152567991163281517146520289154412206989708725501314740543815123242 * α ^ 10 + 60257769914462931158481100919633683041061465448481123420828204444 * α ^ 11 + 20129798805767351823723652441204102433547938067213802588532446662 * α ^ 12 + 5687016607145482595882099777086733334514360250477330630445824496 * α ^ 13 + 1355278557647407824791108174949033065263401718280146352590299132 * α ^ 14 + 271000424772480840244816322457048834002540366106552011600103312 * α ^ 15 + 45077206161318041189379028469239391861894842436881282720631712 * α ^ 16 + 6155423822307023556988091783956120485240591022903519939638936 * α ^ 17 + 676142880398770802271995740973508628770999664408861891669293 * α ^ 18 + 57725697116366115637265587909635903325806420371494216534326 * α ^ 19 + 3538202264412216996329718883610558594067822140944030875519 * α ^ 20 + 77574873286609722098225332819487251209357565591548524952 * α ^ 21 - 147315204845101536255433762427937191325421411462459722039 * α ^ 22 + 5245361991102819530624768487527000682291303265286717178 * α ^ 23 + 6658544653474755689275786385563045545487294797590331 * α ^ 24 + 1472968109561870214375834133381327743623319061135332 * α ^ 25 + 95171634843015522566439274462655369397323761963548 * α ^ 26 + 3545966415236624759599391868158380053883553245824 * α ^ 27 + 64377156482122958948701739689394929584223299312 * α ^ 28 - 1168656375434360221238828101326004753556536896 * α ^ 29 - 139417680493330544069384288780944967009327424 * α ^ 30 - 6070430434653508552057016796802025839583232 * α ^ 31 - 181826034173641815543270617357206754251776 * α ^ 32 - 4202739957608852026901130257441189900288 * α ^ 33 - 78263006650153541891015915303985934336 * α ^ 34 - 1198002545218365750178026069831352320 * α ^ 35 - 15219010328713364070284371473793024 * α ^ 36 - 160981724807992562843830338977792 * α ^ 37 - 1415946326039159376655312551936 * α ^ 38 - 10298650421826586803585810432 * α ^ 39 - 61314611371788369779294208 * α ^ 40 - 294083659089512872280064 * α ^ 41 - 1109163402380295012352 * α ^ 42 - 3168884055181623296 * α ^ 43 - 6448929882243072 * α ^ 44 - 8332022644736 * α ^ 45 - 5138022400 * α ^ 46 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 7591199764941595142535047667167496055166615766339109753578898560 * (17 - α) ^ 46 := - mul_nonneg (by norm_num) (pow_nonneg hu 46) - have h1 : (0:ℝ) ≤ 1342757575219134416928357426104505338852240925288185860898118122400 * α ^ 1 * (17 - α) ^ 45 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 45) - have h2 : (0:ℝ) ≤ 114755136999517997583283831824376925408437409071957821349973204728290 * α ^ 2 * (17 - α) ^ 44 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 44) - have h3 : (0:ℝ) ≤ 6311871144666629761637230662569825452491581180312292712701296505455700 * α ^ 3 * (17 - α) ^ 43 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 43) - have h4 : (0:ℝ) ≤ 251117021819028982864973145165014954053157643806880139740425434345397070 * α ^ 4 * (17 - α) ^ 42 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 42) - have h5 : (0:ℝ) ≤ 7700255582992438800428557545327513666900681197124798184091430231098133960 * α ^ 5 * (17 - α) ^ 41 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 41) - have h6 : (0:ℝ) ≤ 189367631135786370984279829668504339679999112172842699082163134760932823050 * α ^ 6 * (17 - α) ^ 40 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 40) - have h7 : (0:ℝ) ≤ 3837299018002887727841264180140203196909974021427614251792467066036834514460 * α ^ 7 * (17 - α) ^ 39 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 39) - have h8 : (0:ℝ) ≤ 65330193691266612095267419404574125266102388594982857701230218272237672614950 * α ^ 8 * (17 - α) ^ 38 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 38) - have h9 : (0:ℝ) ≤ 948167953912606041527211234549432129570826851527171582246349949742846207580480 * α ^ 9 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 37) - have h10 : (0:ℝ) ≤ 11862897220186135053544305256945784922859357773863352679820145643098022220785278 * α ^ 10 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 36) - have h11 : (0:ℝ) ≤ 129072115915064352802998192157149959447544106737793242351888060162304851138395580 * α ^ 11 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 35) - have h12 : (0:ℝ) ≤ 1229795769892025833353618429128543962117904449244422243628303524212233499528414042 * α ^ 12 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 34) - have h13 : (0:ℝ) ≤ 10318568580638790387954818617820003753357917586903069070216576765343271409771487800 * α ^ 13 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 33) - have h14 : (0:ℝ) ≤ 76586524069802882894078032032353528016591779712305320570499363273565575419847624376 * α ^ 14 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 32) - have h15 : (0:ℝ) ≤ 504684151077635699819713494479495670799591999023571346450099800467157372095419250912 * α ^ 15 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 31) - have h16 : (0:ℝ) ≤ 2961464831656022935314311202766885642337479869778047028701398651217449033783743537080 * α ^ 16 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 30) - have h17 : (0:ℝ) ≤ 15511312927367844114034275848806344502776248279233504803062812081346091041874500312424 * α ^ 17 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 29) - have h18 : (0:ℝ) ≤ 72656111586338879343047119765015961893678349787522472371632798641470861566691804080505 * α ^ 18 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 28) - have h19 : (0:ℝ) ≤ 304808185012857975724498725531184620292840658826980992018187980322769269404048114731402 * α ^ 19 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 27) - have h20 : (0:ℝ) ≤ 1146590392326781377506836763538391565844743608196668993927537593446331465448235657881983 * α ^ 20 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 26) - have h21 : (0:ℝ) ≤ 3870600448216253864751392890281906184377072807016812087208519577192080210828017341041740 * α ^ 21 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 25) - have h22 : (0:ℝ) ≤ 11731891593652584393540855221982594836705418299405024828972301429357123143028053536434669 * α ^ 22 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 24) - have h23 : (0:ℝ) ≤ 31934660245093795505928032518461564485995557345717410206365628000458801939061533187363710 * α ^ 23 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 23) - have h24 : (0:ℝ) ≤ 78047993066241081864729405263799058714155198199791825458167970252230959614239365881878947 * α ^ 24 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 22) - have h25 : (0:ℝ) ≤ 171134843936218514686150148288359364686859698322647460634859632067734173140627231359730584 * α ^ 25 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 21) - have h26 : (0:ℝ) ≤ 336206506050303051354999483042669483751718653067431091525204950883403868367567684342080020 * α ^ 26 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 20) - have h27 : (0:ℝ) ≤ 590632297194451478800263563954322310467842994277133756163742170600614302732421283888959208 * α ^ 27 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 19) - have h28 : (0:ℝ) ≤ 925516670394461047649865831225821273518368307653384139954083832567847096613665974954102740 * α ^ 28 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 18) - have h29 : (0:ℝ) ≤ 1289766645595527592343166744587741066182934225995347417854162835114044818241870914092204864 * α ^ 29 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 17) - have h30 : (0:ℝ) ≤ 1593002416141247767069378716733631264077333099250896896091743214673847829299190958471833770 * α ^ 30 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 16) - have h31 : (0:ℝ) ≤ 1737143176643046947303118633436476715799207563792300127093284518020249525152200860365809660 * α ^ 31 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 15) - have h32 : (0:ℝ) ≤ 1665311418235579100523754798782860220365664075295289918982682336006446972368945219112765174 * α ^ 32 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 14) - have h33 : (0:ℝ) ≤ 1396557360038252731643454796992613166665272986910499262544165249742942020476375868362815880 * α ^ 33 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 13) - have h34 : (0:ℝ) ≤ 1018684619224015379084223520647127025765305887834183888331474942254858102069742927480803487 * α ^ 34 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 12) - have h35 : (0:ℝ) ≤ 641932494254295073687856899416231301192107297550335297051507507404266419546500180865404214 * α ^ 35 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 11) - have h36 : (0:ℝ) ≤ 346616023624199508122240528681160766975802934453336786297349998221685206774349480865493785 * α ^ 36 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 10) - have h37 : (0:ℝ) ≤ 158769464897392551896561203035439621044410847226907537961532798384360622001611952908266388 * α ^ 37 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 9) - have h38 : (0:ℝ) ≤ 60938188611726643632686961457984989878294641295998164978961810053640858299331163879730855 * α ^ 38 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 38)) (pow_nonneg hu 8) - have h39 : (0:ℝ) ≤ 19303965900462850327232871938264169200849651337482672284417001334177009419208937264542474 * α ^ 39 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 39)) (pow_nonneg hu 7) - have h40 : (0:ℝ) ≤ 4956495620088219287305017176528775890173857965129426190480342928881513904895208113754297 * α ^ 40 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 40)) (pow_nonneg hu 6) - have h41 : (0:ℝ) ≤ 1011094459778786182680868888323794915088603327243667761590423358931583382786018989420280 * α ^ 41 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 41)) (pow_nonneg hu 5) - have h42 : (0:ℝ) ≤ 161129362690984017597830623141137027326076650900522288728417841096952993030031822930852 * α ^ 42 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 42)) (pow_nonneg hu 4) - have h43 : (0:ℝ) ≤ 20053630683210270088939005261620316062127222962442862223177250670635839018815183419080 * α ^ 43 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 43)) (pow_nonneg hu 3) - have h44 : (0:ℝ) ≤ 2007106897711885365446090180299995728598915866332529016566715378067994766096351142716 * α ^ 44 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 44)) (pow_nonneg hu 2) - have h45 : (0:ℝ) ≤ 160682627900417809962527853098762123815034415286611690425666398978372619671902878336 * α ^ 45 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 45)) (pow_nonneg hu 1) - have h46 : (0:ℝ) ≤ 7728635588004831865654878836695725660660992895290133611955913220528766346904639440 * α ^ 46 := - mul_nonneg (by norm_num) (pow_nonneg hα 46) have hid : (17 : ℝ) ^ 46 * (7591199764941595142535047667167496055166615766339109753578898560 + 58444846237165943551279131377341207077328035296269812484322869920 * α + 215183176025506919702531217941842711339737075266956526659211243010 * α ^ 2 + 504119825711981991953619761968878166062817925879996924390857878780 * α ^ 3 + 843499983730922829653379646526224878986727978586395545435732482710 * α ^ 4 + 1072503620634158239884244537293452959863774094675706145687308954160 * α ^ 5 + 1076446847966334979143656931502325139234331446767890824217309988610 * α ^ 6 + 874481274546832703168275213074859855200282043558515881767199205780 * α ^ 7 + 584940481506790593329950294203572360626072792868892731256510254790 * α ^ 8 + 325988305644965786771400276568642744850196724125639486229759912680 * α ^ 9 + 152567991163281517146520289154412206989708725501314740543815123242 * α ^ 10 + 60257769914462931158481100919633683041061465448481123420828204444 * α ^ 11 + 20129798805767351823723652441204102433547938067213802588532446662 * α ^ 12 + 5687016607145482595882099777086733334514360250477330630445824496 * α ^ 13 + 1355278557647407824791108174949033065263401718280146352590299132 * α ^ 14 + 271000424772480840244816322457048834002540366106552011600103312 * α ^ 15 + 45077206161318041189379028469239391861894842436881282720631712 * α ^ 16 + 6155423822307023556988091783956120485240591022903519939638936 * α ^ 17 + 676142880398770802271995740973508628770999664408861891669293 * α ^ 18 + 57725697116366115637265587909635903325806420371494216534326 * α ^ 19 + 3538202264412216996329718883610558594067822140944030875519 * α ^ 20 + 77574873286609722098225332819487251209357565591548524952 * α ^ 21 - 147315204845101536255433762427937191325421411462459722039 * α ^ 22 + 5245361991102819530624768487527000682291303265286717178 * α ^ 23 + 6658544653474755689275786385563045545487294797590331 * α ^ 24 + 1472968109561870214375834133381327743623319061135332 * α ^ 25 + 95171634843015522566439274462655369397323761963548 * α ^ 26 + 3545966415236624759599391868158380053883553245824 * α ^ 27 + 64377156482122958948701739689394929584223299312 * α ^ 28 - 1168656375434360221238828101326004753556536896 * α ^ 29 - 139417680493330544069384288780944967009327424 * α ^ 30 - 6070430434653508552057016796802025839583232 * α ^ 31 - 181826034173641815543270617357206754251776 * α ^ 32 - 4202739957608852026901130257441189900288 * α ^ 33 - 78263006650153541891015915303985934336 * α ^ 34 - 1198002545218365750178026069831352320 * α ^ 35 - 15219010328713364070284371473793024 * α ^ 36 - 160981724807992562843830338977792 * α ^ 37 - 1415946326039159376655312551936 * α ^ 38 - 10298650421826586803585810432 * α ^ 39 - 61314611371788369779294208 * α ^ 40 - 294083659089512872280064 * α ^ 41 - 1109163402380295012352 * α ^ 42 - 3168884055181623296 * α ^ 43 - 6448929882243072 * α ^ 44 - 8332022644736 * α ^ 45 - 5138022400 * α ^ 46) = 7591199764941595142535047667167496055166615766339109753578898560 * (17 - α) ^ 46 + 1342757575219134416928357426104505338852240925288185860898118122400 * α ^ 1 * (17 - α) ^ 45 + 114755136999517997583283831824376925408437409071957821349973204728290 * α ^ 2 * (17 - α) ^ 44 + 6311871144666629761637230662569825452491581180312292712701296505455700 * α ^ 3 * (17 - α) ^ 43 + 251117021819028982864973145165014954053157643806880139740425434345397070 * α ^ 4 * (17 - α) ^ 42 + 7700255582992438800428557545327513666900681197124798184091430231098133960 * α ^ 5 * (17 - α) ^ 41 + 189367631135786370984279829668504339679999112172842699082163134760932823050 * α ^ 6 * (17 - α) ^ 40 + 3837299018002887727841264180140203196909974021427614251792467066036834514460 * α ^ 7 * (17 - α) ^ 39 + 65330193691266612095267419404574125266102388594982857701230218272237672614950 * α ^ 8 * (17 - α) ^ 38 + 948167953912606041527211234549432129570826851527171582246349949742846207580480 * α ^ 9 * (17 - α) ^ 37 + 11862897220186135053544305256945784922859357773863352679820145643098022220785278 * α ^ 10 * (17 - α) ^ 36 + 129072115915064352802998192157149959447544106737793242351888060162304851138395580 * α ^ 11 * (17 - α) ^ 35 + 1229795769892025833353618429128543962117904449244422243628303524212233499528414042 * α ^ 12 * (17 - α) ^ 34 + 10318568580638790387954818617820003753357917586903069070216576765343271409771487800 * α ^ 13 * (17 - α) ^ 33 + 76586524069802882894078032032353528016591779712305320570499363273565575419847624376 * α ^ 14 * (17 - α) ^ 32 + 504684151077635699819713494479495670799591999023571346450099800467157372095419250912 * α ^ 15 * (17 - α) ^ 31 + 2961464831656022935314311202766885642337479869778047028701398651217449033783743537080 * α ^ 16 * (17 - α) ^ 30 + 15511312927367844114034275848806344502776248279233504803062812081346091041874500312424 * α ^ 17 * (17 - α) ^ 29 + 72656111586338879343047119765015961893678349787522472371632798641470861566691804080505 * α ^ 18 * (17 - α) ^ 28 + 304808185012857975724498725531184620292840658826980992018187980322769269404048114731402 * α ^ 19 * (17 - α) ^ 27 + 1146590392326781377506836763538391565844743608196668993927537593446331465448235657881983 * α ^ 20 * (17 - α) ^ 26 + 3870600448216253864751392890281906184377072807016812087208519577192080210828017341041740 * α ^ 21 * (17 - α) ^ 25 + 11731891593652584393540855221982594836705418299405024828972301429357123143028053536434669 * α ^ 22 * (17 - α) ^ 24 + 31934660245093795505928032518461564485995557345717410206365628000458801939061533187363710 * α ^ 23 * (17 - α) ^ 23 + 78047993066241081864729405263799058714155198199791825458167970252230959614239365881878947 * α ^ 24 * (17 - α) ^ 22 + 171134843936218514686150148288359364686859698322647460634859632067734173140627231359730584 * α ^ 25 * (17 - α) ^ 21 + 336206506050303051354999483042669483751718653067431091525204950883403868367567684342080020 * α ^ 26 * (17 - α) ^ 20 + 590632297194451478800263563954322310467842994277133756163742170600614302732421283888959208 * α ^ 27 * (17 - α) ^ 19 + 925516670394461047649865831225821273518368307653384139954083832567847096613665974954102740 * α ^ 28 * (17 - α) ^ 18 + 1289766645595527592343166744587741066182934225995347417854162835114044818241870914092204864 * α ^ 29 * (17 - α) ^ 17 + 1593002416141247767069378716733631264077333099250896896091743214673847829299190958471833770 * α ^ 30 * (17 - α) ^ 16 + 1737143176643046947303118633436476715799207563792300127093284518020249525152200860365809660 * α ^ 31 * (17 - α) ^ 15 + 1665311418235579100523754798782860220365664075295289918982682336006446972368945219112765174 * α ^ 32 * (17 - α) ^ 14 + 1396557360038252731643454796992613166665272986910499262544165249742942020476375868362815880 * α ^ 33 * (17 - α) ^ 13 + 1018684619224015379084223520647127025765305887834183888331474942254858102069742927480803487 * α ^ 34 * (17 - α) ^ 12 + 641932494254295073687856899416231301192107297550335297051507507404266419546500180865404214 * α ^ 35 * (17 - α) ^ 11 + 346616023624199508122240528681160766975802934453336786297349998221685206774349480865493785 * α ^ 36 * (17 - α) ^ 10 + 158769464897392551896561203035439621044410847226907537961532798384360622001611952908266388 * α ^ 37 * (17 - α) ^ 9 + 60938188611726643632686961457984989878294641295998164978961810053640858299331163879730855 * α ^ 38 * (17 - α) ^ 8 + 19303965900462850327232871938264169200849651337482672284417001334177009419208937264542474 * α ^ 39 * (17 - α) ^ 7 + 4956495620088219287305017176528775890173857965129426190480342928881513904895208113754297 * α ^ 40 * (17 - α) ^ 6 + 1011094459778786182680868888323794915088603327243667761590423358931583382786018989420280 * α ^ 41 * (17 - α) ^ 5 + 161129362690984017597830623141137027326076650900522288728417841096952993030031822930852 * α ^ 42 * (17 - α) ^ 4 + 20053630683210270088939005261620316062127222962442862223177250670635839018815183419080 * α ^ 43 * (17 - α) ^ 3 + 2007106897711885365446090180299995728598915866332529016566715378067994766096351142716 * α ^ 44 * (17 - α) ^ 2 + 160682627900417809962527853098762123815034415286611690425666398978372619671902878336 * α ^ 45 * (17 - α) ^ 1 + 7728635588004831865654878836695725660660992895290133611955913220528766346904639440 * α ^ 46 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 7591199764941595142535047667167496055166615766339109753578898560 * (17 - α) ^ 46 := - mul_pos (by norm_num) (pow_pos (by linarith) 46) - linarith - · have hpos : (0 : ℝ) < 7728635588004831865654878836695725660660992895290133611955913220528766346904639440 * α ^ 46 := - mul_pos (by norm_num) (pow_pos (by linarith) 46) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 46)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree50_51.lean b/Sendov/FiniteRange/Degree50_51.lean index c7b820f..150c1a5 100644 --- a/Sendov/FiniteRange/Degree50_51.lean +++ b/Sendov/FiniteRange/Degree50_51.lean @@ -88,113 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 1983296105822518649150892894549250995892425255171116289185883918750 + 15931100140393602368014405057264748941230464487163945499694824056650 * α + 61313644372277040962442376585817692381801159938853766654339532342642 * α ^ 2 + 150465161025803906984244548536621322753695053837703089058231205826774 * α ^ 3 + 264322010781344595257900949490583824621999776392907846339168572698350 * α ^ 4 + 353743281892829023763479373880774443309366799073302434018471557825110 * α ^ 5 + 374746430716099889392649480753262242691492748868863233615818683113210 * α ^ 6 + 322333251095138331750810376734129960862151553108003622673897471115306 * α ^ 7 + 229084605395415458859385031638216501003980492983719572433329563703882 * α ^ 8 + 136186580162004849698169069937707109921050663415979174616099970789410 * α ^ 9 + 68297183570273843739235319574922178848744148149317657527481287867250 * α ^ 10 + 29054555352882187051825924818349071162009825742437693416815288122330 * α ^ 11 + 10517845843096179861634152822549541177919036751909714056461382791068 * α ^ 12 + 3243051149627232957975285323520147924344852995685877267136094949840 * α ^ 13 + 850730079576852202812092212763343774803138893059657454552260134214 * α ^ 14 + 189221714566801413370144763019660859707489277898806302228701929446 * α ^ 15 + 35474208966373153737428171347789581229469589042109433569563529953 * α ^ 16 + 5554556457876028787144312502202971828015473429833975918437514119 * α ^ 17 + 716629519575982953947167029297978855992566816319461607180223069 * α ^ 18 + 74636427766751024769605292454839153620634666149147834232905931 * α ^ 19 + 6065508382815751088971849224267373808540598230608937163606579 * α ^ 20 + 356427540055849162043883615776918801250352493347841025665727 * α ^ 21 + 8010922898128612953822450660739207750975492597821084469545 * α ^ 22 - 13811768035257687091848436534105252716200722593308688700839 * α ^ 23 + 472347189731554483068916734651482362647265909534029610926 * α ^ 24 + 200645576218037265363448556666064462492230746541192244 * α ^ 25 + 100792254939342885252420783865617430196525578985330442 * α ^ 26 + 7091638050698434724340077137596634135844686246524912 * α ^ 27 + 285507048268244527798843379331968858452479422433048 * α ^ 28 + 6365143148445153742308391864889359416478446278784 * α ^ 29 - 16632500105576540446570710610087487983679864544 * α ^ 30 - 8141192900297447634759131458865132803547534592 * α ^ 31 - 400672640084661107358183665488704704596271232 * α ^ 32 - 12769723604511066119766459310752455613515776 * α ^ 33 - 309725769188807086499063690021928273938432 * α ^ 34 - 6036271221838887663385231842606805557248 * α ^ 35 - 96889509859715053751265427510064881664 * α ^ 36 - 1296670055323112890407391552598540288 * α ^ 37 - 14548305968728835978279387666579456 * α ^ 38 - 136967029538617142794633045934080 * α ^ 39 - 1078901766843439405240321966080 * α ^ 40 - 7063554191969670305537064960 * α ^ 41 - 38017498823635237609013248 * α ^ 42 - 165453035363695795896320 * α ^ 43 - 568050178195987103744 * α ^ 44 - 1481574358823469056 * α ^ 45 - 2759526258311168 * α ^ 46 - 3270533709824 * α ^ 47 - 1853882368 * α ^ 48 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 1983296105822518649150892894549250995892425255171116289185883918750 * (17 - α) ^ 48 := - mul_nonneg (by norm_num) (pow_nonneg hu 48) - have h1 : (0:ℝ) ≤ 366026915466172135415487744911864779803754308530000655375734437063050 * α ^ 1 * (17 - α) ^ 47 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 47) - have h2 : (0:ℝ) ≤ 32685750243130354166431563659107402625750332035405750191561966328636888 * α ^ 2 * (17 - α) ^ 46 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 46) - have h3 : (0:ℝ) ≤ 1881407841131145090841016986533759097730516052825808704231530487137780460 * α ^ 3 * (17 - α) ^ 45 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 45) - have h4 : (0:ℝ) ≤ 78459256689743329963134594253570543442212800051291261295613679735466812720 * α ^ 4 * (17 - α) ^ 44 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 44) - have h5 : (0:ℝ) ≤ 2526157710396158722925121199079871034544523911581723097994207618552592660140 * α ^ 5 * (17 - α) ^ 43 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 43) - have h6 : (0:ℝ) ≤ 65348270578398047737901045538231544926735111377759221708810966322205125102460 * α ^ 6 * (17 - α) ^ 42 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 42) - have h7 : (0:ℝ) ≤ 1395586695048529216219720727338181782409903542683661464665137976415266653947720 * α ^ 7 * (17 - α) ^ 41 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 41) - have h8 : (0:ℝ) ≤ 25091358961567861189485447956384974798693774013704426176176831023955755758143760 * α ^ 8 * (17 - α) ^ 40 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 40) - have h9 : (0:ℝ) ≤ 385389290374823447581872955370254873043506388116231648347871930606580590239210420 * α ^ 9 * (17 - α) ^ 39 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 39) - have h10 : (0:ℝ) ≤ 5114292252486869911885110308469289761839173642500394020070108012031543397685206240 * α ^ 10 * (17 - α) ^ 38 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 38) - have h11 : (0:ℝ) ≤ 59161256161938370784774347699829801724975303229316300011306943983966944681307590660 * α ^ 11 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 37) - have h12 : (0:ℝ) ≤ 600805106310323904417213469470448614536129232455343240574225543436663232620490973050 * α ^ 12 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 36) - have h13 : (0:ℝ) ≤ 5387148987622905002337912552695991101576356210279594139892815350033519190381631954018 * α ^ 13 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 35) - have h14 : (0:ℝ) ≤ 42848313014751656392801345211288230271187367670920575900488813020424662766115040908726 * α ^ 14 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 34) - have h15 : (0:ℝ) ≤ 303464032538826618020021810092246523076423327835808593359248630575577172669418455370662 * α ^ 15 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 33) - have h16 : (0:ℝ) ≤ 1919675052319908024894686554181462077949811954560704660857906175718223592208137349163213 * α ^ 16 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 32) - have h17 : (0:ℝ) ≤ 10874148852557470485141277547722227524021509120915887117480057293293644142032687753432339 * α ^ 17 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 31) - have h18 : (0:ℝ) ≤ 55271679208564823539840128254013152835651570970254641566356451199627461145310938188424982 * α ^ 18 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 30) - have h19 : (0:ℝ) ≤ 252503463116529357367558410529797790559166244171078469841324516308832648846176593953640464 * α ^ 19 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 29) - have h20 : (0:ℝ) ≤ 1038141469835606067593166733401008792243365429970694049028451636707468137313444745165939138 * α ^ 20 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 28) - have h21 : (0:ℝ) ≤ 3845092335628247042344655260236398462168031115874282430712913167859044335883180372818928032 * α ^ 21 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 27) - have h22 : (0:ℝ) ≤ 12839214422922060993100206502392817799511987618052955635827705879418137857456229303102002808 * α ^ 22 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 26) - have h23 : (0:ℝ) ≤ 38668985960763181946954732106269364443378192304730607843082220299380873795313006656808498078 * α ^ 23 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 25) - have h24 : (0:ℝ) ≤ 105069155536109812068244241812619770677190371101318523388390165019705025089023705073017992201 * α ^ 24 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 24) - have h25 : (0:ℝ) ≤ 257533243404978929099209346342414027031432812223519857139718344355911305954126811366525083697 * α ^ 25 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 23) - have h26 : (0:ℝ) ≤ 569147019919025772591890628632811032011859407504430878312206909813978377735116474357089719868 * α ^ 26 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 22) - have h27 : (0:ℝ) ≤ 1133018419963002695257135527792891577568016315310178309850366791483086891940574911149456141128 * α ^ 27 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 21) - have h28 : (0:ℝ) ≤ 2028823393084462551372573822881776536387839606739316015353770957756761466356425861534814818366 * α ^ 28 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 20) - have h29 : (0:ℝ) ≤ 3261422523223033546198612538770445764908099658312172165119166143094334561521557450816017566082 * α ^ 29 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 19) - have h30 : (0:ℝ) ≤ 4695570437669925151575494973682300710306869448714096516816247877812648326270233197019115846774 * α ^ 30 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 18) - have h31 : (0:ℝ) ≤ 6037682994028240913498413640341842161215563262372408190036046373359050231573990788555033536546 * α ^ 31 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 17) - have h32 : (0:ℝ) ≤ 6911350888808185279134128140957411320398266037074579187309898159530888623281682213973958805785 * α ^ 32 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 16) - have h33 : (0:ℝ) ≤ 7017723164655595521056126675946456567629553403101512610091781353726356232791660976553934912931 * α ^ 33 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 15) - have h34 : (0:ℝ) ≤ 6294935143237609226898430401643730433375800655100783828138379904195915445486580487224848524262 * α ^ 34 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 14) - have h35 : (0:ℝ) ≤ 4964878406314244868780111039956203509756923777921248038055860417036296541552216059906145098404 * α ^ 35 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 13) - have h36 : (0:ℝ) ≤ 3424306290318650239602511891398619048414623269656800653759902188565148030596558040360823787326 * α ^ 36 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 12) - have h37 : (0:ℝ) ≤ 2051958590995686906351648406832466203839543817560131729480349304645431078728413090667388003272 * α ^ 37 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 11) - have h38 : (0:ℝ) ≤ 1060005738961397201738580950863446006402895600697466546122050769062752312325491830374270906944 * α ^ 38 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 38)) (pow_nonneg hu 10) - have h39 : (0:ℝ) ≤ 467577400988976496475501234195271024537914612633016089768118387533173634164273126204352761938 * α ^ 39 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 39)) (pow_nonneg hu 9) - have h40 : (0:ℝ) ≤ 174055424381608100029944299500295460088946458918286120062437292805583013054742467588482744291 * α ^ 40 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 40)) (pow_nonneg hu 8) - have h41 : (0:ℝ) ≤ 53878846132574605007505800468792220908832004075393485465775528877910318074398454899271776059 * α ^ 41 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 41)) (pow_nonneg hu 7) - have h42 : (0:ℝ) ≤ 13614845621699809419890571355526634130837098707003964296944897175809602487667917307467989936 * α ^ 42 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 42)) (pow_nonneg hu 6) - have h43 : (0:ℝ) ≤ 2744159397807574020755344104224532395538285866763175087142310240707624213164183747296183828 * α ^ 43 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 43)) (pow_nonneg hu 5) - have h44 : (0:ℝ) ≤ 428866537260624574850004860175037680310285291204398039963565670689977450658379659200504216 * α ^ 44 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 44)) (pow_nonneg hu 4) - have h45 : (0:ℝ) ≤ 50333756227847631161716151257046024575567930432377627572895340197028609964017169960339112 * α ^ 45 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 45)) (pow_nonneg hu 3) - have h46 : (0:ℝ) ≤ 4302447045325735617429810226177479174756160321138468549855980238567434050919754100402688 * α ^ 46 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 46)) (pow_nonneg hu 2) - have h47 : (0:ℝ) ≤ 258744146897542242897425801777948395291136619450442877052536998228794692040701916234240 * α ^ 47 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 47)) (pow_nonneg hu 1) - have h48 : (0:ℝ) ≤ 9199351670117540067891308093632332055308176052079014496984569179145526721008475136000 * α ^ 48 := - mul_nonneg (by norm_num) (pow_nonneg hα 48) have hid : (17 : ℝ) ^ 48 * (1983296105822518649150892894549250995892425255171116289185883918750 + 15931100140393602368014405057264748941230464487163945499694824056650 * α + 61313644372277040962442376585817692381801159938853766654339532342642 * α ^ 2 + 150465161025803906984244548536621322753695053837703089058231205826774 * α ^ 3 + 264322010781344595257900949490583824621999776392907846339168572698350 * α ^ 4 + 353743281892829023763479373880774443309366799073302434018471557825110 * α ^ 5 + 374746430716099889392649480753262242691492748868863233615818683113210 * α ^ 6 + 322333251095138331750810376734129960862151553108003622673897471115306 * α ^ 7 + 229084605395415458859385031638216501003980492983719572433329563703882 * α ^ 8 + 136186580162004849698169069937707109921050663415979174616099970789410 * α ^ 9 + 68297183570273843739235319574922178848744148149317657527481287867250 * α ^ 10 + 29054555352882187051825924818349071162009825742437693416815288122330 * α ^ 11 + 10517845843096179861634152822549541177919036751909714056461382791068 * α ^ 12 + 3243051149627232957975285323520147924344852995685877267136094949840 * α ^ 13 + 850730079576852202812092212763343774803138893059657454552260134214 * α ^ 14 + 189221714566801413370144763019660859707489277898806302228701929446 * α ^ 15 + 35474208966373153737428171347789581229469589042109433569563529953 * α ^ 16 + 5554556457876028787144312502202971828015473429833975918437514119 * α ^ 17 + 716629519575982953947167029297978855992566816319461607180223069 * α ^ 18 + 74636427766751024769605292454839153620634666149147834232905931 * α ^ 19 + 6065508382815751088971849224267373808540598230608937163606579 * α ^ 20 + 356427540055849162043883615776918801250352493347841025665727 * α ^ 21 + 8010922898128612953822450660739207750975492597821084469545 * α ^ 22 - 13811768035257687091848436534105252716200722593308688700839 * α ^ 23 + 472347189731554483068916734651482362647265909534029610926 * α ^ 24 + 200645576218037265363448556666064462492230746541192244 * α ^ 25 + 100792254939342885252420783865617430196525578985330442 * α ^ 26 + 7091638050698434724340077137596634135844686246524912 * α ^ 27 + 285507048268244527798843379331968858452479422433048 * α ^ 28 + 6365143148445153742308391864889359416478446278784 * α ^ 29 - 16632500105576540446570710610087487983679864544 * α ^ 30 - 8141192900297447634759131458865132803547534592 * α ^ 31 - 400672640084661107358183665488704704596271232 * α ^ 32 - 12769723604511066119766459310752455613515776 * α ^ 33 - 309725769188807086499063690021928273938432 * α ^ 34 - 6036271221838887663385231842606805557248 * α ^ 35 - 96889509859715053751265427510064881664 * α ^ 36 - 1296670055323112890407391552598540288 * α ^ 37 - 14548305968728835978279387666579456 * α ^ 38 - 136967029538617142794633045934080 * α ^ 39 - 1078901766843439405240321966080 * α ^ 40 - 7063554191969670305537064960 * α ^ 41 - 38017498823635237609013248 * α ^ 42 - 165453035363695795896320 * α ^ 43 - 568050178195987103744 * α ^ 44 - 1481574358823469056 * α ^ 45 - 2759526258311168 * α ^ 46 - 3270533709824 * α ^ 47 - 1853882368 * α ^ 48) = 1983296105822518649150892894549250995892425255171116289185883918750 * (17 - α) ^ 48 + 366026915466172135415487744911864779803754308530000655375734437063050 * α ^ 1 * (17 - α) ^ 47 + 32685750243130354166431563659107402625750332035405750191561966328636888 * α ^ 2 * (17 - α) ^ 46 + 1881407841131145090841016986533759097730516052825808704231530487137780460 * α ^ 3 * (17 - α) ^ 45 + 78459256689743329963134594253570543442212800051291261295613679735466812720 * α ^ 4 * (17 - α) ^ 44 + 2526157710396158722925121199079871034544523911581723097994207618552592660140 * α ^ 5 * (17 - α) ^ 43 + 65348270578398047737901045538231544926735111377759221708810966322205125102460 * α ^ 6 * (17 - α) ^ 42 + 1395586695048529216219720727338181782409903542683661464665137976415266653947720 * α ^ 7 * (17 - α) ^ 41 + 25091358961567861189485447956384974798693774013704426176176831023955755758143760 * α ^ 8 * (17 - α) ^ 40 + 385389290374823447581872955370254873043506388116231648347871930606580590239210420 * α ^ 9 * (17 - α) ^ 39 + 5114292252486869911885110308469289761839173642500394020070108012031543397685206240 * α ^ 10 * (17 - α) ^ 38 + 59161256161938370784774347699829801724975303229316300011306943983966944681307590660 * α ^ 11 * (17 - α) ^ 37 + 600805106310323904417213469470448614536129232455343240574225543436663232620490973050 * α ^ 12 * (17 - α) ^ 36 + 5387148987622905002337912552695991101576356210279594139892815350033519190381631954018 * α ^ 13 * (17 - α) ^ 35 + 42848313014751656392801345211288230271187367670920575900488813020424662766115040908726 * α ^ 14 * (17 - α) ^ 34 + 303464032538826618020021810092246523076423327835808593359248630575577172669418455370662 * α ^ 15 * (17 - α) ^ 33 + 1919675052319908024894686554181462077949811954560704660857906175718223592208137349163213 * α ^ 16 * (17 - α) ^ 32 + 10874148852557470485141277547722227524021509120915887117480057293293644142032687753432339 * α ^ 17 * (17 - α) ^ 31 + 55271679208564823539840128254013152835651570970254641566356451199627461145310938188424982 * α ^ 18 * (17 - α) ^ 30 + 252503463116529357367558410529797790559166244171078469841324516308832648846176593953640464 * α ^ 19 * (17 - α) ^ 29 + 1038141469835606067593166733401008792243365429970694049028451636707468137313444745165939138 * α ^ 20 * (17 - α) ^ 28 + 3845092335628247042344655260236398462168031115874282430712913167859044335883180372818928032 * α ^ 21 * (17 - α) ^ 27 + 12839214422922060993100206502392817799511987618052955635827705879418137857456229303102002808 * α ^ 22 * (17 - α) ^ 26 + 38668985960763181946954732106269364443378192304730607843082220299380873795313006656808498078 * α ^ 23 * (17 - α) ^ 25 + 105069155536109812068244241812619770677190371101318523388390165019705025089023705073017992201 * α ^ 24 * (17 - α) ^ 24 + 257533243404978929099209346342414027031432812223519857139718344355911305954126811366525083697 * α ^ 25 * (17 - α) ^ 23 + 569147019919025772591890628632811032011859407504430878312206909813978377735116474357089719868 * α ^ 26 * (17 - α) ^ 22 + 1133018419963002695257135527792891577568016315310178309850366791483086891940574911149456141128 * α ^ 27 * (17 - α) ^ 21 + 2028823393084462551372573822881776536387839606739316015353770957756761466356425861534814818366 * α ^ 28 * (17 - α) ^ 20 + 3261422523223033546198612538770445764908099658312172165119166143094334561521557450816017566082 * α ^ 29 * (17 - α) ^ 19 + 4695570437669925151575494973682300710306869448714096516816247877812648326270233197019115846774 * α ^ 30 * (17 - α) ^ 18 + 6037682994028240913498413640341842161215563262372408190036046373359050231573990788555033536546 * α ^ 31 * (17 - α) ^ 17 + 6911350888808185279134128140957411320398266037074579187309898159530888623281682213973958805785 * α ^ 32 * (17 - α) ^ 16 + 7017723164655595521056126675946456567629553403101512610091781353726356232791660976553934912931 * α ^ 33 * (17 - α) ^ 15 + 6294935143237609226898430401643730433375800655100783828138379904195915445486580487224848524262 * α ^ 34 * (17 - α) ^ 14 + 4964878406314244868780111039956203509756923777921248038055860417036296541552216059906145098404 * α ^ 35 * (17 - α) ^ 13 + 3424306290318650239602511891398619048414623269656800653759902188565148030596558040360823787326 * α ^ 36 * (17 - α) ^ 12 + 2051958590995686906351648406832466203839543817560131729480349304645431078728413090667388003272 * α ^ 37 * (17 - α) ^ 11 + 1060005738961397201738580950863446006402895600697466546122050769062752312325491830374270906944 * α ^ 38 * (17 - α) ^ 10 + 467577400988976496475501234195271024537914612633016089768118387533173634164273126204352761938 * α ^ 39 * (17 - α) ^ 9 + 174055424381608100029944299500295460088946458918286120062437292805583013054742467588482744291 * α ^ 40 * (17 - α) ^ 8 + 53878846132574605007505800468792220908832004075393485465775528877910318074398454899271776059 * α ^ 41 * (17 - α) ^ 7 + 13614845621699809419890571355526634130837098707003964296944897175809602487667917307467989936 * α ^ 42 * (17 - α) ^ 6 + 2744159397807574020755344104224532395538285866763175087142310240707624213164183747296183828 * α ^ 43 * (17 - α) ^ 5 + 428866537260624574850004860175037680310285291204398039963565670689977450658379659200504216 * α ^ 44 * (17 - α) ^ 4 + 50333756227847631161716151257046024575567930432377627572895340197028609964017169960339112 * α ^ 45 * (17 - α) ^ 3 + 4302447045325735617429810226177479174756160321138468549855980238567434050919754100402688 * α ^ 46 * (17 - α) ^ 2 + 258744146897542242897425801777948395291136619450442877052536998228794692040701916234240 * α ^ 47 * (17 - α) ^ 1 + 9199351670117540067891308093632332055308176052079014496984569179145526721008475136000 * α ^ 48 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 1983296105822518649150892894549250995892425255171116289185883918750 * (17 - α) ^ 48 := - mul_pos (by norm_num) (pow_pos (by linarith) 48) - linarith - · have hpos : (0 : ℝ) < 9199351670117540067891308093632332055308176052079014496984569179145526721008475136000 * α ^ 48 := - mul_pos (by norm_num) (pow_pos (by linarith) 48) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 48)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree52_53.lean b/Sendov/FiniteRange/Degree52_53.lean index 9a6c628..601d726 100644 --- a/Sendov/FiniteRange/Degree52_53.lean +++ b/Sendov/FiniteRange/Degree52_53.lean @@ -88,117 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 2158786206398835455807414614345741946541113771140909309351827456752112 + 18060881628885317183903129865386184210636931259177004847461943403431248 * α + 72523751526913871689914498063741871627156282998221168488328768408227884 * α ^ 2 + 186043952493859430608709083701039329302003956855619351393577019518308656 * α ^ 3 + 342352186792731735464993586128215688813987853593111908601035784489017584 * α ^ 4 + 481039143350973516581843203115060631357333955017066302301078896484075192 * α ^ 5 + 536385148360730976146799557733557814318777038771883620685910931111117598 * α ^ 6 + 486973177459613828942749054605832894034828444342062183629433383012760968 * α ^ 7 + 366445983498710745663941283884031432424266298307553290495228389566314580 * α ^ 8 + 231462963120661901399357408339235733527085751003762699569336649733064704 * α ^ 9 + 123822723544233720819377342496077302912265601255690207194574592762760382 * α ^ 10 + 56444234764084989462828858083829787816765813106300946212401546188828432 * α ^ 11 + 22008608122728995449205242852102476325631469834261804695394906754027728 * α ^ 12 + 7353623809616680357566863259021705228111970073628547653529150957921848 * α ^ 13 + 2105293430360560851822138859793778045699608135112104910406227699186678 * α ^ 14 + 515430709094276322360222922253268287610570499499448923895934548603720 * α ^ 15 + 107478868042826110622436885067609215622378470268066806044658545978916 * α ^ 16 + 18965619675038957214919858400770522577747376668487077296700550484152 * α ^ 17 + 2805160201379690314111348362084950864952366379855375613165120590980 * α ^ 18 + 342991269135314358321380120239307230093856195186954782184086092504 * α ^ 19 + 33962560439249200363255807231186470161851488347615308016008248384 * α ^ 20 + 2633515219064481554671199294750396033142024306631342141117342380 * α ^ 21 + 148633574270813874422290547923622884359972747318157801476955959 * α ^ 22 + 3403031020239585108295877062230213266408608085674454931323988 * α ^ 23 - 5379021087810236884979508991939865813601169242801548152141926 * α ^ 24 + 177301236343156026391795710864319371980311028891458462428744 * α ^ 25 - 40911700701069253972939511638042802470451085773720769927 * α ^ 26 + 27847404177739803963243561747514551473461230777429543312 * α ^ 27 + 2163155861798102819189036458258553844449886588504682104 * α ^ 28 + 93357595651430156400551007018380753717170652754834528 * α ^ 29 + 2393234358116242034523747708494764119251642322824544 * α ^ 30 + 15013048286137658650612509829061430420471401902848 * α ^ 31 - 1842593441930339010973203854928850324437642558336 * α ^ 32 - 107353306964614466200187553508809370311222440448 * α ^ 33 - 3666162111111306744447755601199086059560935168 * α ^ 34 - 93356644345705005900818038532098756222427136 * α ^ 35 - 1900483230089570865170384480343133786767360 * α ^ 36 - 31876662776993730438299978705884181495808 * α ^ 37 - 447245036738485694487463467137714307072 * α ^ 38 - 5288819621114196078630291364843487232 * α ^ 39 - 52859730633810963643011459678732288 * α ^ 40 - 446161546901880234704034758393856 * α ^ 41 - 3167349500047341936592130605056 * α ^ 42 - 18770907855391026630248890368 * α ^ 43 - 91797189183100371092373504 * α ^ 44 - 364189492779598108164096 * α ^ 45 - 1143139551315216039936 * α ^ 46 - 2732815988096499712 * α ^ 47 - 4676225293352960 * α ^ 48 - 5102186266624 * α ^ 49 - 2667577344 * α ^ 50 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 2158786206398835455807414614345741946541113771140909309351827456752112 * (17 - α) ^ 50 := - mul_nonneg (by norm_num) (pow_nonneg hu 50) - have h1 : (0:ℝ) ≤ 414974298010992164916723938428852228907883519963054547874444410695936816 * α ^ 1 * (17 - α) ^ 49 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 49) - have h2 : (0:ℝ) ≤ 38648591690978151565940680020861626232221593895027976635018801559557425260 * α ^ 2 * (17 - α) ^ 48 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 48) - have h3 : (0:ℝ) ≤ 2323468774953773046737498344073410604963916757430810426040495562926126538992 * α ^ 3 * (17 - α) ^ 47 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 47) - have h4 : (0:ℝ) ≤ 101349335991740593349006338670862435683901636675912397673964231014026337776992 * α ^ 4 * (17 - α) ^ 46 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 46) - have h5 : (0:ℝ) ≤ 3418523402240372565025362732012218197017682799224385182741003587603019322270088 * α ^ 5 * (17 - α) ^ 45 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 45) - have h6 : (0:ℝ) ≤ 92795830318460904167075752328056310590909312937624225610579756886634415607753926 * α ^ 6 * (17 - α) ^ 44 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 44) - have h7 : (0:ℝ) ≤ 2083150548513343067461154384073343753088328081203102895466392639042540698472213552 * α ^ 7 * (17 - α) ^ 43 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 43) - have h8 : (0:ℝ) ≤ 39441282325689010460905068005007464787875697034233161641025817719437629586599815832 * α ^ 8 * (17 - α) ^ 42 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 42) - have h9 : (0:ℝ) ≤ 639183212529869482732967509857029817382349276322171871286037804499595169420221724576 * α ^ 9 * (17 - α) ^ 41 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 41) - have h10 : (0:ℝ) ≤ 8967891289317846323424522756456515361904817651455107492105958263498697039942754607804 * α ^ 10 * (17 - α) ^ 40 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 40) - have h11 : (0:ℝ) ≤ 109912662905773911775785651830599814138152716415593519404830837106463824445813386386608 * α ^ 11 * (17 - α) ^ 39 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 39) - have h12 : (0:ℝ) ≤ 1185288664388902189248806437812380279610975615235779015443672285781708714559807760293128 * α ^ 12 * (17 - α) ^ 38 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 38) - have h13 : (0:ℝ) ≤ 11312386017398730692131184641629356719495877419525070049772377844481537989327971120696960 * α ^ 13 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 37) - have h14 : (0:ℝ) ≤ 96008520633756064409983434244275286680745229190958399353722082141681347511927190938190428 * α ^ 14 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 36) - have h15 : (0:ℝ) ≤ 727433466208182128845968339617608516747540980223663657764849247640353461478732223298149376 * α ^ 15 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 35) - have h16 : (0:ℝ) ≤ 4936366709381111751784857730466957485889673194213489796538376360678509233705016565561219568 * α ^ 16 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 34) - have h17 : (0:ℝ) ≤ 30082088254960095366958957594286135042878514883960848835770199866562115806088375067362801128 * α ^ 17 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 33) - have h18 : (0:ℝ) ≤ 164985102649690123319061978345185000778850953533122226871900814573805405999712146966652623130 * α ^ 18 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 32) - have h19 : (0:ℝ) ≤ 815818288201891083392614882901171467483608622704000551448258747708939293642643211380800205624 * α ^ 19 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 31) - have h20 : (0:ℝ) ≤ 3642346364254930209461654350984048884263119419677776197894819995644826784702649307916488655048 * α ^ 20 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 30) - have h21 : (0:ℝ) ≤ 14699642422912871844500841018776542189279022499143301125114403207390856393770245321897888096820 * α ^ 21 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 29) - have h22 : (0:ℝ) ≤ 53673006585933151650707212393612027990337017921471920103972688477444212042080888181402531954623 * α ^ 22 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 28) - have h23 : (0:ℝ) ≤ 177424630381056553613555892437643150189372774889210179326490713116128958479669098035885345446552 * α ^ 23 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 27) - have h24 : (0:ℝ) ≤ 531217322618016492802133586903649391958733336005082950612572311095808910788505345175592814369580 * α ^ 24 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 26) - have h25 : (0:ℝ) ≤ 1440878297786625726057735963735191129687061087876632335989525965863749961422678931848398180994264 * α ^ 25 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 25) - have h26 : (0:ℝ) ≤ 3540528972380530248060021030700986765668663375909521118259073708483300881659592107503593191364768 * α ^ 26 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 24) - have h27 : (0:ℝ) ≤ 7878706067439138302871644596778500496033461935373897042861066792548444034343472542257091147209584 * α ^ 27 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 23) - have h28 : (0:ℝ) ≤ 15866985172027478682631903171788637970460063980973228429209846911200894587882339479475867198952036 * α ^ 28 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 22) - have h29 : (0:ℝ) ≤ 28888250810289606634245191706663186299318801988344278179610334690859848174281402135692480432780132 * α ^ 29 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 21) - have h30 : (0:ℝ) ≤ 47477629548102243528458217920917101013725287450823186845340936391317439940465355556234941946032657 * α ^ 30 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 20) - have h31 : (0:ℝ) ≤ 70302798619149431656063874867631560161982110726463060425195857474073971124206669994193325260431968 * α ^ 31 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 19) - have h32 : (0:ℝ) ≤ 93578532127885660914680781758934948491041981899416935218375174036595572222667517918310377720198808 * α ^ 32 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 18) - have h33 : (0:ℝ) ≤ 111671046495563139231753996807194588715349583644959990280095487148731493003528163756917394817921848 * α ^ 33 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 17) - have h34 : (0:ℝ) ≤ 119108317519314874116452075964414453573552081166001011602192516430347593073861906203222286276783210 * α ^ 34 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 16) - have h35 : (0:ℝ) ≤ 113156360454221734073606765068373900287501266200716732578873162490509611564763213724059111444879912 * α ^ 35 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 15) - have h36 : (0:ℝ) ≤ 95376447959581379971158449180838329759355945573810871902930153136280190435130420456031549759592432 * α ^ 36 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 14) - have h37 : (0:ℝ) ≤ 71000547856694915769126077715715772989720497286001979959236111644677764746629355003121324873743636 * α ^ 37 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 13) - have h38 : (0:ℝ) ≤ 46435247311237875241086804176274841256465196204557482607524607905695835753570599397044472496443683 * α ^ 38 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 38)) (pow_nonneg hu 12) - have h39 : (0:ℝ) ≤ 26514718964077437868313478305791884794282002198254450319170212656068940296217672260748146187929000 * α ^ 39 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 39)) (pow_nonneg hu 11) - have h40 : (0:ℝ) ≤ 13119684648080558068145400061379201620208126873006769889319790885496821503611538738560892688675108 * α ^ 40 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 40)) (pow_nonneg hu 10) - have h41 : (0:ℝ) ≤ 5574304384447257915334770015429223070725790686644478804358809424096493843062858412483691392992136 * α ^ 41 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 41)) (pow_nonneg hu 9) - have h42 : (0:ℝ) ≤ 2010881865895736598424115789062219791810721593821299429086893216589613227274491543685953304227120 * α ^ 42 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 42)) (pow_nonneg hu 8) - have h43 : (0:ℝ) ≤ 607237389577241841869363680453643402590101734012060773034199963895826888891782257735573905657616 * α ^ 43 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 43)) (pow_nonneg hu 7) - have h44 : (0:ℝ) ≤ 150749895847577632681470277527543538771101449370569486067541118295682832958042871499658490290684 * α ^ 44 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 44)) (pow_nonneg hu 6) - have h45 : (0:ℝ) ≤ 30052820272696317463395531462440009839882141116365183097551075391516536642298874821618150390348 * α ^ 45 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 45)) (pow_nonneg hu 5) - have h46 : (0:ℝ) ≤ 4663688556843488364172070998639274132596372023847717839521027547698552604606780971945788903755 * α ^ 46 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 46)) (pow_nonneg hu 4) - have h47 : (0:ℝ) ≤ 540081530702743610283233889828122230493014768961119305004582751972922686852640193916287106992 * α ^ 47 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 47)) (pow_nonneg hu 3) - have h48 : (0:ℝ) ≤ 43983793487190009087693541621146525651052894618594476651626932794533461019682370365887330080 * α ^ 48 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 48)) (pow_nonneg hu 2) - have h49 : (0:ℝ) ≤ 2295554691290398410917187961072648259042029375130142853380489371587928525721201467534862000 * α ^ 49 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 49)) (pow_nonneg hu 1) - have h50 : (0:ℝ) ≤ 61696825755958662910832536044204740555351244465959101505141229428727029482047853259288100 * α ^ 50 := - mul_nonneg (by norm_num) (pow_nonneg hα 50) have hid : (17 : ℝ) ^ 50 * (2158786206398835455807414614345741946541113771140909309351827456752112 + 18060881628885317183903129865386184210636931259177004847461943403431248 * α + 72523751526913871689914498063741871627156282998221168488328768408227884 * α ^ 2 + 186043952493859430608709083701039329302003956855619351393577019518308656 * α ^ 3 + 342352186792731735464993586128215688813987853593111908601035784489017584 * α ^ 4 + 481039143350973516581843203115060631357333955017066302301078896484075192 * α ^ 5 + 536385148360730976146799557733557814318777038771883620685910931111117598 * α ^ 6 + 486973177459613828942749054605832894034828444342062183629433383012760968 * α ^ 7 + 366445983498710745663941283884031432424266298307553290495228389566314580 * α ^ 8 + 231462963120661901399357408339235733527085751003762699569336649733064704 * α ^ 9 + 123822723544233720819377342496077302912265601255690207194574592762760382 * α ^ 10 + 56444234764084989462828858083829787816765813106300946212401546188828432 * α ^ 11 + 22008608122728995449205242852102476325631469834261804695394906754027728 * α ^ 12 + 7353623809616680357566863259021705228111970073628547653529150957921848 * α ^ 13 + 2105293430360560851822138859793778045699608135112104910406227699186678 * α ^ 14 + 515430709094276322360222922253268287610570499499448923895934548603720 * α ^ 15 + 107478868042826110622436885067609215622378470268066806044658545978916 * α ^ 16 + 18965619675038957214919858400770522577747376668487077296700550484152 * α ^ 17 + 2805160201379690314111348362084950864952366379855375613165120590980 * α ^ 18 + 342991269135314358321380120239307230093856195186954782184086092504 * α ^ 19 + 33962560439249200363255807231186470161851488347615308016008248384 * α ^ 20 + 2633515219064481554671199294750396033142024306631342141117342380 * α ^ 21 + 148633574270813874422290547923622884359972747318157801476955959 * α ^ 22 + 3403031020239585108295877062230213266408608085674454931323988 * α ^ 23 - 5379021087810236884979508991939865813601169242801548152141926 * α ^ 24 + 177301236343156026391795710864319371980311028891458462428744 * α ^ 25 - 40911700701069253972939511638042802470451085773720769927 * α ^ 26 + 27847404177739803963243561747514551473461230777429543312 * α ^ 27 + 2163155861798102819189036458258553844449886588504682104 * α ^ 28 + 93357595651430156400551007018380753717170652754834528 * α ^ 29 + 2393234358116242034523747708494764119251642322824544 * α ^ 30 + 15013048286137658650612509829061430420471401902848 * α ^ 31 - 1842593441930339010973203854928850324437642558336 * α ^ 32 - 107353306964614466200187553508809370311222440448 * α ^ 33 - 3666162111111306744447755601199086059560935168 * α ^ 34 - 93356644345705005900818038532098756222427136 * α ^ 35 - 1900483230089570865170384480343133786767360 * α ^ 36 - 31876662776993730438299978705884181495808 * α ^ 37 - 447245036738485694487463467137714307072 * α ^ 38 - 5288819621114196078630291364843487232 * α ^ 39 - 52859730633810963643011459678732288 * α ^ 40 - 446161546901880234704034758393856 * α ^ 41 - 3167349500047341936592130605056 * α ^ 42 - 18770907855391026630248890368 * α ^ 43 - 91797189183100371092373504 * α ^ 44 - 364189492779598108164096 * α ^ 45 - 1143139551315216039936 * α ^ 46 - 2732815988096499712 * α ^ 47 - 4676225293352960 * α ^ 48 - 5102186266624 * α ^ 49 - 2667577344 * α ^ 50) = 2158786206398835455807414614345741946541113771140909309351827456752112 * (17 - α) ^ 50 + 414974298010992164916723938428852228907883519963054547874444410695936816 * α ^ 1 * (17 - α) ^ 49 + 38648591690978151565940680020861626232221593895027976635018801559557425260 * α ^ 2 * (17 - α) ^ 48 + 2323468774953773046737498344073410604963916757430810426040495562926126538992 * α ^ 3 * (17 - α) ^ 47 + 101349335991740593349006338670862435683901636675912397673964231014026337776992 * α ^ 4 * (17 - α) ^ 46 + 3418523402240372565025362732012218197017682799224385182741003587603019322270088 * α ^ 5 * (17 - α) ^ 45 + 92795830318460904167075752328056310590909312937624225610579756886634415607753926 * α ^ 6 * (17 - α) ^ 44 + 2083150548513343067461154384073343753088328081203102895466392639042540698472213552 * α ^ 7 * (17 - α) ^ 43 + 39441282325689010460905068005007464787875697034233161641025817719437629586599815832 * α ^ 8 * (17 - α) ^ 42 + 639183212529869482732967509857029817382349276322171871286037804499595169420221724576 * α ^ 9 * (17 - α) ^ 41 + 8967891289317846323424522756456515361904817651455107492105958263498697039942754607804 * α ^ 10 * (17 - α) ^ 40 + 109912662905773911775785651830599814138152716415593519404830837106463824445813386386608 * α ^ 11 * (17 - α) ^ 39 + 1185288664388902189248806437812380279610975615235779015443672285781708714559807760293128 * α ^ 12 * (17 - α) ^ 38 + 11312386017398730692131184641629356719495877419525070049772377844481537989327971120696960 * α ^ 13 * (17 - α) ^ 37 + 96008520633756064409983434244275286680745229190958399353722082141681347511927190938190428 * α ^ 14 * (17 - α) ^ 36 + 727433466208182128845968339617608516747540980223663657764849247640353461478732223298149376 * α ^ 15 * (17 - α) ^ 35 + 4936366709381111751784857730466957485889673194213489796538376360678509233705016565561219568 * α ^ 16 * (17 - α) ^ 34 + 30082088254960095366958957594286135042878514883960848835770199866562115806088375067362801128 * α ^ 17 * (17 - α) ^ 33 + 164985102649690123319061978345185000778850953533122226871900814573805405999712146966652623130 * α ^ 18 * (17 - α) ^ 32 + 815818288201891083392614882901171467483608622704000551448258747708939293642643211380800205624 * α ^ 19 * (17 - α) ^ 31 + 3642346364254930209461654350984048884263119419677776197894819995644826784702649307916488655048 * α ^ 20 * (17 - α) ^ 30 + 14699642422912871844500841018776542189279022499143301125114403207390856393770245321897888096820 * α ^ 21 * (17 - α) ^ 29 + 53673006585933151650707212393612027990337017921471920103972688477444212042080888181402531954623 * α ^ 22 * (17 - α) ^ 28 + 177424630381056553613555892437643150189372774889210179326490713116128958479669098035885345446552 * α ^ 23 * (17 - α) ^ 27 + 531217322618016492802133586903649391958733336005082950612572311095808910788505345175592814369580 * α ^ 24 * (17 - α) ^ 26 + 1440878297786625726057735963735191129687061087876632335989525965863749961422678931848398180994264 * α ^ 25 * (17 - α) ^ 25 + 3540528972380530248060021030700986765668663375909521118259073708483300881659592107503593191364768 * α ^ 26 * (17 - α) ^ 24 + 7878706067439138302871644596778500496033461935373897042861066792548444034343472542257091147209584 * α ^ 27 * (17 - α) ^ 23 + 15866985172027478682631903171788637970460063980973228429209846911200894587882339479475867198952036 * α ^ 28 * (17 - α) ^ 22 + 28888250810289606634245191706663186299318801988344278179610334690859848174281402135692480432780132 * α ^ 29 * (17 - α) ^ 21 + 47477629548102243528458217920917101013725287450823186845340936391317439940465355556234941946032657 * α ^ 30 * (17 - α) ^ 20 + 70302798619149431656063874867631560161982110726463060425195857474073971124206669994193325260431968 * α ^ 31 * (17 - α) ^ 19 + 93578532127885660914680781758934948491041981899416935218375174036595572222667517918310377720198808 * α ^ 32 * (17 - α) ^ 18 + 111671046495563139231753996807194588715349583644959990280095487148731493003528163756917394817921848 * α ^ 33 * (17 - α) ^ 17 + 119108317519314874116452075964414453573552081166001011602192516430347593073861906203222286276783210 * α ^ 34 * (17 - α) ^ 16 + 113156360454221734073606765068373900287501266200716732578873162490509611564763213724059111444879912 * α ^ 35 * (17 - α) ^ 15 + 95376447959581379971158449180838329759355945573810871902930153136280190435130420456031549759592432 * α ^ 36 * (17 - α) ^ 14 + 71000547856694915769126077715715772989720497286001979959236111644677764746629355003121324873743636 * α ^ 37 * (17 - α) ^ 13 + 46435247311237875241086804176274841256465196204557482607524607905695835753570599397044472496443683 * α ^ 38 * (17 - α) ^ 12 + 26514718964077437868313478305791884794282002198254450319170212656068940296217672260748146187929000 * α ^ 39 * (17 - α) ^ 11 + 13119684648080558068145400061379201620208126873006769889319790885496821503611538738560892688675108 * α ^ 40 * (17 - α) ^ 10 + 5574304384447257915334770015429223070725790686644478804358809424096493843062858412483691392992136 * α ^ 41 * (17 - α) ^ 9 + 2010881865895736598424115789062219791810721593821299429086893216589613227274491543685953304227120 * α ^ 42 * (17 - α) ^ 8 + 607237389577241841869363680453643402590101734012060773034199963895826888891782257735573905657616 * α ^ 43 * (17 - α) ^ 7 + 150749895847577632681470277527543538771101449370569486067541118295682832958042871499658490290684 * α ^ 44 * (17 - α) ^ 6 + 30052820272696317463395531462440009839882141116365183097551075391516536642298874821618150390348 * α ^ 45 * (17 - α) ^ 5 + 4663688556843488364172070998639274132596372023847717839521027547698552604606780971945788903755 * α ^ 46 * (17 - α) ^ 4 + 540081530702743610283233889828122230493014768961119305004582751972922686852640193916287106992 * α ^ 47 * (17 - α) ^ 3 + 43983793487190009087693541621146525651052894618594476651626932794533461019682370365887330080 * α ^ 48 * (17 - α) ^ 2 + 2295554691290398410917187961072648259042029375130142853380489371587928525721201467534862000 * α ^ 49 * (17 - α) ^ 1 + 61696825755958662910832536044204740555351244465959101505141229428727029482047853259288100 * α ^ 50 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 2158786206398835455807414614345741946541113771140909309351827456752112 * (17 - α) ^ 50 := - mul_pos (by norm_num) (pow_pos (by linarith) 50) - linarith - · have hpos : (0 : ℝ) < 61696825755958662910832536044204740555351244465959101505141229428727029482047853259288100 * α ^ 50 := - mul_pos (by norm_num) (pow_pos (by linarith) 50) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 50)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree54_55.lean b/Sendov/FiniteRange/Degree54_55.lean index 1ede8d8..db146b8 100644 --- a/Sendov/FiniteRange/Degree54_55.lean +++ b/Sendov/FiniteRange/Degree54_55.lean @@ -88,121 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 16494167009921791229556693354250558994004960089275608134952301595194145700 + 143495585732014632876947701159299432571935297872102967009453889788942630516 * α + 600146981561757364071810080610152109467421702720565940343744136045710714240 * α ^ 2 + 1606309613433661462999425062531603257368288440796455160921241994205807550800 * α ^ 3 + 3089935016411981969366335770505513109414946535522135899534602918518452400110 * α ^ 4 + 4548021756358959061868607547427969034568735681024830591427930680507708516630 * α ^ 5 + 5324472427116589963068442803453435582254682183625311260959169925128717206890 * α ^ 6 + 5088112301464007763161223382731859106222272351099136492562868432790050748010 * α ^ 7 + 4041350342582910718376698346793695673500055519225008392201038233346955184130 * α ^ 8 + 2702810799510161555412033309004487136564483291932054239796551253387958338250 * α ^ 9 + 1536279381058752516392997665745371680813310918710686404622076783423411472310 * α ^ 10 + 747035505761971294025842500370255312982388584883798779389925639599781539110 * α ^ 11 + 312120280284390297007832319287765858778034126483703719026036710712245847630 * α ^ 12 + 112328303645112191177480265164326260518118446637968730517219246030090061670 * α ^ 13 + 34847965479991464020760392422930205817393828567231232594447128943554577950 * α ^ 14 + 9311065733578254803436313728561027301061995457613177507038687159207136510 * α ^ 15 + 2137053395968205693740631086110584184448273974022381233594071100920418660 * α ^ 16 + 419415497303046617346927271099007566525536754801411545759490611489535020 * α ^ 17 + 69903195768650128169410986270066096062738214853608222509952701694930390 * α ^ 18 + 9796751930080145102336247171862671684216870902559058128633974960508990 * α ^ 19 + 1138373287745887689323718901024639495300275153431093749751357684888655 * α ^ 20 + 107431234099507044305505224510335533709977858803000709455555262812475 * α ^ 21 + 7965572671696337257969240111258550023673082988480052797472718090765 * α ^ 22 + 432489851677951286849434341419775059089962332363725955872440307245 * α ^ 23 + 10033042060175777949356539605564287060646991070535569056012261935 * α ^ 24 - 14665345174670112106333566037790518499419114767637006814333117685 * α ^ 25 + 467265281717233365794825008753399741068194685496332969035489307 * α ^ 26 - 338571739674856609859042128682071390079128171355900195378565 * α ^ 27 + 51828010052697170919200272082439937455364221416970311841360 * α ^ 28 + 4551610675134221759317748807561457084971246067804745378320 * α ^ 29 + 209779510423918524619133931870713143087995729911985149040 * α ^ 30 + 5970127197067432618593627815816805105135662362948064640 * α ^ 31 + 72450550286061369082689048114099286472057904479048640 * α ^ 32 - 2583219468428786599910558481880637801957466132337920 * α ^ 33 - 195852731109616002368456744436432386876454107873280 * α ^ 34 - 7247973580231951783404261339025545494805311297280 * α ^ 35 - 194124681108967495056283792222752779031406556160 * α ^ 36 - 4123433450448809567758812935503400791570882560 * α ^ 37 - 72082021160947668781050521228246549326725120 * α ^ 38 - 1056193512343203991501036178583787410636800 * α ^ 39 - 13096880010730035770569022035700611809280 * α ^ 40 - 138052872308930943537538309704895365120 * α ^ 41 - 1238136265130428487231808151440916480 * α ^ 42 - 9428378825017111932776968669429760 * α ^ 43 - 60659413041205873935423111168000 * α ^ 44 - 327048428909975887634922209280 * α ^ 45 - 1459908719275463855607644160 * α ^ 46 - 5302273507938488014602240 * α ^ 47 - 15275608180278584934400 * α ^ 48 - 33595607399404666880 * α ^ 49 - 52996826537656320 * α ^ 50 - 53409512161280 * α ^ 51 - 25836912640 * α ^ 52 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 16494167009921791229556693354250558994004960089275608134952301595194145700 * (17 - α) ^ 52 := - mul_nonneg (by norm_num) (pow_nonneg hu 52) - have h1 : (0:ℝ) ≤ 3297121641960181902845058974129119421411157988468082062178235809362120295172 * α ^ 1 * (17 - α) ^ 51 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 51) - have h2 : (0:ℝ) ≤ 319724415956160860091458945589182808902003352419736285543485329679451094270932 * α ^ 2 * (17 - α) ^ 50 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 50) - have h3 : (0:ℝ) ≤ 20038710926027661432334875342791217340018851913295984793285523609822774454252700 * α ^ 3 * (17 - α) ^ 49 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 49) - have h4 : (0:ℝ) ≤ 912506063164863213831944030666321098534650758920349287477777497262175240738402310 * α ^ 4 * (17 - α) ^ 48 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 48) - have h5 : (0:ℝ) ≤ 32177823044530476695020659335002454111188404373175841794915018442377955651394113990 * α ^ 5 * (17 - α) ^ 47 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 47) - have h6 : (0:ℝ) ≤ 914540681282828800807599319891793843292641936770051259660032453172015089441416681780 * α ^ 6 * (17 - α) ^ 46 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 46) - have h7 : (0:ℝ) ≤ 21529723418168081854258856249066854725157410727767949291151621244500815386654814167180 * α ^ 7 * (17 - α) ^ 45 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 45) - have h8 : (0:ℝ) ≤ 428187563876954541113963075618060221598963677578037826566438784007708913233247747176780 * α ^ 8 * (17 - α) ^ 44 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 44) - have h9 : (0:ℝ) ≤ 7301844169441283547821796282852027526162858087792900418706107149330943728664004086739660 * α ^ 9 * (17 - α) ^ 43 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 43) - have h10 : (0:ℝ) ≤ 107998890241658105222949402539269436370829457640263205565353289295418525536340771107662680 * α ^ 10 * (17 - α) ^ 42 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 42) - have h11 : (0:ℝ) ≤ 1398093827433571704042090344538943552073638570463931753295281987815735454006786470999735160 * α ^ 11 * (17 - α) ^ 41 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 41) - have h12 : (0:ℝ) ≤ 15957032127861583576984677012499030521875944161240621820452635989220785757028810049931646660 * α ^ 12 * (17 - α) ^ 40 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 40) - have h13 : (0:ℝ) ≤ 161526877975623854315474231221259866905794267588621234412370551845474892520146496256658344580 * α ^ 13 * (17 - α) ^ 39 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 39) - have h14 : (0:ℝ) ≤ 1457239742403607406416443184401351553341986505900117649824594649023236812024794234917099752380 * α ^ 14 * (17 - α) ^ 38 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 38) - have h15 : (0:ℝ) ≤ 11764118385331183795485731464799855976003853373075619337664964031988252913700051042473465972420 * α ^ 15 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 37) - have h16 : (0:ℝ) ≤ 85266812327847025363233082778590085924666659056638604615146724746162734347495123483376596599070 * α ^ 16 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 36) - have h17 : (0:ℝ) ≤ 556412933665661316562603334092469787110651645009094640295939461919699008524178193574911456908110 * α ^ 17 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 35) - have h18 : (0:ℝ) ≤ 3276500502586555718746248192880369763373913284974973228696609120912342926842381883477115970971330 * α ^ 18 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 34) - have h19 : (0:ℝ) ≤ 17443973618063549860197174258607173645342170656659807634029925978540184960307013051100945108575830 * α ^ 19 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 33) - have h20 : (0:ℝ) ≤ 84097208992473763322482498841713994615424570017542204453635043962819422256085229322643661036553135 * α ^ 20 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 32) - have h21 : (0:ℝ) ≤ 367595670215331608081325934241054123019019558617664793950031213417886531914880453450235055639827695 * α ^ 21 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 31) - have h22 : (0:ℝ) ≤ 1458319292273003092992284569774617261635353524450745892916673491633645545947909275323789971386584010 * α ^ 22 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 30) - have h23 : (0:ℝ) ≤ 5254980271354566622530408171222928163731186808057577088774647757156770300739259401327506864767179590 * α ^ 23 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 29) - have h24 : (0:ℝ) ≤ 17209987305609188388593928884348304692679416452958887120667494264685355764336243613006433529300889900 * α ^ 24 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 28) - have h25 : (0:ℝ) ≤ 51245313767700576927493227999999199039753952598947831546238937797935220706183422086338270920360486300 * α ^ 25 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 27) - have h26 : (0:ℝ) ≤ 138766478666356226035473697072120508245376894603069112986887914209096091729659135725891961666489860662 * α ^ 26 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 26) - have h27 : (0:ℝ) ≤ 341725720150049744585959626125868368010499310869413614657759212314754963597840236324448419782451114282 * α ^ 27 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 25) - have h28 : (0:ℝ) ≤ 765136285933410012453175445478517650702161463656786558161202904376215029605986594283307478093304307385 * α ^ 28 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 24) - have h29 : (0:ℝ) ≤ 1556877403438278759283881545391171005360005954054145030966940257959498891624213557816408094093075864665 * α ^ 29 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 23) - have h30 : (0:ℝ) ≤ 2876564405128945633873865865688129358774847644012865518697098702186811357802016717785624061301955829430 * α ^ 30 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 22) - have h31 : (0:ℝ) ≤ 4820561162618100599568269482213420070663798726185647089067973322799735823546946658344673073602139469970 * α ^ 31 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 21) - have h32 : (0:ℝ) ≤ 7315920828232011027352935983664196353610979185130017647700999674444485613522154300362261069304268308590 * α ^ 32 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 20) - have h33 : (0:ℝ) ≤ 10036378526288476516030178366360979243689435681024753191393010979431912513169664181917187452264705749630 * α ^ 33 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 19) - have h34 : (0:ℝ) ≤ 12418173602350336332834011143730287052626259450406781462033191143152690802051403229595128207313656006650 * α ^ 34 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 18) - have h35 : (0:ℝ) ≤ 13822754463345097102831820242184258761738276008006821284534279176481079905732530814499207866955435085150 * α ^ 35 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 17) - have h36 : (0:ℝ) ≤ 13801040060918957888564788139270767298844994408740307330701472008264699451769662273654318158513511789155 * α ^ 36 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 16) - have h37 : (0:ℝ) ≤ 12318471680266652419845517118100896836955882316001519109947812762310692937531763121301079422467179937315 * α ^ 37 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 15) - have h38 : (0:ℝ) ≤ 9791961276777243139471730047869500129996328504872391696608131789839153344852214590773875133920134451090 * α ^ 38 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 38)) (pow_nonneg hu 14) - have h39 : (0:ℝ) ≤ 6901396925674586370353679055683314537328841096886193608522335358563478321818303138218149658902821023950 * α ^ 39 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 39)) (pow_nonneg hu 13) - have h40 : (0:ℝ) ≤ 4290696155282947318028543407039084473970660925581234584798657667133577612919565979582433162065644672980 * α ^ 40 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 40)) (pow_nonneg hu 12) - have h41 : (0:ℝ) ≤ 2338873380377640090710543794097867885941646034550384133409823471730993425571758516636190486584614953700 * α ^ 41 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 41)) (pow_nonneg hu 11) - have h42 : (0:ℝ) ≤ 1109732755852378588712211011650814187613669797876675740951121816904470151813091358110884216937743142050 * α ^ 42 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 42)) (pow_nonneg hu 10) - have h43 : (0:ℝ) ≤ 454286800542359954534080719815999805873534526512065733818696923800302006274839909248752230406180846110 * α ^ 43 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 43)) (pow_nonneg hu 9) - have h44 : (0:ℝ) ≤ 158713699307083273689749079467203333163770903148624457146145339447571976015368636000957338799724035275 * α ^ 44 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 44)) (pow_nonneg hu 8) - have h45 : (0:ℝ) ≤ 46680861352325638868600152099580545678224568597334155135966362508038806503807101375708916251637014315 * α ^ 45 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 45)) (pow_nonneg hu 7) - have h46 : (0:ℝ) ≤ 11358113255233464326610717370655147651105757900848936506289875029144788364049674739051630170475728510 * α ^ 46 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 46)) (pow_nonneg hu 6) - have h47 : (0:ℝ) ≤ 2234292960434683002788971594223923746722335287405129686566824534284185319130892757911313973235591050 * α ^ 47 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 47)) (pow_nonneg hu 5) - have h48 : (0:ℝ) ≤ 344434128456143069997502715027323329232394662376196306985663027670793467133639790028593418988513700 * α ^ 48 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 48)) (pow_nonneg hu 4) - have h49 : (0:ℝ) ≤ 39809789393720194364475874377808256220963899458735378967674739520923108380632695527160035322788100 * α ^ 49 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 49)) (pow_nonneg hu 3) - have h50 : (0:ℝ) ≤ 3224979637871433689973695689784750956991084495357901531836611031085730991516232539844546931899840 * α ^ 50 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 50)) (pow_nonneg hu 2) - have h51 : (0:ℝ) ≤ 162942207478993682465981071080743775591479135331458384477879849257595493096166794488597275948400 * α ^ 51 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 51)) (pow_nonneg hu 1) - have h52 : (0:ℝ) ≤ 3907984261693816830880565006531529193978954398787645698090073443074989996324628172410599696000 * α ^ 52 := - mul_nonneg (by norm_num) (pow_nonneg hα 52) have hid : (17 : ℝ) ^ 52 * (16494167009921791229556693354250558994004960089275608134952301595194145700 + 143495585732014632876947701159299432571935297872102967009453889788942630516 * α + 600146981561757364071810080610152109467421702720565940343744136045710714240 * α ^ 2 + 1606309613433661462999425062531603257368288440796455160921241994205807550800 * α ^ 3 + 3089935016411981969366335770505513109414946535522135899534602918518452400110 * α ^ 4 + 4548021756358959061868607547427969034568735681024830591427930680507708516630 * α ^ 5 + 5324472427116589963068442803453435582254682183625311260959169925128717206890 * α ^ 6 + 5088112301464007763161223382731859106222272351099136492562868432790050748010 * α ^ 7 + 4041350342582910718376698346793695673500055519225008392201038233346955184130 * α ^ 8 + 2702810799510161555412033309004487136564483291932054239796551253387958338250 * α ^ 9 + 1536279381058752516392997665745371680813310918710686404622076783423411472310 * α ^ 10 + 747035505761971294025842500370255312982388584883798779389925639599781539110 * α ^ 11 + 312120280284390297007832319287765858778034126483703719026036710712245847630 * α ^ 12 + 112328303645112191177480265164326260518118446637968730517219246030090061670 * α ^ 13 + 34847965479991464020760392422930205817393828567231232594447128943554577950 * α ^ 14 + 9311065733578254803436313728561027301061995457613177507038687159207136510 * α ^ 15 + 2137053395968205693740631086110584184448273974022381233594071100920418660 * α ^ 16 + 419415497303046617346927271099007566525536754801411545759490611489535020 * α ^ 17 + 69903195768650128169410986270066096062738214853608222509952701694930390 * α ^ 18 + 9796751930080145102336247171862671684216870902559058128633974960508990 * α ^ 19 + 1138373287745887689323718901024639495300275153431093749751357684888655 * α ^ 20 + 107431234099507044305505224510335533709977858803000709455555262812475 * α ^ 21 + 7965572671696337257969240111258550023673082988480052797472718090765 * α ^ 22 + 432489851677951286849434341419775059089962332363725955872440307245 * α ^ 23 + 10033042060175777949356539605564287060646991070535569056012261935 * α ^ 24 - 14665345174670112106333566037790518499419114767637006814333117685 * α ^ 25 + 467265281717233365794825008753399741068194685496332969035489307 * α ^ 26 - 338571739674856609859042128682071390079128171355900195378565 * α ^ 27 + 51828010052697170919200272082439937455364221416970311841360 * α ^ 28 + 4551610675134221759317748807561457084971246067804745378320 * α ^ 29 + 209779510423918524619133931870713143087995729911985149040 * α ^ 30 + 5970127197067432618593627815816805105135662362948064640 * α ^ 31 + 72450550286061369082689048114099286472057904479048640 * α ^ 32 - 2583219468428786599910558481880637801957466132337920 * α ^ 33 - 195852731109616002368456744436432386876454107873280 * α ^ 34 - 7247973580231951783404261339025545494805311297280 * α ^ 35 - 194124681108967495056283792222752779031406556160 * α ^ 36 - 4123433450448809567758812935503400791570882560 * α ^ 37 - 72082021160947668781050521228246549326725120 * α ^ 38 - 1056193512343203991501036178583787410636800 * α ^ 39 - 13096880010730035770569022035700611809280 * α ^ 40 - 138052872308930943537538309704895365120 * α ^ 41 - 1238136265130428487231808151440916480 * α ^ 42 - 9428378825017111932776968669429760 * α ^ 43 - 60659413041205873935423111168000 * α ^ 44 - 327048428909975887634922209280 * α ^ 45 - 1459908719275463855607644160 * α ^ 46 - 5302273507938488014602240 * α ^ 47 - 15275608180278584934400 * α ^ 48 - 33595607399404666880 * α ^ 49 - 52996826537656320 * α ^ 50 - 53409512161280 * α ^ 51 - 25836912640 * α ^ 52) = 16494167009921791229556693354250558994004960089275608134952301595194145700 * (17 - α) ^ 52 + 3297121641960181902845058974129119421411157988468082062178235809362120295172 * α ^ 1 * (17 - α) ^ 51 + 319724415956160860091458945589182808902003352419736285543485329679451094270932 * α ^ 2 * (17 - α) ^ 50 + 20038710926027661432334875342791217340018851913295984793285523609822774454252700 * α ^ 3 * (17 - α) ^ 49 + 912506063164863213831944030666321098534650758920349287477777497262175240738402310 * α ^ 4 * (17 - α) ^ 48 + 32177823044530476695020659335002454111188404373175841794915018442377955651394113990 * α ^ 5 * (17 - α) ^ 47 + 914540681282828800807599319891793843292641936770051259660032453172015089441416681780 * α ^ 6 * (17 - α) ^ 46 + 21529723418168081854258856249066854725157410727767949291151621244500815386654814167180 * α ^ 7 * (17 - α) ^ 45 + 428187563876954541113963075618060221598963677578037826566438784007708913233247747176780 * α ^ 8 * (17 - α) ^ 44 + 7301844169441283547821796282852027526162858087792900418706107149330943728664004086739660 * α ^ 9 * (17 - α) ^ 43 + 107998890241658105222949402539269436370829457640263205565353289295418525536340771107662680 * α ^ 10 * (17 - α) ^ 42 + 1398093827433571704042090344538943552073638570463931753295281987815735454006786470999735160 * α ^ 11 * (17 - α) ^ 41 + 15957032127861583576984677012499030521875944161240621820452635989220785757028810049931646660 * α ^ 12 * (17 - α) ^ 40 + 161526877975623854315474231221259866905794267588621234412370551845474892520146496256658344580 * α ^ 13 * (17 - α) ^ 39 + 1457239742403607406416443184401351553341986505900117649824594649023236812024794234917099752380 * α ^ 14 * (17 - α) ^ 38 + 11764118385331183795485731464799855976003853373075619337664964031988252913700051042473465972420 * α ^ 15 * (17 - α) ^ 37 + 85266812327847025363233082778590085924666659056638604615146724746162734347495123483376596599070 * α ^ 16 * (17 - α) ^ 36 + 556412933665661316562603334092469787110651645009094640295939461919699008524178193574911456908110 * α ^ 17 * (17 - α) ^ 35 + 3276500502586555718746248192880369763373913284974973228696609120912342926842381883477115970971330 * α ^ 18 * (17 - α) ^ 34 + 17443973618063549860197174258607173645342170656659807634029925978540184960307013051100945108575830 * α ^ 19 * (17 - α) ^ 33 + 84097208992473763322482498841713994615424570017542204453635043962819422256085229322643661036553135 * α ^ 20 * (17 - α) ^ 32 + 367595670215331608081325934241054123019019558617664793950031213417886531914880453450235055639827695 * α ^ 21 * (17 - α) ^ 31 + 1458319292273003092992284569774617261635353524450745892916673491633645545947909275323789971386584010 * α ^ 22 * (17 - α) ^ 30 + 5254980271354566622530408171222928163731186808057577088774647757156770300739259401327506864767179590 * α ^ 23 * (17 - α) ^ 29 + 17209987305609188388593928884348304692679416452958887120667494264685355764336243613006433529300889900 * α ^ 24 * (17 - α) ^ 28 + 51245313767700576927493227999999199039753952598947831546238937797935220706183422086338270920360486300 * α ^ 25 * (17 - α) ^ 27 + 138766478666356226035473697072120508245376894603069112986887914209096091729659135725891961666489860662 * α ^ 26 * (17 - α) ^ 26 + 341725720150049744585959626125868368010499310869413614657759212314754963597840236324448419782451114282 * α ^ 27 * (17 - α) ^ 25 + 765136285933410012453175445478517650702161463656786558161202904376215029605986594283307478093304307385 * α ^ 28 * (17 - α) ^ 24 + 1556877403438278759283881545391171005360005954054145030966940257959498891624213557816408094093075864665 * α ^ 29 * (17 - α) ^ 23 + 2876564405128945633873865865688129358774847644012865518697098702186811357802016717785624061301955829430 * α ^ 30 * (17 - α) ^ 22 + 4820561162618100599568269482213420070663798726185647089067973322799735823546946658344673073602139469970 * α ^ 31 * (17 - α) ^ 21 + 7315920828232011027352935983664196353610979185130017647700999674444485613522154300362261069304268308590 * α ^ 32 * (17 - α) ^ 20 + 10036378526288476516030178366360979243689435681024753191393010979431912513169664181917187452264705749630 * α ^ 33 * (17 - α) ^ 19 + 12418173602350336332834011143730287052626259450406781462033191143152690802051403229595128207313656006650 * α ^ 34 * (17 - α) ^ 18 + 13822754463345097102831820242184258761738276008006821284534279176481079905732530814499207866955435085150 * α ^ 35 * (17 - α) ^ 17 + 13801040060918957888564788139270767298844994408740307330701472008264699451769662273654318158513511789155 * α ^ 36 * (17 - α) ^ 16 + 12318471680266652419845517118100896836955882316001519109947812762310692937531763121301079422467179937315 * α ^ 37 * (17 - α) ^ 15 + 9791961276777243139471730047869500129996328504872391696608131789839153344852214590773875133920134451090 * α ^ 38 * (17 - α) ^ 14 + 6901396925674586370353679055683314537328841096886193608522335358563478321818303138218149658902821023950 * α ^ 39 * (17 - α) ^ 13 + 4290696155282947318028543407039084473970660925581234584798657667133577612919565979582433162065644672980 * α ^ 40 * (17 - α) ^ 12 + 2338873380377640090710543794097867885941646034550384133409823471730993425571758516636190486584614953700 * α ^ 41 * (17 - α) ^ 11 + 1109732755852378588712211011650814187613669797876675740951121816904470151813091358110884216937743142050 * α ^ 42 * (17 - α) ^ 10 + 454286800542359954534080719815999805873534526512065733818696923800302006274839909248752230406180846110 * α ^ 43 * (17 - α) ^ 9 + 158713699307083273689749079467203333163770903148624457146145339447571976015368636000957338799724035275 * α ^ 44 * (17 - α) ^ 8 + 46680861352325638868600152099580545678224568597334155135966362508038806503807101375708916251637014315 * α ^ 45 * (17 - α) ^ 7 + 11358113255233464326610717370655147651105757900848936506289875029144788364049674739051630170475728510 * α ^ 46 * (17 - α) ^ 6 + 2234292960434683002788971594223923746722335287405129686566824534284185319130892757911313973235591050 * α ^ 47 * (17 - α) ^ 5 + 344434128456143069997502715027323329232394662376196306985663027670793467133639790028593418988513700 * α ^ 48 * (17 - α) ^ 4 + 39809789393720194364475874377808256220963899458735378967674739520923108380632695527160035322788100 * α ^ 49 * (17 - α) ^ 3 + 3224979637871433689973695689784750956991084495357901531836611031085730991516232539844546931899840 * α ^ 50 * (17 - α) ^ 2 + 162942207478993682465981071080743775591479135331458384477879849257595493096166794488597275948400 * α ^ 51 * (17 - α) ^ 1 + 3907984261693816830880565006531529193978954398787645698090073443074989996324628172410599696000 * α ^ 52 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 16494167009921791229556693354250558994004960089275608134952301595194145700 * (17 - α) ^ 52 := - mul_pos (by norm_num) (pow_pos (by linarith) 52) - linarith - · have hpos : (0 : ℝ) < 3907984261693816830880565006531529193978954398787645698090073443074989996324628172410599696000 * α ^ 52 := - mul_pos (by norm_num) (pow_pos (by linarith) 52) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 52)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree56_58.lean b/Sendov/FiniteRange/Degree56_58.lean index c88b0dc..da1da93 100644 --- a/Sendov/FiniteRange/Degree56_58.lean +++ b/Sendov/FiniteRange/Degree56_58.lean @@ -88,125 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 4006776526237583458791916745921571399903640427998587971001863479614257812500 + 36193299233577005092404435186325555880909575118523570487124919891357421875000 * α + 157404458430456801566314898531435489082055275896144801637965440750122070312500 * α ^ 2 + 438789302805190644765999692456086768304410010456706455086051940917968750000000 * α ^ 3 + 880644388246065999407804638303739222032368746089754793927588987350463867187500 * α ^ 4 + 1354948378632315916086740220782422392456213284262767321014325168609619140625000 * α ^ 5 + 1661602897691580734737365439849633466188200353673006461916168213272094726562500 * α ^ 6 + 1667045608015110082374111106109377028467549691711516663117268814086914062500000 * α ^ 7 + 1393634964581423479006807950372755382512403362475605339704530439338684082031250 * α ^ 8 + 983739476273137944395322828805928193025534886625965973020494254135131835937500 * α ^ 9 + 592005671863910309809560316101676243798968926448970748675875927594299316406250 * α ^ 10 + 305845520279728243480763379048878002620628430303914474045381805538574218750000 * α ^ 11 + 136301035857816688759209743042609079523363637041425866478473082778930664062500 * α ^ 12 + 52557215535889563135879554015106695279244905727351138276424395612451171875000 * α ^ 13 + 17560188550728447991878218358662068709211261557084724400278409291245117187500 * α ^ 14 + 5083558311018366382022659794526798695920221466826180257750759952604687500000 * α ^ 15 + 1273131764429501958625291301675693164238362230486966503823878444190878906250 * α ^ 16 + 274960492120840016369195438376101201319262210714934208739555078202929687500 * α ^ 17 + 50954380823074628723812132018848659015398414173106367885877485025457031250 * α ^ 18 + 8043619315575642311782000673332751078848207374194599271764060475643750000 * α ^ 19 + 1070647032300550686760844315611512648892236354901418090931769834405593750 * α ^ 20 + 118447064950886641697648118438020073800095586622991278431631099619912500 * α ^ 21 + 10665844034582511896384387237050410144703560308738822660894704597031250 * α ^ 22 + 756055215489708905909989210679280265318059125676239214550223981550000 * α ^ 23 + 39319509582765585318317434167304155450155442605644113789923547061875 * α ^ 24 + 867126925428575278846841639739898919922847699797676292404824708330 * α ^ 25 - 1342664334700830923321502819993530701259788051847367543772214665281 * α ^ 26 + 39483777041359676646803092797859249221387704496311861748873113400 * α ^ 27 - 58711046556251894173073392026014465411610439743591823421605392 * α ^ 28 + 2490932168525853073760934875391654922167755426092527716004768 * α ^ 29 + 299316943768298507774611885828874444092265356390330098080400 * α ^ 30 + 15336692487146884782753132557947737242171025616954771587840 * α ^ 31 + 493116066063688255278336127843281464063956961803863360000 * α ^ 32 + 8923910394517508916121212299646048703215085675738298880 * α ^ 33 - 42485806368509927498334028885467492467879729762661120 * α ^ 34 - 9926741056642548036510544310918633673463407651072000 * α ^ 35 - 427541739200753198037475741948767076883193745367040 * α ^ 36 - 12336686560635193418143284676363319056265591808000 * α ^ 37 - 276403480622187214471125457231894057984922849280 * α ^ 38 - 5061460700774592700650136059515237541978439680 * α ^ 39 - 77589542792718274978754693243996574602035200 * α ^ 40 - 1008285668556426930549466452256224957562880 * α ^ 41 - 11180151867078112441929755167105458176000 * α ^ 42 - 106057325448908908308826107393838940160 * α ^ 43 - 860453519636632559264422458435829760 * α ^ 44 - 5953015798094365467380006676070400 * α ^ 45 - 34925450531279060313143566663680 * α ^ 46 - 172262764126427765287157760000 * α ^ 47 - 705448234661772873443573760 * α ^ 48 - 2356408942484969918300160 * α ^ 49 - 6257674902168236195840 * α ^ 50 - 12711757957239406592 * α ^ 51 - 18555990127411200 * α ^ 52 - 17333951135744 * α ^ 53 - 7784628224 * α ^ 54 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 4006776526237583458791916745921571399903640427998587971001863479614257812500 * (17 - α) ^ 54 := - mul_nonneg (by norm_num) (pow_nonneg hu 54) - have h1 : (0:ℝ) ≤ 831652019387638593345638902447299305570259360126824448715224266052246093750000 * α ^ 1 * (17 - α) ^ 53 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 53) - have h2 : (0:ℝ) ≤ 83833748304900879170452634641877950866675611368241564068775231838226318359375000 * α ^ 2 * (17 - α) ^ 52 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 52) - have h3 : (0:ℝ) ≤ 5468494358777378393080477785807867951674090671443673031117236424446105957031250000 * α ^ 3 * (17 - α) ^ 51 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 51) - have h4 : (0:ℝ) ≤ 259497095119023070284911959202753696905030203192837428866594793371009826660156250000 * α ^ 4 * (17 - α) ^ 50 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 50) - have h5 : (0:ℝ) ≤ 9548226194342856021369990031496637841520575254703619359937770099499221801757812500000 * α ^ 5 * (17 - α) ^ 49 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 49) - have h6 : (0:ℝ) ≤ 283554795754116919933939967317880593392006022363436344694634037363653737640380859375000 * α ^ 6 * (17 - α) ^ 48 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 48) - have h7 : (0:ℝ) ≤ 6985033324607242622400264323272167984455201909490308654941771836141864102172851562500000 * α ^ 7 * (17 - α) ^ 47 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 47) - have h8 : (0:ℝ) ≤ 145585869325517123027631865241602024127251143700135843061398935728533566792640686035156250 * α ^ 8 * (17 - α) ^ 46 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 46) - have h9 : (0:ℝ) ≤ 2605939606481930370231755414493637687294479329903418074328564748827833386281097412109375000 * α ^ 9 * (17 - α) ^ 45 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 45) - have h10 : (0:ℝ) ≤ 40524996895639459847128154228148170371947695272650286201553195462882818721524821166992187500 * α ^ 10 * (17 - α) ^ 44 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 44) - have h11 : (0:ℝ) ≤ 552551133383357806856520189290844564406656538250136666178295793900819727635981966064453125000 * α ^ 11 * (17 - α) ^ 43 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 43) - have h12 : (0:ℝ) ≤ 6654537960345176614579520210501969964341553464814299926502106023232060321118045116027832031250 * α ^ 12 * (17 - α) ^ 42 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 42) - have h13 : (0:ℝ) ≤ 71215632892928225012541089836574503427207341702460836120538723682777701285820760548632812500000 * α ^ 13 * (17 - α) ^ 41 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 41) - have h14 : (0:ℝ) ≤ 680613583355729809602306987711530797435340161763367564193121313750649561609059057159169921875000 * α ^ 14 * (17 - α) ^ 40 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 40) - have h15 : (0:ℝ) ≤ 5832875752360000513642484795718619279175379757851803276997150658226737011497871446091396093750000 * α ^ 15 * (17 - α) ^ 39 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 39) - have h16 : (0:ℝ) ≤ 44979351085207558150078784978662679910370590969134326277300556578996443629331813144059755039062500 * α ^ 16 * (17 - α) ^ 38 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 38) - have h17 : (0:ℝ) ≤ 312995911940481513520445963433861073963208442217604567895958294256991627351128534764956244218750000 * α ^ 17 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 37) - have h18 : (0:ℝ) ≤ 1970161029906836645506545335621217130652959793873949162987985608245722153781520858422880420890625000 * α ^ 18 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 36) - have h19 : (0:ℝ) ≤ 11240168074382975494983845291739726207752209032492025653981589349256891847236794547066229926806250000 * α ^ 19 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 35) - have h20 : (0:ℝ) ≤ 58220468052171150534543089230853402616213765163545474800357913943776071267588624931694422468683718750 * α ^ 20 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 34) - have h21 : (0:ℝ) ≤ 274162442806735488937328580878545767896445602338781689345873092416421648387300355873155086008186200000 * α ^ 21 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 33) - have h22 : (0:ℝ) ≤ 1175053053219549755923303158761313219677705229404659836838649889496146832750569917119434117241667287500 * α ^ 22 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 32) - have h23 : (0:ℝ) ≤ 4587918386962882020150348519193673004398898248795343130672609419407279340288027481893308532612882750000 * α ^ 23 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 31) - have h24 : (0:ℝ) ≤ 16330076475454767959070546693996088924163345527886054247186679311654325903066537139062302883030633149375 * α ^ 24 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 30) - have h25 : (0:ℝ) ≤ 53015531748660804101125233244023173725306131782343261679623854226624053438968135738999293061644801261060 * α ^ 25 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 29) - have h26 : (0:ℝ) ≤ 157042247362868043075174929076891424448113760391534609598267651251111262726701902052468899161352536565826 * α ^ 26 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 28) - have h27 : (0:ℝ) ≤ 424536028113530069741207063773543340247417183854664190521457558189988983776332421257010922807774328703468 * α ^ 27 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 27) - have h28 : (0:ℝ) ≤ 1047394825014464265044437577949313703859620376795552005549249263622157394802977948988963043499590064285701 * α ^ 28 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 26) - have h29 : (0:ℝ) ≤ 2357953243932795895351786030037214986312773901878377266600410243701385112182023007703278183236835882555920 * α ^ 29 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 25) - have h30 : (0:ℝ) ≤ 4841990819787898672356879612840738450763274999724268831092864647028159910497634849060319644324211875401000 * α ^ 30 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 24) - have h31 : (0:ℝ) ≤ 9063584503650178882271337601783826443148131765373991434810543048088202441000466212270593355824045378675000 * α ^ 31 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 23) - have h32 : (0:ℝ) ≤ 15451128490873801008027757078817526210012989527697672000297488543102153793093056771081079889530059921809375 * α ^ 32 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 22) - have h33 : (0:ℝ) ≤ 23958789035470262232279921076956417405034112471262464267273767085684019981430087645587646696528226066737500 * α ^ 33 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 21) - have h34 : (0:ℝ) ≤ 33738977176761179018990595988066513346352404262225555749812365323678028997756330293158647680594843998343750 * α ^ 34 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 20) - have h35 : (0:ℝ) ≤ 43066010152981647775428783321099345843672023374934640403912525283591537133423955925346616576791170076562500 * α ^ 35 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 19) - have h36 : (0:ℝ) ≤ 49716389232502500304027459338301800974067035710033081062048758917500248639945950282904415348908887986328125 * α ^ 36 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 18) - have h37 : (0:ℝ) ≤ 51772728585970415852508288051049002543845872981898134416451565218988426676405878702958035332866606796875000 * α ^ 37 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 17) - have h38 : (0:ℝ) ≤ 48489623083597730277404885225414500632015670930460944310500759458078933768686805720241794646887945820312500 * α ^ 38 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 38)) (pow_nonneg hu 16) - have h39 : (0:ℝ) ≤ 40706685418039446342456126818361030430892463367085468425983118729461107320981091338190269943859904687500000 * α ^ 39 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 39)) (pow_nonneg hu 15) - have h40 : (0:ℝ) ≤ 30510757875107724377755328842206506253240610141014079628356809193148547036423525594278170823630233154296875 * α ^ 40 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 40)) (pow_nonneg hu 14) - have h41 : (0:ℝ) ≤ 20325417185768341572644199400008775190356569699126770047800664408936401012312339590678833285411352539062500 * α ^ 41 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 41)) (pow_nonneg hu 13) - have h42 : (0:ℝ) ≤ 11970484403352576009251094586102294750081037384202884978488076602265682461511720826286535223334289550781250 * α ^ 42 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 42)) (pow_nonneg hu 12) - have h43 : (0:ℝ) ≤ 6193242030824480837746170022650419963156765230142047685904514800454071854093027706906593305633666992187500 * α ^ 43 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 43)) (pow_nonneg hu 11) - have h44 : (0:ℝ) ≤ 2793420712321765649092179680582709716866031666381458570060592097389668488933904453892321322512969970703125 * α ^ 44 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 44)) (pow_nonneg hu 10) - have h45 : (0:ℝ) ≤ 1088149422884559786015096896649994047996413331792775697347682065754794925880331083486662942138671875000000 * α ^ 45 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 45)) (pow_nonneg hu 9) - have h46 : (0:ℝ) ≤ 361802514627870134054227480223533630715173215487471596187535638974794633464984427234290066680908203125000 * α ^ 46 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 46)) (pow_nonneg hu 8) - have h47 : (0:ℝ) ≤ 101146608070751659320633087948602468401536695297326173484816516224027843212819017493162674713134765625000 * α ^ 47 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 47)) (pow_nonneg hu 7) - have h48 : (0:ℝ) ≤ 23308619653592257439475827609650039406713094584665162739531070571873085270495926103569096851348876953125 * α ^ 48 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 48)) (pow_nonneg hu 6) - have h49 : (0:ℝ) ≤ 4309056167008746262541403431206719244122955714616670864926279020311783589907259065312067031860351562500 * α ^ 49 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 49)) (pow_nonneg hu 5) - have h50 : (0:ℝ) ≤ 614552339408580729666564781265917271485257491177590074251947797114305883650016905691361427307128906250 * α ^ 50 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 50)) (pow_nonneg hu 4) - have h51 : (0:ℝ) ≤ 63623700305983189824220164500388274837272339260459679341376353550049617549841760780096054077148437500 * α ^ 51 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 51)) (pow_nonneg hu 3) - have h52 : (0:ℝ) ≤ 4296576620263370001927713368254137045425780398934810417013483195008307979207405258715152740478515625 * α ^ 52 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 52)) (pow_nonneg hu 2) - have h53 : (0:ℝ) ≤ 149430873582062166621125852273186331577668585046621031080994039368115021643902842998504638671875000 * α ^ 53 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 53)) (pow_nonneg hu 1) - have h54 : (0:ℝ) ≤ 947247377954257591039710592438900578151634152117436911287820530796278073275661468505859375000000 * α ^ 54 := - mul_nonneg (by norm_num) (pow_nonneg hα 54) have hid : (17 : ℝ) ^ 54 * (4006776526237583458791916745921571399903640427998587971001863479614257812500 + 36193299233577005092404435186325555880909575118523570487124919891357421875000 * α + 157404458430456801566314898531435489082055275896144801637965440750122070312500 * α ^ 2 + 438789302805190644765999692456086768304410010456706455086051940917968750000000 * α ^ 3 + 880644388246065999407804638303739222032368746089754793927588987350463867187500 * α ^ 4 + 1354948378632315916086740220782422392456213284262767321014325168609619140625000 * α ^ 5 + 1661602897691580734737365439849633466188200353673006461916168213272094726562500 * α ^ 6 + 1667045608015110082374111106109377028467549691711516663117268814086914062500000 * α ^ 7 + 1393634964581423479006807950372755382512403362475605339704530439338684082031250 * α ^ 8 + 983739476273137944395322828805928193025534886625965973020494254135131835937500 * α ^ 9 + 592005671863910309809560316101676243798968926448970748675875927594299316406250 * α ^ 10 + 305845520279728243480763379048878002620628430303914474045381805538574218750000 * α ^ 11 + 136301035857816688759209743042609079523363637041425866478473082778930664062500 * α ^ 12 + 52557215535889563135879554015106695279244905727351138276424395612451171875000 * α ^ 13 + 17560188550728447991878218358662068709211261557084724400278409291245117187500 * α ^ 14 + 5083558311018366382022659794526798695920221466826180257750759952604687500000 * α ^ 15 + 1273131764429501958625291301675693164238362230486966503823878444190878906250 * α ^ 16 + 274960492120840016369195438376101201319262210714934208739555078202929687500 * α ^ 17 + 50954380823074628723812132018848659015398414173106367885877485025457031250 * α ^ 18 + 8043619315575642311782000673332751078848207374194599271764060475643750000 * α ^ 19 + 1070647032300550686760844315611512648892236354901418090931769834405593750 * α ^ 20 + 118447064950886641697648118438020073800095586622991278431631099619912500 * α ^ 21 + 10665844034582511896384387237050410144703560308738822660894704597031250 * α ^ 22 + 756055215489708905909989210679280265318059125676239214550223981550000 * α ^ 23 + 39319509582765585318317434167304155450155442605644113789923547061875 * α ^ 24 + 867126925428575278846841639739898919922847699797676292404824708330 * α ^ 25 - 1342664334700830923321502819993530701259788051847367543772214665281 * α ^ 26 + 39483777041359676646803092797859249221387704496311861748873113400 * α ^ 27 - 58711046556251894173073392026014465411610439743591823421605392 * α ^ 28 + 2490932168525853073760934875391654922167755426092527716004768 * α ^ 29 + 299316943768298507774611885828874444092265356390330098080400 * α ^ 30 + 15336692487146884782753132557947737242171025616954771587840 * α ^ 31 + 493116066063688255278336127843281464063956961803863360000 * α ^ 32 + 8923910394517508916121212299646048703215085675738298880 * α ^ 33 - 42485806368509927498334028885467492467879729762661120 * α ^ 34 - 9926741056642548036510544310918633673463407651072000 * α ^ 35 - 427541739200753198037475741948767076883193745367040 * α ^ 36 - 12336686560635193418143284676363319056265591808000 * α ^ 37 - 276403480622187214471125457231894057984922849280 * α ^ 38 - 5061460700774592700650136059515237541978439680 * α ^ 39 - 77589542792718274978754693243996574602035200 * α ^ 40 - 1008285668556426930549466452256224957562880 * α ^ 41 - 11180151867078112441929755167105458176000 * α ^ 42 - 106057325448908908308826107393838940160 * α ^ 43 - 860453519636632559264422458435829760 * α ^ 44 - 5953015798094365467380006676070400 * α ^ 45 - 34925450531279060313143566663680 * α ^ 46 - 172262764126427765287157760000 * α ^ 47 - 705448234661772873443573760 * α ^ 48 - 2356408942484969918300160 * α ^ 49 - 6257674902168236195840 * α ^ 50 - 12711757957239406592 * α ^ 51 - 18555990127411200 * α ^ 52 - 17333951135744 * α ^ 53 - 7784628224 * α ^ 54) = 4006776526237583458791916745921571399903640427998587971001863479614257812500 * (17 - α) ^ 54 + 831652019387638593345638902447299305570259360126824448715224266052246093750000 * α ^ 1 * (17 - α) ^ 53 + 83833748304900879170452634641877950866675611368241564068775231838226318359375000 * α ^ 2 * (17 - α) ^ 52 + 5468494358777378393080477785807867951674090671443673031117236424446105957031250000 * α ^ 3 * (17 - α) ^ 51 + 259497095119023070284911959202753696905030203192837428866594793371009826660156250000 * α ^ 4 * (17 - α) ^ 50 + 9548226194342856021369990031496637841520575254703619359937770099499221801757812500000 * α ^ 5 * (17 - α) ^ 49 + 283554795754116919933939967317880593392006022363436344694634037363653737640380859375000 * α ^ 6 * (17 - α) ^ 48 + 6985033324607242622400264323272167984455201909490308654941771836141864102172851562500000 * α ^ 7 * (17 - α) ^ 47 + 145585869325517123027631865241602024127251143700135843061398935728533566792640686035156250 * α ^ 8 * (17 - α) ^ 46 + 2605939606481930370231755414493637687294479329903418074328564748827833386281097412109375000 * α ^ 9 * (17 - α) ^ 45 + 40524996895639459847128154228148170371947695272650286201553195462882818721524821166992187500 * α ^ 10 * (17 - α) ^ 44 + 552551133383357806856520189290844564406656538250136666178295793900819727635981966064453125000 * α ^ 11 * (17 - α) ^ 43 + 6654537960345176614579520210501969964341553464814299926502106023232060321118045116027832031250 * α ^ 12 * (17 - α) ^ 42 + 71215632892928225012541089836574503427207341702460836120538723682777701285820760548632812500000 * α ^ 13 * (17 - α) ^ 41 + 680613583355729809602306987711530797435340161763367564193121313750649561609059057159169921875000 * α ^ 14 * (17 - α) ^ 40 + 5832875752360000513642484795718619279175379757851803276997150658226737011497871446091396093750000 * α ^ 15 * (17 - α) ^ 39 + 44979351085207558150078784978662679910370590969134326277300556578996443629331813144059755039062500 * α ^ 16 * (17 - α) ^ 38 + 312995911940481513520445963433861073963208442217604567895958294256991627351128534764956244218750000 * α ^ 17 * (17 - α) ^ 37 + 1970161029906836645506545335621217130652959793873949162987985608245722153781520858422880420890625000 * α ^ 18 * (17 - α) ^ 36 + 11240168074382975494983845291739726207752209032492025653981589349256891847236794547066229926806250000 * α ^ 19 * (17 - α) ^ 35 + 58220468052171150534543089230853402616213765163545474800357913943776071267588624931694422468683718750 * α ^ 20 * (17 - α) ^ 34 + 274162442806735488937328580878545767896445602338781689345873092416421648387300355873155086008186200000 * α ^ 21 * (17 - α) ^ 33 + 1175053053219549755923303158761313219677705229404659836838649889496146832750569917119434117241667287500 * α ^ 22 * (17 - α) ^ 32 + 4587918386962882020150348519193673004398898248795343130672609419407279340288027481893308532612882750000 * α ^ 23 * (17 - α) ^ 31 + 16330076475454767959070546693996088924163345527886054247186679311654325903066537139062302883030633149375 * α ^ 24 * (17 - α) ^ 30 + 53015531748660804101125233244023173725306131782343261679623854226624053438968135738999293061644801261060 * α ^ 25 * (17 - α) ^ 29 + 157042247362868043075174929076891424448113760391534609598267651251111262726701902052468899161352536565826 * α ^ 26 * (17 - α) ^ 28 + 424536028113530069741207063773543340247417183854664190521457558189988983776332421257010922807774328703468 * α ^ 27 * (17 - α) ^ 27 + 1047394825014464265044437577949313703859620376795552005549249263622157394802977948988963043499590064285701 * α ^ 28 * (17 - α) ^ 26 + 2357953243932795895351786030037214986312773901878377266600410243701385112182023007703278183236835882555920 * α ^ 29 * (17 - α) ^ 25 + 4841990819787898672356879612840738450763274999724268831092864647028159910497634849060319644324211875401000 * α ^ 30 * (17 - α) ^ 24 + 9063584503650178882271337601783826443148131765373991434810543048088202441000466212270593355824045378675000 * α ^ 31 * (17 - α) ^ 23 + 15451128490873801008027757078817526210012989527697672000297488543102153793093056771081079889530059921809375 * α ^ 32 * (17 - α) ^ 22 + 23958789035470262232279921076956417405034112471262464267273767085684019981430087645587646696528226066737500 * α ^ 33 * (17 - α) ^ 21 + 33738977176761179018990595988066513346352404262225555749812365323678028997756330293158647680594843998343750 * α ^ 34 * (17 - α) ^ 20 + 43066010152981647775428783321099345843672023374934640403912525283591537133423955925346616576791170076562500 * α ^ 35 * (17 - α) ^ 19 + 49716389232502500304027459338301800974067035710033081062048758917500248639945950282904415348908887986328125 * α ^ 36 * (17 - α) ^ 18 + 51772728585970415852508288051049002543845872981898134416451565218988426676405878702958035332866606796875000 * α ^ 37 * (17 - α) ^ 17 + 48489623083597730277404885225414500632015670930460944310500759458078933768686805720241794646887945820312500 * α ^ 38 * (17 - α) ^ 16 + 40706685418039446342456126818361030430892463367085468425983118729461107320981091338190269943859904687500000 * α ^ 39 * (17 - α) ^ 15 + 30510757875107724377755328842206506253240610141014079628356809193148547036423525594278170823630233154296875 * α ^ 40 * (17 - α) ^ 14 + 20325417185768341572644199400008775190356569699126770047800664408936401012312339590678833285411352539062500 * α ^ 41 * (17 - α) ^ 13 + 11970484403352576009251094586102294750081037384202884978488076602265682461511720826286535223334289550781250 * α ^ 42 * (17 - α) ^ 12 + 6193242030824480837746170022650419963156765230142047685904514800454071854093027706906593305633666992187500 * α ^ 43 * (17 - α) ^ 11 + 2793420712321765649092179680582709716866031666381458570060592097389668488933904453892321322512969970703125 * α ^ 44 * (17 - α) ^ 10 + 1088149422884559786015096896649994047996413331792775697347682065754794925880331083486662942138671875000000 * α ^ 45 * (17 - α) ^ 9 + 361802514627870134054227480223533630715173215487471596187535638974794633464984427234290066680908203125000 * α ^ 46 * (17 - α) ^ 8 + 101146608070751659320633087948602468401536695297326173484816516224027843212819017493162674713134765625000 * α ^ 47 * (17 - α) ^ 7 + 23308619653592257439475827609650039406713094584665162739531070571873085270495926103569096851348876953125 * α ^ 48 * (17 - α) ^ 6 + 4309056167008746262541403431206719244122955714616670864926279020311783589907259065312067031860351562500 * α ^ 49 * (17 - α) ^ 5 + 614552339408580729666564781265917271485257491177590074251947797114305883650016905691361427307128906250 * α ^ 50 * (17 - α) ^ 4 + 63623700305983189824220164500388274837272339260459679341376353550049617549841760780096054077148437500 * α ^ 51 * (17 - α) ^ 3 + 4296576620263370001927713368254137045425780398934810417013483195008307979207405258715152740478515625 * α ^ 52 * (17 - α) ^ 2 + 149430873582062166621125852273186331577668585046621031080994039368115021643902842998504638671875000 * α ^ 53 * (17 - α) ^ 1 + 947247377954257591039710592438900578151634152117436911287820530796278073275661468505859375000000 * α ^ 54 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 4006776526237583458791916745921571399903640427998587971001863479614257812500 * (17 - α) ^ 54 := - mul_pos (by norm_num) (pow_pos (by linarith) 54) - linarith - · have hpos : (0 : ℝ) < 947247377954257591039710592438900578151634152117436911287820530796278073275661468505859375000000 * α ^ 54 := - mul_pos (by norm_num) (pow_pos (by linarith) 54) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 54)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree58_60.lean b/Sendov/FiniteRange/Degree58_60.lean index 2904abf..afdd6c3 100644 --- a/Sendov/FiniteRange/Degree58_60.lean +++ b/Sendov/FiniteRange/Degree58_60.lean @@ -88,129 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 1180273288616099684023784650402498199886255444730023274978571199510266513047596 + 11055102824011442029948266567510506642575381276841013106178383140649638883273740 * α + 49922645194024990734283616516471280600334184364447547102243551298880869797559488 * α ^ 2 + 144719942608174873104026182095524650959577750970144395839719569131273169856379216 * α ^ 3 + 302526482246635225757578631533959631447003848728875689601323895427543714021299068 * α ^ 4 + 485662255765025402514981086091947264736043236799566038683821482401809082117981716 * α ^ 5 + 622606333409943749753890815208648354755606137297243000849237534232491249017638372 * α ^ 6 + 654352069860427639900751348035281558837881303628117455206054590616141095225034932 * α ^ 7 + 574357399231416827070511854689853503943460240353865007966655407656850680547039034 * α ^ 8 + 426752571345870223801790426727818388140106457832728071034614633845667453226768626 * α ^ 9 + 271079935317622563319456334579591661701883897872193010593643933885082711035509852 * α ^ 10 + 148286371479076003045732417755582133525685636981220867944156217604240361014274724 * α ^ 11 + 70217169066647225915394151645973808431273168363378941311910545513943342491505944 * α ^ 12 + 28882635903906998561313897779843874583553384770520360078626138405360811163881868 * α ^ 13 + 10340675254845519580917140785070160244501596661998078491888557158268998114446532 * α ^ 14 + 3224423637549642502496418645711742177932306998129835583325750859424757337666996 * α ^ 15 + 875062504101721302059576940201180260130574140021726848117119157209427049292266 * α ^ 16 + 206253961710804940753907484420744734282964403780943395544748624256594408470306 * α ^ 17 + 42070236802464351764635254679415144786913128539020355841577805021278534599952 * α ^ 18 + 7386217051829558880237703381942358818281589489452528309990518263995367432488 * α ^ 19 + 1107793613576531791057535432236447149617292886122026324465700872270457547494 * α ^ 20 + 140459087137897856469559866359157699541937133355950394902889100420287426914 * α ^ 21 + 14838359760717420231756157247609092582149974794155897343599292760550967914 * α ^ 22 + 1279004725824261809420174464624373933895777466651732360112330465852550258 * α ^ 23 + 87033426312093344876434088654180488427125423854890952784009041976465947 * α ^ 24 + 4369112665592393971521458232346790403396711247658540001242310421975335 * α ^ 25 + 97654992764826340667007297954456940399851548824989983096539223841294 * α ^ 26 - 140180336953330902099623933788922389004727627031585783295797300519590 * α ^ 27 + 4011521197356040330478113154305443808925568648433687983973999832370 * α ^ 28 - 6836116057285781356883522416064683372386240155164063320736832232 * α ^ 29 + 136155913451608763461692617832470536736112881493096843133744560 * α ^ 30 + 23084190208503516369122355362110577411004819796039225427268288 * α ^ 31 + 1272092669921250187525125636594403706428638167041905626630688 * α ^ 32 + 43743288386492835342171671864673441962710429642110919385856 * α ^ 33 + 919770851750237042763795205605716932136524848257092998144 * α ^ 34 + 3589129787637507437982773070768409846725811870537367040 * α ^ 35 - 616787227367020803961294798626057817769112354291227136 * α ^ 36 - 30943009074599150760660807547437896432729575808956416 * α ^ 37 - 952040288448666548370356300676837076289373764554752 * α ^ 38 - 22303674458304714179931228274300996373189822005248 * α ^ 39 - 424667137052011465151087643604559827985297448960 * α ^ 40 - 6764616781706422065650823730243312809557557248 * α ^ 41 - 91516551558371359215307258976568083952304128 * α ^ 42 - 1060132719651553338827644611213921972781056 * α ^ 43 - 10557532799422900249752275241549216743424 * α ^ 44 - 90481973634654084996556237361914576896 * α ^ 45 - 666432341608325016551912342849323008 * α ^ 46 - 4202788903097596849838434642034688 * α ^ 47 - 22554190076903951857505928216576 * α ^ 48 - 102065451905712762371350462464 * α ^ 49 - 384517782188687390618419200 * α ^ 50 - 1184406710041525201403904 * α ^ 51 - 2906644614364092432384 * α ^ 52 - 5467069217104723968 * α ^ 53 - 7402337748385792 * α ^ 54 - 6424197332992 * α ^ 55 - 2684354560 * α ^ 56 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 1180273288616099684023784650402498199886255444730023274978571199510266513047596 * (17 - α) ^ 56 := - mul_nonneg (by norm_num) (pow_nonneg hu 56) - have h1 : (0:ℝ) ≤ 254032052170696096814452472070218512117411786611178526203832500563618785746318956 * α ^ 1 * (17 - α) ^ 55 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 55) - have h2 : (0:ℝ) ≤ 26581786465992714133606222775502371032129394160055924210292174209129794157448936772 * α ^ 2 * (17 - α) ^ 54 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 54) - have h3 : (0:ℝ) ≤ 1801905125284524294246494051997323405505883272969655457886034380748404658915029385356 * α ^ 3 * (17 - α) ^ 53 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 53) - have h4 : (0:ℝ) ≤ 88960777843487839207354469588977939024483934333485516580514560192823003078437474637384 * α ^ 4 * (17 - α) ^ 52 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 52) - have h5 : (0:ℝ) ≤ 3409710295444689753751021773779609449447011909852801588651071013422638895502085385574456 * α ^ 5 * (17 - α) ^ 51 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 51) - have h6 : (0:ℝ) ≤ 105611745061099871040994619483246321125469657724218486870230193879528974892413607636605284 * α ^ 6 * (17 - α) ^ 50 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 50) - have h7 : (0:ℝ) ≤ 2717077493210926098447489650385141874390859518222133351745212828060950258218810177908282556 * α ^ 7 * (17 - α) ^ 49 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 49) - have h8 : (0:ℝ) ≤ 59226539189538299382222748715390123146365770386986878118026762708622792734361308033174370018 * α ^ 8 * (17 - α) ^ 48 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 48) - have h9 : (0:ℝ) ≤ 1110347623085275380732784124563019672170207376288907445733220470280957735947728184470496756010 * α ^ 9 * (17 - α) ^ 47 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 47) - have h10 : (0:ℝ) ≤ 18112519692658810410404967374345439836251270145825076491663143586046571832030458464477826206258 * α ^ 10 * (17 - α) ^ 46 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 46) - have h11 : (0:ℝ) ≤ 259468406097457687929633525944011735968016319542087733822510053479299676655957583926253741360502 * α ^ 11 * (17 - α) ^ 45 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 45) - have h12 : (0:ℝ) ≤ 3288616364869040104475987141993494253571602787363843112397732704776764511075222653495077733735718 * α ^ 12 * (17 - α) ^ 44 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 44) - have h13 : (0:ℝ) ≤ 37103473125865952584340786773431223496072304382597727768926156417429611089103427290200640921026334 * α ^ 13 * (17 - α) ^ 43 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 43) - have h14 : (0:ℝ) ≤ 374523382812426223233967303671275687297451096894379697013331090967253251615175373801177901144258730 * α ^ 14 * (17 - α) ^ 42 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 42) - have h15 : (0:ℝ) ≤ 3396494550442924093336698525515677714454583693723746546679078674756021148647562726100992633195827670 * α ^ 15 * (17 - α) ^ 41 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 41) - have h16 : (0:ℝ) ≤ 27771451470570936428940278209636484839068297258115446941354573210378654498093153647787388326291195220 * α ^ 16 * (17 - α) ^ 40 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 40) - have h17 : (0:ℝ) ≤ 205336433200531842769564752332775005425876161312494024088869532088213815964669131170023033890476305980 * α ^ 17 * (17 - α) ^ 39 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 39) - have h18 : (0:ℝ) ≤ 1376302917197732669050568166563895672822852883204651206746822345275035657680019417369627527115086850120 * α ^ 18 * (17 - α) ^ 38 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 38) - have h19 : (0:ℝ) ≤ 8380155294397784796024596289754563707905478379672589828457151616147990659832389424273341383748688207080 * α ^ 19 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 37) - have h20 : (0:ℝ) ≤ 46434805880795731321224499533392807251809590691101718819109701496201837794500680135302573321020690890746 * α ^ 20 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 36) - have h21 : (0:ℝ) ≤ 234491333325177991679288999498604121924586729800797548175219657080832899570210449706339657838128968884354 * α ^ 21 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 35) - have h22 : (0:ℝ) ≤ 1080514930086925704280859540483502286254671084929525637672420222697615347555423346347115532203110643365136 * α ^ 22 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 34) - have h23 : (0:ℝ) ≤ 4547675284413232416488077752788320517949654297288884032643195010720956134703008952100555630475629759787488 * α ^ 23 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 33) - have h24 : (0:ℝ) ≤ 17496546097098586152071398152312222042613115074033174731514387311101666529876250406780911401607973057493255 * α ^ 24 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 32) - have h25 : (0:ℝ) ≤ 61573424970057153431741932997114452252230749510452379581517661469288846340022317444210252355996069897749331 * α ^ 25 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 31) - have h26 : (0:ℝ) ≤ 198297654024175037814903698649403184988215012123240470670091291048259056629782551733808484416396638864067091 * α ^ 26 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 30) - have h27 : (0:ℝ) ≤ 584610302749161753333489816331275650573703865862791211866486561498961706693997631039254643972613296017180617 * α ^ 27 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 29) - have h28 : (0:ℝ) ≤ 1578046905956627892814531753544431465414315118110738633436435926556242944082783767807930560452112935615842171 * α ^ 28 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 28) - have h29 : (0:ℝ) ≤ 3900276267502012608001991748970773203576515687854492513578111746545720357741690474840268134056865690598209279 * α ^ 29 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 27) - have h30 : (0:ℝ) ≤ 8825565680944180807206852648457428249507576570214954247410910715730515927908602962682166825659628608449565179 * α ^ 30 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 26) - have h31 : (0:ℝ) ≤ 18278222890683728517844209588507295086668349633646134150369498537778483167121641476779372484086759659269711781 * α ^ 31 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 25) - have h32 : (0:ℝ) ≤ 34630021303309994264801974849783975057715767549012563612835970835153541351334334084636838049899704411229419039 * α ^ 32 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 24) - have h33 : (0:ℝ) ≤ 59976325403926759553950096138547851891588162346459693279652757133352417289699475136155912596938565990681022967 * α ^ 33 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 23) - have h34 : (0:ℝ) ≤ 94859908857514726802312972207926527679144706496572092127703134483420755663937004295941931559564856864612372015 * α ^ 34 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 22) - have h35 : (0:ℝ) ≤ 136838029261198215465308944618229439296028860400759258689603958243702943063871561985963901374611376885862608933 * α ^ 35 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 21) - have h36 : (0:ℝ) ≤ 179750481304348065934713749450324777683615725218792657415497203296024872885988657067853702018371602813684069687 * α ^ 36 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 20) - have h37 : (0:ℝ) ≤ 214614205815431393733148792819846945536633335373334115752048809273342647443432539934607000062616305939408924323 * α ^ 37 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 19) - have h38 : (0:ℝ) ≤ 232391950882130480511841466255675296149805103394932221634682309682031574184073376765275830067134447105269029319 * α ^ 38 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 38)) (pow_nonneg hu 18) - have h39 : (0:ℝ) ≤ 227646786129095617123180754743680811362220841807439017659139374884333921571156246794142321243097055097178445825 * α ^ 39 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 39)) (pow_nonneg hu 17) - have h40 : (0:ℝ) ≤ 201151592000254076319111933803082921016858033652344635301102367059012097196101762301692963719714653038174763855 * α ^ 40 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 40)) (pow_nonneg hu 16) - have h41 : (0:ℝ) ≤ 159796714515585050308711763046365954383154641733651622252372673160438440025715520354135554841621456682694603135 * α ^ 41 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 41)) (pow_nonneg hu 15) - have h42 : (0:ℝ) ≤ 113694441321074008752288203116701595054184371599569875421293420056220499034682316015196771177249973056572181735 * α ^ 42 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 42)) (pow_nonneg hu 14) - have h43 : (0:ℝ) ≤ 72130500744694542887028943813151106507208801012210269142093276885199604435222351545247283246975115560376609205 * α ^ 43 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 43)) (pow_nonneg hu 13) - have h44 : (0:ℝ) ≤ 40593915959417627531746494374957888051425398581583793505319726935377556193558075899850407121984115730929357755 * α ^ 44 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 44)) (pow_nonneg hu 12) - have h45 : (0:ℝ) ≤ 20142112914146928990742750521398817973806574189219001955193033477789707030767693751116805380225357379276747519 * α ^ 45 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 45)) (pow_nonneg hu 11) - have h46 : (0:ℝ) ≤ 8746984555426014571216178944742661168209625273320645227018468690933303880145359024731425263277253405247586951 * α ^ 46 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 46)) (pow_nonneg hu 10) - have h47 : (0:ℝ) ≤ 3294813943512375946477459661112271578543735031048904613485581394105299356535226701518930871689765592849920009 * α ^ 47 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 47)) (pow_nonneg hu 9) - have h48 : (0:ℝ) ≤ 1064633594182767781418524670877965310710625221215403900701843563201440674916875929401734783421144317918768437 * α ^ 48 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 48)) (pow_nonneg hu 8) - have h49 : (0:ℝ) ≤ 290979947292633634820286085206318086271058595522743900697255282277868275830483412118913673100403134596829605 * α ^ 49 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 49)) (pow_nonneg hu 7) - have h50 : (0:ℝ) ≤ 66053632008286815218730609011172165768275118555864770965140596782012442105314066073321580207922244489207001 * α ^ 50 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 50)) (pow_nonneg hu 6) - have h51 : (0:ℝ) ≤ 12152795314691969352387359587094653935442718022653966020106284283370382118838609048927994949757671991794739 * α ^ 51 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 51)) (pow_nonneg hu 5) - have h52 : (0:ℝ) ≤ 1751156608268941082844684121012320147103407396012602177215161083358650243742317419805210038235339659097451 * α ^ 52 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 52)) (pow_nonneg hu 4) - have h53 : (0:ℝ) ≤ 187813139479594914512845605964389800598941841721249536400462885091353372097871422654926648798226033258823 * α ^ 53 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 53)) (pow_nonneg hu 3) - have h54 : (0:ℝ) ≤ 13802072582465965788484953766306541577986163631972344323322049452623866943671442557170586787638780254425 * α ^ 54 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 54)) (pow_nonneg hu 2) - have h55 : (0:ℝ) ≤ 594982734136165220266045344041112246141469375919551772765097596644107694713723809345475527250815129375 * α ^ 55 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 55)) (pow_nonneg hu 1) - have h56 : (0:ℝ) ≤ 10211558413705494402424769335540267701249567140173495481288972120637089282914579657148619242232312500 * α ^ 56 := - mul_nonneg (by norm_num) (pow_nonneg hα 56) have hid : (17 : ℝ) ^ 56 * (1180273288616099684023784650402498199886255444730023274978571199510266513047596 + 11055102824011442029948266567510506642575381276841013106178383140649638883273740 * α + 49922645194024990734283616516471280600334184364447547102243551298880869797559488 * α ^ 2 + 144719942608174873104026182095524650959577750970144395839719569131273169856379216 * α ^ 3 + 302526482246635225757578631533959631447003848728875689601323895427543714021299068 * α ^ 4 + 485662255765025402514981086091947264736043236799566038683821482401809082117981716 * α ^ 5 + 622606333409943749753890815208648354755606137297243000849237534232491249017638372 * α ^ 6 + 654352069860427639900751348035281558837881303628117455206054590616141095225034932 * α ^ 7 + 574357399231416827070511854689853503943460240353865007966655407656850680547039034 * α ^ 8 + 426752571345870223801790426727818388140106457832728071034614633845667453226768626 * α ^ 9 + 271079935317622563319456334579591661701883897872193010593643933885082711035509852 * α ^ 10 + 148286371479076003045732417755582133525685636981220867944156217604240361014274724 * α ^ 11 + 70217169066647225915394151645973808431273168363378941311910545513943342491505944 * α ^ 12 + 28882635903906998561313897779843874583553384770520360078626138405360811163881868 * α ^ 13 + 10340675254845519580917140785070160244501596661998078491888557158268998114446532 * α ^ 14 + 3224423637549642502496418645711742177932306998129835583325750859424757337666996 * α ^ 15 + 875062504101721302059576940201180260130574140021726848117119157209427049292266 * α ^ 16 + 206253961710804940753907484420744734282964403780943395544748624256594408470306 * α ^ 17 + 42070236802464351764635254679415144786913128539020355841577805021278534599952 * α ^ 18 + 7386217051829558880237703381942358818281589489452528309990518263995367432488 * α ^ 19 + 1107793613576531791057535432236447149617292886122026324465700872270457547494 * α ^ 20 + 140459087137897856469559866359157699541937133355950394902889100420287426914 * α ^ 21 + 14838359760717420231756157247609092582149974794155897343599292760550967914 * α ^ 22 + 1279004725824261809420174464624373933895777466651732360112330465852550258 * α ^ 23 + 87033426312093344876434088654180488427125423854890952784009041976465947 * α ^ 24 + 4369112665592393971521458232346790403396711247658540001242310421975335 * α ^ 25 + 97654992764826340667007297954456940399851548824989983096539223841294 * α ^ 26 - 140180336953330902099623933788922389004727627031585783295797300519590 * α ^ 27 + 4011521197356040330478113154305443808925568648433687983973999832370 * α ^ 28 - 6836116057285781356883522416064683372386240155164063320736832232 * α ^ 29 + 136155913451608763461692617832470536736112881493096843133744560 * α ^ 30 + 23084190208503516369122355362110577411004819796039225427268288 * α ^ 31 + 1272092669921250187525125636594403706428638167041905626630688 * α ^ 32 + 43743288386492835342171671864673441962710429642110919385856 * α ^ 33 + 919770851750237042763795205605716932136524848257092998144 * α ^ 34 + 3589129787637507437982773070768409846725811870537367040 * α ^ 35 - 616787227367020803961294798626057817769112354291227136 * α ^ 36 - 30943009074599150760660807547437896432729575808956416 * α ^ 37 - 952040288448666548370356300676837076289373764554752 * α ^ 38 - 22303674458304714179931228274300996373189822005248 * α ^ 39 - 424667137052011465151087643604559827985297448960 * α ^ 40 - 6764616781706422065650823730243312809557557248 * α ^ 41 - 91516551558371359215307258976568083952304128 * α ^ 42 - 1060132719651553338827644611213921972781056 * α ^ 43 - 10557532799422900249752275241549216743424 * α ^ 44 - 90481973634654084996556237361914576896 * α ^ 45 - 666432341608325016551912342849323008 * α ^ 46 - 4202788903097596849838434642034688 * α ^ 47 - 22554190076903951857505928216576 * α ^ 48 - 102065451905712762371350462464 * α ^ 49 - 384517782188687390618419200 * α ^ 50 - 1184406710041525201403904 * α ^ 51 - 2906644614364092432384 * α ^ 52 - 5467069217104723968 * α ^ 53 - 7402337748385792 * α ^ 54 - 6424197332992 * α ^ 55 - 2684354560 * α ^ 56) = 1180273288616099684023784650402498199886255444730023274978571199510266513047596 * (17 - α) ^ 56 + 254032052170696096814452472070218512117411786611178526203832500563618785746318956 * α ^ 1 * (17 - α) ^ 55 + 26581786465992714133606222775502371032129394160055924210292174209129794157448936772 * α ^ 2 * (17 - α) ^ 54 + 1801905125284524294246494051997323405505883272969655457886034380748404658915029385356 * α ^ 3 * (17 - α) ^ 53 + 88960777843487839207354469588977939024483934333485516580514560192823003078437474637384 * α ^ 4 * (17 - α) ^ 52 + 3409710295444689753751021773779609449447011909852801588651071013422638895502085385574456 * α ^ 5 * (17 - α) ^ 51 + 105611745061099871040994619483246321125469657724218486870230193879528974892413607636605284 * α ^ 6 * (17 - α) ^ 50 + 2717077493210926098447489650385141874390859518222133351745212828060950258218810177908282556 * α ^ 7 * (17 - α) ^ 49 + 59226539189538299382222748715390123146365770386986878118026762708622792734361308033174370018 * α ^ 8 * (17 - α) ^ 48 + 1110347623085275380732784124563019672170207376288907445733220470280957735947728184470496756010 * α ^ 9 * (17 - α) ^ 47 + 18112519692658810410404967374345439836251270145825076491663143586046571832030458464477826206258 * α ^ 10 * (17 - α) ^ 46 + 259468406097457687929633525944011735968016319542087733822510053479299676655957583926253741360502 * α ^ 11 * (17 - α) ^ 45 + 3288616364869040104475987141993494253571602787363843112397732704776764511075222653495077733735718 * α ^ 12 * (17 - α) ^ 44 + 37103473125865952584340786773431223496072304382597727768926156417429611089103427290200640921026334 * α ^ 13 * (17 - α) ^ 43 + 374523382812426223233967303671275687297451096894379697013331090967253251615175373801177901144258730 * α ^ 14 * (17 - α) ^ 42 + 3396494550442924093336698525515677714454583693723746546679078674756021148647562726100992633195827670 * α ^ 15 * (17 - α) ^ 41 + 27771451470570936428940278209636484839068297258115446941354573210378654498093153647787388326291195220 * α ^ 16 * (17 - α) ^ 40 + 205336433200531842769564752332775005425876161312494024088869532088213815964669131170023033890476305980 * α ^ 17 * (17 - α) ^ 39 + 1376302917197732669050568166563895672822852883204651206746822345275035657680019417369627527115086850120 * α ^ 18 * (17 - α) ^ 38 + 8380155294397784796024596289754563707905478379672589828457151616147990659832389424273341383748688207080 * α ^ 19 * (17 - α) ^ 37 + 46434805880795731321224499533392807251809590691101718819109701496201837794500680135302573321020690890746 * α ^ 20 * (17 - α) ^ 36 + 234491333325177991679288999498604121924586729800797548175219657080832899570210449706339657838128968884354 * α ^ 21 * (17 - α) ^ 35 + 1080514930086925704280859540483502286254671084929525637672420222697615347555423346347115532203110643365136 * α ^ 22 * (17 - α) ^ 34 + 4547675284413232416488077752788320517949654297288884032643195010720956134703008952100555630475629759787488 * α ^ 23 * (17 - α) ^ 33 + 17496546097098586152071398152312222042613115074033174731514387311101666529876250406780911401607973057493255 * α ^ 24 * (17 - α) ^ 32 + 61573424970057153431741932997114452252230749510452379581517661469288846340022317444210252355996069897749331 * α ^ 25 * (17 - α) ^ 31 + 198297654024175037814903698649403184988215012123240470670091291048259056629782551733808484416396638864067091 * α ^ 26 * (17 - α) ^ 30 + 584610302749161753333489816331275650573703865862791211866486561498961706693997631039254643972613296017180617 * α ^ 27 * (17 - α) ^ 29 + 1578046905956627892814531753544431465414315118110738633436435926556242944082783767807930560452112935615842171 * α ^ 28 * (17 - α) ^ 28 + 3900276267502012608001991748970773203576515687854492513578111746545720357741690474840268134056865690598209279 * α ^ 29 * (17 - α) ^ 27 + 8825565680944180807206852648457428249507576570214954247410910715730515927908602962682166825659628608449565179 * α ^ 30 * (17 - α) ^ 26 + 18278222890683728517844209588507295086668349633646134150369498537778483167121641476779372484086759659269711781 * α ^ 31 * (17 - α) ^ 25 + 34630021303309994264801974849783975057715767549012563612835970835153541351334334084636838049899704411229419039 * α ^ 32 * (17 - α) ^ 24 + 59976325403926759553950096138547851891588162346459693279652757133352417289699475136155912596938565990681022967 * α ^ 33 * (17 - α) ^ 23 + 94859908857514726802312972207926527679144706496572092127703134483420755663937004295941931559564856864612372015 * α ^ 34 * (17 - α) ^ 22 + 136838029261198215465308944618229439296028860400759258689603958243702943063871561985963901374611376885862608933 * α ^ 35 * (17 - α) ^ 21 + 179750481304348065934713749450324777683615725218792657415497203296024872885988657067853702018371602813684069687 * α ^ 36 * (17 - α) ^ 20 + 214614205815431393733148792819846945536633335373334115752048809273342647443432539934607000062616305939408924323 * α ^ 37 * (17 - α) ^ 19 + 232391950882130480511841466255675296149805103394932221634682309682031574184073376765275830067134447105269029319 * α ^ 38 * (17 - α) ^ 18 + 227646786129095617123180754743680811362220841807439017659139374884333921571156246794142321243097055097178445825 * α ^ 39 * (17 - α) ^ 17 + 201151592000254076319111933803082921016858033652344635301102367059012097196101762301692963719714653038174763855 * α ^ 40 * (17 - α) ^ 16 + 159796714515585050308711763046365954383154641733651622252372673160438440025715520354135554841621456682694603135 * α ^ 41 * (17 - α) ^ 15 + 113694441321074008752288203116701595054184371599569875421293420056220499034682316015196771177249973056572181735 * α ^ 42 * (17 - α) ^ 14 + 72130500744694542887028943813151106507208801012210269142093276885199604435222351545247283246975115560376609205 * α ^ 43 * (17 - α) ^ 13 + 40593915959417627531746494374957888051425398581583793505319726935377556193558075899850407121984115730929357755 * α ^ 44 * (17 - α) ^ 12 + 20142112914146928990742750521398817973806574189219001955193033477789707030767693751116805380225357379276747519 * α ^ 45 * (17 - α) ^ 11 + 8746984555426014571216178944742661168209625273320645227018468690933303880145359024731425263277253405247586951 * α ^ 46 * (17 - α) ^ 10 + 3294813943512375946477459661112271578543735031048904613485581394105299356535226701518930871689765592849920009 * α ^ 47 * (17 - α) ^ 9 + 1064633594182767781418524670877965310710625221215403900701843563201440674916875929401734783421144317918768437 * α ^ 48 * (17 - α) ^ 8 + 290979947292633634820286085206318086271058595522743900697255282277868275830483412118913673100403134596829605 * α ^ 49 * (17 - α) ^ 7 + 66053632008286815218730609011172165768275118555864770965140596782012442105314066073321580207922244489207001 * α ^ 50 * (17 - α) ^ 6 + 12152795314691969352387359587094653935442718022653966020106284283370382118838609048927994949757671991794739 * α ^ 51 * (17 - α) ^ 5 + 1751156608268941082844684121012320147103407396012602177215161083358650243742317419805210038235339659097451 * α ^ 52 * (17 - α) ^ 4 + 187813139479594914512845605964389800598941841721249536400462885091353372097871422654926648798226033258823 * α ^ 53 * (17 - α) ^ 3 + 13802072582465965788484953766306541577986163631972344323322049452623866943671442557170586787638780254425 * α ^ 54 * (17 - α) ^ 2 + 594982734136165220266045344041112246141469375919551772765097596644107694713723809345475527250815129375 * α ^ 55 * (17 - α) ^ 1 + 10211558413705494402424769335540267701249567140173495481288972120637089282914579657148619242232312500 * α ^ 56 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 1180273288616099684023784650402498199886255444730023274978571199510266513047596 * (17 - α) ^ 56 := - mul_pos (by norm_num) (pow_pos (by linarith) 56) - linarith - · have hpos : (0 : ℝ) < 10211558413705494402424769335540267701249567140173495481288972120637089282914579657148619242232312500 * α ^ 56 := - mul_pos (by norm_num) (pow_pos (by linarith) 56) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 56)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree60_63.lean b/Sendov/FiniteRange/Degree60_63.lean index 3235414..6b89ae4 100644 --- a/Sendov/FiniteRange/Degree60_63.lean +++ b/Sendov/FiniteRange/Degree60_63.lean @@ -88,133 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 + 16985863033574280235844441932687847244474918343296922124467065830558560591641911607696 * α + 79535686565443616767714198705465441607069525916537281975943363396026310601750092892488 * α ^ 2 + 239403368066863055363036191982445140250970254028533507257869611464498452359820776516672 * α ^ 3 + 520412199687668549649368000742289832307395871986227854434049639793742028919048260538980 * α ^ 4 + 870157990458303443210342456693112304974391575125591793142671535717764222680483811054120 * α ^ 5 + 1163895406905166893909394336483096101920864956907539643884037297958617393209091960980980 * α ^ 6 + 1278712702347990314588936279615328559669420142052152673561809586945926657118282053100192 * α ^ 7 + 1175725999507118690334304481188590417967828338375807066246239349405176693210977652965164 * α ^ 8 + 917174565683194380325199349414315003531063568224297761645149376513377860921193466166360 * α ^ 9 + 613220450431269534465945368150179786921282701580434508261534043083701875736956664994572 * α ^ 10 + 354057578771667900301737961009087756507978666072508030411200442531544505558679233553472 * α ^ 11 + 177508212962690728847102755764000185519630950904902948797136565592445320434555097902358 * α ^ 12 + 77576143881435246639915934911657056385846898645191797585491387399418570120013455336412 * α ^ 13 + 29625606539961534087112448697426117322036816304400291238815402402574337305159894234710 * α ^ 14 + 9897983624006015895072166102753315050019559506815047218656308374776682178809801281072 * α ^ 15 + 2893024329186264383797233494270141942147451227576867206489337752203105179024976096612 * α ^ 16 + 738824037484601173560395482737511489082491085984005275312812825534063503137534438984 * α ^ 17 + 164441392895370259121202826289551958180582089330511860705087484253672173523954414324 * α ^ 18 + 31771089808007468337610992777240040391387210585565359776690610466850812101226150720 * α ^ 19 + 5298220195377128677201324507710581490774005592592493587530562214239637638718207838 * α ^ 20 + 756659597417575188091510844865331006747834890107597233256807850344151631080238572 * α ^ 21 + 91559608573015197712368058376578410389957871248555658418907655613710858144349974 * α ^ 22 + 9249930419338172598175237698997019936144549918443437721165100485815394918388112 * α ^ 23 + 763883913294738134810454963300633389711111356082193955572628106712061571529450 * α ^ 24 + 49887514803037691118937977551057551319824185688173200456490865107511572859188 * α ^ 25 + 2408300944763273858718491162262422770972533056902127038712768748993172577610 * α ^ 26 + 51725078185114864055621675260185352972397611437758098966549358454837797760 * α ^ 27 - 77510592929500392468407361123374953300216693743671418464304395453235289971 * α ^ 28 + 2067570494221092433188386134604931347621528152582381523034724429480663810 * α ^ 29 - 4580593295775337280722829599699027320935759304984497739306397718132427 * α ^ 30 + 167416972491317272532611766388094644865407567559322236979252017800 * α ^ 31 + 8389683035480047874686298369093744577278032988658533654716580671488 * α ^ 32 + 533168330392361738160636316662426153463437758146484284733956527840 * α ^ 33 + 20133734272551384350294239387428682262688585273913890267463998960 * α ^ 34 + 493961052258347053233401169722862536905607351132290352999275776 * α ^ 35 + 5693741143796291743936421907647419400331769333817148390864384 * α ^ 36 - 136838149185369327185106181434226275722488605188850651649536 * α ^ 37 - 10213381894013887312358741093692449757528996456249043806464 * α ^ 38 - 350916645279993747972377869550082945451923877049098721280 * α ^ 39 - 8752703600310726164117509854956335599020724135444320256 * α ^ 40 - 174795107690037567064791487247091959281487206843686912 * α ^ 41 - 2905560404482515211390475250648416164278477823340544 * α ^ 42 - 40986185232466565782519730515559353841538308898816 * α ^ 43 - 495823850271711791881581412818585367225361694720 * α ^ 44 - 5173168623120670073594814754124350179396943872 * α ^ 45 - 46665067131765629087874046716431817185624064 * α ^ 46 - 363947916336732295692730495412120808062976 * α ^ 47 - 2448922340507063244670480160751278358528 * α ^ 48 - 14156403192874033788431089246006149120 * α ^ 49 - 69840635580766128998624519726825472 * α ^ 50 - 291304208587694376741876403273728 * α ^ 51 - 1013847100270960749479253245952 * α ^ 52 - 2890985222950997734006456320 * α ^ 53 - 6580251459272551201505280 * α ^ 54 - 11498869995682148646912 * α ^ 55 - 14487778418579472384 * α ^ 56 - 11716883921240064 * α ^ 57 - 4568503025664 * α ^ 58 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 * (17 - α) ^ 58 := - mul_nonneg (by norm_num) (pow_nonneg hu 58) - have h1 : (0:ℝ) ≤ 390326433597525193146123071698409867301520390117218290267746409833092718425696728651808 * α ^ 1 * (17 - α) ^ 57 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 57) - have h2 : (0:ℝ) ≤ 42339767414709412024800543085671455832484522045547354532982698096600368845688639786434272 * α ^ 2 * (17 - α) ^ 56 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 56) - have h3 : (0:ℝ) ≤ 2978288251912812668426975142881017511384301236011339350466382171100719277406612535201202432 * α ^ 3 * (17 - α) ^ 55 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 55) - have h4 : (0:ℝ) ≤ 152745949949503787162875767681479712010274958086345519055757721242134449740576558561672466100 * α ^ 4 * (17 - α) ^ 54 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 54) - have h5 : (0:ℝ) ≤ 6088522642574857806357024467621421962247301068049055791879352484148857589737344570006424306432 * α ^ 5 * (17 - α) ^ 53 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 53) - have h6 : (0:ℝ) ≤ 196353730172495768212131228592895964623220340501637536200602452342681588928305193631061786495128 * α ^ 6 * (17 - α) ^ 52 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 52) - have h7 : (0:ℝ) ≤ 5266157866495799387947512134510522910378331486905487931902457256370064452591463479230852331820688 * α ^ 7 * (17 - α) ^ 51 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 51) - have h8 : (0:ℝ) ≤ 119820143547425060414405575247909992318712489020361652433663435983410928998020585429365087295873272 * α ^ 8 * (17 - α) ^ 50 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 50) - have h9 : (0:ℝ) ≤ 2347881458090802952975815753665509878263409227272937917396103015417709833460343242062605055065007520 * α ^ 9 * (17 - α) ^ 49 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 49) - have h10 : (0:ℝ) ≤ 40087439558071587468650026480818375755059891510076862445505823029454511957690006955557287865611736368 * α ^ 10 * (17 - α) ^ 48 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 48) - have h11 : (0:ℝ) ≤ 601952482871233638447257366201476457757370789071367246820395949483198507616680072154695375018993206080 * α ^ 11 * (17 - α) ^ 47 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 47) - have h12 : (0:ℝ) ≤ 8009470199896280650115766696812280446758293363345211706745554624342950667301865303395190896548719848894 * α ^ 12 * (17 - α) ^ 46 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 46) - have h13 : (0:ℝ) ≤ 95019362618823693655434560324233095572340322211181765633801354884655907381821543655651592610813813891216 * α ^ 13 * (17 - α) ^ 45 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 45) - have h14 : (0:ℝ) ≤ 1010201707551433403309553561274371166022594138303310301376573778032472462922417174557444934419810264510660 * α ^ 14 * (17 - α) ^ 44 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 44) - have h15 : (0:ℝ) ≤ 9666021740205241072831491648575295854988543778205392913804696971472866176266073951546563512467374588927208 * α ^ 15 * (17 - α) ^ 43 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 43) - have h16 : (0:ℝ) ≤ 83539422247937309919557615020970488939815680020028362327882719748972398761527927690277222254506587818510230 * α ^ 16 * (17 - α) ^ 42 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 42) - have h17 : (0:ℝ) ≤ 654118420001028745738306390006036203398367424921715171378029833094091806885053261792691008623047458390979656 * α ^ 17 * (17 - α) ^ 41 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 41) - have h18 : (0:ℝ) ≤ 4652186358394523426651350117431277481053696460019422776379929513303869171324522998809216735658736365543149056 * α ^ 18 * (17 - α) ^ 40 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 40) - have h19 : (0:ℝ) ≤ 30118791616775324911184234952445703914857411555877912743140868805910755261334373116907433215385078679006707440 * α ^ 19 * (17 - α) ^ 39 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 39) - have h20 : (0:ℝ) ≤ 177826427793428069222664936517971981732084250622079798759954938089906960407318562179543208670385720641305484484 * α ^ 20 * (17 - α) ^ 38 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 38) - have h21 : (0:ℝ) ≤ 958974728072861489890512212348583321104118795534766915893103879494275523886658791163551854756652905815510994528 * α ^ 21 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 37) - have h22 : (0:ℝ) ≤ 4729723071531116796957485128322656283636236954549201452338482026970860715184248091976900742259324658054589766592 * α ^ 22 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 36) - have h23 : (0:ℝ) ≤ 21357626391876046213696677013115319309126810433424794269849513349981113078786111769550369530995181611742183411536 * α ^ 23 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 35) - have h24 : (0:ℝ) ≤ 88378492075701468992449068981435994543226968075794931456837379496731600212606957395063382063437679158720468757170 * α ^ 24 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 34) - have h25 : (0:ℝ) ≤ 335374317924993519374894630236901278966604414721735688724835686564184905864027923099074702766636244586098764495656 * α ^ 25 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 33) - have h26 : (0:ℝ) ≤ 1167747403010750979143600445942797877583165267655942642217360148980523954073844543734436948340308328790173989450240 * α ^ 26 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 32) - have h27 : (0:ℝ) ≤ 3732406493950907275441950492949127432338499662676613602897135646128454363022292331302101040551201738067461761785664 * α ^ 27 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 31) - have h28 : (0:ℝ) ≤ 10954129200438058193458578123785740490187961119866684050714899067863611709664062247915680616127050262599212424644897 * α ^ 28 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 30) - have h29 : (0:ℝ) ≤ 29524937330321420901887693835267567366420221233340924484096603443964250287652843237880043795863468001106755829620680 * α ^ 29 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 29) - have h30 : (0:ℝ) ≤ 73087125140139025535278935287700443682500254736472038981634113551624541486231287807821582020794101152220739006249054 * α ^ 30 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 28) - have h31 : (0:ℝ) ≤ 166147644042440368311067169194067229624014747885167057075915274327610140356799603915688925405707986646551735878107548 * α ^ 31 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 27) - have h32 : (0:ℝ) ≤ 346772843057251234464569444053204287523460387723124946687308651228411784130792835892965479313436122483094189414638435 * α ^ 32 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 26) - have h33 : (0:ℝ) ≤ 664225955992969098770607024010663586597562367955519444707479326460670050391696600135144018377249349272512491633374996 * α ^ 33 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 25) - have h34 : (0:ℝ) ≤ 1166927452705629997542488080350699352093937922567202455194634401101839128946832909551419826543265369338614818217043960 * α ^ 34 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 24) - have h35 : (0:ℝ) ≤ 1878756607833380897964887521267252840224951551991841799719666838851961513969673042361037791640974884809523420884857896 * α ^ 35 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 23) - have h36 : (0:ℝ) ≤ 2769054221066722167360357163072398302792888941316285917570542419942819549648264402600819292556739224578295584544111593 * α ^ 36 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 22) - have h37 : (0:ℝ) ≤ 3731200624302652450167208268451073697815114712494349214865173019453170935880402861700349003895204451567678626785884944 * α ^ 37 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 21) - have h38 : (0:ℝ) ≤ 4589060320062131760404941760267700835789214136011164185047467243912104258380281276437542650223991907463154227654480250 * α ^ 38 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 38)) (pow_nonneg hu 20) - have h39 : (0:ℝ) ≤ 5142005613111678624089090068072653156514352316794579159234104771289794844001366200904371725907143894777202797701901140 * α ^ 39 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 39)) (pow_nonneg hu 19) - have h40 : (0:ℝ) ≤ 5237411173258795881045797059007984704429066340121408567111553635714834497251049352739808449923037569813646734054022299 * α ^ 40 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 40)) (pow_nonneg hu 18) - have h41 : (0:ℝ) ≤ 4836963127294992600059755436214556792844531244095433636867849886599932076358086832823383902964112824599524794814907660 * α ^ 41 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 41)) (pow_nonneg hu 17) - have h42 : (0:ℝ) ≤ 4038642993383808502646993082987941730662364203715934601149860715099116021657255631782766462484195430978656049244711644 * α ^ 42 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 42)) (pow_nonneg hu 16) - have h43 : (0:ℝ) ≤ 3038452569137952848001398255617645415509309374884449236698224469982642958671749123930862050454967951657624568575856688 * α ^ 43 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 43)) (pow_nonneg hu 15) - have h44 : (0:ℝ) ≤ 2051868663368925893596995729015571533363774183714583901584727359036447948070300988236179249392897564162618659414308125 * α ^ 44 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 44)) (pow_nonneg hu 14) - have h45 : (0:ℝ) ≤ 1238175994140035374637906473341260146948966827890334540274993830863642501653683339638928725989225430525272809854519160 * α ^ 45 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 45)) (pow_nonneg hu 13) - have h46 : (0:ℝ) ≤ 664157193310869042816823748632341892142095205218119162176744496952019558037232907168597445007823380125777368765119662 * α ^ 46 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 46)) (pow_nonneg hu 12) - have h47 : (0:ℝ) ≤ 314709886085135861297147136857650883344977185951101514937597344260222119762475730654304761445438390089176776231442524 * α ^ 47 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 47)) (pow_nonneg hu 11) - have h48 : (0:ℝ) ≤ 130752300650671071539193189087470650687679774298245936504525933790335489689909687270813505169056399644554354547239027 * α ^ 48 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 48)) (pow_nonneg hu 10) - have h49 : (0:ℝ) ≤ 47197367207696915154864396118931631129224589120774745992092456851672119895365941889175184835650784414267376300303620 * α ^ 49 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 49)) (pow_nonneg hu 9) - have h50 : (0:ℝ) ≤ 14634551667218002061058569723384799807420346162568828832552477052180173516934500629665142381604576011817456177436512 * α ^ 50 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 50)) (pow_nonneg hu 8) - have h51 : (0:ℝ) ≤ 3842020781478673446935098659029021030741590331823487291470293090299720569242182142621667182316185787786272194127544 * α ^ 51 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 51)) (pow_nonneg hu 7) - have h52 : (0:ℝ) ≤ 838031670173391441198956875841265626545050410662677811959134541401400325959689376985919100766189972881282787577763 * α ^ 52 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 52)) (pow_nonneg hu 6) - have h53 : (0:ℝ) ≤ 148041122984446508528033501826038847912820726117568892710474612036947233357823264896703744164136565988458171335488 * α ^ 53 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 53)) (pow_nonneg hu 5) - have h54 : (0:ℝ) ≤ 20425027753973244256487010270626798809629979580987772972987591577599400419675783451565774908699336057777964446110 * α ^ 54 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 54)) (pow_nonneg hu 4) - have h55 : (0:ℝ) ≤ 2082801294909426227172103997302542506576066130763213820723347100167035816595437754294159646550971592826080127596 * α ^ 55 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 55)) (pow_nonneg hu 3) - have h56 : (0:ℝ) ≤ 143053115347005574042966026900851192531277156875872861510463214959748868032658829240606333338274956129514869223 * α ^ 56 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 56)) (pow_nonneg hu 2) - have h57 : (0:ℝ) ≤ 5492607925836276782575645752168619846129179160632349319557999016078091770978332301317881391624780373381782060 * α ^ 57 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 57)) (pow_nonneg hu 1) - have h58 : (0:ℝ) ≤ 68316788541465931995562079450677157534774523435506193215243865134760205880356610515710383859614369923388540 * α ^ 58 := - mul_nonneg (by norm_num) (pow_nonneg hα 58) have hid : (17 : ℝ) ^ 58 * (1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 + 16985863033574280235844441932687847244474918343296922124467065830558560591641911607696 * α + 79535686565443616767714198705465441607069525916537281975943363396026310601750092892488 * α ^ 2 + 239403368066863055363036191982445140250970254028533507257869611464498452359820776516672 * α ^ 3 + 520412199687668549649368000742289832307395871986227854434049639793742028919048260538980 * α ^ 4 + 870157990458303443210342456693112304974391575125591793142671535717764222680483811054120 * α ^ 5 + 1163895406905166893909394336483096101920864956907539643884037297958617393209091960980980 * α ^ 6 + 1278712702347990314588936279615328559669420142052152673561809586945926657118282053100192 * α ^ 7 + 1175725999507118690334304481188590417967828338375807066246239349405176693210977652965164 * α ^ 8 + 917174565683194380325199349414315003531063568224297761645149376513377860921193466166360 * α ^ 9 + 613220450431269534465945368150179786921282701580434508261534043083701875736956664994572 * α ^ 10 + 354057578771667900301737961009087756507978666072508030411200442531544505558679233553472 * α ^ 11 + 177508212962690728847102755764000185519630950904902948797136565592445320434555097902358 * α ^ 12 + 77576143881435246639915934911657056385846898645191797585491387399418570120013455336412 * α ^ 13 + 29625606539961534087112448697426117322036816304400291238815402402574337305159894234710 * α ^ 14 + 9897983624006015895072166102753315050019559506815047218656308374776682178809801281072 * α ^ 15 + 2893024329186264383797233494270141942147451227576867206489337752203105179024976096612 * α ^ 16 + 738824037484601173560395482737511489082491085984005275312812825534063503137534438984 * α ^ 17 + 164441392895370259121202826289551958180582089330511860705087484253672173523954414324 * α ^ 18 + 31771089808007468337610992777240040391387210585565359776690610466850812101226150720 * α ^ 19 + 5298220195377128677201324507710581490774005592592493587530562214239637638718207838 * α ^ 20 + 756659597417575188091510844865331006747834890107597233256807850344151631080238572 * α ^ 21 + 91559608573015197712368058376578410389957871248555658418907655613710858144349974 * α ^ 22 + 9249930419338172598175237698997019936144549918443437721165100485815394918388112 * α ^ 23 + 763883913294738134810454963300633389711111356082193955572628106712061571529450 * α ^ 24 + 49887514803037691118937977551057551319824185688173200456490865107511572859188 * α ^ 25 + 2408300944763273858718491162262422770972533056902127038712768748993172577610 * α ^ 26 + 51725078185114864055621675260185352972397611437758098966549358454837797760 * α ^ 27 - 77510592929500392468407361123374953300216693743671418464304395453235289971 * α ^ 28 + 2067570494221092433188386134604931347621528152582381523034724429480663810 * α ^ 29 - 4580593295775337280722829599699027320935759304984497739306397718132427 * α ^ 30 + 167416972491317272532611766388094644865407567559322236979252017800 * α ^ 31 + 8389683035480047874686298369093744577278032988658533654716580671488 * α ^ 32 + 533168330392361738160636316662426153463437758146484284733956527840 * α ^ 33 + 20133734272551384350294239387428682262688585273913890267463998960 * α ^ 34 + 493961052258347053233401169722862536905607351132290352999275776 * α ^ 35 + 5693741143796291743936421907647419400331769333817148390864384 * α ^ 36 - 136838149185369327185106181434226275722488605188850651649536 * α ^ 37 - 10213381894013887312358741093692449757528996456249043806464 * α ^ 38 - 350916645279993747972377869550082945451923877049098721280 * α ^ 39 - 8752703600310726164117509854956335599020724135444320256 * α ^ 40 - 174795107690037567064791487247091959281487206843686912 * α ^ 41 - 2905560404482515211390475250648416164278477823340544 * α ^ 42 - 40986185232466565782519730515559353841538308898816 * α ^ 43 - 495823850271711791881581412818585367225361694720 * α ^ 44 - 5173168623120670073594814754124350179396943872 * α ^ 45 - 46665067131765629087874046716431817185624064 * α ^ 46 - 363947916336732295692730495412120808062976 * α ^ 47 - 2448922340507063244670480160751278358528 * α ^ 48 - 14156403192874033788431089246006149120 * α ^ 49 - 69840635580766128998624519726825472 * α ^ 50 - 291304208587694376741876403273728 * α ^ 51 - 1013847100270960749479253245952 * α ^ 52 - 2890985222950997734006456320 * α ^ 53 - 6580251459272551201505280 * α ^ 54 - 11498869995682148646912 * α ^ 55 - 14487778418579472384 * α ^ 56 - 11716883921240064 * α ^ 57 - 4568503025664 * α ^ 58) = 1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 * (17 - α) ^ 58 + 390326433597525193146123071698409867301520390117218290267746409833092718425696728651808 * α ^ 1 * (17 - α) ^ 57 + 42339767414709412024800543085671455832484522045547354532982698096600368845688639786434272 * α ^ 2 * (17 - α) ^ 56 + 2978288251912812668426975142881017511384301236011339350466382171100719277406612535201202432 * α ^ 3 * (17 - α) ^ 55 + 152745949949503787162875767681479712010274958086345519055757721242134449740576558561672466100 * α ^ 4 * (17 - α) ^ 54 + 6088522642574857806357024467621421962247301068049055791879352484148857589737344570006424306432 * α ^ 5 * (17 - α) ^ 53 + 196353730172495768212131228592895964623220340501637536200602452342681588928305193631061786495128 * α ^ 6 * (17 - α) ^ 52 + 5266157866495799387947512134510522910378331486905487931902457256370064452591463479230852331820688 * α ^ 7 * (17 - α) ^ 51 + 119820143547425060414405575247909992318712489020361652433663435983410928998020585429365087295873272 * α ^ 8 * (17 - α) ^ 50 + 2347881458090802952975815753665509878263409227272937917396103015417709833460343242062605055065007520 * α ^ 9 * (17 - α) ^ 49 + 40087439558071587468650026480818375755059891510076862445505823029454511957690006955557287865611736368 * α ^ 10 * (17 - α) ^ 48 + 601952482871233638447257366201476457757370789071367246820395949483198507616680072154695375018993206080 * α ^ 11 * (17 - α) ^ 47 + 8009470199896280650115766696812280446758293363345211706745554624342950667301865303395190896548719848894 * α ^ 12 * (17 - α) ^ 46 + 95019362618823693655434560324233095572340322211181765633801354884655907381821543655651592610813813891216 * α ^ 13 * (17 - α) ^ 45 + 1010201707551433403309553561274371166022594138303310301376573778032472462922417174557444934419810264510660 * α ^ 14 * (17 - α) ^ 44 + 9666021740205241072831491648575295854988543778205392913804696971472866176266073951546563512467374588927208 * α ^ 15 * (17 - α) ^ 43 + 83539422247937309919557615020970488939815680020028362327882719748972398761527927690277222254506587818510230 * α ^ 16 * (17 - α) ^ 42 + 654118420001028745738306390006036203398367424921715171378029833094091806885053261792691008623047458390979656 * α ^ 17 * (17 - α) ^ 41 + 4652186358394523426651350117431277481053696460019422776379929513303869171324522998809216735658736365543149056 * α ^ 18 * (17 - α) ^ 40 + 30118791616775324911184234952445703914857411555877912743140868805910755261334373116907433215385078679006707440 * α ^ 19 * (17 - α) ^ 39 + 177826427793428069222664936517971981732084250622079798759954938089906960407318562179543208670385720641305484484 * α ^ 20 * (17 - α) ^ 38 + 958974728072861489890512212348583321104118795534766915893103879494275523886658791163551854756652905815510994528 * α ^ 21 * (17 - α) ^ 37 + 4729723071531116796957485128322656283636236954549201452338482026970860715184248091976900742259324658054589766592 * α ^ 22 * (17 - α) ^ 36 + 21357626391876046213696677013115319309126810433424794269849513349981113078786111769550369530995181611742183411536 * α ^ 23 * (17 - α) ^ 35 + 88378492075701468992449068981435994543226968075794931456837379496731600212606957395063382063437679158720468757170 * α ^ 24 * (17 - α) ^ 34 + 335374317924993519374894630236901278966604414721735688724835686564184905864027923099074702766636244586098764495656 * α ^ 25 * (17 - α) ^ 33 + 1167747403010750979143600445942797877583165267655942642217360148980523954073844543734436948340308328790173989450240 * α ^ 26 * (17 - α) ^ 32 + 3732406493950907275441950492949127432338499662676613602897135646128454363022292331302101040551201738067461761785664 * α ^ 27 * (17 - α) ^ 31 + 10954129200438058193458578123785740490187961119866684050714899067863611709664062247915680616127050262599212424644897 * α ^ 28 * (17 - α) ^ 30 + 29524937330321420901887693835267567366420221233340924484096603443964250287652843237880043795863468001106755829620680 * α ^ 29 * (17 - α) ^ 29 + 73087125140139025535278935287700443682500254736472038981634113551624541486231287807821582020794101152220739006249054 * α ^ 30 * (17 - α) ^ 28 + 166147644042440368311067169194067229624014747885167057075915274327610140356799603915688925405707986646551735878107548 * α ^ 31 * (17 - α) ^ 27 + 346772843057251234464569444053204287523460387723124946687308651228411784130792835892965479313436122483094189414638435 * α ^ 32 * (17 - α) ^ 26 + 664225955992969098770607024010663586597562367955519444707479326460670050391696600135144018377249349272512491633374996 * α ^ 33 * (17 - α) ^ 25 + 1166927452705629997542488080350699352093937922567202455194634401101839128946832909551419826543265369338614818217043960 * α ^ 34 * (17 - α) ^ 24 + 1878756607833380897964887521267252840224951551991841799719666838851961513969673042361037791640974884809523420884857896 * α ^ 35 * (17 - α) ^ 23 + 2769054221066722167360357163072398302792888941316285917570542419942819549648264402600819292556739224578295584544111593 * α ^ 36 * (17 - α) ^ 22 + 3731200624302652450167208268451073697815114712494349214865173019453170935880402861700349003895204451567678626785884944 * α ^ 37 * (17 - α) ^ 21 + 4589060320062131760404941760267700835789214136011164185047467243912104258380281276437542650223991907463154227654480250 * α ^ 38 * (17 - α) ^ 20 + 5142005613111678624089090068072653156514352316794579159234104771289794844001366200904371725907143894777202797701901140 * α ^ 39 * (17 - α) ^ 19 + 5237411173258795881045797059007984704429066340121408567111553635714834497251049352739808449923037569813646734054022299 * α ^ 40 * (17 - α) ^ 18 + 4836963127294992600059755436214556792844531244095433636867849886599932076358086832823383902964112824599524794814907660 * α ^ 41 * (17 - α) ^ 17 + 4038642993383808502646993082987941730662364203715934601149860715099116021657255631782766462484195430978656049244711644 * α ^ 42 * (17 - α) ^ 16 + 3038452569137952848001398255617645415509309374884449236698224469982642958671749123930862050454967951657624568575856688 * α ^ 43 * (17 - α) ^ 15 + 2051868663368925893596995729015571533363774183714583901584727359036447948070300988236179249392897564162618659414308125 * α ^ 44 * (17 - α) ^ 14 + 1238175994140035374637906473341260146948966827890334540274993830863642501653683339638928725989225430525272809854519160 * α ^ 45 * (17 - α) ^ 13 + 664157193310869042816823748632341892142095205218119162176744496952019558037232907168597445007823380125777368765119662 * α ^ 46 * (17 - α) ^ 12 + 314709886085135861297147136857650883344977185951101514937597344260222119762475730654304761445438390089176776231442524 * α ^ 47 * (17 - α) ^ 11 + 130752300650671071539193189087470650687679774298245936504525933790335489689909687270813505169056399644554354547239027 * α ^ 48 * (17 - α) ^ 10 + 47197367207696915154864396118931631129224589120774745992092456851672119895365941889175184835650784414267376300303620 * α ^ 49 * (17 - α) ^ 9 + 14634551667218002061058569723384799807420346162568828832552477052180173516934500629665142381604576011817456177436512 * α ^ 50 * (17 - α) ^ 8 + 3842020781478673446935098659029021030741590331823487291470293090299720569242182142621667182316185787786272194127544 * α ^ 51 * (17 - α) ^ 7 + 838031670173391441198956875841265626545050410662677811959134541401400325959689376985919100766189972881282787577763 * α ^ 52 * (17 - α) ^ 6 + 148041122984446508528033501826038847912820726117568892710474612036947233357823264896703744164136565988458171335488 * α ^ 53 * (17 - α) ^ 5 + 20425027753973244256487010270626798809629979580987772972987591577599400419675783451565774908699336057777964446110 * α ^ 54 * (17 - α) ^ 4 + 2082801294909426227172103997302542506576066130763213820723347100167035816595437754294159646550971592826080127596 * α ^ 55 * (17 - α) ^ 3 + 143053115347005574042966026900851192531277156875872861510463214959748868032658829240606333338274956129514869223 * α ^ 56 * (17 - α) ^ 2 + 5492607925836276782575645752168619846129179160632349319557999016078091770978332301317881391624780373381782060 * α ^ 57 * (17 - α) ^ 1 + 68316788541465931995562079450677157534774523435506193215243865134760205880356610515710383859614369923388540 * α ^ 58 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 * (17 - α) ^ 58 := - mul_pos (by norm_num) (pow_pos (by linarith) 58) - linarith - · have hpos : (0 : ℝ) < 68316788541465931995562079450677157534774523435506193215243865134760205880356610515710383859614369923388540 * α ^ 58 := - mul_pos (by norm_num) (pow_pos (by linarith) 58) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 58)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree64_69.lean b/Sendov/FiniteRange/Degree64_69.lean index 2da8d8f..cad1743 100644 --- a/Sendov/FiniteRange/Degree64_69.lean +++ b/Sendov/FiniteRange/Degree64_69.lean @@ -88,141 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 + 61381176382803809362111499051840544591370805103230496041366966719316985769735186577074210428 * α + 307875927191106748261011216414410411442655519490352054541897661765849218694794523337461209647 * α ^ 2 + 995139520442941110972922094595461359252165093278183682740950849972307343163433414772266439134 * α ^ 3 + 2329135965026413320254515390788191269701711986947806984107173389521959680472053301869564187977 * α ^ 4 + 4205152400427897818943955614854872603184778207497298031576474014041708453522600564012661712908 * α ^ 5 + 6092227728539116602774802993811227514150357030998079498007336022099744281828374410394763218967 * α ^ 6 + 7273914911154976681674028920562209810638892503140251984517953529760649706898772999266377410618 * α ^ 7 + 7294841936549908246762850463172756077551550164308271524011607481986853316219925718877268241253 * α ^ 8 + 6231636865479569934304365225476315224178754021865462499626075023963516933948459908031199504392 * α ^ 9 + 4582454355475931479184872096047779444629884546826401854025935798959693699768306789254756052107 * α ^ 10 + 2923936751602144899711097457334391073444202579871680510494335159924208835914470439635141162662 * α ^ 11 + 1628646305582237968027987059869036927850582412822128278929774316093217652148166106137543210729 * α ^ 12 + 795445013477937519140644933077682364729772242866058887702125127747950219835128702530435684436 * α ^ 13 + 341732386485246488082914550033328759932103344872452353652503157863279852435899383534716977739 * α ^ 14 + 129398024588904114703104106088147845845858920384624466782691337832071760366611282163240673066 * α ^ 15 + 43227083179690319937679095035602516318669269367605716008461368393810348604333859857847549497 * α ^ 16 + 12739734973954297734917244488839138405165723257781387930800239709000470619130237106664340656 * α ^ 17 + 3309003690560409027996242316235318569343087760556101911245828294749346009825368969657069031 * α ^ 18 + 755904091146328721648601114370911122594719522671458365690647375941659996310302273197058470 * α ^ 19 + 151378877572074703874732245694134372432105936678872727794384094115460812902730719423948317 * α ^ 20 + 26454923472459858634887234579799069438230123457614797089205636430511024677434784809220924 * α ^ 21 + 4009557348845189672922466111254379827931543987777056770742617262249980072703900044793759 * α ^ 22 + 522684797686516768766815870526767734538930901093141236380109988654434790535464480525226 * α ^ 23 + 57960196328928756537267261570029521956658673559059668642752896597993471772708261591453 * α ^ 24 + 5385398873189231308982589874195610465961820936268053590519181757629535422805253399024 * α ^ 25 + 410397478215636804806491132412571076795910317178146076050633000481647199256305822637 * α ^ 26 + 24812014519928905914570908638577043729393183935810050156873373621420956394826529722 * α ^ 27 + 1113510388782381458493062026644349844210314014993864209186922164992790354371374639 * α ^ 28 + 22409773065959463084902151065290205378008886892907135598840606673031087144995204 * α ^ 29 - 35763698158235183891226289780431937498580930947719484832564827737501564744289629 * α ^ 30 + 840760995622979288098811692316543958334461895228266842721825922823541893315826 * α ^ 31 - 2476024715094217195652794819915917218077074423531979390443969076889551332351 * α ^ 32 - 42343131706354479044867362267674031525737275327352243122650061208773859828 * α ^ 33 + 1121663574053726688315155444107301037632747178037371530068223719748652900 * α ^ 34 + 127119237016866360421264159870103175079883989461074891879168221493189568 * α ^ 35 + 5840998162333194724309799734276135965778520891167491660434664446065776 * α ^ 36 + 175992443424517154194105688439948495022759467456834921814514733630912 * α ^ 37 + 3457340410083421419722141826010375932802380080806011689658236008128 * α ^ 38 + 24387290416155856471527726331603437910487483092148051628143522304 * α ^ 39 - 1239885867289330313685948822187720768399781886302021720494414080 * α ^ 40 - 65142911505809786191440265839050522466645141325685819456216064 * α ^ 41 - 1919845972367683574507152058644769097612240398422850416591872 * α ^ 42 - 42690755951658679674359660598349223111852496540029559373824 * α ^ 43 - 774277941425789906408100254236527798872560249769923817472 * α ^ 44 - 11837447748695307877084872298248109006399402655405555712 * α ^ 45 - 155160542836944884945355229969272241433459624584396800 * α ^ 46 - 1760282021481048069096957321992926156742736627499008 * α ^ 47 - 17375591117616735181132725973057892264379050557440 * α ^ 48 - 149596040045196039764745879558857285877770747904 * α ^ 49 - 1123758519054636222507004226738421820190097408 * α ^ 50 - 7354587732063594511120345756955829080162304 * α ^ 51 - 41799839163275444256118641007392250134528 * α ^ 52 - 205261854328197847356177208926730715136 * α ^ 53 - 864576623781254196788511741560487936 * α ^ 54 - 3092645524632136056284929849294848 * α ^ 55 - 9268224902397535157105681498112 * α ^ 56 - 22840148173664707695687499776 * α ^ 57 - 45078822391172061959553024 * α ^ 58 - 68515609003558969540608 * α ^ 59 - 75294374818201206784 * α ^ 60 - 53251155240681472 * α ^ 61 - 18200997658624 * α ^ 62 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 * (17 - α) ^ 62 := - mul_nonneg (by norm_num) (pow_nonneg hu 62) - have h1 : (0:ℝ) ≤ 1410592329453155093339211289542411736609735429121847896493629858906716014852004156892167552548 * α ^ 1 * (17 - α) ^ 61 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 61) - have h2 : (0:ℝ) ≤ 163825348961034855748532998133187489244150138166953116803112907190951119777389438269950378047615 * α ^ 2 * (17 - α) ^ 60 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 60) - have h3 : (0:ℝ) ≤ 12361195960575736306163012120329422246578502920843748763821862084625502483053715706760463722075322 * α ^ 3 * (17 - α) ^ 59 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 59) - have h4 : (0:ℝ) ≤ 681335583687244816837155518706910028522515498128290805387946937709694218848663276792277722205885165 * α ^ 4 * (17 - α) ^ 58 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 58) - have h5 : (0:ℝ) ≤ 29246467299582416554371726277124312659485967608331036186864901441962932711378452493174003728374440456 * α ^ 5 * (17 - α) ^ 57 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 57) - have h6 : (0:ℝ) ≤ 1017843449098855324693227940286198056557561324301642345041220834540478580971172148752686938326750596235 * α ^ 6 * (17 - α) ^ 56 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 56) - have h7 : (0:ℝ) ≤ 29523351481445963795800452678069515843407715524336444192954336309944099949871809204575864476533589605302 * α ^ 7 * (17 - α) ^ 55 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 55) - have h8 : (0:ℝ) ≤ 728152422115299748757980286386613270210125867312784076185146979717429960990761502520944266554529234032105 * α ^ 8 * (17 - α) ^ 54 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 54) - have h9 : (0:ℝ) ≤ 15503254854319433781737681560944871435301212863859242862611647178701987248949779238980829394743551131411876 * α ^ 9 * (17 - α) ^ 53 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 53) - have h10 : (0:ℝ) ≤ 288328427720996697724483216206576565555295259358381796122313701494259650958770973285158322571941967268217143 * α ^ 10 * (17 - α) ^ 52 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 52) - have h11 : (0:ℝ) ≤ 4728226481516661217868239930012852768555767163427788258399165321871029858334868657036824174585537128584095058 * α ^ 11 * (17 - α) ^ 51 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 51) - have h12 : (0:ℝ) ≤ 68892078096367493868938707195995003059858819884647635693839050805569143627035213407543911684688112707333940917 * α ^ 12 * (17 - α) ^ 50 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 50) - have h13 : (0:ℝ) ≤ 897489256219895957725717014821990251236531986784876454449072801996710996644666496224561803033929426140365957072 * α ^ 13 * (17 - α) ^ 49 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 49) - have h14 : (0:ℝ) ≤ 10508734440253299052373528881880146721004546284790249412377062790386529187304727179044043353704708859442299500759 * α ^ 14 * (17 - α) ^ 48 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 48) - have h15 : (0:ℝ) ≤ 111081473282973163902827719026653126099023149223026091072328009130583311867466584644887598351195354843454575061078 * α ^ 15 * (17 - α) ^ 47 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 47) - have h16 : (0:ℝ) ≤ 1063941006387245192155551249879696393695003441753984944370011723535983307131499226741597118204956342316757068738269 * α ^ 16 * (17 - α) ^ 46 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 46) - have h17 : (0:ℝ) ≤ 9262986013458072655807408147636790265923148648024710835072780996730402742732552216518640508409071199773338460467580 * α ^ 17 * (17 - α) ^ 45 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 45) - have h18 : (0:ℝ) ≤ 73504432944628644806132381782654602892005780151536635377604343542798349874150577323370221243526662142861029485765267 * α ^ 18 * (17 - α) ^ 44 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 44) - have h19 : (0:ℝ) ≤ 532852613339223838375512331827090700606511743950503229897754718887488029896868379807709267119939501223065295366693602 * α ^ 19 * (17 - α) ^ 43 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 43) - have h20 : (0:ℝ) ≤ 3535814546782694307375152520118433313583952495849109269521484647041374707696487816679620238442969871612220462861303513 * α ^ 20 * (17 - α) ^ 42 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 42) - have h21 : (0:ℝ) ≤ 21512685649336335238232172882299955129752294290179941353113200512198826289055015641521741143998370572855870359074246104 * α ^ 21 * (17 - α) ^ 41 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 41) - have h22 : (0:ℝ) ≤ 120184751154982212109537129094706701776062091437923605319229141083097993817265572578568789467586467189277588039631049315 * α ^ 22 * (17 - α) ^ 40 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 40) - have h23 : (0:ℝ) ≤ 617286849338083584591749927075053814330691243681016327221117622061037920401281200900095661642210214781389352540371769782 * α ^ 23 * (17 - α) ^ 39 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 39) - have h24 : (0:ℝ) ≤ 2917821849269728689002023193436139836170048452644874266623784725971608066582467147212148057605900165316289226284189316377 * α ^ 24 * (17 - α) ^ 38 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 38) - have h25 : (0:ℝ) ≤ 12704073587524590432537550601733909995628450893588885496540802041053069795718152620703039939205080151846264466052385716508 * α ^ 25 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 37) - have h26 : (0:ℝ) ≤ 50986252288170844090494680336411030634809274601549641047867345938670169429122180568151839986046629584836753070752554325549 * α ^ 26 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 36) - have h27 : (0:ℝ) ≤ 188731245384436542993876553440655528970657000032064943068315442235001403174655449380246936385673578684853218729590355262518 * α ^ 27 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 35) - have h28 : (0:ℝ) ≤ 644638862330020323974120509999798597971327969663585928073571369717884850872334505415491868174223509023103931648896623159239 * α ^ 28 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 34) - have h29 : (0:ℝ) ≤ 2032465294997125297900965524691015077382636066034389731503867693576128697782554799572131661348538947203921438149968717062968 * α ^ 29 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 33) - have h30 : (0:ℝ) ≤ 5916563574791151204959096743639378777667289023700421621098488569051297390955699005328526305783519890090961210344520200855839 * α ^ 30 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 32) - have h31 : (0:ℝ) ≤ 15904395842739942400691632117874198526447327814312513603909114134462651263485542388901837738413027124647322988507344907172326 * α ^ 31 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 31) - have h32 : (0:ℝ) ≤ 39480621688975930462788359812689019736710921053310451812820878220682147479485730376139224433028788139612764026510819938357313 * α ^ 32 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 30) - have h33 : (0:ℝ) ≤ 90498905447243483519998876972476498394113495417286506436759680590889186513026023767081117347518009234654646481535950533463192 * α ^ 33 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 29) - have h34 : (0:ℝ) ≤ 191523061794373512741555851851454724489150681013895009425168301404571522764467282969120404401773322532157478133115443560285302 * α ^ 34 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 28) - have h35 : (0:ℝ) ≤ 374102432352617119867752270588761366904228295175272818014486180253881707053636572216880029501969121629062410575837741541045540 * α ^ 35 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 27) - have h36 : (0:ℝ) ≤ 674163867855629078514194069974085158409299328199490452497247676315473162081360642182363547674290072742445351524110985068872354 * α ^ 36 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 26) - have h37 : (0:ℝ) ≤ 1120190445035094331280254183489294295074052698129528674820873994885643430165035917680757332898500267079209483615084452103804008 * α ^ 37 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 25) - have h38 : (0:ℝ) ≤ 1714900723005197968608097741871663993547860800425642883240541486610428452579319183757683479188744534283136109042046984240571814 * α ^ 38 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 38)) (pow_nonneg hu 24) - have h39 : (0:ℝ) ≤ 2416521455885624032995813409015090294329753742015754392681809119734841244318096451186191210367408907919148396327456308763254204 * α ^ 39 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 39)) (pow_nonneg hu 23) - have h40 : (0:ℝ) ≤ 3130667990811173505654112986656672677984543765718045066563298172181269932987292074370043542684045671485290799340932412432127666 * α ^ 40 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 40)) (pow_nonneg hu 22) - have h41 : (0:ℝ) ≤ 3723632079113581550914531608562041601402119257773277980450525464260286884296416621721582409231033706311054972465336219853088080 * α ^ 41 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 41)) (pow_nonneg hu 21) - have h42 : (0:ℝ) ≤ 4059377708897210330188497275486334922259944254887440167982165880025056118561927845076658189142750307922329495731330184747118638 * α ^ 42 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 42)) (pow_nonneg hu 20) - have h43 : (0:ℝ) ≤ 4048339098511651153484403478604219407237868497167064020335159037949103178704020226621821552775015074419425081166608975426397828 * α ^ 43 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 43)) (pow_nonneg hu 19) - have h44 : (0:ℝ) ≤ 3685125185916007961192554820161330975941990328916335627053257624724395938552675772827896673200200979526558921356874703197634202 * α ^ 44 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 44)) (pow_nonneg hu 18) - have h45 : (0:ℝ) ≤ 3054048224733814016209061368888708478509554580679361743439116448337817549920283187451853860165586457447146488334169873043392888 * α ^ 45 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 45)) (pow_nonneg hu 17) - have h46 : (0:ℝ) ≤ 2297607116406960807358259781678168246891645615834759456321137666589029442664420364955901391909484370982081566881227744010874086 * α ^ 46 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 46)) (pow_nonneg hu 16) - have h47 : (0:ℝ) ≤ 1563834963456883771498309022248496753805125281048581681606795606079693488022698265201311315270316165083707358234478370753591340 * α ^ 47 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 47)) (pow_nonneg hu 15) - have h48 : (0:ℝ) ≤ 959258589419178016234935333453270943911310250588295913774272713867179363938066640752243714741723229316103934660921840058331018 * α ^ 48 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 48)) (pow_nonneg hu 14) - have h49 : (0:ℝ) ≤ 527900112010660650248359261223300285284919503338654858382838983941810697808740176247054336097235620277146518114081044914641704 * α ^ 49 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 49)) (pow_nonneg hu 13) - have h50 : (0:ℝ) ≤ 259264801192497118934660971527450137059592143267324741721675524446679377229923273369087143487942107768190580548411748863625788 * α ^ 50 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 50)) (pow_nonneg hu 12) - have h51 : (0:ℝ) ≤ 112925257755528735753324539726634534462874074768785640447769616735919582936276633211358842716251496812674695066733945373630376 * α ^ 51 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 51)) (pow_nonneg hu 11) - have h52 : (0:ℝ) ≤ 43294208295108225572313363454714123552240387039341439399675327329984812526400837615036809250708210257269984868804715221768900 * α ^ 52 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 52)) (pow_nonneg hu 10) - have h53 : (0:ℝ) ≤ 14477109131118555980678814863672526273272305897056735808931397755854119363286698878099100454732834934400199349504635868575272 * α ^ 53 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 53)) (pow_nonneg hu 9) - have h54 : (0:ℝ) ≤ 4174569243543245209284931467152030006445783333411091743019898951807503568926775515227295551582461714654886147011664393698640 * α ^ 54 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 54)) (pow_nonneg hu 8) - have h55 : (0:ℝ) ≤ 1023195555636300366841604521638282501064465993225005460684172679015270094224232028670477159664015610240056559067645353077104 * α ^ 55 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 55)) (pow_nonneg hu 7) - have h56 : (0:ℝ) ≤ 209198594431248589503412319008039641002648327066847874065351685585470814434000466355080564735310580499259736416826148144344 * α ^ 56 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 56)) (pow_nonneg hu 6) - have h57 : (0:ℝ) ≤ 34783976201620581654146479854021503178010426501131959915156711925834764330476282903763164286902924648174181467158619488528 * α ^ 57 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 57)) (pow_nonneg hu 5) - have h58 : (0:ℝ) ≤ 4537117170708547774244512797745793493972596799818372048598224751094284949822133549967909771513344000829119085557004800874 * α ^ 58 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 58)) (pow_nonneg hu 4) - have h59 : (0:ℝ) ≤ 439587616858133764615021615831943232239201592269473877183402700593166522993563786139416926646861354484165239718064288908 * α ^ 59 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 59)) (pow_nonneg hu 3) - have h60 : (0:ℝ) ≤ 28864689907498275516712488927232990145839965615854349188000067895024636971944883064300818736721726097224141170690557182 * α ^ 60 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 60)) (pow_nonneg hu 2) - have h61 : (0:ℝ) ≤ 1070072225555048253521045141065543739116562978962155304409124790881546160712961916037048669936728578132382704101086352 * α ^ 61 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 61)) (pow_nonneg hu 1) - have h62 : (0:ℝ) ≤ 13265174660695058386402183278677678416743473633987916452549678002795064626597224750728225831441096471610791877259904 * α ^ 62 := - mul_nonneg (by norm_num) (pow_nonneg hα 62) have hid : (17 : ℝ) ^ 62 * (5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 + 61381176382803809362111499051840544591370805103230496041366966719316985769735186577074210428 * α + 307875927191106748261011216414410411442655519490352054541897661765849218694794523337461209647 * α ^ 2 + 995139520442941110972922094595461359252165093278183682740950849972307343163433414772266439134 * α ^ 3 + 2329135965026413320254515390788191269701711986947806984107173389521959680472053301869564187977 * α ^ 4 + 4205152400427897818943955614854872603184778207497298031576474014041708453522600564012661712908 * α ^ 5 + 6092227728539116602774802993811227514150357030998079498007336022099744281828374410394763218967 * α ^ 6 + 7273914911154976681674028920562209810638892503140251984517953529760649706898772999266377410618 * α ^ 7 + 7294841936549908246762850463172756077551550164308271524011607481986853316219925718877268241253 * α ^ 8 + 6231636865479569934304365225476315224178754021865462499626075023963516933948459908031199504392 * α ^ 9 + 4582454355475931479184872096047779444629884546826401854025935798959693699768306789254756052107 * α ^ 10 + 2923936751602144899711097457334391073444202579871680510494335159924208835914470439635141162662 * α ^ 11 + 1628646305582237968027987059869036927850582412822128278929774316093217652148166106137543210729 * α ^ 12 + 795445013477937519140644933077682364729772242866058887702125127747950219835128702530435684436 * α ^ 13 + 341732386485246488082914550033328759932103344872452353652503157863279852435899383534716977739 * α ^ 14 + 129398024588904114703104106088147845845858920384624466782691337832071760366611282163240673066 * α ^ 15 + 43227083179690319937679095035602516318669269367605716008461368393810348604333859857847549497 * α ^ 16 + 12739734973954297734917244488839138405165723257781387930800239709000470619130237106664340656 * α ^ 17 + 3309003690560409027996242316235318569343087760556101911245828294749346009825368969657069031 * α ^ 18 + 755904091146328721648601114370911122594719522671458365690647375941659996310302273197058470 * α ^ 19 + 151378877572074703874732245694134372432105936678872727794384094115460812902730719423948317 * α ^ 20 + 26454923472459858634887234579799069438230123457614797089205636430511024677434784809220924 * α ^ 21 + 4009557348845189672922466111254379827931543987777056770742617262249980072703900044793759 * α ^ 22 + 522684797686516768766815870526767734538930901093141236380109988654434790535464480525226 * α ^ 23 + 57960196328928756537267261570029521956658673559059668642752896597993471772708261591453 * α ^ 24 + 5385398873189231308982589874195610465961820936268053590519181757629535422805253399024 * α ^ 25 + 410397478215636804806491132412571076795910317178146076050633000481647199256305822637 * α ^ 26 + 24812014519928905914570908638577043729393183935810050156873373621420956394826529722 * α ^ 27 + 1113510388782381458493062026644349844210314014993864209186922164992790354371374639 * α ^ 28 + 22409773065959463084902151065290205378008886892907135598840606673031087144995204 * α ^ 29 - 35763698158235183891226289780431937498580930947719484832564827737501564744289629 * α ^ 30 + 840760995622979288098811692316543958334461895228266842721825922823541893315826 * α ^ 31 - 2476024715094217195652794819915917218077074423531979390443969076889551332351 * α ^ 32 - 42343131706354479044867362267674031525737275327352243122650061208773859828 * α ^ 33 + 1121663574053726688315155444107301037632747178037371530068223719748652900 * α ^ 34 + 127119237016866360421264159870103175079883989461074891879168221493189568 * α ^ 35 + 5840998162333194724309799734276135965778520891167491660434664446065776 * α ^ 36 + 175992443424517154194105688439948495022759467456834921814514733630912 * α ^ 37 + 3457340410083421419722141826010375932802380080806011689658236008128 * α ^ 38 + 24387290416155856471527726331603437910487483092148051628143522304 * α ^ 39 - 1239885867289330313685948822187720768399781886302021720494414080 * α ^ 40 - 65142911505809786191440265839050522466645141325685819456216064 * α ^ 41 - 1919845972367683574507152058644769097612240398422850416591872 * α ^ 42 - 42690755951658679674359660598349223111852496540029559373824 * α ^ 43 - 774277941425789906408100254236527798872560249769923817472 * α ^ 44 - 11837447748695307877084872298248109006399402655405555712 * α ^ 45 - 155160542836944884945355229969272241433459624584396800 * α ^ 46 - 1760282021481048069096957321992926156742736627499008 * α ^ 47 - 17375591117616735181132725973057892264379050557440 * α ^ 48 - 149596040045196039764745879558857285877770747904 * α ^ 49 - 1123758519054636222507004226738421820190097408 * α ^ 50 - 7354587732063594511120345756955829080162304 * α ^ 51 - 41799839163275444256118641007392250134528 * α ^ 52 - 205261854328197847356177208926730715136 * α ^ 53 - 864576623781254196788511741560487936 * α ^ 54 - 3092645524632136056284929849294848 * α ^ 55 - 9268224902397535157105681498112 * α ^ 56 - 22840148173664707695687499776 * α ^ 57 - 45078822391172061959553024 * α ^ 58 - 68515609003558969540608 * α ^ 59 - 75294374818201206784 * α ^ 60 - 53251155240681472 * α ^ 61 - 18200997658624 * α ^ 62) = 5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 * (17 - α) ^ 62 + 1410592329453155093339211289542411736609735429121847896493629858906716014852004156892167552548 * α ^ 1 * (17 - α) ^ 61 + 163825348961034855748532998133187489244150138166953116803112907190951119777389438269950378047615 * α ^ 2 * (17 - α) ^ 60 + 12361195960575736306163012120329422246578502920843748763821862084625502483053715706760463722075322 * α ^ 3 * (17 - α) ^ 59 + 681335583687244816837155518706910028522515498128290805387946937709694218848663276792277722205885165 * α ^ 4 * (17 - α) ^ 58 + 29246467299582416554371726277124312659485967608331036186864901441962932711378452493174003728374440456 * α ^ 5 * (17 - α) ^ 57 + 1017843449098855324693227940286198056557561324301642345041220834540478580971172148752686938326750596235 * α ^ 6 * (17 - α) ^ 56 + 29523351481445963795800452678069515843407715524336444192954336309944099949871809204575864476533589605302 * α ^ 7 * (17 - α) ^ 55 + 728152422115299748757980286386613270210125867312784076185146979717429960990761502520944266554529234032105 * α ^ 8 * (17 - α) ^ 54 + 15503254854319433781737681560944871435301212863859242862611647178701987248949779238980829394743551131411876 * α ^ 9 * (17 - α) ^ 53 + 288328427720996697724483216206576565555295259358381796122313701494259650958770973285158322571941967268217143 * α ^ 10 * (17 - α) ^ 52 + 4728226481516661217868239930012852768555767163427788258399165321871029858334868657036824174585537128584095058 * α ^ 11 * (17 - α) ^ 51 + 68892078096367493868938707195995003059858819884647635693839050805569143627035213407543911684688112707333940917 * α ^ 12 * (17 - α) ^ 50 + 897489256219895957725717014821990251236531986784876454449072801996710996644666496224561803033929426140365957072 * α ^ 13 * (17 - α) ^ 49 + 10508734440253299052373528881880146721004546284790249412377062790386529187304727179044043353704708859442299500759 * α ^ 14 * (17 - α) ^ 48 + 111081473282973163902827719026653126099023149223026091072328009130583311867466584644887598351195354843454575061078 * α ^ 15 * (17 - α) ^ 47 + 1063941006387245192155551249879696393695003441753984944370011723535983307131499226741597118204956342316757068738269 * α ^ 16 * (17 - α) ^ 46 + 9262986013458072655807408147636790265923148648024710835072780996730402742732552216518640508409071199773338460467580 * α ^ 17 * (17 - α) ^ 45 + 73504432944628644806132381782654602892005780151536635377604343542798349874150577323370221243526662142861029485765267 * α ^ 18 * (17 - α) ^ 44 + 532852613339223838375512331827090700606511743950503229897754718887488029896868379807709267119939501223065295366693602 * α ^ 19 * (17 - α) ^ 43 + 3535814546782694307375152520118433313583952495849109269521484647041374707696487816679620238442969871612220462861303513 * α ^ 20 * (17 - α) ^ 42 + 21512685649336335238232172882299955129752294290179941353113200512198826289055015641521741143998370572855870359074246104 * α ^ 21 * (17 - α) ^ 41 + 120184751154982212109537129094706701776062091437923605319229141083097993817265572578568789467586467189277588039631049315 * α ^ 22 * (17 - α) ^ 40 + 617286849338083584591749927075053814330691243681016327221117622061037920401281200900095661642210214781389352540371769782 * α ^ 23 * (17 - α) ^ 39 + 2917821849269728689002023193436139836170048452644874266623784725971608066582467147212148057605900165316289226284189316377 * α ^ 24 * (17 - α) ^ 38 + 12704073587524590432537550601733909995628450893588885496540802041053069795718152620703039939205080151846264466052385716508 * α ^ 25 * (17 - α) ^ 37 + 50986252288170844090494680336411030634809274601549641047867345938670169429122180568151839986046629584836753070752554325549 * α ^ 26 * (17 - α) ^ 36 + 188731245384436542993876553440655528970657000032064943068315442235001403174655449380246936385673578684853218729590355262518 * α ^ 27 * (17 - α) ^ 35 + 644638862330020323974120509999798597971327969663585928073571369717884850872334505415491868174223509023103931648896623159239 * α ^ 28 * (17 - α) ^ 34 + 2032465294997125297900965524691015077382636066034389731503867693576128697782554799572131661348538947203921438149968717062968 * α ^ 29 * (17 - α) ^ 33 + 5916563574791151204959096743639378777667289023700421621098488569051297390955699005328526305783519890090961210344520200855839 * α ^ 30 * (17 - α) ^ 32 + 15904395842739942400691632117874198526447327814312513603909114134462651263485542388901837738413027124647322988507344907172326 * α ^ 31 * (17 - α) ^ 31 + 39480621688975930462788359812689019736710921053310451812820878220682147479485730376139224433028788139612764026510819938357313 * α ^ 32 * (17 - α) ^ 30 + 90498905447243483519998876972476498394113495417286506436759680590889186513026023767081117347518009234654646481535950533463192 * α ^ 33 * (17 - α) ^ 29 + 191523061794373512741555851851454724489150681013895009425168301404571522764467282969120404401773322532157478133115443560285302 * α ^ 34 * (17 - α) ^ 28 + 374102432352617119867752270588761366904228295175272818014486180253881707053636572216880029501969121629062410575837741541045540 * α ^ 35 * (17 - α) ^ 27 + 674163867855629078514194069974085158409299328199490452497247676315473162081360642182363547674290072742445351524110985068872354 * α ^ 36 * (17 - α) ^ 26 + 1120190445035094331280254183489294295074052698129528674820873994885643430165035917680757332898500267079209483615084452103804008 * α ^ 37 * (17 - α) ^ 25 + 1714900723005197968608097741871663993547860800425642883240541486610428452579319183757683479188744534283136109042046984240571814 * α ^ 38 * (17 - α) ^ 24 + 2416521455885624032995813409015090294329753742015754392681809119734841244318096451186191210367408907919148396327456308763254204 * α ^ 39 * (17 - α) ^ 23 + 3130667990811173505654112986656672677984543765718045066563298172181269932987292074370043542684045671485290799340932412432127666 * α ^ 40 * (17 - α) ^ 22 + 3723632079113581550914531608562041601402119257773277980450525464260286884296416621721582409231033706311054972465336219853088080 * α ^ 41 * (17 - α) ^ 21 + 4059377708897210330188497275486334922259944254887440167982165880025056118561927845076658189142750307922329495731330184747118638 * α ^ 42 * (17 - α) ^ 20 + 4048339098511651153484403478604219407237868497167064020335159037949103178704020226621821552775015074419425081166608975426397828 * α ^ 43 * (17 - α) ^ 19 + 3685125185916007961192554820161330975941990328916335627053257624724395938552675772827896673200200979526558921356874703197634202 * α ^ 44 * (17 - α) ^ 18 + 3054048224733814016209061368888708478509554580679361743439116448337817549920283187451853860165586457447146488334169873043392888 * α ^ 45 * (17 - α) ^ 17 + 2297607116406960807358259781678168246891645615834759456321137666589029442664420364955901391909484370982081566881227744010874086 * α ^ 46 * (17 - α) ^ 16 + 1563834963456883771498309022248496753805125281048581681606795606079693488022698265201311315270316165083707358234478370753591340 * α ^ 47 * (17 - α) ^ 15 + 959258589419178016234935333453270943911310250588295913774272713867179363938066640752243714741723229316103934660921840058331018 * α ^ 48 * (17 - α) ^ 14 + 527900112010660650248359261223300285284919503338654858382838983941810697808740176247054336097235620277146518114081044914641704 * α ^ 49 * (17 - α) ^ 13 + 259264801192497118934660971527450137059592143267324741721675524446679377229923273369087143487942107768190580548411748863625788 * α ^ 50 * (17 - α) ^ 12 + 112925257755528735753324539726634534462874074768785640447769616735919582936276633211358842716251496812674695066733945373630376 * α ^ 51 * (17 - α) ^ 11 + 43294208295108225572313363454714123552240387039341439399675327329984812526400837615036809250708210257269984868804715221768900 * α ^ 52 * (17 - α) ^ 10 + 14477109131118555980678814863672526273272305897056735808931397755854119363286698878099100454732834934400199349504635868575272 * α ^ 53 * (17 - α) ^ 9 + 4174569243543245209284931467152030006445783333411091743019898951807503568926775515227295551582461714654886147011664393698640 * α ^ 54 * (17 - α) ^ 8 + 1023195555636300366841604521638282501064465993225005460684172679015270094224232028670477159664015610240056559067645353077104 * α ^ 55 * (17 - α) ^ 7 + 209198594431248589503412319008039641002648327066847874065351685585470814434000466355080564735310580499259736416826148144344 * α ^ 56 * (17 - α) ^ 6 + 34783976201620581654146479854021503178010426501131959915156711925834764330476282903763164286902924648174181467158619488528 * α ^ 57 * (17 - α) ^ 5 + 4537117170708547774244512797745793493972596799818372048598224751094284949822133549967909771513344000829119085557004800874 * α ^ 58 * (17 - α) ^ 4 + 439587616858133764615021615831943232239201592269473877183402700593166522993563786139416926646861354484165239718064288908 * α ^ 59 * (17 - α) ^ 3 + 28864689907498275516712488927232990145839965615854349188000067895024636971944883064300818736721726097224141170690557182 * α ^ 60 * (17 - α) ^ 2 + 1070072225555048253521045141065543739116562978962155304409124790881546160712961916037048669936728578132382704101086352 * α ^ 61 * (17 - α) ^ 1 + 13265174660695058386402183278677678416743473633987916452549678002795064626597224750728225831441096471610791877259904 * α ^ 62 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 * (17 - α) ^ 62 := - mul_pos (by norm_num) (pow_pos (by linarith) 62) - linarith - · have hpos : (0 : ℝ) < 13265174660695058386402183278677678416743473633987916452549678002795064626597224750728225831441096471610791877259904 * α ^ 62 := - mul_pos (by norm_num) (pow_pos (by linarith) 62) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 62)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree6_6.lean b/Sendov/FiniteRange/Degree6_6.lean index 3e07d6e..1194600 100644 --- a/Sendov/FiniteRange/Degree6_6.lean +++ b/Sendov/FiniteRange/Degree6_6.lean @@ -88,25 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 5 / 2) : 0 < 1575 - 900 * α + 2345 * α ^ 2 - 342 * α ^ 3 - 24 * α ^ 4 := by have hu : (0 : ℝ) ≤ 5 - 2 * α := by linarith - have h0 : (0:ℝ) ≤ 1575 * (5 - 2 * α) ^ 4 := - mul_nonneg (by norm_num) (pow_nonneg hu 4) - have h1 : (0:ℝ) ≤ 8100 * α ^ 1 * (5 - 2 * α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 3) - have h2 : (0:ℝ) ≤ 69425 * α ^ 2 * (5 - 2 * α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 2) - have h3 : (0:ℝ) ≤ 188150 * α ^ 3 * (5 - 2 * α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 1) - have h4 : (0:ℝ) ≤ 123200 * α ^ 4 := - mul_nonneg (by norm_num) (pow_nonneg hα 4) have hid : (5 : ℝ) ^ 4 * (1575 - 900 * α + 2345 * α ^ 2 - 342 * α ^ 3 - 24 * α ^ 4) = 1575 * (5 - 2 * α) ^ 4 + 8100 * α ^ 1 * (5 - 2 * α) ^ 3 + 69425 * α ^ 2 * (5 - 2 * α) ^ 2 + 188150 * α ^ 3 * (5 - 2 * α) ^ 1 + 123200 * α ^ 4 := by ring - rcases le_total α (5 / (2 * 2)) with h | h - · have hpos : (0 : ℝ) < 1575 * (5 - 2 * α) ^ 4 := - mul_pos (by norm_num) (pow_pos (by linarith) 4) - linarith - · have hpos : (0 : ℝ) < 123200 * α ^ 4 := - mul_pos (by norm_num) (pow_pos (by linarith) 4) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (5 : ℝ) ^ 4)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 5 - 2 * α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/FiniteRange/Degree70_79.lean b/Sendov/FiniteRange/Degree70_79.lean index 69ed97c..c57f23e 100644 --- a/Sendov/FiniteRange/Degree70_79.lean +++ b/Sendov/FiniteRange/Degree70_79.lean @@ -88,153 +88,16 @@ set_option maxHeartbeats 2000000 in lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 + 55048255682073709607204036059519252499577954075805344228144067353398773939360654388786551620754044174 * α + 303631470940991973002262259034385880105972184753330155102383400602879297569999672180560254047614733064 * α ^ 2 + 1082629940665673044764709543433093878486364849040990099597525143450118708087349123259727336344728664544 * α ^ 3 + 2804599610843097204574458002687246299093134788634086599591559738125527989079685417982892820063924460373 * α ^ 4 + 5624645401139815516982667151087561797773568501921017826805664176655117168979590819326893993434748481137 * α ^ 5 + 9086529173583154645809008602511982564716590500042635425568606924621639922909196505882243392404835758015 * α ^ 6 + 12147764349688852841301807848655896145357577978996235836231868297037709466427619171816150975300099741791 * α ^ 7 + 13702180594674637952993181456614636961007303430300258709825461099491823680923881039132440258291527607905 * α ^ 8 + 13228790758953813166525229226864556895698491358332563699351209388421354345605839944544173983846341165317 * α ^ 9 + 11051940590803482762640027098441612629424377433949792947689615004158487742382763237735051674050718363307 * α ^ 10 + 8057730499045200268719730173861520782106924341107579339386385608691893710110000816392557161453112592131 * α ^ 11 + 5160484214825899033659577721795935067593212006301594642310233538545527417677809202356341306165128799909 * α ^ 12 + 2917926196608374844731210581375035036343917943893823360466936440450011366221495240241631678212028102353 * α ^ 13 + 1462315101539635752571716649246230545438507378471968670138935884045737693317302923326515165319274353863 * α ^ 14 + 651362758608261532683053553948901251603409142895470962454343186012266250060431761761109117155529185351 * α ^ 15 + 258382911131744978730219354901244362207736065992848531597126642760778004801626888171716412430540285505 * α ^ 16 + 91380564667115290929103952618176877475251392601510902630099986346625474504164568221576682912080867653 * α ^ 17 + 28823701484229764785510610641119924329640879766929838579606063832811514346965585992079347095184066891 * α ^ 18 + 8105512742405337827384222403832648005310429131045055117867656987105207137736030417145103472632533011 * α ^ 19 + 2029737755516453702412381601616827618446965035012177295868811221050918334739516968406653005043323145 * α ^ 20 + 451715825606281157427809648282481163078916909506829474305720867391455366362160566615805697668034469 * α ^ 21 + 89083872539236033065296789508746088826183108150642030163709620396857932007741467883529598127701027 * α ^ 22 + 15507062046600275350060333043623953591886937497826357117111310333499555606548238470938828041232307 * α ^ 23 + 2370291817598182097124474831710334939044419386117776585894929734754031639676722325611554692802929 * α ^ 24 + 315999149372391878452912834168990330419105934995500914232394089420371940254905369886539160346853 * α ^ 25 + 36423009146013699028116153780709317964569427476167451734283550363318237494233399180783337169695 * α ^ 26 + 3588163263018483116273779737008794180190405472634090416966530935626554841121047871569879767559 * α ^ 27 + 297471336921909919923207632811348664497121895483393172379791904969696166207311294171026521523 * α ^ 28 + 20305725467845794109711961738383951154160346509672805134214469944833591189715035234346686183 * α ^ 29 + 1103609488904163566431208273520751297004151033048526881874218221163688540301268998957942157 * α ^ 30 + 44705334211106925450419755417917993038028222392715074881553657780646344635657758883181805 * α ^ 31 + 805515192221430510609334948188870016650885857492958289044650012247928862875245764497551 * α ^ 32 - 1482048260833901649795245609960707851397885375498496335550472054736679501095164961700205 * α ^ 33 + 28550595118000674813695237772389123615483889198973830073821326304976753853122397016687 * α ^ 34 - 110293125322577848844861697626305509333317224753061067523753150512274273997930489889 * α ^ 35 - 2944264371932464496615000679541333014546134952187144901035323438838119921163626816 * α ^ 36 - 42753460721496719482279714802299033215763752656049106329252818812714655687701920 * α ^ 37 + 892039301043622007789612879017665871347081871863607139597567473234375585298160 * α ^ 38 + 90290182213750286064408757160215991459134539105309106871418780497371434069600 * α ^ 39 + 3686520145576645994835054065141215370192750469525569878892121423026501980224 * α ^ 40 + 101266458446089775184406440743070690042012917626596066692722657223969408256 * α ^ 41 + 1921165999972257449345542825175329806471062302564814176599267497713370880 * α ^ 42 + 18910079844664677393253742829163990204177395135122636437886747825783808 * α ^ 43 - 267203790007683385371238236401248869931744610843957702759988424811520 * α ^ 44 - 18630321688593096100250955298980358254132585106002718798371125157888 * α ^ 45 - 549431692437424587483251682306834452811394511706522157550126837760 * α ^ 46 - 11827470008686810839474011121751705014739559837533303829463834624 * α ^ 47 - 206601161707202641093681870196336457333557666704999087205793792 * α ^ 48 - 3050100062225303864539589793145445854252294435418792706244608 * α ^ 49 - 38831214153718995312467487136862135070778219830730009018368 * α ^ 50 - 431130925861351878296650698743841679980168113965805076480 * α ^ 51 - 4201734530680545401568837521217272752627836979325435904 * α ^ 52 - 36075335848543051909606823878062380154340083870203904 * α ^ 53 - 273302433216495374400156548854470569604061187801088 * α ^ 54 - 1826924843542958932998763336695299600883344474112 * α ^ 55 - 10760219439515367849051421269035765266542231552 * α ^ 56 - 55683568301576061216924181665153394893914112 * α ^ 57 - 252108560765968990302771636780305076977664 * α ^ 58 - 992726472130728702576289249214808981504 * α ^ 59 - 3372896548691756253399508431270838272 * α ^ 60 - 9784355714995137510417248525746176 * α ^ 61 - 23895590924284630456363042996224 * α ^ 62 - 48203390780462373975323836416 * α ^ 63 - 78197438735478405231280128 * α ^ 64 - 98061705121359087009792 * α ^ 65 - 89226089066196369408 * α ^ 66 - 52420526819246080 * α ^ 67 - 14929306320896 * α ^ 68 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 * (17 - α) ^ 68 := - mul_nonneg (by norm_num) (pow_nonneg hu 68) - have h1 : (0:ℝ) ≤ 1265157032653140923172696358781045157064900401217905487833243537047108668589294636491165982694547047750 * α ^ 1 * (17 - α) ^ 67 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 67) - have h2 : (0:ℝ) ≤ 161482237306767878745241819415998746410809769680683392204930507623070859153937168257049914988047412112214 * α ^ 2 * (17 - α) ^ 66 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 66) - have h3 : (0:ℝ) ≤ 13422247499165700437689764267709730212036079924252530397947436539414938500806129414515249428924591360471250 * α ^ 3 * (17 - α) ^ 65 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 65) - have h4 : (0:ℝ) ≤ 816972781682827686607611010623394023676328688115620152082292022403046953548356768129403300216449427112754113 * α ^ 4 * (17 - α) ^ 64 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 64) - have h5 : (0:ℝ) ≤ 38824370988158138726941311700115756071290366487538089829867353036362853363011105712229404919753034517698319713 * α ^ 5 * (17 - α) ^ 63 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 63) - have h6 : (0:ℝ) ≤ 1499833600292598822014341704041896176361474668441008024749667474678088913996818119654158697311930608272571456030 * α ^ 6 * (17 - α) ^ 62 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 62) - have h7 : (0:ℝ) ≤ 48422932809787295787390564041245327912518154539781119501099341947995210984379450371937423256131589899210941134514 * α ^ 7 * (17 - α) ^ 61 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 61) - have h8 : (0:ℝ) ≤ 1333124974240927854482159425251402107245186286978279403787625094573367841803246952758768754029487309692347318336240 * α ^ 8 * (17 - α) ^ 60 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 60) - have h9 : (0:ℝ) ≤ 31777797124891464951721548329322036172531399956667440482696617718123564246691425958497694319690617969140927686684080 * α ^ 9 * (17 - α) ^ 59 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 59) - have h10 : (0:ℝ) ≤ 663714337585641075862710458977346289450664855026176138573830637339763833070986663739178423777505821459460189852947968 * α ^ 10 * (17 - α) ^ 58 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 58) - have h11 : (0:ℝ) ≤ 12262485846674184769453169937509946039571704829287751556559418951991378092254593946982159731229796032255503955934621616 * α ^ 11 * (17 - α) ^ 57 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 57) - have h12 : (0:ℝ) ≤ 201969028018565162730161510400745329670143714141289296191558060115320430534002168054679415522116383859539020895554723776 * α ^ 12 * (17 - α) ^ 56 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 56) - have h13 : (0:ℝ) ≤ 2984596421743417793782332651870684512173959536289036391110144204303743763821125710106900081031600434022380226544823660080 * α ^ 13 * (17 - α) ^ 55 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 55) - have h14 : (0:ℝ) ≤ 39784321437763110285727312524497427978490644060968737608182005051306614478428882059166898040103949867844194968529236966504 * α ^ 14 * (17 - α) ^ 54 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 54) - have h15 : (0:ℝ) ≤ 480543938548422612890741989991526270246304382173993722693724388642176377466756024411416886199383755538111290823987013369160 * α ^ 15 * (17 - α) ^ 53 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 53) - have h16 : (0:ℝ) ≤ 5279901417754954883742431587978703767626877114504290728644469223047973916917301789839124306590322937367972095259516102221832 * α ^ 16 * (17 - α) ^ 52 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 52) - have h17 : (0:ℝ) ≤ 52945203354166745644230222209580146500462821416245712770967147511123795041025063164899837137984308325228112243872402797720184 * α ^ 17 * (17 - α) ^ 51 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 51) - have h18 : (0:ℝ) ≤ 485928342569266463087021622036455747024462941842401506731286158733175889455343816199003845608430478859161164238309759380850320 * α ^ 18 * (17 - α) ^ 50 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 50) - have h19 : (0:ℝ) ≤ 4091958406668774678507241930361086964473233452855436917980174792821511603462125609865012423204529448494332739565952940847535008 * α ^ 19 * (17 - α) ^ 49 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 49) - have h20 : (0:ℝ) ≤ 31683212460188578387342804176945072229413086255880741845271045566233563281959233289534062862735569422810201289901710942585691872 * α ^ 20 * (17 - α) ^ 48 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 48) - have h21 : (0:ℝ) ≤ 225979630689303507786898260664009071625270094449716362704636848456295027690433997904251442068696550669529118551488817387880290256 * α ^ 21 * (17 - α) ^ 47 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 47) - have h22 : (0:ℝ) ≤ 1487128617430673014516169749515363875219566281808091046150030684893815735850131065805579647668091571852789526355428971538991078216 * α ^ 22 * (17 - α) ^ 46 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 46) - have h23 : (0:ℝ) ≤ 9042148580683115945632798662691502266143017079630193956758831416930496458610190341296994016055070448189744269126207258222640342120 * α ^ 23 * (17 - α) ^ 45 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 45) - have h24 : (0:ℝ) ≤ 50858358010848454557731664420671103160817707432587833055365526944577128658034548080461931999630601918157623952028511496302491645436 * α ^ 24 * (17 - α) ^ 44 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 44) - have h25 : (0:ℝ) ≤ 264894421723415244260430513144029948945395618262574763973851002784217525442701126127347374644597622077075226262022822088501696204428 * α ^ 25 * (17 - α) ^ 43 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 43) - have h26 : (0:ℝ) ≤ 1278767873696353424101636053219073837545595922525849403166724782352583013823834674590289275813557084219485073578825413587799211967436 * α ^ 26 * (17 - α) ^ 42 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 42) - have h27 : (0:ℝ) ≤ 5725993526407220170131735130796235929803474480006433589234997891028171711914835354674252789493105774845667439300549950141552174204148 * α ^ 27 * (17 - α) ^ 41 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 41) - have h28 : (0:ℝ) ≤ 23797472948050627920664370923139924765880312522674540655463364156321698714682589900985886207317662923270995738996512039485735022862410 * α ^ 28 * (17 - α) ^ 40 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 40) - have h29 : (0:ℝ) ≤ 91847188399449607906860584187806753120315922783214799014025827204769651430206806052585878934846199020273478297324347000279002931574522 * α ^ 29 * (17 - α) ^ 39 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 39) - have h30 : (0:ℝ) ≤ 329342373949609101951511940154131075827972185993638085640480145831458749736060460017623365544223280262966286218021296303864864015746416 * α ^ 30 * (17 - α) ^ 38 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 38) - have h31 : (0:ℝ) ≤ 1097560558892751992700895204428590904051076121281041797677676037125864755311439126982165925162500305191774580034834400855567800165723472 * α ^ 31 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 37) - have h32 : (0:ℝ) ≤ 3400354684972857879605435169696913406951341446392821917656396040731072702340906869893233782691459204642830241785914469379158439677051796 * α ^ 32 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 36) - have h33 : (0:ℝ) ≤ 9795255185712404229440153808939878082728601957977592077724575912171144463816508150030377679174644938546737146393361620285646830422256420 * α ^ 33 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 35) - have h34 : (0:ℝ) ≤ 26239203554755141459745089973391959355052889674186027464718372088695695988893799042814172271546870765144481886268457658334065389516464974 * α ^ 34 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 34) - have h35 : (0:ℝ) ≤ 65364772208973664575034750355459656935183422873874505526092428372633233840636570937545030505946122798332726471550017157961822599578476434 * α ^ 35 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 33) - have h36 : (0:ℝ) ≤ 151417890873929453489601556690033520410995454719040770050368045093177324038829603093684868348571248298437596387498225961228162231792553093 * α ^ 36 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 32) - have h37 : (0:ℝ) ≤ 326136561459197293128988773328742282995557141736905381102626192805005586172364773727221188473432861214419687642701273642338530960261384661 * α ^ 37 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 31) - have h38 : (0:ℝ) ≤ 653015723122962185079373689805649153519043802243690625985998409467892401539972839267641852663543640591936858448032520844893189758926012070 * α ^ 38 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 38)) (pow_nonneg hu 30) - have h39 : (0:ℝ) ≤ 1215133738838743206101520047205100561581201889449447221306287657871682157019672294661855343053509410150028759117930302323754459334908148634 * α ^ 39 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 39)) (pow_nonneg hu 29) - have h40 : (0:ℝ) ≤ 2100547367169647162309522500534430225020946624321317667617084318982110113730770172930764538999209173828708805485472118278853696220026559040 * α ^ 40 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 40)) (pow_nonneg hu 28) - have h41 : (0:ℝ) ≤ 3371572226105498605533309421720928970740445870449689033321124541953074173720243492689723243231990142125903392944525071646763046153799712752 * α ^ 41 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 41)) (pow_nonneg hu 27) - have h42 : (0:ℝ) ≤ 5021731712866329267615629279744145209979569686428333572284923100300160062927127615408116117696235006051137970230291268323176361338022571184 * α ^ 42 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 42)) (pow_nonneg hu 26) - have h43 : (0:ℝ) ≤ 6935282526605279700851082376753425399984816075966925438156290984812989264949621990948332423313032156685195715186548440728089466656780320080 * α ^ 43 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 43)) (pow_nonneg hu 25) - have h44 : (0:ℝ) ≤ 8872887599583942844730285240702268137994535894273818319558203225690794212214876544716058828209821312295910996151845255442057724010075373248 * α ^ 44 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 44)) (pow_nonneg hu 24) - have h45 : (0:ℝ) ≤ 10504640550563806719417324418003161655867163727170635219980235187136023481938024960895708709168710341339951422197356602510535614885945508256 * α ^ 45 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 45)) (pow_nonneg hu 23) - have h46 : (0:ℝ) ≤ 11493574135707887540289576369636114410520335535521279072065981221823553796516692389915466887949431055195475567153283570135491233527632506928 * α ^ 46 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 46)) (pow_nonneg hu 22) - have h47 : (0:ℝ) ≤ 11604808627242697256579914136813566676833914505736299110704677968571962615410435000953138171276194970496716595805082770429385722453886399056 * α ^ 47 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 47)) (pow_nonneg hu 21) - have h48 : (0:ℝ) ≤ 10793967840695396334802012163192802178890797549077696640851371801953999538826236827198386902657587341524929692133771331237779053672003790160 * α ^ 48 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 48)) (pow_nonneg hu 20) - have h49 : (0:ℝ) ≤ 9230499922489526427651509591753374367209146684551244899464268618430259566127381498045470358588046512126019036255090586145820433029559234480 * α ^ 49 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 49)) (pow_nonneg hu 19) - have h50 : (0:ℝ) ≤ 7240815654095776003678341965368139318124068790043794347929887962009532007602522612129159417690713015083966661427793715858516996767469271084 * α ^ 50 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 50)) (pow_nonneg hu 18) - have h51 : (0:ℝ) ≤ 5196910721982371088216812572801559409316958643069477659778573971072818964949630354690214200347540577616724298122257242598606667131480040052 * α ^ 51 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 51)) (pow_nonneg hu 17) - have h52 : (0:ℝ) ≤ 3402631899636205416266590253352818738890126853621420549170291181525659701590036840082549061908694049445145596493472438472698439652700425890 * α ^ 52 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 52)) (pow_nonneg hu 16) - have h53 : (0:ℝ) ≤ 2025465883034696535913461632694517262359063545972119023350389907385898500473981148635068061077366719947869607252392209033800465429303336450 * α ^ 53 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 53)) (pow_nonneg hu 15) - have h54 : (0:ℝ) ≤ 1091892060376371705496056687719844206882169207141786444740932042075723042341165731755946837934817210431949903331903986496675369334494701764 * α ^ 54 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 54)) (pow_nonneg hu 14) - have h55 : (0:ℝ) ≤ 530656327268367909969479070273109187787062122866155559515976559252491925394512132156718870616555877823790538113874300155722493907068691260 * α ^ 55 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 55)) (pow_nonneg hu 13) - have h56 : (0:ℝ) ≤ 231274284789425659234396174824508586685686100786488695662129653371227054848548241907361605558199603413655338792402925999207216602489857076 * α ^ 56 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 56)) (pow_nonneg hu 12) - have h57 : (0:ℝ) ≤ 89827076778691705270449318543458115575152231899967166072570553309114042367109650873526097636925926390123634607634695515051611658499946996 * α ^ 57 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 57)) (pow_nonneg hu 11) - have h58 : (0:ℝ) ≤ 30860904487494092370763766510390952712726910195346707673456930961614703228983522639588565939176152364301734964159970624603354686308829140 * α ^ 58 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 58)) (pow_nonneg hu 10) - have h59 : (0:ℝ) ≤ 9293886338970220832863344149731277643249660026631312547931533444041183229427806614161759486641998156855793362317993688595988612988379260 * α ^ 59 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 59)) (pow_nonneg hu 9) - have h60 : (0:ℝ) ≤ 2426161101634452818983962562364451171736421102519269820482811118536093138975233934291550597521985218265397595876703167336388333325163886 * α ^ 60 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 60)) (pow_nonneg hu 8) - have h61 : (0:ℝ) ≤ 541326371175450174067359875320150061071720972908442799245727828526206560614239255074965243639722409936039557063502412543527181027654830 * α ^ 61 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 61)) (pow_nonneg hu 7) - have h62 : (0:ℝ) ≤ 101368480597397327160028924375975580286493435206169413993404105377621448331740368126390317293582211745281779073436064732857223060861736 * α ^ 62 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 62)) (pow_nonneg hu 6) - have h63 : (0:ℝ) ≤ 15547562252184505730936231501759499165264416461623728410208958056020346369720300266147477570730217995958466276171125428082524576695080 * α ^ 63 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 63)) (pow_nonneg hu 5) - have h64 : (0:ℝ) ≤ 1887656008153650149223340824201972880431295033490416452460837788376128006557577215350851966367675841189217496088025419715076251556542 * α ^ 64 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 64)) (pow_nonneg hu 4) - have h65 : (0:ℝ) ≤ 172441329568599584346229934517512403814851421579063304992333529980418530837648814241006023742701428622424347746365799682216705162958 * α ^ 65 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 65)) (pow_nonneg hu 3) - have h66 : (0:ℝ) ≤ 10912136951540694390745084178080768035297012709958710219152508683320236507590661219843460673650554961847278661895402354571440431696 * α ^ 66 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 66)) (pow_nonneg hu 2) - have h67 : (0:ℝ) ≤ 409247002638066659293933857623421051407334490908373427758260767055975950442905835798620454491056045234820861455361280121831050520 * α ^ 67 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 67)) (pow_nonneg hu 1) - have h68 : (0:ℝ) ≤ 6145809855889991363427473372969457107085687932679016036884496519288814567653275417252009402531892559405828541206858545507410560 * α ^ 68 := - mul_nonneg (by norm_num) (pow_nonneg hα 68) have hid : (17 : ℝ) ^ 68 * (4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 + 55048255682073709607204036059519252499577954075805344228144067353398773939360654388786551620754044174 * α + 303631470940991973002262259034385880105972184753330155102383400602879297569999672180560254047614733064 * α ^ 2 + 1082629940665673044764709543433093878486364849040990099597525143450118708087349123259727336344728664544 * α ^ 3 + 2804599610843097204574458002687246299093134788634086599591559738125527989079685417982892820063924460373 * α ^ 4 + 5624645401139815516982667151087561797773568501921017826805664176655117168979590819326893993434748481137 * α ^ 5 + 9086529173583154645809008602511982564716590500042635425568606924621639922909196505882243392404835758015 * α ^ 6 + 12147764349688852841301807848655896145357577978996235836231868297037709466427619171816150975300099741791 * α ^ 7 + 13702180594674637952993181456614636961007303430300258709825461099491823680923881039132440258291527607905 * α ^ 8 + 13228790758953813166525229226864556895698491358332563699351209388421354345605839944544173983846341165317 * α ^ 9 + 11051940590803482762640027098441612629424377433949792947689615004158487742382763237735051674050718363307 * α ^ 10 + 8057730499045200268719730173861520782106924341107579339386385608691893710110000816392557161453112592131 * α ^ 11 + 5160484214825899033659577721795935067593212006301594642310233538545527417677809202356341306165128799909 * α ^ 12 + 2917926196608374844731210581375035036343917943893823360466936440450011366221495240241631678212028102353 * α ^ 13 + 1462315101539635752571716649246230545438507378471968670138935884045737693317302923326515165319274353863 * α ^ 14 + 651362758608261532683053553948901251603409142895470962454343186012266250060431761761109117155529185351 * α ^ 15 + 258382911131744978730219354901244362207736065992848531597126642760778004801626888171716412430540285505 * α ^ 16 + 91380564667115290929103952618176877475251392601510902630099986346625474504164568221576682912080867653 * α ^ 17 + 28823701484229764785510610641119924329640879766929838579606063832811514346965585992079347095184066891 * α ^ 18 + 8105512742405337827384222403832648005310429131045055117867656987105207137736030417145103472632533011 * α ^ 19 + 2029737755516453702412381601616827618446965035012177295868811221050918334739516968406653005043323145 * α ^ 20 + 451715825606281157427809648282481163078916909506829474305720867391455366362160566615805697668034469 * α ^ 21 + 89083872539236033065296789508746088826183108150642030163709620396857932007741467883529598127701027 * α ^ 22 + 15507062046600275350060333043623953591886937497826357117111310333499555606548238470938828041232307 * α ^ 23 + 2370291817598182097124474831710334939044419386117776585894929734754031639676722325611554692802929 * α ^ 24 + 315999149372391878452912834168990330419105934995500914232394089420371940254905369886539160346853 * α ^ 25 + 36423009146013699028116153780709317964569427476167451734283550363318237494233399180783337169695 * α ^ 26 + 3588163263018483116273779737008794180190405472634090416966530935626554841121047871569879767559 * α ^ 27 + 297471336921909919923207632811348664497121895483393172379791904969696166207311294171026521523 * α ^ 28 + 20305725467845794109711961738383951154160346509672805134214469944833591189715035234346686183 * α ^ 29 + 1103609488904163566431208273520751297004151033048526881874218221163688540301268998957942157 * α ^ 30 + 44705334211106925450419755417917993038028222392715074881553657780646344635657758883181805 * α ^ 31 + 805515192221430510609334948188870016650885857492958289044650012247928862875245764497551 * α ^ 32 - 1482048260833901649795245609960707851397885375498496335550472054736679501095164961700205 * α ^ 33 + 28550595118000674813695237772389123615483889198973830073821326304976753853122397016687 * α ^ 34 - 110293125322577848844861697626305509333317224753061067523753150512274273997930489889 * α ^ 35 - 2944264371932464496615000679541333014546134952187144901035323438838119921163626816 * α ^ 36 - 42753460721496719482279714802299033215763752656049106329252818812714655687701920 * α ^ 37 + 892039301043622007789612879017665871347081871863607139597567473234375585298160 * α ^ 38 + 90290182213750286064408757160215991459134539105309106871418780497371434069600 * α ^ 39 + 3686520145576645994835054065141215370192750469525569878892121423026501980224 * α ^ 40 + 101266458446089775184406440743070690042012917626596066692722657223969408256 * α ^ 41 + 1921165999972257449345542825175329806471062302564814176599267497713370880 * α ^ 42 + 18910079844664677393253742829163990204177395135122636437886747825783808 * α ^ 43 - 267203790007683385371238236401248869931744610843957702759988424811520 * α ^ 44 - 18630321688593096100250955298980358254132585106002718798371125157888 * α ^ 45 - 549431692437424587483251682306834452811394511706522157550126837760 * α ^ 46 - 11827470008686810839474011121751705014739559837533303829463834624 * α ^ 47 - 206601161707202641093681870196336457333557666704999087205793792 * α ^ 48 - 3050100062225303864539589793145445854252294435418792706244608 * α ^ 49 - 38831214153718995312467487136862135070778219830730009018368 * α ^ 50 - 431130925861351878296650698743841679980168113965805076480 * α ^ 51 - 4201734530680545401568837521217272752627836979325435904 * α ^ 52 - 36075335848543051909606823878062380154340083870203904 * α ^ 53 - 273302433216495374400156548854470569604061187801088 * α ^ 54 - 1826924843542958932998763336695299600883344474112 * α ^ 55 - 10760219439515367849051421269035765266542231552 * α ^ 56 - 55683568301576061216924181665153394893914112 * α ^ 57 - 252108560765968990302771636780305076977664 * α ^ 58 - 992726472130728702576289249214808981504 * α ^ 59 - 3372896548691756253399508431270838272 * α ^ 60 - 9784355714995137510417248525746176 * α ^ 61 - 23895590924284630456363042996224 * α ^ 62 - 48203390780462373975323836416 * α ^ 63 - 78197438735478405231280128 * α ^ 64 - 98061705121359087009792 * α ^ 65 - 89226089066196369408 * α ^ 66 - 52420526819246080 * α ^ 67 - 14929306320896 * α ^ 68) = 4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 * (17 - α) ^ 68 + 1265157032653140923172696358781045157064900401217905487833243537047108668589294636491165982694547047750 * α ^ 1 * (17 - α) ^ 67 + 161482237306767878745241819415998746410809769680683392204930507623070859153937168257049914988047412112214 * α ^ 2 * (17 - α) ^ 66 + 13422247499165700437689764267709730212036079924252530397947436539414938500806129414515249428924591360471250 * α ^ 3 * (17 - α) ^ 65 + 816972781682827686607611010623394023676328688115620152082292022403046953548356768129403300216449427112754113 * α ^ 4 * (17 - α) ^ 64 + 38824370988158138726941311700115756071290366487538089829867353036362853363011105712229404919753034517698319713 * α ^ 5 * (17 - α) ^ 63 + 1499833600292598822014341704041896176361474668441008024749667474678088913996818119654158697311930608272571456030 * α ^ 6 * (17 - α) ^ 62 + 48422932809787295787390564041245327912518154539781119501099341947995210984379450371937423256131589899210941134514 * α ^ 7 * (17 - α) ^ 61 + 1333124974240927854482159425251402107245186286978279403787625094573367841803246952758768754029487309692347318336240 * α ^ 8 * (17 - α) ^ 60 + 31777797124891464951721548329322036172531399956667440482696617718123564246691425958497694319690617969140927686684080 * α ^ 9 * (17 - α) ^ 59 + 663714337585641075862710458977346289450664855026176138573830637339763833070986663739178423777505821459460189852947968 * α ^ 10 * (17 - α) ^ 58 + 12262485846674184769453169937509946039571704829287751556559418951991378092254593946982159731229796032255503955934621616 * α ^ 11 * (17 - α) ^ 57 + 201969028018565162730161510400745329670143714141289296191558060115320430534002168054679415522116383859539020895554723776 * α ^ 12 * (17 - α) ^ 56 + 2984596421743417793782332651870684512173959536289036391110144204303743763821125710106900081031600434022380226544823660080 * α ^ 13 * (17 - α) ^ 55 + 39784321437763110285727312524497427978490644060968737608182005051306614478428882059166898040103949867844194968529236966504 * α ^ 14 * (17 - α) ^ 54 + 480543938548422612890741989991526270246304382173993722693724388642176377466756024411416886199383755538111290823987013369160 * α ^ 15 * (17 - α) ^ 53 + 5279901417754954883742431587978703767626877114504290728644469223047973916917301789839124306590322937367972095259516102221832 * α ^ 16 * (17 - α) ^ 52 + 52945203354166745644230222209580146500462821416245712770967147511123795041025063164899837137984308325228112243872402797720184 * α ^ 17 * (17 - α) ^ 51 + 485928342569266463087021622036455747024462941842401506731286158733175889455343816199003845608430478859161164238309759380850320 * α ^ 18 * (17 - α) ^ 50 + 4091958406668774678507241930361086964473233452855436917980174792821511603462125609865012423204529448494332739565952940847535008 * α ^ 19 * (17 - α) ^ 49 + 31683212460188578387342804176945072229413086255880741845271045566233563281959233289534062862735569422810201289901710942585691872 * α ^ 20 * (17 - α) ^ 48 + 225979630689303507786898260664009071625270094449716362704636848456295027690433997904251442068696550669529118551488817387880290256 * α ^ 21 * (17 - α) ^ 47 + 1487128617430673014516169749515363875219566281808091046150030684893815735850131065805579647668091571852789526355428971538991078216 * α ^ 22 * (17 - α) ^ 46 + 9042148580683115945632798662691502266143017079630193956758831416930496458610190341296994016055070448189744269126207258222640342120 * α ^ 23 * (17 - α) ^ 45 + 50858358010848454557731664420671103160817707432587833055365526944577128658034548080461931999630601918157623952028511496302491645436 * α ^ 24 * (17 - α) ^ 44 + 264894421723415244260430513144029948945395618262574763973851002784217525442701126127347374644597622077075226262022822088501696204428 * α ^ 25 * (17 - α) ^ 43 + 1278767873696353424101636053219073837545595922525849403166724782352583013823834674590289275813557084219485073578825413587799211967436 * α ^ 26 * (17 - α) ^ 42 + 5725993526407220170131735130796235929803474480006433589234997891028171711914835354674252789493105774845667439300549950141552174204148 * α ^ 27 * (17 - α) ^ 41 + 23797472948050627920664370923139924765880312522674540655463364156321698714682589900985886207317662923270995738996512039485735022862410 * α ^ 28 * (17 - α) ^ 40 + 91847188399449607906860584187806753120315922783214799014025827204769651430206806052585878934846199020273478297324347000279002931574522 * α ^ 29 * (17 - α) ^ 39 + 329342373949609101951511940154131075827972185993638085640480145831458749736060460017623365544223280262966286218021296303864864015746416 * α ^ 30 * (17 - α) ^ 38 + 1097560558892751992700895204428590904051076121281041797677676037125864755311439126982165925162500305191774580034834400855567800165723472 * α ^ 31 * (17 - α) ^ 37 + 3400354684972857879605435169696913406951341446392821917656396040731072702340906869893233782691459204642830241785914469379158439677051796 * α ^ 32 * (17 - α) ^ 36 + 9795255185712404229440153808939878082728601957977592077724575912171144463816508150030377679174644938546737146393361620285646830422256420 * α ^ 33 * (17 - α) ^ 35 + 26239203554755141459745089973391959355052889674186027464718372088695695988893799042814172271546870765144481886268457658334065389516464974 * α ^ 34 * (17 - α) ^ 34 + 65364772208973664575034750355459656935183422873874505526092428372633233840636570937545030505946122798332726471550017157961822599578476434 * α ^ 35 * (17 - α) ^ 33 + 151417890873929453489601556690033520410995454719040770050368045093177324038829603093684868348571248298437596387498225961228162231792553093 * α ^ 36 * (17 - α) ^ 32 + 326136561459197293128988773328742282995557141736905381102626192805005586172364773727221188473432861214419687642701273642338530960261384661 * α ^ 37 * (17 - α) ^ 31 + 653015723122962185079373689805649153519043802243690625985998409467892401539972839267641852663543640591936858448032520844893189758926012070 * α ^ 38 * (17 - α) ^ 30 + 1215133738838743206101520047205100561581201889449447221306287657871682157019672294661855343053509410150028759117930302323754459334908148634 * α ^ 39 * (17 - α) ^ 29 + 2100547367169647162309522500534430225020946624321317667617084318982110113730770172930764538999209173828708805485472118278853696220026559040 * α ^ 40 * (17 - α) ^ 28 + 3371572226105498605533309421720928970740445870449689033321124541953074173720243492689723243231990142125903392944525071646763046153799712752 * α ^ 41 * (17 - α) ^ 27 + 5021731712866329267615629279744145209979569686428333572284923100300160062927127615408116117696235006051137970230291268323176361338022571184 * α ^ 42 * (17 - α) ^ 26 + 6935282526605279700851082376753425399984816075966925438156290984812989264949621990948332423313032156685195715186548440728089466656780320080 * α ^ 43 * (17 - α) ^ 25 + 8872887599583942844730285240702268137994535894273818319558203225690794212214876544716058828209821312295910996151845255442057724010075373248 * α ^ 44 * (17 - α) ^ 24 + 10504640550563806719417324418003161655867163727170635219980235187136023481938024960895708709168710341339951422197356602510535614885945508256 * α ^ 45 * (17 - α) ^ 23 + 11493574135707887540289576369636114410520335535521279072065981221823553796516692389915466887949431055195475567153283570135491233527632506928 * α ^ 46 * (17 - α) ^ 22 + 11604808627242697256579914136813566676833914505736299110704677968571962615410435000953138171276194970496716595805082770429385722453886399056 * α ^ 47 * (17 - α) ^ 21 + 10793967840695396334802012163192802178890797549077696640851371801953999538826236827198386902657587341524929692133771331237779053672003790160 * α ^ 48 * (17 - α) ^ 20 + 9230499922489526427651509591753374367209146684551244899464268618430259566127381498045470358588046512126019036255090586145820433029559234480 * α ^ 49 * (17 - α) ^ 19 + 7240815654095776003678341965368139318124068790043794347929887962009532007602522612129159417690713015083966661427793715858516996767469271084 * α ^ 50 * (17 - α) ^ 18 + 5196910721982371088216812572801559409316958643069477659778573971072818964949630354690214200347540577616724298122257242598606667131480040052 * α ^ 51 * (17 - α) ^ 17 + 3402631899636205416266590253352818738890126853621420549170291181525659701590036840082549061908694049445145596493472438472698439652700425890 * α ^ 52 * (17 - α) ^ 16 + 2025465883034696535913461632694517262359063545972119023350389907385898500473981148635068061077366719947869607252392209033800465429303336450 * α ^ 53 * (17 - α) ^ 15 + 1091892060376371705496056687719844206882169207141786444740932042075723042341165731755946837934817210431949903331903986496675369334494701764 * α ^ 54 * (17 - α) ^ 14 + 530656327268367909969479070273109187787062122866155559515976559252491925394512132156718870616555877823790538113874300155722493907068691260 * α ^ 55 * (17 - α) ^ 13 + 231274284789425659234396174824508586685686100786488695662129653371227054848548241907361605558199603413655338792402925999207216602489857076 * α ^ 56 * (17 - α) ^ 12 + 89827076778691705270449318543458115575152231899967166072570553309114042367109650873526097636925926390123634607634695515051611658499946996 * α ^ 57 * (17 - α) ^ 11 + 30860904487494092370763766510390952712726910195346707673456930961614703228983522639588565939176152364301734964159970624603354686308829140 * α ^ 58 * (17 - α) ^ 10 + 9293886338970220832863344149731277643249660026631312547931533444041183229427806614161759486641998156855793362317993688595988612988379260 * α ^ 59 * (17 - α) ^ 9 + 2426161101634452818983962562364451171736421102519269820482811118536093138975233934291550597521985218265397595876703167336388333325163886 * α ^ 60 * (17 - α) ^ 8 + 541326371175450174067359875320150061071720972908442799245727828526206560614239255074965243639722409936039557063502412543527181027654830 * α ^ 61 * (17 - α) ^ 7 + 101368480597397327160028924375975580286493435206169413993404105377621448331740368126390317293582211745281779073436064732857223060861736 * α ^ 62 * (17 - α) ^ 6 + 15547562252184505730936231501759499165264416461623728410208958056020346369720300266147477570730217995958466276171125428082524576695080 * α ^ 63 * (17 - α) ^ 5 + 1887656008153650149223340824201972880431295033490416452460837788376128006557577215350851966367675841189217496088025419715076251556542 * α ^ 64 * (17 - α) ^ 4 + 172441329568599584346229934517512403814851421579063304992333529980418530837648814241006023742701428622424347746365799682216705162958 * α ^ 65 * (17 - α) ^ 3 + 10912136951540694390745084178080768035297012709958710219152508683320236507590661219843460673650554961847278661895402354571440431696 * α ^ 66 * (17 - α) ^ 2 + 409247002638066659293933857623421051407334490908373427758260767055975950442905835798620454491056045234820861455361280121831050520 * α ^ 67 * (17 - α) ^ 1 + 6145809855889991363427473372969457107085687932679016036884496519288814567653275417252009402531892559405828541206858545507410560 * α ^ 68 := by ring - rcases le_total α (17 / (2 * 1)) with h | h - · have hpos : (0 : ℝ) < 4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 * (17 - α) ^ 68 := - mul_pos (by norm_num) (pow_pos (by linarith) 68) - linarith - · have hpos : (0 : ℝ) < 6145809855889991363427473372969457107085687932679016036884496519288814567653275417252009402531892559405828541206858545507410560 * α ^ 68 := - mul_pos (by norm_num) (pow_pos (by linarith) 68) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 68)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < 17 - α := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget diff --git a/Sendov/Reduction/Alpha17.lean b/Sendov/Reduction/Alpha17.lean index 8e979d5..ab65d13 100644 --- a/Sendov/Reduction/Alpha17.lean +++ b/Sendov/Reduction/Alpha17.lean @@ -123,16 +123,20 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) -- the standing facts about `β(1)` set B1 : ℝ := QQ (a * x) (a ^ 2) 1 with hB1def set r : ℝ := ((n : ℝ) - 2) / 2 with hrdef - have hfeas : (a * x) ^ 2 ≤ a ^ 2 := by nlinarith [sq_nonneg a, sq_nonneg x] + have hfeas : (a * x) ^ 2 ≤ a ^ 2 := by + simpa only [mul_pow, mul_one] using mul_le_mul_of_nonneg_left hx (sq_nonneg a) have hB0 : 0 ≤ B1 := QQ_nonneg hfeas 1 have h3 : (0 : ℝ) < 3 + α := by linarith have hB1lt : B1 < 1 := by have : α / (3 + α) < 1 := by rw [div_lt_one h3]; linarith linarith have hB1eq : B1 = 1 - 2 * (a * x) + a ^ 2 := by rw [hB1def, QQ_one] - have hax : 0 < a * x := by nlinarith [sq_nonneg a] - have haxle : a * x ≤ 1 := by nlinarith [sq_nonneg (x - 1), sq_nonneg (x + 1), ha.le] - have hxpos : 0 < x := by nlinarith [hax, ha] + have hax : 0 < a * x := by nlinarith only [hB1lt, hB1eq, sq_nonneg a] + have haxle : a * x ≤ 1 := by + have hxle : x ≤ 1 := by nlinarith only [hx] + calc a * x ≤ a * 1 := mul_le_mul_of_nonneg_left hxle ha.le + _ ≤ 1 := by simpa only [mul_one] using ha1.le + have hxpos : 0 < x := by nlinarith only [hax, ha] have hr : (0 : ℝ) < r := by rw [hrdef]; rw [hMn] at hM34; linarith -- `log α ≥ 2.83` have hlog17 : (2.83 : ℝ) ≤ Real.log α := @@ -140,9 +144,12 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) have hlogpos : (0 : ℝ) < Real.log α := by linarith -- `x² ≥ 1 - β(1) ≥ log α / α` have hxsq : Real.log α / α ≤ x ^ 2 := by - have h1 : 1 - B1 ≤ x ^ 2 := by rw [hB1eq]; nlinarith [sq_nonneg (x - a)] + have h1 : 1 - B1 ≤ x ^ 2 := by + rw [hB1eq] + nlinarith only [sq_nonneg (x - a)] rw [div_le_iff₀ hα0] - nlinarith [hlogb, h1] + exact hlogb.trans (by + simpa only [mul_comm] using mul_le_mul_of_nonneg_left h1 hα0.le) -- the chord split of the integral have hI1 := integral_le_tail_lin hfeas hax haxle hr set I1 : ℝ := ∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ r with hI1def @@ -168,20 +175,19 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) have hfourx : 4 * M n / (x ^ 2 * ((n : ℝ) + 2)) ≤ 4 * α / Real.log α := by have h1 : 4 * M n / (x ^ 2 * ((n : ℝ) + 2)) ≤ 4 / x ^ 2 := by rw [div_le_div_iff₀ (by positivity) (by positivity)] - have : M n ≤ (n : ℝ) + 2 := by rw [hMn]; linarith - nlinarith [sq_nonneg x, hxpos] + have hMn2 : M n ≤ (n : ℝ) + 2 := by rw [hMn]; linarith only [] + nlinarith only [mul_le_mul_of_nonneg_right hMn2 (sq_nonneg x)] have h2 : (4 : ℝ) / x ^ 2 ≤ 4 * α / Real.log α := by rw [div_le_div_iff₀ (by positivity) hlogpos] - have := hxsq - rw [div_le_iff₀ hα0] at this - nlinarith [this] - linarith + have hlogx := hxsq + rw [div_le_iff₀ hα0] at hlogx + linarith only [hlogx] + exact h1.trans h2 have hfirst : (1 - x ^ 2) / (2 * M n) ≤ 1 / (2 * M n) := by have hD : (0 : ℝ) < 2 * M n := by linarith - rw [div_le_div_iff₀ hD hD] - nlinarith [sq_nonneg x, hD] + exact div_le_div_of_nonneg_right (sub_le_self 1 (sq_nonneg x)) hD.le have hmain : 2 * α ≤ 1 / (2 * M n) + 4 * α / Real.log α + a ^ 2 * n * M n * (B1 ^ r / 2) := by - linarith [horigin, hstep, hfourx, hfirst, hax] + linarith only [horigin, hstep, hfourx, hfirst, hax] -- the substitution `v = M/(2α) - 1` -- `obtain` rather than `set`: a `set` binding is a local *definition*, which `linarith` -- zeta-reduces back into `M n / (2 * α) - 1`, making its goals nonlinear in `α` @@ -225,7 +231,8 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) ring -- the two exponential factors have hvexp : exp (-(v * Real.log α)) ≤ exp (-(2.83 * v)) := - Real.exp_le_exp.2 (by nlinarith [hv0, hlog17]) + Real.exp_le_exp.2 (by + simpa only [mul_comm] using neg_le_neg (mul_le_mul_of_nonneg_right hlog17 hv0)) have he1 : (2.7 : ℝ) < exp 1 := by linarith [Real.exp_one_gt_d9] have hsecexp : exp (Real.log α / (2 * α)) ≤ 1 / (1 - 0.1852) := by refine le_trans (Real.exp_le_exp.2 ?_) (exp_le_one_div_one_sub (by norm_num)) @@ -235,8 +242,8 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) rw [div_le_iff₀ h2α] have hlast : α / 2.7 ≤ 0.1852 * (2 * α) := by rw [div_le_iff₀ (by norm_num : (0 : ℝ) < 2.7)] - nlinarith [hα0] - linarith [h, h27, hlast] + linarith only [hα0] + linarith only [h, h27, hlast] -- assemble the geometric term have hnv : (n : ℝ) = 2 * α * (v + 1) + 1 := by rw [← hMv, hMn] @@ -251,7 +258,7 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) ≤ (n : ℝ) * α * v * (exp (-(2.83 * v)) / α * (1 / (1 - 0.1852))) := by refine mul_le_mul_of_nonneg_left (hB1r.trans ?_) (by positivity) refine mul_le_mul ?_ hsecexp (Real.exp_pos _).le (by positivity) - gcongr + exact div_le_div_of_nonneg_right hvexp hα0.le refine hstep1.trans ?_ have hfinal : (n : ℝ) * α * v * (exp (-(2.83 * v)) / α * (1 / (1 - 0.1852))) = α * (v * (2 * (v + 1) + 1 / α) * exp (-(2.83 * v))) * (1 / (1 - 0.1852)) := by @@ -262,18 +269,18 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) refine le_trans ?_ (tail_poly_bound hv0) have hinv : (1 : ℝ) / α ≤ 1 / 17 := by rw [div_le_div_iff₀ hα0 (by norm_num)]; linarith - have hprod : (0 : ℝ) ≤ v * exp (-(2.83 * v)) := mul_nonneg hv0 hexpnn - nlinarith [mul_le_mul_of_nonneg_left hinv hprod] + exact mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_left (add_le_add le_rfl hinv) hv0) hexpnn have hscale : α * (v * (2 * (v + 1) + 1 / α) * exp (-(2.83 * v))) ≤ α * 0.4118 := mul_le_mul_of_nonneg_left hbound hα0.le - linarith [hscale] + linarith only [hscale, hα0] -- the numeric contradiction have hlogterm : 4 * α / Real.log α ≤ 1.41343 * α := by rw [div_le_iff₀ hlogpos] - nlinarith [hlog17, hα0] + linarith only [mul_le_mul_of_nonneg_right hlog17 hα0.le, hα0] have hMterm : 1 / (2 * M n) ≤ 1 / 68 := by rw [div_le_div_iff₀ (by positivity) (by norm_num)] linarith - linarith [hmain, hlogterm, hMterm, hthird, hcon] + linarith only [hmain, hlogterm, hMterm, hthird, hcon] end Sendov diff --git a/scripts/emit_batch.py b/scripts/emit_batch.py index eff2114..9ae6570 100644 --- a/scripts/emit_batch.py +++ b/scripts/emit_batch.py @@ -25,14 +25,6 @@ def poly(cs, var="α"): bern = " + ".join((f"{G[0]} * {LIN} ^ {d}" if j==0 else f"{G[d]} * α ^ {d}" if j==d else f"{G[j]} * α ^ {j} * {LIN} ^ {d-j}") for j in range(d+1)) -haves = "\n".join( - (f" have h{j} : (0:ℝ) ≤ {G[0]} * {LIN} ^ {d} :=\n" - f" mul_nonneg (by norm_num) (pow_nonneg hu {d})" if j==0 else - f" have h{j} : (0:ℝ) ≤ {G[d]} * α ^ {d} :=\n" - f" mul_nonneg (by norm_num) (pow_nonneg hα {d})" if j==d else - f" have h{j} : (0:ℝ) ≤ {G[j]} * α ^ {j} * {LIN} ^ {d-j} :=\n" - f" mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα {j})) (pow_nonneg hu {d-j})") - for j in range(d+1)) src = f'''/- Copyright (c) 2026 Terence Tao. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. @@ -123,16 +115,16 @@ def Nmomc : List ℤ := lemma P_pos {{α : ℝ}} (hα : 0 ≤ α) (hα' : α ≤ {Us}) : 0 < {P} := by have hu : (0 : ℝ) ≤ {LIN0} := by linarith -{haves} have hid : ({up} : ℝ) ^ {d} * ({P}) = {bern} := by ring - rcases le_total α ({up} / (2 * {uq})) with h | h - · have hpos : (0 : ℝ) < {G[0]} * {LIN} ^ {d} := - mul_pos (by norm_num) (pow_pos (by linarith) {d}) - linarith - · have hpos : (0 : ℝ) < {G[d]} * α ^ {d} := - mul_pos (by norm_num) (pow_pos (by linarith) {d}) - linarith + -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- at α = 0 the first summand is positive. The identity above checks every coefficient. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < ({up} : ℝ) ^ {d})).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · have hu_pos : (0 : ℝ) < {LIN0} := by linarith + positivity set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget From 882ef2969d2bae0aada84e1e8951929e4af2e5cd Mon Sep 17 00:00:00 2001 From: Methode Date: Sat, 12 Sep 2026 11:40:39 -0700 Subject: [PATCH 03/24] [verified] Complete readability-first pass across the Sendov library --- Sendov/Analytic/Jsum.lean | 36 ++----- Sendov/Analytic/LowDegree.lean | 21 +--- Sendov/Analytic/Maclaurin.lean | 17 +-- Sendov/Analytic/Origin.lean | 13 +-- Sendov/Analytic/OriginExact.lean | 27 ++--- Sendov/Analytic/Polar.lean | 38 ++----- Sendov/Boundary.lean | 41 ++------ Sendov/Common/Basic.lean | 5 +- Sendov/Common/BernsteinCert.lean | 139 +++++++++++++++++++++++++ Sendov/Common/Chord.lean | 18 ++-- Sendov/Common/Quadratic.lean | 10 +- Sendov/Common/Rpow.lean | 13 +-- Sendov/Common/Sinh.lean | 9 +- Sendov/Counterexample/Factor.lean | 7 +- Sendov/Counterexample/Identities.lean | 40 ++----- Sendov/FiniteRange/Batch.lean | 8 +- Sendov/FiniteRange/Degree10_11.lean | 13 +-- Sendov/FiniteRange/Degree12_13.lean | 13 +-- Sendov/FiniteRange/Degree14_15.lean | 13 +-- Sendov/FiniteRange/Degree16_18.lean | 13 +-- Sendov/FiniteRange/Degree18_20.lean | 13 +-- Sendov/FiniteRange/Degree20.lean | 52 +++------ Sendov/FiniteRange/Degree20Packed.lean | 16 +-- Sendov/FiniteRange/Degree20_22.lean | 13 +-- Sendov/FiniteRange/Degree22_24.lean | 13 +-- Sendov/FiniteRange/Degree24_26.lean | 13 +-- Sendov/FiniteRange/Degree26_27.lean | 13 +-- Sendov/FiniteRange/Degree28_29.lean | 13 +-- Sendov/FiniteRange/Degree30_31.lean | 13 +-- Sendov/FiniteRange/Degree32_33.lean | 13 +-- Sendov/FiniteRange/Degree34_35.lean | 13 +-- Sendov/FiniteRange/Degree36_37.lean | 13 +-- Sendov/FiniteRange/Degree38_39.lean | 13 +-- Sendov/FiniteRange/Degree40_41.lean | 13 +-- Sendov/FiniteRange/Degree42_43.lean | 13 +-- Sendov/FiniteRange/Degree44_45.lean | 13 +-- Sendov/FiniteRange/Degree46_47.lean | 13 +-- Sendov/FiniteRange/Degree48_49.lean | 13 +-- Sendov/FiniteRange/Degree5.lean | 8 +- Sendov/FiniteRange/Degree50_51.lean | 13 +-- Sendov/FiniteRange/Degree52_53.lean | 13 +-- Sendov/FiniteRange/Degree53Packed.lean | 15 +-- Sendov/FiniteRange/Degree54_55.lean | 13 +-- Sendov/FiniteRange/Degree56_58.lean | 13 +-- Sendov/FiniteRange/Degree58_60.lean | 13 +-- Sendov/FiniteRange/Degree6.lean | 11 +- Sendov/FiniteRange/Degree60_63.lean | 13 +-- Sendov/FiniteRange/Degree64_69.lean | 13 +-- Sendov/FiniteRange/Degree6_6.lean | 13 +-- Sendov/FiniteRange/Degree7.lean | 6 +- Sendov/FiniteRange/Degree70_79.lean | 13 +-- Sendov/FiniteRange/Degree8.lean | 8 +- Sendov/FiniteRange/Degree80_100.lean | 11 +- Sendov/FiniteRange/Degree8_9.lean | 11 +- Sendov/FiniteRange/Degree97Packed.lean | 30 +++--- Sendov/FiniteRange/Moments.lean | 10 +- Sendov/FiniteRange/OddBound.lean | 12 +-- Sendov/FiniteRange/Pack.lean | 6 +- Sendov/FiniteRange/PackBridge.lean | 74 +++++-------- Sendov/FiniteRange/Recurrence.lean | 9 +- Sendov/LargeDegree/Endgame.lean | 127 +--------------------- Sendov/LargeDegree/Monotone.lean | 12 +-- Sendov/Reduction/BetaBound.lean | 36 +++---- Sendov/Reduction/Simplified.lean | 31 +++--- Sendov/Reduction/Stat.lean | 18 ++-- scripts/emit_batch.py | 13 +-- scripts/gen_endgame.py | 19 +--- scripts/gen_sinh.py | 108 +++++++++---------- scripts/sinh_tail.lean.txt | 138 ++++++++++-------------- 69 files changed, 583 insertions(+), 1017 deletions(-) create mode 100644 Sendov/Common/BernsteinCert.lean diff --git a/Sendov/Analytic/Jsum.lean b/Sendov/Analytic/Jsum.lean index 8d4c413..35c09c7 100644 --- a/Sendov/Analytic/Jsum.lean +++ b/Sendov/Analytic/Jsum.lean @@ -39,44 +39,24 @@ namespace Sendov lemma sum_map_sub (s : Multiset ℂ) (f g : ℂ → ℂ) : (s.map (fun v => f v - g v)).sum = (s.map f).sum - (s.map g).sum := by - induction s using Multiset.induction_on with - | empty => simp - | cons v t ih => - simp only [Multiset.map_cons, Multiset.sum_cons, ih] - ring + exact Multiset.sum_map_sub lemma sum_map_const_sub (s : Multiset ℂ) (c : ℂ) (g : ℂ → ℂ) : (s.map (fun v => c - g v)).sum = (s.card : ℂ) * c - (s.map g).sum := by - induction s using Multiset.induction_on with - | empty => simp - | cons v t ih => - simp only [Multiset.map_cons, Multiset.sum_cons, Multiset.card_cons, ih] - push_cast - ring + rw [sum_map_sub] + simp lemma sum_map_re (s : Multiset ℂ) : (s.map (fun v => v.re)).sum = s.sum.re := by - induction s using Multiset.induction_on with - | empty => simp - | cons v t ih => simp only [Multiset.map_cons, Multiset.sum_cons, Complex.add_re, ih] + exact (map_multiset_sum Complex.reAddGroupHom s).symm lemma norm_sum_map_le (s : Multiset ℂ) (f : ℂ → ℂ) : ‖(s.map f).sum‖ ≤ (s.map (fun w => ‖f w‖)).sum := by - induction s using Multiset.induction_on with - | empty => simp - | cons v t ih => - simp only [Multiset.map_cons, Multiset.sum_cons] - linarith [norm_add_le (f v) ((t.map f).sum), ih] + simpa only [Multiset.map_map, Function.comp_def] using norm_multiset_sum_le (s.map f) lemma norm_prod_le_one : ∀ (s : Multiset ℂ), (∀ w ∈ s, ‖w‖ ≤ 1) → ‖s.prod‖ ≤ 1 := by - intro s - induction s using Multiset.induction_on with - | empty => intro _; simp - | cons v t ih => - intro hs - have hv := hs v (Multiset.mem_cons_self v t) - have ht : ∀ u ∈ t, ‖u‖ ≤ 1 := fun u hu => hs u (Multiset.mem_cons_of_mem hu) - rw [Multiset.prod_cons, norm_mul] - nlinarith [ih ht, norm_nonneg v, norm_nonneg t.prod] + intro s hs + rw [norm_multiset_prod] + exact prod_norm_le_one s hs /-- `(∏ s) ∑ⱼ 1/sⱼ = ∑ⱼ ∏_{k≠j} sₖ`, the clearing of denominators that is valid exactly when no `sⱼ` vanishes. -/ diff --git a/Sendov/Analytic/LowDegree.lean b/Sendov/Analytic/LowDegree.lean index 3cfd2f2..f01d8a9 100644 --- a/Sendov/Analytic/LowDegree.lean +++ b/Sendov/Analytic/LowDegree.lean @@ -72,22 +72,11 @@ lemma prod_norm_le_lowX_pow {a t : ℝ} (ha0 : 0 ≤ a) (ha1 : a ≤ 1) (ht0 : 0 ∀ (q : Multiset ℂ), (∀ v ∈ q, ‖v‖ ≤ 1) → (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod ≤ lowX a t ^ q.card := by - intro q - induction q using Multiset.induction_on with - | empty => intro _; simp - | cons v s ih => - intro hq - have hv := hq v (Multiset.mem_cons_self v s) - have hs : ∀ u ∈ s, ‖u‖ ≤ 1 := fun u hu => hq u (Multiset.mem_cons_of_mem hu) - have hX0 : 0 ≤ lowX a t := lowX_nonneg ha0 ha1 ht0 - have h3 : 0 ≤ (s.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod := - prod_map_norm_nonneg s _ - simp only [Multiset.map_cons, Multiset.prod_cons, Multiset.card_cons, pow_succ] - calc ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖ - * (s.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod - ≤ lowX a t * lowX a t ^ s.card := - mul_le_mul (norm_le_lowX ha0 ha1 ht0 hv) (ih hs) h3 hX0 - _ = lowX a t ^ s.card * lowX a t := by ring + intro q hq + simpa using Multiset.prod_map_le_prod_map₀ + (fun v : ℂ => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖) + (fun _ => lowX a t) (fun _ _ => norm_nonneg _) + (fun v hv => norm_le_lowX ha0 ha1 ht0 (hq v hv)) /-- The branch point `(⋆)`, with every factor replaced by the scalar `X(t)`. -/ theorem one_le_lowJ {n : ℕ} {a : ℝ} (ha0 : 0 ≤ a) (ha1 : a ≤ 1) diff --git a/Sendov/Analytic/Maclaurin.lean b/Sendov/Analytic/Maclaurin.lean index eb9177b..f684caa 100644 --- a/Sendov/Analytic/Maclaurin.lean +++ b/Sendov/Analytic/Maclaurin.lean @@ -152,15 +152,10 @@ lemma esymm_card_cons (a : ℝ) (t : Multiset ℝ) (ht : t ≠ 0) : omega⟩ rw [hm] simp only [Multiset.esymm, Multiset.powersetCard_cons, Multiset.map_add, Multiset.sum_add, - Multiset.map_map, Nat.add_sub_cancel] - congr 1 - · rw [← hm, Multiset.powersetCard_self] - simp - · rw [← Multiset.sum_map_mul_left] - congr 1 - apply Multiset.map_congr rfl - intro u _ - simp + Multiset.map_map, Nat.add_sub_cancel, Function.comp_def, Multiset.prod_cons, + Multiset.sum_map_mul_left] + rw [← hm, Multiset.powersetCard_self] + simp /-- **Maclaurin's inequality, top case.** `e_{N-1}(s) ≤ N (mean s)^{N-1}`. -/ theorem Multiset.esymm_card_pred_le : ∀ (s : Multiset ℝ), (∀ x ∈ s, 0 ≤ x) → s ≠ 0 → @@ -213,9 +208,7 @@ theorem Multiset.esymm_card_pred_le : ∀ (s : Multiset ℝ), (∀ x ∈ s, 0 · have hstep := maclaurin_step (a := a) t.card hc hupos ha calc t.prod + a * t.esymm (t.card - 1) ≤ u ^ t.card + a * ((t.card : ℝ) * u ^ (t.card - 1)) := by - have h2 : a * t.esymm (t.card - 1) ≤ a * ((t.card : ℝ) * u ^ (t.card - 1)) := - mul_le_mul_of_nonneg_left hIH ha - linarith [hamgm] + exact add_le_add hamgm (mul_le_mul_of_nonneg_left hIH ha) _ = u ^ t.card + (t.card : ℝ) * a * u ^ (t.card - 1) := by ring _ ≤ ((t.card : ℝ) + 1) * ((a + t.card * u) / (t.card + 1)) ^ t.card := hstep _ = ((t.card : ℝ) + 1) * ((a + t.sum) / ((t.card : ℝ) + 1)) ^ t.card := by rw [hsum] diff --git a/Sendov/Analytic/Origin.lean b/Sendov/Analytic/Origin.lean index 5e22114..beb75a0 100644 --- a/Sendov/Analytic/Origin.lean +++ b/Sendov/Analytic/Origin.lean @@ -89,22 +89,13 @@ theorem sumEraseProdMap_eq_esymm {α : Type*} : ∀ (s : Multiset α) (f : α /-- `‖1 + s v‖² = 1 + 2 s Re v + s² ‖v‖²` for real `s`. -/ lemma norm_sq_one_add_real_mul (s : ℝ) (v : ℂ) : ‖1 + (s : ℂ) * v‖ ^ 2 = 1 + 2 * s * v.re + s ^ 2 * ‖v‖ ^ 2 := by - rw [← Complex.normSq_eq_norm_sq, ← Complex.normSq_eq_norm_sq] - simp only [Complex.normSq_apply, Complex.add_re, Complex.add_im, Complex.mul_re, - Complex.mul_im, Complex.ofReal_re, Complex.ofReal_im, Complex.one_re, Complex.one_im] - ring + simpa using norm_sq_add_real_mul 1 s v lemma sum_norm_sq_one_sub_split (s : ℝ) (q : Multiset ℂ) : (q.map (fun v => ‖1 + (s : ℂ) * v‖ ^ 2)).sum = (q.card : ℝ) + 2 * s * ((q.map (fun v => v.re)).sum) + s ^ 2 * ((q.map (fun v => ‖v‖ ^ 2)).sum) := by - induction q using Multiset.induction_on with - | empty => simp - | cons v t ih => - simp only [Multiset.map_cons, Multiset.sum_cons, Multiset.card_cons] - rw [ih, norm_sq_one_add_real_mul] - push_cast - ring + simpa using sum_norm_sq_split 1 s q /-- `∑ⱼ ‖1 - a t qⱼ‖² ≤ (n-1) β(t)`, where `β(t) = 1 - 2 a x t + a² t²`. -/ theorem sum_norm_sq_one_sub_le {n : ℕ} {a x t : ℝ} {q : Multiset ℂ} diff --git a/Sendov/Analytic/OriginExact.lean b/Sendov/Analytic/OriginExact.lean index 63fb6f4..a9550a5 100644 --- a/Sendov/Analytic/OriginExact.lean +++ b/Sendov/Analytic/OriginExact.lean @@ -42,25 +42,17 @@ open Complex (I) lemma sum_norm_le_card : ∀ (q : Multiset ℂ), (∀ v ∈ q, ‖v‖ ≤ 1) → (q.map (fun v => ‖v‖)).sum ≤ (q.card : ℝ) := by - intro q - induction q using Multiset.induction_on with - | empty => intro _; simp - | cons v t ih => - intro hq - have hv := hq v (Multiset.mem_cons_self v t) - have ht : ∀ u ∈ t, ‖u‖ ≤ 1 := fun u hu => hq u (Multiset.mem_cons_of_mem hu) - simp only [Multiset.map_cons, Multiset.sum_cons, Multiset.card_cons] - push_cast - linarith [ih ht] + intro q hq + simpa using Multiset.sum_map_le_sum_map (fun v : ℂ => ‖v‖) (fun _ => (1 : ℝ)) hq /-- `|s + it| ≤ s + t²/(2s)` for `s > 0`, in cleared form. Squaring both sides leaves -`t⁴ ≥ 0`. -/ +`t⁴ ≥ 0`; directly, the cleared inequality is `(‖w‖ - w.re)² ≥ 0`. -/ lemma norm_mul_two_re_le {w : ℂ} (_hs : 0 < w.re) : ‖w‖ * (2 * w.re) ≤ 2 * w.re ^ 2 + w.im ^ 2 := by have h1 : ‖w‖ ^ 2 = w.re ^ 2 + w.im ^ 2 := by rw [← Complex.normSq_eq_norm_sq, Complex.normSq_apply] ring - nlinarith [norm_nonneg w, h1, sq_nonneg (w.im ^ 2), sq_nonneg (w.re * w.im)] + nlinarith only [h1, sq_nonneg (‖w‖ - w.re)] /-! ### The quantity `W`, the growth bound `(grow)`, and the two real-arithmetic steps -/ @@ -77,14 +69,13 @@ lemma Worigin_eq (n : ℕ) (a x y : ℝ) : lemma Worigin_re (n : ℕ) (a x y : ℝ) : (Worigin n a x y).re = a ^ 2 * ((n : ℝ) - 1) + 1 - a * x := by - rw [Worigin_eq, Complex.add_re, Complex.ofReal_re, Complex.mul_re, Complex.ofReal_re, - Complex.ofReal_im, Complex.I_re, Complex.I_im] - ring + rw [Worigin_eq] + simp only [Complex.add_re, Complex.ofReal_re, Complex.mul_I_re, Complex.ofReal_im, + neg_zero, add_zero] lemma Worigin_im (n : ℕ) (a x y : ℝ) : (Worigin n a x y).im = -(a * y) := by - rw [Worigin_eq, Complex.add_im, Complex.ofReal_im, Complex.mul_im, Complex.ofReal_re, - Complex.ofReal_im, Complex.I_re, Complex.I_im] - ring + rw [Worigin_eq] + simp only [Complex.add_im, Complex.ofReal_im, Complex.mul_I_im, Complex.ofReal_re, zero_add] /-- **(grow).** `‖W‖ ≥ 2an/(n-1)`. Bounding `‖W‖` below by its real part reduces this to `(n-1)²a² - (3n-1)a + (n-1) > 0`; completing the square turns that into diff --git a/Sendov/Analytic/Polar.lean b/Sendov/Analytic/Polar.lean index 7e595fd..6d4ac97 100644 --- a/Sendov/Analytic/Polar.lean +++ b/Sendov/Analytic/Polar.lean @@ -73,24 +73,11 @@ lemma norm_sub_le_norm_one_sub_mul {a : ℝ} (ha : |a| ≤ 1) {z : ℂ} (hz : /-! ### Products of norms over a multiset -/ lemma norm_multiset_prod (s : Multiset ℂ) : ‖s.prod‖ = (s.map (fun w => ‖w‖)).prod := by - induction s using Multiset.induction_on with - | empty => simp - | cons w t ih => simp [ih] + exact map_multiset_prod (normHom : ℂ →*₀ ℝ) s lemma prod_map_le_of_le {s : Multiset ℂ} {f g : ℂ → ℂ} (h : ∀ w ∈ s, ‖f w‖ ≤ ‖g w‖) : (s.map (fun w => ‖f w‖)).prod ≤ (s.map (fun w => ‖g w‖)).prod := by - induction s using Multiset.induction_on with - | empty => simp - | cons w t ih => - have hw := h w (Multiset.mem_cons_self w t) - have ht : ∀ u ∈ t, ‖f u‖ ≤ ‖g u‖ := fun u hu => h u (Multiset.mem_cons_of_mem hu) - have hnn : (0 : ℝ) ≤ (t.map (fun u => ‖f u‖)).prod := - Multiset.prod_nonneg (by - intro y hy - obtain ⟨u, _, rfl⟩ := Multiset.mem_map.1 hy - exact norm_nonneg _) - simp only [Multiset.map_cons, Multiset.prod_cons] - exact mul_le_mul hw (ih ht) hnn (norm_nonneg _) + exact Multiset.prod_map_le_prod_map₀ _ _ (fun _ _ => norm_nonneg _) h /-! ### The branch point -/ @@ -102,10 +89,7 @@ lemma norm_prod_map (s : Multiset ℂ) (f : ℂ → ℂ) : lemma prod_map_norm_nonneg (s : Multiset ℂ) (f : ℂ → ℂ) : 0 ≤ (s.map (fun w => ‖f w‖)).prod := by - refine Multiset.prod_nonneg ?_ - intro y hy - obtain ⟨u, _, rfl⟩ := Multiset.mem_map.1 hy - exact norm_nonneg _ + exact Multiset.prod_map_nonneg (fun _ _ => norm_nonneg _) /-- **The branch point `(⋆)`.** `1 ≤ ∫₀¹ ∏ⱼ |a + t(1-a²)qⱼ| dt`. @@ -164,11 +148,7 @@ lemma norm_sq_add_real_mul (a s : ℝ) (v : ℂ) : lemma prod_map_sq (s : Multiset ℂ) (f : ℂ → ℝ) : (s.map (fun v => f v ^ 2)).prod = ((s.map f).prod) ^ 2 := by - induction s using Multiset.induction_on with - | empty => simp - | cons v t ih => - simp only [Multiset.map_cons, Multiset.prod_cons, ih] - ring + exact Multiset.prod_map_pow /-- Splitting `∑ⱼ ‖a + s qⱼ‖²` into its three pieces. -/ lemma sum_norm_sq_split (a s : ℝ) (q : Multiset ℂ) : @@ -185,14 +165,8 @@ lemma sum_norm_sq_split (a s : ℝ) (q : Multiset ℂ) : lemma sum_norm_sq_le_card (q : Multiset ℂ) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) : (q.map (fun v => ‖v‖ ^ 2)).sum ≤ (q.card : ℝ) := by - induction q using Multiset.induction_on with - | empty => simp - | cons v t ih => - have hv := hq1 v (Multiset.mem_cons_self v t) - have ht : ∀ u ∈ t, ‖u‖ ≤ 1 := fun u hu => hq1 u (Multiset.mem_cons_of_mem hu) - simp only [Multiset.map_cons, Multiset.sum_cons, Multiset.card_cons] - push_cast - nlinarith [ih ht, norm_nonneg v] + simpa using Multiset.sum_map_le_sum_map (fun v : ℂ => ‖v‖ ^ 2) (fun _ => (1 : ℝ)) + (fun v hv => pow_le_one₀ (norm_nonneg v) (hq1 v hv)) lemma continuous_prod_norm (a : ℝ) (q : Multiset ℂ) : Continuous fun t : ℝ => diff --git a/Sendov/Boundary.lean b/Sendov/Boundary.lean index 414f337..9c2d3eb 100644 --- a/Sendov/Boundary.lean +++ b/Sendov/Boundary.lean @@ -98,50 +98,21 @@ lemma eq_one_of_re_eq_one_of_norm_le_one {v : ℂ} (hre : v.re = 1) (hv : ‖v /-- A multiset of nonnegative reals summing to zero is all zeroes. -/ lemma eq_zero_of_sum_eq_zero {s : Multiset ℝ} (hs : ∀ x ∈ s, 0 ≤ x) (h : s.sum = 0) : ∀ x ∈ s, x = 0 := by - intro x hx - have hsplit : s.sum = x + (s.erase x).sum := by - conv_lhs => rw [← Multiset.cons_erase hx] - rw [Multiset.sum_cons] - have hrest : 0 ≤ (s.erase x).sum := - Multiset.sum_nonneg fun y hy => hs y (Multiset.mem_of_mem_erase hy) - rw [hsplit] at h - have := hs x hx - linarith + exact Multiset.all_zero_of_le_zero_le_of_sum_eq_zero hs h lemma sum_le_card_mul (c : ℝ) : ∀ (s : Multiset ℝ), (∀ x ∈ s, x ≤ c) → s.sum ≤ (s.card : ℝ) * c := by - intro s - induction s using Multiset.induction_on with - | empty => intro _; simp - | cons v t ih => - intro h - have hv := h v (Multiset.mem_cons_self v t) - have ht : ∀ x ∈ t, x ≤ c := fun x hx => h x (Multiset.mem_cons_of_mem hx) - simp only [Multiset.sum_cons, Multiset.card_cons] - push_cast - linarith [ih ht] + intro s h + simpa only [nsmul_eq_mul] using Multiset.sum_le_card_nsmul s c h lemma card_mul_le_sum (c : ℝ) : ∀ (s : Multiset ℝ), (∀ x ∈ s, c ≤ x) → (s.card : ℝ) * c ≤ s.sum := by - intro s - induction s using Multiset.induction_on with - | empty => intro _; simp - | cons v t ih => - intro h - have hv := h v (Multiset.mem_cons_self v t) - have ht : ∀ x ∈ t, c ≤ x := fun x hx => h x (Multiset.mem_cons_of_mem hx) - simp only [Multiset.sum_cons, Multiset.card_cons] - push_cast - linarith [ih ht] + intro s h + simpa only [nsmul_eq_mul] using Multiset.card_nsmul_le_sum h lemma sum_map_one_sub_re (s : Multiset ℂ) : (s.map (fun v => 1 - v.re)).sum = (s.card : ℝ) - (s.map (fun v => v.re)).sum := by - induction s using Multiset.induction_on with - | empty => simp - | cons v t ih => - simp only [Multiset.map_cons, Multiset.sum_cons, Multiset.card_cons, ih] - push_cast - ring + simp [Multiset.sum_map_sub, Multiset.map_const', Multiset.sum_replicate] /-! ### The boundary reciprocal identity -/ diff --git a/Sendov/Common/Basic.lean b/Sendov/Common/Basic.lean index c085745..dc80934 100644 --- a/Sendov/Common/Basic.lean +++ b/Sendov/Common/Basic.lean @@ -65,7 +65,7 @@ lemma alpha_le_half_M (hn : 2 ≤ n) (hfeas : c n α ^ 2 ≤ A n α) : α ≤ M lemma Q_nonneg (hfeas : c n α ^ 2 ≤ A n α) (t : ℝ) : 0 ≤ Q n α t := by rw [Q_eq] - exact add_nonneg (sq_nonneg _) (mul_nonneg (by linarith) (sq_nonneg _)) + exact add_nonneg (sq_nonneg _) (mul_nonneg (sub_nonneg.2 hfeas) (sq_nonneg _)) /-- `Q n α 1 = B = α / (3 + α)`: the substituted quadratic takes at `t = 1` the value that the simplified polar inequality `β(1) < α / (3 + α)` prescribes. -/ @@ -125,7 +125,6 @@ lemma R_le_of_integral_le (hn : 2 ≤ n) (hα : 0 ≤ α) {J : ℝ} div_nonneg (mul_nonneg (mul_nonneg (mul_nonneg (sq_nonneg _) (Nat.cast_nonneg n)) (M_pos hn).le) hn2) (by linarith) rw [R] - have := mul_le_mul_of_nonneg_left hJ hcoef - linarith + exact add_le_add_right (mul_le_mul_of_nonneg_left hJ hcoef) _ end Sendov diff --git a/Sendov/Common/BernsteinCert.lean b/Sendov/Common/BernsteinCert.lean new file mode 100644 index 0000000..4d170f9 --- /dev/null +++ b/Sendov/Common/BernsteinCert.lean @@ -0,0 +1,139 @@ +import Mathlib.Data.Real.Basic +import Mathlib.Tactic.Positivity +import Mathlib.Tactic.Linarith + +namespace BernsteinCert +/-- An addition tree of natural-coefficient bivariate monomials. -/ +inductive Cert where + | mono (c i j : ℕ) + | add (a b : Cert) + +def Cert.eval : Cert → ℝ → ℝ → ℝ + | .mono c i j, x, y => (c : ℝ) * x^i * y^j + | .add a b, x, y => a.eval x y + b.eval x y + +/-- `true` selects a positive pure-y term; `false` selects a positive pure-x term. -/ +def Cert.edge (left : Bool) : Cert → Bool + | .mono c i j => (0 < c) && ((if left then i else j) == 0) + | .add a b => a.edge left || b.edge left + +theorem Cert.nonneg (a : Cert) {x y : ℝ} (hx : 0 ≤ x) (hy : 0 ≤ y) : + 0 ≤ a.eval x y := by + induction a with + | mono c i j => + exact mul_nonneg (mul_nonneg (Nat.cast_nonneg c) (pow_nonneg hx i)) + (pow_nonneg hy j) + | add a b ha hb => exact add_nonneg ha hb + +theorem Cert.pos_left (a : Cert) {x y : ℝ} (hx : 0 ≤ x) (hy : 0 < y) + (h : a.edge true = true) : 0 < a.eval x y := by + induction a with + | mono c i j => + simp only [edge, ↓reduceIte, Bool.and_eq_true, decide_eq_true_eq, + beq_iff_eq] at h + rcases h with ⟨hc, rfl⟩ + simpa only [eval, pow_zero, mul_one] using + mul_pos (Nat.cast_pos.mpr hc : (0 : ℝ) < c) (pow_pos hy j) + | add a b ha hb => + simp only [edge, Bool.or_eq_true] at h + rcases h with h | h + · exact add_pos_of_pos_of_nonneg (ha h) (b.nonneg hx hy.le) + · exact add_pos_of_nonneg_of_pos (a.nonneg hx hy.le) (hb h) + +theorem Cert.pos_right (a : Cert) {x y : ℝ} (hx : 0 < x) (hy : 0 ≤ y) + (h : a.edge false = true) : 0 < a.eval x y := by + induction a with + | mono c i j => + simp only [edge, Bool.false_eq_true, ↓reduceIte, Bool.and_eq_true, decide_eq_true_eq, + beq_iff_eq] at h + rcases h with ⟨hc, rfl⟩ + simpa only [eval, pow_zero, mul_one] using + mul_pos (Nat.cast_pos.mpr hc : (0 : ℝ) < c) (pow_pos hx i) + | add a b ha hb => + simp only [edge, Bool.or_eq_true] at h + rcases h with h | h + · exact add_pos_of_pos_of_nonneg (ha h) (b.nonneg hx.le hy) + · exact add_pos_of_nonneg_of_pos (a.nonneg hx.le hy) (hb h) + +/-- The reusable core: nonnegative coordinates with positive sum and both endpoint supports. -/ +theorem Cert.pos (a : Cert) {x y : ℝ} (hx : 0 ≤ x) (hy : 0 ≤ y) + (hxy : 0 < x + y) (hl : a.edge true = true) (hr : a.edge false = true) : + 0 < a.eval x y := by + rcases lt_or_eq_of_le hx with h | h + · exact a.pos_right h hy hr + · exact a.pos_left hx (by linarith) hl + +theorem scaled_pos (a : Cert) {x y s P : ℝ} + (hid : s * P = a.eval x y) (hs : 0 < s) (hx : 0 ≤ x) (hy : 0 ≤ y) + (hxy : 0 < x + y) (hl : a.edge true = true) (hr : a.edge false = true) : 0 < P := by + have hp : 0 < s * P := hid.symm ▸ a.pos hx hy hxy hl hr + exact (mul_pos_iff_of_pos_left hs).mp hp + +open Lean Meta Elab Tactic +-- Heterogeneous operation notation has six arguments; its last two are the operands. +private def binary? (e : Expr) (n : Name) : Option (Expr × Expr) := + if e.isAppOfArity n 6 then some (e.getArg! 4, e.getArg! 5) else none + +private partial def factors (e : Expr) : Array Expr := + match binary? e ``HMul.hMul with + | some (a,b) => factors a ++ factors b + | none => #[e] + +private def natSyntax (n : Nat) : TSyntax `term := ⟨Syntax.mkNumLit (toString n)⟩ + +-- Homogeneity is a frontend restriction; the soundness theorem also covers mixed degrees. +private partial def reify (e x y : Expr) : TacticM (TSyntax `term × Nat) := do + if let some (a,b) := binary? e ``HAdd.hAdd then + let (ca, da) ← reify a x y + let (cb, db) ← reify b x y + unless da == db do throwError "bernstein_cert: mixed total degrees {da} and {db}" + return (← `(Cert.add $ca $cb), da) + let mut c := 1 + let mut i := 0 + let mut j := 0 + let mut seenC := false + for f in factors e do + if ← isDefEq f x then i := i+1 + else if ← isDefEq f y then j := j+1 + else if f.isAppOfArity ``HPow.hPow 6 then + let base := f.getArg! 4 + let some n ← getNatValue? (f.getArg! 5) + | throwError "bernstein_cert: exponent must be numeral" + if ← isDefEq base x then i := i+n + else if ← isDefEq base y then j := j+n + else throwError "bernstein_cert: unknown power base" + else + unless f.isAppOfArity ``OfNat.ofNat 3 do + throwError "bernstein_cert: coefficient must be a natural numeral, got {f}" + let some n ← getNatValue? (f.getArg! 1) + | throwError "bernstein_cert: invalid numeral" + if seenC then throwError "bernstein_cert: multiple coefficients unsupported" + c := n + seenC := true + return (← `(Cert.mono $(natSyntax c) $(natSyntax i) $(natSyntax j)), i+j) + +elab "bernstein_cert " x:term:max y:term:max " using " hid:term : tactic => withMainContext do + let xe ← elabTerm x (some (mkConst ``Real)) + let ye ← elabTerm y (some (mkConst ``Real)) + let he ← elabTerm hid none + let ht ← inferType he + unless ht.isAppOfArity ``Eq 3 do throwError "bernstein_cert: expected equality" + let lhs := ht.getArg! 1 + let some (s, _) := binary? lhs ``HMul.hMul + | throwError "bernstein_cert: identity LHS must be scale * target" + let (c, _) ← reify (ht.getArg! 2) xe ye + let st ← Term.exprToSyntax s + evalTactic (← `(tactic| + refine BernsteinCert.scaled_pos $c (x := $x) (y := $y) (s := $st) + ?_ ?_ ?_ ?_ ?_ (by decide) (by decide))) + focus do + let h := mkIdent (← mkFreshUserName `hBernsteinIdentity) + evalTactic (← `(tactic| have $h := $hid)) + -- Normalize the identity and certificate once; reflexive goals need no `exact`. + evalTactic (← `(tactic| simp only [Cert.eval, Nat.cast_ofNat, Nat.cast_zero, + Nat.cast_one, pow_zero, pow_one, mul_one, one_mul, mul_assoc] at $h ⊢)) + unless (← getGoals).isEmpty do + evalTactic (← `(tactic| exact $h)) + evalTactic (← `(tactic| all_goals first | assumption | positivity | linarith)) + +end BernsteinCert diff --git a/Sendov/Common/Chord.lean b/Sendov/Common/Chord.lean index b2dfcc7..cff6014 100644 --- a/Sendov/Common/Chord.lean +++ b/Sendov/Common/Chord.lean @@ -50,11 +50,8 @@ lemma integral_lin_mul_rpow {s : ℝ} (hs : 0 < s) : (1 - x) * x ^ s = x ^ s - x ^ (s + (1 : ℕ)) := by intro x hx rw [Set.uIcc_of_le (by norm_num : (0 : ℝ) ≤ 1)] at hx - rcases eq_or_lt_of_le hx.1 with h | h - · rw [← h, Real.zero_rpow (by positivity), Real.zero_rpow (by push_cast; linarith)] - ring - · rw [rpow_add_nat_pos h] - ring + rw [Real.rpow_add_natCast' hx.1 (by positivity : s + (1 : ℕ) ≠ 0)] + ring rw [hrefl, intervalIntegral.integral_congr hcongr] have hi' : IntervalIntegrable (fun x : ℝ => x ^ s) volume 0 1 := intervalIntegral.intervalIntegrable_rpow' (by linarith) @@ -83,13 +80,10 @@ lemma integral_cube_mul_rpow {s : ℝ} (hs : 0 < s) : = x ^ s - 3 * x ^ (s + (1 : ℕ)) + 3 * x ^ (s + (2 : ℕ)) - x ^ (s + (3 : ℕ)) := by intro x hx rw [Set.uIcc_of_le (by norm_num : (0 : ℝ) ≤ 1)] at hx - rcases eq_or_lt_of_le hx.1 with h | h - · rw [← h] - rw [Real.zero_rpow (by positivity), Real.zero_rpow (by push_cast; linarith), - Real.zero_rpow (by push_cast; linarith), Real.zero_rpow (by push_cast; linarith)] - ring - · rw [rpow_add_nat_pos h, rpow_add_nat_pos h, rpow_add_nat_pos h] - ring + rw [Real.rpow_add_natCast' hx.1 (by positivity : s + (1 : ℕ) ≠ 0), + Real.rpow_add_natCast' hx.1 (by positivity : s + (2 : ℕ) ≠ 0), + Real.rpow_add_natCast' hx.1 (by positivity : s + (3 : ℕ) ≠ 0)] + ring rw [hrefl, intervalIntegral.integral_congr hcongr] have hi' : IntervalIntegrable (fun x : ℝ => x ^ s) volume 0 1 := intervalIntegral.intervalIntegrable_rpow' (by linarith) diff --git a/Sendov/Common/Quadratic.lean b/Sendov/Common/Quadratic.lean index 28b5d18..877abba 100644 --- a/Sendov/Common/Quadratic.lean +++ b/Sendov/Common/Quadratic.lean @@ -56,18 +56,18 @@ lemma QQ_one (c A : ℝ) : QQ c A 1 = 1 - 2 * c + A := by simp [QQ] /-- Feasibility `c² ≤ A` says exactly that `QQ` is a sum of squares. -/ lemma QQ_nonneg (hfeas : c ^ 2 ≤ A) (t : ℝ) : 0 ≤ QQ c A t := by rw [QQ_eq] - exact add_nonneg (sq_nonneg _) (mul_nonneg (by linarith) (sq_nonneg _)) + exact add_nonneg (sq_nonneg _) (mul_nonneg (sub_nonneg.2 hfeas) (sq_nonneg _)) /-- `QQ ≤ 1` on `[0,1]`, from `QQ 1 ≤ 1` and `0 ≤ c` alone. -/ lemma QQ_le_one (hc : 0 ≤ c) (hB : QQ c A 1 ≤ 1) (ht0 : 0 ≤ t) (ht1 : t ≤ 1) : QQ c A t ≤ 1 := by have hAc : A - 2 * c ≤ 0 := by rw [QQ_one] at hB; linarith - have h5 : A * t - 2 * c ≤ 0 := by + have hAt : A * t ≤ 2 * c := by rcases le_total 0 A with h | h - · nlinarith [mul_le_of_le_one_right h ht1] - · nlinarith [mul_nonneg ht0 (neg_nonneg.2 h)] + · exact (mul_le_of_le_one_right h ht1).trans (sub_nonpos.1 hAc) + · exact (mul_nonpos_of_nonpos_of_nonneg h ht0).trans (by positivity) simp only [QQ] - nlinarith [mul_nonneg ht0 (neg_nonneg.2 h5)] + nlinarith [mul_nonneg ht0 (sub_nonneg.2 hAt)] /-- Below the vertex, `QQ` lies under the chord `1 - ct`. -/ lemma QQ_le_chord (ht0 : 0 ≤ t) (ht : A * t ≤ c) : QQ c A t ≤ 1 - c * t := by diff --git a/Sendov/Common/Rpow.lean b/Sendov/Common/Rpow.lean index 018d586..e17a3d7 100644 --- a/Sendov/Common/Rpow.lean +++ b/Sendov/Common/Rpow.lean @@ -19,9 +19,10 @@ In particular: * the finite range uses `Sendov.continuous_integrand` to compare integrals in `Sendov.integral_rpow_le`, and the large-degree argument needs the same fact to split `∫₀¹` at the vertex of `Q`; -* `Sendov.rpow_add_nat_pos` is used by the Beta integral, and the same splitting of a real - power into a real and a natural part is what turns `B ^ ((n-4)/2)` into `B ^ k * √B` in - the large-degree reduction. +* `Sendov.rpow_add_nat_pos` remains a compatibility wrapper for positive bases. The Beta + integrals use Mathlib’s zero-compatible splitting directly; splitting a real power into + a real and a natural part also turns `B ^ ((n-4)/2)` into `B ^ k * √B` in the large-degree + reduction. -/ namespace Sendov @@ -36,13 +37,13 @@ lemma integral_rpow_zero_one {s : ℝ} (hs : -1 < s) : /-- `x ^ (s + m) = x ^ s * x ^ m` for positive `x` and a natural `m`. -/ lemma rpow_add_nat_pos {x : ℝ} (hx : 0 < x) (s : ℝ) (m : ℕ) : - x ^ (s + (m : ℝ)) = x ^ s * x ^ m := by - rw [Real.rpow_add hx, Real.rpow_natCast] + x ^ (s + (m : ℝ)) = x ^ s * x ^ m := + Real.rpow_add_natCast hx.ne' s m /-- `fun x ↦ x ^ e` is continuous on all of `ℝ` for a nonnegative real exponent `e`. The exponent must be nonnegative: at `e < 0` the function blows up at the origin. -/ lemma continuous_rpow_const {e : ℝ} (he : 0 ≤ e) : Continuous fun x : ℝ => x ^ e := - continuous_iff_continuousAt.2 fun x => Real.continuousAt_rpow_const x e (Or.inr he) + Real.continuous_rpow_const he /-- The integrand of `Sendov.R` is continuous, hence interval integrable. Needed wherever an integral involving `Q ^ e` is split or compared. -/ diff --git a/Sendov/Common/Sinh.lean b/Sendov/Common/Sinh.lean index 1febaf8..cda6eb3 100644 --- a/Sendov/Common/Sinh.lean +++ b/Sendov/Common/Sinh.lean @@ -75,13 +75,8 @@ private lemma nonneg_of_deriv {f g : ℝ → ℝ} (hd : ∀ z, HasDerivAt f (g z simpa [h0] using hmono (mem_Ici.2 le_rfl) (mem_Ici.2 hy) hy /-- `1 + y + y²/2 ≤ exp y` for `y ≥ 0`: three terms of the exponential series. -/ -private lemma quad_le_exp {y : ℝ} (hy : 0 ≤ y) : 1 + y + y ^ 2 / 2 ≤ exp y := by - suffices 0 ≤ exp y - 1 - y - y ^ 2 / 2 by linarith - refine nonneg_of_deriv (f := fun t => exp t - 1 - t - t ^ 2 / 2) - (g := fun t => exp t - 1 - t) (fun t => ?_) (by norm_num) (fun t ht => ?_) hy - · exact ((((hasDerivAt_exp t).sub_const 1).sub (hasDerivAt_id' t)).sub - ((hasDerivAt_pow 2 t).div_const 2)).congr_deriv (by norm_num) - · linarith [add_one_le_exp t] +private lemma quad_le_exp {y : ℝ} (hy : 0 ≤ y) : 1 + y + y ^ 2 / 2 ≤ exp y := + Real.quadratic_le_exp_of_nonneg hy /-- The family closed under differentiation: `e^{2y} u(y) - e^y v(y) - w(y)` with `u`, `w` cubic and `v` quartic. -/ diff --git a/Sendov/Counterexample/Factor.lean b/Sendov/Counterexample/Factor.lean index 579170b..9cbf8e0 100644 --- a/Sendov/Counterexample/Factor.lean +++ b/Sendov/Counterexample/Factor.lean @@ -108,12 +108,7 @@ theorem exists_crit_multiset {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.nat linarith obtain ⟨q, hq⟩ : ∃ q : Multiset ℂ, q = W.map (fun w => (a - w)⁻¹) := ⟨_, rfl⟩ have hback : q.map (fun v => a - v⁻¹) = W := by - rw [hq, Multiset.map_map] - have hid : ∀ w ∈ W, ((fun v => a - v⁻¹) ∘ (fun w => (a - w)⁻¹)) w = w := by - intro w hw - simp only [Function.comp_apply, inv_inv] - ring - rw [Multiset.map_congr rfl hid, Multiset.map_id'] + simp [hq, Multiset.map_map] refine ⟨q, ?_, ?_, ?_, ?_⟩ · rw [hq, Multiset.card_map, hcard] · intro v hv diff --git a/Sendov/Counterexample/Identities.lean b/Sendov/Counterexample/Identities.lean index 27e8472..28a1cfe 100644 --- a/Sendov/Counterexample/Identities.lean +++ b/Sendov/Counterexample/Identities.lean @@ -115,11 +115,7 @@ lemma sumEraseProd_cons (v : ℂ) (t : Multiset ℂ) : /-- Negating a multiset before taking the product. -/ lemma prod_map_neg (s : Multiset ℂ) : (s.map (fun w => -w)).prod = (-1) ^ (Multiset.card s) * s.prod := by - induction s using Multiset.induction_on with - | empty => simp - | cons a t ih => - simp only [Multiset.map_cons, Multiset.prod_cons, Multiset.card_cons, ih] - ring + exact Multiset.prod_map_neg s /-- `∏ⱼ (X - zⱼ)` at the origin. -/ lemma eval_prod_zero (z : Multiset ℂ) : @@ -148,16 +144,12 @@ lemma eval_deriv_prod_zero : ∀ (z : Multiset ℂ), /-- `∏ⱼ (1/vⱼ - a) · ∏ⱼ vⱼ = ∏ⱼ (1 - a vⱼ)`: clearing the denominators of the `q`-side. -/ lemma prod_inv_sub_mul : ∀ (q : Multiset ℂ), (∀ v ∈ q, v ≠ 0) → (q.map (fun v => v⁻¹ - a)).prod * q.prod = (q.map (fun v => 1 - a * v)).prod := by - intro q - induction q using Multiset.induction_on with - | empty => simp - | cons v t ih => - intro hq - have hv : v ≠ 0 := hq v (Multiset.mem_cons_self v t) - have ht : ∀ w ∈ t, w ≠ 0 := fun w hw => hq w (Multiset.mem_cons_of_mem hw) - simp only [Multiset.map_cons, Multiset.prod_cons] - rw [← ih ht] - field_simp + intro q hq + conv_lhs => rhs; rw [← Multiset.map_id' q] + rw [← Multiset.prod_map_mul] + refine congrArg Multiset.prod (Multiset.map_congr rfl ?_) + intro v hv + rw [sub_mul, inv_mul_cancel₀ (hq v hv)] open scoped Classical in /-- **The second origin identity**, division-free. The blog post's form @@ -296,25 +288,13 @@ theorem first_origin_identity {p : ℂ[X]} (hc0 : c ≠ 0) (ha0 : a ≠ 0) /-- Pulling a constant out of a product over a multiset. -/ lemma prod_map_mul_const (b : ℂ) (s : Multiset ℂ) (f : ℂ → ℂ) : (s.map (fun v => b * f v)).prod = b ^ (Multiset.card s) * (s.map f).prod := by - induction s using Multiset.induction_on with - | empty => simp - | cons v t ih => - simp only [Multiset.map_cons, Multiset.prod_cons, Multiset.card_cons, ih] - ring + rw [Multiset.prod_map_mul, Multiset.map_const', Multiset.prod_replicate] /-- `∏ⱼ (1/vⱼ) · ∏ⱼ vⱼ = 1`. -/ lemma prod_inv_mul : ∀ (q : Multiset ℂ), (∀ v ∈ q, v ≠ 0) → (q.map (fun v => v⁻¹)).prod * q.prod = 1 := by - intro q - induction q using Multiset.induction_on with - | empty => simp - | cons v t ih => - intro hq - have hv : v ≠ 0 := hq v (Multiset.mem_cons_self v t) - have ht : ∀ w ∈ t, w ≠ 0 := fun w hw => hq w (Multiset.mem_cons_of_mem hw) - simp only [Multiset.map_cons, Multiset.prod_cons] - rw [← ih ht] - field_simp + intro q hq + simpa using (prod_inv_sub_mul (a := 0) q hq) /-- **`p'(a)` two ways.** `(∏ⱼ qⱼ) ∏ⱼ (a - zⱼ) = n`. This is what makes the polar identity usable without dividing: it is the denominator of the blog post's diff --git a/Sendov/FiniteRange/Batch.lean b/Sendov/FiniteRange/Batch.lean index bb9ce63..bcd824c 100644 --- a/Sendov/FiniteRange/Batch.lean +++ b/Sendov/FiniteRange/Batch.lean @@ -41,9 +41,7 @@ namespace Sendov variable {α t : ℝ} lemma M_mono {m n : ℕ} (h : m ≤ n) : M m ≤ M n := by - simp only [M] - have : (m : ℝ) ≤ (n : ℝ) := by exact_mod_cast h - linarith + exact sub_le_sub_right (Nat.cast_le.2 h) 1 /-- `A` increases with `n`: raising the degree moves `a²` towards `1`. -/ lemma A_mono {m n : ℕ} (hm : 2 ≤ m) (h : m ≤ n) (hα : 0 ≤ α) : A m α ≤ A n α := by @@ -97,9 +95,7 @@ open MeasureTheory /-- `x ^ y ≤ x ^ z` for `0 ≤ x ≤ 1` and `0 < z ≤ y`, allowing `x = 0`. -/ lemma rpow_le_rpow_exponent_ge' {x y z : ℝ} (hx0 : 0 ≤ x) (hx1 : x ≤ 1) (hz : 0 < z) (hzy : z ≤ y) : x ^ y ≤ x ^ z := by - rcases eq_or_lt_of_le hx0 with h | h - · rw [← h, Real.zero_rpow (by linarith), Real.zero_rpow (by linarith)] - · exact Real.rpow_le_rpow_of_exponent_ge h hx1 hzy + exact Real.rpow_le_rpow_of_exponent_ge' hx0 hx1 hz.le hzy /-- The moment decreases with the degree: `Q` falls and the exponent rises. -/ theorem integral_anti {m n : ℕ} (hm : 5 ≤ m) (h : m ≤ n) (hα : 0 ≤ α) diff --git a/Sendov/FiniteRange/Degree10_11.lean b/Sendov/FiniteRange/Degree10_11.lean index fafaeed..5f6b46a 100644 --- a/Sendov/FiniteRange/Degree10_11.lean +++ b/Sendov/FiniteRange/Degree10_11.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 10 to 11 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 5) : have hu : (0 : ℝ) ≤ 5 - α := by linarith have hid : (5 : ℝ) ^ 8 * (32349375 + 39180105 * α + 10086687 * α ^ 2 - 24445935 * α ^ 3 + 11871036 * α ^ 4 - 351846 * α ^ 5 - 81598 * α ^ 6 - 4664 * α ^ 7 - 88 * α ^ 8) = 32349375 * (5 - α) ^ 8 + 454695525 * α ^ 1 * (5 - α) ^ 7 + 2529253350 * α ^ 2 * (5 - α) ^ 6 + 4382737200 * α ^ 3 * (5 - α) ^ 5 + 5044170375 * α ^ 4 * (5 - α) ^ 4 + 11732079375 * α ^ 5 * (5 - α) ^ 3 + 18187642400 * α ^ 6 * (5 - α) ^ 2 + 11329113600 * α ^ 7 * (5 - α) ^ 1 + 2070835200 * α ^ 8 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (5 : ℝ) ^ 8)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 5 - α := by linarith - positivity + bernstein_cert α (5 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 10 ≤ n) (h1 : n ≤ 11) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (32349375 + 39180105 * α + 10086687 * α ^ 2 - 24445935 * α ^ 3 + 11871036 * α ^ 4 - 351846 * α ^ 5 - 81598 * α ^ 6 - 4664 * α ^ 7 - 88 * α ^ 8) / (680400 * (3 + α) ^ 4) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B10_11 diff --git a/Sendov/FiniteRange/Degree12_13.lean b/Sendov/FiniteRange/Degree12_13.lean index ba5f96e..d60bf3d 100644 --- a/Sendov/FiniteRange/Degree12_13.lean +++ b/Sendov/FiniteRange/Degree12_13.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 12 to 13 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 6) : have hu : (0 : ℝ) ≤ 6 - α := by linarith have hid : (6 : ℝ) ^ 10 * (67214552328 + 108758874312 * α + 64248083658 * α ^ 2 + 8893434528 * α ^ 3 - 26471207052 * α ^ 4 + 9402730740 * α ^ 5 - 77587159 * α ^ 6 - 46242248 * α ^ 7 - 3634800 * α ^ 8 - 118976 * α ^ 9 - 1456 * α ^ 10) = 67214552328 * (6 - α) ^ 10 + 1324698769152 * α ^ 1 * (6 - α) ^ 9 + 11210565079296 * α ^ 2 * (6 - α) ^ 8 + 51982093082304 * α ^ 3 * (6 - α) ^ 7 + 112831785636336 * α ^ 4 * (6 - α) ^ 6 + 136300060037952 * α ^ 5 * (6 - α) ^ 5 + 172834300408608 * α ^ 6 * (6 - α) ^ 4 + 277236880276032 * α ^ 7 * (6 - α) ^ 3 + 281516219316936 * α ^ 8 * (6 - α) ^ 2 + 131510134768320 * α ^ 9 * (6 - α) ^ 1 + 19805743188000 * α ^ 10 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (6 : ℝ) ^ 10)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 6 - α := by linarith - positivity + bernstein_cert α (6 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 12 ≤ n) (h1 : n ≤ 13) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (67214552328 + 108758874312 * α + 64248083658 * α ^ 2 + 8893434528 * α ^ 3 - 26471207052 * α ^ 4 + 9402730740 * α ^ 5 - 77587159 * α ^ 6 - 46242248 * α ^ 7 - 3634800 * α ^ 8 - 118976 * α ^ 9 - 1456 * α ^ 10) / (442743840 * (3 + α) ^ 5) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B12_13 diff --git a/Sendov/FiniteRange/Degree14_15.lean b/Sendov/FiniteRange/Degree14_15.lean index 86f5a93..1cebbe2 100644 --- a/Sendov/FiniteRange/Degree14_15.lean +++ b/Sendov/FiniteRange/Degree14_15.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 14 to 15 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 7) : have hu : (0 : ℝ) ≤ 7 - α := by linarith have hid : (7 : ℝ) ^ 12 * (4540012290450 + 9000770719122 * α + 7217967952260 * α ^ 2 + 2789503991820 * α ^ 3 + 226924812075 * α ^ 4 - 867448623285 * α ^ 5 + 235182487819 * α ^ 6 + 1315276135 * α ^ 7 - 765536900 * α ^ 8 - 78585080 * α ^ 9 - 3463520 * α ^ 10 - 74480 * α ^ 11 - 640 * α ^ 12) = 4540012290450 * (7 - α) ^ 12 + 117485542519254 * α ^ 1 * (7 - α) ^ 11 + 1346380586202834 * α ^ 2 * (7 - α) ^ 10 + 8957703596562630 * α ^ 3 * (7 - α) ^ 9 + 37714860895632375 * α ^ 4 * (7 - α) ^ 8 + 91053479724275985 * α ^ 5 * (7 - α) ^ 7 + 128817765797828254 * α ^ 6 * (7 - α) ^ 6 + 133833540832996984 * α ^ 7 * (7 - α) ^ 5 + 161773229978174745 * α ^ 8 * (7 - α) ^ 4 + 197834312331965435 * α ^ 9 * (7 - α) ^ 3 + 152113356071582990 * α ^ 10 * (7 - α) ^ 2 + 57359456154000000 * α ^ 11 * (7 - α) ^ 1 + 7376986416800000 * α ^ 12 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (7 : ℝ) ^ 12)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 7 - α := by linarith - positivity + bernstein_cert α (7 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 14 ≤ n) (h1 : n ≤ 15) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (4540012290450 + 9000770719122 * α + 7217967952260 * α ^ 2 + 2789503991820 * α ^ 3 + 226924812075 * α ^ 4 - 867448623285 * α ^ 5 + 235182487819 * α ^ 6 + 1315276135 * α ^ 7 - 765536900 * α ^ 8 - 78585080 * α ^ 9 - 3463520 * α ^ 10 - 74480 * α ^ 11 - 640 * α ^ 12) / (9606092496 * (3 + α) ^ 6) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B14_15 diff --git a/Sendov/FiniteRange/Degree16_18.lean b/Sendov/FiniteRange/Degree16_18.lean index 133a663..12b1df3 100644 --- a/Sendov/FiniteRange/Degree16_18.lean +++ b/Sendov/FiniteRange/Degree16_18.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 16 to 18 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17 / 2) : have hu : (0 : ℝ) ≤ 17 - 2 * α := by linarith have hid : (17 : ℝ) ^ 14 * (308547940078125 + 716274580556250 * α + 701075142421875 * α ^ 2 + 366034929547500 * α ^ 3 + 98713082723625 * α ^ 4 - 785317395690 * α ^ 5 - 34202916258669 * α ^ 6 + 6366700041480 * α ^ 7 + 121732471512 * α ^ 8 - 9494954208 * α ^ 9 - 1551607200 * α ^ 10 - 87661568 * α ^ 11 - 2586240 * α ^ 12 - 39936 * α ^ 13 - 256 * α ^ 14) = 308547940078125 * (17 - 2 * α) ^ 14 + 20816010191643750 * α ^ 1 * (17 - 2 * α) ^ 13 + 631515530954221875 * α ^ 2 * (17 - 2 * α) ^ 12 + 11358598773482842500 * α ^ 3 * (17 - 2 * α) ^ 11 + 134099015737057493625 * α ^ 4 * (17 - 2 * α) ^ 10 + 1075072539293623306170 * α ^ 5 * (17 - 2 * α) ^ 9 + 5177641117293101872899 * α ^ 6 * (17 - 2 * α) ^ 8 + 13260545037504883513944 * α ^ 7 * (17 - 2 * α) ^ 7 + 13392270163441462237560 * α ^ 8 * (17 - 2 * α) ^ 6 + 934363054464939802080 * α ^ 9 * (17 - 2 * α) ^ 5 + 56141276222621229749280 * α ^ 10 * (17 - 2 * α) ^ 4 + 269593608305522330908544 * α ^ 11 * (17 - 2 * α) ^ 3 + 451523429099140347738624 * α ^ 12 * (17 - 2 * α) ^ 2 + 320966535936278232000000 * α ^ 13 * (17 - 2 * α) ^ 1 + 72913603873782672000000 * α ^ 14 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 14)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - 2 * α := by linarith - positivity + bernstein_cert α (17 - 2 * α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 16 ≤ n) (h1 : n ≤ 18) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (308547940078125 + 716274580556250 * α + 701075142421875 * α ^ 2 + 366034929547500 * α ^ 3 + 98713082723625 * α ^ 4 - 785317395690 * α ^ 5 - 34202916258669 * α ^ 6 + 6366700041480 * α ^ 7 + 121732471512 * α ^ 8 - 9494954208 * α ^ 9 - 1551607200 * α ^ 10 - 87661568 * α ^ 11 - 2586240 * α ^ 12 - 39936 * α ^ 13 - 256 * α ^ 14) / (215371406250 * (3 + α) ^ 7) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B16_18 diff --git a/Sendov/FiniteRange/Degree18_20.lean b/Sendov/FiniteRange/Degree18_20.lean index ecf63f3..2682467 100644 --- a/Sendov/FiniteRange/Degree18_20.lean +++ b/Sendov/FiniteRange/Degree18_20.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 18 to 20 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 19 / 2) : have hu : (0 : ℝ) ≤ 19 - 2 * α := by linarith have hid : (19 : ℝ) ^ 16 * (1996938880799635773 + 5327542416376042533 * α + 6168567333266685756 * α ^ 2 + 4015726419901684032 * α ^ 3 + 1568562341575363317 * α ^ 4 + 336439630979056719 * α ^ 5 - 5059047712773960 * α ^ 6 - 94154641040290584 * α ^ 7 + 14305270642714822 * α ^ 8 + 337895936432856 * α ^ 9 - 7990669279488 * α ^ 10 - 2592154628256 * α ^ 11 - 177335477376 * α ^ 12 - 6421337472 * α ^ 13 - 134803968 * α ^ 14 - 1555968 * α ^ 15 - 7680 * α ^ 16) = 1996938880799635773 * (19 - 2 * α) ^ 16 + 165125350096733152863 * α ^ 1 * (19 - 2 * α) ^ 15 + 6222082647427442972766 * α ^ 2 * (19 - 2 * α) ^ 14 + 141355820787428498073516 * α ^ 3 * (19 - 2 * α) ^ 13 + 2157735283869217913370909 * α ^ 4 * (19 - 2 * α) ^ 12 + 23307179713209861652797525 * α ^ 5 * (19 - 2 * α) ^ 11 + 181491504176132704398182238 * α ^ 6 * (19 - 2 * α) ^ 10 + 947234591820259386271884708 * α ^ 7 * (19 - 2 * α) ^ 9 + 3056114849066116568052366478 * α ^ 8 * (19 - 2 * α) ^ 8 + 5409419472435810969555104008 * α ^ 9 * (19 - 2 * α) ^ 7 + 3773674627041183640344074704 * α ^ 10 * (19 - 2 * α) ^ 6 + 2563877062588931411214853312 * α ^ 11 * (19 - 2 * α) ^ 5 + 27502208508532453123433891776 * α ^ 12 * (19 - 2 * α) ^ 4 + 85133541744770676359382205696 * α ^ 13 * (19 - 2 * α) ^ 3 + 113617195875176526046213373440 * α ^ 14 * (19 - 2 * α) ^ 2 + 68841959775014032750000000000 * α ^ 15 * (19 - 2 * α) ^ 1 + 13908254927398975000000000000 * α ^ 16 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (19 : ℝ) ^ 16)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 19 - 2 * α := by linarith - positivity + bernstein_cert α (19 - 2 * α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 18 ≤ n) (h1 : n ≤ 20) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (1996938880799635773 + 5327542416376042533 * α + 6168567333266685756 * α ^ 2 + 4015726419901684032 * α ^ 3 + 1568562341575363317 * α ^ 4 + 336439630979056719 * α ^ 5 - 5059047712773960 * α ^ 6 - 94154641040290584 * α ^ 7 + 14305270642714822 * α ^ 8 + 337895936432856 * α ^ 9 - 7990669279488 * α ^ 10 - 2592154628256 * α ^ 11 - 177335477376 * α ^ 12 - 6421337472 * α ^ 13 - 134803968 * α ^ 14 - 1555968 * α ^ 15 - 7680 * α ^ 16) / (454875191212728 * (3 + α) ^ 8) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B18_20 diff --git a/Sendov/FiniteRange/Degree20.lean b/Sendov/FiniteRange/Degree20.lean index 830169b..164bb8c 100644 --- a/Sendov/FiniteRange/Degree20.lean +++ b/Sendov/FiniteRange/Degree20.lean @@ -58,33 +58,16 @@ lemma P_twenty_pos (hα : 0 ≤ α) (hle : α ≤ 19 / 2) : 11 - 847605280292160 * α ^ 12 - 61937116512768 * α ^ 13 - 2508597900288 * α ^ 14 - 62979502080 * α ^ 15 - 979335936 * α ^ 16 - 8690688 * α ^ 17 - 33792 * α ^ 18 := by have hu : (0 : ℝ) ≤ 19 - 2 * α := by linarith - have h0 : (0:ℝ) ≤ 2428684725423666483774 * (19 - 2 * α) ^ 18 := by positivity - have h1 : (0:ℝ) ≤ 226730525571039907134432 * α ^ 1 * (19 - 2 * α) ^ 17 := by positivity - have h2 : (0:ℝ) ≤ 9762590243023517445883524 * α ^ 2 * (19 - 2 * α) ^ 16 := by positivity - have h3 : (0:ℝ) ≤ 257123733807820195223425224 * α ^ 3 * (19 - 2 * α) ^ 15 := by positivity - have h4 : (0:ℝ) ≤ 4632014993012551188816601077 * α ^ 4 * (19 - 2 * α) ^ 14 := by positivity - have h5 : (0:ℝ) ≤ 60459331875837108393876395364 * α ^ 5 * (19 - 2 * α) ^ 13 := by positivity - have h6 : (0:ℝ) ≤ 590623191218980187440834237938 * α ^ 6 * (19 - 2 * α) ^ 12 := by positivity - have h7 : (0:ℝ) ≤ 4389613323288949613610408693204 * α ^ 7 * (19 - 2 * α) ^ 11 := by positivity - have h8 : (0:ℝ) ≤ 24480093296536555966858990491717 * α ^ 8 * (19 - 2 * α) ^ 10 := by positivity - have h9 : (0:ℝ) ≤ 100744503274528106203930847272696 * α ^ 9 * (19 - 2 * α) ^ 9 := by positivity - have h10 : (0:ℝ) ≤ 306223243964547514886419597653624 * α ^ 10 * (19 - 2 * α) ^ 8 := by positivity - have h11 : (0:ℝ) ≤ 708731127961028987356988552204352 * α ^ 11 * (19 - 2 * α) ^ 7 := by positivity - have h12 : (0:ℝ) ≤ 1342727866428363194166781707341088 * α ^ 12 * (19 - 2 * α) ^ 6 := by positivity - have h13 : (0:ℝ) ≤ 2273564082246386518492641655978752 * α ^ 13 * (19 - 2 * α) ^ 5 := by positivity - have h14 : (0:ℝ) ≤ 3442867955253474296197691549373696 * α ^ 14 * (19 - 2 * α) ^ 4 := by positivity - have h15 : (0:ℝ) ≤ 4130621657305785039523793191219200 * α ^ 15 * (19 - 2 * α) ^ 3 := by positivity - have h16 : (0:ℝ) ≤ 3349606068894706620649142246807040 * α ^ 16 * (19 - 2 * α) ^ 2 := by positivity - have h17 : (0:ℝ) ≤ 1529243641677728878687500000000000 * α ^ 17 * (19 - 2 * α) ^ 1 := by positivity - have h18 : (0:ℝ) ≤ 274558827655262150000000000000000 * α ^ 18 := by positivity - have hid : (19 : ℝ) ^ 18 * ( 2428684725423666483774 + 7331467129251995458872 * α + 9806391760574638480284 * α ^ 2 + + have hid : (19 : ℝ) ^ 18 * + (2428684725423666483774 + 7331467129251995458872 * α + 9806391760574638480284 * α ^ 2 + 7611575747798170524888 * α ^ 3 + 3758723770378675135797 * α ^ 4 + 1206125979814312523496 * α ^ 5 + 235504051379657180694 * α ^ 6 + 11454730616615814828 * α ^ 7 - 32607895082957507571 * α ^ 8 + 5227920728232680812 * α ^ 9 + 102472476340054572 * α ^ 10 - 2640164743526400 * α ^ 11 - 847605280292160 * α ^ 12 - 61937116512768 * α ^ 13 - 2508597900288 * α ^ 14 - 62979502080 * α ^ 15 - 979335936 * α ^ 16 - 8690688 * α ^ 17 - 33792 * α ^ 18) - = 2428684725423666483774 * (19 - 2 * α) ^ 18 + 226730525571039907134432 * α ^ 1 * (19 - 2 * + = 2428684725423666483774 * (19 - 2 * α) ^ 18 + + 226730525571039907134432 * α ^ 1 * (19 - 2 * α) ^ 17 + 9762590243023517445883524 * α ^ 2 * (19 - 2 * α) ^ 16 + 257123733807820195223425224 * α ^ 3 * (19 - 2 * α) ^ 15 + 4632014993012551188816601077 * α ^ 4 * (19 - 2 * α) ^ 14 + 60459331875837108393876395364 * α ^ 5 * (19 - 2 * α) ^ 13 + @@ -102,13 +85,13 @@ lemma P_twenty_pos (hα : 0 ≤ α) (hle : α ≤ 19 / 2) : 1529243641677728878687500000000000 * α ^ 17 * (19 - 2 * α) ^ 1 + 274558827655262150000000000000000 * α ^ 18 := by ring - rcases le_total α (19 / 4) with h | h - · have hpos : (0 : ℝ) < 2428684725423666483774 * (19 - 2 * α) ^ 18 := - mul_pos (by norm_num) (pow_pos (by linarith) 18) - linarith - · have hpos : (0 : ℝ) < 274558827655262150000000000000000 * α ^ 18 := - mul_pos (by norm_num) (pow_pos (by linarith) 18) - linarith + -- The last Bernstein term is positive away from zero; the first handles zero. + apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < 19 ^ 18)).mp + rw [hid] + rcases lt_or_eq_of_le hα with hpos | hzero + · positivity + · subst α + norm_num /-- The upper bound for `R 20 α`, from the general moment formula with `k = 8`. -/ lemma R_twenty_le (hα : 0 ≤ α) : @@ -133,7 +116,8 @@ theorem finite_range_twenty (hα : 0 ≤ α) (hfeas : c 20 α ^ 2 ≤ A 20 α) : have hR := R_twenty_le hα have hid : 1 / 6 + 1 / (4 * (3 + α)) + 1 / 38 + 1 / (76 * (3 + α)) + 1710 * A 20 α ^ 2 / (3 + α) * mom 20 α 8 - = 1 - ( 2428684725423666483774 + 7331467129251995458872 * α + 9806391760574638480284 * α ^ 2 + + = 1 - + (2428684725423666483774 + 7331467129251995458872 * α + 9806391760574638480284 * α ^ 2 + 7611575747798170524888 * α ^ 3 + 3758723770378675135797 * α ^ 4 + 1206125979814312523496 * α ^ 5 + 235504051379657180694 * α ^ 6 + 11454730616615814828 * α ^ 7 - 32607895082957507571 * α ^ 8 + 5227920728232680812 * α ^ 9 + 102472476340054572 * α ^ 10 @@ -148,14 +132,6 @@ theorem finite_range_twenty (hα : 0 ≤ α) (hfeas : c 20 α ^ 2 ≤ A 20 α) : ring rw [hid] at hR have hP := P_twenty_pos hα hle - have hq : 0 < ( 2428684725423666483774 + 7331467129251995458872 * α + 9806391760574638480284 * α ^ 2 + - 7611575747798170524888 * α ^ 3 + 3758723770378675135797 * α ^ 4 + 1206125979814312523496 * - α ^ 5 + 235504051379657180694 * α ^ 6 + 11454730616615814828 * α ^ 7 - - 32607895082957507571 * α ^ 8 + 5227920728232680812 * α ^ 9 + 102472476340054572 * α ^ 10 - - 2640164743526400 * α ^ 11 - 847605280292160 * α ^ 12 - 61937116512768 * α ^ 13 - - 2508597900288 * α ^ 14 - 62979502080 * α ^ 15 - 979335936 * α ^ 16 - 8690688 * α ^ 17 - - 33792 * α ^ 18) - / (178855464872570772 * (3 + α) ^ 9) := div_pos hP (by positivity) - linarith + exact hR.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end Sendov diff --git a/Sendov/FiniteRange/Degree20Packed.lean b/Sendov/FiniteRange/Degree20Packed.lean index d0dc02c..a617063 100644 --- a/Sendov/FiniteRange/Degree20Packed.lean +++ b/Sendov/FiniteRange/Degree20Packed.lean @@ -40,24 +40,24 @@ integer exponentiation and seventeen digit extractions. -/ theorem Nmom20_eq : Nmom20 = wsum L20 0 (qrow (gg0 20) (gg1 20) (gg2 20) 8) := by refine wsum_eq_of_packed (gg0 20) (gg1 20) (gg2 20) 8 L20 beta20 tau20 Nmom20 - (by norm_num [beta20]) (by norm_num [tau20]) ?_ ?_ ?_ ?_ ?_ - · decide - · decide - · decide - · rfl - · rfl + (by decide) (by decide) ?_ ?_ ?_ ?_ ?_ + · decide -- No overflow when packing the row in τ. + · decide -- The supplied numerator coefficients fit in β. + · decide -- The computed weighted sum also fits in β. + · rfl -- The two coefficient lists have the same length. + · rfl -- Exact packed integer equality. /-- The degree-twenty moment, via the packed route. -/ theorem integral_twenty_packed (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 20 α t ^ 8) = pev Nmom20 α / ((L20 : ℝ) * (2 * M 20 * (3 + α)) ^ 8) := - integral_moment_packed 20 8 (by norm_num) α hα L20 (by norm_num [L20]) Nmom20 + integral_moment_packed 20 8 (by norm_num) α hα L20 (by decide) Nmom20 (by decide) (by rw [Nmom20_eq]) /-- **The cross-check.** The multinomial formula and the packed recurrence agree. Neither side is expanded: both compute the same integral, so they are equal by transitivity. -/ theorem packed_agrees_twenty (α : ℝ) (hα : 0 ≤ α) : pev Nmom20 α / ((L20 : ℝ) * (2 * M 20 * (3 + α)) ^ 8) = mom 20 α 8 := by - rw [← integral_twenty_packed α hα, integral_moment] + exact (integral_twenty_packed α hα).symm.trans (integral_moment 20 α 8) end Sendov diff --git a/Sendov/FiniteRange/Degree20_22.lean b/Sendov/FiniteRange/Degree20_22.lean index 7c09215..3b02309 100644 --- a/Sendov/FiniteRange/Degree20_22.lean +++ b/Sendov/FiniteRange/Degree20_22.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 20 to 22 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 21 / 2) : have hu : (0 : ℝ) ≤ 21 - 2 * α := by linarith have hid : (21 : ℝ) ^ 18 * (721140310389707127738 + 2170180610909239016088 * α + 2889750967198268814324 * α ^ 2 + 2227128338977232972904 * α ^ 3 + 1085997068794302710391 * α ^ 4 + 339049376116278228288 * α ^ 5 + 60509700204282383346 * α ^ 6 - 1038039442012938636 * α ^ 7 - 14060791839010189905 * α ^ 8 + 1774506642858471852 * α ^ 9 + 45855210342618468 * α ^ 10 + 226538249017920 * α ^ 11 - 222291771124416 * α ^ 12 - 18538380993792 * α ^ 13 - 787852835840 * α ^ 14 - 20286313472 * α ^ 15 - 320448768 * α ^ 16 - 2874368 * α ^ 17 - 11264 * α ^ 18) = 721140310389707127738 * (21 - 2 * α) ^ 18 + 71534844003123475936416 * α ^ 1 * (21 - 2 * α) ^ 17 + 3265227002682133966779372 * α ^ 2 * (21 - 2 * α) ^ 16 + 90905348441621278719467208 * α ^ 3 * (21 - 2 * α) ^ 15 + 1724899809677710491069520311 * α ^ 4 * (21 - 2 * α) ^ 14 + 23603549699659251265167149604 * α ^ 5 * (21 - 2 * α) ^ 13 + 240138761499155563910895585654 * α ^ 6 * (21 - 2 * α) ^ 12 + 1837366344267267569709080196468 * α ^ 7 * (21 - 2 * α) ^ 11 + 10104702475479597929008103413095 * α ^ 8 * (21 - 2 * α) ^ 10 + 37641802639366180553916149163576 * α ^ 9 * (21 - 2 * α) ^ 9 + 88449061215859475411346373536264 * α ^ 10 * (21 - 2 * α) ^ 8 + 113640861426905556745222707601920 * α ^ 11 * (21 - 2 * α) ^ 7 + 55669273871103476657042199021792 * α ^ 12 * (21 - 2 * α) ^ 6 + 99281941699214882417362945572096 * α ^ 13 * (21 - 2 * α) ^ 5 + 654986082897929475911576119281408 * α ^ 14 * (21 - 2 * α) ^ 4 + 1538940561324052318678745687107584 * α ^ 15 * (21 - 2 * α) ^ 3 + 1719020178639381082845279983473152 * α ^ 16 * (21 - 2 * α) ^ 2 + 910135906460129539245476343896064 * α ^ 17 * (21 - 2 * α) ^ 1 + 165769381149578270034391223083008 * α ^ 18 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (21 : ℝ) ^ 18)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 21 - 2 * α := by linarith - positivity + bernstein_cert α (21 - 2 * α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 20 ≤ n) (h1 : n ≤ 22) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (721140310389707127738 + 2170180610909239016088 * α + 2889750967198268814324 * α ^ 2 + 2227128338977232972904 * α ^ 3 + 1085997068794302710391 * α ^ 4 + 339049376116278228288 * α ^ 5 + 60509700204282383346 * α ^ 6 - 1038039442012938636 * α ^ 7 - 14060791839010189905 * α ^ 8 + 1774506642858471852 * α ^ 9 + 45855210342618468 * α ^ 10 + 226538249017920 * α ^ 11 - 222291771124416 * α ^ 12 - 18538380993792 * α ^ 13 - 787852835840 * α ^ 14 - 20286313472 * α ^ 15 - 320448768 * α ^ 16 - 2874368 * α ^ 17 - 11264 * α ^ 18) / (53913369794124204 * (3 + α) ^ 9) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B20_22 diff --git a/Sendov/FiniteRange/Degree22_24.lean b/Sendov/FiniteRange/Degree22_24.lean index 2a2e9ad..3a7590a 100644 --- a/Sendov/FiniteRange/Degree22_24.lean +++ b/Sendov/FiniteRange/Degree22_24.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 22 to 24 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 23 / 2) : have hu : (0 : ℝ) ≤ 23 - 2 * α := by linarith have hid : (23 : ℝ) ^ 20 * (72676691260477709153931 + 243335498910644300539743 * α + 365647629606098581621152 * α ^ 2 + 324203560761134112575706 * α ^ 3 + 187220150267586036026391 * α ^ 4 + 72995868351568741088853 * α ^ 5 + 18997181712653091143742 * α ^ 6 + 2912276075526675669294 * α ^ 7 - 47524187765551795452 * α ^ 8 - 572344038827543054862 * α ^ 9 + 60958599043408078986 * α ^ 10 + 1608150216459380292 * α ^ 11 + 37160884428953616 * α ^ 12 - 4770728942909184 * α ^ 13 - 508194774105984 * α ^ 14 - 24843494479104 * α ^ 15 - 745526594304 * α ^ 16 - 14490071808 * α ^ 17 - 179034112 * α ^ 18 - 1285120 * α ^ 19 - 4096 * α ^ 20) = 72676691260477709153931 * (23 - 2 * α) ^ 20 + 8503784125363927278571329 * α ^ 1 * (23 - 2 * α) ^ 19 + 461337107467492327306312350 * α ^ 2 * (23 - 2 * α) ^ 18 + 15398943675157072979676921186 * α ^ 3 * (23 - 2 * α) ^ 17 + 353905086689575653155085657243 * α ^ 4 * (23 - 2 * α) ^ 16 + 5938058763785413089179396251875 * α ^ 5 * (23 - 2 * α) ^ 15 + 75246714147642299181739714271832 * α ^ 6 * (23 - 2 * α) ^ 14 + 734384442923791787182437424591542 * α ^ 7 * (23 - 2 * α) ^ 13 + 5562914983973677901584481691318984 * α ^ 8 * (23 - 2 * α) ^ 12 + 31773805113877239761694178561183806 * α ^ 9 * (23 - 2 * α) ^ 11 + 130856587563539007907893649077192702 * α ^ 10 * (23 - 2 * α) ^ 10 + 369427721563914607645637465073374604 * α ^ 11 * (23 - 2 * α) ^ 9 + 659851634553627022861170989844737856 * α ^ 12 * (23 - 2 * α) ^ 8 + 615817039503279914009940077569822464 * α ^ 13 * (23 - 2 * α) ^ 7 + 195270527269368587749778342774288064 * α ^ 14 * (23 - 2 * α) ^ 6 + 857988173853242270013037467185126784 * α ^ 15 * (23 - 2 * α) ^ 5 + 4220624235641254987215180793015588608 * α ^ 16 * (23 - 2 * α) ^ 4 + 8094967304722603824961003917794419968 * α ^ 17 * (23 - 2 * α) ^ 3 + 7807057971748984716263131834792835072 * α ^ 18 * (23 - 2 * α) ^ 2 + 3677240872883486972453388075862686720 * α ^ 19 * (23 - 2 * α) ^ 1 + 610286593660503076943530707277762560 * α ^ 20 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (23 : ℝ) ^ 20)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 23 - 2 * α := by linarith - positivity + bernstein_cert α (23 - 2 * α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 22 ≤ n) (h1 : n ≤ 24) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (72676691260477709153931 + 243335498910644300539743 * α + 365647629606098581621152 * α ^ 2 + 324203560761134112575706 * α ^ 3 + 187220150267586036026391 * α ^ 4 + 72995868351568741088853 * α ^ 5 + 18997181712653091143742 * α ^ 6 + 2912276075526675669294 * α ^ 7 - 47524187765551795452 * α ^ 8 - 572344038827543054862 * α ^ 9 + 60958599043408078986 * α ^ 10 + 1608150216459380292 * α ^ 11 + 37160884428953616 * α ^ 12 - 4770728942909184 * α ^ 13 - 508194774105984 * α ^ 14 - 24843494479104 * α ^ 15 - 745526594304 * α ^ 16 - 14490071808 * α ^ 17 - 179034112 * α ^ 18 - 1285120 * α ^ 19 - 4096 * α ^ 20) / (1789880961368575530 * (3 + α) ^ 10) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B22_24 diff --git a/Sendov/FiniteRange/Degree24_26.lean b/Sendov/FiniteRange/Degree24_26.lean index 99b1625..798825d 100644 --- a/Sendov/FiniteRange/Degree24_26.lean +++ b/Sendov/FiniteRange/Degree24_26.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 24 to 26 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 25 / 2) : have hu : (0 : ℝ) ≤ 25 - 2 * α := by linarith have hid : (25 : ℝ) ^ 22 * (874071004010582953643568750 + 3221297610086019399669004500 * α + 5386914463346812349691460974 * α ^ 2 + 5391225879978445091101054368 * α ^ 3 + 3582299145670361769507272658 * α ^ 4 + 1654127651781089540379647100 * α ^ 5 + 537462463626302644652842710 * α ^ 6 + 120043033655516749475390448 * α ^ 7 + 16184849120135434020794931 * α ^ 8 - 222784389930881498880726 * α ^ 9 - 2725770297915674501126913 * α ^ 10 + 248640476833385673099320 * α ^ 11 + 6386094327528944247792 * α ^ 12 + 230085309479261626272 * α ^ 13 - 10099884196228450032 * α ^ 14 - 1569527054513950464 * α ^ 15 - 87896838917715456 * α ^ 16 - 2989402709094912 * α ^ 17 - 67703370254592 * α ^ 18 - 1033617561600 * α ^ 19 - 10281172992 * α ^ 20 - 60432384 * α ^ 21 - 159744 * α ^ 22) = 874071004010582953643568750 * (25 - 2 * α) ^ 22 + 118991564428616134952042137500 * α ^ 1 * (25 - 2 * α) ^ 21 + 7556825637887856737376275358750 * α ^ 2 * (25 - 2 * α) ^ 20 + 297326570539550302672678360350000 * α ^ 3 * (25 - 2 * α) ^ 19 + 8118326774696702494364871859181250 * α ^ 4 * (25 - 2 * α) ^ 18 + 163302166743534227801697447509662500 * α ^ 5 * (25 - 2 * α) ^ 17 + 2507454163520304052153861436880993750 * α ^ 6 * (25 - 2 * α) ^ 16 + 30047259752690844282111594563558670000 * α ^ 7 * (25 - 2 * α) ^ 15 + 284787676890052141286070572033915521875 * α ^ 8 * (25 - 2 * α) ^ 14 + 2146769361227978442422195176181338368750 * α ^ 9 * (25 - 2 * α) ^ 13 + 12630679896438305929175193655858187184375 * α ^ 10 * (25 - 2 * α) ^ 12 + 56067735566028501096437207497525020350000 * α ^ 11 * (25 - 2 * α) ^ 11 + 180631480948809558078622444236010586285000 * α ^ 12 * (25 - 2 * α) ^ 10 + 400779538225462244119560623305257108200000 * α ^ 13 * (25 - 2 * α) ^ 9 + 552145957044674175745646853887912448300000 * α ^ 14 * (25 - 2 * α) ^ 8 + 348851941562555217823842842079415684800000 * α ^ 15 * (25 - 2 * α) ^ 7 + 38623525300380552283361811907759716000000 * α ^ 16 * (25 - 2 * α) ^ 6 + 822237191651812497627267691867773310080000 * α ^ 17 * (25 - 2 * α) ^ 5 + 3269244329154715153428677298597459316800000 * α ^ 18 * (25 - 2 * α) ^ 4 + 5333912969812883272270527401813990707200000 * α ^ 19 * (25 - 2 * α) ^ 3 + 4537960847197188659144322307990683712000000 * α ^ 20 * (25 - 2 * α) ^ 2 + 1927546466544754214336332480358954905600000 * α ^ 21 * (25 - 2 * α) ^ 1 + 294013599962108674661431900766763888640000 * α ^ 22 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (25 : ℝ) ^ 22)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 25 - 2 * α := by linarith - positivity + bernstein_cert α (25 - 2 * α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 24 ≤ n) (h1 : n ≤ 26) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (874071004010582953643568750 + 3221297610086019399669004500 * α + 5386914463346812349691460974 * α ^ 2 + 5391225879978445091101054368 * α ^ 3 + 3582299145670361769507272658 * α ^ 4 + 1654127651781089540379647100 * α ^ 5 + 537462463626302644652842710 * α ^ 6 + 120043033655516749475390448 * α ^ 7 + 16184849120135434020794931 * α ^ 8 - 222784389930881498880726 * α ^ 9 - 2725770297915674501126913 * α ^ 10 + 248640476833385673099320 * α ^ 11 + 6386094327528944247792 * α ^ 12 + 230085309479261626272 * α ^ 13 - 10099884196228450032 * α ^ 14 - 1569527054513950464 * α ^ 15 - 87896838917715456 * α ^ 16 - 2989402709094912 * α ^ 17 - 67703370254592 * α ^ 18 - 1033617561600 * α ^ 19 - 10281172992 * α ^ 20 - 60432384 * α ^ 21 - 159744 * α ^ 22) / (7109199446723183525100 * (3 + α) ^ 11) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B24_26 diff --git a/Sendov/FiniteRange/Degree26_27.lean b/Sendov/FiniteRange/Degree26_27.lean index 240f9fc..947edd5 100644 --- a/Sendov/FiniteRange/Degree26_27.lean +++ b/Sendov/FiniteRange/Degree26_27.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 26 to 27 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 13) : have hu : (0 : ℝ) ≤ 13 - α := by linarith have hid : (13 : ℝ) ^ 24 * (750669183453805732727050781250 + 3020533706655215263366699218750 * α + 5564839729610338783264160156250 * α ^ 2 + 6204652935907732786560058593750 * α ^ 3 + 4659850847351595430480957031250 * α ^ 4 + 2480313988118708551463378906250 * α ^ 5 + 956953438533800725637460937500 * α ^ 6 + 267988469385291406396875000000 * α ^ 7 + 53061280626889862612388984375 * α ^ 8 + 6649776660279075672227540625 * α ^ 9 + 67029306131497703210255025 * α ^ 10 - 797547671168471728584421521 * α ^ 11 + 69793209950586805764791132 * α ^ 12 + 1582701213221515173844854 * α ^ 13 + 64909025019891545058702 * α ^ 14 - 1621590589357829572680 * α ^ 15 - 347824272218530328424 * α ^ 16 - 21365270620680629952 * α ^ 17 - 794207858493279744 * α ^ 18 - 20077534583212032 * α ^ 19 - 355351304655360 * α ^ 20 - 4364532094464 * α ^ 21 - 35609836032 * α ^ 22 - 174127104 * α ^ 23 - 387072 * α ^ 24) = 750669183453805732727050781250 * (13 - α) ^ 24 + 57282998589409136009216308593750 * α ^ 1 * (13 - α) ^ 23 + 2050782187227307000350952148437500 * α ^ 2 * (13 - α) ^ 22 + 45775586403380034332501220703125000 * α ^ 3 * (13 - α) ^ 21 + 714118209031145161147786743164062500 * α ^ 4 * (13 - α) ^ 20 + 8273284316298011107371657322265625000 * α ^ 5 * (13 - α) ^ 19 + 73835510530487101104526833122402343750 * α ^ 6 * (13 - α) ^ 18 + 519733885027019750587474273435957031250 * α ^ 7 * (13 - α) ^ 17 + 2930800059791589030908400058323199921875 * α ^ 8 * (13 - α) ^ 16 + 13372402464675670629912241174388163590625 * α ^ 9 * (13 - α) ^ 15 + 49616523603298906478895841666067082338100 * α ^ 10 * (13 - α) ^ 14 + 148533037390768639293168587946346173784998 * α ^ 11 * (13 - α) ^ 13 + 352390650499030404141412366217263718435741 * α ^ 12 * (13 - α) ^ 12 + 649782112359758546338767005837625709617885 * α ^ 13 * (13 - α) ^ 11 + 915968039619170700348192462171799252793910 * α ^ 14 * (13 - α) ^ 10 + 976506256524831093733472748853893192499190 * α ^ 15 * (13 - α) ^ 9 + 793928461670457408996135461409947476637907 * α ^ 16 * (13 - α) ^ 8 + 532094243038671655145113443710174863949229 * α ^ 17 * (13 - α) ^ 7 + 362157082250568977592235276631536616142420 * α ^ 18 * (13 - α) ^ 6 + 282315964683600802659165217851025305107370 * α ^ 19 * (13 - α) ^ 5 + 202899768509895477280344720514446057053655 * α ^ 20 * (13 - α) ^ 4 + 106150121400148174823355428864276604237047 * α ^ 21 * (13 - α) ^ 3 + 35288625801200476947393636186470118639744 * α ^ 22 * (13 - α) ^ 2 + 6423617838051124838400000000000000000000 * α ^ 23 * (13 - α) ^ 1 + 451304798929131929600000000000000000000 * α ^ 24 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (13 : ℝ) ^ 24)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 13 - α := by linarith - positivity + bernstein_cert α (13 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 26 ≤ n) (h1 : n ≤ 27) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (750669183453805732727050781250 + 3020533706655215263366699218750 * α + 5564839729610338783264160156250 * α ^ 2 + 6204652935907732786560058593750 * α ^ 3 + 4659850847351595430480957031250 * α ^ 4 + 2480313988118708551463378906250 * α ^ 5 + 956953438533800725637460937500 * α ^ 6 + 267988469385291406396875000000 * α ^ 7 + 53061280626889862612388984375 * α ^ 8 + 6649776660279075672227540625 * α ^ 9 + 67029306131497703210255025 * α ^ 10 - 797547671168471728584421521 * α ^ 11 + 69793209950586805764791132 * α ^ 12 + 1582701213221515173844854 * α ^ 13 + 64909025019891545058702 * α ^ 14 - 1621590589357829572680 * α ^ 15 - 347824272218530328424 * α ^ 16 - 21365270620680629952 * α ^ 17 - 794207858493279744 * α ^ 18 - 20077534583212032 * α ^ 19 - 355351304655360 * α ^ 20 - 4364532094464 * α ^ 21 - 35609836032 * α ^ 22 - 174127104 * α ^ 23 - 387072 * α ^ 24) / (2011529617309570312500000 * (3 + α) ^ 12) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B26_27 diff --git a/Sendov/FiniteRange/Degree28_29.lean b/Sendov/FiniteRange/Degree28_29.lean index de10911..930c4ee 100644 --- a/Sendov/FiniteRange/Degree28_29.lean +++ b/Sendov/FiniteRange/Degree28_29.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 28 to 29 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 14) : have hu : (0 : ℝ) ≤ 14 - α := by linarith have hid : (14 : ℝ) ^ 26 * (426450318135882438427115499581616 + 1858834576882378710373815569972592 * α + 3736799374885893548337894566091516 * α ^ 2 + 4586209917810757974592827719731488 * α ^ 3 + 3832530771213891318426391118558376 * α ^ 4 + 2301315780911216714788724083158840 * α ^ 5 + 1020320104787175718704940125987654 * α ^ 6 + 337351267574328588560584527446352 * α ^ 7 + 82684042360278469454015755593696 * α ^ 8 + 14571761439373687941870063150072 * α ^ 9 + 1651893249078514632421437650658 * α ^ 10 + 16915365961758038105007429024 * α ^ 11 - 175858786927760049854457800868 * α ^ 12 + 13481653528168191298544554836 * α ^ 13 + 281552860237833486968732937 * α ^ 14 + 14047072236623243173813992 * α ^ 15 - 9139934377157415820848 * α ^ 16 - 45943869853012600689984 * α ^ 17 - 3291728447735177292432 * α ^ 18 - 135117714229500881664 * α ^ 19 - 3776901841060823808 * α ^ 20 - 75424649382531072 * α ^ 21 - 1084454315870976 * α ^ 22 - 11022972807168 * α ^ 23 - 75437817856 * α ^ 24 - 312639488 * α ^ 25 - 593920 * α ^ 26) = 426450318135882438427115499581616 * (14 - α) ^ 26 + 37111392347886245344338420968738304 * α ^ 1 * (14 - α) ^ 25 + 1521601132780629476593875321808369536 * α ^ 2 * (14 - α) ^ 24 + 39078340323995248057144700994634782336 * α ^ 3 * (14 - α) ^ 23 + 705051187055396740500579766777381514208 * α ^ 4 * (14 - α) ^ 22 + 9500322353274936154789534542408692441472 * α ^ 5 * (14 - α) ^ 21 + 99235235865063211599523391118038843304768 * α ^ 6 * (14 - α) ^ 20 + 823320752785879259967748712211136296143232 * α ^ 7 * (14 - α) ^ 19 + 5515721851061510718162550472414882027285712 * α ^ 8 * (14 - α) ^ 18 + 30174754728220837604457187088268784920537216 * α ^ 9 * (14 - α) ^ 17 + 135797159637259310387481461578932353970581952 * α ^ 10 * (14 - α) ^ 16 + 504664886820509810760132037456041458875523328 * α ^ 11 * (14 - α) ^ 15 + 1540639091909534601865038875378381140958117952 * α ^ 12 * (14 - α) ^ 14 + 3809796887220625879921007425681056060029021952 * α ^ 13 * (14 - α) ^ 13 + 7501791404136392824573180146400956404327039616 * α ^ 14 * (14 - α) ^ 12 + 11572714929523078093880359132036853394473485056 * α ^ 15 * (14 - α) ^ 11 + 13789723758378925038095275082223262786347860304 * α ^ 16 * (14 - α) ^ 10 + 12582251901524132212672360901736009892398456576 * α ^ 17 * (14 - α) ^ 9 + 8935758721652166554311189913325631720840187136 * α ^ 18 * (14 - α) ^ 8 + 5484179813557289010393355638182801357129728128 * α ^ 19 * (14 - α) ^ 7 + 3657829613491729305512570847707150262111504864 * α ^ 20 * (14 - α) ^ 6 + 2783234625894929033925209345455919590486513536 * α ^ 21 * (14 - α) ^ 5 + 1864845683118524255504101199017909275287974464 * α ^ 22 * (14 - α) ^ 4 + 893973882849468086668452977297233134024522624 * α ^ 23 * (14 - α) ^ 3 + 272658852549522790950799560990477918176209712 * α ^ 24 * (14 - α) ^ 2 + 45835418967464600203531300713422486095708800 * α ^ 25 * (14 - α) ^ 1 + 3000012367952955673085245642674753894705600 * α ^ 26 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (14 : ℝ) ^ 26)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 14 - α := by linarith - positivity + bernstein_cert α (14 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 28 ≤ n) (h1 : n ≤ 29) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (426450318135882438427115499581616 + 1858834576882378710373815569972592 * α + 3736799374885893548337894566091516 * α ^ 2 + 4586209917810757974592827719731488 * α ^ 3 + 3832530771213891318426391118558376 * α ^ 4 + 2301315780911216714788724083158840 * α ^ 5 + 1020320104787175718704940125987654 * α ^ 6 + 337351267574328588560584527446352 * α ^ 7 + 82684042360278469454015755593696 * α ^ 8 + 14571761439373687941870063150072 * α ^ 9 + 1651893249078514632421437650658 * α ^ 10 + 16915365961758038105007429024 * α ^ 11 - 175858786927760049854457800868 * α ^ 12 + 13481653528168191298544554836 * α ^ 13 + 281552860237833486968732937 * α ^ 14 + 14047072236623243173813992 * α ^ 15 - 9139934377157415820848 * α ^ 16 - 45943869853012600689984 * α ^ 17 - 3291728447735177292432 * α ^ 18 - 135117714229500881664 * α ^ 19 - 3776901841060823808 * α ^ 20 - 75424649382531072 * α ^ 21 - 1084454315870976 * α ^ 22 - 11022972807168 * α ^ 23 - 75437817856 * α ^ 24 - 312639488 * α ^ 25 - 593920 * α ^ 26) / (378820688032445824710417600 * (3 + α) ^ 13) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B28_29 diff --git a/Sendov/FiniteRange/Degree30_31.lean b/Sendov/FiniteRange/Degree30_31.lean index 8ed1f00..336fcc9 100644 --- a/Sendov/FiniteRange/Degree30_31.lean +++ b/Sendov/FiniteRange/Degree30_31.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 30 to 31 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 15) : have hu : (0 : ℝ) ≤ 15 - α := by linarith have hid : (15 : ℝ) ^ 28 * (586577450963685326737168897370707500 + 2753132994648490979146101875384719500 * α + 5996201651556610186353013706234776680 * α ^ 2 + 8030975436338556704707041798612128472 * α ^ 3 + 7388055615126493367424454764006350082 * α ^ 4 + 4936598337528514606768767094265091378 * α ^ 5 + 2469192037754886771172170203022293214 * α ^ 6 + 938102920031818441360780570553215590 * α ^ 7 + 271392183919032658980825616039479546 * α ^ 8 + 59155996945930238392567631443933866 * α ^ 9 + 9399459563896087929210688264754844 * α ^ 10 + 974977535533292148502665510758532 * α ^ 11 + 10861549420545366403779627757839 * α ^ 12 - 92622867478166716461279291384369 * α ^ 13 + 6300099969105231240951104525763 * α ^ 14 + 117642575887863777951373952647 * α ^ 15 + 6754895556059983986318667916 * α ^ 16 + 94553344499679709104836184 * α ^ 17 - 13437772607038842242965408 * α ^ 18 - 1178131104153353973775376 * α ^ 19 - 53368378574787271805184 * α ^ 20 - 1629770789867125896192 * α ^ 21 - 35941441812526263552 * α ^ 22 - 584181453145681152 * α ^ 23 - 6973783723783168 * α ^ 24 - 59692780623872 * α ^ 25 - 347727077376 * α ^ 26 - 1237127168 * α ^ 27 - 2031616 * α ^ 28) = 586577450963685326737168897370707500 * (15 - α) ^ 28 + 57721163546710553835832257257150602500 * α ^ 1 * (15 - α) ^ 27 + 2685890510897149191990249186639763585500 * α ^ 2 * (15 - α) ^ 26 + 78599194705430136604146587933476363108500 * α ^ 3 * (15 - α) ^ 25 + 1622909997175605567337562554410307661576250 * α ^ 4 * (15 - α) ^ 24 + 25146768623114737087640078167646014091973750 * α ^ 5 * (15 - α) ^ 23 + 303641086695050391528892238082119715503670000 * α ^ 6 * (15 - α) ^ 22 + 2929031512855517774498282614444762020783307500 * α ^ 7 * (15 - α) ^ 21 + 22961042451753622392989015501956773126769350000 * α ^ 8 * (15 - α) ^ 20 + 148033957973212624082175754920221815579937805000 * α ^ 9 * (15 - α) ^ 19 + 791520488598836900068848830160917234498844101250 * α ^ 10 * (15 - α) ^ 18 + 3529526175327511018680726743043836767850893061250 * α ^ 11 * (15 - α) ^ 17 + 13165011207751367740633403433981725749824494296875 * α ^ 12 * (15 - α) ^ 16 + 40931653416291075198328442361012806391694992643125 * α ^ 13 * (15 - α) ^ 15 + 104936099346045749439240355737362583910582002551250 * α ^ 14 * (15 - α) ^ 14 + 218605526114400884612386873561624396579818747067500 * α ^ 15 * (15 - α) ^ 13 + 364544768185120783615020401898669737526038946860625 * α ^ 16 * (15 - α) ^ 12 + 479686011445303946308298171035582326066907836556875 * α ^ 17 * (15 - α) ^ 11 + 491421915359135714614282850386451786914114000492500 * α ^ 18 * (15 - α) ^ 10 + 389161288470744666432388567554714822581024179398750 * α ^ 19 * (15 - α) ^ 9 + 244558897556532361649184200629954946613489703141875 * α ^ 20 * (15 - α) ^ 8 + 139992773266086273600697845417718983669371612533125 * α ^ 21 * (15 - α) ^ 7 + 93042859490049901489480348991956175393389715291250 * α ^ 22 * (15 - α) ^ 6 + 69299238884896976481539054996360074995454890772500 * α ^ 23 * (15 - α) ^ 5 + 43491785146541891064576495824222890234435540966875 * α ^ 24 * (15 - α) ^ 4 + 19249688128515085853018716648633058220873114065625 * α ^ 25 * (15 - α) ^ 3 + 5426365264657811094720994999869461719092174416250 * α ^ 26 * (15 - α) ^ 2 + 847744461331358174965504508366152817665302528000 * α ^ 27 * (15 - α) ^ 1 + 51950222508646395464079311308157550857404416000 * α ^ 28 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (15 : ℝ) ^ 28)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 15 - α := by linarith - positivity + bernstein_cert α (15 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 30 ≤ n) (h1 : n ≤ 31) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (586577450963685326737168897370707500 + 2753132994648490979146101875384719500 * α + 5996201651556610186353013706234776680 * α ^ 2 + 8030975436338556704707041798612128472 * α ^ 3 + 7388055615126493367424454764006350082 * α ^ 4 + 4936598337528514606768767094265091378 * α ^ 5 + 2469192037754886771172170203022293214 * α ^ 6 + 938102920031818441360780570553215590 * α ^ 7 + 271392183919032658980825616039479546 * α ^ 8 + 59155996945930238392567631443933866 * α ^ 9 + 9399459563896087929210688264754844 * α ^ 10 + 974977535533292148502665510758532 * α ^ 11 + 10861549420545366403779627757839 * α ^ 12 - 92622867478166716461279291384369 * α ^ 13 + 6300099969105231240951104525763 * α ^ 14 + 117642575887863777951373952647 * α ^ 15 + 6754895556059983986318667916 * α ^ 16 + 94553344499679709104836184 * α ^ 17 - 13437772607038842242965408 * α ^ 18 - 1178131104153353973775376 * α ^ 19 - 53368378574787271805184 * α ^ 20 - 1629770789867125896192 * α ^ 21 - 35941441812526263552 * α ^ 22 - 584181453145681152 * α ^ 23 - 6973783723783168 * α ^ 24 - 59692780623872 * α ^ 25 - 347727077376 * α ^ 26 - 1237127168 * α ^ 27 - 2031616 * α ^ 28) / (172881045887035525441599708000 * (3 + α) ^ 14) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B30_31 diff --git a/Sendov/FiniteRange/Degree32_33.lean b/Sendov/FiniteRange/Degree32_33.lean index 2663e99..f40ce27 100644 --- a/Sendov/FiniteRange/Degree32_33.lean +++ b/Sendov/FiniteRange/Degree32_33.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 32 to 33 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 16) : have hu : (0 : ℝ) ≤ 16 - α := by linarith have hid : (16 : ℝ) ^ 30 * (383977583360819576313951392966054557440 + 1930634984998770141470327139790256873760 * α + 4528139655529657241697903448404234220551 * α ^ 2 + 6571116743547522810411224078221219285242 * α ^ 3 + 6597373572981213714180223077765169741761 * α ^ 4 + 4853145290868457132481352533313124037136 * α ^ 5 + 2701279688513765542055333848381676518287 * α ^ 6 + 1157769823809425762972955166775789744790 * α ^ 7 + 384826365482239087514233918976406892725 * α ^ 8 + 98972460520277767374027328895457052524 * α ^ 9 + 19429030643214541979169516429755259903 * α ^ 10 + 2812337464920293963928011188383752346 * α ^ 11 + 269412053495826821775011955678389445 * α ^ 12 + 3352473026131557768885960806993016 * α ^ 13 - 22950931900671630187087717249723635 * α ^ 14 + 1401665499631441401236402118586466 * α ^ 15 + 22766380179065358125804378947555 * α ^ 16 + 1462014916628262060084862591156 * α ^ 17 + 35132359566977040523019407180 * α ^ 18 - 1604603346728872922022402944 * α ^ 19 - 192243388845480689610974960 * α ^ 20 - 9672937893957196503857344 * α ^ 21 - 320523259524150064257216 * α ^ 22 - 7695435702924730354176 * α ^ 23 - 138216454665665111296 * α ^ 24 - 1869603872239262720 * α ^ 25 - 18853950116959232 * α ^ 26 - 137859411329024 * α ^ 27 - 692050472960 * α ^ 28 - 2136915968 * α ^ 29 - 3063808 * α ^ 30) = 383977583360819576313951392966054557440 * (16 - α) ^ 30 + 42409487260804909552943776025625746703360 * α ^ 1 * (16 - α) ^ 29 + 2222048633616978115213463931594396882372096 * α ^ 2 * (16 - α) ^ 28 + 73473353083404174858760833498075355240412160 * α ^ 3 * (16 - α) ^ 27 + 1720652985002569694625940957603172487457959168 * α ^ 4 * (16 - α) ^ 26 + 30363605055601889844187715226554004982348216320 * α ^ 5 * (16 - α) ^ 25 + 419419313440566659766595274985269607940848110592 * α ^ 6 * (16 - α) ^ 24 + 4651028177520748697700758854373515125968713340928 * α ^ 7 * (16 - α) ^ 23 + 42137577409585697471273190015560150932516267552512 * α ^ 8 * (16 - α) ^ 22 + 315813162774288007921028011965819893459606590098432 * α ^ 9 * (16 - α) ^ 21 + 1975705535276134028928012252827490436823332026530304 * α ^ 10 * (16 - α) ^ 20 + 10382688588871544644830770347967881283088055308155904 * α ^ 11 * (16 - α) ^ 19 + 46032559619183787080156358678834876487940673091005696 * α ^ 12 * (16 - α) ^ 18 + 172591747559291476479103054798864248406917335500124160 * α ^ 13 * (16 - α) ^ 17 + 545974175950014920103132403616690663895819828147984384 * α ^ 14 * (16 - α) ^ 16 + 1445130613022938433929608617595105884579474631328108544 * α ^ 15 * (16 - α) ^ 15 + 3161509852911810407500355299058617164221708297980898560 * α ^ 16 * (16 - α) ^ 14 + 5640295189041616515165641512647513399952299862475037696 * α ^ 17 * (16 - α) ^ 13 + 8096357711013760274749679034695047723667449284765784576 * α ^ 18 * (16 - α) ^ 12 + 9222746840024741255973982987098297227268540123123805184 * α ^ 19 * (16 - α) ^ 11 + 8223039813167952720182093497637178426661494992975589120 * α ^ 20 * (16 - α) ^ 10 + 5704256351282499932163905647696347181598873537091336192 * α ^ 21 * (16 - α) ^ 9 + 3201419973312332497561890234813360990647765548239842304 * α ^ 22 * (16 - α) ^ 8 + 1740681060211180094425255735717618532157429256988792832 * α ^ 23 * (16 - α) ^ 7 + 1171781379026559228219387738006839365835033511446179072 * α ^ 24 * (16 - α) ^ 6 + 856349049543820949149124961191230752126749714115924992 * α ^ 25 * (16 - α) ^ 5 + 505504390045160314727256739583393494736411020808873472 * α ^ 26 * (16 - α) ^ 4 + 207885993237921287478858446074371829024853091294110720 * α ^ 27 * (16 - α) ^ 3 + 54498421679605652502910205539029441943284379111601920 * α ^ 28 * (16 - α) ^ 2 + 7954898798277651559977779244576588075469014026035200 * α ^ 29 * (16 - α) ^ 1 + 458384953904887998462676380172134968211581830656000 * α ^ 30 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (16 : ℝ) ^ 30)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 16 - α := by linarith - positivity + bernstein_cert α (16 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 32 ≤ n) (h1 : n ≤ 33) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (383977583360819576313951392966054557440 + 1930634984998770141470327139790256873760 * α + 4528139655529657241697903448404234220551 * α ^ 2 + 6571116743547522810411224078221219285242 * α ^ 3 + 6597373572981213714180223077765169741761 * α ^ 4 + 4853145290868457132481352533313124037136 * α ^ 5 + 2701279688513765542055333848381676518287 * α ^ 6 + 1157769823809425762972955166775789744790 * α ^ 7 + 384826365482239087514233918976406892725 * α ^ 8 + 98972460520277767374027328895457052524 * α ^ 9 + 19429030643214541979169516429755259903 * α ^ 10 + 2812337464920293963928011188383752346 * α ^ 11 + 269412053495826821775011955678389445 * α ^ 12 + 3352473026131557768885960806993016 * α ^ 13 - 22950931900671630187087717249723635 * α ^ 14 + 1401665499631441401236402118586466 * α ^ 15 + 22766380179065358125804378947555 * α ^ 16 + 1462014916628262060084862591156 * α ^ 17 + 35132359566977040523019407180 * α ^ 18 - 1604603346728872922022402944 * α ^ 19 - 192243388845480689610974960 * α ^ 20 - 9672937893957196503857344 * α ^ 21 - 320523259524150064257216 * α ^ 22 - 7695435702924730354176 * α ^ 23 - 138216454665665111296 * α ^ 24 - 1869603872239262720 * α ^ 25 - 18853950116959232 * α ^ 26 - 137859411329024 * α ^ 27 - 692050472960 * α ^ 28 - 2136915968 * α ^ 29 - 3063808 * α ^ 30) / (37572885123356984842662119654400 * (3 + α) ^ 15) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B32_33 diff --git a/Sendov/FiniteRange/Degree34_35.lean b/Sendov/FiniteRange/Degree34_35.lean index 93a5581..ca79541 100644 --- a/Sendov/FiniteRange/Degree34_35.lean +++ b/Sendov/FiniteRange/Degree34_35.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 34 to 35 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 32 * (13399266531718143561671329774091404024125 + 71849885492802810816842838949259978576823 * α + 180538945319091116404922710783631485776255 * α ^ 2 + 282156930875912547195503056499665223632869 * α ^ 3 + 306955881947816717076752055353611201997433 * α ^ 4 + 246444353252723432574425088492703243027965 * α ^ 5 + 151019226036657912949719936683240321200053 * α ^ 6 + 72028327083715746440304318235594953916857 * α ^ 7 + 27007117326925331098314143315441103261561 * α ^ 8 + 7979024241553623900285784858349597089245 * α ^ 9 + 1847320854708526473676328223562198887417 * α ^ 10 + 329938708337757813561795624655269556461 * α ^ 11 + 43878641971714608549212527982241857715 * α ^ 12 + 3911666704610568428372170990877699643 * α ^ 13 + 54464632768848512857832724331386693 * α ^ 14 - 300202584430678770107735269889128119 * α ^ 15 + 16644540127319447720784804793743786 * α ^ 16 + 228891055611380679685401624709920 * α ^ 17 + 16200353115196577039237473724202 * α ^ 18 + 510663548855848557629648901888 * α ^ 19 - 6873476290889727146869228680 * α ^ 20 - 1591901557063130972106786240 * α ^ 21 - 90385492060860172817322528 * α ^ 22 - 3241298369821124224491264 * α ^ 23 - 83924819944658782911360 * α ^ 24 - 1639999868886062272512 * α ^ 25 - 24549687196522919424 * α ^ 26 - 281209623855906816 * α ^ 27 - 2429673447720960 * α ^ 28 - 15359508856832 * α ^ 29 - 67149078528 * α ^ 30 - 181665792 * α ^ 31 - 229376 * α ^ 32) = 13399266531718143561671329774091404024125 * (17 - α) ^ 32 + 1650224582392628377859810814908344564577991 * α ^ 1 * (17 - α) ^ 31 + 96686681051656613148087819110678844495289416 * α ^ 2 * (17 - α) ^ 30 + 3585943364127806535175218856650333719997862062 * α ^ 3 * (17 - α) ^ 29 + 94506835391773642943632702539240023655585239976 * α ^ 4 * (17 - α) ^ 28 + 1883536024491957754295155022173521798076402761306 * α ^ 5 * (17 - α) ^ 27 + 29498713431163207985062885810393117977995458611360 * α ^ 6 * (17 - α) ^ 26 + 372444567835409169626366992601449865136908523715554 * α ^ 7 * (17 - α) ^ 25 + 3859379869369491930046652624818040581445251700417436 * α ^ 8 * (17 - α) ^ 24 + 33247489122948312922756142978001205956348938877434094 * α ^ 9 * (17 - α) ^ 23 + 240361064800204816769332884725722337309385385508245284 * α ^ 10 * (17 - α) ^ 22 + 1468297579222476711150318215261328148465442277706125318 * α ^ 11 * (17 - α) ^ 21 + 7616476027067108231341929094010647728198437294881398882 * α ^ 12 * (17 - α) ^ 20 + 33663083667068151985435771538517917417846319467001398040 * α ^ 13 * (17 - α) ^ 19 + 127012191711700706943666066187667778984137340603569186202 * α ^ 14 * (17 - α) ^ 18 + 408483237363770470892000173862806063969919527704726536136 * α ^ 15 * (17 - α) ^ 17 + 1112699056508533083404960444025601114584826187986242644199 * α ^ 16 * (17 - α) ^ 16 + 2541228944450694617802464818664598037324243538753868594135 * α ^ 17 * (17 - α) ^ 15 + 4808963007779256297034335517823636520905050012269500452122 * α ^ 18 * (17 - α) ^ 14 + 7449105095546099705010373449780908551641339483192620776998 * α ^ 19 * (17 - α) ^ 13 + 9324511543492008692105399378290148512417024338959823894774 * α ^ 20 * (17 - α) ^ 12 + 9297740340616393778000297728009621202927136433782291562398 * α ^ 21 * (17 - α) ^ 11 + 7274130570772010006967162133652153552632813945113550333758 * α ^ 22 * (17 - α) ^ 10 + 4441828800293274983181495636158215106270810356077510048966 * α ^ 23 * (17 - α) ^ 9 + 2239471510489480023234027273281488727890334103099818233488 * α ^ 24 * (17 - α) ^ 8 + 1180013639374388482169007814986614403675247990630945641900 * α ^ 25 * (17 - α) ^ 7 + 818218224361787722039978747842931615637242518870584611650 * α ^ 26 * (17 - α) ^ 6 + 587927012852098590957570014487485323178262550641905003190 * α ^ 27 * (17 - α) ^ 5 + 327641901908612799526209846021045735379467528409310341680 * α ^ 28 * (17 - α) ^ 4 + 125868057563181650595391338568950934373772184543193971640 * α ^ 29 * (17 - α) ^ 3 + 30847873348677414400175155768102397838878364715388408640 * α ^ 30 * (17 - α) ^ 2 + 4226337377572378619631312225122710192128000000000000000 * α ^ 31 * (17 - α) ^ 1 + 229862066916150806363247669850238091264000000000000000 * α ^ 32 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 32)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 34 ≤ n) (h1 : n ≤ 35) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (13399266531718143561671329774091404024125 + 71849885492802810816842838949259978576823 * α + 180538945319091116404922710783631485776255 * α ^ 2 + 282156930875912547195503056499665223632869 * α ^ 3 + 306955881947816717076752055353611201997433 * α ^ 4 + 246444353252723432574425088492703243027965 * α ^ 5 + 151019226036657912949719936683240321200053 * α ^ 6 + 72028327083715746440304318235594953916857 * α ^ 7 + 27007117326925331098314143315441103261561 * α ^ 8 + 7979024241553623900285784858349597089245 * α ^ 9 + 1847320854708526473676328223562198887417 * α ^ 10 + 329938708337757813561795624655269556461 * α ^ 11 + 43878641971714608549212527982241857715 * α ^ 12 + 3911666704610568428372170990877699643 * α ^ 13 + 54464632768848512857832724331386693 * α ^ 14 - 300202584430678770107735269889128119 * α ^ 15 + 16644540127319447720784804793743786 * α ^ 16 + 228891055611380679685401624709920 * α ^ 17 + 16200353115196577039237473724202 * α ^ 18 + 510663548855848557629648901888 * α ^ 19 - 6873476290889727146869228680 * α ^ 20 - 1591901557063130972106786240 * α ^ 21 - 90385492060860172817322528 * α ^ 22 - 3241298369821124224491264 * α ^ 23 - 83924819944658782911360 * α ^ 24 - 1639999868886062272512 * α ^ 25 - 24549687196522919424 * α ^ 26 - 281209623855906816 * α ^ 27 - 2429673447720960 * α ^ 28 - 15359508856832 * α ^ 29 - 67149078528 * α ^ 30 - 181665792 * α ^ 31 - 229376 * α ^ 32) / (435539996816352082589992870143936 * (3 + α) ^ 16) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B34_35 diff --git a/Sendov/FiniteRange/Degree36_37.lean b/Sendov/FiniteRange/Degree36_37.lean index e2df718..8158a91 100644 --- a/Sendov/FiniteRange/Degree36_37.lean +++ b/Sendov/FiniteRange/Degree36_37.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 36 to 37 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 34 * (1340862494179159723457439116979158935546875000 + 7637969043915714340759947223349395751953125000 * α + 20469159372189815097433030931483526306152343750 * α ^ 2 + 34274361726863699928017616105749597900390625000 * α ^ 3 + 40158420010659405404629812835302538476562500000 * α ^ 4 + 34937401402816329855420946112276054381835937500 * α ^ 5 + 23367211725435618964676169025739806953662109375 * α ^ 6 + 12270122821734134505495363628244218847460937500 * α ^ 7 + 5119554315996410501630574472803506399777343750 * α ^ 8 + 1706085086162412699720364430591688420225000000 * α ^ 9 + 453657266969080072299236418096329864193140625 * α ^ 10 + 95512498825559724167251930963289431001100000 * α ^ 11 + 15651081746907280778533576463846724310987500 * α ^ 12 + 1925946170421648313592236215225863164072500 * α ^ 13 + 160780952585487184902439630853241164106375 * α ^ 14 + 2481149473011100292550908813010287159220 * α ^ 15 - 11166042731030257542258130633810209326742 * α ^ 16 + 567791382062622839648458479091876877544 * α ^ 17 + 6430218988186661251397393995576293933 * α ^ 18 + 498747834176692841464289681241746784 * α ^ 19 + 18702443537088721760797370916939480 * α ^ 20 + 57367909378421946482804755695328 * α ^ 21 - 35467391809924321679454804549376 * α ^ 22 - 2344076836762407866768807250432 * α ^ 23 - 91095016683709754039240857216 * α ^ 24 - 2528503186830718445641541120 * α ^ 25 - 53176733671797993730857984 * α ^ 26 - 866597180873027929669632 * α ^ 27 - 11005160172719761434624 * α ^ 28 - 108265710516964073472 * α ^ 29 - 810954254409318400 * α ^ 30 - 4477829562761216 * α ^ 31 - 17204805009408 * α ^ 32 - 41120301056 * α ^ 33 - 46071808 * α ^ 34) = 1340862494179159723457439116979158935546875000 * (17 - α) ^ 34 + 175434798548658574390472032774231131591796875000 * α ^ 1 * (17 - α) ^ 33 + 10952711551434080913184099676123058282165527343750 * α ^ 2 * (17 - α) ^ 32 + 434270856341448311475241819934694889103759765625000 * α ^ 3 * (17 - α) ^ 31 + 12278911436635306192132622790762987549533349609375000 * α ^ 4 * (17 - α) ^ 30 + 263557269216566555320865047728777428822756844726562500 * α ^ 5 * (17 - α) ^ 29 + 4463883671586096731770907085592494749976786136669921875 * α ^ 6 * (17 - α) ^ 28 + 61225965954407894273160354546600964058305754660156250000 * α ^ 7 * (17 - α) ^ 27 + 692587772613132439128122751366082049061109249880812500000 * α ^ 8 * (17 - α) ^ 26 + 6547796240902796556445336115711018473638408241918575000000 * α ^ 9 * (17 - α) ^ 25 + 52247549382615756077051379940154408637849061298491733812500 * α ^ 10 * (17 - α) ^ 24 + 354466647029909646510470656479599263564041502427407695300000 * α ^ 11 * (17 - α) ^ 23 + 2055889704738111710267568200183486826512215613684783110200000 * α ^ 12 * (17 - α) ^ 22 + 10234888840339768071474956793147766100757409148665132934370000 * α ^ 13 * (17 - α) ^ 21 + 43858398380617067829266771169258660902757314148335253721083000 * α ^ 14 * (17 - α) ^ 20 + 162055210405371666456160142527627828678422430377426835106958960 * α ^ 15 * (17 - α) ^ 19 + 516145320938971158929091669417239050325330885780111469198875088 * α ^ 16 * (17 - α) ^ 18 + 1412064392511895951084181534107896493318729250846824514725955712 * α ^ 17 * (17 - α) ^ 17 + 3296410975824492770073801068890863487757382337405699389044881152 * α ^ 18 * (17 - α) ^ 16 + 6510700656466073656283913487155596019027366109135146309819197400 * α ^ 19 * (17 - α) ^ 15 + 10778762671920232847172097564072974706837835927532659281695627000 * α ^ 20 * (17 - α) ^ 14 + 14812853870469700737370316477184138613188186623760145268072292500 * α ^ 21 * (17 - α) ^ 13 + 16720671608226908945079705353880617034286101018111021059080009375 * α ^ 22 * (17 - α) ^ 12 + 15317420704224111419919616448379092129752276964124634080685800000 * α ^ 23 * (17 - α) ^ 11 + 11238165133613859896218350103981386092933200214685034701456250000 * α ^ 24 * (17 - α) ^ 10 + 6544374325964212483346602292437892685413037367000381149781250000 * α ^ 25 * (17 - α) ^ 9 + 3087009276202780754337495361663231009012869918782181865781250000 * α ^ 26 * (17 - α) ^ 8 + 1334541850899219151104336491093618277155327063911213757812500000 * α ^ 27 * (17 - α) ^ 7 + 671021217962301496929047441300025617792685964844905141406250000 * α ^ 28 * (17 - α) ^ 6 + 390013014583991314611686405951849748841394880271566591796875000 * α ^ 29 * (17 - α) ^ 5 + 198126638262411132449557681354886342145672562882243054199218750 * α ^ 30 * (17 - α) ^ 4 + 72921376026239920902575443619361410154303245019324218750000000 * α ^ 31 * (17 - α) ^ 3 + 17546793780907574541651374555825605095190744540455322265625000 * α ^ 32 * (17 - α) ^ 2 + 2427279654890969862947772530516229556781067701712646484375000 * α ^ 33 * (17 - α) ^ 1 + 141776547693471981630558155006611207847406241325378417968750 * α ^ 34 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 34)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 36 ≤ n) (h1 : n ≤ 37) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (1340862494179159723457439116979158935546875000 + 7637969043915714340759947223349395751953125000 * α + 20469159372189815097433030931483526306152343750 * α ^ 2 + 34274361726863699928017616105749597900390625000 * α ^ 3 + 40158420010659405404629812835302538476562500000 * α ^ 4 + 34937401402816329855420946112276054381835937500 * α ^ 5 + 23367211725435618964676169025739806953662109375 * α ^ 6 + 12270122821734134505495363628244218847460937500 * α ^ 7 + 5119554315996410501630574472803506399777343750 * α ^ 8 + 1706085086162412699720364430591688420225000000 * α ^ 9 + 453657266969080072299236418096329864193140625 * α ^ 10 + 95512498825559724167251930963289431001100000 * α ^ 11 + 15651081746907280778533576463846724310987500 * α ^ 12 + 1925946170421648313592236215225863164072500 * α ^ 13 + 160780952585487184902439630853241164106375 * α ^ 14 + 2481149473011100292550908813010287159220 * α ^ 15 - 11166042731030257542258130633810209326742 * α ^ 16 + 567791382062622839648458479091876877544 * α ^ 17 + 6430218988186661251397393995576293933 * α ^ 18 + 498747834176692841464289681241746784 * α ^ 19 + 18702443537088721760797370916939480 * α ^ 20 + 57367909378421946482804755695328 * α ^ 21 - 35467391809924321679454804549376 * α ^ 22 - 2344076836762407866768807250432 * α ^ 23 - 91095016683709754039240857216 * α ^ 24 - 2528503186830718445641541120 * α ^ 25 - 53176733671797993730857984 * α ^ 26 - 866597180873027929669632 * α ^ 27 - 11005160172719761434624 * α ^ 28 - 108265710516964073472 * α ^ 29 - 810954254409318400 * α ^ 30 - 4477829562761216 * α ^ 31 - 17204805009408 * α ^ 32 - 41120301056 * α ^ 33 - 46071808 * α ^ 34) / (14484306327350467025497631835937500000 * (3 + α) ^ 17) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B36_37 diff --git a/Sendov/FiniteRange/Degree38_39.lean b/Sendov/FiniteRange/Degree38_39.lean index afcef1f..088a6ff 100644 --- a/Sendov/FiniteRange/Degree38_39.lean +++ b/Sendov/FiniteRange/Degree38_39.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 38 to 39 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 36 * (263016241667210021671084890841481617690003189110 + 1586061041777522258785370750920508059260325100670 * α + 4515569002916763022083813591656453793545843463960 * α ^ 2 + 8064535450447153538886731843043227730967854436080 * α ^ 3 + 10124049292126400106014356225197947036232792604485 * α ^ 4 + 9486490487762873429871569630238934346081556621609 * α ^ 5 + 6875502816855646349457849536822502570739478645343 * α ^ 6 + 3940536916491738744952644524802984325688545318839 * α ^ 7 + 1810118648803944257004276579444295893576974412957 * α ^ 8 + 671223601039568220250335587923837679954504671929 * α ^ 9 + 201302327242382412835780103712068254297083069927 * α ^ 10 + 48665320464285286858138805925504857552220130935 * α ^ 11 + 9395447364524194147939717327946455319249576385 * α ^ 12 + 1422463731757903542558687467068487748999154005 * α ^ 13 + 162936488968328754409221779604516446092275015 * α ^ 14 + 12804246766409474561270894860455521523191007 * α ^ 15 + 216069416334011168489825518695466581657549 * α ^ 16 - 808211600142399392096627843592018139890543 * α ^ 17 + 38042736580603120168867477319356142859621 * α ^ 18 + 344373790265831271857444699712655317117 * α ^ 19 + 29315226870352164747186119924985775776 * α ^ 20 + 1247198097855472249813750976434442560 * α ^ 21 + 16662184536264199136681220318869840 * α ^ 22 - 1406905416514864930658623327447840 * α ^ 23 - 115154592405960528415597818779200 * α ^ 24 - 4877945634325956011421670432000 * α ^ 25 - 144681078013665355320791476480 * α ^ 26 - 3249838030348665967746429440 * α ^ 27 - 56982963376184696008104960 * α ^ 28 - 788738718851438284800000 * α ^ 29 - 8618882420705188376576 * α ^ 30 - 73677168662756319232 * α ^ 31 - 483260148118798336 * α ^ 32 - 2351449584959488 * α ^ 33 - 8003806560256 * α ^ 34 - 17023172608 * α ^ 35 - 17039360 * α ^ 36) = 263016241667210021671084890841481617690003189110 * (17 - α) ^ 36 + 36431622410237439179510358835941975244265641519350 * α ^ 1 * (17 - α) ^ 35 + 2414405993950912571012301206016550860739344205122390 * α ^ 2 * (17 - α) ^ 34 + 101911987093790495993891637162656810587351337884854450 * α ^ 3 * (17 - α) ^ 33 + 3077136529375910511818308139163370204204710108135348945 * α ^ 4 * (17 - α) ^ 32 + 70767700416372118022916506935148443513144214212984079433 * α ^ 5 * (17 - α) ^ 31 + 1288872796711775738410766166408400924167189843482363181510 * α ^ 6 * (17 - α) ^ 30 + 19083400748229222868616813579365546608706181811242799713442 * α ^ 7 * (17 - α) ^ 29 + 234010152840381946349380212378698061303021231207480935794380 * α ^ 8 * (17 - α) ^ 28 + 2409083298538233479330794311735295130068631390190510305345916 * α ^ 9 * (17 - α) ^ 27 + 21034199072421691415654588980184171455732743682853035936388736 * α ^ 10 * (17 - α) ^ 26 + 156965739060943279756832920952171731542118382822579555902264320 * α ^ 11 * (17 - α) ^ 25 + 1007013809256349634438976269863634909802444822788284670764336920 * α ^ 12 * (17 - α) ^ 24 + 5578883286717752179555968646363028277131383001091676680613578600 * α ^ 13 * (17 - α) ^ 23 + 26778108682132812026449907006307737451347925518376385819177842180 * α ^ 14 * (17 - α) ^ 22 + 111626866485074002051921408370316196620668741767980677786122726476 * α ^ 15 * (17 - α) ^ 21 + 404749936967515936812332395113162625848731824975287760415129552520 * α ^ 16 * (17 - α) ^ 20 + 1276851853339474854752478301460896841716394369316599334161708835864 * α ^ 17 * (17 - α) ^ 19 + 3498152021559931653758754395800484089136347016702124578632888785870 * α ^ 18 * (17 - α) ^ 18 + 8288489989122825212327334609599909543398390901155522489744660111602 * α ^ 19 * (17 - α) ^ 17 + 16882651085623904442176264117055333605492167285591363946133352298205 * α ^ 20 * (17 - α) ^ 16 + 29353791640642678379569945946711713118769355441603863420459332583845 * α ^ 21 * (17 - α) ^ 15 + 43236117652901827874516888436407546705327794671242323926919339677542 * α ^ 22 * (17 - α) ^ 14 + 53514417120286757722309232459981186747567529389425853874706900031330 * α ^ 23 * (17 - α) ^ 13 + 55160684404854002133844526815694799322288761295220210026216244417256 * α ^ 24 * (17 - α) ^ 12 + 46859199139271497704482066786546595457658791134521569883679868639464 * α ^ 25 * (17 - α) ^ 11 + 32418496139685480362601229821482044096981462148753646754741401291900 * α ^ 26 * (17 - α) ^ 10 + 18064228253690987870059860955691584275196341087334183534685080363332 * α ^ 27 * (17 - α) ^ 9 + 8116057087439008484605418610430390304640800612633036742729214781010 * α ^ 28 * (17 - α) ^ 8 + 3094097281163451800860397134053738271256213921040320763043485148866 * α ^ 29 * (17 - α) ^ 7 + 1174308203032074417716759573429346434013837010515376831055725367856 * α ^ 30 * (17 - α) ^ 6 + 514147619716779490199856234417204230784802425196644936366761384400 * α ^ 31 * (17 - α) ^ 5 + 225918222596880524574644194822909829140432799329070928335788308150 * α ^ 32 * (17 - α) ^ 4 + 78378867100425150377346627184325309287549636198734508005978549750 * α ^ 33 * (17 - α) ^ 3 + 18415214840638052851390630908893866826964214257262459916509597440 * α ^ 34 * (17 - α) ^ 2 + 2542392303855460193752438935467117379253704583645900859266878840 * α ^ 35 * (17 - α) ^ 1 + 152938893321252958580549098618153156123487784458433341017459200 * α ^ 36 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 36)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 38 ≤ n) (h1 : n ≤ 39) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (263016241667210021671084890841481617690003189110 + 1586061041777522258785370750920508059260325100670 * α + 4515569002916763022083813591656453793545843463960 * α ^ 2 + 8064535450447153538886731843043227730967854436080 * α ^ 3 + 10124049292126400106014356225197947036232792604485 * α ^ 4 + 9486490487762873429871569630238934346081556621609 * α ^ 5 + 6875502816855646349457849536822502570739478645343 * α ^ 6 + 3940536916491738744952644524802984325688545318839 * α ^ 7 + 1810118648803944257004276579444295893576974412957 * α ^ 8 + 671223601039568220250335587923837679954504671929 * α ^ 9 + 201302327242382412835780103712068254297083069927 * α ^ 10 + 48665320464285286858138805925504857552220130935 * α ^ 11 + 9395447364524194147939717327946455319249576385 * α ^ 12 + 1422463731757903542558687467068487748999154005 * α ^ 13 + 162936488968328754409221779604516446092275015 * α ^ 14 + 12804246766409474561270894860455521523191007 * α ^ 15 + 216069416334011168489825518695466581657549 * α ^ 16 - 808211600142399392096627843592018139890543 * α ^ 17 + 38042736580603120168867477319356142859621 * α ^ 18 + 344373790265831271857444699712655317117 * α ^ 19 + 29315226870352164747186119924985775776 * α ^ 20 + 1247198097855472249813750976434442560 * α ^ 21 + 16662184536264199136681220318869840 * α ^ 22 - 1406905416514864930658623327447840 * α ^ 23 - 115154592405960528415597818779200 * α ^ 24 - 4877945634325956011421670432000 * α ^ 25 - 144681078013665355320791476480 * α ^ 26 - 3249838030348665967746429440 * α ^ 27 - 56982963376184696008104960 * α ^ 28 - 788738718851438284800000 * α ^ 29 - 8618882420705188376576 * α ^ 30 - 73677168662756319232 * α ^ 31 - 483260148118798336 * α ^ 32 - 2351449584959488 * α ^ 33 - 8003806560256 * α ^ 34 - 17023172608 * α ^ 35 - 17039360 * α ^ 36) / (944533280285743117909608355250454382800 * (3 + α) ^ 18) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B38_39 diff --git a/Sendov/FiniteRange/Degree40_41.lean b/Sendov/FiniteRange/Degree40_41.lean index d7abd31..64c0604 100644 --- a/Sendov/FiniteRange/Degree40_41.lean +++ b/Sendov/FiniteRange/Degree40_41.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 40 to 41 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 38 * (653328533869198792815460418567456328463360027860000 + 4157882298167732116226370617284188848212873011241200 * α + 12532182988010399386002617462745633312768152237121570 * α ^ 2 + 23778313854745445633723704693422676769304621097023060 * α ^ 3 + 31839691004956228828005033576674262680347642949789970 * α ^ 4 + 31966947875077850162540664582127534223677059725715480 * α ^ 5 + 24954452263842718944480719755732872419125467194310990 * α ^ 6 + 15498456398852386516930447507216103141023058978163900 * α ^ 7 + 7770525510255924837049186376423929043180641908035178 * α ^ 8 + 3172282421659051612506049390871943668830947112996128 * α ^ 9 + 1058580212642493803810630674822381941853484677345557 * α ^ 10 + 288603554681274589435804606029301359165948874522986 * α ^ 11 + 63964171378367904791712568423672278670444648520985 * α ^ 12 + 11403554558448059539985445321284291979921951939708 * α ^ 13 + 1604683068013899575897130419685118852646893739688 * α ^ 14 + 171973766788073602692262435759609700705097645552 * α ^ 15 + 12777319017916275759622043304057680904260665896 * α ^ 16 + 232511338229217727198624028718607742301689616 * α ^ 17 - 736152391583269859036039443814447014605197787 * α ^ 18 + 32344027389559443630831441714104468449897746 * α ^ 19 + 226192739078384191702850277844962783099369 * α ^ 20 + 21321388850847068435151126284573459826132 * α ^ 21 + 1002825060545767936823647697965569833484 * α ^ 22 + 20605096429138626101144518690493027136 * α ^ 23 - 588379321688541475027751329888140192 * α ^ 24 - 68916522458163479393324809629479808 * α ^ 25 - 3219999749177967431080752136593024 * α ^ 26 - 101984865798504570834320095942656 * α ^ 27 - 2433981075208899701339322164736 * α ^ 28 - 45526079756647968714698102784 * α ^ 29 - 678401876172921453922277376 * α ^ 30 - 8091691517611230731255808 * α ^ 31 - 76978691001245722632192 * α ^ 32 - 577480811034021101568 * α ^ 33 - 3345672064015171584 * α ^ 34 - 14456978064408576 * α ^ 35 - 43900332474368 * α ^ 36 - 83629441024 * α ^ 37 - 75235328 * α ^ 38) = 653328533869198792815460418567456328463360027860000 * (17 - α) ^ 38 + 95510483355881000102835796399394550901226522249780400 * α ^ 1 * (17 - α) ^ 37 + 6696398808392555675010412239258164611825635220184428530 * α ^ 2 * (17 - α) ^ 36 + 299794710667200193646561985461117827680016512752986934460 * α ^ 3 * (17 - α) ^ 35 + 9627257466437286352224279116990630228292750401872068624570 * α ^ 4 * (17 - α) ^ 34 + 236169626370579092102401540068424043031156213235832488824240 * α ^ 5 * (17 - α) ^ 33 + 4602580155935131911540977878848744873896752358859535239239310 * α ^ 6 * (17 - α) ^ 32 + 73167568636523068791230387895812989143995323139339741955173340 * α ^ 7 * (17 - α) ^ 31 + 966819100697307203780359917617580768148731765217116962982472158 * α ^ 8 * (17 - α) ^ 30 + 10767130098246849195301111459928119363029994766661588897784000776 * α ^ 9 * (17 - α) ^ 29 + 102122724502527454683682344439666460359467859469480457468195144927 * α ^ 10 * (17 - α) ^ 28 + 831548691595541121952529230262845541710942265958095940858036487578 * α ^ 11 * (17 - α) ^ 27 + 5848940149873603781228937217250745230319503456527981662700527649479 * α ^ 12 * (17 - α) ^ 26 + 35707752760626549856948044943531072922885702324271579224065621550616 * α ^ 13 * (17 - α) ^ 25 + 189904423378547635211179836338153464631558375737888355414680794292332 * α ^ 14 * (17 - α) ^ 24 + 882263986278123132234428133435096956146433318787491830406424008581944 * α ^ 15 * (17 - α) ^ 23 + 3587848295098893896231452077434369033403531934780731646206410657559996 * α ^ 16 * (17 - α) ^ 22 + 12789017524790293159146747559828714620914231030244750348653705133535680 * α ^ 17 * (17 - α) ^ 21 + 39978318616507844028720464128037031241214473591909362382585304014435338 * α ^ 18 * (17 - α) ^ 20 + 109503304419314521695778687533175441622403892877574691241529360322168236 * α ^ 19 * (17 - α) ^ 19 + 262146994169564092167982595241915300650038077337630821023247107830038522 * α ^ 20 * (17 - α) ^ 18 + 546246295187027447378330498619919154502317914469485801874390148357919248 * α ^ 21 * (17 - α) ^ 17 + 985534144714139122250483741567233765101065359192115038605404874832119258 * α ^ 22 * (17 - α) ^ 16 + 1530417579360385957788702153622880731287836667255896423677766156573103972 * α ^ 23 * (17 - α) ^ 15 + 2032430461020079853532514261208602767750794542173780707088682857868910994 * α ^ 24 * (17 - α) ^ 14 + 2292218444285680589433098519469973212042230727005845801142745772952622648 * α ^ 25 * (17 - α) ^ 13 + 2178219997541878792508669700595426088654476354491195218415916040098361367 * α ^ 26 * (17 - α) ^ 12 + 1727949063757596178243483752801428201813213932341449769191552685893782458 * α ^ 27 * (17 - α) ^ 11 + 1131913488897144192892030857095843493930963307289300925015925127269708335 * α ^ 28 * (17 - α) ^ 10 + 605118754195259451063140144378285109492445949756638818759841365239660040 * α ^ 29 * (17 - α) ^ 9 + 261880298008050145266750753761576086552682439953827145257817540609824860 * α ^ 30 * (17 - α) ^ 8 + 92875679601113717412714391333499851806464327195844345337907650773348120 * α ^ 31 * (17 - α) ^ 7 + 29072995044312488455979921670033751326475480533216429941625836322969708 * α ^ 32 * (17 - α) ^ 6 + 9369857362358365457781039003340826933535211191808499527159369766606160 * α ^ 33 * (17 - α) ^ 5 + 3266469696161126128466003284878933770066029563371692346986063283168790 * α ^ 34 * (17 - α) ^ 4 + 1021356923480101951479641774555034890704687659508130011121545901779380 * α ^ 35 * (17 - α) ^ 3 + 230938112747876039693246783422362329462732319382520584715540384755870 * α ^ 36 * (17 - α) ^ 2 + 31563581230674524529692712927313637685716918468331288776448654765600 * α ^ 37 * (17 - α) ^ 1 + 1919753133109689509058670629650134022172078593720565270277159571400 * α ^ 38 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 38)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 40 ≤ n) (h1 : n ≤ 41) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (653328533869198792815460418567456328463360027860000 + 4157882298167732116226370617284188848212873011241200 * α + 12532182988010399386002617462745633312768152237121570 * α ^ 2 + 23778313854745445633723704693422676769304621097023060 * α ^ 3 + 31839691004956228828005033576674262680347642949789970 * α ^ 4 + 31966947875077850162540664582127534223677059725715480 * α ^ 5 + 24954452263842718944480719755732872419125467194310990 * α ^ 6 + 15498456398852386516930447507216103141023058978163900 * α ^ 7 + 7770525510255924837049186376423929043180641908035178 * α ^ 8 + 3172282421659051612506049390871943668830947112996128 * α ^ 9 + 1058580212642493803810630674822381941853484677345557 * α ^ 10 + 288603554681274589435804606029301359165948874522986 * α ^ 11 + 63964171378367904791712568423672278670444648520985 * α ^ 12 + 11403554558448059539985445321284291979921951939708 * α ^ 13 + 1604683068013899575897130419685118852646893739688 * α ^ 14 + 171973766788073602692262435759609700705097645552 * α ^ 15 + 12777319017916275759622043304057680904260665896 * α ^ 16 + 232511338229217727198624028718607742301689616 * α ^ 17 - 736152391583269859036039443814447014605197787 * α ^ 18 + 32344027389559443630831441714104468449897746 * α ^ 19 + 226192739078384191702850277844962783099369 * α ^ 20 + 21321388850847068435151126284573459826132 * α ^ 21 + 1002825060545767936823647697965569833484 * α ^ 22 + 20605096429138626101144518690493027136 * α ^ 23 - 588379321688541475027751329888140192 * α ^ 24 - 68916522458163479393324809629479808 * α ^ 25 - 3219999749177967431080752136593024 * α ^ 26 - 101984865798504570834320095942656 * α ^ 27 - 2433981075208899701339322164736 * α ^ 28 - 45526079756647968714698102784 * α ^ 29 - 678401876172921453922277376 * α ^ 30 - 8091691517611230731255808 * α ^ 31 - 76978691001245722632192 * α ^ 32 - 577480811034021101568 * α ^ 33 - 3345672064015171584 * α ^ 34 - 14456978064408576 * α ^ 35 - 43900332474368 * α ^ 36 - 83629441024 * α ^ 37 - 75235328 * α ^ 38) / (780218937072834586624023381831090266352000 * (3 + α) ^ 19) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B40_41 diff --git a/Sendov/FiniteRange/Degree42_43.lean b/Sendov/FiniteRange/Degree42_43.lean index eefe264..e605f05 100644 --- a/Sendov/FiniteRange/Degree42_43.lean +++ b/Sendov/FiniteRange/Degree42_43.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 42 to 43 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 40 * (1280928413415314397834869540387070773955050164531041030 + 8579596886133703000731870831081948314922065693350883370 * α + 27292297105154921952287403075281892231896279402880100950 * α ^ 2 + 54824009941858550176912358984664841592247597016637905770 * α ^ 3 + 77993650469489645959523814188253045468476206212378807150 * α ^ 4 + 83524935090318289329452750100125758268073947901595075110 * α ^ 5 + 69864044339248988241671793073316243248508325653371578960 * α ^ 6 + 46735744905970337877740011413866843308996677044757141876 * α ^ 7 + 25392412342651970229153408582081225972535817324636108157 * α ^ 8 + 11314456845720888558092495939704512751963595258860145451 * α ^ 9 + 4156583831931947231874280330967249614130082308880369711 * α ^ 10 + 1260841374442113914894353137980805411382131606623222097 * α ^ 11 + 315103088046242389807187425423229491723179974811052320 * α ^ 12 + 64474796856269342035203905269807575254628539228620830 * α ^ 13 + 10677851103479065036063092086580878016800993639429844 * α ^ 14 + 1403715274370741006129430385190458757679221958797478 * α ^ 15 + 141371440744366093378881819780110077583832470458881 * α ^ 16 + 9967433380699679025437124999852577310642665327515 * α ^ 17 + 193067019640064558163668388981876117360705214251 * α ^ 18 - 526348205714148288340590540843861549545919252135 * α ^ 19 + 21747004181067783415574645835305370950903835816 * α ^ 20 + 112680245244072016728446540389593488784136590 * α ^ 21 + 11981738273725154350817268365041623637172994 * α ^ 22 + 613973728602142293085684365363276715529976 * α ^ 23 + 15948973394297291153786386954935347707464 * α ^ 24 - 107684213318232680083685034683113736832 * α ^ 25 - 31027964293347059199661593149947343808 * α ^ 26 - 1633467609886255958992085630289238016 * α ^ 27 - 55350060514047685232072125284311296 * α ^ 28 - 1399005645314407761350477999499264 * α ^ 29 - 27739113827411317709592921773056 * α ^ 30 - 440917774047260414297889849344 * α ^ 31 - 5667329623457291353154629632 * α ^ 32 - 58939961119748330433282048 * α ^ 33 - 492976521437911894081536 * α ^ 34 - 3273203375389549068288 * α ^ 35 - 16876898137105432576 * α ^ 36 - 65205684590477312 * α ^ 37 - 177752858296320 * α ^ 38 - 305048059904 * α ^ 39 - 247988224 * α ^ 40) = 1280928413415314397834869540387070773955050164531041030 * (17 - α) ^ 40 + 197090283600885526925836585743875952311877123368206658490 * α ^ 1 * (17 - α) ^ 39 + 14574870761360362764007488091265713791496293430458196852260 * α ^ 2 * (17 - α) ^ 38 + 689807122352331972850018568182567669403146541709879062869200 * α ^ 3 * (17 - α) ^ 37 + 23474981116788659940295903209229597513213621976643052103205180 * α ^ 4 * (17 - α) ^ 36 + 611866838450106888263269653882018737667714606579935222429231160 * α ^ 5 * (17 - α) ^ 35 + 12704966108874081414158869474590380254978128823530400951437383070 * α ^ 6 * (17 - α) ^ 34 + 215835205701475999098573854286109430455663338527171355584817462378 * α ^ 7 * (17 - α) ^ 33 + 3057463015648964051048726715818912718934404644565989436353377379661 * α ^ 8 * (17 - α) ^ 32 + 36627145478607558025819186137856364423514446441125420313957605902195 * α ^ 9 * (17 - α) ^ 31 + 375047859308149340518089344648422780629330440775991914316145068984356 * α ^ 10 * (17 - α) ^ 30 + 3309722847734299600989754701031358954177490834341008198660668294423486 * α ^ 11 * (17 - α) ^ 29 + 25334280905778547167991484601858053756995044929407956045911106763735047 * α ^ 12 * (17 - α) ^ 28 + 169053231472854221672538042658045160250622512820809581036739296186604987 * α ^ 13 * (17 - α) ^ 27 + 987295696101506016750123997135936935428967974131049275929891243289099020 * α ^ 14 * (17 - α) ^ 26 + 5061855600544715172298535944485508872496786942997547092399772690908724552 * α ^ 15 * (17 - α) ^ 25 + 22836459878606542127997069590698683872398300158025332179037971805498008466 * α ^ 16 * (17 - α) ^ 24 + 90815511641941473829215661492687510352960775737402151799341783414491782134 * α ^ 17 * (17 - α) ^ 23 + 318734183329134027469187419914043420985326381868548104315467322483762890280 * α ^ 18 * (17 - α) ^ 22 + 987849647539835196212635720362290798791340169209853062676349181616504012372 * α ^ 19 * (17 - α) ^ 21 + 2702794013053376717386235575702898281842016607777011413996179654284315020276 * α ^ 20 * (17 - α) ^ 20 + 6518481722287093687872286675516248686966900062551161802625983585543325193064 * α ^ 21 * (17 - α) ^ 19 + 13819577825963737277443482404663949106919306450306673694620269914296761836662 * α ^ 22 * (17 - α) ^ 18 + 25656213473396052436767203417861850495715135024347044339699650611836313451386 * α ^ 23 * (17 - α) ^ 17 + 41518212269954562717893522706197113635871186246049005811923337699275786209441 * α ^ 24 * (17 - α) ^ 16 + 58264237368783003337224503745095851911428895082867699051272864692889281810823 * α ^ 25 * (17 - α) ^ 15 + 70509961613749498938328718833682422186993284582226371629980357718310864201564 * α ^ 26 * (17 - α) ^ 14 + 73129293701134101287464321060861793455351594458440621340710860077426859412246 * α ^ 27 * (17 - α) ^ 13 + 64542036519874264738723665643239022405337439766598405390089713472010764525231 * α ^ 28 * (17 - α) ^ 12 + 48068721003017849550137162829500406726021869001249651041646233420511089834739 * α ^ 29 * (17 - α) ^ 11 + 29908472648708029501911019147420406642840298425192025295010509794183714590200 * α ^ 30 * (17 - α) ^ 10 + 15366480688785955559510007565183167290828149965129842034139827497171629495988 * α ^ 31 * (17 - α) ^ 9 + 6442852602434353997138149389259641709926610254417225973756279884877273521210 * α ^ 32 * (17 - α) ^ 8 + 2192109403287939599157040147405748715444730026475711367949290093543157305286 * α ^ 33 * (17 - α) ^ 7 + 617553044098254770008870419213467265211621023542309177891008000912439731428 * α ^ 34 * (17 - α) ^ 6 + 156511669279787056670653626987150971088769146525896634427590110835904143048 * α ^ 35 * (17 - α) ^ 5 + 40425174529035112350411546621406361023805738975780328231031555794395201242 * α ^ 36 * (17 - α) ^ 4 + 10426184083634003349248930440636043818034523209966796671645165924159912258 * α ^ 37 * (17 - α) ^ 3 + 2178083492795567226675987694618231233066113322011885814782838606188228664 * α ^ 38 * (17 - α) ^ 2 + 290493393201934314395217100992245864671975635874035159763234167124538720 * α ^ 39 * (17 - α) ^ 1 + 17674868145691221378279476901019271057432085542810612311003098402179200 * α ^ 40 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 40)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 42 ≤ n) (h1 : n ≤ 43) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (1280928413415314397834869540387070773955050164531041030 + 8579596886133703000731870831081948314922065693350883370 * α + 27292297105154921952287403075281892231896279402880100950 * α ^ 2 + 54824009941858550176912358984664841592247597016637905770 * α ^ 3 + 77993650469489645959523814188253045468476206212378807150 * α ^ 4 + 83524935090318289329452750100125758268073947901595075110 * α ^ 5 + 69864044339248988241671793073316243248508325653371578960 * α ^ 6 + 46735744905970337877740011413866843308996677044757141876 * α ^ 7 + 25392412342651970229153408582081225972535817324636108157 * α ^ 8 + 11314456845720888558092495939704512751963595258860145451 * α ^ 9 + 4156583831931947231874280330967249614130082308880369711 * α ^ 10 + 1260841374442113914894353137980805411382131606623222097 * α ^ 11 + 315103088046242389807187425423229491723179974811052320 * α ^ 12 + 64474796856269342035203905269807575254628539228620830 * α ^ 13 + 10677851103479065036063092086580878016800993639429844 * α ^ 14 + 1403715274370741006129430385190458757679221958797478 * α ^ 15 + 141371440744366093378881819780110077583832470458881 * α ^ 16 + 9967433380699679025437124999852577310642665327515 * α ^ 17 + 193067019640064558163668388981876117360705214251 * α ^ 18 - 526348205714148288340590540843861549545919252135 * α ^ 19 + 21747004181067783415574645835305370950903835816 * α ^ 20 + 112680245244072016728446540389593488784136590 * α ^ 21 + 11981738273725154350817268365041623637172994 * α ^ 22 + 613973728602142293085684365363276715529976 * α ^ 23 + 15948973394297291153786386954935347707464 * α ^ 24 - 107684213318232680083685034683113736832 * α ^ 25 - 31027964293347059199661593149947343808 * α ^ 26 - 1633467609886255958992085630289238016 * α ^ 27 - 55350060514047685232072125284311296 * α ^ 28 - 1399005645314407761350477999499264 * α ^ 29 - 27739113827411317709592921773056 * α ^ 30 - 440917774047260414297889849344 * α ^ 31 - 5667329623457291353154629632 * α ^ 32 - 58939961119748330433282048 * α ^ 33 - 492976521437911894081536 * α ^ 34 - 3273203375389549068288 * α ^ 35 - 16876898137105432576 * α ^ 36 - 65205684590477312 * α ^ 37 - 177752858296320 * α ^ 38 - 305048059904 * α ^ 39 - 247988224 * α ^ 40) / (508824949463896030944977981473879851039376800 * (3 + α) ^ 20) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B42_43 diff --git a/Sendov/FiniteRange/Degree44_45.lean b/Sendov/FiniteRange/Degree44_45.lean index ed88b9c..535bae3 100644 --- a/Sendov/FiniteRange/Degree44_45.lean +++ b/Sendov/FiniteRange/Degree44_45.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 44 to 45 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 42 * (234355849074955263951049856572420428528087559257217338000 + 1647917825991745087828090979449220009324402935342213794192 * α + 5517259206635462357799308151379743852022400880405143709300 * α ^ 2 + 11697286850057325472448884282596125036178461096427071180160 * α ^ 3 + 17618194225546020573784427664650585416610740635319786403400 * α ^ 4 + 20046068608053045224231426681510601856273741292025591141480 * α ^ 5 + 17885461556571898483672892064956643539473640662999345701666 * α ^ 6 + 12820152657712533249363000294926617606868677915971896670240 * α ^ 7 + 7502523555651917287805352494007861019866814933742609160696 * α ^ 8 + 3622686298843516098851206612510488687148684155393129482472 * α ^ 9 + 1452571052316260978855070270500133585694231422375833061090 * α ^ 10 + 485064610274304784360415817487598469472479148412401415808 * α ^ 11 + 134868827326575807784515799657395435527619954194004227748 * α ^ 12 + 31113923159253038634767916248106358904477281041358348956 * α ^ 13 + 5912609861703141760519754094833940739302488844248812479 * α ^ 14 + 914297729950293095944937323513702712183136890515661088 * α ^ 15 + 112786258002906693411402876201621614411462995639363644 * α ^ 16 + 10715561597079704979556413609803278787797162405942296 * α ^ 17 + 719193622230655390355126847425184862615908011115060 * α ^ 18 + 14657836127065470780938993503699490899434597229512 * α ^ 19 - 34950338977013178639767569738567864677193896372240 * α ^ 20 + 1366801847725067991778952117668601561839569590900 * α ^ 21 + 4959220152208557382027853908303681091859164175 * α ^ 22 + 615471404273198116343750989411396892897296680 * α ^ 23 + 34101039377472481958974903669374217452733632 * α ^ 24 + 1034386808344405409707750019488517511355008 * α ^ 25 + 5291527796743143896670464285156657893296 * α ^ 26 - 1219504316386418556368987826914293621248 * α ^ 27 - 75185184777106907253176174218461272832 * α ^ 28 - 2739147805326680629369630717760523264 * α ^ 29 - 73210280752772515350101169959614464 * α ^ 30 - 1531828473996677645738094611644416 * α ^ 31 - 25792432980458262033466819153920 * α ^ 32 - 353823743440056079889063264256 * α ^ 33 - 3970096169377863374039531520 * α ^ 34 - 36356947826301657371639808 * α ^ 35 - 269616704004970519658496 * α ^ 36 - 1596209219881105096704 * α ^ 37 - 7373431975900938240 * α ^ 38 - 25626639771107328 * α ^ 39 - 63065268682752 * α ^ 40 - 98008301568 * α ^ 41 - 72351744 * α ^ 42) = 234355849074955263951049856572420428528087559257217338000 * (17 - α) ^ 42 + 37857548703007787579021640626678398156694527389620762697264 * α ^ 1 * (17 - α) ^ 41 + 2944867021487431429882033394933706308696266088891073674557524 * α ^ 2 * (17 - α) ^ 40 + 146910666364742997856783011317318114681608355643172977318910560 * α ^ 3 * (17 - α) ^ 39 + 5281338930363712858347930254940637802165598810816949523191508760 * α ^ 4 * (17 - α) ^ 38 + 145753437649734017761868379170413156812750014126479617274091172120 * α ^ 5 * (17 - α) ^ 37 + 3212433660877561136639288711614882650266994711330586733979437268666 * α ^ 6 * (17 - α) ^ 36 + 58080099103816679194960077966232290827409612456400212654077549294136 * α ^ 7 * (17 - α) ^ 35 + 878073000124467105754351061548458968812316660181611332798436479232076 * α ^ 8 * (17 - α) ^ 34 + 11259922048324651489289493311309309631891001644523667321376037356186888 * α ^ 9 * (17 - α) ^ 33 + 123812154859041152773858816918455744865935561732076455885319152132304488 * α ^ 10 * (17 - α) ^ 32 + 1177282729304429087196944522508776379491442707108602485795557386562286720 * α ^ 11 * (17 - α) ^ 31 + 9744718648999432569661305582435950678261853364124701152000275689844790852 * α ^ 12 * (17 - α) ^ 30 + 70584478999572099526210718832986814594230665767170003296124002517210218548 * α ^ 13 * (17 - α) ^ 29 + 449272053601042666671596079622675645227192899930246481044206503873022598127 * α ^ 14 * (17 - α) ^ 28 + 2521166194604692753878031098107876914463687672229082966575780993950448786492 * α ^ 15 * (17 - α) ^ 27 + 12505743633148390302761257035504316007036914113543301212072536616680265609966 * α ^ 16 * (17 - α) ^ 26 + 54941752319236926994034527846178330055107665824491889262114770438776772080688 * α ^ 17 * (17 - α) ^ 25 + 214108133336419833203656668659528095997912595237383503399365023725947428991765 * α ^ 18 * (17 - α) ^ 24 + 740907981283804161674373017608569262860463894016142577208923888370995315389936 * α ^ 19 * (17 - α) ^ 23 + 2278016136661934557373907941895735701975033136406032948359780173720186398978768 * α ^ 20 * (17 - α) ^ 22 + 6223044015900732285273426821948491350903940514086744466166738234457122088918648 * α ^ 21 * (17 - α) ^ 21 + 15091573130026048461544325185690904741676446061897994842743984569608882476868246 * α ^ 22 * (17 - α) ^ 20 + 32431472815063210198529045051946172792892281829735717630866526639188278809402520 * α ^ 23 * (17 - α) ^ 19 + 61589977160019028252201500272191461481719309803518295921163839432202796081677436 * α ^ 24 * (17 - α) ^ 18 + 103000834533491129063640284036092678067268542010637673258239410761540957030115384 * α ^ 25 * (17 - α) ^ 17 + 151071516679099175443820464035839365942459349434188215403085360254317550609833028 * α ^ 26 * (17 - α) ^ 16 + 193445346233280859296440806414848722181948957409609959791787404726401564917282096 * α ^ 27 * (17 - α) ^ 15 + 215172096945268414340053333093031776453400001175778749956470312358926404221592428 * α ^ 28 * (17 - α) ^ 14 + 206736790098352378662725797487880027357919714030453368776992727928497863099548756 * α ^ 29 * (17 - α) ^ 13 + 170462524827332695320086649521380810293612989490733605162878601757384672794284747 * α ^ 30 * (17 - α) ^ 12 + 119693210823537512228591503646550664793242492067851215311990782497984104429398428 * α ^ 31 * (17 - α) ^ 11 + 70908831093339465886818052612765873755388314931239009902767176459421394442785742 * α ^ 32 * (17 - α) ^ 10 + 35048237403311100028743507259452310464158209931947679191434306115144076602284800 * α ^ 33 * (17 - α) ^ 9 + 14268450259765073448679759926668655504802778135164107658390044566561421617189673 * α ^ 34 * (17 - α) ^ 8 + 4724185205300768110792705712599630650015863880955341087853206634323491488643616 * α ^ 35 * (17 - α) ^ 7 + 1265299135971789660909673234797601828374717278246484983747256160401664255750872 * α ^ 36 * (17 - α) ^ 6 + 280178539570804945484739775418806390334413870080009334057823189831955617940552 * α ^ 37 * (17 - α) ^ 5 + 55439566906689638975335374901816806066147146428085261656377329665751391494454 * α ^ 38 * (17 - α) ^ 4 + 10724868311110483392855160615399587116240195810586300982060213202048731748152 * α ^ 39 * (17 - α) ^ 3 + 1891608447746568174857958621996992326295338311284555046921110287910697380220 * α ^ 40 * (17 - α) ^ 2 + 236532288128129299669916971619583813438473071647279968567818223819695392000 * α ^ 41 * (17 - α) ^ 1 + 14180011930716980449379240294714564887587943224073955569876816155335397250 * α ^ 42 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 42)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 44 ≤ n) (h1 : n ≤ 45) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (234355849074955263951049856572420428528087559257217338000 + 1647917825991745087828090979449220009324402935342213794192 * α + 5517259206635462357799308151379743852022400880405143709300 * α ^ 2 + 11697286850057325472448884282596125036178461096427071180160 * α ^ 3 + 17618194225546020573784427664650585416610740635319786403400 * α ^ 4 + 20046068608053045224231426681510601856273741292025591141480 * α ^ 5 + 17885461556571898483672892064956643539473640662999345701666 * α ^ 6 + 12820152657712533249363000294926617606868677915971896670240 * α ^ 7 + 7502523555651917287805352494007861019866814933742609160696 * α ^ 8 + 3622686298843516098851206612510488687148684155393129482472 * α ^ 9 + 1452571052316260978855070270500133585694231422375833061090 * α ^ 10 + 485064610274304784360415817487598469472479148412401415808 * α ^ 11 + 134868827326575807784515799657395435527619954194004227748 * α ^ 12 + 31113923159253038634767916248106358904477281041358348956 * α ^ 13 + 5912609861703141760519754094833940739302488844248812479 * α ^ 14 + 914297729950293095944937323513702712183136890515661088 * α ^ 15 + 112786258002906693411402876201621614411462995639363644 * α ^ 16 + 10715561597079704979556413609803278787797162405942296 * α ^ 17 + 719193622230655390355126847425184862615908011115060 * α ^ 18 + 14657836127065470780938993503699490899434597229512 * α ^ 19 - 34950338977013178639767569738567864677193896372240 * α ^ 20 + 1366801847725067991778952117668601561839569590900 * α ^ 21 + 4959220152208557382027853908303681091859164175 * α ^ 22 + 615471404273198116343750989411396892897296680 * α ^ 23 + 34101039377472481958974903669374217452733632 * α ^ 24 + 1034386808344405409707750019488517511355008 * α ^ 25 + 5291527796743143896670464285156657893296 * α ^ 26 - 1219504316386418556368987826914293621248 * α ^ 27 - 75185184777106907253176174218461272832 * α ^ 28 - 2739147805326680629369630717760523264 * α ^ 29 - 73210280752772515350101169959614464 * α ^ 30 - 1531828473996677645738094611644416 * α ^ 31 - 25792432980458262033466819153920 * α ^ 32 - 353823743440056079889063264256 * α ^ 33 - 3970096169377863374039531520 * α ^ 34 - 36356947826301657371639808 * α ^ 35 - 269616704004970519658496 * α ^ 36 - 1596209219881105096704 * α ^ 37 - 7373431975900938240 * α ^ 38 - 25626639771107328 * α ^ 39 - 63065268682752 * α ^ 40 - 98008301568 * α ^ 41 - 72351744 * α ^ 42) / (30972068525792759965739480222844093512456083008 * (3 + α) ^ 21) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B44_45 diff --git a/Sendov/FiniteRange/Degree46_47.lean b/Sendov/FiniteRange/Degree46_47.lean index 8b58e0e..c990f1b 100644 --- a/Sendov/FiniteRange/Degree46_47.lean +++ b/Sendov/FiniteRange/Degree46_47.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 46 to 47 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 44 * (842100496490164655863899050953513048577517889022827148437500 + 6202389537263705762292576691419085693567510900497436523437500 * α + 21800976172966131822633999416830068976610560420989990234375000 * α ^ 2 + 48647779340585710046299723714124054163748508466339111328125000 * α ^ 3 + 77335744367973576659808264003823907539197097243080139160156250 * α ^ 4 + 93163317164153721286069997796054376135656931010389709472656250 * α ^ 5 + 88315055516249458646175698818625653153167262528008728027343750 * α ^ 6 + 67525482393603249349320023657815936540710634750331726074218750 * α ^ 7 + 42343249160820224575714518101180101058857691214973571777343750 * α ^ 8 + 22022629774039619130278840067223760137223751259001110839843750 * α ^ 9 + 9569037722124326061646207068547925124389847238604876953125000 * α ^ 10 + 3487611243366543917723910686246986580789320695836231250000000 * α ^ 11 + 1067491157924455805861448662311325524405538803060341943359375 * α ^ 12 + 273968142184015848925560036581877108638855706237317490234375 * α ^ 13 + 58692019460587884114525551639474562464674600041476138671875 * α ^ 14 + 10411576695976844279717630513220926151802953315673888359375 * α ^ 15 + 1509986509025418223518044667529937663568415780777702125000 * α ^ 16 + 175469918947028739649743022943799878357086029596651812500 * α ^ 17 + 15779760028253605454031412572296146026014740194967383750 * α ^ 18 + 1010913062001619607789595546144718629262771585185507750 * α ^ 19 + 21462061397781700126941815631803690593259676260498115 * α ^ 20 - 45387057094906818237348334721211459766084329446075757 * α ^ 21 + 1689541722499339437202551579490531894232999398986279 * α ^ 22 + 3936001560036108693341101447415785391643174835443 * α ^ 23 + 607977630486171911031424776719828152869889423044 * α ^ 24 + 36336260809521268434231902077696447132341347400 * α ^ 25 + 1235785272488557483704068508469144496017205184 * α ^ 26 + 15739109405711750147519445570667095018389712 * α ^ 27 - 844836507113777181276666926325076953789696 * α ^ 28 - 65867488403154309232905535325099415940608 * α ^ 29 - 2603492828180830946162421054768504476160 * α ^ 30 - 73591830258372192880755514270838320128 * α ^ 31 - 1619902372241517858218483163123738624 * α ^ 32 - 28740854840777906929998653281886208 * α ^ 33 - 417683720829155224442216354095104 * α ^ 34 - 5006133645480122906718714101760 * α ^ 35 - 49524449888141405612129746944 * α ^ 36 - 402720876040696001365082112 * α ^ 37 - 2667361119757440577634304 * α ^ 38 - 14172645073027210739712 * α ^ 39 - 59000480246059499520 * α ^ 40 - 185464776902049792 * α ^ 41 - 414106827882496 * α ^ 42 - 585532178432 * α ^ 43 - 394264576 * α ^ 44) = 842100496490164655863899050953513048577517889022827148437500 * (17 - α) ^ 44 + 142493043979050242816985361996079030928058472425460815429687500 * α ^ 1 * (17 - α) ^ 43 + 11631055935406676773424347895093264920192634352945327758789062500 * α ^ 2 * (17 - α) ^ 42 + 609992449449811389379816851349777566641910911240855026245117187500 * α ^ 3 * (17 - α) ^ 41 + 23098700643661062063264209577856576688439492919078299293518066406250 * α ^ 4 * (17 - α) ^ 40 + 672886788673347303113646845460420332103897531976657897846984863281250 * α ^ 5 * (17 - α) ^ 39 + 15689183510706334336751155501240168225930150393352115080165405273437500 * α ^ 6 * (17 - α) ^ 38 + 300787141414416123262875017253530680535010772323084607526017456054687500 * α ^ 7 * (17 - α) ^ 37 + 4834082125229902229160089626065942580696829879116404068575523803710937500 * α ^ 8 * (17 - α) ^ 36 + 66072765878867110841147420893730369943336026053933255103129270288085937500 * α ^ 9 * (17 - α) ^ 35 + 776562148162541303792514188712949580055222798582046568076665765594238281250 * α ^ 10 * (17 - α) ^ 34 + 7916165993961948987449580340899456664926175109154616993743620562742089843750 * α ^ 11 * (17 - α) ^ 33 + 70468708978108892817571764541075442041839869106980895974143854170172216796875 * α ^ 12 * (17 - α) ^ 32 + 550782470594884966715313206866948703867564604566371289578563249171289130859375 * α ^ 13 * (17 - α) ^ 31 + 3796271005225225067290420328594083801226095054076152502460026076879075960937500 * α ^ 14 * (17 - α) ^ 30 + 23154951045516208632207010063622078794447604241421409800591507255675276447500000 * α ^ 15 * (17 - α) ^ 29 + 125329005241909283645244852767369785798817688336457585844713864177983765701578125 * α ^ 16 * (17 - α) ^ 28 + 603309363715139594521494665743634826511126981458830526026064579534478738308515625 * α ^ 17 * (17 - α) ^ 27 + 2587364175724392722746563574797525717547108337555060272594625213670122377224922500 * α ^ 18 * (17 - α) ^ 26 + 9898549256162510047261715675023148365372355380576229013767998580288842214641264500 * α ^ 19 * (17 - α) ^ 25 + 33813519196392670210313059666995142454669959269244976653953740675056602158569578990 * α ^ 20 * (17 - α) ^ 24 + 103196149479405719489529062495189947552780951823855220313054805583706227764000739366 * α ^ 21 * (17 - α) ^ 23 + 281414632953734490932383578025410664595174480569956516679000280734682217487402570284 * α ^ 22 * (17 - α) ^ 22 + 685395337547723093442698987180372896387216615945658732837662652249972601215820937644 * α ^ 23 * (17 - α) ^ 21 + 1489149662951024487101091584274360794704873551266921796745007333128807261864150039440 * α ^ 24 * (17 - α) ^ 20 + 2880717800764736562237157455028656259513844924473937460829052015392479287411749584000 * α ^ 25 * (17 - α) ^ 19 + 4948638359187857502444997471872385263341628692259466992165339970591851807662058176250 * α ^ 26 * (17 - α) ^ 18 + 7524808365437321671268164297839989387020638669389928036404610340476432390943699968750 * α ^ 27 * (17 - α) ^ 17 + 10090745730787017626963337198418905561056134794018935219523451765642743556242036084375 * α ^ 28 * (17 - α) ^ 16 + 11884304827785561031887161390332218762155951913733146752455369428108543693253527796875 * α ^ 29 * (17 - α) ^ 15 + 12236134768064187298824467090486239622825767135842989738867807258895895376319098437500 * α ^ 30 * (17 - α) ^ 14 + 10956342185947834383371522495075810215688468611001591955872795308997953700512875000000 * α ^ 31 * (17 - α) ^ 13 + 8480200760430773875569783935490297001453280452983110658282869458743468575057900390625 * α ^ 32 * (17 - α) ^ 12 + 5633029575677093237429398107221916268853414367970165464924058295269805975873642578125 * α ^ 33 * (17 - α) ^ 11 + 3183457062375806825326758077695313148081656523121607548560593992595734846529882812500 * α ^ 34 * (17 - α) ^ 10 + 1514534325584221507212883373649465749871038738085239693277104497573823324223632812500 * α ^ 35 * (17 - α) ^ 9 + 598855676703127526215866064910890958440342074461336641457617262869261681970214843750 * α ^ 36 * (17 - α) ^ 8 + 193895710320064143314152952928304080530489756415618625370542369927247228210449218750 * α ^ 37 * (17 - α) ^ 7 + 50633726898981387585795045476023804360885506077389009794334574956167921386718750000 * α ^ 38 * (17 - α) ^ 6 + 10572386406974364669523632230312278886927530949116535421326834315982454833984375000 * α ^ 39 * (17 - α) ^ 5 + 1792713553761047052220517000286370236664409834359847244425465316189674377441406250 * α ^ 40 * (17 - α) ^ 4 + 262340726959871612498380595594270897589647597255618313914727785960884094238281250 * α ^ 41 * (17 - α) ^ 3 + 34914711121164009908327832512530464932432901098435282301515528343963623046875000 * α ^ 42 * (17 - α) ^ 2 + 3721215228917653403021576873516894679349471790204206905261547785186767578125000 * α ^ 43 * (17 - α) ^ 1 + 210713180134643197170850407242377156075926959031893252124925369262695312500000 * α ^ 44 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 44)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 46 ≤ n) (h1 : n ≤ 47) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (842100496490164655863899050953513048577517889022827148437500 + 6202389537263705762292576691419085693567510900497436523437500 * α + 21800976172966131822633999416830068976610560420989990234375000 * α ^ 2 + 48647779340585710046299723714124054163748508466339111328125000 * α ^ 3 + 77335744367973576659808264003823907539197097243080139160156250 * α ^ 4 + 93163317164153721286069997796054376135656931010389709472656250 * α ^ 5 + 88315055516249458646175698818625653153167262528008728027343750 * α ^ 6 + 67525482393603249349320023657815936540710634750331726074218750 * α ^ 7 + 42343249160820224575714518101180101058857691214973571777343750 * α ^ 8 + 22022629774039619130278840067223760137223751259001110839843750 * α ^ 9 + 9569037722124326061646207068547925124389847238604876953125000 * α ^ 10 + 3487611243366543917723910686246986580789320695836231250000000 * α ^ 11 + 1067491157924455805861448662311325524405538803060341943359375 * α ^ 12 + 273968142184015848925560036581877108638855706237317490234375 * α ^ 13 + 58692019460587884114525551639474562464674600041476138671875 * α ^ 14 + 10411576695976844279717630513220926151802953315673888359375 * α ^ 15 + 1509986509025418223518044667529937663568415780777702125000 * α ^ 16 + 175469918947028739649743022943799878357086029596651812500 * α ^ 17 + 15779760028253605454031412572296146026014740194967383750 * α ^ 18 + 1010913062001619607789595546144718629262771585185507750 * α ^ 19 + 21462061397781700126941815631803690593259676260498115 * α ^ 20 - 45387057094906818237348334721211459766084329446075757 * α ^ 21 + 1689541722499339437202551579490531894232999398986279 * α ^ 22 + 3936001560036108693341101447415785391643174835443 * α ^ 23 + 607977630486171911031424776719828152869889423044 * α ^ 24 + 36336260809521268434231902077696447132341347400 * α ^ 25 + 1235785272488557483704068508469144496017205184 * α ^ 26 + 15739109405711750147519445570667095018389712 * α ^ 27 - 844836507113777181276666926325076953789696 * α ^ 28 - 65867488403154309232905535325099415940608 * α ^ 29 - 2603492828180830946162421054768504476160 * α ^ 30 - 73591830258372192880755514270838320128 * α ^ 31 - 1619902372241517858218483163123738624 * α ^ 32 - 28740854840777906929998653281886208 * α ^ 33 - 417683720829155224442216354095104 * α ^ 34 - 5006133645480122906718714101760 * α ^ 35 - 49524449888141405612129746944 * α ^ 36 - 402720876040696001365082112 * α ^ 37 - 2667361119757440577634304 * α ^ 38 - 14172645073027210739712 * α ^ 39 - 59000480246059499520 * α ^ 40 - 185464776902049792 * α ^ 41 - 414106827882496 * α ^ 42 - 585532178432 * α ^ 43 - 394264576 * α ^ 44) / (37032941535730355418797437426924667358398437500000 * (3 + α) ^ 22) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B46_47 diff --git a/Sendov/FiniteRange/Degree48_49.lean b/Sendov/FiniteRange/Degree48_49.lean index 791e8cf..dcd02d3 100644 --- a/Sendov/FiniteRange/Degree48_49.lean +++ b/Sendov/FiniteRange/Degree48_49.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 48 to 49 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 46 * (7591199764941595142535047667167496055166615766339109753578898560 + 58444846237165943551279131377341207077328035296269812484322869920 * α + 215183176025506919702531217941842711339737075266956526659211243010 * α ^ 2 + 504119825711981991953619761968878166062817925879996924390857878780 * α ^ 3 + 843499983730922829653379646526224878986727978586395545435732482710 * α ^ 4 + 1072503620634158239884244537293452959863774094675706145687308954160 * α ^ 5 + 1076446847966334979143656931502325139234331446767890824217309988610 * α ^ 6 + 874481274546832703168275213074859855200282043558515881767199205780 * α ^ 7 + 584940481506790593329950294203572360626072792868892731256510254790 * α ^ 8 + 325988305644965786771400276568642744850196724125639486229759912680 * α ^ 9 + 152567991163281517146520289154412206989708725501314740543815123242 * α ^ 10 + 60257769914462931158481100919633683041061465448481123420828204444 * α ^ 11 + 20129798805767351823723652441204102433547938067213802588532446662 * α ^ 12 + 5687016607145482595882099777086733334514360250477330630445824496 * α ^ 13 + 1355278557647407824791108174949033065263401718280146352590299132 * α ^ 14 + 271000424772480840244816322457048834002540366106552011600103312 * α ^ 15 + 45077206161318041189379028469239391861894842436881282720631712 * α ^ 16 + 6155423822307023556988091783956120485240591022903519939638936 * α ^ 17 + 676142880398770802271995740973508628770999664408861891669293 * α ^ 18 + 57725697116366115637265587909635903325806420371494216534326 * α ^ 19 + 3538202264412216996329718883610558594067822140944030875519 * α ^ 20 + 77574873286609722098225332819487251209357565591548524952 * α ^ 21 - 147315204845101536255433762427937191325421411462459722039 * α ^ 22 + 5245361991102819530624768487527000682291303265286717178 * α ^ 23 + 6658544653474755689275786385563045545487294797590331 * α ^ 24 + 1472968109561870214375834133381327743623319061135332 * α ^ 25 + 95171634843015522566439274462655369397323761963548 * α ^ 26 + 3545966415236624759599391868158380053883553245824 * α ^ 27 + 64377156482122958948701739689394929584223299312 * α ^ 28 - 1168656375434360221238828101326004753556536896 * α ^ 29 - 139417680493330544069384288780944967009327424 * α ^ 30 - 6070430434653508552057016796802025839583232 * α ^ 31 - 181826034173641815543270617357206754251776 * α ^ 32 - 4202739957608852026901130257441189900288 * α ^ 33 - 78263006650153541891015915303985934336 * α ^ 34 - 1198002545218365750178026069831352320 * α ^ 35 - 15219010328713364070284371473793024 * α ^ 36 - 160981724807992562843830338977792 * α ^ 37 - 1415946326039159376655312551936 * α ^ 38 - 10298650421826586803585810432 * α ^ 39 - 61314611371788369779294208 * α ^ 40 - 294083659089512872280064 * α ^ 41 - 1109163402380295012352 * α ^ 42 - 3168884055181623296 * α ^ 43 - 6448929882243072 * α ^ 44 - 8332022644736 * α ^ 45 - 5138022400 * α ^ 46) = 7591199764941595142535047667167496055166615766339109753578898560 * (17 - α) ^ 46 + 1342757575219134416928357426104505338852240925288185860898118122400 * α ^ 1 * (17 - α) ^ 45 + 114755136999517997583283831824376925408437409071957821349973204728290 * α ^ 2 * (17 - α) ^ 44 + 6311871144666629761637230662569825452491581180312292712701296505455700 * α ^ 3 * (17 - α) ^ 43 + 251117021819028982864973145165014954053157643806880139740425434345397070 * α ^ 4 * (17 - α) ^ 42 + 7700255582992438800428557545327513666900681197124798184091430231098133960 * α ^ 5 * (17 - α) ^ 41 + 189367631135786370984279829668504339679999112172842699082163134760932823050 * α ^ 6 * (17 - α) ^ 40 + 3837299018002887727841264180140203196909974021427614251792467066036834514460 * α ^ 7 * (17 - α) ^ 39 + 65330193691266612095267419404574125266102388594982857701230218272237672614950 * α ^ 8 * (17 - α) ^ 38 + 948167953912606041527211234549432129570826851527171582246349949742846207580480 * α ^ 9 * (17 - α) ^ 37 + 11862897220186135053544305256945784922859357773863352679820145643098022220785278 * α ^ 10 * (17 - α) ^ 36 + 129072115915064352802998192157149959447544106737793242351888060162304851138395580 * α ^ 11 * (17 - α) ^ 35 + 1229795769892025833353618429128543962117904449244422243628303524212233499528414042 * α ^ 12 * (17 - α) ^ 34 + 10318568580638790387954818617820003753357917586903069070216576765343271409771487800 * α ^ 13 * (17 - α) ^ 33 + 76586524069802882894078032032353528016591779712305320570499363273565575419847624376 * α ^ 14 * (17 - α) ^ 32 + 504684151077635699819713494479495670799591999023571346450099800467157372095419250912 * α ^ 15 * (17 - α) ^ 31 + 2961464831656022935314311202766885642337479869778047028701398651217449033783743537080 * α ^ 16 * (17 - α) ^ 30 + 15511312927367844114034275848806344502776248279233504803062812081346091041874500312424 * α ^ 17 * (17 - α) ^ 29 + 72656111586338879343047119765015961893678349787522472371632798641470861566691804080505 * α ^ 18 * (17 - α) ^ 28 + 304808185012857975724498725531184620292840658826980992018187980322769269404048114731402 * α ^ 19 * (17 - α) ^ 27 + 1146590392326781377506836763538391565844743608196668993927537593446331465448235657881983 * α ^ 20 * (17 - α) ^ 26 + 3870600448216253864751392890281906184377072807016812087208519577192080210828017341041740 * α ^ 21 * (17 - α) ^ 25 + 11731891593652584393540855221982594836705418299405024828972301429357123143028053536434669 * α ^ 22 * (17 - α) ^ 24 + 31934660245093795505928032518461564485995557345717410206365628000458801939061533187363710 * α ^ 23 * (17 - α) ^ 23 + 78047993066241081864729405263799058714155198199791825458167970252230959614239365881878947 * α ^ 24 * (17 - α) ^ 22 + 171134843936218514686150148288359364686859698322647460634859632067734173140627231359730584 * α ^ 25 * (17 - α) ^ 21 + 336206506050303051354999483042669483751718653067431091525204950883403868367567684342080020 * α ^ 26 * (17 - α) ^ 20 + 590632297194451478800263563954322310467842994277133756163742170600614302732421283888959208 * α ^ 27 * (17 - α) ^ 19 + 925516670394461047649865831225821273518368307653384139954083832567847096613665974954102740 * α ^ 28 * (17 - α) ^ 18 + 1289766645595527592343166744587741066182934225995347417854162835114044818241870914092204864 * α ^ 29 * (17 - α) ^ 17 + 1593002416141247767069378716733631264077333099250896896091743214673847829299190958471833770 * α ^ 30 * (17 - α) ^ 16 + 1737143176643046947303118633436476715799207563792300127093284518020249525152200860365809660 * α ^ 31 * (17 - α) ^ 15 + 1665311418235579100523754798782860220365664075295289918982682336006446972368945219112765174 * α ^ 32 * (17 - α) ^ 14 + 1396557360038252731643454796992613166665272986910499262544165249742942020476375868362815880 * α ^ 33 * (17 - α) ^ 13 + 1018684619224015379084223520647127025765305887834183888331474942254858102069742927480803487 * α ^ 34 * (17 - α) ^ 12 + 641932494254295073687856899416231301192107297550335297051507507404266419546500180865404214 * α ^ 35 * (17 - α) ^ 11 + 346616023624199508122240528681160766975802934453336786297349998221685206774349480865493785 * α ^ 36 * (17 - α) ^ 10 + 158769464897392551896561203035439621044410847226907537961532798384360622001611952908266388 * α ^ 37 * (17 - α) ^ 9 + 60938188611726643632686961457984989878294641295998164978961810053640858299331163879730855 * α ^ 38 * (17 - α) ^ 8 + 19303965900462850327232871938264169200849651337482672284417001334177009419208937264542474 * α ^ 39 * (17 - α) ^ 7 + 4956495620088219287305017176528775890173857965129426190480342928881513904895208113754297 * α ^ 40 * (17 - α) ^ 6 + 1011094459778786182680868888323794915088603327243667761590423358931583382786018989420280 * α ^ 41 * (17 - α) ^ 5 + 161129362690984017597830623141137027326076650900522288728417841096952993030031822930852 * α ^ 42 * (17 - α) ^ 4 + 20053630683210270088939005261620316062127222962442862223177250670635839018815183419080 * α ^ 43 * (17 - α) ^ 3 + 2007106897711885365446090180299995728598915866332529016566715378067994766096351142716 * α ^ 44 * (17 - α) ^ 2 + 160682627900417809962527853098762123815034415286611690425666398978372619671902878336 * α ^ 45 * (17 - α) ^ 1 + 7728635588004831865654878836695725660660992895290133611955913220528766346904639440 * α ^ 46 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 46)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 48 ≤ n) (h1 : n ≤ 49) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (7591199764941595142535047667167496055166615766339109753578898560 + 58444846237165943551279131377341207077328035296269812484322869920 * α + 215183176025506919702531217941842711339737075266956526659211243010 * α ^ 2 + 504119825711981991953619761968878166062817925879996924390857878780 * α ^ 3 + 843499983730922829653379646526224878986727978586395545435732482710 * α ^ 4 + 1072503620634158239884244537293452959863774094675706145687308954160 * α ^ 5 + 1076446847966334979143656931502325139234331446767890824217309988610 * α ^ 6 + 874481274546832703168275213074859855200282043558515881767199205780 * α ^ 7 + 584940481506790593329950294203572360626072792868892731256510254790 * α ^ 8 + 325988305644965786771400276568642744850196724125639486229759912680 * α ^ 9 + 152567991163281517146520289154412206989708725501314740543815123242 * α ^ 10 + 60257769914462931158481100919633683041061465448481123420828204444 * α ^ 11 + 20129798805767351823723652441204102433547938067213802588532446662 * α ^ 12 + 5687016607145482595882099777086733334514360250477330630445824496 * α ^ 13 + 1355278557647407824791108174949033065263401718280146352590299132 * α ^ 14 + 271000424772480840244816322457048834002540366106552011600103312 * α ^ 15 + 45077206161318041189379028469239391861894842436881282720631712 * α ^ 16 + 6155423822307023556988091783956120485240591022903519939638936 * α ^ 17 + 676142880398770802271995740973508628770999664408861891669293 * α ^ 18 + 57725697116366115637265587909635903325806420371494216534326 * α ^ 19 + 3538202264412216996329718883610558594067822140944030875519 * α ^ 20 + 77574873286609722098225332819487251209357565591548524952 * α ^ 21 - 147315204845101536255433762427937191325421411462459722039 * α ^ 22 + 5245361991102819530624768487527000682291303265286717178 * α ^ 23 + 6658544653474755689275786385563045545487294797590331 * α ^ 24 + 1472968109561870214375834133381327743623319061135332 * α ^ 25 + 95171634843015522566439274462655369397323761963548 * α ^ 26 + 3545966415236624759599391868158380053883553245824 * α ^ 27 + 64377156482122958948701739689394929584223299312 * α ^ 28 - 1168656375434360221238828101326004753556536896 * α ^ 29 - 139417680493330544069384288780944967009327424 * α ^ 30 - 6070430434653508552057016796802025839583232 * α ^ 31 - 181826034173641815543270617357206754251776 * α ^ 32 - 4202739957608852026901130257441189900288 * α ^ 33 - 78263006650153541891015915303985934336 * α ^ 34 - 1198002545218365750178026069831352320 * α ^ 35 - 15219010328713364070284371473793024 * α ^ 36 - 160981724807992562843830338977792 * α ^ 37 - 1415946326039159376655312551936 * α ^ 38 - 10298650421826586803585810432 * α ^ 39 - 61314611371788369779294208 * α ^ 40 - 294083659089512872280064 * α ^ 41 - 1109163402380295012352 * α ^ 42 - 3168884055181623296 * α ^ 43 - 6448929882243072 * α ^ 44 - 8332022644736 * α ^ 45 - 5138022400 * α ^ 46) / (111104789153591208606089611655419825719034010961907200 * (3 + α) ^ 23) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B48_49 diff --git a/Sendov/FiniteRange/Degree5.lean b/Sendov/FiniteRange/Degree5.lean index 25a293f..cf374a9 100644 --- a/Sendov/FiniteRange/Degree5.lean +++ b/Sendov/FiniteRange/Degree5.lean @@ -106,10 +106,8 @@ theorem finite_range_five (hα : 0 ≤ α) (hfeas : c 5 α ^ 2 ≤ A 5 α) : R 5 ring rw [hid] at hR have hP : 0 < -9 * α ^ 4 - 123 * α ^ 3 + 596 * α ^ 2 + 30 * α + 234 := by - nlinarith [mul_nonneg (pow_nonneg hα 3) (sub_nonneg.2 hle), - mul_nonneg (pow_nonneg hα 2) (sub_nonneg.2 hle), sq_nonneg α, hα] - have : 0 < (-9 * α ^ 4 - 123 * α ^ 3 + 596 * α ^ 2 + 30 * α + 234) / (96 * (3 + α) ^ 2) := - div_pos hP (by positivity) - linarith + nlinarith only [hα, mul_nonneg (pow_nonneg hα 3) (sub_nonneg.2 hle), + mul_nonneg (pow_nonneg hα 2) (sub_nonneg.2 hle), sq_nonneg α] + exact hR.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end Sendov diff --git a/Sendov/FiniteRange/Degree50_51.lean b/Sendov/FiniteRange/Degree50_51.lean index 150c1a5..94ae59e 100644 --- a/Sendov/FiniteRange/Degree50_51.lean +++ b/Sendov/FiniteRange/Degree50_51.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 50 to 51 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 48 * (1983296105822518649150892894549250995892425255171116289185883918750 + 15931100140393602368014405057264748941230464487163945499694824056650 * α + 61313644372277040962442376585817692381801159938853766654339532342642 * α ^ 2 + 150465161025803906984244548536621322753695053837703089058231205826774 * α ^ 3 + 264322010781344595257900949490583824621999776392907846339168572698350 * α ^ 4 + 353743281892829023763479373880774443309366799073302434018471557825110 * α ^ 5 + 374746430716099889392649480753262242691492748868863233615818683113210 * α ^ 6 + 322333251095138331750810376734129960862151553108003622673897471115306 * α ^ 7 + 229084605395415458859385031638216501003980492983719572433329563703882 * α ^ 8 + 136186580162004849698169069937707109921050663415979174616099970789410 * α ^ 9 + 68297183570273843739235319574922178848744148149317657527481287867250 * α ^ 10 + 29054555352882187051825924818349071162009825742437693416815288122330 * α ^ 11 + 10517845843096179861634152822549541177919036751909714056461382791068 * α ^ 12 + 3243051149627232957975285323520147924344852995685877267136094949840 * α ^ 13 + 850730079576852202812092212763343774803138893059657454552260134214 * α ^ 14 + 189221714566801413370144763019660859707489277898806302228701929446 * α ^ 15 + 35474208966373153737428171347789581229469589042109433569563529953 * α ^ 16 + 5554556457876028787144312502202971828015473429833975918437514119 * α ^ 17 + 716629519575982953947167029297978855992566816319461607180223069 * α ^ 18 + 74636427766751024769605292454839153620634666149147834232905931 * α ^ 19 + 6065508382815751088971849224267373808540598230608937163606579 * α ^ 20 + 356427540055849162043883615776918801250352493347841025665727 * α ^ 21 + 8010922898128612953822450660739207750975492597821084469545 * α ^ 22 - 13811768035257687091848436534105252716200722593308688700839 * α ^ 23 + 472347189731554483068916734651482362647265909534029610926 * α ^ 24 + 200645576218037265363448556666064462492230746541192244 * α ^ 25 + 100792254939342885252420783865617430196525578985330442 * α ^ 26 + 7091638050698434724340077137596634135844686246524912 * α ^ 27 + 285507048268244527798843379331968858452479422433048 * α ^ 28 + 6365143148445153742308391864889359416478446278784 * α ^ 29 - 16632500105576540446570710610087487983679864544 * α ^ 30 - 8141192900297447634759131458865132803547534592 * α ^ 31 - 400672640084661107358183665488704704596271232 * α ^ 32 - 12769723604511066119766459310752455613515776 * α ^ 33 - 309725769188807086499063690021928273938432 * α ^ 34 - 6036271221838887663385231842606805557248 * α ^ 35 - 96889509859715053751265427510064881664 * α ^ 36 - 1296670055323112890407391552598540288 * α ^ 37 - 14548305968728835978279387666579456 * α ^ 38 - 136967029538617142794633045934080 * α ^ 39 - 1078901766843439405240321966080 * α ^ 40 - 7063554191969670305537064960 * α ^ 41 - 38017498823635237609013248 * α ^ 42 - 165453035363695795896320 * α ^ 43 - 568050178195987103744 * α ^ 44 - 1481574358823469056 * α ^ 45 - 2759526258311168 * α ^ 46 - 3270533709824 * α ^ 47 - 1853882368 * α ^ 48) = 1983296105822518649150892894549250995892425255171116289185883918750 * (17 - α) ^ 48 + 366026915466172135415487744911864779803754308530000655375734437063050 * α ^ 1 * (17 - α) ^ 47 + 32685750243130354166431563659107402625750332035405750191561966328636888 * α ^ 2 * (17 - α) ^ 46 + 1881407841131145090841016986533759097730516052825808704231530487137780460 * α ^ 3 * (17 - α) ^ 45 + 78459256689743329963134594253570543442212800051291261295613679735466812720 * α ^ 4 * (17 - α) ^ 44 + 2526157710396158722925121199079871034544523911581723097994207618552592660140 * α ^ 5 * (17 - α) ^ 43 + 65348270578398047737901045538231544926735111377759221708810966322205125102460 * α ^ 6 * (17 - α) ^ 42 + 1395586695048529216219720727338181782409903542683661464665137976415266653947720 * α ^ 7 * (17 - α) ^ 41 + 25091358961567861189485447956384974798693774013704426176176831023955755758143760 * α ^ 8 * (17 - α) ^ 40 + 385389290374823447581872955370254873043506388116231648347871930606580590239210420 * α ^ 9 * (17 - α) ^ 39 + 5114292252486869911885110308469289761839173642500394020070108012031543397685206240 * α ^ 10 * (17 - α) ^ 38 + 59161256161938370784774347699829801724975303229316300011306943983966944681307590660 * α ^ 11 * (17 - α) ^ 37 + 600805106310323904417213469470448614536129232455343240574225543436663232620490973050 * α ^ 12 * (17 - α) ^ 36 + 5387148987622905002337912552695991101576356210279594139892815350033519190381631954018 * α ^ 13 * (17 - α) ^ 35 + 42848313014751656392801345211288230271187367670920575900488813020424662766115040908726 * α ^ 14 * (17 - α) ^ 34 + 303464032538826618020021810092246523076423327835808593359248630575577172669418455370662 * α ^ 15 * (17 - α) ^ 33 + 1919675052319908024894686554181462077949811954560704660857906175718223592208137349163213 * α ^ 16 * (17 - α) ^ 32 + 10874148852557470485141277547722227524021509120915887117480057293293644142032687753432339 * α ^ 17 * (17 - α) ^ 31 + 55271679208564823539840128254013152835651570970254641566356451199627461145310938188424982 * α ^ 18 * (17 - α) ^ 30 + 252503463116529357367558410529797790559166244171078469841324516308832648846176593953640464 * α ^ 19 * (17 - α) ^ 29 + 1038141469835606067593166733401008792243365429970694049028451636707468137313444745165939138 * α ^ 20 * (17 - α) ^ 28 + 3845092335628247042344655260236398462168031115874282430712913167859044335883180372818928032 * α ^ 21 * (17 - α) ^ 27 + 12839214422922060993100206502392817799511987618052955635827705879418137857456229303102002808 * α ^ 22 * (17 - α) ^ 26 + 38668985960763181946954732106269364443378192304730607843082220299380873795313006656808498078 * α ^ 23 * (17 - α) ^ 25 + 105069155536109812068244241812619770677190371101318523388390165019705025089023705073017992201 * α ^ 24 * (17 - α) ^ 24 + 257533243404978929099209346342414027031432812223519857139718344355911305954126811366525083697 * α ^ 25 * (17 - α) ^ 23 + 569147019919025772591890628632811032011859407504430878312206909813978377735116474357089719868 * α ^ 26 * (17 - α) ^ 22 + 1133018419963002695257135527792891577568016315310178309850366791483086891940574911149456141128 * α ^ 27 * (17 - α) ^ 21 + 2028823393084462551372573822881776536387839606739316015353770957756761466356425861534814818366 * α ^ 28 * (17 - α) ^ 20 + 3261422523223033546198612538770445764908099658312172165119166143094334561521557450816017566082 * α ^ 29 * (17 - α) ^ 19 + 4695570437669925151575494973682300710306869448714096516816247877812648326270233197019115846774 * α ^ 30 * (17 - α) ^ 18 + 6037682994028240913498413640341842161215563262372408190036046373359050231573990788555033536546 * α ^ 31 * (17 - α) ^ 17 + 6911350888808185279134128140957411320398266037074579187309898159530888623281682213973958805785 * α ^ 32 * (17 - α) ^ 16 + 7017723164655595521056126675946456567629553403101512610091781353726356232791660976553934912931 * α ^ 33 * (17 - α) ^ 15 + 6294935143237609226898430401643730433375800655100783828138379904195915445486580487224848524262 * α ^ 34 * (17 - α) ^ 14 + 4964878406314244868780111039956203509756923777921248038055860417036296541552216059906145098404 * α ^ 35 * (17 - α) ^ 13 + 3424306290318650239602511891398619048414623269656800653759902188565148030596558040360823787326 * α ^ 36 * (17 - α) ^ 12 + 2051958590995686906351648406832466203839543817560131729480349304645431078728413090667388003272 * α ^ 37 * (17 - α) ^ 11 + 1060005738961397201738580950863446006402895600697466546122050769062752312325491830374270906944 * α ^ 38 * (17 - α) ^ 10 + 467577400988976496475501234195271024537914612633016089768118387533173634164273126204352761938 * α ^ 39 * (17 - α) ^ 9 + 174055424381608100029944299500295460088946458918286120062437292805583013054742467588482744291 * α ^ 40 * (17 - α) ^ 8 + 53878846132574605007505800468792220908832004075393485465775528877910318074398454899271776059 * α ^ 41 * (17 - α) ^ 7 + 13614845621699809419890571355526634130837098707003964296944897175809602487667917307467989936 * α ^ 42 * (17 - α) ^ 6 + 2744159397807574020755344104224532395538285866763175087142310240707624213164183747296183828 * α ^ 43 * (17 - α) ^ 5 + 428866537260624574850004860175037680310285291204398039963565670689977450658379659200504216 * α ^ 44 * (17 - α) ^ 4 + 50333756227847631161716151257046024575567930432377627572895340197028609964017169960339112 * α ^ 45 * (17 - α) ^ 3 + 4302447045325735617429810226177479174756160321138468549855980238567434050919754100402688 * α ^ 46 * (17 - α) ^ 2 + 258744146897542242897425801777948395291136619450442877052536998228794692040701916234240 * α ^ 47 * (17 - α) ^ 1 + 9199351670117540067891308093632332055308176052079014496984569179145526721008475136000 * α ^ 48 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 48)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 50 ≤ n) (h1 : n ≤ 51) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (1983296105822518649150892894549250995892425255171116289185883918750 + 15931100140393602368014405057264748941230464487163945499694824056650 * α + 61313644372277040962442376585817692381801159938853766654339532342642 * α ^ 2 + 150465161025803906984244548536621322753695053837703089058231205826774 * α ^ 3 + 264322010781344595257900949490583824621999776392907846339168572698350 * α ^ 4 + 353743281892829023763479373880774443309366799073302434018471557825110 * α ^ 5 + 374746430716099889392649480753262242691492748868863233615818683113210 * α ^ 6 + 322333251095138331750810376734129960862151553108003622673897471115306 * α ^ 7 + 229084605395415458859385031638216501003980492983719572433329563703882 * α ^ 8 + 136186580162004849698169069937707109921050663415979174616099970789410 * α ^ 9 + 68297183570273843739235319574922178848744148149317657527481287867250 * α ^ 10 + 29054555352882187051825924818349071162009825742437693416815288122330 * α ^ 11 + 10517845843096179861634152822549541177919036751909714056461382791068 * α ^ 12 + 3243051149627232957975285323520147924344852995685877267136094949840 * α ^ 13 + 850730079576852202812092212763343774803138893059657454552260134214 * α ^ 14 + 189221714566801413370144763019660859707489277898806302228701929446 * α ^ 15 + 35474208966373153737428171347789581229469589042109433569563529953 * α ^ 16 + 5554556457876028787144312502202971828015473429833975918437514119 * α ^ 17 + 716629519575982953947167029297978855992566816319461607180223069 * α ^ 18 + 74636427766751024769605292454839153620634666149147834232905931 * α ^ 19 + 6065508382815751088971849224267373808540598230608937163606579 * α ^ 20 + 356427540055849162043883615776918801250352493347841025665727 * α ^ 21 + 8010922898128612953822450660739207750975492597821084469545 * α ^ 22 - 13811768035257687091848436534105252716200722593308688700839 * α ^ 23 + 472347189731554483068916734651482362647265909534029610926 * α ^ 24 + 200645576218037265363448556666064462492230746541192244 * α ^ 25 + 100792254939342885252420783865617430196525578985330442 * α ^ 26 + 7091638050698434724340077137596634135844686246524912 * α ^ 27 + 285507048268244527798843379331968858452479422433048 * α ^ 28 + 6365143148445153742308391864889359416478446278784 * α ^ 29 - 16632500105576540446570710610087487983679864544 * α ^ 30 - 8141192900297447634759131458865132803547534592 * α ^ 31 - 400672640084661107358183665488704704596271232 * α ^ 32 - 12769723604511066119766459310752455613515776 * α ^ 33 - 309725769188807086499063690021928273938432 * α ^ 34 - 6036271221838887663385231842606805557248 * α ^ 35 - 96889509859715053751265427510064881664 * α ^ 36 - 1296670055323112890407391552598540288 * α ^ 37 - 14548305968728835978279387666579456 * α ^ 38 - 136967029538617142794633045934080 * α ^ 39 - 1078901766843439405240321966080 * α ^ 40 - 7063554191969670305537064960 * α ^ 41 - 38017498823635237609013248 * α ^ 42 - 165453035363695795896320 * α ^ 43 - 568050178195987103744 * α ^ 44 - 1481574358823469056 * α ^ 45 - 2759526258311168 * α ^ 46 - 3270533709824 * α ^ 47 - 1853882368 * α ^ 48) / (9662005486581138944445785843849787039898391583452760000 * (3 + α) ^ 24) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B50_51 diff --git a/Sendov/FiniteRange/Degree52_53.lean b/Sendov/FiniteRange/Degree52_53.lean index 601d726..fd5439d 100644 --- a/Sendov/FiniteRange/Degree52_53.lean +++ b/Sendov/FiniteRange/Degree52_53.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 52 to 53 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 50 * (2158786206398835455807414614345741946541113771140909309351827456752112 + 18060881628885317183903129865386184210636931259177004847461943403431248 * α + 72523751526913871689914498063741871627156282998221168488328768408227884 * α ^ 2 + 186043952493859430608709083701039329302003956855619351393577019518308656 * α ^ 3 + 342352186792731735464993586128215688813987853593111908601035784489017584 * α ^ 4 + 481039143350973516581843203115060631357333955017066302301078896484075192 * α ^ 5 + 536385148360730976146799557733557814318777038771883620685910931111117598 * α ^ 6 + 486973177459613828942749054605832894034828444342062183629433383012760968 * α ^ 7 + 366445983498710745663941283884031432424266298307553290495228389566314580 * α ^ 8 + 231462963120661901399357408339235733527085751003762699569336649733064704 * α ^ 9 + 123822723544233720819377342496077302912265601255690207194574592762760382 * α ^ 10 + 56444234764084989462828858083829787816765813106300946212401546188828432 * α ^ 11 + 22008608122728995449205242852102476325631469834261804695394906754027728 * α ^ 12 + 7353623809616680357566863259021705228111970073628547653529150957921848 * α ^ 13 + 2105293430360560851822138859793778045699608135112104910406227699186678 * α ^ 14 + 515430709094276322360222922253268287610570499499448923895934548603720 * α ^ 15 + 107478868042826110622436885067609215622378470268066806044658545978916 * α ^ 16 + 18965619675038957214919858400770522577747376668487077296700550484152 * α ^ 17 + 2805160201379690314111348362084950864952366379855375613165120590980 * α ^ 18 + 342991269135314358321380120239307230093856195186954782184086092504 * α ^ 19 + 33962560439249200363255807231186470161851488347615308016008248384 * α ^ 20 + 2633515219064481554671199294750396033142024306631342141117342380 * α ^ 21 + 148633574270813874422290547923622884359972747318157801476955959 * α ^ 22 + 3403031020239585108295877062230213266408608085674454931323988 * α ^ 23 - 5379021087810236884979508991939865813601169242801548152141926 * α ^ 24 + 177301236343156026391795710864319371980311028891458462428744 * α ^ 25 - 40911700701069253972939511638042802470451085773720769927 * α ^ 26 + 27847404177739803963243561747514551473461230777429543312 * α ^ 27 + 2163155861798102819189036458258553844449886588504682104 * α ^ 28 + 93357595651430156400551007018380753717170652754834528 * α ^ 29 + 2393234358116242034523747708494764119251642322824544 * α ^ 30 + 15013048286137658650612509829061430420471401902848 * α ^ 31 - 1842593441930339010973203854928850324437642558336 * α ^ 32 - 107353306964614466200187553508809370311222440448 * α ^ 33 - 3666162111111306744447755601199086059560935168 * α ^ 34 - 93356644345705005900818038532098756222427136 * α ^ 35 - 1900483230089570865170384480343133786767360 * α ^ 36 - 31876662776993730438299978705884181495808 * α ^ 37 - 447245036738485694487463467137714307072 * α ^ 38 - 5288819621114196078630291364843487232 * α ^ 39 - 52859730633810963643011459678732288 * α ^ 40 - 446161546901880234704034758393856 * α ^ 41 - 3167349500047341936592130605056 * α ^ 42 - 18770907855391026630248890368 * α ^ 43 - 91797189183100371092373504 * α ^ 44 - 364189492779598108164096 * α ^ 45 - 1143139551315216039936 * α ^ 46 - 2732815988096499712 * α ^ 47 - 4676225293352960 * α ^ 48 - 5102186266624 * α ^ 49 - 2667577344 * α ^ 50) = 2158786206398835455807414614345741946541113771140909309351827456752112 * (17 - α) ^ 50 + 414974298010992164916723938428852228907883519963054547874444410695936816 * α ^ 1 * (17 - α) ^ 49 + 38648591690978151565940680020861626232221593895027976635018801559557425260 * α ^ 2 * (17 - α) ^ 48 + 2323468774953773046737498344073410604963916757430810426040495562926126538992 * α ^ 3 * (17 - α) ^ 47 + 101349335991740593349006338670862435683901636675912397673964231014026337776992 * α ^ 4 * (17 - α) ^ 46 + 3418523402240372565025362732012218197017682799224385182741003587603019322270088 * α ^ 5 * (17 - α) ^ 45 + 92795830318460904167075752328056310590909312937624225610579756886634415607753926 * α ^ 6 * (17 - α) ^ 44 + 2083150548513343067461154384073343753088328081203102895466392639042540698472213552 * α ^ 7 * (17 - α) ^ 43 + 39441282325689010460905068005007464787875697034233161641025817719437629586599815832 * α ^ 8 * (17 - α) ^ 42 + 639183212529869482732967509857029817382349276322171871286037804499595169420221724576 * α ^ 9 * (17 - α) ^ 41 + 8967891289317846323424522756456515361904817651455107492105958263498697039942754607804 * α ^ 10 * (17 - α) ^ 40 + 109912662905773911775785651830599814138152716415593519404830837106463824445813386386608 * α ^ 11 * (17 - α) ^ 39 + 1185288664388902189248806437812380279610975615235779015443672285781708714559807760293128 * α ^ 12 * (17 - α) ^ 38 + 11312386017398730692131184641629356719495877419525070049772377844481537989327971120696960 * α ^ 13 * (17 - α) ^ 37 + 96008520633756064409983434244275286680745229190958399353722082141681347511927190938190428 * α ^ 14 * (17 - α) ^ 36 + 727433466208182128845968339617608516747540980223663657764849247640353461478732223298149376 * α ^ 15 * (17 - α) ^ 35 + 4936366709381111751784857730466957485889673194213489796538376360678509233705016565561219568 * α ^ 16 * (17 - α) ^ 34 + 30082088254960095366958957594286135042878514883960848835770199866562115806088375067362801128 * α ^ 17 * (17 - α) ^ 33 + 164985102649690123319061978345185000778850953533122226871900814573805405999712146966652623130 * α ^ 18 * (17 - α) ^ 32 + 815818288201891083392614882901171467483608622704000551448258747708939293642643211380800205624 * α ^ 19 * (17 - α) ^ 31 + 3642346364254930209461654350984048884263119419677776197894819995644826784702649307916488655048 * α ^ 20 * (17 - α) ^ 30 + 14699642422912871844500841018776542189279022499143301125114403207390856393770245321897888096820 * α ^ 21 * (17 - α) ^ 29 + 53673006585933151650707212393612027990337017921471920103972688477444212042080888181402531954623 * α ^ 22 * (17 - α) ^ 28 + 177424630381056553613555892437643150189372774889210179326490713116128958479669098035885345446552 * α ^ 23 * (17 - α) ^ 27 + 531217322618016492802133586903649391958733336005082950612572311095808910788505345175592814369580 * α ^ 24 * (17 - α) ^ 26 + 1440878297786625726057735963735191129687061087876632335989525965863749961422678931848398180994264 * α ^ 25 * (17 - α) ^ 25 + 3540528972380530248060021030700986765668663375909521118259073708483300881659592107503593191364768 * α ^ 26 * (17 - α) ^ 24 + 7878706067439138302871644596778500496033461935373897042861066792548444034343472542257091147209584 * α ^ 27 * (17 - α) ^ 23 + 15866985172027478682631903171788637970460063980973228429209846911200894587882339479475867198952036 * α ^ 28 * (17 - α) ^ 22 + 28888250810289606634245191706663186299318801988344278179610334690859848174281402135692480432780132 * α ^ 29 * (17 - α) ^ 21 + 47477629548102243528458217920917101013725287450823186845340936391317439940465355556234941946032657 * α ^ 30 * (17 - α) ^ 20 + 70302798619149431656063874867631560161982110726463060425195857474073971124206669994193325260431968 * α ^ 31 * (17 - α) ^ 19 + 93578532127885660914680781758934948491041981899416935218375174036595572222667517918310377720198808 * α ^ 32 * (17 - α) ^ 18 + 111671046495563139231753996807194588715349583644959990280095487148731493003528163756917394817921848 * α ^ 33 * (17 - α) ^ 17 + 119108317519314874116452075964414453573552081166001011602192516430347593073861906203222286276783210 * α ^ 34 * (17 - α) ^ 16 + 113156360454221734073606765068373900287501266200716732578873162490509611564763213724059111444879912 * α ^ 35 * (17 - α) ^ 15 + 95376447959581379971158449180838329759355945573810871902930153136280190435130420456031549759592432 * α ^ 36 * (17 - α) ^ 14 + 71000547856694915769126077715715772989720497286001979959236111644677764746629355003121324873743636 * α ^ 37 * (17 - α) ^ 13 + 46435247311237875241086804176274841256465196204557482607524607905695835753570599397044472496443683 * α ^ 38 * (17 - α) ^ 12 + 26514718964077437868313478305791884794282002198254450319170212656068940296217672260748146187929000 * α ^ 39 * (17 - α) ^ 11 + 13119684648080558068145400061379201620208126873006769889319790885496821503611538738560892688675108 * α ^ 40 * (17 - α) ^ 10 + 5574304384447257915334770015429223070725790686644478804358809424096493843062858412483691392992136 * α ^ 41 * (17 - α) ^ 9 + 2010881865895736598424115789062219791810721593821299429086893216589613227274491543685953304227120 * α ^ 42 * (17 - α) ^ 8 + 607237389577241841869363680453643402590101734012060773034199963895826888891782257735573905657616 * α ^ 43 * (17 - α) ^ 7 + 150749895847577632681470277527543538771101449370569486067541118295682832958042871499658490290684 * α ^ 44 * (17 - α) ^ 6 + 30052820272696317463395531462440009839882141116365183097551075391516536642298874821618150390348 * α ^ 45 * (17 - α) ^ 5 + 4663688556843488364172070998639274132596372023847717839521027547698552604606780971945788903755 * α ^ 46 * (17 - α) ^ 4 + 540081530702743610283233889828122230493014768961119305004582751972922686852640193916287106992 * α ^ 47 * (17 - α) ^ 3 + 43983793487190009087693541621146525651052894618594476651626932794533461019682370365887330080 * α ^ 48 * (17 - α) ^ 2 + 2295554691290398410917187961072648259042029375130142853380489371587928525721201467534862000 * α ^ 49 * (17 - α) ^ 1 + 61696825755958662910832536044204740555351244465959101505141229428727029482047853259288100 * α ^ 50 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 50)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 52 ≤ n) (h1 : n ≤ 53) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (2158786206398835455807414614345741946541113771140909309351827456752112 + 18060881628885317183903129865386184210636931259177004847461943403431248 * α + 72523751526913871689914498063741871627156282998221168488328768408227884 * α ^ 2 + 186043952493859430608709083701039329302003956855619351393577019518308656 * α ^ 3 + 342352186792731735464993586128215688813987853593111908601035784489017584 * α ^ 4 + 481039143350973516581843203115060631357333955017066302301078896484075192 * α ^ 5 + 536385148360730976146799557733557814318777038771883620685910931111117598 * α ^ 6 + 486973177459613828942749054605832894034828444342062183629433383012760968 * α ^ 7 + 366445983498710745663941283884031432424266298307553290495228389566314580 * α ^ 8 + 231462963120661901399357408339235733527085751003762699569336649733064704 * α ^ 9 + 123822723544233720819377342496077302912265601255690207194574592762760382 * α ^ 10 + 56444234764084989462828858083829787816765813106300946212401546188828432 * α ^ 11 + 22008608122728995449205242852102476325631469834261804695394906754027728 * α ^ 12 + 7353623809616680357566863259021705228111970073628547653529150957921848 * α ^ 13 + 2105293430360560851822138859793778045699608135112104910406227699186678 * α ^ 14 + 515430709094276322360222922253268287610570499499448923895934548603720 * α ^ 15 + 107478868042826110622436885067609215622378470268066806044658545978916 * α ^ 16 + 18965619675038957214919858400770522577747376668487077296700550484152 * α ^ 17 + 2805160201379690314111348362084950864952366379855375613165120590980 * α ^ 18 + 342991269135314358321380120239307230093856195186954782184086092504 * α ^ 19 + 33962560439249200363255807231186470161851488347615308016008248384 * α ^ 20 + 2633515219064481554671199294750396033142024306631342141117342380 * α ^ 21 + 148633574270813874422290547923622884359972747318157801476955959 * α ^ 22 + 3403031020239585108295877062230213266408608085674454931323988 * α ^ 23 - 5379021087810236884979508991939865813601169242801548152141926 * α ^ 24 + 177301236343156026391795710864319371980311028891458462428744 * α ^ 25 - 40911700701069253972939511638042802470451085773720769927 * α ^ 26 + 27847404177739803963243561747514551473461230777429543312 * α ^ 27 + 2163155861798102819189036458258553844449886588504682104 * α ^ 28 + 93357595651430156400551007018380753717170652754834528 * α ^ 29 + 2393234358116242034523747708494764119251642322824544 * α ^ 30 + 15013048286137658650612509829061430420471401902848 * α ^ 31 - 1842593441930339010973203854928850324437642558336 * α ^ 32 - 107353306964614466200187553508809370311222440448 * α ^ 33 - 3666162111111306744447755601199086059560935168 * α ^ 34 - 93356644345705005900818038532098756222427136 * α ^ 35 - 1900483230089570865170384480343133786767360 * α ^ 36 - 31876662776993730438299978705884181495808 * α ^ 37 - 447245036738485694487463467137714307072 * α ^ 38 - 5288819621114196078630291364843487232 * α ^ 39 - 52859730633810963643011459678732288 * α ^ 40 - 446161546901880234704034758393856 * α ^ 41 - 3167349500047341936592130605056 * α ^ 42 - 18770907855391026630248890368 * α ^ 43 - 91797189183100371092373504 * α ^ 44 - 364189492779598108164096 * α ^ 45 - 1143139551315216039936 * α ^ 46 - 2732815988096499712 * α ^ 47 - 4676225293352960 * α ^ 48 - 5102186266624 * α ^ 49 - 2667577344 * α ^ 50) / (3501052148609730436138801945234855464676764937608356932800 * (3 + α) ^ 25) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B52_53 diff --git a/Sendov/FiniteRange/Degree53Packed.lean b/Sendov/FiniteRange/Degree53Packed.lean index 9d62bba..58c7206 100644 --- a/Sendov/FiniteRange/Degree53Packed.lean +++ b/Sendov/FiniteRange/Degree53Packed.lean @@ -41,23 +41,24 @@ def Nmom53 : List ℤ := theorem pev_Nmom53 (α : ℝ) : pev Nmom53 α = pev (wsum L53 0 (qrow (gg0 53) (gg1 53) (gg2 53) 24)) α := by refine pev_wsum_eq_of_packed (gg0 53) (gg1 53) (gg2 53) 24 73 L53 beta53 tau53 Nmom53 - (by norm_num [beta53]) (by norm_num [tau53]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 53) (gg1 53) (gg2 53) 24 3 beta53 tau53 (by norm_num [beta53]) + (by decide) (by decide) ?_ ?_ ?_ ?_ ?_ ?_ α + -- Bound the packed row structurally, without expanding qrow. + · refine rowZ_bound (gg0 53) (gg1 53) (gg2 53) 24 3 beta53 tau53 (by decide) (by decide) (by decide) (by decide) ?_ norm_num [gg0, gg1, gg2, l1, beta53, tau53] - · decide - · refine wsum_bound (gg0 53) (gg1 53) (gg2 53) 24 L53 beta53 (by norm_num [L53]) ?_ + · decide -- Every supplied numerator coefficient fits in β. + · refine wsum_bound (gg0 53) (gg1 53) (gg2 53) 24 L53 beta53 (by decide) ?_ norm_num [gg0, gg1, gg2, l1, L53, beta53] - · decide + · decide -- The supplied list satisfies the promised length bound. · exact wsum_length_le L53 _ 0 (qrow_entry_length_le (gg0 53) (gg1 53) (gg2 53) 3 (by decide) (by decide) (by decide) 24) - · rfl + · rfl -- The remaining check is the exact packed integer equality. /-- The degree-53 moment. -/ theorem integral_fiftythree (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 53 α t ^ 24) = pev Nmom53 α / ((L53 : ℝ) * (2 * M 53 * (3 + α)) ^ 24) := - integral_moment_packed 53 24 (by norm_num) α hα L53 (by norm_num [L53]) Nmom53 + integral_moment_packed 53 24 (by norm_num) α hα L53 (by decide) Nmom53 (by decide) (pev_Nmom53 α) end Sendov diff --git a/Sendov/FiniteRange/Degree54_55.lean b/Sendov/FiniteRange/Degree54_55.lean index db146b8..38099b7 100644 --- a/Sendov/FiniteRange/Degree54_55.lean +++ b/Sendov/FiniteRange/Degree54_55.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 54 to 55 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 52 * (16494167009921791229556693354250558994004960089275608134952301595194145700 + 143495585732014632876947701159299432571935297872102967009453889788942630516 * α + 600146981561757364071810080610152109467421702720565940343744136045710714240 * α ^ 2 + 1606309613433661462999425062531603257368288440796455160921241994205807550800 * α ^ 3 + 3089935016411981969366335770505513109414946535522135899534602918518452400110 * α ^ 4 + 4548021756358959061868607547427969034568735681024830591427930680507708516630 * α ^ 5 + 5324472427116589963068442803453435582254682183625311260959169925128717206890 * α ^ 6 + 5088112301464007763161223382731859106222272351099136492562868432790050748010 * α ^ 7 + 4041350342582910718376698346793695673500055519225008392201038233346955184130 * α ^ 8 + 2702810799510161555412033309004487136564483291932054239796551253387958338250 * α ^ 9 + 1536279381058752516392997665745371680813310918710686404622076783423411472310 * α ^ 10 + 747035505761971294025842500370255312982388584883798779389925639599781539110 * α ^ 11 + 312120280284390297007832319287765858778034126483703719026036710712245847630 * α ^ 12 + 112328303645112191177480265164326260518118446637968730517219246030090061670 * α ^ 13 + 34847965479991464020760392422930205817393828567231232594447128943554577950 * α ^ 14 + 9311065733578254803436313728561027301061995457613177507038687159207136510 * α ^ 15 + 2137053395968205693740631086110584184448273974022381233594071100920418660 * α ^ 16 + 419415497303046617346927271099007566525536754801411545759490611489535020 * α ^ 17 + 69903195768650128169410986270066096062738214853608222509952701694930390 * α ^ 18 + 9796751930080145102336247171862671684216870902559058128633974960508990 * α ^ 19 + 1138373287745887689323718901024639495300275153431093749751357684888655 * α ^ 20 + 107431234099507044305505224510335533709977858803000709455555262812475 * α ^ 21 + 7965572671696337257969240111258550023673082988480052797472718090765 * α ^ 22 + 432489851677951286849434341419775059089962332363725955872440307245 * α ^ 23 + 10033042060175777949356539605564287060646991070535569056012261935 * α ^ 24 - 14665345174670112106333566037790518499419114767637006814333117685 * α ^ 25 + 467265281717233365794825008753399741068194685496332969035489307 * α ^ 26 - 338571739674856609859042128682071390079128171355900195378565 * α ^ 27 + 51828010052697170919200272082439937455364221416970311841360 * α ^ 28 + 4551610675134221759317748807561457084971246067804745378320 * α ^ 29 + 209779510423918524619133931870713143087995729911985149040 * α ^ 30 + 5970127197067432618593627815816805105135662362948064640 * α ^ 31 + 72450550286061369082689048114099286472057904479048640 * α ^ 32 - 2583219468428786599910558481880637801957466132337920 * α ^ 33 - 195852731109616002368456744436432386876454107873280 * α ^ 34 - 7247973580231951783404261339025545494805311297280 * α ^ 35 - 194124681108967495056283792222752779031406556160 * α ^ 36 - 4123433450448809567758812935503400791570882560 * α ^ 37 - 72082021160947668781050521228246549326725120 * α ^ 38 - 1056193512343203991501036178583787410636800 * α ^ 39 - 13096880010730035770569022035700611809280 * α ^ 40 - 138052872308930943537538309704895365120 * α ^ 41 - 1238136265130428487231808151440916480 * α ^ 42 - 9428378825017111932776968669429760 * α ^ 43 - 60659413041205873935423111168000 * α ^ 44 - 327048428909975887634922209280 * α ^ 45 - 1459908719275463855607644160 * α ^ 46 - 5302273507938488014602240 * α ^ 47 - 15275608180278584934400 * α ^ 48 - 33595607399404666880 * α ^ 49 - 52996826537656320 * α ^ 50 - 53409512161280 * α ^ 51 - 25836912640 * α ^ 52) = 16494167009921791229556693354250558994004960089275608134952301595194145700 * (17 - α) ^ 52 + 3297121641960181902845058974129119421411157988468082062178235809362120295172 * α ^ 1 * (17 - α) ^ 51 + 319724415956160860091458945589182808902003352419736285543485329679451094270932 * α ^ 2 * (17 - α) ^ 50 + 20038710926027661432334875342791217340018851913295984793285523609822774454252700 * α ^ 3 * (17 - α) ^ 49 + 912506063164863213831944030666321098534650758920349287477777497262175240738402310 * α ^ 4 * (17 - α) ^ 48 + 32177823044530476695020659335002454111188404373175841794915018442377955651394113990 * α ^ 5 * (17 - α) ^ 47 + 914540681282828800807599319891793843292641936770051259660032453172015089441416681780 * α ^ 6 * (17 - α) ^ 46 + 21529723418168081854258856249066854725157410727767949291151621244500815386654814167180 * α ^ 7 * (17 - α) ^ 45 + 428187563876954541113963075618060221598963677578037826566438784007708913233247747176780 * α ^ 8 * (17 - α) ^ 44 + 7301844169441283547821796282852027526162858087792900418706107149330943728664004086739660 * α ^ 9 * (17 - α) ^ 43 + 107998890241658105222949402539269436370829457640263205565353289295418525536340771107662680 * α ^ 10 * (17 - α) ^ 42 + 1398093827433571704042090344538943552073638570463931753295281987815735454006786470999735160 * α ^ 11 * (17 - α) ^ 41 + 15957032127861583576984677012499030521875944161240621820452635989220785757028810049931646660 * α ^ 12 * (17 - α) ^ 40 + 161526877975623854315474231221259866905794267588621234412370551845474892520146496256658344580 * α ^ 13 * (17 - α) ^ 39 + 1457239742403607406416443184401351553341986505900117649824594649023236812024794234917099752380 * α ^ 14 * (17 - α) ^ 38 + 11764118385331183795485731464799855976003853373075619337664964031988252913700051042473465972420 * α ^ 15 * (17 - α) ^ 37 + 85266812327847025363233082778590085924666659056638604615146724746162734347495123483376596599070 * α ^ 16 * (17 - α) ^ 36 + 556412933665661316562603334092469787110651645009094640295939461919699008524178193574911456908110 * α ^ 17 * (17 - α) ^ 35 + 3276500502586555718746248192880369763373913284974973228696609120912342926842381883477115970971330 * α ^ 18 * (17 - α) ^ 34 + 17443973618063549860197174258607173645342170656659807634029925978540184960307013051100945108575830 * α ^ 19 * (17 - α) ^ 33 + 84097208992473763322482498841713994615424570017542204453635043962819422256085229322643661036553135 * α ^ 20 * (17 - α) ^ 32 + 367595670215331608081325934241054123019019558617664793950031213417886531914880453450235055639827695 * α ^ 21 * (17 - α) ^ 31 + 1458319292273003092992284569774617261635353524450745892916673491633645545947909275323789971386584010 * α ^ 22 * (17 - α) ^ 30 + 5254980271354566622530408171222928163731186808057577088774647757156770300739259401327506864767179590 * α ^ 23 * (17 - α) ^ 29 + 17209987305609188388593928884348304692679416452958887120667494264685355764336243613006433529300889900 * α ^ 24 * (17 - α) ^ 28 + 51245313767700576927493227999999199039753952598947831546238937797935220706183422086338270920360486300 * α ^ 25 * (17 - α) ^ 27 + 138766478666356226035473697072120508245376894603069112986887914209096091729659135725891961666489860662 * α ^ 26 * (17 - α) ^ 26 + 341725720150049744585959626125868368010499310869413614657759212314754963597840236324448419782451114282 * α ^ 27 * (17 - α) ^ 25 + 765136285933410012453175445478517650702161463656786558161202904376215029605986594283307478093304307385 * α ^ 28 * (17 - α) ^ 24 + 1556877403438278759283881545391171005360005954054145030966940257959498891624213557816408094093075864665 * α ^ 29 * (17 - α) ^ 23 + 2876564405128945633873865865688129358774847644012865518697098702186811357802016717785624061301955829430 * α ^ 30 * (17 - α) ^ 22 + 4820561162618100599568269482213420070663798726185647089067973322799735823546946658344673073602139469970 * α ^ 31 * (17 - α) ^ 21 + 7315920828232011027352935983664196353610979185130017647700999674444485613522154300362261069304268308590 * α ^ 32 * (17 - α) ^ 20 + 10036378526288476516030178366360979243689435681024753191393010979431912513169664181917187452264705749630 * α ^ 33 * (17 - α) ^ 19 + 12418173602350336332834011143730287052626259450406781462033191143152690802051403229595128207313656006650 * α ^ 34 * (17 - α) ^ 18 + 13822754463345097102831820242184258761738276008006821284534279176481079905732530814499207866955435085150 * α ^ 35 * (17 - α) ^ 17 + 13801040060918957888564788139270767298844994408740307330701472008264699451769662273654318158513511789155 * α ^ 36 * (17 - α) ^ 16 + 12318471680266652419845517118100896836955882316001519109947812762310692937531763121301079422467179937315 * α ^ 37 * (17 - α) ^ 15 + 9791961276777243139471730047869500129996328504872391696608131789839153344852214590773875133920134451090 * α ^ 38 * (17 - α) ^ 14 + 6901396925674586370353679055683314537328841096886193608522335358563478321818303138218149658902821023950 * α ^ 39 * (17 - α) ^ 13 + 4290696155282947318028543407039084473970660925581234584798657667133577612919565979582433162065644672980 * α ^ 40 * (17 - α) ^ 12 + 2338873380377640090710543794097867885941646034550384133409823471730993425571758516636190486584614953700 * α ^ 41 * (17 - α) ^ 11 + 1109732755852378588712211011650814187613669797876675740951121816904470151813091358110884216937743142050 * α ^ 42 * (17 - α) ^ 10 + 454286800542359954534080719815999805873534526512065733818696923800302006274839909248752230406180846110 * α ^ 43 * (17 - α) ^ 9 + 158713699307083273689749079467203333163770903148624457146145339447571976015368636000957338799724035275 * α ^ 44 * (17 - α) ^ 8 + 46680861352325638868600152099580545678224568597334155135966362508038806503807101375708916251637014315 * α ^ 45 * (17 - α) ^ 7 + 11358113255233464326610717370655147651105757900848936506289875029144788364049674739051630170475728510 * α ^ 46 * (17 - α) ^ 6 + 2234292960434683002788971594223923746722335287405129686566824534284185319130892757911313973235591050 * α ^ 47 * (17 - α) ^ 5 + 344434128456143069997502715027323329232394662376196306985663027670793467133639790028593418988513700 * α ^ 48 * (17 - α) ^ 4 + 39809789393720194364475874377808256220963899458735378967674739520923108380632695527160035322788100 * α ^ 49 * (17 - α) ^ 3 + 3224979637871433689973695689784750956991084495357901531836611031085730991516232539844546931899840 * α ^ 50 * (17 - α) ^ 2 + 162942207478993682465981071080743775591479135331458384477879849257595493096166794488597275948400 * α ^ 51 * (17 - α) ^ 1 + 3907984261693816830880565006531529193978954398787645698090073443074989996324628172410599696000 * α ^ 52 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 52)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 54 ≤ n) (h1 : n ≤ 55) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (16494167009921791229556693354250558994004960089275608134952301595194145700 + 143495585732014632876947701159299432571935297872102967009453889788942630516 * α + 600146981561757364071810080610152109467421702720565940343744136045710714240 * α ^ 2 + 1606309613433661462999425062531603257368288440796455160921241994205807550800 * α ^ 3 + 3089935016411981969366335770505513109414946535522135899534602918518452400110 * α ^ 4 + 4548021756358959061868607547427969034568735681024830591427930680507708516630 * α ^ 5 + 5324472427116589963068442803453435582254682183625311260959169925128717206890 * α ^ 6 + 5088112301464007763161223382731859106222272351099136492562868432790050748010 * α ^ 7 + 4041350342582910718376698346793695673500055519225008392201038233346955184130 * α ^ 8 + 2702810799510161555412033309004487136564483291932054239796551253387958338250 * α ^ 9 + 1536279381058752516392997665745371680813310918710686404622076783423411472310 * α ^ 10 + 747035505761971294025842500370255312982388584883798779389925639599781539110 * α ^ 11 + 312120280284390297007832319287765858778034126483703719026036710712245847630 * α ^ 12 + 112328303645112191177480265164326260518118446637968730517219246030090061670 * α ^ 13 + 34847965479991464020760392422930205817393828567231232594447128943554577950 * α ^ 14 + 9311065733578254803436313728561027301061995457613177507038687159207136510 * α ^ 15 + 2137053395968205693740631086110584184448273974022381233594071100920418660 * α ^ 16 + 419415497303046617346927271099007566525536754801411545759490611489535020 * α ^ 17 + 69903195768650128169410986270066096062738214853608222509952701694930390 * α ^ 18 + 9796751930080145102336247171862671684216870902559058128633974960508990 * α ^ 19 + 1138373287745887689323718901024639495300275153431093749751357684888655 * α ^ 20 + 107431234099507044305505224510335533709977858803000709455555262812475 * α ^ 21 + 7965572671696337257969240111258550023673082988480052797472718090765 * α ^ 22 + 432489851677951286849434341419775059089962332363725955872440307245 * α ^ 23 + 10033042060175777949356539605564287060646991070535569056012261935 * α ^ 24 - 14665345174670112106333566037790518499419114767637006814333117685 * α ^ 25 + 467265281717233365794825008753399741068194685496332969035489307 * α ^ 26 - 338571739674856609859042128682071390079128171355900195378565 * α ^ 27 + 51828010052697170919200272082439937455364221416970311841360 * α ^ 28 + 4551610675134221759317748807561457084971246067804745378320 * α ^ 29 + 209779510423918524619133931870713143087995729911985149040 * α ^ 30 + 5970127197067432618593627815816805105135662362948064640 * α ^ 31 + 72450550286061369082689048114099286472057904479048640 * α ^ 32 - 2583219468428786599910558481880637801957466132337920 * α ^ 33 - 195852731109616002368456744436432386876454107873280 * α ^ 34 - 7247973580231951783404261339025545494805311297280 * α ^ 35 - 194124681108967495056283792222752779031406556160 * α ^ 36 - 4123433450448809567758812935503400791570882560 * α ^ 37 - 72082021160947668781050521228246549326725120 * α ^ 38 - 1056193512343203991501036178583787410636800 * α ^ 39 - 13096880010730035770569022035700611809280 * α ^ 40 - 138052872308930943537538309704895365120 * α ^ 41 - 1238136265130428487231808151440916480 * α ^ 42 - 9428378825017111932776968669429760 * α ^ 43 - 60659413041205873935423111168000 * α ^ 44 - 327048428909975887634922209280 * α ^ 45 - 1459908719275463855607644160 * α ^ 46 - 5302273507938488014602240 * α ^ 47 - 15275608180278584934400 * α ^ 48 - 33595607399404666880 * α ^ 49 - 52996826537656320 * α ^ 50 - 53409512161280 * α ^ 51 - 25836912640 * α ^ 52) / (8905825603714907746191103330109125499618527182188584734005088 * (3 + α) ^ 26) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B54_55 diff --git a/Sendov/FiniteRange/Degree56_58.lean b/Sendov/FiniteRange/Degree56_58.lean index da1da93..652186c 100644 --- a/Sendov/FiniteRange/Degree56_58.lean +++ b/Sendov/FiniteRange/Degree56_58.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 56 to 58 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 54 * (4006776526237583458791916745921571399903640427998587971001863479614257812500 + 36193299233577005092404435186325555880909575118523570487124919891357421875000 * α + 157404458430456801566314898531435489082055275896144801637965440750122070312500 * α ^ 2 + 438789302805190644765999692456086768304410010456706455086051940917968750000000 * α ^ 3 + 880644388246065999407804638303739222032368746089754793927588987350463867187500 * α ^ 4 + 1354948378632315916086740220782422392456213284262767321014325168609619140625000 * α ^ 5 + 1661602897691580734737365439849633466188200353673006461916168213272094726562500 * α ^ 6 + 1667045608015110082374111106109377028467549691711516663117268814086914062500000 * α ^ 7 + 1393634964581423479006807950372755382512403362475605339704530439338684082031250 * α ^ 8 + 983739476273137944395322828805928193025534886625965973020494254135131835937500 * α ^ 9 + 592005671863910309809560316101676243798968926448970748675875927594299316406250 * α ^ 10 + 305845520279728243480763379048878002620628430303914474045381805538574218750000 * α ^ 11 + 136301035857816688759209743042609079523363637041425866478473082778930664062500 * α ^ 12 + 52557215535889563135879554015106695279244905727351138276424395612451171875000 * α ^ 13 + 17560188550728447991878218358662068709211261557084724400278409291245117187500 * α ^ 14 + 5083558311018366382022659794526798695920221466826180257750759952604687500000 * α ^ 15 + 1273131764429501958625291301675693164238362230486966503823878444190878906250 * α ^ 16 + 274960492120840016369195438376101201319262210714934208739555078202929687500 * α ^ 17 + 50954380823074628723812132018848659015398414173106367885877485025457031250 * α ^ 18 + 8043619315575642311782000673332751078848207374194599271764060475643750000 * α ^ 19 + 1070647032300550686760844315611512648892236354901418090931769834405593750 * α ^ 20 + 118447064950886641697648118438020073800095586622991278431631099619912500 * α ^ 21 + 10665844034582511896384387237050410144703560308738822660894704597031250 * α ^ 22 + 756055215489708905909989210679280265318059125676239214550223981550000 * α ^ 23 + 39319509582765585318317434167304155450155442605644113789923547061875 * α ^ 24 + 867126925428575278846841639739898919922847699797676292404824708330 * α ^ 25 - 1342664334700830923321502819993530701259788051847367543772214665281 * α ^ 26 + 39483777041359676646803092797859249221387704496311861748873113400 * α ^ 27 - 58711046556251894173073392026014465411610439743591823421605392 * α ^ 28 + 2490932168525853073760934875391654922167755426092527716004768 * α ^ 29 + 299316943768298507774611885828874444092265356390330098080400 * α ^ 30 + 15336692487146884782753132557947737242171025616954771587840 * α ^ 31 + 493116066063688255278336127843281464063956961803863360000 * α ^ 32 + 8923910394517508916121212299646048703215085675738298880 * α ^ 33 - 42485806368509927498334028885467492467879729762661120 * α ^ 34 - 9926741056642548036510544310918633673463407651072000 * α ^ 35 - 427541739200753198037475741948767076883193745367040 * α ^ 36 - 12336686560635193418143284676363319056265591808000 * α ^ 37 - 276403480622187214471125457231894057984922849280 * α ^ 38 - 5061460700774592700650136059515237541978439680 * α ^ 39 - 77589542792718274978754693243996574602035200 * α ^ 40 - 1008285668556426930549466452256224957562880 * α ^ 41 - 11180151867078112441929755167105458176000 * α ^ 42 - 106057325448908908308826107393838940160 * α ^ 43 - 860453519636632559264422458435829760 * α ^ 44 - 5953015798094365467380006676070400 * α ^ 45 - 34925450531279060313143566663680 * α ^ 46 - 172262764126427765287157760000 * α ^ 47 - 705448234661772873443573760 * α ^ 48 - 2356408942484969918300160 * α ^ 49 - 6257674902168236195840 * α ^ 50 - 12711757957239406592 * α ^ 51 - 18555990127411200 * α ^ 52 - 17333951135744 * α ^ 53 - 7784628224 * α ^ 54) = 4006776526237583458791916745921571399903640427998587971001863479614257812500 * (17 - α) ^ 54 + 831652019387638593345638902447299305570259360126824448715224266052246093750000 * α ^ 1 * (17 - α) ^ 53 + 83833748304900879170452634641877950866675611368241564068775231838226318359375000 * α ^ 2 * (17 - α) ^ 52 + 5468494358777378393080477785807867951674090671443673031117236424446105957031250000 * α ^ 3 * (17 - α) ^ 51 + 259497095119023070284911959202753696905030203192837428866594793371009826660156250000 * α ^ 4 * (17 - α) ^ 50 + 9548226194342856021369990031496637841520575254703619359937770099499221801757812500000 * α ^ 5 * (17 - α) ^ 49 + 283554795754116919933939967317880593392006022363436344694634037363653737640380859375000 * α ^ 6 * (17 - α) ^ 48 + 6985033324607242622400264323272167984455201909490308654941771836141864102172851562500000 * α ^ 7 * (17 - α) ^ 47 + 145585869325517123027631865241602024127251143700135843061398935728533566792640686035156250 * α ^ 8 * (17 - α) ^ 46 + 2605939606481930370231755414493637687294479329903418074328564748827833386281097412109375000 * α ^ 9 * (17 - α) ^ 45 + 40524996895639459847128154228148170371947695272650286201553195462882818721524821166992187500 * α ^ 10 * (17 - α) ^ 44 + 552551133383357806856520189290844564406656538250136666178295793900819727635981966064453125000 * α ^ 11 * (17 - α) ^ 43 + 6654537960345176614579520210501969964341553464814299926502106023232060321118045116027832031250 * α ^ 12 * (17 - α) ^ 42 + 71215632892928225012541089836574503427207341702460836120538723682777701285820760548632812500000 * α ^ 13 * (17 - α) ^ 41 + 680613583355729809602306987711530797435340161763367564193121313750649561609059057159169921875000 * α ^ 14 * (17 - α) ^ 40 + 5832875752360000513642484795718619279175379757851803276997150658226737011497871446091396093750000 * α ^ 15 * (17 - α) ^ 39 + 44979351085207558150078784978662679910370590969134326277300556578996443629331813144059755039062500 * α ^ 16 * (17 - α) ^ 38 + 312995911940481513520445963433861073963208442217604567895958294256991627351128534764956244218750000 * α ^ 17 * (17 - α) ^ 37 + 1970161029906836645506545335621217130652959793873949162987985608245722153781520858422880420890625000 * α ^ 18 * (17 - α) ^ 36 + 11240168074382975494983845291739726207752209032492025653981589349256891847236794547066229926806250000 * α ^ 19 * (17 - α) ^ 35 + 58220468052171150534543089230853402616213765163545474800357913943776071267588624931694422468683718750 * α ^ 20 * (17 - α) ^ 34 + 274162442806735488937328580878545767896445602338781689345873092416421648387300355873155086008186200000 * α ^ 21 * (17 - α) ^ 33 + 1175053053219549755923303158761313219677705229404659836838649889496146832750569917119434117241667287500 * α ^ 22 * (17 - α) ^ 32 + 4587918386962882020150348519193673004398898248795343130672609419407279340288027481893308532612882750000 * α ^ 23 * (17 - α) ^ 31 + 16330076475454767959070546693996088924163345527886054247186679311654325903066537139062302883030633149375 * α ^ 24 * (17 - α) ^ 30 + 53015531748660804101125233244023173725306131782343261679623854226624053438968135738999293061644801261060 * α ^ 25 * (17 - α) ^ 29 + 157042247362868043075174929076891424448113760391534609598267651251111262726701902052468899161352536565826 * α ^ 26 * (17 - α) ^ 28 + 424536028113530069741207063773543340247417183854664190521457558189988983776332421257010922807774328703468 * α ^ 27 * (17 - α) ^ 27 + 1047394825014464265044437577949313703859620376795552005549249263622157394802977948988963043499590064285701 * α ^ 28 * (17 - α) ^ 26 + 2357953243932795895351786030037214986312773901878377266600410243701385112182023007703278183236835882555920 * α ^ 29 * (17 - α) ^ 25 + 4841990819787898672356879612840738450763274999724268831092864647028159910497634849060319644324211875401000 * α ^ 30 * (17 - α) ^ 24 + 9063584503650178882271337601783826443148131765373991434810543048088202441000466212270593355824045378675000 * α ^ 31 * (17 - α) ^ 23 + 15451128490873801008027757078817526210012989527697672000297488543102153793093056771081079889530059921809375 * α ^ 32 * (17 - α) ^ 22 + 23958789035470262232279921076956417405034112471262464267273767085684019981430087645587646696528226066737500 * α ^ 33 * (17 - α) ^ 21 + 33738977176761179018990595988066513346352404262225555749812365323678028997756330293158647680594843998343750 * α ^ 34 * (17 - α) ^ 20 + 43066010152981647775428783321099345843672023374934640403912525283591537133423955925346616576791170076562500 * α ^ 35 * (17 - α) ^ 19 + 49716389232502500304027459338301800974067035710033081062048758917500248639945950282904415348908887986328125 * α ^ 36 * (17 - α) ^ 18 + 51772728585970415852508288051049002543845872981898134416451565218988426676405878702958035332866606796875000 * α ^ 37 * (17 - α) ^ 17 + 48489623083597730277404885225414500632015670930460944310500759458078933768686805720241794646887945820312500 * α ^ 38 * (17 - α) ^ 16 + 40706685418039446342456126818361030430892463367085468425983118729461107320981091338190269943859904687500000 * α ^ 39 * (17 - α) ^ 15 + 30510757875107724377755328842206506253240610141014079628356809193148547036423525594278170823630233154296875 * α ^ 40 * (17 - α) ^ 14 + 20325417185768341572644199400008775190356569699126770047800664408936401012312339590678833285411352539062500 * α ^ 41 * (17 - α) ^ 13 + 11970484403352576009251094586102294750081037384202884978488076602265682461511720826286535223334289550781250 * α ^ 42 * (17 - α) ^ 12 + 6193242030824480837746170022650419963156765230142047685904514800454071854093027706906593305633666992187500 * α ^ 43 * (17 - α) ^ 11 + 2793420712321765649092179680582709716866031666381458570060592097389668488933904453892321322512969970703125 * α ^ 44 * (17 - α) ^ 10 + 1088149422884559786015096896649994047996413331792775697347682065754794925880331083486662942138671875000000 * α ^ 45 * (17 - α) ^ 9 + 361802514627870134054227480223533630715173215487471596187535638974794633464984427234290066680908203125000 * α ^ 46 * (17 - α) ^ 8 + 101146608070751659320633087948602468401536695297326173484816516224027843212819017493162674713134765625000 * α ^ 47 * (17 - α) ^ 7 + 23308619653592257439475827609650039406713094584665162739531070571873085270495926103569096851348876953125 * α ^ 48 * (17 - α) ^ 6 + 4309056167008746262541403431206719244122955714616670864926279020311783589907259065312067031860351562500 * α ^ 49 * (17 - α) ^ 5 + 614552339408580729666564781265917271485257491177590074251947797114305883650016905691361427307128906250 * α ^ 50 * (17 - α) ^ 4 + 63623700305983189824220164500388274837272339260459679341376353550049617549841760780096054077148437500 * α ^ 51 * (17 - α) ^ 3 + 4296576620263370001927713368254137045425780398934810417013483195008307979207405258715152740478515625 * α ^ 52 * (17 - α) ^ 2 + 149430873582062166621125852273186331577668585046621031080994039368115021643902842998504638671875000 * α ^ 53 * (17 - α) ^ 1 + 947247377954257591039710592438900578151634152117436911287820530796278073275661468505859375000000 * α ^ 54 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 54)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 56 ≤ n) (h1 : n ≤ 58) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (4006776526237583458791916745921571399903640427998587971001863479614257812500 + 36193299233577005092404435186325555880909575118523570487124919891357421875000 * α + 157404458430456801566314898531435489082055275896144801637965440750122070312500 * α ^ 2 + 438789302805190644765999692456086768304410010456706455086051940917968750000000 * α ^ 3 + 880644388246065999407804638303739222032368746089754793927588987350463867187500 * α ^ 4 + 1354948378632315916086740220782422392456213284262767321014325168609619140625000 * α ^ 5 + 1661602897691580734737365439849633466188200353673006461916168213272094726562500 * α ^ 6 + 1667045608015110082374111106109377028467549691711516663117268814086914062500000 * α ^ 7 + 1393634964581423479006807950372755382512403362475605339704530439338684082031250 * α ^ 8 + 983739476273137944395322828805928193025534886625965973020494254135131835937500 * α ^ 9 + 592005671863910309809560316101676243798968926448970748675875927594299316406250 * α ^ 10 + 305845520279728243480763379048878002620628430303914474045381805538574218750000 * α ^ 11 + 136301035857816688759209743042609079523363637041425866478473082778930664062500 * α ^ 12 + 52557215535889563135879554015106695279244905727351138276424395612451171875000 * α ^ 13 + 17560188550728447991878218358662068709211261557084724400278409291245117187500 * α ^ 14 + 5083558311018366382022659794526798695920221466826180257750759952604687500000 * α ^ 15 + 1273131764429501958625291301675693164238362230486966503823878444190878906250 * α ^ 16 + 274960492120840016369195438376101201319262210714934208739555078202929687500 * α ^ 17 + 50954380823074628723812132018848659015398414173106367885877485025457031250 * α ^ 18 + 8043619315575642311782000673332751078848207374194599271764060475643750000 * α ^ 19 + 1070647032300550686760844315611512648892236354901418090931769834405593750 * α ^ 20 + 118447064950886641697648118438020073800095586622991278431631099619912500 * α ^ 21 + 10665844034582511896384387237050410144703560308738822660894704597031250 * α ^ 22 + 756055215489708905909989210679280265318059125676239214550223981550000 * α ^ 23 + 39319509582765585318317434167304155450155442605644113789923547061875 * α ^ 24 + 867126925428575278846841639739898919922847699797676292404824708330 * α ^ 25 - 1342664334700830923321502819993530701259788051847367543772214665281 * α ^ 26 + 39483777041359676646803092797859249221387704496311861748873113400 * α ^ 27 - 58711046556251894173073392026014465411610439743591823421605392 * α ^ 28 + 2490932168525853073760934875391654922167755426092527716004768 * α ^ 29 + 299316943768298507774611885828874444092265356390330098080400 * α ^ 30 + 15336692487146884782753132557947737242171025616954771587840 * α ^ 31 + 493116066063688255278336127843281464063956961803863360000 * α ^ 32 + 8923910394517508916121212299646048703215085675738298880 * α ^ 33 - 42485806368509927498334028885467492467879729762661120 * α ^ 34 - 9926741056642548036510544310918633673463407651072000 * α ^ 35 - 427541739200753198037475741948767076883193745367040 * α ^ 36 - 12336686560635193418143284676363319056265591808000 * α ^ 37 - 276403480622187214471125457231894057984922849280 * α ^ 38 - 5061460700774592700650136059515237541978439680 * α ^ 39 - 77589542792718274978754693243996574602035200 * α ^ 40 - 1008285668556426930549466452256224957562880 * α ^ 41 - 11180151867078112441929755167105458176000 * α ^ 42 - 106057325448908908308826107393838940160 * α ^ 43 - 860453519636632559264422458435829760 * α ^ 44 - 5953015798094365467380006676070400 * α ^ 45 - 34925450531279060313143566663680 * α ^ 46 - 172262764126427765287157760000 * α ^ 47 - 705448234661772873443573760 * α ^ 48 - 2356408942484969918300160 * α ^ 49 - 6257674902168236195840 * α ^ 50 - 12711757957239406592 * α ^ 51 - 18555990127411200 * α ^ 52 - 17333951135744 * α ^ 53 - 7784628224 * α ^ 54) / (720871145576788208016023138432681714844933807849884033203125000 * (3 + α) ^ 27) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B56_58 diff --git a/Sendov/FiniteRange/Degree58_60.lean b/Sendov/FiniteRange/Degree58_60.lean index afdd6c3..16a8b11 100644 --- a/Sendov/FiniteRange/Degree58_60.lean +++ b/Sendov/FiniteRange/Degree58_60.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 58 to 60 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 56 * (1180273288616099684023784650402498199886255444730023274978571199510266513047596 + 11055102824011442029948266567510506642575381276841013106178383140649638883273740 * α + 49922645194024990734283616516471280600334184364447547102243551298880869797559488 * α ^ 2 + 144719942608174873104026182095524650959577750970144395839719569131273169856379216 * α ^ 3 + 302526482246635225757578631533959631447003848728875689601323895427543714021299068 * α ^ 4 + 485662255765025402514981086091947264736043236799566038683821482401809082117981716 * α ^ 5 + 622606333409943749753890815208648354755606137297243000849237534232491249017638372 * α ^ 6 + 654352069860427639900751348035281558837881303628117455206054590616141095225034932 * α ^ 7 + 574357399231416827070511854689853503943460240353865007966655407656850680547039034 * α ^ 8 + 426752571345870223801790426727818388140106457832728071034614633845667453226768626 * α ^ 9 + 271079935317622563319456334579591661701883897872193010593643933885082711035509852 * α ^ 10 + 148286371479076003045732417755582133525685636981220867944156217604240361014274724 * α ^ 11 + 70217169066647225915394151645973808431273168363378941311910545513943342491505944 * α ^ 12 + 28882635903906998561313897779843874583553384770520360078626138405360811163881868 * α ^ 13 + 10340675254845519580917140785070160244501596661998078491888557158268998114446532 * α ^ 14 + 3224423637549642502496418645711742177932306998129835583325750859424757337666996 * α ^ 15 + 875062504101721302059576940201180260130574140021726848117119157209427049292266 * α ^ 16 + 206253961710804940753907484420744734282964403780943395544748624256594408470306 * α ^ 17 + 42070236802464351764635254679415144786913128539020355841577805021278534599952 * α ^ 18 + 7386217051829558880237703381942358818281589489452528309990518263995367432488 * α ^ 19 + 1107793613576531791057535432236447149617292886122026324465700872270457547494 * α ^ 20 + 140459087137897856469559866359157699541937133355950394902889100420287426914 * α ^ 21 + 14838359760717420231756157247609092582149974794155897343599292760550967914 * α ^ 22 + 1279004725824261809420174464624373933895777466651732360112330465852550258 * α ^ 23 + 87033426312093344876434088654180488427125423854890952784009041976465947 * α ^ 24 + 4369112665592393971521458232346790403396711247658540001242310421975335 * α ^ 25 + 97654992764826340667007297954456940399851548824989983096539223841294 * α ^ 26 - 140180336953330902099623933788922389004727627031585783295797300519590 * α ^ 27 + 4011521197356040330478113154305443808925568648433687983973999832370 * α ^ 28 - 6836116057285781356883522416064683372386240155164063320736832232 * α ^ 29 + 136155913451608763461692617832470536736112881493096843133744560 * α ^ 30 + 23084190208503516369122355362110577411004819796039225427268288 * α ^ 31 + 1272092669921250187525125636594403706428638167041905626630688 * α ^ 32 + 43743288386492835342171671864673441962710429642110919385856 * α ^ 33 + 919770851750237042763795205605716932136524848257092998144 * α ^ 34 + 3589129787637507437982773070768409846725811870537367040 * α ^ 35 - 616787227367020803961294798626057817769112354291227136 * α ^ 36 - 30943009074599150760660807547437896432729575808956416 * α ^ 37 - 952040288448666548370356300676837076289373764554752 * α ^ 38 - 22303674458304714179931228274300996373189822005248 * α ^ 39 - 424667137052011465151087643604559827985297448960 * α ^ 40 - 6764616781706422065650823730243312809557557248 * α ^ 41 - 91516551558371359215307258976568083952304128 * α ^ 42 - 1060132719651553338827644611213921972781056 * α ^ 43 - 10557532799422900249752275241549216743424 * α ^ 44 - 90481973634654084996556237361914576896 * α ^ 45 - 666432341608325016551912342849323008 * α ^ 46 - 4202788903097596849838434642034688 * α ^ 47 - 22554190076903951857505928216576 * α ^ 48 - 102065451905712762371350462464 * α ^ 49 - 384517782188687390618419200 * α ^ 50 - 1184406710041525201403904 * α ^ 51 - 2906644614364092432384 * α ^ 52 - 5467069217104723968 * α ^ 53 - 7402337748385792 * α ^ 54 - 6424197332992 * α ^ 55 - 2684354560 * α ^ 56) = 1180273288616099684023784650402498199886255444730023274978571199510266513047596 * (17 - α) ^ 56 + 254032052170696096814452472070218512117411786611178526203832500563618785746318956 * α ^ 1 * (17 - α) ^ 55 + 26581786465992714133606222775502371032129394160055924210292174209129794157448936772 * α ^ 2 * (17 - α) ^ 54 + 1801905125284524294246494051997323405505883272969655457886034380748404658915029385356 * α ^ 3 * (17 - α) ^ 53 + 88960777843487839207354469588977939024483934333485516580514560192823003078437474637384 * α ^ 4 * (17 - α) ^ 52 + 3409710295444689753751021773779609449447011909852801588651071013422638895502085385574456 * α ^ 5 * (17 - α) ^ 51 + 105611745061099871040994619483246321125469657724218486870230193879528974892413607636605284 * α ^ 6 * (17 - α) ^ 50 + 2717077493210926098447489650385141874390859518222133351745212828060950258218810177908282556 * α ^ 7 * (17 - α) ^ 49 + 59226539189538299382222748715390123146365770386986878118026762708622792734361308033174370018 * α ^ 8 * (17 - α) ^ 48 + 1110347623085275380732784124563019672170207376288907445733220470280957735947728184470496756010 * α ^ 9 * (17 - α) ^ 47 + 18112519692658810410404967374345439836251270145825076491663143586046571832030458464477826206258 * α ^ 10 * (17 - α) ^ 46 + 259468406097457687929633525944011735968016319542087733822510053479299676655957583926253741360502 * α ^ 11 * (17 - α) ^ 45 + 3288616364869040104475987141993494253571602787363843112397732704776764511075222653495077733735718 * α ^ 12 * (17 - α) ^ 44 + 37103473125865952584340786773431223496072304382597727768926156417429611089103427290200640921026334 * α ^ 13 * (17 - α) ^ 43 + 374523382812426223233967303671275687297451096894379697013331090967253251615175373801177901144258730 * α ^ 14 * (17 - α) ^ 42 + 3396494550442924093336698525515677714454583693723746546679078674756021148647562726100992633195827670 * α ^ 15 * (17 - α) ^ 41 + 27771451470570936428940278209636484839068297258115446941354573210378654498093153647787388326291195220 * α ^ 16 * (17 - α) ^ 40 + 205336433200531842769564752332775005425876161312494024088869532088213815964669131170023033890476305980 * α ^ 17 * (17 - α) ^ 39 + 1376302917197732669050568166563895672822852883204651206746822345275035657680019417369627527115086850120 * α ^ 18 * (17 - α) ^ 38 + 8380155294397784796024596289754563707905478379672589828457151616147990659832389424273341383748688207080 * α ^ 19 * (17 - α) ^ 37 + 46434805880795731321224499533392807251809590691101718819109701496201837794500680135302573321020690890746 * α ^ 20 * (17 - α) ^ 36 + 234491333325177991679288999498604121924586729800797548175219657080832899570210449706339657838128968884354 * α ^ 21 * (17 - α) ^ 35 + 1080514930086925704280859540483502286254671084929525637672420222697615347555423346347115532203110643365136 * α ^ 22 * (17 - α) ^ 34 + 4547675284413232416488077752788320517949654297288884032643195010720956134703008952100555630475629759787488 * α ^ 23 * (17 - α) ^ 33 + 17496546097098586152071398152312222042613115074033174731514387311101666529876250406780911401607973057493255 * α ^ 24 * (17 - α) ^ 32 + 61573424970057153431741932997114452252230749510452379581517661469288846340022317444210252355996069897749331 * α ^ 25 * (17 - α) ^ 31 + 198297654024175037814903698649403184988215012123240470670091291048259056629782551733808484416396638864067091 * α ^ 26 * (17 - α) ^ 30 + 584610302749161753333489816331275650573703865862791211866486561498961706693997631039254643972613296017180617 * α ^ 27 * (17 - α) ^ 29 + 1578046905956627892814531753544431465414315118110738633436435926556242944082783767807930560452112935615842171 * α ^ 28 * (17 - α) ^ 28 + 3900276267502012608001991748970773203576515687854492513578111746545720357741690474840268134056865690598209279 * α ^ 29 * (17 - α) ^ 27 + 8825565680944180807206852648457428249507576570214954247410910715730515927908602962682166825659628608449565179 * α ^ 30 * (17 - α) ^ 26 + 18278222890683728517844209588507295086668349633646134150369498537778483167121641476779372484086759659269711781 * α ^ 31 * (17 - α) ^ 25 + 34630021303309994264801974849783975057715767549012563612835970835153541351334334084636838049899704411229419039 * α ^ 32 * (17 - α) ^ 24 + 59976325403926759553950096138547851891588162346459693279652757133352417289699475136155912596938565990681022967 * α ^ 33 * (17 - α) ^ 23 + 94859908857514726802312972207926527679144706496572092127703134483420755663937004295941931559564856864612372015 * α ^ 34 * (17 - α) ^ 22 + 136838029261198215465308944618229439296028860400759258689603958243702943063871561985963901374611376885862608933 * α ^ 35 * (17 - α) ^ 21 + 179750481304348065934713749450324777683615725218792657415497203296024872885988657067853702018371602813684069687 * α ^ 36 * (17 - α) ^ 20 + 214614205815431393733148792819846945536633335373334115752048809273342647443432539934607000062616305939408924323 * α ^ 37 * (17 - α) ^ 19 + 232391950882130480511841466255675296149805103394932221634682309682031574184073376765275830067134447105269029319 * α ^ 38 * (17 - α) ^ 18 + 227646786129095617123180754743680811362220841807439017659139374884333921571156246794142321243097055097178445825 * α ^ 39 * (17 - α) ^ 17 + 201151592000254076319111933803082921016858033652344635301102367059012097196101762301692963719714653038174763855 * α ^ 40 * (17 - α) ^ 16 + 159796714515585050308711763046365954383154641733651622252372673160438440025715520354135554841621456682694603135 * α ^ 41 * (17 - α) ^ 15 + 113694441321074008752288203116701595054184371599569875421293420056220499034682316015196771177249973056572181735 * α ^ 42 * (17 - α) ^ 14 + 72130500744694542887028943813151106507208801012210269142093276885199604435222351545247283246975115560376609205 * α ^ 43 * (17 - α) ^ 13 + 40593915959417627531746494374957888051425398581583793505319726935377556193558075899850407121984115730929357755 * α ^ 44 * (17 - α) ^ 12 + 20142112914146928990742750521398817973806574189219001955193033477789707030767693751116805380225357379276747519 * α ^ 45 * (17 - α) ^ 11 + 8746984555426014571216178944742661168209625273320645227018468690933303880145359024731425263277253405247586951 * α ^ 46 * (17 - α) ^ 10 + 3294813943512375946477459661112271578543735031048904613485581394105299356535226701518930871689765592849920009 * α ^ 47 * (17 - α) ^ 9 + 1064633594182767781418524670877965310710625221215403900701843563201440674916875929401734783421144317918768437 * α ^ 48 * (17 - α) ^ 8 + 290979947292633634820286085206318086271058595522743900697255282277868275830483412118913673100403134596829605 * α ^ 49 * (17 - α) ^ 7 + 66053632008286815218730609011172165768275118555864770965140596782012442105314066073321580207922244489207001 * α ^ 50 * (17 - α) ^ 6 + 12152795314691969352387359587094653935442718022653966020106284283370382118838609048927994949757671991794739 * α ^ 51 * (17 - α) ^ 5 + 1751156608268941082844684121012320147103407396012602177215161083358650243742317419805210038235339659097451 * α ^ 52 * (17 - α) ^ 4 + 187813139479594914512845605964389800598941841721249536400462885091353372097871422654926648798226033258823 * α ^ 53 * (17 - α) ^ 3 + 13802072582465965788484953766306541577986163631972344323322049452623866943671442557170586787638780254425 * α ^ 54 * (17 - α) ^ 2 + 594982734136165220266045344041112246141469375919551772765097596644107694713723809345475527250815129375 * α ^ 55 * (17 - α) ^ 1 + 10211558413705494402424769335540267701249567140173495481288972120637089282914579657148619242232312500 * α ^ 56 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 56)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 58 ≤ n) (h1 : n ≤ 60) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (1180273288616099684023784650402498199886255444730023274978571199510266513047596 + 11055102824011442029948266567510506642575381276841013106178383140649638883273740 * α + 49922645194024990734283616516471280600334184364447547102243551298880869797559488 * α ^ 2 + 144719942608174873104026182095524650959577750970144395839719569131273169856379216 * α ^ 3 + 302526482246635225757578631533959631447003848728875689601323895427543714021299068 * α ^ 4 + 485662255765025402514981086091947264736043236799566038683821482401809082117981716 * α ^ 5 + 622606333409943749753890815208648354755606137297243000849237534232491249017638372 * α ^ 6 + 654352069860427639900751348035281558837881303628117455206054590616141095225034932 * α ^ 7 + 574357399231416827070511854689853503943460240353865007966655407656850680547039034 * α ^ 8 + 426752571345870223801790426727818388140106457832728071034614633845667453226768626 * α ^ 9 + 271079935317622563319456334579591661701883897872193010593643933885082711035509852 * α ^ 10 + 148286371479076003045732417755582133525685636981220867944156217604240361014274724 * α ^ 11 + 70217169066647225915394151645973808431273168363378941311910545513943342491505944 * α ^ 12 + 28882635903906998561313897779843874583553384770520360078626138405360811163881868 * α ^ 13 + 10340675254845519580917140785070160244501596661998078491888557158268998114446532 * α ^ 14 + 3224423637549642502496418645711742177932306998129835583325750859424757337666996 * α ^ 15 + 875062504101721302059576940201180260130574140021726848117119157209427049292266 * α ^ 16 + 206253961710804940753907484420744734282964403780943395544748624256594408470306 * α ^ 17 + 42070236802464351764635254679415144786913128539020355841577805021278534599952 * α ^ 18 + 7386217051829558880237703381942358818281589489452528309990518263995367432488 * α ^ 19 + 1107793613576531791057535432236447149617292886122026324465700872270457547494 * α ^ 20 + 140459087137897856469559866359157699541937133355950394902889100420287426914 * α ^ 21 + 14838359760717420231756157247609092582149974794155897343599292760550967914 * α ^ 22 + 1279004725824261809420174464624373933895777466651732360112330465852550258 * α ^ 23 + 87033426312093344876434088654180488427125423854890952784009041976465947 * α ^ 24 + 4369112665592393971521458232346790403396711247658540001242310421975335 * α ^ 25 + 97654992764826340667007297954456940399851548824989983096539223841294 * α ^ 26 - 140180336953330902099623933788922389004727627031585783295797300519590 * α ^ 27 + 4011521197356040330478113154305443808925568648433687983973999832370 * α ^ 28 - 6836116057285781356883522416064683372386240155164063320736832232 * α ^ 29 + 136155913451608763461692617832470536736112881493096843133744560 * α ^ 30 + 23084190208503516369122355362110577411004819796039225427268288 * α ^ 31 + 1272092669921250187525125636594403706428638167041905626630688 * α ^ 32 + 43743288386492835342171671864673441962710429642110919385856 * α ^ 33 + 919770851750237042763795205605716932136524848257092998144 * α ^ 34 + 3589129787637507437982773070768409846725811870537367040 * α ^ 35 - 616787227367020803961294798626057817769112354291227136 * α ^ 36 - 30943009074599150760660807547437896432729575808956416 * α ^ 37 - 952040288448666548370356300676837076289373764554752 * α ^ 38 - 22303674458304714179931228274300996373189822005248 * α ^ 39 - 424667137052011465151087643604559827985297448960 * α ^ 40 - 6764616781706422065650823730243312809557557248 * α ^ 41 - 91516551558371359215307258976568083952304128 * α ^ 42 - 1060132719651553338827644611213921972781056 * α ^ 43 - 10557532799422900249752275241549216743424 * α ^ 44 - 90481973634654084996556237361914576896 * α ^ 45 - 666432341608325016551912342849323008 * α ^ 46 - 4202788903097596849838434642034688 * α ^ 47 - 22554190076903951857505928216576 * α ^ 48 - 102065451905712762371350462464 * α ^ 49 - 384517782188687390618419200 * α ^ 50 - 1184406710041525201403904 * α ^ 51 - 2906644614364092432384 * α ^ 52 - 5467069217104723968 * α ^ 53 - 7402337748385792 * α ^ 54 - 6424197332992 * α ^ 55 - 2684354560 * α ^ 56) / (70705400725025142717653694431177969790740772523753364892596242608 * (3 + α) ^ 28) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B58_60 diff --git a/Sendov/FiniteRange/Degree6.lean b/Sendov/FiniteRange/Degree6.lean index 140edec..f1287fc 100644 --- a/Sendov/FiniteRange/Degree6.lean +++ b/Sendov/FiniteRange/Degree6.lean @@ -76,11 +76,10 @@ theorem finite_range_six (hα : 0 ≤ α) (hfeas : c 6 α ^ 2 ≤ A 6 α) : R 6 rw [M_six] at h linarith have hP : 0 < -24 * α ^ 4 - 342 * α ^ 3 + 2345 * α ^ 2 - 900 * α + 1575 := by - nlinarith [mul_nonneg (mul_nonneg (mul_nonneg hα hα) hα) (sub_nonneg.2 hle), - mul_nonneg (mul_nonneg hα hα) (sub_nonneg.2 hle), sq_nonneg (1103 * α - 450)] - have hpos : 0 < 1 - R 6 α := by - rw [one_sub_R_six hα] - exact div_pos hP (by positivity) - linarith + nlinarith only [hα, mul_nonneg (pow_nonneg hα 3) (sub_nonneg.2 hle), + mul_nonneg (pow_nonneg hα 2) (sub_nonneg.2 hle), sq_nonneg (1103 * α - 450)] + apply sub_pos.mp + rw [one_sub_R_six hα] + exact div_pos hP (by positivity) end Sendov diff --git a/Sendov/FiniteRange/Degree60_63.lean b/Sendov/FiniteRange/Degree60_63.lean index 6b89ae4..50fbb1e 100644 --- a/Sendov/FiniteRange/Degree60_63.lean +++ b/Sendov/FiniteRange/Degree60_63.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 60 to 63 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 58 * (1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 + 16985863033574280235844441932687847244474918343296922124467065830558560591641911607696 * α + 79535686565443616767714198705465441607069525916537281975943363396026310601750092892488 * α ^ 2 + 239403368066863055363036191982445140250970254028533507257869611464498452359820776516672 * α ^ 3 + 520412199687668549649368000742289832307395871986227854434049639793742028919048260538980 * α ^ 4 + 870157990458303443210342456693112304974391575125591793142671535717764222680483811054120 * α ^ 5 + 1163895406905166893909394336483096101920864956907539643884037297958617393209091960980980 * α ^ 6 + 1278712702347990314588936279615328559669420142052152673561809586945926657118282053100192 * α ^ 7 + 1175725999507118690334304481188590417967828338375807066246239349405176693210977652965164 * α ^ 8 + 917174565683194380325199349414315003531063568224297761645149376513377860921193466166360 * α ^ 9 + 613220450431269534465945368150179786921282701580434508261534043083701875736956664994572 * α ^ 10 + 354057578771667900301737961009087756507978666072508030411200442531544505558679233553472 * α ^ 11 + 177508212962690728847102755764000185519630950904902948797136565592445320434555097902358 * α ^ 12 + 77576143881435246639915934911657056385846898645191797585491387399418570120013455336412 * α ^ 13 + 29625606539961534087112448697426117322036816304400291238815402402574337305159894234710 * α ^ 14 + 9897983624006015895072166102753315050019559506815047218656308374776682178809801281072 * α ^ 15 + 2893024329186264383797233494270141942147451227576867206489337752203105179024976096612 * α ^ 16 + 738824037484601173560395482737511489082491085984005275312812825534063503137534438984 * α ^ 17 + 164441392895370259121202826289551958180582089330511860705087484253672173523954414324 * α ^ 18 + 31771089808007468337610992777240040391387210585565359776690610466850812101226150720 * α ^ 19 + 5298220195377128677201324507710581490774005592592493587530562214239637638718207838 * α ^ 20 + 756659597417575188091510844865331006747834890107597233256807850344151631080238572 * α ^ 21 + 91559608573015197712368058376578410389957871248555658418907655613710858144349974 * α ^ 22 + 9249930419338172598175237698997019936144549918443437721165100485815394918388112 * α ^ 23 + 763883913294738134810454963300633389711111356082193955572628106712061571529450 * α ^ 24 + 49887514803037691118937977551057551319824185688173200456490865107511572859188 * α ^ 25 + 2408300944763273858718491162262422770972533056902127038712768748993172577610 * α ^ 26 + 51725078185114864055621675260185352972397611437758098966549358454837797760 * α ^ 27 - 77510592929500392468407361123374953300216693743671418464304395453235289971 * α ^ 28 + 2067570494221092433188386134604931347621528152582381523034724429480663810 * α ^ 29 - 4580593295775337280722829599699027320935759304984497739306397718132427 * α ^ 30 + 167416972491317272532611766388094644865407567559322236979252017800 * α ^ 31 + 8389683035480047874686298369093744577278032988658533654716580671488 * α ^ 32 + 533168330392361738160636316662426153463437758146484284733956527840 * α ^ 33 + 20133734272551384350294239387428682262688585273913890267463998960 * α ^ 34 + 493961052258347053233401169722862536905607351132290352999275776 * α ^ 35 + 5693741143796291743936421907647419400331769333817148390864384 * α ^ 36 - 136838149185369327185106181434226275722488605188850651649536 * α ^ 37 - 10213381894013887312358741093692449757528996456249043806464 * α ^ 38 - 350916645279993747972377869550082945451923877049098721280 * α ^ 39 - 8752703600310726164117509854956335599020724135444320256 * α ^ 40 - 174795107690037567064791487247091959281487206843686912 * α ^ 41 - 2905560404482515211390475250648416164278477823340544 * α ^ 42 - 40986185232466565782519730515559353841538308898816 * α ^ 43 - 495823850271711791881581412818585367225361694720 * α ^ 44 - 5173168623120670073594814754124350179396943872 * α ^ 45 - 46665067131765629087874046716431817185624064 * α ^ 46 - 363947916336732295692730495412120808062976 * α ^ 47 - 2448922340507063244670480160751278358528 * α ^ 48 - 14156403192874033788431089246006149120 * α ^ 49 - 69840635580766128998624519726825472 * α ^ 50 - 291304208587694376741876403273728 * α ^ 51 - 1013847100270960749479253245952 * α ^ 52 - 2890985222950997734006456320 * α ^ 53 - 6580251459272551201505280 * α ^ 54 - 11498869995682148646912 * α ^ 55 - 14487778418579472384 * α ^ 56 - 11716883921240064 * α ^ 57 - 4568503025664 * α ^ 58) = 1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 * (17 - α) ^ 58 + 390326433597525193146123071698409867301520390117218290267746409833092718425696728651808 * α ^ 1 * (17 - α) ^ 57 + 42339767414709412024800543085671455832484522045547354532982698096600368845688639786434272 * α ^ 2 * (17 - α) ^ 56 + 2978288251912812668426975142881017511384301236011339350466382171100719277406612535201202432 * α ^ 3 * (17 - α) ^ 55 + 152745949949503787162875767681479712010274958086345519055757721242134449740576558561672466100 * α ^ 4 * (17 - α) ^ 54 + 6088522642574857806357024467621421962247301068049055791879352484148857589737344570006424306432 * α ^ 5 * (17 - α) ^ 53 + 196353730172495768212131228592895964623220340501637536200602452342681588928305193631061786495128 * α ^ 6 * (17 - α) ^ 52 + 5266157866495799387947512134510522910378331486905487931902457256370064452591463479230852331820688 * α ^ 7 * (17 - α) ^ 51 + 119820143547425060414405575247909992318712489020361652433663435983410928998020585429365087295873272 * α ^ 8 * (17 - α) ^ 50 + 2347881458090802952975815753665509878263409227272937917396103015417709833460343242062605055065007520 * α ^ 9 * (17 - α) ^ 49 + 40087439558071587468650026480818375755059891510076862445505823029454511957690006955557287865611736368 * α ^ 10 * (17 - α) ^ 48 + 601952482871233638447257366201476457757370789071367246820395949483198507616680072154695375018993206080 * α ^ 11 * (17 - α) ^ 47 + 8009470199896280650115766696812280446758293363345211706745554624342950667301865303395190896548719848894 * α ^ 12 * (17 - α) ^ 46 + 95019362618823693655434560324233095572340322211181765633801354884655907381821543655651592610813813891216 * α ^ 13 * (17 - α) ^ 45 + 1010201707551433403309553561274371166022594138303310301376573778032472462922417174557444934419810264510660 * α ^ 14 * (17 - α) ^ 44 + 9666021740205241072831491648575295854988543778205392913804696971472866176266073951546563512467374588927208 * α ^ 15 * (17 - α) ^ 43 + 83539422247937309919557615020970488939815680020028362327882719748972398761527927690277222254506587818510230 * α ^ 16 * (17 - α) ^ 42 + 654118420001028745738306390006036203398367424921715171378029833094091806885053261792691008623047458390979656 * α ^ 17 * (17 - α) ^ 41 + 4652186358394523426651350117431277481053696460019422776379929513303869171324522998809216735658736365543149056 * α ^ 18 * (17 - α) ^ 40 + 30118791616775324911184234952445703914857411555877912743140868805910755261334373116907433215385078679006707440 * α ^ 19 * (17 - α) ^ 39 + 177826427793428069222664936517971981732084250622079798759954938089906960407318562179543208670385720641305484484 * α ^ 20 * (17 - α) ^ 38 + 958974728072861489890512212348583321104118795534766915893103879494275523886658791163551854756652905815510994528 * α ^ 21 * (17 - α) ^ 37 + 4729723071531116796957485128322656283636236954549201452338482026970860715184248091976900742259324658054589766592 * α ^ 22 * (17 - α) ^ 36 + 21357626391876046213696677013115319309126810433424794269849513349981113078786111769550369530995181611742183411536 * α ^ 23 * (17 - α) ^ 35 + 88378492075701468992449068981435994543226968075794931456837379496731600212606957395063382063437679158720468757170 * α ^ 24 * (17 - α) ^ 34 + 335374317924993519374894630236901278966604414721735688724835686564184905864027923099074702766636244586098764495656 * α ^ 25 * (17 - α) ^ 33 + 1167747403010750979143600445942797877583165267655942642217360148980523954073844543734436948340308328790173989450240 * α ^ 26 * (17 - α) ^ 32 + 3732406493950907275441950492949127432338499662676613602897135646128454363022292331302101040551201738067461761785664 * α ^ 27 * (17 - α) ^ 31 + 10954129200438058193458578123785740490187961119866684050714899067863611709664062247915680616127050262599212424644897 * α ^ 28 * (17 - α) ^ 30 + 29524937330321420901887693835267567366420221233340924484096603443964250287652843237880043795863468001106755829620680 * α ^ 29 * (17 - α) ^ 29 + 73087125140139025535278935287700443682500254736472038981634113551624541486231287807821582020794101152220739006249054 * α ^ 30 * (17 - α) ^ 28 + 166147644042440368311067169194067229624014747885167057075915274327610140356799603915688925405707986646551735878107548 * α ^ 31 * (17 - α) ^ 27 + 346772843057251234464569444053204287523460387723124946687308651228411784130792835892965479313436122483094189414638435 * α ^ 32 * (17 - α) ^ 26 + 664225955992969098770607024010663586597562367955519444707479326460670050391696600135144018377249349272512491633374996 * α ^ 33 * (17 - α) ^ 25 + 1166927452705629997542488080350699352093937922567202455194634401101839128946832909551419826543265369338614818217043960 * α ^ 34 * (17 - α) ^ 24 + 1878756607833380897964887521267252840224951551991841799719666838851961513969673042361037791640974884809523420884857896 * α ^ 35 * (17 - α) ^ 23 + 2769054221066722167360357163072398302792888941316285917570542419942819549648264402600819292556739224578295584544111593 * α ^ 36 * (17 - α) ^ 22 + 3731200624302652450167208268451073697815114712494349214865173019453170935880402861700349003895204451567678626785884944 * α ^ 37 * (17 - α) ^ 21 + 4589060320062131760404941760267700835789214136011164185047467243912104258380281276437542650223991907463154227654480250 * α ^ 38 * (17 - α) ^ 20 + 5142005613111678624089090068072653156514352316794579159234104771289794844001366200904371725907143894777202797701901140 * α ^ 39 * (17 - α) ^ 19 + 5237411173258795881045797059007984704429066340121408567111553635714834497251049352739808449923037569813646734054022299 * α ^ 40 * (17 - α) ^ 18 + 4836963127294992600059755436214556792844531244095433636867849886599932076358086832823383902964112824599524794814907660 * α ^ 41 * (17 - α) ^ 17 + 4038642993383808502646993082987941730662364203715934601149860715099116021657255631782766462484195430978656049244711644 * α ^ 42 * (17 - α) ^ 16 + 3038452569137952848001398255617645415509309374884449236698224469982642958671749123930862050454967951657624568575856688 * α ^ 43 * (17 - α) ^ 15 + 2051868663368925893596995729015571533363774183714583901584727359036447948070300988236179249392897564162618659414308125 * α ^ 44 * (17 - α) ^ 14 + 1238175994140035374637906473341260146948966827890334540274993830863642501653683339638928725989225430525272809854519160 * α ^ 45 * (17 - α) ^ 13 + 664157193310869042816823748632341892142095205218119162176744496952019558037232907168597445007823380125777368765119662 * α ^ 46 * (17 - α) ^ 12 + 314709886085135861297147136857650883344977185951101514937597344260222119762475730654304761445438390089176776231442524 * α ^ 47 * (17 - α) ^ 11 + 130752300650671071539193189087470650687679774298245936504525933790335489689909687270813505169056399644554354547239027 * α ^ 48 * (17 - α) ^ 10 + 47197367207696915154864396118931631129224589120774745992092456851672119895365941889175184835650784414267376300303620 * α ^ 49 * (17 - α) ^ 9 + 14634551667218002061058569723384799807420346162568828832552477052180173516934500629665142381604576011817456177436512 * α ^ 50 * (17 - α) ^ 8 + 3842020781478673446935098659029021030741590331823487291470293090299720569242182142621667182316185787786272194127544 * α ^ 51 * (17 - α) ^ 7 + 838031670173391441198956875841265626545050410662677811959134541401400325959689376985919100766189972881282787577763 * α ^ 52 * (17 - α) ^ 6 + 148041122984446508528033501826038847912820726117568892710474612036947233357823264896703744164136565988458171335488 * α ^ 53 * (17 - α) ^ 5 + 20425027753973244256487010270626798809629979580987772972987591577599400419675783451565774908699336057777964446110 * α ^ 54 * (17 - α) ^ 4 + 2082801294909426227172103997302542506576066130763213820723347100167035816595437754294159646550971592826080127596 * α ^ 55 * (17 - α) ^ 3 + 143053115347005574042966026900851192531277156875872861510463214959748868032658829240606333338274956129514869223 * α ^ 56 * (17 - α) ^ 2 + 5492607925836276782575645752168619846129179160632349319557999016078091770978332301317881391624780373381782060 * α ^ 57 * (17 - α) ^ 1 + 68316788541465931995562079450677157534774523435506193215243865134760205880356610515710383859614369923388540 * α ^ 58 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 58)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 60 ≤ n) (h1 : n ≤ 63) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 + 16985863033574280235844441932687847244474918343296922124467065830558560591641911607696 * α + 79535686565443616767714198705465441607069525916537281975943363396026310601750092892488 * α ^ 2 + 239403368066863055363036191982445140250970254028533507257869611464498452359820776516672 * α ^ 3 + 520412199687668549649368000742289832307395871986227854434049639793742028919048260538980 * α ^ 4 + 870157990458303443210342456693112304974391575125591793142671535717764222680483811054120 * α ^ 5 + 1163895406905166893909394336483096101920864956907539643884037297958617393209091960980980 * α ^ 6 + 1278712702347990314588936279615328559669420142052152673561809586945926657118282053100192 * α ^ 7 + 1175725999507118690334304481188590417967828338375807066246239349405176693210977652965164 * α ^ 8 + 917174565683194380325199349414315003531063568224297761645149376513377860921193466166360 * α ^ 9 + 613220450431269534465945368150179786921282701580434508261534043083701875736956664994572 * α ^ 10 + 354057578771667900301737961009087756507978666072508030411200442531544505558679233553472 * α ^ 11 + 177508212962690728847102755764000185519630950904902948797136565592445320434555097902358 * α ^ 12 + 77576143881435246639915934911657056385846898645191797585491387399418570120013455336412 * α ^ 13 + 29625606539961534087112448697426117322036816304400291238815402402574337305159894234710 * α ^ 14 + 9897983624006015895072166102753315050019559506815047218656308374776682178809801281072 * α ^ 15 + 2893024329186264383797233494270141942147451227576867206489337752203105179024976096612 * α ^ 16 + 738824037484601173560395482737511489082491085984005275312812825534063503137534438984 * α ^ 17 + 164441392895370259121202826289551958180582089330511860705087484253672173523954414324 * α ^ 18 + 31771089808007468337610992777240040391387210585565359776690610466850812101226150720 * α ^ 19 + 5298220195377128677201324507710581490774005592592493587530562214239637638718207838 * α ^ 20 + 756659597417575188091510844865331006747834890107597233256807850344151631080238572 * α ^ 21 + 91559608573015197712368058376578410389957871248555658418907655613710858144349974 * α ^ 22 + 9249930419338172598175237698997019936144549918443437721165100485815394918388112 * α ^ 23 + 763883913294738134810454963300633389711111356082193955572628106712061571529450 * α ^ 24 + 49887514803037691118937977551057551319824185688173200456490865107511572859188 * α ^ 25 + 2408300944763273858718491162262422770972533056902127038712768748993172577610 * α ^ 26 + 51725078185114864055621675260185352972397611437758098966549358454837797760 * α ^ 27 - 77510592929500392468407361123374953300216693743671418464304395453235289971 * α ^ 28 + 2067570494221092433188386134604931347621528152582381523034724429480663810 * α ^ 29 - 4580593295775337280722829599699027320935759304984497739306397718132427 * α ^ 30 + 167416972491317272532611766388094644865407567559322236979252017800 * α ^ 31 + 8389683035480047874686298369093744577278032988658533654716580671488 * α ^ 32 + 533168330392361738160636316662426153463437758146484284733956527840 * α ^ 33 + 20133734272551384350294239387428682262688585273913890267463998960 * α ^ 34 + 493961052258347053233401169722862536905607351132290352999275776 * α ^ 35 + 5693741143796291743936421907647419400331769333817148390864384 * α ^ 36 - 136838149185369327185106181434226275722488605188850651649536 * α ^ 37 - 10213381894013887312358741093692449757528996456249043806464 * α ^ 38 - 350916645279993747972377869550082945451923877049098721280 * α ^ 39 - 8752703600310726164117509854956335599020724135444320256 * α ^ 40 - 174795107690037567064791487247091959281487206843686912 * α ^ 41 - 2905560404482515211390475250648416164278477823340544 * α ^ 42 - 40986185232466565782519730515559353841538308898816 * α ^ 43 - 495823850271711791881581412818585367225361694720 * α ^ 44 - 5173168623120670073594814754124350179396943872 * α ^ 45 - 46665067131765629087874046716431817185624064 * α ^ 46 - 363947916336732295692730495412120808062976 * α ^ 47 - 2448922340507063244670480160751278358528 * α ^ 48 - 14156403192874033788431089246006149120 * α ^ 49 - 69840635580766128998624519726825472 * α ^ 50 - 291304208587694376741876403273728 * α ^ 51 - 1013847100270960749479253245952 * α ^ 52 - 2890985222950997734006456320 * α ^ 53 - 6580251459272551201505280 * α ^ 54 - 11498869995682148646912 * α ^ 55 - 14487778418579472384 * α ^ 56 - 11716883921240064 * α ^ 57 - 4568503025664 * α ^ 58) / (34956176830804188618864971427671197206330339979080770327319313608079680 * (3 + α) ^ 29) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B60_63 diff --git a/Sendov/FiniteRange/Degree64_69.lean b/Sendov/FiniteRange/Degree64_69.lean index cad1743..1dbcc86 100644 --- a/Sendov/FiniteRange/Degree64_69.lean +++ b/Sendov/FiniteRange/Degree64_69.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 64 to 69 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 62 * (5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 + 61381176382803809362111499051840544591370805103230496041366966719316985769735186577074210428 * α + 307875927191106748261011216414410411442655519490352054541897661765849218694794523337461209647 * α ^ 2 + 995139520442941110972922094595461359252165093278183682740950849972307343163433414772266439134 * α ^ 3 + 2329135965026413320254515390788191269701711986947806984107173389521959680472053301869564187977 * α ^ 4 + 4205152400427897818943955614854872603184778207497298031576474014041708453522600564012661712908 * α ^ 5 + 6092227728539116602774802993811227514150357030998079498007336022099744281828374410394763218967 * α ^ 6 + 7273914911154976681674028920562209810638892503140251984517953529760649706898772999266377410618 * α ^ 7 + 7294841936549908246762850463172756077551550164308271524011607481986853316219925718877268241253 * α ^ 8 + 6231636865479569934304365225476315224178754021865462499626075023963516933948459908031199504392 * α ^ 9 + 4582454355475931479184872096047779444629884546826401854025935798959693699768306789254756052107 * α ^ 10 + 2923936751602144899711097457334391073444202579871680510494335159924208835914470439635141162662 * α ^ 11 + 1628646305582237968027987059869036927850582412822128278929774316093217652148166106137543210729 * α ^ 12 + 795445013477937519140644933077682364729772242866058887702125127747950219835128702530435684436 * α ^ 13 + 341732386485246488082914550033328759932103344872452353652503157863279852435899383534716977739 * α ^ 14 + 129398024588904114703104106088147845845858920384624466782691337832071760366611282163240673066 * α ^ 15 + 43227083179690319937679095035602516318669269367605716008461368393810348604333859857847549497 * α ^ 16 + 12739734973954297734917244488839138405165723257781387930800239709000470619130237106664340656 * α ^ 17 + 3309003690560409027996242316235318569343087760556101911245828294749346009825368969657069031 * α ^ 18 + 755904091146328721648601114370911122594719522671458365690647375941659996310302273197058470 * α ^ 19 + 151378877572074703874732245694134372432105936678872727794384094115460812902730719423948317 * α ^ 20 + 26454923472459858634887234579799069438230123457614797089205636430511024677434784809220924 * α ^ 21 + 4009557348845189672922466111254379827931543987777056770742617262249980072703900044793759 * α ^ 22 + 522684797686516768766815870526767734538930901093141236380109988654434790535464480525226 * α ^ 23 + 57960196328928756537267261570029521956658673559059668642752896597993471772708261591453 * α ^ 24 + 5385398873189231308982589874195610465961820936268053590519181757629535422805253399024 * α ^ 25 + 410397478215636804806491132412571076795910317178146076050633000481647199256305822637 * α ^ 26 + 24812014519928905914570908638577043729393183935810050156873373621420956394826529722 * α ^ 27 + 1113510388782381458493062026644349844210314014993864209186922164992790354371374639 * α ^ 28 + 22409773065959463084902151065290205378008886892907135598840606673031087144995204 * α ^ 29 - 35763698158235183891226289780431937498580930947719484832564827737501564744289629 * α ^ 30 + 840760995622979288098811692316543958334461895228266842721825922823541893315826 * α ^ 31 - 2476024715094217195652794819915917218077074423531979390443969076889551332351 * α ^ 32 - 42343131706354479044867362267674031525737275327352243122650061208773859828 * α ^ 33 + 1121663574053726688315155444107301037632747178037371530068223719748652900 * α ^ 34 + 127119237016866360421264159870103175079883989461074891879168221493189568 * α ^ 35 + 5840998162333194724309799734276135965778520891167491660434664446065776 * α ^ 36 + 175992443424517154194105688439948495022759467456834921814514733630912 * α ^ 37 + 3457340410083421419722141826010375932802380080806011689658236008128 * α ^ 38 + 24387290416155856471527726331603437910487483092148051628143522304 * α ^ 39 - 1239885867289330313685948822187720768399781886302021720494414080 * α ^ 40 - 65142911505809786191440265839050522466645141325685819456216064 * α ^ 41 - 1919845972367683574507152058644769097612240398422850416591872 * α ^ 42 - 42690755951658679674359660598349223111852496540029559373824 * α ^ 43 - 774277941425789906408100254236527798872560249769923817472 * α ^ 44 - 11837447748695307877084872298248109006399402655405555712 * α ^ 45 - 155160542836944884945355229969272241433459624584396800 * α ^ 46 - 1760282021481048069096957321992926156742736627499008 * α ^ 47 - 17375591117616735181132725973057892264379050557440 * α ^ 48 - 149596040045196039764745879558857285877770747904 * α ^ 49 - 1123758519054636222507004226738421820190097408 * α ^ 50 - 7354587732063594511120345756955829080162304 * α ^ 51 - 41799839163275444256118641007392250134528 * α ^ 52 - 205261854328197847356177208926730715136 * α ^ 53 - 864576623781254196788511741560487936 * α ^ 54 - 3092645524632136056284929849294848 * α ^ 55 - 9268224902397535157105681498112 * α ^ 56 - 22840148173664707695687499776 * α ^ 57 - 45078822391172061959553024 * α ^ 58 - 68515609003558969540608 * α ^ 59 - 75294374818201206784 * α ^ 60 - 53251155240681472 * α ^ 61 - 18200997658624 * α ^ 62) = 5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 * (17 - α) ^ 62 + 1410592329453155093339211289542411736609735429121847896493629858906716014852004156892167552548 * α ^ 1 * (17 - α) ^ 61 + 163825348961034855748532998133187489244150138166953116803112907190951119777389438269950378047615 * α ^ 2 * (17 - α) ^ 60 + 12361195960575736306163012120329422246578502920843748763821862084625502483053715706760463722075322 * α ^ 3 * (17 - α) ^ 59 + 681335583687244816837155518706910028522515498128290805387946937709694218848663276792277722205885165 * α ^ 4 * (17 - α) ^ 58 + 29246467299582416554371726277124312659485967608331036186864901441962932711378452493174003728374440456 * α ^ 5 * (17 - α) ^ 57 + 1017843449098855324693227940286198056557561324301642345041220834540478580971172148752686938326750596235 * α ^ 6 * (17 - α) ^ 56 + 29523351481445963795800452678069515843407715524336444192954336309944099949871809204575864476533589605302 * α ^ 7 * (17 - α) ^ 55 + 728152422115299748757980286386613270210125867312784076185146979717429960990761502520944266554529234032105 * α ^ 8 * (17 - α) ^ 54 + 15503254854319433781737681560944871435301212863859242862611647178701987248949779238980829394743551131411876 * α ^ 9 * (17 - α) ^ 53 + 288328427720996697724483216206576565555295259358381796122313701494259650958770973285158322571941967268217143 * α ^ 10 * (17 - α) ^ 52 + 4728226481516661217868239930012852768555767163427788258399165321871029858334868657036824174585537128584095058 * α ^ 11 * (17 - α) ^ 51 + 68892078096367493868938707195995003059858819884647635693839050805569143627035213407543911684688112707333940917 * α ^ 12 * (17 - α) ^ 50 + 897489256219895957725717014821990251236531986784876454449072801996710996644666496224561803033929426140365957072 * α ^ 13 * (17 - α) ^ 49 + 10508734440253299052373528881880146721004546284790249412377062790386529187304727179044043353704708859442299500759 * α ^ 14 * (17 - α) ^ 48 + 111081473282973163902827719026653126099023149223026091072328009130583311867466584644887598351195354843454575061078 * α ^ 15 * (17 - α) ^ 47 + 1063941006387245192155551249879696393695003441753984944370011723535983307131499226741597118204956342316757068738269 * α ^ 16 * (17 - α) ^ 46 + 9262986013458072655807408147636790265923148648024710835072780996730402742732552216518640508409071199773338460467580 * α ^ 17 * (17 - α) ^ 45 + 73504432944628644806132381782654602892005780151536635377604343542798349874150577323370221243526662142861029485765267 * α ^ 18 * (17 - α) ^ 44 + 532852613339223838375512331827090700606511743950503229897754718887488029896868379807709267119939501223065295366693602 * α ^ 19 * (17 - α) ^ 43 + 3535814546782694307375152520118433313583952495849109269521484647041374707696487816679620238442969871612220462861303513 * α ^ 20 * (17 - α) ^ 42 + 21512685649336335238232172882299955129752294290179941353113200512198826289055015641521741143998370572855870359074246104 * α ^ 21 * (17 - α) ^ 41 + 120184751154982212109537129094706701776062091437923605319229141083097993817265572578568789467586467189277588039631049315 * α ^ 22 * (17 - α) ^ 40 + 617286849338083584591749927075053814330691243681016327221117622061037920401281200900095661642210214781389352540371769782 * α ^ 23 * (17 - α) ^ 39 + 2917821849269728689002023193436139836170048452644874266623784725971608066582467147212148057605900165316289226284189316377 * α ^ 24 * (17 - α) ^ 38 + 12704073587524590432537550601733909995628450893588885496540802041053069795718152620703039939205080151846264466052385716508 * α ^ 25 * (17 - α) ^ 37 + 50986252288170844090494680336411030634809274601549641047867345938670169429122180568151839986046629584836753070752554325549 * α ^ 26 * (17 - α) ^ 36 + 188731245384436542993876553440655528970657000032064943068315442235001403174655449380246936385673578684853218729590355262518 * α ^ 27 * (17 - α) ^ 35 + 644638862330020323974120509999798597971327969663585928073571369717884850872334505415491868174223509023103931648896623159239 * α ^ 28 * (17 - α) ^ 34 + 2032465294997125297900965524691015077382636066034389731503867693576128697782554799572131661348538947203921438149968717062968 * α ^ 29 * (17 - α) ^ 33 + 5916563574791151204959096743639378777667289023700421621098488569051297390955699005328526305783519890090961210344520200855839 * α ^ 30 * (17 - α) ^ 32 + 15904395842739942400691632117874198526447327814312513603909114134462651263485542388901837738413027124647322988507344907172326 * α ^ 31 * (17 - α) ^ 31 + 39480621688975930462788359812689019736710921053310451812820878220682147479485730376139224433028788139612764026510819938357313 * α ^ 32 * (17 - α) ^ 30 + 90498905447243483519998876972476498394113495417286506436759680590889186513026023767081117347518009234654646481535950533463192 * α ^ 33 * (17 - α) ^ 29 + 191523061794373512741555851851454724489150681013895009425168301404571522764467282969120404401773322532157478133115443560285302 * α ^ 34 * (17 - α) ^ 28 + 374102432352617119867752270588761366904228295175272818014486180253881707053636572216880029501969121629062410575837741541045540 * α ^ 35 * (17 - α) ^ 27 + 674163867855629078514194069974085158409299328199490452497247676315473162081360642182363547674290072742445351524110985068872354 * α ^ 36 * (17 - α) ^ 26 + 1120190445035094331280254183489294295074052698129528674820873994885643430165035917680757332898500267079209483615084452103804008 * α ^ 37 * (17 - α) ^ 25 + 1714900723005197968608097741871663993547860800425642883240541486610428452579319183757683479188744534283136109042046984240571814 * α ^ 38 * (17 - α) ^ 24 + 2416521455885624032995813409015090294329753742015754392681809119734841244318096451186191210367408907919148396327456308763254204 * α ^ 39 * (17 - α) ^ 23 + 3130667990811173505654112986656672677984543765718045066563298172181269932987292074370043542684045671485290799340932412432127666 * α ^ 40 * (17 - α) ^ 22 + 3723632079113581550914531608562041601402119257773277980450525464260286884296416621721582409231033706311054972465336219853088080 * α ^ 41 * (17 - α) ^ 21 + 4059377708897210330188497275486334922259944254887440167982165880025056118561927845076658189142750307922329495731330184747118638 * α ^ 42 * (17 - α) ^ 20 + 4048339098511651153484403478604219407237868497167064020335159037949103178704020226621821552775015074419425081166608975426397828 * α ^ 43 * (17 - α) ^ 19 + 3685125185916007961192554820161330975941990328916335627053257624724395938552675772827896673200200979526558921356874703197634202 * α ^ 44 * (17 - α) ^ 18 + 3054048224733814016209061368888708478509554580679361743439116448337817549920283187451853860165586457447146488334169873043392888 * α ^ 45 * (17 - α) ^ 17 + 2297607116406960807358259781678168246891645615834759456321137666589029442664420364955901391909484370982081566881227744010874086 * α ^ 46 * (17 - α) ^ 16 + 1563834963456883771498309022248496753805125281048581681606795606079693488022698265201311315270316165083707358234478370753591340 * α ^ 47 * (17 - α) ^ 15 + 959258589419178016234935333453270943911310250588295913774272713867179363938066640752243714741723229316103934660921840058331018 * α ^ 48 * (17 - α) ^ 14 + 527900112010660650248359261223300285284919503338654858382838983941810697808740176247054336097235620277146518114081044914641704 * α ^ 49 * (17 - α) ^ 13 + 259264801192497118934660971527450137059592143267324741721675524446679377229923273369087143487942107768190580548411748863625788 * α ^ 50 * (17 - α) ^ 12 + 112925257755528735753324539726634534462874074768785640447769616735919582936276633211358842716251496812674695066733945373630376 * α ^ 51 * (17 - α) ^ 11 + 43294208295108225572313363454714123552240387039341439399675327329984812526400837615036809250708210257269984868804715221768900 * α ^ 52 * (17 - α) ^ 10 + 14477109131118555980678814863672526273272305897056735808931397755854119363286698878099100454732834934400199349504635868575272 * α ^ 53 * (17 - α) ^ 9 + 4174569243543245209284931467152030006445783333411091743019898951807503568926775515227295551582461714654886147011664393698640 * α ^ 54 * (17 - α) ^ 8 + 1023195555636300366841604521638282501064465993225005460684172679015270094224232028670477159664015610240056559067645353077104 * α ^ 55 * (17 - α) ^ 7 + 209198594431248589503412319008039641002648327066847874065351685585470814434000466355080564735310580499259736416826148144344 * α ^ 56 * (17 - α) ^ 6 + 34783976201620581654146479854021503178010426501131959915156711925834764330476282903763164286902924648174181467158619488528 * α ^ 57 * (17 - α) ^ 5 + 4537117170708547774244512797745793493972596799818372048598224751094284949822133549967909771513344000829119085557004800874 * α ^ 58 * (17 - α) ^ 4 + 439587616858133764615021615831943232239201592269473877183402700593166522993563786139416926646861354484165239718064288908 * α ^ 59 * (17 - α) ^ 3 + 28864689907498275516712488927232990145839965615854349188000067895024636971944883064300818736721726097224141170690557182 * α ^ 60 * (17 - α) ^ 2 + 1070072225555048253521045141065543739116562978962155304409124790881546160712961916037048669936728578132382704101086352 * α ^ 61 * (17 - α) ^ 1 + 13265174660695058386402183278677678416743473633987916452549678002795064626597224750728225831441096471610791877259904 * α ^ 62 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 62)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 64 ≤ n) (h1 : n ≤ 69) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 + 61381176382803809362111499051840544591370805103230496041366966719316985769735186577074210428 * α + 307875927191106748261011216414410411442655519490352054541897661765849218694794523337461209647 * α ^ 2 + 995139520442941110972922094595461359252165093278183682740950849972307343163433414772266439134 * α ^ 3 + 2329135965026413320254515390788191269701711986947806984107173389521959680472053301869564187977 * α ^ 4 + 4205152400427897818943955614854872603184778207497298031576474014041708453522600564012661712908 * α ^ 5 + 6092227728539116602774802993811227514150357030998079498007336022099744281828374410394763218967 * α ^ 6 + 7273914911154976681674028920562209810638892503140251984517953529760649706898772999266377410618 * α ^ 7 + 7294841936549908246762850463172756077551550164308271524011607481986853316219925718877268241253 * α ^ 8 + 6231636865479569934304365225476315224178754021865462499626075023963516933948459908031199504392 * α ^ 9 + 4582454355475931479184872096047779444629884546826401854025935798959693699768306789254756052107 * α ^ 10 + 2923936751602144899711097457334391073444202579871680510494335159924208835914470439635141162662 * α ^ 11 + 1628646305582237968027987059869036927850582412822128278929774316093217652148166106137543210729 * α ^ 12 + 795445013477937519140644933077682364729772242866058887702125127747950219835128702530435684436 * α ^ 13 + 341732386485246488082914550033328759932103344872452353652503157863279852435899383534716977739 * α ^ 14 + 129398024588904114703104106088147845845858920384624466782691337832071760366611282163240673066 * α ^ 15 + 43227083179690319937679095035602516318669269367605716008461368393810348604333859857847549497 * α ^ 16 + 12739734973954297734917244488839138405165723257781387930800239709000470619130237106664340656 * α ^ 17 + 3309003690560409027996242316235318569343087760556101911245828294749346009825368969657069031 * α ^ 18 + 755904091146328721648601114370911122594719522671458365690647375941659996310302273197058470 * α ^ 19 + 151378877572074703874732245694134372432105936678872727794384094115460812902730719423948317 * α ^ 20 + 26454923472459858634887234579799069438230123457614797089205636430511024677434784809220924 * α ^ 21 + 4009557348845189672922466111254379827931543987777056770742617262249980072703900044793759 * α ^ 22 + 522684797686516768766815870526767734538930901093141236380109988654434790535464480525226 * α ^ 23 + 57960196328928756537267261570029521956658673559059668642752896597993471772708261591453 * α ^ 24 + 5385398873189231308982589874195610465961820936268053590519181757629535422805253399024 * α ^ 25 + 410397478215636804806491132412571076795910317178146076050633000481647199256305822637 * α ^ 26 + 24812014519928905914570908638577043729393183935810050156873373621420956394826529722 * α ^ 27 + 1113510388782381458493062026644349844210314014993864209186922164992790354371374639 * α ^ 28 + 22409773065959463084902151065290205378008886892907135598840606673031087144995204 * α ^ 29 - 35763698158235183891226289780431937498580930947719484832564827737501564744289629 * α ^ 30 + 840760995622979288098811692316543958334461895228266842721825922823541893315826 * α ^ 31 - 2476024715094217195652794819915917218077074423531979390443969076889551332351 * α ^ 32 - 42343131706354479044867362267674031525737275327352243122650061208773859828 * α ^ 33 + 1121663574053726688315155444107301037632747178037371530068223719748652900 * α ^ 34 + 127119237016866360421264159870103175079883989461074891879168221493189568 * α ^ 35 + 5840998162333194724309799734276135965778520891167491660434664446065776 * α ^ 36 + 175992443424517154194105688439948495022759467456834921814514733630912 * α ^ 37 + 3457340410083421419722141826010375932802380080806011689658236008128 * α ^ 38 + 24387290416155856471527726331603437910487483092148051628143522304 * α ^ 39 - 1239885867289330313685948822187720768399781886302021720494414080 * α ^ 40 - 65142911505809786191440265839050522466645141325685819456216064 * α ^ 41 - 1919845972367683574507152058644769097612240398422850416591872 * α ^ 42 - 42690755951658679674359660598349223111852496540029559373824 * α ^ 43 - 774277941425789906408100254236527798872560249769923817472 * α ^ 44 - 11837447748695307877084872298248109006399402655405555712 * α ^ 45 - 155160542836944884945355229969272241433459624584396800 * α ^ 46 - 1760282021481048069096957321992926156742736627499008 * α ^ 47 - 17375591117616735181132725973057892264379050557440 * α ^ 48 - 149596040045196039764745879558857285877770747904 * α ^ 49 - 1123758519054636222507004226738421820190097408 * α ^ 50 - 7354587732063594511120345756955829080162304 * α ^ 51 - 41799839163275444256118641007392250134528 * α ^ 52 - 205261854328197847356177208926730715136 * α ^ 53 - 864576623781254196788511741560487936 * α ^ 54 - 3092645524632136056284929849294848 * α ^ 55 - 9268224902397535157105681498112 * α ^ 56 - 22840148173664707695687499776 * α ^ 57 - 45078822391172061959553024 * α ^ 58 - 68515609003558969540608 * α ^ 59 - 75294374818201206784 * α ^ 60 - 53251155240681472 * α ^ 61 - 18200997658624 * α ^ 62) / (13124052596236045911528558813876389304261669684415149295591106226549152703744 * (3 + α) ^ 31) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B64_69 diff --git a/Sendov/FiniteRange/Degree6_6.lean b/Sendov/FiniteRange/Degree6_6.lean index 1194600..7bafa2d 100644 --- a/Sendov/FiniteRange/Degree6_6.lean +++ b/Sendov/FiniteRange/Degree6_6.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 6 to 6 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 5 / 2) : have hu : (0 : ℝ) ≤ 5 - 2 * α := by linarith have hid : (5 : ℝ) ^ 4 * (1575 - 900 * α + 2345 * α ^ 2 - 342 * α ^ 3 - 24 * α ^ 4) = 1575 * (5 - 2 * α) ^ 4 + 8100 * α ^ 1 * (5 - 2 * α) ^ 3 + 69425 * α ^ 2 * (5 - 2 * α) ^ 2 + 188150 * α ^ 3 * (5 - 2 * α) ^ 1 + 123200 * α ^ 4 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (5 : ℝ) ^ 4)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 5 - 2 * α := by linarith - positivity + bernstein_cert α (5 - 2 * α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 6 ≤ n) (h1 : n ≤ 6) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (1575 - 900 * α + 2345 * α ^ 2 - 342 * α ^ 3 - 24 * α ^ 4) / (375 * (3 + α) ^ 2) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B6_6 diff --git a/Sendov/FiniteRange/Degree7.lean b/Sendov/FiniteRange/Degree7.lean index d9d6805..38f5e9d 100644 --- a/Sendov/FiniteRange/Degree7.lean +++ b/Sendov/FiniteRange/Degree7.lean @@ -101,12 +101,10 @@ theorem finite_range_seven (hα : 0 ≤ α) (hfeas : c 7 α ^ 2 ≤ A 7 α) : R rw [hid] at hR have hP : 0 < -5 * α ^ 6 - 222 * α ^ 5 - 2619 * α ^ 4 + 17388 * α ^ 3 + 19413 * α ^ 2 - 5022 * α + 33291 := by - nlinarith [mul_nonneg (pow_nonneg hα 3) (sub_nonneg.2 hle), + nlinarith only [hα, pow_nonneg hα 3, mul_nonneg (pow_nonneg hα 3) (sub_nonneg.2 hle), mul_nonneg (pow_nonneg hα 4) (sub_nonneg.2 hle), mul_nonneg (pow_nonneg hα 5) (sub_nonneg.2 hle), sq_nonneg (19413 * α - 2511)] - have : 0 < (-5 * α ^ 6 - 222 * α ^ 5 - 2619 * α ^ 4 + 17388 * α ^ 3 + 19413 * α ^ 2 - - 5022 * α + 33291) / (2592 * (3 + α) ^ 3) := div_pos hP (by positivity) - linarith + exact hR.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end Sendov diff --git a/Sendov/FiniteRange/Degree70_79.lean b/Sendov/FiniteRange/Degree70_79.lean index c57f23e..906180f 100644 --- a/Sendov/FiniteRange/Degree70_79.lean +++ b/Sendov/FiniteRange/Degree70_79.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 70 to 79 @@ -90,14 +91,9 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 68 * (4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 + 55048255682073709607204036059519252499577954075805344228144067353398773939360654388786551620754044174 * α + 303631470940991973002262259034385880105972184753330155102383400602879297569999672180560254047614733064 * α ^ 2 + 1082629940665673044764709543433093878486364849040990099597525143450118708087349123259727336344728664544 * α ^ 3 + 2804599610843097204574458002687246299093134788634086599591559738125527989079685417982892820063924460373 * α ^ 4 + 5624645401139815516982667151087561797773568501921017826805664176655117168979590819326893993434748481137 * α ^ 5 + 9086529173583154645809008602511982564716590500042635425568606924621639922909196505882243392404835758015 * α ^ 6 + 12147764349688852841301807848655896145357577978996235836231868297037709466427619171816150975300099741791 * α ^ 7 + 13702180594674637952993181456614636961007303430300258709825461099491823680923881039132440258291527607905 * α ^ 8 + 13228790758953813166525229226864556895698491358332563699351209388421354345605839944544173983846341165317 * α ^ 9 + 11051940590803482762640027098441612629424377433949792947689615004158487742382763237735051674050718363307 * α ^ 10 + 8057730499045200268719730173861520782106924341107579339386385608691893710110000816392557161453112592131 * α ^ 11 + 5160484214825899033659577721795935067593212006301594642310233538545527417677809202356341306165128799909 * α ^ 12 + 2917926196608374844731210581375035036343917943893823360466936440450011366221495240241631678212028102353 * α ^ 13 + 1462315101539635752571716649246230545438507378471968670138935884045737693317302923326515165319274353863 * α ^ 14 + 651362758608261532683053553948901251603409142895470962454343186012266250060431761761109117155529185351 * α ^ 15 + 258382911131744978730219354901244362207736065992848531597126642760778004801626888171716412430540285505 * α ^ 16 + 91380564667115290929103952618176877475251392601510902630099986346625474504164568221576682912080867653 * α ^ 17 + 28823701484229764785510610641119924329640879766929838579606063832811514346965585992079347095184066891 * α ^ 18 + 8105512742405337827384222403832648005310429131045055117867656987105207137736030417145103472632533011 * α ^ 19 + 2029737755516453702412381601616827618446965035012177295868811221050918334739516968406653005043323145 * α ^ 20 + 451715825606281157427809648282481163078916909506829474305720867391455366362160566615805697668034469 * α ^ 21 + 89083872539236033065296789508746088826183108150642030163709620396857932007741467883529598127701027 * α ^ 22 + 15507062046600275350060333043623953591886937497826357117111310333499555606548238470938828041232307 * α ^ 23 + 2370291817598182097124474831710334939044419386117776585894929734754031639676722325611554692802929 * α ^ 24 + 315999149372391878452912834168990330419105934995500914232394089420371940254905369886539160346853 * α ^ 25 + 36423009146013699028116153780709317964569427476167451734283550363318237494233399180783337169695 * α ^ 26 + 3588163263018483116273779737008794180190405472634090416966530935626554841121047871569879767559 * α ^ 27 + 297471336921909919923207632811348664497121895483393172379791904969696166207311294171026521523 * α ^ 28 + 20305725467845794109711961738383951154160346509672805134214469944833591189715035234346686183 * α ^ 29 + 1103609488904163566431208273520751297004151033048526881874218221163688540301268998957942157 * α ^ 30 + 44705334211106925450419755417917993038028222392715074881553657780646344635657758883181805 * α ^ 31 + 805515192221430510609334948188870016650885857492958289044650012247928862875245764497551 * α ^ 32 - 1482048260833901649795245609960707851397885375498496335550472054736679501095164961700205 * α ^ 33 + 28550595118000674813695237772389123615483889198973830073821326304976753853122397016687 * α ^ 34 - 110293125322577848844861697626305509333317224753061067523753150512274273997930489889 * α ^ 35 - 2944264371932464496615000679541333014546134952187144901035323438838119921163626816 * α ^ 36 - 42753460721496719482279714802299033215763752656049106329252818812714655687701920 * α ^ 37 + 892039301043622007789612879017665871347081871863607139597567473234375585298160 * α ^ 38 + 90290182213750286064408757160215991459134539105309106871418780497371434069600 * α ^ 39 + 3686520145576645994835054065141215370192750469525569878892121423026501980224 * α ^ 40 + 101266458446089775184406440743070690042012917626596066692722657223969408256 * α ^ 41 + 1921165999972257449345542825175329806471062302564814176599267497713370880 * α ^ 42 + 18910079844664677393253742829163990204177395135122636437886747825783808 * α ^ 43 - 267203790007683385371238236401248869931744610843957702759988424811520 * α ^ 44 - 18630321688593096100250955298980358254132585106002718798371125157888 * α ^ 45 - 549431692437424587483251682306834452811394511706522157550126837760 * α ^ 46 - 11827470008686810839474011121751705014739559837533303829463834624 * α ^ 47 - 206601161707202641093681870196336457333557666704999087205793792 * α ^ 48 - 3050100062225303864539589793145445854252294435418792706244608 * α ^ 49 - 38831214153718995312467487136862135070778219830730009018368 * α ^ 50 - 431130925861351878296650698743841679980168113965805076480 * α ^ 51 - 4201734530680545401568837521217272752627836979325435904 * α ^ 52 - 36075335848543051909606823878062380154340083870203904 * α ^ 53 - 273302433216495374400156548854470569604061187801088 * α ^ 54 - 1826924843542958932998763336695299600883344474112 * α ^ 55 - 10760219439515367849051421269035765266542231552 * α ^ 56 - 55683568301576061216924181665153394893914112 * α ^ 57 - 252108560765968990302771636780305076977664 * α ^ 58 - 992726472130728702576289249214808981504 * α ^ 59 - 3372896548691756253399508431270838272 * α ^ 60 - 9784355714995137510417248525746176 * α ^ 61 - 23895590924284630456363042996224 * α ^ 62 - 48203390780462373975323836416 * α ^ 63 - 78197438735478405231280128 * α ^ 64 - 98061705121359087009792 * α ^ 65 - 89226089066196369408 * α ^ 66 - 52420526819246080 * α ^ 67 - 14929306320896 * α ^ 68) = 4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 * (17 - α) ^ 68 + 1265157032653140923172696358781045157064900401217905487833243537047108668589294636491165982694547047750 * α ^ 1 * (17 - α) ^ 67 + 161482237306767878745241819415998746410809769680683392204930507623070859153937168257049914988047412112214 * α ^ 2 * (17 - α) ^ 66 + 13422247499165700437689764267709730212036079924252530397947436539414938500806129414515249428924591360471250 * α ^ 3 * (17 - α) ^ 65 + 816972781682827686607611010623394023676328688115620152082292022403046953548356768129403300216449427112754113 * α ^ 4 * (17 - α) ^ 64 + 38824370988158138726941311700115756071290366487538089829867353036362853363011105712229404919753034517698319713 * α ^ 5 * (17 - α) ^ 63 + 1499833600292598822014341704041896176361474668441008024749667474678088913996818119654158697311930608272571456030 * α ^ 6 * (17 - α) ^ 62 + 48422932809787295787390564041245327912518154539781119501099341947995210984379450371937423256131589899210941134514 * α ^ 7 * (17 - α) ^ 61 + 1333124974240927854482159425251402107245186286978279403787625094573367841803246952758768754029487309692347318336240 * α ^ 8 * (17 - α) ^ 60 + 31777797124891464951721548329322036172531399956667440482696617718123564246691425958497694319690617969140927686684080 * α ^ 9 * (17 - α) ^ 59 + 663714337585641075862710458977346289450664855026176138573830637339763833070986663739178423777505821459460189852947968 * α ^ 10 * (17 - α) ^ 58 + 12262485846674184769453169937509946039571704829287751556559418951991378092254593946982159731229796032255503955934621616 * α ^ 11 * (17 - α) ^ 57 + 201969028018565162730161510400745329670143714141289296191558060115320430534002168054679415522116383859539020895554723776 * α ^ 12 * (17 - α) ^ 56 + 2984596421743417793782332651870684512173959536289036391110144204303743763821125710106900081031600434022380226544823660080 * α ^ 13 * (17 - α) ^ 55 + 39784321437763110285727312524497427978490644060968737608182005051306614478428882059166898040103949867844194968529236966504 * α ^ 14 * (17 - α) ^ 54 + 480543938548422612890741989991526270246304382173993722693724388642176377466756024411416886199383755538111290823987013369160 * α ^ 15 * (17 - α) ^ 53 + 5279901417754954883742431587978703767626877114504290728644469223047973916917301789839124306590322937367972095259516102221832 * α ^ 16 * (17 - α) ^ 52 + 52945203354166745644230222209580146500462821416245712770967147511123795041025063164899837137984308325228112243872402797720184 * α ^ 17 * (17 - α) ^ 51 + 485928342569266463087021622036455747024462941842401506731286158733175889455343816199003845608430478859161164238309759380850320 * α ^ 18 * (17 - α) ^ 50 + 4091958406668774678507241930361086964473233452855436917980174792821511603462125609865012423204529448494332739565952940847535008 * α ^ 19 * (17 - α) ^ 49 + 31683212460188578387342804176945072229413086255880741845271045566233563281959233289534062862735569422810201289901710942585691872 * α ^ 20 * (17 - α) ^ 48 + 225979630689303507786898260664009071625270094449716362704636848456295027690433997904251442068696550669529118551488817387880290256 * α ^ 21 * (17 - α) ^ 47 + 1487128617430673014516169749515363875219566281808091046150030684893815735850131065805579647668091571852789526355428971538991078216 * α ^ 22 * (17 - α) ^ 46 + 9042148580683115945632798662691502266143017079630193956758831416930496458610190341296994016055070448189744269126207258222640342120 * α ^ 23 * (17 - α) ^ 45 + 50858358010848454557731664420671103160817707432587833055365526944577128658034548080461931999630601918157623952028511496302491645436 * α ^ 24 * (17 - α) ^ 44 + 264894421723415244260430513144029948945395618262574763973851002784217525442701126127347374644597622077075226262022822088501696204428 * α ^ 25 * (17 - α) ^ 43 + 1278767873696353424101636053219073837545595922525849403166724782352583013823834674590289275813557084219485073578825413587799211967436 * α ^ 26 * (17 - α) ^ 42 + 5725993526407220170131735130796235929803474480006433589234997891028171711914835354674252789493105774845667439300549950141552174204148 * α ^ 27 * (17 - α) ^ 41 + 23797472948050627920664370923139924765880312522674540655463364156321698714682589900985886207317662923270995738996512039485735022862410 * α ^ 28 * (17 - α) ^ 40 + 91847188399449607906860584187806753120315922783214799014025827204769651430206806052585878934846199020273478297324347000279002931574522 * α ^ 29 * (17 - α) ^ 39 + 329342373949609101951511940154131075827972185993638085640480145831458749736060460017623365544223280262966286218021296303864864015746416 * α ^ 30 * (17 - α) ^ 38 + 1097560558892751992700895204428590904051076121281041797677676037125864755311439126982165925162500305191774580034834400855567800165723472 * α ^ 31 * (17 - α) ^ 37 + 3400354684972857879605435169696913406951341446392821917656396040731072702340906869893233782691459204642830241785914469379158439677051796 * α ^ 32 * (17 - α) ^ 36 + 9795255185712404229440153808939878082728601957977592077724575912171144463816508150030377679174644938546737146393361620285646830422256420 * α ^ 33 * (17 - α) ^ 35 + 26239203554755141459745089973391959355052889674186027464718372088695695988893799042814172271546870765144481886268457658334065389516464974 * α ^ 34 * (17 - α) ^ 34 + 65364772208973664575034750355459656935183422873874505526092428372633233840636570937545030505946122798332726471550017157961822599578476434 * α ^ 35 * (17 - α) ^ 33 + 151417890873929453489601556690033520410995454719040770050368045093177324038829603093684868348571248298437596387498225961228162231792553093 * α ^ 36 * (17 - α) ^ 32 + 326136561459197293128988773328742282995557141736905381102626192805005586172364773727221188473432861214419687642701273642338530960261384661 * α ^ 37 * (17 - α) ^ 31 + 653015723122962185079373689805649153519043802243690625985998409467892401539972839267641852663543640591936858448032520844893189758926012070 * α ^ 38 * (17 - α) ^ 30 + 1215133738838743206101520047205100561581201889449447221306287657871682157019672294661855343053509410150028759117930302323754459334908148634 * α ^ 39 * (17 - α) ^ 29 + 2100547367169647162309522500534430225020946624321317667617084318982110113730770172930764538999209173828708805485472118278853696220026559040 * α ^ 40 * (17 - α) ^ 28 + 3371572226105498605533309421720928970740445870449689033321124541953074173720243492689723243231990142125903392944525071646763046153799712752 * α ^ 41 * (17 - α) ^ 27 + 5021731712866329267615629279744145209979569686428333572284923100300160062927127615408116117696235006051137970230291268323176361338022571184 * α ^ 42 * (17 - α) ^ 26 + 6935282526605279700851082376753425399984816075966925438156290984812989264949621990948332423313032156685195715186548440728089466656780320080 * α ^ 43 * (17 - α) ^ 25 + 8872887599583942844730285240702268137994535894273818319558203225690794212214876544716058828209821312295910996151845255442057724010075373248 * α ^ 44 * (17 - α) ^ 24 + 10504640550563806719417324418003161655867163727170635219980235187136023481938024960895708709168710341339951422197356602510535614885945508256 * α ^ 45 * (17 - α) ^ 23 + 11493574135707887540289576369636114410520335535521279072065981221823553796516692389915466887949431055195475567153283570135491233527632506928 * α ^ 46 * (17 - α) ^ 22 + 11604808627242697256579914136813566676833914505736299110704677968571962615410435000953138171276194970496716595805082770429385722453886399056 * α ^ 47 * (17 - α) ^ 21 + 10793967840695396334802012163192802178890797549077696640851371801953999538826236827198386902657587341524929692133771331237779053672003790160 * α ^ 48 * (17 - α) ^ 20 + 9230499922489526427651509591753374367209146684551244899464268618430259566127381498045470358588046512126019036255090586145820433029559234480 * α ^ 49 * (17 - α) ^ 19 + 7240815654095776003678341965368139318124068790043794347929887962009532007602522612129159417690713015083966661427793715858516996767469271084 * α ^ 50 * (17 - α) ^ 18 + 5196910721982371088216812572801559409316958643069477659778573971072818964949630354690214200347540577616724298122257242598606667131480040052 * α ^ 51 * (17 - α) ^ 17 + 3402631899636205416266590253352818738890126853621420549170291181525659701590036840082549061908694049445145596493472438472698439652700425890 * α ^ 52 * (17 - α) ^ 16 + 2025465883034696535913461632694517262359063545972119023350389907385898500473981148635068061077366719947869607252392209033800465429303336450 * α ^ 53 * (17 - α) ^ 15 + 1091892060376371705496056687719844206882169207141786444740932042075723042341165731755946837934817210431949903331903986496675369334494701764 * α ^ 54 * (17 - α) ^ 14 + 530656327268367909969479070273109187787062122866155559515976559252491925394512132156718870616555877823790538113874300155722493907068691260 * α ^ 55 * (17 - α) ^ 13 + 231274284789425659234396174824508586685686100786488695662129653371227054848548241907361605558199603413655338792402925999207216602489857076 * α ^ 56 * (17 - α) ^ 12 + 89827076778691705270449318543458115575152231899967166072570553309114042367109650873526097636925926390123634607634695515051611658499946996 * α ^ 57 * (17 - α) ^ 11 + 30860904487494092370763766510390952712726910195346707673456930961614703228983522639588565939176152364301734964159970624603354686308829140 * α ^ 58 * (17 - α) ^ 10 + 9293886338970220832863344149731277643249660026631312547931533444041183229427806614161759486641998156855793362317993688595988612988379260 * α ^ 59 * (17 - α) ^ 9 + 2426161101634452818983962562364451171736421102519269820482811118536093138975233934291550597521985218265397595876703167336388333325163886 * α ^ 60 * (17 - α) ^ 8 + 541326371175450174067359875320150061071720972908442799245727828526206560614239255074965243639722409936039557063502412543527181027654830 * α ^ 61 * (17 - α) ^ 7 + 101368480597397327160028924375975580286493435206169413993404105377621448331740368126390317293582211745281779073436064732857223060861736 * α ^ 62 * (17 - α) ^ 6 + 15547562252184505730936231501759499165264416461623728410208958056020346369720300266147477570730217995958466276171125428082524576695080 * α ^ 63 * (17 - α) ^ 5 + 1887656008153650149223340824201972880431295033490416452460837788376128006557577215350851966367675841189217496088025419715076251556542 * α ^ 64 * (17 - α) ^ 4 + 172441329568599584346229934517512403814851421579063304992333529980418530837648814241006023742701428622424347746365799682216705162958 * α ^ 65 * (17 - α) ^ 3 + 10912136951540694390745084178080768035297012709958710219152508683320236507590661219843460673650554961847278661895402354571440431696 * α ^ 66 * (17 - α) ^ 2 + 409247002638066659293933857623421051407334490908373427758260767055975950442905835798620454491056045234820861455361280121831050520 * α ^ 67 * (17 - α) ^ 1 + 6145809855889991363427473372969457107085687932679016036884496519288814567653275417252009402531892559405828541206858545507410560 * α ^ 68 := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 68)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 70 ≤ n) (h1 : n ≤ 79) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 + 55048255682073709607204036059519252499577954075805344228144067353398773939360654388786551620754044174 * α + 303631470940991973002262259034385880105972184753330155102383400602879297569999672180560254047614733064 * α ^ 2 + 1082629940665673044764709543433093878486364849040990099597525143450118708087349123259727336344728664544 * α ^ 3 + 2804599610843097204574458002687246299093134788634086599591559738125527989079685417982892820063924460373 * α ^ 4 + 5624645401139815516982667151087561797773568501921017826805664176655117168979590819326893993434748481137 * α ^ 5 + 9086529173583154645809008602511982564716590500042635425568606924621639922909196505882243392404835758015 * α ^ 6 + 12147764349688852841301807848655896145357577978996235836231868297037709466427619171816150975300099741791 * α ^ 7 + 13702180594674637952993181456614636961007303430300258709825461099491823680923881039132440258291527607905 * α ^ 8 + 13228790758953813166525229226864556895698491358332563699351209388421354345605839944544173983846341165317 * α ^ 9 + 11051940590803482762640027098441612629424377433949792947689615004158487742382763237735051674050718363307 * α ^ 10 + 8057730499045200268719730173861520782106924341107579339386385608691893710110000816392557161453112592131 * α ^ 11 + 5160484214825899033659577721795935067593212006301594642310233538545527417677809202356341306165128799909 * α ^ 12 + 2917926196608374844731210581375035036343917943893823360466936440450011366221495240241631678212028102353 * α ^ 13 + 1462315101539635752571716649246230545438507378471968670138935884045737693317302923326515165319274353863 * α ^ 14 + 651362758608261532683053553948901251603409142895470962454343186012266250060431761761109117155529185351 * α ^ 15 + 258382911131744978730219354901244362207736065992848531597126642760778004801626888171716412430540285505 * α ^ 16 + 91380564667115290929103952618176877475251392601510902630099986346625474504164568221576682912080867653 * α ^ 17 + 28823701484229764785510610641119924329640879766929838579606063832811514346965585992079347095184066891 * α ^ 18 + 8105512742405337827384222403832648005310429131045055117867656987105207137736030417145103472632533011 * α ^ 19 + 2029737755516453702412381601616827618446965035012177295868811221050918334739516968406653005043323145 * α ^ 20 + 451715825606281157427809648282481163078916909506829474305720867391455366362160566615805697668034469 * α ^ 21 + 89083872539236033065296789508746088826183108150642030163709620396857932007741467883529598127701027 * α ^ 22 + 15507062046600275350060333043623953591886937497826357117111310333499555606548238470938828041232307 * α ^ 23 + 2370291817598182097124474831710334939044419386117776585894929734754031639676722325611554692802929 * α ^ 24 + 315999149372391878452912834168990330419105934995500914232394089420371940254905369886539160346853 * α ^ 25 + 36423009146013699028116153780709317964569427476167451734283550363318237494233399180783337169695 * α ^ 26 + 3588163263018483116273779737008794180190405472634090416966530935626554841121047871569879767559 * α ^ 27 + 297471336921909919923207632811348664497121895483393172379791904969696166207311294171026521523 * α ^ 28 + 20305725467845794109711961738383951154160346509672805134214469944833591189715035234346686183 * α ^ 29 + 1103609488904163566431208273520751297004151033048526881874218221163688540301268998957942157 * α ^ 30 + 44705334211106925450419755417917993038028222392715074881553657780646344635657758883181805 * α ^ 31 + 805515192221430510609334948188870016650885857492958289044650012247928862875245764497551 * α ^ 32 - 1482048260833901649795245609960707851397885375498496335550472054736679501095164961700205 * α ^ 33 + 28550595118000674813695237772389123615483889198973830073821326304976753853122397016687 * α ^ 34 - 110293125322577848844861697626305509333317224753061067523753150512274273997930489889 * α ^ 35 - 2944264371932464496615000679541333014546134952187144901035323438838119921163626816 * α ^ 36 - 42753460721496719482279714802299033215763752656049106329252818812714655687701920 * α ^ 37 + 892039301043622007789612879017665871347081871863607139597567473234375585298160 * α ^ 38 + 90290182213750286064408757160215991459134539105309106871418780497371434069600 * α ^ 39 + 3686520145576645994835054065141215370192750469525569878892121423026501980224 * α ^ 40 + 101266458446089775184406440743070690042012917626596066692722657223969408256 * α ^ 41 + 1921165999972257449345542825175329806471062302564814176599267497713370880 * α ^ 42 + 18910079844664677393253742829163990204177395135122636437886747825783808 * α ^ 43 - 267203790007683385371238236401248869931744610843957702759988424811520 * α ^ 44 - 18630321688593096100250955298980358254132585106002718798371125157888 * α ^ 45 - 549431692437424587483251682306834452811394511706522157550126837760 * α ^ 46 - 11827470008686810839474011121751705014739559837533303829463834624 * α ^ 47 - 206601161707202641093681870196336457333557666704999087205793792 * α ^ 48 - 3050100062225303864539589793145445854252294435418792706244608 * α ^ 49 - 38831214153718995312467487136862135070778219830730009018368 * α ^ 50 - 431130925861351878296650698743841679980168113965805076480 * α ^ 51 - 4201734530680545401568837521217272752627836979325435904 * α ^ 52 - 36075335848543051909606823878062380154340083870203904 * α ^ 53 - 273302433216495374400156548854470569604061187801088 * α ^ 54 - 1826924843542958932998763336695299600883344474112 * α ^ 55 - 10760219439515367849051421269035765266542231552 * α ^ 56 - 55683568301576061216924181665153394893914112 * α ^ 57 - 252108560765968990302771636780305076977664 * α ^ 58 - 992726472130728702576289249214808981504 * α ^ 59 - 3372896548691756253399508431270838272 * α ^ 60 - 9784355714995137510417248525746176 * α ^ 61 - 23895590924284630456363042996224 * α ^ 62 - 48203390780462373975323836416 * α ^ 63 - 78197438735478405231280128 * α ^ 64 - 98061705121359087009792 * α ^ 65 - 89226089066196369408 * α ^ 66 - 52420526819246080 * α ^ 67 - 14929306320896 * α ^ 68) / (397402644038401809557590389565008829884509406750026281207302771191507751602453558160 * (3 + α) ^ 34) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B70_79 diff --git a/Sendov/FiniteRange/Degree8.lean b/Sendov/FiniteRange/Degree8.lean index f307c55..18dd48e 100644 --- a/Sendov/FiniteRange/Degree8.lean +++ b/Sendov/FiniteRange/Degree8.lean @@ -78,12 +78,10 @@ theorem finite_range_eight (hα : 0 ≤ α) (hfeas : c 8 α ^ 2 ≤ A 8 α) : R rw [hid] at hR have hP : 0 < -240 * α ^ 6 - 7488 * α ^ 5 - 60624 * α ^ 4 + 747712 * α ^ 3 - 700161 * α ^ 2 + 882882 * α + 1102059 := by - nlinarith [mul_nonneg (pow_nonneg hα 5) (sub_nonneg.2 hle), + nlinarith only [hα, mul_nonneg (pow_nonneg hα 5) (sub_nonneg.2 hle), mul_nonneg (pow_nonneg hα 4) (sub_nonneg.2 hle), mul_nonneg (pow_nonneg hα 3) (sub_nonneg.2 hle), - mul_nonneg hα (sq_nonneg (867020 * α - 700161)), hα, sq_nonneg α] - have : 0 < (-240 * α ^ 6 - 7488 * α ^ 5 - 60624 * α ^ 4 + 747712 * α ^ 3 - 700161 * α ^ 2 - + 882882 * α + 1102059) / (72030 * (3 + α) ^ 3) := div_pos hP (by positivity) - linarith + mul_nonneg hα (sq_nonneg (867020 * α - 700161)), sq_nonneg α] + exact hR.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end Sendov diff --git a/Sendov/FiniteRange/Degree80_100.lean b/Sendov/FiniteRange/Degree80_100.lean index 24f652d..6324f96 100644 --- a/Sendov/FiniteRange/Degree80_100.lean +++ b/Sendov/FiniteRange/Degree80_100.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 80 to 100 @@ -92,12 +93,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : ring -- The Bernstein summands are nonnegative. If α > 0 the last one is positive; -- at α = 0 the first one is positive. No per-coefficient hypotheses are needed. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (17 : ℝ) ^ 78)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 17 - α := by linarith - positivity + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 80 ≤ n) (h1 : n ≤ 100) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (25811606424535915506326543401482443660479168162161070878750987845784640947537512918254143661443967851841624182260454 + 336370345330350208165234204307830830778265112065902973986047706784620119812179101529287799329664970700047233908530028 * α + 2135490323710205451177831007886434323850910269893926405766449302023972016567372609179660983528148958829173461437058426 * α ^ 2 + 8800193380808665214547458427848614541537421741398394617093689631071556593600442609061272206311515066984302690924269000 * α ^ 3 + 26462827687725576351409435396337556001601266481763435312645957683742611763538244106923991390112640216709155823432046446 * α ^ 4 + 61890317824100182817489513892770080906362674388551785381427868354803942587321704313688072997460165545388054174413205140 * α ^ 5 + 117172359697259929763030783557189322339080300100874585985220084088882745103145230216047487779174956161518920280447603674 * α ^ 6 + 184544739027532874709347195849421533711097651533181291373211062330869431152671413319813999120439419738468174182904364464 * α ^ 7 + 246608145764613286789878656386710073720610930090411123420903881172229605185065434892818764890373842116194248634263756798 * α ^ 8 + 283763693487574246430404620051411555790859557853657413692053633072552222818811355084552210214522447497912164915857007772 * α ^ 9 + 284375388167493337786979561808634395465424553508941556573930507406581722477890971264427055005741911794482115087411543730 * α ^ 10 + 250434456333498778687253731739220273422355020504490227298836915758303181227856673748711052077418442551670601820448469608 * α ^ 11 + 195186376833089073717511924197741339564583901408375396552289751612744737294639334816437871802096096044647044024483571528 * α ^ 12 + 135403325876044028593166865189418922031634343539481341612266706224679843802900374983571701066935649917189903585957861976 * α ^ 13 + 83987295633438700092517506437803590415296544388998812046873276158407316217262430264254188896692746403373298520205212844 * α ^ 14 + 46749761312162043935912318982126078666828249385834636225082169910759646501503433598091545864589766997203234619939545928 * α ^ 15 + 23418772546685983831264607439067708954491960164074800112819444923487497120280358300648725634717312663795784508649665131 * α ^ 16 + 10580616042971700828358189370081401738808367070894586162364463432933276777181125840333157268302229461101124643546709974 * α ^ 17 + 4318183659819981488074693370040938716545728929617703773317165795943654804101138834083140850940446923358733078548068645 * α ^ 18 + 1593587693765014079746102214238987350113694708675138266157201007419844029857283186926010079342854945184589138949560164 * α ^ 19 + 532047925009422644797257472015181516662587259482075864085888807106871007422932953581727885439598490014141304896691047 * α ^ 20 + 160701892364069140905358669813546549814319510910544697552500165178091918076856803958923921001593977227161490804746106 * α ^ 21 + 43889653627121057923774311030558057038777866396589839090993605786486211704353490599487695285745585770243180871001173 * α ^ 22 + 10827357706237228452243490602525886439138079007606319319715720331950005385599610283148806774807521304374526909486664 * α ^ 23 + 2408842256812625932290911263046890728148322122703071503064745543954110106028352314896838503963205885454006647328032 * α ^ 24 + 482237450846393383131287501498018968499665598348674814673101519961867723893846884326467389187302292657246662111488 * α ^ 25 + 86620744735037078123451064351322751112466467920961355862225908103410633498456796660448573578914072648246281297272 * α ^ 26 + 13908651519349479073873240534072463905809010212400405416347877534040408226391579668251784782713336166212519013104 * α ^ 27 + 1987136509055095540850907316692328719109975779097323211935130132295635949953814198439654077152611676110556260102 * α ^ 28 + 251138932516361376722297645486554574796035287318555929793528638706264274506637419055880639659286763175005448076 * α ^ 29 + 27871094123052914818399316975765472111564288696313684416212667809570265754686721498698986614959173244385297518 * α ^ 30 + 2690865047909357054511239261296500605261094896849533507003089976244070348637842057420543829564694293947173400 * α ^ 31 + 223291370726238703406997118812607738047342804101888528968918478200237656608670127439529056632663807296136083 * α ^ 32 + 15669985331287744715848606174054829999776651533612117903292549399606649200386705738963593063781305669960598 * α ^ 33 + 909073729758232176167878755737698432102154655242833248859457302905520734577946123899448989405380991348941 * α ^ 34 + 42091260471451636997926921594629293230252747899173824918202060597101883618323097768155200270442748875668 * α ^ 35 + 1450861895455204845787988647170733163350496179912678839329200986510884388428173389320127180407765638551 * α ^ 36 + 19698279579096177164787018164158789132912466550646401885212259058865017062230215250892367283766302154 * α ^ 37 - 57652053317489414390572934832324830300466266131622345505450510286650133357321127488185831111381791595 * α ^ 38 + 735839726136777192033003352499083088738558026604488978404480341017143472486567180936350888710307864 * α ^ 39 - 4556557091452941380040035385055147646930930624200910749123957637499614710015132762550103799821048 * α ^ 40 - 133385784303410256278801057965454595590178412725438433339158980224721485193506478868247418219456 * α ^ 41 - 3423096723020314850982421385371010756189634167048478694293828864372204445633272936186470719904 * α ^ 42 - 69804839903958953293946387520015029557798645931631581080348037608367532112774187909634522240 * α ^ 43 - 865452330871186953510596734828786492278941181396935228550729318386099014534564956306824064 * α ^ 44 + 6798618471243250403976624728656397719531634223766543816506986827945697172779099788420608 * α ^ 45 + 788561506471686257274486905164229697457259305541495354329419768350740667053416558054144 * α ^ 46 + 27404388758747154771370930189376580679701159098426606936627216153391035767084433846272 * α ^ 47 + 646649551478726098614980210707984819816807233831805276746361716798674738190577340416 * α ^ 48 + 11211130515851440319438235357551475100839553634180130203899774136494056161035911168 * α ^ 49 + 130654761491363390209265527305244677484674002463471732106539824077702885812797440 * α ^ 50 + 357370958717189390935129396104908992248522307474545437642970135644954582646784 * α ^ 51 - 29181736810016345568442240720495430859483450421903151495150669166766787592192 * α ^ 52 - 955989844135526470691849812345208816075517571032312722273829147296013484032 * α ^ 53 - 19693589749621923555627023816809550207524792367857705784556171741361864704 * α ^ 54 - 319527958823219288171919301676630081495413277792849934402743906350399488 * α ^ 55 - 4359916692864270231911575583538878442433933182393484084715401339994112 * α ^ 56 - 51487996872395271018065603117315986670053043845988016897449388933120 * α ^ 57 - 534287852041371238607889671805075544881560005268660814584293097472 * α ^ 58 - 4914742088163302214038533958003066516795399439930469941648556032 * α ^ 59 - 40286770643795091951577560453084774722804729349509280681689088 * α ^ 60 - 295170417808439805757992973335875121127546339919271705968640 * α ^ 61 - 1935804396482191076314681386409043851261791712104853536768 * α ^ 62 - 11366432523474642581662414816114955814707861565858643968 * α ^ 63 - 59703170845283859723339853111711322814822346376871936 * α ^ 64 - 280018128137086019618307155094771953353132297158656 * α ^ 65 - 1169385347161959260160465901639985114274911485952 * α ^ 66 - 4331161143994110763407260197680039459865755648 * α ^ 67 - 14153828793218044771011521216530198581739520 * α ^ 68 - 40537586126827346928475190951612417835008 * α ^ 69 - 100883783567908658123954038279633895424 * α ^ 70 - 215746527094612923562575346607849472 * α ^ 71 - 390762372880065519809958474940416 * α ^ 72 - 587839886222327464463148515328 * α ^ 73 - 714822291149465741724483584 * α ^ 74 - 675179423113136706682880 * α ^ 75 - 464818794079734202368 * α ^ 76 - 207493237324120064 * α ^ 77 - 45079976738816 * α ^ 78) / (8726915358595123009554969816074437428683544448177575906986909934144882288031056240648490385586384 * (3 + α) ^ 39) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B80_100 diff --git a/Sendov/FiniteRange/Degree8_9.lean b/Sendov/FiniteRange/Degree8_9.lean index 33482ec..19fce56 100644 --- a/Sendov/FiniteRange/Degree8_9.lean +++ b/Sendov/FiniteRange/Degree8_9.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch 8 to 9 @@ -92,12 +93,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 4) : ring -- The Bernstein summands are nonnegative. If α > 0 the last one is positive; -- at α = 0 the first one is positive. No per-coefficient hypotheses are needed. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < (4 : ℝ) ^ 6)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < 4 - α := by linarith - positivity + bernstein_cert α (4 - α) using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -128,8 +124,7 @@ theorem finite_range {n : ℕ} (h0 : 8 ≤ n) (h1 : n ≤ 9) {α : ℝ} ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < (656208 + 407736 * α - 877827 * α ^ 2 + 621074 * α ^ 3 - 39267 * α ^ 4 - 5436 * α ^ 5 - 180 * α ^ 6) / (47040 * (3 + α) ^ 3) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B8_9 diff --git a/Sendov/FiniteRange/Degree97Packed.lean b/Sendov/FiniteRange/Degree97Packed.lean index 950ea7e..76a2c04 100644 --- a/Sendov/FiniteRange/Degree97Packed.lean +++ b/Sendov/FiniteRange/Degree97Packed.lean @@ -36,24 +36,25 @@ def Nmom97_46 : List ℤ := theorem pev_Nmom97_46 (α : ℝ) : pev Nmom97_46 α = pev (wsum L97_46 0 (qrow (gg0 97) (gg1 97) (gg2 97) 46)) α := by refine pev_wsum_eq_of_packed (gg0 97) (gg1 97) (gg2 97) 46 139 L97_46 beta97_46 tau97_46 - Nmom97_46 (by norm_num [beta97_46]) (by norm_num [tau97_46]) ?_ ?_ ?_ ?_ ?_ ?_ α + Nmom97_46 (by decide) (by decide) ?_ ?_ ?_ ?_ ?_ ?_ α + -- Bound the packed row structurally, without expanding qrow. · refine rowZ_bound (gg0 97) (gg1 97) (gg2 97) 46 3 beta97_46 tau97_46 - (by norm_num [beta97_46]) (by decide) (by decide) (by decide) ?_ + (by decide) (by decide) (by decide) (by decide) ?_ norm_num [gg0, gg1, gg2, l1, beta97_46, tau97_46] - · decide + · decide -- Every supplied numerator coefficient fits in β. · refine wsum_bound (gg0 97) (gg1 97) (gg2 97) 46 L97_46 beta97_46 - (by norm_num [L97_46]) ?_ + (by decide) ?_ norm_num [gg0, gg1, gg2, l1, L97_46, beta97_46] - · decide + · decide -- The supplied list satisfies the promised length bound. · exact wsum_length_le L97_46 _ 0 (qrow_entry_length_le (gg0 97) (gg1 97) (gg2 97) 3 (by decide) (by decide) (by decide) 46) - · rfl + · rfl -- The remaining check is the exact packed integer equality. /-- The degree-97 moment at `k = 46`. -/ theorem integral_ninetyseven_46 (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 97 α t ^ 46) = pev Nmom97_46 α / ((L97_46 : ℝ) * (2 * M 97 * (3 + α)) ^ 46) := - integral_moment_packed 97 46 (by norm_num) α hα L97_46 (by norm_num [L97_46]) Nmom97_46 + integral_moment_packed 97 46 (by norm_num) α hα L97_46 (by decide) Nmom97_46 (by decide) (pev_Nmom97_46 α) /-- `lcm (4 .. 98)`. -/ @@ -72,24 +73,25 @@ def Nmom97_47 : List ℤ := theorem pev_Nmom97_47 (α : ℝ) : pev Nmom97_47 α = pev (wsum L97_47 0 (qrow (gg0 97) (gg1 97) (gg2 97) 47)) α := by refine pev_wsum_eq_of_packed (gg0 97) (gg1 97) (gg2 97) 47 142 L97_47 beta97_47 tau97_47 - Nmom97_47 (by norm_num [beta97_47]) (by norm_num [tau97_47]) ?_ ?_ ?_ ?_ ?_ ?_ α + Nmom97_47 (by decide) (by decide) ?_ ?_ ?_ ?_ ?_ ?_ α + -- Bound the packed row structurally, without expanding qrow. · refine rowZ_bound (gg0 97) (gg1 97) (gg2 97) 47 3 beta97_47 tau97_47 - (by norm_num [beta97_47]) (by decide) (by decide) (by decide) ?_ + (by decide) (by decide) (by decide) (by decide) ?_ norm_num [gg0, gg1, gg2, l1, beta97_47, tau97_47] - · decide + · decide -- Every supplied numerator coefficient fits in β. · refine wsum_bound (gg0 97) (gg1 97) (gg2 97) 47 L97_47 beta97_47 - (by norm_num [L97_47]) ?_ + (by decide) ?_ norm_num [gg0, gg1, gg2, l1, L97_47, beta97_47] - · decide + · decide -- The supplied list satisfies the promised length bound. · exact wsum_length_le L97_47 _ 0 (qrow_entry_length_le (gg0 97) (gg1 97) (gg2 97) 3 (by decide) (by decide) (by decide) 47) - · rfl + · rfl -- The remaining check is the exact packed integer equality. /-- The degree-97 moment at `k = 47`. -/ theorem integral_ninetyseven_47 (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 97 α t ^ 47) = pev Nmom97_47 α / ((L97_47 : ℝ) * (2 * M 97 * (3 + α)) ^ 47) := - integral_moment_packed 97 47 (by norm_num) α hα L97_47 (by norm_num [L97_47]) Nmom97_47 + integral_moment_packed 97 47 (by norm_num) α hα L97_47 (by decide) Nmom97_47 (by decide) (pev_Nmom97_47 α) end Sendov diff --git a/Sendov/FiniteRange/Moments.lean b/Sendov/FiniteRange/Moments.lean index d790797..2ed9435 100644 --- a/Sendov/FiniteRange/Moments.lean +++ b/Sendov/FiniteRange/Moments.lean @@ -67,14 +67,8 @@ lemma t3_mul_Q_pow (n : ℕ) (α t : ℝ) (k : ℕ) : rw [hQ, quad_pow, mul_sum] refine sum_congr rfl fun i _ => ?_ rw [mul_sum] - refine sum_congr rfl fun l hl => ?_ - have hl' : l ≤ i := Nat.lt_succ_iff.1 (mem_range.1 hl) - have hexp : 3 + (2 * i - l) = 2 * i - l + 3 := by omega - calc t ^ 3 * (((k.choose i : ℝ) * (i.choose l) * (-2 * c n α) ^ l * A n α ^ (i - l)) - * t ^ (2 * i - l)) - = ((k.choose i : ℝ) * (i.choose l) * (-2 * c n α) ^ l * A n α ^ (i - l)) - * (t ^ 3 * t ^ (2 * i - l)) := by ring - _ = _ := by rw [← pow_add, hexp] + refine sum_congr rfl fun l _ => ?_ + rw [mul_left_comm, ← pow_add, Nat.add_comm 3] /-- The `k`-th moment `∫ t in 0..1, t ^ 3 * Q ^ k`, as an explicit finite double sum. This is `(M)` of the informal plan. -/ diff --git a/Sendov/FiniteRange/OddBound.lean b/Sendov/FiniteRange/OddBound.lean index fe33feb..6c465a5 100644 --- a/Sendov/FiniteRange/OddBound.lean +++ b/Sendov/FiniteRange/OddBound.lean @@ -44,15 +44,9 @@ lemma sqrt_le_tangent (hq : 0 ≤ q) (hw : 0 < w) : Real.sqrt q ≤ q / (2 * w) /-- The half-integer power bound `q ^ (k + 1/2) ≤ q ^ k * (q/(2w) + w/2)`. -/ lemma rpow_add_half_le (hq : 0 ≤ q) (k : ℕ) (hw : 0 < w) : q ^ ((k : ℝ) + 1 / 2) ≤ q ^ k * (q / (2 * w) + w / 2) := by - rcases hq.lt_or_eq with h | h - · have he : q ^ ((k : ℝ) + 1 / 2) = q ^ k * Real.sqrt q := by - rw [Real.rpow_add h, Real.rpow_natCast, Real.sqrt_eq_rpow] - rw [he] - exact mul_le_mul_of_nonneg_left (sqrt_le_tangent hq hw) (pow_nonneg hq k) - · rw [← h, Real.zero_rpow (by positivity)] - refine mul_nonneg (pow_nonneg le_rfl k) ?_ - rw [zero_div] - linarith + rw [Real.rpow_add_of_nonneg hq (Nat.cast_nonneg k) (by positivity), + Real.rpow_natCast, ← Real.sqrt_eq_rpow] + exact mul_le_mul_of_nonneg_left (sqrt_le_tangent hq hw) (pow_nonneg hq k) /-- **The odd-degree bound.** The square root is eliminated in favour of polynomial moments, at the cost of a free parameter `w > 0`. -/ diff --git a/Sendov/FiniteRange/Pack.lean b/Sendov/FiniteRange/Pack.lean index 01cd8b7..3a1ae82 100644 --- a/Sendov/FiniteRange/Pack.lean +++ b/Sendov/FiniteRange/Pack.lean @@ -137,7 +137,7 @@ lemma npev_pmulN (p q : List ℕ) (b : ℕ) : lemma npev_ppowN (p : List ℕ) (b k : ℕ) : npev (ppowN p k) b = npev p b ^ k := by induction k with | zero => simp [ppowN] - | succ k ih => simp only [ppowN, npev_pmulN, ih, pow_succ]; ring + | succ k ih => simp only [ppowN, npev_pmulN, ih, pow_succ'] /-! ### The overflow bound -/ @@ -165,9 +165,7 @@ theorem unpackN_pow (b : ℕ) (hb : 0 < b) (p : List ℕ) (k : ℕ) unpackN b (ppowN p k).length (npev p b ^ k) = ppowN p k := by rw [← npev_ppowN p b k] refine unpackN_npev b hb _ fun a ha => ?_ - have h1 : a ≤ npev (ppowN p k) 1 := mem_le_npev_one _ a ha - rw [npev_ppowN] at h1 - omega + exact lt_of_le_of_lt (by simpa [npev_ppowN] using mem_le_npev_one (ppowN p k) a ha) hbound /-! ### Signed coefficients diff --git a/Sendov/FiniteRange/PackBridge.lean b/Sendov/FiniteRange/PackBridge.lean index 1ea5504..395f723 100644 --- a/Sendov/FiniteRange/PackBridge.lean +++ b/Sendov/FiniteRange/PackBridge.lean @@ -330,32 +330,22 @@ zero-padded. -/ theorem unpackZ_pevZ_le (β : ℤ) (hβ : 0 < β) : ∀ (m : ℕ) (p : List ℤ), p.length ≤ m → (∀ a ∈ p, 2 * |a| < β) → unpackZ β m (pevZ p β) = p ++ List.replicate (m - p.length) 0 := by - intro m - induction m with - | zero => - intro p hlen _ - simp [List.length_eq_zero_iff.1 (Nat.le_zero.1 hlen)] - | succ m ih => - intro p hlen hb - cases p with - | nil => - have h0 : bdig β 0 = 0 := by - have : (0 : ℤ) % β = 0 := Int.zero_emod β - simp only [bdig, this] - split_ifs <;> omega - simp only [pevZ_nil, unpackZ_succ, h0, List.nil_append, List.length_nil, - Nat.sub_zero, List.replicate_succ] - have := ih [] (Nat.zero_le m) (by simp) - simpa using this - | cons a p => - have ha : 2 * |a| < β := hb a (List.mem_cons_self ..) - have hp : ∀ x ∈ p, 2 * |x| < β := fun x hx => hb x (List.mem_cons_of_mem _ hx) - have hd : bdig β (a + β * pevZ p β) = a := bdig_add_mul β a _ hβ ha - have hq : (a + β * pevZ p β - a) / β = pevZ p β := by - rw [add_sub_cancel_left, Int.mul_ediv_cancel_left _ hβ.ne'] - simp only [pevZ_cons, unpackZ_succ, hd, hq, List.length_cons] - rw [ih p (by simpa using Nat.le_of_succ_le_succ hlen) hp] - simp + intro m p hlen hb + -- Apply the exact round trip to the padded list, rather than repeat digit extraction. + have hlen' : (p ++ List.replicate (m - p.length) 0).length = m := by + simp only [List.length_append, List.length_replicate] + omega + have heval : pevZ (p ++ List.replicate (m - p.length) 0) β = pevZ p β := by + have h := pev_append_zeros p (m - p.length) (β : ℝ) + simp only [pev_intCast] at h + exact_mod_cast h + have hround := unpackZ_pevZ β hβ (p ++ List.replicate (m - p.length) 0) (by + intro a ha + rcases List.mem_append.1 ha with ha | ha + · exact hb a ha + · have ha0 : a = 0 := (List.mem_replicate.1 ha).2 + simpa [ha0] using hβ) + simpa only [hlen', heval] using hround /-- The weighted sum computed directly on the α-packed row. -/ def wsumZ (L : ℤ) : ℕ → List ℤ → ℤ @@ -368,18 +358,15 @@ def wsumZ (L : ℤ) : ℕ → List ℤ → ℤ wsumZ L i (a :: s) = (L / ((i : ℤ) + 4)) * a + wsumZ L (i + 1) s := rfl lemma pevZ_padd (p q : List ℤ) (b : ℤ) : pevZ (padd p q) b = pevZ p b + pevZ q b := by - induction p generalizing q with - | nil => simp [padd] - | cons a p ih => - cases q with - | nil => simp [padd] - | cons c q => simp only [padd, pevZ_cons, ih]; ring + have h := pev_padd p q (b : ℝ) + simp only [pev_intCast] at h + exact_mod_cast h lemma pevZ_map_mul (c : ℤ) (q : List ℤ) (b : ℤ) : pevZ (q.map (fun x => c * x)) b = c * pevZ q b := by - induction q with - | nil => simp - | cons x q ih => simp only [List.map_cons, pevZ_cons, ih]; ring + have h := pev_map_mul c q (b : ℝ) + simp only [pev_intCast] at h + exact_mod_cast h /-- The packed weighted sum agrees with packing the weighted sum: this is what makes the check a single integer comparison. -/ @@ -620,20 +607,7 @@ theorem integral_moment_packed (n k : ℕ) (hn : 2 ≤ n) (α : ℝ) (hα : 0 /-- Every coefficient of every entry of a row is bounded by the row's `L¹` norm. -/ lemma abs_le_l1row : ∀ (r : List (List ℤ)) (p : List ℤ), p ∈ r → ∀ a ∈ p, |a| ≤ l1row r := by - intro r - induction r with - | nil => intro p hp; cases hp - | cons q r ih => - intro p hp a ha - rcases List.mem_cons.1 hp with h | h - · subst h - have := abs_le_l1 p a ha - have := l1row_nonneg r - simp only [l1row_cons] - omega - · have := ih p h a ha - have := l1_nonneg q - simp only [l1row_cons] - omega + intro r p hp a ha + exact (abs_le_l1 p a ha).trans (l1_le_l1row r p hp) end Sendov diff --git a/Sendov/FiniteRange/Recurrence.lean b/Sendov/FiniteRange/Recurrence.lean index b26f0cb..d9d7614 100644 --- a/Sendov/FiniteRange/Recurrence.lean +++ b/Sendov/FiniteRange/Recurrence.lean @@ -135,8 +135,8 @@ lemma rev_rscale (g : List ℤ) (r : List (List ℤ)) (α t : ℝ) : induction r with | nil => simp [rscale] | cons p r ih => - simp only [rscale, List.map_cons, rev_cons, pev_pmul] at * - rw [ih] + change rev (pmul g p :: rscale g r) α t = _ + rw [rev_cons, pev_pmul, ih, rev_cons] ring lemma rev_shift (r : List (List ℤ)) (α t : ℝ) : @@ -240,10 +240,7 @@ def gg2 (n : ℕ) : List ℤ := [6 * ((n : ℤ) - 1), 2 * ((n : ℤ) - 1) - 12, lemma DQ_eq (n : ℕ) (hn : 2 ≤ n) (α t : ℝ) (hα : 0 ≤ α) : (2 * M n * (3 + α)) * Q n α t = pev (gg0 n) α + pev (gg1 n) α * t + pev (gg2 n) α * t ^ 2 := by - have hM : ((n : ℝ) - 1) ≠ 0 := by - have h := M_pos hn - simp only [M] at h - linarith + have hM : ((n : ℝ) - 1) ≠ 0 := (M_pos hn).ne' have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' simp only [gg0, gg1, gg2, pev_cons, pev_nil, Q, c, A, M] push_cast diff --git a/Sendov/LargeDegree/Endgame.lean b/Sendov/LargeDegree/Endgame.lean index 24c08cd..ea2e0b6 100644 --- a/Sendov/LargeDegree/Endgame.lean +++ b/Sendov/LargeDegree/Endgame.lean @@ -4,6 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE. Authors: Terence Tao -/ import Sendov.LargeDegree.Monotone +import Sendov.Common.BernsteinCert /-! # The large-degree claim @@ -53,133 +54,9 @@ set_option maxHeartbeats 4000000 in lemma F_pos (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 1122702787291394736448332031899900000000 + 19046325083555631071589567727384404000000 * α + 158421799401305511319831453323336122340000 * α ^ 2 + 861086144839783899262522290902928965732400 * α ^ 3 + 3439408019860839882261371580238947745811319 * α ^ 4 + 10763976190978343059270128976319908699279230 * α ^ 5 + 27482264870203746404049226779511973140100922 * α ^ 6 + 58851751350273881387953189525455032864879976 * α ^ 7 + 107855247587877306122230293103712405510570475 * α ^ 8 + 171759728691636266490365540891679381811794330 * α ^ 9 + 240529488382582584529650966973246412375404200 * α ^ 10 + 299026713527922503750214218383542861883052640 * α ^ 11 + 332584383792637363818110693156644176263245770 * α ^ 12 + 333049929303875184857821696251322094451555300 * α ^ 13 + 301880762905153988961008260011013859110924020 * α ^ 14 + 248778383542817950458457719347804130388393200 * α ^ 15 + 187098708657492312991354787006951375606496810 * α ^ 16 + 128821377534531366266108990532541378516293180 * α ^ 17 + 81419630849957631346647265524754482691775400 * α ^ 18 + 47345231058420765609063602657623737762737040 * α ^ 19 + 25377634631717199993415818405387727249820325 * α ^ 20 + 12558381461678887884336588690871882873720170 * α ^ 21 + 5744808624780589326694261819822529221060710 * α ^ 22 + 2431706095253331452737540626239749451182200 * α ^ 23 + 953157993950838580367703259303917955151865 * α ^ 24 + 346144642670223976596034179062502690180750 * α ^ 25 + 116495518414609472010567246197077176778320 * α ^ 26 + 36336281152740288609221052030650841399360 * α ^ 27 + 10502010275079971287850469706276099760700 * α ^ 28 + 2811408048396859598615803016678577566616 * α ^ 29 + 696637045577195749563697260889295071320 * α ^ 30 + 159631247175312590035611267009797954208 * α ^ 31 + 33785522480785269776966858820750983964 * α ^ 32 + 6594450665275339854415586104207300200 * α ^ 33 + 1184779969344702509178802875319571760 * α ^ 34 + 195478905533580848831244517654808400 * α ^ 35 + 29535092351319878473338799170306705 * α ^ 36 + 4072478636506932555839271140088690 * α ^ 37 + 510306927013451786184096375133350 * α ^ 38 + 57808428584128470185954723726040 * α ^ 39 + 5881482509330352987406470588525 * α ^ 40 + 532894392271418064251604942870 * α ^ 41 + 42515012647728027357611076360 * α ^ 42 + 2939585612233076406278632800 * α ^ 43 + 171946491190832176774496730 * α ^ 44 + 8163588014241841361016900 * α ^ 45 + 287999399301298111575540 * α ^ 46 + 5555726484083859953520 * α ^ 47 - 536551383276446293350 * α ^ 48 - 269167118332858968420 * α ^ 49 - 48279425158933803000 * α ^ 50 - 1759012112154436560 * α ^ 51 + 273395914772406495 * α ^ 52 + 6240162359537050 * α ^ 53 - 1129204084343291 * α ^ 54 + 41554143448524 * α ^ 55 - 721404477395 * α ^ 56 + 6229533730 * α ^ 57 - 21627837 * α ^ 58 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith - have h0 : (0:ℝ) ≤ 1122702787291394736448332031899900000000 * (17 - α) ^ 58 := - mul_nonneg (by norm_num) (pow_nonneg hu 58) - have h1 : (0:ℝ) ≤ 388904288083346622931025909215729068000000 * α ^ 1 * (17 - α) ^ 57 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 1)) (pow_nonneg hu 57) - have h2 : (0:ℝ) ≤ 66095616740335374779150673987010161532260000 * α ^ 2 * (17 - α) ^ 56 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 2)) (pow_nonneg hu 56) - have h3 : (0:ℝ) ≤ 7345821640480281350499142140546658776321841200 * α ^ 3 * (17 - α) ^ 55 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 3)) (pow_nonneg hu 55) - have h4 : (0:ℝ) ≤ 600398748030850807066041679815685800572608040199 * α ^ 4 * (17 - α) ^ 54 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 4)) (pow_nonneg hu 54) - have h5 : (0:ℝ) ≤ 38479987967757849353019399973163199134827376858856 * α ^ 5 * (17 - α) ^ 53 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 5)) (pow_nonneg hu 53) - have h6 : (0:ℝ) ≤ 2013648131786096177205150562840212460891734276215217 * α ^ 6 * (17 - α) ^ 52 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 6)) (pow_nonneg hu 52) - have h7 : (0:ℝ) ≤ 88459088337848664272764574750756035751708812314589560 * α ^ 7 * (17 - α) ^ 51 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 7)) (pow_nonneg hu 51) - have h8 : (0:ℝ) ≤ 3328752627388631431253304215842302161184427248710824200 * α ^ 8 * (17 - α) ^ 50 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 8)) (pow_nonneg hu 50) - have h9 : (0:ℝ) ≤ 108955148579598077254581984889507974501857717600550300000 * α ^ 9 * (17 - α) ^ 49 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 9)) (pow_nonneg hu 49) - have h10 : (0:ℝ) ≤ 3139320986827193043298955183356728835782414071606732250000 * α ^ 10 * (17 - α) ^ 48 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 10)) (pow_nonneg hu 48) - have h11 : (0:ℝ) ≤ 80389849002074687648105368735226451202772917094058768000000 * α ^ 11 * (17 - α) ^ 47 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 11)) (pow_nonneg hu 47) - have h12 : (0:ℝ) ≤ 1843869779817877110104286469976591396926664444962705440000000 * α ^ 12 * (17 - α) ^ 46 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 12)) (pow_nonneg hu 46) - have h13 : (0:ℝ) ≤ 38126021284745149595963616317393007484187425284263404800000000 * α ^ 13 * (17 - α) ^ 45 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 13)) (pow_nonneg hu 45) - have h14 : (0:ℝ) ≤ 714519722771974812940511821448225512188719319523829280000000000 * α ^ 14 * (17 - α) ^ 44 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 14)) (pow_nonneg hu 44) - have h15 : (0:ℝ) ≤ 12192162072496626088921760868440507818256588279501222400000000000 * α ^ 15 * (17 - α) ^ 43 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 15)) (pow_nonneg hu 43) - have h16 : (0:ℝ) ≤ 190149195298252798424521646382266997826378949113808102400000000000 * α ^ 16 * (17 - α) ^ 42 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 16)) (pow_nonneg hu 42) - have h17 : (0:ℝ) ≤ 2719453325782140875058402865898661993411332371079473152000000000000 * α ^ 17 * (17 - α) ^ 41 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 17)) (pow_nonneg hu 41) - have h18 : (0:ℝ) ≤ 35765156781668343145270939254204039481078844597447447040000000000000 * α ^ 18 * (17 - α) ^ 40 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 18)) (pow_nonneg hu 40) - have h19 : (0:ℝ) ≤ 433581369383490123337920330591320005197369743601113088000000000000000 * α ^ 19 * (17 - α) ^ 39 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 19)) (pow_nonneg hu 39) - have h20 : (0:ℝ) ≤ 4855120840322429070915669670313005676027625016591872000000000000000000 * α ^ 20 * (17 - α) ^ 38 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 20)) (pow_nonneg hu 38) - have h21 : (0:ℝ) ≤ 50303800927352895844904371767120477621293024508175810560000000000000000 * α ^ 21 * (17 - α) ^ 37 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 21)) (pow_nonneg hu 37) - have h22 : (0:ℝ) ≤ 482953904720497092819809519030958414936076990756461772800000000000000000 * α ^ 22 * (17 - α) ^ 36 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 22)) (pow_nonneg hu 36) - have h23 : (0:ℝ) ≤ 4301697515309799266557277840727716853246295229412212736000000000000000000 * α ^ 23 * (17 - α) ^ 35 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 23)) (pow_nonneg hu 35) - have h24 : (0:ℝ) ≤ 35582005974740842580199098139010545771216816653126860800000000000000000000 * α ^ 24 * (17 - α) ^ 34 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 24)) (pow_nonneg hu 34) - have h25 : (0:ℝ) ≤ 273535549248031302586908863638264651412739231630163968000000000000000000000 * α ^ 25 * (17 - α) ^ 33 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 25)) (pow_nonneg hu 33) - have h26 : (0:ℝ) ≤ 1955426273644204648009173651834541693843095232637140992000000000000000000000 * α ^ 26 * (17 - α) ^ 32 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 26)) (pow_nonneg hu 32) - have h27 : (0:ℝ) ≤ 13004222926412994888311248631808734105341900865415413760000000000000000000000 * α ^ 27 * (17 - α) ^ 31 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 27)) (pow_nonneg hu 31) - have h28 : (0:ℝ) ≤ 80470387643773112884644249468688475191473557588882227200000000000000000000000 * α ^ 28 * (17 - α) ^ 30 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 28)) (pow_nonneg hu 30) - have h29 : (0:ℝ) ≤ 463355476918012102672652719197790300193712035699097600000000000000000000000000 * α ^ 29 * (17 - α) ^ 29 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 29)) (pow_nonneg hu 29) - have h30 : (0:ℝ) ≤ 2482344082055683113128185595725000998635940934141870080000000000000000000000000 * α ^ 30 * (17 - α) ^ 28 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 30)) (pow_nonneg hu 28) - have h31 : (0:ℝ) ≤ 12369353793584370842106405783534323328114720329863004160000000000000000000000000 * α ^ 31 * (17 - α) ^ 27 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 31)) (pow_nonneg hu 27) - have h32 : (0:ℝ) ≤ 57300834405504520484711032055319485636127102860053708800000000000000000000000000 * α ^ 32 * (17 - α) ^ 26 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 32)) (pow_nonneg hu 26) - have h33 : (0:ℝ) ≤ 246613403330189144932245957910378250136137902552252416000000000000000000000000000 * α ^ 33 * (17 - α) ^ 25 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 33)) (pow_nonneg hu 25) - have h34 : (0:ℝ) ≤ 985246695411671462829426238732411673050896371023872000000000000000000000000000000 * α ^ 34 * (17 - α) ^ 24 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 34)) (pow_nonneg hu 24) - have h35 : (0:ℝ) ≤ 3649974776445129628396257437653948413551102593597440000000000000000000000000000000 * α ^ 35 * (17 - α) ^ 23 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 35)) (pow_nonneg hu 23) - have h36 : (0:ℝ) ≤ 12522828085409243337307923676013931236910302987550720000000000000000000000000000000 * α ^ 36 * (17 - α) ^ 22 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 36)) (pow_nonneg hu 22) - have h37 : (0:ℝ) ≤ 39731340789062838384502107867195079108983927708057600000000000000000000000000000000 * α ^ 37 * (17 - α) ^ 21 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 37)) (pow_nonneg hu 21) - have h38 : (0:ℝ) ≤ 116365100653574128528674694068315721419971773857792000000000000000000000000000000000 * α ^ 38 * (17 - α) ^ 20 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 38)) (pow_nonneg hu 20) - have h39 : (0:ℝ) ≤ 313971050757264181615490913824916376724876505907200000000000000000000000000000000000 * α ^ 39 * (17 - α) ^ 19 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 39)) (pow_nonneg hu 19) - have h40 : (0:ℝ) ≤ 778602881203434272472350446775468799876667539456000000000000000000000000000000000000 * α ^ 40 * (17 - α) ^ 18 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 40)) (pow_nonneg hu 18) - have h41 : (0:ℝ) ≤ 1769823234178269115425193251412793044953817153536000000000000000000000000000000000000 * α ^ 41 * (17 - α) ^ 17 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 41)) (pow_nonneg hu 17) - have h42 : (0:ℝ) ≤ 3676061908648613727975384722760757591726652129280000000000000000000000000000000000000 * α ^ 42 * (17 - α) ^ 16 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 42)) (pow_nonneg hu 16) - have h43 : (0:ℝ) ≤ 6952202666310032877475473290777345311129573785600000000000000000000000000000000000000 * α ^ 43 * (17 - α) ^ 15 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 43)) (pow_nonneg hu 15) - have h44 : (0:ℝ) ≤ 11922241592723733002313059523572394705939333120000000000000000000000000000000000000000 * α ^ 44 * (17 - α) ^ 14 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 44)) (pow_nonneg hu 14) - have h45 : (0:ℝ) ≤ 18450845478651168634684539530259247984017408000000000000000000000000000000000000000000 * α ^ 45 * (17 - α) ^ 13 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 45)) (pow_nonneg hu 13) - have h46 : (0:ℝ) ≤ 25626302281194153741004424813630605199042150400000000000000000000000000000000000000000 * α ^ 46 * (17 - α) ^ 12 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 46)) (pow_nonneg hu 12) - have h47 : (0:ℝ) ≤ 31735356381499745521943376637135285074788352000000000000000000000000000000000000000000 * α ^ 47 * (17 - α) ^ 11 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 47)) (pow_nonneg hu 11) - have h48 : (0:ℝ) ≤ 34773986078859125604170241648646078618789153800477215677912265790935664780750000000000 * α ^ 48 * (17 - α) ^ 10 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 48)) (pow_nonneg hu 10) - have h49 : (0:ℝ) ≤ 33406510810664082686608872230111026353099051641531587806834322064288344554180000000000 * α ^ 49 * (17 - α) ^ 9 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 49)) (pow_nonneg hu 9) - have h50 : (0:ℝ) ≤ 27820946523539616021999756980494999341031737804699133246948994617042670678045550000000 * α ^ 50 * (17 - α) ^ 8 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 50)) (pow_nonneg hu 8) - have h51 : (0:ℝ) ≤ 19791944456596303161181417657916215477628661862047060146272089595047078222827061000000 * α ^ 51 * (17 - α) ^ 7 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 51)) (pow_nonneg hu 7) - have h52 : (0:ℝ) ≤ 11779484527176566489160923853925282151874607361320815965499241151163816336970531507500 * α ^ 52 * (17 - α) ^ 6 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 52)) (pow_nonneg hu 6) - have h53 : (0:ℝ) ≤ 5685451710206041407628952698706724254113808400301600724661558108213464738446593549500 * α ^ 53 * (17 - α) ^ 5 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 53)) (pow_nonneg hu 5) - have h54 : (0:ℝ) ≤ 2124220422337628714954562682925792634155465583908214661397004639843167881489238854787 * α ^ 54 * (17 - α) ^ 4 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 54)) (pow_nonneg hu 4) - have h55 : (0:ℝ) ≤ 572909076732572616057605734230328840239193993814061157407956440967916397115623518120 * α ^ 55 * (17 - α) ^ 3 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 55)) (pow_nonneg hu 3) - have h56 : (0:ℝ) ≤ 99530623246032452139763064572679576747235355843313027086842616874975359183988464200 * α ^ 56 * (17 - α) ^ 2 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 56)) (pow_nonneg hu 2) - have h57 : (0:ℝ) ≤ 8820861539641882551843091227900257872626927159038875775406157756108783934565132000 * α ^ 57 * (17 - α) ^ 1 := - mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα 57)) (pow_nonneg hu 1) - have h58 : (0:ℝ) ≤ 161598081294237579548393327166198311182821276785721838823669379905701080186270000 * α ^ 58 := - mul_nonneg (by norm_num) (pow_nonneg hα 58) have hid : (17 : ℝ) ^ 58 * (1122702787291394736448332031899900000000 + 19046325083555631071589567727384404000000 * α + 158421799401305511319831453323336122340000 * α ^ 2 + 861086144839783899262522290902928965732400 * α ^ 3 + 3439408019860839882261371580238947745811319 * α ^ 4 + 10763976190978343059270128976319908699279230 * α ^ 5 + 27482264870203746404049226779511973140100922 * α ^ 6 + 58851751350273881387953189525455032864879976 * α ^ 7 + 107855247587877306122230293103712405510570475 * α ^ 8 + 171759728691636266490365540891679381811794330 * α ^ 9 + 240529488382582584529650966973246412375404200 * α ^ 10 + 299026713527922503750214218383542861883052640 * α ^ 11 + 332584383792637363818110693156644176263245770 * α ^ 12 + 333049929303875184857821696251322094451555300 * α ^ 13 + 301880762905153988961008260011013859110924020 * α ^ 14 + 248778383542817950458457719347804130388393200 * α ^ 15 + 187098708657492312991354787006951375606496810 * α ^ 16 + 128821377534531366266108990532541378516293180 * α ^ 17 + 81419630849957631346647265524754482691775400 * α ^ 18 + 47345231058420765609063602657623737762737040 * α ^ 19 + 25377634631717199993415818405387727249820325 * α ^ 20 + 12558381461678887884336588690871882873720170 * α ^ 21 + 5744808624780589326694261819822529221060710 * α ^ 22 + 2431706095253331452737540626239749451182200 * α ^ 23 + 953157993950838580367703259303917955151865 * α ^ 24 + 346144642670223976596034179062502690180750 * α ^ 25 + 116495518414609472010567246197077176778320 * α ^ 26 + 36336281152740288609221052030650841399360 * α ^ 27 + 10502010275079971287850469706276099760700 * α ^ 28 + 2811408048396859598615803016678577566616 * α ^ 29 + 696637045577195749563697260889295071320 * α ^ 30 + 159631247175312590035611267009797954208 * α ^ 31 + 33785522480785269776966858820750983964 * α ^ 32 + 6594450665275339854415586104207300200 * α ^ 33 + 1184779969344702509178802875319571760 * α ^ 34 + 195478905533580848831244517654808400 * α ^ 35 + 29535092351319878473338799170306705 * α ^ 36 + 4072478636506932555839271140088690 * α ^ 37 + 510306927013451786184096375133350 * α ^ 38 + 57808428584128470185954723726040 * α ^ 39 + 5881482509330352987406470588525 * α ^ 40 + 532894392271418064251604942870 * α ^ 41 + 42515012647728027357611076360 * α ^ 42 + 2939585612233076406278632800 * α ^ 43 + 171946491190832176774496730 * α ^ 44 + 8163588014241841361016900 * α ^ 45 + 287999399301298111575540 * α ^ 46 + 5555726484083859953520 * α ^ 47 - 536551383276446293350 * α ^ 48 - 269167118332858968420 * α ^ 49 - 48279425158933803000 * α ^ 50 - 1759012112154436560 * α ^ 51 + 273395914772406495 * α ^ 52 + 6240162359537050 * α ^ 53 - 1129204084343291 * α ^ 54 + 41554143448524 * α ^ 55 - 721404477395 * α ^ 56 + 6229533730 * α ^ 57 - 21627837 * α ^ 58) = 1122702787291394736448332031899900000000 * (17 - α) ^ 58 + 388904288083346622931025909215729068000000 * α ^ 1 * (17 - α) ^ 57 + 66095616740335374779150673987010161532260000 * α ^ 2 * (17 - α) ^ 56 + 7345821640480281350499142140546658776321841200 * α ^ 3 * (17 - α) ^ 55 + 600398748030850807066041679815685800572608040199 * α ^ 4 * (17 - α) ^ 54 + 38479987967757849353019399973163199134827376858856 * α ^ 5 * (17 - α) ^ 53 + 2013648131786096177205150562840212460891734276215217 * α ^ 6 * (17 - α) ^ 52 + 88459088337848664272764574750756035751708812314589560 * α ^ 7 * (17 - α) ^ 51 + 3328752627388631431253304215842302161184427248710824200 * α ^ 8 * (17 - α) ^ 50 + 108955148579598077254581984889507974501857717600550300000 * α ^ 9 * (17 - α) ^ 49 + 3139320986827193043298955183356728835782414071606732250000 * α ^ 10 * (17 - α) ^ 48 + 80389849002074687648105368735226451202772917094058768000000 * α ^ 11 * (17 - α) ^ 47 + 1843869779817877110104286469976591396926664444962705440000000 * α ^ 12 * (17 - α) ^ 46 + 38126021284745149595963616317393007484187425284263404800000000 * α ^ 13 * (17 - α) ^ 45 + 714519722771974812940511821448225512188719319523829280000000000 * α ^ 14 * (17 - α) ^ 44 + 12192162072496626088921760868440507818256588279501222400000000000 * α ^ 15 * (17 - α) ^ 43 + 190149195298252798424521646382266997826378949113808102400000000000 * α ^ 16 * (17 - α) ^ 42 + 2719453325782140875058402865898661993411332371079473152000000000000 * α ^ 17 * (17 - α) ^ 41 + 35765156781668343145270939254204039481078844597447447040000000000000 * α ^ 18 * (17 - α) ^ 40 + 433581369383490123337920330591320005197369743601113088000000000000000 * α ^ 19 * (17 - α) ^ 39 + 4855120840322429070915669670313005676027625016591872000000000000000000 * α ^ 20 * (17 - α) ^ 38 + 50303800927352895844904371767120477621293024508175810560000000000000000 * α ^ 21 * (17 - α) ^ 37 + 482953904720497092819809519030958414936076990756461772800000000000000000 * α ^ 22 * (17 - α) ^ 36 + 4301697515309799266557277840727716853246295229412212736000000000000000000 * α ^ 23 * (17 - α) ^ 35 + 35582005974740842580199098139010545771216816653126860800000000000000000000 * α ^ 24 * (17 - α) ^ 34 + 273535549248031302586908863638264651412739231630163968000000000000000000000 * α ^ 25 * (17 - α) ^ 33 + 1955426273644204648009173651834541693843095232637140992000000000000000000000 * α ^ 26 * (17 - α) ^ 32 + 13004222926412994888311248631808734105341900865415413760000000000000000000000 * α ^ 27 * (17 - α) ^ 31 + 80470387643773112884644249468688475191473557588882227200000000000000000000000 * α ^ 28 * (17 - α) ^ 30 + 463355476918012102672652719197790300193712035699097600000000000000000000000000 * α ^ 29 * (17 - α) ^ 29 + 2482344082055683113128185595725000998635940934141870080000000000000000000000000 * α ^ 30 * (17 - α) ^ 28 + 12369353793584370842106405783534323328114720329863004160000000000000000000000000 * α ^ 31 * (17 - α) ^ 27 + 57300834405504520484711032055319485636127102860053708800000000000000000000000000 * α ^ 32 * (17 - α) ^ 26 + 246613403330189144932245957910378250136137902552252416000000000000000000000000000 * α ^ 33 * (17 - α) ^ 25 + 985246695411671462829426238732411673050896371023872000000000000000000000000000000 * α ^ 34 * (17 - α) ^ 24 + 3649974776445129628396257437653948413551102593597440000000000000000000000000000000 * α ^ 35 * (17 - α) ^ 23 + 12522828085409243337307923676013931236910302987550720000000000000000000000000000000 * α ^ 36 * (17 - α) ^ 22 + 39731340789062838384502107867195079108983927708057600000000000000000000000000000000 * α ^ 37 * (17 - α) ^ 21 + 116365100653574128528674694068315721419971773857792000000000000000000000000000000000 * α ^ 38 * (17 - α) ^ 20 + 313971050757264181615490913824916376724876505907200000000000000000000000000000000000 * α ^ 39 * (17 - α) ^ 19 + 778602881203434272472350446775468799876667539456000000000000000000000000000000000000 * α ^ 40 * (17 - α) ^ 18 + 1769823234178269115425193251412793044953817153536000000000000000000000000000000000000 * α ^ 41 * (17 - α) ^ 17 + 3676061908648613727975384722760757591726652129280000000000000000000000000000000000000 * α ^ 42 * (17 - α) ^ 16 + 6952202666310032877475473290777345311129573785600000000000000000000000000000000000000 * α ^ 43 * (17 - α) ^ 15 + 11922241592723733002313059523572394705939333120000000000000000000000000000000000000000 * α ^ 44 * (17 - α) ^ 14 + 18450845478651168634684539530259247984017408000000000000000000000000000000000000000000 * α ^ 45 * (17 - α) ^ 13 + 25626302281194153741004424813630605199042150400000000000000000000000000000000000000000 * α ^ 46 * (17 - α) ^ 12 + 31735356381499745521943376637135285074788352000000000000000000000000000000000000000000 * α ^ 47 * (17 - α) ^ 11 + 34773986078859125604170241648646078618789153800477215677912265790935664780750000000000 * α ^ 48 * (17 - α) ^ 10 + 33406510810664082686608872230111026353099051641531587806834322064288344554180000000000 * α ^ 49 * (17 - α) ^ 9 + 27820946523539616021999756980494999341031737804699133246948994617042670678045550000000 * α ^ 50 * (17 - α) ^ 8 + 19791944456596303161181417657916215477628661862047060146272089595047078222827061000000 * α ^ 51 * (17 - α) ^ 7 + 11779484527176566489160923853925282151874607361320815965499241151163816336970531507500 * α ^ 52 * (17 - α) ^ 6 + 5685451710206041407628952698706724254113808400301600724661558108213464738446593549500 * α ^ 53 * (17 - α) ^ 5 + 2124220422337628714954562682925792634155465583908214661397004639843167881489238854787 * α ^ 54 * (17 - α) ^ 4 + 572909076732572616057605734230328840239193993814061157407956440967916397115623518120 * α ^ 55 * (17 - α) ^ 3 + 99530623246032452139763064572679576747235355843313027086842616874975359183988464200 * α ^ 56 * (17 - α) ^ 2 + 8820861539641882551843091227900257872626927159038875775406157756108783934565132000 * α ^ 57 * (17 - α) ^ 1 + 161598081294237579548393327166198311182821276785721838823669379905701080186270000 * α ^ 58 := by ring - rcases le_total α (17 / 2) with h | h - · have hpos : (0 : ℝ) < 1122702787291394736448332031899900000000 * (17 - α) ^ 58 := - mul_pos (by norm_num) (pow_pos (by linarith) 58) - linarith - · have hpos : (0 : ℝ) < 161598081294237579548393327166198311182821276785721838823669379905701080186270000 * α ^ 58 := - mul_pos (by norm_num) (pow_pos (by linarith) 58) - linarith + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 4000000 in /-- **The bound in `α` alone is below `1`.** -/ diff --git a/Sendov/LargeDegree/Monotone.lean b/Sendov/LargeDegree/Monotone.lean index 3f990ee..df20fae 100644 --- a/Sendov/LargeDegree/Monotone.lean +++ b/Sendov/LargeDegree/Monotone.lean @@ -195,16 +195,14 @@ lemma T1_le (hn : 101 ≤ n) (hα : 0 ≤ α) (hα' : α ≤ 17) : have hN : (0 : ℝ) < (n : ℝ) - 1 := by linarith have hN2 : (0 : ℝ) < (n : ℝ) + 2 := by linarith have hN4 : (0 : ℝ) < (n : ℝ) + 4 := by linarith - have hprod : (0 : ℝ) ≤ ((n : ℝ) - 1) * ((n : ℝ) + 2) * ((n : ℝ) + 4) := - mul_nonneg (mul_nonneg hN.le hN2.le) hN4.le have hD1 : (0 : ℝ) < (3 + α) * c 101 α ^ 4 * ((n : ℝ) - 1) * ((n : ℝ) + 2) * ((n : ℝ) + 4) := mul_pos (mul_pos (mul_pos (mul_pos h3 (pow_pos hc1 4)) hN) hN2) hN4 have hDle : (3 + α) * c 101 α ^ 4 * ((n : ℝ) - 1) * ((n : ℝ) + 2) * ((n : ℝ) + 4) ≤ (3 + α) * c n α ^ 4 * ((n : ℝ) - 1) * ((n : ℝ) + 2) * ((n : ℝ) + 4) := by - have hd : (0 : ℝ) ≤ (3 + α) * (c n α ^ 4 - c 101 α ^ 4) * - (((n : ℝ) - 1) * ((n : ℝ) + 2) * ((n : ℝ) + 4)) := - mul_nonneg (mul_nonneg h3.le (by linarith)) hprod - nlinarith [hd] + exact mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left hc4 h3.le) hN.le) + hN2.le) hN4.le -- step A: enlarge the denominator's `c` from `c n` down to `c 101` have stepA : T1 n α ≤ 24 * ((n : ℝ) - 1 - 2 * α) ^ 2 / @@ -340,7 +338,7 @@ theorem U_le_Ut (hn : 101 ≤ n) (hα : 0 ≤ α) (hα' : α ≤ 17) : U n α = (α / (3 + α)) ^ 48 * Real.sqrt (α / (3 + α)) := by rw [show (101 : ℕ) - 4 = 2 * 48 + 1 by norm_num, pow_succ, pow_mul, Real.sq_sqrt hB] rw [h97] - nlinarith [pow_nonneg hB 48] + exact mul_le_of_le_one_right (pow_nonneg hB 48) hb1 have e4 : T2 101 α ≤ (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * (α / (3 + α)) ^ 48 := by have hA101 : A 101 α = (100 - 2 * α) / 100 := by diff --git a/Sendov/Reduction/BetaBound.lean b/Sendov/Reduction/BetaBound.lean index ceb0809..fa2a099 100644 --- a/Sendov/Reduction/BetaBound.lean +++ b/Sendov/Reduction/BetaBound.lean @@ -46,27 +46,6 @@ lemma integral_exp_mul (hc : c ≠ 0) (a b : ℝ) : simp only [smul_eq_mul] field_simp -/-- The closed form of the integral in `(lt)`. -/ -lemma integral_exp_eq (hα : 0 < α) (hB : B < 2) : - (∫ t in (0 : ℝ)..1, exp (α * (-1 + (2 - B) * t))) - = exp (-(α * B / 2)) * (sinh (α * (2 - B) / 2) / (α * (2 - B) / 2)) := by - have hkpos : 0 < α * (2 - B) := by - have : 0 < 2 - B := by linarith - positivity - have hrw : ∀ t : ℝ, α * (-1 + (2 - B) * t) = -α + α * (2 - B) * t := by - intro t; ring - simp only [hrw, Real.exp_add] - rw [intervalIntegral.integral_const_mul, integral_exp_mul hkpos.ne' 0 1] - simp only [mul_zero, Real.exp_zero] - have hEF : exp (-(α * B / 2)) = exp (-α) * exp (α * (2 - B) / 2) := by - rw [← Real.exp_add]; congr 1; ring - have hsq : exp (α * (2 - B) * 1) = exp (α * (2 - B) / 2) * exp (α * (2 - B) / 2) := by - rw [← Real.exp_add]; congr 1; ring - have hneg : exp (-(α * (2 - B) / 2)) = (exp (α * (2 - B) / 2))⁻¹ := Real.exp_neg _ - have hF : exp (α * (2 - B) / 2) ≠ 0 := (Real.exp_pos _).ne' - rw [Real.sinh_eq, hEF, hsq, hneg] - field_simp - /-- The same integral, in the form the logarithmic half of `(beta-bound)` uses. -/ lemma integral_exp_eq' (hα : 0 < α) (hB : B < 2) : (∫ t in (0 : ℝ)..1, exp (α * (-1 + (2 - B) * t))) @@ -84,6 +63,21 @@ lemma integral_exp_eq' (hα : 0 < α) (hB : B < 2) : rw [← hsum] field_simp +/-- The closed form of the integral in `(lt)`. -/ +lemma integral_exp_eq (hα : 0 < α) (hB : B < 2) : + (∫ t in (0 : ℝ)..1, exp (α * (-1 + (2 - B) * t))) + = exp (-(α * B / 2)) * (sinh (α * (2 - B) / 2) / (α * (2 - B) / 2)) := by + -- Evaluate once in endpoint form, then center the two exponentials for `sinh`. + rw [integral_exp_eq' hα hB, Real.sinh_eq] + have hplus : exp (α * (1 - B)) = + exp (-(α * B / 2)) * exp (α * (2 - B) / 2) := by + rw [← Real.exp_add]; congr 1; ring + have hminus : exp (-α) = + exp (-(α * B / 2)) / exp (α * (2 - B) / 2) := by + rw [← Real.exp_sub]; congr 1; ring + rw [hplus, hminus, Real.exp_neg (α * (2 - B) / 2)] + field_simp + /-- `(lt)` forces `B < 2`: otherwise the integrand never exceeds `e^{-α} < 1`. -/ lemma beta_lt_two (hα : 0 < α) (hlt : 1 ≤ ∫ t in (0 : ℝ)..1, exp (α * (-1 + (2 - B) * t))) : B < 2 := by diff --git a/Sendov/Reduction/Simplified.lean b/Sendov/Reduction/Simplified.lean index b2815a5..5b7199a 100644 --- a/Sendov/Reduction/Simplified.lean +++ b/Sendov/Reduction/Simplified.lean @@ -141,9 +141,12 @@ lemma integral_beta_split (hn : 5 ≤ n) (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 ((hc2.add hc3).intervalIntegrable _ _) ?_ intro u hu have h := beta_split hn ha ha1 hx hu.1 hu.2 - have hu0 : (0 : ℝ) ≤ u := hu.1 - nlinarith [h, hu0, Real.rpow_nonneg (QQ_nonneg (by nlinarith [sq_nonneg a] : - (a * x) ^ 2 ≤ a ^ 2) u) (((n : ℝ) - 4) / 2)] + -- Multiply the pointwise split by the nonnegative integration weight. + calc _ ≤ u * ((1 - a * x * u) ^ ((n : ℝ) - 2) + + ((n : ℝ) - 2) / 2 * (a ^ 2 * u ^ 2 * (1 - x ^ 2)) + * QQ (a * x) (a ^ 2) u ^ (((n : ℝ) - 4) / 2)) := + mul_le_mul_of_nonneg_left h hu.1 + _ = _ := by ring refine hstep.trans ?_ rw [intervalIntegral.integral_const_mul] gcongr @@ -245,23 +248,13 @@ theorem one_le_of_origin (hn : 5 ≤ n) (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 linarith [horigin, hkey, hinv', hfirst, hlast, hax_eq] -- divide by `2α` have h2α : (0 : ℝ) < 2 * α := by linarith + -- Divide the assembled inequality once; normalize all five terms together. + have hscaled := div_le_div_of_nonneg_right hmain h2α.le have hne : (1 : ℝ) - B1 ≠ 0 := by linarith - have h1 : 2 * α * (B1 / (2 * α * (1 - B1))) = B1 / (1 - B1) := by - field_simp - have h2 : 2 * α * (B1 / (4 * α)) = B1 / 2 := by - field_simp - ring - have h3 : 2 * α * (1 / (2 * M n)) = α / M n := by - field_simp - have h4 : 2 * α * (B1 / (4 * α * M n)) = B1 / (2 * M n) := by - field_simp - ring - have h5 : 2 * α * ((a ^ 2) ^ 2 * (n : ℝ) * M n * ((n : ℝ) - 2) * B1 / (4 * α) * I3) - = (a ^ 2) ^ 2 * (n : ℝ) * M n * ((n : ℝ) - 2) * B1 / 2 * I3 := by - field_simp + convert hscaled using 1 + · rfl + · exact (div_self h2α.ne').symm + · field_simp ring - refine le_of_mul_le_mul_left ?_ h2α - rw [mul_one, mul_add, mul_add, mul_add, mul_add, h1, h2, h3, h4, h5] - exact hmain end Sendov diff --git a/Sendov/Reduction/Stat.lean b/Sendov/Reduction/Stat.lean index 9f2af43..b500597 100644 --- a/Sendov/Reduction/Stat.lean +++ b/Sendov/Reduction/Stat.lean @@ -95,8 +95,9 @@ theorem stat_of_one_le (hn : 5 ≤ n) (hx : x ^ 2 ≤ 1) rw [div_le_div_iff₀ (by linarith) (by linarith)] nlinarith [hkey] have t4 : B1 / (4 * α * M n) ≤ 1 / (4 * M n * (3 + α)) := by - rw [div_le_div_iff₀ (by positivity) (by positivity)] - nlinarith [hkey, hM] + -- This is the same scalar bound as `t2`, divided by the positive `M`. + simpa only [div_div, mul_assoc, mul_comm, mul_left_comm] using + div_le_div_of_nonneg_right t2 hM.le -- the integral term have hcle : c n α ≤ a * x := c_le_mul hn2 hα hα0 hbeta have hr : (0 : ℝ) ≤ ((n : ℝ) - 4) / 2 := by @@ -119,17 +120,12 @@ theorem stat_of_one_le (hn : 5 ≤ n) (hx : x ^ 2 ≤ 1) * ∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ (((n : ℝ) - 4) / 2) := by have hcoef : (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) * B1 / (4 * α) ≤ A n α ^ 2 * n * M n * ((n : ℝ) - 2) / (4 * (3 + α)) := by - rw [hA, div_le_div_iff₀ (by linarith) (by linarith)] - nlinarith [hkey, hpre] - have hstep1 : (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) * B1 / (4 * α) - * (∫ t in (0 : ℝ)..1, t ^ 3 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 4) / 2)) - ≤ A n α ^ 2 * n * M n * ((n : ℝ) - 2) / (4 * (3 + α)) - * (∫ t in (0 : ℝ)..1, t ^ 3 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 4) / 2)) := - mul_le_mul_of_nonneg_right hcoef hInn - refine hstep1.trans ?_ + rw [hA] + simpa only [← mul_div_assoc, mul_one] using mul_le_mul_of_nonneg_left t2 hpre have hcnn : (0 : ℝ) ≤ A n α ^ 2 * n * M n * ((n : ℝ) - 2) / (4 * (3 + α)) := by rw [hA]; positivity - refine mul_le_mul_of_nonneg_left ?_ hcnn + -- Both the coefficient and the integral increase under the substitution. + apply mul_le_mul hcoef ?_ hInn hcnn simpa only [Q_eq_QQ, hA] using hI rw [R] linarith diff --git a/scripts/emit_batch.py b/scripts/emit_batch.py index 9ae6570..f3f8f2f 100644 --- a/scripts/emit_batch.py +++ b/scripts/emit_batch.py @@ -32,6 +32,7 @@ def poly(cs, var="α"): -/ import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge +import Sendov.Common.BernsteinCert /-! # The batch {n0} to {n1} @@ -117,14 +118,9 @@ def Nmomc : List ℤ := have hu : (0 : ℝ) ≤ {LIN0} := by linarith have hid : ({up} : ℝ) ^ {d} * ({P}) = {bern} := by ring - -- All coefficients are checked by positivity. The last summand is positive for α > 0; + -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < ({up} : ℝ) ^ {d})).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · have hu_pos : (0 : ℝ) < {LIN0} := by linarith - positivity + bernstein_cert α {LIN} using hid set_option maxHeartbeats 2000000 in -- clearing denominators across the batch identity exceeds the default budget @@ -155,8 +151,7 @@ def Nmomc : List ℤ := ring rw [hid] at hb have hP := P_pos hα hUn - have hq : 0 < ({P}) / ({const} * (3 + α) ^ {p}) := div_pos hP (by positivity) - linarith + exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) end B{n0}_{n1} diff --git a/scripts/gen_endgame.py b/scripts/gen_endgame.py index 45dd34c..1577560 100644 --- a/scripts/gen_endgame.py +++ b/scripts/gen_endgame.py @@ -85,14 +85,7 @@ def poly(cs, var="α"): bern = " + ".join((f"{G[0]} * (17 - α) ^ {d}" if m == 0 else f"{G[d]} * α ^ {d}" if m == d else f"{G[m]} * α ^ {m} * (17 - α) ^ {d-m}") for m in range(d+1)) -haves = "\n".join( - (f" have h{m} : (0:ℝ) ≤ {G[0]} * (17 - α) ^ {d} :=\n" - f" mul_nonneg (by norm_num) (pow_nonneg hu {d})" if m == 0 else - f" have h{m} : (0:ℝ) ≤ {G[d]} * α ^ {d} :=\n" - f" mul_nonneg (by norm_num) (pow_nonneg hα {d})" if m == d else - f" have h{m} : (0:ℝ) ≤ {G[m]} * α ^ {m} * (17 - α) ^ {d-m} :=\n" - f" mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα {m})) (pow_nonneg hu {d-m})") - for m in range(d+1)) + src = f'''/- Copyright (c) 2026 Terence Tao. All rights reserved. @@ -100,6 +93,7 @@ def poly(cs, var="α"): Authors: Terence Tao -/ import Sendov.LargeDegree.Monotone +import Sendov.Common.BernsteinCert /-! # The large-degree claim @@ -149,16 +143,9 @@ def poly(cs, var="α"): lemma F_pos (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < {P} := by have hu : (0 : ℝ) ≤ 17 - α := by linarith -{haves} have hid : (17 : ℝ) ^ {d} * ({P}) = {bern} := by ring - rcases le_total α (17 / 2) with h | h - · have hpos : (0 : ℝ) < {G[0]} * (17 - α) ^ {d} := - mul_pos (by norm_num) (pow_pos (by linarith) {d}) - linarith - · have hpos : (0 : ℝ) < {G[d]} * α ^ {d} := - mul_pos (by norm_num) (pow_pos (by linarith) {d}) - linarith + bernstein_cert α (17 - α) using hid set_option maxHeartbeats 4000000 in /-- **The bound in `α` alone is below `1`.** -/ diff --git a/scripts/gen_sinh.py b/scripts/gen_sinh.py index 5557467..1cbf83f 100644 --- a/scripts/gen_sinh.py +++ b/scripts/gen_sinh.py @@ -65,14 +65,10 @@ def poly_str(cs, var="y"): steps.append(f''' private lemma step{j} (y : ℝ) (hy : 0 ≤ y) : 0 ≤ Sf {args(j)} y := by - refine nonneg_of_deriv (g := Sf {args(j+1)}) - (fun z => ?_) ?_ step{j+1} hy - · have h := hasDerivAt_Sf {args(j)} z - refine h.congr_deriv ?_ - simp only [Sf] - ring - · simp only [Sf] - norm_num''') + refine nonneg_Sf_of_deriv (by norm_num) ?_ hy + intro z hz + convert step{j+1} z hz using 1 + norm_num''') src = f'''/- Copyright (c) 2026 Terence Tao. All rights reserved. @@ -136,34 +132,23 @@ def poly_str(cs, var="y"): namespace Sendov -open Real +open Real Set Filter /-- `f` vanishes at `0` and has nonnegative derivative on `[0,∞)`, hence is nonnegative there. -/ private lemma nonneg_of_deriv {{f g : ℝ → ℝ}} (hd : ∀ z, HasDerivAt f (g z) z) (h0 : f 0 = 0) (hg : ∀ z, 0 ≤ z → 0 ≤ g z) {{y : ℝ}} (hy : 0 ≤ y) : 0 ≤ f y := by - have hmono : MonotoneOn f (Set.Ici 0) := by + have hmono : MonotoneOn f (Ici 0) := by refine monotoneOn_of_deriv_nonneg (convex_Ici 0) (fun z _ => (hd z).continuousAt.continuousWithinAt) (fun z hz => (hd z).differentiableAt.differentiableWithinAt) (fun z hz => ?_) rw [(hd z).deriv] rw [interior_Ici] at hz exact hg z (le_of_lt hz) - have := hmono (Set.mem_Ici.2 le_rfl) (Set.mem_Ici.2 hy) hy - rwa [h0] at this + simpa [h0] using hmono (mem_Ici.2 le_rfl) (mem_Ici.2 hy) hy /-- `1 + y + y²/2 ≤ exp y` for `y ≥ 0`: three terms of the exponential series. -/ -private lemma quad_le_exp {{y : ℝ}} (hy : 0 ≤ y) : 1 + y + y ^ 2 / 2 ≤ exp y := by - have key : ∀ z : ℝ, 0 ≤ z → 0 ≤ exp z - 1 - z - z ^ 2 / 2 := by - intro z hz - refine nonneg_of_deriv (f := fun t => exp t - 1 - t - t ^ 2 / 2) - (g := fun t => exp t - 1 - t) (fun t => ?_) (by norm_num) (fun t ht => ?_) hz - · have h := (((Real.hasDerivAt_exp t).sub_const 1).sub (hasDerivAt_id' t)).sub - ((hasDerivAt_pow 2 t).div_const 2) - refine h.congr_deriv ?_ - norm_num - · have := Real.add_one_le_exp t - linarith - linarith [key y hy] +private lemma quad_le_exp {{y : ℝ}} (hy : 0 ≤ y) : 1 + y + y ^ 2 / 2 ≤ exp y := + Real.quadratic_le_exp_of_nonneg hy /-- The family closed under differentiation: `e^{{2y}} u(y) - e^y v(y) - w(y)` with `u`, `w` cubic and `v` quartic. -/ @@ -178,11 +163,9 @@ def poly_str(cs, var="y"): v₄ (v₃ + 4 * v₄) (v₂ + 3 * v₃) (v₁ + 2 * v₂) (v₀ + v₁) 0 (3 * w₃) (2 * w₂) w₁ y) y := by simp only [Sf] - have he2 : HasDerivAt (fun t : ℝ => exp (2 * t)) (exp (2 * y) * 2) y := by - have h := ((hasDerivAt_id' y).const_mul (2 : ℝ)).exp - refine h.congr_deriv ?_ - ring - have he1 : HasDerivAt (fun t : ℝ => exp t) (exp y) y := Real.hasDerivAt_exp y + have he2 : HasDerivAt (fun t : ℝ => exp (2 * t)) (exp (2 * y) * 2) y := + ((hasDerivAt_id' y).const_mul (2 : ℝ)).exp.congr_deriv (by ring) + have he1 : HasDerivAt (fun t : ℝ => exp t) (exp y) y := hasDerivAt_exp y have hu : HasDerivAt (fun t : ℝ => u₃ * t ^ 3 + u₂ * t ^ 2 + u₁ * t + u₀) (3 * u₃ * y ^ 2 + 2 * u₂ * y + u₁) y := by have h := ((((hasDerivAt_pow 3 y).const_mul u₃).add @@ -205,30 +188,38 @@ def poly_str(cs, var="y"): refine h.congr_deriv ?_ norm_num ring - have h := ((he2.mul hu).sub (he1.mul hv)).sub hw - refine h.congr_deriv ?_ - ring + exact (((he2.mul hu).sub (he1.mul hv)).sub hw).congr_deriv (by ring) + +/-- One step of the derivative descent for `Sf`: its value at zero is `u₀ - v₀ - w₀`, +and its derivative stays in the same family. This packages the analytic argument once; +the numbered steps below only check the coefficient recurrence. -/ +private lemma nonneg_Sf_of_deriv + {{u₃ u₂ u₁ u₀ v₄ v₃ v₂ v₁ v₀ w₃ w₂ w₁ w₀ : ℝ}} + (h0 : u₀ - v₀ - w₀ = 0) + (hd : ∀ z, 0 ≤ z → + 0 ≤ Sf (2 * u₃) (2 * u₂ + 3 * u₃) (2 * u₁ + 2 * u₂) (2 * u₀ + u₁) + v₄ (v₃ + 4 * v₄) (v₂ + 3 * v₃) (v₁ + 2 * v₂) (v₀ + v₁) + 0 (3 * w₃) (2 * w₂) w₁ z) + {{y : ℝ}} (hy : 0 ≤ y) : 0 ≤ Sf u₃ u₂ u₁ u₀ v₄ v₃ v₂ v₁ v₀ w₃ w₂ w₁ w₀ y := by + exact nonneg_of_deriv (hasDerivAt_Sf u₃ u₂ u₁ u₀ v₄ v₃ v₂ v₁ v₀ w₃ w₂ w₁ w₀) + (by simpa [Sf] using h0) hd hy /-- The base of the induction, `Φ⁽⁸⁾ ≥ 0`. Three terms of the exponential series leave a polynomial with every coefficient positive. -/ private lemma step8 (y : ℝ) (hy : 0 ≤ y) : 0 ≤ Sf {args(8)} y := by - have hA : (0 : ℝ) ≤ 256 * y ^ 3 + 512 * y ^ 2 - 512 * y + 2560 := by + have : (1 + y + y ^ 2 / 2) * (256 * y ^ 3 + 512 * y ^ 2 - 512 * y + 2560) + ≤ exp y * (256 * y ^ 3 + 512 * y ^ 2 - 512 * y + 2560) := by + grw [quad_le_exp hy] nlinarith [sq_nonneg (y - 1), pow_nonneg hy 3, sq_nonneg y] - have h1 : (1 + y + y ^ 2 / 2) * (256 * y ^ 3 + 512 * y ^ 2 - 512 * y + 2560) - ≤ exp y * (256 * y ^ 3 + 512 * y ^ 2 - 512 * y + 2560) := - mul_le_mul_of_nonneg_right (quad_le_exp hy) hA - have h2 : (0 : ℝ) ≤ {poly_str(bc)} := by + have : (0 : ℝ) ≤ {poly_str(bc)} := by nlinarith [pow_nonneg hy 5, pow_nonneg hy 4, pow_nonneg hy 3, sq_nonneg y, hy] have h3 : (0 : ℝ) ≤ exp y * (256 * y ^ 3 + 512 * y ^ 2 - 512 * y + 2560) - - ({poly_str(rows[8][1])}) := by - nlinarith [h1, h2] - have hexp : exp (2 * y) = exp y * exp y := by rw [two_mul, Real.exp_add] - have h4 := mul_nonneg (Real.exp_pos y).le h3 - calc (0 : ℝ) ≤ exp y * (exp y * (256 * y ^ 3 + 512 * y ^ 2 - 512 * y + 2560) - - ({poly_str(rows[8][1])})) := h4 - _ = Sf {args(8)} y := by - simp only [Sf, hexp] + - ({poly_str(rows[8][1])}) := by nlinarith + calc + _ ≤ _ := mul_nonneg (exp_pos y).le h3 + _ = _ := by + simp only [Sf, two_mul, exp_add] ring {"".join(steps)} @@ -236,13 +227,10 @@ def poly_str(cs, var="y"): private lemma Sf_eq (h : ℝ) : Sf {args(0)} (2 * h) = 16 * exp h ^ 2 * (h ^ 4 * sinh h ^ 2 - (h ^ 2 + 9) * (h * cosh h - sinh h) ^ 2) := by - have hE : exp h ≠ 0 := (Real.exp_pos h).ne' - have e4 : exp (2 * (2 * h)) = exp h ^ 4 := by - rw [show (2 : ℝ) * (2 * h) = h + h + h + h by ring, Real.exp_add, Real.exp_add, Real.exp_add] - ring - have e2 : exp (2 * h) = exp h ^ 2 := by - rw [show (2 : ℝ) * h = h + h by ring, Real.exp_add]; ring - simp only [Sf, Real.sinh_eq, Real.cosh_eq, e4, e2, Real.exp_neg] + have : exp h ≠ 0 := (exp_pos h).ne' + have e4 : exp (2 * (2 * h)) = exp h ^ 4 := by simp [←exp_nat_mul]; ring + have e2 : exp (2 * h) = exp h ^ 2 := by simp [←exp_nat_mul] + simp only [Sf, sinh_eq, cosh_eq, e4, e2, exp_neg] field_simp ring @@ -251,17 +239,21 @@ def poly_str(cs, var="y"): (h ^ 2 + 9) * (h * cosh h - sinh h) ^ 2 ≤ h ^ 4 * sinh h ^ 2 := by have h0 := step0 (2 * h) (by linarith) rw [Sf_eq] at h0 - have hpos : (0 : ℝ) < 16 * exp h ^ 2 := by positivity - by_contra hc - push_neg at hc - nlinarith [h0, hpos, hc] + have : (0 : ℝ) < 16 * exp h ^ 2 := by positivity + nlinarith end Sendov ''' # The analytic tail carries no generated data, and contains brace characters that an # f-string would swallow, so it is kept beside this script rather than inlined. +from pathlib import Path +import argparse + +parser = argparse.ArgumentParser(description="Emit Sinh.lean from the symbolic derivative recurrence") +parser.add_argument("--output", type=Path, default=Path("Sinh.lean")) +options = parser.parse_args() src = src.replace("\nend Sendov\n", "\n") + io.open( - "sinh_tail.lean.txt", encoding="utf-8").read() -io.open(r"c:/Users/teort/Github/sendov/Sendov/Common/Sinh.lean", "w", + Path(__file__).with_name("sinh_tail.lean.txt"), encoding="utf-8").read() +io.open(options.output, "w", encoding="utf-8", newline="\n").write(src) print(f"written Sinh.lean, {len(src)} bytes") diff --git a/scripts/sinh_tail.lean.txt b/scripts/sinh_tail.lean.txt index fbbd4af..c6a2af8 100644 --- a/scripts/sinh_tail.lean.txt +++ b/scripts/sinh_tail.lean.txt @@ -1,119 +1,91 @@ /-- `sinh h ≤ h cosh h` for `h ≥ 0`; equivalently `h cosh h - sinh h ≥ 0`, which is what makes the square root below legitimate. -/ private lemma sinh_le_mul_cosh {h : ℝ} (hh : 0 ≤ h) : sinh h ≤ h * cosh h := by - have key : ∀ z : ℝ, 0 ≤ z → 0 ≤ z * cosh z - sinh z := by - intro z hz + have : 0 ≤ h * cosh h - sinh h := by refine nonneg_of_deriv (f := fun t => t * cosh t - sinh t) (g := fun t => t * sinh t) - (fun t => ?_) (by simp) (fun t ht => mul_nonneg ht (Real.sinh_nonneg_iff.2 ht)) hz - have h := ((hasDerivAt_id' t).mul (Real.hasDerivAt_cosh t)).sub (Real.hasDerivAt_sinh t) - refine h.congr_deriv ?_ - ring - linarith [key h hh] + (fun t => ?_) (by simp) (fun t ht => mul_nonneg ht (sinh_nonneg_iff.2 ht)) hh + exact (((hasDerivAt_id' t).mul (hasDerivAt_cosh t)).sub (hasDerivAt_sinh t)).congr_deriv + (by ring) + linarith /-- `√(h²+9) (h cosh h - sinh h) ≤ h² sinh h`: the square root of `Sendov.sinh_sq_le`, which is the derivative inequality `coth h - 1/h ≤ h/√(h²+9)` cleared of denominators. -/ theorem sqrt_mul_sub_le {h : ℝ} (hh : 0 ≤ h) : - Real.sqrt (h ^ 2 + 9) * (h * cosh h - sinh h) ≤ h ^ 2 * sinh h := by - have hd : (0 : ℝ) ≤ h * cosh h - sinh h := by linarith [sinh_le_mul_cosh hh] - have hs : (0 : ℝ) ≤ h ^ 2 * sinh h := mul_nonneg (sq_nonneg h) (Real.sinh_nonneg_iff.2 hh) - have hroot : Real.sqrt (h ^ 2 + 9) ^ 2 = h ^ 2 + 9 := Real.sq_sqrt (by positivity) - have hl : (0 : ℝ) ≤ Real.sqrt (h ^ 2 + 9) * (h * cosh h - sinh h) := - mul_nonneg (Real.sqrt_nonneg _) hd - have hsq : (Real.sqrt (h ^ 2 + 9) * (h * cosh h - sinh h)) ^ 2 ≤ (h ^ 2 * sinh h) ^ 2 := by - calc (Real.sqrt (h ^ 2 + 9) * (h * cosh h - sinh h)) ^ 2 - = (h ^ 2 + 9) * (h * cosh h - sinh h) ^ 2 := by rw [mul_pow, hroot] - _ ≤ h ^ 4 * sinh h ^ 2 := sinh_sq_le hh - _ = (h ^ 2 * sinh h) ^ 2 := by ring - nlinarith [hsq, hl, hs] + sqrt (h ^ 2 + 9) * (h * cosh h - sinh h) ≤ h ^ 2 * sinh h := by + have : (0 : ℝ) ≤ h ^ 2 * sinh h := mul_nonneg (sq_nonneg h) (sinh_nonneg_iff.2 hh) + have : (0 : ℝ) ≤ sqrt (h ^ 2 + 9) * (h * cosh h - sinh h) := + mul_nonneg (sqrt_nonneg _) (by linarith [sinh_le_mul_cosh hh]) + have : (sqrt (h ^ 2 + 9) * (h * cosh h - sinh h)) ^ 2 ≤ (h ^ 2 * sinh h) ^ 2 := by + convert sinh_sq_le hh + · rw [mul_pow, sq_sqrt (by positivity)] + · ring + nlinarith /-- **The sharp bound.** This is `(lsh)` of the blog post. -/ theorem log_sinh_div_le {h : ℝ} (hh : 0 < h) : - Real.log (sinh h / h) ≤ Real.sqrt (h ^ 2 + 9) - 3 := by - set ψ : ℝ → ℝ := fun z => Real.sqrt (z ^ 2 + 9) - 3 - (Real.log (sinh z) - Real.log z) with hψdef + log (sinh h / h) ≤ sqrt (h ^ 2 + 9) - 3 := by + set ψ : ℝ → ℝ := fun z => sqrt (z ^ 2 + 9) - 3 - (log (sinh z) - log z) with hψdef -- `ψ` has nonnegative derivative on `(0,∞)` have hderiv : ∀ z : ℝ, 0 < z → - HasDerivAt ψ (z / Real.sqrt (z ^ 2 + 9) - (cosh z / sinh z - 1 / z)) z := by + HasDerivAt ψ (z / sqrt (z ^ 2 + 9) - (cosh z / sinh z - 1 / z)) z := by intro z hz - have hs9 : (0 : ℝ) < z ^ 2 + 9 := by positivity - have hsq : Real.sqrt (z ^ 2 + 9) ≠ 0 := by positivity - have hsinh : sinh z ≠ 0 := ne_of_gt (Real.sinh_pos_iff.2 hz) - have h1 : HasDerivAt (fun t : ℝ => Real.sqrt (t ^ 2 + 9) - 3) - (z / Real.sqrt (z ^ 2 + 9)) z := by - have h := (((hasDerivAt_pow 2 z).add_const 9).sqrt (ne_of_gt hs9)).sub_const 3 + have hsinh : sinh z ≠ 0 := ne_of_gt (sinh_pos_iff.2 hz) + apply HasDerivAt.sub + · have h := (((hasDerivAt_pow 2 z).add_const 9).sqrt (ne_of_gt (by positivity))).sub_const 3 refine h.congr_deriv ?_ field_simp ring - have h2 : HasDerivAt (fun t : ℝ => Real.log (sinh t) - Real.log t) - (cosh z / sinh z - 1 / z) z := by - have ha := (Real.hasDerivAt_sinh z).log hsinh - have hb := (hasDerivAt_id' z).log (ne_of_gt hz) - have h := ha.sub hb - refine h.congr_deriv ?_ - field_simp - exact h1.sub h2 - have hmono : MonotoneOn ψ (Set.Ioi 0) := by + · exact (((hasDerivAt_sinh z).log hsinh).sub + ((hasDerivAt_id' z).log (ne_of_gt hz))).congr_deriv (by field_simp) + have hmono : MonotoneOn ψ (Ioi 0) := by refine monotoneOn_of_deriv_nonneg (convex_Ioi 0) (fun z hz => (hderiv z hz).continuousAt.continuousWithinAt) (fun z hz => (hderiv z (by rwa [interior_Ioi] at hz)).differentiableAt.differentiableWithinAt) (fun z hz => ?_) - rw [interior_Ioi] at hz - have hz0 : (0 : ℝ) < z := hz - rw [(hderiv z hz0).deriv] - have hsinh : (0 : ℝ) < sinh z := Real.sinh_pos_iff.2 hz0 - have hsq : (0 : ℝ) < Real.sqrt (z ^ 2 + 9) := by positivity - rw [sub_nonneg, div_sub_div _ _ (ne_of_gt hsinh) (ne_of_gt hz0), - div_le_div_iff₀ (by positivity) hsq] - have := sqrt_mul_sub_le (le_of_lt hz0) - nlinarith [this, hsq, hsinh, hz0] + rw [interior_Ioi, mem_Ioi] at hz + rw [(hderiv z hz).deriv, sub_nonneg, div_sub_div _ _ (ne_of_gt (sinh_pos_iff.2 hz)) + (ne_of_gt hz), div_le_div_iff₀ (by positivity) (by positivity)] + nlinarith [sqrt_mul_sub_le (le_of_lt hz)] -- `ψ → 0` as `z → 0⁺` - have hslope : Filter.Tendsto (fun z : ℝ => sinh z / z) (nhdsWithin 0 {(0 : ℝ)}ᶜ) (nhds 1) := by - have h := Real.hasDerivAt_sinh 0 - rw [hasDerivAt_iff_tendsto_slope] at h - simpa [slope_fun_def, Real.sinh_zero, Real.cosh_zero, div_eq_inv_mul] using h - have hlog : Filter.Tendsto ψ (nhdsWithin 0 (Set.Ioi 0)) (nhds 0) := by - have hsub : nhdsWithin (0 : ℝ) (Set.Ioi 0) ≤ nhdsWithin 0 {(0 : ℝ)}ᶜ := + have hslope : Tendsto (fun z => sinh z / z) (nhdsWithin 0 {(0 : ℝ)}ᶜ) (nhds 1) := by + simpa [slope_fun_def, div_eq_inv_mul, hasDerivAt_iff_tendsto_slope] using hasDerivAt_sinh 0 + have hlog : Tendsto ψ (nhdsWithin 0 (Ioi 0)) (nhds 0) := by + have hsub : nhdsWithin (0 : ℝ) (Ioi 0) ≤ nhdsWithin 0 {(0 : ℝ)}ᶜ := nhdsWithin_mono _ (fun z hz => ne_of_gt hz) - have h1 : Filter.Tendsto (fun z : ℝ => Real.log (sinh z / z)) - (nhdsWithin 0 (Set.Ioi 0)) (nhds 0) := by - have := (Real.continuousAt_log one_ne_zero).tendsto.comp (hslope.mono_left hsub) - simpa [Function.comp_def] using this - have h2 : Filter.Tendsto (fun z : ℝ => Real.sqrt (z ^ 2 + 9) - 3) - (nhdsWithin 0 (Set.Ioi 0)) (nhds 0) := by - have h9 : Real.sqrt (9 : ℝ) = 3 := by - rw [show (9 : ℝ) = 3 ^ 2 by norm_num, Real.sqrt_sq (by norm_num : (0:ℝ) ≤ 3)] - have hc : ContinuousAt (fun z : ℝ => Real.sqrt (z ^ 2 + 9) - 3) 0 := by fun_prop - simpa [ContinuousWithinAt, h9] using hc.continuousWithinAt (s := Set.Ioi (0 : ℝ)) - have heq : ∀ᶠ z : ℝ in nhdsWithin 0 (Set.Ioi 0), - ψ z = (Real.sqrt (z ^ 2 + 9) - 3) - Real.log (sinh z / z) := by + have h1 : Tendsto (fun z => log (sinh z / z)) (nhdsWithin 0 (Ioi 0)) (nhds 0) := by + simpa [Function.comp_def] using (continuousAt_log one_ne_zero).tendsto.comp + (hslope.mono_left hsub) + have h2 : Tendsto (fun z : ℝ => sqrt (z ^ 2 + 9) - 3) + (nhdsWithin 0 (Ioi 0)) (nhds 0) := by + have h9 : sqrt (9 : ℝ) = 3 := by + rw [show (9 : ℝ) = 3 ^ 2 by norm_num, sqrt_sq (by norm_num : (0:ℝ) ≤ 3)] + have hc : ContinuousAt (fun z => sqrt (z ^ 2 + 9) - 3) 0 := by fun_prop + simpa [ContinuousWithinAt, h9] using hc.continuousWithinAt (s := Ioi (0 : ℝ)) + have heq : ∀ᶠ z : ℝ in nhdsWithin 0 (Ioi 0), + ψ z = (sqrt (z ^ 2 + 9) - 3) - log (sinh z / z) := by filter_upwards [self_mem_nhdsWithin] with z hz - have hz0 : (0 : ℝ) < z := hz - rw [hψdef] - rw [Real.log_div (ne_of_gt (Real.sinh_pos_iff.2 hz0)) (ne_of_gt hz0)] - rw [Filter.tendsto_congr' heq] - simpa using h2.sub h1 + rw [hψdef, log_div (ne_of_gt (sinh_pos_iff.2 hz)) (ne_of_gt hz)] + simpa [tendsto_congr' heq] using h2.sub h1 -- combine - have hev : ∀ᶠ z : ℝ in nhdsWithin 0 (Set.Ioi 0), ψ z ≤ ψ h := by - have hmem : Set.Ioo (0 : ℝ) h ∈ nhdsWithin (0 : ℝ) (Set.Ioi 0) := - mem_nhdsGT_iff_exists_Ioo_subset.2 (Exists.intro h (And.intro (Set.mem_Ioi.2 hh) subset_rfl)) + have hev : ∀ᶠ z : ℝ in nhdsWithin 0 (Ioi 0), ψ z ≤ ψ h := by + have hmem : Ioo (0 : ℝ) h ∈ nhdsWithin (0 : ℝ) (Ioi 0) := + mem_nhdsGT_iff_exists_Ioo_subset.2 (Exists.intro h (And.intro (mem_Ioi.2 hh) subset_rfl)) filter_upwards [hmem] with z hz - exact hmono (Set.mem_Ioi.2 hz.1) (Set.mem_Ioi.2 hh) (le_of_lt hz.2) + exact hmono (mem_Ioi.2 hz.1) (mem_Ioi.2 hh) (le_of_lt hz.2) have h0 : (0 : ℝ) ≤ ψ h := le_of_tendsto hlog hev - have hpos : (0 : ℝ) < sinh h / h := div_pos (Real.sinh_pos_iff.2 hh) hh + have : (0 : ℝ) < sinh h / h := div_pos (sinh_pos_iff.2 hh) hh rw [hψdef] at h0 - rw [Real.log_div (ne_of_gt (Real.sinh_pos_iff.2 hh)) (ne_of_gt hh)] + rw [log_div (ne_of_gt (sinh_pos_iff.2 hh)) (ne_of_gt hh)] linarith /-- The form in which the estimate is used: `sinh h ≤ h exp (√(h²+9) - 3)`. -/ theorem sinh_le_mul_exp {h : ℝ} (hh : 0 ≤ h) : - sinh h ≤ h * Real.exp (Real.sqrt (h ^ 2 + 9) - 3) := by + sinh h ≤ h * exp (sqrt (h ^ 2 + 9) - 3) := by rcases eq_or_lt_of_le hh with rfl | hpos · simp - · have hlog := log_sinh_div_le hpos - have hd : (0 : ℝ) < sinh h / h := div_pos (Real.sinh_pos_iff.2 hpos) hpos - have := (Real.log_le_iff_le_exp hd).1 hlog - calc sinh h = (sinh h / h) * h := by field_simp - _ ≤ Real.exp (Real.sqrt (h ^ 2 + 9) - 3) * h := - mul_le_mul_of_nonneg_right this (le_of_lt hpos) - _ = h * Real.exp (Real.sqrt (h ^ 2 + 9) - 3) := by ring + · have hd : (0 : ℝ) < sinh h / h := div_pos (sinh_pos_iff.2 hpos) hpos + grw [← (log_le_iff_le_exp hd).1 (log_sinh_div_le hpos)] + field_simp + simp end Sendov From 6d9ce8893cd6f1f1473b6f221e1de9958be3fe5c Mon Sep 17 00:00:00 2001 From: Methode Date: Sat, 12 Sep 2026 20:19:38 -0700 Subject: [PATCH 04/24] [verified] Share batch certificate interfaces and optimize polynomial identities --- Sendov/Common/BernsteinRing.lean | 83 +++++++++++++++++++ Sendov/FiniteRange/BatchCertificate.lean | 39 +++++++++ Sendov/FiniteRange/Degree10_11.lean | 37 +++------ Sendov/FiniteRange/Degree12_13.lean | 37 +++------ Sendov/FiniteRange/Degree14_15.lean | 37 +++------ Sendov/FiniteRange/Degree16_18.lean | 37 +++------ Sendov/FiniteRange/Degree18_20.lean | 37 +++------ Sendov/FiniteRange/Degree20_22.lean | 37 +++------ Sendov/FiniteRange/Degree22_24.lean | 37 +++------ Sendov/FiniteRange/Degree24_26.lean | 37 +++------ Sendov/FiniteRange/Degree26_27.lean | 37 +++------ Sendov/FiniteRange/Degree28_29.lean | 37 +++------ Sendov/FiniteRange/Degree30_31.lean | 37 +++------ Sendov/FiniteRange/Degree32_33.lean | 37 +++------ Sendov/FiniteRange/Degree34_35.lean | 37 +++------ Sendov/FiniteRange/Degree36_37.lean | 37 +++------ Sendov/FiniteRange/Degree38_39.lean | 37 +++------ Sendov/FiniteRange/Degree40_41.lean | 37 +++------ Sendov/FiniteRange/Degree42_43.lean | 37 +++------ Sendov/FiniteRange/Degree44_45.lean | 37 +++------ Sendov/FiniteRange/Degree46_47.lean | 37 +++------ Sendov/FiniteRange/Degree48_49.lean | 37 +++------ Sendov/FiniteRange/Degree50_51.lean | 37 +++------ Sendov/FiniteRange/Degree52_53.lean | 37 +++------ Sendov/FiniteRange/Degree54_55.lean | 37 +++------ Sendov/FiniteRange/Degree56_58.lean | 37 +++------ Sendov/FiniteRange/Degree58_60.lean | 37 +++------ Sendov/FiniteRange/Degree60_63.lean | 37 +++------ Sendov/FiniteRange/Degree64_69.lean | 37 +++------ Sendov/FiniteRange/Degree6_6.lean | 37 +++------ Sendov/FiniteRange/Degree70_79.lean | 37 +++------ Sendov/FiniteRange/Degree80_100.lean | 37 +++------ Sendov/FiniteRange/Degree8_9.lean | 37 +++------ .../FiniteRange/PackedMomentCertificate.lean | 42 ++++++++++ Sendov/LargeDegree/Endgame.lean | 43 ++++++---- scripts/emit_batch.py | 37 +++------ scripts/gen_endgame.py | 62 +++++++++----- 37 files changed, 650 insertions(+), 803 deletions(-) create mode 100644 Sendov/Common/BernsteinRing.lean create mode 100644 Sendov/FiniteRange/BatchCertificate.lean create mode 100644 Sendov/FiniteRange/PackedMomentCertificate.lean diff --git a/Sendov/Common/BernsteinRing.lean b/Sendov/Common/BernsteinRing.lean new file mode 100644 index 0000000..0f31f12 --- /dev/null +++ b/Sendov/Common/BernsteinRing.lean @@ -0,0 +1,83 @@ +/- +Copyright (c) 2026. All rights reserved. +Released under Apache 2.0 license as described in the file LICENSE. +Authors: Sendov contributors +-/ +import Mathlib.Tactic.Ring +import Mathlib.Data.Real.Basic + +/-! +# Bernstein identities through homogeneous Horner form + +`bernstein_ring x y` proves an equality whose right side is a homogeneous sum +of natural-coefficient monomials in `x` and `y`. It builds a Horner intermediate +in `y`, verifies the original left side against that intermediate with `ring1`, +and verifies the complete original right side after making `y` an independent +atom. The parser only suggests an intermediate: both equalities are proved by +Mathlib's proof-producing ring tactic. No evaluation point is used. +Coordinates must elaborate unambiguously in the goal's carrier; the supported +right side uses addition, multiplication, natural numerals and natural powers +of those two coordinates, with a common total degree. +-/ + +namespace Sendov.BernsteinRing + +open Lean Meta Elab Tactic + +private def binary? (e : Expr) (n : Name) : Option (Expr × Expr) := + if e.isAppOfArity n 6 then some (e.getArg! 4, e.getArg! 5) else none + +private partial def flatten (e : Expr) (op : Name) : Array Expr := + match binary? e op with + | some (a, b) => flatten a op ++ flatten b op + | none => #[e] + +private def numeral (n : Nat) : TSyntax `term := ⟨Syntax.mkNumLit (toString n)⟩ + +private def monomial (e x y : Expr) : TacticM (Nat × Nat × Nat) := do + let mut c := 1 + let mut i := 0 + let mut j := 0 + for f in flatten e ``HMul.hMul do + if ← isDefEq f x then i := i + 1 + else if ← isDefEq f y then j := j + 1 + else if f.isAppOfArity ``HPow.hPow 6 then + let some n ← getNatValue? (f.getArg! 5) + | throwError "bernstein_ring: expected natural exponent" + if ← isDefEq (f.getArg! 4) x then i := i + n + else if ← isDefEq (f.getArg! 4) y then j := j + n + else throwError "bernstein_ring: unsupported power base" + else if f.isAppOfArity ``OfNat.ofNat 3 then + let some n ← getNatValue? (f.getArg! 1) + | throwError "bernstein_ring: expected natural coefficient" + c := c * n + else throwError "bernstein_ring: unsupported monomial factor {f}" + return (c, i, j) + +/-- Verify the supplied equality through homogeneous Horner form; keep the statement intact. -/ +elab "bernstein_ring " x:term:max y:term:max : tactic => withMainContext do + let goal ← getMainGoal + let target ← instantiateMVars (← goal.getType) + let some (ty, _, rhs) := target.eq? + | throwError "bernstein_ring: expected equality" + let xe ← elabTerm x (some ty) + let ye ← elabTerm y (some ty) + let terms ← (flatten rhs ``HAdd.hAdd).mapM (monomial · xe ye) + let (_, i, j) := terms[0]! + let degree := i + j + let mut cs := Array.replicate (degree + 1) 0 + for (c, i, j) in terms do + unless i + j == degree do throwError "bernstein_ring: mixed total degrees" + cs := cs.modify i (· + c) + let mut h := numeral cs[0]! + -- After step i, h = ∑ k ≤ i, cs[k] * x^k * y^(i-k). + for i in [1:degree + 1] do + h ← `($h * $y + $(numeral cs[i]!) * $x ^ $(numeral i)) + evalTactic (← `(tactic| trans $h)) + focus do evalTactic (← `(tactic| ring1)) + focus do + let atom := mkIdent (← mkFreshUserName `bernsteinCoordinate) + evalTactic (← `(tactic| generalize $y = $atom)) + evalTactic (← `(tactic| ring1)) + +end Sendov.BernsteinRing diff --git a/Sendov/FiniteRange/BatchCertificate.lean b/Sendov/FiniteRange/BatchCertificate.lean new file mode 100644 index 0000000..7301723 --- /dev/null +++ b/Sendov/FiniteRange/BatchCertificate.lean @@ -0,0 +1,39 @@ +/- +Copyright (c) 2026 Terence Tao. All rights reserved. +Released under Apache 2.0 license as described in the file LICENSE. +Authors: Terence Tao +-/ +import Sendov.FiniteRange.Batch + +/-! +# From a batch moment and a positive deficit to `R < 1` + +The analytic batch bound and the supplied algebraic identity have different jobs. +This interface joins them without expanding the moment polynomial or its certificate. +The lower endpoint needs only `c ≥ 0`, not feasibility; feasibility remains at the +actual degree. Thus the same contract covers low-degree and large-degree batches. +-/ + +namespace Sendov + +/-- An integer moment at the lower endpoint and a positive deficit certify the whole +batch. `m₀` and `m₁` allow the caller's exact endpoint numerals in the supplied identity. +No sign assumption on the moment or on the numerator's individual coefficients is needed. +The denominator and the complete deficit must both be strictly positive. -/ +theorem R_lt_one_of_batch_certificate {n₀ n n₁ k : ℕ} {α m₀ m₁ I P D : ℝ} + (h0 : 5 ≤ n₀) (h1 : n₀ ≤ n) (h2 : n ≤ n₁) (hα : 0 ≤ α) + (hc0 : 0 ≤ c n₀ α) (hfeas : c n α ^ 2 ≤ A n α) + (hk : ((n₀ : ℝ) - 4) / 2 = (k : ℝ)) + (hM0 : M n₀ = m₀) (hM1 : M n₁ = m₁) + (hmoment : (∫ t in (0 : ℝ)..1, t ^ 3 * Q n₀ α t ^ k) = I) + (hcert : 1 / 6 + 1 / (4 * (3 + α)) + 1 / (2 * m₀) + + 1 / (4 * m₀ * (3 + α)) + + (1 - 2 * α / m₁) ^ 2 * n₁ * m₁ * ((n₁ : ℝ) - 2) + / (4 * (3 + α)) * I = 1 - P / D) + (hP : 0 < P) (hD : 0 < D) : R n α < 1 := by + have hb := R_le_batch h0 h1 h2 hα hc0 hfeas + simp only [hk, Real.rpow_natCast, hmoment, A, hM0, hM1] at hb + rw [hcert] at hb + exact hb.trans_lt (sub_lt_self _ (div_pos hP hD)) + +end Sendov diff --git a/Sendov/FiniteRange/Degree10_11.lean b/Sendov/FiniteRange/Degree10_11.lean index 5f6b46a..08dd71c 100644 --- a/Sendov/FiniteRange/Degree10_11.lean +++ b/Sendov/FiniteRange/Degree10_11.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 10 to 11 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 10) (gg1 10) (gg2 10) 3)) α := by - refine pev_wsum_eq_of_packed (gg0 10) (gg1 10) (gg2 10) 3 10 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 10) (gg1 10) (gg2 10) 3 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 10) (gg1 10) (gg2 10) 3 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 10) (gg1 10) (gg2 10) 3 (by simp) (by simp) (by simp) 3) - · rfl + refine pev_moment_eq_of_packed_bounds 10 3 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 10 α t ^ 3) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 5) : 0 < 32349375 + 39180105 * α + 10086687 * α ^ 2 - 24445935 * α ^ 3 + 11871036 * α ^ 4 - 351846 * α ^ 5 - 81598 * α ^ 6 - 4664 * α ^ 7 - 88 * α ^ 8 := by have hu : (0 : ℝ) ≤ 5 - α := by linarith have hid : (5 : ℝ) ^ 8 * (32349375 + 39180105 * α + 10086687 * α ^ 2 - 24445935 * α ^ 3 + 11871036 * α ^ 4 - 351846 * α ^ 5 - 81598 * α ^ 6 - 4664 * α ^ 7 - 88 * α ^ 8) = 32349375 * (5 - α) ^ 8 + 454695525 * α ^ 1 * (5 - α) ^ 7 + 2529253350 * α ^ 2 * (5 - α) ^ 6 + 4382737200 * α ^ 3 * (5 - α) ^ 5 + 5044170375 * α ^ 4 * (5 - α) ^ 4 + 11732079375 * α ^ 5 * (5 - α) ^ 3 + 18187642400 * α ^ 6 * (5 - α) ^ 2 + 11329113600 * α ^ 7 * (5 - α) ^ 1 + 2070835200 * α ^ 8 := by - ring + bernstein_ring α (5 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (5 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 10 ≤ n) (h1 : n ≤ 11) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (11 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (11 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 10) (n := n) (n₁ := 11) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((10 : ℕ) : ℝ) - 4 = 6 by norm_num] at hb - rw [show (6 : ℝ) / 2 = ((3 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 9) + 1 / (4 * 9 * (3 + α)) + (1 - 2 * α / 10) ^ 2 * 11 * 10 * (11 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 9 * (3 + α)) ^ 3)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 10 ≤ n) (h1 : n ≤ 11) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 10) (n₁ := 11) (k := 3) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B10_11 diff --git a/Sendov/FiniteRange/Degree12_13.lean b/Sendov/FiniteRange/Degree12_13.lean index d60bf3d..3a7b70a 100644 --- a/Sendov/FiniteRange/Degree12_13.lean +++ b/Sendov/FiniteRange/Degree12_13.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 12 to 13 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 12) (gg1 12) (gg2 12) 4)) α := by - refine pev_wsum_eq_of_packed (gg0 12) (gg1 12) (gg2 12) 4 13 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 12) (gg1 12) (gg2 12) 4 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 12) (gg1 12) (gg2 12) 4 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 12) (gg1 12) (gg2 12) 3 (by simp) (by simp) (by simp) 4) - · rfl + refine pev_moment_eq_of_packed_bounds 12 4 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 12 α t ^ 4) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 6) : 0 < 67214552328 + 108758874312 * α + 64248083658 * α ^ 2 + 8893434528 * α ^ 3 - 26471207052 * α ^ 4 + 9402730740 * α ^ 5 - 77587159 * α ^ 6 - 46242248 * α ^ 7 - 3634800 * α ^ 8 - 118976 * α ^ 9 - 1456 * α ^ 10 := by have hu : (0 : ℝ) ≤ 6 - α := by linarith have hid : (6 : ℝ) ^ 10 * (67214552328 + 108758874312 * α + 64248083658 * α ^ 2 + 8893434528 * α ^ 3 - 26471207052 * α ^ 4 + 9402730740 * α ^ 5 - 77587159 * α ^ 6 - 46242248 * α ^ 7 - 3634800 * α ^ 8 - 118976 * α ^ 9 - 1456 * α ^ 10) = 67214552328 * (6 - α) ^ 10 + 1324698769152 * α ^ 1 * (6 - α) ^ 9 + 11210565079296 * α ^ 2 * (6 - α) ^ 8 + 51982093082304 * α ^ 3 * (6 - α) ^ 7 + 112831785636336 * α ^ 4 * (6 - α) ^ 6 + 136300060037952 * α ^ 5 * (6 - α) ^ 5 + 172834300408608 * α ^ 6 * (6 - α) ^ 4 + 277236880276032 * α ^ 7 * (6 - α) ^ 3 + 281516219316936 * α ^ 8 * (6 - α) ^ 2 + 131510134768320 * α ^ 9 * (6 - α) ^ 1 + 19805743188000 * α ^ 10 := by - ring + bernstein_ring α (6 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (6 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 12 ≤ n) (h1 : n ≤ 13) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (13 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (13 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 12) (n := n) (n₁ := 13) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((12 : ℕ) : ℝ) - 4 = 8 by norm_num] at hb - rw [show (8 : ℝ) / 2 = ((4 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 11) + 1 / (4 * 11 * (3 + α)) + (1 - 2 * α / 12) ^ 2 * 13 * 12 * (13 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 11 * (3 + α)) ^ 4)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 12 ≤ n) (h1 : n ≤ 13) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 12) (n₁ := 13) (k := 4) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B12_13 diff --git a/Sendov/FiniteRange/Degree14_15.lean b/Sendov/FiniteRange/Degree14_15.lean index 1cebbe2..f054c05 100644 --- a/Sendov/FiniteRange/Degree14_15.lean +++ b/Sendov/FiniteRange/Degree14_15.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 14 to 15 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 14) (gg1 14) (gg2 14) 5)) α := by - refine pev_wsum_eq_of_packed (gg0 14) (gg1 14) (gg2 14) 5 16 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 14) (gg1 14) (gg2 14) 5 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 14) (gg1 14) (gg2 14) 5 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 14) (gg1 14) (gg2 14) 3 (by simp) (by simp) (by simp) 5) - · rfl + refine pev_moment_eq_of_packed_bounds 14 5 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 14 α t ^ 5) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 7) : 0 < 4540012290450 + 9000770719122 * α + 7217967952260 * α ^ 2 + 2789503991820 * α ^ 3 + 226924812075 * α ^ 4 - 867448623285 * α ^ 5 + 235182487819 * α ^ 6 + 1315276135 * α ^ 7 - 765536900 * α ^ 8 - 78585080 * α ^ 9 - 3463520 * α ^ 10 - 74480 * α ^ 11 - 640 * α ^ 12 := by have hu : (0 : ℝ) ≤ 7 - α := by linarith have hid : (7 : ℝ) ^ 12 * (4540012290450 + 9000770719122 * α + 7217967952260 * α ^ 2 + 2789503991820 * α ^ 3 + 226924812075 * α ^ 4 - 867448623285 * α ^ 5 + 235182487819 * α ^ 6 + 1315276135 * α ^ 7 - 765536900 * α ^ 8 - 78585080 * α ^ 9 - 3463520 * α ^ 10 - 74480 * α ^ 11 - 640 * α ^ 12) = 4540012290450 * (7 - α) ^ 12 + 117485542519254 * α ^ 1 * (7 - α) ^ 11 + 1346380586202834 * α ^ 2 * (7 - α) ^ 10 + 8957703596562630 * α ^ 3 * (7 - α) ^ 9 + 37714860895632375 * α ^ 4 * (7 - α) ^ 8 + 91053479724275985 * α ^ 5 * (7 - α) ^ 7 + 128817765797828254 * α ^ 6 * (7 - α) ^ 6 + 133833540832996984 * α ^ 7 * (7 - α) ^ 5 + 161773229978174745 * α ^ 8 * (7 - α) ^ 4 + 197834312331965435 * α ^ 9 * (7 - α) ^ 3 + 152113356071582990 * α ^ 10 * (7 - α) ^ 2 + 57359456154000000 * α ^ 11 * (7 - α) ^ 1 + 7376986416800000 * α ^ 12 := by - ring + bernstein_ring α (7 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (7 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 14 ≤ n) (h1 : n ≤ 15) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (15 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (15 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 14) (n := n) (n₁ := 15) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((14 : ℕ) : ℝ) - 4 = 10 by norm_num] at hb - rw [show (10 : ℝ) / 2 = ((5 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 13) + 1 / (4 * 13 * (3 + α)) + (1 - 2 * α / 14) ^ 2 * 15 * 14 * (15 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 13 * (3 + α)) ^ 5)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 14 ≤ n) (h1 : n ≤ 15) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 14) (n₁ := 15) (k := 5) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B14_15 diff --git a/Sendov/FiniteRange/Degree16_18.lean b/Sendov/FiniteRange/Degree16_18.lean index 12b1df3..0740d27 100644 --- a/Sendov/FiniteRange/Degree16_18.lean +++ b/Sendov/FiniteRange/Degree16_18.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 16 to 18 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 16) (gg1 16) (gg2 16) 6)) α := by - refine pev_wsum_eq_of_packed (gg0 16) (gg1 16) (gg2 16) 6 19 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 16) (gg1 16) (gg2 16) 6 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 16) (gg1 16) (gg2 16) 6 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 16) (gg1 16) (gg2 16) 3 (by simp) (by simp) (by simp) 6) - · rfl + refine pev_moment_eq_of_packed_bounds 16 6 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 16 α t ^ 6) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17 / 2) : 0 < 308547940078125 + 716274580556250 * α + 701075142421875 * α ^ 2 + 366034929547500 * α ^ 3 + 98713082723625 * α ^ 4 - 785317395690 * α ^ 5 - 34202916258669 * α ^ 6 + 6366700041480 * α ^ 7 + 121732471512 * α ^ 8 - 9494954208 * α ^ 9 - 1551607200 * α ^ 10 - 87661568 * α ^ 11 - 2586240 * α ^ 12 - 39936 * α ^ 13 - 256 * α ^ 14 := by have hu : (0 : ℝ) ≤ 17 - 2 * α := by linarith have hid : (17 : ℝ) ^ 14 * (308547940078125 + 716274580556250 * α + 701075142421875 * α ^ 2 + 366034929547500 * α ^ 3 + 98713082723625 * α ^ 4 - 785317395690 * α ^ 5 - 34202916258669 * α ^ 6 + 6366700041480 * α ^ 7 + 121732471512 * α ^ 8 - 9494954208 * α ^ 9 - 1551607200 * α ^ 10 - 87661568 * α ^ 11 - 2586240 * α ^ 12 - 39936 * α ^ 13 - 256 * α ^ 14) = 308547940078125 * (17 - 2 * α) ^ 14 + 20816010191643750 * α ^ 1 * (17 - 2 * α) ^ 13 + 631515530954221875 * α ^ 2 * (17 - 2 * α) ^ 12 + 11358598773482842500 * α ^ 3 * (17 - 2 * α) ^ 11 + 134099015737057493625 * α ^ 4 * (17 - 2 * α) ^ 10 + 1075072539293623306170 * α ^ 5 * (17 - 2 * α) ^ 9 + 5177641117293101872899 * α ^ 6 * (17 - 2 * α) ^ 8 + 13260545037504883513944 * α ^ 7 * (17 - 2 * α) ^ 7 + 13392270163441462237560 * α ^ 8 * (17 - 2 * α) ^ 6 + 934363054464939802080 * α ^ 9 * (17 - 2 * α) ^ 5 + 56141276222621229749280 * α ^ 10 * (17 - 2 * α) ^ 4 + 269593608305522330908544 * α ^ 11 * (17 - 2 * α) ^ 3 + 451523429099140347738624 * α ^ 12 * (17 - 2 * α) ^ 2 + 320966535936278232000000 * α ^ 13 * (17 - 2 * α) ^ 1 + 72913603873782672000000 * α ^ 14 := by - ring + bernstein_ring α (17 - 2 * α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - 2 * α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 16 ≤ n) (h1 : n ≤ 18) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (18 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (18 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 16) (n := n) (n₁ := 18) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((16 : ℕ) : ℝ) - 4 = 12 by norm_num] at hb - rw [show (12 : ℝ) / 2 = ((6 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 15) + 1 / (4 * 15 * (3 + α)) + (1 - 2 * α / 17) ^ 2 * 18 * 17 * (18 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 15 * (3 + α)) ^ 6)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 16 ≤ n) (h1 : n ≤ 18) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 16) (n₁ := 18) (k := 6) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B16_18 diff --git a/Sendov/FiniteRange/Degree18_20.lean b/Sendov/FiniteRange/Degree18_20.lean index 2682467..0f80bda 100644 --- a/Sendov/FiniteRange/Degree18_20.lean +++ b/Sendov/FiniteRange/Degree18_20.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 18 to 20 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 18) (gg1 18) (gg2 18) 7)) α := by - refine pev_wsum_eq_of_packed (gg0 18) (gg1 18) (gg2 18) 7 22 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 18) (gg1 18) (gg2 18) 7 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 18) (gg1 18) (gg2 18) 7 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 18) (gg1 18) (gg2 18) 3 (by simp) (by simp) (by simp) 7) - · rfl + refine pev_moment_eq_of_packed_bounds 18 7 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 18 α t ^ 7) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 19 / 2) : 0 < 1996938880799635773 + 5327542416376042533 * α + 6168567333266685756 * α ^ 2 + 4015726419901684032 * α ^ 3 + 1568562341575363317 * α ^ 4 + 336439630979056719 * α ^ 5 - 5059047712773960 * α ^ 6 - 94154641040290584 * α ^ 7 + 14305270642714822 * α ^ 8 + 337895936432856 * α ^ 9 - 7990669279488 * α ^ 10 - 2592154628256 * α ^ 11 - 177335477376 * α ^ 12 - 6421337472 * α ^ 13 - 134803968 * α ^ 14 - 1555968 * α ^ 15 - 7680 * α ^ 16 := by have hu : (0 : ℝ) ≤ 19 - 2 * α := by linarith have hid : (19 : ℝ) ^ 16 * (1996938880799635773 + 5327542416376042533 * α + 6168567333266685756 * α ^ 2 + 4015726419901684032 * α ^ 3 + 1568562341575363317 * α ^ 4 + 336439630979056719 * α ^ 5 - 5059047712773960 * α ^ 6 - 94154641040290584 * α ^ 7 + 14305270642714822 * α ^ 8 + 337895936432856 * α ^ 9 - 7990669279488 * α ^ 10 - 2592154628256 * α ^ 11 - 177335477376 * α ^ 12 - 6421337472 * α ^ 13 - 134803968 * α ^ 14 - 1555968 * α ^ 15 - 7680 * α ^ 16) = 1996938880799635773 * (19 - 2 * α) ^ 16 + 165125350096733152863 * α ^ 1 * (19 - 2 * α) ^ 15 + 6222082647427442972766 * α ^ 2 * (19 - 2 * α) ^ 14 + 141355820787428498073516 * α ^ 3 * (19 - 2 * α) ^ 13 + 2157735283869217913370909 * α ^ 4 * (19 - 2 * α) ^ 12 + 23307179713209861652797525 * α ^ 5 * (19 - 2 * α) ^ 11 + 181491504176132704398182238 * α ^ 6 * (19 - 2 * α) ^ 10 + 947234591820259386271884708 * α ^ 7 * (19 - 2 * α) ^ 9 + 3056114849066116568052366478 * α ^ 8 * (19 - 2 * α) ^ 8 + 5409419472435810969555104008 * α ^ 9 * (19 - 2 * α) ^ 7 + 3773674627041183640344074704 * α ^ 10 * (19 - 2 * α) ^ 6 + 2563877062588931411214853312 * α ^ 11 * (19 - 2 * α) ^ 5 + 27502208508532453123433891776 * α ^ 12 * (19 - 2 * α) ^ 4 + 85133541744770676359382205696 * α ^ 13 * (19 - 2 * α) ^ 3 + 113617195875176526046213373440 * α ^ 14 * (19 - 2 * α) ^ 2 + 68841959775014032750000000000 * α ^ 15 * (19 - 2 * α) ^ 1 + 13908254927398975000000000000 * α ^ 16 := by - ring + bernstein_ring α (19 - 2 * α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (19 - 2 * α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 18 ≤ n) (h1 : n ≤ 20) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (20 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (20 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 18) (n := n) (n₁ := 20) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((18 : ℕ) : ℝ) - 4 = 14 by norm_num] at hb - rw [show (14 : ℝ) / 2 = ((7 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 17) + 1 / (4 * 17 * (3 + α)) + (1 - 2 * α / 19) ^ 2 * 20 * 19 * (20 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 17 * (3 + α)) ^ 7)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 18 ≤ n) (h1 : n ≤ 20) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 18) (n₁ := 20) (k := 7) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B18_20 diff --git a/Sendov/FiniteRange/Degree20_22.lean b/Sendov/FiniteRange/Degree20_22.lean index 3b02309..bff3ff0 100644 --- a/Sendov/FiniteRange/Degree20_22.lean +++ b/Sendov/FiniteRange/Degree20_22.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 20 to 22 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 20) (gg1 20) (gg2 20) 8)) α := by - refine pev_wsum_eq_of_packed (gg0 20) (gg1 20) (gg2 20) 8 25 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 20) (gg1 20) (gg2 20) 8 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 20) (gg1 20) (gg2 20) 8 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 20) (gg1 20) (gg2 20) 3 (by simp) (by simp) (by simp) 8) - · rfl + refine pev_moment_eq_of_packed_bounds 20 8 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 20 α t ^ 8) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 21 / 2) : 0 < 721140310389707127738 + 2170180610909239016088 * α + 2889750967198268814324 * α ^ 2 + 2227128338977232972904 * α ^ 3 + 1085997068794302710391 * α ^ 4 + 339049376116278228288 * α ^ 5 + 60509700204282383346 * α ^ 6 - 1038039442012938636 * α ^ 7 - 14060791839010189905 * α ^ 8 + 1774506642858471852 * α ^ 9 + 45855210342618468 * α ^ 10 + 226538249017920 * α ^ 11 - 222291771124416 * α ^ 12 - 18538380993792 * α ^ 13 - 787852835840 * α ^ 14 - 20286313472 * α ^ 15 - 320448768 * α ^ 16 - 2874368 * α ^ 17 - 11264 * α ^ 18 := by have hu : (0 : ℝ) ≤ 21 - 2 * α := by linarith have hid : (21 : ℝ) ^ 18 * (721140310389707127738 + 2170180610909239016088 * α + 2889750967198268814324 * α ^ 2 + 2227128338977232972904 * α ^ 3 + 1085997068794302710391 * α ^ 4 + 339049376116278228288 * α ^ 5 + 60509700204282383346 * α ^ 6 - 1038039442012938636 * α ^ 7 - 14060791839010189905 * α ^ 8 + 1774506642858471852 * α ^ 9 + 45855210342618468 * α ^ 10 + 226538249017920 * α ^ 11 - 222291771124416 * α ^ 12 - 18538380993792 * α ^ 13 - 787852835840 * α ^ 14 - 20286313472 * α ^ 15 - 320448768 * α ^ 16 - 2874368 * α ^ 17 - 11264 * α ^ 18) = 721140310389707127738 * (21 - 2 * α) ^ 18 + 71534844003123475936416 * α ^ 1 * (21 - 2 * α) ^ 17 + 3265227002682133966779372 * α ^ 2 * (21 - 2 * α) ^ 16 + 90905348441621278719467208 * α ^ 3 * (21 - 2 * α) ^ 15 + 1724899809677710491069520311 * α ^ 4 * (21 - 2 * α) ^ 14 + 23603549699659251265167149604 * α ^ 5 * (21 - 2 * α) ^ 13 + 240138761499155563910895585654 * α ^ 6 * (21 - 2 * α) ^ 12 + 1837366344267267569709080196468 * α ^ 7 * (21 - 2 * α) ^ 11 + 10104702475479597929008103413095 * α ^ 8 * (21 - 2 * α) ^ 10 + 37641802639366180553916149163576 * α ^ 9 * (21 - 2 * α) ^ 9 + 88449061215859475411346373536264 * α ^ 10 * (21 - 2 * α) ^ 8 + 113640861426905556745222707601920 * α ^ 11 * (21 - 2 * α) ^ 7 + 55669273871103476657042199021792 * α ^ 12 * (21 - 2 * α) ^ 6 + 99281941699214882417362945572096 * α ^ 13 * (21 - 2 * α) ^ 5 + 654986082897929475911576119281408 * α ^ 14 * (21 - 2 * α) ^ 4 + 1538940561324052318678745687107584 * α ^ 15 * (21 - 2 * α) ^ 3 + 1719020178639381082845279983473152 * α ^ 16 * (21 - 2 * α) ^ 2 + 910135906460129539245476343896064 * α ^ 17 * (21 - 2 * α) ^ 1 + 165769381149578270034391223083008 * α ^ 18 := by - ring + bernstein_ring α (21 - 2 * α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (21 - 2 * α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 20 ≤ n) (h1 : n ≤ 22) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (22 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (22 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 20) (n := n) (n₁ := 22) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((20 : ℕ) : ℝ) - 4 = 16 by norm_num] at hb - rw [show (16 : ℝ) / 2 = ((8 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 19) + 1 / (4 * 19 * (3 + α)) + (1 - 2 * α / 21) ^ 2 * 22 * 21 * (22 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 19 * (3 + α)) ^ 8)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 20 ≤ n) (h1 : n ≤ 22) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 20) (n₁ := 22) (k := 8) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B20_22 diff --git a/Sendov/FiniteRange/Degree22_24.lean b/Sendov/FiniteRange/Degree22_24.lean index 3a7590a..ab7800d 100644 --- a/Sendov/FiniteRange/Degree22_24.lean +++ b/Sendov/FiniteRange/Degree22_24.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 22 to 24 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 22) (gg1 22) (gg2 22) 9)) α := by - refine pev_wsum_eq_of_packed (gg0 22) (gg1 22) (gg2 22) 9 28 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 22) (gg1 22) (gg2 22) 9 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 22) (gg1 22) (gg2 22) 9 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 22) (gg1 22) (gg2 22) 3 (by simp) (by simp) (by simp) 9) - · rfl + refine pev_moment_eq_of_packed_bounds 22 9 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 22 α t ^ 9) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 23 / 2) : 0 < 72676691260477709153931 + 243335498910644300539743 * α + 365647629606098581621152 * α ^ 2 + 324203560761134112575706 * α ^ 3 + 187220150267586036026391 * α ^ 4 + 72995868351568741088853 * α ^ 5 + 18997181712653091143742 * α ^ 6 + 2912276075526675669294 * α ^ 7 - 47524187765551795452 * α ^ 8 - 572344038827543054862 * α ^ 9 + 60958599043408078986 * α ^ 10 + 1608150216459380292 * α ^ 11 + 37160884428953616 * α ^ 12 - 4770728942909184 * α ^ 13 - 508194774105984 * α ^ 14 - 24843494479104 * α ^ 15 - 745526594304 * α ^ 16 - 14490071808 * α ^ 17 - 179034112 * α ^ 18 - 1285120 * α ^ 19 - 4096 * α ^ 20 := by have hu : (0 : ℝ) ≤ 23 - 2 * α := by linarith have hid : (23 : ℝ) ^ 20 * (72676691260477709153931 + 243335498910644300539743 * α + 365647629606098581621152 * α ^ 2 + 324203560761134112575706 * α ^ 3 + 187220150267586036026391 * α ^ 4 + 72995868351568741088853 * α ^ 5 + 18997181712653091143742 * α ^ 6 + 2912276075526675669294 * α ^ 7 - 47524187765551795452 * α ^ 8 - 572344038827543054862 * α ^ 9 + 60958599043408078986 * α ^ 10 + 1608150216459380292 * α ^ 11 + 37160884428953616 * α ^ 12 - 4770728942909184 * α ^ 13 - 508194774105984 * α ^ 14 - 24843494479104 * α ^ 15 - 745526594304 * α ^ 16 - 14490071808 * α ^ 17 - 179034112 * α ^ 18 - 1285120 * α ^ 19 - 4096 * α ^ 20) = 72676691260477709153931 * (23 - 2 * α) ^ 20 + 8503784125363927278571329 * α ^ 1 * (23 - 2 * α) ^ 19 + 461337107467492327306312350 * α ^ 2 * (23 - 2 * α) ^ 18 + 15398943675157072979676921186 * α ^ 3 * (23 - 2 * α) ^ 17 + 353905086689575653155085657243 * α ^ 4 * (23 - 2 * α) ^ 16 + 5938058763785413089179396251875 * α ^ 5 * (23 - 2 * α) ^ 15 + 75246714147642299181739714271832 * α ^ 6 * (23 - 2 * α) ^ 14 + 734384442923791787182437424591542 * α ^ 7 * (23 - 2 * α) ^ 13 + 5562914983973677901584481691318984 * α ^ 8 * (23 - 2 * α) ^ 12 + 31773805113877239761694178561183806 * α ^ 9 * (23 - 2 * α) ^ 11 + 130856587563539007907893649077192702 * α ^ 10 * (23 - 2 * α) ^ 10 + 369427721563914607645637465073374604 * α ^ 11 * (23 - 2 * α) ^ 9 + 659851634553627022861170989844737856 * α ^ 12 * (23 - 2 * α) ^ 8 + 615817039503279914009940077569822464 * α ^ 13 * (23 - 2 * α) ^ 7 + 195270527269368587749778342774288064 * α ^ 14 * (23 - 2 * α) ^ 6 + 857988173853242270013037467185126784 * α ^ 15 * (23 - 2 * α) ^ 5 + 4220624235641254987215180793015588608 * α ^ 16 * (23 - 2 * α) ^ 4 + 8094967304722603824961003917794419968 * α ^ 17 * (23 - 2 * α) ^ 3 + 7807057971748984716263131834792835072 * α ^ 18 * (23 - 2 * α) ^ 2 + 3677240872883486972453388075862686720 * α ^ 19 * (23 - 2 * α) ^ 1 + 610286593660503076943530707277762560 * α ^ 20 := by - ring + bernstein_ring α (23 - 2 * α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (23 - 2 * α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 22 ≤ n) (h1 : n ≤ 24) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (24 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (24 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 22) (n := n) (n₁ := 24) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((22 : ℕ) : ℝ) - 4 = 18 by norm_num] at hb - rw [show (18 : ℝ) / 2 = ((9 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 21) + 1 / (4 * 21 * (3 + α)) + (1 - 2 * α / 23) ^ 2 * 24 * 23 * (24 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 21 * (3 + α)) ^ 9)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 22 ≤ n) (h1 : n ≤ 24) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 22) (n₁ := 24) (k := 9) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B22_24 diff --git a/Sendov/FiniteRange/Degree24_26.lean b/Sendov/FiniteRange/Degree24_26.lean index 798825d..b718164 100644 --- a/Sendov/FiniteRange/Degree24_26.lean +++ b/Sendov/FiniteRange/Degree24_26.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 24 to 26 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 24) (gg1 24) (gg2 24) 10)) α := by - refine pev_wsum_eq_of_packed (gg0 24) (gg1 24) (gg2 24) 10 31 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 24) (gg1 24) (gg2 24) 10 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 24) (gg1 24) (gg2 24) 10 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 24) (gg1 24) (gg2 24) 3 (by simp) (by simp) (by simp) 10) - · rfl + refine pev_moment_eq_of_packed_bounds 24 10 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 24 α t ^ 10) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 25 / 2) : 0 < 874071004010582953643568750 + 3221297610086019399669004500 * α + 5386914463346812349691460974 * α ^ 2 + 5391225879978445091101054368 * α ^ 3 + 3582299145670361769507272658 * α ^ 4 + 1654127651781089540379647100 * α ^ 5 + 537462463626302644652842710 * α ^ 6 + 120043033655516749475390448 * α ^ 7 + 16184849120135434020794931 * α ^ 8 - 222784389930881498880726 * α ^ 9 - 2725770297915674501126913 * α ^ 10 + 248640476833385673099320 * α ^ 11 + 6386094327528944247792 * α ^ 12 + 230085309479261626272 * α ^ 13 - 10099884196228450032 * α ^ 14 - 1569527054513950464 * α ^ 15 - 87896838917715456 * α ^ 16 - 2989402709094912 * α ^ 17 - 67703370254592 * α ^ 18 - 1033617561600 * α ^ 19 - 10281172992 * α ^ 20 - 60432384 * α ^ 21 - 159744 * α ^ 22 := by have hu : (0 : ℝ) ≤ 25 - 2 * α := by linarith have hid : (25 : ℝ) ^ 22 * (874071004010582953643568750 + 3221297610086019399669004500 * α + 5386914463346812349691460974 * α ^ 2 + 5391225879978445091101054368 * α ^ 3 + 3582299145670361769507272658 * α ^ 4 + 1654127651781089540379647100 * α ^ 5 + 537462463626302644652842710 * α ^ 6 + 120043033655516749475390448 * α ^ 7 + 16184849120135434020794931 * α ^ 8 - 222784389930881498880726 * α ^ 9 - 2725770297915674501126913 * α ^ 10 + 248640476833385673099320 * α ^ 11 + 6386094327528944247792 * α ^ 12 + 230085309479261626272 * α ^ 13 - 10099884196228450032 * α ^ 14 - 1569527054513950464 * α ^ 15 - 87896838917715456 * α ^ 16 - 2989402709094912 * α ^ 17 - 67703370254592 * α ^ 18 - 1033617561600 * α ^ 19 - 10281172992 * α ^ 20 - 60432384 * α ^ 21 - 159744 * α ^ 22) = 874071004010582953643568750 * (25 - 2 * α) ^ 22 + 118991564428616134952042137500 * α ^ 1 * (25 - 2 * α) ^ 21 + 7556825637887856737376275358750 * α ^ 2 * (25 - 2 * α) ^ 20 + 297326570539550302672678360350000 * α ^ 3 * (25 - 2 * α) ^ 19 + 8118326774696702494364871859181250 * α ^ 4 * (25 - 2 * α) ^ 18 + 163302166743534227801697447509662500 * α ^ 5 * (25 - 2 * α) ^ 17 + 2507454163520304052153861436880993750 * α ^ 6 * (25 - 2 * α) ^ 16 + 30047259752690844282111594563558670000 * α ^ 7 * (25 - 2 * α) ^ 15 + 284787676890052141286070572033915521875 * α ^ 8 * (25 - 2 * α) ^ 14 + 2146769361227978442422195176181338368750 * α ^ 9 * (25 - 2 * α) ^ 13 + 12630679896438305929175193655858187184375 * α ^ 10 * (25 - 2 * α) ^ 12 + 56067735566028501096437207497525020350000 * α ^ 11 * (25 - 2 * α) ^ 11 + 180631480948809558078622444236010586285000 * α ^ 12 * (25 - 2 * α) ^ 10 + 400779538225462244119560623305257108200000 * α ^ 13 * (25 - 2 * α) ^ 9 + 552145957044674175745646853887912448300000 * α ^ 14 * (25 - 2 * α) ^ 8 + 348851941562555217823842842079415684800000 * α ^ 15 * (25 - 2 * α) ^ 7 + 38623525300380552283361811907759716000000 * α ^ 16 * (25 - 2 * α) ^ 6 + 822237191651812497627267691867773310080000 * α ^ 17 * (25 - 2 * α) ^ 5 + 3269244329154715153428677298597459316800000 * α ^ 18 * (25 - 2 * α) ^ 4 + 5333912969812883272270527401813990707200000 * α ^ 19 * (25 - 2 * α) ^ 3 + 4537960847197188659144322307990683712000000 * α ^ 20 * (25 - 2 * α) ^ 2 + 1927546466544754214336332480358954905600000 * α ^ 21 * (25 - 2 * α) ^ 1 + 294013599962108674661431900766763888640000 * α ^ 22 := by - ring + bernstein_ring α (25 - 2 * α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (25 - 2 * α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 24 ≤ n) (h1 : n ≤ 26) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (26 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (26 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 24) (n := n) (n₁ := 26) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((24 : ℕ) : ℝ) - 4 = 20 by norm_num] at hb - rw [show (20 : ℝ) / 2 = ((10 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 23) + 1 / (4 * 23 * (3 + α)) + (1 - 2 * α / 25) ^ 2 * 26 * 25 * (26 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 23 * (3 + α)) ^ 10)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 24 ≤ n) (h1 : n ≤ 26) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 24) (n₁ := 26) (k := 10) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B24_26 diff --git a/Sendov/FiniteRange/Degree26_27.lean b/Sendov/FiniteRange/Degree26_27.lean index 947edd5..305f88a 100644 --- a/Sendov/FiniteRange/Degree26_27.lean +++ b/Sendov/FiniteRange/Degree26_27.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 26 to 27 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 26) (gg1 26) (gg2 26) 11)) α := by - refine pev_wsum_eq_of_packed (gg0 26) (gg1 26) (gg2 26) 11 34 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 26) (gg1 26) (gg2 26) 11 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 26) (gg1 26) (gg2 26) 11 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 26) (gg1 26) (gg2 26) 3 (by simp) (by simp) (by simp) 11) - · rfl + refine pev_moment_eq_of_packed_bounds 26 11 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 26 α t ^ 11) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 13) : 0 < 750669183453805732727050781250 + 3020533706655215263366699218750 * α + 5564839729610338783264160156250 * α ^ 2 + 6204652935907732786560058593750 * α ^ 3 + 4659850847351595430480957031250 * α ^ 4 + 2480313988118708551463378906250 * α ^ 5 + 956953438533800725637460937500 * α ^ 6 + 267988469385291406396875000000 * α ^ 7 + 53061280626889862612388984375 * α ^ 8 + 6649776660279075672227540625 * α ^ 9 + 67029306131497703210255025 * α ^ 10 - 797547671168471728584421521 * α ^ 11 + 69793209950586805764791132 * α ^ 12 + 1582701213221515173844854 * α ^ 13 + 64909025019891545058702 * α ^ 14 - 1621590589357829572680 * α ^ 15 - 347824272218530328424 * α ^ 16 - 21365270620680629952 * α ^ 17 - 794207858493279744 * α ^ 18 - 20077534583212032 * α ^ 19 - 355351304655360 * α ^ 20 - 4364532094464 * α ^ 21 - 35609836032 * α ^ 22 - 174127104 * α ^ 23 - 387072 * α ^ 24 := by have hu : (0 : ℝ) ≤ 13 - α := by linarith have hid : (13 : ℝ) ^ 24 * (750669183453805732727050781250 + 3020533706655215263366699218750 * α + 5564839729610338783264160156250 * α ^ 2 + 6204652935907732786560058593750 * α ^ 3 + 4659850847351595430480957031250 * α ^ 4 + 2480313988118708551463378906250 * α ^ 5 + 956953438533800725637460937500 * α ^ 6 + 267988469385291406396875000000 * α ^ 7 + 53061280626889862612388984375 * α ^ 8 + 6649776660279075672227540625 * α ^ 9 + 67029306131497703210255025 * α ^ 10 - 797547671168471728584421521 * α ^ 11 + 69793209950586805764791132 * α ^ 12 + 1582701213221515173844854 * α ^ 13 + 64909025019891545058702 * α ^ 14 - 1621590589357829572680 * α ^ 15 - 347824272218530328424 * α ^ 16 - 21365270620680629952 * α ^ 17 - 794207858493279744 * α ^ 18 - 20077534583212032 * α ^ 19 - 355351304655360 * α ^ 20 - 4364532094464 * α ^ 21 - 35609836032 * α ^ 22 - 174127104 * α ^ 23 - 387072 * α ^ 24) = 750669183453805732727050781250 * (13 - α) ^ 24 + 57282998589409136009216308593750 * α ^ 1 * (13 - α) ^ 23 + 2050782187227307000350952148437500 * α ^ 2 * (13 - α) ^ 22 + 45775586403380034332501220703125000 * α ^ 3 * (13 - α) ^ 21 + 714118209031145161147786743164062500 * α ^ 4 * (13 - α) ^ 20 + 8273284316298011107371657322265625000 * α ^ 5 * (13 - α) ^ 19 + 73835510530487101104526833122402343750 * α ^ 6 * (13 - α) ^ 18 + 519733885027019750587474273435957031250 * α ^ 7 * (13 - α) ^ 17 + 2930800059791589030908400058323199921875 * α ^ 8 * (13 - α) ^ 16 + 13372402464675670629912241174388163590625 * α ^ 9 * (13 - α) ^ 15 + 49616523603298906478895841666067082338100 * α ^ 10 * (13 - α) ^ 14 + 148533037390768639293168587946346173784998 * α ^ 11 * (13 - α) ^ 13 + 352390650499030404141412366217263718435741 * α ^ 12 * (13 - α) ^ 12 + 649782112359758546338767005837625709617885 * α ^ 13 * (13 - α) ^ 11 + 915968039619170700348192462171799252793910 * α ^ 14 * (13 - α) ^ 10 + 976506256524831093733472748853893192499190 * α ^ 15 * (13 - α) ^ 9 + 793928461670457408996135461409947476637907 * α ^ 16 * (13 - α) ^ 8 + 532094243038671655145113443710174863949229 * α ^ 17 * (13 - α) ^ 7 + 362157082250568977592235276631536616142420 * α ^ 18 * (13 - α) ^ 6 + 282315964683600802659165217851025305107370 * α ^ 19 * (13 - α) ^ 5 + 202899768509895477280344720514446057053655 * α ^ 20 * (13 - α) ^ 4 + 106150121400148174823355428864276604237047 * α ^ 21 * (13 - α) ^ 3 + 35288625801200476947393636186470118639744 * α ^ 22 * (13 - α) ^ 2 + 6423617838051124838400000000000000000000 * α ^ 23 * (13 - α) ^ 1 + 451304798929131929600000000000000000000 * α ^ 24 := by - ring + bernstein_ring α (13 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (13 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 26 ≤ n) (h1 : n ≤ 27) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (27 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (27 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 26) (n := n) (n₁ := 27) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((26 : ℕ) : ℝ) - 4 = 22 by norm_num] at hb - rw [show (22 : ℝ) / 2 = ((11 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 25) + 1 / (4 * 25 * (3 + α)) + (1 - 2 * α / 26) ^ 2 * 27 * 26 * (27 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 25 * (3 + α)) ^ 11)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 26 ≤ n) (h1 : n ≤ 27) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 26) (n₁ := 27) (k := 11) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B26_27 diff --git a/Sendov/FiniteRange/Degree28_29.lean b/Sendov/FiniteRange/Degree28_29.lean index 930c4ee..9155e27 100644 --- a/Sendov/FiniteRange/Degree28_29.lean +++ b/Sendov/FiniteRange/Degree28_29.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 28 to 29 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 28) (gg1 28) (gg2 28) 12)) α := by - refine pev_wsum_eq_of_packed (gg0 28) (gg1 28) (gg2 28) 12 37 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 28) (gg1 28) (gg2 28) 12 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 28) (gg1 28) (gg2 28) 12 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 28) (gg1 28) (gg2 28) 3 (by simp) (by simp) (by simp) 12) - · rfl + refine pev_moment_eq_of_packed_bounds 28 12 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 28 α t ^ 12) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 14) : 0 < 426450318135882438427115499581616 + 1858834576882378710373815569972592 * α + 3736799374885893548337894566091516 * α ^ 2 + 4586209917810757974592827719731488 * α ^ 3 + 3832530771213891318426391118558376 * α ^ 4 + 2301315780911216714788724083158840 * α ^ 5 + 1020320104787175718704940125987654 * α ^ 6 + 337351267574328588560584527446352 * α ^ 7 + 82684042360278469454015755593696 * α ^ 8 + 14571761439373687941870063150072 * α ^ 9 + 1651893249078514632421437650658 * α ^ 10 + 16915365961758038105007429024 * α ^ 11 - 175858786927760049854457800868 * α ^ 12 + 13481653528168191298544554836 * α ^ 13 + 281552860237833486968732937 * α ^ 14 + 14047072236623243173813992 * α ^ 15 - 9139934377157415820848 * α ^ 16 - 45943869853012600689984 * α ^ 17 - 3291728447735177292432 * α ^ 18 - 135117714229500881664 * α ^ 19 - 3776901841060823808 * α ^ 20 - 75424649382531072 * α ^ 21 - 1084454315870976 * α ^ 22 - 11022972807168 * α ^ 23 - 75437817856 * α ^ 24 - 312639488 * α ^ 25 - 593920 * α ^ 26 := by have hu : (0 : ℝ) ≤ 14 - α := by linarith have hid : (14 : ℝ) ^ 26 * (426450318135882438427115499581616 + 1858834576882378710373815569972592 * α + 3736799374885893548337894566091516 * α ^ 2 + 4586209917810757974592827719731488 * α ^ 3 + 3832530771213891318426391118558376 * α ^ 4 + 2301315780911216714788724083158840 * α ^ 5 + 1020320104787175718704940125987654 * α ^ 6 + 337351267574328588560584527446352 * α ^ 7 + 82684042360278469454015755593696 * α ^ 8 + 14571761439373687941870063150072 * α ^ 9 + 1651893249078514632421437650658 * α ^ 10 + 16915365961758038105007429024 * α ^ 11 - 175858786927760049854457800868 * α ^ 12 + 13481653528168191298544554836 * α ^ 13 + 281552860237833486968732937 * α ^ 14 + 14047072236623243173813992 * α ^ 15 - 9139934377157415820848 * α ^ 16 - 45943869853012600689984 * α ^ 17 - 3291728447735177292432 * α ^ 18 - 135117714229500881664 * α ^ 19 - 3776901841060823808 * α ^ 20 - 75424649382531072 * α ^ 21 - 1084454315870976 * α ^ 22 - 11022972807168 * α ^ 23 - 75437817856 * α ^ 24 - 312639488 * α ^ 25 - 593920 * α ^ 26) = 426450318135882438427115499581616 * (14 - α) ^ 26 + 37111392347886245344338420968738304 * α ^ 1 * (14 - α) ^ 25 + 1521601132780629476593875321808369536 * α ^ 2 * (14 - α) ^ 24 + 39078340323995248057144700994634782336 * α ^ 3 * (14 - α) ^ 23 + 705051187055396740500579766777381514208 * α ^ 4 * (14 - α) ^ 22 + 9500322353274936154789534542408692441472 * α ^ 5 * (14 - α) ^ 21 + 99235235865063211599523391118038843304768 * α ^ 6 * (14 - α) ^ 20 + 823320752785879259967748712211136296143232 * α ^ 7 * (14 - α) ^ 19 + 5515721851061510718162550472414882027285712 * α ^ 8 * (14 - α) ^ 18 + 30174754728220837604457187088268784920537216 * α ^ 9 * (14 - α) ^ 17 + 135797159637259310387481461578932353970581952 * α ^ 10 * (14 - α) ^ 16 + 504664886820509810760132037456041458875523328 * α ^ 11 * (14 - α) ^ 15 + 1540639091909534601865038875378381140958117952 * α ^ 12 * (14 - α) ^ 14 + 3809796887220625879921007425681056060029021952 * α ^ 13 * (14 - α) ^ 13 + 7501791404136392824573180146400956404327039616 * α ^ 14 * (14 - α) ^ 12 + 11572714929523078093880359132036853394473485056 * α ^ 15 * (14 - α) ^ 11 + 13789723758378925038095275082223262786347860304 * α ^ 16 * (14 - α) ^ 10 + 12582251901524132212672360901736009892398456576 * α ^ 17 * (14 - α) ^ 9 + 8935758721652166554311189913325631720840187136 * α ^ 18 * (14 - α) ^ 8 + 5484179813557289010393355638182801357129728128 * α ^ 19 * (14 - α) ^ 7 + 3657829613491729305512570847707150262111504864 * α ^ 20 * (14 - α) ^ 6 + 2783234625894929033925209345455919590486513536 * α ^ 21 * (14 - α) ^ 5 + 1864845683118524255504101199017909275287974464 * α ^ 22 * (14 - α) ^ 4 + 893973882849468086668452977297233134024522624 * α ^ 23 * (14 - α) ^ 3 + 272658852549522790950799560990477918176209712 * α ^ 24 * (14 - α) ^ 2 + 45835418967464600203531300713422486095708800 * α ^ 25 * (14 - α) ^ 1 + 3000012367952955673085245642674753894705600 * α ^ 26 := by - ring + bernstein_ring α (14 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (14 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 28 ≤ n) (h1 : n ≤ 29) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (29 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (29 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 28) (n := n) (n₁ := 29) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((28 : ℕ) : ℝ) - 4 = 24 by norm_num] at hb - rw [show (24 : ℝ) / 2 = ((12 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 27) + 1 / (4 * 27 * (3 + α)) + (1 - 2 * α / 28) ^ 2 * 29 * 28 * (29 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 27 * (3 + α)) ^ 12)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 28 ≤ n) (h1 : n ≤ 29) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 28) (n₁ := 29) (k := 12) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B28_29 diff --git a/Sendov/FiniteRange/Degree30_31.lean b/Sendov/FiniteRange/Degree30_31.lean index 336fcc9..4e00296 100644 --- a/Sendov/FiniteRange/Degree30_31.lean +++ b/Sendov/FiniteRange/Degree30_31.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 30 to 31 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 30) (gg1 30) (gg2 30) 13)) α := by - refine pev_wsum_eq_of_packed (gg0 30) (gg1 30) (gg2 30) 13 40 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 30) (gg1 30) (gg2 30) 13 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 30) (gg1 30) (gg2 30) 13 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 30) (gg1 30) (gg2 30) 3 (by simp) (by simp) (by simp) 13) - · rfl + refine pev_moment_eq_of_packed_bounds 30 13 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 30 α t ^ 13) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 15) : 0 < 586577450963685326737168897370707500 + 2753132994648490979146101875384719500 * α + 5996201651556610186353013706234776680 * α ^ 2 + 8030975436338556704707041798612128472 * α ^ 3 + 7388055615126493367424454764006350082 * α ^ 4 + 4936598337528514606768767094265091378 * α ^ 5 + 2469192037754886771172170203022293214 * α ^ 6 + 938102920031818441360780570553215590 * α ^ 7 + 271392183919032658980825616039479546 * α ^ 8 + 59155996945930238392567631443933866 * α ^ 9 + 9399459563896087929210688264754844 * α ^ 10 + 974977535533292148502665510758532 * α ^ 11 + 10861549420545366403779627757839 * α ^ 12 - 92622867478166716461279291384369 * α ^ 13 + 6300099969105231240951104525763 * α ^ 14 + 117642575887863777951373952647 * α ^ 15 + 6754895556059983986318667916 * α ^ 16 + 94553344499679709104836184 * α ^ 17 - 13437772607038842242965408 * α ^ 18 - 1178131104153353973775376 * α ^ 19 - 53368378574787271805184 * α ^ 20 - 1629770789867125896192 * α ^ 21 - 35941441812526263552 * α ^ 22 - 584181453145681152 * α ^ 23 - 6973783723783168 * α ^ 24 - 59692780623872 * α ^ 25 - 347727077376 * α ^ 26 - 1237127168 * α ^ 27 - 2031616 * α ^ 28 := by have hu : (0 : ℝ) ≤ 15 - α := by linarith have hid : (15 : ℝ) ^ 28 * (586577450963685326737168897370707500 + 2753132994648490979146101875384719500 * α + 5996201651556610186353013706234776680 * α ^ 2 + 8030975436338556704707041798612128472 * α ^ 3 + 7388055615126493367424454764006350082 * α ^ 4 + 4936598337528514606768767094265091378 * α ^ 5 + 2469192037754886771172170203022293214 * α ^ 6 + 938102920031818441360780570553215590 * α ^ 7 + 271392183919032658980825616039479546 * α ^ 8 + 59155996945930238392567631443933866 * α ^ 9 + 9399459563896087929210688264754844 * α ^ 10 + 974977535533292148502665510758532 * α ^ 11 + 10861549420545366403779627757839 * α ^ 12 - 92622867478166716461279291384369 * α ^ 13 + 6300099969105231240951104525763 * α ^ 14 + 117642575887863777951373952647 * α ^ 15 + 6754895556059983986318667916 * α ^ 16 + 94553344499679709104836184 * α ^ 17 - 13437772607038842242965408 * α ^ 18 - 1178131104153353973775376 * α ^ 19 - 53368378574787271805184 * α ^ 20 - 1629770789867125896192 * α ^ 21 - 35941441812526263552 * α ^ 22 - 584181453145681152 * α ^ 23 - 6973783723783168 * α ^ 24 - 59692780623872 * α ^ 25 - 347727077376 * α ^ 26 - 1237127168 * α ^ 27 - 2031616 * α ^ 28) = 586577450963685326737168897370707500 * (15 - α) ^ 28 + 57721163546710553835832257257150602500 * α ^ 1 * (15 - α) ^ 27 + 2685890510897149191990249186639763585500 * α ^ 2 * (15 - α) ^ 26 + 78599194705430136604146587933476363108500 * α ^ 3 * (15 - α) ^ 25 + 1622909997175605567337562554410307661576250 * α ^ 4 * (15 - α) ^ 24 + 25146768623114737087640078167646014091973750 * α ^ 5 * (15 - α) ^ 23 + 303641086695050391528892238082119715503670000 * α ^ 6 * (15 - α) ^ 22 + 2929031512855517774498282614444762020783307500 * α ^ 7 * (15 - α) ^ 21 + 22961042451753622392989015501956773126769350000 * α ^ 8 * (15 - α) ^ 20 + 148033957973212624082175754920221815579937805000 * α ^ 9 * (15 - α) ^ 19 + 791520488598836900068848830160917234498844101250 * α ^ 10 * (15 - α) ^ 18 + 3529526175327511018680726743043836767850893061250 * α ^ 11 * (15 - α) ^ 17 + 13165011207751367740633403433981725749824494296875 * α ^ 12 * (15 - α) ^ 16 + 40931653416291075198328442361012806391694992643125 * α ^ 13 * (15 - α) ^ 15 + 104936099346045749439240355737362583910582002551250 * α ^ 14 * (15 - α) ^ 14 + 218605526114400884612386873561624396579818747067500 * α ^ 15 * (15 - α) ^ 13 + 364544768185120783615020401898669737526038946860625 * α ^ 16 * (15 - α) ^ 12 + 479686011445303946308298171035582326066907836556875 * α ^ 17 * (15 - α) ^ 11 + 491421915359135714614282850386451786914114000492500 * α ^ 18 * (15 - α) ^ 10 + 389161288470744666432388567554714822581024179398750 * α ^ 19 * (15 - α) ^ 9 + 244558897556532361649184200629954946613489703141875 * α ^ 20 * (15 - α) ^ 8 + 139992773266086273600697845417718983669371612533125 * α ^ 21 * (15 - α) ^ 7 + 93042859490049901489480348991956175393389715291250 * α ^ 22 * (15 - α) ^ 6 + 69299238884896976481539054996360074995454890772500 * α ^ 23 * (15 - α) ^ 5 + 43491785146541891064576495824222890234435540966875 * α ^ 24 * (15 - α) ^ 4 + 19249688128515085853018716648633058220873114065625 * α ^ 25 * (15 - α) ^ 3 + 5426365264657811094720994999869461719092174416250 * α ^ 26 * (15 - α) ^ 2 + 847744461331358174965504508366152817665302528000 * α ^ 27 * (15 - α) ^ 1 + 51950222508646395464079311308157550857404416000 * α ^ 28 := by - ring + bernstein_ring α (15 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (15 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 30 ≤ n) (h1 : n ≤ 31) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (31 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (31 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 30) (n := n) (n₁ := 31) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((30 : ℕ) : ℝ) - 4 = 26 by norm_num] at hb - rw [show (26 : ℝ) / 2 = ((13 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 29) + 1 / (4 * 29 * (3 + α)) + (1 - 2 * α / 30) ^ 2 * 31 * 30 * (31 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 29 * (3 + α)) ^ 13)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 30 ≤ n) (h1 : n ≤ 31) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 30) (n₁ := 31) (k := 13) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B30_31 diff --git a/Sendov/FiniteRange/Degree32_33.lean b/Sendov/FiniteRange/Degree32_33.lean index f40ce27..9ee8d11 100644 --- a/Sendov/FiniteRange/Degree32_33.lean +++ b/Sendov/FiniteRange/Degree32_33.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 32 to 33 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 32) (gg1 32) (gg2 32) 14)) α := by - refine pev_wsum_eq_of_packed (gg0 32) (gg1 32) (gg2 32) 14 43 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 32) (gg1 32) (gg2 32) 14 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 32) (gg1 32) (gg2 32) 14 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 32) (gg1 32) (gg2 32) 3 (by simp) (by simp) (by simp) 14) - · rfl + refine pev_moment_eq_of_packed_bounds 32 14 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 32 α t ^ 14) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 16) : 0 < 383977583360819576313951392966054557440 + 1930634984998770141470327139790256873760 * α + 4528139655529657241697903448404234220551 * α ^ 2 + 6571116743547522810411224078221219285242 * α ^ 3 + 6597373572981213714180223077765169741761 * α ^ 4 + 4853145290868457132481352533313124037136 * α ^ 5 + 2701279688513765542055333848381676518287 * α ^ 6 + 1157769823809425762972955166775789744790 * α ^ 7 + 384826365482239087514233918976406892725 * α ^ 8 + 98972460520277767374027328895457052524 * α ^ 9 + 19429030643214541979169516429755259903 * α ^ 10 + 2812337464920293963928011188383752346 * α ^ 11 + 269412053495826821775011955678389445 * α ^ 12 + 3352473026131557768885960806993016 * α ^ 13 - 22950931900671630187087717249723635 * α ^ 14 + 1401665499631441401236402118586466 * α ^ 15 + 22766380179065358125804378947555 * α ^ 16 + 1462014916628262060084862591156 * α ^ 17 + 35132359566977040523019407180 * α ^ 18 - 1604603346728872922022402944 * α ^ 19 - 192243388845480689610974960 * α ^ 20 - 9672937893957196503857344 * α ^ 21 - 320523259524150064257216 * α ^ 22 - 7695435702924730354176 * α ^ 23 - 138216454665665111296 * α ^ 24 - 1869603872239262720 * α ^ 25 - 18853950116959232 * α ^ 26 - 137859411329024 * α ^ 27 - 692050472960 * α ^ 28 - 2136915968 * α ^ 29 - 3063808 * α ^ 30 := by have hu : (0 : ℝ) ≤ 16 - α := by linarith have hid : (16 : ℝ) ^ 30 * (383977583360819576313951392966054557440 + 1930634984998770141470327139790256873760 * α + 4528139655529657241697903448404234220551 * α ^ 2 + 6571116743547522810411224078221219285242 * α ^ 3 + 6597373572981213714180223077765169741761 * α ^ 4 + 4853145290868457132481352533313124037136 * α ^ 5 + 2701279688513765542055333848381676518287 * α ^ 6 + 1157769823809425762972955166775789744790 * α ^ 7 + 384826365482239087514233918976406892725 * α ^ 8 + 98972460520277767374027328895457052524 * α ^ 9 + 19429030643214541979169516429755259903 * α ^ 10 + 2812337464920293963928011188383752346 * α ^ 11 + 269412053495826821775011955678389445 * α ^ 12 + 3352473026131557768885960806993016 * α ^ 13 - 22950931900671630187087717249723635 * α ^ 14 + 1401665499631441401236402118586466 * α ^ 15 + 22766380179065358125804378947555 * α ^ 16 + 1462014916628262060084862591156 * α ^ 17 + 35132359566977040523019407180 * α ^ 18 - 1604603346728872922022402944 * α ^ 19 - 192243388845480689610974960 * α ^ 20 - 9672937893957196503857344 * α ^ 21 - 320523259524150064257216 * α ^ 22 - 7695435702924730354176 * α ^ 23 - 138216454665665111296 * α ^ 24 - 1869603872239262720 * α ^ 25 - 18853950116959232 * α ^ 26 - 137859411329024 * α ^ 27 - 692050472960 * α ^ 28 - 2136915968 * α ^ 29 - 3063808 * α ^ 30) = 383977583360819576313951392966054557440 * (16 - α) ^ 30 + 42409487260804909552943776025625746703360 * α ^ 1 * (16 - α) ^ 29 + 2222048633616978115213463931594396882372096 * α ^ 2 * (16 - α) ^ 28 + 73473353083404174858760833498075355240412160 * α ^ 3 * (16 - α) ^ 27 + 1720652985002569694625940957603172487457959168 * α ^ 4 * (16 - α) ^ 26 + 30363605055601889844187715226554004982348216320 * α ^ 5 * (16 - α) ^ 25 + 419419313440566659766595274985269607940848110592 * α ^ 6 * (16 - α) ^ 24 + 4651028177520748697700758854373515125968713340928 * α ^ 7 * (16 - α) ^ 23 + 42137577409585697471273190015560150932516267552512 * α ^ 8 * (16 - α) ^ 22 + 315813162774288007921028011965819893459606590098432 * α ^ 9 * (16 - α) ^ 21 + 1975705535276134028928012252827490436823332026530304 * α ^ 10 * (16 - α) ^ 20 + 10382688588871544644830770347967881283088055308155904 * α ^ 11 * (16 - α) ^ 19 + 46032559619183787080156358678834876487940673091005696 * α ^ 12 * (16 - α) ^ 18 + 172591747559291476479103054798864248406917335500124160 * α ^ 13 * (16 - α) ^ 17 + 545974175950014920103132403616690663895819828147984384 * α ^ 14 * (16 - α) ^ 16 + 1445130613022938433929608617595105884579474631328108544 * α ^ 15 * (16 - α) ^ 15 + 3161509852911810407500355299058617164221708297980898560 * α ^ 16 * (16 - α) ^ 14 + 5640295189041616515165641512647513399952299862475037696 * α ^ 17 * (16 - α) ^ 13 + 8096357711013760274749679034695047723667449284765784576 * α ^ 18 * (16 - α) ^ 12 + 9222746840024741255973982987098297227268540123123805184 * α ^ 19 * (16 - α) ^ 11 + 8223039813167952720182093497637178426661494992975589120 * α ^ 20 * (16 - α) ^ 10 + 5704256351282499932163905647696347181598873537091336192 * α ^ 21 * (16 - α) ^ 9 + 3201419973312332497561890234813360990647765548239842304 * α ^ 22 * (16 - α) ^ 8 + 1740681060211180094425255735717618532157429256988792832 * α ^ 23 * (16 - α) ^ 7 + 1171781379026559228219387738006839365835033511446179072 * α ^ 24 * (16 - α) ^ 6 + 856349049543820949149124961191230752126749714115924992 * α ^ 25 * (16 - α) ^ 5 + 505504390045160314727256739583393494736411020808873472 * α ^ 26 * (16 - α) ^ 4 + 207885993237921287478858446074371829024853091294110720 * α ^ 27 * (16 - α) ^ 3 + 54498421679605652502910205539029441943284379111601920 * α ^ 28 * (16 - α) ^ 2 + 7954898798277651559977779244576588075469014026035200 * α ^ 29 * (16 - α) ^ 1 + 458384953904887998462676380172134968211581830656000 * α ^ 30 := by - ring + bernstein_ring α (16 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (16 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 32 ≤ n) (h1 : n ≤ 33) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (33 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (33 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 32) (n := n) (n₁ := 33) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((32 : ℕ) : ℝ) - 4 = 28 by norm_num] at hb - rw [show (28 : ℝ) / 2 = ((14 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 31) + 1 / (4 * 31 * (3 + α)) + (1 - 2 * α / 32) ^ 2 * 33 * 32 * (33 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 31 * (3 + α)) ^ 14)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 32 ≤ n) (h1 : n ≤ 33) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 32) (n₁ := 33) (k := 14) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B32_33 diff --git a/Sendov/FiniteRange/Degree34_35.lean b/Sendov/FiniteRange/Degree34_35.lean index ca79541..419c169 100644 --- a/Sendov/FiniteRange/Degree34_35.lean +++ b/Sendov/FiniteRange/Degree34_35.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 34 to 35 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 34) (gg1 34) (gg2 34) 15)) α := by - refine pev_wsum_eq_of_packed (gg0 34) (gg1 34) (gg2 34) 15 46 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 34) (gg1 34) (gg2 34) 15 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 34) (gg1 34) (gg2 34) 15 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 34) (gg1 34) (gg2 34) 3 (by simp) (by simp) (by simp) 15) - · rfl + refine pev_moment_eq_of_packed_bounds 34 15 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 34 α t ^ 15) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 13399266531718143561671329774091404024125 + 71849885492802810816842838949259978576823 * α + 180538945319091116404922710783631485776255 * α ^ 2 + 282156930875912547195503056499665223632869 * α ^ 3 + 306955881947816717076752055353611201997433 * α ^ 4 + 246444353252723432574425088492703243027965 * α ^ 5 + 151019226036657912949719936683240321200053 * α ^ 6 + 72028327083715746440304318235594953916857 * α ^ 7 + 27007117326925331098314143315441103261561 * α ^ 8 + 7979024241553623900285784858349597089245 * α ^ 9 + 1847320854708526473676328223562198887417 * α ^ 10 + 329938708337757813561795624655269556461 * α ^ 11 + 43878641971714608549212527982241857715 * α ^ 12 + 3911666704610568428372170990877699643 * α ^ 13 + 54464632768848512857832724331386693 * α ^ 14 - 300202584430678770107735269889128119 * α ^ 15 + 16644540127319447720784804793743786 * α ^ 16 + 228891055611380679685401624709920 * α ^ 17 + 16200353115196577039237473724202 * α ^ 18 + 510663548855848557629648901888 * α ^ 19 - 6873476290889727146869228680 * α ^ 20 - 1591901557063130972106786240 * α ^ 21 - 90385492060860172817322528 * α ^ 22 - 3241298369821124224491264 * α ^ 23 - 83924819944658782911360 * α ^ 24 - 1639999868886062272512 * α ^ 25 - 24549687196522919424 * α ^ 26 - 281209623855906816 * α ^ 27 - 2429673447720960 * α ^ 28 - 15359508856832 * α ^ 29 - 67149078528 * α ^ 30 - 181665792 * α ^ 31 - 229376 * α ^ 32 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 32 * (13399266531718143561671329774091404024125 + 71849885492802810816842838949259978576823 * α + 180538945319091116404922710783631485776255 * α ^ 2 + 282156930875912547195503056499665223632869 * α ^ 3 + 306955881947816717076752055353611201997433 * α ^ 4 + 246444353252723432574425088492703243027965 * α ^ 5 + 151019226036657912949719936683240321200053 * α ^ 6 + 72028327083715746440304318235594953916857 * α ^ 7 + 27007117326925331098314143315441103261561 * α ^ 8 + 7979024241553623900285784858349597089245 * α ^ 9 + 1847320854708526473676328223562198887417 * α ^ 10 + 329938708337757813561795624655269556461 * α ^ 11 + 43878641971714608549212527982241857715 * α ^ 12 + 3911666704610568428372170990877699643 * α ^ 13 + 54464632768848512857832724331386693 * α ^ 14 - 300202584430678770107735269889128119 * α ^ 15 + 16644540127319447720784804793743786 * α ^ 16 + 228891055611380679685401624709920 * α ^ 17 + 16200353115196577039237473724202 * α ^ 18 + 510663548855848557629648901888 * α ^ 19 - 6873476290889727146869228680 * α ^ 20 - 1591901557063130972106786240 * α ^ 21 - 90385492060860172817322528 * α ^ 22 - 3241298369821124224491264 * α ^ 23 - 83924819944658782911360 * α ^ 24 - 1639999868886062272512 * α ^ 25 - 24549687196522919424 * α ^ 26 - 281209623855906816 * α ^ 27 - 2429673447720960 * α ^ 28 - 15359508856832 * α ^ 29 - 67149078528 * α ^ 30 - 181665792 * α ^ 31 - 229376 * α ^ 32) = 13399266531718143561671329774091404024125 * (17 - α) ^ 32 + 1650224582392628377859810814908344564577991 * α ^ 1 * (17 - α) ^ 31 + 96686681051656613148087819110678844495289416 * α ^ 2 * (17 - α) ^ 30 + 3585943364127806535175218856650333719997862062 * α ^ 3 * (17 - α) ^ 29 + 94506835391773642943632702539240023655585239976 * α ^ 4 * (17 - α) ^ 28 + 1883536024491957754295155022173521798076402761306 * α ^ 5 * (17 - α) ^ 27 + 29498713431163207985062885810393117977995458611360 * α ^ 6 * (17 - α) ^ 26 + 372444567835409169626366992601449865136908523715554 * α ^ 7 * (17 - α) ^ 25 + 3859379869369491930046652624818040581445251700417436 * α ^ 8 * (17 - α) ^ 24 + 33247489122948312922756142978001205956348938877434094 * α ^ 9 * (17 - α) ^ 23 + 240361064800204816769332884725722337309385385508245284 * α ^ 10 * (17 - α) ^ 22 + 1468297579222476711150318215261328148465442277706125318 * α ^ 11 * (17 - α) ^ 21 + 7616476027067108231341929094010647728198437294881398882 * α ^ 12 * (17 - α) ^ 20 + 33663083667068151985435771538517917417846319467001398040 * α ^ 13 * (17 - α) ^ 19 + 127012191711700706943666066187667778984137340603569186202 * α ^ 14 * (17 - α) ^ 18 + 408483237363770470892000173862806063969919527704726536136 * α ^ 15 * (17 - α) ^ 17 + 1112699056508533083404960444025601114584826187986242644199 * α ^ 16 * (17 - α) ^ 16 + 2541228944450694617802464818664598037324243538753868594135 * α ^ 17 * (17 - α) ^ 15 + 4808963007779256297034335517823636520905050012269500452122 * α ^ 18 * (17 - α) ^ 14 + 7449105095546099705010373449780908551641339483192620776998 * α ^ 19 * (17 - α) ^ 13 + 9324511543492008692105399378290148512417024338959823894774 * α ^ 20 * (17 - α) ^ 12 + 9297740340616393778000297728009621202927136433782291562398 * α ^ 21 * (17 - α) ^ 11 + 7274130570772010006967162133652153552632813945113550333758 * α ^ 22 * (17 - α) ^ 10 + 4441828800293274983181495636158215106270810356077510048966 * α ^ 23 * (17 - α) ^ 9 + 2239471510489480023234027273281488727890334103099818233488 * α ^ 24 * (17 - α) ^ 8 + 1180013639374388482169007814986614403675247990630945641900 * α ^ 25 * (17 - α) ^ 7 + 818218224361787722039978747842931615637242518870584611650 * α ^ 26 * (17 - α) ^ 6 + 587927012852098590957570014487485323178262550641905003190 * α ^ 27 * (17 - α) ^ 5 + 327641901908612799526209846021045735379467528409310341680 * α ^ 28 * (17 - α) ^ 4 + 125868057563181650595391338568950934373772184543193971640 * α ^ 29 * (17 - α) ^ 3 + 30847873348677414400175155768102397838878364715388408640 * α ^ 30 * (17 - α) ^ 2 + 4226337377572378619631312225122710192128000000000000000 * α ^ 31 * (17 - α) ^ 1 + 229862066916150806363247669850238091264000000000000000 * α ^ 32 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 34 ≤ n) (h1 : n ≤ 35) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (35 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (35 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 34) (n := n) (n₁ := 35) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((34 : ℕ) : ℝ) - 4 = 30 by norm_num] at hb - rw [show (30 : ℝ) / 2 = ((15 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 33) + 1 / (4 * 33 * (3 + α)) + (1 - 2 * α / 34) ^ 2 * 35 * 34 * (35 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 33 * (3 + α)) ^ 15)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 34 ≤ n) (h1 : n ≤ 35) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 34) (n₁ := 35) (k := 15) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B34_35 diff --git a/Sendov/FiniteRange/Degree36_37.lean b/Sendov/FiniteRange/Degree36_37.lean index 8158a91..cc7c28b 100644 --- a/Sendov/FiniteRange/Degree36_37.lean +++ b/Sendov/FiniteRange/Degree36_37.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 36 to 37 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 36) (gg1 36) (gg2 36) 16)) α := by - refine pev_wsum_eq_of_packed (gg0 36) (gg1 36) (gg2 36) 16 49 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 36) (gg1 36) (gg2 36) 16 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 36) (gg1 36) (gg2 36) 16 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 36) (gg1 36) (gg2 36) 3 (by simp) (by simp) (by simp) 16) - · rfl + refine pev_moment_eq_of_packed_bounds 36 16 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 36 α t ^ 16) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 1340862494179159723457439116979158935546875000 + 7637969043915714340759947223349395751953125000 * α + 20469159372189815097433030931483526306152343750 * α ^ 2 + 34274361726863699928017616105749597900390625000 * α ^ 3 + 40158420010659405404629812835302538476562500000 * α ^ 4 + 34937401402816329855420946112276054381835937500 * α ^ 5 + 23367211725435618964676169025739806953662109375 * α ^ 6 + 12270122821734134505495363628244218847460937500 * α ^ 7 + 5119554315996410501630574472803506399777343750 * α ^ 8 + 1706085086162412699720364430591688420225000000 * α ^ 9 + 453657266969080072299236418096329864193140625 * α ^ 10 + 95512498825559724167251930963289431001100000 * α ^ 11 + 15651081746907280778533576463846724310987500 * α ^ 12 + 1925946170421648313592236215225863164072500 * α ^ 13 + 160780952585487184902439630853241164106375 * α ^ 14 + 2481149473011100292550908813010287159220 * α ^ 15 - 11166042731030257542258130633810209326742 * α ^ 16 + 567791382062622839648458479091876877544 * α ^ 17 + 6430218988186661251397393995576293933 * α ^ 18 + 498747834176692841464289681241746784 * α ^ 19 + 18702443537088721760797370916939480 * α ^ 20 + 57367909378421946482804755695328 * α ^ 21 - 35467391809924321679454804549376 * α ^ 22 - 2344076836762407866768807250432 * α ^ 23 - 91095016683709754039240857216 * α ^ 24 - 2528503186830718445641541120 * α ^ 25 - 53176733671797993730857984 * α ^ 26 - 866597180873027929669632 * α ^ 27 - 11005160172719761434624 * α ^ 28 - 108265710516964073472 * α ^ 29 - 810954254409318400 * α ^ 30 - 4477829562761216 * α ^ 31 - 17204805009408 * α ^ 32 - 41120301056 * α ^ 33 - 46071808 * α ^ 34 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 34 * (1340862494179159723457439116979158935546875000 + 7637969043915714340759947223349395751953125000 * α + 20469159372189815097433030931483526306152343750 * α ^ 2 + 34274361726863699928017616105749597900390625000 * α ^ 3 + 40158420010659405404629812835302538476562500000 * α ^ 4 + 34937401402816329855420946112276054381835937500 * α ^ 5 + 23367211725435618964676169025739806953662109375 * α ^ 6 + 12270122821734134505495363628244218847460937500 * α ^ 7 + 5119554315996410501630574472803506399777343750 * α ^ 8 + 1706085086162412699720364430591688420225000000 * α ^ 9 + 453657266969080072299236418096329864193140625 * α ^ 10 + 95512498825559724167251930963289431001100000 * α ^ 11 + 15651081746907280778533576463846724310987500 * α ^ 12 + 1925946170421648313592236215225863164072500 * α ^ 13 + 160780952585487184902439630853241164106375 * α ^ 14 + 2481149473011100292550908813010287159220 * α ^ 15 - 11166042731030257542258130633810209326742 * α ^ 16 + 567791382062622839648458479091876877544 * α ^ 17 + 6430218988186661251397393995576293933 * α ^ 18 + 498747834176692841464289681241746784 * α ^ 19 + 18702443537088721760797370916939480 * α ^ 20 + 57367909378421946482804755695328 * α ^ 21 - 35467391809924321679454804549376 * α ^ 22 - 2344076836762407866768807250432 * α ^ 23 - 91095016683709754039240857216 * α ^ 24 - 2528503186830718445641541120 * α ^ 25 - 53176733671797993730857984 * α ^ 26 - 866597180873027929669632 * α ^ 27 - 11005160172719761434624 * α ^ 28 - 108265710516964073472 * α ^ 29 - 810954254409318400 * α ^ 30 - 4477829562761216 * α ^ 31 - 17204805009408 * α ^ 32 - 41120301056 * α ^ 33 - 46071808 * α ^ 34) = 1340862494179159723457439116979158935546875000 * (17 - α) ^ 34 + 175434798548658574390472032774231131591796875000 * α ^ 1 * (17 - α) ^ 33 + 10952711551434080913184099676123058282165527343750 * α ^ 2 * (17 - α) ^ 32 + 434270856341448311475241819934694889103759765625000 * α ^ 3 * (17 - α) ^ 31 + 12278911436635306192132622790762987549533349609375000 * α ^ 4 * (17 - α) ^ 30 + 263557269216566555320865047728777428822756844726562500 * α ^ 5 * (17 - α) ^ 29 + 4463883671586096731770907085592494749976786136669921875 * α ^ 6 * (17 - α) ^ 28 + 61225965954407894273160354546600964058305754660156250000 * α ^ 7 * (17 - α) ^ 27 + 692587772613132439128122751366082049061109249880812500000 * α ^ 8 * (17 - α) ^ 26 + 6547796240902796556445336115711018473638408241918575000000 * α ^ 9 * (17 - α) ^ 25 + 52247549382615756077051379940154408637849061298491733812500 * α ^ 10 * (17 - α) ^ 24 + 354466647029909646510470656479599263564041502427407695300000 * α ^ 11 * (17 - α) ^ 23 + 2055889704738111710267568200183486826512215613684783110200000 * α ^ 12 * (17 - α) ^ 22 + 10234888840339768071474956793147766100757409148665132934370000 * α ^ 13 * (17 - α) ^ 21 + 43858398380617067829266771169258660902757314148335253721083000 * α ^ 14 * (17 - α) ^ 20 + 162055210405371666456160142527627828678422430377426835106958960 * α ^ 15 * (17 - α) ^ 19 + 516145320938971158929091669417239050325330885780111469198875088 * α ^ 16 * (17 - α) ^ 18 + 1412064392511895951084181534107896493318729250846824514725955712 * α ^ 17 * (17 - α) ^ 17 + 3296410975824492770073801068890863487757382337405699389044881152 * α ^ 18 * (17 - α) ^ 16 + 6510700656466073656283913487155596019027366109135146309819197400 * α ^ 19 * (17 - α) ^ 15 + 10778762671920232847172097564072974706837835927532659281695627000 * α ^ 20 * (17 - α) ^ 14 + 14812853870469700737370316477184138613188186623760145268072292500 * α ^ 21 * (17 - α) ^ 13 + 16720671608226908945079705353880617034286101018111021059080009375 * α ^ 22 * (17 - α) ^ 12 + 15317420704224111419919616448379092129752276964124634080685800000 * α ^ 23 * (17 - α) ^ 11 + 11238165133613859896218350103981386092933200214685034701456250000 * α ^ 24 * (17 - α) ^ 10 + 6544374325964212483346602292437892685413037367000381149781250000 * α ^ 25 * (17 - α) ^ 9 + 3087009276202780754337495361663231009012869918782181865781250000 * α ^ 26 * (17 - α) ^ 8 + 1334541850899219151104336491093618277155327063911213757812500000 * α ^ 27 * (17 - α) ^ 7 + 671021217962301496929047441300025617792685964844905141406250000 * α ^ 28 * (17 - α) ^ 6 + 390013014583991314611686405951849748841394880271566591796875000 * α ^ 29 * (17 - α) ^ 5 + 198126638262411132449557681354886342145672562882243054199218750 * α ^ 30 * (17 - α) ^ 4 + 72921376026239920902575443619361410154303245019324218750000000 * α ^ 31 * (17 - α) ^ 3 + 17546793780907574541651374555825605095190744540455322265625000 * α ^ 32 * (17 - α) ^ 2 + 2427279654890969862947772530516229556781067701712646484375000 * α ^ 33 * (17 - α) ^ 1 + 141776547693471981630558155006611207847406241325378417968750 * α ^ 34 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 36 ≤ n) (h1 : n ≤ 37) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (37 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (37 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 36) (n := n) (n₁ := 37) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((36 : ℕ) : ℝ) - 4 = 32 by norm_num] at hb - rw [show (32 : ℝ) / 2 = ((16 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 35) + 1 / (4 * 35 * (3 + α)) + (1 - 2 * α / 36) ^ 2 * 37 * 36 * (37 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 35 * (3 + α)) ^ 16)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 36 ≤ n) (h1 : n ≤ 37) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 36) (n₁ := 37) (k := 16) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B36_37 diff --git a/Sendov/FiniteRange/Degree38_39.lean b/Sendov/FiniteRange/Degree38_39.lean index 088a6ff..1a51a12 100644 --- a/Sendov/FiniteRange/Degree38_39.lean +++ b/Sendov/FiniteRange/Degree38_39.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 38 to 39 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 38) (gg1 38) (gg2 38) 17)) α := by - refine pev_wsum_eq_of_packed (gg0 38) (gg1 38) (gg2 38) 17 52 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 38) (gg1 38) (gg2 38) 17 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 38) (gg1 38) (gg2 38) 17 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 38) (gg1 38) (gg2 38) 3 (by simp) (by simp) (by simp) 17) - · rfl + refine pev_moment_eq_of_packed_bounds 38 17 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 38 α t ^ 17) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 263016241667210021671084890841481617690003189110 + 1586061041777522258785370750920508059260325100670 * α + 4515569002916763022083813591656453793545843463960 * α ^ 2 + 8064535450447153538886731843043227730967854436080 * α ^ 3 + 10124049292126400106014356225197947036232792604485 * α ^ 4 + 9486490487762873429871569630238934346081556621609 * α ^ 5 + 6875502816855646349457849536822502570739478645343 * α ^ 6 + 3940536916491738744952644524802984325688545318839 * α ^ 7 + 1810118648803944257004276579444295893576974412957 * α ^ 8 + 671223601039568220250335587923837679954504671929 * α ^ 9 + 201302327242382412835780103712068254297083069927 * α ^ 10 + 48665320464285286858138805925504857552220130935 * α ^ 11 + 9395447364524194147939717327946455319249576385 * α ^ 12 + 1422463731757903542558687467068487748999154005 * α ^ 13 + 162936488968328754409221779604516446092275015 * α ^ 14 + 12804246766409474561270894860455521523191007 * α ^ 15 + 216069416334011168489825518695466581657549 * α ^ 16 - 808211600142399392096627843592018139890543 * α ^ 17 + 38042736580603120168867477319356142859621 * α ^ 18 + 344373790265831271857444699712655317117 * α ^ 19 + 29315226870352164747186119924985775776 * α ^ 20 + 1247198097855472249813750976434442560 * α ^ 21 + 16662184536264199136681220318869840 * α ^ 22 - 1406905416514864930658623327447840 * α ^ 23 - 115154592405960528415597818779200 * α ^ 24 - 4877945634325956011421670432000 * α ^ 25 - 144681078013665355320791476480 * α ^ 26 - 3249838030348665967746429440 * α ^ 27 - 56982963376184696008104960 * α ^ 28 - 788738718851438284800000 * α ^ 29 - 8618882420705188376576 * α ^ 30 - 73677168662756319232 * α ^ 31 - 483260148118798336 * α ^ 32 - 2351449584959488 * α ^ 33 - 8003806560256 * α ^ 34 - 17023172608 * α ^ 35 - 17039360 * α ^ 36 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 36 * (263016241667210021671084890841481617690003189110 + 1586061041777522258785370750920508059260325100670 * α + 4515569002916763022083813591656453793545843463960 * α ^ 2 + 8064535450447153538886731843043227730967854436080 * α ^ 3 + 10124049292126400106014356225197947036232792604485 * α ^ 4 + 9486490487762873429871569630238934346081556621609 * α ^ 5 + 6875502816855646349457849536822502570739478645343 * α ^ 6 + 3940536916491738744952644524802984325688545318839 * α ^ 7 + 1810118648803944257004276579444295893576974412957 * α ^ 8 + 671223601039568220250335587923837679954504671929 * α ^ 9 + 201302327242382412835780103712068254297083069927 * α ^ 10 + 48665320464285286858138805925504857552220130935 * α ^ 11 + 9395447364524194147939717327946455319249576385 * α ^ 12 + 1422463731757903542558687467068487748999154005 * α ^ 13 + 162936488968328754409221779604516446092275015 * α ^ 14 + 12804246766409474561270894860455521523191007 * α ^ 15 + 216069416334011168489825518695466581657549 * α ^ 16 - 808211600142399392096627843592018139890543 * α ^ 17 + 38042736580603120168867477319356142859621 * α ^ 18 + 344373790265831271857444699712655317117 * α ^ 19 + 29315226870352164747186119924985775776 * α ^ 20 + 1247198097855472249813750976434442560 * α ^ 21 + 16662184536264199136681220318869840 * α ^ 22 - 1406905416514864930658623327447840 * α ^ 23 - 115154592405960528415597818779200 * α ^ 24 - 4877945634325956011421670432000 * α ^ 25 - 144681078013665355320791476480 * α ^ 26 - 3249838030348665967746429440 * α ^ 27 - 56982963376184696008104960 * α ^ 28 - 788738718851438284800000 * α ^ 29 - 8618882420705188376576 * α ^ 30 - 73677168662756319232 * α ^ 31 - 483260148118798336 * α ^ 32 - 2351449584959488 * α ^ 33 - 8003806560256 * α ^ 34 - 17023172608 * α ^ 35 - 17039360 * α ^ 36) = 263016241667210021671084890841481617690003189110 * (17 - α) ^ 36 + 36431622410237439179510358835941975244265641519350 * α ^ 1 * (17 - α) ^ 35 + 2414405993950912571012301206016550860739344205122390 * α ^ 2 * (17 - α) ^ 34 + 101911987093790495993891637162656810587351337884854450 * α ^ 3 * (17 - α) ^ 33 + 3077136529375910511818308139163370204204710108135348945 * α ^ 4 * (17 - α) ^ 32 + 70767700416372118022916506935148443513144214212984079433 * α ^ 5 * (17 - α) ^ 31 + 1288872796711775738410766166408400924167189843482363181510 * α ^ 6 * (17 - α) ^ 30 + 19083400748229222868616813579365546608706181811242799713442 * α ^ 7 * (17 - α) ^ 29 + 234010152840381946349380212378698061303021231207480935794380 * α ^ 8 * (17 - α) ^ 28 + 2409083298538233479330794311735295130068631390190510305345916 * α ^ 9 * (17 - α) ^ 27 + 21034199072421691415654588980184171455732743682853035936388736 * α ^ 10 * (17 - α) ^ 26 + 156965739060943279756832920952171731542118382822579555902264320 * α ^ 11 * (17 - α) ^ 25 + 1007013809256349634438976269863634909802444822788284670764336920 * α ^ 12 * (17 - α) ^ 24 + 5578883286717752179555968646363028277131383001091676680613578600 * α ^ 13 * (17 - α) ^ 23 + 26778108682132812026449907006307737451347925518376385819177842180 * α ^ 14 * (17 - α) ^ 22 + 111626866485074002051921408370316196620668741767980677786122726476 * α ^ 15 * (17 - α) ^ 21 + 404749936967515936812332395113162625848731824975287760415129552520 * α ^ 16 * (17 - α) ^ 20 + 1276851853339474854752478301460896841716394369316599334161708835864 * α ^ 17 * (17 - α) ^ 19 + 3498152021559931653758754395800484089136347016702124578632888785870 * α ^ 18 * (17 - α) ^ 18 + 8288489989122825212327334609599909543398390901155522489744660111602 * α ^ 19 * (17 - α) ^ 17 + 16882651085623904442176264117055333605492167285591363946133352298205 * α ^ 20 * (17 - α) ^ 16 + 29353791640642678379569945946711713118769355441603863420459332583845 * α ^ 21 * (17 - α) ^ 15 + 43236117652901827874516888436407546705327794671242323926919339677542 * α ^ 22 * (17 - α) ^ 14 + 53514417120286757722309232459981186747567529389425853874706900031330 * α ^ 23 * (17 - α) ^ 13 + 55160684404854002133844526815694799322288761295220210026216244417256 * α ^ 24 * (17 - α) ^ 12 + 46859199139271497704482066786546595457658791134521569883679868639464 * α ^ 25 * (17 - α) ^ 11 + 32418496139685480362601229821482044096981462148753646754741401291900 * α ^ 26 * (17 - α) ^ 10 + 18064228253690987870059860955691584275196341087334183534685080363332 * α ^ 27 * (17 - α) ^ 9 + 8116057087439008484605418610430390304640800612633036742729214781010 * α ^ 28 * (17 - α) ^ 8 + 3094097281163451800860397134053738271256213921040320763043485148866 * α ^ 29 * (17 - α) ^ 7 + 1174308203032074417716759573429346434013837010515376831055725367856 * α ^ 30 * (17 - α) ^ 6 + 514147619716779490199856234417204230784802425196644936366761384400 * α ^ 31 * (17 - α) ^ 5 + 225918222596880524574644194822909829140432799329070928335788308150 * α ^ 32 * (17 - α) ^ 4 + 78378867100425150377346627184325309287549636198734508005978549750 * α ^ 33 * (17 - α) ^ 3 + 18415214840638052851390630908893866826964214257262459916509597440 * α ^ 34 * (17 - α) ^ 2 + 2542392303855460193752438935467117379253704583645900859266878840 * α ^ 35 * (17 - α) ^ 1 + 152938893321252958580549098618153156123487784458433341017459200 * α ^ 36 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 38 ≤ n) (h1 : n ≤ 39) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (39 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (39 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 38) (n := n) (n₁ := 39) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((38 : ℕ) : ℝ) - 4 = 34 by norm_num] at hb - rw [show (34 : ℝ) / 2 = ((17 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 37) + 1 / (4 * 37 * (3 + α)) + (1 - 2 * α / 38) ^ 2 * 39 * 38 * (39 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 37 * (3 + α)) ^ 17)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 38 ≤ n) (h1 : n ≤ 39) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 38) (n₁ := 39) (k := 17) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B38_39 diff --git a/Sendov/FiniteRange/Degree40_41.lean b/Sendov/FiniteRange/Degree40_41.lean index 64c0604..e86625b 100644 --- a/Sendov/FiniteRange/Degree40_41.lean +++ b/Sendov/FiniteRange/Degree40_41.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 40 to 41 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 40) (gg1 40) (gg2 40) 18)) α := by - refine pev_wsum_eq_of_packed (gg0 40) (gg1 40) (gg2 40) 18 55 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 40) (gg1 40) (gg2 40) 18 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 40) (gg1 40) (gg2 40) 18 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 40) (gg1 40) (gg2 40) 3 (by simp) (by simp) (by simp) 18) - · rfl + refine pev_moment_eq_of_packed_bounds 40 18 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 40 α t ^ 18) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 653328533869198792815460418567456328463360027860000 + 4157882298167732116226370617284188848212873011241200 * α + 12532182988010399386002617462745633312768152237121570 * α ^ 2 + 23778313854745445633723704693422676769304621097023060 * α ^ 3 + 31839691004956228828005033576674262680347642949789970 * α ^ 4 + 31966947875077850162540664582127534223677059725715480 * α ^ 5 + 24954452263842718944480719755732872419125467194310990 * α ^ 6 + 15498456398852386516930447507216103141023058978163900 * α ^ 7 + 7770525510255924837049186376423929043180641908035178 * α ^ 8 + 3172282421659051612506049390871943668830947112996128 * α ^ 9 + 1058580212642493803810630674822381941853484677345557 * α ^ 10 + 288603554681274589435804606029301359165948874522986 * α ^ 11 + 63964171378367904791712568423672278670444648520985 * α ^ 12 + 11403554558448059539985445321284291979921951939708 * α ^ 13 + 1604683068013899575897130419685118852646893739688 * α ^ 14 + 171973766788073602692262435759609700705097645552 * α ^ 15 + 12777319017916275759622043304057680904260665896 * α ^ 16 + 232511338229217727198624028718607742301689616 * α ^ 17 - 736152391583269859036039443814447014605197787 * α ^ 18 + 32344027389559443630831441714104468449897746 * α ^ 19 + 226192739078384191702850277844962783099369 * α ^ 20 + 21321388850847068435151126284573459826132 * α ^ 21 + 1002825060545767936823647697965569833484 * α ^ 22 + 20605096429138626101144518690493027136 * α ^ 23 - 588379321688541475027751329888140192 * α ^ 24 - 68916522458163479393324809629479808 * α ^ 25 - 3219999749177967431080752136593024 * α ^ 26 - 101984865798504570834320095942656 * α ^ 27 - 2433981075208899701339322164736 * α ^ 28 - 45526079756647968714698102784 * α ^ 29 - 678401876172921453922277376 * α ^ 30 - 8091691517611230731255808 * α ^ 31 - 76978691001245722632192 * α ^ 32 - 577480811034021101568 * α ^ 33 - 3345672064015171584 * α ^ 34 - 14456978064408576 * α ^ 35 - 43900332474368 * α ^ 36 - 83629441024 * α ^ 37 - 75235328 * α ^ 38 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 38 * (653328533869198792815460418567456328463360027860000 + 4157882298167732116226370617284188848212873011241200 * α + 12532182988010399386002617462745633312768152237121570 * α ^ 2 + 23778313854745445633723704693422676769304621097023060 * α ^ 3 + 31839691004956228828005033576674262680347642949789970 * α ^ 4 + 31966947875077850162540664582127534223677059725715480 * α ^ 5 + 24954452263842718944480719755732872419125467194310990 * α ^ 6 + 15498456398852386516930447507216103141023058978163900 * α ^ 7 + 7770525510255924837049186376423929043180641908035178 * α ^ 8 + 3172282421659051612506049390871943668830947112996128 * α ^ 9 + 1058580212642493803810630674822381941853484677345557 * α ^ 10 + 288603554681274589435804606029301359165948874522986 * α ^ 11 + 63964171378367904791712568423672278670444648520985 * α ^ 12 + 11403554558448059539985445321284291979921951939708 * α ^ 13 + 1604683068013899575897130419685118852646893739688 * α ^ 14 + 171973766788073602692262435759609700705097645552 * α ^ 15 + 12777319017916275759622043304057680904260665896 * α ^ 16 + 232511338229217727198624028718607742301689616 * α ^ 17 - 736152391583269859036039443814447014605197787 * α ^ 18 + 32344027389559443630831441714104468449897746 * α ^ 19 + 226192739078384191702850277844962783099369 * α ^ 20 + 21321388850847068435151126284573459826132 * α ^ 21 + 1002825060545767936823647697965569833484 * α ^ 22 + 20605096429138626101144518690493027136 * α ^ 23 - 588379321688541475027751329888140192 * α ^ 24 - 68916522458163479393324809629479808 * α ^ 25 - 3219999749177967431080752136593024 * α ^ 26 - 101984865798504570834320095942656 * α ^ 27 - 2433981075208899701339322164736 * α ^ 28 - 45526079756647968714698102784 * α ^ 29 - 678401876172921453922277376 * α ^ 30 - 8091691517611230731255808 * α ^ 31 - 76978691001245722632192 * α ^ 32 - 577480811034021101568 * α ^ 33 - 3345672064015171584 * α ^ 34 - 14456978064408576 * α ^ 35 - 43900332474368 * α ^ 36 - 83629441024 * α ^ 37 - 75235328 * α ^ 38) = 653328533869198792815460418567456328463360027860000 * (17 - α) ^ 38 + 95510483355881000102835796399394550901226522249780400 * α ^ 1 * (17 - α) ^ 37 + 6696398808392555675010412239258164611825635220184428530 * α ^ 2 * (17 - α) ^ 36 + 299794710667200193646561985461117827680016512752986934460 * α ^ 3 * (17 - α) ^ 35 + 9627257466437286352224279116990630228292750401872068624570 * α ^ 4 * (17 - α) ^ 34 + 236169626370579092102401540068424043031156213235832488824240 * α ^ 5 * (17 - α) ^ 33 + 4602580155935131911540977878848744873896752358859535239239310 * α ^ 6 * (17 - α) ^ 32 + 73167568636523068791230387895812989143995323139339741955173340 * α ^ 7 * (17 - α) ^ 31 + 966819100697307203780359917617580768148731765217116962982472158 * α ^ 8 * (17 - α) ^ 30 + 10767130098246849195301111459928119363029994766661588897784000776 * α ^ 9 * (17 - α) ^ 29 + 102122724502527454683682344439666460359467859469480457468195144927 * α ^ 10 * (17 - α) ^ 28 + 831548691595541121952529230262845541710942265958095940858036487578 * α ^ 11 * (17 - α) ^ 27 + 5848940149873603781228937217250745230319503456527981662700527649479 * α ^ 12 * (17 - α) ^ 26 + 35707752760626549856948044943531072922885702324271579224065621550616 * α ^ 13 * (17 - α) ^ 25 + 189904423378547635211179836338153464631558375737888355414680794292332 * α ^ 14 * (17 - α) ^ 24 + 882263986278123132234428133435096956146433318787491830406424008581944 * α ^ 15 * (17 - α) ^ 23 + 3587848295098893896231452077434369033403531934780731646206410657559996 * α ^ 16 * (17 - α) ^ 22 + 12789017524790293159146747559828714620914231030244750348653705133535680 * α ^ 17 * (17 - α) ^ 21 + 39978318616507844028720464128037031241214473591909362382585304014435338 * α ^ 18 * (17 - α) ^ 20 + 109503304419314521695778687533175441622403892877574691241529360322168236 * α ^ 19 * (17 - α) ^ 19 + 262146994169564092167982595241915300650038077337630821023247107830038522 * α ^ 20 * (17 - α) ^ 18 + 546246295187027447378330498619919154502317914469485801874390148357919248 * α ^ 21 * (17 - α) ^ 17 + 985534144714139122250483741567233765101065359192115038605404874832119258 * α ^ 22 * (17 - α) ^ 16 + 1530417579360385957788702153622880731287836667255896423677766156573103972 * α ^ 23 * (17 - α) ^ 15 + 2032430461020079853532514261208602767750794542173780707088682857868910994 * α ^ 24 * (17 - α) ^ 14 + 2292218444285680589433098519469973212042230727005845801142745772952622648 * α ^ 25 * (17 - α) ^ 13 + 2178219997541878792508669700595426088654476354491195218415916040098361367 * α ^ 26 * (17 - α) ^ 12 + 1727949063757596178243483752801428201813213932341449769191552685893782458 * α ^ 27 * (17 - α) ^ 11 + 1131913488897144192892030857095843493930963307289300925015925127269708335 * α ^ 28 * (17 - α) ^ 10 + 605118754195259451063140144378285109492445949756638818759841365239660040 * α ^ 29 * (17 - α) ^ 9 + 261880298008050145266750753761576086552682439953827145257817540609824860 * α ^ 30 * (17 - α) ^ 8 + 92875679601113717412714391333499851806464327195844345337907650773348120 * α ^ 31 * (17 - α) ^ 7 + 29072995044312488455979921670033751326475480533216429941625836322969708 * α ^ 32 * (17 - α) ^ 6 + 9369857362358365457781039003340826933535211191808499527159369766606160 * α ^ 33 * (17 - α) ^ 5 + 3266469696161126128466003284878933770066029563371692346986063283168790 * α ^ 34 * (17 - α) ^ 4 + 1021356923480101951479641774555034890704687659508130011121545901779380 * α ^ 35 * (17 - α) ^ 3 + 230938112747876039693246783422362329462732319382520584715540384755870 * α ^ 36 * (17 - α) ^ 2 + 31563581230674524529692712927313637685716918468331288776448654765600 * α ^ 37 * (17 - α) ^ 1 + 1919753133109689509058670629650134022172078593720565270277159571400 * α ^ 38 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 40 ≤ n) (h1 : n ≤ 41) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (41 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (41 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 40) (n := n) (n₁ := 41) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((40 : ℕ) : ℝ) - 4 = 36 by norm_num] at hb - rw [show (36 : ℝ) / 2 = ((18 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 39) + 1 / (4 * 39 * (3 + α)) + (1 - 2 * α / 40) ^ 2 * 41 * 40 * (41 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 39 * (3 + α)) ^ 18)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 40 ≤ n) (h1 : n ≤ 41) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 40) (n₁ := 41) (k := 18) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B40_41 diff --git a/Sendov/FiniteRange/Degree42_43.lean b/Sendov/FiniteRange/Degree42_43.lean index e605f05..dacddf3 100644 --- a/Sendov/FiniteRange/Degree42_43.lean +++ b/Sendov/FiniteRange/Degree42_43.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 42 to 43 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 42) (gg1 42) (gg2 42) 19)) α := by - refine pev_wsum_eq_of_packed (gg0 42) (gg1 42) (gg2 42) 19 58 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 42) (gg1 42) (gg2 42) 19 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 42) (gg1 42) (gg2 42) 19 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 42) (gg1 42) (gg2 42) 3 (by simp) (by simp) (by simp) 19) - · rfl + refine pev_moment_eq_of_packed_bounds 42 19 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 42 α t ^ 19) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 1280928413415314397834869540387070773955050164531041030 + 8579596886133703000731870831081948314922065693350883370 * α + 27292297105154921952287403075281892231896279402880100950 * α ^ 2 + 54824009941858550176912358984664841592247597016637905770 * α ^ 3 + 77993650469489645959523814188253045468476206212378807150 * α ^ 4 + 83524935090318289329452750100125758268073947901595075110 * α ^ 5 + 69864044339248988241671793073316243248508325653371578960 * α ^ 6 + 46735744905970337877740011413866843308996677044757141876 * α ^ 7 + 25392412342651970229153408582081225972535817324636108157 * α ^ 8 + 11314456845720888558092495939704512751963595258860145451 * α ^ 9 + 4156583831931947231874280330967249614130082308880369711 * α ^ 10 + 1260841374442113914894353137980805411382131606623222097 * α ^ 11 + 315103088046242389807187425423229491723179974811052320 * α ^ 12 + 64474796856269342035203905269807575254628539228620830 * α ^ 13 + 10677851103479065036063092086580878016800993639429844 * α ^ 14 + 1403715274370741006129430385190458757679221958797478 * α ^ 15 + 141371440744366093378881819780110077583832470458881 * α ^ 16 + 9967433380699679025437124999852577310642665327515 * α ^ 17 + 193067019640064558163668388981876117360705214251 * α ^ 18 - 526348205714148288340590540843861549545919252135 * α ^ 19 + 21747004181067783415574645835305370950903835816 * α ^ 20 + 112680245244072016728446540389593488784136590 * α ^ 21 + 11981738273725154350817268365041623637172994 * α ^ 22 + 613973728602142293085684365363276715529976 * α ^ 23 + 15948973394297291153786386954935347707464 * α ^ 24 - 107684213318232680083685034683113736832 * α ^ 25 - 31027964293347059199661593149947343808 * α ^ 26 - 1633467609886255958992085630289238016 * α ^ 27 - 55350060514047685232072125284311296 * α ^ 28 - 1399005645314407761350477999499264 * α ^ 29 - 27739113827411317709592921773056 * α ^ 30 - 440917774047260414297889849344 * α ^ 31 - 5667329623457291353154629632 * α ^ 32 - 58939961119748330433282048 * α ^ 33 - 492976521437911894081536 * α ^ 34 - 3273203375389549068288 * α ^ 35 - 16876898137105432576 * α ^ 36 - 65205684590477312 * α ^ 37 - 177752858296320 * α ^ 38 - 305048059904 * α ^ 39 - 247988224 * α ^ 40 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 40 * (1280928413415314397834869540387070773955050164531041030 + 8579596886133703000731870831081948314922065693350883370 * α + 27292297105154921952287403075281892231896279402880100950 * α ^ 2 + 54824009941858550176912358984664841592247597016637905770 * α ^ 3 + 77993650469489645959523814188253045468476206212378807150 * α ^ 4 + 83524935090318289329452750100125758268073947901595075110 * α ^ 5 + 69864044339248988241671793073316243248508325653371578960 * α ^ 6 + 46735744905970337877740011413866843308996677044757141876 * α ^ 7 + 25392412342651970229153408582081225972535817324636108157 * α ^ 8 + 11314456845720888558092495939704512751963595258860145451 * α ^ 9 + 4156583831931947231874280330967249614130082308880369711 * α ^ 10 + 1260841374442113914894353137980805411382131606623222097 * α ^ 11 + 315103088046242389807187425423229491723179974811052320 * α ^ 12 + 64474796856269342035203905269807575254628539228620830 * α ^ 13 + 10677851103479065036063092086580878016800993639429844 * α ^ 14 + 1403715274370741006129430385190458757679221958797478 * α ^ 15 + 141371440744366093378881819780110077583832470458881 * α ^ 16 + 9967433380699679025437124999852577310642665327515 * α ^ 17 + 193067019640064558163668388981876117360705214251 * α ^ 18 - 526348205714148288340590540843861549545919252135 * α ^ 19 + 21747004181067783415574645835305370950903835816 * α ^ 20 + 112680245244072016728446540389593488784136590 * α ^ 21 + 11981738273725154350817268365041623637172994 * α ^ 22 + 613973728602142293085684365363276715529976 * α ^ 23 + 15948973394297291153786386954935347707464 * α ^ 24 - 107684213318232680083685034683113736832 * α ^ 25 - 31027964293347059199661593149947343808 * α ^ 26 - 1633467609886255958992085630289238016 * α ^ 27 - 55350060514047685232072125284311296 * α ^ 28 - 1399005645314407761350477999499264 * α ^ 29 - 27739113827411317709592921773056 * α ^ 30 - 440917774047260414297889849344 * α ^ 31 - 5667329623457291353154629632 * α ^ 32 - 58939961119748330433282048 * α ^ 33 - 492976521437911894081536 * α ^ 34 - 3273203375389549068288 * α ^ 35 - 16876898137105432576 * α ^ 36 - 65205684590477312 * α ^ 37 - 177752858296320 * α ^ 38 - 305048059904 * α ^ 39 - 247988224 * α ^ 40) = 1280928413415314397834869540387070773955050164531041030 * (17 - α) ^ 40 + 197090283600885526925836585743875952311877123368206658490 * α ^ 1 * (17 - α) ^ 39 + 14574870761360362764007488091265713791496293430458196852260 * α ^ 2 * (17 - α) ^ 38 + 689807122352331972850018568182567669403146541709879062869200 * α ^ 3 * (17 - α) ^ 37 + 23474981116788659940295903209229597513213621976643052103205180 * α ^ 4 * (17 - α) ^ 36 + 611866838450106888263269653882018737667714606579935222429231160 * α ^ 5 * (17 - α) ^ 35 + 12704966108874081414158869474590380254978128823530400951437383070 * α ^ 6 * (17 - α) ^ 34 + 215835205701475999098573854286109430455663338527171355584817462378 * α ^ 7 * (17 - α) ^ 33 + 3057463015648964051048726715818912718934404644565989436353377379661 * α ^ 8 * (17 - α) ^ 32 + 36627145478607558025819186137856364423514446441125420313957605902195 * α ^ 9 * (17 - α) ^ 31 + 375047859308149340518089344648422780629330440775991914316145068984356 * α ^ 10 * (17 - α) ^ 30 + 3309722847734299600989754701031358954177490834341008198660668294423486 * α ^ 11 * (17 - α) ^ 29 + 25334280905778547167991484601858053756995044929407956045911106763735047 * α ^ 12 * (17 - α) ^ 28 + 169053231472854221672538042658045160250622512820809581036739296186604987 * α ^ 13 * (17 - α) ^ 27 + 987295696101506016750123997135936935428967974131049275929891243289099020 * α ^ 14 * (17 - α) ^ 26 + 5061855600544715172298535944485508872496786942997547092399772690908724552 * α ^ 15 * (17 - α) ^ 25 + 22836459878606542127997069590698683872398300158025332179037971805498008466 * α ^ 16 * (17 - α) ^ 24 + 90815511641941473829215661492687510352960775737402151799341783414491782134 * α ^ 17 * (17 - α) ^ 23 + 318734183329134027469187419914043420985326381868548104315467322483762890280 * α ^ 18 * (17 - α) ^ 22 + 987849647539835196212635720362290798791340169209853062676349181616504012372 * α ^ 19 * (17 - α) ^ 21 + 2702794013053376717386235575702898281842016607777011413996179654284315020276 * α ^ 20 * (17 - α) ^ 20 + 6518481722287093687872286675516248686966900062551161802625983585543325193064 * α ^ 21 * (17 - α) ^ 19 + 13819577825963737277443482404663949106919306450306673694620269914296761836662 * α ^ 22 * (17 - α) ^ 18 + 25656213473396052436767203417861850495715135024347044339699650611836313451386 * α ^ 23 * (17 - α) ^ 17 + 41518212269954562717893522706197113635871186246049005811923337699275786209441 * α ^ 24 * (17 - α) ^ 16 + 58264237368783003337224503745095851911428895082867699051272864692889281810823 * α ^ 25 * (17 - α) ^ 15 + 70509961613749498938328718833682422186993284582226371629980357718310864201564 * α ^ 26 * (17 - α) ^ 14 + 73129293701134101287464321060861793455351594458440621340710860077426859412246 * α ^ 27 * (17 - α) ^ 13 + 64542036519874264738723665643239022405337439766598405390089713472010764525231 * α ^ 28 * (17 - α) ^ 12 + 48068721003017849550137162829500406726021869001249651041646233420511089834739 * α ^ 29 * (17 - α) ^ 11 + 29908472648708029501911019147420406642840298425192025295010509794183714590200 * α ^ 30 * (17 - α) ^ 10 + 15366480688785955559510007565183167290828149965129842034139827497171629495988 * α ^ 31 * (17 - α) ^ 9 + 6442852602434353997138149389259641709926610254417225973756279884877273521210 * α ^ 32 * (17 - α) ^ 8 + 2192109403287939599157040147405748715444730026475711367949290093543157305286 * α ^ 33 * (17 - α) ^ 7 + 617553044098254770008870419213467265211621023542309177891008000912439731428 * α ^ 34 * (17 - α) ^ 6 + 156511669279787056670653626987150971088769146525896634427590110835904143048 * α ^ 35 * (17 - α) ^ 5 + 40425174529035112350411546621406361023805738975780328231031555794395201242 * α ^ 36 * (17 - α) ^ 4 + 10426184083634003349248930440636043818034523209966796671645165924159912258 * α ^ 37 * (17 - α) ^ 3 + 2178083492795567226675987694618231233066113322011885814782838606188228664 * α ^ 38 * (17 - α) ^ 2 + 290493393201934314395217100992245864671975635874035159763234167124538720 * α ^ 39 * (17 - α) ^ 1 + 17674868145691221378279476901019271057432085542810612311003098402179200 * α ^ 40 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 42 ≤ n) (h1 : n ≤ 43) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (43 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (43 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 42) (n := n) (n₁ := 43) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((42 : ℕ) : ℝ) - 4 = 38 by norm_num] at hb - rw [show (38 : ℝ) / 2 = ((19 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 41) + 1 / (4 * 41 * (3 + α)) + (1 - 2 * α / 42) ^ 2 * 43 * 42 * (43 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 41 * (3 + α)) ^ 19)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 42 ≤ n) (h1 : n ≤ 43) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 42) (n₁ := 43) (k := 19) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B42_43 diff --git a/Sendov/FiniteRange/Degree44_45.lean b/Sendov/FiniteRange/Degree44_45.lean index 535bae3..af78c75 100644 --- a/Sendov/FiniteRange/Degree44_45.lean +++ b/Sendov/FiniteRange/Degree44_45.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 44 to 45 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 44) (gg1 44) (gg2 44) 20)) α := by - refine pev_wsum_eq_of_packed (gg0 44) (gg1 44) (gg2 44) 20 61 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 44) (gg1 44) (gg2 44) 20 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 44) (gg1 44) (gg2 44) 20 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 44) (gg1 44) (gg2 44) 3 (by simp) (by simp) (by simp) 20) - · rfl + refine pev_moment_eq_of_packed_bounds 44 20 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 44 α t ^ 20) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 234355849074955263951049856572420428528087559257217338000 + 1647917825991745087828090979449220009324402935342213794192 * α + 5517259206635462357799308151379743852022400880405143709300 * α ^ 2 + 11697286850057325472448884282596125036178461096427071180160 * α ^ 3 + 17618194225546020573784427664650585416610740635319786403400 * α ^ 4 + 20046068608053045224231426681510601856273741292025591141480 * α ^ 5 + 17885461556571898483672892064956643539473640662999345701666 * α ^ 6 + 12820152657712533249363000294926617606868677915971896670240 * α ^ 7 + 7502523555651917287805352494007861019866814933742609160696 * α ^ 8 + 3622686298843516098851206612510488687148684155393129482472 * α ^ 9 + 1452571052316260978855070270500133585694231422375833061090 * α ^ 10 + 485064610274304784360415817487598469472479148412401415808 * α ^ 11 + 134868827326575807784515799657395435527619954194004227748 * α ^ 12 + 31113923159253038634767916248106358904477281041358348956 * α ^ 13 + 5912609861703141760519754094833940739302488844248812479 * α ^ 14 + 914297729950293095944937323513702712183136890515661088 * α ^ 15 + 112786258002906693411402876201621614411462995639363644 * α ^ 16 + 10715561597079704979556413609803278787797162405942296 * α ^ 17 + 719193622230655390355126847425184862615908011115060 * α ^ 18 + 14657836127065470780938993503699490899434597229512 * α ^ 19 - 34950338977013178639767569738567864677193896372240 * α ^ 20 + 1366801847725067991778952117668601561839569590900 * α ^ 21 + 4959220152208557382027853908303681091859164175 * α ^ 22 + 615471404273198116343750989411396892897296680 * α ^ 23 + 34101039377472481958974903669374217452733632 * α ^ 24 + 1034386808344405409707750019488517511355008 * α ^ 25 + 5291527796743143896670464285156657893296 * α ^ 26 - 1219504316386418556368987826914293621248 * α ^ 27 - 75185184777106907253176174218461272832 * α ^ 28 - 2739147805326680629369630717760523264 * α ^ 29 - 73210280752772515350101169959614464 * α ^ 30 - 1531828473996677645738094611644416 * α ^ 31 - 25792432980458262033466819153920 * α ^ 32 - 353823743440056079889063264256 * α ^ 33 - 3970096169377863374039531520 * α ^ 34 - 36356947826301657371639808 * α ^ 35 - 269616704004970519658496 * α ^ 36 - 1596209219881105096704 * α ^ 37 - 7373431975900938240 * α ^ 38 - 25626639771107328 * α ^ 39 - 63065268682752 * α ^ 40 - 98008301568 * α ^ 41 - 72351744 * α ^ 42 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 42 * (234355849074955263951049856572420428528087559257217338000 + 1647917825991745087828090979449220009324402935342213794192 * α + 5517259206635462357799308151379743852022400880405143709300 * α ^ 2 + 11697286850057325472448884282596125036178461096427071180160 * α ^ 3 + 17618194225546020573784427664650585416610740635319786403400 * α ^ 4 + 20046068608053045224231426681510601856273741292025591141480 * α ^ 5 + 17885461556571898483672892064956643539473640662999345701666 * α ^ 6 + 12820152657712533249363000294926617606868677915971896670240 * α ^ 7 + 7502523555651917287805352494007861019866814933742609160696 * α ^ 8 + 3622686298843516098851206612510488687148684155393129482472 * α ^ 9 + 1452571052316260978855070270500133585694231422375833061090 * α ^ 10 + 485064610274304784360415817487598469472479148412401415808 * α ^ 11 + 134868827326575807784515799657395435527619954194004227748 * α ^ 12 + 31113923159253038634767916248106358904477281041358348956 * α ^ 13 + 5912609861703141760519754094833940739302488844248812479 * α ^ 14 + 914297729950293095944937323513702712183136890515661088 * α ^ 15 + 112786258002906693411402876201621614411462995639363644 * α ^ 16 + 10715561597079704979556413609803278787797162405942296 * α ^ 17 + 719193622230655390355126847425184862615908011115060 * α ^ 18 + 14657836127065470780938993503699490899434597229512 * α ^ 19 - 34950338977013178639767569738567864677193896372240 * α ^ 20 + 1366801847725067991778952117668601561839569590900 * α ^ 21 + 4959220152208557382027853908303681091859164175 * α ^ 22 + 615471404273198116343750989411396892897296680 * α ^ 23 + 34101039377472481958974903669374217452733632 * α ^ 24 + 1034386808344405409707750019488517511355008 * α ^ 25 + 5291527796743143896670464285156657893296 * α ^ 26 - 1219504316386418556368987826914293621248 * α ^ 27 - 75185184777106907253176174218461272832 * α ^ 28 - 2739147805326680629369630717760523264 * α ^ 29 - 73210280752772515350101169959614464 * α ^ 30 - 1531828473996677645738094611644416 * α ^ 31 - 25792432980458262033466819153920 * α ^ 32 - 353823743440056079889063264256 * α ^ 33 - 3970096169377863374039531520 * α ^ 34 - 36356947826301657371639808 * α ^ 35 - 269616704004970519658496 * α ^ 36 - 1596209219881105096704 * α ^ 37 - 7373431975900938240 * α ^ 38 - 25626639771107328 * α ^ 39 - 63065268682752 * α ^ 40 - 98008301568 * α ^ 41 - 72351744 * α ^ 42) = 234355849074955263951049856572420428528087559257217338000 * (17 - α) ^ 42 + 37857548703007787579021640626678398156694527389620762697264 * α ^ 1 * (17 - α) ^ 41 + 2944867021487431429882033394933706308696266088891073674557524 * α ^ 2 * (17 - α) ^ 40 + 146910666364742997856783011317318114681608355643172977318910560 * α ^ 3 * (17 - α) ^ 39 + 5281338930363712858347930254940637802165598810816949523191508760 * α ^ 4 * (17 - α) ^ 38 + 145753437649734017761868379170413156812750014126479617274091172120 * α ^ 5 * (17 - α) ^ 37 + 3212433660877561136639288711614882650266994711330586733979437268666 * α ^ 6 * (17 - α) ^ 36 + 58080099103816679194960077966232290827409612456400212654077549294136 * α ^ 7 * (17 - α) ^ 35 + 878073000124467105754351061548458968812316660181611332798436479232076 * α ^ 8 * (17 - α) ^ 34 + 11259922048324651489289493311309309631891001644523667321376037356186888 * α ^ 9 * (17 - α) ^ 33 + 123812154859041152773858816918455744865935561732076455885319152132304488 * α ^ 10 * (17 - α) ^ 32 + 1177282729304429087196944522508776379491442707108602485795557386562286720 * α ^ 11 * (17 - α) ^ 31 + 9744718648999432569661305582435950678261853364124701152000275689844790852 * α ^ 12 * (17 - α) ^ 30 + 70584478999572099526210718832986814594230665767170003296124002517210218548 * α ^ 13 * (17 - α) ^ 29 + 449272053601042666671596079622675645227192899930246481044206503873022598127 * α ^ 14 * (17 - α) ^ 28 + 2521166194604692753878031098107876914463687672229082966575780993950448786492 * α ^ 15 * (17 - α) ^ 27 + 12505743633148390302761257035504316007036914113543301212072536616680265609966 * α ^ 16 * (17 - α) ^ 26 + 54941752319236926994034527846178330055107665824491889262114770438776772080688 * α ^ 17 * (17 - α) ^ 25 + 214108133336419833203656668659528095997912595237383503399365023725947428991765 * α ^ 18 * (17 - α) ^ 24 + 740907981283804161674373017608569262860463894016142577208923888370995315389936 * α ^ 19 * (17 - α) ^ 23 + 2278016136661934557373907941895735701975033136406032948359780173720186398978768 * α ^ 20 * (17 - α) ^ 22 + 6223044015900732285273426821948491350903940514086744466166738234457122088918648 * α ^ 21 * (17 - α) ^ 21 + 15091573130026048461544325185690904741676446061897994842743984569608882476868246 * α ^ 22 * (17 - α) ^ 20 + 32431472815063210198529045051946172792892281829735717630866526639188278809402520 * α ^ 23 * (17 - α) ^ 19 + 61589977160019028252201500272191461481719309803518295921163839432202796081677436 * α ^ 24 * (17 - α) ^ 18 + 103000834533491129063640284036092678067268542010637673258239410761540957030115384 * α ^ 25 * (17 - α) ^ 17 + 151071516679099175443820464035839365942459349434188215403085360254317550609833028 * α ^ 26 * (17 - α) ^ 16 + 193445346233280859296440806414848722181948957409609959791787404726401564917282096 * α ^ 27 * (17 - α) ^ 15 + 215172096945268414340053333093031776453400001175778749956470312358926404221592428 * α ^ 28 * (17 - α) ^ 14 + 206736790098352378662725797487880027357919714030453368776992727928497863099548756 * α ^ 29 * (17 - α) ^ 13 + 170462524827332695320086649521380810293612989490733605162878601757384672794284747 * α ^ 30 * (17 - α) ^ 12 + 119693210823537512228591503646550664793242492067851215311990782497984104429398428 * α ^ 31 * (17 - α) ^ 11 + 70908831093339465886818052612765873755388314931239009902767176459421394442785742 * α ^ 32 * (17 - α) ^ 10 + 35048237403311100028743507259452310464158209931947679191434306115144076602284800 * α ^ 33 * (17 - α) ^ 9 + 14268450259765073448679759926668655504802778135164107658390044566561421617189673 * α ^ 34 * (17 - α) ^ 8 + 4724185205300768110792705712599630650015863880955341087853206634323491488643616 * α ^ 35 * (17 - α) ^ 7 + 1265299135971789660909673234797601828374717278246484983747256160401664255750872 * α ^ 36 * (17 - α) ^ 6 + 280178539570804945484739775418806390334413870080009334057823189831955617940552 * α ^ 37 * (17 - α) ^ 5 + 55439566906689638975335374901816806066147146428085261656377329665751391494454 * α ^ 38 * (17 - α) ^ 4 + 10724868311110483392855160615399587116240195810586300982060213202048731748152 * α ^ 39 * (17 - α) ^ 3 + 1891608447746568174857958621996992326295338311284555046921110287910697380220 * α ^ 40 * (17 - α) ^ 2 + 236532288128129299669916971619583813438473071647279968567818223819695392000 * α ^ 41 * (17 - α) ^ 1 + 14180011930716980449379240294714564887587943224073955569876816155335397250 * α ^ 42 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 44 ≤ n) (h1 : n ≤ 45) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (45 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (45 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 44) (n := n) (n₁ := 45) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((44 : ℕ) : ℝ) - 4 = 40 by norm_num] at hb - rw [show (40 : ℝ) / 2 = ((20 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 43) + 1 / (4 * 43 * (3 + α)) + (1 - 2 * α / 44) ^ 2 * 45 * 44 * (45 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 43 * (3 + α)) ^ 20)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 44 ≤ n) (h1 : n ≤ 45) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 44) (n₁ := 45) (k := 20) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B44_45 diff --git a/Sendov/FiniteRange/Degree46_47.lean b/Sendov/FiniteRange/Degree46_47.lean index c990f1b..3bb33a1 100644 --- a/Sendov/FiniteRange/Degree46_47.lean +++ b/Sendov/FiniteRange/Degree46_47.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 46 to 47 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 46) (gg1 46) (gg2 46) 21)) α := by - refine pev_wsum_eq_of_packed (gg0 46) (gg1 46) (gg2 46) 21 64 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 46) (gg1 46) (gg2 46) 21 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 46) (gg1 46) (gg2 46) 21 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 46) (gg1 46) (gg2 46) 3 (by simp) (by simp) (by simp) 21) - · rfl + refine pev_moment_eq_of_packed_bounds 46 21 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 46 α t ^ 21) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 842100496490164655863899050953513048577517889022827148437500 + 6202389537263705762292576691419085693567510900497436523437500 * α + 21800976172966131822633999416830068976610560420989990234375000 * α ^ 2 + 48647779340585710046299723714124054163748508466339111328125000 * α ^ 3 + 77335744367973576659808264003823907539197097243080139160156250 * α ^ 4 + 93163317164153721286069997796054376135656931010389709472656250 * α ^ 5 + 88315055516249458646175698818625653153167262528008728027343750 * α ^ 6 + 67525482393603249349320023657815936540710634750331726074218750 * α ^ 7 + 42343249160820224575714518101180101058857691214973571777343750 * α ^ 8 + 22022629774039619130278840067223760137223751259001110839843750 * α ^ 9 + 9569037722124326061646207068547925124389847238604876953125000 * α ^ 10 + 3487611243366543917723910686246986580789320695836231250000000 * α ^ 11 + 1067491157924455805861448662311325524405538803060341943359375 * α ^ 12 + 273968142184015848925560036581877108638855706237317490234375 * α ^ 13 + 58692019460587884114525551639474562464674600041476138671875 * α ^ 14 + 10411576695976844279717630513220926151802953315673888359375 * α ^ 15 + 1509986509025418223518044667529937663568415780777702125000 * α ^ 16 + 175469918947028739649743022943799878357086029596651812500 * α ^ 17 + 15779760028253605454031412572296146026014740194967383750 * α ^ 18 + 1010913062001619607789595546144718629262771585185507750 * α ^ 19 + 21462061397781700126941815631803690593259676260498115 * α ^ 20 - 45387057094906818237348334721211459766084329446075757 * α ^ 21 + 1689541722499339437202551579490531894232999398986279 * α ^ 22 + 3936001560036108693341101447415785391643174835443 * α ^ 23 + 607977630486171911031424776719828152869889423044 * α ^ 24 + 36336260809521268434231902077696447132341347400 * α ^ 25 + 1235785272488557483704068508469144496017205184 * α ^ 26 + 15739109405711750147519445570667095018389712 * α ^ 27 - 844836507113777181276666926325076953789696 * α ^ 28 - 65867488403154309232905535325099415940608 * α ^ 29 - 2603492828180830946162421054768504476160 * α ^ 30 - 73591830258372192880755514270838320128 * α ^ 31 - 1619902372241517858218483163123738624 * α ^ 32 - 28740854840777906929998653281886208 * α ^ 33 - 417683720829155224442216354095104 * α ^ 34 - 5006133645480122906718714101760 * α ^ 35 - 49524449888141405612129746944 * α ^ 36 - 402720876040696001365082112 * α ^ 37 - 2667361119757440577634304 * α ^ 38 - 14172645073027210739712 * α ^ 39 - 59000480246059499520 * α ^ 40 - 185464776902049792 * α ^ 41 - 414106827882496 * α ^ 42 - 585532178432 * α ^ 43 - 394264576 * α ^ 44 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 44 * (842100496490164655863899050953513048577517889022827148437500 + 6202389537263705762292576691419085693567510900497436523437500 * α + 21800976172966131822633999416830068976610560420989990234375000 * α ^ 2 + 48647779340585710046299723714124054163748508466339111328125000 * α ^ 3 + 77335744367973576659808264003823907539197097243080139160156250 * α ^ 4 + 93163317164153721286069997796054376135656931010389709472656250 * α ^ 5 + 88315055516249458646175698818625653153167262528008728027343750 * α ^ 6 + 67525482393603249349320023657815936540710634750331726074218750 * α ^ 7 + 42343249160820224575714518101180101058857691214973571777343750 * α ^ 8 + 22022629774039619130278840067223760137223751259001110839843750 * α ^ 9 + 9569037722124326061646207068547925124389847238604876953125000 * α ^ 10 + 3487611243366543917723910686246986580789320695836231250000000 * α ^ 11 + 1067491157924455805861448662311325524405538803060341943359375 * α ^ 12 + 273968142184015848925560036581877108638855706237317490234375 * α ^ 13 + 58692019460587884114525551639474562464674600041476138671875 * α ^ 14 + 10411576695976844279717630513220926151802953315673888359375 * α ^ 15 + 1509986509025418223518044667529937663568415780777702125000 * α ^ 16 + 175469918947028739649743022943799878357086029596651812500 * α ^ 17 + 15779760028253605454031412572296146026014740194967383750 * α ^ 18 + 1010913062001619607789595546144718629262771585185507750 * α ^ 19 + 21462061397781700126941815631803690593259676260498115 * α ^ 20 - 45387057094906818237348334721211459766084329446075757 * α ^ 21 + 1689541722499339437202551579490531894232999398986279 * α ^ 22 + 3936001560036108693341101447415785391643174835443 * α ^ 23 + 607977630486171911031424776719828152869889423044 * α ^ 24 + 36336260809521268434231902077696447132341347400 * α ^ 25 + 1235785272488557483704068508469144496017205184 * α ^ 26 + 15739109405711750147519445570667095018389712 * α ^ 27 - 844836507113777181276666926325076953789696 * α ^ 28 - 65867488403154309232905535325099415940608 * α ^ 29 - 2603492828180830946162421054768504476160 * α ^ 30 - 73591830258372192880755514270838320128 * α ^ 31 - 1619902372241517858218483163123738624 * α ^ 32 - 28740854840777906929998653281886208 * α ^ 33 - 417683720829155224442216354095104 * α ^ 34 - 5006133645480122906718714101760 * α ^ 35 - 49524449888141405612129746944 * α ^ 36 - 402720876040696001365082112 * α ^ 37 - 2667361119757440577634304 * α ^ 38 - 14172645073027210739712 * α ^ 39 - 59000480246059499520 * α ^ 40 - 185464776902049792 * α ^ 41 - 414106827882496 * α ^ 42 - 585532178432 * α ^ 43 - 394264576 * α ^ 44) = 842100496490164655863899050953513048577517889022827148437500 * (17 - α) ^ 44 + 142493043979050242816985361996079030928058472425460815429687500 * α ^ 1 * (17 - α) ^ 43 + 11631055935406676773424347895093264920192634352945327758789062500 * α ^ 2 * (17 - α) ^ 42 + 609992449449811389379816851349777566641910911240855026245117187500 * α ^ 3 * (17 - α) ^ 41 + 23098700643661062063264209577856576688439492919078299293518066406250 * α ^ 4 * (17 - α) ^ 40 + 672886788673347303113646845460420332103897531976657897846984863281250 * α ^ 5 * (17 - α) ^ 39 + 15689183510706334336751155501240168225930150393352115080165405273437500 * α ^ 6 * (17 - α) ^ 38 + 300787141414416123262875017253530680535010772323084607526017456054687500 * α ^ 7 * (17 - α) ^ 37 + 4834082125229902229160089626065942580696829879116404068575523803710937500 * α ^ 8 * (17 - α) ^ 36 + 66072765878867110841147420893730369943336026053933255103129270288085937500 * α ^ 9 * (17 - α) ^ 35 + 776562148162541303792514188712949580055222798582046568076665765594238281250 * α ^ 10 * (17 - α) ^ 34 + 7916165993961948987449580340899456664926175109154616993743620562742089843750 * α ^ 11 * (17 - α) ^ 33 + 70468708978108892817571764541075442041839869106980895974143854170172216796875 * α ^ 12 * (17 - α) ^ 32 + 550782470594884966715313206866948703867564604566371289578563249171289130859375 * α ^ 13 * (17 - α) ^ 31 + 3796271005225225067290420328594083801226095054076152502460026076879075960937500 * α ^ 14 * (17 - α) ^ 30 + 23154951045516208632207010063622078794447604241421409800591507255675276447500000 * α ^ 15 * (17 - α) ^ 29 + 125329005241909283645244852767369785798817688336457585844713864177983765701578125 * α ^ 16 * (17 - α) ^ 28 + 603309363715139594521494665743634826511126981458830526026064579534478738308515625 * α ^ 17 * (17 - α) ^ 27 + 2587364175724392722746563574797525717547108337555060272594625213670122377224922500 * α ^ 18 * (17 - α) ^ 26 + 9898549256162510047261715675023148365372355380576229013767998580288842214641264500 * α ^ 19 * (17 - α) ^ 25 + 33813519196392670210313059666995142454669959269244976653953740675056602158569578990 * α ^ 20 * (17 - α) ^ 24 + 103196149479405719489529062495189947552780951823855220313054805583706227764000739366 * α ^ 21 * (17 - α) ^ 23 + 281414632953734490932383578025410664595174480569956516679000280734682217487402570284 * α ^ 22 * (17 - α) ^ 22 + 685395337547723093442698987180372896387216615945658732837662652249972601215820937644 * α ^ 23 * (17 - α) ^ 21 + 1489149662951024487101091584274360794704873551266921796745007333128807261864150039440 * α ^ 24 * (17 - α) ^ 20 + 2880717800764736562237157455028656259513844924473937460829052015392479287411749584000 * α ^ 25 * (17 - α) ^ 19 + 4948638359187857502444997471872385263341628692259466992165339970591851807662058176250 * α ^ 26 * (17 - α) ^ 18 + 7524808365437321671268164297839989387020638669389928036404610340476432390943699968750 * α ^ 27 * (17 - α) ^ 17 + 10090745730787017626963337198418905561056134794018935219523451765642743556242036084375 * α ^ 28 * (17 - α) ^ 16 + 11884304827785561031887161390332218762155951913733146752455369428108543693253527796875 * α ^ 29 * (17 - α) ^ 15 + 12236134768064187298824467090486239622825767135842989738867807258895895376319098437500 * α ^ 30 * (17 - α) ^ 14 + 10956342185947834383371522495075810215688468611001591955872795308997953700512875000000 * α ^ 31 * (17 - α) ^ 13 + 8480200760430773875569783935490297001453280452983110658282869458743468575057900390625 * α ^ 32 * (17 - α) ^ 12 + 5633029575677093237429398107221916268853414367970165464924058295269805975873642578125 * α ^ 33 * (17 - α) ^ 11 + 3183457062375806825326758077695313148081656523121607548560593992595734846529882812500 * α ^ 34 * (17 - α) ^ 10 + 1514534325584221507212883373649465749871038738085239693277104497573823324223632812500 * α ^ 35 * (17 - α) ^ 9 + 598855676703127526215866064910890958440342074461336641457617262869261681970214843750 * α ^ 36 * (17 - α) ^ 8 + 193895710320064143314152952928304080530489756415618625370542369927247228210449218750 * α ^ 37 * (17 - α) ^ 7 + 50633726898981387585795045476023804360885506077389009794334574956167921386718750000 * α ^ 38 * (17 - α) ^ 6 + 10572386406974364669523632230312278886927530949116535421326834315982454833984375000 * α ^ 39 * (17 - α) ^ 5 + 1792713553761047052220517000286370236664409834359847244425465316189674377441406250 * α ^ 40 * (17 - α) ^ 4 + 262340726959871612498380595594270897589647597255618313914727785960884094238281250 * α ^ 41 * (17 - α) ^ 3 + 34914711121164009908327832512530464932432901098435282301515528343963623046875000 * α ^ 42 * (17 - α) ^ 2 + 3721215228917653403021576873516894679349471790204206905261547785186767578125000 * α ^ 43 * (17 - α) ^ 1 + 210713180134643197170850407242377156075926959031893252124925369262695312500000 * α ^ 44 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 46 ≤ n) (h1 : n ≤ 47) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (47 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (47 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 46) (n := n) (n₁ := 47) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((46 : ℕ) : ℝ) - 4 = 42 by norm_num] at hb - rw [show (42 : ℝ) / 2 = ((21 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 45) + 1 / (4 * 45 * (3 + α)) + (1 - 2 * α / 46) ^ 2 * 47 * 46 * (47 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 45 * (3 + α)) ^ 21)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 46 ≤ n) (h1 : n ≤ 47) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 46) (n₁ := 47) (k := 21) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B46_47 diff --git a/Sendov/FiniteRange/Degree48_49.lean b/Sendov/FiniteRange/Degree48_49.lean index dcd02d3..93f4502 100644 --- a/Sendov/FiniteRange/Degree48_49.lean +++ b/Sendov/FiniteRange/Degree48_49.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 48 to 49 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 48) (gg1 48) (gg2 48) 22)) α := by - refine pev_wsum_eq_of_packed (gg0 48) (gg1 48) (gg2 48) 22 67 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 48) (gg1 48) (gg2 48) 22 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 48) (gg1 48) (gg2 48) 22 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 48) (gg1 48) (gg2 48) 3 (by simp) (by simp) (by simp) 22) - · rfl + refine pev_moment_eq_of_packed_bounds 48 22 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 48 α t ^ 22) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 7591199764941595142535047667167496055166615766339109753578898560 + 58444846237165943551279131377341207077328035296269812484322869920 * α + 215183176025506919702531217941842711339737075266956526659211243010 * α ^ 2 + 504119825711981991953619761968878166062817925879996924390857878780 * α ^ 3 + 843499983730922829653379646526224878986727978586395545435732482710 * α ^ 4 + 1072503620634158239884244537293452959863774094675706145687308954160 * α ^ 5 + 1076446847966334979143656931502325139234331446767890824217309988610 * α ^ 6 + 874481274546832703168275213074859855200282043558515881767199205780 * α ^ 7 + 584940481506790593329950294203572360626072792868892731256510254790 * α ^ 8 + 325988305644965786771400276568642744850196724125639486229759912680 * α ^ 9 + 152567991163281517146520289154412206989708725501314740543815123242 * α ^ 10 + 60257769914462931158481100919633683041061465448481123420828204444 * α ^ 11 + 20129798805767351823723652441204102433547938067213802588532446662 * α ^ 12 + 5687016607145482595882099777086733334514360250477330630445824496 * α ^ 13 + 1355278557647407824791108174949033065263401718280146352590299132 * α ^ 14 + 271000424772480840244816322457048834002540366106552011600103312 * α ^ 15 + 45077206161318041189379028469239391861894842436881282720631712 * α ^ 16 + 6155423822307023556988091783956120485240591022903519939638936 * α ^ 17 + 676142880398770802271995740973508628770999664408861891669293 * α ^ 18 + 57725697116366115637265587909635903325806420371494216534326 * α ^ 19 + 3538202264412216996329718883610558594067822140944030875519 * α ^ 20 + 77574873286609722098225332819487251209357565591548524952 * α ^ 21 - 147315204845101536255433762427937191325421411462459722039 * α ^ 22 + 5245361991102819530624768487527000682291303265286717178 * α ^ 23 + 6658544653474755689275786385563045545487294797590331 * α ^ 24 + 1472968109561870214375834133381327743623319061135332 * α ^ 25 + 95171634843015522566439274462655369397323761963548 * α ^ 26 + 3545966415236624759599391868158380053883553245824 * α ^ 27 + 64377156482122958948701739689394929584223299312 * α ^ 28 - 1168656375434360221238828101326004753556536896 * α ^ 29 - 139417680493330544069384288780944967009327424 * α ^ 30 - 6070430434653508552057016796802025839583232 * α ^ 31 - 181826034173641815543270617357206754251776 * α ^ 32 - 4202739957608852026901130257441189900288 * α ^ 33 - 78263006650153541891015915303985934336 * α ^ 34 - 1198002545218365750178026069831352320 * α ^ 35 - 15219010328713364070284371473793024 * α ^ 36 - 160981724807992562843830338977792 * α ^ 37 - 1415946326039159376655312551936 * α ^ 38 - 10298650421826586803585810432 * α ^ 39 - 61314611371788369779294208 * α ^ 40 - 294083659089512872280064 * α ^ 41 - 1109163402380295012352 * α ^ 42 - 3168884055181623296 * α ^ 43 - 6448929882243072 * α ^ 44 - 8332022644736 * α ^ 45 - 5138022400 * α ^ 46 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 46 * (7591199764941595142535047667167496055166615766339109753578898560 + 58444846237165943551279131377341207077328035296269812484322869920 * α + 215183176025506919702531217941842711339737075266956526659211243010 * α ^ 2 + 504119825711981991953619761968878166062817925879996924390857878780 * α ^ 3 + 843499983730922829653379646526224878986727978586395545435732482710 * α ^ 4 + 1072503620634158239884244537293452959863774094675706145687308954160 * α ^ 5 + 1076446847966334979143656931502325139234331446767890824217309988610 * α ^ 6 + 874481274546832703168275213074859855200282043558515881767199205780 * α ^ 7 + 584940481506790593329950294203572360626072792868892731256510254790 * α ^ 8 + 325988305644965786771400276568642744850196724125639486229759912680 * α ^ 9 + 152567991163281517146520289154412206989708725501314740543815123242 * α ^ 10 + 60257769914462931158481100919633683041061465448481123420828204444 * α ^ 11 + 20129798805767351823723652441204102433547938067213802588532446662 * α ^ 12 + 5687016607145482595882099777086733334514360250477330630445824496 * α ^ 13 + 1355278557647407824791108174949033065263401718280146352590299132 * α ^ 14 + 271000424772480840244816322457048834002540366106552011600103312 * α ^ 15 + 45077206161318041189379028469239391861894842436881282720631712 * α ^ 16 + 6155423822307023556988091783956120485240591022903519939638936 * α ^ 17 + 676142880398770802271995740973508628770999664408861891669293 * α ^ 18 + 57725697116366115637265587909635903325806420371494216534326 * α ^ 19 + 3538202264412216996329718883610558594067822140944030875519 * α ^ 20 + 77574873286609722098225332819487251209357565591548524952 * α ^ 21 - 147315204845101536255433762427937191325421411462459722039 * α ^ 22 + 5245361991102819530624768487527000682291303265286717178 * α ^ 23 + 6658544653474755689275786385563045545487294797590331 * α ^ 24 + 1472968109561870214375834133381327743623319061135332 * α ^ 25 + 95171634843015522566439274462655369397323761963548 * α ^ 26 + 3545966415236624759599391868158380053883553245824 * α ^ 27 + 64377156482122958948701739689394929584223299312 * α ^ 28 - 1168656375434360221238828101326004753556536896 * α ^ 29 - 139417680493330544069384288780944967009327424 * α ^ 30 - 6070430434653508552057016796802025839583232 * α ^ 31 - 181826034173641815543270617357206754251776 * α ^ 32 - 4202739957608852026901130257441189900288 * α ^ 33 - 78263006650153541891015915303985934336 * α ^ 34 - 1198002545218365750178026069831352320 * α ^ 35 - 15219010328713364070284371473793024 * α ^ 36 - 160981724807992562843830338977792 * α ^ 37 - 1415946326039159376655312551936 * α ^ 38 - 10298650421826586803585810432 * α ^ 39 - 61314611371788369779294208 * α ^ 40 - 294083659089512872280064 * α ^ 41 - 1109163402380295012352 * α ^ 42 - 3168884055181623296 * α ^ 43 - 6448929882243072 * α ^ 44 - 8332022644736 * α ^ 45 - 5138022400 * α ^ 46) = 7591199764941595142535047667167496055166615766339109753578898560 * (17 - α) ^ 46 + 1342757575219134416928357426104505338852240925288185860898118122400 * α ^ 1 * (17 - α) ^ 45 + 114755136999517997583283831824376925408437409071957821349973204728290 * α ^ 2 * (17 - α) ^ 44 + 6311871144666629761637230662569825452491581180312292712701296505455700 * α ^ 3 * (17 - α) ^ 43 + 251117021819028982864973145165014954053157643806880139740425434345397070 * α ^ 4 * (17 - α) ^ 42 + 7700255582992438800428557545327513666900681197124798184091430231098133960 * α ^ 5 * (17 - α) ^ 41 + 189367631135786370984279829668504339679999112172842699082163134760932823050 * α ^ 6 * (17 - α) ^ 40 + 3837299018002887727841264180140203196909974021427614251792467066036834514460 * α ^ 7 * (17 - α) ^ 39 + 65330193691266612095267419404574125266102388594982857701230218272237672614950 * α ^ 8 * (17 - α) ^ 38 + 948167953912606041527211234549432129570826851527171582246349949742846207580480 * α ^ 9 * (17 - α) ^ 37 + 11862897220186135053544305256945784922859357773863352679820145643098022220785278 * α ^ 10 * (17 - α) ^ 36 + 129072115915064352802998192157149959447544106737793242351888060162304851138395580 * α ^ 11 * (17 - α) ^ 35 + 1229795769892025833353618429128543962117904449244422243628303524212233499528414042 * α ^ 12 * (17 - α) ^ 34 + 10318568580638790387954818617820003753357917586903069070216576765343271409771487800 * α ^ 13 * (17 - α) ^ 33 + 76586524069802882894078032032353528016591779712305320570499363273565575419847624376 * α ^ 14 * (17 - α) ^ 32 + 504684151077635699819713494479495670799591999023571346450099800467157372095419250912 * α ^ 15 * (17 - α) ^ 31 + 2961464831656022935314311202766885642337479869778047028701398651217449033783743537080 * α ^ 16 * (17 - α) ^ 30 + 15511312927367844114034275848806344502776248279233504803062812081346091041874500312424 * α ^ 17 * (17 - α) ^ 29 + 72656111586338879343047119765015961893678349787522472371632798641470861566691804080505 * α ^ 18 * (17 - α) ^ 28 + 304808185012857975724498725531184620292840658826980992018187980322769269404048114731402 * α ^ 19 * (17 - α) ^ 27 + 1146590392326781377506836763538391565844743608196668993927537593446331465448235657881983 * α ^ 20 * (17 - α) ^ 26 + 3870600448216253864751392890281906184377072807016812087208519577192080210828017341041740 * α ^ 21 * (17 - α) ^ 25 + 11731891593652584393540855221982594836705418299405024828972301429357123143028053536434669 * α ^ 22 * (17 - α) ^ 24 + 31934660245093795505928032518461564485995557345717410206365628000458801939061533187363710 * α ^ 23 * (17 - α) ^ 23 + 78047993066241081864729405263799058714155198199791825458167970252230959614239365881878947 * α ^ 24 * (17 - α) ^ 22 + 171134843936218514686150148288359364686859698322647460634859632067734173140627231359730584 * α ^ 25 * (17 - α) ^ 21 + 336206506050303051354999483042669483751718653067431091525204950883403868367567684342080020 * α ^ 26 * (17 - α) ^ 20 + 590632297194451478800263563954322310467842994277133756163742170600614302732421283888959208 * α ^ 27 * (17 - α) ^ 19 + 925516670394461047649865831225821273518368307653384139954083832567847096613665974954102740 * α ^ 28 * (17 - α) ^ 18 + 1289766645595527592343166744587741066182934225995347417854162835114044818241870914092204864 * α ^ 29 * (17 - α) ^ 17 + 1593002416141247767069378716733631264077333099250896896091743214673847829299190958471833770 * α ^ 30 * (17 - α) ^ 16 + 1737143176643046947303118633436476715799207563792300127093284518020249525152200860365809660 * α ^ 31 * (17 - α) ^ 15 + 1665311418235579100523754798782860220365664075295289918982682336006446972368945219112765174 * α ^ 32 * (17 - α) ^ 14 + 1396557360038252731643454796992613166665272986910499262544165249742942020476375868362815880 * α ^ 33 * (17 - α) ^ 13 + 1018684619224015379084223520647127025765305887834183888331474942254858102069742927480803487 * α ^ 34 * (17 - α) ^ 12 + 641932494254295073687856899416231301192107297550335297051507507404266419546500180865404214 * α ^ 35 * (17 - α) ^ 11 + 346616023624199508122240528681160766975802934453336786297349998221685206774349480865493785 * α ^ 36 * (17 - α) ^ 10 + 158769464897392551896561203035439621044410847226907537961532798384360622001611952908266388 * α ^ 37 * (17 - α) ^ 9 + 60938188611726643632686961457984989878294641295998164978961810053640858299331163879730855 * α ^ 38 * (17 - α) ^ 8 + 19303965900462850327232871938264169200849651337482672284417001334177009419208937264542474 * α ^ 39 * (17 - α) ^ 7 + 4956495620088219287305017176528775890173857965129426190480342928881513904895208113754297 * α ^ 40 * (17 - α) ^ 6 + 1011094459778786182680868888323794915088603327243667761590423358931583382786018989420280 * α ^ 41 * (17 - α) ^ 5 + 161129362690984017597830623141137027326076650900522288728417841096952993030031822930852 * α ^ 42 * (17 - α) ^ 4 + 20053630683210270088939005261620316062127222962442862223177250670635839018815183419080 * α ^ 43 * (17 - α) ^ 3 + 2007106897711885365446090180299995728598915866332529016566715378067994766096351142716 * α ^ 44 * (17 - α) ^ 2 + 160682627900417809962527853098762123815034415286611690425666398978372619671902878336 * α ^ 45 * (17 - α) ^ 1 + 7728635588004831865654878836695725660660992895290133611955913220528766346904639440 * α ^ 46 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 48 ≤ n) (h1 : n ≤ 49) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (49 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (49 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 48) (n := n) (n₁ := 49) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((48 : ℕ) : ℝ) - 4 = 44 by norm_num] at hb - rw [show (44 : ℝ) / 2 = ((22 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 47) + 1 / (4 * 47 * (3 + α)) + (1 - 2 * α / 48) ^ 2 * 49 * 48 * (49 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 47 * (3 + α)) ^ 22)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 48 ≤ n) (h1 : n ≤ 49) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 48) (n₁ := 49) (k := 22) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B48_49 diff --git a/Sendov/FiniteRange/Degree50_51.lean b/Sendov/FiniteRange/Degree50_51.lean index 94ae59e..9ea0021 100644 --- a/Sendov/FiniteRange/Degree50_51.lean +++ b/Sendov/FiniteRange/Degree50_51.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 50 to 51 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 50) (gg1 50) (gg2 50) 23)) α := by - refine pev_wsum_eq_of_packed (gg0 50) (gg1 50) (gg2 50) 23 70 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 50) (gg1 50) (gg2 50) 23 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 50) (gg1 50) (gg2 50) 23 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 50) (gg1 50) (gg2 50) 3 (by simp) (by simp) (by simp) 23) - · rfl + refine pev_moment_eq_of_packed_bounds 50 23 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 50 α t ^ 23) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 1983296105822518649150892894549250995892425255171116289185883918750 + 15931100140393602368014405057264748941230464487163945499694824056650 * α + 61313644372277040962442376585817692381801159938853766654339532342642 * α ^ 2 + 150465161025803906984244548536621322753695053837703089058231205826774 * α ^ 3 + 264322010781344595257900949490583824621999776392907846339168572698350 * α ^ 4 + 353743281892829023763479373880774443309366799073302434018471557825110 * α ^ 5 + 374746430716099889392649480753262242691492748868863233615818683113210 * α ^ 6 + 322333251095138331750810376734129960862151553108003622673897471115306 * α ^ 7 + 229084605395415458859385031638216501003980492983719572433329563703882 * α ^ 8 + 136186580162004849698169069937707109921050663415979174616099970789410 * α ^ 9 + 68297183570273843739235319574922178848744148149317657527481287867250 * α ^ 10 + 29054555352882187051825924818349071162009825742437693416815288122330 * α ^ 11 + 10517845843096179861634152822549541177919036751909714056461382791068 * α ^ 12 + 3243051149627232957975285323520147924344852995685877267136094949840 * α ^ 13 + 850730079576852202812092212763343774803138893059657454552260134214 * α ^ 14 + 189221714566801413370144763019660859707489277898806302228701929446 * α ^ 15 + 35474208966373153737428171347789581229469589042109433569563529953 * α ^ 16 + 5554556457876028787144312502202971828015473429833975918437514119 * α ^ 17 + 716629519575982953947167029297978855992566816319461607180223069 * α ^ 18 + 74636427766751024769605292454839153620634666149147834232905931 * α ^ 19 + 6065508382815751088971849224267373808540598230608937163606579 * α ^ 20 + 356427540055849162043883615776918801250352493347841025665727 * α ^ 21 + 8010922898128612953822450660739207750975492597821084469545 * α ^ 22 - 13811768035257687091848436534105252716200722593308688700839 * α ^ 23 + 472347189731554483068916734651482362647265909534029610926 * α ^ 24 + 200645576218037265363448556666064462492230746541192244 * α ^ 25 + 100792254939342885252420783865617430196525578985330442 * α ^ 26 + 7091638050698434724340077137596634135844686246524912 * α ^ 27 + 285507048268244527798843379331968858452479422433048 * α ^ 28 + 6365143148445153742308391864889359416478446278784 * α ^ 29 - 16632500105576540446570710610087487983679864544 * α ^ 30 - 8141192900297447634759131458865132803547534592 * α ^ 31 - 400672640084661107358183665488704704596271232 * α ^ 32 - 12769723604511066119766459310752455613515776 * α ^ 33 - 309725769188807086499063690021928273938432 * α ^ 34 - 6036271221838887663385231842606805557248 * α ^ 35 - 96889509859715053751265427510064881664 * α ^ 36 - 1296670055323112890407391552598540288 * α ^ 37 - 14548305968728835978279387666579456 * α ^ 38 - 136967029538617142794633045934080 * α ^ 39 - 1078901766843439405240321966080 * α ^ 40 - 7063554191969670305537064960 * α ^ 41 - 38017498823635237609013248 * α ^ 42 - 165453035363695795896320 * α ^ 43 - 568050178195987103744 * α ^ 44 - 1481574358823469056 * α ^ 45 - 2759526258311168 * α ^ 46 - 3270533709824 * α ^ 47 - 1853882368 * α ^ 48 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 48 * (1983296105822518649150892894549250995892425255171116289185883918750 + 15931100140393602368014405057264748941230464487163945499694824056650 * α + 61313644372277040962442376585817692381801159938853766654339532342642 * α ^ 2 + 150465161025803906984244548536621322753695053837703089058231205826774 * α ^ 3 + 264322010781344595257900949490583824621999776392907846339168572698350 * α ^ 4 + 353743281892829023763479373880774443309366799073302434018471557825110 * α ^ 5 + 374746430716099889392649480753262242691492748868863233615818683113210 * α ^ 6 + 322333251095138331750810376734129960862151553108003622673897471115306 * α ^ 7 + 229084605395415458859385031638216501003980492983719572433329563703882 * α ^ 8 + 136186580162004849698169069937707109921050663415979174616099970789410 * α ^ 9 + 68297183570273843739235319574922178848744148149317657527481287867250 * α ^ 10 + 29054555352882187051825924818349071162009825742437693416815288122330 * α ^ 11 + 10517845843096179861634152822549541177919036751909714056461382791068 * α ^ 12 + 3243051149627232957975285323520147924344852995685877267136094949840 * α ^ 13 + 850730079576852202812092212763343774803138893059657454552260134214 * α ^ 14 + 189221714566801413370144763019660859707489277898806302228701929446 * α ^ 15 + 35474208966373153737428171347789581229469589042109433569563529953 * α ^ 16 + 5554556457876028787144312502202971828015473429833975918437514119 * α ^ 17 + 716629519575982953947167029297978855992566816319461607180223069 * α ^ 18 + 74636427766751024769605292454839153620634666149147834232905931 * α ^ 19 + 6065508382815751088971849224267373808540598230608937163606579 * α ^ 20 + 356427540055849162043883615776918801250352493347841025665727 * α ^ 21 + 8010922898128612953822450660739207750975492597821084469545 * α ^ 22 - 13811768035257687091848436534105252716200722593308688700839 * α ^ 23 + 472347189731554483068916734651482362647265909534029610926 * α ^ 24 + 200645576218037265363448556666064462492230746541192244 * α ^ 25 + 100792254939342885252420783865617430196525578985330442 * α ^ 26 + 7091638050698434724340077137596634135844686246524912 * α ^ 27 + 285507048268244527798843379331968858452479422433048 * α ^ 28 + 6365143148445153742308391864889359416478446278784 * α ^ 29 - 16632500105576540446570710610087487983679864544 * α ^ 30 - 8141192900297447634759131458865132803547534592 * α ^ 31 - 400672640084661107358183665488704704596271232 * α ^ 32 - 12769723604511066119766459310752455613515776 * α ^ 33 - 309725769188807086499063690021928273938432 * α ^ 34 - 6036271221838887663385231842606805557248 * α ^ 35 - 96889509859715053751265427510064881664 * α ^ 36 - 1296670055323112890407391552598540288 * α ^ 37 - 14548305968728835978279387666579456 * α ^ 38 - 136967029538617142794633045934080 * α ^ 39 - 1078901766843439405240321966080 * α ^ 40 - 7063554191969670305537064960 * α ^ 41 - 38017498823635237609013248 * α ^ 42 - 165453035363695795896320 * α ^ 43 - 568050178195987103744 * α ^ 44 - 1481574358823469056 * α ^ 45 - 2759526258311168 * α ^ 46 - 3270533709824 * α ^ 47 - 1853882368 * α ^ 48) = 1983296105822518649150892894549250995892425255171116289185883918750 * (17 - α) ^ 48 + 366026915466172135415487744911864779803754308530000655375734437063050 * α ^ 1 * (17 - α) ^ 47 + 32685750243130354166431563659107402625750332035405750191561966328636888 * α ^ 2 * (17 - α) ^ 46 + 1881407841131145090841016986533759097730516052825808704231530487137780460 * α ^ 3 * (17 - α) ^ 45 + 78459256689743329963134594253570543442212800051291261295613679735466812720 * α ^ 4 * (17 - α) ^ 44 + 2526157710396158722925121199079871034544523911581723097994207618552592660140 * α ^ 5 * (17 - α) ^ 43 + 65348270578398047737901045538231544926735111377759221708810966322205125102460 * α ^ 6 * (17 - α) ^ 42 + 1395586695048529216219720727338181782409903542683661464665137976415266653947720 * α ^ 7 * (17 - α) ^ 41 + 25091358961567861189485447956384974798693774013704426176176831023955755758143760 * α ^ 8 * (17 - α) ^ 40 + 385389290374823447581872955370254873043506388116231648347871930606580590239210420 * α ^ 9 * (17 - α) ^ 39 + 5114292252486869911885110308469289761839173642500394020070108012031543397685206240 * α ^ 10 * (17 - α) ^ 38 + 59161256161938370784774347699829801724975303229316300011306943983966944681307590660 * α ^ 11 * (17 - α) ^ 37 + 600805106310323904417213469470448614536129232455343240574225543436663232620490973050 * α ^ 12 * (17 - α) ^ 36 + 5387148987622905002337912552695991101576356210279594139892815350033519190381631954018 * α ^ 13 * (17 - α) ^ 35 + 42848313014751656392801345211288230271187367670920575900488813020424662766115040908726 * α ^ 14 * (17 - α) ^ 34 + 303464032538826618020021810092246523076423327835808593359248630575577172669418455370662 * α ^ 15 * (17 - α) ^ 33 + 1919675052319908024894686554181462077949811954560704660857906175718223592208137349163213 * α ^ 16 * (17 - α) ^ 32 + 10874148852557470485141277547722227524021509120915887117480057293293644142032687753432339 * α ^ 17 * (17 - α) ^ 31 + 55271679208564823539840128254013152835651570970254641566356451199627461145310938188424982 * α ^ 18 * (17 - α) ^ 30 + 252503463116529357367558410529797790559166244171078469841324516308832648846176593953640464 * α ^ 19 * (17 - α) ^ 29 + 1038141469835606067593166733401008792243365429970694049028451636707468137313444745165939138 * α ^ 20 * (17 - α) ^ 28 + 3845092335628247042344655260236398462168031115874282430712913167859044335883180372818928032 * α ^ 21 * (17 - α) ^ 27 + 12839214422922060993100206502392817799511987618052955635827705879418137857456229303102002808 * α ^ 22 * (17 - α) ^ 26 + 38668985960763181946954732106269364443378192304730607843082220299380873795313006656808498078 * α ^ 23 * (17 - α) ^ 25 + 105069155536109812068244241812619770677190371101318523388390165019705025089023705073017992201 * α ^ 24 * (17 - α) ^ 24 + 257533243404978929099209346342414027031432812223519857139718344355911305954126811366525083697 * α ^ 25 * (17 - α) ^ 23 + 569147019919025772591890628632811032011859407504430878312206909813978377735116474357089719868 * α ^ 26 * (17 - α) ^ 22 + 1133018419963002695257135527792891577568016315310178309850366791483086891940574911149456141128 * α ^ 27 * (17 - α) ^ 21 + 2028823393084462551372573822881776536387839606739316015353770957756761466356425861534814818366 * α ^ 28 * (17 - α) ^ 20 + 3261422523223033546198612538770445764908099658312172165119166143094334561521557450816017566082 * α ^ 29 * (17 - α) ^ 19 + 4695570437669925151575494973682300710306869448714096516816247877812648326270233197019115846774 * α ^ 30 * (17 - α) ^ 18 + 6037682994028240913498413640341842161215563262372408190036046373359050231573990788555033536546 * α ^ 31 * (17 - α) ^ 17 + 6911350888808185279134128140957411320398266037074579187309898159530888623281682213973958805785 * α ^ 32 * (17 - α) ^ 16 + 7017723164655595521056126675946456567629553403101512610091781353726356232791660976553934912931 * α ^ 33 * (17 - α) ^ 15 + 6294935143237609226898430401643730433375800655100783828138379904195915445486580487224848524262 * α ^ 34 * (17 - α) ^ 14 + 4964878406314244868780111039956203509756923777921248038055860417036296541552216059906145098404 * α ^ 35 * (17 - α) ^ 13 + 3424306290318650239602511891398619048414623269656800653759902188565148030596558040360823787326 * α ^ 36 * (17 - α) ^ 12 + 2051958590995686906351648406832466203839543817560131729480349304645431078728413090667388003272 * α ^ 37 * (17 - α) ^ 11 + 1060005738961397201738580950863446006402895600697466546122050769062752312325491830374270906944 * α ^ 38 * (17 - α) ^ 10 + 467577400988976496475501234195271024537914612633016089768118387533173634164273126204352761938 * α ^ 39 * (17 - α) ^ 9 + 174055424381608100029944299500295460088946458918286120062437292805583013054742467588482744291 * α ^ 40 * (17 - α) ^ 8 + 53878846132574605007505800468792220908832004075393485465775528877910318074398454899271776059 * α ^ 41 * (17 - α) ^ 7 + 13614845621699809419890571355526634130837098707003964296944897175809602487667917307467989936 * α ^ 42 * (17 - α) ^ 6 + 2744159397807574020755344104224532395538285866763175087142310240707624213164183747296183828 * α ^ 43 * (17 - α) ^ 5 + 428866537260624574850004860175037680310285291204398039963565670689977450658379659200504216 * α ^ 44 * (17 - α) ^ 4 + 50333756227847631161716151257046024575567930432377627572895340197028609964017169960339112 * α ^ 45 * (17 - α) ^ 3 + 4302447045325735617429810226177479174756160321138468549855980238567434050919754100402688 * α ^ 46 * (17 - α) ^ 2 + 258744146897542242897425801777948395291136619450442877052536998228794692040701916234240 * α ^ 47 * (17 - α) ^ 1 + 9199351670117540067891308093632332055308176052079014496984569179145526721008475136000 * α ^ 48 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 50 ≤ n) (h1 : n ≤ 51) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (51 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (51 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 50) (n := n) (n₁ := 51) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((50 : ℕ) : ℝ) - 4 = 46 by norm_num] at hb - rw [show (46 : ℝ) / 2 = ((23 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 49) + 1 / (4 * 49 * (3 + α)) + (1 - 2 * α / 50) ^ 2 * 51 * 50 * (51 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 49 * (3 + α)) ^ 23)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 50 ≤ n) (h1 : n ≤ 51) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 50) (n₁ := 51) (k := 23) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B50_51 diff --git a/Sendov/FiniteRange/Degree52_53.lean b/Sendov/FiniteRange/Degree52_53.lean index fd5439d..b8c13e9 100644 --- a/Sendov/FiniteRange/Degree52_53.lean +++ b/Sendov/FiniteRange/Degree52_53.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 52 to 53 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 52) (gg1 52) (gg2 52) 24)) α := by - refine pev_wsum_eq_of_packed (gg0 52) (gg1 52) (gg2 52) 24 73 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 52) (gg1 52) (gg2 52) 24 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 52) (gg1 52) (gg2 52) 24 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 52) (gg1 52) (gg2 52) 3 (by simp) (by simp) (by simp) 24) - · rfl + refine pev_moment_eq_of_packed_bounds 52 24 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 52 α t ^ 24) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 2158786206398835455807414614345741946541113771140909309351827456752112 + 18060881628885317183903129865386184210636931259177004847461943403431248 * α + 72523751526913871689914498063741871627156282998221168488328768408227884 * α ^ 2 + 186043952493859430608709083701039329302003956855619351393577019518308656 * α ^ 3 + 342352186792731735464993586128215688813987853593111908601035784489017584 * α ^ 4 + 481039143350973516581843203115060631357333955017066302301078896484075192 * α ^ 5 + 536385148360730976146799557733557814318777038771883620685910931111117598 * α ^ 6 + 486973177459613828942749054605832894034828444342062183629433383012760968 * α ^ 7 + 366445983498710745663941283884031432424266298307553290495228389566314580 * α ^ 8 + 231462963120661901399357408339235733527085751003762699569336649733064704 * α ^ 9 + 123822723544233720819377342496077302912265601255690207194574592762760382 * α ^ 10 + 56444234764084989462828858083829787816765813106300946212401546188828432 * α ^ 11 + 22008608122728995449205242852102476325631469834261804695394906754027728 * α ^ 12 + 7353623809616680357566863259021705228111970073628547653529150957921848 * α ^ 13 + 2105293430360560851822138859793778045699608135112104910406227699186678 * α ^ 14 + 515430709094276322360222922253268287610570499499448923895934548603720 * α ^ 15 + 107478868042826110622436885067609215622378470268066806044658545978916 * α ^ 16 + 18965619675038957214919858400770522577747376668487077296700550484152 * α ^ 17 + 2805160201379690314111348362084950864952366379855375613165120590980 * α ^ 18 + 342991269135314358321380120239307230093856195186954782184086092504 * α ^ 19 + 33962560439249200363255807231186470161851488347615308016008248384 * α ^ 20 + 2633515219064481554671199294750396033142024306631342141117342380 * α ^ 21 + 148633574270813874422290547923622884359972747318157801476955959 * α ^ 22 + 3403031020239585108295877062230213266408608085674454931323988 * α ^ 23 - 5379021087810236884979508991939865813601169242801548152141926 * α ^ 24 + 177301236343156026391795710864319371980311028891458462428744 * α ^ 25 - 40911700701069253972939511638042802470451085773720769927 * α ^ 26 + 27847404177739803963243561747514551473461230777429543312 * α ^ 27 + 2163155861798102819189036458258553844449886588504682104 * α ^ 28 + 93357595651430156400551007018380753717170652754834528 * α ^ 29 + 2393234358116242034523747708494764119251642322824544 * α ^ 30 + 15013048286137658650612509829061430420471401902848 * α ^ 31 - 1842593441930339010973203854928850324437642558336 * α ^ 32 - 107353306964614466200187553508809370311222440448 * α ^ 33 - 3666162111111306744447755601199086059560935168 * α ^ 34 - 93356644345705005900818038532098756222427136 * α ^ 35 - 1900483230089570865170384480343133786767360 * α ^ 36 - 31876662776993730438299978705884181495808 * α ^ 37 - 447245036738485694487463467137714307072 * α ^ 38 - 5288819621114196078630291364843487232 * α ^ 39 - 52859730633810963643011459678732288 * α ^ 40 - 446161546901880234704034758393856 * α ^ 41 - 3167349500047341936592130605056 * α ^ 42 - 18770907855391026630248890368 * α ^ 43 - 91797189183100371092373504 * α ^ 44 - 364189492779598108164096 * α ^ 45 - 1143139551315216039936 * α ^ 46 - 2732815988096499712 * α ^ 47 - 4676225293352960 * α ^ 48 - 5102186266624 * α ^ 49 - 2667577344 * α ^ 50 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 50 * (2158786206398835455807414614345741946541113771140909309351827456752112 + 18060881628885317183903129865386184210636931259177004847461943403431248 * α + 72523751526913871689914498063741871627156282998221168488328768408227884 * α ^ 2 + 186043952493859430608709083701039329302003956855619351393577019518308656 * α ^ 3 + 342352186792731735464993586128215688813987853593111908601035784489017584 * α ^ 4 + 481039143350973516581843203115060631357333955017066302301078896484075192 * α ^ 5 + 536385148360730976146799557733557814318777038771883620685910931111117598 * α ^ 6 + 486973177459613828942749054605832894034828444342062183629433383012760968 * α ^ 7 + 366445983498710745663941283884031432424266298307553290495228389566314580 * α ^ 8 + 231462963120661901399357408339235733527085751003762699569336649733064704 * α ^ 9 + 123822723544233720819377342496077302912265601255690207194574592762760382 * α ^ 10 + 56444234764084989462828858083829787816765813106300946212401546188828432 * α ^ 11 + 22008608122728995449205242852102476325631469834261804695394906754027728 * α ^ 12 + 7353623809616680357566863259021705228111970073628547653529150957921848 * α ^ 13 + 2105293430360560851822138859793778045699608135112104910406227699186678 * α ^ 14 + 515430709094276322360222922253268287610570499499448923895934548603720 * α ^ 15 + 107478868042826110622436885067609215622378470268066806044658545978916 * α ^ 16 + 18965619675038957214919858400770522577747376668487077296700550484152 * α ^ 17 + 2805160201379690314111348362084950864952366379855375613165120590980 * α ^ 18 + 342991269135314358321380120239307230093856195186954782184086092504 * α ^ 19 + 33962560439249200363255807231186470161851488347615308016008248384 * α ^ 20 + 2633515219064481554671199294750396033142024306631342141117342380 * α ^ 21 + 148633574270813874422290547923622884359972747318157801476955959 * α ^ 22 + 3403031020239585108295877062230213266408608085674454931323988 * α ^ 23 - 5379021087810236884979508991939865813601169242801548152141926 * α ^ 24 + 177301236343156026391795710864319371980311028891458462428744 * α ^ 25 - 40911700701069253972939511638042802470451085773720769927 * α ^ 26 + 27847404177739803963243561747514551473461230777429543312 * α ^ 27 + 2163155861798102819189036458258553844449886588504682104 * α ^ 28 + 93357595651430156400551007018380753717170652754834528 * α ^ 29 + 2393234358116242034523747708494764119251642322824544 * α ^ 30 + 15013048286137658650612509829061430420471401902848 * α ^ 31 - 1842593441930339010973203854928850324437642558336 * α ^ 32 - 107353306964614466200187553508809370311222440448 * α ^ 33 - 3666162111111306744447755601199086059560935168 * α ^ 34 - 93356644345705005900818038532098756222427136 * α ^ 35 - 1900483230089570865170384480343133786767360 * α ^ 36 - 31876662776993730438299978705884181495808 * α ^ 37 - 447245036738485694487463467137714307072 * α ^ 38 - 5288819621114196078630291364843487232 * α ^ 39 - 52859730633810963643011459678732288 * α ^ 40 - 446161546901880234704034758393856 * α ^ 41 - 3167349500047341936592130605056 * α ^ 42 - 18770907855391026630248890368 * α ^ 43 - 91797189183100371092373504 * α ^ 44 - 364189492779598108164096 * α ^ 45 - 1143139551315216039936 * α ^ 46 - 2732815988096499712 * α ^ 47 - 4676225293352960 * α ^ 48 - 5102186266624 * α ^ 49 - 2667577344 * α ^ 50) = 2158786206398835455807414614345741946541113771140909309351827456752112 * (17 - α) ^ 50 + 414974298010992164916723938428852228907883519963054547874444410695936816 * α ^ 1 * (17 - α) ^ 49 + 38648591690978151565940680020861626232221593895027976635018801559557425260 * α ^ 2 * (17 - α) ^ 48 + 2323468774953773046737498344073410604963916757430810426040495562926126538992 * α ^ 3 * (17 - α) ^ 47 + 101349335991740593349006338670862435683901636675912397673964231014026337776992 * α ^ 4 * (17 - α) ^ 46 + 3418523402240372565025362732012218197017682799224385182741003587603019322270088 * α ^ 5 * (17 - α) ^ 45 + 92795830318460904167075752328056310590909312937624225610579756886634415607753926 * α ^ 6 * (17 - α) ^ 44 + 2083150548513343067461154384073343753088328081203102895466392639042540698472213552 * α ^ 7 * (17 - α) ^ 43 + 39441282325689010460905068005007464787875697034233161641025817719437629586599815832 * α ^ 8 * (17 - α) ^ 42 + 639183212529869482732967509857029817382349276322171871286037804499595169420221724576 * α ^ 9 * (17 - α) ^ 41 + 8967891289317846323424522756456515361904817651455107492105958263498697039942754607804 * α ^ 10 * (17 - α) ^ 40 + 109912662905773911775785651830599814138152716415593519404830837106463824445813386386608 * α ^ 11 * (17 - α) ^ 39 + 1185288664388902189248806437812380279610975615235779015443672285781708714559807760293128 * α ^ 12 * (17 - α) ^ 38 + 11312386017398730692131184641629356719495877419525070049772377844481537989327971120696960 * α ^ 13 * (17 - α) ^ 37 + 96008520633756064409983434244275286680745229190958399353722082141681347511927190938190428 * α ^ 14 * (17 - α) ^ 36 + 727433466208182128845968339617608516747540980223663657764849247640353461478732223298149376 * α ^ 15 * (17 - α) ^ 35 + 4936366709381111751784857730466957485889673194213489796538376360678509233705016565561219568 * α ^ 16 * (17 - α) ^ 34 + 30082088254960095366958957594286135042878514883960848835770199866562115806088375067362801128 * α ^ 17 * (17 - α) ^ 33 + 164985102649690123319061978345185000778850953533122226871900814573805405999712146966652623130 * α ^ 18 * (17 - α) ^ 32 + 815818288201891083392614882901171467483608622704000551448258747708939293642643211380800205624 * α ^ 19 * (17 - α) ^ 31 + 3642346364254930209461654350984048884263119419677776197894819995644826784702649307916488655048 * α ^ 20 * (17 - α) ^ 30 + 14699642422912871844500841018776542189279022499143301125114403207390856393770245321897888096820 * α ^ 21 * (17 - α) ^ 29 + 53673006585933151650707212393612027990337017921471920103972688477444212042080888181402531954623 * α ^ 22 * (17 - α) ^ 28 + 177424630381056553613555892437643150189372774889210179326490713116128958479669098035885345446552 * α ^ 23 * (17 - α) ^ 27 + 531217322618016492802133586903649391958733336005082950612572311095808910788505345175592814369580 * α ^ 24 * (17 - α) ^ 26 + 1440878297786625726057735963735191129687061087876632335989525965863749961422678931848398180994264 * α ^ 25 * (17 - α) ^ 25 + 3540528972380530248060021030700986765668663375909521118259073708483300881659592107503593191364768 * α ^ 26 * (17 - α) ^ 24 + 7878706067439138302871644596778500496033461935373897042861066792548444034343472542257091147209584 * α ^ 27 * (17 - α) ^ 23 + 15866985172027478682631903171788637970460063980973228429209846911200894587882339479475867198952036 * α ^ 28 * (17 - α) ^ 22 + 28888250810289606634245191706663186299318801988344278179610334690859848174281402135692480432780132 * α ^ 29 * (17 - α) ^ 21 + 47477629548102243528458217920917101013725287450823186845340936391317439940465355556234941946032657 * α ^ 30 * (17 - α) ^ 20 + 70302798619149431656063874867631560161982110726463060425195857474073971124206669994193325260431968 * α ^ 31 * (17 - α) ^ 19 + 93578532127885660914680781758934948491041981899416935218375174036595572222667517918310377720198808 * α ^ 32 * (17 - α) ^ 18 + 111671046495563139231753996807194588715349583644959990280095487148731493003528163756917394817921848 * α ^ 33 * (17 - α) ^ 17 + 119108317519314874116452075964414453573552081166001011602192516430347593073861906203222286276783210 * α ^ 34 * (17 - α) ^ 16 + 113156360454221734073606765068373900287501266200716732578873162490509611564763213724059111444879912 * α ^ 35 * (17 - α) ^ 15 + 95376447959581379971158449180838329759355945573810871902930153136280190435130420456031549759592432 * α ^ 36 * (17 - α) ^ 14 + 71000547856694915769126077715715772989720497286001979959236111644677764746629355003121324873743636 * α ^ 37 * (17 - α) ^ 13 + 46435247311237875241086804176274841256465196204557482607524607905695835753570599397044472496443683 * α ^ 38 * (17 - α) ^ 12 + 26514718964077437868313478305791884794282002198254450319170212656068940296217672260748146187929000 * α ^ 39 * (17 - α) ^ 11 + 13119684648080558068145400061379201620208126873006769889319790885496821503611538738560892688675108 * α ^ 40 * (17 - α) ^ 10 + 5574304384447257915334770015429223070725790686644478804358809424096493843062858412483691392992136 * α ^ 41 * (17 - α) ^ 9 + 2010881865895736598424115789062219791810721593821299429086893216589613227274491543685953304227120 * α ^ 42 * (17 - α) ^ 8 + 607237389577241841869363680453643402590101734012060773034199963895826888891782257735573905657616 * α ^ 43 * (17 - α) ^ 7 + 150749895847577632681470277527543538771101449370569486067541118295682832958042871499658490290684 * α ^ 44 * (17 - α) ^ 6 + 30052820272696317463395531462440009839882141116365183097551075391516536642298874821618150390348 * α ^ 45 * (17 - α) ^ 5 + 4663688556843488364172070998639274132596372023847717839521027547698552604606780971945788903755 * α ^ 46 * (17 - α) ^ 4 + 540081530702743610283233889828122230493014768961119305004582751972922686852640193916287106992 * α ^ 47 * (17 - α) ^ 3 + 43983793487190009087693541621146525651052894618594476651626932794533461019682370365887330080 * α ^ 48 * (17 - α) ^ 2 + 2295554691290398410917187961072648259042029375130142853380489371587928525721201467534862000 * α ^ 49 * (17 - α) ^ 1 + 61696825755958662910832536044204740555351244465959101505141229428727029482047853259288100 * α ^ 50 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 52 ≤ n) (h1 : n ≤ 53) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (53 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (53 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 52) (n := n) (n₁ := 53) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((52 : ℕ) : ℝ) - 4 = 48 by norm_num] at hb - rw [show (48 : ℝ) / 2 = ((24 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 51) + 1 / (4 * 51 * (3 + α)) + (1 - 2 * α / 52) ^ 2 * 53 * 52 * (53 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 51 * (3 + α)) ^ 24)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 52 ≤ n) (h1 : n ≤ 53) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 52) (n₁ := 53) (k := 24) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B52_53 diff --git a/Sendov/FiniteRange/Degree54_55.lean b/Sendov/FiniteRange/Degree54_55.lean index 38099b7..21d4509 100644 --- a/Sendov/FiniteRange/Degree54_55.lean +++ b/Sendov/FiniteRange/Degree54_55.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 54 to 55 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 54) (gg1 54) (gg2 54) 25)) α := by - refine pev_wsum_eq_of_packed (gg0 54) (gg1 54) (gg2 54) 25 76 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 54) (gg1 54) (gg2 54) 25 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 54) (gg1 54) (gg2 54) 25 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 54) (gg1 54) (gg2 54) 3 (by simp) (by simp) (by simp) 25) - · rfl + refine pev_moment_eq_of_packed_bounds 54 25 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 54 α t ^ 25) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 16494167009921791229556693354250558994004960089275608134952301595194145700 + 143495585732014632876947701159299432571935297872102967009453889788942630516 * α + 600146981561757364071810080610152109467421702720565940343744136045710714240 * α ^ 2 + 1606309613433661462999425062531603257368288440796455160921241994205807550800 * α ^ 3 + 3089935016411981969366335770505513109414946535522135899534602918518452400110 * α ^ 4 + 4548021756358959061868607547427969034568735681024830591427930680507708516630 * α ^ 5 + 5324472427116589963068442803453435582254682183625311260959169925128717206890 * α ^ 6 + 5088112301464007763161223382731859106222272351099136492562868432790050748010 * α ^ 7 + 4041350342582910718376698346793695673500055519225008392201038233346955184130 * α ^ 8 + 2702810799510161555412033309004487136564483291932054239796551253387958338250 * α ^ 9 + 1536279381058752516392997665745371680813310918710686404622076783423411472310 * α ^ 10 + 747035505761971294025842500370255312982388584883798779389925639599781539110 * α ^ 11 + 312120280284390297007832319287765858778034126483703719026036710712245847630 * α ^ 12 + 112328303645112191177480265164326260518118446637968730517219246030090061670 * α ^ 13 + 34847965479991464020760392422930205817393828567231232594447128943554577950 * α ^ 14 + 9311065733578254803436313728561027301061995457613177507038687159207136510 * α ^ 15 + 2137053395968205693740631086110584184448273974022381233594071100920418660 * α ^ 16 + 419415497303046617346927271099007566525536754801411545759490611489535020 * α ^ 17 + 69903195768650128169410986270066096062738214853608222509952701694930390 * α ^ 18 + 9796751930080145102336247171862671684216870902559058128633974960508990 * α ^ 19 + 1138373287745887689323718901024639495300275153431093749751357684888655 * α ^ 20 + 107431234099507044305505224510335533709977858803000709455555262812475 * α ^ 21 + 7965572671696337257969240111258550023673082988480052797472718090765 * α ^ 22 + 432489851677951286849434341419775059089962332363725955872440307245 * α ^ 23 + 10033042060175777949356539605564287060646991070535569056012261935 * α ^ 24 - 14665345174670112106333566037790518499419114767637006814333117685 * α ^ 25 + 467265281717233365794825008753399741068194685496332969035489307 * α ^ 26 - 338571739674856609859042128682071390079128171355900195378565 * α ^ 27 + 51828010052697170919200272082439937455364221416970311841360 * α ^ 28 + 4551610675134221759317748807561457084971246067804745378320 * α ^ 29 + 209779510423918524619133931870713143087995729911985149040 * α ^ 30 + 5970127197067432618593627815816805105135662362948064640 * α ^ 31 + 72450550286061369082689048114099286472057904479048640 * α ^ 32 - 2583219468428786599910558481880637801957466132337920 * α ^ 33 - 195852731109616002368456744436432386876454107873280 * α ^ 34 - 7247973580231951783404261339025545494805311297280 * α ^ 35 - 194124681108967495056283792222752779031406556160 * α ^ 36 - 4123433450448809567758812935503400791570882560 * α ^ 37 - 72082021160947668781050521228246549326725120 * α ^ 38 - 1056193512343203991501036178583787410636800 * α ^ 39 - 13096880010730035770569022035700611809280 * α ^ 40 - 138052872308930943537538309704895365120 * α ^ 41 - 1238136265130428487231808151440916480 * α ^ 42 - 9428378825017111932776968669429760 * α ^ 43 - 60659413041205873935423111168000 * α ^ 44 - 327048428909975887634922209280 * α ^ 45 - 1459908719275463855607644160 * α ^ 46 - 5302273507938488014602240 * α ^ 47 - 15275608180278584934400 * α ^ 48 - 33595607399404666880 * α ^ 49 - 52996826537656320 * α ^ 50 - 53409512161280 * α ^ 51 - 25836912640 * α ^ 52 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 52 * (16494167009921791229556693354250558994004960089275608134952301595194145700 + 143495585732014632876947701159299432571935297872102967009453889788942630516 * α + 600146981561757364071810080610152109467421702720565940343744136045710714240 * α ^ 2 + 1606309613433661462999425062531603257368288440796455160921241994205807550800 * α ^ 3 + 3089935016411981969366335770505513109414946535522135899534602918518452400110 * α ^ 4 + 4548021756358959061868607547427969034568735681024830591427930680507708516630 * α ^ 5 + 5324472427116589963068442803453435582254682183625311260959169925128717206890 * α ^ 6 + 5088112301464007763161223382731859106222272351099136492562868432790050748010 * α ^ 7 + 4041350342582910718376698346793695673500055519225008392201038233346955184130 * α ^ 8 + 2702810799510161555412033309004487136564483291932054239796551253387958338250 * α ^ 9 + 1536279381058752516392997665745371680813310918710686404622076783423411472310 * α ^ 10 + 747035505761971294025842500370255312982388584883798779389925639599781539110 * α ^ 11 + 312120280284390297007832319287765858778034126483703719026036710712245847630 * α ^ 12 + 112328303645112191177480265164326260518118446637968730517219246030090061670 * α ^ 13 + 34847965479991464020760392422930205817393828567231232594447128943554577950 * α ^ 14 + 9311065733578254803436313728561027301061995457613177507038687159207136510 * α ^ 15 + 2137053395968205693740631086110584184448273974022381233594071100920418660 * α ^ 16 + 419415497303046617346927271099007566525536754801411545759490611489535020 * α ^ 17 + 69903195768650128169410986270066096062738214853608222509952701694930390 * α ^ 18 + 9796751930080145102336247171862671684216870902559058128633974960508990 * α ^ 19 + 1138373287745887689323718901024639495300275153431093749751357684888655 * α ^ 20 + 107431234099507044305505224510335533709977858803000709455555262812475 * α ^ 21 + 7965572671696337257969240111258550023673082988480052797472718090765 * α ^ 22 + 432489851677951286849434341419775059089962332363725955872440307245 * α ^ 23 + 10033042060175777949356539605564287060646991070535569056012261935 * α ^ 24 - 14665345174670112106333566037790518499419114767637006814333117685 * α ^ 25 + 467265281717233365794825008753399741068194685496332969035489307 * α ^ 26 - 338571739674856609859042128682071390079128171355900195378565 * α ^ 27 + 51828010052697170919200272082439937455364221416970311841360 * α ^ 28 + 4551610675134221759317748807561457084971246067804745378320 * α ^ 29 + 209779510423918524619133931870713143087995729911985149040 * α ^ 30 + 5970127197067432618593627815816805105135662362948064640 * α ^ 31 + 72450550286061369082689048114099286472057904479048640 * α ^ 32 - 2583219468428786599910558481880637801957466132337920 * α ^ 33 - 195852731109616002368456744436432386876454107873280 * α ^ 34 - 7247973580231951783404261339025545494805311297280 * α ^ 35 - 194124681108967495056283792222752779031406556160 * α ^ 36 - 4123433450448809567758812935503400791570882560 * α ^ 37 - 72082021160947668781050521228246549326725120 * α ^ 38 - 1056193512343203991501036178583787410636800 * α ^ 39 - 13096880010730035770569022035700611809280 * α ^ 40 - 138052872308930943537538309704895365120 * α ^ 41 - 1238136265130428487231808151440916480 * α ^ 42 - 9428378825017111932776968669429760 * α ^ 43 - 60659413041205873935423111168000 * α ^ 44 - 327048428909975887634922209280 * α ^ 45 - 1459908719275463855607644160 * α ^ 46 - 5302273507938488014602240 * α ^ 47 - 15275608180278584934400 * α ^ 48 - 33595607399404666880 * α ^ 49 - 52996826537656320 * α ^ 50 - 53409512161280 * α ^ 51 - 25836912640 * α ^ 52) = 16494167009921791229556693354250558994004960089275608134952301595194145700 * (17 - α) ^ 52 + 3297121641960181902845058974129119421411157988468082062178235809362120295172 * α ^ 1 * (17 - α) ^ 51 + 319724415956160860091458945589182808902003352419736285543485329679451094270932 * α ^ 2 * (17 - α) ^ 50 + 20038710926027661432334875342791217340018851913295984793285523609822774454252700 * α ^ 3 * (17 - α) ^ 49 + 912506063164863213831944030666321098534650758920349287477777497262175240738402310 * α ^ 4 * (17 - α) ^ 48 + 32177823044530476695020659335002454111188404373175841794915018442377955651394113990 * α ^ 5 * (17 - α) ^ 47 + 914540681282828800807599319891793843292641936770051259660032453172015089441416681780 * α ^ 6 * (17 - α) ^ 46 + 21529723418168081854258856249066854725157410727767949291151621244500815386654814167180 * α ^ 7 * (17 - α) ^ 45 + 428187563876954541113963075618060221598963677578037826566438784007708913233247747176780 * α ^ 8 * (17 - α) ^ 44 + 7301844169441283547821796282852027526162858087792900418706107149330943728664004086739660 * α ^ 9 * (17 - α) ^ 43 + 107998890241658105222949402539269436370829457640263205565353289295418525536340771107662680 * α ^ 10 * (17 - α) ^ 42 + 1398093827433571704042090344538943552073638570463931753295281987815735454006786470999735160 * α ^ 11 * (17 - α) ^ 41 + 15957032127861583576984677012499030521875944161240621820452635989220785757028810049931646660 * α ^ 12 * (17 - α) ^ 40 + 161526877975623854315474231221259866905794267588621234412370551845474892520146496256658344580 * α ^ 13 * (17 - α) ^ 39 + 1457239742403607406416443184401351553341986505900117649824594649023236812024794234917099752380 * α ^ 14 * (17 - α) ^ 38 + 11764118385331183795485731464799855976003853373075619337664964031988252913700051042473465972420 * α ^ 15 * (17 - α) ^ 37 + 85266812327847025363233082778590085924666659056638604615146724746162734347495123483376596599070 * α ^ 16 * (17 - α) ^ 36 + 556412933665661316562603334092469787110651645009094640295939461919699008524178193574911456908110 * α ^ 17 * (17 - α) ^ 35 + 3276500502586555718746248192880369763373913284974973228696609120912342926842381883477115970971330 * α ^ 18 * (17 - α) ^ 34 + 17443973618063549860197174258607173645342170656659807634029925978540184960307013051100945108575830 * α ^ 19 * (17 - α) ^ 33 + 84097208992473763322482498841713994615424570017542204453635043962819422256085229322643661036553135 * α ^ 20 * (17 - α) ^ 32 + 367595670215331608081325934241054123019019558617664793950031213417886531914880453450235055639827695 * α ^ 21 * (17 - α) ^ 31 + 1458319292273003092992284569774617261635353524450745892916673491633645545947909275323789971386584010 * α ^ 22 * (17 - α) ^ 30 + 5254980271354566622530408171222928163731186808057577088774647757156770300739259401327506864767179590 * α ^ 23 * (17 - α) ^ 29 + 17209987305609188388593928884348304692679416452958887120667494264685355764336243613006433529300889900 * α ^ 24 * (17 - α) ^ 28 + 51245313767700576927493227999999199039753952598947831546238937797935220706183422086338270920360486300 * α ^ 25 * (17 - α) ^ 27 + 138766478666356226035473697072120508245376894603069112986887914209096091729659135725891961666489860662 * α ^ 26 * (17 - α) ^ 26 + 341725720150049744585959626125868368010499310869413614657759212314754963597840236324448419782451114282 * α ^ 27 * (17 - α) ^ 25 + 765136285933410012453175445478517650702161463656786558161202904376215029605986594283307478093304307385 * α ^ 28 * (17 - α) ^ 24 + 1556877403438278759283881545391171005360005954054145030966940257959498891624213557816408094093075864665 * α ^ 29 * (17 - α) ^ 23 + 2876564405128945633873865865688129358774847644012865518697098702186811357802016717785624061301955829430 * α ^ 30 * (17 - α) ^ 22 + 4820561162618100599568269482213420070663798726185647089067973322799735823546946658344673073602139469970 * α ^ 31 * (17 - α) ^ 21 + 7315920828232011027352935983664196353610979185130017647700999674444485613522154300362261069304268308590 * α ^ 32 * (17 - α) ^ 20 + 10036378526288476516030178366360979243689435681024753191393010979431912513169664181917187452264705749630 * α ^ 33 * (17 - α) ^ 19 + 12418173602350336332834011143730287052626259450406781462033191143152690802051403229595128207313656006650 * α ^ 34 * (17 - α) ^ 18 + 13822754463345097102831820242184258761738276008006821284534279176481079905732530814499207866955435085150 * α ^ 35 * (17 - α) ^ 17 + 13801040060918957888564788139270767298844994408740307330701472008264699451769662273654318158513511789155 * α ^ 36 * (17 - α) ^ 16 + 12318471680266652419845517118100896836955882316001519109947812762310692937531763121301079422467179937315 * α ^ 37 * (17 - α) ^ 15 + 9791961276777243139471730047869500129996328504872391696608131789839153344852214590773875133920134451090 * α ^ 38 * (17 - α) ^ 14 + 6901396925674586370353679055683314537328841096886193608522335358563478321818303138218149658902821023950 * α ^ 39 * (17 - α) ^ 13 + 4290696155282947318028543407039084473970660925581234584798657667133577612919565979582433162065644672980 * α ^ 40 * (17 - α) ^ 12 + 2338873380377640090710543794097867885941646034550384133409823471730993425571758516636190486584614953700 * α ^ 41 * (17 - α) ^ 11 + 1109732755852378588712211011650814187613669797876675740951121816904470151813091358110884216937743142050 * α ^ 42 * (17 - α) ^ 10 + 454286800542359954534080719815999805873534526512065733818696923800302006274839909248752230406180846110 * α ^ 43 * (17 - α) ^ 9 + 158713699307083273689749079467203333163770903148624457146145339447571976015368636000957338799724035275 * α ^ 44 * (17 - α) ^ 8 + 46680861352325638868600152099580545678224568597334155135966362508038806503807101375708916251637014315 * α ^ 45 * (17 - α) ^ 7 + 11358113255233464326610717370655147651105757900848936506289875029144788364049674739051630170475728510 * α ^ 46 * (17 - α) ^ 6 + 2234292960434683002788971594223923746722335287405129686566824534284185319130892757911313973235591050 * α ^ 47 * (17 - α) ^ 5 + 344434128456143069997502715027323329232394662376196306985663027670793467133639790028593418988513700 * α ^ 48 * (17 - α) ^ 4 + 39809789393720194364475874377808256220963899458735378967674739520923108380632695527160035322788100 * α ^ 49 * (17 - α) ^ 3 + 3224979637871433689973695689784750956991084495357901531836611031085730991516232539844546931899840 * α ^ 50 * (17 - α) ^ 2 + 162942207478993682465981071080743775591479135331458384477879849257595493096166794488597275948400 * α ^ 51 * (17 - α) ^ 1 + 3907984261693816830880565006531529193978954398787645698090073443074989996324628172410599696000 * α ^ 52 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 54 ≤ n) (h1 : n ≤ 55) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (55 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (55 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 54) (n := n) (n₁ := 55) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((54 : ℕ) : ℝ) - 4 = 50 by norm_num] at hb - rw [show (50 : ℝ) / 2 = ((25 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 53) + 1 / (4 * 53 * (3 + α)) + (1 - 2 * α / 54) ^ 2 * 55 * 54 * (55 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 53 * (3 + α)) ^ 25)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 54 ≤ n) (h1 : n ≤ 55) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 54) (n₁ := 55) (k := 25) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B54_55 diff --git a/Sendov/FiniteRange/Degree56_58.lean b/Sendov/FiniteRange/Degree56_58.lean index 652186c..85935cc 100644 --- a/Sendov/FiniteRange/Degree56_58.lean +++ b/Sendov/FiniteRange/Degree56_58.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 56 to 58 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 56) (gg1 56) (gg2 56) 26)) α := by - refine pev_wsum_eq_of_packed (gg0 56) (gg1 56) (gg2 56) 26 79 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 56) (gg1 56) (gg2 56) 26 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 56) (gg1 56) (gg2 56) 26 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 56) (gg1 56) (gg2 56) 3 (by simp) (by simp) (by simp) 26) - · rfl + refine pev_moment_eq_of_packed_bounds 56 26 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 56 α t ^ 26) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 4006776526237583458791916745921571399903640427998587971001863479614257812500 + 36193299233577005092404435186325555880909575118523570487124919891357421875000 * α + 157404458430456801566314898531435489082055275896144801637965440750122070312500 * α ^ 2 + 438789302805190644765999692456086768304410010456706455086051940917968750000000 * α ^ 3 + 880644388246065999407804638303739222032368746089754793927588987350463867187500 * α ^ 4 + 1354948378632315916086740220782422392456213284262767321014325168609619140625000 * α ^ 5 + 1661602897691580734737365439849633466188200353673006461916168213272094726562500 * α ^ 6 + 1667045608015110082374111106109377028467549691711516663117268814086914062500000 * α ^ 7 + 1393634964581423479006807950372755382512403362475605339704530439338684082031250 * α ^ 8 + 983739476273137944395322828805928193025534886625965973020494254135131835937500 * α ^ 9 + 592005671863910309809560316101676243798968926448970748675875927594299316406250 * α ^ 10 + 305845520279728243480763379048878002620628430303914474045381805538574218750000 * α ^ 11 + 136301035857816688759209743042609079523363637041425866478473082778930664062500 * α ^ 12 + 52557215535889563135879554015106695279244905727351138276424395612451171875000 * α ^ 13 + 17560188550728447991878218358662068709211261557084724400278409291245117187500 * α ^ 14 + 5083558311018366382022659794526798695920221466826180257750759952604687500000 * α ^ 15 + 1273131764429501958625291301675693164238362230486966503823878444190878906250 * α ^ 16 + 274960492120840016369195438376101201319262210714934208739555078202929687500 * α ^ 17 + 50954380823074628723812132018848659015398414173106367885877485025457031250 * α ^ 18 + 8043619315575642311782000673332751078848207374194599271764060475643750000 * α ^ 19 + 1070647032300550686760844315611512648892236354901418090931769834405593750 * α ^ 20 + 118447064950886641697648118438020073800095586622991278431631099619912500 * α ^ 21 + 10665844034582511896384387237050410144703560308738822660894704597031250 * α ^ 22 + 756055215489708905909989210679280265318059125676239214550223981550000 * α ^ 23 + 39319509582765585318317434167304155450155442605644113789923547061875 * α ^ 24 + 867126925428575278846841639739898919922847699797676292404824708330 * α ^ 25 - 1342664334700830923321502819993530701259788051847367543772214665281 * α ^ 26 + 39483777041359676646803092797859249221387704496311861748873113400 * α ^ 27 - 58711046556251894173073392026014465411610439743591823421605392 * α ^ 28 + 2490932168525853073760934875391654922167755426092527716004768 * α ^ 29 + 299316943768298507774611885828874444092265356390330098080400 * α ^ 30 + 15336692487146884782753132557947737242171025616954771587840 * α ^ 31 + 493116066063688255278336127843281464063956961803863360000 * α ^ 32 + 8923910394517508916121212299646048703215085675738298880 * α ^ 33 - 42485806368509927498334028885467492467879729762661120 * α ^ 34 - 9926741056642548036510544310918633673463407651072000 * α ^ 35 - 427541739200753198037475741948767076883193745367040 * α ^ 36 - 12336686560635193418143284676363319056265591808000 * α ^ 37 - 276403480622187214471125457231894057984922849280 * α ^ 38 - 5061460700774592700650136059515237541978439680 * α ^ 39 - 77589542792718274978754693243996574602035200 * α ^ 40 - 1008285668556426930549466452256224957562880 * α ^ 41 - 11180151867078112441929755167105458176000 * α ^ 42 - 106057325448908908308826107393838940160 * α ^ 43 - 860453519636632559264422458435829760 * α ^ 44 - 5953015798094365467380006676070400 * α ^ 45 - 34925450531279060313143566663680 * α ^ 46 - 172262764126427765287157760000 * α ^ 47 - 705448234661772873443573760 * α ^ 48 - 2356408942484969918300160 * α ^ 49 - 6257674902168236195840 * α ^ 50 - 12711757957239406592 * α ^ 51 - 18555990127411200 * α ^ 52 - 17333951135744 * α ^ 53 - 7784628224 * α ^ 54 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 54 * (4006776526237583458791916745921571399903640427998587971001863479614257812500 + 36193299233577005092404435186325555880909575118523570487124919891357421875000 * α + 157404458430456801566314898531435489082055275896144801637965440750122070312500 * α ^ 2 + 438789302805190644765999692456086768304410010456706455086051940917968750000000 * α ^ 3 + 880644388246065999407804638303739222032368746089754793927588987350463867187500 * α ^ 4 + 1354948378632315916086740220782422392456213284262767321014325168609619140625000 * α ^ 5 + 1661602897691580734737365439849633466188200353673006461916168213272094726562500 * α ^ 6 + 1667045608015110082374111106109377028467549691711516663117268814086914062500000 * α ^ 7 + 1393634964581423479006807950372755382512403362475605339704530439338684082031250 * α ^ 8 + 983739476273137944395322828805928193025534886625965973020494254135131835937500 * α ^ 9 + 592005671863910309809560316101676243798968926448970748675875927594299316406250 * α ^ 10 + 305845520279728243480763379048878002620628430303914474045381805538574218750000 * α ^ 11 + 136301035857816688759209743042609079523363637041425866478473082778930664062500 * α ^ 12 + 52557215535889563135879554015106695279244905727351138276424395612451171875000 * α ^ 13 + 17560188550728447991878218358662068709211261557084724400278409291245117187500 * α ^ 14 + 5083558311018366382022659794526798695920221466826180257750759952604687500000 * α ^ 15 + 1273131764429501958625291301675693164238362230486966503823878444190878906250 * α ^ 16 + 274960492120840016369195438376101201319262210714934208739555078202929687500 * α ^ 17 + 50954380823074628723812132018848659015398414173106367885877485025457031250 * α ^ 18 + 8043619315575642311782000673332751078848207374194599271764060475643750000 * α ^ 19 + 1070647032300550686760844315611512648892236354901418090931769834405593750 * α ^ 20 + 118447064950886641697648118438020073800095586622991278431631099619912500 * α ^ 21 + 10665844034582511896384387237050410144703560308738822660894704597031250 * α ^ 22 + 756055215489708905909989210679280265318059125676239214550223981550000 * α ^ 23 + 39319509582765585318317434167304155450155442605644113789923547061875 * α ^ 24 + 867126925428575278846841639739898919922847699797676292404824708330 * α ^ 25 - 1342664334700830923321502819993530701259788051847367543772214665281 * α ^ 26 + 39483777041359676646803092797859249221387704496311861748873113400 * α ^ 27 - 58711046556251894173073392026014465411610439743591823421605392 * α ^ 28 + 2490932168525853073760934875391654922167755426092527716004768 * α ^ 29 + 299316943768298507774611885828874444092265356390330098080400 * α ^ 30 + 15336692487146884782753132557947737242171025616954771587840 * α ^ 31 + 493116066063688255278336127843281464063956961803863360000 * α ^ 32 + 8923910394517508916121212299646048703215085675738298880 * α ^ 33 - 42485806368509927498334028885467492467879729762661120 * α ^ 34 - 9926741056642548036510544310918633673463407651072000 * α ^ 35 - 427541739200753198037475741948767076883193745367040 * α ^ 36 - 12336686560635193418143284676363319056265591808000 * α ^ 37 - 276403480622187214471125457231894057984922849280 * α ^ 38 - 5061460700774592700650136059515237541978439680 * α ^ 39 - 77589542792718274978754693243996574602035200 * α ^ 40 - 1008285668556426930549466452256224957562880 * α ^ 41 - 11180151867078112441929755167105458176000 * α ^ 42 - 106057325448908908308826107393838940160 * α ^ 43 - 860453519636632559264422458435829760 * α ^ 44 - 5953015798094365467380006676070400 * α ^ 45 - 34925450531279060313143566663680 * α ^ 46 - 172262764126427765287157760000 * α ^ 47 - 705448234661772873443573760 * α ^ 48 - 2356408942484969918300160 * α ^ 49 - 6257674902168236195840 * α ^ 50 - 12711757957239406592 * α ^ 51 - 18555990127411200 * α ^ 52 - 17333951135744 * α ^ 53 - 7784628224 * α ^ 54) = 4006776526237583458791916745921571399903640427998587971001863479614257812500 * (17 - α) ^ 54 + 831652019387638593345638902447299305570259360126824448715224266052246093750000 * α ^ 1 * (17 - α) ^ 53 + 83833748304900879170452634641877950866675611368241564068775231838226318359375000 * α ^ 2 * (17 - α) ^ 52 + 5468494358777378393080477785807867951674090671443673031117236424446105957031250000 * α ^ 3 * (17 - α) ^ 51 + 259497095119023070284911959202753696905030203192837428866594793371009826660156250000 * α ^ 4 * (17 - α) ^ 50 + 9548226194342856021369990031496637841520575254703619359937770099499221801757812500000 * α ^ 5 * (17 - α) ^ 49 + 283554795754116919933939967317880593392006022363436344694634037363653737640380859375000 * α ^ 6 * (17 - α) ^ 48 + 6985033324607242622400264323272167984455201909490308654941771836141864102172851562500000 * α ^ 7 * (17 - α) ^ 47 + 145585869325517123027631865241602024127251143700135843061398935728533566792640686035156250 * α ^ 8 * (17 - α) ^ 46 + 2605939606481930370231755414493637687294479329903418074328564748827833386281097412109375000 * α ^ 9 * (17 - α) ^ 45 + 40524996895639459847128154228148170371947695272650286201553195462882818721524821166992187500 * α ^ 10 * (17 - α) ^ 44 + 552551133383357806856520189290844564406656538250136666178295793900819727635981966064453125000 * α ^ 11 * (17 - α) ^ 43 + 6654537960345176614579520210501969964341553464814299926502106023232060321118045116027832031250 * α ^ 12 * (17 - α) ^ 42 + 71215632892928225012541089836574503427207341702460836120538723682777701285820760548632812500000 * α ^ 13 * (17 - α) ^ 41 + 680613583355729809602306987711530797435340161763367564193121313750649561609059057159169921875000 * α ^ 14 * (17 - α) ^ 40 + 5832875752360000513642484795718619279175379757851803276997150658226737011497871446091396093750000 * α ^ 15 * (17 - α) ^ 39 + 44979351085207558150078784978662679910370590969134326277300556578996443629331813144059755039062500 * α ^ 16 * (17 - α) ^ 38 + 312995911940481513520445963433861073963208442217604567895958294256991627351128534764956244218750000 * α ^ 17 * (17 - α) ^ 37 + 1970161029906836645506545335621217130652959793873949162987985608245722153781520858422880420890625000 * α ^ 18 * (17 - α) ^ 36 + 11240168074382975494983845291739726207752209032492025653981589349256891847236794547066229926806250000 * α ^ 19 * (17 - α) ^ 35 + 58220468052171150534543089230853402616213765163545474800357913943776071267588624931694422468683718750 * α ^ 20 * (17 - α) ^ 34 + 274162442806735488937328580878545767896445602338781689345873092416421648387300355873155086008186200000 * α ^ 21 * (17 - α) ^ 33 + 1175053053219549755923303158761313219677705229404659836838649889496146832750569917119434117241667287500 * α ^ 22 * (17 - α) ^ 32 + 4587918386962882020150348519193673004398898248795343130672609419407279340288027481893308532612882750000 * α ^ 23 * (17 - α) ^ 31 + 16330076475454767959070546693996088924163345527886054247186679311654325903066537139062302883030633149375 * α ^ 24 * (17 - α) ^ 30 + 53015531748660804101125233244023173725306131782343261679623854226624053438968135738999293061644801261060 * α ^ 25 * (17 - α) ^ 29 + 157042247362868043075174929076891424448113760391534609598267651251111262726701902052468899161352536565826 * α ^ 26 * (17 - α) ^ 28 + 424536028113530069741207063773543340247417183854664190521457558189988983776332421257010922807774328703468 * α ^ 27 * (17 - α) ^ 27 + 1047394825014464265044437577949313703859620376795552005549249263622157394802977948988963043499590064285701 * α ^ 28 * (17 - α) ^ 26 + 2357953243932795895351786030037214986312773901878377266600410243701385112182023007703278183236835882555920 * α ^ 29 * (17 - α) ^ 25 + 4841990819787898672356879612840738450763274999724268831092864647028159910497634849060319644324211875401000 * α ^ 30 * (17 - α) ^ 24 + 9063584503650178882271337601783826443148131765373991434810543048088202441000466212270593355824045378675000 * α ^ 31 * (17 - α) ^ 23 + 15451128490873801008027757078817526210012989527697672000297488543102153793093056771081079889530059921809375 * α ^ 32 * (17 - α) ^ 22 + 23958789035470262232279921076956417405034112471262464267273767085684019981430087645587646696528226066737500 * α ^ 33 * (17 - α) ^ 21 + 33738977176761179018990595988066513346352404262225555749812365323678028997756330293158647680594843998343750 * α ^ 34 * (17 - α) ^ 20 + 43066010152981647775428783321099345843672023374934640403912525283591537133423955925346616576791170076562500 * α ^ 35 * (17 - α) ^ 19 + 49716389232502500304027459338301800974067035710033081062048758917500248639945950282904415348908887986328125 * α ^ 36 * (17 - α) ^ 18 + 51772728585970415852508288051049002543845872981898134416451565218988426676405878702958035332866606796875000 * α ^ 37 * (17 - α) ^ 17 + 48489623083597730277404885225414500632015670930460944310500759458078933768686805720241794646887945820312500 * α ^ 38 * (17 - α) ^ 16 + 40706685418039446342456126818361030430892463367085468425983118729461107320981091338190269943859904687500000 * α ^ 39 * (17 - α) ^ 15 + 30510757875107724377755328842206506253240610141014079628356809193148547036423525594278170823630233154296875 * α ^ 40 * (17 - α) ^ 14 + 20325417185768341572644199400008775190356569699126770047800664408936401012312339590678833285411352539062500 * α ^ 41 * (17 - α) ^ 13 + 11970484403352576009251094586102294750081037384202884978488076602265682461511720826286535223334289550781250 * α ^ 42 * (17 - α) ^ 12 + 6193242030824480837746170022650419963156765230142047685904514800454071854093027706906593305633666992187500 * α ^ 43 * (17 - α) ^ 11 + 2793420712321765649092179680582709716866031666381458570060592097389668488933904453892321322512969970703125 * α ^ 44 * (17 - α) ^ 10 + 1088149422884559786015096896649994047996413331792775697347682065754794925880331083486662942138671875000000 * α ^ 45 * (17 - α) ^ 9 + 361802514627870134054227480223533630715173215487471596187535638974794633464984427234290066680908203125000 * α ^ 46 * (17 - α) ^ 8 + 101146608070751659320633087948602468401536695297326173484816516224027843212819017493162674713134765625000 * α ^ 47 * (17 - α) ^ 7 + 23308619653592257439475827609650039406713094584665162739531070571873085270495926103569096851348876953125 * α ^ 48 * (17 - α) ^ 6 + 4309056167008746262541403431206719244122955714616670864926279020311783589907259065312067031860351562500 * α ^ 49 * (17 - α) ^ 5 + 614552339408580729666564781265917271485257491177590074251947797114305883650016905691361427307128906250 * α ^ 50 * (17 - α) ^ 4 + 63623700305983189824220164500388274837272339260459679341376353550049617549841760780096054077148437500 * α ^ 51 * (17 - α) ^ 3 + 4296576620263370001927713368254137045425780398934810417013483195008307979207405258715152740478515625 * α ^ 52 * (17 - α) ^ 2 + 149430873582062166621125852273186331577668585046621031080994039368115021643902842998504638671875000 * α ^ 53 * (17 - α) ^ 1 + 947247377954257591039710592438900578151634152117436911287820530796278073275661468505859375000000 * α ^ 54 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 56 ≤ n) (h1 : n ≤ 58) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (58 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (58 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 56) (n := n) (n₁ := 58) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((56 : ℕ) : ℝ) - 4 = 52 by norm_num] at hb - rw [show (52 : ℝ) / 2 = ((26 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 55) + 1 / (4 * 55 * (3 + α)) + (1 - 2 * α / 57) ^ 2 * 58 * 57 * (58 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 55 * (3 + α)) ^ 26)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 56 ≤ n) (h1 : n ≤ 58) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 56) (n₁ := 58) (k := 26) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B56_58 diff --git a/Sendov/FiniteRange/Degree58_60.lean b/Sendov/FiniteRange/Degree58_60.lean index 16a8b11..b013b57 100644 --- a/Sendov/FiniteRange/Degree58_60.lean +++ b/Sendov/FiniteRange/Degree58_60.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 58 to 60 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 58) (gg1 58) (gg2 58) 27)) α := by - refine pev_wsum_eq_of_packed (gg0 58) (gg1 58) (gg2 58) 27 82 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 58) (gg1 58) (gg2 58) 27 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 58) (gg1 58) (gg2 58) 27 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 58) (gg1 58) (gg2 58) 3 (by simp) (by simp) (by simp) 27) - · rfl + refine pev_moment_eq_of_packed_bounds 58 27 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 58 α t ^ 27) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 1180273288616099684023784650402498199886255444730023274978571199510266513047596 + 11055102824011442029948266567510506642575381276841013106178383140649638883273740 * α + 49922645194024990734283616516471280600334184364447547102243551298880869797559488 * α ^ 2 + 144719942608174873104026182095524650959577750970144395839719569131273169856379216 * α ^ 3 + 302526482246635225757578631533959631447003848728875689601323895427543714021299068 * α ^ 4 + 485662255765025402514981086091947264736043236799566038683821482401809082117981716 * α ^ 5 + 622606333409943749753890815208648354755606137297243000849237534232491249017638372 * α ^ 6 + 654352069860427639900751348035281558837881303628117455206054590616141095225034932 * α ^ 7 + 574357399231416827070511854689853503943460240353865007966655407656850680547039034 * α ^ 8 + 426752571345870223801790426727818388140106457832728071034614633845667453226768626 * α ^ 9 + 271079935317622563319456334579591661701883897872193010593643933885082711035509852 * α ^ 10 + 148286371479076003045732417755582133525685636981220867944156217604240361014274724 * α ^ 11 + 70217169066647225915394151645973808431273168363378941311910545513943342491505944 * α ^ 12 + 28882635903906998561313897779843874583553384770520360078626138405360811163881868 * α ^ 13 + 10340675254845519580917140785070160244501596661998078491888557158268998114446532 * α ^ 14 + 3224423637549642502496418645711742177932306998129835583325750859424757337666996 * α ^ 15 + 875062504101721302059576940201180260130574140021726848117119157209427049292266 * α ^ 16 + 206253961710804940753907484420744734282964403780943395544748624256594408470306 * α ^ 17 + 42070236802464351764635254679415144786913128539020355841577805021278534599952 * α ^ 18 + 7386217051829558880237703381942358818281589489452528309990518263995367432488 * α ^ 19 + 1107793613576531791057535432236447149617292886122026324465700872270457547494 * α ^ 20 + 140459087137897856469559866359157699541937133355950394902889100420287426914 * α ^ 21 + 14838359760717420231756157247609092582149974794155897343599292760550967914 * α ^ 22 + 1279004725824261809420174464624373933895777466651732360112330465852550258 * α ^ 23 + 87033426312093344876434088654180488427125423854890952784009041976465947 * α ^ 24 + 4369112665592393971521458232346790403396711247658540001242310421975335 * α ^ 25 + 97654992764826340667007297954456940399851548824989983096539223841294 * α ^ 26 - 140180336953330902099623933788922389004727627031585783295797300519590 * α ^ 27 + 4011521197356040330478113154305443808925568648433687983973999832370 * α ^ 28 - 6836116057285781356883522416064683372386240155164063320736832232 * α ^ 29 + 136155913451608763461692617832470536736112881493096843133744560 * α ^ 30 + 23084190208503516369122355362110577411004819796039225427268288 * α ^ 31 + 1272092669921250187525125636594403706428638167041905626630688 * α ^ 32 + 43743288386492835342171671864673441962710429642110919385856 * α ^ 33 + 919770851750237042763795205605716932136524848257092998144 * α ^ 34 + 3589129787637507437982773070768409846725811870537367040 * α ^ 35 - 616787227367020803961294798626057817769112354291227136 * α ^ 36 - 30943009074599150760660807547437896432729575808956416 * α ^ 37 - 952040288448666548370356300676837076289373764554752 * α ^ 38 - 22303674458304714179931228274300996373189822005248 * α ^ 39 - 424667137052011465151087643604559827985297448960 * α ^ 40 - 6764616781706422065650823730243312809557557248 * α ^ 41 - 91516551558371359215307258976568083952304128 * α ^ 42 - 1060132719651553338827644611213921972781056 * α ^ 43 - 10557532799422900249752275241549216743424 * α ^ 44 - 90481973634654084996556237361914576896 * α ^ 45 - 666432341608325016551912342849323008 * α ^ 46 - 4202788903097596849838434642034688 * α ^ 47 - 22554190076903951857505928216576 * α ^ 48 - 102065451905712762371350462464 * α ^ 49 - 384517782188687390618419200 * α ^ 50 - 1184406710041525201403904 * α ^ 51 - 2906644614364092432384 * α ^ 52 - 5467069217104723968 * α ^ 53 - 7402337748385792 * α ^ 54 - 6424197332992 * α ^ 55 - 2684354560 * α ^ 56 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 56 * (1180273288616099684023784650402498199886255444730023274978571199510266513047596 + 11055102824011442029948266567510506642575381276841013106178383140649638883273740 * α + 49922645194024990734283616516471280600334184364447547102243551298880869797559488 * α ^ 2 + 144719942608174873104026182095524650959577750970144395839719569131273169856379216 * α ^ 3 + 302526482246635225757578631533959631447003848728875689601323895427543714021299068 * α ^ 4 + 485662255765025402514981086091947264736043236799566038683821482401809082117981716 * α ^ 5 + 622606333409943749753890815208648354755606137297243000849237534232491249017638372 * α ^ 6 + 654352069860427639900751348035281558837881303628117455206054590616141095225034932 * α ^ 7 + 574357399231416827070511854689853503943460240353865007966655407656850680547039034 * α ^ 8 + 426752571345870223801790426727818388140106457832728071034614633845667453226768626 * α ^ 9 + 271079935317622563319456334579591661701883897872193010593643933885082711035509852 * α ^ 10 + 148286371479076003045732417755582133525685636981220867944156217604240361014274724 * α ^ 11 + 70217169066647225915394151645973808431273168363378941311910545513943342491505944 * α ^ 12 + 28882635903906998561313897779843874583553384770520360078626138405360811163881868 * α ^ 13 + 10340675254845519580917140785070160244501596661998078491888557158268998114446532 * α ^ 14 + 3224423637549642502496418645711742177932306998129835583325750859424757337666996 * α ^ 15 + 875062504101721302059576940201180260130574140021726848117119157209427049292266 * α ^ 16 + 206253961710804940753907484420744734282964403780943395544748624256594408470306 * α ^ 17 + 42070236802464351764635254679415144786913128539020355841577805021278534599952 * α ^ 18 + 7386217051829558880237703381942358818281589489452528309990518263995367432488 * α ^ 19 + 1107793613576531791057535432236447149617292886122026324465700872270457547494 * α ^ 20 + 140459087137897856469559866359157699541937133355950394902889100420287426914 * α ^ 21 + 14838359760717420231756157247609092582149974794155897343599292760550967914 * α ^ 22 + 1279004725824261809420174464624373933895777466651732360112330465852550258 * α ^ 23 + 87033426312093344876434088654180488427125423854890952784009041976465947 * α ^ 24 + 4369112665592393971521458232346790403396711247658540001242310421975335 * α ^ 25 + 97654992764826340667007297954456940399851548824989983096539223841294 * α ^ 26 - 140180336953330902099623933788922389004727627031585783295797300519590 * α ^ 27 + 4011521197356040330478113154305443808925568648433687983973999832370 * α ^ 28 - 6836116057285781356883522416064683372386240155164063320736832232 * α ^ 29 + 136155913451608763461692617832470536736112881493096843133744560 * α ^ 30 + 23084190208503516369122355362110577411004819796039225427268288 * α ^ 31 + 1272092669921250187525125636594403706428638167041905626630688 * α ^ 32 + 43743288386492835342171671864673441962710429642110919385856 * α ^ 33 + 919770851750237042763795205605716932136524848257092998144 * α ^ 34 + 3589129787637507437982773070768409846725811870537367040 * α ^ 35 - 616787227367020803961294798626057817769112354291227136 * α ^ 36 - 30943009074599150760660807547437896432729575808956416 * α ^ 37 - 952040288448666548370356300676837076289373764554752 * α ^ 38 - 22303674458304714179931228274300996373189822005248 * α ^ 39 - 424667137052011465151087643604559827985297448960 * α ^ 40 - 6764616781706422065650823730243312809557557248 * α ^ 41 - 91516551558371359215307258976568083952304128 * α ^ 42 - 1060132719651553338827644611213921972781056 * α ^ 43 - 10557532799422900249752275241549216743424 * α ^ 44 - 90481973634654084996556237361914576896 * α ^ 45 - 666432341608325016551912342849323008 * α ^ 46 - 4202788903097596849838434642034688 * α ^ 47 - 22554190076903951857505928216576 * α ^ 48 - 102065451905712762371350462464 * α ^ 49 - 384517782188687390618419200 * α ^ 50 - 1184406710041525201403904 * α ^ 51 - 2906644614364092432384 * α ^ 52 - 5467069217104723968 * α ^ 53 - 7402337748385792 * α ^ 54 - 6424197332992 * α ^ 55 - 2684354560 * α ^ 56) = 1180273288616099684023784650402498199886255444730023274978571199510266513047596 * (17 - α) ^ 56 + 254032052170696096814452472070218512117411786611178526203832500563618785746318956 * α ^ 1 * (17 - α) ^ 55 + 26581786465992714133606222775502371032129394160055924210292174209129794157448936772 * α ^ 2 * (17 - α) ^ 54 + 1801905125284524294246494051997323405505883272969655457886034380748404658915029385356 * α ^ 3 * (17 - α) ^ 53 + 88960777843487839207354469588977939024483934333485516580514560192823003078437474637384 * α ^ 4 * (17 - α) ^ 52 + 3409710295444689753751021773779609449447011909852801588651071013422638895502085385574456 * α ^ 5 * (17 - α) ^ 51 + 105611745061099871040994619483246321125469657724218486870230193879528974892413607636605284 * α ^ 6 * (17 - α) ^ 50 + 2717077493210926098447489650385141874390859518222133351745212828060950258218810177908282556 * α ^ 7 * (17 - α) ^ 49 + 59226539189538299382222748715390123146365770386986878118026762708622792734361308033174370018 * α ^ 8 * (17 - α) ^ 48 + 1110347623085275380732784124563019672170207376288907445733220470280957735947728184470496756010 * α ^ 9 * (17 - α) ^ 47 + 18112519692658810410404967374345439836251270145825076491663143586046571832030458464477826206258 * α ^ 10 * (17 - α) ^ 46 + 259468406097457687929633525944011735968016319542087733822510053479299676655957583926253741360502 * α ^ 11 * (17 - α) ^ 45 + 3288616364869040104475987141993494253571602787363843112397732704776764511075222653495077733735718 * α ^ 12 * (17 - α) ^ 44 + 37103473125865952584340786773431223496072304382597727768926156417429611089103427290200640921026334 * α ^ 13 * (17 - α) ^ 43 + 374523382812426223233967303671275687297451096894379697013331090967253251615175373801177901144258730 * α ^ 14 * (17 - α) ^ 42 + 3396494550442924093336698525515677714454583693723746546679078674756021148647562726100992633195827670 * α ^ 15 * (17 - α) ^ 41 + 27771451470570936428940278209636484839068297258115446941354573210378654498093153647787388326291195220 * α ^ 16 * (17 - α) ^ 40 + 205336433200531842769564752332775005425876161312494024088869532088213815964669131170023033890476305980 * α ^ 17 * (17 - α) ^ 39 + 1376302917197732669050568166563895672822852883204651206746822345275035657680019417369627527115086850120 * α ^ 18 * (17 - α) ^ 38 + 8380155294397784796024596289754563707905478379672589828457151616147990659832389424273341383748688207080 * α ^ 19 * (17 - α) ^ 37 + 46434805880795731321224499533392807251809590691101718819109701496201837794500680135302573321020690890746 * α ^ 20 * (17 - α) ^ 36 + 234491333325177991679288999498604121924586729800797548175219657080832899570210449706339657838128968884354 * α ^ 21 * (17 - α) ^ 35 + 1080514930086925704280859540483502286254671084929525637672420222697615347555423346347115532203110643365136 * α ^ 22 * (17 - α) ^ 34 + 4547675284413232416488077752788320517949654297288884032643195010720956134703008952100555630475629759787488 * α ^ 23 * (17 - α) ^ 33 + 17496546097098586152071398152312222042613115074033174731514387311101666529876250406780911401607973057493255 * α ^ 24 * (17 - α) ^ 32 + 61573424970057153431741932997114452252230749510452379581517661469288846340022317444210252355996069897749331 * α ^ 25 * (17 - α) ^ 31 + 198297654024175037814903698649403184988215012123240470670091291048259056629782551733808484416396638864067091 * α ^ 26 * (17 - α) ^ 30 + 584610302749161753333489816331275650573703865862791211866486561498961706693997631039254643972613296017180617 * α ^ 27 * (17 - α) ^ 29 + 1578046905956627892814531753544431465414315118110738633436435926556242944082783767807930560452112935615842171 * α ^ 28 * (17 - α) ^ 28 + 3900276267502012608001991748970773203576515687854492513578111746545720357741690474840268134056865690598209279 * α ^ 29 * (17 - α) ^ 27 + 8825565680944180807206852648457428249507576570214954247410910715730515927908602962682166825659628608449565179 * α ^ 30 * (17 - α) ^ 26 + 18278222890683728517844209588507295086668349633646134150369498537778483167121641476779372484086759659269711781 * α ^ 31 * (17 - α) ^ 25 + 34630021303309994264801974849783975057715767549012563612835970835153541351334334084636838049899704411229419039 * α ^ 32 * (17 - α) ^ 24 + 59976325403926759553950096138547851891588162346459693279652757133352417289699475136155912596938565990681022967 * α ^ 33 * (17 - α) ^ 23 + 94859908857514726802312972207926527679144706496572092127703134483420755663937004295941931559564856864612372015 * α ^ 34 * (17 - α) ^ 22 + 136838029261198215465308944618229439296028860400759258689603958243702943063871561985963901374611376885862608933 * α ^ 35 * (17 - α) ^ 21 + 179750481304348065934713749450324777683615725218792657415497203296024872885988657067853702018371602813684069687 * α ^ 36 * (17 - α) ^ 20 + 214614205815431393733148792819846945536633335373334115752048809273342647443432539934607000062616305939408924323 * α ^ 37 * (17 - α) ^ 19 + 232391950882130480511841466255675296149805103394932221634682309682031574184073376765275830067134447105269029319 * α ^ 38 * (17 - α) ^ 18 + 227646786129095617123180754743680811362220841807439017659139374884333921571156246794142321243097055097178445825 * α ^ 39 * (17 - α) ^ 17 + 201151592000254076319111933803082921016858033652344635301102367059012097196101762301692963719714653038174763855 * α ^ 40 * (17 - α) ^ 16 + 159796714515585050308711763046365954383154641733651622252372673160438440025715520354135554841621456682694603135 * α ^ 41 * (17 - α) ^ 15 + 113694441321074008752288203116701595054184371599569875421293420056220499034682316015196771177249973056572181735 * α ^ 42 * (17 - α) ^ 14 + 72130500744694542887028943813151106507208801012210269142093276885199604435222351545247283246975115560376609205 * α ^ 43 * (17 - α) ^ 13 + 40593915959417627531746494374957888051425398581583793505319726935377556193558075899850407121984115730929357755 * α ^ 44 * (17 - α) ^ 12 + 20142112914146928990742750521398817973806574189219001955193033477789707030767693751116805380225357379276747519 * α ^ 45 * (17 - α) ^ 11 + 8746984555426014571216178944742661168209625273320645227018468690933303880145359024731425263277253405247586951 * α ^ 46 * (17 - α) ^ 10 + 3294813943512375946477459661112271578543735031048904613485581394105299356535226701518930871689765592849920009 * α ^ 47 * (17 - α) ^ 9 + 1064633594182767781418524670877965310710625221215403900701843563201440674916875929401734783421144317918768437 * α ^ 48 * (17 - α) ^ 8 + 290979947292633634820286085206318086271058595522743900697255282277868275830483412118913673100403134596829605 * α ^ 49 * (17 - α) ^ 7 + 66053632008286815218730609011172165768275118555864770965140596782012442105314066073321580207922244489207001 * α ^ 50 * (17 - α) ^ 6 + 12152795314691969352387359587094653935442718022653966020106284283370382118838609048927994949757671991794739 * α ^ 51 * (17 - α) ^ 5 + 1751156608268941082844684121012320147103407396012602177215161083358650243742317419805210038235339659097451 * α ^ 52 * (17 - α) ^ 4 + 187813139479594914512845605964389800598941841721249536400462885091353372097871422654926648798226033258823 * α ^ 53 * (17 - α) ^ 3 + 13802072582465965788484953766306541577986163631972344323322049452623866943671442557170586787638780254425 * α ^ 54 * (17 - α) ^ 2 + 594982734136165220266045344041112246141469375919551772765097596644107694713723809345475527250815129375 * α ^ 55 * (17 - α) ^ 1 + 10211558413705494402424769335540267701249567140173495481288972120637089282914579657148619242232312500 * α ^ 56 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 58 ≤ n) (h1 : n ≤ 60) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (60 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (60 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 58) (n := n) (n₁ := 60) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((58 : ℕ) : ℝ) - 4 = 54 by norm_num] at hb - rw [show (54 : ℝ) / 2 = ((27 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 57) + 1 / (4 * 57 * (3 + α)) + (1 - 2 * α / 59) ^ 2 * 60 * 59 * (60 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 57 * (3 + α)) ^ 27)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 58 ≤ n) (h1 : n ≤ 60) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 58) (n₁ := 60) (k := 27) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B58_60 diff --git a/Sendov/FiniteRange/Degree60_63.lean b/Sendov/FiniteRange/Degree60_63.lean index 50fbb1e..3f97a9d 100644 --- a/Sendov/FiniteRange/Degree60_63.lean +++ b/Sendov/FiniteRange/Degree60_63.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 60 to 63 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 60) (gg1 60) (gg2 60) 28)) α := by - refine pev_wsum_eq_of_packed (gg0 60) (gg1 60) (gg2 60) 28 85 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 60) (gg1 60) (gg2 60) 28 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 60) (gg1 60) (gg2 60) 28 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 60) (gg1 60) (gg2 60) 3 (by simp) (by simp) (by simp) 28) - · rfl + refine pev_moment_eq_of_packed_bounds 60 28 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 60 α t ^ 28) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 + 16985863033574280235844441932687847244474918343296922124467065830558560591641911607696 * α + 79535686565443616767714198705465441607069525916537281975943363396026310601750092892488 * α ^ 2 + 239403368066863055363036191982445140250970254028533507257869611464498452359820776516672 * α ^ 3 + 520412199687668549649368000742289832307395871986227854434049639793742028919048260538980 * α ^ 4 + 870157990458303443210342456693112304974391575125591793142671535717764222680483811054120 * α ^ 5 + 1163895406905166893909394336483096101920864956907539643884037297958617393209091960980980 * α ^ 6 + 1278712702347990314588936279615328559669420142052152673561809586945926657118282053100192 * α ^ 7 + 1175725999507118690334304481188590417967828338375807066246239349405176693210977652965164 * α ^ 8 + 917174565683194380325199349414315003531063568224297761645149376513377860921193466166360 * α ^ 9 + 613220450431269534465945368150179786921282701580434508261534043083701875736956664994572 * α ^ 10 + 354057578771667900301737961009087756507978666072508030411200442531544505558679233553472 * α ^ 11 + 177508212962690728847102755764000185519630950904902948797136565592445320434555097902358 * α ^ 12 + 77576143881435246639915934911657056385846898645191797585491387399418570120013455336412 * α ^ 13 + 29625606539961534087112448697426117322036816304400291238815402402574337305159894234710 * α ^ 14 + 9897983624006015895072166102753315050019559506815047218656308374776682178809801281072 * α ^ 15 + 2893024329186264383797233494270141942147451227576867206489337752203105179024976096612 * α ^ 16 + 738824037484601173560395482737511489082491085984005275312812825534063503137534438984 * α ^ 17 + 164441392895370259121202826289551958180582089330511860705087484253672173523954414324 * α ^ 18 + 31771089808007468337610992777240040391387210585565359776690610466850812101226150720 * α ^ 19 + 5298220195377128677201324507710581490774005592592493587530562214239637638718207838 * α ^ 20 + 756659597417575188091510844865331006747834890107597233256807850344151631080238572 * α ^ 21 + 91559608573015197712368058376578410389957871248555658418907655613710858144349974 * α ^ 22 + 9249930419338172598175237698997019936144549918443437721165100485815394918388112 * α ^ 23 + 763883913294738134810454963300633389711111356082193955572628106712061571529450 * α ^ 24 + 49887514803037691118937977551057551319824185688173200456490865107511572859188 * α ^ 25 + 2408300944763273858718491162262422770972533056902127038712768748993172577610 * α ^ 26 + 51725078185114864055621675260185352972397611437758098966549358454837797760 * α ^ 27 - 77510592929500392468407361123374953300216693743671418464304395453235289971 * α ^ 28 + 2067570494221092433188386134604931347621528152582381523034724429480663810 * α ^ 29 - 4580593295775337280722829599699027320935759304984497739306397718132427 * α ^ 30 + 167416972491317272532611766388094644865407567559322236979252017800 * α ^ 31 + 8389683035480047874686298369093744577278032988658533654716580671488 * α ^ 32 + 533168330392361738160636316662426153463437758146484284733956527840 * α ^ 33 + 20133734272551384350294239387428682262688585273913890267463998960 * α ^ 34 + 493961052258347053233401169722862536905607351132290352999275776 * α ^ 35 + 5693741143796291743936421907647419400331769333817148390864384 * α ^ 36 - 136838149185369327185106181434226275722488605188850651649536 * α ^ 37 - 10213381894013887312358741093692449757528996456249043806464 * α ^ 38 - 350916645279993747972377869550082945451923877049098721280 * α ^ 39 - 8752703600310726164117509854956335599020724135444320256 * α ^ 40 - 174795107690037567064791487247091959281487206843686912 * α ^ 41 - 2905560404482515211390475250648416164278477823340544 * α ^ 42 - 40986185232466565782519730515559353841538308898816 * α ^ 43 - 495823850271711791881581412818585367225361694720 * α ^ 44 - 5173168623120670073594814754124350179396943872 * α ^ 45 - 46665067131765629087874046716431817185624064 * α ^ 46 - 363947916336732295692730495412120808062976 * α ^ 47 - 2448922340507063244670480160751278358528 * α ^ 48 - 14156403192874033788431089246006149120 * α ^ 49 - 69840635580766128998624519726825472 * α ^ 50 - 291304208587694376741876403273728 * α ^ 51 - 1013847100270960749479253245952 * α ^ 52 - 2890985222950997734006456320 * α ^ 53 - 6580251459272551201505280 * α ^ 54 - 11498869995682148646912 * α ^ 55 - 14487778418579472384 * α ^ 56 - 11716883921240064 * α ^ 57 - 4568503025664 * α ^ 58 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 58 * (1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 + 16985863033574280235844441932687847244474918343296922124467065830558560591641911607696 * α + 79535686565443616767714198705465441607069525916537281975943363396026310601750092892488 * α ^ 2 + 239403368066863055363036191982445140250970254028533507257869611464498452359820776516672 * α ^ 3 + 520412199687668549649368000742289832307395871986227854434049639793742028919048260538980 * α ^ 4 + 870157990458303443210342456693112304974391575125591793142671535717764222680483811054120 * α ^ 5 + 1163895406905166893909394336483096101920864956907539643884037297958617393209091960980980 * α ^ 6 + 1278712702347990314588936279615328559669420142052152673561809586945926657118282053100192 * α ^ 7 + 1175725999507118690334304481188590417967828338375807066246239349405176693210977652965164 * α ^ 8 + 917174565683194380325199349414315003531063568224297761645149376513377860921193466166360 * α ^ 9 + 613220450431269534465945368150179786921282701580434508261534043083701875736956664994572 * α ^ 10 + 354057578771667900301737961009087756507978666072508030411200442531544505558679233553472 * α ^ 11 + 177508212962690728847102755764000185519630950904902948797136565592445320434555097902358 * α ^ 12 + 77576143881435246639915934911657056385846898645191797585491387399418570120013455336412 * α ^ 13 + 29625606539961534087112448697426117322036816304400291238815402402574337305159894234710 * α ^ 14 + 9897983624006015895072166102753315050019559506815047218656308374776682178809801281072 * α ^ 15 + 2893024329186264383797233494270141942147451227576867206489337752203105179024976096612 * α ^ 16 + 738824037484601173560395482737511489082491085984005275312812825534063503137534438984 * α ^ 17 + 164441392895370259121202826289551958180582089330511860705087484253672173523954414324 * α ^ 18 + 31771089808007468337610992777240040391387210585565359776690610466850812101226150720 * α ^ 19 + 5298220195377128677201324507710581490774005592592493587530562214239637638718207838 * α ^ 20 + 756659597417575188091510844865331006747834890107597233256807850344151631080238572 * α ^ 21 + 91559608573015197712368058376578410389957871248555658418907655613710858144349974 * α ^ 22 + 9249930419338172598175237698997019936144549918443437721165100485815394918388112 * α ^ 23 + 763883913294738134810454963300633389711111356082193955572628106712061571529450 * α ^ 24 + 49887514803037691118937977551057551319824185688173200456490865107511572859188 * α ^ 25 + 2408300944763273858718491162262422770972533056902127038712768748993172577610 * α ^ 26 + 51725078185114864055621675260185352972397611437758098966549358454837797760 * α ^ 27 - 77510592929500392468407361123374953300216693743671418464304395453235289971 * α ^ 28 + 2067570494221092433188386134604931347621528152582381523034724429480663810 * α ^ 29 - 4580593295775337280722829599699027320935759304984497739306397718132427 * α ^ 30 + 167416972491317272532611766388094644865407567559322236979252017800 * α ^ 31 + 8389683035480047874686298369093744577278032988658533654716580671488 * α ^ 32 + 533168330392361738160636316662426153463437758146484284733956527840 * α ^ 33 + 20133734272551384350294239387428682262688585273913890267463998960 * α ^ 34 + 493961052258347053233401169722862536905607351132290352999275776 * α ^ 35 + 5693741143796291743936421907647419400331769333817148390864384 * α ^ 36 - 136838149185369327185106181434226275722488605188850651649536 * α ^ 37 - 10213381894013887312358741093692449757528996456249043806464 * α ^ 38 - 350916645279993747972377869550082945451923877049098721280 * α ^ 39 - 8752703600310726164117509854956335599020724135444320256 * α ^ 40 - 174795107690037567064791487247091959281487206843686912 * α ^ 41 - 2905560404482515211390475250648416164278477823340544 * α ^ 42 - 40986185232466565782519730515559353841538308898816 * α ^ 43 - 495823850271711791881581412818585367225361694720 * α ^ 44 - 5173168623120670073594814754124350179396943872 * α ^ 45 - 46665067131765629087874046716431817185624064 * α ^ 46 - 363947916336732295692730495412120808062976 * α ^ 47 - 2448922340507063244670480160751278358528 * α ^ 48 - 14156403192874033788431089246006149120 * α ^ 49 - 69840635580766128998624519726825472 * α ^ 50 - 291304208587694376741876403273728 * α ^ 51 - 1013847100270960749479253245952 * α ^ 52 - 2890985222950997734006456320 * α ^ 53 - 6580251459272551201505280 * α ^ 54 - 11498869995682148646912 * α ^ 55 - 14487778418579472384 * α ^ 56 - 11716883921240064 * α ^ 57 - 4568503025664 * α ^ 58) = 1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 * (17 - α) ^ 58 + 390326433597525193146123071698409867301520390117218290267746409833092718425696728651808 * α ^ 1 * (17 - α) ^ 57 + 42339767414709412024800543085671455832484522045547354532982698096600368845688639786434272 * α ^ 2 * (17 - α) ^ 56 + 2978288251912812668426975142881017511384301236011339350466382171100719277406612535201202432 * α ^ 3 * (17 - α) ^ 55 + 152745949949503787162875767681479712010274958086345519055757721242134449740576558561672466100 * α ^ 4 * (17 - α) ^ 54 + 6088522642574857806357024467621421962247301068049055791879352484148857589737344570006424306432 * α ^ 5 * (17 - α) ^ 53 + 196353730172495768212131228592895964623220340501637536200602452342681588928305193631061786495128 * α ^ 6 * (17 - α) ^ 52 + 5266157866495799387947512134510522910378331486905487931902457256370064452591463479230852331820688 * α ^ 7 * (17 - α) ^ 51 + 119820143547425060414405575247909992318712489020361652433663435983410928998020585429365087295873272 * α ^ 8 * (17 - α) ^ 50 + 2347881458090802952975815753665509878263409227272937917396103015417709833460343242062605055065007520 * α ^ 9 * (17 - α) ^ 49 + 40087439558071587468650026480818375755059891510076862445505823029454511957690006955557287865611736368 * α ^ 10 * (17 - α) ^ 48 + 601952482871233638447257366201476457757370789071367246820395949483198507616680072154695375018993206080 * α ^ 11 * (17 - α) ^ 47 + 8009470199896280650115766696812280446758293363345211706745554624342950667301865303395190896548719848894 * α ^ 12 * (17 - α) ^ 46 + 95019362618823693655434560324233095572340322211181765633801354884655907381821543655651592610813813891216 * α ^ 13 * (17 - α) ^ 45 + 1010201707551433403309553561274371166022594138303310301376573778032472462922417174557444934419810264510660 * α ^ 14 * (17 - α) ^ 44 + 9666021740205241072831491648575295854988543778205392913804696971472866176266073951546563512467374588927208 * α ^ 15 * (17 - α) ^ 43 + 83539422247937309919557615020970488939815680020028362327882719748972398761527927690277222254506587818510230 * α ^ 16 * (17 - α) ^ 42 + 654118420001028745738306390006036203398367424921715171378029833094091806885053261792691008623047458390979656 * α ^ 17 * (17 - α) ^ 41 + 4652186358394523426651350117431277481053696460019422776379929513303869171324522998809216735658736365543149056 * α ^ 18 * (17 - α) ^ 40 + 30118791616775324911184234952445703914857411555877912743140868805910755261334373116907433215385078679006707440 * α ^ 19 * (17 - α) ^ 39 + 177826427793428069222664936517971981732084250622079798759954938089906960407318562179543208670385720641305484484 * α ^ 20 * (17 - α) ^ 38 + 958974728072861489890512212348583321104118795534766915893103879494275523886658791163551854756652905815510994528 * α ^ 21 * (17 - α) ^ 37 + 4729723071531116796957485128322656283636236954549201452338482026970860715184248091976900742259324658054589766592 * α ^ 22 * (17 - α) ^ 36 + 21357626391876046213696677013115319309126810433424794269849513349981113078786111769550369530995181611742183411536 * α ^ 23 * (17 - α) ^ 35 + 88378492075701468992449068981435994543226968075794931456837379496731600212606957395063382063437679158720468757170 * α ^ 24 * (17 - α) ^ 34 + 335374317924993519374894630236901278966604414721735688724835686564184905864027923099074702766636244586098764495656 * α ^ 25 * (17 - α) ^ 33 + 1167747403010750979143600445942797877583165267655942642217360148980523954073844543734436948340308328790173989450240 * α ^ 26 * (17 - α) ^ 32 + 3732406493950907275441950492949127432338499662676613602897135646128454363022292331302101040551201738067461761785664 * α ^ 27 * (17 - α) ^ 31 + 10954129200438058193458578123785740490187961119866684050714899067863611709664062247915680616127050262599212424644897 * α ^ 28 * (17 - α) ^ 30 + 29524937330321420901887693835267567366420221233340924484096603443964250287652843237880043795863468001106755829620680 * α ^ 29 * (17 - α) ^ 29 + 73087125140139025535278935287700443682500254736472038981634113551624541486231287807821582020794101152220739006249054 * α ^ 30 * (17 - α) ^ 28 + 166147644042440368311067169194067229624014747885167057075915274327610140356799603915688925405707986646551735878107548 * α ^ 31 * (17 - α) ^ 27 + 346772843057251234464569444053204287523460387723124946687308651228411784130792835892965479313436122483094189414638435 * α ^ 32 * (17 - α) ^ 26 + 664225955992969098770607024010663586597562367955519444707479326460670050391696600135144018377249349272512491633374996 * α ^ 33 * (17 - α) ^ 25 + 1166927452705629997542488080350699352093937922567202455194634401101839128946832909551419826543265369338614818217043960 * α ^ 34 * (17 - α) ^ 24 + 1878756607833380897964887521267252840224951551991841799719666838851961513969673042361037791640974884809523420884857896 * α ^ 35 * (17 - α) ^ 23 + 2769054221066722167360357163072398302792888941316285917570542419942819549648264402600819292556739224578295584544111593 * α ^ 36 * (17 - α) ^ 22 + 3731200624302652450167208268451073697815114712494349214865173019453170935880402861700349003895204451567678626785884944 * α ^ 37 * (17 - α) ^ 21 + 4589060320062131760404941760267700835789214136011164185047467243912104258380281276437542650223991907463154227654480250 * α ^ 38 * (17 - α) ^ 20 + 5142005613111678624089090068072653156514352316794579159234104771289794844001366200904371725907143894777202797701901140 * α ^ 39 * (17 - α) ^ 19 + 5237411173258795881045797059007984704429066340121408567111553635714834497251049352739808449923037569813646734054022299 * α ^ 40 * (17 - α) ^ 18 + 4836963127294992600059755436214556792844531244095433636867849886599932076358086832823383902964112824599524794814907660 * α ^ 41 * (17 - α) ^ 17 + 4038642993383808502646993082987941730662364203715934601149860715099116021657255631782766462484195430978656049244711644 * α ^ 42 * (17 - α) ^ 16 + 3038452569137952848001398255617645415509309374884449236698224469982642958671749123930862050454967951657624568575856688 * α ^ 43 * (17 - α) ^ 15 + 2051868663368925893596995729015571533363774183714583901584727359036447948070300988236179249392897564162618659414308125 * α ^ 44 * (17 - α) ^ 14 + 1238175994140035374637906473341260146948966827890334540274993830863642501653683339638928725989225430525272809854519160 * α ^ 45 * (17 - α) ^ 13 + 664157193310869042816823748632341892142095205218119162176744496952019558037232907168597445007823380125777368765119662 * α ^ 46 * (17 - α) ^ 12 + 314709886085135861297147136857650883344977185951101514937597344260222119762475730654304761445438390089176776231442524 * α ^ 47 * (17 - α) ^ 11 + 130752300650671071539193189087470650687679774298245936504525933790335489689909687270813505169056399644554354547239027 * α ^ 48 * (17 - α) ^ 10 + 47197367207696915154864396118931631129224589120774745992092456851672119895365941889175184835650784414267376300303620 * α ^ 49 * (17 - α) ^ 9 + 14634551667218002061058569723384799807420346162568828832552477052180173516934500629665142381604576011817456177436512 * α ^ 50 * (17 - α) ^ 8 + 3842020781478673446935098659029021030741590331823487291470293090299720569242182142621667182316185787786272194127544 * α ^ 51 * (17 - α) ^ 7 + 838031670173391441198956875841265626545050410662677811959134541401400325959689376985919100766189972881282787577763 * α ^ 52 * (17 - α) ^ 6 + 148041122984446508528033501826038847912820726117568892710474612036947233357823264896703744164136565988458171335488 * α ^ 53 * (17 - α) ^ 5 + 20425027753973244256487010270626798809629979580987772972987591577599400419675783451565774908699336057777964446110 * α ^ 54 * (17 - α) ^ 4 + 2082801294909426227172103997302542506576066130763213820723347100167035816595437754294159646550971592826080127596 * α ^ 55 * (17 - α) ^ 3 + 143053115347005574042966026900851192531277156875872861510463214959748868032658829240606333338274956129514869223 * α ^ 56 * (17 - α) ^ 2 + 5492607925836276782575645752168619846129179160632349319557999016078091770978332301317881391624780373381782060 * α ^ 57 * (17 - α) ^ 1 + 68316788541465931995562079450677157534774523435506193215243865134760205880356610515710383859614369923388540 * α ^ 58 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 60 ≤ n) (h1 : n ≤ 63) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (63 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (63 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 60) (n := n) (n₁ := 63) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((60 : ℕ) : ℝ) - 4 = 56 by norm_num] at hb - rw [show (56 : ℝ) / 2 = ((28 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 59) + 1 / (4 * 59 * (3 + α)) + (1 - 2 * α / 62) ^ 2 * 63 * 62 * (63 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 59 * (3 + α)) ^ 28)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 60 ≤ n) (h1 : n ≤ 63) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 60) (n₁ := 63) (k := 28) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B60_63 diff --git a/Sendov/FiniteRange/Degree64_69.lean b/Sendov/FiniteRange/Degree64_69.lean index 1dbcc86..ec85162 100644 --- a/Sendov/FiniteRange/Degree64_69.lean +++ b/Sendov/FiniteRange/Degree64_69.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 64 to 69 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 64) (gg1 64) (gg2 64) 30)) α := by - refine pev_wsum_eq_of_packed (gg0 64) (gg1 64) (gg2 64) 30 91 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 64) (gg1 64) (gg2 64) 30 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 64) (gg1 64) (gg2 64) 30 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 64) (gg1 64) (gg2 64) 3 (by simp) (by simp) (by simp) 30) - · rfl + refine pev_moment_eq_of_packed_bounds 64 30 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 64 α t ^ 30) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 + 61381176382803809362111499051840544591370805103230496041366966719316985769735186577074210428 * α + 307875927191106748261011216414410411442655519490352054541897661765849218694794523337461209647 * α ^ 2 + 995139520442941110972922094595461359252165093278183682740950849972307343163433414772266439134 * α ^ 3 + 2329135965026413320254515390788191269701711986947806984107173389521959680472053301869564187977 * α ^ 4 + 4205152400427897818943955614854872603184778207497298031576474014041708453522600564012661712908 * α ^ 5 + 6092227728539116602774802993811227514150357030998079498007336022099744281828374410394763218967 * α ^ 6 + 7273914911154976681674028920562209810638892503140251984517953529760649706898772999266377410618 * α ^ 7 + 7294841936549908246762850463172756077551550164308271524011607481986853316219925718877268241253 * α ^ 8 + 6231636865479569934304365225476315224178754021865462499626075023963516933948459908031199504392 * α ^ 9 + 4582454355475931479184872096047779444629884546826401854025935798959693699768306789254756052107 * α ^ 10 + 2923936751602144899711097457334391073444202579871680510494335159924208835914470439635141162662 * α ^ 11 + 1628646305582237968027987059869036927850582412822128278929774316093217652148166106137543210729 * α ^ 12 + 795445013477937519140644933077682364729772242866058887702125127747950219835128702530435684436 * α ^ 13 + 341732386485246488082914550033328759932103344872452353652503157863279852435899383534716977739 * α ^ 14 + 129398024588904114703104106088147845845858920384624466782691337832071760366611282163240673066 * α ^ 15 + 43227083179690319937679095035602516318669269367605716008461368393810348604333859857847549497 * α ^ 16 + 12739734973954297734917244488839138405165723257781387930800239709000470619130237106664340656 * α ^ 17 + 3309003690560409027996242316235318569343087760556101911245828294749346009825368969657069031 * α ^ 18 + 755904091146328721648601114370911122594719522671458365690647375941659996310302273197058470 * α ^ 19 + 151378877572074703874732245694134372432105936678872727794384094115460812902730719423948317 * α ^ 20 + 26454923472459858634887234579799069438230123457614797089205636430511024677434784809220924 * α ^ 21 + 4009557348845189672922466111254379827931543987777056770742617262249980072703900044793759 * α ^ 22 + 522684797686516768766815870526767734538930901093141236380109988654434790535464480525226 * α ^ 23 + 57960196328928756537267261570029521956658673559059668642752896597993471772708261591453 * α ^ 24 + 5385398873189231308982589874195610465961820936268053590519181757629535422805253399024 * α ^ 25 + 410397478215636804806491132412571076795910317178146076050633000481647199256305822637 * α ^ 26 + 24812014519928905914570908638577043729393183935810050156873373621420956394826529722 * α ^ 27 + 1113510388782381458493062026644349844210314014993864209186922164992790354371374639 * α ^ 28 + 22409773065959463084902151065290205378008886892907135598840606673031087144995204 * α ^ 29 - 35763698158235183891226289780431937498580930947719484832564827737501564744289629 * α ^ 30 + 840760995622979288098811692316543958334461895228266842721825922823541893315826 * α ^ 31 - 2476024715094217195652794819915917218077074423531979390443969076889551332351 * α ^ 32 - 42343131706354479044867362267674031525737275327352243122650061208773859828 * α ^ 33 + 1121663574053726688315155444107301037632747178037371530068223719748652900 * α ^ 34 + 127119237016866360421264159870103175079883989461074891879168221493189568 * α ^ 35 + 5840998162333194724309799734276135965778520891167491660434664446065776 * α ^ 36 + 175992443424517154194105688439948495022759467456834921814514733630912 * α ^ 37 + 3457340410083421419722141826010375932802380080806011689658236008128 * α ^ 38 + 24387290416155856471527726331603437910487483092148051628143522304 * α ^ 39 - 1239885867289330313685948822187720768399781886302021720494414080 * α ^ 40 - 65142911505809786191440265839050522466645141325685819456216064 * α ^ 41 - 1919845972367683574507152058644769097612240398422850416591872 * α ^ 42 - 42690755951658679674359660598349223111852496540029559373824 * α ^ 43 - 774277941425789906408100254236527798872560249769923817472 * α ^ 44 - 11837447748695307877084872298248109006399402655405555712 * α ^ 45 - 155160542836944884945355229969272241433459624584396800 * α ^ 46 - 1760282021481048069096957321992926156742736627499008 * α ^ 47 - 17375591117616735181132725973057892264379050557440 * α ^ 48 - 149596040045196039764745879558857285877770747904 * α ^ 49 - 1123758519054636222507004226738421820190097408 * α ^ 50 - 7354587732063594511120345756955829080162304 * α ^ 51 - 41799839163275444256118641007392250134528 * α ^ 52 - 205261854328197847356177208926730715136 * α ^ 53 - 864576623781254196788511741560487936 * α ^ 54 - 3092645524632136056284929849294848 * α ^ 55 - 9268224902397535157105681498112 * α ^ 56 - 22840148173664707695687499776 * α ^ 57 - 45078822391172061959553024 * α ^ 58 - 68515609003558969540608 * α ^ 59 - 75294374818201206784 * α ^ 60 - 53251155240681472 * α ^ 61 - 18200997658624 * α ^ 62 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 62 * (5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 + 61381176382803809362111499051840544591370805103230496041366966719316985769735186577074210428 * α + 307875927191106748261011216414410411442655519490352054541897661765849218694794523337461209647 * α ^ 2 + 995139520442941110972922094595461359252165093278183682740950849972307343163433414772266439134 * α ^ 3 + 2329135965026413320254515390788191269701711986947806984107173389521959680472053301869564187977 * α ^ 4 + 4205152400427897818943955614854872603184778207497298031576474014041708453522600564012661712908 * α ^ 5 + 6092227728539116602774802993811227514150357030998079498007336022099744281828374410394763218967 * α ^ 6 + 7273914911154976681674028920562209810638892503140251984517953529760649706898772999266377410618 * α ^ 7 + 7294841936549908246762850463172756077551550164308271524011607481986853316219925718877268241253 * α ^ 8 + 6231636865479569934304365225476315224178754021865462499626075023963516933948459908031199504392 * α ^ 9 + 4582454355475931479184872096047779444629884546826401854025935798959693699768306789254756052107 * α ^ 10 + 2923936751602144899711097457334391073444202579871680510494335159924208835914470439635141162662 * α ^ 11 + 1628646305582237968027987059869036927850582412822128278929774316093217652148166106137543210729 * α ^ 12 + 795445013477937519140644933077682364729772242866058887702125127747950219835128702530435684436 * α ^ 13 + 341732386485246488082914550033328759932103344872452353652503157863279852435899383534716977739 * α ^ 14 + 129398024588904114703104106088147845845858920384624466782691337832071760366611282163240673066 * α ^ 15 + 43227083179690319937679095035602516318669269367605716008461368393810348604333859857847549497 * α ^ 16 + 12739734973954297734917244488839138405165723257781387930800239709000470619130237106664340656 * α ^ 17 + 3309003690560409027996242316235318569343087760556101911245828294749346009825368969657069031 * α ^ 18 + 755904091146328721648601114370911122594719522671458365690647375941659996310302273197058470 * α ^ 19 + 151378877572074703874732245694134372432105936678872727794384094115460812902730719423948317 * α ^ 20 + 26454923472459858634887234579799069438230123457614797089205636430511024677434784809220924 * α ^ 21 + 4009557348845189672922466111254379827931543987777056770742617262249980072703900044793759 * α ^ 22 + 522684797686516768766815870526767734538930901093141236380109988654434790535464480525226 * α ^ 23 + 57960196328928756537267261570029521956658673559059668642752896597993471772708261591453 * α ^ 24 + 5385398873189231308982589874195610465961820936268053590519181757629535422805253399024 * α ^ 25 + 410397478215636804806491132412571076795910317178146076050633000481647199256305822637 * α ^ 26 + 24812014519928905914570908638577043729393183935810050156873373621420956394826529722 * α ^ 27 + 1113510388782381458493062026644349844210314014993864209186922164992790354371374639 * α ^ 28 + 22409773065959463084902151065290205378008886892907135598840606673031087144995204 * α ^ 29 - 35763698158235183891226289780431937498580930947719484832564827737501564744289629 * α ^ 30 + 840760995622979288098811692316543958334461895228266842721825922823541893315826 * α ^ 31 - 2476024715094217195652794819915917218077074423531979390443969076889551332351 * α ^ 32 - 42343131706354479044867362267674031525737275327352243122650061208773859828 * α ^ 33 + 1121663574053726688315155444107301037632747178037371530068223719748652900 * α ^ 34 + 127119237016866360421264159870103175079883989461074891879168221493189568 * α ^ 35 + 5840998162333194724309799734276135965778520891167491660434664446065776 * α ^ 36 + 175992443424517154194105688439948495022759467456834921814514733630912 * α ^ 37 + 3457340410083421419722141826010375932802380080806011689658236008128 * α ^ 38 + 24387290416155856471527726331603437910487483092148051628143522304 * α ^ 39 - 1239885867289330313685948822187720768399781886302021720494414080 * α ^ 40 - 65142911505809786191440265839050522466645141325685819456216064 * α ^ 41 - 1919845972367683574507152058644769097612240398422850416591872 * α ^ 42 - 42690755951658679674359660598349223111852496540029559373824 * α ^ 43 - 774277941425789906408100254236527798872560249769923817472 * α ^ 44 - 11837447748695307877084872298248109006399402655405555712 * α ^ 45 - 155160542836944884945355229969272241433459624584396800 * α ^ 46 - 1760282021481048069096957321992926156742736627499008 * α ^ 47 - 17375591117616735181132725973057892264379050557440 * α ^ 48 - 149596040045196039764745879558857285877770747904 * α ^ 49 - 1123758519054636222507004226738421820190097408 * α ^ 50 - 7354587732063594511120345756955829080162304 * α ^ 51 - 41799839163275444256118641007392250134528 * α ^ 52 - 205261854328197847356177208926730715136 * α ^ 53 - 864576623781254196788511741560487936 * α ^ 54 - 3092645524632136056284929849294848 * α ^ 55 - 9268224902397535157105681498112 * α ^ 56 - 22840148173664707695687499776 * α ^ 57 - 45078822391172061959553024 * α ^ 58 - 68515609003558969540608 * α ^ 59 - 75294374818201206784 * α ^ 60 - 53251155240681472 * α ^ 61 - 18200997658624 * α ^ 62) = 5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 * (17 - α) ^ 62 + 1410592329453155093339211289542411736609735429121847896493629858906716014852004156892167552548 * α ^ 1 * (17 - α) ^ 61 + 163825348961034855748532998133187489244150138166953116803112907190951119777389438269950378047615 * α ^ 2 * (17 - α) ^ 60 + 12361195960575736306163012120329422246578502920843748763821862084625502483053715706760463722075322 * α ^ 3 * (17 - α) ^ 59 + 681335583687244816837155518706910028522515498128290805387946937709694218848663276792277722205885165 * α ^ 4 * (17 - α) ^ 58 + 29246467299582416554371726277124312659485967608331036186864901441962932711378452493174003728374440456 * α ^ 5 * (17 - α) ^ 57 + 1017843449098855324693227940286198056557561324301642345041220834540478580971172148752686938326750596235 * α ^ 6 * (17 - α) ^ 56 + 29523351481445963795800452678069515843407715524336444192954336309944099949871809204575864476533589605302 * α ^ 7 * (17 - α) ^ 55 + 728152422115299748757980286386613270210125867312784076185146979717429960990761502520944266554529234032105 * α ^ 8 * (17 - α) ^ 54 + 15503254854319433781737681560944871435301212863859242862611647178701987248949779238980829394743551131411876 * α ^ 9 * (17 - α) ^ 53 + 288328427720996697724483216206576565555295259358381796122313701494259650958770973285158322571941967268217143 * α ^ 10 * (17 - α) ^ 52 + 4728226481516661217868239930012852768555767163427788258399165321871029858334868657036824174585537128584095058 * α ^ 11 * (17 - α) ^ 51 + 68892078096367493868938707195995003059858819884647635693839050805569143627035213407543911684688112707333940917 * α ^ 12 * (17 - α) ^ 50 + 897489256219895957725717014821990251236531986784876454449072801996710996644666496224561803033929426140365957072 * α ^ 13 * (17 - α) ^ 49 + 10508734440253299052373528881880146721004546284790249412377062790386529187304727179044043353704708859442299500759 * α ^ 14 * (17 - α) ^ 48 + 111081473282973163902827719026653126099023149223026091072328009130583311867466584644887598351195354843454575061078 * α ^ 15 * (17 - α) ^ 47 + 1063941006387245192155551249879696393695003441753984944370011723535983307131499226741597118204956342316757068738269 * α ^ 16 * (17 - α) ^ 46 + 9262986013458072655807408147636790265923148648024710835072780996730402742732552216518640508409071199773338460467580 * α ^ 17 * (17 - α) ^ 45 + 73504432944628644806132381782654602892005780151536635377604343542798349874150577323370221243526662142861029485765267 * α ^ 18 * (17 - α) ^ 44 + 532852613339223838375512331827090700606511743950503229897754718887488029896868379807709267119939501223065295366693602 * α ^ 19 * (17 - α) ^ 43 + 3535814546782694307375152520118433313583952495849109269521484647041374707696487816679620238442969871612220462861303513 * α ^ 20 * (17 - α) ^ 42 + 21512685649336335238232172882299955129752294290179941353113200512198826289055015641521741143998370572855870359074246104 * α ^ 21 * (17 - α) ^ 41 + 120184751154982212109537129094706701776062091437923605319229141083097993817265572578568789467586467189277588039631049315 * α ^ 22 * (17 - α) ^ 40 + 617286849338083584591749927075053814330691243681016327221117622061037920401281200900095661642210214781389352540371769782 * α ^ 23 * (17 - α) ^ 39 + 2917821849269728689002023193436139836170048452644874266623784725971608066582467147212148057605900165316289226284189316377 * α ^ 24 * (17 - α) ^ 38 + 12704073587524590432537550601733909995628450893588885496540802041053069795718152620703039939205080151846264466052385716508 * α ^ 25 * (17 - α) ^ 37 + 50986252288170844090494680336411030634809274601549641047867345938670169429122180568151839986046629584836753070752554325549 * α ^ 26 * (17 - α) ^ 36 + 188731245384436542993876553440655528970657000032064943068315442235001403174655449380246936385673578684853218729590355262518 * α ^ 27 * (17 - α) ^ 35 + 644638862330020323974120509999798597971327969663585928073571369717884850872334505415491868174223509023103931648896623159239 * α ^ 28 * (17 - α) ^ 34 + 2032465294997125297900965524691015077382636066034389731503867693576128697782554799572131661348538947203921438149968717062968 * α ^ 29 * (17 - α) ^ 33 + 5916563574791151204959096743639378777667289023700421621098488569051297390955699005328526305783519890090961210344520200855839 * α ^ 30 * (17 - α) ^ 32 + 15904395842739942400691632117874198526447327814312513603909114134462651263485542388901837738413027124647322988507344907172326 * α ^ 31 * (17 - α) ^ 31 + 39480621688975930462788359812689019736710921053310451812820878220682147479485730376139224433028788139612764026510819938357313 * α ^ 32 * (17 - α) ^ 30 + 90498905447243483519998876972476498394113495417286506436759680590889186513026023767081117347518009234654646481535950533463192 * α ^ 33 * (17 - α) ^ 29 + 191523061794373512741555851851454724489150681013895009425168301404571522764467282969120404401773322532157478133115443560285302 * α ^ 34 * (17 - α) ^ 28 + 374102432352617119867752270588761366904228295175272818014486180253881707053636572216880029501969121629062410575837741541045540 * α ^ 35 * (17 - α) ^ 27 + 674163867855629078514194069974085158409299328199490452497247676315473162081360642182363547674290072742445351524110985068872354 * α ^ 36 * (17 - α) ^ 26 + 1120190445035094331280254183489294295074052698129528674820873994885643430165035917680757332898500267079209483615084452103804008 * α ^ 37 * (17 - α) ^ 25 + 1714900723005197968608097741871663993547860800425642883240541486610428452579319183757683479188744534283136109042046984240571814 * α ^ 38 * (17 - α) ^ 24 + 2416521455885624032995813409015090294329753742015754392681809119734841244318096451186191210367408907919148396327456308763254204 * α ^ 39 * (17 - α) ^ 23 + 3130667990811173505654112986656672677984543765718045066563298172181269932987292074370043542684045671485290799340932412432127666 * α ^ 40 * (17 - α) ^ 22 + 3723632079113581550914531608562041601402119257773277980450525464260286884296416621721582409231033706311054972465336219853088080 * α ^ 41 * (17 - α) ^ 21 + 4059377708897210330188497275486334922259944254887440167982165880025056118561927845076658189142750307922329495731330184747118638 * α ^ 42 * (17 - α) ^ 20 + 4048339098511651153484403478604219407237868497167064020335159037949103178704020226621821552775015074419425081166608975426397828 * α ^ 43 * (17 - α) ^ 19 + 3685125185916007961192554820161330975941990328916335627053257624724395938552675772827896673200200979526558921356874703197634202 * α ^ 44 * (17 - α) ^ 18 + 3054048224733814016209061368888708478509554580679361743439116448337817549920283187451853860165586457447146488334169873043392888 * α ^ 45 * (17 - α) ^ 17 + 2297607116406960807358259781678168246891645615834759456321137666589029442664420364955901391909484370982081566881227744010874086 * α ^ 46 * (17 - α) ^ 16 + 1563834963456883771498309022248496753805125281048581681606795606079693488022698265201311315270316165083707358234478370753591340 * α ^ 47 * (17 - α) ^ 15 + 959258589419178016234935333453270943911310250588295913774272713867179363938066640752243714741723229316103934660921840058331018 * α ^ 48 * (17 - α) ^ 14 + 527900112010660650248359261223300285284919503338654858382838983941810697808740176247054336097235620277146518114081044914641704 * α ^ 49 * (17 - α) ^ 13 + 259264801192497118934660971527450137059592143267324741721675524446679377229923273369087143487942107768190580548411748863625788 * α ^ 50 * (17 - α) ^ 12 + 112925257755528735753324539726634534462874074768785640447769616735919582936276633211358842716251496812674695066733945373630376 * α ^ 51 * (17 - α) ^ 11 + 43294208295108225572313363454714123552240387039341439399675327329984812526400837615036809250708210257269984868804715221768900 * α ^ 52 * (17 - α) ^ 10 + 14477109131118555980678814863672526273272305897056735808931397755854119363286698878099100454732834934400199349504635868575272 * α ^ 53 * (17 - α) ^ 9 + 4174569243543245209284931467152030006445783333411091743019898951807503568926775515227295551582461714654886147011664393698640 * α ^ 54 * (17 - α) ^ 8 + 1023195555636300366841604521638282501064465993225005460684172679015270094224232028670477159664015610240056559067645353077104 * α ^ 55 * (17 - α) ^ 7 + 209198594431248589503412319008039641002648327066847874065351685585470814434000466355080564735310580499259736416826148144344 * α ^ 56 * (17 - α) ^ 6 + 34783976201620581654146479854021503178010426501131959915156711925834764330476282903763164286902924648174181467158619488528 * α ^ 57 * (17 - α) ^ 5 + 4537117170708547774244512797745793493972596799818372048598224751094284949822133549967909771513344000829119085557004800874 * α ^ 58 * (17 - α) ^ 4 + 439587616858133764615021615831943232239201592269473877183402700593166522993563786139416926646861354484165239718064288908 * α ^ 59 * (17 - α) ^ 3 + 28864689907498275516712488927232990145839965615854349188000067895024636971944883064300818736721726097224141170690557182 * α ^ 60 * (17 - α) ^ 2 + 1070072225555048253521045141065543739116562978962155304409124790881546160712961916037048669936728578132382704101086352 * α ^ 61 * (17 - α) ^ 1 + 13265174660695058386402183278677678416743473633987916452549678002795064626597224750728225831441096471610791877259904 * α ^ 62 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 64 ≤ n) (h1 : n ≤ 69) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (69 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (69 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 64) (n := n) (n₁ := 69) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((64 : ℕ) : ℝ) - 4 = 60 by norm_num] at hb - rw [show (60 : ℝ) / 2 = ((30 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 63) + 1 / (4 * 63 * (3 + α)) + (1 - 2 * α / 68) ^ 2 * 69 * 68 * (69 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 63 * (3 + α)) ^ 30)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 64 ≤ n) (h1 : n ≤ 69) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 64) (n₁ := 69) (k := 30) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B64_69 diff --git a/Sendov/FiniteRange/Degree6_6.lean b/Sendov/FiniteRange/Degree6_6.lean index 7bafa2d..1414207 100644 --- a/Sendov/FiniteRange/Degree6_6.lean +++ b/Sendov/FiniteRange/Degree6_6.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 6 to 6 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 6) (gg1 6) (gg2 6) 1)) α := by - refine pev_wsum_eq_of_packed (gg0 6) (gg1 6) (gg2 6) 1 4 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 6) (gg1 6) (gg2 6) 1 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 6) (gg1 6) (gg2 6) 1 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 6) (gg1 6) (gg2 6) 3 (by simp) (by simp) (by simp) 1) - · rfl + refine pev_moment_eq_of_packed_bounds 6 1 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 6 α t ^ 1) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 5 / 2) : 0 < 1575 - 900 * α + 2345 * α ^ 2 - 342 * α ^ 3 - 24 * α ^ 4 := by have hu : (0 : ℝ) ≤ 5 - 2 * α := by linarith have hid : (5 : ℝ) ^ 4 * (1575 - 900 * α + 2345 * α ^ 2 - 342 * α ^ 3 - 24 * α ^ 4) = 1575 * (5 - 2 * α) ^ 4 + 8100 * α ^ 1 * (5 - 2 * α) ^ 3 + 69425 * α ^ 2 * (5 - 2 * α) ^ 2 + 188150 * α ^ 3 * (5 - 2 * α) ^ 1 + 123200 * α ^ 4 := by - ring + bernstein_ring α (5 - 2 * α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (5 - 2 * α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 6 ≤ n) (h1 : n ≤ 6) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (6 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (6 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 6) (n := n) (n₁ := 6) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((6 : ℕ) : ℝ) - 4 = 2 by norm_num] at hb - rw [show (2 : ℝ) / 2 = ((1 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 5) + 1 / (4 * 5 * (3 + α)) + (1 - 2 * α / 5) ^ 2 * 6 * 5 * (6 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 5 * (3 + α)) ^ 1)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 6 ≤ n) (h1 : n ≤ 6) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 6) (n₁ := 6) (k := 1) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B6_6 diff --git a/Sendov/FiniteRange/Degree70_79.lean b/Sendov/FiniteRange/Degree70_79.lean index 906180f..d350358 100644 --- a/Sendov/FiniteRange/Degree70_79.lean +++ b/Sendov/FiniteRange/Degree70_79.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 70 to 79 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 70) (gg1 70) (gg2 70) 33)) α := by - refine pev_wsum_eq_of_packed (gg0 70) (gg1 70) (gg2 70) 33 100 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 70) (gg1 70) (gg2 70) 33 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 70) (gg1 70) (gg2 70) 33 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 70) (gg1 70) (gg2 70) 3 (by simp) (by simp) (by simp) 33) - · rfl + refine pev_moment_eq_of_packed_bounds 70 33 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 70 α t ^ 33) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 + 55048255682073709607204036059519252499577954075805344228144067353398773939360654388786551620754044174 * α + 303631470940991973002262259034385880105972184753330155102383400602879297569999672180560254047614733064 * α ^ 2 + 1082629940665673044764709543433093878486364849040990099597525143450118708087349123259727336344728664544 * α ^ 3 + 2804599610843097204574458002687246299093134788634086599591559738125527989079685417982892820063924460373 * α ^ 4 + 5624645401139815516982667151087561797773568501921017826805664176655117168979590819326893993434748481137 * α ^ 5 + 9086529173583154645809008602511982564716590500042635425568606924621639922909196505882243392404835758015 * α ^ 6 + 12147764349688852841301807848655896145357577978996235836231868297037709466427619171816150975300099741791 * α ^ 7 + 13702180594674637952993181456614636961007303430300258709825461099491823680923881039132440258291527607905 * α ^ 8 + 13228790758953813166525229226864556895698491358332563699351209388421354345605839944544173983846341165317 * α ^ 9 + 11051940590803482762640027098441612629424377433949792947689615004158487742382763237735051674050718363307 * α ^ 10 + 8057730499045200268719730173861520782106924341107579339386385608691893710110000816392557161453112592131 * α ^ 11 + 5160484214825899033659577721795935067593212006301594642310233538545527417677809202356341306165128799909 * α ^ 12 + 2917926196608374844731210581375035036343917943893823360466936440450011366221495240241631678212028102353 * α ^ 13 + 1462315101539635752571716649246230545438507378471968670138935884045737693317302923326515165319274353863 * α ^ 14 + 651362758608261532683053553948901251603409142895470962454343186012266250060431761761109117155529185351 * α ^ 15 + 258382911131744978730219354901244362207736065992848531597126642760778004801626888171716412430540285505 * α ^ 16 + 91380564667115290929103952618176877475251392601510902630099986346625474504164568221576682912080867653 * α ^ 17 + 28823701484229764785510610641119924329640879766929838579606063832811514346965585992079347095184066891 * α ^ 18 + 8105512742405337827384222403832648005310429131045055117867656987105207137736030417145103472632533011 * α ^ 19 + 2029737755516453702412381601616827618446965035012177295868811221050918334739516968406653005043323145 * α ^ 20 + 451715825606281157427809648282481163078916909506829474305720867391455366362160566615805697668034469 * α ^ 21 + 89083872539236033065296789508746088826183108150642030163709620396857932007741467883529598127701027 * α ^ 22 + 15507062046600275350060333043623953591886937497826357117111310333499555606548238470938828041232307 * α ^ 23 + 2370291817598182097124474831710334939044419386117776585894929734754031639676722325611554692802929 * α ^ 24 + 315999149372391878452912834168990330419105934995500914232394089420371940254905369886539160346853 * α ^ 25 + 36423009146013699028116153780709317964569427476167451734283550363318237494233399180783337169695 * α ^ 26 + 3588163263018483116273779737008794180190405472634090416966530935626554841121047871569879767559 * α ^ 27 + 297471336921909919923207632811348664497121895483393172379791904969696166207311294171026521523 * α ^ 28 + 20305725467845794109711961738383951154160346509672805134214469944833591189715035234346686183 * α ^ 29 + 1103609488904163566431208273520751297004151033048526881874218221163688540301268998957942157 * α ^ 30 + 44705334211106925450419755417917993038028222392715074881553657780646344635657758883181805 * α ^ 31 + 805515192221430510609334948188870016650885857492958289044650012247928862875245764497551 * α ^ 32 - 1482048260833901649795245609960707851397885375498496335550472054736679501095164961700205 * α ^ 33 + 28550595118000674813695237772389123615483889198973830073821326304976753853122397016687 * α ^ 34 - 110293125322577848844861697626305509333317224753061067523753150512274273997930489889 * α ^ 35 - 2944264371932464496615000679541333014546134952187144901035323438838119921163626816 * α ^ 36 - 42753460721496719482279714802299033215763752656049106329252818812714655687701920 * α ^ 37 + 892039301043622007789612879017665871347081871863607139597567473234375585298160 * α ^ 38 + 90290182213750286064408757160215991459134539105309106871418780497371434069600 * α ^ 39 + 3686520145576645994835054065141215370192750469525569878892121423026501980224 * α ^ 40 + 101266458446089775184406440743070690042012917626596066692722657223969408256 * α ^ 41 + 1921165999972257449345542825175329806471062302564814176599267497713370880 * α ^ 42 + 18910079844664677393253742829163990204177395135122636437886747825783808 * α ^ 43 - 267203790007683385371238236401248869931744610843957702759988424811520 * α ^ 44 - 18630321688593096100250955298980358254132585106002718798371125157888 * α ^ 45 - 549431692437424587483251682306834452811394511706522157550126837760 * α ^ 46 - 11827470008686810839474011121751705014739559837533303829463834624 * α ^ 47 - 206601161707202641093681870196336457333557666704999087205793792 * α ^ 48 - 3050100062225303864539589793145445854252294435418792706244608 * α ^ 49 - 38831214153718995312467487136862135070778219830730009018368 * α ^ 50 - 431130925861351878296650698743841679980168113965805076480 * α ^ 51 - 4201734530680545401568837521217272752627836979325435904 * α ^ 52 - 36075335848543051909606823878062380154340083870203904 * α ^ 53 - 273302433216495374400156548854470569604061187801088 * α ^ 54 - 1826924843542958932998763336695299600883344474112 * α ^ 55 - 10760219439515367849051421269035765266542231552 * α ^ 56 - 55683568301576061216924181665153394893914112 * α ^ 57 - 252108560765968990302771636780305076977664 * α ^ 58 - 992726472130728702576289249214808981504 * α ^ 59 - 3372896548691756253399508431270838272 * α ^ 60 - 9784355714995137510417248525746176 * α ^ 61 - 23895590924284630456363042996224 * α ^ 62 - 48203390780462373975323836416 * α ^ 63 - 78197438735478405231280128 * α ^ 64 - 98061705121359087009792 * α ^ 65 - 89226089066196369408 * α ^ 66 - 52420526819246080 * α ^ 67 - 14929306320896 * α ^ 68 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 68 * (4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 + 55048255682073709607204036059519252499577954075805344228144067353398773939360654388786551620754044174 * α + 303631470940991973002262259034385880105972184753330155102383400602879297569999672180560254047614733064 * α ^ 2 + 1082629940665673044764709543433093878486364849040990099597525143450118708087349123259727336344728664544 * α ^ 3 + 2804599610843097204574458002687246299093134788634086599591559738125527989079685417982892820063924460373 * α ^ 4 + 5624645401139815516982667151087561797773568501921017826805664176655117168979590819326893993434748481137 * α ^ 5 + 9086529173583154645809008602511982564716590500042635425568606924621639922909196505882243392404835758015 * α ^ 6 + 12147764349688852841301807848655896145357577978996235836231868297037709466427619171816150975300099741791 * α ^ 7 + 13702180594674637952993181456614636961007303430300258709825461099491823680923881039132440258291527607905 * α ^ 8 + 13228790758953813166525229226864556895698491358332563699351209388421354345605839944544173983846341165317 * α ^ 9 + 11051940590803482762640027098441612629424377433949792947689615004158487742382763237735051674050718363307 * α ^ 10 + 8057730499045200268719730173861520782106924341107579339386385608691893710110000816392557161453112592131 * α ^ 11 + 5160484214825899033659577721795935067593212006301594642310233538545527417677809202356341306165128799909 * α ^ 12 + 2917926196608374844731210581375035036343917943893823360466936440450011366221495240241631678212028102353 * α ^ 13 + 1462315101539635752571716649246230545438507378471968670138935884045737693317302923326515165319274353863 * α ^ 14 + 651362758608261532683053553948901251603409142895470962454343186012266250060431761761109117155529185351 * α ^ 15 + 258382911131744978730219354901244362207736065992848531597126642760778004801626888171716412430540285505 * α ^ 16 + 91380564667115290929103952618176877475251392601510902630099986346625474504164568221576682912080867653 * α ^ 17 + 28823701484229764785510610641119924329640879766929838579606063832811514346965585992079347095184066891 * α ^ 18 + 8105512742405337827384222403832648005310429131045055117867656987105207137736030417145103472632533011 * α ^ 19 + 2029737755516453702412381601616827618446965035012177295868811221050918334739516968406653005043323145 * α ^ 20 + 451715825606281157427809648282481163078916909506829474305720867391455366362160566615805697668034469 * α ^ 21 + 89083872539236033065296789508746088826183108150642030163709620396857932007741467883529598127701027 * α ^ 22 + 15507062046600275350060333043623953591886937497826357117111310333499555606548238470938828041232307 * α ^ 23 + 2370291817598182097124474831710334939044419386117776585894929734754031639676722325611554692802929 * α ^ 24 + 315999149372391878452912834168990330419105934995500914232394089420371940254905369886539160346853 * α ^ 25 + 36423009146013699028116153780709317964569427476167451734283550363318237494233399180783337169695 * α ^ 26 + 3588163263018483116273779737008794180190405472634090416966530935626554841121047871569879767559 * α ^ 27 + 297471336921909919923207632811348664497121895483393172379791904969696166207311294171026521523 * α ^ 28 + 20305725467845794109711961738383951154160346509672805134214469944833591189715035234346686183 * α ^ 29 + 1103609488904163566431208273520751297004151033048526881874218221163688540301268998957942157 * α ^ 30 + 44705334211106925450419755417917993038028222392715074881553657780646344635657758883181805 * α ^ 31 + 805515192221430510609334948188870016650885857492958289044650012247928862875245764497551 * α ^ 32 - 1482048260833901649795245609960707851397885375498496335550472054736679501095164961700205 * α ^ 33 + 28550595118000674813695237772389123615483889198973830073821326304976753853122397016687 * α ^ 34 - 110293125322577848844861697626305509333317224753061067523753150512274273997930489889 * α ^ 35 - 2944264371932464496615000679541333014546134952187144901035323438838119921163626816 * α ^ 36 - 42753460721496719482279714802299033215763752656049106329252818812714655687701920 * α ^ 37 + 892039301043622007789612879017665871347081871863607139597567473234375585298160 * α ^ 38 + 90290182213750286064408757160215991459134539105309106871418780497371434069600 * α ^ 39 + 3686520145576645994835054065141215370192750469525569878892121423026501980224 * α ^ 40 + 101266458446089775184406440743070690042012917626596066692722657223969408256 * α ^ 41 + 1921165999972257449345542825175329806471062302564814176599267497713370880 * α ^ 42 + 18910079844664677393253742829163990204177395135122636437886747825783808 * α ^ 43 - 267203790007683385371238236401248869931744610843957702759988424811520 * α ^ 44 - 18630321688593096100250955298980358254132585106002718798371125157888 * α ^ 45 - 549431692437424587483251682306834452811394511706522157550126837760 * α ^ 46 - 11827470008686810839474011121751705014739559837533303829463834624 * α ^ 47 - 206601161707202641093681870196336457333557666704999087205793792 * α ^ 48 - 3050100062225303864539589793145445854252294435418792706244608 * α ^ 49 - 38831214153718995312467487136862135070778219830730009018368 * α ^ 50 - 431130925861351878296650698743841679980168113965805076480 * α ^ 51 - 4201734530680545401568837521217272752627836979325435904 * α ^ 52 - 36075335848543051909606823878062380154340083870203904 * α ^ 53 - 273302433216495374400156548854470569604061187801088 * α ^ 54 - 1826924843542958932998763336695299600883344474112 * α ^ 55 - 10760219439515367849051421269035765266542231552 * α ^ 56 - 55683568301576061216924181665153394893914112 * α ^ 57 - 252108560765968990302771636780305076977664 * α ^ 58 - 992726472130728702576289249214808981504 * α ^ 59 - 3372896548691756253399508431270838272 * α ^ 60 - 9784355714995137510417248525746176 * α ^ 61 - 23895590924284630456363042996224 * α ^ 62 - 48203390780462373975323836416 * α ^ 63 - 78197438735478405231280128 * α ^ 64 - 98061705121359087009792 * α ^ 65 - 89226089066196369408 * α ^ 66 - 52420526819246080 * α ^ 67 - 14929306320896 * α ^ 68) = 4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 * (17 - α) ^ 68 + 1265157032653140923172696358781045157064900401217905487833243537047108668589294636491165982694547047750 * α ^ 1 * (17 - α) ^ 67 + 161482237306767878745241819415998746410809769680683392204930507623070859153937168257049914988047412112214 * α ^ 2 * (17 - α) ^ 66 + 13422247499165700437689764267709730212036079924252530397947436539414938500806129414515249428924591360471250 * α ^ 3 * (17 - α) ^ 65 + 816972781682827686607611010623394023676328688115620152082292022403046953548356768129403300216449427112754113 * α ^ 4 * (17 - α) ^ 64 + 38824370988158138726941311700115756071290366487538089829867353036362853363011105712229404919753034517698319713 * α ^ 5 * (17 - α) ^ 63 + 1499833600292598822014341704041896176361474668441008024749667474678088913996818119654158697311930608272571456030 * α ^ 6 * (17 - α) ^ 62 + 48422932809787295787390564041245327912518154539781119501099341947995210984379450371937423256131589899210941134514 * α ^ 7 * (17 - α) ^ 61 + 1333124974240927854482159425251402107245186286978279403787625094573367841803246952758768754029487309692347318336240 * α ^ 8 * (17 - α) ^ 60 + 31777797124891464951721548329322036172531399956667440482696617718123564246691425958497694319690617969140927686684080 * α ^ 9 * (17 - α) ^ 59 + 663714337585641075862710458977346289450664855026176138573830637339763833070986663739178423777505821459460189852947968 * α ^ 10 * (17 - α) ^ 58 + 12262485846674184769453169937509946039571704829287751556559418951991378092254593946982159731229796032255503955934621616 * α ^ 11 * (17 - α) ^ 57 + 201969028018565162730161510400745329670143714141289296191558060115320430534002168054679415522116383859539020895554723776 * α ^ 12 * (17 - α) ^ 56 + 2984596421743417793782332651870684512173959536289036391110144204303743763821125710106900081031600434022380226544823660080 * α ^ 13 * (17 - α) ^ 55 + 39784321437763110285727312524497427978490644060968737608182005051306614478428882059166898040103949867844194968529236966504 * α ^ 14 * (17 - α) ^ 54 + 480543938548422612890741989991526270246304382173993722693724388642176377466756024411416886199383755538111290823987013369160 * α ^ 15 * (17 - α) ^ 53 + 5279901417754954883742431587978703767626877114504290728644469223047973916917301789839124306590322937367972095259516102221832 * α ^ 16 * (17 - α) ^ 52 + 52945203354166745644230222209580146500462821416245712770967147511123795041025063164899837137984308325228112243872402797720184 * α ^ 17 * (17 - α) ^ 51 + 485928342569266463087021622036455747024462941842401506731286158733175889455343816199003845608430478859161164238309759380850320 * α ^ 18 * (17 - α) ^ 50 + 4091958406668774678507241930361086964473233452855436917980174792821511603462125609865012423204529448494332739565952940847535008 * α ^ 19 * (17 - α) ^ 49 + 31683212460188578387342804176945072229413086255880741845271045566233563281959233289534062862735569422810201289901710942585691872 * α ^ 20 * (17 - α) ^ 48 + 225979630689303507786898260664009071625270094449716362704636848456295027690433997904251442068696550669529118551488817387880290256 * α ^ 21 * (17 - α) ^ 47 + 1487128617430673014516169749515363875219566281808091046150030684893815735850131065805579647668091571852789526355428971538991078216 * α ^ 22 * (17 - α) ^ 46 + 9042148580683115945632798662691502266143017079630193956758831416930496458610190341296994016055070448189744269126207258222640342120 * α ^ 23 * (17 - α) ^ 45 + 50858358010848454557731664420671103160817707432587833055365526944577128658034548080461931999630601918157623952028511496302491645436 * α ^ 24 * (17 - α) ^ 44 + 264894421723415244260430513144029948945395618262574763973851002784217525442701126127347374644597622077075226262022822088501696204428 * α ^ 25 * (17 - α) ^ 43 + 1278767873696353424101636053219073837545595922525849403166724782352583013823834674590289275813557084219485073578825413587799211967436 * α ^ 26 * (17 - α) ^ 42 + 5725993526407220170131735130796235929803474480006433589234997891028171711914835354674252789493105774845667439300549950141552174204148 * α ^ 27 * (17 - α) ^ 41 + 23797472948050627920664370923139924765880312522674540655463364156321698714682589900985886207317662923270995738996512039485735022862410 * α ^ 28 * (17 - α) ^ 40 + 91847188399449607906860584187806753120315922783214799014025827204769651430206806052585878934846199020273478297324347000279002931574522 * α ^ 29 * (17 - α) ^ 39 + 329342373949609101951511940154131075827972185993638085640480145831458749736060460017623365544223280262966286218021296303864864015746416 * α ^ 30 * (17 - α) ^ 38 + 1097560558892751992700895204428590904051076121281041797677676037125864755311439126982165925162500305191774580034834400855567800165723472 * α ^ 31 * (17 - α) ^ 37 + 3400354684972857879605435169696913406951341446392821917656396040731072702340906869893233782691459204642830241785914469379158439677051796 * α ^ 32 * (17 - α) ^ 36 + 9795255185712404229440153808939878082728601957977592077724575912171144463816508150030377679174644938546737146393361620285646830422256420 * α ^ 33 * (17 - α) ^ 35 + 26239203554755141459745089973391959355052889674186027464718372088695695988893799042814172271546870765144481886268457658334065389516464974 * α ^ 34 * (17 - α) ^ 34 + 65364772208973664575034750355459656935183422873874505526092428372633233840636570937545030505946122798332726471550017157961822599578476434 * α ^ 35 * (17 - α) ^ 33 + 151417890873929453489601556690033520410995454719040770050368045093177324038829603093684868348571248298437596387498225961228162231792553093 * α ^ 36 * (17 - α) ^ 32 + 326136561459197293128988773328742282995557141736905381102626192805005586172364773727221188473432861214419687642701273642338530960261384661 * α ^ 37 * (17 - α) ^ 31 + 653015723122962185079373689805649153519043802243690625985998409467892401539972839267641852663543640591936858448032520844893189758926012070 * α ^ 38 * (17 - α) ^ 30 + 1215133738838743206101520047205100561581201889449447221306287657871682157019672294661855343053509410150028759117930302323754459334908148634 * α ^ 39 * (17 - α) ^ 29 + 2100547367169647162309522500534430225020946624321317667617084318982110113730770172930764538999209173828708805485472118278853696220026559040 * α ^ 40 * (17 - α) ^ 28 + 3371572226105498605533309421720928970740445870449689033321124541953074173720243492689723243231990142125903392944525071646763046153799712752 * α ^ 41 * (17 - α) ^ 27 + 5021731712866329267615629279744145209979569686428333572284923100300160062927127615408116117696235006051137970230291268323176361338022571184 * α ^ 42 * (17 - α) ^ 26 + 6935282526605279700851082376753425399984816075966925438156290984812989264949621990948332423313032156685195715186548440728089466656780320080 * α ^ 43 * (17 - α) ^ 25 + 8872887599583942844730285240702268137994535894273818319558203225690794212214876544716058828209821312295910996151845255442057724010075373248 * α ^ 44 * (17 - α) ^ 24 + 10504640550563806719417324418003161655867163727170635219980235187136023481938024960895708709168710341339951422197356602510535614885945508256 * α ^ 45 * (17 - α) ^ 23 + 11493574135707887540289576369636114410520335535521279072065981221823553796516692389915466887949431055195475567153283570135491233527632506928 * α ^ 46 * (17 - α) ^ 22 + 11604808627242697256579914136813566676833914505736299110704677968571962615410435000953138171276194970496716595805082770429385722453886399056 * α ^ 47 * (17 - α) ^ 21 + 10793967840695396334802012163192802178890797549077696640851371801953999538826236827198386902657587341524929692133771331237779053672003790160 * α ^ 48 * (17 - α) ^ 20 + 9230499922489526427651509591753374367209146684551244899464268618430259566127381498045470358588046512126019036255090586145820433029559234480 * α ^ 49 * (17 - α) ^ 19 + 7240815654095776003678341965368139318124068790043794347929887962009532007602522612129159417690713015083966661427793715858516996767469271084 * α ^ 50 * (17 - α) ^ 18 + 5196910721982371088216812572801559409316958643069477659778573971072818964949630354690214200347540577616724298122257242598606667131480040052 * α ^ 51 * (17 - α) ^ 17 + 3402631899636205416266590253352818738890126853621420549170291181525659701590036840082549061908694049445145596493472438472698439652700425890 * α ^ 52 * (17 - α) ^ 16 + 2025465883034696535913461632694517262359063545972119023350389907385898500473981148635068061077366719947869607252392209033800465429303336450 * α ^ 53 * (17 - α) ^ 15 + 1091892060376371705496056687719844206882169207141786444740932042075723042341165731755946837934817210431949903331903986496675369334494701764 * α ^ 54 * (17 - α) ^ 14 + 530656327268367909969479070273109187787062122866155559515976559252491925394512132156718870616555877823790538113874300155722493907068691260 * α ^ 55 * (17 - α) ^ 13 + 231274284789425659234396174824508586685686100786488695662129653371227054848548241907361605558199603413655338792402925999207216602489857076 * α ^ 56 * (17 - α) ^ 12 + 89827076778691705270449318543458115575152231899967166072570553309114042367109650873526097636925926390123634607634695515051611658499946996 * α ^ 57 * (17 - α) ^ 11 + 30860904487494092370763766510390952712726910195346707673456930961614703228983522639588565939176152364301734964159970624603354686308829140 * α ^ 58 * (17 - α) ^ 10 + 9293886338970220832863344149731277643249660026631312547931533444041183229427806614161759486641998156855793362317993688595988612988379260 * α ^ 59 * (17 - α) ^ 9 + 2426161101634452818983962562364451171736421102519269820482811118536093138975233934291550597521985218265397595876703167336388333325163886 * α ^ 60 * (17 - α) ^ 8 + 541326371175450174067359875320150061071720972908442799245727828526206560614239255074965243639722409936039557063502412543527181027654830 * α ^ 61 * (17 - α) ^ 7 + 101368480597397327160028924375975580286493435206169413993404105377621448331740368126390317293582211745281779073436064732857223060861736 * α ^ 62 * (17 - α) ^ 6 + 15547562252184505730936231501759499165264416461623728410208958056020346369720300266147477570730217995958466276171125428082524576695080 * α ^ 63 * (17 - α) ^ 5 + 1887656008153650149223340824201972880431295033490416452460837788376128006557577215350851966367675841189217496088025419715076251556542 * α ^ 64 * (17 - α) ^ 4 + 172441329568599584346229934517512403814851421579063304992333529980418530837648814241006023742701428622424347746365799682216705162958 * α ^ 65 * (17 - α) ^ 3 + 10912136951540694390745084178080768035297012709958710219152508683320236507590661219843460673650554961847278661895402354571440431696 * α ^ 66 * (17 - α) ^ 2 + 409247002638066659293933857623421051407334490908373427758260767055975950442905835798620454491056045234820861455361280121831050520 * α ^ 67 * (17 - α) ^ 1 + 6145809855889991363427473372969457107085687932679016036884496519288814567653275417252009402531892559405828541206858545507410560 * α ^ 68 := by - ring + bernstein_ring α (17 - α) -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 70 ≤ n) (h1 : n ≤ 79) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (79 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (79 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 70) (n := n) (n₁ := 79) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((70 : ℕ) : ℝ) - 4 = 66 by norm_num] at hb - rw [show (66 : ℝ) / 2 = ((33 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 69) + 1 / (4 * 69 * (3 + α)) + (1 - 2 * α / 78) ^ 2 * 79 * 78 * (79 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 69 * (3 + α)) ^ 33)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 70 ≤ n) (h1 : n ≤ 79) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 70) (n₁ := 79) (k := 33) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B70_79 diff --git a/Sendov/FiniteRange/Degree80_100.lean b/Sendov/FiniteRange/Degree80_100.lean index 6324f96..eda9bee 100644 --- a/Sendov/FiniteRange/Degree80_100.lean +++ b/Sendov/FiniteRange/Degree80_100.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 80 to 100 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 80) (gg1 80) (gg2 80) 38)) α := by - refine pev_wsum_eq_of_packed (gg0 80) (gg1 80) (gg2 80) 38 115 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 80) (gg1 80) (gg2 80) 38 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 80) (gg1 80) (gg2 80) 38 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 80) (gg1 80) (gg2 80) 3 (by simp) (by simp) (by simp) 38) - · rfl + refine pev_moment_eq_of_packed_bounds 80 38 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 80 α t ^ 38) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 25811606424535915506326543401482443660479168162161070878750987845784640947537512918254143661443967851841624182260454 + 336370345330350208165234204307830830778265112065902973986047706784620119812179101529287799329664970700047233908530028 * α + 2135490323710205451177831007886434323850910269893926405766449302023972016567372609179660983528148958829173461437058426 * α ^ 2 + 8800193380808665214547458427848614541537421741398394617093689631071556593600442609061272206311515066984302690924269000 * α ^ 3 + 26462827687725576351409435396337556001601266481763435312645957683742611763538244106923991390112640216709155823432046446 * α ^ 4 + 61890317824100182817489513892770080906362674388551785381427868354803942587321704313688072997460165545388054174413205140 * α ^ 5 + 117172359697259929763030783557189322339080300100874585985220084088882745103145230216047487779174956161518920280447603674 * α ^ 6 + 184544739027532874709347195849421533711097651533181291373211062330869431152671413319813999120439419738468174182904364464 * α ^ 7 + 246608145764613286789878656386710073720610930090411123420903881172229605185065434892818764890373842116194248634263756798 * α ^ 8 + 283763693487574246430404620051411555790859557853657413692053633072552222818811355084552210214522447497912164915857007772 * α ^ 9 + 284375388167493337786979561808634395465424553508941556573930507406581722477890971264427055005741911794482115087411543730 * α ^ 10 + 250434456333498778687253731739220273422355020504490227298836915758303181227856673748711052077418442551670601820448469608 * α ^ 11 + 195186376833089073717511924197741339564583901408375396552289751612744737294639334816437871802096096044647044024483571528 * α ^ 12 + 135403325876044028593166865189418922031634343539481341612266706224679843802900374983571701066935649917189903585957861976 * α ^ 13 + 83987295633438700092517506437803590415296544388998812046873276158407316217262430264254188896692746403373298520205212844 * α ^ 14 + 46749761312162043935912318982126078666828249385834636225082169910759646501503433598091545864589766997203234619939545928 * α ^ 15 + 23418772546685983831264607439067708954491960164074800112819444923487497120280358300648725634717312663795784508649665131 * α ^ 16 + 10580616042971700828358189370081401738808367070894586162364463432933276777181125840333157268302229461101124643546709974 * α ^ 17 + 4318183659819981488074693370040938716545728929617703773317165795943654804101138834083140850940446923358733078548068645 * α ^ 18 + 1593587693765014079746102214238987350113694708675138266157201007419844029857283186926010079342854945184589138949560164 * α ^ 19 + 532047925009422644797257472015181516662587259482075864085888807106871007422932953581727885439598490014141304896691047 * α ^ 20 + 160701892364069140905358669813546549814319510910544697552500165178091918076856803958923921001593977227161490804746106 * α ^ 21 + 43889653627121057923774311030558057038777866396589839090993605786486211704353490599487695285745585770243180871001173 * α ^ 22 + 10827357706237228452243490602525886439138079007606319319715720331950005385599610283148806774807521304374526909486664 * α ^ 23 + 2408842256812625932290911263046890728148322122703071503064745543954110106028352314896838503963205885454006647328032 * α ^ 24 + 482237450846393383131287501498018968499665598348674814673101519961867723893846884326467389187302292657246662111488 * α ^ 25 + 86620744735037078123451064351322751112466467920961355862225908103410633498456796660448573578914072648246281297272 * α ^ 26 + 13908651519349479073873240534072463905809010212400405416347877534040408226391579668251784782713336166212519013104 * α ^ 27 + 1987136509055095540850907316692328719109975779097323211935130132295635949953814198439654077152611676110556260102 * α ^ 28 + 251138932516361376722297645486554574796035287318555929793528638706264274506637419055880639659286763175005448076 * α ^ 29 + 27871094123052914818399316975765472111564288696313684416212667809570265754686721498698986614959173244385297518 * α ^ 30 + 2690865047909357054511239261296500605261094896849533507003089976244070348637842057420543829564694293947173400 * α ^ 31 + 223291370726238703406997118812607738047342804101888528968918478200237656608670127439529056632663807296136083 * α ^ 32 + 15669985331287744715848606174054829999776651533612117903292549399606649200386705738963593063781305669960598 * α ^ 33 + 909073729758232176167878755737698432102154655242833248859457302905520734577946123899448989405380991348941 * α ^ 34 + 42091260471451636997926921594629293230252747899173824918202060597101883618323097768155200270442748875668 * α ^ 35 + 1450861895455204845787988647170733163350496179912678839329200986510884388428173389320127180407765638551 * α ^ 36 + 19698279579096177164787018164158789132912466550646401885212259058865017062230215250892367283766302154 * α ^ 37 - 57652053317489414390572934832324830300466266131622345505450510286650133357321127488185831111381791595 * α ^ 38 + 735839726136777192033003352499083088738558026604488978404480341017143472486567180936350888710307864 * α ^ 39 - 4556557091452941380040035385055147646930930624200910749123957637499614710015132762550103799821048 * α ^ 40 - 133385784303410256278801057965454595590178412725438433339158980224721485193506478868247418219456 * α ^ 41 - 3423096723020314850982421385371010756189634167048478694293828864372204445633272936186470719904 * α ^ 42 - 69804839903958953293946387520015029557798645931631581080348037608367532112774187909634522240 * α ^ 43 - 865452330871186953510596734828786492278941181396935228550729318386099014534564956306824064 * α ^ 44 + 6798618471243250403976624728656397719531634223766543816506986827945697172779099788420608 * α ^ 45 + 788561506471686257274486905164229697457259305541495354329419768350740667053416558054144 * α ^ 46 + 27404388758747154771370930189376580679701159098426606936627216153391035767084433846272 * α ^ 47 + 646649551478726098614980210707984819816807233831805276746361716798674738190577340416 * α ^ 48 + 11211130515851440319438235357551475100839553634180130203899774136494056161035911168 * α ^ 49 + 130654761491363390209265527305244677484674002463471732106539824077702885812797440 * α ^ 50 + 357370958717189390935129396104908992248522307474545437642970135644954582646784 * α ^ 51 - 29181736810016345568442240720495430859483450421903151495150669166766787592192 * α ^ 52 - 955989844135526470691849812345208816075517571032312722273829147296013484032 * α ^ 53 - 19693589749621923555627023816809550207524792367857705784556171741361864704 * α ^ 54 - 319527958823219288171919301676630081495413277792849934402743906350399488 * α ^ 55 - 4359916692864270231911575583538878442433933182393484084715401339994112 * α ^ 56 - 51487996872395271018065603117315986670053043845988016897449388933120 * α ^ 57 - 534287852041371238607889671805075544881560005268660814584293097472 * α ^ 58 - 4914742088163302214038533958003066516795399439930469941648556032 * α ^ 59 - 40286770643795091951577560453084774722804729349509280681689088 * α ^ 60 - 295170417808439805757992973335875121127546339919271705968640 * α ^ 61 - 1935804396482191076314681386409043851261791712104853536768 * α ^ 62 - 11366432523474642581662414816114955814707861565858643968 * α ^ 63 - 59703170845283859723339853111711322814822346376871936 * α ^ 64 - 280018128137086019618307155094771953353132297158656 * α ^ 65 - 1169385347161959260160465901639985114274911485952 * α ^ 66 - 4331161143994110763407260197680039459865755648 * α ^ 67 - 14153828793218044771011521216530198581739520 * α ^ 68 - 40537586126827346928475190951612417835008 * α ^ 69 - 100883783567908658123954038279633895424 * α ^ 70 - 215746527094612923562575346607849472 * α ^ 71 - 390762372880065519809958474940416 * α ^ 72 - 587839886222327464463148515328 * α ^ 73 - 714822291149465741724483584 * α ^ 74 - 675179423113136706682880 * α ^ 75 - 464818794079734202368 * α ^ 76 - 207493237324120064 * α ^ 77 - 45079976738816 * α ^ 78 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 78 * (25811606424535915506326543401482443660479168162161070878750987845784640947537512918254143661443967851841624182260454 + 336370345330350208165234204307830830778265112065902973986047706784620119812179101529287799329664970700047233908530028 * α + 2135490323710205451177831007886434323850910269893926405766449302023972016567372609179660983528148958829173461437058426 * α ^ 2 + 8800193380808665214547458427848614541537421741398394617093689631071556593600442609061272206311515066984302690924269000 * α ^ 3 + 26462827687725576351409435396337556001601266481763435312645957683742611763538244106923991390112640216709155823432046446 * α ^ 4 + 61890317824100182817489513892770080906362674388551785381427868354803942587321704313688072997460165545388054174413205140 * α ^ 5 + 117172359697259929763030783557189322339080300100874585985220084088882745103145230216047487779174956161518920280447603674 * α ^ 6 + 184544739027532874709347195849421533711097651533181291373211062330869431152671413319813999120439419738468174182904364464 * α ^ 7 + 246608145764613286789878656386710073720610930090411123420903881172229605185065434892818764890373842116194248634263756798 * α ^ 8 + 283763693487574246430404620051411555790859557853657413692053633072552222818811355084552210214522447497912164915857007772 * α ^ 9 + 284375388167493337786979561808634395465424553508941556573930507406581722477890971264427055005741911794482115087411543730 * α ^ 10 + 250434456333498778687253731739220273422355020504490227298836915758303181227856673748711052077418442551670601820448469608 * α ^ 11 + 195186376833089073717511924197741339564583901408375396552289751612744737294639334816437871802096096044647044024483571528 * α ^ 12 + 135403325876044028593166865189418922031634343539481341612266706224679843802900374983571701066935649917189903585957861976 * α ^ 13 + 83987295633438700092517506437803590415296544388998812046873276158407316217262430264254188896692746403373298520205212844 * α ^ 14 + 46749761312162043935912318982126078666828249385834636225082169910759646501503433598091545864589766997203234619939545928 * α ^ 15 + 23418772546685983831264607439067708954491960164074800112819444923487497120280358300648725634717312663795784508649665131 * α ^ 16 + 10580616042971700828358189370081401738808367070894586162364463432933276777181125840333157268302229461101124643546709974 * α ^ 17 + 4318183659819981488074693370040938716545728929617703773317165795943654804101138834083140850940446923358733078548068645 * α ^ 18 + 1593587693765014079746102214238987350113694708675138266157201007419844029857283186926010079342854945184589138949560164 * α ^ 19 + 532047925009422644797257472015181516662587259482075864085888807106871007422932953581727885439598490014141304896691047 * α ^ 20 + 160701892364069140905358669813546549814319510910544697552500165178091918076856803958923921001593977227161490804746106 * α ^ 21 + 43889653627121057923774311030558057038777866396589839090993605786486211704353490599487695285745585770243180871001173 * α ^ 22 + 10827357706237228452243490602525886439138079007606319319715720331950005385599610283148806774807521304374526909486664 * α ^ 23 + 2408842256812625932290911263046890728148322122703071503064745543954110106028352314896838503963205885454006647328032 * α ^ 24 + 482237450846393383131287501498018968499665598348674814673101519961867723893846884326467389187302292657246662111488 * α ^ 25 + 86620744735037078123451064351322751112466467920961355862225908103410633498456796660448573578914072648246281297272 * α ^ 26 + 13908651519349479073873240534072463905809010212400405416347877534040408226391579668251784782713336166212519013104 * α ^ 27 + 1987136509055095540850907316692328719109975779097323211935130132295635949953814198439654077152611676110556260102 * α ^ 28 + 251138932516361376722297645486554574796035287318555929793528638706264274506637419055880639659286763175005448076 * α ^ 29 + 27871094123052914818399316975765472111564288696313684416212667809570265754686721498698986614959173244385297518 * α ^ 30 + 2690865047909357054511239261296500605261094896849533507003089976244070348637842057420543829564694293947173400 * α ^ 31 + 223291370726238703406997118812607738047342804101888528968918478200237656608670127439529056632663807296136083 * α ^ 32 + 15669985331287744715848606174054829999776651533612117903292549399606649200386705738963593063781305669960598 * α ^ 33 + 909073729758232176167878755737698432102154655242833248859457302905520734577946123899448989405380991348941 * α ^ 34 + 42091260471451636997926921594629293230252747899173824918202060597101883618323097768155200270442748875668 * α ^ 35 + 1450861895455204845787988647170733163350496179912678839329200986510884388428173389320127180407765638551 * α ^ 36 + 19698279579096177164787018164158789132912466550646401885212259058865017062230215250892367283766302154 * α ^ 37 - 57652053317489414390572934832324830300466266131622345505450510286650133357321127488185831111381791595 * α ^ 38 + 735839726136777192033003352499083088738558026604488978404480341017143472486567180936350888710307864 * α ^ 39 - 4556557091452941380040035385055147646930930624200910749123957637499614710015132762550103799821048 * α ^ 40 - 133385784303410256278801057965454595590178412725438433339158980224721485193506478868247418219456 * α ^ 41 - 3423096723020314850982421385371010756189634167048478694293828864372204445633272936186470719904 * α ^ 42 - 69804839903958953293946387520015029557798645931631581080348037608367532112774187909634522240 * α ^ 43 - 865452330871186953510596734828786492278941181396935228550729318386099014534564956306824064 * α ^ 44 + 6798618471243250403976624728656397719531634223766543816506986827945697172779099788420608 * α ^ 45 + 788561506471686257274486905164229697457259305541495354329419768350740667053416558054144 * α ^ 46 + 27404388758747154771370930189376580679701159098426606936627216153391035767084433846272 * α ^ 47 + 646649551478726098614980210707984819816807233831805276746361716798674738190577340416 * α ^ 48 + 11211130515851440319438235357551475100839553634180130203899774136494056161035911168 * α ^ 49 + 130654761491363390209265527305244677484674002463471732106539824077702885812797440 * α ^ 50 + 357370958717189390935129396104908992248522307474545437642970135644954582646784 * α ^ 51 - 29181736810016345568442240720495430859483450421903151495150669166766787592192 * α ^ 52 - 955989844135526470691849812345208816075517571032312722273829147296013484032 * α ^ 53 - 19693589749621923555627023816809550207524792367857705784556171741361864704 * α ^ 54 - 319527958823219288171919301676630081495413277792849934402743906350399488 * α ^ 55 - 4359916692864270231911575583538878442433933182393484084715401339994112 * α ^ 56 - 51487996872395271018065603117315986670053043845988016897449388933120 * α ^ 57 - 534287852041371238607889671805075544881560005268660814584293097472 * α ^ 58 - 4914742088163302214038533958003066516795399439930469941648556032 * α ^ 59 - 40286770643795091951577560453084774722804729349509280681689088 * α ^ 60 - 295170417808439805757992973335875121127546339919271705968640 * α ^ 61 - 1935804396482191076314681386409043851261791712104853536768 * α ^ 62 - 11366432523474642581662414816114955814707861565858643968 * α ^ 63 - 59703170845283859723339853111711322814822346376871936 * α ^ 64 - 280018128137086019618307155094771953353132297158656 * α ^ 65 - 1169385347161959260160465901639985114274911485952 * α ^ 66 - 4331161143994110763407260197680039459865755648 * α ^ 67 - 14153828793218044771011521216530198581739520 * α ^ 68 - 40537586126827346928475190951612417835008 * α ^ 69 - 100883783567908658123954038279633895424 * α ^ 70 - 215746527094612923562575346607849472 * α ^ 71 - 390762372880065519809958474940416 * α ^ 72 - 587839886222327464463148515328 * α ^ 73 - 714822291149465741724483584 * α ^ 74 - 675179423113136706682880 * α ^ 75 - 464818794079734202368 * α ^ 76 - 207493237324120064 * α ^ 77 - 45079976738816 * α ^ 78) = 25811606424535915506326543401482443660479168162161070878750987845784640947537512918254143661443967851841624182260454 * (17 - α) ^ 78 + 7731601171729754948302451858548754728747882021768914086305388067309744030714970733621715794196933994344449662661325888 * α ^ 1 * (17 - α) ^ 77 + 1134977739682559152144183344552781855394081041684581420063129512966886926387568279248276946977482731207073356960903835128 * α ^ 2 * (17 - α) ^ 76 + 108834637037659199091355921419729186300121822584927223690221434809345565260667023227379040139264943526676297937882231816944 * α ^ 3 * (17 - α) ^ 75 + 7666861356053587141879051542023151513155253675338534070219208289734940750831143744550245239925873313943561985580954527982616 * α ^ 4 * (17 - α) ^ 74 + 423077887233518864483787884707532169136310014420797711374285732639883356220901878487666885430844058504013013662258662655409024 * α ^ 5 * (17 - α) ^ 73 + 19043789756155440424344440725874751801324872083267566506068169098722085040014291705260338415543274194102043673327180400129929832 * α ^ 6 * (17 - α) ^ 72 + 718947188407260825753518059058500078605524217441449955961763119488742316279761434573371789300650648290365793225194740365639829248 * α ^ 7 * (17 - α) ^ 71 + 23229944260791702898096600141389848573573933604759267334016067683455922366132699662001188778646003391197287922373361993488875467772 * α ^ 8 * (17 - α) ^ 70 + 652356286335394807010040506322513589425276848772982033180582110575315337819948577150432209238058606495049799638171924460488723115728 * α ^ 9 * (17 - α) ^ 69 + 16115244618115471773154398428945842467530527293496478962865411951374999566160962962621541576431428483629410984630108362973322526046352 * α ^ 10 * (17 - α) ^ 68 + 353590213705899227670735133595068406610777044757491438541768497813388671143323439181516543806998722646874310797601900004357046159618416 * α ^ 11 * (17 - α) ^ 67 + 6945545366374205473681219757999841297413797165201420435841487238189483615527433260434909542451873571311839418856181380505673028690189834 * α ^ 12 * (17 - α) ^ 66 + 122943429683776586616098034509418349763379413100200501385374144116228404023652411356804056379171036434910191105635835310497125437439368616 * α ^ 13 * (17 - α) ^ 65 + 1971943361675961854095978497179540085473722438976489160404258526153302499359290412285125679239602051452003303294340674036438891755271461344 * α ^ 14 * (17 - α) ^ 64 + 28794613849932432807185452777239504156831844265536120723695409096275314438957801587812894208037520422020805646713238048377079475740273188040 * α ^ 15 * (17 - α) ^ 63 + 384328560383502952032438759151017028938946671283519542604007361014389867788722109711367554903315805912734859044701209907625689918745997497675 * α ^ 16 * (17 - α) ^ 62 + 4705189064883150340603293176324983232690962514057066121441689655603425308970643761709274220489500917477746179322066734647863357743464493676520 * α ^ 17 * (17 - α) ^ 61 + 52996214890563273796160643818818348185528424059725114966862380369319342813162215520720537479664066314153467772804561608859372679443782254992220 * α ^ 18 * (17 - α) ^ 60 + 550617253247385218427009607064332121441409621321669095638902982534390077955117952713512591688404159855259550612508039696237055140143912070148080 * α ^ 19 * (17 - α) ^ 59 + 5289254261689909642998694788883801072432560837908488801188757508626280600068147475966012413534329068218714313264686298658627525464990766966507480 * α ^ 20 * (17 - α) ^ 58 + 47071723811940484288699822861559515707560341788285556322087973575337149744998528596195569152380487445854405880284205334835719251975349528608895960 * α ^ 21 * (17 - α) ^ 57 + 388797566873530668184175407886161066305517869569175948336046190337058590155012538967688933864691298489884730691529378580953514253496007438959580140 * α ^ 22 * (17 - α) ^ 56 + 2985179603519724471752085802643613314281923391910045186703182258691770626157427630859816171548924404331298520035371797680826375874045307985095169160 * α ^ 23 * (17 - α) ^ 55 + 21335697765899092801522874710986881769845405599093285192366939176739104568310936178280383293402533817032054113166202401026875457402502001299016941965 * α ^ 24 * (17 - α) ^ 54 + 142124309577284830558031748098405686449899656084274181428411809022465874914849955156662717515516567844716088626134776657964597427502198457271981932744 * α ^ 25 * (17 - α) ^ 53 + 883340987406927324886485469060737975106344280304169568718286595798294963628744880539858577253973934458679980792763078663809587077960963632717815152096 * α ^ 26 * (17 - α) ^ 52 + 5127488920008786553466393714789905427388213762697569627668475082844096754564454348757229349829628841608199919978811602705936439756284569017181261626624 * α ^ 27 * (17 - α) ^ 51 + 27820537271116488598533849210418200371695645263092839593736637431588817343110855564285745636333362483896532668071984474388396970246448477332845548675696 * α ^ 28 * (17 - α) ^ 50 + 141199792955232750444991232388282777593870842150187857240279059394142520379652599318770827523191507794494653442014857111518160506592547548123217567703264 * α ^ 29 * (17 - α) ^ 49 + 670800231791884784143046690550307121328633658472928365947843469281367978857427131528889056504264285777346962640789773628915428849835988530657823235764048 * α ^ 30 * (17 - α) ^ 48 + 2984619384354511629107356504926848471696327337771023943436513427949142667105830054851593100735343248824065325292573736440802608827461183426769246769291552 * α ^ 31 * (17 - α) ^ 47 + 12443245301685101113004238920453035362065480822223920063453295700954394658154324530222082866216981544902180469303864185921832037521423470739534568240530698 * α ^ 32 * (17 - α) ^ 46 + 48630498545566508730887646850031839032254744413887093356079449812021579883240090827460324033575160396265167473696926411553805741150177366589537208618389312 * α ^ 33 * (17 - α) ^ 45 + 178224283616173729873597347832665682938537443237014013583101955743465983895935219727459727536113766122912311165368553083312822196229416994722881465788897608 * α ^ 34 * (17 - α) ^ 44 + 612680644790166184991917379793912279464385512434753774369824036938764938304766938235637731701416442390635006960662151462757565543096111536600700611590433104 * α ^ 35 * (17 - α) ^ 43 + 1976111675207627574170813927131479302618451807610755803915352844606204227936969836964454024080255606582154150762724021578810678171015308008029327160761230036 * α ^ 36 * (17 - α) ^ 42 + 5981029220510678070817415728895653202641308066347103599758984876348600755271333269460791392164878746120136312582494705765569069531832293963655323002573446064 * α ^ 37 * (17 - α) ^ 41 + 16989543154359445469457986390510733383994704572611451201272330066228088393042712150225004932550683152805630464909266619414416501639238958482074875942132768616 * α ^ 38 * (17 - α) ^ 40 + 45296105880774016543608993638859556610721433636610042456973317141222907592128054856106393044377927691870302622862352603383769755644737397448590274359670368944 * α ^ 39 * (17 - α) ^ 39 + 113350571234050534076326107126518287982410454182311080227306939093496067875998083564452872849439161949940409925105928531974054521742151944897862268669201061520 * α ^ 40 * (17 - α) ^ 38 + 266231157835868807500470306762042513611189637040966950733290536030191636687157078964587562059672497373973922906293139029665558703936748610317140546883955859680 * α ^ 41 * (17 - α) ^ 37 + 586858197296154628798446528461843998024068971134701870886809269117315332250708613879369916177860732342900319979198468207186334042554992489311324197461026564960 * α ^ 42 * (17 - α) ^ 36 + 1213922719117161670068732317088234253543419578795181021310311760507171888098020651110360608663151069102950683003635002998812668248827290683460647339113637593920 * α ^ 43 * (17 - α) ^ 35 + 2355882656955618145368440772792310544302184458306643829069873721060849050791043491096322023978836887243291929862008841402040135117369951147006375023758607414630 * α ^ 44 * (17 - α) ^ 34 + 4288620425723236042270245525821460550276787699330226001900869309698399107377083284501409207640281375703914610994654965609663507351571250965113379319161632928200 * α ^ 45 * (17 - α) ^ 33 + 7320707928796224459121297405137632144399624953401924235118562284160734706017732510625383671234631311037891028803627184501344210399941335731279835946303059679200 * α ^ 46 * (17 - α) ^ 32 + 11713899213743447915704134395332202117298482214292060770979810663078726380483695637745416926561937897954981745807583035850470327859420144985559683638576277883400 * α ^ 47 * (17 - α) ^ 31 + 17561942867533342398436880431957294329537588050449243474998468656204324106460768754190028781389060814644401148893175783608534017391500137587346401404729767961775 * α ^ 48 * (17 - α) ^ 30 + 24657037500931233931100038936709405139583850503696185642594534868113339647480541733889215934553454050856843493087316935868401534155234466743591899388039722825000 * α ^ 49 * (17 - α) ^ 29 + 32399766183005623339431502134384903673258583171905972220491732685551275126382181817021974632337480906159861245942216595446130287593916379360777739204014519763740 * α ^ 50 * (17 - α) ^ 28 + 39816869923705792061452702806451616229648477329837692188071941553276215504100718506084662900753752185561490136348790335058840343832503703423988939862391056305232 * α ^ 51 * (17 - α) ^ 27 + 45725596948318007559653827457799417148215312861758852406937933348972792240139365978502472349006051930446814676684606316211695543376347509599898036528286933085224 * α ^ 52 * (17 - α) ^ 26 + 49023805818598732375036617236844617864434596645116211451566972339635320087833097798204901700925015829301327369649045560010979770125252618435350703761516463073848 * α ^ 53 * (17 - α) ^ 25 + 49015998485968580948941115202148896246224655491148535539418948950288060451674238170130060593823432628223618516376352101072100358750709310490151188159024541427052 * α ^ 54 * (17 - α) ^ 24 + 45647022194403892164725670688230786593406330796296866532743501180312044777291667628466008426907011381782621245185421119984904334692872397917622931589975159950376 * α ^ 55 * (17 - α) ^ 23 + 39538178387322663214678107833346063706962357676818250082020803464382411757712672815180178231414974228300278324399692737955948708504923951831175084051680088175165 * α ^ 56 * (17 - α) ^ 22 + 31801899439090094777334950705334813338730886166159685008908427150218448246372446469199745436135611138307188820293411565869844276004036024233170865193572905525320 * α ^ 57 * (17 - α) ^ 21 + 23709975953138035217254879474127618178276877789282349375912411789239026737801814945663600235688954031236781561111671014867771739568818009667175830050625483670800 * α ^ 58 * (17 - α) ^ 20 + 16351417027375290237568460048941744283542362032677807325524002415873874456253818166492303955129235315728196511827486827201910640986408449258178453972071138841280 * α ^ 59 * (17 - α) ^ 19 + 10406661000804048469244285454442048401950551096021855689021431743408141364929640862344616974092488532662628383447959199105412832327366951066981956912776793272828 * α ^ 60 * (17 - α) ^ 18 + 6096044218883636648858638385299408772703826861168771488836313560232401989614872890471308028293712697562093239071809816669597593582410767226213878470560164105360 * α ^ 61 * (17 - α) ^ 17 + 3276846591075729012589755509945912260769516795393912260645693976533757884223032498368536502265562067479892796636427846477439354731388021106706514152220778103040 * α ^ 62 * (17 - α) ^ 16 + 1610794513834802575152755949091561602421721957898331237110261276182871154723607727539375914584552916560724124724924463417208104868865606317263016841364405825680 * α ^ 63 * (17 - α) ^ 15 + 721246729451681999848797234165823691040492879910986098969913863731997028544659333437426233091222522940845475324110626012544305358208410635315439163726896332470 * α ^ 64 * (17 - α) ^ 14 + 292822391376166813009638824792532072858861097043830666638215128792614436289145455232446359525025830476319501900465615628266091285776053359537792998581547295600 * α ^ 65 * (17 - α) ^ 13 + 107224012150816902001912227507553282916599557139225796253173519533916191353535425807887044534914331713036619424330904015814415822193999401215526600838512604840 * α ^ 66 * (17 - α) ^ 12 + 35191006165935842226308618125286667631304103617509372764131233521722150894012101410223152943777334278979699369241450735115442948195848108495015472586714890880 * α ^ 67 * (17 - α) ^ 11 + 10275267801259336459300721782985532390900842929751059267873958488400935538863318074454099079440422678680619531094605908728254236555735059631933624997615828260 * α ^ 68 * (17 - α) ^ 10 + 2645336786640622909024119594938504328204268908990167832700614571718874779959845931540799248941313778802020955617601042505306160484123987291058458612715400640 * α ^ 69 * (17 - α) ^ 9 + 593906665872865965150458489550777045487297564791632460724893427149867065488464014938181589464594007951273185164028728407261435342265396855306832150409931320 * α ^ 70 * (17 - α) ^ 8 + 114690263695272628709900519325805172252624298016857930148989306502982113118510158582594826209607467459228127771008256970868516723274528081539115152119985440 * α ^ 71 * (17 - α) ^ 7 + 18716846109423476071035991682553676602728521782795818848220231089640237632710705010278610380508724798549109713393602376467223809385880736717949117062987530 * α ^ 72 * (17 - α) ^ 6 + 2521536870830508163836030824568047223988339893444693792826398274518701446642999471126321332113161322019782540488604986950909127037746871670766269501360960 * α ^ 73 * (17 - α) ^ 5 + 271493817296270881805641386430241155441908017852388246927155500054431367358594643258294586467756369131577116044199352316870588393438911740552090772405440 * α ^ 74 * (17 - α) ^ 4 + 22279566970411804598533929895269272846291071572877769238590666634237638229153811201206324018077221933863978836996195706320785275148859533443992017146000 * α ^ 75 * (17 - α) ^ 3 + 1291912491540789931050578781552895013123449146872856063262109993503327217135399912381220941445555078359565379700265238460988056930139111470428573934100 * α ^ 76 * (17 - α) ^ 2 + 46088990360704592332570841005323881782750533628800932523924974522918510553541700882043059731976492164473134284830339681303220274485070007892391252000 * α ^ 77 * (17 - α) ^ 1 + 725258734923967308075393848591202551763398627116692128836036203184259468021639559495815066910705200892668021559827725204513110094309349741193210000 * α ^ 78 := by - ring + bernstein_ring α (17 - α) -- The Bernstein summands are nonnegative. If α > 0 the last one is positive; -- at α = 0 the first one is positive. No per-coefficient hypotheses are needed. bernstein_cert α (17 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 80 ≤ n) (h1 : n ≤ 100) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (100 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (100 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 80) (n := n) (n₁ := 100) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((80 : ℕ) : ℝ) - 4 = 76 by norm_num] at hb - rw [show (76 : ℝ) / 2 = ((38 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 79) + 1 / (4 * 79 * (3 + α)) + (1 - 2 * α / 99) ^ 2 * 100 * 99 * (100 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 79 * (3 + α)) ^ 38)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 80 ≤ n) (h1 : n ≤ 100) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 80) (n₁ := 100) (k := 38) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B80_100 diff --git a/Sendov/FiniteRange/Degree8_9.lean b/Sendov/FiniteRange/Degree8_9.lean index 19fce56..f05501f 100644 --- a/Sendov/FiniteRange/Degree8_9.lean +++ b/Sendov/FiniteRange/Degree8_9.lean @@ -6,6 +6,9 @@ Authors: Terence Tao import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch 8 to 9 @@ -63,19 +66,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 8) (gg1 8) (gg2 8) 2)) α := by - refine pev_wsum_eq_of_packed (gg0 8) (gg1 8) (gg2 8) 2 7 Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 8) (gg1 8) (gg2 8) 2 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 8) (gg1 8) (gg2 8) 2 Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 8) (gg1 8) (gg2 8) 3 (by simp) (by simp) (by simp) 2) - · rfl + refine pev_moment_eq_of_packed_bounds 8 2 Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q 8 α t ^ 2) @@ -90,7 +85,7 @@ lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 4) : 0 < 656208 + 407736 * α - 877827 * α ^ 2 + 621074 * α ^ 3 - 39267 * α ^ 4 - 5436 * α ^ 5 - 180 * α ^ 6 := by have hu : (0 : ℝ) ≤ 4 - α := by linarith have hid : (4 : ℝ) ^ 6 * (656208 + 407736 * α - 877827 * α ^ 2 + 621074 * α ^ 3 - 39267 * α ^ 4 - 5436 * α ^ 5 - 180 * α ^ 6) = 656208 * (4 - α) ^ 6 + 5568192 * α ^ 1 * (4 - α) ^ 5 + 3952608 * α ^ 2 * (4 - α) ^ 4 + 13001408 * α ^ 3 * (4 - α) ^ 3 + 51075024 * α ^ 4 * (4 - α) ^ 2 + 49486080 * α ^ 5 * (4 - α) ^ 1 + 11634560 * α ^ 6 := by - ring + bernstein_ring α (4 - α) -- The Bernstein summands are nonnegative. If α > 0 the last one is positive; -- at α = 0 the first one is positive. No per-coefficient hypotheses are needed. bernstein_cert α (4 - α) using hid @@ -107,13 +102,6 @@ theorem finite_range {n : ℕ} (h0 : 8 ≤ n) (h1 : n ≤ 9) {α : ℝ} have hcast : ((n : ℕ) : ℝ) ≤ (9 : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ (9 : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := 8) (n := n) (n₁ := 9) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show ((8 : ℕ) : ℝ) - 4 = 4 by norm_num] at hb - rw [show (4 : ℝ) / 2 = ((2 : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, M_lo, M_hi, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 7) + 1 / (4 * 7 * (3 + α)) + (1 - 2 * α / 8) ^ 2 * 9 * 8 * (9 - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * 7 * (3 + α)) ^ 2)) @@ -122,9 +110,10 @@ theorem finite_range {n : ℕ} (h0 : 8 ≤ n) (h1 : n ≤ 9) {α : ℝ} push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := 8) (n₁ := 9) (k := 2) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B8_9 diff --git a/Sendov/FiniteRange/PackedMomentCertificate.lean b/Sendov/FiniteRange/PackedMomentCertificate.lean new file mode 100644 index 0000000..c679baa --- /dev/null +++ b/Sendov/FiniteRange/PackedMomentCertificate.lean @@ -0,0 +1,42 @@ +/- +Copyright (c) 2026 Terence Tao. All rights reserved. +Released under Apache 2.0 license as described in the file LICENSE. +Authors: Terence Tao +-/ +import Sendov.FiniteRange.PackBridge + +/-! +# Numeric conditions for a packed batch moment + +The analytic recurrence bounds discharge the true row obligations uniformly. +Each batch still supplies its exact numerator and kernel-checked packed equality. +-/ + +namespace Sendov + +/-- Numeric overflow and length bounds suffice to verify a supplied moment numerator. +The three recurrence multipliers have length at most three, so the true weighted row +has length at most `1 + 3*k`. Its coefficients and packed row are bounded analytically; +only the supplied numerator and the single packed equality are computed by the caller. +Trailing zeros are permitted, and no recurrence row needs to be expanded. -/ +theorem pev_moment_eq_of_packed_bounds (n k : ℕ) (L β τ : ℤ) (Nmom : List ℤ) + (hL : 0 ≤ L) (hβ : 1 ≤ β) (hτ : 0 < τ) + (hrow : 2 * ((l1 (gg0 n) + l1 (gg1 n) + l1 (gg2 n)) ^ k + * β ^ (1 + 3 * k)) < τ) + (hweight : 2 * (L * (l1 (gg0 n) + l1 (gg1 n) + l1 (gg2 n)) ^ k) < β) + (hN : ∀ a ∈ Nmom, 2 * |a| < β) (hlen : Nmom.length ≤ 1 + 3 * k) + (hcheck : wsumZ L 0 (unpackZ τ (2 * k + 1) + ((pevZ (gg0 n) β + pevZ (gg1 n) β * τ + pevZ (gg2 n) β * τ ^ 2) ^ k)) + = pevZ Nmom β) (α : ℝ) : + pev Nmom α = pev (wsum L 0 (qrow (gg0 n) (gg1 n) (gg2 n) k)) α := by + refine pev_wsum_eq_of_packed (gg0 n) (gg1 n) (gg2 n) k (1 + 3 * k) + L β τ Nmom (by omega) hτ ?_ hN ?_ hlen ?_ ?_ α + · exact rowZ_bound (gg0 n) (gg1 n) (gg2 n) k 3 β τ hβ + (by simp) (by simp) (by simp) hrow + · exact wsum_bound (gg0 n) (gg1 n) (gg2 n) k L β hL hweight + · exact wsum_length_le L _ 0 + (qrow_entry_length_le (gg0 n) (gg1 n) (gg2 n) 3 + (by simp) (by simp) (by simp) k) + · simpa only [qrow_length] using hcheck + +end Sendov diff --git a/Sendov/LargeDegree/Endgame.lean b/Sendov/LargeDegree/Endgame.lean index ea2e0b6..864071f 100644 --- a/Sendov/LargeDegree/Endgame.lean +++ b/Sendov/LargeDegree/Endgame.lean @@ -5,6 +5,7 @@ Authors: Terence Tao -/ import Sendov.LargeDegree.Monotone import Sendov.Common.BernsteinCert +import Sendov.Common.BernsteinRing /-! # The large-degree claim @@ -55,7 +56,7 @@ lemma F_pos (hα : 0 ≤ α) (hα' : α ≤ 17) : 0 < 1122702787291394736448332031899900000000 + 19046325083555631071589567727384404000000 * α + 158421799401305511319831453323336122340000 * α ^ 2 + 861086144839783899262522290902928965732400 * α ^ 3 + 3439408019860839882261371580238947745811319 * α ^ 4 + 10763976190978343059270128976319908699279230 * α ^ 5 + 27482264870203746404049226779511973140100922 * α ^ 6 + 58851751350273881387953189525455032864879976 * α ^ 7 + 107855247587877306122230293103712405510570475 * α ^ 8 + 171759728691636266490365540891679381811794330 * α ^ 9 + 240529488382582584529650966973246412375404200 * α ^ 10 + 299026713527922503750214218383542861883052640 * α ^ 11 + 332584383792637363818110693156644176263245770 * α ^ 12 + 333049929303875184857821696251322094451555300 * α ^ 13 + 301880762905153988961008260011013859110924020 * α ^ 14 + 248778383542817950458457719347804130388393200 * α ^ 15 + 187098708657492312991354787006951375606496810 * α ^ 16 + 128821377534531366266108990532541378516293180 * α ^ 17 + 81419630849957631346647265524754482691775400 * α ^ 18 + 47345231058420765609063602657623737762737040 * α ^ 19 + 25377634631717199993415818405387727249820325 * α ^ 20 + 12558381461678887884336588690871882873720170 * α ^ 21 + 5744808624780589326694261819822529221060710 * α ^ 22 + 2431706095253331452737540626239749451182200 * α ^ 23 + 953157993950838580367703259303917955151865 * α ^ 24 + 346144642670223976596034179062502690180750 * α ^ 25 + 116495518414609472010567246197077176778320 * α ^ 26 + 36336281152740288609221052030650841399360 * α ^ 27 + 10502010275079971287850469706276099760700 * α ^ 28 + 2811408048396859598615803016678577566616 * α ^ 29 + 696637045577195749563697260889295071320 * α ^ 30 + 159631247175312590035611267009797954208 * α ^ 31 + 33785522480785269776966858820750983964 * α ^ 32 + 6594450665275339854415586104207300200 * α ^ 33 + 1184779969344702509178802875319571760 * α ^ 34 + 195478905533580848831244517654808400 * α ^ 35 + 29535092351319878473338799170306705 * α ^ 36 + 4072478636506932555839271140088690 * α ^ 37 + 510306927013451786184096375133350 * α ^ 38 + 57808428584128470185954723726040 * α ^ 39 + 5881482509330352987406470588525 * α ^ 40 + 532894392271418064251604942870 * α ^ 41 + 42515012647728027357611076360 * α ^ 42 + 2939585612233076406278632800 * α ^ 43 + 171946491190832176774496730 * α ^ 44 + 8163588014241841361016900 * α ^ 45 + 287999399301298111575540 * α ^ 46 + 5555726484083859953520 * α ^ 47 - 536551383276446293350 * α ^ 48 - 269167118332858968420 * α ^ 49 - 48279425158933803000 * α ^ 50 - 1759012112154436560 * α ^ 51 + 273395914772406495 * α ^ 52 + 6240162359537050 * α ^ 53 - 1129204084343291 * α ^ 54 + 41554143448524 * α ^ 55 - 721404477395 * α ^ 56 + 6229533730 * α ^ 57 - 21627837 * α ^ 58 := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ 58 * (1122702787291394736448332031899900000000 + 19046325083555631071589567727384404000000 * α + 158421799401305511319831453323336122340000 * α ^ 2 + 861086144839783899262522290902928965732400 * α ^ 3 + 3439408019860839882261371580238947745811319 * α ^ 4 + 10763976190978343059270128976319908699279230 * α ^ 5 + 27482264870203746404049226779511973140100922 * α ^ 6 + 58851751350273881387953189525455032864879976 * α ^ 7 + 107855247587877306122230293103712405510570475 * α ^ 8 + 171759728691636266490365540891679381811794330 * α ^ 9 + 240529488382582584529650966973246412375404200 * α ^ 10 + 299026713527922503750214218383542861883052640 * α ^ 11 + 332584383792637363818110693156644176263245770 * α ^ 12 + 333049929303875184857821696251322094451555300 * α ^ 13 + 301880762905153988961008260011013859110924020 * α ^ 14 + 248778383542817950458457719347804130388393200 * α ^ 15 + 187098708657492312991354787006951375606496810 * α ^ 16 + 128821377534531366266108990532541378516293180 * α ^ 17 + 81419630849957631346647265524754482691775400 * α ^ 18 + 47345231058420765609063602657623737762737040 * α ^ 19 + 25377634631717199993415818405387727249820325 * α ^ 20 + 12558381461678887884336588690871882873720170 * α ^ 21 + 5744808624780589326694261819822529221060710 * α ^ 22 + 2431706095253331452737540626239749451182200 * α ^ 23 + 953157993950838580367703259303917955151865 * α ^ 24 + 346144642670223976596034179062502690180750 * α ^ 25 + 116495518414609472010567246197077176778320 * α ^ 26 + 36336281152740288609221052030650841399360 * α ^ 27 + 10502010275079971287850469706276099760700 * α ^ 28 + 2811408048396859598615803016678577566616 * α ^ 29 + 696637045577195749563697260889295071320 * α ^ 30 + 159631247175312590035611267009797954208 * α ^ 31 + 33785522480785269776966858820750983964 * α ^ 32 + 6594450665275339854415586104207300200 * α ^ 33 + 1184779969344702509178802875319571760 * α ^ 34 + 195478905533580848831244517654808400 * α ^ 35 + 29535092351319878473338799170306705 * α ^ 36 + 4072478636506932555839271140088690 * α ^ 37 + 510306927013451786184096375133350 * α ^ 38 + 57808428584128470185954723726040 * α ^ 39 + 5881482509330352987406470588525 * α ^ 40 + 532894392271418064251604942870 * α ^ 41 + 42515012647728027357611076360 * α ^ 42 + 2939585612233076406278632800 * α ^ 43 + 171946491190832176774496730 * α ^ 44 + 8163588014241841361016900 * α ^ 45 + 287999399301298111575540 * α ^ 46 + 5555726484083859953520 * α ^ 47 - 536551383276446293350 * α ^ 48 - 269167118332858968420 * α ^ 49 - 48279425158933803000 * α ^ 50 - 1759012112154436560 * α ^ 51 + 273395914772406495 * α ^ 52 + 6240162359537050 * α ^ 53 - 1129204084343291 * α ^ 54 + 41554143448524 * α ^ 55 - 721404477395 * α ^ 56 + 6229533730 * α ^ 57 - 21627837 * α ^ 58) = 1122702787291394736448332031899900000000 * (17 - α) ^ 58 + 388904288083346622931025909215729068000000 * α ^ 1 * (17 - α) ^ 57 + 66095616740335374779150673987010161532260000 * α ^ 2 * (17 - α) ^ 56 + 7345821640480281350499142140546658776321841200 * α ^ 3 * (17 - α) ^ 55 + 600398748030850807066041679815685800572608040199 * α ^ 4 * (17 - α) ^ 54 + 38479987967757849353019399973163199134827376858856 * α ^ 5 * (17 - α) ^ 53 + 2013648131786096177205150562840212460891734276215217 * α ^ 6 * (17 - α) ^ 52 + 88459088337848664272764574750756035751708812314589560 * α ^ 7 * (17 - α) ^ 51 + 3328752627388631431253304215842302161184427248710824200 * α ^ 8 * (17 - α) ^ 50 + 108955148579598077254581984889507974501857717600550300000 * α ^ 9 * (17 - α) ^ 49 + 3139320986827193043298955183356728835782414071606732250000 * α ^ 10 * (17 - α) ^ 48 + 80389849002074687648105368735226451202772917094058768000000 * α ^ 11 * (17 - α) ^ 47 + 1843869779817877110104286469976591396926664444962705440000000 * α ^ 12 * (17 - α) ^ 46 + 38126021284745149595963616317393007484187425284263404800000000 * α ^ 13 * (17 - α) ^ 45 + 714519722771974812940511821448225512188719319523829280000000000 * α ^ 14 * (17 - α) ^ 44 + 12192162072496626088921760868440507818256588279501222400000000000 * α ^ 15 * (17 - α) ^ 43 + 190149195298252798424521646382266997826378949113808102400000000000 * α ^ 16 * (17 - α) ^ 42 + 2719453325782140875058402865898661993411332371079473152000000000000 * α ^ 17 * (17 - α) ^ 41 + 35765156781668343145270939254204039481078844597447447040000000000000 * α ^ 18 * (17 - α) ^ 40 + 433581369383490123337920330591320005197369743601113088000000000000000 * α ^ 19 * (17 - α) ^ 39 + 4855120840322429070915669670313005676027625016591872000000000000000000 * α ^ 20 * (17 - α) ^ 38 + 50303800927352895844904371767120477621293024508175810560000000000000000 * α ^ 21 * (17 - α) ^ 37 + 482953904720497092819809519030958414936076990756461772800000000000000000 * α ^ 22 * (17 - α) ^ 36 + 4301697515309799266557277840727716853246295229412212736000000000000000000 * α ^ 23 * (17 - α) ^ 35 + 35582005974740842580199098139010545771216816653126860800000000000000000000 * α ^ 24 * (17 - α) ^ 34 + 273535549248031302586908863638264651412739231630163968000000000000000000000 * α ^ 25 * (17 - α) ^ 33 + 1955426273644204648009173651834541693843095232637140992000000000000000000000 * α ^ 26 * (17 - α) ^ 32 + 13004222926412994888311248631808734105341900865415413760000000000000000000000 * α ^ 27 * (17 - α) ^ 31 + 80470387643773112884644249468688475191473557588882227200000000000000000000000 * α ^ 28 * (17 - α) ^ 30 + 463355476918012102672652719197790300193712035699097600000000000000000000000000 * α ^ 29 * (17 - α) ^ 29 + 2482344082055683113128185595725000998635940934141870080000000000000000000000000 * α ^ 30 * (17 - α) ^ 28 + 12369353793584370842106405783534323328114720329863004160000000000000000000000000 * α ^ 31 * (17 - α) ^ 27 + 57300834405504520484711032055319485636127102860053708800000000000000000000000000 * α ^ 32 * (17 - α) ^ 26 + 246613403330189144932245957910378250136137902552252416000000000000000000000000000 * α ^ 33 * (17 - α) ^ 25 + 985246695411671462829426238732411673050896371023872000000000000000000000000000000 * α ^ 34 * (17 - α) ^ 24 + 3649974776445129628396257437653948413551102593597440000000000000000000000000000000 * α ^ 35 * (17 - α) ^ 23 + 12522828085409243337307923676013931236910302987550720000000000000000000000000000000 * α ^ 36 * (17 - α) ^ 22 + 39731340789062838384502107867195079108983927708057600000000000000000000000000000000 * α ^ 37 * (17 - α) ^ 21 + 116365100653574128528674694068315721419971773857792000000000000000000000000000000000 * α ^ 38 * (17 - α) ^ 20 + 313971050757264181615490913824916376724876505907200000000000000000000000000000000000 * α ^ 39 * (17 - α) ^ 19 + 778602881203434272472350446775468799876667539456000000000000000000000000000000000000 * α ^ 40 * (17 - α) ^ 18 + 1769823234178269115425193251412793044953817153536000000000000000000000000000000000000 * α ^ 41 * (17 - α) ^ 17 + 3676061908648613727975384722760757591726652129280000000000000000000000000000000000000 * α ^ 42 * (17 - α) ^ 16 + 6952202666310032877475473290777345311129573785600000000000000000000000000000000000000 * α ^ 43 * (17 - α) ^ 15 + 11922241592723733002313059523572394705939333120000000000000000000000000000000000000000 * α ^ 44 * (17 - α) ^ 14 + 18450845478651168634684539530259247984017408000000000000000000000000000000000000000000 * α ^ 45 * (17 - α) ^ 13 + 25626302281194153741004424813630605199042150400000000000000000000000000000000000000000 * α ^ 46 * (17 - α) ^ 12 + 31735356381499745521943376637135285074788352000000000000000000000000000000000000000000 * α ^ 47 * (17 - α) ^ 11 + 34773986078859125604170241648646078618789153800477215677912265790935664780750000000000 * α ^ 48 * (17 - α) ^ 10 + 33406510810664082686608872230111026353099051641531587806834322064288344554180000000000 * α ^ 49 * (17 - α) ^ 9 + 27820946523539616021999756980494999341031737804699133246948994617042670678045550000000 * α ^ 50 * (17 - α) ^ 8 + 19791944456596303161181417657916215477628661862047060146272089595047078222827061000000 * α ^ 51 * (17 - α) ^ 7 + 11779484527176566489160923853925282151874607361320815965499241151163816336970531507500 * α ^ 52 * (17 - α) ^ 6 + 5685451710206041407628952698706724254113808400301600724661558108213464738446593549500 * α ^ 53 * (17 - α) ^ 5 + 2124220422337628714954562682925792634155465583908214661397004639843167881489238854787 * α ^ 54 * (17 - α) ^ 4 + 572909076732572616057605734230328840239193993814061157407956440967916397115623518120 * α ^ 55 * (17 - α) ^ 3 + 99530623246032452139763064572679576747235355843313027086842616874975359183988464200 * α ^ 56 * (17 - α) ^ 2 + 8820861539641882551843091227900257872626927159038875775406157756108783934565132000 * α ^ 57 * (17 - α) ^ 1 + 161598081294237579548393327166198311182821276785721838823669379905701080186270000 * α ^ 58 := by - ring + bernstein_ring α (17 - α) bernstein_cert α (17 - α) using hid set_option maxHeartbeats 4000000 in @@ -77,39 +78,51 @@ theorem Ut_lt_one (hα : 0 ≤ α) (hα' : α ≤ 17) : Ut α < 1 := by ring -- `(α/(3+α)) ^ 48` cancels against `(3+α) ^ 49` without expanding either have h48 : (α / (3 + α)) ^ 48 * (3 + α) ^ 49 = α ^ 48 * (3 + α) := by - rw [div_pow, show (3 + α) ^ 49 = (3 + α) ^ 48 * (3 + α) from by ring, ← mul_assoc, + rw [div_pow, pow_succ (3 + α) 48, ← mul_assoc, div_mul_cancel₀ _ (pow_ne_zero 48 h3.ne')] - -- the six terms of `Ut`, each multiplied by `D` + -- The six terms of `Ut`, each multiplied by `D`. Composite powers are kept + -- as scalar factors: cancel denominators first, then normalize only the coefficients. have t1 : (1 / 6 : ℝ) * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) = 144200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4 := by - ring + norm_num [← mul_assoc] have t2 : 1 / (4 * (3 + α)) * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) = 216300 * (3 + α) ^ 48 * (300 + 47 * α - α ^ 2) ^ 4 := by + rw [pow_succ (3 + α) 48] + -- Remove the single factor `3 + α`; the remaining powers stay opaque. + generalize (3 + α) ^ 48 = p, (300 + 47 * α - α ^ 2) ^ 4 = g field_simp ring have t3 : (1 / 200 : ℝ) * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) = 4326 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4 := by - ring + norm_num [← mul_assoc] have t4 : 1 / (400 * (3 + α)) * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) = 2163 * (3 + α) ^ 48 * (300 + 47 * α - α ^ 2) ^ 4 := by + rw [pow_succ (3 + α) 48] + -- Remove the single factor `3 + α`; the remaining powers stay opaque. + generalize (3 + α) ^ 48 = p, (300 + 47 * α - α ^ 2) ^ 4 = g field_simp ring have t5 : 101 / 100 * (1600000 * (100 - 2 * α) ^ 2 * (3 + α) ^ 3 / (721 * (300 + 47 * α - α ^ 2) ^ 4)) * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) = 1939200000 * (100 - 2 * α) ^ 2 * (3 + α) ^ 52 := by - -- cancel the γ⁴ syntactically; `field_simp` leaves a stray γ⁻¹ here - have hne : (721 : ℝ) * (300 + 47 * α - α ^ 2) ^ 4 ≠ 0 := - mul_ne_zero (by norm_num) (pow_ne_zero 4 hg.ne') - rw [show 101 / 100 * (1600000 * (100 - 2 * α) ^ 2 * (3 + α) ^ 3 - / (721 * (300 + 47 * α - α ^ 2) ^ 4)) * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) - = 1600000 * (100 - 2 * α) ^ 2 * (3 + α) ^ 3 - / (721 * (300 + 47 * α - α ^ 2) ^ 4) * (721 * (300 + 47 * α - α ^ 2) ^ 4) - * (1212 * (3 + α) ^ 49) from by ring, - div_mul_cancel₀ _ hne] + -- Combine exponents by `pow_add`, and cancel only the scalar denominator γ⁴. + rw [show (3 + α) ^ 52 = (3 + α) ^ 3 * (3 + α) ^ 49 from pow_add _ 3 49] + have hg4 := pow_ne_zero 4 hgne + generalize (100 - 2 * α) ^ 2 = a, (3 + α) ^ 3 = b, (3 + α) ^ 49 = p + generalize (300 + 47 * α - α ^ 2) ^ 4 = g at hg4 ⊢ + field_simp ring have t6 : (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * (α / (3 + α)) ^ 48 * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) = (21627837 / 4) * (100 - 2 * α) ^ 2 * α ^ 48 * (300 + 47 * α - α ^ 2) ^ 4 := by + -- First expose the paired powers so that `h48` cancels 48 denominator factors. rw [show (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * (α / (3 + α)) ^ 48 * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) = ((100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * (865200 * (300 + 47 * α - α ^ 2) ^ 4)) - * ((α / (3 + α)) ^ 48 * (3 + α) ^ 49) from by ring, h48] + * ((α / (3 + α)) ^ 48 * (3 + α) ^ 49) from by + -- This is only reassociation of scalar factors, not a polynomial identity. + generalize (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) = a, + (α / (3 + α)) ^ 48 = b, (3 + α) ^ 49 = p, + (300 + 47 * α - α ^ 2) ^ 4 = g + ring, h48] + -- Only one factor `3 + α` remains to cancel; do not expand α⁴⁸ or γ⁴. + generalize (100 - 2 * α) ^ 2 = a, α ^ 48 = p, (300 + 47 * α - α ^ 2) ^ 4 = g field_simp ring have hD : (0 : ℝ) < 865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4 := by diff --git a/scripts/emit_batch.py b/scripts/emit_batch.py index f3f8f2f..f26ba78 100644 --- a/scripts/emit_batch.py +++ b/scripts/emit_batch.py @@ -33,6 +33,9 @@ def poly(cs, var="α"): import Sendov.FiniteRange.Batch import Sendov.FiniteRange.PackBridge import Sendov.Common.BernsteinCert +import Sendov.FiniteRange.BatchCertificate +import Sendov.FiniteRange.PackedMomentCertificate +import Sendov.Common.BernsteinRing /-! # The batch {n0} to {n1} @@ -90,19 +93,11 @@ def Nmomc : List ℤ := theorem pev_Nmomc (α : ℝ) : pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 {n0}) (gg1 {n0}) (gg2 {n0}) {k})) α := by - refine pev_wsum_eq_of_packed (gg0 {n0}) (gg1 {n0}) (gg2 {n0}) {k} {mlen} Lc betac - tauc Nmomc (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ ?_ ?_ ?_ ?_ α - · refine rowZ_bound (gg0 {n0}) (gg1 {n0}) (gg2 {n0}) {k} 3 betac tauc - (by norm_num [betac]) (by simp) (by simp) (by simp) ?_ - norm_num [gg0, gg1, gg2, l1, betac, tauc] - · decide - · refine wsum_bound (gg0 {n0}) (gg1 {n0}) (gg2 {n0}) {k} Lc betac - (by norm_num [Lc]) ?_ - norm_num [gg0, gg1, gg2, l1, Lc, betac] - · decide - · exact wsum_length_le Lc _ 0 - (qrow_entry_length_le (gg0 {n0}) (gg1 {n0}) (gg2 {n0}) 3 (by simp) (by simp) (by simp) {k}) - · rfl + refine pev_moment_eq_of_packed_bounds {n0} {k} Lc betac tauc Nmomc + (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ + (by decide) (by decide) (by rfl) α + · norm_num [gg0, gg1, gg2, l1, betac, tauc] + · norm_num [gg0, gg1, gg2, l1, Lc, betac] theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : (∫ t in (0 : ℝ)..1, t ^ 3 * Q {n0} α t ^ {k}) @@ -117,7 +112,7 @@ def Nmomc : List ℤ := 0 < {P} := by have hu : (0 : ℝ) ≤ {LIN0} := by linarith have hid : ({up} : ℝ) ^ {d} * ({P}) = {bern} := by - ring + bernstein_ring α {LIN} -- The certificate checks coefficient signs. The last summand is positive for α > 0; -- at α = 0 the first summand is positive. The identity above checks every coefficient. bernstein_cert α {LIN} using hid @@ -134,13 +129,6 @@ def Nmomc : List ℤ := have hcast : ((n : ℕ) : ℝ) ≤ ({n1} : ℝ) := by exact_mod_cast h1 have hMle : M n ≤ ({n1} : ℝ) - 1 := by simp only [M]; linarith linarith [_hα'] - have hb := R_le_batch (n₀ := {n0}) (n := n) (n₁ := {n1}) (by norm_num) h0 h1 hα - (c_lo_nonneg hα hUn) hfeas - rw [show (({n0} : ℕ) : ℝ) - 4 = {n0-4} by norm_num] at hb - rw [show ({n0-4} : ℝ) / 2 = (({k} : ℕ) : ℝ) by norm_num] at hb - simp only [Real.rpow_natCast] at hb - rw [integral_lo α hα, {MRW}, A_hi] at hb - push_cast at hb have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * {M0}) + 1 / (4 * {M0} * (3 + α)) + (1 - 2 * α / {M1}) ^ 2 * {n1} * {M1} * ({n1} - 2) / (4 * (3 + α)) * (pev Nmomc α / ((Lc : ℝ) * (2 * {M0} * (3 + α)) ^ {k})) @@ -149,9 +137,10 @@ def Nmomc : List ℤ := push_cast field_simp ring - rw [hid] at hb - have hP := P_pos hα hUn - exact hb.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) + exact R_lt_one_of_batch_certificate (n₀ := {n0}) (n₁ := {n1}) (k := {k}) + (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas + (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) + hid (P_pos hα hUn) (by positivity) end B{n0}_{n1} diff --git a/scripts/gen_endgame.py b/scripts/gen_endgame.py index 1577560..45519e4 100644 --- a/scripts/gen_endgame.py +++ b/scripts/gen_endgame.py @@ -1,4 +1,4 @@ -import sympy as sp, io +import sympy as sp a = sp.symbols('a') g = 300 + 47*a - a**2 @@ -94,6 +94,7 @@ def poly(cs, var="α"): -/ import Sendov.LargeDegree.Monotone import Sendov.Common.BernsteinCert +import Sendov.Common.BernsteinRing /-! # The large-degree claim @@ -144,7 +145,7 @@ def poly(cs, var="α"): 0 < {P} := by have hu : (0 : ℝ) ≤ 17 - α := by linarith have hid : (17 : ℝ) ^ {d} * ({P}) = {bern} := by - ring + bernstein_ring α (17 - α) bernstein_cert α (17 - α) using hid set_option maxHeartbeats 4000000 in @@ -166,39 +167,51 @@ def poly(cs, var="α"): ring -- `(α/(3+α)) ^ 48` cancels against `(3+α) ^ 49` without expanding either have h48 : (α / (3 + α)) ^ 48 * (3 + α) ^ 49 = α ^ 48 * (3 + α) := by - rw [div_pow, show (3 + α) ^ 49 = (3 + α) ^ 48 * (3 + α) from by ring, ← mul_assoc, + rw [div_pow, pow_succ (3 + α) 48, ← mul_assoc, div_mul_cancel₀ _ (pow_ne_zero 48 h3.ne')] - -- the six terms of `Ut`, each multiplied by `D` + -- The six terms of `Ut`, each multiplied by `D`. Composite powers are kept + -- as scalar factors: cancel denominators first, then normalize only the coefficients. have t1 : (1 / 6 : ℝ) * ({DD}) = {k16} * (3 + α) ^ 49 * {G4} := by - ring + norm_num [← mul_assoc] have t2 : 1 / (4 * (3 + α)) * ({DD}) = {k4} * (3 + α) ^ 48 * {G4} := by + rw [pow_succ (3 + α) 48] + -- Remove the single factor `3 + α`; the remaining powers stay opaque. + generalize (3 + α) ^ 48 = p, {G4} = g field_simp ring have t3 : (1 / 200 : ℝ) * ({DD}) = {k200} * (3 + α) ^ 49 * {G4} := by - ring + norm_num [← mul_assoc] have t4 : 1 / (400 * (3 + α)) * ({DD}) = {k400} * (3 + α) ^ 48 * {G4} := by + rw [pow_succ (3 + α) 48] + -- Remove the single factor `3 + α`; the remaining powers stay opaque. + generalize (3 + α) ^ 48 = p, {G4} = g field_simp ring have t5 : 101 / 100 * (1600000 * (100 - 2 * α) ^ 2 * (3 + α) ^ 3 - / (721 * (300 + 47 * α - α ^ 2) ^ 4)) * ({DD}) + / (721 * {G4})) * ({DD}) = {kT1} * (100 - 2 * α) ^ 2 * (3 + α) ^ 52 := by - -- cancel the γ⁴ syntactically; `field_simp` leaves a stray γ⁻¹ here - have hne : (721 : ℝ) * (300 + 47 * α - α ^ 2) ^ 4 ≠ 0 := - mul_ne_zero (by norm_num) (pow_ne_zero 4 hg.ne') - rw [show 101 / 100 * (1600000 * (100 - 2 * α) ^ 2 * (3 + α) ^ 3 - / (721 * (300 + 47 * α - α ^ 2) ^ 4)) * ({DD}) - = 1600000 * (100 - 2 * α) ^ 2 * (3 + α) ^ 3 - / (721 * (300 + 47 * α - α ^ 2) ^ 4) * (721 * (300 + 47 * α - α ^ 2) ^ 4) - * ({kT1div} * (3 + α) ^ 49) from by ring, - div_mul_cancel₀ _ hne] + -- Combine exponents by `pow_add`, and cancel only the scalar denominator γ⁴. + rw [show (3 + α) ^ 52 = (3 + α) ^ 3 * (3 + α) ^ 49 from pow_add _ 3 49] + have hg4 := pow_ne_zero 4 hgne + generalize (100 - 2 * α) ^ 2 = a, (3 + α) ^ 3 = b, (3 + α) ^ 49 = p + generalize {G4} = g at hg4 ⊢ + field_simp ring have t6 : (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * (α / (3 + α)) ^ 48 * ({DD}) = {kT2} * (100 - 2 * α) ^ 2 * α ^ 48 * {G4} := by + -- First expose the paired powers so that `h48` cancels 48 denominator factors. rw [show (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * (α / (3 + α)) ^ 48 * ({DD}) = ((100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * ({Lp} * {G4})) - * ((α / (3 + α)) ^ 48 * (3 + α) ^ 49) from by ring, h48] + * ((α / (3 + α)) ^ 48 * (3 + α) ^ 49) from by + -- This is only reassociation of scalar factors, not a polynomial identity. + generalize (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) = a, + (α / (3 + α)) ^ 48 = b, (3 + α) ^ 49 = p, + {G4} = g + ring, h48] + -- Only one factor `3 + α` remains to cancel; do not expand α⁴⁸ or γ⁴. + generalize (100 - 2 * α) ^ 2 = a, α ^ 48 = p, {G4} = g field_simp ring have hD : (0 : ℝ) < {DD} := by @@ -225,6 +238,15 @@ def poly(cs, var="α"): end Sendov ''' -io.open(r"c:/Users/teort/Github/sendov/Sendov/LargeDegree/Endgame.lean", "w", - encoding="utf-8", newline="\n").write(src) -print(f"written Endgame.lean, {len(src)} bytes") +# Resolve relative to this checkout; --output supports isolated regeneration checks. +import argparse +from pathlib import Path +parser = argparse.ArgumentParser() +parser.add_argument("--output", type=Path, + default=Path(__file__).resolve().parents[1] / "Sendov/LargeDegree/Endgame.lean", + help="Output Lean file; overwrites it if present. Default: this checkout's Endgame.lean.") +output = parser.parse_args().output +output.parent.mkdir(parents=True, exist_ok=True) +with output.open("w", encoding="utf-8", newline="\n") as stream: + stream.write(src) +print(f"written Endgame.lean, {len(src.encode('utf-8'))} bytes") From 69b560e72e2990a3ba38e169eab37389f4a87823 Mon Sep 17 00:00:00 2001 From: Methode Date: Sun, 13 Sep 2026 00:37:11 -0700 Subject: [PATCH 05/24] refactor(sendov): adopt verified cubic critical-point proof route --- .github/workflows/lean_action_ci.yml | 2 +- README.md | 362 +-- Sendov.lean | 74 - Sendov/Analytic/Polar.lean | 9 +- Sendov/Common/Basic.lean | 111 +- Sendov/Common/BernsteinList.lean | 31 + Sendov/Common/Chord.lean | 60 +- Sendov/Common/DistillationBounds.lean | 29 + Sendov/Common/DistillationCritical.lean | 513 +++ Sendov/Common/DistillationCriticalFinite.lean | 130 + Sendov/Common/DistillationEnvelope.lean | 89 + Sendov/Common/DistillationFactors.lean | 220 ++ Sendov/Common/DistillationFinite.lean | 106 + Sendov/Common/DistillationHyperbolic.lean | 476 +++ Sendov/Common/DistillationKernel.lean | 105 + Sendov/Common/DistillationMajorant.lean | 30 + Sendov/Common/Quadratic.lean | 45 +- Sendov/Common/Rpow.lean | 38 +- Sendov/Common/TwoChord.lean | 221 ++ Sendov/Defs.lean | 95 +- Sendov/DistillationFinite/Row81.lean | 96 + Sendov/DistillationFinite/Rows13_20.lean | 936 ++++++ Sendov/DistillationFinite/Rows21_28.lean | 936 ++++++ Sendov/DistillationFinite/Rows29_36.lean | 937 ++++++ Sendov/DistillationFinite/Rows37_44.lean | 935 ++++++ Sendov/DistillationFinite/Rows45_52.lean | 850 +++++ Sendov/DistillationFinite/Rows53_60.lean | 782 +++++ Sendov/DistillationFinite/Rows5_12.lean | 925 ++++++ Sendov/DistillationFinite/Rows61_68.lean | 754 +++++ Sendov/DistillationFinite/Rows69_76.lean | 754 +++++ Sendov/DistillationFinite/Rows77_80.lean | 378 +++ Sendov/FiniteRange/Batch.lean | 188 -- Sendov/FiniteRange/BatchCertificate.lean | 39 - Sendov/FiniteRange/Cover.lean | 180 -- Sendov/FiniteRange/Degree10_11.lean | 120 - Sendov/FiniteRange/Degree12_13.lean | 120 - Sendov/FiniteRange/Degree14_15.lean | 120 - Sendov/FiniteRange/Degree16_18.lean | 120 - Sendov/FiniteRange/Degree18_20.lean | 120 - Sendov/FiniteRange/Degree20.lean | 137 - Sendov/FiniteRange/Degree20Packed.lean | 63 - Sendov/FiniteRange/Degree20_22.lean | 120 - Sendov/FiniteRange/Degree22_24.lean | 120 - Sendov/FiniteRange/Degree24_26.lean | 120 - Sendov/FiniteRange/Degree26_27.lean | 120 - Sendov/FiniteRange/Degree28_29.lean | 120 - Sendov/FiniteRange/Degree30_31.lean | 120 - Sendov/FiniteRange/Degree32_33.lean | 120 - Sendov/FiniteRange/Degree34_35.lean | 120 - Sendov/FiniteRange/Degree36_37.lean | 120 - Sendov/FiniteRange/Degree38_39.lean | 120 - Sendov/FiniteRange/Degree40_41.lean | 120 - Sendov/FiniteRange/Degree42_43.lean | 120 - Sendov/FiniteRange/Degree44_45.lean | 120 - Sendov/FiniteRange/Degree46_47.lean | 120 - Sendov/FiniteRange/Degree48_49.lean | 120 - Sendov/FiniteRange/Degree5.lean | 113 - Sendov/FiniteRange/Degree50_51.lean | 120 - Sendov/FiniteRange/Degree52_53.lean | 120 - Sendov/FiniteRange/Degree53Packed.lean | 64 - Sendov/FiniteRange/Degree54_55.lean | 120 - Sendov/FiniteRange/Degree56_58.lean | 120 - Sendov/FiniteRange/Degree58_60.lean | 120 - Sendov/FiniteRange/Degree6.lean | 85 - Sendov/FiniteRange/Degree60_63.lean | 120 - Sendov/FiniteRange/Degree64_69.lean | 120 - Sendov/FiniteRange/Degree6_6.lean | 120 - Sendov/FiniteRange/Degree7.lean | 110 - Sendov/FiniteRange/Degree70_79.lean | 120 - Sendov/FiniteRange/Degree8.lean | 87 - Sendov/FiniteRange/Degree80_100.lean | 120 - Sendov/FiniteRange/Degree8_9.lean | 120 - Sendov/FiniteRange/Degree97Packed.lean | 97 - Sendov/FiniteRange/Moments.lean | 125 - Sendov/FiniteRange/OddBound.lean | 67 - Sendov/FiniteRange/Pack.lean | 239 -- Sendov/FiniteRange/PackBridge.lean | 613 ---- .../FiniteRange/PackedMomentCertificate.lean | 42 - Sendov/FiniteRange/Recurrence.lean | 259 -- Sendov/FiniteRange/Reduce.lean | 88 - Sendov/Interior.lean | 13 +- Sendov/LargeDegree/DistillationTail.lean | 354 ++ Sendov/LargeDegree/DistillationTailBound.lean | 36 + Sendov/LargeDegree/Endgame.lean | 150 - Sendov/LargeDegree/Monotone.lean | 359 --- Sendov/LargeDegree/Tail.lean | 94 - Sendov/Main.lean | 53 - Sendov/Reduction/Alpha17.lean | 2 +- Sendov/Reduction/CubicPolar.lean | 127 + Sendov/Reduction/CubicScalar.lean | 48 + Sendov/Reduction/DistillationBridge.lean | 169 + Sendov/Reduction/Main.lean | 86 +- Sendov/Reduction/Setup.lean | 36 +- Sendov/Reduction/Simplified.lean | 4 +- Sendov/Reduction/Stat.lean | 133 - data/LICENSE-PAPER.txt | 15 + data/README.md | 17 + data/paper_certificate_table.json | 2851 +++++++++++++++++ docs/design.md | 712 +--- docs/finite-range.md | 72 - docs/getting-started.md | 215 +- docs/making-of.md | 326 -- docs/plan-finite-range.md | 398 --- docs/proof-large-degree.md | 1025 ------ formalization.yaml | 645 ++-- scripts/GENERATORS.md | 69 + scripts/LICENSE-APACHE-2.0.txt | 202 ++ scripts/LICENSE-DISTILLATION-MIT.txt | 21 + scripts/audit.sh | 18 +- scripts/axioms.lean | 63 +- scripts/bundle_rows.py | 74 + scripts/distillation_data.py | 112 + scripts/emit_batch.py | 151 - scripts/gen_all_batches.py | 21 - scripts/gen_batch.py | 95 - scripts/gen_cover.py | 96 - scripts/gen_degree.py | 226 -- scripts/gen_distillation.py | 222 ++ scripts/gen_endgame.py | 252 -- scripts/gen_moment.py | 65 - scripts/gen_monotone_certs.py | 38 - scripts/gen_sinh.py | 157 +- scripts/generator_output.py | 24 + scripts/mutation_test.sh | 56 - scripts/pack_params.py | 39 - scripts/plan_batches.py | 43 - scripts/staged_build.sh | 49 - tests/BoundaryConsumer.lean | 42 + tests/expected.json | 20 + tests/test_axiom_audit.py | 153 + tests/test_bundle_rows.py | 60 + tests/test_generator_core.py | 143 + tests/test_generators.py | 237 ++ 133 files changed, 15855 insertions(+), 12178 deletions(-) create mode 100644 Sendov/Common/BernsteinList.lean create mode 100644 Sendov/Common/DistillationBounds.lean create mode 100644 Sendov/Common/DistillationCritical.lean create mode 100644 Sendov/Common/DistillationCriticalFinite.lean create mode 100644 Sendov/Common/DistillationEnvelope.lean create mode 100644 Sendov/Common/DistillationFactors.lean create mode 100644 Sendov/Common/DistillationFinite.lean create mode 100644 Sendov/Common/DistillationHyperbolic.lean create mode 100644 Sendov/Common/DistillationKernel.lean create mode 100644 Sendov/Common/DistillationMajorant.lean create mode 100644 Sendov/Common/TwoChord.lean create mode 100644 Sendov/DistillationFinite/Row81.lean create mode 100644 Sendov/DistillationFinite/Rows13_20.lean create mode 100644 Sendov/DistillationFinite/Rows21_28.lean create mode 100644 Sendov/DistillationFinite/Rows29_36.lean create mode 100644 Sendov/DistillationFinite/Rows37_44.lean create mode 100644 Sendov/DistillationFinite/Rows45_52.lean create mode 100644 Sendov/DistillationFinite/Rows53_60.lean create mode 100644 Sendov/DistillationFinite/Rows5_12.lean create mode 100644 Sendov/DistillationFinite/Rows61_68.lean create mode 100644 Sendov/DistillationFinite/Rows69_76.lean create mode 100644 Sendov/DistillationFinite/Rows77_80.lean delete mode 100644 Sendov/FiniteRange/Batch.lean delete mode 100644 Sendov/FiniteRange/BatchCertificate.lean delete mode 100644 Sendov/FiniteRange/Cover.lean delete mode 100644 Sendov/FiniteRange/Degree10_11.lean delete mode 100644 Sendov/FiniteRange/Degree12_13.lean delete mode 100644 Sendov/FiniteRange/Degree14_15.lean delete mode 100644 Sendov/FiniteRange/Degree16_18.lean delete mode 100644 Sendov/FiniteRange/Degree18_20.lean delete mode 100644 Sendov/FiniteRange/Degree20.lean delete mode 100644 Sendov/FiniteRange/Degree20Packed.lean delete mode 100644 Sendov/FiniteRange/Degree20_22.lean delete mode 100644 Sendov/FiniteRange/Degree22_24.lean delete mode 100644 Sendov/FiniteRange/Degree24_26.lean delete mode 100644 Sendov/FiniteRange/Degree26_27.lean delete mode 100644 Sendov/FiniteRange/Degree28_29.lean delete mode 100644 Sendov/FiniteRange/Degree30_31.lean delete mode 100644 Sendov/FiniteRange/Degree32_33.lean delete mode 100644 Sendov/FiniteRange/Degree34_35.lean delete mode 100644 Sendov/FiniteRange/Degree36_37.lean delete mode 100644 Sendov/FiniteRange/Degree38_39.lean delete mode 100644 Sendov/FiniteRange/Degree40_41.lean delete mode 100644 Sendov/FiniteRange/Degree42_43.lean delete mode 100644 Sendov/FiniteRange/Degree44_45.lean delete mode 100644 Sendov/FiniteRange/Degree46_47.lean delete mode 100644 Sendov/FiniteRange/Degree48_49.lean delete mode 100644 Sendov/FiniteRange/Degree5.lean delete mode 100644 Sendov/FiniteRange/Degree50_51.lean delete mode 100644 Sendov/FiniteRange/Degree52_53.lean delete mode 100644 Sendov/FiniteRange/Degree53Packed.lean delete mode 100644 Sendov/FiniteRange/Degree54_55.lean delete mode 100644 Sendov/FiniteRange/Degree56_58.lean delete mode 100644 Sendov/FiniteRange/Degree58_60.lean delete mode 100644 Sendov/FiniteRange/Degree6.lean delete mode 100644 Sendov/FiniteRange/Degree60_63.lean delete mode 100644 Sendov/FiniteRange/Degree64_69.lean delete mode 100644 Sendov/FiniteRange/Degree6_6.lean delete mode 100644 Sendov/FiniteRange/Degree7.lean delete mode 100644 Sendov/FiniteRange/Degree70_79.lean delete mode 100644 Sendov/FiniteRange/Degree8.lean delete mode 100644 Sendov/FiniteRange/Degree80_100.lean delete mode 100644 Sendov/FiniteRange/Degree8_9.lean delete mode 100644 Sendov/FiniteRange/Degree97Packed.lean delete mode 100644 Sendov/FiniteRange/Moments.lean delete mode 100644 Sendov/FiniteRange/OddBound.lean delete mode 100644 Sendov/FiniteRange/Pack.lean delete mode 100644 Sendov/FiniteRange/PackBridge.lean delete mode 100644 Sendov/FiniteRange/PackedMomentCertificate.lean delete mode 100644 Sendov/FiniteRange/Recurrence.lean delete mode 100644 Sendov/FiniteRange/Reduce.lean create mode 100644 Sendov/LargeDegree/DistillationTail.lean create mode 100644 Sendov/LargeDegree/DistillationTailBound.lean delete mode 100644 Sendov/LargeDegree/Endgame.lean delete mode 100644 Sendov/LargeDegree/Monotone.lean delete mode 100644 Sendov/LargeDegree/Tail.lean delete mode 100644 Sendov/Main.lean create mode 100644 Sendov/Reduction/CubicPolar.lean create mode 100644 Sendov/Reduction/CubicScalar.lean create mode 100644 Sendov/Reduction/DistillationBridge.lean delete mode 100644 Sendov/Reduction/Stat.lean create mode 100644 data/LICENSE-PAPER.txt create mode 100644 data/README.md create mode 100644 data/paper_certificate_table.json delete mode 100644 docs/finite-range.md delete mode 100644 docs/making-of.md delete mode 100644 docs/plan-finite-range.md delete mode 100644 docs/proof-large-degree.md create mode 100644 scripts/GENERATORS.md create mode 100644 scripts/LICENSE-APACHE-2.0.txt create mode 100644 scripts/LICENSE-DISTILLATION-MIT.txt create mode 100644 scripts/bundle_rows.py create mode 100644 scripts/distillation_data.py delete mode 100644 scripts/emit_batch.py delete mode 100644 scripts/gen_all_batches.py delete mode 100644 scripts/gen_batch.py delete mode 100644 scripts/gen_cover.py delete mode 100644 scripts/gen_degree.py create mode 100644 scripts/gen_distillation.py delete mode 100644 scripts/gen_endgame.py delete mode 100644 scripts/gen_moment.py delete mode 100644 scripts/gen_monotone_certs.py create mode 100644 scripts/generator_output.py delete mode 100644 scripts/mutation_test.sh delete mode 100644 scripts/pack_params.py delete mode 100644 scripts/plan_batches.py delete mode 100644 scripts/staged_build.sh create mode 100644 tests/BoundaryConsumer.lean create mode 100644 tests/expected.json create mode 100644 tests/test_axiom_audit.py create mode 100644 tests/test_bundle_rows.py create mode 100644 tests/test_generator_core.py create mode 100644 tests/test_generators.py diff --git a/.github/workflows/lean_action_ci.yml b/.github/workflows/lean_action_ci.yml index 0980c52..ac9fcbb 100644 --- a/.github/workflows/lean_action_ci.yml +++ b/.github/workflows/lean_action_ci.yml @@ -20,6 +20,6 @@ jobs: # The repository's trust policy, enforced: no `sorry` outside the two # deliberate holes in Challenge.lean, no project-defined axiom, no # native_decide, no unsafe, no floating point, and the top-level results - # depending on the three standard axioms only. See docs/design.md §8. + # depending on the three standard axioms only. See docs/design.md. - name: Trust audit run: bash scripts/audit.sh diff --git a/README.md b/README.md index 8734228..9daf2c1 100644 --- a/README.md +++ b/README.md @@ -1,280 +1,96 @@ # Sendov's conjecture in Lean -A formalization of **Sendov's conjecture** and the **Phelps–Rodriguez conjecture**, in full -generality. - -```lean -/-- Sendov's conjecture. -/ -theorem Sendov.sendov {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegree = n) - (hroots : ∀ w ∈ p.roots, ‖w‖ ≤ 1) {a : ℂ} (hpa : p.eval a = 0) : - ∃ ζ : ℂ, (derivative p).eval ζ = 0 ∧ ‖ζ - a‖ ≤ 1 - -/-- The Phelps–Rodriguez conjecture. -/ -theorem Sendov.phelps_rodriguez {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegree = n) - (hroots : ∀ w ∈ p.roots, ‖w‖ ≤ 1) {a : ℂ} (hpa : p.eval a = 0) : - (∃ ζ : ℂ, (derivative p).eval ζ = 0 ∧ ‖ζ - a‖ < 1) - ∨ (‖a‖ = 1 ∧ ∃ c : ℂ, c ≠ 0 ∧ p = C c * (X ^ n - C (a ^ n))) -``` - -If every zero of a complex polynomial of degree `n ≥ 2` lies in the closed unit disk, then -every zero `a` has a critical point within distance `1` — and within distance *strictly* less -than `1`, unless `a` is on the unit circle and `p` is a scalar multiple of `zⁿ - aⁿ`. - -The informal proof being formalized is -[*A digestion of the proof of Sendov's conjecture*](https://terrytao.wordpress.com/2026/08/12/a-digestion-of-the-proof-of-sendovs-conjecture/). - -Both are in [`Sendov/Conjecture.lean`](Sendov/Conjecture.lean#L83), and both depend on -`propext`, `Classical.choice` and `Quot.sound` only. - -[`Challenge.lean`](Challenge.lean) is the statement of record: 87 lines, importing only -Mathlib, declaring no definitions of its own. A reader who wants to check *what* has been -proved should read that file and need not read anything else. - -## Roadmap - -The proof is by contradiction throughout. Suppose `p` has degree `n ≥ 2`, all zeroes in the -closed unit disk, `p(a) = 0`, and *no* critical point within distance `1` of `a`. - -### 0. Normalize, and split into two multisets - -A rotation `p(ωz)` moves `a` to the real point `‖a‖`, so `a` may be assumed real and in -`[0,1]` — [`Sendov.rotate`](Sendov/Conjecture.lean#L43). The counterexample is then -repackaged as two multisets of `n-1` points of the closed unit disk: - -| | | -|---|---| -| the other zeroes `zⱼ` | [`exists_root_multiset`](Sendov/Counterexample/Factor.lean#L46) | -| the critical points, as `qⱼ = 1/(a - wⱼ)` | [`exists_crit_multiset`](Sendov/Counterexample/Factor.lean#L74) | - -The hypothesis "no critical point within distance 1" is exactly `‖qⱼ‖ ≤ 1`. - -### 1. Four identities linking zeroes to critical points - -All in [`Sendov/Counterexample/Identities.lean`](Sendov/Counterexample/Identities.lean), all -division-free, so that no `p'(a) ≠ 0` side condition is ever needed: - -| identity | meaning | | -|---|---|---| -| [`centroid_identity`](Sendov/Counterexample/Identities.lean#L60) | centroid of zeroes = centroid of critical points | | -| [`prod_sub_mul_prod`](Sendov/Counterexample/Identities.lean#L322) | `p'(a)` two ways: `(∏qⱼ)(∏(a-zⱼ)) = n` | | -| [`polar_identity`](Sendov/Counterexample/Identities.lean#L355) | `∏(1-azⱼ)/(a-zⱼ)` as an integral | | -| [`first_origin_identity`](Sendov/Counterexample/Identities.lean#L241) | `∫₀¹F` in terms of `∏zⱼ` | `F(t) = ∏(1 - a t qⱼ)` | -| [`second_origin_identity`](Sendov/Counterexample/Identities.lean#L165) | `F(1)` in terms of `∏zⱼ` and `∑1/zⱼ` | | - -### 2. The branch point `(⋆)` - -The polar identity together with `p'(a)` two ways gives - -> [`one_le_integral_prod_norm`](Sendov/Analytic/Polar.lean#L115) : `1 ≤ ∫₀¹ ∏ⱼ ‖a + t(1-a²)qⱼ‖ dt` - -This is where the argument forks. The Möbius estimate `|1-az|/|a-z| ≥ 1` is the one step that -needs `a` real. - -### 3a. Low degrees, `2 ≤ n ≤ 4` - -Bounding each factor of `(⋆)` by the *scalar* `X(t) = a + (1-a²)t` already contradicts itself: -`1 ≤ Jₘ(a) = ∫₀¹X(t)ᵐ dt` with `m = n-1`, while `Jₘ(a) < 1` for `0 < a < 1` and `m ≤ 4`. The -computation is done once, at `m = 4`, where `1 - J₄(a) = ((1-a)³(1+a)/5)(a⁴-3a³+3a+4)`. - -> [`low_degree_contradiction`](Sendov/Analytic/LowDegree.lean#L210), from -> [`one_le_lowJ`](Sendov/Analytic/LowDegree.lean#L93) and -> [`lowJ_lt_one`](Sendov/Analytic/LowDegree.lean#L185) - -No origin channel, no `Real.rpow`, no certificates. - -The lemma is stated for `2 ≤ n ≤ 5`, but this is the only branch that needs no certificate, -and the recorded proof enters it only for `n ≤ 4`: [`sendov_interior`](Sendov/Interior.lean#L53) -splits at `n < 5`, so degree `5` goes through the two-channel branch below like every larger -degree. - -### 3b. High degrees, `n ≥ 5`: two channels that cannot both hold - -Write `x + iy = (∑ⱼqⱼ)/(n-1)` and `α = (n-1)(1-a²)/2`. - -**The polar channel.** AM–GM relaxes `(⋆)` to a scalar inequality in `x` alone: - -> [`one_le_integral_Ppolar`](Sendov/Analytic/Polar.lean#L274) — the raw polar inequality `(1Q)` - -**The origin channel.** Differentiating `F(t) = ∏ⱼ(1 - a t qⱼ)` and integrating against the -fundamental theorem of calculus: - -| step | | +This local development proves **Sendov's conjecture** and the full +**Phelps–Rodriguez equality classification**. The statements of record are +`SendovConjecture.sendov` and `SendovConjecture.phelps_rodriguez` in +[`Solution.lean`](Solution.lean), with the original specifications retained in +[`Challenge.lean`](Challenge.lean). The latter contains the original two +statement placeholders and is not imported by the proof. + +For every complex polynomial of degree at least two whose zeros lie in the +closed unit disk, every zero has a critical point at distance at most one. +The distance is strictly less than one unless the distinguished zero lies on +the unit circle and the polynomial has the stated nonzero scalar-multiple +form. There is no extra numerical, genericity, degree-bound, or simple-root +hypothesis in either final theorem. + +## One active proof route + +The polynomial identities, analytic reduction, low-degree argument and boundary +classification start from Terence Tao's formalization.[1] The scalar endgame +here is a Lean implementation of Senjian An's rational-envelope and +low-degree critical-polynomial method, not an import of its Python checks as +trusted facts.[2] + +| Part | Active source | |---|---| -| `∑ⱼ∏_{k≠j}‖1-atq_k‖ ≤ (n-1)β(t)^{(n-2)/2}` | [`sumEraseProdMap_norm_le`](Sendov/Analytic/Origin.lean#L158) | -| `‖F'(t) + (n-1)a(x+iy)F(t)‖ ≤ …` | [`norm_deriv_add_le`](Sendov/Analytic/Origin.lean#L329) | -| integrate, using `F(0) = 1` | [`one_le_tri`](Sendov/Analytic/Origin.lean#L388) | -| estimate `J∑1/zⱼ`, paying the defect `1-\|J\|²` | [`Jsum_estimate`](Sendov/Analytic/Jsum.lean#L122) | -| `‖W‖ ≥ 2an/(n-1)`, collapsing `\|J\|` to `1` | [`grow`](Sendov/Analytic/OriginExact.lean#L92) | -| | [`origin_exact`](Sendov/Analytic/OriginExact.lean#L179) | - -`grow` reduces to `(n-1)²a² - (3n-1)a + (n-1) > 0`, whose discriminant `(3n-1)² - 4(n-1)³` is -negative exactly from `n ≥ 5`. **This is the only place `n ≥ 5` is used.** - -**The contradiction.** The two inequalities force `α ≤ 17` and then contradict each other: - -> [`polar_origin_incompatible`](Sendov/Reduction/Main.lean#L60) - -by way of the chain `(1Q) ⟹ (lt)` ([`polar_exp`](Sendov/Reduction/Polar.lean#L74)), -`(lt) ⟹ (beta-bound)` ([`beta_le`](Sendov/Reduction/BetaBound.lean#L108)), -[`alpha_le_seventeen`](Sendov/Reduction/Alpha17.lean#L106), and a numerical claim `stat`: - -> [`stat_lt_one`](Sendov/Main.lean#L40), from -> [`finite_range_le_100`](Sendov/FiniteRange/Cover.lean#L58) (degrees 5–100, by per-degree -> Bernstein certificates) and [`large_degree`](Sendov/LargeDegree/Endgame.lean#L251) -> (degrees ≥ 101, by an analytic reduction that removes the degree, then the single -> Bernstein certificate [`F_pos`](Sendov/LargeDegree/Endgame.lean#L53) for what it leaves) - -See [`docs/finite-range.md`](docs/finite-range.md) for that component on its own. - -### 3c. The boundary, `‖a‖ = 1` - -The polar identity degenerates at the boundary — the reflected point `1/a` coincides with `a` -and `1-a² = 0` — so it is replaced by one identity from `p''(1)/p'(1)`: - -> `∑ⱼqⱼ = 2∑ⱼ1/(1-zⱼ)` — [`boundary_reciprocal`](Sendov/Boundary.lean#L151) - -Both sides are then pinned: `Re qⱼ ≤ ‖qⱼ‖ ≤ 1` caps the left at `n-1`, while -`Re 1/(1-z) - 1/2 = (1-‖z‖²)/(2‖1-z‖²) ≥ 0` floors the right at `n-1`. Equality term by term -forces `qⱼ = 1`, so every critical point is `0` and `p = c(zⁿ-1)`. - -> [`all_q_eq_one`](Sendov/Boundary.lean#L168) → [`rubinstein_one`](Sendov/Boundary.lean#L210) - -The boundary case is Rubinstein's theorem, and it is where the Phelps–Rodriguez equality case -comes from. The argument is **not new**: the identity and the half-plane bound above are -equation (5.1) and Remark 5.1 of [Tang and Zhang](https://arxiv.org/abs/2508.10341), where the -same two steps give the `a = 1` case of Sendov's conjecture. What is done here in addition is -to run the sandwich to equality, recovering the classification — which is Rubinstein's 1968 -theorem, and so not new either. See [Provenance](#provenance-and-novelty). - -### 3d. The centre, `a = 0` - -`p'(a)` two ways is already enough: `(∏qⱼ)(∏zⱼ) = n` with both factors of norm at most one -forces `n ≤ 1`. - -> [`sendov_center`](Sendov/Interior.lean#L125) - -### 4. Assembling - -> [`sendov_interior`](Sendov/Interior.lean#L53) (real `0 < a < 1`) → -> [`sendov_interior_real`](Sendov/Interior.lean#L162) (with `a = 0`) → -> [`phelps_rodriguez`](Sendov/Conjecture.lean#L83) (rotation, and the boundary) → -> [`sendov`](Sendov/Conjecture.lean#L158) - -## Two ingredients absent from Mathlib - -* **Maclaurin's inequality**, top case — [`Multiset.esymm_card_pred_le`](Sendov/Analytic/Maclaurin.lean#L166), - by multiset induction reducing to Bernoulli. The same induction gives multiset AM–GM, - [`Multiset.prod_le_mean_pow`](Sendov/Analytic/Maclaurin.lean#L107). -* **The defect lemma** — [`defect`](Sendov/Analytic/Defect.lean#L93): - `∏|wⱼ| · ∑ⱼ|1/wⱼ - conj wⱼ| ≤ 1 - ∏|wⱼ|²` on the closed unit disk. - -A third piece worth naming is [`log_sinh_div_le`](Sendov/Common/Sinh.lean#L245), -`log(sinh h / h) ≤ √(h²+9) - 3`, which is sharp to three orders at `h = 0` and is the crux of -the `(beta-bound)` step. - -## Trust - -* no `sorry` and no project-defined `axiom`, with one deliberate exception: `Challenge.lean` - *states* the two theorems without proving them, which is what makes it the statement of - record for Comparator to check `Solution.lean` against. `scripts/audit.sh` requires exactly - those two holes and no others, and forbids `sorry` everywhere else including `Solution.lean`; -* no `native_decide`, no `unsafe`, no floating point in any statement or proof; -* `maxHeartbeats` / `maxRecDepth` appear only as deliberate resource knobs, each with an - explanatory comment. - -`scripts/audit.sh` checks all of this and prints the axiom dependencies of the top-level -results; `scripts/mutation_test.sh` checks that the numerical certificates are actually -load-bearing. - -## Building - -``` +| Final statements and rotation | [`Solution.lean`](Solution.lean), [`Conjecture`](Sendov/Conjecture.lean) | +| Unit-circle boundary and equality case | [`Boundary`](Sendov/Boundary.lean) | +| Interior degrees `2 ≤ n ≤ 5` | [`LowDegree`](Sendov/Analytic/LowDegree.lean), [`Interior`](Sendov/Interior.lean) | +| Original polar/origin hypotheses → scalar domain and lower bound | [`CubicScalar`](Sendov/Reduction/CubicScalar.lean) | +| Strong hyperbolic bound and cubic polar envelope | [`DistillationHyperbolic`](Sendov/Common/DistillationHyperbolic.lean), [`CubicPolar`](Sendov/Reduction/CubicPolar.lean) | +| Two-chord integral estimate and regularized factors | [`TwoChord`](Sendov/Common/TwoChord.lean), [`DistillationMajorant`](Sendov/Common/DistillationMajorant.lean) | +| Finite critical-point certificates | [`DistillationFinite`](Sendov/Common/DistillationFinite.lean), [`generated modules`](Sendov/DistillationFinite) | +| Real-parameter tail using the actual base certificate | [`DistillationTailBound`](Sendov/LargeDegree/DistillationTailBound.lean) | +| Complete contradiction | [`DistillationBounds`](Sendov/Common/DistillationBounds.lean), [`Reduction/Main`](Sendov/Reduction/Main.lean) | + +The convention is **`m = n - 1`**. The finite proof covers all `5 ≤ m ≤ 81`; +the tail is proved for every real `m ≥ 81` and uses the certified `m=81` case. +The final degree split uses the finite proof through `n=82`, then the tail. +Both are parts of the same scalar argument. + +Each finite case uses the complete critical polynomials of degrees **7, 7, 4**. +Exact Bernstein identities prove derivative signs on the full outer intervals; +a mixed-endpoint estimate covers the central bracket. The proof does not assume +that a numerical root finder found all critical points. Closed endpoints and +empty outer intervals are handled explicitly. + +The old `R`-based finite/large-degree certificate system and its specialized +generators are retired, not shipped as a second compatibility route. General +lemmas still used by the new proof remain. The mean/variance budget formulation +also incorporates an idea examined in Pickhardt's work; no conditional Sendov +claim or assumed threshold from that project is used.[3] + +## Build and verify + +Use the versions pinned by [`lean-toolchain`](lean-toolchain) and +[`lake-manifest.json`](lake-manifest.json): + +```sh lake exe cache get lake build -bash scripts/audit.sh +lake env lean scripts/axioms.lean ``` -Memory, not time, is the binding constraint on a full build; `scripts/staged_build.sh` builds -the certificate files in batches. - -## Documents - -| | | -|---|---| -| [`docs/making-of.md`](docs/making-of.md) | how this formalization happened: a curated transcript of the conversation that produced it | -| [`docs/getting-started.md`](docs/getting-started.md) | how to set up to do something like this, for someone new to Lean, VS Code, GitHub or coding agents | -| [`docs/design.md`](docs/design.md) | design record: status table, the measurements behind each decision, and the traps encountered | -| [`docs/finite-range.md`](docs/finite-range.md) | the finite-range check on its own | -| [`docs/proof-large-degree.md`](docs/proof-large-degree.md) | informal proof for degrees ≥ 101 | -| [`docs/plan-*.md`](docs/) | the staged hand-off plans, with notes on where they were superseded | -| [the blog post](https://terrytao.wordpress.com/2026/08/12/a-digestion-of-the-proof-of-sendovs-conjecture/) | the informal proof being formalized | - -## Provenance and novelty - -**No novelty is claimed anywhere in this repository, and no literature or formalization search -was performed.** Where this document notes that something here differs from earlier work, that -is a description of this development, not a priority claim: whether any of it is new is -unknown. - -The mathematics descends from **Lech Mazur's** proof. Sendov's conjecture was first proved, and -first formalized in Lean, by that work at [ProofAtlas](https://www.proofatlas.ai/formalizations/sendov-conjecture/) — priority for both belongs there. -The informal proof formalized here is [Tao's digestion](https://terrytao.wordpress.com/2026/08/12/a-digestion-of-the-proof-of-sendovs-conjecture/) of Mazur's argument, described in -the post as an effort "to place the proof in proper context with previous literature and to -simplify and streamline the argument to highlight the main ideas". This repository is therefore -the **second** formalization of Sendov's conjecture, and its mathematical content is a -streamlined descendant of the first rather than an independent route to the same theorem. - -As far as we are aware it is the first formalization of the **Phelps–Rodriguez** form: the -earlier formalization reports a single main theorem, Sendov's `‖ζ - a‖ ≤ 1`, and does not state -the equality classification. That is an observation about the one earlier formalization we know -of, not the result of a search. - -The two developments are separately checkable evidence for the same theorem, and they differ in -what they state and in size: - -| | this repository | the earlier formalization | -|---|---|---| -| statement | Sendov **and** Phelps–Rodriguez | Sendov | -| Lean | 80 files, 15,152 lines | 1,160 files, 92,816 lines *(as reported there)* | -| shared code | none | | - -The boundary argument in [`Sendov/Boundary.lean`](Sendov/Boundary.lean) is likewise not new. -It was reached here from the blog post rather than from the literature, but its two ingredients -are equation (5.1) and Remark 5.1 of Quanyu Tang and Teng Zhang, *Sharp Schoenberg type -inequalities and the de Bruin–Sharma problem*, [arXiv:2508.10341](https://arxiv.org/abs/2508.10341): -their `∑ₖ 1/wₖ = 2 ∑ⱼ 1/zⱼ` is `boundary_reciprocal` after moving the distinguished zero from -`0` to `1`, and their `ℜ(1/zⱼ) ≤ -1/2` is `half_le_re_inv_one_sub`. Remark 5.1 stops at the -non-strict conclusion `min|wₖ| ≤ 1`; the extra step here, extracting equality term by term to -get the classification, recovers Rubinstein's 1968 theorem and is not claimed as new either. - -One difference is worth naming because it is checkable here: this development uses **no -interval arithmetic and no floating point at all**. The computational step — a numerical -inequality reached by every degree from `5` up, in both the finite range and, after the -analytic reduction, the large-degree endgame — is discharged by exact rational Bernstein -certificates re-verified inside Lean, and `scripts/audit.sh` fails the build if `Float` -appears anywhere in a statement or proof. No comparison of the two proofs' internal arguments has been carried out. - -## How this was produced - -Essentially all of the Lean source in this repository was written by **Claude Opus 5** -(Anthropic), working interactively in Claude Code under the direction and review of the -author: choosing the Lean formulations, finding and repairing proofs, and designing the -certificate machinery. The author set the targets, supplied the informal proof and the staged -plans in `docs/`, made the mathematical decisions, and reviewed the output as it was produced. -No external or independent review has been performed. - -The Bernstein certificates are emitted by the Python scripts in `scripts/`: the per-degree -ones in `Sendov/FiniteRange/`, and the degree-58 endgame certificate `F_pos` in -`Sendov/LargeDegree/Endgame.lean`, from `scripts/gen_endgame.py`. Those scripts are outside the trusted base: they write Lean source that Lean -re-verifies from scratch, so a bug in them causes a build failure, not an unsound theorem. - -Two documents record the process rather than the result. -[`docs/making-of.md`](docs/making-of.md) is a curated transcript of the conversation that -produced the development — the stages it went through, and the dead ends and mistakes along -the way. [`docs/getting-started.md`](docs/getting-started.md) describes the setup this -repository started from and the working habits that mattered, for someone new to Lean, VS Code, -GitHub or coding agents. - -## Licence - -Apache-2.0; see [`LICENSE`](LICENSE). +The mathematical proof uses only `propext`, `Classical.choice`, and `Quot.sound`. +No project axiom, `sorry`, `native_decide`, or floating-point computation is used +in the proved library. Kernel replay, original headline-type comparison and +actual proof-dependency checks are separate acceptance steps; compilation alone +is not reported as all of them. + +See [`docs/getting-started.md`](docs/getting-started.md) for verification and +[`scripts/GENERATORS.md`](scripts/GENERATORS.md) for reproducible generation. +The finite generator emits the entire table in one command to a fresh output +root. Python prepares exact data; Lean verifies the complete identities and +inequalities. A successful generator run is **not** a completed proof check. + +## Provenance and scope + +This is a local adaptation, not a claim that upstream maintainers reviewed or +endorsed these changes. The repository keeps the original Apache-2.0 code +license. The distilled mathematics and certificate table are attributed to +Senjian An's fixed source version; the source paper is CC BY 4.0.[2] +The retained generator entry points incorporate applicable portability fixes; +obsolete batch-specific tools are not retained merely to preserve a PR surface.[4] +Only contributions serving the active proof and its reproducibility are kept. +Unverified theorem corpora, numerical demonstrations, unrelated visualization +programs and obsolete generator interfaces are not part of the proof deliverable. + +See [`docs/design.md`](docs/design.md) for the reduction contract and trust boundary. + +## Sources + +[1] https://github.com/teorth/sendov +[2] https://github.com/SJanPerth/Sendov-Proof-Distillation/tree/e8ae601491ec171ab4f7f8456113dd6a047aa85d +[3] https://github.com/pickhardt/sendov-explicit-threshold +[4] https://github.com/teorth/sendov/pull/1 diff --git a/Sendov.lean b/Sendov.lean index 2f6e5d8..e9215f0 100644 --- a/Sendov.lean +++ b/Sendov.lean @@ -1,75 +1 @@ -import Sendov.Common.Basic -import Sendov.Common.Rpow -import Sendov.Common.Quadratic -import Sendov.Common.Chord -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.Moments -import Sendov.FiniteRange.OddBound -import Sendov.FiniteRange.Pack -import Sendov.FiniteRange.Recurrence -import Sendov.FiniteRange.PackBridge -import Sendov.FiniteRange.Reduce -import Sendov.FiniteRange.Degree5 -import Sendov.FiniteRange.Degree6 -import Sendov.FiniteRange.Degree7 -import Sendov.FiniteRange.Degree8 -import Sendov.FiniteRange.Degree20 -import Sendov.FiniteRange.Degree20Packed -import Sendov.FiniteRange.Degree53Packed -import Sendov.FiniteRange.Degree97Packed -import Sendov.FiniteRange.Degree6_6 -import Sendov.FiniteRange.Degree8_9 -import Sendov.FiniteRange.Degree10_11 -import Sendov.FiniteRange.Degree12_13 -import Sendov.FiniteRange.Degree14_15 -import Sendov.FiniteRange.Degree16_18 -import Sendov.FiniteRange.Degree18_20 -import Sendov.FiniteRange.Degree20_22 -import Sendov.FiniteRange.Degree22_24 -import Sendov.FiniteRange.Degree24_26 -import Sendov.FiniteRange.Degree26_27 -import Sendov.FiniteRange.Degree28_29 -import Sendov.FiniteRange.Degree30_31 -import Sendov.FiniteRange.Degree32_33 -import Sendov.FiniteRange.Degree34_35 -import Sendov.FiniteRange.Degree36_37 -import Sendov.FiniteRange.Degree38_39 -import Sendov.FiniteRange.Degree40_41 -import Sendov.FiniteRange.Degree42_43 -import Sendov.FiniteRange.Degree44_45 -import Sendov.FiniteRange.Degree46_47 -import Sendov.FiniteRange.Degree48_49 -import Sendov.FiniteRange.Degree50_51 -import Sendov.FiniteRange.Degree52_53 -import Sendov.FiniteRange.Degree54_55 -import Sendov.FiniteRange.Degree56_58 -import Sendov.FiniteRange.Degree58_60 -import Sendov.FiniteRange.Degree60_63 -import Sendov.FiniteRange.Degree64_69 -import Sendov.FiniteRange.Degree70_79 -import Sendov.FiniteRange.Degree80_100 -import Sendov.LargeDegree.Tail -import Sendov.FiniteRange.Cover -import Sendov.LargeDegree.Monotone -import Sendov.LargeDegree.Endgame -import Sendov.Main -import Sendov.Common.Sinh -import Sendov.Reduction.Setup -import Sendov.Reduction.Polar -import Sendov.Reduction.BetaBound -import Sendov.Reduction.Stat -import Sendov.Reduction.Simplified -import Sendov.Reduction.Alpha17 -import Sendov.Reduction.Main -import Sendov.Analytic.Maclaurin -import Sendov.Analytic.Defect -import Sendov.Counterexample.Factor -import Sendov.Counterexample.Identities -import Sendov.Analytic.Polar -import Sendov.Analytic.Origin -import Sendov.Analytic.Jsum -import Sendov.Analytic.OriginExact -import Sendov.Analytic.LowDegree -import Sendov.Interior -import Sendov.Boundary import Sendov.Conjecture diff --git a/Sendov/Analytic/Polar.lean b/Sendov/Analytic/Polar.lean index 6d4ac97..f2b8289 100644 --- a/Sendov/Analytic/Polar.lean +++ b/Sendov/Analytic/Polar.lean @@ -155,13 +155,8 @@ lemma sum_norm_sq_split (a s : ℝ) (q : Multiset ℂ) : (q.map (fun v => ‖(a : ℂ) + (s : ℂ) * v‖ ^ 2)).sum = (q.card : ℝ) * a ^ 2 + 2 * a * s * ((q.map (fun v => v.re)).sum) + s ^ 2 * ((q.map (fun v => ‖v‖ ^ 2)).sum) := by - induction q using Multiset.induction_on with - | empty => simp - | cons v t ih => - simp only [Multiset.map_cons, Multiset.sum_cons, Multiset.card_cons] - rw [ih, norm_sq_add_real_mul] - push_cast - ring + simp_rw [norm_sq_add_real_mul] + simp [Multiset.sum_map_add, Multiset.sum_map_mul_left, nsmul_eq_mul] lemma sum_norm_sq_le_card (q : Multiset ℂ) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) : (q.map (fun v => ‖v‖ ^ 2)).sum ≤ (q.card : ℝ) := by diff --git a/Sendov/Common/Basic.lean b/Sendov/Common/Basic.lean index dc80934..6fc28ad 100644 --- a/Sendov/Common/Basic.lean +++ b/Sendov/Common/Basic.lean @@ -6,18 +6,9 @@ Authors: Terence Tao import Sendov.Defs /-! -# Basic properties of the quantities in the finite-range claim +# Positivity of the degree coordinate -Elementary facts about `Sendov.M`, `Sendov.A`, `Sendov.c` and `Sendov.Q`, used by every -degree-specific argument. The two facts that matter are: - -* `Sendov.Q_nonneg`: the feasibility constraint `c ^ 2 ≤ A` says exactly that `Q` is a sum - of squares, hence nonnegative. This is what makes the real power `Q ^ ((n-4)/2)` - appearing in `Sendov.R` behave, and in particular avoids the junk values of `Real.rpow` - at negative bases. -* `Sendov.Q_one`: `Q n α 1 = α / (3 + α)`, the value `B` prescribed by the simplified polar - inequality of the blog post. Since `Q n α 1 = 1 - 2 * c n α + A n α`, this pins down - `A - 2 * c = B - 1 < 0`, which is what gives `Sendov.Q_le_one`. +`M_pos` supplies the positive denominator used by the analytic reduction and scalar coordinates. -/ namespace Sendov @@ -29,102 +20,4 @@ lemma M_pos (hn : 2 ≤ n) : 0 < M n := by simp only [M] linarith -lemma three_add_pos (hα : 0 ≤ α) : (0 : ℝ) < 3 + α := by linarith - -/-- `Q` written as a sum of squares. Compare `β(t) = (1 - a x t) ^ 2 + a² t² (1 - x²)` -in the blog post. -/ -lemma Q_eq (n : ℕ) (α t : ℝ) : - Q n α t = (1 - c n α * t) ^ 2 + (A n α - c n α ^ 2) * t ^ 2 := by - simp only [Q] - ring - -/-- Feasibility forces `a² ≥ 0`. -/ -lemma A_nonneg (hfeas : c n α ^ 2 ≤ A n α) : 0 ≤ A n α := - le_trans (sq_nonneg _) hfeas - -/-- Feasibility bounds `α` by `(n-1)/2`, simply because it forces `A = 1 - 2α/(n-1) ≥ 0`. - -This crude consequence is all that the *numerical* step of any degree needs: on -`0 ≤ α ≤ min 17 ((n-1)/2)` the upper bounds for `R n α` used in this development stay below -`0.856` for every `5 ≤ n ≤ 97`. The exact shape of the feasible region, which is cut out -by a quartic in `α`, is therefore never required by the polynomial certificates. - -This must not be read as saying that `A ≥ 0` replaces feasibility everywhere. It does not: -the odd-degree bound needs `0 ≤ Q n α t` on `[0,1]`, which is `Sendov.Q_nonneg` and uses the -full constraint `c ^ 2 ≤ A` — it does not follow from `A ≥ 0`. Accordingly -`Sendov.integral_rpow_le` takes `hfeas` itself, and only the passage from the resulting -rational function to a polynomial positivity statement is weakened to `α ≤ M n / 2`. For -even degrees the moment identity `Sendov.integral_moment` needs no hypothesis at all. -/ -lemma alpha_le_half_M (hn : 2 ≤ n) (hfeas : c n α ^ 2 ≤ A n α) : α ≤ M n / 2 := by - have hM : 0 < M n := M_pos hn - have hA : 0 ≤ A n α := A_nonneg hfeas - rw [A] at hA - have h : 2 * α / M n ≤ 1 := by linarith - rw [div_le_one hM] at h - linarith - -lemma Q_nonneg (hfeas : c n α ^ 2 ≤ A n α) (t : ℝ) : 0 ≤ Q n α t := by - rw [Q_eq] - exact add_nonneg (sq_nonneg _) (mul_nonneg (sub_nonneg.2 hfeas) (sq_nonneg _)) - -/-- `Q n α 1 = B = α / (3 + α)`: the substituted quadratic takes at `t = 1` the value that -the simplified polar inequality `β(1) < α / (3 + α)` prescribes. -/ -lemma Q_one (hn : 2 ≤ n) (hα : 0 ≤ α) : Q n α 1 = α / (3 + α) := by - have hM : M n ≠ 0 := (M_pos hn).ne' - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - simp only [Q, c, A] - field_simp - ring - -/-- `Q` is convex with `Q 0 = 1` and `Q 1 = B ≤ 1`, hence bounded by `1` on `[0,1]`. - -Only `0 ≤ c` is needed, not `0 ≤ A`: writing `Q t - 1 = t (A t - 2c)`, the identity -`Q 1 = B < 1` gives `A ≤ 2c` outright, and then `A t ≤ 2c` holds whether `A` is nonnegative -(as `A t ≤ A`) or negative (as `A t ≤ 0 ≤ 2c`). That matters for batches of degrees whose -`α`-range reaches past `(n₀-1)/2`, where `A n₀ α` can be negative. -/ -lemma Q_le_one (hn : 2 ≤ n) (hα : 0 ≤ α) (hc : 0 ≤ c n α) - (ht0 : 0 ≤ t) (ht1 : t ≤ 1) : Q n α t ≤ 1 := by - have hB : Q n α 1 ≤ 1 := by - rw [Q_one hn hα, div_le_one (three_add_pos hα)] - linarith - have hAc : A n α - 2 * c n α ≤ 0 := by - simp only [Q] at hB - linarith - have h5 : A n α * t - 2 * c n α ≤ 0 := by - rcases le_total 0 (A n α) with h | h - · nlinarith [mul_le_of_le_one_right h ht1] - · nlinarith [mul_nonneg ht0 (neg_nonneg.2 h)] - simp only [Q] - nlinarith [mul_nonneg ht0 (neg_nonneg.2 h5)] - -/-- Feasibility gives `α ≤ (n-1)/2`, and hence `c ≥ (1-B)/2 > 0`. -/ -lemma c_pos_of_le_half_M (hn : 2 ≤ n) (hα : 0 ≤ α) (hhalf : α ≤ M n / 2) : 0 < c n α := by - have hM : 0 < M n := M_pos hn - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have h1 : α / M n ≤ 1 / 2 := by - rw [div_le_div_iff₀ hM (by norm_num)] - linarith - have h2 : α / (2 * (3 + α)) < 1 / 2 := by - rw [div_lt_div_iff₀ (by positivity) (by norm_num)] - linarith - simp only [c] - linarith - -/-- The coefficient multiplying the integral in `Sendov.R` is nonnegative, so any upper -bound for the integral yields an upper bound for `R`. This is how each degree replaces its -integral by an explicit rational function. -/ -lemma R_le_of_integral_le (hn : 2 ≤ n) (hα : 0 ≤ α) {J : ℝ} - (hJ : (∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ (((n : ℝ) - 4) / 2)) ≤ J) : - R n α ≤ 1 / 6 + 1 / (4 * (3 + α)) + 1 / (2 * M n) + 1 / (4 * M n * (3 + α)) + - A n α ^ 2 * n * M n * ((n : ℝ) - 2) / (4 * (3 + α)) * J := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hn2 : (0 : ℝ) ≤ (n : ℝ) - 2 := by - have : (2 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn - linarith - have hcoef : 0 ≤ A n α ^ 2 * n * M n * ((n : ℝ) - 2) / (4 * (3 + α)) := - div_nonneg (mul_nonneg (mul_nonneg (mul_nonneg (sq_nonneg _) (Nat.cast_nonneg n)) - (M_pos hn).le) hn2) (by linarith) - rw [R] - exact add_le_add_right (mul_le_mul_of_nonneg_left hJ hcoef) _ - end Sendov diff --git a/Sendov/Common/BernsteinList.lean b/Sendov/Common/BernsteinList.lean new file mode 100644 index 0000000..8356f64 --- /dev/null +++ b/Sendov/Common/BernsteinList.lean @@ -0,0 +1,31 @@ +import Sendov.Common.BernsteinCert +import Sendov.Common.BernsteinRing + +/-! +# Coefficient-list frontend for the existing Bernstein certificate theorem + +The raw list `[c₀, …, cₙ]` denotes `∑ cᵢ X^i Y^(n-i)` (no extra binomial +factors). Natural coefficients give nonnegativity; both axis supports are checked +by the existing `Cert.edge`. Empty data denotes zero and cannot have either support. +Every application still supplies a complete polynomial identity proved in Lean. +-/ +namespace BernsteinCert + +/-- Build the existing addition tree, starting the X exponent at `i`. +The singleton case avoids adding an artificial zero monomial of a different degree. -/ +def coeffTree : List ℕ → ℕ → Cert + | [], _ => .mono 0 0 0 + | [c], i => .mono c i 0 + | c :: d :: cs, i => .add (.mono c i (cs.length + 1)) (coeffTree (d :: cs) (i + 1)) + +/-- Closed-interval positivity from raw coefficients; no new positivity checker. +The interval, scale, two endpoint supports and full identity are explicit obligations. -/ +theorem coeffs_pos (cs : List ℕ) {lo hi s P x : ℝ} + (hab : lo < hi) (hs : 0 < s) (hx : x ∈ Set.Icc lo hi) + (hl : (coeffTree cs 0).edge true = true) + (hr : (coeffTree cs 0).edge false = true) + (hid : s * P = (coeffTree cs 0).eval (x - lo) (hi - x)) : 0 < P := by + exact scaled_pos (coeffTree cs 0) hid hs (sub_nonneg.mpr hx.1) + (sub_nonneg.mpr hx.2) (by linarith) hl hr + +end BernsteinCert diff --git a/Sendov/Common/Chord.lean b/Sendov/Common/Chord.lean index cff6014..0585e6e 100644 --- a/Sendov/Common/Chord.lean +++ b/Sendov/Common/Chord.lean @@ -6,30 +6,11 @@ Authors: Terence Tao import Sendov.Common.Quadratic /-! -# Chord bounds and the Beta integrals +# Chord bounds and Beta integrals -Both halves of the argument replace a power of the quadratic by a power of its chord and -integrate. The blog post does this twice, with different weights: - -* with weight `t`, to bound `∫₀¹ t β(t)^{(n-2)/2}` in the proof of `α ≤ 17`; -* with weight `t³`, to bound `∫₀¹ t³ Q^{(n-4)/2}` in the large-degree argument. - -Both reduce to a Beta integral, and the split is the same in both cases, so it is proved once: -`Sendov.integral_le_tail_gen` bounds `∫₀¹ t^k QQ^r` by the chord integral over `[0,1/c]` plus -`QQ 1 ^ r / (k+1)`, for any natural `k`, leaving the Beta value to be substituted afterwards. - -The informal write-up instead uses `QQ ≤ exp(-ct)` and the Gamma integral -`∫₀^∞ t³ e^{-rct} dt = 6/(rc)⁴`. The Beta route is preferable in Lean — no improper integral -and no `Real.exp` — and is strictly sharper, since -`6/((s+1)(s+2)(s+3)(s+4)) ≤ 6/s⁴` (`Sendov.beta_le_six_div_pow`), so every numerical constant -downstream of the Gamma bound stays valid. - -## Main statements - -* `Sendov.integral_lin_mul_rpow`, `Sendov.integral_cube_mul_rpow`: the Beta values; -* `Sendov.integral_chord_lin`, `Sendov.integral_chord_pow`: the same, scaled to `[0,1/c]`; -* `Sendov.integral_le_tail_gen`: the split, for an arbitrary weight `t^k`; -* `Sendov.integral_le_tail_lin`, `Sendov.integral_le_tail_cube`: the two instances used. +Retain the linear and cubic Beta integrals, scaled chord integrals, generic split and linear tail. +`Alpha17` consumes the linear tail; `Simplified` the linear chord; `TwoChord` the cubic Beta +integral. -/ namespace Sendov @@ -106,13 +87,6 @@ lemma integral_cube_mul_rpow {s : ℝ} (hs : 0 < s) : field_simp ring -/-- The Beta value is at most `6/s⁴`; this is the form the informal argument uses, obtained -there from the Gamma integral. -/ -lemma beta_le_six_div_pow {s : ℝ} (hs : 0 < s) : - 6 / ((s + 1) * (s + 2) * (s + 3) * (s + 4)) ≤ 6 / s ^ 4 := by - apply div_le_div_of_nonneg_left (by norm_num) (by positivity) - nlinarith [hs.le, sq_nonneg s, sq_nonneg (s + 1)] - /-- The chord integral with weight `t`, over `[0, 1/c]`. -/ lemma integral_chord_lin {s c : ℝ} (hs : 0 < s) (hc : 0 < c) : (∫ t in (0 : ℝ)..1 / c, t * (1 - c * t) ^ s) = 1 / (c ^ 2 * ((s + 1) * (s + 2))) := by @@ -246,23 +220,6 @@ theorem integral_le_tail_gen {c A : ℝ} (hfeas : c ^ 2 ≤ A) (hc : 0 < c) (hc1 nlinarith [mul_nonneg hBnn hsk] linarith -/-- The integral is antitone in `c`: raising `c` lowers `QQ` pointwise on `[0,1]`. Note that -nonnegativity is only needed for the *larger* `c`; for the smaller one it comes free from the -pointwise comparison. (`Sendov.integral_anti` in `FiniteRange.Batch` is the same trick applied -to the degree instead.) -/ -lemma integral_QQ_anti {c₁ c₂ A : ℝ} (hle : c₁ ≤ c₂) (hfeas : c₂ ^ 2 ≤ A) {r : ℝ} (hr : 0 ≤ r) - (k : ℕ) : - (∫ t in (0 : ℝ)..1, t ^ k * QQ c₂ A t ^ r) - ≤ ∫ t in (0 : ℝ)..1, t ^ k * QQ c₁ A t ^ r := by - refine intervalIntegral.integral_mono_on (by norm_num) - ((continuous_pow_mul_QQ c₂ A k hr).intervalIntegrable _ _) - ((continuous_pow_mul_QQ c₁ A k hr).intervalIntegrable _ _) ?_ - intro u hu - refine mul_le_mul_of_nonneg_left ?_ (pow_nonneg hu.1 k) - refine Real.rpow_le_rpow (QQ_nonneg hfeas u) ?_ hr - simp only [QQ] - nlinarith [hu.1, hle] - /-- The instance with weight `t`, used for `α ≤ 17`. -/ theorem integral_le_tail_lin {c A : ℝ} (hfeas : c ^ 2 ≤ A) (hc : 0 < c) (hc1 : c ≤ 1) {r : ℝ} (hr : 0 < r) : @@ -273,13 +230,4 @@ theorem integral_le_tail_lin {c A : ℝ} (hfeas : c ^ 2 ≤ A) (hc : 0 < c) (hc1 rw [integral_chord_lin hr hc, show ((1 : ℕ) : ℝ) + 1 = 2 by norm_num] at h exact h -/-- The instance with weight `t³`, used by the large-degree argument. -/ -theorem integral_le_tail_cube {c A : ℝ} (hfeas : c ^ 2 ≤ A) (hc : 0 < c) (hc1 : c ≤ 1) - {r : ℝ} (hr : 0 < r) : - (∫ t in (0 : ℝ)..1, t ^ 3 * QQ c A t ^ r) - ≤ 6 / (c ^ 4 * ((r + 1) * (r + 2) * (r + 3) * (r + 4))) + QQ c A 1 ^ r / 4 := by - have h := integral_le_tail_gen hfeas hc hc1 hr 3 - rw [integral_chord_pow hr hc, show ((3 : ℕ) : ℝ) + 1 = 4 by norm_num] at h - exact h - end Sendov diff --git a/Sendov/Common/DistillationBounds.lean b/Sendov/Common/DistillationBounds.lean new file mode 100644 index 0000000..a107351 --- /dev/null +++ b/Sendov/Common/DistillationBounds.lean @@ -0,0 +1,29 @@ +import Sendov.Common.DistillationFinite +import Sendov.LargeDegree.DistillationTailBound + +/-! +# The complete scalar upper bound + +The original degree is `n`; the scalar parameter is `m = n - 1`. +The certified finite range covers `5 ≤ m ≤ 81`. Above it, the proved +real-degree tail uses the same degree-81 critical-point certificate. +-/ +namespace Sendov + +/-- The cubic scalar obstruction is strictly below one on the full domain +produced by the geometric reduction. No numerical or tail premise remains. -/ +theorem distillScalar_lt_one {n : ℕ} (hn : 6 ≤ n) {α : ℝ} + (hα : 0 < α) (h17 : α ≤ 17) (hhalf : 2 * α ≤ M n) : + scalarObstruction (M n) α (cubicPolarEnvelope α) < 1 := by + have hn1 : 1 ≤ n := by omega + have hM : ((n - 1 : ℕ) : ℝ) = M n := by + rw [Nat.cast_sub hn1] + simp [M] + have hm : 5 ≤ n - 1 := by omega + rw [← hM] at hhalf ⊢ + by_cases hfinite : n - 1 ≤ 81 + · exact (distillFinite_scalar hm hfinite hα (by linarith) h17).trans (by norm_num) + · have hlarge : (81 : ℝ) ≤ (n - 1 : ℕ) := by exact_mod_cast (show 81 ≤ n - 1 by omega) + exact (distillScalar_lt_two_thirds hlarge hα h17).trans (by norm_num) + +end Sendov diff --git a/Sendov/Common/DistillationCritical.lean b/Sendov/Common/DistillationCritical.lean new file mode 100644 index 0000000..63f1dbf --- /dev/null +++ b/Sendov/Common/DistillationCritical.lean @@ -0,0 +1,513 @@ +import Sendov.Common.DistillationFactors + +/-! +# Critical polynomials and derivatives of the distillation components + +Adaptation of Senjian An, *Proof Distillation for Sendov's Conjecture*, +revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, Appendix B and (5.2)--(5.4). +Paper: CC BY 4.0, https://creativecommons.org/licenses/by/4.0/ . +The three definitions use exactly the descending coefficient order of +`verification/verify_paper.py`. They are not the old Sendov R or T1. +-/ + +namespace Sendov + +noncomputable def distillCritical0 (m α : ℝ) : ℝ := + -4176 * α ^ 7 + 2 * (1363 * m - 36072) * α ^ 6 + + (-377 * m ^ 2 + 22092 * m - 514512) * α ^ 5 + + 12 * (103 * m ^ 2 - 1323 * m - 161676) * α ^ 4 + + 1134 * (49 * m ^ 2 - 566 * m - 3600) * α ^ 3 + + 486 * (665 * m ^ 2 - 4752 * m - 9360) * α ^ 2 + + 972 * (743 * m ^ 2 - 3330 * m - 2160) * α + 43740 * m * (13 * m - 36) + +noncomputable def distillCritical1 (m α : ℝ) : ℝ := + 1392 * (m - 1) * α ^ 7 - 4 * (174 * m ^ 2 - 8279 * m + 4392) * α ^ 6 - + 2 * (2914 * m ^ 2 - 158961 * m + 34992) * α ^ 5 - + 3 * (783 * m ^ 3 - m ^ 2 - 538848 * m + 6048) * α ^ 4 - + 216 * (140 * m ^ 3 - 609 * m ^ 2 - 21974 * m - 2610) * α ^ 3 - + 216 * (660 * m ^ 3 - 2164 * m ^ 2 - 37581 * m - 6480) * α ^ 2 - + 648 * (450 * m ^ 3 - 934 * m ^ 2 - 11655 * m - 1620) * α - + 14580 * m * (15 * m ^ 2 - 17 * m - 204) + +noncomputable def distillCritical2 (m α : ℝ) : ℝ := + 116 * α ^ 4 + 2 * (110 * m + 453) * α ^ 3 - + 3 * (27 * m ^ 2 - 565 * m - 720) * α ^ 2 - + 540 * (m ^ 2 - 7 * m - 3) * α - 810 * m * (m - 3) + +noncomputable def distillN (α : ℝ) : ℝ := 29 * α ^ 2 + 180 * α + 270 + +noncomputable def distillB (m α : ℝ) : ℝ := + 24 * α ^ 4 + (37 * m + 216) * α ^ 3 + (252 * m + 648) * α ^ 2 + + (486 * m + 648) * α + 216 * m + +noncomputable def distillD (m α : ℝ) : ℝ := 50 * m * (α + 3) ^ 3 - distillB m α + +noncomputable def distillK (m α : ℝ) : ℝ := + (α + 3) * (m - 2 * α) * (58 * α + 180) - + (3 * (m - 2 * α) + 4 * (α + 3)) * distillN α + +noncomputable def distillRp (m α : ℝ) : ℝ := + (α + 3) * (96 * α ^ 3 + 3 * (37 * m + 216) * α ^ 2 + + 2 * (252 * m + 648) * α + (486 * m + 648)) - 3 * distillB m α + +noncomputable def distillL (α : ℝ) : ℝ := 81 * α ^ 2 + 540 * α + 810 + +lemma distillCritical0_eq (m α : ℝ) : + distillCritical0 m α = distillK m α * distillD m α + + 4 * (m - 2 * α) * distillN α * distillRp m α := by + unfold distillCritical0 distillK distillD distillN distillRp distillB + ring + +lemma distillCritical1_eq (m α : ℝ) : + distillCritical1 m α = -2 * distillK m α * distillB m α - + (m - 3) * (m - 2 * α) * distillN α * distillRp m α := by + unfold distillCritical1 distillK distillN distillRp distillB + ring + +lemma distillCritical2_eq (m α : ℝ) : + distillCritical2 m α = -2 * α * distillK m α - + (m - 3) * (m - 2 * α) * distillL α := by + unfold distillCritical2 distillK distillN distillL + ring + +lemma distillRatio_compact {α : ℝ} (hα : 0 ≤ α) : + distillRatio α = distillN α / (30 * (α + 3) ^ 3) := by + have ht : α + 3 ≠ 0 := by linarith + unfold distillRatio distillN + field_simp [ht] + ring + +lemma cubicPolarEnvelope_compact {α : ℝ} (hα : 0 ≤ α) : + cubicPolarEnvelope α = α * distillN α / (30 * (α + 3) ^ 3) := by + have ht : α + 3 ≠ 0 := by linarith + unfold cubicPolarEnvelope distillN + field_simp [ht] + ring + +lemma distillNode_compact {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : + distillNode m α = distillB m α / (50 * m * (α + 3) ^ 3) := by + rw [distillNode, cubicPolarEnvelope_compact hα] + have ht : α + 3 ≠ 0 := by linarith + unfold distillB distillN + field_simp [ht, hm.ne'] + ring + +lemma distillD_eq {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : + distillD m α = 50 * m * (α + 3) ^ 3 * (1 - distillNode m α) := by + rw [distillNode_compact hm hα, distillD] + have ht : α + 3 ≠ 0 := by linarith + field_simp [ht, hm.ne'] + +lemma distillN_pos {α : ℝ} (hα : 0 ≤ α) : 0 < distillN α := by + unfold distillN + positivity + +lemma distillB_pos {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : + 0 < distillB m α := by + unfold distillB + positivity + +lemma distillD_pos {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) (hαm : α ≤ m / 2) : + 0 < distillD m α := by + rw [distillD_eq hm hα] + have := distillNode_lt_one hm hα hαm + have : 0 < α + 3 := by linarith + positivity + +lemma distillRatio_pos {α : ℝ} (hα : 0 ≤ α) : 0 < distillRatio α := by + rw [distillRatio_compact hα] + exact div_pos (distillN_pos hα) (by positivity) + +lemma cubicPolarEnvelope_pos {α : ℝ} (hα : 0 < α) : 0 < cubicPolarEnvelope α := by + rw [cubicPolarEnvelope_compact hα.le] + exact div_pos (mul_pos hα (distillN_pos hα.le)) (by positivity) + +lemma distillKappa_pos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 ≤ α) (hαm : 2 * α < m) : + 0 < distillKappa m α := by + have hs : 0 < m ^ 2 - 1 := by nlinarith + have hq : 0 < m - 2 * α := by linarith + have hr := distillRatio_pos hα + unfold distillKappa + positivity + +lemma distillT0_pos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 ≤ α) (hαm : 2 * α < m) : + 0 < distillT0 m α := by + have hk := distillKappa_pos hm hα hαm + have hb := distillNode_lt_one (by linarith : 0 < m) hα (by linarith) + have hm1 : 0 < m - 1 := by linarith + unfold distillT0 + positivity + +lemma distillT1_pos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 ≤ α) (hαm : 2 * α < m) : + 0 < distillT1 m α := by + have hk := distillKappa_pos hm hα hαm + have hb := distillNode_pos (by linarith : 0 < m) hα + unfold distillT1 + positivity + +lemma distillT2_pos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : + 0 < distillT2 m α := by + have hk := distillKappa_pos hm hα.le hαm + have he := cubicPolarEnvelope_pos hα + unfold distillT2 + positivity + +lemma distillRatio_continuousOn : ContinuousOn distillRatio (Set.Ici 0) := by + unfold distillRatio + have hd : ∀ α ∈ Set.Ici (0 : ℝ), α + 3 ≠ 0 := by + intro α hα + have : 0 ≤ α := hα + linarith + have hu : ContinuousOn (fun α : ℝ ↦ α / (α + 3)) (Set.Ici 0) := + continuousOn_id.div (continuousOn_id.add continuousOn_const) hd + fun_prop + +lemma cubicPolarEnvelope_continuousOn : ContinuousOn cubicPolarEnvelope (Set.Ici 0) := by + unfold cubicPolarEnvelope + have hd : ∀ α ∈ Set.Ici (0 : ℝ), α + 3 ≠ 0 := by + intro α hα + have : 0 ≤ α := hα + linarith + have hu : ContinuousOn (fun α : ℝ ↦ α / (α + 3)) (Set.Ici 0) := + continuousOn_id.div (continuousOn_id.add continuousOn_const) hd + fun_prop + +lemma distillKappa_continuousOn (m : ℝ) : + ContinuousOn (distillKappa m) (Set.Ici 0) := by + unfold distillKappa + exact (continuousOn_const.mul distillRatio_continuousOn).mul (by fun_prop) + +lemma distillNode_continuousOn (m : ℝ) : ContinuousOn (distillNode m) (Set.Ici 0) := by + unfold distillNode + exact (continuousOn_const.add + (continuousOn_const.mul cubicPolarEnvelope_continuousOn)).add (by fun_prop) + +lemma distillT0_continuousOn {m : ℝ} (hm : 5 ≤ m) : + ContinuousOn (distillT0 m) (Set.Icc 0 (m / 2)) := by + have hk := (distillKappa_continuousOn m).mono (Set.Icc_subset_Ici_self (a := m / 2)) + have hb := (distillNode_continuousOn m).mono (Set.Icc_subset_Ici_self (a := m / 2)) + unfold distillT0 + apply hk.mul + apply continuousOn_const.div + · exact continuousOn_const.mul ((continuousOn_const.sub hb).pow 4) + · intro α hα + have hm1 : 0 < m - 1 := by linarith + have hn := distillNode_lt_one (by linarith : 0 < m) hα.1 hα.2 + positivity + +lemma distillT1_continuousOn {m : ℝ} (hm : 5 ≤ m) : + ContinuousOn (distillT1 m) (Set.Icc 0 (m / 2)) := by + have hk := (distillKappa_continuousOn m).mono (Set.Icc_subset_Ici_self (a := m / 2)) + have hb := (distillNode_continuousOn m).mono (Set.Icc_subset_Ici_self (a := m / 2)) + unfold distillT1 + exact (continuousOn_const.mul hk).mul (hb.rpow_const (fun _ _ ↦ Or.inr (by linarith))) + +lemma distillT2_continuousOn {m : ℝ} (hm : 5 ≤ m) : + ContinuousOn (distillT2 m) (Set.Icc 0 (m / 2)) := by + have hk := (distillKappa_continuousOn m).mono (Set.Icc_subset_Ici_self (a := m / 2)) + have he := cubicPolarEnvelope_continuousOn.mono (Set.Icc_subset_Ici_self (a := m / 2)) + unfold distillT2 + exact (continuousOn_const.mul hk).mul (he.rpow_const (fun _ _ ↦ Or.inr (by linarith))) + +/- The derivative calculation is factored through small logarithmic-slope +identities. No expanded degree-seven polynomial enters rational simplification. -/ +private lemma hasDerivAt_distillU {α : ℝ} (hα : 0 ≤ α) : + HasDerivAt (fun x : ℝ ↦ x / (x + 3)) (3 / (α + 3) ^ 2) α := by + have ht : α + 3 ≠ 0 := by linarith + convert! (hasDerivAt_id α).div ((hasDerivAt_id α).add_const 3) ht using 1 + simp only [id_eq] + ring + +lemma hasDerivAt_distillRatio {α : ℝ} (hα : 0 ≤ α) : + HasDerivAt distillRatio + (distillRatio α * ((58 * α + 180) / distillN α - 3 / (α + 3))) α := by + have hu := hasDerivAt_distillU hα + have ht : α + 3 ≠ 0 := by linarith + have hn := (distillN_pos hα).ne' + convert! ((hu.const_sub 1).mul ((hu.pow 2 |>.div_const 30).const_sub 1)).div_const 3 + using 1 + · rw [distillRatio_compact hα] + norm_num only [Pi.pow_apply, Nat.reduceSub, Nat.cast_ofNat, pow_one, mul_one] + field_simp [ht, hn] + unfold distillN + ring + +lemma hasDerivAt_cubicPolarEnvelope {α : ℝ} (hα : 0 ≤ α) : + HasDerivAt cubicPolarEnvelope (distillL α / (30 * (α + 3) ^ 4)) α := by + have hu := hasDerivAt_distillU hα + have ht : α + 3 ≠ 0 := by linarith + convert! hu.sub ((hu.pow 3).div_const 30) using 1 + · unfold distillL + norm_num only [Nat.reduceSub, Nat.cast_ofNat] + field_simp [ht] + ring + +lemma hasDerivAt_distillNode {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : + HasDerivAt (distillNode m) (distillRp m α / (50 * m * (α + 3) ^ 4)) α := by + have he := hasDerivAt_cubicPolarEnvelope hα + have ht : α + 3 ≠ 0 := by linarith + convert! ((he.const_mul (3 / 5)).const_add (4 / 25)).add + (((hasDerivAt_id α).const_mul 12).div_const (25 * m)) using 1 + · field_simp [ht, hm.ne'] + unfold distillRp distillB distillL + ring + +lemma hasDerivAt_distillKappa {m α : ℝ} (hα : 0 ≤ α) (hαm : 2 * α < m) : + HasDerivAt (distillKappa m) + (distillKappa m α * (distillK m α / ((α + 3) * (m - 2 * α) * distillN α))) α := by + have hr := hasDerivAt_distillRatio hα + have ht : α + 3 ≠ 0 := by linarith + have hq : m - 2 * α ≠ 0 := by linarith + have hn := (distillN_pos hα).ne' + convert! (hr.const_mul ((m ^ 2 - 1) / (4 * m))).mul + ((((hasDerivAt_id α).const_mul 2).const_sub m).pow 2) using 1 + · unfold distillKappa distillK + norm_num only [Pi.pow_apply, id_eq, Nat.reduceSub, Nat.cast_ofNat, pow_one, mul_one] + field_simp [ht, hq, hn] + ring + +private lemma hasDerivAt_mul_slope {f g : ℝ → ℝ} {α u v : ℝ} + (hf : HasDerivAt f (f α * u) α) (hg : HasDerivAt g (g α * v) α) : + HasDerivAt (fun x ↦ f x * g x) (f α * g α * (u + v)) α := by + convert! hf.mul hg using 1 + ring + +private lemma hasDerivAt_rpow_slope {f : ℝ → ℝ} {α u p : ℝ} + (hf : HasDerivAt f (f α * u) α) (hpos : 0 < f α) : + HasDerivAt (fun x ↦ f x ^ p) (f α ^ p * (p * u)) α := by + convert! hf.rpow_const (Or.inl hpos.ne') using 1 + rw [Real.rpow_sub hpos, Real.rpow_one] + field_simp + +private lemma hasDerivAt_distillNode_slope {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : + HasDerivAt (distillNode m) + (distillNode m α * (distillRp m α / ((α + 3) * distillB m α))) α := by + convert! hasDerivAt_distillNode hm hα using 1 + rw [distillNode_compact hm hα] + have ht : α + 3 ≠ 0 := by linarith + have hb := (distillB_pos hm hα).ne' + field_simp [ht, hb, hm.ne'] + +private lemma hasDerivAt_cubicPolarEnvelope_slope {α : ℝ} (hα : 0 < α) : + HasDerivAt cubicPolarEnvelope + (cubicPolarEnvelope α * (distillL α / (α * (α + 3) * distillN α))) α := by + convert! hasDerivAt_cubicPolarEnvelope hα.le using 1 + rw [cubicPolarEnvelope_compact hα.le] + have ht : α + 3 ≠ 0 := by linarith + have hn := (distillN_pos hα.le).ne' + field_simp [ht, hn, hα.ne'] + +lemma hasDerivAt_distillT1 {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : + HasDerivAt (distillT1 m) + (distillT1 m α * (-distillCritical1 m α / + (2 * (α + 3) * (m - 2 * α) * distillN α * distillB m α))) α := by + have hm0 : 0 < m := by linarith + have hk := hasDerivAt_distillKappa hα.le hαm + have hb := hasDerivAt_rpow_slope (p := (m - 3) / 2) + (hasDerivAt_distillNode_slope hm0 hα.le) (distillNode_pos hm0 hα.le) + have hs : distillK m α / ((α + 3) * (m - 2 * α) * distillN α) + + (m - 3) / 2 * (distillRp m α / ((α + 3) * distillB m α)) = + -distillCritical1 m α / + (2 * (α + 3) * (m - 2 * α) * distillN α * distillB m α) := by + rw [distillCritical1_eq] + have ht : α + 3 ≠ 0 := by linarith + have hq : m - 2 * α ≠ 0 := by linarith + have hn := (distillN_pos hα.le).ne' + have hB := (distillB_pos hm0 hα.le).ne' + generalize hq' : m - 2 * α = q at hq ⊢ + field_simp [ht, hq, hn, hB] + ring + have hd := (hasDerivAt_mul_slope hk hb).const_mul (259 / 3125) + rw [hs] at hd + unfold distillT1 + simpa only [mul_assoc] using hd + +lemma hasDerivAt_distillT2 {m α : ℝ} (_hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : + HasDerivAt (distillT2 m) + (distillT2 m α * (-distillCritical2 m α / + (2 * α * (α + 3) * (m - 2 * α) * distillN α))) α := by + have hk := hasDerivAt_distillKappa hα.le hαm + have he := hasDerivAt_rpow_slope (p := (m - 3) / 2) + (hasDerivAt_cubicPolarEnvelope_slope hα) (cubicPolarEnvelope_pos hα) + have hs : distillK m α / ((α + 3) * (m - 2 * α) * distillN α) + + (m - 3) / 2 * (distillL α / (α * (α + 3) * distillN α)) = + -distillCritical2 m α / + (2 * α * (α + 3) * (m - 2 * α) * distillN α) := by + rw [distillCritical2_eq] + have ht : α + 3 ≠ 0 := by linarith + have hq : m - 2 * α ≠ 0 := by linarith + have hn := (distillN_pos hα.le).ne' + generalize hq' : m - 2 * α = q at hq ⊢ + field_simp [ht, hq, hn, hα.ne'] + ring + have hd := (hasDerivAt_mul_slope hk he).const_mul (421 / 3125) + rw [hs] at hd + unfold distillT2 + simpa only [mul_assoc] using hd + +private lemma hasDerivAt_reciprocal_quartic {f : ℝ → ℝ} {α d A C : ℝ} + (hf : HasDerivAt f d α) (hC : C ≠ 0) (hb : 1 - f α ≠ 0) : + HasDerivAt (fun x ↦ A / (C * (1 - f x) ^ 4)) + ((A / (C * (1 - f α) ^ 4)) * (4 * d / (1 - f α))) α := by + convert! (hasDerivAt_const α A).div (((hf.const_sub 1).pow 4).const_mul C) + (mul_ne_zero hC (pow_ne_zero 4 hb)) using 1 + norm_num only [Pi.pow_apply, Nat.reduceSub, Nat.cast_ofNat] + field_simp [hC, hb] + ring + +lemma hasDerivAt_distillT0 {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : + HasDerivAt (distillT0 m) + (distillT0 m α * (distillCritical0 m α / + ((α + 3) * (m - 2 * α) * distillN α * distillD m α))) α := by + have hm0 : 0 < m := by linarith + have ht : α + 3 ≠ 0 := by linarith + have hq : m - 2 * α ≠ 0 := by linarith + have hn := (distillN_pos hα.le).ne' + have hD := (distillD_pos hm0 hα.le (by linarith)).ne' + have hb : 1 - distillNode m α ≠ 0 := + (sub_pos.mpr (distillNode_lt_one hm0 hα.le (by linarith))).ne' + have hC : (m - 1) * (m + 1) * (m + 3) * (m + 5) ≠ 0 := by + have hm1 : 0 < m - 1 := by linarith + positivity + have hfrac := hasDerivAt_reciprocal_quartic (A := 96 * (3 / 5) ^ 4) + (hasDerivAt_distillNode hm0 hα.le) hC hb + have hs₀ : 4 * (distillRp m α / (50 * m * (α + 3) ^ 4)) / + (1 - distillNode m α) = 4 * distillRp m α / ((α + 3) * distillD m α) := by + rw [distillD_eq hm0 hα.le] + field_simp [ht, hb, hm0.ne'] + rw [hs₀] at hfrac + have hs : distillK m α / ((α + 3) * (m - 2 * α) * distillN α) + + 4 * distillRp m α / ((α + 3) * distillD m α) = + distillCritical0 m α / ((α + 3) * (m - 2 * α) * distillN α * distillD m α) := by + rw [distillCritical0_eq] + generalize hq' : m - 2 * α = q at hq ⊢ + field_simp [ht, hq, hn, hD] + have hd := hasDerivAt_mul_slope (hasDerivAt_distillKappa hα.le hαm) hfrac + rw [hs] at hd + exact hd + +lemma distillT0_denom_pos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : + 0 < (α + 3) * (m - 2 * α) * distillN α * distillD m α := by + have hq : 0 < m - 2 * α := by linarith + have hn := distillN_pos hα.le + have hd := distillD_pos (by linarith : 0 < m) hα.le (by linarith) + positivity + +lemma distillT1_denom_pos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : + 0 < 2 * (α + 3) * (m - 2 * α) * distillN α * distillB m α := by + have hq : 0 < m - 2 * α := by linarith + have hn := distillN_pos hα.le + have hb := distillB_pos (by linarith : 0 < m) hα.le + positivity + +lemma distillT2_denom_pos {m α : ℝ} (_hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : + 0 < 2 * α * (α + 3) * (m - 2 * α) * distillN α := by + have hq : 0 < m - 2 * α := by linarith + have hn := distillN_pos hα.le + positivity + +lemma distillT0_deriv_nonneg_iff {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α < m) : + 0 ≤ deriv (distillT0 m) α ↔ 0 ≤ distillCritical0 m α := by + rw [(hasDerivAt_distillT0 hm hα hαm).deriv] + have ht := distillT0_pos hm hα.le hαm + have hd := distillT0_denom_pos hm hα hαm + rw [mul_nonneg_iff_of_pos_left ht, le_div_iff₀ hd, zero_mul] + +lemma distillT0_deriv_nonneg {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α < m) (hp : 0 ≤ distillCritical0 m α) : + 0 ≤ deriv (distillT0 m) α := + (distillT0_deriv_nonneg_iff hm hα hαm).mpr hp + +lemma distillT0_deriv_nonpos_iff {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α < m) : + deriv (distillT0 m) α ≤ 0 ↔ distillCritical0 m α ≤ 0 := by + rw [(hasDerivAt_distillT0 hm hα hαm).deriv] + have ht := distillT0_pos hm hα.le hαm + have hd := distillT0_denom_pos hm hα hαm + constructor + · intro h + have hnum := (div_le_iff₀ hd).mp (nonpos_of_mul_nonpos_right h ht) + simp only [zero_mul] at hnum + exact hnum + · intro hp + apply mul_nonpos_of_nonneg_of_nonpos ht.le + apply div_nonpos_of_nonpos_of_nonneg _ hd.le + exact hp + +lemma distillT0_deriv_nonpos {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α < m) (hp : distillCritical0 m α ≤ 0) : + deriv (distillT0 m) α ≤ 0 := + (distillT0_deriv_nonpos_iff hm hα hαm).mpr hp + +lemma distillT1_deriv_nonneg_iff {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α < m) : + 0 ≤ deriv (distillT1 m) α ↔ distillCritical1 m α ≤ 0 := by + rw [(hasDerivAt_distillT1 hm hα hαm).deriv] + have ht := distillT1_pos hm hα.le hαm + have hd := distillT1_denom_pos hm hα hαm + rw [mul_nonneg_iff_of_pos_left ht, le_div_iff₀ hd, zero_mul] + exact neg_nonneg + +lemma distillT1_deriv_nonneg {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α < m) (hp : distillCritical1 m α ≤ 0) : + 0 ≤ deriv (distillT1 m) α := + (distillT1_deriv_nonneg_iff hm hα hαm).mpr hp + +lemma distillT1_deriv_nonpos_iff {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α < m) : + deriv (distillT1 m) α ≤ 0 ↔ 0 ≤ distillCritical1 m α := by + rw [(hasDerivAt_distillT1 hm hα hαm).deriv] + have ht := distillT1_pos hm hα.le hαm + have hd := distillT1_denom_pos hm hα hαm + constructor + · intro h + have hnum := (div_le_iff₀ hd).mp (nonpos_of_mul_nonpos_right h ht) + simp only [zero_mul] at hnum + exact neg_nonpos.mp hnum + · intro hp + apply mul_nonpos_of_nonneg_of_nonpos ht.le + apply div_nonpos_of_nonpos_of_nonneg _ hd.le + exact neg_nonpos.mpr hp + +lemma distillT1_deriv_nonpos {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α < m) (hp : 0 ≤ distillCritical1 m α) : + deriv (distillT1 m) α ≤ 0 := + (distillT1_deriv_nonpos_iff hm hα hαm).mpr hp + +lemma distillT2_deriv_nonneg_iff {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α < m) : + 0 ≤ deriv (distillT2 m) α ↔ distillCritical2 m α ≤ 0 := by + rw [(hasDerivAt_distillT2 hm hα hαm).deriv] + have ht := distillT2_pos hm hα hαm + have hd := distillT2_denom_pos hm hα hαm + rw [mul_nonneg_iff_of_pos_left ht, le_div_iff₀ hd, zero_mul] + exact neg_nonneg + +lemma distillT2_deriv_nonneg {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α < m) (hp : distillCritical2 m α ≤ 0) : + 0 ≤ deriv (distillT2 m) α := + (distillT2_deriv_nonneg_iff hm hα hαm).mpr hp + +lemma distillT2_deriv_nonpos_iff {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α < m) : + deriv (distillT2 m) α ≤ 0 ↔ 0 ≤ distillCritical2 m α := by + rw [(hasDerivAt_distillT2 hm hα hαm).deriv] + have ht := distillT2_pos hm hα hαm + have hd := distillT2_denom_pos hm hα hαm + constructor + · intro h + have hnum := (div_le_iff₀ hd).mp (nonpos_of_mul_nonpos_right h ht) + simp only [zero_mul] at hnum + exact neg_nonpos.mp hnum + · intro hp + apply mul_nonpos_of_nonneg_of_nonpos ht.le + apply div_nonpos_of_nonpos_of_nonneg _ hd.le + exact neg_nonpos.mpr hp + +lemma distillT2_deriv_nonpos {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α < m) (hp : 0 ≤ distillCritical2 m α) : + deriv (distillT2 m) α ≤ 0 := + (distillT2_deriv_nonpos_iff hm hα hαm).mpr hp + +end Sendov diff --git a/Sendov/Common/DistillationCriticalFinite.lean b/Sendov/Common/DistillationCriticalFinite.lean new file mode 100644 index 0000000..e5d0700 --- /dev/null +++ b/Sendov/Common/DistillationCriticalFinite.lean @@ -0,0 +1,130 @@ +import Sendov.Common.DistillationCritical +import Sendov.Common.DistillationMajorant +import Sendov.Common.BernsteinCert +import Sendov.Common.BernsteinRing +import Mathlib.Analysis.Calculus.Deriv.MeanValue + +/-! +# Finite critical-bracket bounds + +Critical polynomials and fixed budgets from Senjian An, *Proof Distillation for +Sendov's Conjecture*, e8ae601491ec171ab4f7f8456113dd6a047aa85d (paper CC BY 4.0). +New Lean proofs, Apache-2.0 as the baseline. The interval outside the bracket is +controlled analytically; only the bracket uses the mixed factor estimate. +-/ +namespace Sendov + +/-- Two monotone flanks and a bounded central bracket cover the exact closed domain. +Degenerate flanks are allowed: their derivative hypotheses have empty open domains. -/ +lemma distillPeak_le {f : ℝ → ℝ} {d l r b x : ℝ} + (hl : 0 ≤ l) (hlr : l ≤ r) (hr : r ≤ d) + (hc : ContinuousOn f (Set.Icc 0 d)) + (hd : ∀ x ∈ Set.Ioo 0 d, DifferentiableAt ℝ f x) + (hp : ∀ x ∈ Set.Ioo 0 l, 0 ≤ deriv f x) + (hn : ∀ x ∈ Set.Ioo r d, deriv f x ≤ 0) + (hb : ∀ x ∈ Set.Icc l r, f x ≤ b) (hx : x ∈ Set.Icc 0 d) : f x ≤ b := by + have hld : l ≤ d := hlr.trans hr + have hr0 : 0 ≤ r := hl.trans hlr + have hleft : MonotoneOn f (Set.Icc 0 l) := by + apply monotoneOn_of_deriv_nonneg (convex_Icc _ _) + (hc.mono (Set.Icc_subset_Icc le_rfl hld)) + · rw [interior_Icc] + intro y hy + exact (hd y ⟨hy.1, hy.2.trans_le hld⟩).differentiableWithinAt + · simpa only [interior_Icc] using hp + have hright : AntitoneOn f (Set.Icc r d) := by + apply antitoneOn_of_deriv_nonpos (convex_Icc _ _) + (hc.mono (Set.Icc_subset_Icc hr0 le_rfl)) + · rw [interior_Icc] + intro y hy + exact (hd y ⟨hr0.trans_lt hy.1, hy.2⟩).differentiableWithinAt + · simpa only [interior_Icc] using hn + by_cases hxl : x ≤ l + · exact (hleft ⟨hx.1, hxl⟩ ⟨hl, le_rfl⟩ hxl).trans (hb l ⟨le_rfl, hlr⟩) + by_cases hxr : x ≤ r + · exact hb x ⟨le_of_not_ge hxl, hxr⟩ + · have hrx : r ≤ x := le_of_not_ge hxr + exact (hright ⟨le_rfl, hr⟩ ⟨hrx, hx.2⟩ hrx).trans (hb r ⟨hlr, le_rfl⟩) + +/-- Squaring half-integer powers is exact, also at zero. -/ +lemma distillRpow_half_sq {b : ℝ} (hb : 0 ≤ b) (n : ℕ) : + (b ^ ((n : ℝ) / 2)) ^ 2 = b ^ n := by + rw [← Real.rpow_natCast, ← Real.rpow_mul hb] + norm_num + +lemma distillMulRpow_le_of_sq {a b c m : ℝ} (n : ℕ) + (hb : 0 ≤ b) (hc : 0 ≤ c) (hn : (m - 3) / 2 = (n : ℝ) / 2) + (hsq : a ^ 2 * b ^ n ≤ c ^ 2) : a * b ^ ((m - 3) / 2) ≤ c := by + have hid : (a * b ^ ((m - 3) / 2)) ^ 2 = a ^ 2 * b ^ n := by + rw [mul_pow, hn, distillRpow_half_sq hb] + nlinarith [sq_nonneg (a * b ^ ((m - 3) / 2) - c)] + +/-- Component 0: exact flanks from the critical derivative API and one mixed bracket. -/ +lemma distillT0_le_of_critical {m d l r b α : ℝ} + (hm : 5 ≤ m) (hl : 0 ≤ l) (hlr : l ≤ r) (hr : r ≤ d) (hdm : d ≤ m / 2) + (hp : ∀ x ∈ Set.Ioo 0 l, 0 ≤ distillCritical0 m x) + (hq : ∀ x ∈ Set.Ioo r d, 0 ≤ -distillCritical0 m x) + (hb : distillKappa m l * (96 * (3 / 5) ^ 4 / + ((m - 1) * (m + 1) * (m + 3) * (m + 5) * (1 - distillNode m r) ^ 4)) ≤ b) + (hα : α ∈ Set.Icc 0 d) : distillT0 m α ≤ b := by + apply distillPeak_le hl hlr hr + ((distillT0_continuousOn hm).mono (Set.Icc_subset_Icc le_rfl hdm)) + (fun x hx ↦ (hasDerivAt_distillT0 hm hx.1 (by have := hx.2; linarith)).differentiableAt) + ?_ ?_ ?_ hα + · intro x hx + apply distillT0_deriv_nonneg hm hx.1 (by have := hx.2; linarith) + exact hp x hx + · intro x hx + apply distillT0_deriv_nonpos hm (by have := hx.1; linarith) + (by have := hx.2; linarith) + exact neg_nonneg.mp (hq x hx) + · intro x hx + exact (distillT0_mixed hm hl hx.1 hx.2 (hr.trans hdm)).trans hb + +/-- Component 1: exact flanks from the critical derivative API and one mixed bracket. -/ +lemma distillT1_le_of_critical {m d l r b α : ℝ} + (n : ℕ) (hb0 : 0 ≤ b) (hn : (m - 3) / 2 = (n : ℝ) / 2) + (hm : 5 ≤ m) (hl : 0 ≤ l) (hlr : l ≤ r) (hr : r ≤ d) (hdm : d ≤ m / 2) + (hp : ∀ x ∈ Set.Ioo 0 l, 0 ≤ -distillCritical1 m x) + (hq : ∀ x ∈ Set.Ioo r d, 0 ≤ distillCritical1 m x) + (hb : ((259 / 3125) * distillKappa m l) ^ 2 * (distillNode m r) ^ n ≤ b ^ 2) + (hα : α ∈ Set.Icc 0 d) : distillT1 m α ≤ b := by + apply distillPeak_le hl hlr hr + ((distillT1_continuousOn hm).mono (Set.Icc_subset_Icc le_rfl hdm)) + (fun x hx ↦ (hasDerivAt_distillT1 hm hx.1 (by have := hx.2; linarith)).differentiableAt) + ?_ ?_ ?_ hα + · intro x hx + apply distillT1_deriv_nonneg hm hx.1 (by have := hx.2; linarith) + exact neg_nonneg.mp (hp x hx) + · intro x hx + apply distillT1_deriv_nonpos hm (by have := hx.1; linarith) + (by have := hx.2; linarith) + exact hq x hx + · intro x hx + apply (distillT1_mixed hm hl hx.1 hx.2 (hr.trans hdm)).trans + exact distillMulRpow_le_of_sq n (distillNode_pos (by linarith) (hl.trans hlr)).le hb0 hn hb + +/-- Component 2: exact flanks from the critical derivative API and one mixed bracket. -/ +lemma distillT2_le_of_critical {m d l r b α : ℝ} + (n : ℕ) (hb0 : 0 ≤ b) (hn : (m - 3) / 2 = (n : ℝ) / 2) + (hm : 5 ≤ m) (hl : 0 ≤ l) (hlr : l ≤ r) (hr : r ≤ d) (hdm : d ≤ m / 2) + (hp : ∀ x ∈ Set.Ioo 0 l, 0 ≤ -distillCritical2 m x) + (hq : ∀ x ∈ Set.Ioo r d, 0 ≤ distillCritical2 m x) + (hb : ((421 / 3125) * distillKappa m l) ^ 2 * (cubicPolarEnvelope r) ^ n ≤ b ^ 2) + (hα : α ∈ Set.Icc 0 d) : distillT2 m α ≤ b := by + apply distillPeak_le hl hlr hr + ((distillT2_continuousOn hm).mono (Set.Icc_subset_Icc le_rfl hdm)) + (fun x hx ↦ (hasDerivAt_distillT2 hm hx.1 (by have := hx.2; linarith)).differentiableAt) + ?_ ?_ ?_ hα + · intro x hx + apply distillT2_deriv_nonneg hm hx.1 (by have := hx.2; linarith) + exact neg_nonneg.mp (hp x hx) + · intro x hx + apply distillT2_deriv_nonpos hm (by have := hx.1; linarith) + (by have := hx.2; linarith) + exact hq x hx + · intro x hx + apply (distillT2_mixed hm hl hx.1 hx.2 (hr.trans hdm)).trans + exact distillMulRpow_le_of_sq n (cubicPolarEnvelope_nonneg (hl.trans hlr)) hb0 hn hb + +end Sendov diff --git a/Sendov/Common/DistillationEnvelope.lean b/Sendov/Common/DistillationEnvelope.lean new file mode 100644 index 0000000..51bff22 --- /dev/null +++ b/Sendov/Common/DistillationEnvelope.lean @@ -0,0 +1,89 @@ +import Sendov.Common.DistillationKernel + +/-! +# Rational envelope ingredients and exact scalar coordinates + +New Lean proofs of the algebraic/monotone portion of Senjian An's paper, +revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, Sections 2--4. +Paper licensed CC BY 4.0: https://creativecommons.org/licenses/by/4.0/ . +No theorem here asserts that the polar constraint implies the cubic envelope: +that requires the stronger hyperbolic comparison in Appendix A. +-/ + +namespace Sendov + +open MeasureTheory + +/-- The cubic correction is in `u = α / (α + 3)`, not in alpha itself. -/ +noncomputable def cubicPolarEnvelope (α : ℝ) : ℝ := + let u := α / (α + 3) + u - u ^ 3 / 30 + +lemma cubicPolarEnvelope_nonneg {α : ℝ} (hα : 0 ≤ α) : + 0 ≤ cubicPolarEnvelope α := by + have hd : 0 < α + 3 := by linarith + have hu : 0 ≤ α / (α + 3) := div_nonneg hα hd.le + have hu1 : α / (α + 3) ≤ 1 := (div_le_one hd).mpr (by linarith) + have hu3 := pow_le_pow_left₀ hu hu1 3 + unfold cubicPolarEnvelope + nlinarith [pow_nonneg hu 3, mul_nonneg hu (sub_nonneg.mpr hu1), + mul_nonneg (sq_nonneg (α / (α + 3))) (sub_nonneg.mpr hu1)] + +lemma cubicPolarEnvelope_le_linear {α : ℝ} (hα : 0 ≤ α) : + cubicPolarEnvelope α ≤ α / (α + 3) := by + have hu : 0 ≤ α / (α + 3) := div_nonneg hα (by linarith) + unfold cubicPolarEnvelope + linarith [pow_nonneg hu 3] + +lemma cubicPolarEnvelope_lt_one {α : ℝ} (hα : 0 ≤ α) : + cubicPolarEnvelope α < 1 := by + refine (cubicPolarEnvelope_le_linear hα).trans_lt ?_ + exact (div_lt_one (by linarith : 0 < α + 3)).mpr (by linarith) + +/-- Monotonicity without differentiating a rational function. -/ +lemma cubicPolarEnvelope_mono {α β : ℝ} (hα : 0 ≤ α) (hαβ : α ≤ β) : + cubicPolarEnvelope α ≤ cubicPolarEnvelope β := by + have hβ : 0 ≤ β := hα.trans hαβ + have hdα : 0 < α + 3 := by linarith + have hdβ : 0 < β + 3 := by linarith + set u := α / (α + 3) with hu + set v := β / (β + 3) with hv + have hu0 : 0 ≤ u := div_nonneg hα hdα.le + have hv0 : 0 ≤ v := div_nonneg hβ hdβ.le + have hu1 : u ≤ 1 := (div_le_one hdα).mpr (by linarith) + have hv1 : v ≤ 1 := (div_le_one hdβ).mpr (by linarith) + have huv : u ≤ v := by + dsimp [u, v] + rw [div_le_div_iff₀ hdα hdβ] + nlinarith + have hu2 : u ^ 2 ≤ 1 := by nlinarith [mul_nonneg hu0 (sub_nonneg.mpr hu1)] + have hv2 : v ^ 2 ≤ 1 := by nlinarith [mul_nonneg hv0 (sub_nonneg.mpr hv1)] + have huv1 : u * v ≤ 1 := mul_le_one₀ hu1 hv0 hv1 + have hfactor : 0 ≤ 1 - (v ^ 2 + v * u + u ^ 2) / 30 := by nlinarith + have hprod := mul_nonneg (sub_nonneg.mpr huv) hfactor + change u - u ^ 3 / 30 ≤ v - v ^ 3 / 30 + nlinarith [hprod] + +/-- The paper's exact chord node. -/ +lemma cubicPolarEnvelope_node (m α : ℝ) : + polarKernel m α (cubicPolarEnvelope α) (3 / 5) = + 4 / 25 + 3 / 5 * cubicPolarEnvelope α + 12 * α / (25 * m) := by + unfold polarKernel + ring + +/-- A real consumer of envelope monotonicity in the enlarged parameter domain. -/ +lemma cubicPolarKernel_mono_alpha {m α β t : ℝ} (hm : 0 < m) + (hα : 0 ≤ α) (hαβ : α ≤ β) (ht : t ∈ Set.Icc (0 : ℝ) 1) : + polarKernel m α (cubicPolarEnvelope α) t ≤ + polarKernel m β (cubicPolarEnvelope β) t := by + exact (polarKernel_mono_alpha hm hαβ ht).trans + (polarKernel_mono_eta (cubicPolarEnvelope_mono hα hαβ) ht.1) + +/-- The paper's `H_m(α;η)` at positive alpha. At zero this raw formula is NOT its +continuous extension: real division is total in Lean. -/ +noncomputable def scalarObstruction (m α η : ℝ) : ℝ := + η / (2 * α * (1 - η)) + η / (4 * α) + 1 / (2 * m) + η / (4 * α * m) + + η * (m ^ 2 - 1) * (m - 2 * α) ^ 2 / (4 * α * m) * + ∫ t in (0 : ℝ)..1, t ^ 3 * polarKernel m α η t ^ ((m - 3) / 2) + +end Sendov diff --git a/Sendov/Common/DistillationFactors.lean b/Sendov/Common/DistillationFactors.lean new file mode 100644 index 0000000..b01e890 --- /dev/null +++ b/Sendov/Common/DistillationFactors.lean @@ -0,0 +1,220 @@ +import Sendov.Common.DistillationEnvelope + +/-! +# Regularized distillation factors + +Adaptation of Senjian An (SJanPerth), *Proof Distillation for Sendov's Conjecture*, +revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, Lemma 4.1 and (5.1). +Paper: CC BY 4.0, https://creativecommons.org/licenses/by/4.0/ . +These are new Lean proofs, not imported numerical certificates. The raw scalar +obstruction at zero is not its continuous extension; positive-alpha hypotheses +on the elementary and scalar bridges are intentional. +-/ + +namespace Sendov + +noncomputable def distillRatio (α : ℝ) : ℝ := + (1 - α / (α + 3)) * (1 - (α / (α + 3)) ^ 2 / 30) / 3 + +noncomputable def distillKappa (m α : ℝ) : ℝ := + (m ^ 2 - 1) / (4 * m) * distillRatio α * (m - 2 * α) ^ 2 + +noncomputable def distillNode (m α : ℝ) : ℝ := + 4 / 25 + 3 / 5 * cubicPolarEnvelope α + 12 * α / (25 * m) + +noncomputable def distillEBudget (m : ℝ) : ℝ := 1 / 4 + 7 / (12 * m) + +noncomputable def distillT0 (m α : ℝ) : ℝ := + distillKappa m α * (96 * (3 / 5) ^ 4 / + ((m - 1) * (m + 1) * (m + 3) * (m + 5) * (1 - distillNode m α) ^ 4)) + +noncomputable def distillT1 (m α : ℝ) : ℝ := + (259 / 3125) * distillKappa m α * distillNode m α ^ ((m - 3) / 2) + +noncomputable def distillT2 (m α : ℝ) : ℝ := + (421 / 3125) * distillKappa m α * cubicPolarEnvelope α ^ ((m - 3) / 2) + +@[simp] lemma distillRatio_zero : distillRatio 0 = 1 / 3 := by + norm_num [distillRatio] + +lemma distillRatio_eq {α : ℝ} (hα : 0 < α) : + distillRatio α = cubicPolarEnvelope α / α := by + unfold distillRatio cubicPolarEnvelope + field_simp + ring + +lemma distillRatio_nonneg {α : ℝ} (hα : 0 ≤ α) : 0 ≤ distillRatio α := by + have hd : 0 < α + 3 := by linarith + have hu : 0 ≤ α / (α + 3) := div_nonneg hα hd.le + have hu1 : α / (α + 3) ≤ 1 := (div_le_one hd).mpr (by linarith) + have hu2 := pow_le_pow_left₀ hu hu1 2 + unfold distillRatio + exact div_nonneg (mul_nonneg (by linarith) + (by simp only [one_pow] at hu2; linarith)) (by norm_num) + +lemma distillRatio_antitone {α β : ℝ} (hα : 0 ≤ α) (hαβ : α ≤ β) : + distillRatio β ≤ distillRatio α := by + have hβ : 0 ≤ β := hα.trans hαβ + have hdα : 0 < α + 3 := by linarith + have hdβ : 0 < β + 3 := by linarith + have hu : 0 ≤ α / (α + 3) := div_nonneg hα hdα.le + have hv : 0 ≤ β / (β + 3) := div_nonneg hβ hdβ.le + have hv1 : β / (β + 3) ≤ 1 := (div_le_one hdβ).mpr (by linarith) + have huv : α / (α + 3) ≤ β / (β + 3) := by + rw [div_le_div_iff₀ hdα hdβ] + nlinarith + have hu2 := pow_le_pow_left₀ hu huv 2 + have hv2 := pow_le_pow_left₀ hv hv1 2 + unfold distillRatio + apply div_le_div_of_nonneg_right _ (by norm_num) + apply mul_le_mul (by linarith) (by linarith) (by simp only [one_pow] at hv2; linarith) + linarith + +lemma distillKappa_nonneg {m α : ℝ} (hm : 5 ≤ m) (hα : 0 ≤ α) : + 0 ≤ distillKappa m α := by + unfold distillKappa + exact mul_nonneg (mul_nonneg (div_nonneg (by nlinarith) (by linarith)) + (distillRatio_nonneg hα)) (sq_nonneg _) + +lemma distillKappa_antitone {m α β : ℝ} (hm : 5 ≤ m) + (hα : 0 ≤ α) (hαβ : α ≤ β) (hβ : β ≤ m / 2) : + distillKappa m β ≤ distillKappa m α := by + have hc : 0 ≤ (m ^ 2 - 1) / (4 * m) := + div_nonneg (by nlinarith) (by linarith) + have hsq : (m - 2 * β) ^ 2 ≤ (m - 2 * α) ^ 2 := + pow_le_pow_left₀ (by linarith) (by linarith) 2 + exact mul_le_mul (mul_le_mul_of_nonneg_left (distillRatio_antitone hα hαβ) hc) + hsq (sq_nonneg _) (mul_nonneg hc (distillRatio_nonneg hα)) + +lemma distillNode_eq (m α : ℝ) : + distillNode m α = polarKernel m α (cubicPolarEnvelope α) (3 / 5) := + (cubicPolarEnvelope_node m α).symm + +lemma distillNode_pos {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : + 0 < distillNode m α := by + have he := cubicPolarEnvelope_nonneg hα + have ht : 0 ≤ 12 * α / (25 * m) := div_nonneg (by positivity) (by positivity) + unfold distillNode + linarith + +lemma distillNode_lt_one {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) + (hαm : α ≤ m / 2) : distillNode m α < 1 := by + have he := cubicPolarEnvelope_lt_one hα + have ht : 12 * α / (25 * m) ≤ 6 / 25 := by + apply (div_le_iff₀ (by positivity : 0 < 25 * m)).mpr + linarith + unfold distillNode + linarith + +lemma distillNode_mono {m α β : ℝ} (hm : 0 < m) (hα : 0 ≤ α) + (hαβ : α ≤ β) : distillNode m α ≤ distillNode m β := by + rw [distillNode_eq, distillNode_eq] + exact cubicPolarKernel_mono_alpha hm hα hαβ (by norm_num) + +/-- The elementary part of the raw obstruction, only at positive alpha. -/ +lemma distillElementary_le_budget {m α : ℝ} (hm : 0 < m) (hα : 0 < α) : + cubicPolarEnvelope α / (2 * α * (1 - cubicPolarEnvelope α)) + + cubicPolarEnvelope α / (4 * α) + 1 / (2 * m) + + cubicPolarEnvelope α / (4 * α * m) ≤ distillEBudget m := by + have he := cubicPolarEnvelope_le_linear hα.le + have he1 := cubicPolarEnvelope_lt_one hα.le + have her : cubicPolarEnvelope α ≤ α / 3 := by + have hr := distillRatio_antitone (le_refl 0) hα.le + rw [distillRatio_zero, distillRatio_eq hα] at hr + exact (div_le_iff₀ hα).mp hr |>.trans_eq (by ring) + have hfirst : cubicPolarEnvelope α / (2 * α * (1 - cubicPolarEnvelope α)) ≤ + 1 / 6 := by + apply (div_le_iff₀ (by positivity : 0 < 2 * α * (1 - cubicPolarEnvelope α))).mpr + have := (le_div_iff₀ (by linarith : 0 < α + 3)).mp he + nlinarith + have hsecond : cubicPolarEnvelope α / (4 * α) ≤ 1 / 12 := by + apply (div_le_iff₀ (by positivity : 0 < 4 * α)).mpr + linarith + have hlast : cubicPolarEnvelope α / (4 * α * m) ≤ 1 / (12 * m) := by + rw [div_le_div_iff₀ (by positivity : 0 < 4 * α * m) (by positivity : 0 < 12 * m)] + nlinarith [mul_le_mul_of_nonneg_right her hm.le] + have hid : (1 : ℝ) / 6 + 1 / 12 + 1 / (2 * m) + 1 / (12 * m) = + distillEBudget m := by + unfold distillEBudget + ring + linarith + +/-- The prefactor is regularized only after cancelling a positive alpha. -/ +lemma distillKappa_eq {m α : ℝ} (hα : 0 < α) : + distillKappa m α = + cubicPolarEnvelope α * (m ^ 2 - 1) * (m - 2 * α) ^ 2 / (4 * α * m) := by + rw [distillKappa, distillRatio_eq hα] + ring + +/-- Explicitly record the raw zero endpoint, which is not the continuous extension. -/ +@[simp] lemma scalarObstruction_zero (m : ℝ) : + scalarObstruction m 0 (cubicPolarEnvelope 0) = 1 / (2 * m) := by + simp [scalarObstruction, cubicPolarEnvelope] + +lemma distillT0_mixed {m l α r : ℝ} (hm : 5 ≤ m) (hl : 0 ≤ l) + (hlα : l ≤ α) (hαr : α ≤ r) (hr : r ≤ m / 2) : + distillT0 m α ≤ distillKappa m l * (96 * (3 / 5) ^ 4 / + ((m - 1) * (m + 1) * (m + 3) * (m + 5) * (1 - distillNode m r) ^ 4)) := by + have hm0 : 0 < m := by linarith + have hα0 : 0 ≤ α := hl.trans hlα + have hr0 : 0 ≤ r := hα0.trans hαr + have hnode := distillNode_mono hm0 hα0 hαr + have hnoder := distillNode_lt_one hm0 hr0 hr + have hnodeα := distillNode_lt_one hm0 hα0 (hαr.trans hr) + have hc : 0 < (m - 1) * (m + 1) * (m + 3) * (m + 5) := by + have : 0 < m - 1 := by linarith + positivity + have hd : (m - 1) * (m + 1) * (m + 3) * (m + 5) * + (1 - distillNode m r) ^ 4 ≤ + (m - 1) * (m + 1) * (m + 3) * (m + 5) * (1 - distillNode m α) ^ 4 := + mul_le_mul_of_nonneg_left (pow_le_pow_left₀ (by linarith) (by linarith) 4) hc.le + have hfrac := div_le_div_of_nonneg_left (by positivity : 0 ≤ 96 * (3 / 5 : ℝ) ^ 4) + (by positivity : 0 < (m - 1) * (m + 1) * (m + 3) * (m + 5) * + (1 - distillNode m r) ^ 4) hd + exact mul_le_mul (distillKappa_antitone hm hl hlα (hαr.trans hr)) hfrac + (by positivity) (distillKappa_nonneg hm hl) + +lemma distillT1_mixed {m l α r : ℝ} (hm : 5 ≤ m) (hl : 0 ≤ l) + (hlα : l ≤ α) (hαr : α ≤ r) (hr : r ≤ m / 2) : + distillT1 m α ≤ (259 / 3125) * distillKappa m l * + distillNode m r ^ ((m - 3) / 2) := by + have hm0 : 0 < m := by linarith + have hα0 : 0 ≤ α := hl.trans hlα + have hb := Real.rpow_le_rpow (distillNode_pos hm0 hα0).le + (distillNode_mono hm0 hα0 hαr) (by linarith : 0 ≤ (m - 3) / 2) + exact mul_le_mul + (mul_le_mul_of_nonneg_left (distillKappa_antitone hm hl hlα (hαr.trans hr)) + (by norm_num)) hb (Real.rpow_nonneg (distillNode_pos hm0 hα0).le _) + (mul_nonneg (by norm_num) (distillKappa_nonneg hm hl)) + +lemma distillT2_mixed {m l α r : ℝ} (hm : 5 ≤ m) (hl : 0 ≤ l) + (hlα : l ≤ α) (hαr : α ≤ r) (hr : r ≤ m / 2) : + distillT2 m α ≤ (421 / 3125) * distillKappa m l * + cubicPolarEnvelope r ^ ((m - 3) / 2) := by + have hα0 : 0 ≤ α := hl.trans hlα + have hb := Real.rpow_le_rpow (cubicPolarEnvelope_nonneg hα0) + (cubicPolarEnvelope_mono hα0 hαr) (by linarith : 0 ≤ (m - 3) / 2) + exact mul_le_mul + (mul_le_mul_of_nonneg_left (distillKappa_antitone hm hl hlα (hαr.trans hr)) + (by norm_num)) hb (Real.rpow_nonneg (cubicPolarEnvelope_nonneg hα0) _) + (mul_nonneg (by norm_num) (distillKappa_nonneg hm hl)) + +/-- Algebraic assembly for a separately proved two-chord integral bound. +No integral estimate or polar implication is asserted by this interface. -/ +lemma distillScalar_le_components {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) + (hJ : (∫ t in (0 : ℝ)..1, + t ^ 3 * polarKernel m α (cubicPolarEnvelope α) t ^ ((m - 3) / 2)) ≤ + 96 * (3 / 5) ^ 4 / + ((m - 1) * (m + 1) * (m + 3) * (m + 5) * (1 - distillNode m α) ^ 4) + + (259 / 3125) * distillNode m α ^ ((m - 3) / 2) + + (421 / 3125) * cubicPolarEnvelope α ^ ((m - 3) / 2)) : + scalarObstruction m α (cubicPolarEnvelope α) ≤ + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α := by + have hE := distillElementary_le_budget (by linarith : 0 < m) hα + have hK := mul_le_mul_of_nonneg_left hJ (distillKappa_nonneg hm hα.le) + unfold scalarObstruction + rw [← distillKappa_eq hα] + unfold distillT0 distillT1 distillT2 + nlinarith + +end Sendov diff --git a/Sendov/Common/DistillationFinite.lean b/Sendov/Common/DistillationFinite.lean new file mode 100644 index 0000000..f57ebbc --- /dev/null +++ b/Sendov/Common/DistillationFinite.lean @@ -0,0 +1,106 @@ +import Sendov.DistillationFinite.Rows5_12 +import Sendov.DistillationFinite.Rows13_20 +import Sendov.DistillationFinite.Rows21_28 +import Sendov.DistillationFinite.Rows29_36 +import Sendov.DistillationFinite.Rows37_44 +import Sendov.DistillationFinite.Rows45_52 +import Sendov.DistillationFinite.Rows53_60 +import Sendov.DistillationFinite.Rows61_68 +import Sendov.DistillationFinite.Rows69_76 +import Sendov.DistillationFinite.Rows77_80 +import Sendov.DistillationFinite.Row81 + +/-! Exact finite-domain critical-bracket closure. Fixed original paper budgets; +see DistillationCriticalFinite for attribution. No sampled truth or global T grid. -/ +namespace Sendov + +theorem distillFinite_components {m : ℕ} (hm : 5 ≤ m) (hm81 : m ≤ 81) + {α : ℝ} (hα : 0 ≤ α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := by + interval_cases m + · exact (distillFinite_5 α hα (by linarith)).trans_lt distillFiniteBound_5 + · exact (distillFinite_6 α hα (by linarith)).trans_lt distillFiniteBound_6 + · exact (distillFinite_7 α hα (by linarith)).trans_lt distillFiniteBound_7 + · exact (distillFinite_8 α hα (by linarith)).trans_lt distillFiniteBound_8 + · exact (distillFinite_9 α hα (by linarith)).trans_lt distillFiniteBound_9 + · exact (distillFinite_10 α hα (by linarith)).trans_lt distillFiniteBound_10 + · exact (distillFinite_11 α hα (by linarith)).trans_lt distillFiniteBound_11 + · exact (distillFinite_12 α hα (by linarith)).trans_lt distillFiniteBound_12 + · exact (distillFinite_13 α hα (by linarith)).trans_lt distillFiniteBound_13 + · exact (distillFinite_14 α hα (by linarith)).trans_lt distillFiniteBound_14 + · exact (distillFinite_15 α hα (by linarith)).trans_lt distillFiniteBound_15 + · exact (distillFinite_16 α hα (by linarith)).trans_lt distillFiniteBound_16 + · exact (distillFinite_17 α hα (by linarith)).trans_lt distillFiniteBound_17 + · exact (distillFinite_18 α hα (by linarith)).trans_lt distillFiniteBound_18 + · exact (distillFinite_19 α hα (by linarith)).trans_lt distillFiniteBound_19 + · exact (distillFinite_20 α hα (by linarith)).trans_lt distillFiniteBound_20 + · exact (distillFinite_21 α hα (by linarith)).trans_lt distillFiniteBound_21 + · exact (distillFinite_22 α hα (by linarith)).trans_lt distillFiniteBound_22 + · exact (distillFinite_23 α hα (by linarith)).trans_lt distillFiniteBound_23 + · exact (distillFinite_24 α hα (by linarith)).trans_lt distillFiniteBound_24 + · exact (distillFinite_25 α hα (by linarith)).trans_lt distillFiniteBound_25 + · exact (distillFinite_26 α hα (by linarith)).trans_lt distillFiniteBound_26 + · exact (distillFinite_27 α hα (by linarith)).trans_lt distillFiniteBound_27 + · exact (distillFinite_28 α hα (by linarith)).trans_lt distillFiniteBound_28 + · exact (distillFinite_29 α hα (by linarith)).trans_lt distillFiniteBound_29 + · exact (distillFinite_30 α hα (by linarith)).trans_lt distillFiniteBound_30 + · exact (distillFinite_31 α hα (by linarith)).trans_lt distillFiniteBound_31 + · exact (distillFinite_32 α hα (by linarith)).trans_lt distillFiniteBound_32 + · exact (distillFinite_33 α hα (by linarith)).trans_lt distillFiniteBound_33 + · exact (distillFinite_34 α hα (by linarith)).trans_lt distillFiniteBound_34 + · exact (distillFinite_35 α hα (by linarith)).trans_lt distillFiniteBound_35 + · exact (distillFinite_36 α hα (by linarith)).trans_lt distillFiniteBound_36 + · exact (distillFinite_37 α hα (by linarith)).trans_lt distillFiniteBound_37 + · exact (distillFinite_38 α hα (by linarith)).trans_lt distillFiniteBound_38 + · exact (distillFinite_39 α hα (by linarith)).trans_lt distillFiniteBound_39 + · exact (distillFinite_40 α hα (by linarith)).trans_lt distillFiniteBound_40 + · exact (distillFinite_41 α hα (by linarith)).trans_lt distillFiniteBound_41 + · exact (distillFinite_42 α hα (by linarith)).trans_lt distillFiniteBound_42 + · exact (distillFinite_43 α hα (by linarith)).trans_lt distillFiniteBound_43 + · exact (distillFinite_44 α hα (by linarith)).trans_lt distillFiniteBound_44 + · exact (distillFinite_45 α hα (by linarith)).trans_lt distillFiniteBound_45 + · exact (distillFinite_46 α hα (by linarith)).trans_lt distillFiniteBound_46 + · exact (distillFinite_47 α hα (by linarith)).trans_lt distillFiniteBound_47 + · exact (distillFinite_48 α hα (by linarith)).trans_lt distillFiniteBound_48 + · exact (distillFinite_49 α hα (by linarith)).trans_lt distillFiniteBound_49 + · exact (distillFinite_50 α hα (by linarith)).trans_lt distillFiniteBound_50 + · exact (distillFinite_51 α hα (by linarith)).trans_lt distillFiniteBound_51 + · exact (distillFinite_52 α hα (by linarith)).trans_lt distillFiniteBound_52 + · exact (distillFinite_53 α hα (by linarith)).trans_lt distillFiniteBound_53 + · exact (distillFinite_54 α hα (by linarith)).trans_lt distillFiniteBound_54 + · exact (distillFinite_55 α hα (by linarith)).trans_lt distillFiniteBound_55 + · exact (distillFinite_56 α hα (by linarith)).trans_lt distillFiniteBound_56 + · exact (distillFinite_57 α hα (by linarith)).trans_lt distillFiniteBound_57 + · exact (distillFinite_58 α hα (by linarith)).trans_lt distillFiniteBound_58 + · exact (distillFinite_59 α hα (by linarith)).trans_lt distillFiniteBound_59 + · exact (distillFinite_60 α hα (by linarith)).trans_lt distillFiniteBound_60 + · exact (distillFinite_61 α hα (by linarith)).trans_lt distillFiniteBound_61 + · exact (distillFinite_62 α hα (by linarith)).trans_lt distillFiniteBound_62 + · exact (distillFinite_63 α hα (by linarith)).trans_lt distillFiniteBound_63 + · exact (distillFinite_64 α hα (by linarith)).trans_lt distillFiniteBound_64 + · exact (distillFinite_65 α hα (by linarith)).trans_lt distillFiniteBound_65 + · exact (distillFinite_66 α hα (by linarith)).trans_lt distillFiniteBound_66 + · exact (distillFinite_67 α hα (by linarith)).trans_lt distillFiniteBound_67 + · exact (distillFinite_68 α hα (by linarith)).trans_lt distillFiniteBound_68 + · exact (distillFinite_69 α hα (by linarith)).trans_lt distillFiniteBound_69 + · exact (distillFinite_70 α hα (by linarith)).trans_lt distillFiniteBound_70 + · exact (distillFinite_71 α hα (by linarith)).trans_lt distillFiniteBound_71 + · exact (distillFinite_72 α hα (by linarith)).trans_lt distillFiniteBound_72 + · exact (distillFinite_73 α hα (by linarith)).trans_lt distillFiniteBound_73 + · exact (distillFinite_74 α hα (by linarith)).trans_lt distillFiniteBound_74 + · exact (distillFinite_75 α hα (by linarith)).trans_lt distillFiniteBound_75 + · exact (distillFinite_76 α hα (by linarith)).trans_lt distillFiniteBound_76 + · exact (distillFinite_77 α hα (by linarith)).trans_lt distillFiniteBound_77 + · exact (distillFinite_78 α hα (by linarith)).trans_lt distillFiniteBound_78 + · exact (distillFinite_79 α hα (by linarith)).trans_lt distillFiniteBound_79 + · exact (distillFinite_80 α hα (by linarith)).trans_lt distillFiniteBound_80 + · exact (distillFinite_81 α hα (by linarith)).trans_lt distillFiniteBound_81 + +theorem distillFinite_scalar {m : ℕ} (hm : 5 ≤ m) (hm81 : m ≤ 81) + {α : ℝ} (hα : 0 < α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : + scalarObstruction m α (cubicPolarEnvelope α) < 199 / 200 := by + have hmR : (5 : ℝ) ≤ m := by exact_mod_cast hm + exact (distillScalar_le_majorant hmR hα (by linarith)).trans_lt + (distillFinite_components hm hm81 hα.le hαm h17) + +end Sendov diff --git a/Sendov/Common/DistillationHyperbolic.lean b/Sendov/Common/DistillationHyperbolic.lean new file mode 100644 index 0000000..e817bf8 --- /dev/null +++ b/Sendov/Common/DistillationHyperbolic.lean @@ -0,0 +1,476 @@ +/- +Copyright (c) 2026 Terence Tao. All rights reserved. +Released under Apache 2.0 license as described in the file LICENSE. +Authors: Terence Tao + +Adapted from Appendix A of Senjian An (SJanPerth), +Proof Distillation for Sendov's Conjecture, revision + e8ae601491ec171ab4f7f8456113dd6a047aa85d. +Paper licensed CC BY 4.0: https://creativecommons.org/licenses/by/4.0/ . +Changes: replace the infinite-series certificate with an exact eleven-derivative +exponential closure, and replace Descartes' rule with a Bernstein identity. +Derivative descent / logarithmic endpoint argument adapted from Terence Tao's +Apache-2.0 Sendov/Common/Sinh.lean. No existing weak hyperbolic bound is used. +-/ +import Mathlib.Analysis.SpecialFunctions.Log.Deriv +import Mathlib.Analysis.SpecialFunctions.Sqrt +import Mathlib.Analysis.SpecialFunctions.Trigonometric.DerivHyp +import Mathlib.Analysis.Calculus.MeanValue + +/-! +# Strong hyperbolic comparison on `[0,10]` + +Write `F(x) = x² A(x) sinh(x) - D(x) (x cosh(x) - sinh(x))`, with `D = 55 B`. +The functions `f0,...,f11` below satisfy `f0(x) = 2 exp(x) F(x)`, +`f(j+1) = f(j)'`, and `f(j)(0) = 0` for `j ≤ 10`. +The final function is exactly `2048 x¹⁰ exp(2x)`, not a Taylor approximation. +Descending nonnegativity therefore proves the full-function Padé comparison. + +An explicit degree-eight Bernstein identity proves `P ≤ 0` on `[0,100]`. +This is sufficient for the square comparison (strict negativity is unnecessary). +Positive denominators, differentiation on `(0,10]`, and the right limit at zero +then give `log (sinh(x)/x) ≤ (7/8) (sqrt(9 + (8/7) x²) - 3)`. +The final theorem includes `x = 0` in the equivalent exponential bound. +-/ + +namespace Sendov.DistillationHyperbolic + +open Real Set Filter + +private lemma nonneg_of_deriv {f g : ℝ → ℝ} (hd : ∀ z, HasDerivAt f (g z) z) + (h0 : f 0 = 0) (hg : ∀ z, 0 ≤ z → 0 ≤ g z) {y : ℝ} (hy : 0 ≤ y) : 0 ≤ f y := by + have hmono : MonotoneOn f (Ici 0) := by + refine monotoneOn_of_deriv_nonneg (convex_Ici 0) + (fun z _ => (hd z).continuousAt.continuousWithinAt) + (fun z _ => (hd z).differentiableAt.differentiableWithinAt) (fun z hz => ?_) + rw [(hd z).deriv] + rw [interior_Ici] at hz + exact hg z (le_of_lt hz) + simpa [h0] using hmono (mem_Ici.2 le_rfl) (mem_Ici.2 hy) hy + +/-- The numerator polynomial in the donor Padé majorant. -/ +def A (x : ℝ) : ℝ := x ^ 8 + 1430 * x ^ 6 + 289575 * x ^ 4 + 16081065 * x ^ 2 + 218243025 + +/-- Exactly 55 times the donor denominator polynomial. -/ +def D (x : ℝ) : ℝ := 55 * x ^ 8 + 25740 * x ^ 6 + 2837835 * x ^ 4 + 91891800 * x ^ 2 + 654729075 + +private noncomputable def f0 (x : ℝ) : ℝ := + exp (2 * x) * (x ^ 10 - 55 * x ^ 9 + 1485 * x ^ 8 - 25740 * x ^ 7 + 315315 * x ^ 6 - 2837835 * x + ^ 5 + 18918900 * x ^ 4 - 91891800 * x ^ 3 + 310134825 * x ^ 2 - 654729075 * x + 654729075) - + (x ^ 10 + 55 * x ^ 9 + 1485 * x ^ 8 + 25740 * x ^ 7 + 315315 * x ^ 6 + 2837835 * x ^ 5 + + 18918900 * x ^ 4 + 91891800 * x ^ 3 + 310134825 * x ^ 2 + 654729075 * x + 654729075) + +private noncomputable def f1 (x : ℝ) : ℝ := + exp (2 * x) * (2 * x ^ 10 - 100 * x ^ 9 + 2475 * x ^ 8 - 39600 * x ^ 7 + 450450 * x ^ 6 - + 3783780 * x ^ 5 + 23648625 * x ^ 4 - 108108000 * x ^ 3 + 344594250 * x ^ 2 - 689188500 * x + + 654729075) - (10 * x ^ 9 + 495 * x ^ 8 + 11880 * x ^ 7 + 180180 * x ^ 6 + 1891890 * x ^ 5 + + 14189175 * x ^ 4 + 75675600 * x ^ 3 + 275675400 * x ^ 2 + 620269650 * x + 654729075) + +private noncomputable def f2 (x : ℝ) : ℝ := + exp (2 * x) * (4 * x ^ 10 - 180 * x ^ 9 + 4050 * x ^ 8 - 59400 * x ^ 7 + 623700 * x ^ 6 - + 4864860 * x ^ 5 + 28378350 * x ^ 4 - 121621500 * x ^ 3 + 364864500 * x ^ 2 - 689188500 * x + + 620269650) - (90 * x ^ 8 + 3960 * x ^ 7 + 83160 * x ^ 6 + 1081080 * x ^ 5 + 9459450 * x ^ 4 + + 56756700 * x ^ 3 + 227026800 * x ^ 2 + 551350800 * x + 620269650) + +private noncomputable def f3 (x : ℝ) : ℝ := + exp (2 * x) * (8 * x ^ 10 - 320 * x ^ 9 + 6480 * x ^ 8 - 86400 * x ^ 7 + 831600 * x ^ 6 - + 5987520 * x ^ 5 + 32432400 * x ^ 4 - 129729600 * x ^ 3 + 364864500 * x ^ 2 - 648648000 * x + + 551350800) - (720 * x ^ 7 + 27720 * x ^ 6 + 498960 * x ^ 5 + 5405400 * x ^ 4 + 37837800 * x + ^ 3 + 170270100 * x ^ 2 + 454053600 * x + 551350800) + +private noncomputable def f4 (x : ℝ) : ℝ := + exp (2 * x) * (16 * x ^ 10 - 560 * x ^ 9 + 10080 * x ^ 8 - 120960 * x ^ 7 + 1058400 * x ^ 6 - + 6985440 * x ^ 5 + 34927200 * x ^ 4 - 129729600 * x ^ 3 + 340540200 * x ^ 2 - 567567000 * x + + 454053600) - (5040 * x ^ 6 + 166320 * x ^ 5 + 2494800 * x ^ 4 + 21621600 * x ^ 3 + 113513400 + * x ^ 2 + 340540200 * x + 454053600) + +private noncomputable def f5 (x : ℝ) : ℝ := + exp (2 * x) * (32 * x ^ 10 - 960 * x ^ 9 + 15120 * x ^ 8 - 161280 * x ^ 7 + 1270080 * x ^ 6 - + 7620480 * x ^ 5 + 34927200 * x ^ 4 - 119750400 * x ^ 3 + 291891600 * x ^ 2 - 454053600 * x + + 340540200) - (30240 * x ^ 5 + 831600 * x ^ 4 + 9979200 * x ^ 3 + 64864800 * x ^ 2 + + 227026800 * x + 340540200) + +private noncomputable def f6 (x : ℝ) : ℝ := + exp (2 * x) * (64 * x ^ 10 - 1600 * x ^ 9 + 21600 * x ^ 8 - 201600 * x ^ 7 + 1411200 * x ^ 6 - + 7620480 * x ^ 5 + 31752000 * x ^ 4 - 99792000 * x ^ 3 + 224532000 * x ^ 2 - 324324000 * x + + 227026800) - (151200 * x ^ 4 + 3326400 * x ^ 3 + 29937600 * x ^ 2 + 129729600 * x + + 227026800) + +private noncomputable def f7 (x : ℝ) : ℝ := + exp (2 * x) * (128 * x ^ 10 - 2560 * x ^ 9 + 28800 * x ^ 8 - 230400 * x ^ 7 + 1411200 * x ^ 6 - + 6773760 * x ^ 5 + 25401600 * x ^ 4 - 72576000 * x ^ 3 + 149688000 * x ^ 2 - 199584000 * x + + 129729600) - (604800 * x ^ 3 + 9979200 * x ^ 2 + 59875200 * x + 129729600) + +private noncomputable def f8 (x : ℝ) : ℝ := + exp (2 * x) * (256 * x ^ 10 - 3840 * x ^ 9 + 34560 * x ^ 8 - 230400 * x ^ 7 + 1209600 * x ^ 6 - + 5080320 * x ^ 5 + 16934400 * x ^ 4 - 43545600 * x ^ 3 + 81648000 * x ^ 2 - 99792000 * x + + 59875200) - (1814400 * x ^ 2 + 19958400 * x + 59875200) + +private noncomputable def f9 (x : ℝ) : ℝ := + exp (2 * x) * (512 * x ^ 10 - 5120 * x ^ 9 + 34560 * x ^ 8 - 184320 * x ^ 7 + 806400 * x ^ 6 - + 2903040 * x ^ 5 + 8467200 * x ^ 4 - 19353600 * x ^ 3 + 32659200 * x ^ 2 - 36288000 * x + + 19958400) - (3628800 * x + 19958400) + +private noncomputable def f10 (x : ℝ) : ℝ := + exp (2 * x) * (1024 * x ^ 10 - 5120 * x ^ 9 + 23040 * x ^ 8 - 92160 * x ^ 7 + 322560 * x ^ 6 - + 967680 * x ^ 5 + 2419200 * x ^ 4 - 4838400 * x ^ 3 + 7257600 * x ^ 2 - 7257600 * x + + 3628800) - (3628800) + +private noncomputable def f11 (x : ℝ) : ℝ := + exp (2 * x) * (2048 * x ^ 10) - (0) + +private lemma deriv0 (x : ℝ) : HasDerivAt f0 (f1 x) x := by + have he := ((hasDerivAt_id' x).const_mul (2 : ℝ)).exp + have hu := ((((((((((hasDerivAt_pow 10 x).add ((hasDerivAt_pow 9 x).const_mul (-55 : ℝ))).add + ((hasDerivAt_pow 8 x).const_mul (1485 : ℝ))).add ((hasDerivAt_pow 7 x).const_mul (-25740 : + ℝ))).add ((hasDerivAt_pow 6 x).const_mul (315315 : ℝ))).add ((hasDerivAt_pow 5 x).const_mul + (-2837835 : ℝ))).add ((hasDerivAt_pow 4 x).const_mul (18918900 : ℝ))).add ((hasDerivAt_pow 3 + x).const_mul (-91891800 : ℝ))).add ((hasDerivAt_pow 2 x).const_mul (310134825 : ℝ))).add + ((hasDerivAt_id' x).const_mul (-654729075 : ℝ))).add (hasDerivAt_const x (654729075 : ℝ)) + have hv := ((((((((((hasDerivAt_pow 10 x).add ((hasDerivAt_pow 9 x).const_mul (55 : ℝ))).add + ((hasDerivAt_pow 8 x).const_mul (1485 : ℝ))).add ((hasDerivAt_pow 7 x).const_mul (25740 : + ℝ))).add ((hasDerivAt_pow 6 x).const_mul (315315 : ℝ))).add ((hasDerivAt_pow 5 x).const_mul + (2837835 : ℝ))).add ((hasDerivAt_pow 4 x).const_mul (18918900 : ℝ))).add ((hasDerivAt_pow 3 + x).const_mul (91891800 : ℝ))).add ((hasDerivAt_pow 2 x).const_mul (310134825 : ℝ))).add + ((hasDerivAt_id' x).const_mul (654729075 : ℝ))).add (hasDerivAt_const x (654729075 : ℝ)) + convert! (he.mul hu).sub hv using 1 <;> norm_num [f0, f1, Pi.add_apply] <;> + first | (funext z; dsimp [f0]; ring) | ring + +private lemma deriv1 (x : ℝ) : HasDerivAt f1 (f2 x) x := by + have he := ((hasDerivAt_id' x).const_mul (2 : ℝ)).exp + have hu := (((((((((((hasDerivAt_pow 10 x).const_mul (2 : ℝ)).add ((hasDerivAt_pow 9 + x).const_mul (-100 : ℝ))).add ((hasDerivAt_pow 8 x).const_mul (2475 : ℝ))).add + ((hasDerivAt_pow 7 x).const_mul (-39600 : ℝ))).add ((hasDerivAt_pow 6 x).const_mul (450450 : + ℝ))).add ((hasDerivAt_pow 5 x).const_mul (-3783780 : ℝ))).add ((hasDerivAt_pow 4 + x).const_mul (23648625 : ℝ))).add ((hasDerivAt_pow 3 x).const_mul (-108108000 : ℝ))).add + ((hasDerivAt_pow 2 x).const_mul (344594250 : ℝ))).add ((hasDerivAt_id' x).const_mul + (-689188500 : ℝ))).add (hasDerivAt_const x (654729075 : ℝ)) + have hv := ((((((((((hasDerivAt_pow 9 x).const_mul (10 : ℝ)).add ((hasDerivAt_pow 8 x).const_mul + (495 : ℝ))).add ((hasDerivAt_pow 7 x).const_mul (11880 : ℝ))).add ((hasDerivAt_pow 6 + x).const_mul (180180 : ℝ))).add ((hasDerivAt_pow 5 x).const_mul (1891890 : ℝ))).add + ((hasDerivAt_pow 4 x).const_mul (14189175 : ℝ))).add ((hasDerivAt_pow 3 x).const_mul + (75675600 : ℝ))).add ((hasDerivAt_pow 2 x).const_mul (275675400 : ℝ))).add ((hasDerivAt_id' + x).const_mul (620269650 : ℝ))).add (hasDerivAt_const x (654729075 : ℝ)) + convert! (he.mul hu).sub hv using 1 <;> norm_num [f1, f2, Pi.add_apply] <;> + first | (funext z; dsimp [f1]; ring) | ring + +private lemma deriv2 (x : ℝ) : HasDerivAt f2 (f3 x) x := by + have he := ((hasDerivAt_id' x).const_mul (2 : ℝ)).exp + have hu := (((((((((((hasDerivAt_pow 10 x).const_mul (4 : ℝ)).add ((hasDerivAt_pow 9 + x).const_mul (-180 : ℝ))).add ((hasDerivAt_pow 8 x).const_mul (4050 : ℝ))).add + ((hasDerivAt_pow 7 x).const_mul (-59400 : ℝ))).add ((hasDerivAt_pow 6 x).const_mul (623700 : + ℝ))).add ((hasDerivAt_pow 5 x).const_mul (-4864860 : ℝ))).add ((hasDerivAt_pow 4 + x).const_mul (28378350 : ℝ))).add ((hasDerivAt_pow 3 x).const_mul (-121621500 : ℝ))).add + ((hasDerivAt_pow 2 x).const_mul (364864500 : ℝ))).add ((hasDerivAt_id' x).const_mul + (-689188500 : ℝ))).add (hasDerivAt_const x (620269650 : ℝ)) + have hv := (((((((((hasDerivAt_pow 8 x).const_mul (90 : ℝ)).add ((hasDerivAt_pow 7 x).const_mul + (3960 : ℝ))).add ((hasDerivAt_pow 6 x).const_mul (83160 : ℝ))).add ((hasDerivAt_pow 5 + x).const_mul (1081080 : ℝ))).add ((hasDerivAt_pow 4 x).const_mul (9459450 : ℝ))).add + ((hasDerivAt_pow 3 x).const_mul (56756700 : ℝ))).add ((hasDerivAt_pow 2 x).const_mul + (227026800 : ℝ))).add ((hasDerivAt_id' x).const_mul (551350800 : ℝ))).add (hasDerivAt_const + x (620269650 : ℝ)) + convert! (he.mul hu).sub hv using 1 <;> norm_num [f2, f3, Pi.add_apply] <;> + first | (funext z; dsimp [f2]; ring) | ring + +private lemma deriv3 (x : ℝ) : HasDerivAt f3 (f4 x) x := by + have he := ((hasDerivAt_id' x).const_mul (2 : ℝ)).exp + have hu := (((((((((((hasDerivAt_pow 10 x).const_mul (8 : ℝ)).add ((hasDerivAt_pow 9 + x).const_mul (-320 : ℝ))).add ((hasDerivAt_pow 8 x).const_mul (6480 : ℝ))).add + ((hasDerivAt_pow 7 x).const_mul (-86400 : ℝ))).add ((hasDerivAt_pow 6 x).const_mul (831600 : + ℝ))).add ((hasDerivAt_pow 5 x).const_mul (-5987520 : ℝ))).add ((hasDerivAt_pow 4 + x).const_mul (32432400 : ℝ))).add ((hasDerivAt_pow 3 x).const_mul (-129729600 : ℝ))).add + ((hasDerivAt_pow 2 x).const_mul (364864500 : ℝ))).add ((hasDerivAt_id' x).const_mul + (-648648000 : ℝ))).add (hasDerivAt_const x (551350800 : ℝ)) + have hv := ((((((((hasDerivAt_pow 7 x).const_mul (720 : ℝ)).add ((hasDerivAt_pow 6 x).const_mul + (27720 : ℝ))).add ((hasDerivAt_pow 5 x).const_mul (498960 : ℝ))).add ((hasDerivAt_pow 4 + x).const_mul (5405400 : ℝ))).add ((hasDerivAt_pow 3 x).const_mul (37837800 : ℝ))).add + ((hasDerivAt_pow 2 x).const_mul (170270100 : ℝ))).add ((hasDerivAt_id' x).const_mul + (454053600 : ℝ))).add (hasDerivAt_const x (551350800 : ℝ)) + convert! (he.mul hu).sub hv using 1 <;> norm_num [f3, f4, Pi.add_apply] <;> + first | (funext z; dsimp [f3]; ring) | ring + +private lemma deriv4 (x : ℝ) : HasDerivAt f4 (f5 x) x := by + have he := ((hasDerivAt_id' x).const_mul (2 : ℝ)).exp + have hu := (((((((((((hasDerivAt_pow 10 x).const_mul (16 : ℝ)).add ((hasDerivAt_pow 9 + x).const_mul (-560 : ℝ))).add ((hasDerivAt_pow 8 x).const_mul (10080 : ℝ))).add + ((hasDerivAt_pow 7 x).const_mul (-120960 : ℝ))).add ((hasDerivAt_pow 6 x).const_mul (1058400 + : ℝ))).add ((hasDerivAt_pow 5 x).const_mul (-6985440 : ℝ))).add ((hasDerivAt_pow 4 + x).const_mul (34927200 : ℝ))).add ((hasDerivAt_pow 3 x).const_mul (-129729600 : ℝ))).add + ((hasDerivAt_pow 2 x).const_mul (340540200 : ℝ))).add ((hasDerivAt_id' x).const_mul + (-567567000 : ℝ))).add (hasDerivAt_const x (454053600 : ℝ)) + have hv := (((((((hasDerivAt_pow 6 x).const_mul (5040 : ℝ)).add ((hasDerivAt_pow 5 x).const_mul + (166320 : ℝ))).add ((hasDerivAt_pow 4 x).const_mul (2494800 : ℝ))).add ((hasDerivAt_pow 3 + x).const_mul (21621600 : ℝ))).add ((hasDerivAt_pow 2 x).const_mul (113513400 : ℝ))).add + ((hasDerivAt_id' x).const_mul (340540200 : ℝ))).add (hasDerivAt_const x (454053600 : ℝ)) + convert! (he.mul hu).sub hv using 1 <;> norm_num [f4, f5, Pi.add_apply] <;> + first | (funext z; dsimp [f4]; ring) | ring + +private lemma deriv5 (x : ℝ) : HasDerivAt f5 (f6 x) x := by + have he := ((hasDerivAt_id' x).const_mul (2 : ℝ)).exp + have hu := (((((((((((hasDerivAt_pow 10 x).const_mul (32 : ℝ)).add ((hasDerivAt_pow 9 + x).const_mul (-960 : ℝ))).add ((hasDerivAt_pow 8 x).const_mul (15120 : ℝ))).add + ((hasDerivAt_pow 7 x).const_mul (-161280 : ℝ))).add ((hasDerivAt_pow 6 x).const_mul (1270080 + : ℝ))).add ((hasDerivAt_pow 5 x).const_mul (-7620480 : ℝ))).add ((hasDerivAt_pow 4 + x).const_mul (34927200 : ℝ))).add ((hasDerivAt_pow 3 x).const_mul (-119750400 : ℝ))).add + ((hasDerivAt_pow 2 x).const_mul (291891600 : ℝ))).add ((hasDerivAt_id' x).const_mul + (-454053600 : ℝ))).add (hasDerivAt_const x (340540200 : ℝ)) + have hv := ((((((hasDerivAt_pow 5 x).const_mul (30240 : ℝ)).add ((hasDerivAt_pow 4 x).const_mul + (831600 : ℝ))).add ((hasDerivAt_pow 3 x).const_mul (9979200 : ℝ))).add ((hasDerivAt_pow 2 + x).const_mul (64864800 : ℝ))).add ((hasDerivAt_id' x).const_mul (227026800 : ℝ))).add + (hasDerivAt_const x (340540200 : ℝ)) + convert! (he.mul hu).sub hv using 1 <;> norm_num [f5, f6, Pi.add_apply] <;> + first | (funext z; dsimp [f5]; ring) | ring + +private lemma deriv6 (x : ℝ) : HasDerivAt f6 (f7 x) x := by + have he := ((hasDerivAt_id' x).const_mul (2 : ℝ)).exp + have hu := (((((((((((hasDerivAt_pow 10 x).const_mul (64 : ℝ)).add ((hasDerivAt_pow 9 + x).const_mul (-1600 : ℝ))).add ((hasDerivAt_pow 8 x).const_mul (21600 : ℝ))).add + ((hasDerivAt_pow 7 x).const_mul (-201600 : ℝ))).add ((hasDerivAt_pow 6 x).const_mul (1411200 + : ℝ))).add ((hasDerivAt_pow 5 x).const_mul (-7620480 : ℝ))).add ((hasDerivAt_pow 4 + x).const_mul (31752000 : ℝ))).add ((hasDerivAt_pow 3 x).const_mul (-99792000 : ℝ))).add + ((hasDerivAt_pow 2 x).const_mul (224532000 : ℝ))).add ((hasDerivAt_id' x).const_mul + (-324324000 : ℝ))).add (hasDerivAt_const x (227026800 : ℝ)) + have hv := (((((hasDerivAt_pow 4 x).const_mul (151200 : ℝ)).add ((hasDerivAt_pow 3 x).const_mul + (3326400 : ℝ))).add ((hasDerivAt_pow 2 x).const_mul (29937600 : ℝ))).add ((hasDerivAt_id' + x).const_mul (129729600 : ℝ))).add (hasDerivAt_const x (227026800 : ℝ)) + convert! (he.mul hu).sub hv using 1 <;> norm_num [f6, f7, Pi.add_apply] <;> + first | (funext z; dsimp [f6]; ring) | ring + +private lemma deriv7 (x : ℝ) : HasDerivAt f7 (f8 x) x := by + have he := ((hasDerivAt_id' x).const_mul (2 : ℝ)).exp + have hu := (((((((((((hasDerivAt_pow 10 x).const_mul (128 : ℝ)).add ((hasDerivAt_pow 9 + x).const_mul (-2560 : ℝ))).add ((hasDerivAt_pow 8 x).const_mul (28800 : ℝ))).add + ((hasDerivAt_pow 7 x).const_mul (-230400 : ℝ))).add ((hasDerivAt_pow 6 x).const_mul (1411200 + : ℝ))).add ((hasDerivAt_pow 5 x).const_mul (-6773760 : ℝ))).add ((hasDerivAt_pow 4 + x).const_mul (25401600 : ℝ))).add ((hasDerivAt_pow 3 x).const_mul (-72576000 : ℝ))).add + ((hasDerivAt_pow 2 x).const_mul (149688000 : ℝ))).add ((hasDerivAt_id' x).const_mul + (-199584000 : ℝ))).add (hasDerivAt_const x (129729600 : ℝ)) + have hv := ((((hasDerivAt_pow 3 x).const_mul (604800 : ℝ)).add ((hasDerivAt_pow 2 x).const_mul + (9979200 : ℝ))).add ((hasDerivAt_id' x).const_mul (59875200 : ℝ))).add (hasDerivAt_const x + (129729600 : ℝ)) + convert! (he.mul hu).sub hv using 1 <;> norm_num [f7, f8, Pi.add_apply] <;> + first | (funext z; dsimp [f7]; ring) | ring + +private lemma deriv8 (x : ℝ) : HasDerivAt f8 (f9 x) x := by + have he := ((hasDerivAt_id' x).const_mul (2 : ℝ)).exp + have hu := (((((((((((hasDerivAt_pow 10 x).const_mul (256 : ℝ)).add ((hasDerivAt_pow 9 + x).const_mul (-3840 : ℝ))).add ((hasDerivAt_pow 8 x).const_mul (34560 : ℝ))).add + ((hasDerivAt_pow 7 x).const_mul (-230400 : ℝ))).add ((hasDerivAt_pow 6 x).const_mul (1209600 + : ℝ))).add ((hasDerivAt_pow 5 x).const_mul (-5080320 : ℝ))).add ((hasDerivAt_pow 4 + x).const_mul (16934400 : ℝ))).add ((hasDerivAt_pow 3 x).const_mul (-43545600 : ℝ))).add + ((hasDerivAt_pow 2 x).const_mul (81648000 : ℝ))).add ((hasDerivAt_id' x).const_mul + (-99792000 : ℝ))).add (hasDerivAt_const x (59875200 : ℝ)) + have hv := (((hasDerivAt_pow 2 x).const_mul (1814400 : ℝ)).add ((hasDerivAt_id' x).const_mul + (19958400 : ℝ))).add (hasDerivAt_const x (59875200 : ℝ)) + convert! (he.mul hu).sub hv using 1 <;> norm_num [f8, f9, Pi.add_apply] <;> + first | (funext z; dsimp [f8]; ring) | ring + +private lemma deriv9 (x : ℝ) : HasDerivAt f9 (f10 x) x := by + have he := ((hasDerivAt_id' x).const_mul (2 : ℝ)).exp + have hu := (((((((((((hasDerivAt_pow 10 x).const_mul (512 : ℝ)).add ((hasDerivAt_pow 9 + x).const_mul (-5120 : ℝ))).add ((hasDerivAt_pow 8 x).const_mul (34560 : ℝ))).add + ((hasDerivAt_pow 7 x).const_mul (-184320 : ℝ))).add ((hasDerivAt_pow 6 x).const_mul (806400 + : ℝ))).add ((hasDerivAt_pow 5 x).const_mul (-2903040 : ℝ))).add ((hasDerivAt_pow 4 + x).const_mul (8467200 : ℝ))).add ((hasDerivAt_pow 3 x).const_mul (-19353600 : ℝ))).add + ((hasDerivAt_pow 2 x).const_mul (32659200 : ℝ))).add ((hasDerivAt_id' x).const_mul + (-36288000 : ℝ))).add (hasDerivAt_const x (19958400 : ℝ)) + have hv := ((hasDerivAt_id' x).const_mul (3628800 : ℝ)).add (hasDerivAt_const x (19958400 : ℝ)) + convert! (he.mul hu).sub hv using 1 <;> norm_num [f9, f10, Pi.add_apply] <;> + first | (funext z; dsimp [f9]; ring) | ring + +private lemma deriv10 (x : ℝ) : HasDerivAt f10 (f11 x) x := by + have he := ((hasDerivAt_id' x).const_mul (2 : ℝ)).exp + have hu := (((((((((((hasDerivAt_pow 10 x).const_mul (1024 : ℝ)).add ((hasDerivAt_pow 9 + x).const_mul (-5120 : ℝ))).add ((hasDerivAt_pow 8 x).const_mul (23040 : ℝ))).add + ((hasDerivAt_pow 7 x).const_mul (-92160 : ℝ))).add ((hasDerivAt_pow 6 x).const_mul (322560 : + ℝ))).add ((hasDerivAt_pow 5 x).const_mul (-967680 : ℝ))).add ((hasDerivAt_pow 4 x).const_mul + (2419200 : ℝ))).add ((hasDerivAt_pow 3 x).const_mul (-4838400 : ℝ))).add ((hasDerivAt_pow 2 + x).const_mul (7257600 : ℝ))).add ((hasDerivAt_id' x).const_mul (-7257600 : ℝ))).add + (hasDerivAt_const x (3628800 : ℝ)) + have hv := hasDerivAt_const x (3628800 : ℝ) + convert! (he.mul hu).sub hv using 1 <;> norm_num [f10, f11, Pi.add_apply] <;> + first | (funext z; dsimp [f10]; ring) | ring + +private lemma nonneg11 (x : ℝ) (_hx : 0 ≤ x) : 0 ≤ f11 x := by + simp only [f11, sub_zero] + positivity + +private lemma nonneg10 (x : ℝ) (hx : 0 ≤ x) : 0 ≤ f10 x := + nonneg_of_deriv deriv10 (by norm_num [f10]) nonneg11 hx + +private lemma nonneg9 (x : ℝ) (hx : 0 ≤ x) : 0 ≤ f9 x := + nonneg_of_deriv deriv9 (by norm_num [f9]) nonneg10 hx + +private lemma nonneg8 (x : ℝ) (hx : 0 ≤ x) : 0 ≤ f8 x := + nonneg_of_deriv deriv8 (by norm_num [f8]) nonneg9 hx + +private lemma nonneg7 (x : ℝ) (hx : 0 ≤ x) : 0 ≤ f7 x := + nonneg_of_deriv deriv7 (by norm_num [f7]) nonneg8 hx + +private lemma nonneg6 (x : ℝ) (hx : 0 ≤ x) : 0 ≤ f6 x := + nonneg_of_deriv deriv6 (by norm_num [f6]) nonneg7 hx + +private lemma nonneg5 (x : ℝ) (hx : 0 ≤ x) : 0 ≤ f5 x := + nonneg_of_deriv deriv5 (by norm_num [f5]) nonneg6 hx + +private lemma nonneg4 (x : ℝ) (hx : 0 ≤ x) : 0 ≤ f4 x := + nonneg_of_deriv deriv4 (by norm_num [f4]) nonneg5 hx + +private lemma nonneg3 (x : ℝ) (hx : 0 ≤ x) : 0 ≤ f3 x := + nonneg_of_deriv deriv3 (by norm_num [f3]) nonneg4 hx + +private lemma nonneg2 (x : ℝ) (hx : 0 ≤ x) : 0 ≤ f2 x := + nonneg_of_deriv deriv2 (by norm_num [f2]) nonneg3 hx + +private lemma nonneg1 (x : ℝ) (hx : 0 ≤ x) : 0 ≤ f1 x := + nonneg_of_deriv deriv1 (by norm_num [f1]) nonneg2 hx + +private lemma nonneg0 (x : ℝ) (hx : 0 ≤ x) : 0 ≤ f0 x := + nonneg_of_deriv deriv0 (by norm_num [f0]) nonneg1 hx + +/-- Full-function Padé inequality, proved by exact derivatives, not a Taylor truncation. -/ +theorem pade_nonneg {x : ℝ} (hx : 0 ≤ x) : + 0 ≤ x ^ 2 * A x * sinh x - D x * (x * cosh x - sinh x) := by + have h := nonneg0 x hx + have he : exp x ≠ 0 := (exp_pos x).ne' + have hid : f0 x = 2 * exp x * + (x ^ 2 * A x * sinh x - D x * (x * cosh x - sinh x)) := by + simp only [f0, A, D, sinh_eq, cosh_eq, exp_neg, + show exp (2 * x) = exp x ^ 2 by simp [← exp_nat_mul]] + field_simp + ring + rw [hid] at h + exact nonneg_of_mul_nonneg_right h (by positivity) + +private def P (x : ℝ) : ℝ := 8 * x ^ 8 + 1768 * x ^ 7 + 1352780 * x ^ 6 + 225122040 * x ^ 5 + + 3059031690 * x ^ 4 - 2283465284100 * x ^ 3 - 180738098991450 * x ^ 2 - 4712864935103325 * x - + 19052007184460250 + +private lemma P_nonpos {y : ℝ} (hy : 0 ≤ y) (hy100 : y ≤ 100) : P y ≤ 0 := by + have hz : 0 ≤ 100 - y := sub_nonneg.mpr hy100 + have h : 0 ≤ 19052007184460250 * y ^ 0 * (100 - y) ^ 8 + + 623702550986014500 * y ^ 1 * (100 - y) ^ 7 + + 5639842645651714500 * y ^ 2 * (100 - y) ^ 6 + + 24091679989633756500 * y ^ 3 * (100 - y) ^ 5 + + 56050805875991355000 * y ^ 4 * (100 - y) ^ 4 + + 73069379238481411500 * y ^ 5 * (100 - y) ^ 3 + + 50433980040599369500 * y ^ 6 * (100 - y) ^ 2 + + 14853399996035009500 * y ^ 7 * (100 - y) ^ 1 + + 414481205709292750 * y ^ 8 * (100 - y) ^ 0 := by positivity + have hid : 19052007184460250 * y ^ 0 * (100 - y) ^ 8 + + 623702550986014500 * y ^ 1 * (100 - y) ^ 7 + + 5639842645651714500 * y ^ 2 * (100 - y) ^ 6 + + 24091679989633756500 * y ^ 3 * (100 - y) ^ 5 + + 56050805875991355000 * y ^ 4 * (100 - y) ^ 4 + + 73069379238481411500 * y ^ 5 * (100 - y) ^ 3 + + 50433980040599369500 * y ^ 6 * (100 - y) ^ 2 + + 14853399996035009500 * y ^ 7 * (100 - y) ^ 1 + + 414481205709292750 * y ^ 8 * (100 - y) ^ 0 = -(100 ^ 8 : ℝ) * P y := by + unfold P + ring + rw [hid] at h + nlinarith + +/-- Rational square comparison, with the essential factor `8/7`. -/ +theorem pade_square_le {x : ℝ} (hx : 0 ≤ x) (hx10 : x ≤ 10) : + (9 + (8 / 7 : ℝ) * x ^ 2) * A x ^ 2 ≤ D x ^ 2 := by + have hP := P_nonpos (sq_nonneg x) (show x ^ 2 ≤ 100 by nlinarith) + have hid : 7 * ((9 + (8 / 7 : ℝ) * x ^ 2) * A x ^ 2 - D x ^ 2) = + x ^ 2 * P (x ^ 2) := by unfold A D P; ring + have hh := mul_nonpos_of_nonneg_of_nonpos (sq_nonneg x) hP + nlinarith + +/-- Cleared derivative comparison for the stronger, interval-restricted bound. -/ +theorem sqrt_mul_sub_le {x : ℝ} (hx : 0 ≤ x) (hx10 : x ≤ 10) : + sqrt (9 + (8 / 7 : ℝ) * x ^ 2) * (x * cosh x - sinh x) ≤ x ^ 2 * sinh x := by + have hA : 0 ≤ A x := by unfold A; positivity + have hD : 0 < D x := by unfold D; positivity + have hs := pade_square_le hx hx10 + have hr : 0 ≤ 9 + (8 / 7 : ℝ) * x ^ 2 := by positivity + have hroot : sqrt (9 + (8 / 7 : ℝ) * x ^ 2) * A x ≤ D x := by + have heq : (sqrt (9 + (8 / 7 : ℝ) * x ^ 2) * A x) ^ 2 = + (9 + (8 / 7 : ℝ) * x ^ 2) * A x ^ 2 := by rw [mul_pow, sq_sqrt hr] + have hpos := mul_nonneg (sqrt_nonneg (9 + (8 / 7 : ℝ) * x ^ 2)) hA + nlinarith + have hp := pade_nonneg hx + have hsinh : 0 ≤ sinh x := sinh_nonneg_iff.mpr hx + have hmul := mul_le_mul_of_nonneg_left hroot (mul_nonneg (sq_nonneg x) hsinh) + have hmul2 := mul_nonneg (sqrt_nonneg (9 + (8 / 7 : ℝ) * x ^ 2)) hp + have hh : D x * (sqrt (9 + (8 / 7 : ℝ) * x ^ 2) * + (x * cosh x - sinh x)) ≤ D x * (x ^ 2 * sinh x) := by nlinarith + exact (mul_le_mul_iff_right₀ hD).mp hh + +/-- Strong SJanPerth bound on `(0,10]`; both rational scale factors are retained. -/ +theorem log_sinh_div_le {h : ℝ} (hh : 0 < h) (hh10 : h ≤ 10) : + log (sinh h / h) ≤ (7 / 8 : ℝ) * (sqrt (9 + (8 / 7 : ℝ) * h ^ 2) - 3) := by + set ψ : ℝ → ℝ := fun z => (7 / 8 : ℝ) * (sqrt (9 + (8 / 7 : ℝ) * z ^ 2) - 3) - (log (sinh z) - + log z) with hψdef + -- `ψ` has nonnegative derivative on `(0,10]`. + have hderiv : ∀ z : ℝ, 0 < z → + HasDerivAt ψ (z / sqrt (9 + (8 / 7 : ℝ) * z ^ 2) - (cosh z / sinh z - 1 / z)) z := by + intro z hz + have hsinh : sinh z ≠ 0 := ne_of_gt (sinh_pos_iff.2 hz) + apply HasDerivAt.sub + · have h := ((((hasDerivAt_pow 2 z).const_mul (8 / 7 : ℝ)).const_add 9).sqrt (ne_of_gt (by + positivity))).sub_const 3 |>.const_mul (7 / 8 : ℝ) + refine h.congr_deriv ?_ + field_simp + ring + · exact (((hasDerivAt_sinh z).log hsinh).sub + ((hasDerivAt_id' z).log (ne_of_gt hz))).congr_deriv (by field_simp) + have hmono : MonotoneOn ψ (Ioc 0 10) := by + refine monotoneOn_of_deriv_nonneg (convex_Ioc 0 10) + (fun z hz => (hderiv z hz.1).continuousAt.continuousWithinAt) + (fun z hz => (hderiv z (by rw [interior_Ioc] at hz; exact + hz.1)).differentiableAt.differentiableWithinAt) + (fun z hz => ?_) + rw [interior_Ioc, mem_Ioo] at hz + have hzpos : 0 < z := hz.1 + rw [(hderiv z hz.1).deriv, sub_nonneg, div_sub_div _ _ (ne_of_gt (sinh_pos_iff.2 hz.1)) + (ne_of_gt hz.1), div_le_div_iff₀ (by positivity) (by positivity)] + nlinarith [sqrt_mul_sub_le (le_of_lt hz.1) (le_of_lt hz.2)] + -- `ψ → 0` as `z → 0⁺` + have hslope : Tendsto (fun z => sinh z / z) (nhdsWithin 0 {(0 : ℝ)}ᶜ) (nhds 1) := by + simpa [slope_fun_def, div_eq_inv_mul, hasDerivAt_iff_tendsto_slope] using hasDerivAt_sinh 0 + have hlog : Tendsto ψ (nhdsWithin 0 (Ioi 0)) (nhds 0) := by + have hsub : nhdsWithin (0 : ℝ) (Ioi 0) ≤ nhdsWithin 0 {(0 : ℝ)}ᶜ := + nhdsWithin_mono _ (fun z hz => ne_of_gt hz) + have h1 : Tendsto (fun z => log (sinh z / z)) (nhdsWithin 0 (Ioi 0)) (nhds 0) := by + simpa [Function.comp_def] using (continuousAt_log one_ne_zero).tendsto.comp + (hslope.mono_left hsub) + have h2 : Tendsto (fun z : ℝ => (7 / 8 : ℝ) * (sqrt (9 + (8 / 7 : ℝ) * z ^ 2) - 3)) + (nhdsWithin 0 (Ioi 0)) (nhds 0) := by + have h9 : sqrt (9 : ℝ) = 3 := by + rw [show (9 : ℝ) = 3 ^ 2 by norm_num, sqrt_sq (by norm_num : (0:ℝ) ≤ 3)] + have hc : ContinuousAt (fun z => (7 / 8 : ℝ) * (sqrt (9 + (8 / 7 : ℝ) * z ^ 2) - 3)) 0 := by + fun_prop + simpa [ContinuousWithinAt, h9] using hc.continuousWithinAt (s := Ioi (0 : ℝ)) + have heq : ∀ᶠ z : ℝ in nhdsWithin 0 (Ioi 0), + ψ z = ((7 / 8 : ℝ) * (sqrt (9 + (8 / 7 : ℝ) * z ^ 2) - 3)) - log (sinh z / z) := by + filter_upwards [self_mem_nhdsWithin] with z hz + rw [hψdef, log_div (ne_of_gt (sinh_pos_iff.2 hz)) (ne_of_gt hz)] + simpa [tendsto_congr' heq] using h2.sub h1 + -- combine + have hev : ∀ᶠ z : ℝ in nhdsWithin 0 (Ioi 0), ψ z ≤ ψ h := by + have hmem : Ioo (0 : ℝ) h ∈ nhdsWithin (0 : ℝ) (Ioi 0) := + mem_nhdsGT_iff_exists_Ioo_subset.2 (Exists.intro h (And.intro (mem_Ioi.2 hh) subset_rfl)) + filter_upwards [hmem] with z hz + exact hmono ⟨hz.1, le_trans hz.2.le hh10⟩ ⟨hh, hh10⟩ (le_of_lt hz.2) + have h0 : (0 : ℝ) ≤ ψ h := le_of_tendsto hlog hev + have : (0 : ℝ) < sinh h / h := div_pos (sinh_pos_iff.2 hh) hh + rw [hψdef] at h0 + rw [log_div (ne_of_gt (sinh_pos_iff.2 hh)) (ne_of_gt hh)] + linarith + +/-- Strong exponential form, including the endpoint `h = 0`. -/ +theorem sinh_le_mul_exp {h : ℝ} (hh : 0 ≤ h) (hh10 : h ≤ 10) : + sinh h ≤ h * exp ((7 / 8 : ℝ) * (sqrt (9 + (8 / 7 : ℝ) * h ^ 2) - 3)) := by + rcases eq_or_lt_of_le hh with rfl | hpos + · simp + · have hd : (0 : ℝ) < sinh h / h := div_pos (sinh_pos_iff.2 hpos) hpos + grw [← (log_le_iff_le_exp hd).1 (log_sinh_div_le hpos hh10)] + field_simp + simp + + +end Sendov.DistillationHyperbolic diff --git a/Sendov/Common/DistillationKernel.lean b/Sendov/Common/DistillationKernel.lean new file mode 100644 index 0000000..c640d0e --- /dev/null +++ b/Sendov/Common/DistillationKernel.lean @@ -0,0 +1,105 @@ +/- +Copyright (c) 2026 Terence Tao. All rights reserved. +Released under Apache 2.0 license as described in the file LICENSE. +The integral comparison proof is generalized from Sendov.Common.Chord by Terence Tao. +-/ +import Sendov.Common.Quadratic + +/-! +# Scalar kernels for the two-chord distillation route + +Mathematical source: Senjian An, *Proof Distillation for Sendov's Conjecture*, +revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, equations (2.2), (4.4), +and the parameter comparison in Section 2.4. Paper: CC BY 4.0, +https://creativecommons.org/licenses/by/4.0/ . This is a new Lean formulation, +not a transcription of an upstream formal proof (the upstream has none). + +The scalar kernel is nonnegative on the integration interval without the +stronger global feasibility hypothesis. This matters for the enlarged paper +parameter domain used by the scalar comparisons and the two-chord integral bound. +-/ + +namespace Sendov + +open MeasureTheory + +/-- Paper kernel, with real degree parameter `m = n - 1`. -/ +noncomputable def polarKernel (m α η t : ℝ) : ℝ := + (1 - t) ^ 2 + η * t + (2 * α / m) * t * (1 - t) + +/-- Exact coordinate map to the pre-existing quadratic. -/ +lemma polarKernel_eq_QQ (m α η t : ℝ) : + polarKernel m α η t = QQ (1 - α / m - η / 2) (1 - 2 * α / m) t := by + simp only [polarKernel, QQ, div_eq_mul_inv] + ring + +/-- The enlarged scalar domain needs interval positivity, not global feasibility. -/ +lemma polarKernel_nonneg {m α η t : ℝ} (hm : 0 ≤ m) (hα : 0 ≤ α) + (hη : 0 ≤ η) (ht : t ∈ Set.Icc (0 : ℝ) 1) : 0 ≤ polarKernel m α η t := by + unfold polarKernel + exact add_nonneg (add_nonneg (sq_nonneg _) (mul_nonneg hη ht.1)) + (mul_nonneg (mul_nonneg (div_nonneg (by positivity) hm) ht.1) + (sub_nonneg.mpr ht.2)) + +/-- Increasing the endpoint parameter increases the kernel on `[0,1]`. -/ +lemma polarKernel_mono_eta {m α η₁ η₂ t : ℝ} (hη : η₁ ≤ η₂) (ht : 0 ≤ t) : + polarKernel m α η₁ t ≤ polarKernel m α η₂ t := by + unfold polarKernel + gcongr + +/-- Increasing alpha increases the kernel for fixed endpoint parameter. -/ +lemma polarKernel_mono_alpha {m α₁ α₂ η t : ℝ} (hm : 0 < m) (hα : α₁ ≤ α₂) + (ht : t ∈ Set.Icc (0 : ℝ) 1) : + polarKernel m α₁ η t ≤ polarKernel m α₂ η t := by + unfold polarKernel + gcongr + · exact sub_nonneg.mpr ht.2 + · exact ht.1 + +/-- Exact secant gap, valid before imposing any sign hypotheses. -/ +lemma QQ_secant_gap (c A l r t : ℝ) (hlr : l ≠ r) : + ((r - t) * QQ c A l + (t - l) * QQ c A r) / (r - l) - QQ c A t = + A * (t - l) * (r - t) := by + have hrl : r - l ≠ 0 := sub_ne_zero.mpr (Ne.symm hlr) + unfold QQ + field_simp + ring + +/-- Each secant is an upper bound on its own interval when the quadratic is convex. -/ +lemma QQ_le_secant {c A l r t : ℝ} (hA : 0 ≤ A) (hlr : l < r) + (ht : t ∈ Set.Icc l r) : + QQ c A t ≤ ((r - t) * QQ c A l + (t - l) * QQ c A r) / (r - l) := by + have h := QQ_secant_gap c A l r t hlr.ne + have hn := mul_nonneg (mul_nonneg hA (sub_nonneg.mpr ht.1)) + (sub_nonneg.mpr ht.2) + linarith + +/-- Integral comparison with exactly the positivity needed on the interval. +This generalization serves both actual polynomial data and the enlarged scalar domain. -/ +lemma integral_QQ_anti_on {c₁ c₂ A : ℝ} (hle : c₁ ≤ c₂) + (hQ : ∀ t ∈ Set.Icc (0 : ℝ) 1, 0 ≤ QQ c₂ A t) {r : ℝ} (hr : 0 ≤ r) + (k : ℕ) : + (∫ t in (0 : ℝ)..1, t ^ k * QQ c₂ A t ^ r) + ≤ ∫ t in (0 : ℝ)..1, t ^ k * QQ c₁ A t ^ r := by + refine intervalIntegral.integral_mono_on (by norm_num) + ((continuous_pow_mul_QQ c₂ A k hr).intervalIntegrable _ _) + ((continuous_pow_mul_QQ c₁ A k hr).intervalIntegrable _ _) ?_ + intro t ht + refine mul_le_mul_of_nonneg_left ?_ (pow_nonneg ht.1 k) + refine Real.rpow_le_rpow (hQ t ht) ?_ hr + simp only [QQ] + nlinarith [ht.1, hle] + +/-- Paper parameter monotonicity of the integral, for every nonnegative exponent. +No geometric feasibility is assumed. -/ +lemma integral_polarKernel_mono_eta {m α η₁ η₂ r : ℝ} (hm : 0 ≤ m) + (hα : 0 ≤ α) (hη₁ : 0 ≤ η₁) (hη : η₁ ≤ η₂) (hr : 0 ≤ r) (k : ℕ) : + (∫ t in (0 : ℝ)..1, t ^ k * polarKernel m α η₁ t ^ r) + ≤ ∫ t in (0 : ℝ)..1, t ^ k * polarKernel m α η₂ t ^ r := by + simp only [polarKernel_eq_QQ] + refine integral_QQ_anti_on (by linarith) ?_ hr k + intro t ht + rw [← polarKernel_eq_QQ] + exact polarKernel_nonneg hm hα hη₁ ht + +end Sendov diff --git a/Sendov/Common/DistillationMajorant.lean b/Sendov/Common/DistillationMajorant.lean new file mode 100644 index 0000000..1a73379 --- /dev/null +++ b/Sendov/Common/DistillationMajorant.lean @@ -0,0 +1,30 @@ +import Sendov.Common.DistillationFactors +import Sendov.Common.TwoChord + +/-! +# The proved scalar majorant + +This joins the two-chord integral estimate to the regularized factors from +Senjian An's *Proof Distillation for Sendov's Conjecture*, revision +`e8ae601491ec171ab4f7f8456113dd6a047aa85d`, Section 4. +Mathematical source: https://github.com/SJanPerth/Sendov-Proof-Distillation +(CC BY 4.0; https://creativecommons.org/licenses/by/4.0/). +This is a new Lean formulation. The integral bound is proved, not an assumption. +The remaining finite and tail component bounds are separate theorems. +-/ + +namespace Sendov + +/-- The complete two-chord upper bound for the cubic scalar obstruction. +Positive alpha is intentional: the raw scalar definition at zero is not its +continuous extension. No extra integrability or geometric feasibility is needed. -/ +theorem distillScalar_le_majorant {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) + (hαm : 2 * α ≤ m) : + scalarObstruction m α (cubicPolarEnvelope α) ≤ + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α := by + apply distillScalar_le_components hm hα + simpa only [distillNode_eq] using + integral_polarKernel_two_chord hm hα.le hαm + (cubicPolarEnvelope_nonneg hα.le) (cubicPolarEnvelope_lt_one hα.le) + +end Sendov diff --git a/Sendov/Common/Quadratic.lean b/Sendov/Common/Quadratic.lean index 877abba..8d21381 100644 --- a/Sendov/Common/Quadratic.lean +++ b/Sendov/Common/Quadratic.lean @@ -6,32 +6,10 @@ Authors: Terence Tao import Sendov.Common.Rpow /-! -# The quadratic `1 - 2ct + At²` +# The actual quadratic -Two quadratics drive the whole development, and they are the same object with different -parameters: - -* `β(t) = 1 - 2axt + a²t²`, the quantity the blog post's inequalities are stated in; -* `Q n α t = 1 - 2c(α)t + a²t²`, what `β` becomes after `β(1)` is replaced by `α/(3+α)`. - -So the facts about them — nonnegativity under feasibility, the chord bound below the vertex, -monotonicity above it — are proved once here for - - `QQ c A t = 1 - 2ct + At²`, - -and `Sendov.Q n α t = QQ (c n α) (A n α) t` holds by `rfl`. - -Note which hypothesis each fact needs. Nonnegativity is exactly feasibility `c² ≤ A`, since -`QQ = (1-ct)² + (A-c²)t²`. The bound `QQ ≤ 1` on `[0,1]` needs only `0 ≤ c` together with -`QQ 1 ≤ 1`: writing `QQ t - 1 = t(At - 2c)`, the value at `t = 1` already gives `A ≤ 2c`, and -then `At ≤ 2c` whether `A` is nonnegative (as `At ≤ A`) or negative (as `At ≤ 0 ≤ 2c`). That -matters, because `A` is genuinely negative in parts of the range. - -## Main statements - -* `Sendov.QQ_nonneg`, `Sendov.QQ_le_one`; -* `Sendov.QQ_le_chord`: `QQ t ≤ 1 - ct` below the vertex; -* `Sendov.QQ_le_at_one`: `QQ t ≤ QQ 1` above it. +`QQ c A t = 1 - 2ct + At²` supports actual polar/origin coordinates and scalar kernels. +The letters `c` and `A` here are independent real parameters, not an obsolete substitution. -/ namespace Sendov @@ -39,18 +17,12 @@ namespace Sendov /-- The quadratic `1 - 2ct + At²`. -/ noncomputable def QQ (c A t : ℝ) : ℝ := 1 - 2 * c * t + A * t ^ 2 -/-- `Sendov.Q` is an instance of `Sendov.QQ`. Stated before the section variables below, -which deliberately shadow `Sendov.c` and `Sendov.A`. -/ -lemma Q_eq_QQ (n : ℕ) (α t : ℝ) : Q n α t = QQ (c n α) (A n α) t := rfl - variable {c A t : ℝ} /-- `QQ` as a sum of squares. -/ lemma QQ_eq (c A t : ℝ) : QQ c A t = (1 - c * t) ^ 2 + (A - c ^ 2) * t ^ 2 := by simp only [QQ]; ring -lemma QQ_zero (c A : ℝ) : QQ c A 0 = 1 := by simp [QQ] - lemma QQ_one (c A : ℝ) : QQ c A 1 = 1 - 2 * c + A := by simp [QQ] /-- Feasibility `c² ≤ A` says exactly that `QQ` is a sum of squares. -/ @@ -58,17 +30,6 @@ lemma QQ_nonneg (hfeas : c ^ 2 ≤ A) (t : ℝ) : 0 ≤ QQ c A t := by rw [QQ_eq] exact add_nonneg (sq_nonneg _) (mul_nonneg (sub_nonneg.2 hfeas) (sq_nonneg _)) -/-- `QQ ≤ 1` on `[0,1]`, from `QQ 1 ≤ 1` and `0 ≤ c` alone. -/ -lemma QQ_le_one (hc : 0 ≤ c) (hB : QQ c A 1 ≤ 1) (ht0 : 0 ≤ t) (ht1 : t ≤ 1) : - QQ c A t ≤ 1 := by - have hAc : A - 2 * c ≤ 0 := by rw [QQ_one] at hB; linarith - have hAt : A * t ≤ 2 * c := by - rcases le_total 0 A with h | h - · exact (mul_le_of_le_one_right h ht1).trans (sub_nonpos.1 hAc) - · exact (mul_nonpos_of_nonpos_of_nonneg h ht0).trans (by positivity) - simp only [QQ] - nlinarith [mul_nonneg ht0 (sub_nonneg.2 hAt)] - /-- Below the vertex, `QQ` lies under the chord `1 - ct`. -/ lemma QQ_le_chord (ht0 : 0 ≤ t) (ht : A * t ≤ c) : QQ c A t ≤ 1 - c * t := by simp only [QQ] diff --git a/Sendov/Common/Rpow.lean b/Sendov/Common/Rpow.lean index e17a3d7..81e7098 100644 --- a/Sendov/Common/Rpow.lean +++ b/Sendov/Common/Rpow.lean @@ -7,22 +7,10 @@ import Sendov.Common.Basic import Mathlib.Analysis.SpecialFunctions.Integrals.Basic /-! -# Real powers, shared by both ranges +# Real powers and integration -The exponent `(n-4)/2` in `Sendov.R` is a real exponent, so both halves of the development — -the finite range and the large-degree argument — manipulate `Real.rpow`, and both need the -integrand `t ^ 3 * Q ^ e` to be continuous in order to integrate it. Those facts have no -connection to either strategy, so they live here rather than in the strategy-specific files. - -In particular: - -* the finite range uses `Sendov.continuous_integrand` to compare integrals in - `Sendov.integral_rpow_le`, and the large-degree argument needs the same fact to split - `∫₀¹` at the vertex of `Q`; -* `Sendov.rpow_add_nat_pos` remains a compatibility wrapper for positive bases. The Beta - integrals use Mathlib’s zero-compatible splitting directly; splitting a real power into - a real and a natural part also turns `B ^ ((n-4)/2)` into `B ^ k * √B` in the large-degree - reduction. +The zero-to-one real-power integral and continuity lemma support the linear and cubic Beta +integrals and the actual quadratic kernel. -/ namespace Sendov @@ -35,29 +23,9 @@ lemma integral_rpow_zero_one {s : ℝ} (hs : -1 < s) : rw [integral_rpow (Or.inl hs), Real.one_rpow, Real.zero_rpow (by linarith)] ring -/-- `x ^ (s + m) = x ^ s * x ^ m` for positive `x` and a natural `m`. -/ -lemma rpow_add_nat_pos {x : ℝ} (hx : 0 < x) (s : ℝ) (m : ℕ) : - x ^ (s + (m : ℝ)) = x ^ s * x ^ m := - Real.rpow_add_natCast hx.ne' s m - /-- `fun x ↦ x ^ e` is continuous on all of `ℝ` for a nonnegative real exponent `e`. The exponent must be nonnegative: at `e < 0` the function blows up at the origin. -/ lemma continuous_rpow_const {e : ℝ} (he : 0 ≤ e) : Continuous fun x : ℝ => x ^ e := Real.continuous_rpow_const he -/-- The integrand of `Sendov.R` is continuous, hence interval integrable. Needed wherever an -integral involving `Q ^ e` is split or compared. -/ -lemma continuous_integrand (n : ℕ) (α : ℝ) {e : ℝ} (he : 0 ≤ e) : - Continuous fun t : ℝ => t ^ 3 * Q n α t ^ e := by - have hQ : Continuous fun t : ℝ => Q n α t := by - simp only [Q]; fun_prop - have h3 : Continuous fun t : ℝ => t ^ 3 := by fun_prop - exact h3.mul ((continuous_rpow_const he).comp hQ) - -/-- On `[0,1]` a real power is decreasing in the exponent: `x ^ s ≤ x ^ t` for `t ≤ s`. -Used to drop the `√B` from `B ^ (k + 1/2)`. -/ -lemma rpow_le_rpow_of_le_one {x s t : ℝ} (hx0 : 0 < x) (hx1 : x ≤ 1) (hts : t ≤ s) : - x ^ s ≤ x ^ t := - Real.rpow_le_rpow_of_exponent_ge hx0 hx1 hts - end Sendov diff --git a/Sendov/Common/TwoChord.lean b/Sendov/Common/TwoChord.lean new file mode 100644 index 0000000..8a8fcdc --- /dev/null +++ b/Sendov/Common/TwoChord.lean @@ -0,0 +1,221 @@ +/- +Released under Apache 2.0 license as described in the file LICENSE. +-/ +import Sendov.Common.Chord +import Sendov.Common.DistillationKernel +import Mathlib.Analysis.Convex.SpecificFunctions.Basic + +/-! +# Two-chord integral bound on the enlarged scalar domain + +Adapted mathematically from Senjian An, *Proof Distillation for Sendov's Conjecture*, +revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, Section 4, equations (4.3)–(4.6) +(TEX lines 371–435). Paper licensed CC BY 4.0: +https://creativecommons.org/licenses/by/4.0/ . This is a new Lean proof, not upstream code. + +The endpoint parameter is independent of alpha: both the original linear envelope and +its cubic improvement can use this API. No global geometric feasibility is required. +-/ + +namespace Sendov + +open MeasureTheory + +/-- The interior node stays strictly between zero and one, including degenerate parameters. -/ +lemma polarKernel_three_fifths_mem {m α η : ℝ} (hm : 0 < m) (hα : 0 ≤ α) + (hαm : 2 * α ≤ m) (hη : 0 ≤ η) (hη1 : η < 1) : + polarKernel m α η (3 / 5) ∈ Set.Ioo (0 : ℝ) 1 := by + have hratio : 0 ≤ 2 * α / m := div_nonneg (by positivity) hm.le + have hratio1 : 2 * α / m ≤ 1 := (div_le_one hm).mpr hαm + unfold polarKernel + constructor <;> nlinarith + +/-- First secant, without a geometric feasibility assumption. -/ +lemma polarKernel_le_first_chord {m α η t : ℝ} (hm : 0 < m) (hαm : 2 * α ≤ m) + (ht : t ∈ Set.Icc (0 : ℝ) (3 / 5)) : + polarKernel m α η t ≤ 1 - ((1 - polarKernel m α η (3 / 5)) / (3 / 5)) * t := by + have hA : 0 ≤ 1 - 2 * α / m := sub_nonneg.mpr ((div_le_one hm).mpr hαm) + have h := QQ_le_secant (c := 1 - α / m - η / 2) hA + (by norm_num : (0 : ℝ) < 3 / 5) ht + simp only [← polarKernel_eq_QQ] at h + have hzero : polarKernel m α η 0 = 1 := by simp [polarKernel] + rw [hzero] at h + convert h using 1; ring + +/-- Second secant on its own interval. -/ +lemma polarKernel_le_second_chord {m α η t : ℝ} (hm : 0 < m) (hαm : 2 * α ≤ m) + (ht : t ∈ Set.Icc (3 / 5 : ℝ) 1) : + polarKernel m α η t ≤ (1 - t) / (1 - 3 / 5) * polarKernel m α η (3 / 5) + + (t - 3 / 5) / (1 - 3 / 5) * η := by + have hA : 0 ≤ 1 - 2 * α / m := sub_nonneg.mpr ((div_le_one hm).mpr hαm) + have h := QQ_le_secant (c := 1 - α / m - η / 2) hA + (by norm_num : (3 / 5 : ℝ) < 1) ht + simp only [← polarKernel_eq_QQ] at h + have hone : polarKernel m α η 1 = η := by simp [polarKernel] + rw [hone] at h + convert h using 1; ring + +/-- Convexity separates the endpoint powers on the second interval, also at zero endpoints. -/ +lemma polarKernel_rpow_le_second_chord {m α η s t : ℝ} (hm : 0 < m) + (hα : 0 ≤ α) (hαm : 2 * α ≤ m) (hη : 0 ≤ η) (hs : 1 ≤ s) + (ht : t ∈ Set.Icc (3 / 5 : ℝ) 1) : + polarKernel m α η t ^ s ≤ + (1 - t) / (1 - 3 / 5) * polarKernel m α η (3 / 5) ^ s + + (t - 3 / 5) / (1 - 3 / 5) * η ^ s := by + have hbase := polarKernel_nonneg hm.le hα hη + (show t ∈ Set.Icc (0 : ℝ) 1 from ⟨by linarith [ht.1], ht.2⟩) + refine (Real.rpow_le_rpow hbase (polarKernel_le_second_chord hm hαm ht) + (by linarith)).trans ?_ + have hb := polarKernel_nonneg hm.le hα hη + (show (3 / 5 : ℝ) ∈ Set.Icc (0 : ℝ) 1 by norm_num) + have hw₀ : 0 ≤ (1 - t) / (1 - 3 / 5 : ℝ) := + div_nonneg (sub_nonneg.mpr ht.2) (by norm_num) + have hw₁ : 0 ≤ (t - 3 / 5) / (1 - 3 / 5 : ℝ) := + div_nonneg (sub_nonneg.mpr ht.1) (by norm_num) + have hw : (1 - t) / (1 - 3 / 5 : ℝ) + (t - 3 / 5) / (1 - 3 / 5 : ℝ) = 1 := by ring + simpa only [smul_eq_mul] using (convexOn_rpow hs).2 hb hη hw₀ hw₁ hw + +/-- Continuity provides all interval integrability used below. -/ +lemma continuous_cube_mul_polarKernel_rpow (m α η : ℝ) {s : ℝ} (hs : 0 ≤ s) : + Continuous (fun t : ℝ => t ^ 3 * polarKernel m α η t ^ s) := by + simp only [polarKernel_eq_QQ] + exact continuous_pow_mul_QQ _ _ _ hs + +/-- First chord integrated exactly to its zero, never past a negative base. -/ +lemma integral_first_chord_to_zero {b s : ℝ} (hb : b < 1) (hs : 0 < s) : + (∫ t in (0 : ℝ)..(3 / 5) / (1 - b), t ^ 3 * (1 - ((1 - b) / (3 / 5)) * t) ^ s) = + 6 * (3 / 5) ^ 4 / ((s + 1) * (s + 2) * (s + 3) * (s + 4) * (1 - b) ^ 4) := by + have hc : 0 < (1 - b) / (3 / 5 : ℝ) := by positivity + have hend : (3 / 5 : ℝ) / (1 - b) = 1 / ((1 - b) / (3 / 5)) := by + rw [one_div_div] + rw [hend, integral_chord_pow hs hc] + rw [div_pow, div_mul_eq_mul_div, div_div_eq_mul_div] + ring + +/-- Extending the first chord to its zero gives the beta-integral majorant. -/ +lemma integral_polarKernel_first_chord {m α η s : ℝ} (hm : 0 < m) + (hα : 0 ≤ α) (hαm : 2 * α ≤ m) (hη : 0 ≤ η) (hη1 : η < 1) (hs : 0 < s) : + (∫ t in (0 : ℝ)..(3 / 5), t ^ 3 * polarKernel m α η t ^ s) ≤ + 6 * (3 / 5) ^ 4 / + ((s + 1) * (s + 2) * (s + 3) * (s + 4) * (1 - polarKernel m α η (3 / 5)) ^ 4) := by + set b := polarKernel m α η (3 / 5) + have hb := polarKernel_three_fifths_mem hm hα hαm hη hη1 + have hz : (3 / 5 : ℝ) ≤ (3 / 5) / (1 - b) := by + apply (le_div_iff₀ (by dsimp [b]; linarith [hb.2])).mpr + dsimp [b] + nlinarith [hb.1] + have hcont : Continuous (fun t : ℝ => t ^ 3 * (1 - ((1 - b) / (3 / 5)) * t) ^ s) := + (by fun_prop : Continuous fun t : ℝ => t ^ 3).mul + ((continuous_rpow_const hs.le).comp (by fun_prop)) + have hfirst : (∫ t in (0 : ℝ)..(3 / 5), t ^ 3 * polarKernel m α η t ^ s) ≤ + ∫ t in (0 : ℝ)..(3 / 5), t ^ 3 * (1 - ((1 - b) / (3 / 5)) * t) ^ s := by + refine intervalIntegral.integral_mono_on (by norm_num) + ((continuous_cube_mul_polarKernel_rpow m α η hs.le).intervalIntegrable _ _) + (hcont.intervalIntegrable _ _) ?_ + intro t ht + apply mul_le_mul_of_nonneg_left _ (pow_nonneg ht.1 3) + exact Real.rpow_le_rpow + (polarKernel_nonneg hm.le hα hη ⟨ht.1, by linarith [ht.2]⟩) + (polarKernel_le_first_chord hm hαm ht) hs.le + have hrest : 0 ≤ ∫ t in (3 / 5 : ℝ)..(3 / 5) / (1 - b), + t ^ 3 * (1 - ((1 - b) / (3 / 5)) * t) ^ s := by + refine intervalIntegral.integral_nonneg hz ?_ + intro t ht + have htz : ((1 - b) / (3 / 5)) * t ≤ 1 := by + have ht' := (le_div_iff₀ (show 0 < 1 - b by dsimp [b]; linarith [hb.2])).mp ht.2 + nlinarith + exact mul_nonneg (pow_nonneg (by linarith [ht.1]) 3) + (Real.rpow_nonneg (sub_nonneg.mpr htz) s) + have hadd := intervalIntegral.integral_add_adjacent_intervals (μ := volume) + (hcont.intervalIntegrable 0 (3 / 5)) + (hcont.intervalIntegrable (3 / 5) ((3 / 5) / (1 - b))) + rw [integral_first_chord_to_zero hb.2 hs] at hadd + linarith + +/-- The left endpoint's exact rational weight on the second interval. -/ +lemma integral_second_chord_left_weight : + (∫ t in (3 / 5 : ℝ)..1, t ^ 3 * ((1 - t) / (1 - 3 / 5))) = 259 / 3125 := by + have heq : (fun t : ℝ => t ^ 3 * ((1 - t) / (1 - 3 / 5))) = + fun t : ℝ => (5 / 2) * (t ^ 3 - t ^ 4) := by funext t; ring + rw [heq, intervalIntegral.integral_const_mul, + intervalIntegral.integral_sub + ((continuous_pow 3).intervalIntegrable _ _) ((continuous_pow 4).intervalIntegrable _ _), + integral_pow, integral_pow] + norm_num + +/-- The right endpoint's exact rational weight on the second interval. -/ +lemma integral_second_chord_right_weight : + (∫ t in (3 / 5 : ℝ)..1, t ^ 3 * ((t - 3 / 5) / (1 - 3 / 5))) = 421 / 3125 := by + have heq : (fun t : ℝ => t ^ 3 * ((t - 3 / 5) / (1 - 3 / 5))) = + fun t : ℝ => (5 / 2) * t ^ 4 - (3 / 2) * t ^ 3 := by funext t; ring + rw [heq, intervalIntegral.integral_sub + (((continuous_pow 4).const_mul (5 / 2)).intervalIntegrable _ _) + (((continuous_pow 3).const_mul (3 / 2)).intervalIntegrable _ _), + intervalIntegral.integral_const_mul, intervalIntegral.integral_const_mul, + integral_pow, integral_pow] + norm_num + +/-- Integral of the separated endpoint powers. -/ +lemma integral_second_chord_powers (b η s : ℝ) : + (∫ t in (3 / 5 : ℝ)..1, t ^ 3 * + ((1 - t) / (1 - 3 / 5) * b ^ s + (t - 3 / 5) / (1 - 3 / 5) * η ^ s)) = + (259 / 3125) * b ^ s + (421 / 3125) * η ^ s := by + have heq : (fun t : ℝ => t ^ 3 * + ((1 - t) / (1 - 3 / 5) * b ^ s + (t - 3 / 5) / (1 - 3 / 5) * η ^ s)) = + fun t : ℝ => (t ^ 3 * ((1 - t) / (1 - 3 / 5))) * b ^ s + + (t ^ 3 * ((t - 3 / 5) / (1 - 3 / 5))) * η ^ s := by funext t; ring + rw [heq, intervalIntegral.integral_add + ((by fun_prop : Continuous (fun t : ℝ => + (t ^ 3 * ((1 - t) / (1 - 3 / 5))) * b ^ s)).intervalIntegrable _ _) + ((by fun_prop : Continuous (fun t : ℝ => + (t ^ 3 * ((t - 3 / 5) / (1 - 3 / 5))) * η ^ s)).intervalIntegrable _ _), + intervalIntegral.integral_mul_const, intervalIntegral.integral_mul_const, + integral_second_chord_left_weight, integral_second_chord_right_weight] + +/-- The second integral is bounded by its two endpoint powers. -/ +lemma integral_polarKernel_second_chord {m α η s : ℝ} (hm : 0 < m) + (hα : 0 ≤ α) (hαm : 2 * α ≤ m) (hη : 0 ≤ η) (hs : 1 ≤ s) : + (∫ t in (3 / 5 : ℝ)..1, t ^ 3 * polarKernel m α η t ^ s) ≤ + (259 / 3125) * polarKernel m α η (3 / 5) ^ s + (421 / 3125) * η ^ s := by + rw [← integral_second_chord_powers] + refine intervalIntegral.integral_mono_on (by norm_num) + ((continuous_cube_mul_polarKernel_rpow m α η (by linarith)).intervalIntegrable _ _) + ((by fun_prop : Continuous (fun t : ℝ => t ^ 3 * + ((1 - t) / (1 - 3 / 5) * polarKernel m α η (3 / 5) ^ s + + (t - 3 / 5) / (1 - 3 / 5) * η ^ s))).intervalIntegrable _ _) ?_ + intro t ht + exact mul_le_mul_of_nonneg_left (polarKernel_rpow_le_second_chord hm hα hαm hη hs ht) + (pow_nonneg (by linarith [ht.1]) 3) + +/-- Two-chord bound for any real exponent at least one. Integrability is automatic. -/ +theorem integral_polarKernel_two_chord_rpow {m α η s : ℝ} (hm : 0 < m) + (hα : 0 ≤ α) (hαm : 2 * α ≤ m) (hη : 0 ≤ η) (hη1 : η < 1) (hs : 1 ≤ s) : + (∫ t in (0 : ℝ)..1, t ^ 3 * polarKernel m α η t ^ s) ≤ + 6 * (3 / 5) ^ 4 / + ((s + 1) * (s + 2) * (s + 3) * (s + 4) * (1 - polarKernel m α η (3 / 5)) ^ 4) + + (259 / 3125) * polarKernel m α η (3 / 5) ^ s + (421 / 3125) * η ^ s := by + have hcont := continuous_cube_mul_polarKernel_rpow m α η (show 0 ≤ s by linarith) + rw [← intervalIntegral.integral_add_adjacent_intervals + (hcont.intervalIntegrable 0 (3 / 5)) (hcont.intervalIntegrable (3 / 5) 1)] + have hfirst := integral_polarKernel_first_chord hm hα hαm hη hη1 (show 0 < s by linarith) + have hsecond := integral_polarKernel_second_chord hm hα hαm hη hs + linarith + +/-- The paper's two-chord estimate with real degree, arbitrary admissible eta, and all endpoints. -/ +theorem integral_polarKernel_two_chord {m α η : ℝ} (hm : 5 ≤ m) + (hα : 0 ≤ α) (hαm : 2 * α ≤ m) (hη : 0 ≤ η) (hη1 : η < 1) : + (∫ t in (0 : ℝ)..1, t ^ 3 * polarKernel m α η t ^ ((m - 3) / 2)) ≤ + 96 * (3 / 5) ^ 4 / + ((m - 1) * (m + 1) * (m + 3) * (m + 5) * (1 - polarKernel m α η (3 / 5)) ^ 4) + + (259 / 3125) * polarKernel m α η (3 / 5) ^ ((m - 3) / 2) + + (421 / 3125) * η ^ ((m - 3) / 2) := by + have h := integral_polarKernel_two_chord_rpow (by linarith : 0 < m) hα hαm hη hη1 + (by linarith : 1 ≤ (m - 3) / 2) + have heq : ((m - 3) / 2 + 1) * ((m - 3) / 2 + 2) * ((m - 3) / 2 + 3) * + ((m - 3) / 2 + 4) * (1 - polarKernel m α η (3 / 5)) ^ 4 = + ((m - 1) * (m + 1) * (m + 3) * (m + 5) * + (1 - polarKernel m α η (3 / 5)) ^ 4) / 16 := by ring + rw [heq, div_div_eq_mul_div] at h + convert h using 1; ring + +end Sendov diff --git a/Sendov/Defs.lean b/Sendov/Defs.lean index eda6800..96e5fa8 100644 --- a/Sendov/Defs.lean +++ b/Sendov/Defs.lean @@ -7,81 +7,10 @@ import Mathlib.Analysis.SpecialFunctions.Pow.Real import Mathlib.MeasureTheory.Integral.IntervalIntegral.Basic /-! -# Definitions for the finite-range numerical claim +# Shared coordinates -This file fixes the notation of the numerical claim `stat`, the one step of the proof that is -discharged by computation rather than by argument. It contains definitions only; no statement -is made here. - -`stat` cannot be stated in this file, because every other file in the development imports it -for the definitions below, and putting the claim at the bottom of the import graph would -prevent it from being proved. It is stated and proved in `Sendov.FiniteRange.Cover`, so -auditing it means reading this file for the definitions and that one for the claim built from -them. - -For where `stat` enters the proof as a whole, see `Sendov.Reduction.Main` and the repository -README; for the finite-range component on its own, see `docs/finite-range.md`. - -## Background - -In the blog post one argues by contradiction from a degree `n` polynomial with all zeroes -in the unit disk, a zero `0 ≤ a < 1`, and all critical points at distance `≥ 1` from `a`. -Writing `α := (n-1)(1-a²)/2` and `β(1) := 1 - 2ax + a²` (where `x` is the real part of the -mean of the reciprocal critical-point data), the post derives: - -* `0 < β(1) < α/(3+α)` (the simplified polar inequality); -* `α ≤ 17` and an inequality `(1le)`, valid for `n ≥ 5`; -* the elimination of every degree `n ≥ 98` by an asymptotic argument. - -Monotonicity in `β(1)` lets one replace `β(1)` by `α/(3+α)` in `(1le)`, which replaces -`a x` by `c` and `β(t)` by `Q t` below. The resulting inequality is equation `stat` of the -post, namely `1 ≤ R n α`. The upper bound `c ≤ a x` moreover forces the feasibility -constraint `c ^ 2 ≤ A`, which is what keeps `α` away from its formal upper limit `(n-1)/2`. - -What is left open is that `stat` is infeasible on the remaining range - -`5 ≤ n ≤ 97`, `0 ≤ α ≤ 17`, `c ^ 2 ≤ A`, - -which is exactly `Sendov.finite_range` below. - -## Main statements - -* `Sendov.M`, `Sendov.A`, `Sendov.c`, `Sendov.Q`, `Sendov.R`: the quantities of `stat`. - -The claim assembled from them lives in `Sendov.FiniteRange.Cover`: - -* `Sendov.finite_range`: on the range above, `R n α < 1`; -* `Sendov.finite_range_le_100`: the same for `5 ≤ n ≤ 100`, which is what is actually - proved — the finite certification was pushed past `97` to meet the large-degree argument; -* `Sendov.finite_range_contradiction`: consequently the post's equation `stat`, - `1 ≤ R n α`, is contradictory on that range. This is the form in which the claim is - applied. - -## Implementation notes - -* `α = 0` is allowed, although the blog post has `α > 0` (an earlier inequality there was - divided by `α`). This makes the statement slightly stronger and is harmless: the bound - extends continuously to `α = 0` and stays below `1` there. -* No upper bound on `α` in terms of `n` is assumed: `hfeas` already forces `0 ≤ A n α`, - hence `α ≤ (n-1)/2`. -* The exponent `((n:ℝ) - 4) / 2` is a half-integer for odd `n`, so `Q n α t ^ _` is - `Real.rpow`. Under `hfeas` one has `0 ≤ Q n α t` for `0 ≤ t ≤ 1`, so no junk values of - `rpow` at negative bases arise; the integrand is continuous, so no integrability - hypothesis is needed either. - -## Numerical diagnostics - -These are *not* inputs to the proof, and must not be used as hypotheses; they are recorded -only to indicate the size of the margin. Numerically, `R n α` attains a maximum of about -`0.8529` over the feasible range, at `n = 53`, `α = 17` — which remains inside the range -below, so shortening it does not make the claim easier. For comparison, `R 5 0 ≈ 0.6458` -and `R 97 17 ≈ 0.2921`. The feasibility constraint is binding at low degree: it caps -`α ≲ 1.68` when `n = 5` and `α ≲ 2.19` when `n = 6`, and only ceases to cut into -`[0, 17]` from `n = 36` onwards. - -## References - -* T. Tao, *A digestion of the proof of Sendov's conjecture*, blog post, 2026. +`M n = n - 1` and `A n α = 1 - 2α/M n` are the actual degree and squared-radius coordinates. +The selected scalar route uses the actual quadratic and the cubic polar envelope. -/ namespace Sendov @@ -93,24 +22,6 @@ noncomputable def M (n : ℕ) : ℝ := (n : ℝ) - 1 The blog post's `a ^ 4` is therefore `A n α ^ 2`. -/ noncomputable def A (n : ℕ) (α : ℝ) : ℝ := 1 - 2 * α / M n -/-- `c n α = 1 - α/(n-1) - α/(2(3+α))`: the value taken by `a * x` after the substitution -of `α/(3+α)` for `β(1)`. This is `c(α)` in the blog post. -/ -noncomputable def c (n : ℕ) (α : ℝ) : ℝ := 1 - α / M n - α / (2 * (3 + α)) - -/-- `Q n α t = 1 - 2 c t + A t ^ 2`: the quadratic replacing `β(t) = 1 - 2 a x t + a² t²` -after the substitution of `α/(3+α)` for `β(1)`. Note `Q n α 1 = α/(3+α)`. -/ -noncomputable def Q (n : ℕ) (α : ℝ) (t : ℝ) : ℝ := 1 - 2 * c n α * t + A n α * t ^ 2 - -/-- `R n α` is the right-hand side of equation `stat` of the blog post: -`1/6 + 1/(4(3+α)) + 1/(2(n-1)) + 1/(4(n-1)(3+α)) - + a⁴ n (n-1) (n-2)/(4(3+α)) * ∫ t in 0..1, t³ (1 - 2c(α)t + a²t²) ^ ((n-4)/2)`. -/ -noncomputable def R (n : ℕ) (α : ℝ) : ℝ := - 1 / 6 + 1 / (4 * (3 + α)) + 1 / (2 * M n) + 1 / (4 * M n * (3 + α)) + - A n α ^ 2 * n * M n * ((n : ℝ) - 2) / (4 * (3 + α)) * - ∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ (((n : ℝ) - 4) / 2) -/-! The claim itself is stated and proved in `Sendov.FiniteRange.Cover` -(`Sendov.finite_range`, `Sendov.finite_range_contradiction`). It cannot live here: this file -sits at the bottom of the import graph, since every other file needs these definitions. -/ end Sendov diff --git a/Sendov/DistillationFinite/Row81.lean b/Sendov/DistillationFinite/Row81.lean new file mode 100644 index 0000000..612e137 --- /dev/null +++ b/Sendov/DistillationFinite/Row81.lean @@ -0,0 +1,96 @@ +import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.BernsteinList + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow81 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 81 x := by + refine (BernsteinCert.coeffs_pos + [3603169980, 101281054752, 1089452610954, 5569802774496, 13692055572072, 15406547380731, + 10739679509790, 2733585354369] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 81 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 81 α ≤ (169 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 81 x := by + refine (BernsteinCert.coeffs_pos + [114359017320, 3357049129056, 38559316406976, 219267310218336, 647941970508930, + 983688471433584, 773066148894270, 207673649421240] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 81 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 81 α ≤ (1 / 250) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 78 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 81 x := by + refine (BernsteinCert.coeffs_pos + [5117580, 75467700, 308981574, 320029530, 71709640] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 81 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 81 α ≤ (201 / 1000) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 78 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow81 + +theorem distillFinite_81 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 81 + distillT0 81 α + distillT1 81 α + distillT2 81 α ≤ (76691 / 121500) := by + have h0 := CriticalRow81.component0 α hα hd + have h1 := CriticalRow81.component1 α hα hd + have h2 := CriticalRow81.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_81 : ((76691 / 121500) : ℝ) < 199 / 200 := by norm_num + +theorem distillFiniteTailBase {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : + distillEBudget 81 + distillT0 81 α + distillT1 81 α + distillT2 81 α < 2 / 3 := by + exact (distillFinite_81 α hα h17).trans_lt (by norm_num) + +end Sendov diff --git a/Sendov/DistillationFinite/Rows13_20.lean b/Sendov/DistillationFinite/Rows13_20.lean new file mode 100644 index 0000000..d6f0260 --- /dev/null +++ b/Sendov/DistillationFinite/Rows13_20.lean @@ -0,0 +1,936 @@ +import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.BernsteinList + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow13 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 4)) : + 0 ≤ distillCritical0 13 x := by + refine (BernsteinCert.coeffs_pos + [95312609280, 986159038464, 4182255286272, 9323494875648, 11586221773824, 7716434879920, + 2252158751992, 69702872952] + (lo := 0) (hi := (13 / 4)) (s := 4826809) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((13 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 2) (13 / 2)) : + 0 ≤ -distillCritical0 13 x := by + refine (BernsteinCert.coeffs_pos + [1189709612, 37772699081, 260361665772, 828361550449, 1449618070732, 1449000260187, + 780713914268, 176894977259] + (lo := (7 / 2)) (hi := (13 / 2)) (s := 34992) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (7 / 2)) ((13 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : + distillT0 13 α ≤ (239 / 1000) := by + apply distillT0_le_of_critical (l := (13 / 4)) (r := (7 / 2)) (d := (13 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 3) : + 0 ≤ -distillCritical1 13 x := by + refine (BernsteinCert.coeffs_pos + [1645800, 16941952, 71804080, 160487408, 199865978, 132068736, 36713934, 381360] + (lo := 0) (hi := 3) (s := 9) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (3 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 4) (13 / 2)) : + 0 ≤ distillCritical1 13 x := by + refine (BernsteinCert.coeffs_pos + [936862162992, 22850723657552, 153778667321056, 494270967533056, 882182150561280, + 901351912066304, 495897196957184, 114401900763136] + (lo := (13 / 4)) (hi := (13 / 2)) (s := 4826809) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (13 / 4)) ((13 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : + distillT1 13 α ≤ (77 / 500) := by + apply distillT1_le_of_critical (l := 3) (r := (13 / 4)) (d := (13 / 2)) + 10 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 3) : + 0 ≤ -distillCritical2 13 x := by + refine (BernsteinCert.coeffs_pos + [3900, 20100, 33398, 18330, 784] + (lo := 0) (hi := 3) (s := 3) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (3 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 4) (13 / 2)) : + 0 ≤ distillCritical2 13 x := by + refine (BernsteinCert.coeffs_pos + [320316, 11716616, 44579760, 58856160, 25927552] + (lo := (13 / 4)) (hi := (13 / 2)) (s := 2197) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (13 / 4)) ((13 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : + distillT2 13 α ≤ (129 / 1000) := by + apply distillT2_le_of_critical (l := 3) (r := (13 / 4)) (d := (13 / 2)) + 10 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow13 + +theorem distillFinite_13 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : + distillEBudget 13 + distillT0 13 α + distillT1 13 α + distillT2 13 α ≤ (15929 / 19500) := by + have h0 := CriticalRow13.component0 α hα hd + have h1 := CriticalRow13.component1 α hα hd + have h2 := CriticalRow13.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_13 : ((15929 / 19500) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow14 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (7 / 2)) : + 0 ≤ distillCritical0 14 x := by + refine (BernsteinCert.coeffs_pos + [1634826240, 17468504064, 76407535872, 175522049280, 224895192000, 155251799056, + 48093576856, 2297476344] + (lo := 0) (hi := (7 / 2)) (s := 117649) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((7 / 2) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 4) 7) : + 0 ≤ -distillCritical0 14 x := by + refine (BernsteinCert.coeffs_pos + [31505747040, 3139887834864, 24475073676480, 82219170216960, 148918433249280, + 152794802917376, 84167676051456, 19458984509440] + (lo := (15 / 4)) (hi := 7) (s := 4826809) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (15 / 4)) (7 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : + distillT0 14 α ≤ (243 / 1000) := by + apply distillT0_le_of_critical (l := (7 / 2)) (r := (15 / 4)) (d := 7) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 4)) : + 0 ≤ -distillCritical1 14 x := by + refine (BernsteinCert.coeffs_pos + [8354066595840, 89082275364864, 390991396847616, 905593677189120, 1172159626377984, + 812792326493504, 246560391834720, 9461705445040] + (lo := 0) (hi := (13 / 4)) (s := 62748517) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((13 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 2) 7) : + 0 ≤ distillCritical1 14 x := by + refine (BernsteinCert.coeffs_pos + [8263120944, 371817286832, 2817201946960, 9576838303744, 17712993405312, 18584497896704, + 10449732005120, 2457165967360] + (lo := (7 / 2)) (hi := 7) (s := 117649) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (7 / 2)) (7 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : + distillT1 14 α ≤ (31 / 200) := by + apply distillT1_le_of_critical (l := (13 / 4)) (r := (7 / 2)) (d := 7) + 11 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 4)) : + 0 ≤ -distillCritical2 14 x := by + refine (BernsteinCert.coeffs_pos + [31933440, 170415360, 292567584, 166593880, 9195140] + (lo := 0) (hi := (13 / 4)) (s := 28561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((13 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 2) 7) : + 0 ≤ distillCritical2 14 x := by + refine (BernsteinCert.coeffs_pos + [15288, 1542572, 6226992, 8437200, 3777280] + (lo := (7 / 2)) (hi := 7) (s := 343) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (7 / 2)) (7 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : + distillT2 14 α ≤ (33 / 250) := by + apply distillT2_le_of_critical (l := (13 / 4)) (r := (7 / 2)) (d := 7) + 11 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow14 + +theorem distillFinite_14 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : + distillEBudget 14 + distillT0 14 α + distillT1 14 α + distillT2 14 α ≤ (493 / 600) := by + have h0 := CriticalRow14.component0 α hα hd + have h1 := CriticalRow14.component1 α hα hd + have h2 := CriticalRow14.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_14 : ((493 / 600) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow15 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 4) : + 0 ≤ distillCritical0 15 x := by + refine (BernsteinCert.coeffs_pos + [26079975, 294403005, 1352845395, 3241657665, 4291827957, 3017029239, 912832401, + 13390923] + (lo := 0) (hi := 4) (s := 4096) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (4 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 4) (15 / 2)) : + 0 ≤ -distillCritical0 15 x := by + refine (BernsteinCert.coeffs_pos + [3075661352184, 81246089189976, 538497355541328, 1681320236398848, 2907450237404160, + 2881036943671680, 1541466330819840, 347148353664000] + (lo := (17 / 4)) (hi := (15 / 2)) (s := 62748517) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (17 / 4)) ((15 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : + distillT0 15 α ≤ (31 / 125) := by + apply distillT0_le_of_critical (l := 4) (r := (17 / 4)) (d := (15 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 4)) : + 0 ≤ -distillCritical1 15 x := by + refine (BernsteinCert.coeffs_pos + [191102976, 2162130944, 10024951808, 24392509440, 32908441600, 23448196576, 6982601904, + 43361328] + (lo := 0) (hi := (15 / 4)) (s := 3125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((15 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 4 (15 / 2)) : + 0 ≤ distillCritical1 15 x := by + refine (BernsteinCert.coeffs_pos + [29636069376, 736116675072, 4943373389568, 15801867967104, 28021669675200, + 28437914681640, 15539857707960, 3560930262000] + (lo := 4) (hi := (15 / 2)) (s := 117649) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 4) ((15 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : + distillT1 15 α ≤ (39 / 250) := by + apply distillT1_le_of_critical (l := (15 / 4)) (r := 4) (d := (15 / 2)) + 12 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 4)) : + 0 ≤ -distillCritical2 15 x := by + refine (BernsteinCert.coeffs_pos + [18432, 103680, 183808, 102264, 804] + (lo := 0) (hi := (15 / 4)) (s := 25) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((15 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 4 (15 / 2)) : + 0 ≤ distillCritical2 15 x := by + refine (BernsteinCert.coeffs_pos + [114560, 2404512, 8513280, 10865340, 4681800] + (lo := 4) (hi := (15 / 2)) (s := 343) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 4) ((15 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : + distillT2 15 α ≤ (17 / 125) := by + apply distillT2_le_of_critical (l := (15 / 4)) (r := 4) (d := (15 / 2)) + 12 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow15 + +theorem distillFinite_15 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : + distillEBudget 15 + distillT0 15 α + distillT1 15 α + distillT2 15 α ≤ (373 / 450) := by + have h0 := CriticalRow15.component0 α hα hd + have h1 := CriticalRow15.component1 α hα hd + have h2 := CriticalRow15.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_15 : ((373 / 450) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow16 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 4)) : + 0 ≤ distillCritical0 16 x := by + refine (BernsteinCert.coeffs_pos + [1972182712320, 22926687731712, 108347544207360, 266704058474496, 362811134954496, + 263349024912128, 84343618952256, 2781135409648] + (lo := 0) (hi := (17 / 4)) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((17 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 2) 8) : + 0 ≤ -distillCritical0 16 x := by + refine (BernsteinCert.coeffs_pos + [13422546288, 665907316704, 4906210792896, 16098896403072, 28751483518464, + 29204927704064, 15959087198208, 3663911747584] + (lo := (9 / 2)) (hi := 8) (s := 823543) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (9 / 2)) (8 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : + distillT0 16 α ≤ (251 / 1000) := by + apply distillT0_le_of_critical (l := (17 / 4)) (r := (9 / 2)) (d := 8) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 4) : + 0 ≤ -distillCritical1 16 x := by + refine (BernsteinCert.coeffs_pos + [6130890, 71590149, 342415404, 859646871, 1199203626, 890581747, 285996160, 9254673] + (lo := 0) (hi := 4) (s := 128) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (4 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 4) 8) : + 0 ≤ distillCritical1 16 x := by + refine (BernsteinCert.coeffs_pos + [15134656784656, 713207139336832, 5389882680124416, 18206806631106560, + 33433144747765760, 34819713077477376, 19434630765740032, 4536633546244096] + (lo := (17 / 4)) (hi := 8) (s := 170859375) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (17 / 4)) (8 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : + distillT1 16 α ≤ (157 / 1000) := by + apply distillT1_le_of_critical (l := 4) (r := (17 / 4)) (d := 8) + 13 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 4) : + 0 ≤ -distillCritical2 16 x := by + refine (BernsteinCert.coeffs_pos + [10530, 61155, 111741, 64433, 1461] + (lo := 0) (hi := 4) (s := 16) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (4 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 4) 8) : + 0 ≤ distillCritical2 16 x := by + refine (BernsteinCert.coeffs_pos + [10204444, 301877416, 1123574784, 1468708096, 642678784] + (lo := (17 / 4)) (hi := 8) (s := 50625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (17 / 4)) (8 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : + distillT2 16 α ≤ (7 / 50) := by + apply distillT2_le_of_critical (l := 4) (r := (17 / 4)) (d := 8) + 13 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow16 + +theorem distillFinite_16 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : + distillEBudget 16 + distillT0 16 α + distillT1 16 α + distillT2 16 α ≤ (20027 / 24000) := by + have h0 := CriticalRow16.component0 α hα hd + have h1 := CriticalRow16.component1 α hα hd + have h2 := CriticalRow16.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_16 : ((20027 / 24000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow17 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (19 / 4)) : + 0 ≤ distillCritical0 17 x := by + refine (BernsteinCert.coeffs_pos + [2253820723200, 27574101098496, 136446721136640, 349375546750464, 490179912370176, + 362651147992720, 114843490435896, 390340442168] + (lo := 0) (hi := (19 / 4)) (s := 893871739) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((19 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 5 (17 / 2)) : + 0 ≤ -distillCritical0 17 x := by + refine (BernsteinCert.coeffs_pos + [50391315840, 1210326217408, 7831599144320, 24159770489792, 41457331418328, + 40848782192260, 21756336775348, 4880218869944] + (lo := 5) (hi := (17 / 2)) (s := 823543) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 5) ((17 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : + distillT0 17 α ≤ (32 / 125) := by + apply distillT0_le_of_critical (l := (19 / 4)) (r := 5) (d := (17 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 2)) : + 0 ≤ -distillCritical1 17 x := by + refine (BernsteinCert.coeffs_pos + [167203840, 2061905408, 10374514944, 27264937856, 39554095696, 30217779960, 9659524024, + 64588688] + (lo := 0) (hi := (9 / 2)) (s := 6561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((9 / 2) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 4) (17 / 2)) : + 0 ≤ distillCritical1 17 x := by + refine (BernsteinCert.coeffs_pos + [49818019422896, 1316111243212112, 8920425494468256, 28532184143080960, + 50483737628892160, 51058649636572416, 27790063192013312, 6340904691931136] + (lo := (19 / 4)) (hi := (17 / 2)) (s := 170859375) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (19 / 4)) ((17 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : + distillT1 17 α ≤ (157 / 1000) := by + apply distillT1_le_of_critical (l := (9 / 2)) (r := (19 / 4)) (d := (17 / 2)) + 14 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 4)) : + 0 ≤ -distillCritical2 17 x := by + refine (BernsteinCert.coeffs_pos + [2903040, 17383680, 32674848, 19440040, 675924] + (lo := 0) (hi := (17 / 4)) (s := 4913) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((17 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 2) (17 / 2)) : + 0 ≤ distillCritical2 17 x := by + refine (BernsteinCert.coeffs_pos + [51111, 2623968, 10265430, 13725352, 6092171] + (lo := (9 / 2)) (hi := (17 / 2)) (s := 512) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (9 / 2)) ((17 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : + distillT2 17 α ≤ (29 / 200) := by + apply distillT2_le_of_critical (l := (17 / 4)) (r := (9 / 2)) (d := (17 / 2)) + 14 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow17 + +theorem distillFinite_17 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : + distillEBudget 17 + distillT0 17 α + distillT1 17 α + distillT2 17 α ≤ (21479 / 25500) := by + have h0 := CriticalRow17.component0 α hα hd + have h1 := CriticalRow17.component1 α hα hd + have h2 := CriticalRow17.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_17 : ((21479 / 25500) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow18 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 5) : + 0 ≤ distillCritical0 18 x := by + refine (BernsteinCert.coeffs_pos + [31177872, 391875408, 1989487656, 5219727480, 7502139000, 5710155372, 1906260228, + 42056496] + (lo := 0) (hi := 5) (s := 15625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (5 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 4) 9) : + 0 ≤ -distillCritical0 18 x := by + refine (BernsteinCert.coeffs_pos + [1926607008, 73720166256, 524548632768, 1694855393280, 2998373345280, 3024924807168, + 1643920736256, 375595204608] + (lo := (21 / 4)) (hi := 9) (s := 78125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (21 / 4)) (9 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : + distillT0 18 α ≤ (259 / 1000) := by + apply distillT0_le_of_critical (l := 5) (r := (21 / 4)) (d := 9) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (19 / 4)) : + 0 ≤ -distillCritical1 18 x := by + refine (BernsteinCert.coeffs_pos + [18704203776000, 237355485954048, 1228172209569792, 3319004068098048, 4958468754534144, + 3926425884542784, 1339372424410272, 40779572863632] + (lo := 0) (hi := (19 / 4)) (s := 893871739) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((19 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 5 9) : + 0 ≤ distillCritical1 18 x := by + refine (BernsteinCert.coeffs_pos + [92712615, 5246215902, 40156857081, 135740625552, 248599719945, 257891522598, + 143292810807, 33287968332] + (lo := 5) (hi := 9) (s := 1024) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 5) (9 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : + distillT1 18 α ≤ (79 / 500) := by + apply distillT1_le_of_critical (l := (19 / 4)) (r := 5) (d := 9) + 15 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 2)) : + 0 ≤ -distillCritical2 18 x := by + refine (BernsteinCert.coeffs_pos + [4800, 29600, 57144, 34956, 1568] + (lo := 0) (hi := (9 / 2)) (s := 9) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((9 / 2) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 4) 9) : + 0 ≤ distillCritical2 18 x := by + refine (BernsteinCert.coeffs_pos + [1705388, 371129784, 1526114304, 2084600448, 937598976] + (lo := (19 / 4)) (hi := 9) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (19 / 4)) (9 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : + distillT2 18 α ≤ (3 / 20) := by + apply distillT2_le_of_critical (l := (9 / 2)) (r := (19 / 4)) (d := 9) + 15 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow18 + +theorem distillFinite_18 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : + distillEBudget 18 + distillT0 18 α + distillT1 18 α + distillT2 18 α ≤ (11467 / 13500) := by + have h0 := CriticalRow18.component0 α hα hd + have h1 := CriticalRow18.component1 α hα hd + have h2 := CriticalRow18.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_18 : ((11467 / 13500) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow19 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 4)) : + 0 ≤ distillCritical0 19 x := by + refine (BernsteinCert.coeffs_pos + [11823022080, 152534925312, 793746229248, 2131410839040, 3133102819840, 2446484008528, + 854290278968, 31580537144] + (lo := 0) (hi := (21 / 4)) (s := 7411887) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((21 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 2) (19 / 2)) : + 0 ≤ -distillCritical0 19 x := by + refine (BernsteinCert.coeffs_pos + [815511069, 158277314263, 1265345417225, 4295494687115, 7836312414375, 8090637953749, + 4483415908339, 1042574009225] + (lo := (11 / 2)) (hi := (19 / 2)) (s := 262144) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (11 / 2)) ((19 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : + distillT0 19 α ≤ (131 / 500) := by + apply distillT0_le_of_critical (l := (21 / 4)) (r := (11 / 2)) (d := (19 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 4)) : + 0 ≤ -distillCritical1 19 x := by + refine (BernsteinCert.coeffs_pos + [91296890880, 1218553348096, 6608431685632, 18634236508160, 28881217019648, + 23521701222432, 8058000683376, 78742960176] + (lo := 0) (hi := (21 / 4)) (s := 7411887) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((21 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 2) (19 / 2)) : + 0 ≤ distillCritical1 19 x := by + refine (BernsteinCert.coeffs_pos + [39694891881, 1174877186107, 8120323321637, 26120350376351, 46267736011851, + 46754263641793, 25399921798375, 5781468959525] + (lo := (11 / 2)) (hi := (19 / 2)) (s := 131072) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (11 / 2)) ((19 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : + distillT1 19 α ≤ (159 / 1000) := by + apply distillT1_le_of_critical (l := (21 / 4)) (r := (11 / 2)) (d := (19 / 2)) + 16 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 5) : + 0 ≤ -distillCritical2 19 x := by + refine (BernsteinCert.coeffs_pos + [49248, 318492, 634368, 383102, 3478] + (lo := 0) (hi := 5) (s := 125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (5 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 4) (19 / 2)) : + 0 ≤ distillCritical2 19 x := by + refine (BernsteinCert.coeffs_pos + [20787084, 540100584, 1978380336, 2567429600, 1118051200] + (lo := (21 / 4)) (hi := (19 / 2)) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (21 / 4)) ((19 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : + distillT2 19 α ≤ (77 / 500) := by + apply distillT2_le_of_critical (l := 5) (r := (21 / 4)) (d := (19 / 2)) + 16 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow19 + +theorem distillFinite_19 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : + distillEBudget 19 + distillT0 19 α + distillT1 19 α + distillT2 19 α ≤ (1951 / 2280) := by + have h0 := CriticalRow19.component0 α hα hd + have h1 := CriticalRow19.component1 α hα hd + have h2 := CriticalRow19.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_19 : ((1951 / 2280) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow20 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 4)) : + 0 ≤ distillCritical0 20 x := by + refine (BernsteinCert.coeffs_pos + [3210529996800, 43392000983040, 235474379735040, 655390796451840, 990711683438592, + 788061705056000, 275622004818080, 3955544430960] + (lo := 0) (hi := (23 / 4)) (s := 3404825447) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((23 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 6 10) : + 0 ≤ -distillCritical0 20 x := by + refine (BernsteinCert.coeffs_pos + [8003691, 269774631, 1879076907, 6011913663, 10570468665, 10616391005, 5748621105, + 1309160125] + (lo := 6) (hi := 10) (s := 256) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 6) (10 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : + distillT0 20 α ≤ (53 / 200) := by + apply distillT0_le_of_critical (l := (23 / 4)) (r := 6) (d := 10) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (11 / 2)) : + 0 ≤ -distillCritical1 20 x := by + refine (BernsteinCert.coeffs_pos + [18513100800, 253662658560, 1411196636160, 4080619848960, 6491826102912, 5455808074592, + 1977015589344, 61606601776] + (lo := 0) (hi := (11 / 2)) (s := 1771561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((11 / 2) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 4) 10) : + 0 ≤ distillCritical1 20 x := by + refine (BernsteinCert.coeffs_pos + [27976374343920, 2430543418874560, 19114144481148800, 65035103129729024, + 119222947355381760, 123523222279290880, 68472870743572480, 15859922763776000] + (lo := (23 / 4)) (hi := 10) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (23 / 4)) (10 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : + distillT1 20 α ≤ (159 / 1000) := by + apply distillT1_le_of_critical (l := (11 / 2)) (r := (23 / 4)) (d := 10) + 17 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 4)) : + 0 ≤ -distillCritical2 20 x := by + refine (BernsteinCert.coeffs_pos + [2611200, 17352960, 35435200, 21976488, 447500] + (lo := 0) (hi := (21 / 4)) (s := 7203) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((21 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 2) 10) : + 0 ≤ distillCritical2 20 x := by + refine (BernsteinCert.coeffs_pos + [975328, 37035532, 141627840, 187507360, 82700800] + (lo := (11 / 2)) (hi := 10) (s := 6561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (11 / 2)) (10 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : + distillT2 20 α ≤ (4 / 25) := by + apply distillT2_le_of_critical (l := (21 / 4)) (r := (11 / 2)) (d := 10) + 17 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow20 + +theorem distillFinite_20 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : + distillEBudget 20 + distillT0 20 α + distillT1 20 α + distillT2 20 α ≤ (5179 / 6000) := by + have h0 := CriticalRow20.component0 α hα hd + have h1 := CriticalRow20.component1 α hα hd + have h2 := CriticalRow20.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_20 : ((5179 / 6000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end diff --git a/Sendov/DistillationFinite/Rows21_28.lean b/Sendov/DistillationFinite/Rows21_28.lean new file mode 100644 index 0000000..038f3a2 --- /dev/null +++ b/Sendov/DistillationFinite/Rows21_28.lean @@ -0,0 +1,936 @@ +import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.BernsteinList + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow21 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 6) : + 0 ≤ distillCritical0 21 x := by + refine (BernsteinCert.coeffs_pos + [24885, 344577, 1913103, 5439279, 8390587, 6828303, 2490257, 73041] + (lo := 0) (hi := 6) (s := 32) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (6 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 4) (21 / 2)) : + 0 ≤ -distillCritical0 21 x := by + refine (BernsteinCert.coeffs_pos + [3083660642280, 283158061418568, 2194144323169680, 7355419192733184, 13318328773327104, + 13676740567926912, 7545890856409344, 1747843365768192] + (lo := (25 / 4)) (hi := (21 / 2)) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (25 / 4)) ((21 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : + distillT0 21 α ≤ (67 / 250) := by + apply distillT0_le_of_critical (l := 6) (r := (25 / 4)) (d := (21 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 6) : + 0 ≤ -distillCritical1 21 x := by + refine (BernsteinCert.coeffs_pos + [105945, 1521433, 8842533, 26602997, 43805279, 37832655, 13846627, 197859] + (lo := 0) (hi := 6) (s := 16) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (6 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 4) (21 / 2)) : + 0 ≤ distillCritical1 21 x := by + refine (BernsteinCert.coeffs_pos + [113758150270320, 4082926086718224, 29077158265650144, 94484104230311424, + 168014508486308352, 169982024485001472, 92325810395635200, 20993604324489216] + (lo := (25 / 4)) (hi := (21 / 2)) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (25 / 4)) ((21 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : + distillT1 21 α ≤ (4 / 25) := by + apply distillT1_le_of_critical (l := 6) (r := (25 / 4)) (d := (21 / 2)) + 18 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (11 / 2)) : + 0 ≤ -distillCritical2 21 x := by + refine (BernsteinCert.coeffs_pos + [4898880, 33423840, 69893784, 44401356, 1334176] + (lo := 0) (hi := (11 / 2)) (s := 14641) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((11 / 2) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 4) (21 / 2)) : + 0 ≤ distillCritical2 21 x := by + refine (BernsteinCert.coeffs_pos + [8924540, 646825560, 2582180784, 3484393632, 1555231104] + (lo := (23 / 4)) (hi := (21 / 2)) (s := 130321) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (23 / 4)) ((21 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : + distillT2 21 α ≤ (33 / 200) := by + apply distillT2_le_of_critical (l := (11 / 2)) (r := (23 / 4)) (d := (21 / 2)) + 18 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow21 + +theorem distillFinite_21 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : + distillEBudget 21 + distillT0 21 α + distillT1 21 α + distillT2 21 α ≤ (7837 / 9000) := by + have h0 := CriticalRow21.component0 α hα hd + have h1 := CriticalRow21.component1 α hα hd + have h2 := CriticalRow21.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_21 : ((7837 / 9000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow22 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 2)) : + 0 ≤ distillCritical0 22 x := by + refine (BernsteinCert.coeffs_pos + [30792960000, 445377927168, 2572183662336, 7563508192512, 11975591323968, 9920238748240, + 3646030987656, 33436259048] + (lo := 0) (hi := (13 / 2)) (s := 62748517) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((13 / 2) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 4) 11) : + 0 ≤ -distillCritical0 22 x := by + refine (BernsteinCert.coeffs_pos + [14767914854880, 467537063626224, 3217749780157632, 10235741853238272, + 17931176975505408, 17960411366723584, 9703583421087744, 2205301382316032] + (lo := (27 / 4)) (hi := 11) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (27 / 4)) (11 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : + distillT0 22 α ≤ (271 / 1000) := by + apply distillT0_le_of_critical (l := (13 / 2)) (r := (27 / 4)) (d := 11) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 4)) : + 0 ≤ -distillCritical1 22 x := by + refine (BernsteinCert.coeffs_pos + [7023225470976, 103328513851392, 614788765433856, 1892504223682560, 3190211005935360, + 2832819482168896, 1088817206404192, 36504389791536] + (lo := 0) (hi := (25 / 4)) (s := 1220703125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((25 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 2) 11) : + 0 ≤ distillCritical1 22 x := by + refine (BernsteinCert.coeffs_pos + [69911613200, 31099175440592, 255054315681168, 878129789212672, 1616258257694080, + 1676061209948928, 928512234606848, 214744360742912] + (lo := (13 / 2)) (hi := 11) (s := 4782969) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (13 / 2)) (11 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : + distillT1 22 α ≤ (4 / 25) := by + apply distillT1_le_of_critical (l := (25 / 4)) (r := (13 / 2)) (d := 11) + 19 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 4)) : + 0 ≤ -distillCritical2 22 x := by + refine (BernsteinCert.coeffs_pos + [86676480, 606631680, 1297754016, 842672584, 32412212] + (lo := 0) (hi := (23 / 4)) (s := 279841) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((23 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 6 11) : + 0 ≤ distillCritical2 22 x := by + refine (BernsteinCert.coeffs_pos + [2268, 2744892, 11439318, 15719282, 7095088] + (lo := 6) (hi := 11) (s := 625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 6) (11 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : + distillT2 22 α ≤ (17 / 100) := by + apply distillT2_le_of_critical (l := (23 / 4)) (r := 6) (d := 11) + 19 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow22 + +theorem distillFinite_22 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : + distillEBudget 22 + distillT0 22 α + distillT1 22 α + distillT2 22 α ≤ (14479 / 16500) := by + have h0 := CriticalRow22.component0 α hα hd + have h1 := CriticalRow22.component1 α hα hd + have h2 := CriticalRow22.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_22 : ((14479 / 16500) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow23 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 4)) : + 0 ≤ distillCritical0 23 x := by + refine (BernsteinCert.coeffs_pos + [1982136320, 29323280384, 172988123136, 518772464128, 836616640000, 707264918448, + 270200563544, 6453121496] + (lo := 0) (hi := (27 / 4)) (s := 4782969) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((27 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 7 (23 / 2)) : + 0 ≤ -distillCritical0 23 x := by + refine (BernsteinCert.coeffs_pos + [51396902528, 3634851593024, 27652415110656, 91979940230464, 165754342766344, + 169621380354876, 93314280169484, 21556236449192] + (lo := 7) (hi := (23 / 2)) (s := 4782969) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 7) ((23 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : + distillT0 23 α ≤ (273 / 1000) := by + apply distillT0_le_of_critical (l := (27 / 4)) (r := 7) (d := (23 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 4)) : + 0 ≤ -distillCritical1 23 x := by + refine (BernsteinCert.coeffs_pos + [55318937600, 850379964416, 5270920028160, 16838754555904, 29316774613504, + 26723143323168, 10412319412112, 203634219920] + (lo := 0) (hi := (27 / 4)) (s := 14348907) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((27 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 7 (23 / 2)) : + 0 ≤ distillCritical1 23 x := by + refine (BernsteinCert.coeffs_pos + [995128529152, 50666535851392, 376094514533376, 1239774891757376, 2218546071663440, + 2250988264845624, 1223993114037784, 278345609952016] + (lo := 7) (hi := (23 / 2)) (s := 4782969) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 7) ((23 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : + distillT1 23 α ≤ (161 / 1000) := by + apply distillT1_le_of_critical (l := (27 / 4)) (r := 7) (d := (23 / 2)) + 20 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 4)) : + 0 ≤ -distillCritical2 23 x := by + refine (BernsteinCert.coeffs_pos + [3815424, 27876096, 61417344, 39553096, 383924] + (lo := 0) (hi := (25 / 4)) (s := 15625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((25 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 2) (23 / 2)) : + 0 ≤ distillCritical2 23 x := by + refine (BernsteinCert.coeffs_pos + [239472, 7601533, 28569717, 37538223, 16475567] + (lo := (13 / 2)) (hi := (23 / 2)) (s := 1250) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (13 / 2)) ((23 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : + distillT2 23 α ≤ (7 / 40) := by + apply distillT2_le_of_critical (l := (25 / 4)) (r := (13 / 2)) (d := (23 / 2)) + 20 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow23 + +theorem distillFinite_23 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : + distillEBudget 23 + distillT0 23 α + distillT1 23 α + distillT2 23 α ≤ (61021 / 69000) := by + have h0 := CriticalRow23.component0 α hα hd + have h1 := CriticalRow23.component1 α hα hd + have h2 := CriticalRow23.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_23 : ((61021 / 69000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow24 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 4)) : + 0 ≤ distillCritical0 24 x := by + refine (BernsteinCert.coeffs_pos + [4746997923840, 73164538773504, 447965465444352, 1386669848739840, 2291328567198720, + 1969726633871616, 762089030190336, 4533555905904] + (lo := 0) (hi := (29 / 4)) (s := 17249876309) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((29 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 2) 12) : + 0 ≤ -distillCritical0 24 x := by + refine (BernsteinCert.coeffs_pos + [84982480, 2628270592, 17997003840, 57099267200, 99853936640, 99883987968, 53902778368, + 12236308480] + (lo := (15 / 2)) (hi := 12) (s := 2187) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (15 / 2)) (12 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : + distillT0 24 α ≤ (11 / 40) := by + apply distillT0_le_of_critical (l := (29 / 4)) (r := (15 / 2)) (d := 12) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 4)) : + 0 ≤ -distillCritical1 24 x := by + refine (BernsteinCert.coeffs_pos + [46025240739840, 737939268698112, 4757440347832320, 15751231124705280, + 28292882244470784, 26463699854085888, 10476559012793856, 67764558438576] + (lo := 0) (hi := (29 / 4)) (s := 17249876309) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((29 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 2) 12) : + 0 ≤ distillCritical1 24 x := by + refine (BernsteinCert.coeffs_pos + [127355280, 3996095744, 27497476416, 87364258560, 152491243264, 151703445504, + 81098987520, 18159042560] + (lo := (15 / 2)) (hi := 12) (s := 243) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (15 / 2)) (12 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : + distillT1 24 α ≤ (161 / 1000) := by + apply distillT1_le_of_critical (l := (29 / 4)) (r := (15 / 2)) (d := 12) + 21 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 2)) : + 0 ≤ -distillCritical2 24 x := by + refine (BernsteinCert.coeffs_pos + [6531840, 48872160, 110005056, 72339708, 1361896] + (lo := 0) (hi := (13 / 2)) (s := 28561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((13 / 2) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 4) 12) : + 0 ≤ distillCritical2 24 x := by + refine (BernsteinCert.coeffs_pos + [268524, 12988152, 50695424, 67761920, 30064640] + (lo := (27 / 4)) (hi := 12) (s := 2401) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (27 / 4)) (12 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : + distillT2 24 α ≤ (9 / 50) := by + apply distillT2_le_of_critical (l := (13 / 2)) (r := (27 / 4)) (d := 12) + 21 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow24 + +theorem distillFinite_24 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : + distillEBudget 24 + distillT0 24 α + distillT1 24 α + distillT2 24 α ≤ (32051 / 36000) := by + have h0 := CriticalRow24.component0 α hα hd + have h1 := CriticalRow24.component1 α hα hd + have h2 := CriticalRow24.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_24 : ((32051 / 36000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow25 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 2)) : + 0 ≤ distillCritical0 25 x := by + refine (BernsteinCert.coeffs_pos + [6658560, 104818944, 654663744, 2063864160, 3467847680, 3035622620, 1217166364, + 24580624] + (lo := 0) (hi := (15 / 2)) (s := 28125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((15 / 2) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 4) (25 / 2)) : + 0 ≤ -distillCritical0 25 x := by + refine (BernsteinCert.coeffs_pos + [11384777913672, 727247908624744, 5482364668675376, 18160873161033728, + 32640788624409600, 33335006304645760, 18306494249163520, 4221637754240000] + (lo := (31 / 4)) (hi := (25 / 2)) (s := 893871739) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (31 / 4)) ((25 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : + distillT0 25 α ≤ (277 / 1000) := by + apply distillT0_le_of_critical (l := (15 / 2)) (r := (31 / 4)) (d := (25 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 2)) : + 0 ≤ -distillCritical1 25 x := by + refine (BernsteinCert.coeffs_pos + [67169280, 1100406272, 7243465472, 24471594880, 44862645040, 42979698360, 17765271432, + 447251712] + (lo := 0) (hi := (15 / 2)) (s := 28125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((15 / 2) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 4) (25 / 2)) : + 0 ≤ distillCritical1 25 x := by + refine (BernsteinCert.coeffs_pos + [80779279690416, 9690244766280272, 76014640230507808, 255281173869243904, + 460715608679823360, 469477527539559680, 255847429110325760, 58239373592320000] + (lo := (31 / 4)) (hi := (25 / 2)) (s := 893871739) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (31 / 4)) ((25 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : + distillT1 25 α ≤ (161 / 1000) := by + apply distillT1_le_of_critical (l := (15 / 2)) (r := (31 / 4)) (d := (25 / 2)) + 22 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 4)) : + 0 ≤ -distillCritical2 25 x := by + refine (BernsteinCert.coeffs_pos + [1408000, 10781440, 24773280, 16607608, 446692] + (lo := 0) (hi := (27 / 4)) (s := 6561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((27 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 7 (25 / 2)) : + 0 ≤ distillCritical2 25 x := by + refine (BernsteinCert.coeffs_pos + [675264, 70830128, 287108160, 390125940, 174871000] + (lo := 7) (hi := (25 / 2)) (s := 14641) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 7) ((25 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : + distillT2 25 α ≤ (93 / 500) := by + apply distillT2_le_of_critical (l := (27 / 4)) (r := 7) (d := (25 / 2)) + 22 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow25 + +theorem distillFinite_25 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : + distillEBudget 25 + distillT0 25 α + distillT1 25 α + distillT2 25 α ≤ (673 / 750) := by + have h0 := CriticalRow25.component0 α hα hd + have h1 := CriticalRow25.component1 α hα hd + have h2 := CriticalRow25.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_25 : ((673 / 750) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow26 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 8) : + 0 ≤ distillCritical0 26 x := by + refine (BernsteinCert.coeffs_pos + [21465405, 351232443, 2272145985, 7380885159, 12686998359, 11280128177, 4598433899, + 19441197] + (lo := 0) (hi := 8) (s := 131072) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (8 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 4) 13) : + 0 ≤ -distillCritical0 26 x := by + refine (BernsteinCert.coeffs_pos + [35732324880864, 1111011969593232, 7610471820871488, 24143164934547456, + 42212599768676352, 42215407934861312, 22774884449009664, 5167836332818432] + (lo := (33 / 4)) (hi := 13) (s := 893871739) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (33 / 4)) (13 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : + distillT0 26 α ≤ (279 / 1000) := by + apply distillT0_le_of_critical (l := 8) (r := (33 / 4)) (d := 13) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 8) : + 0 ≤ -distillCritical1 26 x := by + refine (BernsteinCert.coeffs_pos + [224936595, 3833861949, 26188308639, 91501746849, 172741990137, 169597494487, + 71352632725, 1013459211] + (lo := 0) (hi := 8) (s := 131072) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (8 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 4) 13) : + 0 ≤ distillCritical1 26 x := by + refine (BernsteinCert.coeffs_pos + [324416503328400, 14750115770725920, 106891472433082176, 346391522019348480, + 610649595233212416, 610945977391734784, 327730049946697728, 73539025671028736] + (lo := (33 / 4)) (hi := 13) (s := 893871739) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (33 / 4)) (13 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : + distillT1 26 α ≤ (81 / 500) := by + apply distillT1_le_of_critical (l := 8) (r := (33 / 4)) (d := 13) + 23 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 4)) : + 0 ≤ -distillCritical2 26 x := by + refine (BernsteinCert.coeffs_pos + [124001280, 988104960, 2335033056, 1555350296, 2376324] + (lo := 0) (hi := (29 / 4)) (s := 707281) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((29 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 2) 13) : + 0 ≤ distillCritical2 26 x := by + refine (BernsteinCert.coeffs_pos + [3357720, 94466340, 350231856, 457397744, 199972864] + (lo := (15 / 2)) (hi := 13) (s := 14641) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (15 / 2)) (13 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : + distillT2 26 α ≤ (191 / 1000) := by + apply distillT2_le_of_critical (l := (29 / 4)) (r := (15 / 2)) (d := 13) + 23 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow26 + +theorem distillFinite_26 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : + distillEBudget 26 + distillT0 26 α + distillT1 26 α + distillT2 26 α ≤ (35273 / 39000) := by + have h0 := CriticalRow26.component0 α hα hd + have h1 := CriticalRow26.component1 α hα hd + have h2 := CriticalRow26.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_26 : ((35273 / 39000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow27 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (33 / 4)) : + 0 ≤ distillCritical0 27 x := by + refine (BernsteinCert.coeffs_pos + [2786918400, 46516617216, 306593777664, 1013088923136, 1768271491584, 1597776150672, + 673159819896, 12051890424] + (lo := 0) (hi := (33 / 4)) (s := 19487171) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((33 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 2) (27 / 2)) : + 0 ≤ -distillCritical0 27 x := by + refine (BernsteinCert.coeffs_pos + [16869196368, 1064646906651, 8010422479728, 26503241824755, 47589705911880, + 48561168058353, 26645623846776, 6138784644993] + (lo := (17 / 2)) (hi := (27 / 2)) (s := 1250000) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (17 / 2)) ((27 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : + distillT0 27 α ≤ (7 / 25) := by + apply distillT0_le_of_critical (l := (33 / 4)) (r := (17 / 2)) (d := (27 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 2)) : + 0 ≤ -distillCritical1 27 x := by + refine (BernsteinCert.coeffs_pos + [517590466560, 9164734004736, 64877844748032, 234166178994048, 454805616687840, + 457372160416728, 196146018321624, 793019555328] + (lo := 0) (hi := (17 / 2)) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((17 / 2) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (35 / 4) (27 / 2)) : + 0 ≤ distillCritical1 27 x := by + refine (BernsteinCert.coeffs_pos + [697464484134000, 21680354555329392, 147540088389767904, 463553223820494336, + 800156563044226560, 787234858010355456, 416198987466259968, 92157018004187136] + (lo := (35 / 4)) (hi := (27 / 2)) (s := 893871739) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (35 / 4)) ((27 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : + distillT1 27 α ≤ (81 / 500) := by + apply distillT1_le_of_critical (l := (17 / 2)) (r := (35 / 4)) (d := (27 / 2)) + 24 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 2)) : + 0 ≤ -distillCritical2 27 x := by + refine (BernsteinCert.coeffs_pos + [20736, 168864, 406896, 276044, 2776] + (lo := 0) (hi := (15 / 2)) (s := 125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((15 / 2) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 4) (27 / 2)) : + 0 ≤ distillCritical2 27 x := by + refine (BernsteinCert.coeffs_pos + [42192956, 1621851288, 6219278064, 8249965344, 3642807168] + (lo := (31 / 4)) (hi := (27 / 2)) (s := 279841) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (31 / 4)) ((27 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : + distillT2 27 α ≤ (49 / 250) := by + apply distillT2_le_of_critical (l := (15 / 2)) (r := (31 / 4)) (d := (27 / 2)) + 24 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow27 + +theorem distillFinite_27 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : + distillEBudget 27 + distillT0 27 α + distillT1 27 α + distillT2 27 α ≤ (36839 / 40500) := by + have h0 := CriticalRow27.component0 α hα hd + have h1 := CriticalRow27.component1 α hα hd + have h2 := CriticalRow27.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_27 : ((36839 / 40500) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow28 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (35 / 4)) : + 0 ≤ distillCritical0 28 x := by + refine (BernsteinCert.coeffs_pos + [188045328384, 3255662149632, 22185558540288, 75419892633600, 134471191326720, + 123265812193024, 52966489937952, 193320907088] + (lo := 0) (hi := (35 / 4)) (s := 1838265625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((35 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 9 14) : + 0 ≤ -distillCritical0 28 x := by + refine (BernsteinCert.coeffs_pos + [3085052184, 98833401288, 680357243664, 2162577493440, 3785116471440, 3787832416864, + 2044289592288, 463931297984] + (lo := 9) (hi := 14) (s := 78125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 9) (14 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : + distillT0 28 α ≤ (141 / 500) := by + apply distillT0_le_of_critical (l := (35 / 4)) (r := 9) (d := 14) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (35 / 4)) : + 0 ≤ -distillCritical1 28 x := by + refine (BernsteinCert.coeffs_pos + [2117420974080, 38227241336832, 275727892119552, 1013321618657280, 2003778711229440, + 2057395616543360, 916168403232192, 19758575767792] + (lo := 0) (hi := (35 / 4)) (s := 1838265625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((35 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 9 14) : + 0 ≤ distillCritical1 28 x := by + refine (BernsteinCert.coeffs_pos + [10785881592, 1250744333184, 9687079540872, 32143744732320, 57333275573520, + 57748023276032, 31107450384384, 6999015288832] + (lo := 9) (hi := 14) (s := 78125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 9) (14 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : + distillT1 28 α ≤ (81 / 500) := by + apply distillT1_le_of_critical (l := (35 / 4)) (r := 9) (d := 14) + 25 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (31 / 4)) : + 0 ≤ -distillCritical2 28 x := by + refine (BernsteinCert.coeffs_pos + [145152000, 1207353600, 2964629184, 2045792744, 36236724] + (lo := 0) (hi := (31 / 4)) (s := 923521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((31 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 8 14) : + 0 ≤ distillCritical2 28 x := by + refine (BernsteinCert.coeffs_pos + [13769, 847223, 3360153, 4524719, 2016812] + (lo := 8) (hi := 14) (s := 162) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 8) (14 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : + distillT2 28 α ≤ (101 / 500) := by + apply distillT2_le_of_critical (l := (31 / 4)) (r := 8) (d := 14) + 25 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow28 + +theorem distillFinite_28 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : + distillEBudget 28 + distillT0 28 α + distillT1 28 α + distillT2 28 α ≤ (5501 / 6000) := by + have h0 := CriticalRow28.component0 α hα hd + have h1 := CriticalRow28.component1 α hα hd + have h2 := CriticalRow28.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_28 : ((5501 / 6000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end diff --git a/Sendov/DistillationFinite/Rows29_36.lean b/Sendov/DistillationFinite/Rows29_36.lean new file mode 100644 index 0000000..aa2824a --- /dev/null +++ b/Sendov/DistillationFinite/Rows29_36.lean @@ -0,0 +1,937 @@ +import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.BernsteinList + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow29 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 9) : + 0 ≤ distillCritical0 29 x := by + refine (BernsteinCert.coeffs_pos + [197780, 3488992, 24198318, 83590720, 151154120, 140565393, 62268338, 1040539] + (lo := 0) (hi := 9) (s := 2187) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (9 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (37 / 4) (29 / 2)) : + 0 ≤ -distillCritical0 29 x := by + refine (BernsteinCert.coeffs_pos + [3365009093848, 225248328637816, 1701585339576240, 5636574293296640, 10125674930489600, + 10333620443687808, 5669434720615168, 1305691412116480] + (lo := (37 / 4)) (hi := (29 / 2)) (s := 257298363) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (37 / 4)) ((29 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : + distillT0 29 α ≤ (283 / 1000) := by + apply distillT0_le_of_critical (l := 9) (r := (37 / 4)) (d := (29 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (37 / 4)) : + 0 ≤ -distillCritical1 29 x := by + refine (BernsteinCert.coeffs_pos + [82561740963840, 1545252498210816, 11528781702340608, 43691654914836480, + 88744704573081984, 93213389812990880, 42340381608252144, 546067555464592] + (lo := 0) (hi := (37 / 4)) (s := 94931877133) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((37 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 2) (29 / 2)) : + 0 ≤ distillCritical1 29 x := by + refine (BernsteinCert.coeffs_pos + [59461268712, 2904147866329, 21016658198312, 67640225648945, 118241015368320, + 117227207292427, 62291372501104, 13841798528747] + (lo := (19 / 2)) (hi := (29 / 2)) (s := 125000) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (19 / 2)) ((29 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : + distillT1 29 α ≤ (81 / 500) := by + apply distillT1_le_of_critical (l := (37 / 4)) (r := (19 / 2)) (d := (29 / 2)) + 26 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 8) : + 0 ≤ -distillCritical2 29 x := by + refine (BernsteinCert.coeffs_pos + [152685, 1296540, 3242406, 2273324, 55989] + (lo := 0) (hi := 8) (s := 1024) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (8 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 4) (29 / 2)) : + 0 ≤ distillCritical2 29 x := by + refine (BernsteinCert.coeffs_pos + [2306556, 370203624, 1518559536, 2074659424, 933059456] + (lo := (33 / 4)) (hi := (29 / 2)) (s := 78125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (33 / 4)) ((29 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : + distillT2 29 α ≤ (207 / 1000) := by + apply distillT2_le_of_critical (l := 8) (r := (33 / 4)) (d := (29 / 2)) + 26 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow29 + +theorem distillFinite_29 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : + distillEBudget 29 + distillT0 29 α + distillT1 29 α + distillT2 29 α ≤ (10028 / 10875) := by + have h0 := CriticalRow29.component0 α hα hd + have h1 := CriticalRow29.component1 α hα hd + have h2 := CriticalRow29.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_29 : ((10028 / 10875) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow30 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (19 / 2)) : + 0 ≤ distillCritical0 30 x := by + refine (BernsteinCert.coeffs_pos + [59458406400, 1085950126080, 7774295811840, 27590328241920, 50896812815424, + 47958547091760, 21722649776040, 85582967880] + (lo := 0) (hi := (19 / 2)) (s := 893871739) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((19 / 2) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (39 / 4) 15) : + 0 ≤ -distillCritical0 30 x := by + refine (BernsteinCert.coeffs_pos + [30938144928, 1046274794768, 7267036504896, 23185203672064, 40666332743680, + 40751676026880, 22014264688640, 4998856704000] + (lo := (39 / 4)) (hi := 15) (s := 823543) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (39 / 4)) (15 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : + distillT0 30 α ≤ (71 / 250) := by + apply distillT0_le_of_critical (l := (19 / 2)) (r := (39 / 4)) (d := 15) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (39 / 4)) : + 0 ≤ -distillCritical1 30 x := by + refine (BernsteinCert.coeffs_pos + [41897164800, 811945492480, 6259018383360, 24436949258240, 50941706289408, + 54707108281152, 25370825388576, 124412060016] + (lo := 0) (hi := (39 / 4)) (s := 62748517) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((39 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 10 15) : + 0 ≤ distillCritical1 30 x := by + refine (BernsteinCert.coeffs_pos + [3037223088, 102525926208, 701995390560, 2199334347360, 3774932441820, 3688383688128, + 1935210028068, 425057271840] + (lo := 10) (hi := 15) (s := 3125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 10) (15 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : + distillT1 30 α ≤ (81 / 500) := by + apply distillT1_le_of_critical (l := (39 / 4)) (r := 10) (d := 15) + 27 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 2)) : + 0 ≤ -distillCritical2 30 x := by + refine (BernsteinCert.coeffs_pos + [10497600, 92443680, 237338280, 165581964, 501328] + (lo := 0) (hi := (17 / 2)) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((17 / 2) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (35 / 4) 15) : + 0 ≤ distillCritical2 30 x := by + refine (BernsteinCert.coeffs_pos + [2902028, 95820792, 362222208, 477505152, 210014208] + (lo := (35 / 4)) (hi := 15) (s := 15625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (35 / 4)) (15 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : + distillT2 30 α ≤ (53 / 250) := by + apply distillT2_le_of_critical (l := (17 / 2)) (r := (35 / 4)) (d := 15) + 27 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow30 + +theorem distillFinite_30 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : + distillEBudget 30 + distillT0 30 α + distillT1 30 α + distillT2 30 α ≤ (8347 / 9000) := by + have h0 := CriticalRow30.component0 α hα hd + have h1 := CriticalRow30.component1 α hα hd + have h2 := CriticalRow30.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_30 : ((8347 / 9000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow31 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (39 / 4)) : + 0 ≤ distillCritical0 31 x := by + refine (BernsteinCert.coeffs_pos + [33552138240, 623766847488, 4540664236032, 16359631151616, 30574635908608, + 29180498720752, 13596057413528, 222672713624] + (lo := 0) (hi := (39 / 4)) (s := 564736653) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((39 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 10 (31 / 2)) : + 0 ≤ -distillCritical0 31 x := by + refine (BernsteinCert.coeffs_pos + [225435578880, 17266180879616, 131637595733440, 437468013861088, 787146933908688, + 804045361730924, 441344960087348, 101656747262824] + (lo := 10) (hi := (31 / 2)) (s := 19487171) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 10) ((31 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : + distillT0 31 α ≤ (57 / 200) := by + apply distillT0_le_of_critical (l := (39 / 4)) (r := 10) (d := (31 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 10) : + 0 ≤ -distillCritical1 31 x := by + refine (BernsteinCert.coeffs_pos + [77311179, 1524959784, 11957184495, 47451971880, 100514528985, 109921626124, + 52678060789, 1108527660] + (lo := 0) (hi := 10) (s := 125000) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (10 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (41 / 4) (31 / 2)) : + 0 ≤ distillCritical1 31 x := by + refine (BernsteinCert.coeffs_pos + [175051664695024, 38828586873419056, 303923780105488032, 1005941384272358912, + 1783658361378919424, 1783473051877208832, 953008433951074816, 212597817534662656] + (lo := (41 / 4)) (hi := (31 / 2)) (s := 1801088541) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (41 / 4)) ((31 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : + distillT1 31 α ≤ (161 / 1000) := by + apply distillT1_le_of_critical (l := 10) (r := (41 / 4)) (d := (31 / 2)) + 28 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (35 / 4)) : + 0 ≤ -distillCritical2 31 x := by + refine (BernsteinCert.coeffs_pos + [5142528, 46179072, 120638208, 85451912, 876748] + (lo := 0) (hi := (35 / 4)) (s := 42875) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((35 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 9 (31 / 2)) : + 0 ≤ distillCritical2 31 x := by + refine (BernsteinCert.coeffs_pos + [3439584, 159263280, 620637528, 829540940, 368040184] + (lo := 9) (hi := (31 / 2)) (s := 28561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 9) ((31 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : + distillT2 31 α ≤ (109 / 500) := by + apply distillT2_le_of_critical (l := (35 / 4)) (r := 9) (d := (31 / 2)) + 28 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow31 + +theorem distillFinite_31 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : + distillEBudget 31 + distillT0 31 α + distillT1 31 α + distillT2 31 α ≤ (10844 / 11625) := by + have h0 := CriticalRow31.component0 α hα hd + have h1 := CriticalRow31.component1 α hα hd + have h2 := CriticalRow31.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_31 : ((10844 / 11625) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow32 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (41 / 4)) : + 0 ≤ distillCritical0 32 x := by + refine (BernsteinCert.coeffs_pos + [8714295705600, 167446784507904, 1256310382952448, 4644359403872256, 8844419150920704, + 8542597473847040, 4078182123919808, 19928443544304] + (lo := 0) (hi := (41 / 4)) (s := 194754273881) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((41 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 2) 16) : + 0 ≤ -distillCritical0 32 x := by + refine (BernsteinCert.coeffs_pos + [60907600080, 2234356822368, 15716019034944, 50406603295104, 88678358294016, + 89041249092608, 48167533867008, 10948007624704] + (lo := (21 / 2)) (hi := 16) (s := 1771561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (21 / 2)) (16 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : + distillT0 32 α ≤ (143 / 500) := by + apply distillT0_le_of_critical (l := (41 / 4)) (r := (21 / 2)) (d := 16) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 2)) : + 0 ≤ -distillCritical1 32 x := by + refine (BernsteinCert.coeffs_pos + [3591045120, 73215256576, 592203874304, 2417611393792, 5248741992704, 5861748113536, + 2868300956864, 40425357264] + (lo := 0) (hi := (21 / 2)) (s := 7411887) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((21 / 2) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (43 / 4) 16) : + 0 ≤ distillCritical1 32 x := by + refine (BernsteinCert.coeffs_pos + [849882632166704, 54409221776846720, 400426286009455104, 1290051097497143296, + 2247293886519808000, 2216049022292066304, 1170022511241199616, 258160945409294336] + (lo := (43 / 4)) (hi := 16) (s := 1801088541) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (43 / 4)) (16 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : + distillT1 32 α ≤ (161 / 1000) := by + apply distillT1_le_of_critical (l := (21 / 2)) (r := (43 / 4)) (d := 16) + 29 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 9) : + 0 ≤ -distillCritical2 32 x := by + refine (BernsteinCert.coeffs_pos + [9280, 84940, 225684, 162154, 2734] + (lo := 0) (hi := 9) (s := 81) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (9 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (37 / 4) 16) : + 0 ≤ distillCritical2 32 x := by + refine (BernsteinCert.coeffs_pos + [34367932, 2704293256, 10863601152, 14715316480, 6583287808] + (lo := (37 / 4)) (hi := 16) (s := 531441) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (37 / 4)) (16 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : + distillT2 32 α ≤ (223 / 1000) := by + apply distillT2_le_of_critical (l := 9) (r := (37 / 4)) (d := 16) + 29 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow32 + +theorem distillFinite_32 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : + distillEBudget 32 + distillT0 32 α + distillT1 32 α + distillT2 32 α ≤ (9007 / 9600) := by + have h0 := CriticalRow32.component0 α hα hd + have h1 := CriticalRow32.component1 α hα hd + have h2 := CriticalRow32.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_32 : ((9007 / 9600) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow33 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 2)) : + 0 ≤ distillCritical0 33 x := by + refine (BernsteinCert.coeffs_pos + [33200640, 648791808, 4945453632, 18545582496, 35746242560, 34920812276, 17115504588, + 286099272] + (lo := 0) (hi := (21 / 2)) (s := 823543) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((21 / 2) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (43 / 4) (33 / 2)) : + 0 ≤ -distillCritical0 33 x := by + refine (BernsteinCert.coeffs_pos + [30858499404744, 3012677290638312, 23291304021084528, 77793108841608192, + 140340539631739392, 143579388903355008, 78888657534803712, 18180403202497536] + (lo := (43 / 4)) (hi := (33 / 2)) (s := 3404825447) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (43 / 4)) ((33 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : + distillT0 33 α ≤ (143 / 500) := by + apply distillT0_le_of_critical (l := (21 / 2)) (r := (43 / 4)) (d := (33 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 11) : + 0 ≤ -distillCritical1 33 x := by + refine (BernsteinCert.coeffs_pos + [681031800, 14337073872, 119514421728, 501493086432, 1115107545366, 1271095479756, + 635419722018, 4884667668] + (lo := 0) (hi := 11) (s := 1771561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (11 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (45 / 4) (33 / 2)) : + 0 ≤ distillCritical1 33 x := by + refine (BernsteinCert.coeffs_pos + [118768488240, 4869217031312, 34046637330016, 107078840929792, 183532073576960, + 178659588595968, 93274775496192, 20369848891392] + (lo := (45 / 4)) (hi := (33 / 2)) (s := 117649) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (45 / 4)) ((33 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : + distillT1 33 α ≤ (161 / 1000) := by + apply distillT1_le_of_critical (l := 11) (r := (45 / 4)) (d := (33 / 2)) + 30 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (37 / 4)) : + 0 ≤ -distillCritical2 33 x := by + refine (BernsteinCert.coeffs_pos + [205286400, 1914451200, 5171252256, 3765766920, 86276788] + (lo := 0) (hi := (37 / 4)) (s := 1874161) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((37 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 2) (33 / 2)) : + 0 ≤ distillCritical2 33 x := by + refine (BernsteinCert.coeffs_pos + [11518, 3195873, 13234545, 18159795, 8189181] + (lo := (19 / 2)) (hi := (33 / 2)) (s := 686) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (19 / 2)) ((33 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : + distillT2 33 α ≤ (57 / 250) := by + apply distillT2_le_of_critical (l := (37 / 4)) (r := (19 / 2)) (d := (33 / 2)) + 30 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow33 + +theorem distillFinite_33 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : + distillEBudget 33 + distillT0 33 α + distillT1 33 α + distillT2 33 α ≤ (3733 / 3960) := by + have h0 := CriticalRow33.component0 α hα hd + have h1 := CriticalRow33.component1 α hα hd + have h2 := CriticalRow33.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_33 : ((3733 / 3960) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow34 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 11) : + 0 ≤ distillCritical0 34 x := by + refine (BernsteinCert.coeffs_pos + [603786960, 12176310096, 95533266888, 367170391800, 720353694360, 711325560884, + 357824486244, 2264545576] + (lo := 0) (hi := 11) (s := 19487171) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (11 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (45 / 4) 17) : + 0 ≤ -distillCritical0 34 x := by + refine (BernsteinCert.coeffs_pos + [102465371939040, 4219948061984592, 30165632845323840, 97398834911723520, + 171999965329520640, 173136495778705408, 93825271458643968, 21352274804080640] + (lo := (45 / 4)) (hi := 17) (s := 3404825447) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (45 / 4)) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 34 α ≤ (287 / 1000) := by + apply distillT0_le_of_critical (l := 11) (r := (45 / 4)) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 2)) : + 0 ≤ -distillCritical1 34 x := by + refine (BernsteinCert.coeffs_pos + [1050640865280, 22815734455296, 195838903153152, 843980797313280, 1920753970887648, + 2233555576819312, 1141171228981456, 2058573566256] + (lo := 0) (hi := (23 / 2)) (s := 3404825447) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((23 / 2) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (47 / 4) 17) : + 0 ≤ distillCritical1 34 x := by + refine (BernsteinCert.coeffs_pos + [451252001951824, 14318358312915808, 95869081404545088, 295061851586269184, + 498237870725494784, 479214806220152832, 247569442817720320, 53544450087976960] + (lo := (47 / 4)) (hi := 17) (s := 257298363) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (47 / 4)) (17 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 34 α ≤ (161 / 1000) := by + apply distillT1_le_of_critical (l := (23 / 2)) (r := (47 / 4)) (d := 17) + 31 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (39 / 4)) : + 0 ≤ -distillCritical2 34 x := by + refine (BernsteinCert.coeffs_pos + [8094720, 78055680, 216105248, 156726168, 642652] + (lo := 0) (hi := (39 / 4)) (s := 85683) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((39 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 10 17) : + 0 ≤ distillCritical2 34 x := by + refine (BernsteinCert.coeffs_pos + [52380, 2018300, 7751958, 10296810, 4550560] + (lo := 10) (hi := 17) (s := 343) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 10) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 34 α ≤ (233 / 1000) := by + apply distillT2_le_of_critical (l := (39 / 4)) (r := 10) (d := 17) + 31 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow34 + +theorem distillFinite_34 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 34 + distillT0 34 α + distillT1 34 α + distillT2 34 α ≤ (12089 / 12750) := by + have h0 := CriticalRow34.component0 α hα hd + have h1 := CriticalRow34.component1 α hα hd + have h2 := CriticalRow34.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_34 : ((12089 / 12750) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow35 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (45 / 4)) : + 0 ≤ distillCritical0 35 x := by + refine (BernsteinCert.coeffs_pos + [192217088, 3938992128, 31374428160, 122230658560, 242518571520, 241899403728, + 124716114488, 2191926840] + (lo := 0) (hi := (45 / 4)) (s := 6834375) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((45 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 2) 17) : + 0 ≤ -distillCritical0 35 x := by + refine (BernsteinCert.coeffs_pos + [202982156024, 28797496722988, 221414020533916, 727378963157592, 1286334745696064, + 1287738857803520, 691391983685440, 155509792813440] + (lo := (23 / 2)) (hi := 17) (s := 19487171) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (23 / 2)) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 35 α ≤ (287 / 1000) := by + apply distillT0_le_of_critical (l := (45 / 4)) (r := (23 / 2)) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (47 / 4)) : + 0 ≤ -distillCritical1 35 x := by + refine (BernsteinCert.coeffs_pos + [146948633395200, 3241672841134080, 28249095164682240, 123510663437875200, + 285029609881825536, 336599500923801376, 176872630443951952, 2968987875771408] + (lo := 0) (hi := (47 / 4)) (s := 506623120463) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((47 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 12 17) : + 0 ≤ distillCritical1 35 x := by + refine (BernsteinCert.coeffs_pos + [8095655808, 1022209280136, 7596239778648, 24103580710680, 41072429520180, + 39499970454118, 20305688774836, 4357432784538] + (lo := 12) (hi := 17) (s := 15625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 12) (17 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 35 α ≤ (4 / 25) := by + apply distillT1_le_of_critical (l := (47 / 4)) (r := 12) (d := 17) + 32 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 10) : + 0 ≤ -distillCritical2 35 x := by + refine (BernsteinCert.coeffs_pos + [4536, 44523, 125223, 91991, 955] + (lo := 0) (hi := 10) (s := 50) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (10 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (41 / 4) 17) : + 0 ≤ distillCritical2 35 x := by + refine (BernsteinCert.coeffs_pos + [22885540, 1192238344, 4605871776, 6077243008, 2661273088] + (lo := (41 / 4)) (hi := 17) (s := 177147) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (41 / 4)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 35 α ≤ (239 / 1000) := by + apply distillT2_le_of_critical (l := 10) (r := (41 / 4)) (d := 17) + 32 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow35 + +theorem distillFinite_35 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 35 + distillT0 35 α + distillT1 35 α + distillT2 35 α ≤ (1429 / 1500) := by + have h0 := CriticalRow35.component0 α hα hd + have h1 := CriticalRow35.component1 α hα hd + have h2 := CriticalRow35.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_35 : ((1429 / 1500) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow36 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (47 / 4)) : + 0 ≤ distillCritical0 36 x := by + refine (BernsteinCert.coeffs_pos + [11145125560320, 235364240719872, 1927236725637120, 7687182510084096, 15509440540624896, + 15618680920597248, 8276449656193056, 67386225560688] + (lo := 0) (hi := (47 / 4)) (s := 506623120463) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((47 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 12 17) : + 0 ≤ -distillCritical0 36 x := by + refine (BernsteinCert.coeffs_pos + [6959488896, 289632493152, 1995867444096, 6182251432560, 10450523460960, 10052662448016, + 5197576434552, 1126706704776] + (lo := 12) (hi := 17) (s := 78125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 12) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 36 α ≤ (287 / 1000) := by + apply distillT0_le_of_critical (l := (47 / 4)) (r := 12) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (49 / 4)) : + 0 ≤ -distillCritical1 36 x := by + refine (BernsteinCert.coeffs_pos + [160159582126080, 3639464830697472, 32615119255928832, 146284385698418688, + 345138974429469696, 415358711642044800, 222986021776233408, 2574684763393776] + (lo := 0) (hi := (49 / 4)) (s := 678223072849) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((49 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 2) 17) : + 0 ≤ distillCritical1 36 x := by + refine (BernsteinCert.coeffs_pos + [5164473663280, 268005353881984, 1838845193667744, 5567231374132544, 9132551871822080, + 8485589792050176, 4221711237506560, 877523932011520] + (lo := (25 / 2)) (hi := 17) (s := 1594323) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (25 / 2)) (17 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 36 α ≤ (4 / 25) := by + apply distillT1_le_of_critical (l := (49 / 4)) (r := (25 / 2)) (d := 17) + 33 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (41 / 4)) : + 0 ≤ -distillCritical2 36 x := by + refine (BernsteinCert.coeffs_pos + [246343680, 2460430080, 7027373376, 5225644248, 84568996] + (lo := 0) (hi := (41 / 4)) (s := 2825761) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((41 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 2) 17) : + 0 ≤ distillCritical2 36 x := by + refine (BernsteinCert.coeffs_pos + [2470824, 219597372, 855526104, 1122332400, 487245920] + (lo := (21 / 2)) (hi := 17) (s := 28561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (21 / 2)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 36 α ≤ (61 / 250) := by + apply distillT2_le_of_critical (l := (41 / 4)) (r := (21 / 2)) (d := 17) + 33 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow36 + +theorem distillFinite_36 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 36 + distillT0 36 α + distillT1 36 α + distillT2 36 α ≤ (51689 / 54000) := by + have h0 := CriticalRow36.component0 α hα hd + have h1 := CriticalRow36.component1 α hα hd + have h2 := CriticalRow36.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_36 : ((51689 / 54000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end diff --git a/Sendov/DistillationFinite/Rows37_44.lean b/Sendov/DistillationFinite/Rows37_44.lean new file mode 100644 index 0000000..88a5f2d --- /dev/null +++ b/Sendov/DistillationFinite/Rows37_44.lean @@ -0,0 +1,935 @@ +import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.BernsteinList + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow37 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 12) : + 0 ≤ distillCritical0 37 x := by + refine (BernsteinCert.coeffs_pos + [740925, 15888039, 131983281, 533286819, 1087320151, 1104726613, 599087099, 11285921] + (lo := 0) (hi := 12) (s := 36864) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (12 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (49 / 4) 17) : + 0 ≤ -distillCritical0 37 x := by + refine (BernsteinCert.coeffs_pos + [9003700352232, 3968335648531624, 29919083496350480, 94859866319116736, + 161117899442540544, 154495564621041664, 79290449457934336, 17016402316869632] + (lo := (49 / 4)) (hi := 17) (s := 893871739) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (49 / 4)) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 37 α ≤ (287 / 1000) := by + apply distillT0_le_of_critical (l := 12) (r := (49 / 4)) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (51 / 4)) : + 0 ≤ -distillCritical1 37 x := by + refine (BernsteinCert.coeffs_pos + [716610600960, 16760323211264, 154339513262080, 709644967258112, 1710765993932416, + 2097080117760800, 1150458225450064, 7728910782960] + (lo := 0) (hi := (51 / 4)) (s := 3693048057) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((51 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 13 17) : + 0 ≤ distillCritical1 37 x := by + refine (BernsteinCert.coeffs_pos + [57904457889, 1903795669685, 12084404188825, 34904838577957, 55124204786619, + 49498253087975, 23843598650891, 4803430007359] + (lo := 13) (hi := 17) (s := 4096) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 13) (17 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 37 α ≤ (159 / 1000) := by + apply distillT1_le_of_critical (l := (51 / 4)) (r := 13) (d := 17) + 34 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 2)) : + 0 ≤ -distillCritical2 37 x := by + refine (BernsteinCert.coeffs_pos + [603840, 6134880, 17787848, 13380860, 288504] + (lo := 0) (hi := (21 / 2)) (s := 7203) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((21 / 2) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (43 / 4) 17) : + 0 ≤ distillCritical2 37 x := by + refine (BernsteinCert.coeffs_pos + [6234588, 3425706152, 13501220928, 17627386752, 7590949888] + (lo := (43 / 4)) (hi := 17) (s := 390625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (43 / 4)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 37 α ≤ (249 / 1000) := by + apply distillT2_le_of_critical (l := (21 / 2)) (r := (43 / 4)) (d := 17) + 34 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow37 + +theorem distillFinite_37 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 37 + distillT0 37 α + distillT1 37 α + distillT2 37 α ≤ (21329 / 22200) := by + have h0 := CriticalRow37.component0 α hα hd + have h1 := CriticalRow37.component1 α hα hd + have h2 := CriticalRow37.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_37 : ((21329 / 22200) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow38 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 2)) : + 0 ≤ distillCritical0 38 x := by + refine (BernsteinCert.coeffs_pos + [19488024576, 430097651712, 3668847250176, 15163093935360, 31409640413760, + 32182520121296, 17959131355112, 183739085256] + (lo := 0) (hi := (25 / 2)) (s := 1220703125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((25 / 2) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (51 / 4) 17) : + 0 ≤ -distillCritical0 38 x := by + refine (BernsteinCert.coeffs_pos + [114877510043616, 5092222392625392, 34064628442319808, 101611248598144512, + 164910742970529792, 152014316782931968, 75200397754089472, 15574572477579264] + (lo := (51 / 4)) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (51 / 4)) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 38 α ≤ (287 / 1000) := by + apply distillT0_le_of_critical (l := (25 / 2)) (r := (51 / 4)) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (53 / 4)) : + 0 ≤ -distillCritical1 38 x := by + refine (BernsteinCert.coeffs_pos + [188900514201600, 4543602466553856, 42962852889280512, 202377940809191424, + 498220275127204608, 621777168188123200, 348623477048922592, 794471569575984] + (lo := 0) (hi := (53 / 4)) (s := 1174711139837) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((53 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 2) 17) : + 0 ≤ distillCritical1 38 x := by + refine (BernsteinCert.coeffs_pos + [48542894482896, 1166796017363088, 6856519171796784, 18880824351187008, + 28695963607721088, 24900374693969152, 11615736665854720, 2268809693094912] + (lo := (27 / 2)) (hi := 17) (s := 823543) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (27 / 2)) (17 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 38 α ≤ (159 / 1000) := by + apply distillT1_le_of_critical (l := (53 / 4)) (r := (27 / 2)) (d := 17) + 35 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 11) : + 0 ≤ -distillCritical2 38 x := by + refine (BernsteinCert.coeffs_pos + [1077300, 11288700, 33499974, 25110002, 123072] + (lo := 0) (hi := 11) (s := 14641) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (11 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (45 / 4) 17) : + 0 ≤ distillCritical2 38 x := by + refine (BernsteinCert.coeffs_pos + [117215100, 4017080520, 14313914304, 17750452096, 7368864768] + (lo := (45 / 4)) (hi := 17) (s := 279841) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (45 / 4)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 38 α ≤ (127 / 500) := by + apply distillT2_le_of_critical (l := 11) (r := (45 / 4)) (d := 17) + 35 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow38 + +theorem distillFinite_38 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 38 + distillT0 38 α + distillT1 38 α + distillT2 38 α ≤ (2201 / 2280) := by + have h0 := CriticalRow38.component0 α hα hd + have h1 := CriticalRow38.component1 α hα hd + have h2 := CriticalRow38.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_38 : ((2201 / 2280) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow39 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 13) : + 0 ≤ distillCritical0 39 x := by + refine (BernsteinCert.coeffs_pos + [61804620, 1402759296, 12279055842, 51879916800, 109128666960, 112689040779, + 64787473914, 128530077] + (lo := 0) (hi := 13) (s := 4826809) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (13 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (53 / 4) 17) : + 0 ≤ -distillCritical0 39 x := by + refine (BernsteinCert.coeffs_pos + [17108813084168, 426903230928200, 2561530252353072, 7192600531282240, 11151744305551360, + 9881122686885888, 4712493719736320, 942298208878592] + (lo := (53 / 4)) (hi := 17) (s := 11390625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (53 / 4)) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 39 α ≤ (287 / 1000) := by + apply distillT0_le_of_critical (l := 13) (r := (53 / 4)) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 2)) : + 0 ≤ -distillCritical1 39 x := by + refine (BernsteinCert.coeffs_pos + [243476480, 5939730944, 56934562560, 271685184640, 677116090048, 856291631496, + 491805745592, 7850018192] + (lo := 0) (hi := (27 / 2)) (s := 1594323) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((27 / 2) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (55 / 4) 17) : + 0 ≤ distillCritical1 39 x := by + refine (BernsteinCert.coeffs_pos + [776220767172720, 108950263196626416, 741131633020891104, 2142620140767822720, + 3321211317865522176, 2902649874544336896, 1354858682660904960, 263760894951260160] + (lo := (55 / 4)) (hi := 17) (s := 62748517) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (55 / 4)) (17 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 39 α ≤ (79 / 500) := by + apply distillT1_le_of_critical (l := (27 / 2)) (r := (55 / 4)) (d := 17) + 36 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (45 / 4)) : + 0 ≤ -distillCritical2 39 x := by + refine (BernsteinCert.coeffs_pos + [79872, 850688, 2561152, 1941128, 20292] + (lo := 0) (hi := (45 / 4)) (s := 1125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((45 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 2) 17) : + 0 ≤ distillCritical2 39 x := by + refine (BernsteinCert.coeffs_pos + [5150264, 243542764, 876085176, 1081599280, 445604960] + (lo := (23 / 2)) (hi := 17) (s := 14641) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (23 / 2)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 39 α ≤ (259 / 1000) := by + apply distillT2_le_of_critical (l := (45 / 4)) (r := (23 / 2)) (d := 17) + 36 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow39 + +theorem distillFinite_39 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 39 + distillT0 39 α + distillT1 39 α + distillT2 39 α ≤ (14171 / 14625) := by + have h0 := CriticalRow39.component0 α hα hd + have h1 := CriticalRow39.component1 α hα hd + have h2 := CriticalRow39.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_39 : ((14171 / 14625) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow40 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (53 / 4)) : + 0 ≤ distillCritical0 40 x := by + refine (BernsteinCert.coeffs_pos + [13874076057600, 319404418007040, 2833672340275200, 12117221835079680, + 25732901382730752, 26766447825685760, 15725130190623360, 196910190955120] + (lo := 0) (hi := (53 / 4)) (s := 1174711139837) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((53 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 2) 17) : + 0 ≤ -distillCritical0 40 x := by + refine (BernsteinCert.coeffs_pos + [759374723952, 40137614276256, 263351883650688, 760145428070784, 1188521909766912, + 1052983947921920, 499818697728000, 99188314716160] + (lo := (27 / 2)) (hi := 17) (s := 823543) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (27 / 2)) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 40 α ≤ (287 / 1000) := by + apply distillT0_le_of_critical (l := (53 / 4)) (r := (27 / 2)) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 14) : + 0 ≤ -distillCritical1 40 x := by + refine (BernsteinCert.coeffs_pos + [210644550, 5278767165, 51901770060, 253490323905, 644580351366, 829141605607, + 486430906248, 5795970779] + (lo := 0) (hi := 14) (s := 1647086) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (14 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (57 / 4) 17) : + 0 ≤ distillCritical1 40 x := by + refine (BernsteinCert.coeffs_pos + [2950782573731472, 127688744399884992, 791843921285225472, 2177788679780401152, + 3249058594728886272, 2746165907629015040, 1242607876766760960, 234818901464842240] + (lo := (57 / 4)) (hi := 17) (s := 19487171) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (57 / 4)) (17 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 40 α ≤ (79 / 500) := by + apply distillT1_le_of_critical (l := 14) (r := (57 / 4)) (d := 17) + 37 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 2)) : + 0 ≤ -distillCritical2 40 x := by + refine (BernsteinCert.coeffs_pos + [19180800, 207580320, 633854400, 485505236, 7588800] + (lo := 0) (hi := (23 / 2)) (s := 279841) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((23 / 2) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (47 / 4) 17) : + 0 ≤ distillCritical2 40 x := by + refine (BernsteinCert.coeffs_pos + [42828748, 3746490232, 13653815136, 16800987520, 6873393664] + (lo := (47 / 4)) (hi := 17) (s := 194481) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (47 / 4)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 40 α ≤ (33 / 125) := by + apply distillT2_le_of_critical (l := (23 / 2)) (r := (47 / 4)) (d := 17) + 37 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow40 + +theorem distillFinite_40 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 40 + distillT0 40 α + distillT1 40 α + distillT2 40 α ≤ (11683 / 12000) := by + have h0 := CriticalRow40.component0 α hα hd + have h1 := CriticalRow40.component1 α hα hd + have h2 := CriticalRow40.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_40 : ((11683 / 12000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow41 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (55 / 4)) : + 0 ≤ distillCritical0 41 x := by + refine (BernsteinCert.coeffs_pos + [2920579006464, 69068704333824, 628174873589760, 2743795180500480, 5912462599618560, + 6191155412608784, 3750607427647704, 18608274669400] + (lo := 0) (hi := (55 / 4)) (s := 304487046875) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((55 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 14 17) : + 0 ≤ -distillCritical0 41 x := by + refine (BernsteinCert.coeffs_pos + [5357567964, 131396060728, 761367606246, 2058344771400, 3068265007634, 2611112787531, + 1194934814268, 229074420757] + (lo := 14) (hi := 17) (s := 729) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 14) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 41 α ≤ (287 / 1000) := by + apply distillT0_le_of_critical (l := (55 / 4)) (r := 14) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 2)) : + 0 ≤ -distillCritical1 41 x := by + refine (BernsteinCert.coeffs_pos + [1860406133760, 47858605843968, 482363396206848, 2409898941272448, 6249119240223120, + 8172874298354392, 4897806317994360, 40044402202160] + (lo := 0) (hi := (29 / 2)) (s := 17249876309) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((29 / 2) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (59 / 4) 17) : + 0 ≤ distillCritical1 41 x := by + refine (BernsteinCert.coeffs_pos + [1954946700115088, 49133046896914928, 276734364062525664, 721491122377495552, + 1033831048206699520, 844034084905684992, 369985543123558400, 67847736684707840] + (lo := (59 / 4)) (hi := 17) (s := 1594323) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (59 / 4)) (17 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 41 α ≤ (157 / 1000) := by + apply distillT1_le_of_critical (l := (29 / 2)) (r := (59 / 4)) (d := 17) + 38 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 12) : + 0 ≤ -distillCritical2 41 x := by + refine (BernsteinCert.coeffs_pos + [11685, 130200, 406498, 310320, 65] + (lo := 0) (hi := 12) (s := 192) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (12 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (49 / 4) 17) : + 0 ≤ distillCritical2 41 x := by + refine (BernsteinCert.coeffs_pos + [183148396, 4368408504, 14343986304, 16743616640, 6600007680] + (lo := (49 / 4)) (hi := 17) (s := 130321) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (49 / 4)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 41 α ≤ (269 / 1000) := by + apply distillT2_le_of_critical (l := 12) (r := (49 / 4)) (d := 17) + 38 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow41 + +theorem distillFinite_41 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 41 + distillT0 41 α + distillT1 41 α + distillT2 41 α ≤ (120199 / 123000) := by + have h0 := CriticalRow41.component0 α hα hd + have h1 := CriticalRow41.component1 α hα hd + have h2 := CriticalRow41.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_41 : ((120199 / 123000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow42 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 14) : + 0 ≤ distillCritical0 42 x := by + refine (BernsteinCert.coeffs_pos + [8365275, 200545713, 1847584161, 8163494847, 17749943613, 18703640295, 11565197031, + 172991433] + (lo := 0) (hi := 14) (s := 941192) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (14 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (57 / 4) 17) : + 0 ≤ -distillCritical0 42 x := by + refine (BernsteinCert.coeffs_pos + [50358143685600, 4722866446785552, 30972864974370624, 87161941383312384, + 131906545727993856, 112728368793415680, 51507884468355072, 9824558069317632] + (lo := (57 / 4)) (hi := 17) (s := 19487171) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (57 / 4)) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 42 α ≤ (143 / 500) := by + apply distillT0_le_of_critical (l := 14) (r := (57 / 4)) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 15) : + 0 ≤ -distillCritical1 42 x := by + refine (BernsteinCert.coeffs_pos + [1430352, 37746592, 389757280, 1990818240, 5262008180, 6994043912, 4281391932, 20229000] + (lo := 0) (hi := 15) (s := 15625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (15 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (61 / 4) 17) : + 0 ≤ distillCritical1 42 x := by + refine (BernsteinCert.coeffs_pos + [9674856523168080, 167584454000488224, 851148203633082432, 2090872947977124864, + 2866264359788132352, 2254521947252908032, 955787252801224704, 169895370516332544] + (lo := (61 / 4)) (hi := 17) (s := 823543) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (61 / 4)) (17 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 42 α ≤ (39 / 250) := by + apply distillT1_le_of_critical (l := 15) (r := (61 / 4)) (d := 17) + 39 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (49 / 4)) : + 0 ≤ -distillCritical2 42 x := by + refine (BernsteinCert.coeffs_pos + [48522240, 548985600, 1737425952, 1339888776, 7395196] + (lo := 0) (hi := (49 / 4)) (s := 823543) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((49 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 2) 17) : + 0 ≤ distillCritical2 42 x := by + refine (BernsteinCert.coeffs_pos + [8875520, 260981420, 865671024, 1007149136, 394345088] + (lo := (25 / 2)) (hi := 17) (s := 6561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (25 / 2)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 42 α ≤ (137 / 500) := by + apply distillT2_le_of_critical (l := (49 / 4)) (r := (25 / 2)) (d := 17) + 39 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow42 + +theorem distillFinite_42 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 42 + distillT0 42 α + distillT1 42 α + distillT2 42 α ≤ (8819 / 9000) := by + have h0 := CriticalRow42.component0 α hα hd + have h1 := CriticalRow42.component1 α hα hd + have h2 := CriticalRow42.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_42 : ((8819 / 9000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow43 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 2)) : + 0 ≤ distillCritical0 43 x := by + refine (BernsteinCert.coeffs_pos + [125909614080, 3097543037184, 29228204244672, 131813967943008, 290608670169024, + 307939956026780, 196494775761212, 1570609315632] + (lo := 0) (hi := (29 / 2)) (s := 17249876309) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((29 / 2) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (59 / 4) 17) : + 0 ≤ -distillCritical0 43 x := by + refine (BernsteinCert.coeffs_pos + [241329033437528, 5977566888915992, 33652596827420592, 87893907910468288, + 126297911863822336, 103475167039537152, 45546164845039616, 8391380704477184] + (lo := (59 / 4)) (hi := 17) (s := 4782969) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (59 / 4)) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 43 α ≤ (143 / 500) := by + apply distillT0_le_of_critical (l := (29 / 2)) (r := (59 / 4)) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (31 / 2)) : + 0 ≤ -distillCritical1 43 x := by + refine (BernsteinCert.coeffs_pos + [2150654976000, 58185480135168, 615153183194880, 3210790512868992, 8646426735703392, + 11674976608160744, 7299985660815096, 11266162138960] + (lo := 0) (hi := (31 / 2)) (s := 27512614111) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((31 / 2) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (63 / 4) 17) : + 0 ≤ distillCritical1 43 x := by + refine (BernsteinCert.coeffs_pos + [14560310642175216, 187570090492658352, 848671241110913376, 1943669075490092160, + 2530096609046799360, 1907218885214683136, 778966818478743552, 133836932648697856] + (lo := (63 / 4)) (hi := 17) (s := 78125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (63 / 4)) (17 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 43 α ≤ (39 / 250) := by + apply distillT1_le_of_critical (l := (31 / 2)) (r := (63 / 4)) (d := 17) + 40 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 2)) : + 0 ≤ -distillCritical2 43 x := by + refine (BernsteinCert.coeffs_pos + [891648, 10240992, 32845488, 25577092, 268448] + (lo := 0) (hi := (25 / 2)) (s := 15625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((25 / 2) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (51 / 4) 17) : + 0 ≤ distillCritical2 43 x := by + refine (BernsteinCert.coeffs_pos + [95475996, 3947635080, 13281114720, 15421202048, 6001934848] + (lo := (51 / 4)) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (51 / 4)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 43 α ≤ (279 / 1000) := by + apply distillT2_le_of_critical (l := (25 / 2)) (r := (51 / 4)) (d := 17) + 40 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow43 + +theorem distillFinite_43 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 43 + distillT0 43 α + distillT1 43 α + distillT2 43 α ≤ (127009 / 129000) := by + have h0 := CriticalRow43.component0 α hα hd + have h1 := CriticalRow43.component1 α hα hd + have h2 := CriticalRow43.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_43 : ((127009 / 129000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow44 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 15) : + 0 ≤ distillCritical0 44 x := by + refine (BernsteinCert.coeffs_pos + [849024, 21420384, 206902080, 951954480, 2127248960, 2265354544, 1492973864, 1994520] + (lo := 0) (hi := 15) (s := 140625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (15 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (61 / 4) 17) : + 0 ≤ -distillCritical0 44 x := by + refine (BernsteinCert.coeffs_pos + [489004352844208, 7398831200662496, 36110453925835520, 87131692244405760, + 118340961495285760, 92628275178299392, 39178309244813312, 6959933834526720] + (lo := (61 / 4)) (hi := 17) (s := 823543) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (61 / 4)) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 44 α ≤ (143 / 500) := by + apply distillT0_le_of_critical (l := 15) (r := (61 / 4)) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (63 / 4)) : + 0 ≤ -distillCritical1 44 x := by + refine (BernsteinCert.coeffs_pos + [404970536960, 11094654713856, 118722588278784, 626807954698240, 1706103540857856, + 2329365558662016, 1486183128987200, 20728193456400] + (lo := 0) (hi := (63 / 4)) (s := 5403265623) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((63 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 16 17) : + 0 ≤ distillCritical1 44 x := by + refine (BernsteinCert.coeffs_pos + [95942262656, 5037386289088, 29415669774880, 75016752584016, 103309075583888, + 80437735436936, 33489634275760, 5818447647000] + (lo := 16) (hi := 17) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 16) (17 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 44 α ≤ (31 / 200) := by + apply distillT1_le_of_critical (l := (63 / 4)) (r := 16) (d := 17) + 41 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (51 / 4)) : + 0 ≤ -distillCritical2 44 x := by + refine (BernsteinCert.coeffs_pos + [13854720, 161498880, 524792128, 412470424, 6257148] + (lo := 0) (hi := (51 / 4)) (s := 250563) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((51 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 13 17) : + 0 ≤ distillCritical2 44 x := by + refine (BernsteinCert.coeffs_pos + [84467, 7191936, 24672222, 28638280, 11088375] + (lo := 13) (hi := 17) (s := 128) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 13) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 44 α ≤ (283 / 1000) := by + apply distillT2_le_of_critical (l := (51 / 4)) (r := 13) (d := 17) + 41 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow44 + +theorem distillFinite_44 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 44 + distillT0 44 α + distillT1 44 α + distillT2 44 α ≤ (65159 / 66000) := by + have h0 := CriticalRow44.component0 α hα hd + have h1 := CriticalRow44.component1 α hα hd + have h2 := CriticalRow44.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_44 : ((65159 / 66000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end diff --git a/Sendov/DistillationFinite/Rows45_52.lean b/Sendov/DistillationFinite/Rows45_52.lean new file mode 100644 index 0000000..e064c4f --- /dev/null +++ b/Sendov/DistillationFinite/Rows45_52.lean @@ -0,0 +1,850 @@ +import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.BernsteinList + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow45 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (61 / 4)) : + 0 ≤ distillCritical0 45 x := by + refine (BernsteinCert.coeffs_pos + [290237644800, 7416646778880, 72509269063680, 337237878366720, 759830715528192, + 813132325666224, 546342180873336, 6036468966648] + (lo := 0) (hi := (61 / 4)) (s := 51520374361) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((61 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 2) 17) : + 0 ≤ -distillCritical0 45 x := by + refine (BernsteinCert.coeffs_pos + [50773565824, 1370369396604, 7596016567764, 19286176403624, 26824077330624, + 21226642719360, 9012499380160, 1600178663040] + (lo := (31 / 2)) (hi := 17) (s := 81) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (31 / 2)) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 45 α ≤ (57 / 200) := by + apply distillT0_le_of_critical (l := (61 / 4)) (r := (31 / 2)) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (65 / 4)) : + 0 ≤ -distillCritical1 45 x := by + refine (BernsteinCert.coeffs_pos + [972618596352, 27292873162752, 298783919185920, 1610716128675840, 4463609951479680, + 6186323178993312, 4028997769033392, 44180834863440] + (lo := 0) (hi := (65 / 4)) (s := 15083778125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((65 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 2) 17) : + 0 ≤ distillCritical1 45 x := by + refine (BernsteinCert.coeffs_pos + [43680994075152, 639217250353944, 2962724704861608, 6756753144769056, 8655355325189952, + 6381837711308160, 2540535059687040, 424487977443840] + (lo := (33 / 2)) (hi := 17) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (33 / 2)) (17 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 45 α ≤ (77 / 500) := by + apply distillT1_le_of_critical (l := (65 / 4)) (r := (33 / 2)) (d := 17) + 42 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (53 / 4)) : + 0 ≤ -distillCritical2 45 x := by + refine (BernsteinCert.coeffs_pos + [391910400, 4694319360, 15578252640, 12206129352, 14989876] + (lo := 0) (hi := (53 / 4)) (s := 7890481) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((53 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 2) 17) : + 0 ≤ distillCritical2 45 x := by + refine (BernsteinCert.coeffs_pos + [13856832, 269184060, 818275392, 896135952, 333466304] + (lo := (27 / 2)) (hi := 17) (s := 2401) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (27 / 2)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 45 α ≤ (36 / 125) := by + apply distillT2_le_of_critical (l := (53 / 4)) (r := (27 / 2)) (d := 17) + 42 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow45 + +theorem distillFinite_45 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 45 + distillT0 45 α + distillT1 45 α + distillT2 45 α ≤ (26729 / 27000) := by + have h0 := CriticalRow45.component0 α hα hd + have h1 := CriticalRow45.component1 α hα hd + have h2 := CriticalRow45.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_45 : ((26729 / 27000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow46 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (63 / 4)) : + 0 ≤ distillCritical0 46 x := by + refine (BernsteinCert.coeffs_pos + [8471183360, 221793746944, 2217872498688, 10516706271232, 24002114307584, + 25786587097152, 17905381361840, 87406488928] + (lo := 0) (hi := (63 / 4)) (s := 1801088541) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((63 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 16 17) : + 0 ≤ -distillCritical0 46 x := by + refine (BernsteinCert.coeffs_pos + [27745483632, 363311005264, 1644423464696, 3749437851896, 4849062858456, 3627803822260, + 1469701213876, 250380345416] + (lo := 16) (hi := 17) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 16) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 46 α ≤ (71 / 250) := by + apply distillT0_le_of_critical (l := (63 / 4)) (r := 16) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (67 / 4)) : + 0 ≤ -distillCritical1 46 x := by + refine (BernsteinCert.coeffs_pos + [337937903124480, 9707731313688576, 108665645425606656, 597885756027826176, + 1686200738344827648, 2371417002819163328, 1576375325028149600, 12926181583597584] + (lo := 0) (hi := (67 / 4)) (s := 6060711605323) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((67 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 46 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 46 α ≤ (153 / 1000) := by + apply distillT1_le_of_critical (l := (67 / 4)) (r := 17) (d := 17) + 43 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 2)) : + 0 ≤ -distillCritical2 46 x := by + refine (BernsteinCert.coeffs_pos + [316480, 3844960, 12921576, 10215556, 61384] + (lo := 0) (hi := (27 / 2)) (s := 6561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((27 / 2) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (55 / 4) 17) : + 0 ≤ distillCritical2 46 x := by + refine (BernsteinCert.coeffs_pos + [167510220, 3983957720, 12285681216, 13442494080, 4976573440] + (lo := (55 / 4)) (hi := 17) (s := 28561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (55 / 4)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 46 α ≤ (73 / 250) := by + apply distillT2_le_of_critical (l := (27 / 2)) (r := (55 / 4)) (d := 17) + 43 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow46 + +theorem distillFinite_46 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 46 + distillT0 46 α + distillT1 46 α + distillT2 46 α ≤ (34213 / 34500) := by + have h0 := CriticalRow46.component0 α hα hd + have h1 := CriticalRow46.component1 α hα hd + have h2 := CriticalRow46.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_46 : ((34213 / 34500) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow47 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 16) : + 0 ≤ distillCritical0 47 x := by + refine (BernsteinCert.coeffs_pos + [295518375, 7833043521, 79245659475, 379695923109, 873366376341, 942092902915, + 666360453681, 9399522263] + (lo := 0) (hi := 16) (s := 67108864) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (16 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (65 / 4) 17) : + 0 ≤ -distillCritical0 47 x := by + refine (BernsteinCert.coeffs_pos + [15397621242280, 818716375621736, 4739759707551024, 11971051892787776, + 16322765186136064, 12582209027776512, 5186046842884096, 891992064671744] + (lo := (65 / 4)) (hi := 17) (s := 729) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (65 / 4)) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 47 α ≤ (283 / 1000) := by + apply distillT0_le_of_critical (l := 16) (r := (65 / 4)) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 47 x := by + refine (BernsteinCert.coeffs_pos + [22018774320, 640022273064, 7246161961272, 40299639569208, 114791086917888, + 163061805712510, 110369826011992, 2152820201154] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 47 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 47 α ≤ (69 / 500) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 44 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (55 / 4)) : + 0 ≤ -distillCritical2 47 x := by + refine (BernsteinCert.coeffs_pos + [7796736, 96056064, 326839296, 260620744, 2741276] + (lo := 0) (hi := (55 / 4)) (s := 166375) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((55 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 14 17) : + 0 ≤ distillCritical2 47 x := by + refine (BernsteinCert.coeffs_pos + [139232, 4710300, 14830440, 16246586, 5990346] + (lo := 14) (hi := 17) (s := 27) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 14) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 47 α ≤ (297 / 1000) := by + apply distillT2_le_of_critical (l := (55 / 4)) (r := 14) (d := 17) + 44 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow47 + +theorem distillFinite_47 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 47 + distillT0 47 α + distillT1 47 α + distillT2 47 α ≤ (69119 / 70500) := by + have h0 := CriticalRow47.component0 α hα hd + have h1 := CriticalRow47.component1 α hα hd + have h2 := CriticalRow47.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_47 : ((69119 / 70500) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow48 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (33 / 2)) : + 0 ≤ distillCritical0 48 x := by + refine (BernsteinCert.coeffs_pos + [72253440, 1960587264, 20272389120, 98967977472, 230462447744, 249313304256, + 182338790368, 1525585584] + (lo := 0) (hi := (33 / 2)) (s := 19487171) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((33 / 2) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (67 / 4) 17) : + 0 ≤ -distillCritical0 48 x := by + refine (BernsteinCert.coeffs_pos + [354897485095728, 3321802657734528, 12535233892807680, 25272279824701440, + 29751451415629824, 20598821852184576, 7802772844707840, 1251451303624704] + (lo := (67 / 4)) (hi := 17) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (67 / 4)) (17 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 48 α ≤ (283 / 1000) := by + apply distillT0_le_of_critical (l := (33 / 2)) (r := (67 / 4)) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 48 x := by + refine (BernsteinCert.coeffs_pos + [23472633600, 682648733664, 7735092314688, 43076728701936, 123004760598432, + 175655443877280, 120622004139648, 5124511031136] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 48 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 48 α ≤ (17 / 125) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 45 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 14) : + 0 ≤ -distillCritical2 48 x := by + refine (BernsteinCert.coeffs_pos + [218700, 2731725, 9409023, 7564833, 111803] + (lo := 0) (hi := 14) (s := 4802) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (14 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (57 / 4) 17) : + 0 ≤ distillCritical2 48 x := by + refine (BernsteinCert.coeffs_pos + [39639132, 3205489032, 10401612768, 11441562240, 4207497728] + (lo := (57 / 4)) (hi := 17) (s := 14641) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (57 / 4)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 48 α ≤ (301 / 1000) := by + apply distillT2_le_of_critical (l := 14) (r := (57 / 4)) (d := 17) + 45 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow48 + +theorem distillFinite_48 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 48 + distillT0 48 α + distillT1 48 α + distillT2 48 α ≤ (14143 / 14400) := by + have h0 := CriticalRow48.component0 α hα hd + have h1 := CriticalRow48.component1 α hα hd + have h2 := CriticalRow48.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_48 : ((14143 / 14400) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow49 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 49 x := by + refine (BernsteinCert.coeffs_pos + [1288099260, 35762656032, 377764755210, 1878357794400, 4426800113640, 4799762567483, + 3632062300638, 10457952385] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 49 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 49 α ≤ (261 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 49 x := by + refine (BernsteinCert.coeffs_pos + [24988982760, 727119719136, 8245372912704, 45976583685600, 131587201045986, + 188822483951056, 131343227181150, 8257413991640] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 49 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 49 α ≤ (131 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 46 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 2)) : + 0 ≤ -distillCritical2 49 x := by + refine (BernsteinCert.coeffs_pos + [29211840, 374297760, 1315193064, 1054320500, 2168760] + (lo := 0) (hi := (29 / 2)) (s := 707281) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((29 / 2) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (59 / 4) 17) : + 0 ≤ distillCritical2 49 x := by + refine (BernsteinCert.coeffs_pos + [262554076, 3805372264, 10565597184, 10819327360, 3797309440] + (lo := (59 / 4)) (hi := 17) (s := 6561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (59 / 4)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 49 α ≤ (153 / 500) := by + apply distillT2_le_of_critical (l := (29 / 2)) (r := (59 / 4)) (d := 17) + 46 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow49 + +theorem distillFinite_49 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 49 + distillT0 49 α + distillT1 49 α + distillT2 49 α ≤ (10079 / 10500) := by + have h0 := CriticalRow49.component0 α hα hd + have h1 := CriticalRow49.component1 α hα hd + have h2 := CriticalRow49.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_49 : ((10079 / 10500) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow50 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 50 x := by + refine (BernsteinCert.coeffs_pos + [1342818000, 37306118160, 394455786120, 1964449373400, 4642104191448, 5052406955660, + 3827026759700, 97192809600] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 50 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 50 α ≤ (13 / 50) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 50 x := by + refine (BernsteinCert.coeffs_pos + [26569134000, 773474158080, 8777456969760, 49001824005120, 140546263845804, + 202574751551680, 142542015870100, 11553875896800] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 50 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 50 α ≤ (63 / 500) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 47 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (59 / 4)) : + 0 ≤ -distillCritical2 50 x := by + refine (BernsteinCert.coeffs_pos + [487296000, 6327002880, 22495133280, 18177472424, 116432148] + (lo := 0) (hi := (59 / 4)) (s := 12117361) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((59 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 15 17) : + 0 ≤ distillCritical2 50 x := by + refine (BernsteinCert.coeffs_pos + [188325, 3241035, 9169935, 9407797, 3291036] + (lo := 15) (hi := 17) (s := 4) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 15) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 50 α ≤ (31 / 100) := by + apply distillT2_le_of_critical (l := (59 / 4)) (r := 15) (d := 17) + 47 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow50 + +theorem distillFinite_50 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 50 + distillT0 50 α + distillT1 50 α + distillT2 50 α ≤ (2873 / 3000) := by + have h0 := CriticalRow50.component0 α hα hd + have h1 := CriticalRow50.component1 α hα hd + have h2 := CriticalRow50.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_50 : ((2873 / 3000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow51 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 51 x := by + refine (BernsteinCert.coeffs_pos + [82274940, 2287182096, 24206166522, 120731122728, 286011625536, 312360961923, + 236690749410, 10813061517] + (lo := 0) (hi := 17) (s := 24137569) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 51 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 51 α ≤ (129 / 500) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 51 x := by + refine (BernsteinCert.coeffs_pos + [1659670560, 48338292888, 548929276488, 3067945243848, 8817047328420, 12760239546882, + 9072170055300, 883308444750] + (lo := 0) (hi := 17) (s := 24137569) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 51 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 51 α ≤ (3 / 25) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 48 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 15) : + 0 ≤ -distillCritical2 51 x := by + refine (BernsteinCert.coeffs_pos + [4896, 64404, 231656, 188634, 1986] + (lo := 0) (hi := 15) (s := 125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (15 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (61 / 4) 17) : + 0 ≤ distillCritical2 51 x := by + refine (BernsteinCert.coeffs_pos + [115683404, 2779929784, 8111817696, 8372924800, 2925632000] + (lo := (61 / 4)) (hi := 17) (s := 2401) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (61 / 4)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 51 α ≤ (157 / 500) := by + apply distillT2_le_of_critical (l := 15) (r := (61 / 4)) (d := 17) + 48 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow51 + +theorem distillFinite_51 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 51 + distillT0 51 α + distillT1 51 α + distillT2 51 α ≤ (36469 / 38250) := by + have h0 := CriticalRow51.component0 α hα hd + have h1 := CriticalRow51.component1 α hα hd + have h2 := CriticalRow51.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_51 : ((36469 / 38250) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow52 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 52 x := by + refine (BernsteinCert.coeffs_pos + [1455667200, 40490588448, 428911889472, 2142296933328, 5087080441632, 5572950758576, + 4222210241448, 270345660952] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 52 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 52 α ≤ (32 / 125) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 52 x := by + refine (BernsteinCert.coeffs_pos + [29926091520, 871989110784, 9908848318752, 55438938591408, 159625678843248, + 231882271804840, 166406373124752, 18646863797624] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 52 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 52 α ≤ (113 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 49 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (61 / 4)) : + 0 ≤ -distillCritical2 52 x := by + refine (BernsteinCert.coeffs_pos + [528353280, 7040183040, 25614141504, 21011917304, 303488004] + (lo := 0) (hi := (61 / 4)) (s := 13845841) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((61 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 2) 17) : + 0 ≤ distillCritical2 52 x := by + refine (BernsteinCert.coeffs_pos + [1919632, 136650532, 420486648, 439755280, 154008928] + (lo := (31 / 2)) (hi := 17) (s := 81) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (31 / 2)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 52 α ≤ (159 / 500) := by + apply distillT2_le_of_critical (l := (61 / 4)) (r := (31 / 2)) (d := 17) + 49 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow52 + +theorem distillFinite_52 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 52 + distillT0 52 α + distillT1 52 α + distillT2 52 α ≤ (73961 / 78000) := by + have h0 := CriticalRow52.component0 α hα hd + have h1 := CriticalRow52.component1 α hα hd + have h2 := CriticalRow52.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_52 : ((73961 / 78000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end diff --git a/Sendov/DistillationFinite/Rows53_60.lean b/Sendov/DistillationFinite/Rows53_60.lean new file mode 100644 index 0000000..aa31b2f --- /dev/null +++ b/Sendov/DistillationFinite/Rows53_60.lean @@ -0,0 +1,782 @@ +import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.BernsteinList + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow53 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 53 x := by + refine (BernsteinCert.coeffs_pos + [1513797660, 42131596608, 446676961914, 2234052914256, 5316752614008, 5840850173315, + 4422429264134, 356763655089] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 53 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 53 α ≤ (127 / 500) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 53 x := by + refine (BernsteinCert.coeffs_pos + [31705522200, 924227481744, 10509062039568, 58856051828016, 169761742211382, + 247461175693060, 179088983157658, 22448083421556] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 53 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 53 α ≤ (21 / 200) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 50 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (63 / 4)) : + 0 ≤ -distillCritical2 53 x := by + refine (BernsteinCert.coeffs_pos + [6784000, 92588800, 343321056, 280846744, 770692] + (lo := 0) (hi := (63 / 4)) (s := 194481) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((63 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 16 17) : + 0 ≤ distillCritical2 53 x := by + refine (BernsteinCert.coeffs_pos + [1190908, 10662876, 25488990, 23772974, 7756068] + (lo := 16) (hi := 17) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 16) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 53 α ≤ (161 / 500) := by + apply distillT2_le_of_critical (l := (63 / 4)) (r := 16) (d := 17) + 50 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow53 + +theorem distillFinite_53 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 53 + distillT0 53 α + distillT1 53 α + distillT2 53 α ≤ (149779 / 159000) := by + have h0 := CriticalRow53.component0 α hα hd + have h1 := CriticalRow53.component1 α hα hd + have h2 := CriticalRow53.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_53 : ((149779 / 159000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow54 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 54 x := by + refine (BernsteinCert.coeffs_pos + [1573065360, 43805120112, 464800048200, 2327697029160, 5551214151240, 6113834596908, + 4624399808028, 443076028200] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 54 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 54 α ≤ (251 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 54 x := by + refine (BernsteinCert.coeffs_pos + [33554003760, 978505020576, 11132892077184, 62409028340160, 180305850272796, + 263672609579496, 192283241772420, 26422249246680] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 54 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 54 α ≤ (49 / 500) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 51 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 16) : + 0 ≤ -distillCritical2 54 x := by + refine (BernsteinCert.coeffs_pos + [557685, 7706340, 28893294, 23805444, 160261] + (lo := 0) (hi := 16) (s := 16384) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (16 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (65 / 4) 17) : + 0 ≤ distillCritical2 54 x := by + refine (BernsteinCert.coeffs_pos + [216994460, 2042940200, 4922556096, 4586464640, 1489863680] + (lo := (65 / 4)) (hi := 17) (s := 81) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (65 / 4)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 54 α ≤ (163 / 500) := by + apply distillT2_le_of_critical (l := 16) (r := (65 / 4)) (d := 17) + 51 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow54 + +theorem distillFinite_54 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 54 + distillT0 54 α + distillT1 54 α + distillT2 54 α ≤ (379 / 405) := by + have h0 := CriticalRow54.component0 α hα hd + have h1 := CriticalRow54.component1 α hα hd + have h2 := CriticalRow54.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_54 : ((379 / 405) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow55 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 55 x := by + refine (BernsteinCert.coeffs_pos + [1633470300, 45511158960, 483281148330, 2423229278040, 5790465053328, 6391904029355, + 4828121873130, 529282780285] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 55 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 55 α ≤ (31 / 125) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 55 x := by + refine (BernsteinCert.coeffs_pos + [35472848400, 1034860655880, 11780791646040, 66100487612760, 191265858612744, + 280528399081990, 205997669702640, 30571708087130] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 55 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 55 α ≤ (91 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 52 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (65 / 4)) : + 0 ≤ -distillCritical2 55 x := by + refine (BernsteinCert.coeffs_pos + [1824768, 25526016, 96754560, 80269864, 845252] + (lo := 0) (hi := (65 / 4)) (s := 54925) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((65 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 2) 17) : + 0 ≤ distillCritical2 55 x := by + refine (BernsteinCert.coeffs_pos + [7531920, 80886852, 200203608, 187915664, 61067104] + (lo := (33 / 2)) (hi := 17) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (33 / 2)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 55 α ≤ (33 / 100) := by + apply distillT2_le_of_critical (l := (65 / 4)) (r := (33 / 2)) (d := 17) + 52 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow55 + +theorem distillFinite_55 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 55 + distillT0 55 α + distillT1 55 α + distillT2 55 α ≤ (30677 / 33000) := by + have h0 := CriticalRow55.component0 α hα hd + have h1 := CriticalRow55.component1 α hα hd + have h2 := CriticalRow55.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_55 : ((30677 / 33000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow56 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 56 x := by + refine (BernsteinCert.coeffs_pos + [1695012480, 47249713152, 502120262304, 2520649660896, 6034505320272, 6675058470656, + 5033595459440, 615383911344] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 56 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 56 α ≤ (49 / 200) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 56 x := by + refine (BernsteinCert.coeffs_pos + [37463368320, 1093333316256, 12453213960576, 69933049130736, 202649622816480, + 298040369818384, 220240787681920, 34898806757040] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 56 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 56 α ≤ (83 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 53 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (33 / 2)) : + 0 ≤ -distillCritical2 56 x := by + refine (BernsteinCert.coeffs_pos + [1424640, 20171040, 77284288, 64546404, 913448] + (lo := 0) (hi := (33 / 2)) (s := 43923) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((33 / 2) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (67 / 4) 17) : + 0 ≤ distillCritical2 56 x := by + refine (BernsteinCert.coeffs_pos + [15039724, 480971352, 1363922784, 1345174400, 447183360] + (lo := (67 / 4)) (hi := 17) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (67 / 4)) (17 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 56 α ≤ (167 / 500) := by + apply distillT2_le_of_critical (l := (33 / 2)) (r := (67 / 4)) (d := 17) + 53 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow56 + +theorem distillFinite_56 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 56 + distillT0 56 α + distillT1 56 α + distillT2 56 α ≤ (11069 / 12000) := by + have h0 := CriticalRow56.component0 α hα hd + have h1 := CriticalRow56.component1 α hα hd + have h2 := CriticalRow56.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_56 : ((11069 / 12000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow57 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 57 x := by + refine (BernsteinCert.coeffs_pos + [1757691900, 49020782688, 521317390122, 2619958177728, 6283334952072, 6963297920811, + 5240820566958, 701379421377] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 57 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 57 α ≤ (241 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 57 x := by + refine (BernsteinCert.coeffs_pos + [39526875720, 1153961930304, 13150612235232, 73909332379008, 214464998469258, + 316220347406520, 235021116443862, 39405892070544] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 57 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 57 α ≤ (19 / 250) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 54 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 57 x := by + refine (BernsteinCert.coeffs_pos + [2493180, 36108180, 140875326, 117338634, 389872] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 57 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 57 α ≤ (319 / 1000) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 54 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow57 + +theorem distillFinite_57 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 57 + distillT0 57 α + distillT1 57 α + distillT2 57 α ≤ (19157 / 21375) := by + have h0 := CriticalRow57.component0 α hα hd + have h1 := CriticalRow57.component1 α hα hd + have h2 := CriticalRow57.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_57 : ((19157 / 21375) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow58 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 58 x := by + refine (BernsteinCert.coeffs_pos + [1821508560, 50824367568, 540872531784, 2721154828536, 6536953948728, 7256622379820, + 5449797195684, 787269310384] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 58 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 58 α ≤ (119 / 500) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 58 x := by + refine (BernsteinCert.coeffs_pos + [41664682800, 1216785426624, 13873439684448, 78031956842496, 226719841156332, + 335080157464240, 250347176722068, 44095310841776] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 58 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 58 α ≤ (7 / 100) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 55 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 58 x := by + refine (BernsteinCert.coeffs_pos + [2583900, 37462500, 146596146, 123999334, 2593352] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 58 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 58 α ≤ (161 / 500) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 55 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow58 + +theorem distillFinite_58 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 58 + distillT0 58 α + distillT1 58 α + distillT2 58 α ≤ (15487 / 17400) := by + have h0 := CriticalRow58.component0 α hα hd + have h1 := CriticalRow58.component1 α hα hd + have h2 := CriticalRow58.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_58 : ((15487 / 17400) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow59 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 59 x := by + refine (BernsteinCert.coeffs_pos + [110968380, 3097674576, 32987393370, 166131741960, 399727194720, 444413638099, + 332972079154, 51356092845] + (lo := 0) (hi := 17) (s := 24137569) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 59 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 59 α ≤ (47 / 200) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 59 x := by + refine (BernsteinCert.coeffs_pos + [43878101760, 1281842733816, 14622149522664, 82303542006120, 239422006462956, + 354631625609386, 266227489250140, 48969409884870] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 59 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 59 α ≤ (63 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 56 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 59 x := by + refine (BernsteinCert.coeffs_pos + [2676240, 38841660, 152428584, 130815230, 4863630] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 59 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 59 α ≤ (81 / 250) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 56 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow59 + +theorem distillFinite_59 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 59 + distillT0 59 α + distillT1 59 α + distillT2 59 α ≤ (78047 / 88500) := by + have h0 := CriticalRow59.component0 α hα hd + have h1 := CriticalRow59.component1 α hα hd + have h2 := CriticalRow59.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_59 : ((78047 / 88500) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow60 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 60 x := by + refine (BernsteinCert.coeffs_pos + [1952553600, 54529083360, 581056856640, 2929212532080, 7058560036608, 7858526324400, + 5873005016760, 958732225320] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 60 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 60 α ≤ (231 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 60 x := by + refine (BernsteinCert.coeffs_pos + [46168444800, 1349172780480, 15397194964320, 86726707354800, 252579349974384, + 374886577459800, 282670574761680, 54030536013960] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 60 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 60 α ≤ (57 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 57 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 60 x := by + refine (BernsteinCert.coeffs_pos + [2770200, 40245660, 158372640, 137786322, 7200706] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 60 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 60 α ≤ (81 / 250) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 57 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow60 + +theorem distillFinite_60 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 60 + distillT0 60 α + distillT1 60 α + distillT2 60 α ≤ (15691 / 18000) := by + have h0 := CriticalRow60.component0 α hα hd + have h1 := CriticalRow60.component1 α hα hd + have h2 := CriticalRow60.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_60 : ((15691 / 18000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end diff --git a/Sendov/DistillationFinite/Rows5_12.lean b/Sendov/DistillationFinite/Rows5_12.lean new file mode 100644 index 0000000..c1d3474 --- /dev/null +++ b/Sendov/DistillationFinite/Rows5_12.lean @@ -0,0 +1,925 @@ +import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.BernsteinList + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow5 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (1 / 2)) : + 0 ≤ distillCritical0 5 x := by + refine (BernsteinCert.coeffs_pos + [811814400, 5668081920, 16703858880, 26817130080, 25162157184, 13647499564, 3883427188, + 428541912] + (lo := 0) (hi := (1 / 2)) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((1 / 2) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 4) (5 / 2)) : + 0 ≤ -distillCritical0 5 x := by + refine (BernsteinCert.coeffs_pos + [3667054680, 133443712440, 939063315600, 3006831250944, 5267101731840, 5254197895040, + 2819499598080, 635350144000] + (lo := (3 / 4)) (hi := (5 / 2)) (s := 117649) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (3 / 4)) ((5 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : + distillT0 5 α ≤ (101 / 500) := by + apply distillT0_le_of_critical (l := (1 / 2)) (r := (3 / 4)) (d := (5 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 0) : + 0 ≤ -distillCritical1 5 x := by + exact False.elim (lt_irrefl 0 (hx.1.trans hx.2)) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (1 / 4) (5 / 2)) : + 0 ≤ distillCritical1 5 x := by + refine (BernsteinCert.coeffs_pos + [12259473776, 1574964910352, 13907088807648, 52400775960064, 105639358896640, + 119707352275200, 72226624540160, 18128870144000] + (lo := (1 / 4)) (hi := (5 / 2)) (s := 4782969) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (1 / 4)) ((5 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : + distillT1 5 α ≤ (191 / 1000) := by + apply distillT1_le_of_critical (l := 0) (r := (1 / 4)) (d := (5 / 2)) + 2 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (1 / 2)) : + 0 ≤ -distillCritical2 5 x := by + refine (BernsteinCert.coeffs_pos + [129600, 462240, 574680, 277028, 34872] + (lo := 0) (hi := (1 / 2)) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((1 / 2) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 4) (5 / 2)) : + 0 ≤ distillCritical2 5 x := by + refine (BernsteinCert.coeffs_pos + [105732, 1927944, 6663120, 8426720, 3625600] + (lo := (3 / 4)) (hi := (5 / 2)) (s := 343) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (3 / 4)) ((5 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : + distillT2 5 α ≤ (37 / 250) := by + apply distillT2_le_of_critical (l := (1 / 2)) (r := (3 / 4)) (d := (5 / 2)) + 2 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow5 + +theorem distillFinite_5 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : + distillEBudget 5 + distillT0 5 α + distillT1 5 α + distillT2 5 α ≤ (2723 / 3000) := by + have h0 := CriticalRow5.component0 α hα hd + have h1 := CriticalRow5.component1 α hα hd + have h2 := CriticalRow5.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_5 : ((2723 / 3000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow6 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 1) : + 0 ≤ distillCritical0 6 x := by + refine (BernsteinCert.coeffs_pos + [11022480, 81636336, 251574984, 413183592, 381933576, 188980524, 39624636, 351048] + (lo := 0) (hi := 1) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (1 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 4) 3) : + 0 ≤ -distillCritical0 6 x := by + refine (BernsteinCert.coeffs_pos + [27728275200, 447127232784, 2514208985280, 7143254756352, 11535924344832, + 10802251984896, 5493577531392, 1179296464896] + (lo := (5 / 4)) (hi := 3) (s := 117649) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (5 / 4)) (3 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : + distillT0 6 α ≤ (207 / 1000) := by + apply distillT0_le_of_critical (l := 1) (r := (5 / 4)) (d := 3) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (1 / 2)) : + 0 ≤ -distillCritical1 6 x := by + refine (BernsteinCert.coeffs_pos + [2620200960, 18010708992, 51883587072, 80528401152, 71711489376, 35657006256, + 8597748720, 616902768] + (lo := 0) (hi := (1 / 2)) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((1 / 2) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 4) 3) : + 0 ≤ distillCritical1 6 x := by + refine (BernsteinCert.coeffs_pos + [15436880, 339621280, 2286850752, 7499530240, 13737961472, 14430855168, 8162164736, + 1934098432] + (lo := (3 / 4)) (hi := 3) (s := 243) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (3 / 4)) (3 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : + distillT1 6 α ≤ (171 / 1000) := by + apply distillT1_le_of_critical (l := (1 / 2)) (r := (3 / 4)) (d := 3) + 3 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 4)) : + 0 ≤ -distillCritical2 6 x := by + refine (BernsteinCert.coeffs_pos + [46080, 172800, 225184, 113320, 14740] + (lo := 0) (hi := (3 / 4)) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((3 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 1 3) : + 0 ≤ distillCritical2 6 x := by + refine (BernsteinCert.coeffs_pos + [509, 17451, 66087, 87237, 38556] + (lo := 1) (hi := 3) (s := 4) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 1) (3 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : + distillT2 6 α ≤ (133 / 1000) := by + apply distillT2_le_of_critical (l := (3 / 4)) (r := 1) (d := 3) + 3 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow6 + +theorem distillFinite_6 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : + distillEBudget 6 + distillT0 6 α + distillT1 6 α + distillT2 6 α ≤ (1931 / 2250) := by + have h0 := CriticalRow6.component0 α hα hd + have h1 := CriticalRow6.component1 α hα hd + have h2 := CriticalRow6.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_6 : ((1931 / 2250) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow7 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 4)) : + 0 ≤ distillCritical0 7 x := by + refine (BernsteinCert.coeffs_pos + [55180984320, 429810499584, 1395082082304, 2422130895360, 2386652858880, 1285853794480, + 316795014504, 15850500584] + (lo := 0) (hi := (5 / 4)) (s := 15625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((5 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 2) (7 / 2)) : + 0 ≤ -distillCritical0 7 x := by + refine (BernsteinCert.coeffs_pos + [185130279, 3942712503, 24603999183, 74279629287, 125273982333, 121470457501, + 63677088141, 14055953093] + (lo := (3 / 2)) (hi := (7 / 2)) (s := 2048) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (3 / 2)) ((7 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : + distillT0 7 α ≤ (211 / 1000) := by + apply distillT0_le_of_critical (l := (5 / 4)) (r := (3 / 2)) (d := (7 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 4)) : + 0 ≤ -distillCritical1 7 x := by + refine (BernsteinCert.coeffs_pos + [2835087360, 20677230592, 63304278016, 104741586944, 100016290304, 53990586720, + 14592870576, 1339046832] + (lo := 0) (hi := (3 / 4)) (s := 9) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((3 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 1 (7 / 2)) : + 0 ≤ distillCritical1 7 x := by + refine (BernsteinCert.coeffs_pos + [2066664192, 75283502464, 573374903552, 1998803827520, 3808983147120, 4121099547832, + 2388281187064, 578171524112] + (lo := 1) (hi := (7 / 2)) (s := 78125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 1) ((7 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : + distillT1 7 α ≤ (41 / 250) := by + apply distillT1_le_of_critical (l := (3 / 4)) (r := 1) (d := (7 / 2)) + 4 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 1) : + 0 ≤ -distillCritical2 7 x := by + refine (BernsteinCert.coeffs_pos + [22680, 89100, 121164, 63302, 8442] + (lo := 0) (hi := 1) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (1 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 4) (7 / 2)) : + 0 ≤ distillCritical2 7 x := by + refine (BernsteinCert.coeffs_pos + [30220, 22660840, 94130736, 129223648, 58484608] + (lo := (5 / 4)) (hi := (7 / 2)) (s := 6561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (5 / 4)) ((7 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : + distillT2 7 α ≤ (31 / 250) := by + apply distillT2_le_of_critical (l := 1) (r := (5 / 4)) (d := (7 / 2)) + 4 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow7 + +theorem distillFinite_7 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : + distillEBudget 7 + distillT0 7 α + distillT1 7 α + distillT2 7 α ≤ (2497 / 3000) := by + have h0 := CriticalRow7.component0 α hα hd + have h1 := CriticalRow7.component1 α hα hd + have h2 := CriticalRow7.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_7 : ((2497 / 3000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow8 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 2)) : + 0 ≤ distillCritical0 8 x := by + refine (BernsteinCert.coeffs_pos + [12533760, 102137856, 346844160, 630770688, 653415296, 373756864, 100918592, 7008816] + (lo := 0) (hi := (3 / 2)) (s := 9) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((3 / 2) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 4) 4) : + 0 ≤ -distillCritical0 8 x := by + refine (BernsteinCert.coeffs_pos + [131996352688, 4881726753664, 34523100938496, 110994170240000, 195224673419264, + 195581035905024, 105431361912832, 23874173403136] + (lo := (7 / 4)) (hi := 4) (s := 4782969) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (7 / 4)) (4 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : + distillT0 8 α ≤ (43 / 200) := by + apply distillT0_le_of_critical (l := (3 / 2)) (r := (7 / 4)) (d := 4) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 4)) : + 0 ≤ -distillCritical1 8 x := by + refine (BernsteinCert.coeffs_pos + [236967690240, 1859867246592, 6063769976832, 10513297428480, 10225272023040, + 5291040062720, 1138498333952, 151036272] + (lo := 0) (hi := (5 / 4)) (s := 15625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((5 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 2) 4) : + 0 ≤ distillCritical1 8 x := by + refine (BernsteinCert.coeffs_pos + [11560412016, 226336332672, 1443916812096, 4557986760960, 8092194965760, 8270382964736, + 4563174377472, 1056901758976] + (lo := (3 / 2)) (hi := 4) (s := 78125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (3 / 2)) (4 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : + distillT1 8 α ≤ (157 / 1000) := by + apply distillT1_le_of_critical (l := (5 / 4)) (r := (3 / 2)) (d := 4) + 5 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 2)) : + 0 ≤ -distillCritical2 8 x := by + refine (BernsteinCert.coeffs_pos + [19200, 79200, 108352, 50572, 1872] + (lo := 0) (hi := (3 / 2)) (s := 3) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((3 / 2) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 4) 4) : + 0 ≤ distillCritical2 8 x := by + refine (BernsteinCert.coeffs_pos + [2692492, 45996184, 156390144, 195703552, 83378176] + (lo := (7 / 4)) (hi := 4) (s := 6561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (7 / 4)) (4 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : + distillT2 8 α ≤ (3 / 25) := by + apply distillT2_le_of_critical (l := (3 / 2)) (r := (7 / 4)) (d := 4) + 5 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow8 + +theorem distillFinite_8 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : + distillEBudget 8 + distillT0 8 α + distillT1 8 α + distillT2 8 α ≤ (9779 / 12000) := by + have h0 := CriticalRow8.component0 α hα hd + have h1 := CriticalRow8.component1 α hα hd + have h2 := CriticalRow8.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_8 : ((9779 / 12000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow9 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 2) : + 0 ≤ distillCritical0 9 x := by + refine (BernsteinCert.coeffs_pos + [7971615, 69435063, 250050645, 477017505, 509326785, 289489977, 68863707, 136575] + (lo := 0) (hi := 2) (s := 32) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (2 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 4) (9 / 2)) : + 0 ≤ -distillCritical0 9 x := by + refine (BernsteinCert.coeffs_pos + [11570504, 209153320, 1234367760, 3614356480, 5971193600, 5699726976, 2949468416, + 643701760] + (lo := (9 / 4)) (hi := (9 / 2)) (s := 81) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (9 / 4)) ((9 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : + distillT0 9 α ≤ (11 / 50) := by + apply distillT0_le_of_critical (l := 2) (r := (9 / 4)) (d := (9 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 2)) : + 0 ≤ -distillCritical1 9 x := by + refine (BernsteinCert.coeffs_pos + [6589440, 54425088, 187067136, 343290240, 356562864, 201589656, 51591048, 2494368] + (lo := 0) (hi := (3 / 2)) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((3 / 2) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 4) (9 / 2)) : + 0 ≤ distillCritical1 9 x := by + refine (BernsteinCert.coeffs_pos + [1374449339568, 38263679796816, 271470993332256, 906577981337088, 1671400180482048, + 1758235947404544, 993743949795840, 235128973547520] + (lo := (7 / 4)) (hi := (9 / 2)) (s := 19487171) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (7 / 4)) ((9 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : + distillT1 9 α ≤ (39 / 250) := by + apply distillT1_le_of_critical (l := (3 / 2)) (r := (7 / 4)) (d := (9 / 2)) + 6 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (7 / 4)) : + 0 ≤ -distillCritical2 9 x := by + refine (BernsteinCert.coeffs_pos + [11197440, 48418560, 69561504, 34697496, 2078596] + (lo := 0) (hi := (7 / 4)) (s := 2401) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((7 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 2 (9 / 2)) : + 0 ≤ distillCritical2 9 x := by + refine (BernsteinCert.coeffs_pos + [26944, 697056, 2548584, 3304476, 1440504] + (lo := 2) (hi := (9 / 2)) (s := 125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 2) ((9 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : + distillT2 9 α ≤ (3 / 25) := by + apply distillT2_le_of_critical (l := (7 / 4)) (r := 2) (d := (9 / 2)) + 6 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow9 + +theorem distillFinite_9 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : + distillEBudget 9 + distillT0 9 α + distillT1 9 α + distillT2 9 α ≤ (5473 / 6750) := by + have h0 := CriticalRow9.component0 α hα hd + have h1 := CriticalRow9.component1 α hα hd + have h2 := CriticalRow9.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_9 : ((5473 / 6750) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow10 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 4)) : + 0 ≤ distillCritical0 10 x := by + refine (BernsteinCert.coeffs_pos + [308019200, 2792488960, 10463846400, 20790661120, 23214035456, 13974554304, 3705586832, + 124650592] + (lo := 0) (hi := (9 / 4)) (s := 2187) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((9 / 4) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 2) 5) : + 0 ≤ -distillCritical0 10 x := by + refine (BernsteinCert.coeffs_pos + [182040744, 4514878184, 29445832240, 91088481280, 156343349760, 153833492864, + 81724139264, 18271559680] + (lo := (5 / 2)) (hi := 5) (s := 3125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (5 / 2)) (5 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : + distillT0 10 α ≤ (9 / 40) := by + apply distillT0_le_of_critical (l := (9 / 4)) (r := (5 / 2)) (d := 5) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (7 / 4)) : + 0 ≤ -distillCritical1 10 x := by + refine (BernsteinCert.coeffs_pos + [2689774387200, 23258320404480, 83729139056640, 161196037632000, 176396717043456, + 106236383011136, 30027750193952, 2142322286928] + (lo := 0) (hi := (7 / 4)) (s := 823543) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((7 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 2 5) : + 0 ≤ distillCritical1 10 x := by + refine (BernsteinCert.coeffs_pos + [40230640, 2861489920, 23278100160, 82664174816, 158331459260, 171293951280, + 99052779220, 23910352000] + (lo := 2) (hi := 5) (s := 2187) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 2) (5 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : + distillT1 10 α ≤ (31 / 200) := by + apply distillT1_le_of_critical (l := (7 / 4)) (r := 2) (d := 5) + 7 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 2) : + 0 ≤ -distillCritical2 10 x := by + refine (BernsteinCert.coeffs_pos + [14175, 63990, 95910, 50338, 3779] + (lo := 0) (hi := 2) (s := 4) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (2 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 4) 5) : + 0 ≤ distillCritical2 10 x := by + refine (BernsteinCert.coeffs_pos + [1173852, 66240936, 260405760, 348878720, 155238400] + (lo := (9 / 4)) (hi := 5) (s := 14641) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (9 / 4)) (5 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : + distillT2 10 α ≤ (121 / 1000) := by + apply distillT2_le_of_critical (l := 2) (r := (9 / 4)) (d := 5) + 7 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow10 + +theorem distillFinite_10 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : + distillEBudget 10 + distillT0 10 α + distillT1 10 α + distillT2 10 α ≤ (607 / 750) := by + have h0 := CriticalRow10.component0 α hα hd + have h1 := CriticalRow10.component1 α hα hd + have h2 := CriticalRow10.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_10 : ((607 / 750) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow11 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 2)) : + 0 ≤ distillCritical0 11 x := by + refine (BernsteinCert.coeffs_pos + [1317938688, 12405208320, 48218991552, 99377007840, 115329236160, 72721372108, + 20810300940, 1107629072] + (lo := 0) (hi := (5 / 2)) (s := 15625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((5 / 2) - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 4) (11 / 2)) : + 0 ≤ -distillCritical0 11 x := by + refine (BernsteinCert.coeffs_pos + [29860506888, 1465779690856, 10785194353424, 35335858883840, 62967110431488, + 63771092294272, 34722916282624, 7939748744192] + (lo := (11 / 4)) (hi := (11 / 2)) (s := 1771561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (11 / 4)) ((11 / 2) - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : + distillT0 11 α ≤ (229 / 1000) := by + apply distillT0_le_of_critical (l := (5 / 2)) (r := (11 / 4)) (d := (11 / 2)) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 4)) : + 0 ≤ -distillCritical1 11 x := by + refine (BernsteinCert.coeffs_pos + [5132779520, 47598501888, 182637846528, 371577997312, 423824972544, 258668567520, + 67881102032, 1540304784] + (lo := 0) (hi := (9 / 4)) (s := 6561) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((9 / 4) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 2) (11 / 2)) : + 0 ≤ distillCritical1 11 x := by + refine (BernsteinCert.coeffs_pos + [2269541230, 57025527163, 390064523178, 1270709939423, 2295683591354, 2372211292089, + 1319106854830, 307421296237] + (lo := (5 / 2)) (hi := (11 / 2)) (s := 17496) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (5 / 2)) ((11 / 2) - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : + distillT1 11 α ≤ (77 / 500) := by + apply distillT1_le_of_critical (l := (9 / 4)) (r := (5 / 2)) (d := (11 / 2)) + 8 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 2)) : + 0 ≤ -distillCritical2 11 x := by + refine (BernsteinCert.coeffs_pos + [228096, 1089504, 1679856, 837284, 4336] + (lo := 0) (hi := (5 / 2)) (s := 125) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((5 / 2) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 4) (11 / 2)) : + 0 ≤ distillCritical2 11 x := by + refine (BernsteinCert.coeffs_pos + [625044, 10403560, 35152848, 43822560, 18602624] + (lo := (11 / 4)) (hi := (11 / 2)) (s := 1331) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (11 / 4)) ((11 / 2) - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : + distillT2 11 α ≤ (61 / 500) := by + apply distillT2_le_of_critical (l := (5 / 2)) (r := (11 / 4)) (d := (11 / 2)) + 8 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow11 + +theorem distillFinite_11 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : + distillEBudget 11 + distillT0 11 α + distillT1 11 α + distillT2 11 α ≤ (5333 / 6600) := by + have h0 := CriticalRow11.component0 α hα hd + have h1 := CriticalRow11.component1 α hα hd + have h2 := CriticalRow11.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_11 : ((5333 / 6600) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow12 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 3) : + 0 ≤ distillCritical0 12 x := by + refine (BernsteinCert.coeffs_pos + [28800, 288096, 1182528, 2552496, 3066304, 1958832, 529928, 3960] + (lo := 0) (hi := 3) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (3 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 4) 6) : + 0 ≤ -distillCritical0 12 x := by + refine (BernsteinCert.coeffs_pos + [1664241508272, 35159330460576, 219174632642304, 662380928815104, 1119724972978176, + 1089345607925760, 573425787469824, 127185145823232] + (lo := (13 / 4)) (hi := 6) (s := 19487171) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (13 / 4)) (6 - x) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : + distillT0 12 α ≤ (47 / 200) := by + apply distillT0_le_of_critical (l := 3) (r := (13 / 4)) (d := 6) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 2)) : + 0 ≤ -distillCritical1 12 x := by + refine (BernsteinCert.coeffs_pos + [7847165952, 75733512192, 302446586880, 641197866240, 765023287680, 493871716512, + 142955512032, 7230207600] + (lo := 0) (hi := (5 / 2)) (s := 15625) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((5 / 2) - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 4) 6) : + 0 ≤ distillCritical1 12 x := by + refine (BernsteinCert.coeffs_pos + [2764968101040, 136428974431296, 1056344227288704, 3646711898413056, 6834600949616640, + 7257719142088704, 4127070189256704, 980881124622336] + (lo := (11 / 4)) (hi := 6) (s := 62748517) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - (11 / 4)) (6 - x) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : + distillT1 12 α ≤ (31 / 200) := by + apply distillT1_le_of_critical (l := (5 / 2)) (r := (11 / 4)) (d := 6) + 9 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (11 / 4)) : + 0 ≤ -distillCritical2 12 x := by + refine (BernsteinCert.coeffs_pos + [22394880, 111248640, 178398144, 93750984, 2508244] + (lo := 0) (hi := (11 / 4)) (s := 14641) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) ((11 / 4) - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 3 6) : + 0 ≤ distillCritical2 12 x := by + refine (BernsteinCert.coeffs_pos + [282, 6406, 22972, 29500, 12768] + (lo := 3) (hi := 6) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 3) (6 - x) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : + distillT2 12 α ≤ (1 / 8) := by + apply distillT2_le_of_critical (l := (11 / 4)) (r := 3) (d := 6) + 9 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow12 + +theorem distillFinite_12 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : + distillEBudget 12 + distillT0 12 α + distillT1 12 α + distillT2 12 α ≤ (2929 / 3600) := by + have h0 := CriticalRow12.component0 α hα hd + have h1 := CriticalRow12.component1 α hα hd + have h2 := CriticalRow12.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_12 : ((2929 / 3600) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end diff --git a/Sendov/DistillationFinite/Rows61_68.lean b/Sendov/DistillationFinite/Rows61_68.lean new file mode 100644 index 0000000..88e85a3 --- /dev/null +++ b/Sendov/DistillationFinite/Rows61_68.lean @@ -0,0 +1,754 @@ +import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.BernsteinList + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow61 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 61 x := by + refine (BernsteinCert.coeffs_pos + [2019781980, 56430214272, 601686039834, 3036073584816, 7326547127832, 8167105809971, + 6087236209110, 1044305251249] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 61 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 61 α ≤ (57 / 250) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 61 x := by + refine (BernsteinCert.coeffs_pos + [48537024120, 1418814495216, 16199029223856, 91304072373456, 266199727275870, + 395856838633324, 299684953990290, 59281036043180] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 61 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 61 α ≤ (13 / 250) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 58 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 61 x := by + refine (BernsteinCert.coeffs_pos + [2865780, 41674500, 164428314, 144912610, 9604580] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 61 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 61 α ≤ (81 / 250) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 58 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow61 + +theorem distillFinite_61 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 61 + distillT0 61 α + distillT1 61 α + distillT2 61 α ≤ (19754 / 22875) := by + have h0 := CriticalRow61.component0 α hα hd + have h1 := CriticalRow61.component1 α hα hd + have h2 := CriticalRow61.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_61 : ((19754 / 22875) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow62 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 62 x := by + refine (BernsteinCert.coeffs_pos + [2088147600, 58363860528, 622673236872, 3144822771528, 7599323583912, 8480770304396, + 6303218922668, 1129772656152] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 62 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 62 α ≤ (28 / 125) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 62 x := by + refine (BernsteinCert.coeffs_pos + [50985151920, 1490806806624, 17028105515712, 96038256547008, 280290993952668, + 417554234747800, 317279147669572, 64723256786664] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 62 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 62 α ≤ (23 / 500) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 59 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 62 x := by + refine (BernsteinCert.coeffs_pos + [2962980, 43128180, 170595606, 152194094, 12075252] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 62 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 62 α ≤ (323 / 1000) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 59 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow62 + +theorem distillFinite_62 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 62 + distillT0 62 α + distillT1 62 α + distillT2 62 α ≤ (39637 / 46500) := by + have h0 := CriticalRow62.component0 α hα hd + have h1 := CriticalRow62.component1 α hα hd + have h2 := CriticalRow62.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_62 : ((39637 / 46500) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow63 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 63 x := by + refine (BernsteinCert.coeffs_pos + [2157650460, 60330022128, 644018447754, 3255460092216, 7876889404848, 8799519807675, + 6520953157434, 1215134440029] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 63 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 63 α ≤ (221 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 63 x := by + refine (BernsteinCert.coeffs_pos + [53514140400, 1565188643304, 17884877054328, 100931879360376, 294861005590032, + 439990591421070, 335461676533128, 70359545058546] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 63 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 63 α ≤ (41 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 60 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 63 x := by + refine (BernsteinCert.coeffs_pos + [3061800, 44606700, 176874516, 159630774, 14612722] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 63 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 63 α ≤ (8 / 25) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 60 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow63 + +theorem distillFinite_63 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 63 + distillT0 63 α + distillT1 63 α + distillT2 63 α ≤ (11357 / 13500) := by + have h0 := CriticalRow63.component0 α hα hd + have h1 := CriticalRow63.component1 α hα hd + have h2 := CriticalRow63.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_63 : ((11357 / 13500) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow64 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 64 x := by + refine (BernsteinCert.coeffs_pos + [2228290560, 62328699072, 665721672480, 3367985546880, 8159244590640, 9123354319808, + 6740438913408, 1300390602880] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 64 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 64 α ≤ (217 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 64 x := by + refine (BernsteinCert.coeffs_pos + [56125301760, 1641998933856, 18769797054144, 105987560298480, 309917617773216, + 463177734270976, 354241061314560, 76192247672960] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 64 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 64 α ≤ (37 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 61 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 64 x := by + refine (BernsteinCert.coeffs_pos + [3162240, 46110060, 183265044, 167222650, 17216990] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 64 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 64 α ≤ (317 / 1000) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 61 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow64 + +theorem distillFinite_64 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 64 + distillT0 64 α + distillT1 64 α + distillT2 64 α ≤ (79691 / 96000) := by + have h0 := CriticalRow64.component0 α hα hd + have h1 := CriticalRow64.component1 α hα hd + have h2 := CriticalRow64.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_64 : ((79691 / 96000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow65 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 65 x := by + refine (BernsteinCert.coeffs_pos + [2300067900, 64359891360, 687782911050, 3482399135520, 8446389141288, 9452273840795, + 6961676190590, 1385541144705] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 65 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 65 α ≤ (107 / 500) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 65 x := by + refine (BernsteinCert.coeffs_pos + [58819948200, 1721276606880, 19683318729600, 111207918846240, 325468686087474, + 487127488915360, 373625822747470, 82223711444040] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 65 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 65 α ≤ (33 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 62 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 65 x := by + refine (BernsteinCert.coeffs_pos + [3264300, 47638260, 189767190, 174969722, 19888056] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 65 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 65 α ≤ (313 / 1000) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 62 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow65 + +theorem distillFinite_65 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 65 + distillT0 65 α + distillT1 65 α + distillT2 65 α ≤ (1597 / 1950) := by + have h0 := CriticalRow65.component0 α hα hd + have h1 := CriticalRow65.component1 α hα hd + have h2 := CriticalRow65.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_65 : ((1597 / 1950) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow66 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 66 x := by + refine (BernsteinCert.coeffs_pos + [2372982480, 66423598992, 710202163464, 3598700858136, 8738323056792, 9786278370636, + 7184664988980, 1470586065504] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 66 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 66 α ≤ (211 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 66 x := by + refine (BernsteinCert.coeffs_pos + [61599391920, 1803060590976, 20625895295136, 116595574488576, 341522066118060, + 511851680972064, 393624481565460, 88456283185920] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 66 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 66 α ≤ (29 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 63 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 66 x := by + refine (BernsteinCert.coeffs_pos + [3367980, 49191300, 196380954, 182871990, 22625920] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 66 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 66 α ≤ (309 / 1000) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 63 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow66 + +theorem distillFinite_66 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 66 + distillT0 66 α + distillT1 66 α + distillT2 66 α ≤ (9997 / 12375) := by + have h0 := CriticalRow66.component0 α hα hd + have h1 := CriticalRow66.component1 α hα hd + have h2 := CriticalRow66.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_66 : ((9997 / 12375) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow67 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 67 x := by + refine (BernsteinCert.coeffs_pos + [2447034300, 68519821968, 732979429722, 3716890714728, 9035046337152, 10125367909331, + 7409405308578, 1555525365277] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 67 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 67 α ≤ (26 / 125) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 67 x := by + refine (BernsteinCert.coeffs_pos + [64464945120, 1887389814744, 21597979965192, 122153146710408, 358085613450228, + 537362136058930, 414245558502132, 94892309712734] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 67 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 67 α ≤ (13 / 500) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 64 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 67 x := by + refine (BernsteinCert.coeffs_pos + [3473280, 50769180, 203106336, 190929454, 25430582] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 67 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 67 α ≤ (303 / 1000) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 64 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow67 + +theorem distillFinite_67 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 67 + distillT0 67 α + distillT1 67 α + distillT2 67 α ≤ (159937 / 201000) := by + have h0 := CriticalRow67.component0 α hα hd + have h1 := CriticalRow67.component1 α hα hd + have h2 := CriticalRow67.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_67 : ((159937 / 201000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow68 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 68 x := by + refine (BernsteinCert.coeffs_pos + [148366080, 4155797664, 44477335872, 225704041488, 549209351904, 615855438640, + 449170420552, 96491708472] + (lo := 0) (hi := 17) (s := 24137569) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 68 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 68 α ≤ (51 / 250) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 68 x := by + refine (BernsteinCert.coeffs_pos + [3965760000, 116135482752, 1329413291424, 7522544411568, 22068657862896, 33157098811400, + 25617504370064, 5972596343448] + (lo := 0) (hi := 17) (s := 24137569) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 68 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 68 α ≤ (23 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 65 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 68 x := by + refine (BernsteinCert.coeffs_pos + [210600, 3080700, 12349608, 11714242, 1664826] + (lo := 0) (hi := 17) (s := 4913) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 68 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 68 α ≤ (149 / 500) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 65 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow68 + +theorem distillFinite_68 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 68 + distillT0 68 α + distillT1 68 α + distillT2 68 α ≤ (3197 / 4080) := by + have h0 := CriticalRow68.component0 α hα hd + have h1 := CriticalRow68.component1 α hα hd + have h2 := CriticalRow68.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_68 : ((3197 / 4080) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end diff --git a/Sendov/DistillationFinite/Rows69_76.lean b/Sendov/DistillationFinite/Rows69_76.lean new file mode 100644 index 0000000..794b53c --- /dev/null +++ b/Sendov/DistillationFinite/Rows69_76.lean @@ -0,0 +1,754 @@ +import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.BernsteinList + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow69 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 69 x := by + refine (BernsteinCert.coeffs_pos + [2598549660, 72809813952, 779608003770, 3958934829840, 9642860992440, 10818802013283, + 7864140511398, 1725087101745] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 69 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 69 α ≤ (201 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 69 x := by + refine (BernsteinCert.coeffs_pos + [70459628760, 2063839695696, 23632486476624, 133788518832240, 392774632360326, + 590789137794516, 457389049665930, 108384114377700] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 69 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 69 α ≤ (1 / 50) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 66 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 69 x := by + refine (BernsteinCert.coeffs_pos + [3688740, 53999460, 216891954, 207509970, 31240300] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 69 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 69 α ≤ (73 / 250) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 66 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow69 + +theorem distillFinite_69 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 69 + distillT0 69 α + distillT1 69 α + distillT2 69 α ≤ (159691 / 207000) := by + have h0 := CriticalRow69.component0 α hα hd + have h1 := CriticalRow69.component1 α hα hd + have h2 := CriticalRow69.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_69 : ((159691 / 207000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow70 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 70 x := by + refine (BernsteinCert.coeffs_pos + [2676013200, 75003582960, 803459311560, 4082789088360, 9953952367368, 11173146578540, + 8094135394620, 1809709538440] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 70 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 70 α ≤ (99 / 500) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 70 x := by + refine (BernsteinCert.coeffs_pos + [73591383600, 2156038210080, 24695814746880, 139871557702080, 410915815108764, + 618729335678920, 479928505360260, 115444586144120] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 70 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 70 α ≤ (9 / 500) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 67 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 70 x := by + refine (BernsteinCert.coeffs_pos + [3798900, 55651860, 223952190, 216033022, 34245356] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 70 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 70 α ≤ (57 / 200) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 67 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow70 + +theorem distillFinite_70 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 70 + distillT0 70 α + distillT1 70 α + distillT2 70 α ≤ (1139 / 1500) := by + have h0 := CriticalRow70.component0 α hα hd + have h1 := CriticalRow70.component1 α hα hd + have h2 := CriticalRow70.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_70 : ((1139 / 1500) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow71 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 71 x := by + refine (BernsteinCert.coeffs_pos + [2754613980, 77229867312, 827668633194, 4208531480856, 10269833107152, 11532576152651, + 8325881799050, 1894226354109] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 71 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 71 α ≤ (39 / 200) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 71 x := by + refine (BernsteinCert.coeffs_pos + [76814496720, 2250937678536, 25790463979416, 146134991091096, 429598587499800, + 647503099064854, 503124462107680, 122717899952010] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 71 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 71 α ≤ (2 / 125) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 68 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 71 x := by + refine (BernsteinCert.coeffs_pos + [230040, 3372300, 13595532, 13218310, 2195130] + (lo := 0) (hi := 17) (s := 4913) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 71 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 71 α ≤ (139 / 500) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 68 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow71 + +theorem distillFinite_71 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 71 + distillT0 71 α + distillT1 71 α + distillT2 71 α ≤ (159157 / 213000) := by + have h0 := CriticalRow71.component0 α hα hd + have h1 := CriticalRow71.component1 α hα hd + have h2 := CriticalRow71.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_71 : ((159157 / 213000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow72 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 72 x := by + refine (BernsteinCert.coeffs_pos + [2834352000, 79488667008, 852235968672, 4336162007328, 10590503211792, 11897090735616, + 8559379724688, 1978637548752] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 72 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 72 α ≤ (24 / 125) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 72 x := by + refine (BernsteinCert.coeffs_pos + [80130280320, 2348577029664, 26916887388672, 152581438484208, 448830805118688, + 677122253570160, 526985440641792, 130206402615504] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 72 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 72 α ≤ (7 / 500) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 69 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 72 x := by + refine (BernsteinCert.coeffs_pos + [4024080, 59031180, 238407516, 233544714, 40455862] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 72 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 72 α ≤ (271 / 1000) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 69 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow72 + +theorem distillFinite_72 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 72 + distillT0 72 α + distillT1 72 α + distillT2 72 α ≤ (79391 / 108000) := by + have h0 := CriticalRow72.component0 α hα hd + have h1 := CriticalRow72.component1 α hα hd + have h2 := CriticalRow72.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_72 : ((79391 / 108000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow73 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 73 x := by + refine (BernsteinCert.coeffs_pos + [2915227260, 81779982048, 877161317994, 4465680667776, 10915962681288, 12266690327435, + 8794629171534, 2062943122369] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 73 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 73 α ≤ (189 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 73 x := by + refine (BernsteinCert.coeffs_pos + [83540046600, 2448995192064, 28075538189088, 159213519366336, 468620323550682, + 707598624812680, 551519961696198, 137912440948736] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 73 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 73 α ≤ (3 / 250) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 70 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 73 x := by + refine (BernsteinCert.coeffs_pos + [4139100, 60758100, 245802606, 242533354, 43661312] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 73 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 73 α ≤ (33 / 125) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 70 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow73 + +theorem distillFinite_73 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 73 + distillT0 73 α + distillT1 73 α + distillT2 73 α ≤ (31667 / 43800) := by + have h0 := CriticalRow73.component0 α hα hd + have h1 := CriticalRow73.component1 α hα hd + have h2 := CriticalRow73.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_73 : ((31667 / 43800) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow74 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 74 x := by + refine (BernsteinCert.coeffs_pos + [2997239760, 84103812432, 902444681160, 4597087462200, 11246211515640, 12641374928108, + 9031630139588, 2147143074960] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 74 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 74 α ≤ (187 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 74 x := by + refine (BernsteinCert.coeffs_pos + [87045107760, 2552231094336, 29266869595104, 166033853222400, 488974998381036, + 738944038410256, 576736546004500, 145838361765840] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 74 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 74 α ≤ (11 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 71 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 74 x := by + refine (BernsteinCert.coeffs_pos + [4255740, 62509860, 253309314, 251677190, 46933560] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 74 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 74 α ≤ (32 / 125) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 71 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow74 + +theorem distillFinite_74 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 74 + distillT0 74 α + distillT1 74 α + distillT2 74 α ≤ (79019 / 111000) := by + have h0 := CriticalRow74.component0 α hα hd + have h1 := CriticalRow74.component1 α hα hd + have h2 := CriticalRow74.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_74 : ((79019 / 111000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow75 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 75 x := by + refine (BernsteinCert.coeffs_pos + [3080389500, 86460158160, 928086058170, 4730382390600, 11581249714848, 13021144537635, + 9270382628850, 2231237406525] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 75 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 75 α ≤ (23 / 125) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 75 x := by + refine (BernsteinCert.coeffs_pos + [90646776000, 2658323665080, 30491334821160, 173045059537320, 509902685195004, + 771170319980730, 602643714300300, 153986511880950] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 75 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 75 α ≤ (9 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 72 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 75 x := by + refine (BernsteinCert.coeffs_pos + [4374000, 64286460, 260927640, 260976222, 50272606] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 75 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 75 α ≤ (31 / 125) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 72 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow75 + +theorem distillFinite_75 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 75 + distillT0 75 α + distillT1 75 α + distillT2 75 α ≤ (6289 / 9000) := by + have h0 := CriticalRow75.component0 α hα hd + have h1 := CriticalRow75.component1 α hα hd + have h2 := CriticalRow75.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_75 : ((6289 / 9000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow76 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 76 x := by + refine (BernsteinCert.coeffs_pos + [186157440, 5226412896, 56122673472, 286209732528, 701239839936, 788588185648, + 559463919960, 136189771592] + (lo := 0) (hi := 17) (s := 24137569) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 76 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 76 α ≤ (181 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 76 x := by + refine (BernsteinCert.coeffs_pos + [94346363520, 2767311832896, 31749387081696, 180249757796016, 531411239577840, + 804289295141944, 629249987317200, 162359238108200] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 76 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 76 α ≤ (1 / 125) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 73 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 76 x := by + refine (BernsteinCert.coeffs_pos + [4493880, 66087900, 268657584, 270430450, 53678450] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 76 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 76 α ≤ (241 / 1000) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 73 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow76 + +theorem distillFinite_76 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 76 + distillT0 76 α + distillT1 76 α + distillT2 76 α ≤ (15679 / 22800) := by + have h0 := CriticalRow76.component0 α hα hd + have h1 := CriticalRow76.component1 α hα hd + have h2 := CriticalRow76.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_76 : ((15679 / 22800) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end diff --git a/Sendov/DistillationFinite/Rows77_80.lean b/Sendov/DistillationFinite/Rows77_80.lean new file mode 100644 index 0000000..e831e2c --- /dev/null +++ b/Sendov/DistillationFinite/Rows77_80.lean @@ -0,0 +1,378 @@ +import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.BernsteinList + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow77 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 77 x := by + refine (BernsteinCert.coeffs_pos + [3250100700, 91270395648, 980442853722, 5002636649328, 12265694207832, 13795938783251, + 9753142170998, 2399109206577] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 77 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 77 α ≤ (179 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 77 x := by + refine (BernsteinCert.coeffs_pos + [98145182520, 2879234526384, 33041479591152, 187650567483408, 553508517114798, + 838312789511740, 656563885788802, 170958887261724] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 77 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 77 α ≤ (7 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 74 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 77 x := by + refine (BernsteinCert.coeffs_pos + [4615380, 67914180, 276499146, 280039874, 57151092] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 77 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 77 α ≤ (233 / 1000) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 74 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow77 + +theorem distillFinite_77 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 77 + distillT0 77 α + distillT1 77 α + distillT2 77 α ≤ (22327 / 33000) := by + have h0 := CriticalRow77.component0 α hα hd + have h1 := CriticalRow77.component1 α hα hd + have h2 := CriticalRow77.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_77 : ((22327 / 33000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow78 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 78 x := by + refine (BernsteinCert.coeffs_pos + [3336662160, 93724287408, 1007158272264, 5141595979656, 12615100501608, 14190963419340, + 9997149223884, 2482886675064] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 78 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 78 α ≤ (22 / 125) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 78 x := by + refine (BernsteinCert.coeffs_pos + [102044545200, 2994130674144, 34368065563968, 195250108084416, 576202373391132, + 873252628707960, 684593930448708, 179787806155656] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 78 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 78 α ≤ (3 / 500) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 75 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 78 x := by + refine (BernsteinCert.coeffs_pos + [4738500, 69765300, 284452326, 289804494, 60690532] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 78 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 78 α ≤ (9 / 40) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 75 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow78 + +theorem distillFinite_78 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 78 + distillT0 78 α + distillT1 78 α + distillT2 78 α ≤ (9718 / 14625) := by + have h0 := CriticalRow78.component0 α hα hd + have h1 := CriticalRow78.component1 α hα hd + have h2 := CriticalRow78.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_78 : ((9718 / 14625) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow79 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 79 x := by + refine (BernsteinCert.coeffs_pos + [3424360860, 96210694512, 1034231704650, 5282443443960, 12969296160240, 14591073064283, + 10242907797978, 2566558522525] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 79 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 79 α ≤ (87 / 500) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 79 x := by + refine (BernsteinCert.coeffs_pos + [106045763760, 3112039204776, 35729598214584, 203050999083960, 599500663992096, + 909120638348446, 713348642030520, 188848341604130] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 79 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 79 α ≤ (3 / 500) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 76 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 79 x := by + refine (BernsteinCert.coeffs_pos + [4863240, 71641260, 292517124, 299724310, 64296770] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 79 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 79 α ≤ (217 / 1000) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 76 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow79 + +theorem distillFinite_79 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 79 + distillT0 79 α + distillT1 79 α + distillT2 79 α ≤ (155089 / 237000) := by + have h0 := CriticalRow79.component0 α hα hd + have h1 := CriticalRow79.component1 α hα hd + have h2 := CriticalRow79.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_79 : ((155089 / 237000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow80 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 80 x := by + refine (BernsteinCert.coeffs_pos + [3513196800, 98729616960, 1061663150880, 5425179042240, 13328281183728, 14996267718080, + 10490417893280, 2650124748960] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 80 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 80 α ≤ (171 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 80 x := by + refine (BernsteinCert.coeffs_pos + [110150150400, 3232999046880, 37126530757440, 211055859966960, 623411244502944, + 945928644051040, 742836541267840, 198142840421280] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 80 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 80 α ≤ (1 / 200) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 77 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 80 x := by + refine (BernsteinCert.coeffs_pos + [4989600, 73542060, 300693540, 309799322, 67969806] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - 0) (17 - x) + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 80 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 80 α ≤ (209 / 1000) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 77 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow80 + +theorem distillFinite_80 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 80 + distillT0 80 α + distillT1 80 α + distillT2 80 α ≤ (3083 / 4800) := by + have h0 := CriticalRow80.component0 α hα hd + have h1 := CriticalRow80.component1 α hα hd + have h2 := CriticalRow80.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_80 : ((3083 / 4800) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end diff --git a/Sendov/FiniteRange/Batch.lean b/Sendov/FiniteRange/Batch.lean deleted file mode 100644 index bcd824c..0000000 --- a/Sendov/FiniteRange/Batch.lean +++ /dev/null @@ -1,188 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.Common.Rpow - -/-! -# Batching adjacent degrees - -Every term of `Sendov.R` is monotone in `n`, and the directions cooperate: the elementary -part decreases, the prefactor increases, and the moment decreases. So for a whole range of -degrees `n₀ ≤ n ≤ n₁` one bound suffices, - - `R n α ≤ base n₀ α + pref n₁ α * I n₀ α`, - -needing one moment and one certificate for the batch rather than one per degree. - -The key identity is - - `Q (n+1) α t = Q n α t - (2α / (n(n-1))) * t * (1-t)`, - -so `Q` decreases with `n` on `[0,1]`; combined with `Q ≤ 1` and the exponent `(n-4)/2` -increasing, the moment decreases too. - -This pays most where it costs most. Batch sizes track the slack in `R n α`, which is -smallest near its maximum at `n = 53` and grows away from it, so the expensive high degrees -batch into the largest groups: measured, `n ∈ [62,97]` costs 12.5× less batched, against 2.8× -in the tight middle. Note also that the certificate's degree is set by `n₀`, the *smallest* -member, so a batch is cheaper than any single degree it covers except the first. - -## Main statements - -* `Sendov.Q_succ_sub`: the identity above; -* `Sendov.Q_anti`: `Q` decreases with `n` on `[0,1]`; -* `Sendov.A_mono`: `A` increases with `n`. --/ - -namespace Sendov - -variable {α t : ℝ} - -lemma M_mono {m n : ℕ} (h : m ≤ n) : M m ≤ M n := by - exact sub_le_sub_right (Nat.cast_le.2 h) 1 - -/-- `A` increases with `n`: raising the degree moves `a²` towards `1`. -/ -lemma A_mono {m n : ℕ} (hm : 2 ≤ m) (h : m ≤ n) (hα : 0 ≤ α) : A m α ≤ A n α := by - have hMm : 0 < M m := M_pos hm - have hMn : 0 < M n := lt_of_lt_of_le hMm (M_mono h) - simp only [A] - have : 2 * α / M n ≤ 2 * α / M m := - div_le_div_of_nonneg_left (by linarith) hMm (M_mono h) - linarith - -/-- **The degree step.** Raising `n` by one lowers `Q` by a multiple of `t(1-t)`. -/ -lemma Q_succ_sub (n : ℕ) (hn : 2 ≤ n) (hα : 0 ≤ α) (t : ℝ) : - Q (n + 1) α t = Q n α t - (2 * α / ((n : ℝ) * ((n : ℝ) - 1))) * t * (1 - t) := by - have h1 : ((n : ℝ) - 1) ≠ 0 := by - have := M_pos hn; simp only [M] at this; linarith - have h2 : (n : ℝ) ≠ 0 := by - have : (2 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn - linarith - have hM1 : M (n + 1) = (n : ℝ) := by simp only [M]; push_cast; ring - have hMn : M n = (n : ℝ) - 1 := by simp only [M] - simp only [Q, c, A, hM1, hMn] - field_simp - ring - -/-- `Q` decreases with `n` on `[0,1]`. -/ -lemma Q_anti {m n : ℕ} (hm : 2 ≤ m) (h : m ≤ n) (hα : 0 ≤ α) - (ht0 : 0 ≤ t) (ht1 : t ≤ 1) : Q n α t ≤ Q m α t := by - induction n with - | zero => omega - | succ n ih => - rcases Nat.lt_or_ge m (n + 1) with hlt | hge - · have hmn : m ≤ n := by omega - have hn2 : 2 ≤ n := le_trans hm hmn - have hstep : Q (n + 1) α t ≤ Q n α t := by - rw [Q_succ_sub n hn2 hα t] - have hnn : (0 : ℝ) ≤ 2 * α / ((n : ℝ) * ((n : ℝ) - 1)) := by - have h1 : (0 : ℝ) < (n : ℝ) - 1 := by - have := M_pos hn2; simp only [M] at this; linarith - have h2 : (0 : ℝ) < (n : ℝ) := by linarith - positivity - nlinarith [mul_nonneg (mul_nonneg hnn ht0) (by linarith : (0 : ℝ) ≤ 1 - t)] - exact le_trans hstep (ih hmn) - · have : m = n + 1 := by omega - subst this - exact le_rfl - -/-! ### The batch bound -/ - -open MeasureTheory - -/-- `x ^ y ≤ x ^ z` for `0 ≤ x ≤ 1` and `0 < z ≤ y`, allowing `x = 0`. -/ -lemma rpow_le_rpow_exponent_ge' {x y z : ℝ} (hx0 : 0 ≤ x) (hx1 : x ≤ 1) (hz : 0 < z) - (hzy : z ≤ y) : x ^ y ≤ x ^ z := by - exact Real.rpow_le_rpow_of_exponent_ge' hx0 hx1 hz.le hzy - -/-- The moment decreases with the degree: `Q` falls and the exponent rises. -/ -theorem integral_anti {m n : ℕ} (hm : 5 ≤ m) (h : m ≤ n) (hα : 0 ≤ α) - (hcm : 0 ≤ c m α) (hfn : c n α ^ 2 ≤ A n α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ (((n : ℝ) - 4) / 2)) - ≤ ∫ t in (0 : ℝ)..1, t ^ 3 * Q m α t ^ (((m : ℝ) - 4) / 2) := by - have hm2 : 2 ≤ m := by omega - have hn2 : 2 ≤ n := by omega - have hmR : (5 : ℝ) ≤ (m : ℝ) := by exact_mod_cast hm - have hmnR : (m : ℝ) ≤ (n : ℝ) := by exact_mod_cast h - have hem : (0 : ℝ) < ((m : ℝ) - 4) / 2 := by linarith - have hen : (0 : ℝ) ≤ ((n : ℝ) - 4) / 2 := by linarith - refine intervalIntegral.integral_mono_on (by norm_num) - ((continuous_integrand n α hen).intervalIntegrable _ _) - ((continuous_integrand m α hem.le).intervalIntegrable _ _) ?_ - intro t ht - obtain ⟨ht0, ht1⟩ := ht - refine mul_le_mul_of_nonneg_left ?_ (pow_nonneg ht0 3) - have hQn : 0 ≤ Q n α t := Q_nonneg hfn t - have hmono : Q n α t ≤ Q m α t := Q_anti hm2 h hα ht0 ht1 - -- nonnegativity at `m` comes free from monotonicity, so feasibility at `m` is not needed - have hQm0 : 0 ≤ Q m α t := le_trans hQn hmono - have hQm1 : Q m α t ≤ 1 := Q_le_one hm2 hα hcm ht0 ht1 - have hstep1 : Q n α t ^ (((n : ℝ) - 4) / 2) ≤ Q m α t ^ (((n : ℝ) - 4) / 2) := - Real.rpow_le_rpow hQn hmono hen - have hstep2 : Q m α t ^ (((n : ℝ) - 4) / 2) ≤ Q m α t ^ (((m : ℝ) - 4) / 2) := - rpow_le_rpow_exponent_ge' hQm0 hQm1 hem (by linarith) - linarith - -/-- **The batch bound.** One evaluation covers every degree in `[n₀, n₁]`: the elementary -part and the moment at `n₀`, the prefactor at `n₁`. - -Only `0 ≤ c n₀ α` is required at `n₀`, not feasibility. That matters: feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`, and for `n₀ < 36` it -does not follow from `α ≤ 17` either. Nonnegativity of `Q` at `n₀` instead comes free from -`Q_anti`, since `Q n₀ ≥ Q n ≥ 0`. -/ -theorem R_le_batch {n₀ n n₁ : ℕ} (h0 : 5 ≤ n₀) (h1 : n₀ ≤ n) (h2 : n ≤ n₁) (hα : 0 ≤ α) - (hc0 : 0 ≤ c n₀ α) (hfn : c n α ^ 2 ≤ A n α) : - R n α ≤ 1 / 6 + 1 / (4 * (3 + α)) + 1 / (2 * M n₀) + 1 / (4 * M n₀ * (3 + α)) - + A n₁ α ^ 2 * n₁ * M n₁ * ((n₁ : ℝ) - 2) / (4 * (3 + α)) - * ∫ t in (0 : ℝ)..1, t ^ 3 * Q n₀ α t ^ (((n₀ : ℝ) - 4) / 2) := by - have hn2 : 2 ≤ n := by omega - have h02 : 2 ≤ n₀ := by omega - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hM0 : 0 < M n₀ := M_pos h02 - have hMn : 0 < M n := M_pos hn2 - have hMn1 : 0 < M n₁ := lt_of_lt_of_le hMn (M_mono h2) - -- the elementary part decreases - have hbase : 1 / (2 * M n) + 1 / (4 * M n * (3 + α)) - ≤ 1 / (2 * M n₀) + 1 / (4 * M n₀ * (3 + α)) := by - have hMM : M n₀ ≤ M n := M_mono h1 - have e1 : 1 / (2 * M n) ≤ 1 / (2 * M n₀) := by - apply one_div_le_one_div_of_le (by linarith); linarith - have e2 : 1 / (4 * M n * (3 + α)) ≤ 1 / (4 * M n₀ * (3 + α)) := by - apply one_div_le_one_div_of_le (by positivity); nlinarith - linarith - -- the prefactor increases - have hAn : 0 ≤ A n α := A_nonneg hfn - have hApre : A n α ≤ A n₁ α := A_mono hn2 h2 hα - have hnn1 : (n : ℝ) ≤ (n₁ : ℝ) := by exact_mod_cast h2 - have hn2R : (2 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn2 - have hn12 : (2 : ℝ) ≤ (n₁ : ℝ) := le_trans hn2R hnn1 - have hA2 : A n α ^ 2 ≤ A n₁ α ^ 2 := by nlinarith [hAn, hApre] - have hnn : (0 : ℝ) ≤ (n : ℝ) := by positivity - have hMle : M n ≤ M n₁ := M_mono h2 - have hA1nn : (0 : ℝ) ≤ A n₁ α ^ 2 := sq_nonneg _ - have e1 : A n α ^ 2 * n ≤ A n₁ α ^ 2 * n₁ := mul_le_mul hA2 hnn1 hnn hA1nn - have e2 : A n α ^ 2 * n * M n ≤ A n₁ α ^ 2 * n₁ * M n₁ := - mul_le_mul e1 hMle hMn.le (by positivity) - have e3 : A n α ^ 2 * n * M n * ((n : ℝ) - 2) ≤ A n₁ α ^ 2 * n₁ * M n₁ * ((n₁ : ℝ) - 2) := - mul_le_mul e2 (by linarith) (by linarith) (by positivity) - have hc : (0 : ℝ) < 4 * (3 + α) := by positivity - have hpref : A n α ^ 2 * n * M n * ((n : ℝ) - 2) / (4 * (3 + α)) - ≤ A n₁ α ^ 2 * n₁ * M n₁ * ((n₁ : ℝ) - 2) / (4 * (3 + α)) := by - rw [div_le_div_iff_of_pos_right hc] - exact e3 - -- the moment decreases - have hI := integral_anti (m := n₀) (n := n) h0 h1 hα hc0 hfn - have hInn : 0 ≤ ∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ (((n : ℝ) - 4) / 2) := by - apply intervalIntegral.integral_nonneg (by norm_num) - intro u hu - exact mul_nonneg (pow_nonneg hu.1 3) (Real.rpow_nonneg (Q_nonneg hfn u) _) - have hprefnn : 0 ≤ A n₁ α ^ 2 * n₁ * M n₁ * ((n₁ : ℝ) - 2) / (4 * (3 + α)) := by - have h4 : (0 : ℝ) ≤ (n₁ : ℝ) - 2 := by linarith - have h5 : (0 : ℝ) ≤ M n₁ := hMn1.le - positivity - rw [R] - nlinarith [hbase, hpref, hI, hInn, hprefnn] - -end Sendov diff --git a/Sendov/FiniteRange/BatchCertificate.lean b/Sendov/FiniteRange/BatchCertificate.lean deleted file mode 100644 index 7301723..0000000 --- a/Sendov/FiniteRange/BatchCertificate.lean +++ /dev/null @@ -1,39 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch - -/-! -# From a batch moment and a positive deficit to `R < 1` - -The analytic batch bound and the supplied algebraic identity have different jobs. -This interface joins them without expanding the moment polynomial or its certificate. -The lower endpoint needs only `c ≥ 0`, not feasibility; feasibility remains at the -actual degree. Thus the same contract covers low-degree and large-degree batches. --/ - -namespace Sendov - -/-- An integer moment at the lower endpoint and a positive deficit certify the whole -batch. `m₀` and `m₁` allow the caller's exact endpoint numerals in the supplied identity. -No sign assumption on the moment or on the numerator's individual coefficients is needed. -The denominator and the complete deficit must both be strictly positive. -/ -theorem R_lt_one_of_batch_certificate {n₀ n n₁ k : ℕ} {α m₀ m₁ I P D : ℝ} - (h0 : 5 ≤ n₀) (h1 : n₀ ≤ n) (h2 : n ≤ n₁) (hα : 0 ≤ α) - (hc0 : 0 ≤ c n₀ α) (hfeas : c n α ^ 2 ≤ A n α) - (hk : ((n₀ : ℝ) - 4) / 2 = (k : ℝ)) - (hM0 : M n₀ = m₀) (hM1 : M n₁ = m₁) - (hmoment : (∫ t in (0 : ℝ)..1, t ^ 3 * Q n₀ α t ^ k) = I) - (hcert : 1 / 6 + 1 / (4 * (3 + α)) + 1 / (2 * m₀) - + 1 / (4 * m₀ * (3 + α)) - + (1 - 2 * α / m₁) ^ 2 * n₁ * m₁ * ((n₁ : ℝ) - 2) - / (4 * (3 + α)) * I = 1 - P / D) - (hP : 0 < P) (hD : 0 < D) : R n α < 1 := by - have hb := R_le_batch h0 h1 h2 hα hc0 hfeas - simp only [hk, Real.rpow_natCast, hmoment, A, hM0, hM1] at hb - rw [hcert] at hb - exact hb.trans_lt (sub_lt_self _ (div_pos hP hD)) - -end Sendov diff --git a/Sendov/FiniteRange/Cover.lean b/Sendov/FiniteRange/Cover.lean deleted file mode 100644 index f416c7e..0000000 --- a/Sendov/FiniteRange/Cover.lean +++ /dev/null @@ -1,180 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Degree5 -import Sendov.FiniteRange.Degree7 -import Sendov.FiniteRange.Degree6_6 -import Sendov.FiniteRange.Degree8_9 -import Sendov.FiniteRange.Degree10_11 -import Sendov.FiniteRange.Degree12_13 -import Sendov.FiniteRange.Degree14_15 -import Sendov.FiniteRange.Degree16_18 -import Sendov.FiniteRange.Degree18_20 -import Sendov.FiniteRange.Degree20_22 -import Sendov.FiniteRange.Degree22_24 -import Sendov.FiniteRange.Degree24_26 -import Sendov.FiniteRange.Degree26_27 -import Sendov.FiniteRange.Degree28_29 -import Sendov.FiniteRange.Degree30_31 -import Sendov.FiniteRange.Degree32_33 -import Sendov.FiniteRange.Degree34_35 -import Sendov.FiniteRange.Degree36_37 -import Sendov.FiniteRange.Degree38_39 -import Sendov.FiniteRange.Degree40_41 -import Sendov.FiniteRange.Degree42_43 -import Sendov.FiniteRange.Degree44_45 -import Sendov.FiniteRange.Degree46_47 -import Sendov.FiniteRange.Degree48_49 -import Sendov.FiniteRange.Degree50_51 -import Sendov.FiniteRange.Degree52_53 -import Sendov.FiniteRange.Degree54_55 -import Sendov.FiniteRange.Degree56_58 -import Sendov.FiniteRange.Degree58_60 -import Sendov.FiniteRange.Degree60_63 -import Sendov.FiniteRange.Degree64_69 -import Sendov.FiniteRange.Degree70_79 -import Sendov.FiniteRange.Degree80_100 - -/-! -# The finite range `5 ≤ n ≤ 100` - -This file does nothing but assemble the individual degree files and the degree *batches* into -a single statement. Its only content is the case split, so it is also where the claim "every -degree in the range is covered" gets checked: the branches below are generated from the batch -plan, and the file would not compile if a degree were skipped. - -Degrees `5` and `7` are handled one at a time (`Sendov.finite_range_five`, -`Sendov.finite_range_seven`); every other degree is covered by a batch `B n₀ n₁`, whose proof -is a single Bernstein certificate valid simultaneously for all `n₀ ≤ n ≤ n₁`. --/ - -namespace Sendov - -variable {α : ℝ} - -/-- **The finite range.** Every degree from `5` to `100` inclusive. -/ -theorem finite_range_le_100 {n : ℕ} (h0 : 5 ≤ n) (h1 : n ≤ 100) - (hα : 0 ≤ α) (hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - -- degrees 5..5 - rcases Nat.lt_or_ge n 6 with h | h - · obtain rfl : n = 5 := by omega - exact finite_range_five hα hfeas - -- degrees 6..6 - rcases Nat.lt_or_ge n 7 with h | h - · exact B6_6.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 7..7 - rcases Nat.lt_or_ge n 8 with h | h - · obtain rfl : n = 7 := by omega - exact finite_range_seven hα hfeas - -- degrees 8..9 - rcases Nat.lt_or_ge n 10 with h | h - · exact B8_9.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 10..11 - rcases Nat.lt_or_ge n 12 with h | h - · exact B10_11.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 12..13 - rcases Nat.lt_or_ge n 14 with h | h - · exact B12_13.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 14..15 - rcases Nat.lt_or_ge n 16 with h | h - · exact B14_15.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 16..18 - rcases Nat.lt_or_ge n 19 with h | h - · exact B16_18.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 19..20 - rcases Nat.lt_or_ge n 21 with h | h - · exact B18_20.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 21..22 - rcases Nat.lt_or_ge n 23 with h | h - · exact B20_22.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 23..24 - rcases Nat.lt_or_ge n 25 with h | h - · exact B22_24.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 25..26 - rcases Nat.lt_or_ge n 27 with h | h - · exact B24_26.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 27..27 - rcases Nat.lt_or_ge n 28 with h | h - · exact B26_27.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 28..29 - rcases Nat.lt_or_ge n 30 with h | h - · exact B28_29.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 30..31 - rcases Nat.lt_or_ge n 32 with h | h - · exact B30_31.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 32..33 - rcases Nat.lt_or_ge n 34 with h | h - · exact B32_33.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 34..35 - rcases Nat.lt_or_ge n 36 with h | h - · exact B34_35.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 36..37 - rcases Nat.lt_or_ge n 38 with h | h - · exact B36_37.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 38..39 - rcases Nat.lt_or_ge n 40 with h | h - · exact B38_39.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 40..41 - rcases Nat.lt_or_ge n 42 with h | h - · exact B40_41.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 42..43 - rcases Nat.lt_or_ge n 44 with h | h - · exact B42_43.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 44..45 - rcases Nat.lt_or_ge n 46 with h | h - · exact B44_45.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 46..47 - rcases Nat.lt_or_ge n 48 with h | h - · exact B46_47.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 48..49 - rcases Nat.lt_or_ge n 50 with h | h - · exact B48_49.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 50..51 - rcases Nat.lt_or_ge n 52 with h | h - · exact B50_51.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 52..53 - rcases Nat.lt_or_ge n 54 with h | h - · exact B52_53.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 54..55 - rcases Nat.lt_or_ge n 56 with h | h - · exact B54_55.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 56..58 - rcases Nat.lt_or_ge n 59 with h | h - · exact B56_58.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 59..60 - rcases Nat.lt_or_ge n 61 with h | h - · exact B58_60.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 61..63 - rcases Nat.lt_or_ge n 64 with h | h - · exact B60_63.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 64..69 - rcases Nat.lt_or_ge n 70 with h | h - · exact B64_69.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 70..79 - rcases Nat.lt_or_ge n 80 with h | h - · exact B70_79.finite_range (by omega) (by omega) hα hα' hfeas - -- degrees 80..100 - exact B80_100.finite_range (by omega) (by omega) hα hα' hfeas - -/-- **The finite-range claim.** The right-hand side of equation `stat` of the blog post is -strictly less than `1` on the range of degrees and of `α` left open there, that is, on -`5 ≤ n ≤ 97`, `0 ≤ α ≤ 17`, subject to the feasibility constraint `c ^ 2 ≤ A`. - -This is the original challenge statement. It is a special case of `finite_range_le_100`, -which covers three more degrees: the finite certification was pushed from `97` to `100` so -that it meets the large-degree argument of `Sendov.LargeDegree` with room to spare. -/ -theorem finite_range (n : ℕ) (α : ℝ) (hn : 5 ≤ n) (hn' : n ≤ 97) - (hα : 0 ≤ α) (hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : - R n α < 1 := - finite_range_le_100 hn (by omega) hα hα' hfeas - -/-- Equation `stat` of the blog post is infeasible on the range -`5 ≤ n ≤ 97`, `0 ≤ α ≤ 17`, `c ^ 2 ≤ A`. This is the form in which the claim is used. -/ -theorem finite_range_contradiction (n : ℕ) (α : ℝ) (hn : 5 ≤ n) (hn' : n ≤ 97) - (hα : 0 ≤ α) (hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) (hstat : 1 ≤ R n α) : - False := - absurd hstat (not_le.2 (finite_range n α hn hn' hα hα' hfeas)) - -end Sendov diff --git a/Sendov/FiniteRange/Degree10_11.lean b/Sendov/FiniteRange/Degree10_11.lean deleted file mode 100644 index 08dd71c..0000000 --- a/Sendov/FiniteRange/Degree10_11.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 10 to 11 - -`Sendov.R_le_batch` bounds every `R n α` for `10 ≤ n ≤ 11` by the elementary part and -moment at `n₀ = 10` together with the prefactor at `n₁ = 11`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 8, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B10_11 - -lemma M_lo : M 10 = 9 := by norm_num [M] - -lemma M_hi : M 11 = 10 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 10 α = 1 - 2 * α / 9 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 11 α = 1 - 2 * α / 10 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 10 α = (54 + 3 * α - 2 * α ^ 2) / (18 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 5) : 0 ≤ c 10 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 2520 - -def betac : ℤ := 82590802561 - -def tauc : ℤ := 484002949944962611058313401081496854475499965300896802417388157646295122586173254149900368313668004057389423899346929 - -/-- The moment numerator at `n₀ = 10`, `k = 3`. -/ -def Nmomc : List ℤ := - [472392, 1312200, 1971216, 3407184, 294192, 12096, 192] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 10) (gg1 10) (gg2 10) 3)) α := by - refine pev_moment_eq_of_packed_bounds 10 3 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 10 α t ^ 3) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 10 * (3 + α)) ^ 3) := - integral_moment_packed 10 3 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-8 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 8 * P α` is a positive combination of `αʲ (17-α)^(8-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 5) : - 0 < 32349375 + 39180105 * α + 10086687 * α ^ 2 - 24445935 * α ^ 3 + 11871036 * α ^ 4 - 351846 * α ^ 5 - 81598 * α ^ 6 - 4664 * α ^ 7 - 88 * α ^ 8 := by - have hu : (0 : ℝ) ≤ 5 - α := by linarith - have hid : (5 : ℝ) ^ 8 * (32349375 + 39180105 * α + 10086687 * α ^ 2 - 24445935 * α ^ 3 + 11871036 * α ^ 4 - 351846 * α ^ 5 - 81598 * α ^ 6 - 4664 * α ^ 7 - 88 * α ^ 8) = 32349375 * (5 - α) ^ 8 + 454695525 * α ^ 1 * (5 - α) ^ 7 + 2529253350 * α ^ 2 * (5 - α) ^ 6 + 4382737200 * α ^ 3 * (5 - α) ^ 5 + 5044170375 * α ^ 4 * (5 - α) ^ 4 + 11732079375 * α ^ 5 * (5 - α) ^ 3 + 18187642400 * α ^ 6 * (5 - α) ^ 2 + 11329113600 * α ^ 7 * (5 - α) ^ 1 + 2070835200 * α ^ 8 := by - bernstein_ring α (5 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (5 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `10 ≤ n ≤ 11`.** -/ -theorem finite_range {n : ℕ} (h0 : 10 ≤ n) (h1 : n ≤ 11) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 5 := by - have hcast : ((n : ℕ) : ℝ) ≤ (11 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (11 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 9) + 1 / (4 * 9 * (3 + α)) - + (1 - 2 * α / 10) ^ 2 * 11 * 10 * (11 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 9 * (3 + α)) ^ 3)) - = 1 - (32349375 + 39180105 * α + 10086687 * α ^ 2 - 24445935 * α ^ 3 + 11871036 * α ^ 4 - 351846 * α ^ 5 - 81598 * α ^ 6 - 4664 * α ^ 7 - 88 * α ^ 8) / (680400 * (3 + α) ^ 4) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 10) (n₁ := 11) (k := 3) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B10_11 - -end Sendov diff --git a/Sendov/FiniteRange/Degree12_13.lean b/Sendov/FiniteRange/Degree12_13.lean deleted file mode 100644 index 3a7b70a..0000000 --- a/Sendov/FiniteRange/Degree12_13.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 12 to 13 - -`Sendov.R_le_batch` bounds every `R n α` for `12 ≤ n ≤ 13` by the elementary part and -moment at `n₀ = 12` together with the prefactor at `n₁ = 13`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 10, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B12_13 - -lemma M_lo : M 12 = 11 := by norm_num [M] - -lemma M_hi : M 13 = 12 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 12 α = 1 - 2 * α / 11 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 13 α = 1 - 2 * α / 12 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 12 α = (66 + 5 * α - 2 * α ^ 2) / (22 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 6) : 0 ≤ c 12 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 27720 - -def betac : ℤ := 538941732215041 - -def tauc : ℤ := 6292050050870377734039180756234778163021074014036716599319294695000296491713270664825204672831809746575409998007435248501929604780211870392204795696401964180489810388769719091757577450834981070202288673 - -/-- The moment numerator at `n₀ = 12`, `k = 4`. -/ -def Nmomc : List ℤ := - [265646304, 754389504, 1044603648, 1046977536, 1399732528, 127959680, 6424320, 167936, 1792] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 12) (gg1 12) (gg2 12) 4)) α := by - refine pev_moment_eq_of_packed_bounds 12 4 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 12 α t ^ 4) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 12 * (3 + α)) ^ 4) := - integral_moment_packed 12 4 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-10 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 10 * P α` is a positive combination of `αʲ (17-α)^(10-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 6) : - 0 < 67214552328 + 108758874312 * α + 64248083658 * α ^ 2 + 8893434528 * α ^ 3 - 26471207052 * α ^ 4 + 9402730740 * α ^ 5 - 77587159 * α ^ 6 - 46242248 * α ^ 7 - 3634800 * α ^ 8 - 118976 * α ^ 9 - 1456 * α ^ 10 := by - have hu : (0 : ℝ) ≤ 6 - α := by linarith - have hid : (6 : ℝ) ^ 10 * (67214552328 + 108758874312 * α + 64248083658 * α ^ 2 + 8893434528 * α ^ 3 - 26471207052 * α ^ 4 + 9402730740 * α ^ 5 - 77587159 * α ^ 6 - 46242248 * α ^ 7 - 3634800 * α ^ 8 - 118976 * α ^ 9 - 1456 * α ^ 10) = 67214552328 * (6 - α) ^ 10 + 1324698769152 * α ^ 1 * (6 - α) ^ 9 + 11210565079296 * α ^ 2 * (6 - α) ^ 8 + 51982093082304 * α ^ 3 * (6 - α) ^ 7 + 112831785636336 * α ^ 4 * (6 - α) ^ 6 + 136300060037952 * α ^ 5 * (6 - α) ^ 5 + 172834300408608 * α ^ 6 * (6 - α) ^ 4 + 277236880276032 * α ^ 7 * (6 - α) ^ 3 + 281516219316936 * α ^ 8 * (6 - α) ^ 2 + 131510134768320 * α ^ 9 * (6 - α) ^ 1 + 19805743188000 * α ^ 10 := by - bernstein_ring α (6 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (6 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `12 ≤ n ≤ 13`.** -/ -theorem finite_range {n : ℕ} (h0 : 12 ≤ n) (h1 : n ≤ 13) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 6 := by - have hcast : ((n : ℕ) : ℝ) ≤ (13 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (13 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 11) + 1 / (4 * 11 * (3 + α)) - + (1 - 2 * α / 12) ^ 2 * 13 * 12 * (13 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 11 * (3 + α)) ^ 4)) - = 1 - (67214552328 + 108758874312 * α + 64248083658 * α ^ 2 + 8893434528 * α ^ 3 - 26471207052 * α ^ 4 + 9402730740 * α ^ 5 - 77587159 * α ^ 6 - 46242248 * α ^ 7 - 3634800 * α ^ 8 - 118976 * α ^ 9 - 1456 * α ^ 10) / (442743840 * (3 + α) ^ 5) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 12) (n₁ := 13) (k := 4) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B12_13 - -end Sendov diff --git a/Sendov/FiniteRange/Degree14_15.lean b/Sendov/FiniteRange/Degree14_15.lean deleted file mode 100644 index f054c05..0000000 --- a/Sendov/FiniteRange/Degree14_15.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 14 to 15 - -`Sendov.R_le_batch` bounds every `R n α` for `14 ≤ n ≤ 15` by the elementary part and -moment at `n₀ = 14` together with the prefactor at `n₁ = 15`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 12, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B14_15 - -lemma M_lo : M 14 = 13 := by norm_num [M] - -lemma M_hi : M 15 = 14 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 14 α = 1 - 2 * α / 13 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 15 α = 1 - 2 * α / 14 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 14 α = (78 + 7 * α - 2 * α ^ 2) / (26 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 7) : 0 ≤ c 14 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 360360 - -def betac : ℤ := 5273811281588129281 - -def tauc : ℤ := 5240604256749137818001775409217258559398270598665938104246888891334041344492138378350247489747112270657502763060533670335383336131627922353242397074581977699087266735169689253384888787652968648421800644465440084079049341105429958677566179709215175220574978194512241977108241372511737172688952893630525928871748289 - -/-- The moment numerator at `n₀ = 14`, `k = 5`. -/ -def Nmomc : List ℤ := - [259845693120, 782498283840, 1107091851840, 1019339156160, 768295987680, 853275774240, 79511527040, 4444832000, 147210240, 2670080, 20480] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 14) (gg1 14) (gg2 14) 5)) α := by - refine pev_moment_eq_of_packed_bounds 14 5 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 14 α t ^ 5) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 14 * (3 + α)) ^ 5) := - integral_moment_packed 14 5 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-12 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 12 * P α` is a positive combination of `αʲ (17-α)^(12-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 7) : - 0 < 4540012290450 + 9000770719122 * α + 7217967952260 * α ^ 2 + 2789503991820 * α ^ 3 + 226924812075 * α ^ 4 - 867448623285 * α ^ 5 + 235182487819 * α ^ 6 + 1315276135 * α ^ 7 - 765536900 * α ^ 8 - 78585080 * α ^ 9 - 3463520 * α ^ 10 - 74480 * α ^ 11 - 640 * α ^ 12 := by - have hu : (0 : ℝ) ≤ 7 - α := by linarith - have hid : (7 : ℝ) ^ 12 * (4540012290450 + 9000770719122 * α + 7217967952260 * α ^ 2 + 2789503991820 * α ^ 3 + 226924812075 * α ^ 4 - 867448623285 * α ^ 5 + 235182487819 * α ^ 6 + 1315276135 * α ^ 7 - 765536900 * α ^ 8 - 78585080 * α ^ 9 - 3463520 * α ^ 10 - 74480 * α ^ 11 - 640 * α ^ 12) = 4540012290450 * (7 - α) ^ 12 + 117485542519254 * α ^ 1 * (7 - α) ^ 11 + 1346380586202834 * α ^ 2 * (7 - α) ^ 10 + 8957703596562630 * α ^ 3 * (7 - α) ^ 9 + 37714860895632375 * α ^ 4 * (7 - α) ^ 8 + 91053479724275985 * α ^ 5 * (7 - α) ^ 7 + 128817765797828254 * α ^ 6 * (7 - α) ^ 6 + 133833540832996984 * α ^ 7 * (7 - α) ^ 5 + 161773229978174745 * α ^ 8 * (7 - α) ^ 4 + 197834312331965435 * α ^ 9 * (7 - α) ^ 3 + 152113356071582990 * α ^ 10 * (7 - α) ^ 2 + 57359456154000000 * α ^ 11 * (7 - α) ^ 1 + 7376986416800000 * α ^ 12 := by - bernstein_ring α (7 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (7 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `14 ≤ n ≤ 15`.** -/ -theorem finite_range {n : ℕ} (h0 : 14 ≤ n) (h1 : n ≤ 15) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 7 := by - have hcast : ((n : ℕ) : ℝ) ≤ (15 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (15 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 13) + 1 / (4 * 13 * (3 + α)) - + (1 - 2 * α / 14) ^ 2 * 15 * 14 * (15 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 13 * (3 + α)) ^ 5)) - = 1 - (4540012290450 + 9000770719122 * α + 7217967952260 * α ^ 2 + 2789503991820 * α ^ 3 + 226924812075 * α ^ 4 - 867448623285 * α ^ 5 + 235182487819 * α ^ 6 + 1315276135 * α ^ 7 - 765536900 * α ^ 8 - 78585080 * α ^ 9 - 3463520 * α ^ 10 - 74480 * α ^ 11 - 640 * α ^ 12) / (9606092496 * (3 + α) ^ 6) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 14) (n₁ := 15) (k := 5) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B14_15 - -end Sendov diff --git a/Sendov/FiniteRange/Degree16_18.lean b/Sendov/FiniteRange/Degree16_18.lean deleted file mode 100644 index 0740d27..0000000 --- a/Sendov/FiniteRange/Degree16_18.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 16 to 18 - -`Sendov.R_le_batch` bounds every `R n α` for `16 ≤ n ≤ 18` by the elementary part and -moment at `n₀ = 16` together with the prefactor at `n₁ = 18`, so one moment and one -certificate serve all 3 degrees. The certificate has degree 14, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B16_18 - -lemma M_lo : M 16 = 15 := by norm_num [M] - -lemma M_hi : M 18 = 17 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 16 α = 1 - 2 * α / 15 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 18 α = 1 - 2 * α / 17 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 16 α = (90 + 9 * α - 2 * α ^ 2) / (30 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17 / 2) : 0 ≤ c 16 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 720720 - -def betac : ℤ := 9632409706279062743041 - -def tauc : ℤ := 65604308031184443540574573963916799164579355278379645304399696021576697292522316333712207898845459456442843781680661940474008113586613026045908148093916427474204047696513917860869931635574183554403391853205017812541311293282390174744915537500427122031507443987808875231567434632560187716182055857676129052451323844518845444325992588835078239595296506721823714704265478805643382244491222183969521021663658026171379394048234274188519553 - -/-- The moment numerator at `n₀ = 16`, `k = 6`. -/ -def Nmomc : List ℤ := - [52612659000000, 170273696400000, 255339685800000, 239918448960000, 165235950648000, 99966121176960, 96500543870016, 8976458195712, 533837640960, 20291420160, 478172160, 6377472, 36864] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 16) (gg1 16) (gg2 16) 6)) α := by - refine pev_moment_eq_of_packed_bounds 16 6 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 16 α t ^ 6) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 16 * (3 + α)) ^ 6) := - integral_moment_packed 16 6 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-14 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 14 * P α` is a positive combination of `αʲ (17-α)^(14-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17 / 2) : - 0 < 308547940078125 + 716274580556250 * α + 701075142421875 * α ^ 2 + 366034929547500 * α ^ 3 + 98713082723625 * α ^ 4 - 785317395690 * α ^ 5 - 34202916258669 * α ^ 6 + 6366700041480 * α ^ 7 + 121732471512 * α ^ 8 - 9494954208 * α ^ 9 - 1551607200 * α ^ 10 - 87661568 * α ^ 11 - 2586240 * α ^ 12 - 39936 * α ^ 13 - 256 * α ^ 14 := by - have hu : (0 : ℝ) ≤ 17 - 2 * α := by linarith - have hid : (17 : ℝ) ^ 14 * (308547940078125 + 716274580556250 * α + 701075142421875 * α ^ 2 + 366034929547500 * α ^ 3 + 98713082723625 * α ^ 4 - 785317395690 * α ^ 5 - 34202916258669 * α ^ 6 + 6366700041480 * α ^ 7 + 121732471512 * α ^ 8 - 9494954208 * α ^ 9 - 1551607200 * α ^ 10 - 87661568 * α ^ 11 - 2586240 * α ^ 12 - 39936 * α ^ 13 - 256 * α ^ 14) = 308547940078125 * (17 - 2 * α) ^ 14 + 20816010191643750 * α ^ 1 * (17 - 2 * α) ^ 13 + 631515530954221875 * α ^ 2 * (17 - 2 * α) ^ 12 + 11358598773482842500 * α ^ 3 * (17 - 2 * α) ^ 11 + 134099015737057493625 * α ^ 4 * (17 - 2 * α) ^ 10 + 1075072539293623306170 * α ^ 5 * (17 - 2 * α) ^ 9 + 5177641117293101872899 * α ^ 6 * (17 - 2 * α) ^ 8 + 13260545037504883513944 * α ^ 7 * (17 - 2 * α) ^ 7 + 13392270163441462237560 * α ^ 8 * (17 - 2 * α) ^ 6 + 934363054464939802080 * α ^ 9 * (17 - 2 * α) ^ 5 + 56141276222621229749280 * α ^ 10 * (17 - 2 * α) ^ 4 + 269593608305522330908544 * α ^ 11 * (17 - 2 * α) ^ 3 + 451523429099140347738624 * α ^ 12 * (17 - 2 * α) ^ 2 + 320966535936278232000000 * α ^ 13 * (17 - 2 * α) ^ 1 + 72913603873782672000000 * α ^ 14 := by - bernstein_ring α (17 - 2 * α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - 2 * α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `16 ≤ n ≤ 18`.** -/ -theorem finite_range {n : ℕ} (h0 : 16 ≤ n) (h1 : n ≤ 18) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 / 2 := by - have hcast : ((n : ℕ) : ℝ) ≤ (18 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (18 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 15) + 1 / (4 * 15 * (3 + α)) - + (1 - 2 * α / 17) ^ 2 * 18 * 17 * (18 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 15 * (3 + α)) ^ 6)) - = 1 - (308547940078125 + 716274580556250 * α + 701075142421875 * α ^ 2 + 366034929547500 * α ^ 3 + 98713082723625 * α ^ 4 - 785317395690 * α ^ 5 - 34202916258669 * α ^ 6 + 6366700041480 * α ^ 7 + 121732471512 * α ^ 8 - 9494954208 * α ^ 9 - 1551607200 * α ^ 10 - 87661568 * α ^ 11 - 2586240 * α ^ 12 - 39936 * α ^ 13 - 256 * α ^ 14) / (215371406250 * (3 + α) ^ 7) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 16) (n₁ := 18) (k := 6) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B16_18 - -end Sendov diff --git a/Sendov/FiniteRange/Degree18_20.lean b/Sendov/FiniteRange/Degree18_20.lean deleted file mode 100644 index 0f80bda..0000000 --- a/Sendov/FiniteRange/Degree18_20.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 18 to 20 - -`Sendov.R_le_batch` bounds every `R n α` for `18 ≤ n ≤ 20` by the elementary part and -moment at `n₀ = 18` together with the prefactor at `n₁ = 20`, so one moment and one -certificate serve all 3 degrees. The certificate has degree 16, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B18_20 - -lemma M_lo : M 18 = 17 := by norm_num [M] - -lemma M_hi : M 20 = 19 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 18 α = 1 - 2 * α / 17 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 20 α = 1 - 2 * α / 19 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 18 α = (102 + 11 * α - 2 * α ^ 2) / (34 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 19 / 2) : 0 ≤ c 18 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 12252240 - -def betac : ℤ := 175927662917225332359966721 - -def tauc : ℤ := 358483832023654241638315162089194303184230572320526650607274337745620624638936275643757889347744511177653609383831346364707120039183150206364616435398207395719060972709006144830720087322332895913982687118230996245850245160708643412112175024743903798686289485089015224938759859379750541156419506275337584501638157246946150682644437302655829353348979444821042370136731772238800566165427866451094788337835108013894151378044974961647775374731862145935889517758974312266434672837815042172397866699143848730300875843409734000578209410972334682764700002022390759745948434344742136442797552789219566126849 - -/-- The moment numerator at `n₀ = 18`, `k = 7`. -/ -def Nmomc : List ℤ := - [114983435331692928, 401488164091808640, 646936588267361280, 643985937083510784, 451960609895464320, 248282531980689024, 125596226938129920, 108748744491770880, 9970165621984512, 614458050662400, 25497772633088, 704123822080, 12428021760, 127074304, 573440] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 18) (gg1 18) (gg2 18) 7)) α := by - refine pev_moment_eq_of_packed_bounds 18 7 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 18 α t ^ 7) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 18 * (3 + α)) ^ 7) := - integral_moment_packed 18 7 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-16 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 16 * P α` is a positive combination of `αʲ (17-α)^(16-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 19 / 2) : - 0 < 1996938880799635773 + 5327542416376042533 * α + 6168567333266685756 * α ^ 2 + 4015726419901684032 * α ^ 3 + 1568562341575363317 * α ^ 4 + 336439630979056719 * α ^ 5 - 5059047712773960 * α ^ 6 - 94154641040290584 * α ^ 7 + 14305270642714822 * α ^ 8 + 337895936432856 * α ^ 9 - 7990669279488 * α ^ 10 - 2592154628256 * α ^ 11 - 177335477376 * α ^ 12 - 6421337472 * α ^ 13 - 134803968 * α ^ 14 - 1555968 * α ^ 15 - 7680 * α ^ 16 := by - have hu : (0 : ℝ) ≤ 19 - 2 * α := by linarith - have hid : (19 : ℝ) ^ 16 * (1996938880799635773 + 5327542416376042533 * α + 6168567333266685756 * α ^ 2 + 4015726419901684032 * α ^ 3 + 1568562341575363317 * α ^ 4 + 336439630979056719 * α ^ 5 - 5059047712773960 * α ^ 6 - 94154641040290584 * α ^ 7 + 14305270642714822 * α ^ 8 + 337895936432856 * α ^ 9 - 7990669279488 * α ^ 10 - 2592154628256 * α ^ 11 - 177335477376 * α ^ 12 - 6421337472 * α ^ 13 - 134803968 * α ^ 14 - 1555968 * α ^ 15 - 7680 * α ^ 16) = 1996938880799635773 * (19 - 2 * α) ^ 16 + 165125350096733152863 * α ^ 1 * (19 - 2 * α) ^ 15 + 6222082647427442972766 * α ^ 2 * (19 - 2 * α) ^ 14 + 141355820787428498073516 * α ^ 3 * (19 - 2 * α) ^ 13 + 2157735283869217913370909 * α ^ 4 * (19 - 2 * α) ^ 12 + 23307179713209861652797525 * α ^ 5 * (19 - 2 * α) ^ 11 + 181491504176132704398182238 * α ^ 6 * (19 - 2 * α) ^ 10 + 947234591820259386271884708 * α ^ 7 * (19 - 2 * α) ^ 9 + 3056114849066116568052366478 * α ^ 8 * (19 - 2 * α) ^ 8 + 5409419472435810969555104008 * α ^ 9 * (19 - 2 * α) ^ 7 + 3773674627041183640344074704 * α ^ 10 * (19 - 2 * α) ^ 6 + 2563877062588931411214853312 * α ^ 11 * (19 - 2 * α) ^ 5 + 27502208508532453123433891776 * α ^ 12 * (19 - 2 * α) ^ 4 + 85133541744770676359382205696 * α ^ 13 * (19 - 2 * α) ^ 3 + 113617195875176526046213373440 * α ^ 14 * (19 - 2 * α) ^ 2 + 68841959775014032750000000000 * α ^ 15 * (19 - 2 * α) ^ 1 + 13908254927398975000000000000 * α ^ 16 := by - bernstein_ring α (19 - 2 * α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (19 - 2 * α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `18 ≤ n ≤ 20`.** -/ -theorem finite_range {n : ℕ} (h0 : 18 ≤ n) (h1 : n ≤ 20) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 19 / 2 := by - have hcast : ((n : ℕ) : ℝ) ≤ (20 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (20 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 17) + 1 / (4 * 17 * (3 + α)) - + (1 - 2 * α / 19) ^ 2 * 20 * 19 * (20 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 17 * (3 + α)) ^ 7)) - = 1 - (1996938880799635773 + 5327542416376042533 * α + 6168567333266685756 * α ^ 2 + 4015726419901684032 * α ^ 3 + 1568562341575363317 * α ^ 4 + 336439630979056719 * α ^ 5 - 5059047712773960 * α ^ 6 - 94154641040290584 * α ^ 7 + 14305270642714822 * α ^ 8 + 337895936432856 * α ^ 9 - 7990669279488 * α ^ 10 - 2592154628256 * α ^ 11 - 177335477376 * α ^ 12 - 6421337472 * α ^ 13 - 134803968 * α ^ 14 - 1555968 * α ^ 15 - 7680 * α ^ 16) / (454875191212728 * (3 + α) ^ 8) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 18) (n₁ := 20) (k := 7) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B18_20 - -end Sendov diff --git a/Sendov/FiniteRange/Degree20.lean b/Sendov/FiniteRange/Degree20.lean deleted file mode 100644 index 164bb8c..0000000 --- a/Sendov/FiniteRange/Degree20.lean +++ /dev/null @@ -1,137 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Reduce - -/-! -# The finite-range claim in degree twenty - -A scaling test for the general machinery: here `k = 8`, so `Sendov.mom 20 α 8` is a -45-term double sum, and the cleared numerator `P` has degree 18 with coefficients of up to -22 digits. Positivity of `P` on `[0, 19/2]` is well beyond `nlinarith`, so this is the -first degree needing an explicit certificate. - -The certificate is a Bernstein representation on `[0, 19/2]`: - - `19 ^ 18 * P α = ∑ j < 19, Γ j * α ^ j * (19 - 2α) ^ (18 - j)` - -with all nineteen `Γ j` positive integers (of up to 34 digits). Since `α ≥ 0` and -`19 - 2α ≥ 0` on the range, every summand is nonnegative, and at least one is strictly -positive, so `P > 0`. `P` in fact stays positive up to `α = 12.05`, while feasibility -gives only `α ≤ 19/2`, so the certificate has room to spare. --/ - -set_option maxRecDepth 8000 - -namespace Sendov - -open MeasureTheory - -variable {α : ℝ} - -lemma M_twenty : M 20 = 19 := by norm_num [M] - -lemma A_twenty (α : ℝ) : A 20 α = 1 - 2 * α / 19 := by - rw [A, M] - push_cast - ring - -lemma c_twenty (α : ℝ) : c 20 α = 1 - α / 19 - α / (2 * (3 + α)) := by - rw [c, M] - push_cast - ring - -lemma c_twenty' (hα : 0 ≤ α) : c 20 α = (114 + 13 * α - 2 * α ^ 2) / (38 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c_twenty] - field_simp - ring - -/-- The Bernstein certificate for the degree-twenty numerator on `[0, 19/2]`. -/ -lemma P_twenty_pos (hα : 0 ≤ α) (hle : α ≤ 19 / 2) : - 0 < 2428684725423666483774 + 7331467129251995458872 * α + 9806391760574638480284 * α ^ 2 + - 7611575747798170524888 * α ^ 3 + 3758723770378675135797 * α ^ 4 + 1206125979814312523496 * α - ^ 5 + 235504051379657180694 * α ^ 6 + 11454730616615814828 * α ^ 7 - 32607895082957507571 * - α ^ 8 + 5227920728232680812 * α ^ 9 + 102472476340054572 * α ^ 10 - 2640164743526400 * α ^ - 11 - 847605280292160 * α ^ 12 - 61937116512768 * α ^ 13 - 2508597900288 * α ^ 14 - - 62979502080 * α ^ 15 - 979335936 * α ^ 16 - 8690688 * α ^ 17 - 33792 * α ^ 18 := by - have hu : (0 : ℝ) ≤ 19 - 2 * α := by linarith - have hid : (19 : ℝ) ^ 18 * - (2428684725423666483774 + 7331467129251995458872 * α + 9806391760574638480284 * α ^ 2 + - 7611575747798170524888 * α ^ 3 + 3758723770378675135797 * α ^ 4 + 1206125979814312523496 * - α ^ 5 + 235504051379657180694 * α ^ 6 + 11454730616615814828 * α ^ 7 - - 32607895082957507571 * α ^ 8 + 5227920728232680812 * α ^ 9 + 102472476340054572 * α ^ 10 - - 2640164743526400 * α ^ 11 - 847605280292160 * α ^ 12 - 61937116512768 * α ^ 13 - - 2508597900288 * α ^ 14 - 62979502080 * α ^ 15 - 979335936 * α ^ 16 - 8690688 * α ^ 17 - - 33792 * α ^ 18) - = 2428684725423666483774 * (19 - 2 * α) ^ 18 + - 226730525571039907134432 * α ^ 1 * (19 - 2 * - α) ^ 17 + 9762590243023517445883524 * α ^ 2 * (19 - 2 * α) ^ 16 + - 257123733807820195223425224 * α ^ 3 * (19 - 2 * α) ^ 15 + 4632014993012551188816601077 * - α ^ 4 * (19 - 2 * α) ^ 14 + 60459331875837108393876395364 * α ^ 5 * (19 - 2 * α) ^ 13 + - 590623191218980187440834237938 * α ^ 6 * (19 - 2 * α) ^ 12 + - 4389613323288949613610408693204 * α ^ 7 * (19 - 2 * α) ^ 11 + - 24480093296536555966858990491717 * α ^ 8 * (19 - 2 * α) ^ 10 + - 100744503274528106203930847272696 * α ^ 9 * (19 - 2 * α) ^ 9 + - 306223243964547514886419597653624 * α ^ 10 * (19 - 2 * α) ^ 8 + - 708731127961028987356988552204352 * α ^ 11 * (19 - 2 * α) ^ 7 + - 1342727866428363194166781707341088 * α ^ 12 * (19 - 2 * α) ^ 6 + - 2273564082246386518492641655978752 * α ^ 13 * (19 - 2 * α) ^ 5 + - 3442867955253474296197691549373696 * α ^ 14 * (19 - 2 * α) ^ 4 + - 4130621657305785039523793191219200 * α ^ 15 * (19 - 2 * α) ^ 3 + - 3349606068894706620649142246807040 * α ^ 16 * (19 - 2 * α) ^ 2 + - 1529243641677728878687500000000000 * α ^ 17 * (19 - 2 * α) ^ 1 + - 274558827655262150000000000000000 * α ^ 18 := by - ring - -- The last Bernstein term is positive away from zero; the first handles zero. - apply (mul_pos_iff_of_pos_left (by norm_num : (0 : ℝ) < 19 ^ 18)).mp - rw [hid] - rcases lt_or_eq_of_le hα with hpos | hzero - · positivity - · subst α - norm_num - -/-- The upper bound for `R 20 α`, from the general moment formula with `k = 8`. -/ -lemma R_twenty_le (hα : 0 ≤ α) : - R 20 α ≤ 1 / 6 + 1 / (4 * (3 + α)) + 1 / 38 + 1 / (76 * (3 + α)) - + 1710 * A 20 α ^ 2 / (3 + α) * mom 20 α 8 := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - have hk : ((((20 : ℕ) : ℝ) - 4) / 2) = ((8 : ℕ) : ℝ) := by norm_num - have h := R_le_of_integral_le (n := 20) (by norm_num) hα (le_of_eq (integral_eq_mom 8 hk)) - rw [M_twenty] at h - push_cast at h - refine h.trans (le_of_eq ?_) - field_simp - ring - -/-- **The finite-range claim in degree twenty.** -/ -theorem finite_range_twenty (hα : 0 ≤ α) (hfeas : c 20 α ^ 2 ≤ A 20 α) : R 20 α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hle : α ≤ 19 / 2 := by - have h := alpha_le_half_M (n := 20) (by norm_num) hfeas - rw [M_twenty] at h - linarith - have hR := R_twenty_le hα - have hid : 1 / 6 + 1 / (4 * (3 + α)) + 1 / 38 + 1 / (76 * (3 + α)) - + 1710 * A 20 α ^ 2 / (3 + α) * mom 20 α 8 - = 1 - - (2428684725423666483774 + 7331467129251995458872 * α + 9806391760574638480284 * α ^ 2 + - 7611575747798170524888 * α ^ 3 + 3758723770378675135797 * α ^ 4 + 1206125979814312523496 - * α ^ 5 + 235504051379657180694 * α ^ 6 + 11454730616615814828 * α ^ 7 - - 32607895082957507571 * α ^ 8 + 5227920728232680812 * α ^ 9 + 102472476340054572 * α ^ 10 - - 2640164743526400 * α ^ 11 - 847605280292160 * α ^ 12 - 61937116512768 * α ^ 13 - - 2508597900288 * α ^ 14 - 62979502080 * α ^ 15 - 979335936 * α ^ 16 - 8690688 * α ^ 17 - - 33792 * α ^ 18) - / (178855464872570772 * (3 + α) ^ 9) := by - rw [mom, A_twenty, c_twenty' hα] - simp only [Finset.sum_range_succ, Finset.sum_range_zero, Nat.choose, Nat.cast_one] - norm_num - field_simp - ring - rw [hid] at hR - have hP := P_twenty_pos hα hle - exact hR.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) - -end Sendov diff --git a/Sendov/FiniteRange/Degree20Packed.lean b/Sendov/FiniteRange/Degree20Packed.lean deleted file mode 100644 index a617063..0000000 --- a/Sendov/FiniteRange/Degree20Packed.lean +++ /dev/null @@ -1,63 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.PackBridge -import Sendov.FiniteRange.Reduce - -/-! -# Degree twenty through the packed path - -A differential test of the packing bridge. Degree twenty is already proved in -`Sendov.FiniteRange.Degree20` by the direct route, so any disagreement here is a bug in the -bridge rather than a new mathematical fact. `Sendov.packed_agrees_twenty` states the -cross-check: the multinomial formula `(M)` and the packed recurrence compute the same -number, proved by transitivity through the integral itself, with no expansion at any `k`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 100000 - -namespace Sendov - -/-- `lcm (4 .. 20)`, clearing the weights `1/(j+4)` for `j` up to `16`. -/ -def L20 : ℤ := 232792560 - -/-- Kronecker base packing a coefficient polynomial in `α`. -/ -def beta20 : ℤ := 17557640290828443979548888553985 - -/-- Kronecker base packing the row, a polynomial in `t`. -/ -def tau20 : ℤ := 1447326351619059204898716406983437305998463825678484019367742677287287571938439552267338057721680937249870701724020109571363451685542225000786583505247484723991737401320219819072484624701345840153357440293821689316804560778960232462168634392032438245400519751866728942882795389626136102212364132385633624149225435592794976728090795053404519509839779809147905536216226810069323449403279508449916679354531279513212284207024264926083620338904064993814111335110426148352741960595286112549871063419480493020052871564730892657665 - -/-- The moment numerator, supplied by the generator and verified below. -/ -def Nmom20 : List ℤ := - [342652681018715139072, 1290458050152354091008, 2243577184611827226624, 2399637756691021787136, 1783512729454695095808, 996976999580720707584, 454864090944105851904, 197832256724748957696, 157260237317474747904, 14092143950522867712, 885156618381127680, 38940288112115712, 1195127971889152, 25104659120128, 344544313344, 2787377152, 10092544] - -/-- The generator's numerator is the moment numerator. The computational content is one -integer exponentiation and seventeen digit extractions. -/ -theorem Nmom20_eq : - Nmom20 = wsum L20 0 (qrow (gg0 20) (gg1 20) (gg2 20) 8) := by - refine wsum_eq_of_packed (gg0 20) (gg1 20) (gg2 20) 8 L20 beta20 tau20 Nmom20 - (by decide) (by decide) ?_ ?_ ?_ ?_ ?_ - · decide -- No overflow when packing the row in τ. - · decide -- The supplied numerator coefficients fit in β. - · decide -- The computed weighted sum also fits in β. - · rfl -- The two coefficient lists have the same length. - · rfl -- Exact packed integer equality. - -/-- The degree-twenty moment, via the packed route. -/ -theorem integral_twenty_packed (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 20 α t ^ 8) - = pev Nmom20 α / ((L20 : ℝ) * (2 * M 20 * (3 + α)) ^ 8) := - integral_moment_packed 20 8 (by norm_num) α hα L20 (by decide) Nmom20 - (by decide) (by rw [Nmom20_eq]) - -/-- **The cross-check.** The multinomial formula and the packed recurrence agree. Neither -side is expanded: both compute the same integral, so they are equal by transitivity. -/ -theorem packed_agrees_twenty (α : ℝ) (hα : 0 ≤ α) : - pev Nmom20 α / ((L20 : ℝ) * (2 * M 20 * (3 + α)) ^ 8) = mom 20 α 8 := by - exact (integral_twenty_packed α hα).symm.trans (integral_moment 20 α 8) - -end Sendov diff --git a/Sendov/FiniteRange/Degree20_22.lean b/Sendov/FiniteRange/Degree20_22.lean deleted file mode 100644 index bff3ff0..0000000 --- a/Sendov/FiniteRange/Degree20_22.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 20 to 22 - -`Sendov.R_le_batch` bounds every `R n α` for `20 ≤ n ≤ 22` by the elementary part and -moment at `n₀ = 20` together with the prefactor at `n₁ = 22`, so one moment and one -certificate serve all 3 degrees. The certificate has degree 18, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B20_22 - -lemma M_lo : M 20 = 19 := by norm_num [M] - -lemma M_hi : M 22 = 21 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 20 α = 1 - 2 * α / 19 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 22 α = 1 - 2 * α / 21 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 20 α = (114 + 13 * α - 2 * α ^ 2) / (38 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 21 / 2) : 0 ≤ c 20 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 232792560 - -def betac : ℤ := 4131209409209679854788987576321 - -def tauc : ℤ := 44775284788996865642893254679922271778917421122771510633920083377417225592961214127138545037980122454589072908657663380807599570953499350023955756845650273335369910042414392837789684225435587469649384627401365137215111142493529834089724868392831219963919558050105735619336220634358348775620366460327078867856343356142091112197183816351904389560191323401011583801350056642509421229073471652965690556344130689616076286735679016586779542709253460049049834200030423394619361068308927407924992768190982659511467666364074304423376770648009486446989819845183327368715672103880903585609634804230071151638268944708950497970217303849145427269129679404213103006562198768221354213524467878675079767978766859201415554409852677086782888653509986106731604823282151130888540570232939710702306888786166273 - -/-- The moment numerator at `n₀ = 20`, `k = 8`. -/ -def Nmomc : List ℤ := - [342652681018715139072, 1290458050152354091008, 2243577184611827226624, 2399637756691021787136, 1783512729454695095808, 996976999580720707584, 454864090944105851904, 197832256724748957696, 157260237317474747904, 14092143950522867712, 885156618381127680, 38940288112115712, 1195127971889152, 25104659120128, 344544313344, 2787377152, 10092544] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 20) (gg1 20) (gg2 20) 8)) α := by - refine pev_moment_eq_of_packed_bounds 20 8 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 20 α t ^ 8) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 20 * (3 + α)) ^ 8) := - integral_moment_packed 20 8 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-18 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 18 * P α` is a positive combination of `αʲ (17-α)^(18-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 21 / 2) : - 0 < 721140310389707127738 + 2170180610909239016088 * α + 2889750967198268814324 * α ^ 2 + 2227128338977232972904 * α ^ 3 + 1085997068794302710391 * α ^ 4 + 339049376116278228288 * α ^ 5 + 60509700204282383346 * α ^ 6 - 1038039442012938636 * α ^ 7 - 14060791839010189905 * α ^ 8 + 1774506642858471852 * α ^ 9 + 45855210342618468 * α ^ 10 + 226538249017920 * α ^ 11 - 222291771124416 * α ^ 12 - 18538380993792 * α ^ 13 - 787852835840 * α ^ 14 - 20286313472 * α ^ 15 - 320448768 * α ^ 16 - 2874368 * α ^ 17 - 11264 * α ^ 18 := by - have hu : (0 : ℝ) ≤ 21 - 2 * α := by linarith - have hid : (21 : ℝ) ^ 18 * (721140310389707127738 + 2170180610909239016088 * α + 2889750967198268814324 * α ^ 2 + 2227128338977232972904 * α ^ 3 + 1085997068794302710391 * α ^ 4 + 339049376116278228288 * α ^ 5 + 60509700204282383346 * α ^ 6 - 1038039442012938636 * α ^ 7 - 14060791839010189905 * α ^ 8 + 1774506642858471852 * α ^ 9 + 45855210342618468 * α ^ 10 + 226538249017920 * α ^ 11 - 222291771124416 * α ^ 12 - 18538380993792 * α ^ 13 - 787852835840 * α ^ 14 - 20286313472 * α ^ 15 - 320448768 * α ^ 16 - 2874368 * α ^ 17 - 11264 * α ^ 18) = 721140310389707127738 * (21 - 2 * α) ^ 18 + 71534844003123475936416 * α ^ 1 * (21 - 2 * α) ^ 17 + 3265227002682133966779372 * α ^ 2 * (21 - 2 * α) ^ 16 + 90905348441621278719467208 * α ^ 3 * (21 - 2 * α) ^ 15 + 1724899809677710491069520311 * α ^ 4 * (21 - 2 * α) ^ 14 + 23603549699659251265167149604 * α ^ 5 * (21 - 2 * α) ^ 13 + 240138761499155563910895585654 * α ^ 6 * (21 - 2 * α) ^ 12 + 1837366344267267569709080196468 * α ^ 7 * (21 - 2 * α) ^ 11 + 10104702475479597929008103413095 * α ^ 8 * (21 - 2 * α) ^ 10 + 37641802639366180553916149163576 * α ^ 9 * (21 - 2 * α) ^ 9 + 88449061215859475411346373536264 * α ^ 10 * (21 - 2 * α) ^ 8 + 113640861426905556745222707601920 * α ^ 11 * (21 - 2 * α) ^ 7 + 55669273871103476657042199021792 * α ^ 12 * (21 - 2 * α) ^ 6 + 99281941699214882417362945572096 * α ^ 13 * (21 - 2 * α) ^ 5 + 654986082897929475911576119281408 * α ^ 14 * (21 - 2 * α) ^ 4 + 1538940561324052318678745687107584 * α ^ 15 * (21 - 2 * α) ^ 3 + 1719020178639381082845279983473152 * α ^ 16 * (21 - 2 * α) ^ 2 + 910135906460129539245476343896064 * α ^ 17 * (21 - 2 * α) ^ 1 + 165769381149578270034391223083008 * α ^ 18 := by - bernstein_ring α (21 - 2 * α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (21 - 2 * α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `20 ≤ n ≤ 22`.** -/ -theorem finite_range {n : ℕ} (h0 : 20 ≤ n) (h1 : n ≤ 22) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 21 / 2 := by - have hcast : ((n : ℕ) : ℝ) ≤ (22 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (22 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 19) + 1 / (4 * 19 * (3 + α)) - + (1 - 2 * α / 21) ^ 2 * 22 * 21 * (22 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 19 * (3 + α)) ^ 8)) - = 1 - (721140310389707127738 + 2170180610909239016088 * α + 2889750967198268814324 * α ^ 2 + 2227128338977232972904 * α ^ 3 + 1085997068794302710391 * α ^ 4 + 339049376116278228288 * α ^ 5 + 60509700204282383346 * α ^ 6 - 1038039442012938636 * α ^ 7 - 14060791839010189905 * α ^ 8 + 1774506642858471852 * α ^ 9 + 45855210342618468 * α ^ 10 + 226538249017920 * α ^ 11 - 222291771124416 * α ^ 12 - 18538380993792 * α ^ 13 - 787852835840 * α ^ 14 - 20286313472 * α ^ 15 - 320448768 * α ^ 16 - 2874368 * α ^ 17 - 11264 * α ^ 18) / (53913369794124204 * (3 + α) ^ 9) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 20) (n₁ := 22) (k := 8) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B20_22 - -end Sendov diff --git a/Sendov/FiniteRange/Degree22_24.lean b/Sendov/FiniteRange/Degree22_24.lean deleted file mode 100644 index ab7800d..0000000 --- a/Sendov/FiniteRange/Degree22_24.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 22 to 24 - -`Sendov.R_le_batch` bounds every `R n α` for `22 ≤ n ≤ 24` by the elementary part and -moment at `n₀ = 22` together with the prefactor at `n₁ = 24`, so one moment and one -certificate serve all 3 degrees. The certificate has degree 20, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B22_24 - -lemma M_lo : M 22 = 21 := by norm_num [M] - -lemma M_hi : M 24 = 23 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 22 α = 1 - 2 * α / 21 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 24 α = 1 - 2 * α / 23 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 22 α = (126 + 15 * α - 2 * α ^ 2) / (42 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 23 / 2) : 0 ≤ c 22 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 232792560 - -def betac : ℤ := 5774500618193131865874939367342081 - -def tauc : ℤ := 52113403406617399568675768890198434300892440730552860468456457359822812916403957981341978999482593278271409269805645884496135649846419759057009193613300612144616769946235123570814826138813253665092373673643274802319253928901325155969193585802030603998557856484812350076171944041251538965089353404668598911589180101281800066659429973404184827536244361717247282601231552544467258823560691375175811619171316787642443135211274745052812281973726028703612636651711022615997355506630751683900551998989656240038929214649085265235953918608516395993601881499081882159387466173626361142174157279677614740584272959889365094896808211158507170847555638174887653568352512765279104934288526037600114288775668310037707312009671168290779571054910498924756815599827889354729460340914561182011034734511085509420346820352631874830950754461420175060450633533746353185246669199140615772136375726619739932952117888587198162177055098653469266065620379085335980107485574263048810931409342867852289 - -/-- The moment numerator at `n₀ = 22`, `k = 9`. -/ -def Nmomc : List ℤ := - [63683904221147656083456, 258124956324931816114176, 484131886524725672024064, 558778379485145387968512, 446247743318805044026368, 264110065181693649515520, 122458189294350124959744, 47704848438469830322176, 18201381357540629025792, 13524983241127074966528, 1177792095898695426048, 74548634146090795008, 3411779294798364672, 112771637948841984, 2668046408810496, 44104655831040, 484339875840, 3177971712, 9437184] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 22) (gg1 22) (gg2 22) 9)) α := by - refine pev_moment_eq_of_packed_bounds 22 9 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 22 α t ^ 9) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 22 * (3 + α)) ^ 9) := - integral_moment_packed 22 9 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-20 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 20 * P α` is a positive combination of `αʲ (17-α)^(20-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 23 / 2) : - 0 < 72676691260477709153931 + 243335498910644300539743 * α + 365647629606098581621152 * α ^ 2 + 324203560761134112575706 * α ^ 3 + 187220150267586036026391 * α ^ 4 + 72995868351568741088853 * α ^ 5 + 18997181712653091143742 * α ^ 6 + 2912276075526675669294 * α ^ 7 - 47524187765551795452 * α ^ 8 - 572344038827543054862 * α ^ 9 + 60958599043408078986 * α ^ 10 + 1608150216459380292 * α ^ 11 + 37160884428953616 * α ^ 12 - 4770728942909184 * α ^ 13 - 508194774105984 * α ^ 14 - 24843494479104 * α ^ 15 - 745526594304 * α ^ 16 - 14490071808 * α ^ 17 - 179034112 * α ^ 18 - 1285120 * α ^ 19 - 4096 * α ^ 20 := by - have hu : (0 : ℝ) ≤ 23 - 2 * α := by linarith - have hid : (23 : ℝ) ^ 20 * (72676691260477709153931 + 243335498910644300539743 * α + 365647629606098581621152 * α ^ 2 + 324203560761134112575706 * α ^ 3 + 187220150267586036026391 * α ^ 4 + 72995868351568741088853 * α ^ 5 + 18997181712653091143742 * α ^ 6 + 2912276075526675669294 * α ^ 7 - 47524187765551795452 * α ^ 8 - 572344038827543054862 * α ^ 9 + 60958599043408078986 * α ^ 10 + 1608150216459380292 * α ^ 11 + 37160884428953616 * α ^ 12 - 4770728942909184 * α ^ 13 - 508194774105984 * α ^ 14 - 24843494479104 * α ^ 15 - 745526594304 * α ^ 16 - 14490071808 * α ^ 17 - 179034112 * α ^ 18 - 1285120 * α ^ 19 - 4096 * α ^ 20) = 72676691260477709153931 * (23 - 2 * α) ^ 20 + 8503784125363927278571329 * α ^ 1 * (23 - 2 * α) ^ 19 + 461337107467492327306312350 * α ^ 2 * (23 - 2 * α) ^ 18 + 15398943675157072979676921186 * α ^ 3 * (23 - 2 * α) ^ 17 + 353905086689575653155085657243 * α ^ 4 * (23 - 2 * α) ^ 16 + 5938058763785413089179396251875 * α ^ 5 * (23 - 2 * α) ^ 15 + 75246714147642299181739714271832 * α ^ 6 * (23 - 2 * α) ^ 14 + 734384442923791787182437424591542 * α ^ 7 * (23 - 2 * α) ^ 13 + 5562914983973677901584481691318984 * α ^ 8 * (23 - 2 * α) ^ 12 + 31773805113877239761694178561183806 * α ^ 9 * (23 - 2 * α) ^ 11 + 130856587563539007907893649077192702 * α ^ 10 * (23 - 2 * α) ^ 10 + 369427721563914607645637465073374604 * α ^ 11 * (23 - 2 * α) ^ 9 + 659851634553627022861170989844737856 * α ^ 12 * (23 - 2 * α) ^ 8 + 615817039503279914009940077569822464 * α ^ 13 * (23 - 2 * α) ^ 7 + 195270527269368587749778342774288064 * α ^ 14 * (23 - 2 * α) ^ 6 + 857988173853242270013037467185126784 * α ^ 15 * (23 - 2 * α) ^ 5 + 4220624235641254987215180793015588608 * α ^ 16 * (23 - 2 * α) ^ 4 + 8094967304722603824961003917794419968 * α ^ 17 * (23 - 2 * α) ^ 3 + 7807057971748984716263131834792835072 * α ^ 18 * (23 - 2 * α) ^ 2 + 3677240872883486972453388075862686720 * α ^ 19 * (23 - 2 * α) ^ 1 + 610286593660503076943530707277762560 * α ^ 20 := by - bernstein_ring α (23 - 2 * α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (23 - 2 * α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `22 ≤ n ≤ 24`.** -/ -theorem finite_range {n : ℕ} (h0 : 22 ≤ n) (h1 : n ≤ 24) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 23 / 2 := by - have hcast : ((n : ℕ) : ℝ) ≤ (24 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (24 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 21) + 1 / (4 * 21 * (3 + α)) - + (1 - 2 * α / 23) ^ 2 * 24 * 23 * (24 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 21 * (3 + α)) ^ 9)) - = 1 - (72676691260477709153931 + 243335498910644300539743 * α + 365647629606098581621152 * α ^ 2 + 324203560761134112575706 * α ^ 3 + 187220150267586036026391 * α ^ 4 + 72995868351568741088853 * α ^ 5 + 18997181712653091143742 * α ^ 6 + 2912276075526675669294 * α ^ 7 - 47524187765551795452 * α ^ 8 - 572344038827543054862 * α ^ 9 + 60958599043408078986 * α ^ 10 + 1608150216459380292 * α ^ 11 + 37160884428953616 * α ^ 12 - 4770728942909184 * α ^ 13 - 508194774105984 * α ^ 14 - 24843494479104 * α ^ 15 - 745526594304 * α ^ 16 - 14490071808 * α ^ 17 - 179034112 * α ^ 18 - 1285120 * α ^ 19 - 4096 * α ^ 20) / (1789880961368575530 * (3 + α) ^ 10) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 22) (n₁ := 24) (k := 9) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B22_24 - -end Sendov diff --git a/Sendov/FiniteRange/Degree24_26.lean b/Sendov/FiniteRange/Degree24_26.lean deleted file mode 100644 index b718164..0000000 --- a/Sendov/FiniteRange/Degree24_26.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 24 to 26 - -`Sendov.R_le_batch` bounds every `R n α` for `24 ≤ n ≤ 26` by the elementary part and -moment at `n₀ = 24` together with the prefactor at `n₁ = 26`, so one moment and one -certificate serve all 3 degrees. The certificate has degree 22, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B24_26 - -lemma M_lo : M 24 = 23 := by norm_num [M] - -lemma M_hi : M 26 = 25 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 24 α = 1 - 2 * α / 23 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 26 α = 1 - 2 * α / 25 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 24 α = (138 + 17 * α - 2 * α ^ 2) / (46 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 25 / 2) : 0 ≤ c 24 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 5354228880 - -def betac : ℤ := 207169535963896720099395591492729077761 - -def tauc : ℤ := 24758917493327576141462812677830183371567017132969978190017817116896159063010086182170935195315287986342487638387429295465163650234862127926057162085274681727759515125318949719302456675519000372761221361307915031805467809964014992419947663757588380429163324563529912415106411403011745947325590554409286979300143878596138510475391263611402561988747434102004049942580845088682763442977894869192016597214433416417711376775999926154464728822005557520196678362635217152684345650132590498266302261095946363984727012208457255987446595584067643160838527137552770639009495325056672536563117416826618301030883431417607618760856488445808986867630990003426706499628118824185435630199646483441722254000912895245767176245015981661120146759421315921372443124954613543593343478799715154456776919966756556228106088192297412170853978188023830339107067702315857956086036800427576964681682338544951425176804035838668391516955724735694385595874871472656729746521144495349830619658553076247959754553527964871466306663576806629616777965871520562804437537173211777684405725058238089451929907092518333933640346101136344586892938040988765007336451882866939262352917434034648884345143679115225022717302218543379275426810982214714060272108111873 - -/-- The moment numerator at `n₀ = 24`, `k = 10`. -/ -def Nmomc : List ℤ := - [315542595400376414343137280, 1372405704784856075197992960, 2771005826010710543999477760, 3451094280477455969590272000, 2974802471342849022363187200, 1892050373140518166434754560, 928743180964782053711800320, 367295306457255483092705280, 124654360837959477878768640, 42359986648106960612198400, 29853908180042393981322240, 2515924687236660357795840, 159168052874477224488960, 7480111606347618385920, 260880569954468167680, 6725742542668431360, 126534063532277760, 1689884884992000, 15189584117760, 82465259520, 204472320] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 24) (gg1 24) (gg2 24) 10)) α := by - refine pev_moment_eq_of_packed_bounds 24 10 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 24 α t ^ 10) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 24 * (3 + α)) ^ 10) := - integral_moment_packed 24 10 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-22 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 22 * P α` is a positive combination of `αʲ (17-α)^(22-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 25 / 2) : - 0 < 874071004010582953643568750 + 3221297610086019399669004500 * α + 5386914463346812349691460974 * α ^ 2 + 5391225879978445091101054368 * α ^ 3 + 3582299145670361769507272658 * α ^ 4 + 1654127651781089540379647100 * α ^ 5 + 537462463626302644652842710 * α ^ 6 + 120043033655516749475390448 * α ^ 7 + 16184849120135434020794931 * α ^ 8 - 222784389930881498880726 * α ^ 9 - 2725770297915674501126913 * α ^ 10 + 248640476833385673099320 * α ^ 11 + 6386094327528944247792 * α ^ 12 + 230085309479261626272 * α ^ 13 - 10099884196228450032 * α ^ 14 - 1569527054513950464 * α ^ 15 - 87896838917715456 * α ^ 16 - 2989402709094912 * α ^ 17 - 67703370254592 * α ^ 18 - 1033617561600 * α ^ 19 - 10281172992 * α ^ 20 - 60432384 * α ^ 21 - 159744 * α ^ 22 := by - have hu : (0 : ℝ) ≤ 25 - 2 * α := by linarith - have hid : (25 : ℝ) ^ 22 * (874071004010582953643568750 + 3221297610086019399669004500 * α + 5386914463346812349691460974 * α ^ 2 + 5391225879978445091101054368 * α ^ 3 + 3582299145670361769507272658 * α ^ 4 + 1654127651781089540379647100 * α ^ 5 + 537462463626302644652842710 * α ^ 6 + 120043033655516749475390448 * α ^ 7 + 16184849120135434020794931 * α ^ 8 - 222784389930881498880726 * α ^ 9 - 2725770297915674501126913 * α ^ 10 + 248640476833385673099320 * α ^ 11 + 6386094327528944247792 * α ^ 12 + 230085309479261626272 * α ^ 13 - 10099884196228450032 * α ^ 14 - 1569527054513950464 * α ^ 15 - 87896838917715456 * α ^ 16 - 2989402709094912 * α ^ 17 - 67703370254592 * α ^ 18 - 1033617561600 * α ^ 19 - 10281172992 * α ^ 20 - 60432384 * α ^ 21 - 159744 * α ^ 22) = 874071004010582953643568750 * (25 - 2 * α) ^ 22 + 118991564428616134952042137500 * α ^ 1 * (25 - 2 * α) ^ 21 + 7556825637887856737376275358750 * α ^ 2 * (25 - 2 * α) ^ 20 + 297326570539550302672678360350000 * α ^ 3 * (25 - 2 * α) ^ 19 + 8118326774696702494364871859181250 * α ^ 4 * (25 - 2 * α) ^ 18 + 163302166743534227801697447509662500 * α ^ 5 * (25 - 2 * α) ^ 17 + 2507454163520304052153861436880993750 * α ^ 6 * (25 - 2 * α) ^ 16 + 30047259752690844282111594563558670000 * α ^ 7 * (25 - 2 * α) ^ 15 + 284787676890052141286070572033915521875 * α ^ 8 * (25 - 2 * α) ^ 14 + 2146769361227978442422195176181338368750 * α ^ 9 * (25 - 2 * α) ^ 13 + 12630679896438305929175193655858187184375 * α ^ 10 * (25 - 2 * α) ^ 12 + 56067735566028501096437207497525020350000 * α ^ 11 * (25 - 2 * α) ^ 11 + 180631480948809558078622444236010586285000 * α ^ 12 * (25 - 2 * α) ^ 10 + 400779538225462244119560623305257108200000 * α ^ 13 * (25 - 2 * α) ^ 9 + 552145957044674175745646853887912448300000 * α ^ 14 * (25 - 2 * α) ^ 8 + 348851941562555217823842842079415684800000 * α ^ 15 * (25 - 2 * α) ^ 7 + 38623525300380552283361811907759716000000 * α ^ 16 * (25 - 2 * α) ^ 6 + 822237191651812497627267691867773310080000 * α ^ 17 * (25 - 2 * α) ^ 5 + 3269244329154715153428677298597459316800000 * α ^ 18 * (25 - 2 * α) ^ 4 + 5333912969812883272270527401813990707200000 * α ^ 19 * (25 - 2 * α) ^ 3 + 4537960847197188659144322307990683712000000 * α ^ 20 * (25 - 2 * α) ^ 2 + 1927546466544754214336332480358954905600000 * α ^ 21 * (25 - 2 * α) ^ 1 + 294013599962108674661431900766763888640000 * α ^ 22 := by - bernstein_ring α (25 - 2 * α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (25 - 2 * α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `24 ≤ n ≤ 26`.** -/ -theorem finite_range {n : ℕ} (h0 : 24 ≤ n) (h1 : n ≤ 26) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 25 / 2 := by - have hcast : ((n : ℕ) : ℝ) ≤ (26 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (26 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 23) + 1 / (4 * 23 * (3 + α)) - + (1 - 2 * α / 25) ^ 2 * 26 * 25 * (26 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 23 * (3 + α)) ^ 10)) - = 1 - (874071004010582953643568750 + 3221297610086019399669004500 * α + 5386914463346812349691460974 * α ^ 2 + 5391225879978445091101054368 * α ^ 3 + 3582299145670361769507272658 * α ^ 4 + 1654127651781089540379647100 * α ^ 5 + 537462463626302644652842710 * α ^ 6 + 120043033655516749475390448 * α ^ 7 + 16184849120135434020794931 * α ^ 8 - 222784389930881498880726 * α ^ 9 - 2725770297915674501126913 * α ^ 10 + 248640476833385673099320 * α ^ 11 + 6386094327528944247792 * α ^ 12 + 230085309479261626272 * α ^ 13 - 10099884196228450032 * α ^ 14 - 1569527054513950464 * α ^ 15 - 87896838917715456 * α ^ 16 - 2989402709094912 * α ^ 17 - 67703370254592 * α ^ 18 - 1033617561600 * α ^ 19 - 10281172992 * α ^ 20 - 60432384 * α ^ 21 - 159744 * α ^ 22) / (7109199446723183525100 * (3 + α) ^ 11) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 24) (n₁ := 26) (k := 10) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B24_26 - -end Sendov diff --git a/Sendov/FiniteRange/Degree26_27.lean b/Sendov/FiniteRange/Degree26_27.lean deleted file mode 100644 index 305f88a..0000000 --- a/Sendov/FiniteRange/Degree26_27.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 26 to 27 - -`Sendov.R_le_batch` bounds every `R n α` for `26 ≤ n ≤ 27` by the elementary part and -moment at `n₀ = 26` together with the prefactor at `n₁ = 27`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 24, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B26_27 - -lemma M_lo : M 26 = 25 := by norm_num [M] - -lemma M_hi : M 27 = 26 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 26 α = 1 - 2 * α / 25 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 27 α = 1 - 2 * α / 26 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 26 α = (150 + 19 * α - 2 * α ^ 2) / (50 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 13) : 0 ≤ c 26 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 26771144400 - -def betac : ℤ := 1783830525058754873813927954496295998259201 - -def tauc : ℤ := 23426572919250358783308645088514096201907298946352897748420557318295560941193237193481474904479676507235935263934128419339816950931912560529278042932005772751405963580738343515971252578375924231322508638209932983278865403601836924469699299185781558512016310985120648696496903050071375094251993160525383979303436925169405700243168630263285364965916563320840867533638639188195556282390771540934749261204812851534059341575157575252934491445215643696886058144930715361287076189918238365061783293733182169624688960662814475857067626280716303739779684800711427637917201246110576534885990336144360077173687905062225767049125796030021289925520567730007414463075240289309716289928856064417592548457359521565936815601030204593660862605647240515808652303969306905502702984285254895257424679429717404024747860957388879014385939099599783170944462854881902026569777020494419501512315474114759944056031563655751368519541489944629007560751816588600670400896829921018947925643314402315832165322391344751325424403921339329436943427897029015707284432511082017882091873937231501792437802894038023374955974821214509770321538498329552914826848712197074012846676359735870753167933984550834912923876156995604766769165987975116064666882493340972549121546218645558444611887271837237540852012659310936267952963001977363725916770869697860848704958482952833508425805004937470898243688742697829762944276107615778260972397757154046902387437813567395673071696864805128522088736582576223961868661485569 - -/-- The moment numerator at `n₀ = 26`, `k = 11`. -/ -def Nmomc : List ℤ := - [387230540361328125000000000000, 1801421059826953125000000000000, 3904034368858593750000000000000, 5235740547776268750000000000000, 4871336229481255875000000000000, 3345092202866735673000000000000, 1764975677650708972680000000000, 739008187884024802920000000000, 254413431645839068505760000000, 76379200780785652242028800000, 23390602747025993261119180800, 15823934861267894578878025728, 1286548783877635655383412736, 80855955782052201389506560, 3865275530870070676930560, 140238044038251091722240, 3855363400170394877952, 79769530465684291584, 1222691757773291520, 13471923877969920, 100958947246080, 461050478592, 968884224] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 26) (gg1 26) (gg2 26) 11)) α := by - refine pev_moment_eq_of_packed_bounds 26 11 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 26 α t ^ 11) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 26 * (3 + α)) ^ 11) := - integral_moment_packed 26 11 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-24 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 24 * P α` is a positive combination of `αʲ (17-α)^(24-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 13) : - 0 < 750669183453805732727050781250 + 3020533706655215263366699218750 * α + 5564839729610338783264160156250 * α ^ 2 + 6204652935907732786560058593750 * α ^ 3 + 4659850847351595430480957031250 * α ^ 4 + 2480313988118708551463378906250 * α ^ 5 + 956953438533800725637460937500 * α ^ 6 + 267988469385291406396875000000 * α ^ 7 + 53061280626889862612388984375 * α ^ 8 + 6649776660279075672227540625 * α ^ 9 + 67029306131497703210255025 * α ^ 10 - 797547671168471728584421521 * α ^ 11 + 69793209950586805764791132 * α ^ 12 + 1582701213221515173844854 * α ^ 13 + 64909025019891545058702 * α ^ 14 - 1621590589357829572680 * α ^ 15 - 347824272218530328424 * α ^ 16 - 21365270620680629952 * α ^ 17 - 794207858493279744 * α ^ 18 - 20077534583212032 * α ^ 19 - 355351304655360 * α ^ 20 - 4364532094464 * α ^ 21 - 35609836032 * α ^ 22 - 174127104 * α ^ 23 - 387072 * α ^ 24 := by - have hu : (0 : ℝ) ≤ 13 - α := by linarith - have hid : (13 : ℝ) ^ 24 * (750669183453805732727050781250 + 3020533706655215263366699218750 * α + 5564839729610338783264160156250 * α ^ 2 + 6204652935907732786560058593750 * α ^ 3 + 4659850847351595430480957031250 * α ^ 4 + 2480313988118708551463378906250 * α ^ 5 + 956953438533800725637460937500 * α ^ 6 + 267988469385291406396875000000 * α ^ 7 + 53061280626889862612388984375 * α ^ 8 + 6649776660279075672227540625 * α ^ 9 + 67029306131497703210255025 * α ^ 10 - 797547671168471728584421521 * α ^ 11 + 69793209950586805764791132 * α ^ 12 + 1582701213221515173844854 * α ^ 13 + 64909025019891545058702 * α ^ 14 - 1621590589357829572680 * α ^ 15 - 347824272218530328424 * α ^ 16 - 21365270620680629952 * α ^ 17 - 794207858493279744 * α ^ 18 - 20077534583212032 * α ^ 19 - 355351304655360 * α ^ 20 - 4364532094464 * α ^ 21 - 35609836032 * α ^ 22 - 174127104 * α ^ 23 - 387072 * α ^ 24) = 750669183453805732727050781250 * (13 - α) ^ 24 + 57282998589409136009216308593750 * α ^ 1 * (13 - α) ^ 23 + 2050782187227307000350952148437500 * α ^ 2 * (13 - α) ^ 22 + 45775586403380034332501220703125000 * α ^ 3 * (13 - α) ^ 21 + 714118209031145161147786743164062500 * α ^ 4 * (13 - α) ^ 20 + 8273284316298011107371657322265625000 * α ^ 5 * (13 - α) ^ 19 + 73835510530487101104526833122402343750 * α ^ 6 * (13 - α) ^ 18 + 519733885027019750587474273435957031250 * α ^ 7 * (13 - α) ^ 17 + 2930800059791589030908400058323199921875 * α ^ 8 * (13 - α) ^ 16 + 13372402464675670629912241174388163590625 * α ^ 9 * (13 - α) ^ 15 + 49616523603298906478895841666067082338100 * α ^ 10 * (13 - α) ^ 14 + 148533037390768639293168587946346173784998 * α ^ 11 * (13 - α) ^ 13 + 352390650499030404141412366217263718435741 * α ^ 12 * (13 - α) ^ 12 + 649782112359758546338767005837625709617885 * α ^ 13 * (13 - α) ^ 11 + 915968039619170700348192462171799252793910 * α ^ 14 * (13 - α) ^ 10 + 976506256524831093733472748853893192499190 * α ^ 15 * (13 - α) ^ 9 + 793928461670457408996135461409947476637907 * α ^ 16 * (13 - α) ^ 8 + 532094243038671655145113443710174863949229 * α ^ 17 * (13 - α) ^ 7 + 362157082250568977592235276631536616142420 * α ^ 18 * (13 - α) ^ 6 + 282315964683600802659165217851025305107370 * α ^ 19 * (13 - α) ^ 5 + 202899768509895477280344720514446057053655 * α ^ 20 * (13 - α) ^ 4 + 106150121400148174823355428864276604237047 * α ^ 21 * (13 - α) ^ 3 + 35288625801200476947393636186470118639744 * α ^ 22 * (13 - α) ^ 2 + 6423617838051124838400000000000000000000 * α ^ 23 * (13 - α) ^ 1 + 451304798929131929600000000000000000000 * α ^ 24 := by - bernstein_ring α (13 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (13 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `26 ≤ n ≤ 27`.** -/ -theorem finite_range {n : ℕ} (h0 : 26 ≤ n) (h1 : n ≤ 27) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 13 := by - have hcast : ((n : ℕ) : ℝ) ≤ (27 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (27 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 25) + 1 / (4 * 25 * (3 + α)) - + (1 - 2 * α / 26) ^ 2 * 27 * 26 * (27 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 25 * (3 + α)) ^ 11)) - = 1 - (750669183453805732727050781250 + 3020533706655215263366699218750 * α + 5564839729610338783264160156250 * α ^ 2 + 6204652935907732786560058593750 * α ^ 3 + 4659850847351595430480957031250 * α ^ 4 + 2480313988118708551463378906250 * α ^ 5 + 956953438533800725637460937500 * α ^ 6 + 267988469385291406396875000000 * α ^ 7 + 53061280626889862612388984375 * α ^ 8 + 6649776660279075672227540625 * α ^ 9 + 67029306131497703210255025 * α ^ 10 - 797547671168471728584421521 * α ^ 11 + 69793209950586805764791132 * α ^ 12 + 1582701213221515173844854 * α ^ 13 + 64909025019891545058702 * α ^ 14 - 1621590589357829572680 * α ^ 15 - 347824272218530328424 * α ^ 16 - 21365270620680629952 * α ^ 17 - 794207858493279744 * α ^ 18 - 20077534583212032 * α ^ 19 - 355351304655360 * α ^ 20 - 4364532094464 * α ^ 21 - 35609836032 * α ^ 22 - 174127104 * α ^ 23 - 387072 * α ^ 24) / (2011529617309570312500000 * (3 + α) ^ 12) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 26) (n₁ := 27) (k := 11) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B26_27 - -end Sendov diff --git a/Sendov/FiniteRange/Degree28_29.lean b/Sendov/FiniteRange/Degree28_29.lean deleted file mode 100644 index 9155e27..0000000 --- a/Sendov/FiniteRange/Degree28_29.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 28 to 29 - -`Sendov.R_le_batch` bounds every `R n α` for `28 ≤ n ≤ 29` by the elementary part and -moment at `n₀ = 28` together with the prefactor at `n₁ = 29`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 26, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B28_29 - -lemma M_lo : M 28 = 27 := by norm_num [M] - -lemma M_hi : M 29 = 28 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 28 α = 1 - 2 * α / 27 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 29 α = 1 - 2 * α / 28 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 28 α = (162 + 21 * α - 2 * α ^ 2) / (54 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 14) : 0 ≤ c 28 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 80313433200 - -def betac : ℤ := 10084728626050199397228352592884540009031270401 - -def tauc : ℤ := 1715742150364513412056474547880281547058544185485886742010966490749534934875001179036758791154093298174460044133361383845435871198123394677969978458044607063442117861532457784033033577126980178811408061492922772990001749378790648083730111990133362365288003227032215494657458071331399806759131827194971478978320801040273303421279657969821098670941715573037934816303597054833246537937801006021080258067427759724363125440262317135855285805543706087625112685588429741162242648391448352140222250859841078376519158301915019386890649800419678437010241954576184674538963292148016707905364501806298995153954945639239453526565922414707560982122206746995233754452064141334669982558988545901816794000601891958968141365771110214760541028723343835487545280792997956015703171798767685818824290550047715915996570523642245796805055406635327139682299812193782306348936307346841740389168297423362993751698554883608436164749927770266088455499905731200529283658651223543114794235737501871179858416176859317105941027801895549371766822601329498605200575275885654734960432291576689066864538427755135894844801717231776395915636796412889887994054190321537865476647308316425272598857663174691972234835274251003783521955647050613206967830396884919924937703871446290690157079264225965029365981426264032169691913211564504034740313878734977785955911767507785790552130207009840321800736593722504657422890658595338464082986887216849598623733053004561779593247160872463841176510729112419938113986701194682690494366278218548650749338978591863499386730771289846472630878189435860492510753032203622802413819528387840853655880370774461068166429448823181619720038787996286093142524761737886432830731426650106122260932547333498729164436021072675366328917068238860791756084355073 - -/-- The moment numerator at `n₀ = 28`, `k = 12`. -/ -def Nmomc : List ℤ := - [320394066090341726626971528019968, 1589072018612322895347942522224640, 3684522205733863644552552635105280, 5305366963409803496664296045543424, 5316971788818368572690063365120000, 3942149995287104135031359579160576, 2246432710663378622439556656168960, 1011378178659594802098718608261120, 368720458747778191229547356971008, 112230408493564203033749492858880, 30163249869517511053432152293376, 8402971408578265741863489699840, 5512464281177584575038052249600, 431363267663376638566268633088, 26803056329325193714482216960, 1294129542064434244268064768, 48342713099187473998479360, 1395965397073125090263040, 31055871458551947853824, 527438829380142366720, 6716454118785810432, 62110080958464000, 394042445660160, 1534712610816, 2768240640] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 28) (gg1 28) (gg2 28) 12)) α := by - refine pev_moment_eq_of_packed_bounds 28 12 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 28 α t ^ 12) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 28 * (3 + α)) ^ 12) := - integral_moment_packed 28 12 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-26 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 26 * P α` is a positive combination of `αʲ (17-α)^(26-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 14) : - 0 < 426450318135882438427115499581616 + 1858834576882378710373815569972592 * α + 3736799374885893548337894566091516 * α ^ 2 + 4586209917810757974592827719731488 * α ^ 3 + 3832530771213891318426391118558376 * α ^ 4 + 2301315780911216714788724083158840 * α ^ 5 + 1020320104787175718704940125987654 * α ^ 6 + 337351267574328588560584527446352 * α ^ 7 + 82684042360278469454015755593696 * α ^ 8 + 14571761439373687941870063150072 * α ^ 9 + 1651893249078514632421437650658 * α ^ 10 + 16915365961758038105007429024 * α ^ 11 - 175858786927760049854457800868 * α ^ 12 + 13481653528168191298544554836 * α ^ 13 + 281552860237833486968732937 * α ^ 14 + 14047072236623243173813992 * α ^ 15 - 9139934377157415820848 * α ^ 16 - 45943869853012600689984 * α ^ 17 - 3291728447735177292432 * α ^ 18 - 135117714229500881664 * α ^ 19 - 3776901841060823808 * α ^ 20 - 75424649382531072 * α ^ 21 - 1084454315870976 * α ^ 22 - 11022972807168 * α ^ 23 - 75437817856 * α ^ 24 - 312639488 * α ^ 25 - 593920 * α ^ 26 := by - have hu : (0 : ℝ) ≤ 14 - α := by linarith - have hid : (14 : ℝ) ^ 26 * (426450318135882438427115499581616 + 1858834576882378710373815569972592 * α + 3736799374885893548337894566091516 * α ^ 2 + 4586209917810757974592827719731488 * α ^ 3 + 3832530771213891318426391118558376 * α ^ 4 + 2301315780911216714788724083158840 * α ^ 5 + 1020320104787175718704940125987654 * α ^ 6 + 337351267574328588560584527446352 * α ^ 7 + 82684042360278469454015755593696 * α ^ 8 + 14571761439373687941870063150072 * α ^ 9 + 1651893249078514632421437650658 * α ^ 10 + 16915365961758038105007429024 * α ^ 11 - 175858786927760049854457800868 * α ^ 12 + 13481653528168191298544554836 * α ^ 13 + 281552860237833486968732937 * α ^ 14 + 14047072236623243173813992 * α ^ 15 - 9139934377157415820848 * α ^ 16 - 45943869853012600689984 * α ^ 17 - 3291728447735177292432 * α ^ 18 - 135117714229500881664 * α ^ 19 - 3776901841060823808 * α ^ 20 - 75424649382531072 * α ^ 21 - 1084454315870976 * α ^ 22 - 11022972807168 * α ^ 23 - 75437817856 * α ^ 24 - 312639488 * α ^ 25 - 593920 * α ^ 26) = 426450318135882438427115499581616 * (14 - α) ^ 26 + 37111392347886245344338420968738304 * α ^ 1 * (14 - α) ^ 25 + 1521601132780629476593875321808369536 * α ^ 2 * (14 - α) ^ 24 + 39078340323995248057144700994634782336 * α ^ 3 * (14 - α) ^ 23 + 705051187055396740500579766777381514208 * α ^ 4 * (14 - α) ^ 22 + 9500322353274936154789534542408692441472 * α ^ 5 * (14 - α) ^ 21 + 99235235865063211599523391118038843304768 * α ^ 6 * (14 - α) ^ 20 + 823320752785879259967748712211136296143232 * α ^ 7 * (14 - α) ^ 19 + 5515721851061510718162550472414882027285712 * α ^ 8 * (14 - α) ^ 18 + 30174754728220837604457187088268784920537216 * α ^ 9 * (14 - α) ^ 17 + 135797159637259310387481461578932353970581952 * α ^ 10 * (14 - α) ^ 16 + 504664886820509810760132037456041458875523328 * α ^ 11 * (14 - α) ^ 15 + 1540639091909534601865038875378381140958117952 * α ^ 12 * (14 - α) ^ 14 + 3809796887220625879921007425681056060029021952 * α ^ 13 * (14 - α) ^ 13 + 7501791404136392824573180146400956404327039616 * α ^ 14 * (14 - α) ^ 12 + 11572714929523078093880359132036853394473485056 * α ^ 15 * (14 - α) ^ 11 + 13789723758378925038095275082223262786347860304 * α ^ 16 * (14 - α) ^ 10 + 12582251901524132212672360901736009892398456576 * α ^ 17 * (14 - α) ^ 9 + 8935758721652166554311189913325631720840187136 * α ^ 18 * (14 - α) ^ 8 + 5484179813557289010393355638182801357129728128 * α ^ 19 * (14 - α) ^ 7 + 3657829613491729305512570847707150262111504864 * α ^ 20 * (14 - α) ^ 6 + 2783234625894929033925209345455919590486513536 * α ^ 21 * (14 - α) ^ 5 + 1864845683118524255504101199017909275287974464 * α ^ 22 * (14 - α) ^ 4 + 893973882849468086668452977297233134024522624 * α ^ 23 * (14 - α) ^ 3 + 272658852549522790950799560990477918176209712 * α ^ 24 * (14 - α) ^ 2 + 45835418967464600203531300713422486095708800 * α ^ 25 * (14 - α) ^ 1 + 3000012367952955673085245642674753894705600 * α ^ 26 := by - bernstein_ring α (14 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (14 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `28 ≤ n ≤ 29`.** -/ -theorem finite_range {n : ℕ} (h0 : 28 ≤ n) (h1 : n ≤ 29) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 14 := by - have hcast : ((n : ℕ) : ℝ) ≤ (29 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (29 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 27) + 1 / (4 * 27 * (3 + α)) - + (1 - 2 * α / 28) ^ 2 * 29 * 28 * (29 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 27 * (3 + α)) ^ 12)) - = 1 - (426450318135882438427115499581616 + 1858834576882378710373815569972592 * α + 3736799374885893548337894566091516 * α ^ 2 + 4586209917810757974592827719731488 * α ^ 3 + 3832530771213891318426391118558376 * α ^ 4 + 2301315780911216714788724083158840 * α ^ 5 + 1020320104787175718704940125987654 * α ^ 6 + 337351267574328588560584527446352 * α ^ 7 + 82684042360278469454015755593696 * α ^ 8 + 14571761439373687941870063150072 * α ^ 9 + 1651893249078514632421437650658 * α ^ 10 + 16915365961758038105007429024 * α ^ 11 - 175858786927760049854457800868 * α ^ 12 + 13481653528168191298544554836 * α ^ 13 + 281552860237833486968732937 * α ^ 14 + 14047072236623243173813992 * α ^ 15 - 9139934377157415820848 * α ^ 16 - 45943869853012600689984 * α ^ 17 - 3291728447735177292432 * α ^ 18 - 135117714229500881664 * α ^ 19 - 3776901841060823808 * α ^ 20 - 75424649382531072 * α ^ 21 - 1084454315870976 * α ^ 22 - 11022972807168 * α ^ 23 - 75437817856 * α ^ 24 - 312639488 * α ^ 25 - 593920 * α ^ 26) / (378820688032445824710417600 * (3 + α) ^ 13) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 28) (n₁ := 29) (k := 12) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B28_29 - -end Sendov diff --git a/Sendov/FiniteRange/Degree30_31.lean b/Sendov/FiniteRange/Degree30_31.lean deleted file mode 100644 index 4e00296..0000000 --- a/Sendov/FiniteRange/Degree30_31.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 30 to 31 - -`Sendov.R_le_batch` bounds every `R n α` for `30 ≤ n ≤ 31` by the elementary part and -moment at `n₀ = 30` together with the prefactor at `n₁ = 31`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 28, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B30_31 - -lemma M_lo : M 30 = 29 := by norm_num [M] - -lemma M_hi : M 31 = 30 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 30 α = 1 - 2 * α / 29 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 31 α = 1 - 2 * α / 30 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 30 α = (174 + 23 * α - 2 * α ^ 2) / (58 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 15) : 0 ≤ c 30 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 2329089562800 - -def betac : ℤ := 598643820467341015032219325183684189288396023398401 - -def tauc : ℤ := 313850242117165526650057005049659380340602300607264734706751762579985238369003696776656025895110483887512952258918711367260447692593169223245297215997329463391592278672937106416971149249576928266196583897794299661174183542769842937665601101816118968928169639468359562936803422510662555568808155547798207495587618573478298122314828773131772137494354477397719603766155387068602362905322078199765925651080440530828893076842891569714751410916199002587856298293411213419942943539556894629650945763482039353094667525663851613251965840663818376323714388937533365481859210042531760661388900808376072960247609586393632095800132635917191215415310754308034666397354044012524804747972717796100068405752989898881184832098931329040699271697384648521582655575488102500998160898505044763821428523921248671257577457057705751189013971493323778503638450081530649374231458959183506087119687549483886995350389384354143420510736044613268168898656265722364583802438806454162456531327968866852321870409041859279475871256769512333068977228715481431688179019055342979271313410440219422864945776381686208443149402638883441047527626705973620191646383332224641150550455235226232748604765803993122480287285931600553956494659263480356219432050775783412586901427996712930236992964977979041787771425097188554229106539531190205096348898417164945566245392219837163113468478614638434685266653300362261314174482280861578177711357069976776958392438372631560517772531723675067717092739557143191621876087076700922459966486411162773503421463876089595605655264782418923898518977895173135352813515962536850868137384003416368476179180164228767245148235772674001500230437958212333543577424229290798547485635552088876368829646471619196521567644669785630021461050002751776580231604037096365894537663767669371760278789433958186250470589975450787184982780538779039416576384404586706971226291703499032900226157670093935921508252826529235585694270926120722633432998039540761399535568163244001145334929775205095422405699020167355302416905629561607882315156742733719599888340753360338207843043754472825653520003648019939329 - -/-- The moment numerator at `n₀ = 30`, `k = 13`. -/ -def Nmomc : List ℤ := - [2847322232222377079130299295548866560, 15008988226404392281484543183203565568, 37112008475173470993393263682783510528, 57188567882381822904060946628509335552, 61554387606037947478868681903502606336, 49175417644995034753823426546066964480, 30266999921668094875538981840926900224, 14722581654107051388196649173533425664, 5773724410165756723566084202262839296, 1861804093815965861828856484560027648, 507213355867117246883967915154784256, 123214822854564441785750257598152704, 31464019263956737516909155495370752, 20191362054204790435940152444264448, 1517931070679596171060122428145664, 92893271780986750639134682054656, 4504919947918335797971976716288, 171916708762615946808838455296, 5157244460346339035650719744, 121426254799723639395581952, 2232336341894261335130112, 31693716069507391291392, 340723585068751126528, 2682523919058993152, 14594536705622016, 49052855042048, 76772540416] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 30) (gg1 30) (gg2 30) 13)) α := by - refine pev_moment_eq_of_packed_bounds 30 13 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 30 α t ^ 13) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 30 * (3 + α)) ^ 13) := - integral_moment_packed 30 13 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-28 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 28 * P α` is a positive combination of `αʲ (17-α)^(28-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 15) : - 0 < 586577450963685326737168897370707500 + 2753132994648490979146101875384719500 * α + 5996201651556610186353013706234776680 * α ^ 2 + 8030975436338556704707041798612128472 * α ^ 3 + 7388055615126493367424454764006350082 * α ^ 4 + 4936598337528514606768767094265091378 * α ^ 5 + 2469192037754886771172170203022293214 * α ^ 6 + 938102920031818441360780570553215590 * α ^ 7 + 271392183919032658980825616039479546 * α ^ 8 + 59155996945930238392567631443933866 * α ^ 9 + 9399459563896087929210688264754844 * α ^ 10 + 974977535533292148502665510758532 * α ^ 11 + 10861549420545366403779627757839 * α ^ 12 - 92622867478166716461279291384369 * α ^ 13 + 6300099969105231240951104525763 * α ^ 14 + 117642575887863777951373952647 * α ^ 15 + 6754895556059983986318667916 * α ^ 16 + 94553344499679709104836184 * α ^ 17 - 13437772607038842242965408 * α ^ 18 - 1178131104153353973775376 * α ^ 19 - 53368378574787271805184 * α ^ 20 - 1629770789867125896192 * α ^ 21 - 35941441812526263552 * α ^ 22 - 584181453145681152 * α ^ 23 - 6973783723783168 * α ^ 24 - 59692780623872 * α ^ 25 - 347727077376 * α ^ 26 - 1237127168 * α ^ 27 - 2031616 * α ^ 28 := by - have hu : (0 : ℝ) ≤ 15 - α := by linarith - have hid : (15 : ℝ) ^ 28 * (586577450963685326737168897370707500 + 2753132994648490979146101875384719500 * α + 5996201651556610186353013706234776680 * α ^ 2 + 8030975436338556704707041798612128472 * α ^ 3 + 7388055615126493367424454764006350082 * α ^ 4 + 4936598337528514606768767094265091378 * α ^ 5 + 2469192037754886771172170203022293214 * α ^ 6 + 938102920031818441360780570553215590 * α ^ 7 + 271392183919032658980825616039479546 * α ^ 8 + 59155996945930238392567631443933866 * α ^ 9 + 9399459563896087929210688264754844 * α ^ 10 + 974977535533292148502665510758532 * α ^ 11 + 10861549420545366403779627757839 * α ^ 12 - 92622867478166716461279291384369 * α ^ 13 + 6300099969105231240951104525763 * α ^ 14 + 117642575887863777951373952647 * α ^ 15 + 6754895556059983986318667916 * α ^ 16 + 94553344499679709104836184 * α ^ 17 - 13437772607038842242965408 * α ^ 18 - 1178131104153353973775376 * α ^ 19 - 53368378574787271805184 * α ^ 20 - 1629770789867125896192 * α ^ 21 - 35941441812526263552 * α ^ 22 - 584181453145681152 * α ^ 23 - 6973783723783168 * α ^ 24 - 59692780623872 * α ^ 25 - 347727077376 * α ^ 26 - 1237127168 * α ^ 27 - 2031616 * α ^ 28) = 586577450963685326737168897370707500 * (15 - α) ^ 28 + 57721163546710553835832257257150602500 * α ^ 1 * (15 - α) ^ 27 + 2685890510897149191990249186639763585500 * α ^ 2 * (15 - α) ^ 26 + 78599194705430136604146587933476363108500 * α ^ 3 * (15 - α) ^ 25 + 1622909997175605567337562554410307661576250 * α ^ 4 * (15 - α) ^ 24 + 25146768623114737087640078167646014091973750 * α ^ 5 * (15 - α) ^ 23 + 303641086695050391528892238082119715503670000 * α ^ 6 * (15 - α) ^ 22 + 2929031512855517774498282614444762020783307500 * α ^ 7 * (15 - α) ^ 21 + 22961042451753622392989015501956773126769350000 * α ^ 8 * (15 - α) ^ 20 + 148033957973212624082175754920221815579937805000 * α ^ 9 * (15 - α) ^ 19 + 791520488598836900068848830160917234498844101250 * α ^ 10 * (15 - α) ^ 18 + 3529526175327511018680726743043836767850893061250 * α ^ 11 * (15 - α) ^ 17 + 13165011207751367740633403433981725749824494296875 * α ^ 12 * (15 - α) ^ 16 + 40931653416291075198328442361012806391694992643125 * α ^ 13 * (15 - α) ^ 15 + 104936099346045749439240355737362583910582002551250 * α ^ 14 * (15 - α) ^ 14 + 218605526114400884612386873561624396579818747067500 * α ^ 15 * (15 - α) ^ 13 + 364544768185120783615020401898669737526038946860625 * α ^ 16 * (15 - α) ^ 12 + 479686011445303946308298171035582326066907836556875 * α ^ 17 * (15 - α) ^ 11 + 491421915359135714614282850386451786914114000492500 * α ^ 18 * (15 - α) ^ 10 + 389161288470744666432388567554714822581024179398750 * α ^ 19 * (15 - α) ^ 9 + 244558897556532361649184200629954946613489703141875 * α ^ 20 * (15 - α) ^ 8 + 139992773266086273600697845417718983669371612533125 * α ^ 21 * (15 - α) ^ 7 + 93042859490049901489480348991956175393389715291250 * α ^ 22 * (15 - α) ^ 6 + 69299238884896976481539054996360074995454890772500 * α ^ 23 * (15 - α) ^ 5 + 43491785146541891064576495824222890234435540966875 * α ^ 24 * (15 - α) ^ 4 + 19249688128515085853018716648633058220873114065625 * α ^ 25 * (15 - α) ^ 3 + 5426365264657811094720994999869461719092174416250 * α ^ 26 * (15 - α) ^ 2 + 847744461331358174965504508366152817665302528000 * α ^ 27 * (15 - α) ^ 1 + 51950222508646395464079311308157550857404416000 * α ^ 28 := by - bernstein_ring α (15 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (15 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `30 ≤ n ≤ 31`.** -/ -theorem finite_range {n : ℕ} (h0 : 30 ≤ n) (h1 : n ≤ 31) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 15 := by - have hcast : ((n : ℕ) : ℝ) ≤ (31 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (31 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 29) + 1 / (4 * 29 * (3 + α)) - + (1 - 2 * α / 30) ^ 2 * 31 * 30 * (31 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 29 * (3 + α)) ^ 13)) - = 1 - (586577450963685326737168897370707500 + 2753132994648490979146101875384719500 * α + 5996201651556610186353013706234776680 * α ^ 2 + 8030975436338556704707041798612128472 * α ^ 3 + 7388055615126493367424454764006350082 * α ^ 4 + 4936598337528514606768767094265091378 * α ^ 5 + 2469192037754886771172170203022293214 * α ^ 6 + 938102920031818441360780570553215590 * α ^ 7 + 271392183919032658980825616039479546 * α ^ 8 + 59155996945930238392567631443933866 * α ^ 9 + 9399459563896087929210688264754844 * α ^ 10 + 974977535533292148502665510758532 * α ^ 11 + 10861549420545366403779627757839 * α ^ 12 - 92622867478166716461279291384369 * α ^ 13 + 6300099969105231240951104525763 * α ^ 14 + 117642575887863777951373952647 * α ^ 15 + 6754895556059983986318667916 * α ^ 16 + 94553344499679709104836184 * α ^ 17 - 13437772607038842242965408 * α ^ 18 - 1178131104153353973775376 * α ^ 19 - 53368378574787271805184 * α ^ 20 - 1629770789867125896192 * α ^ 21 - 35941441812526263552 * α ^ 22 - 584181453145681152 * α ^ 23 - 6973783723783168 * α ^ 24 - 59692780623872 * α ^ 25 - 347727077376 * α ^ 26 - 1237127168 * α ^ 27 - 2031616 * α ^ 28) / (172881045887035525441599708000 * (3 + α) ^ 14) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 30) (n₁ := 31) (k := 13) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B30_31 - -end Sendov diff --git a/Sendov/FiniteRange/Degree32_33.lean b/Sendov/FiniteRange/Degree32_33.lean deleted file mode 100644 index 9ee8d11..0000000 --- a/Sendov/FiniteRange/Degree32_33.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 32 to 33 - -`Sendov.R_le_batch` bounds every `R n α` for `32 ≤ n ≤ 33` by the elementary part and -moment at `n₀ = 32` together with the prefactor at `n₁ = 33`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 30, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B32_33 - -lemma M_lo : M 32 = 31 := by norm_num [M] - -lemma M_hi : M 33 = 32 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 32 α = 1 - 2 * α / 31 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 33 α = 1 - 2 * α / 32 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 32 α = (186 + 25 * α - 2 * α ^ 2) / (62 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 16) : 0 ≤ c 32 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 144403552893600 - -def betac : ℤ := 82007696765268867835437188499033438694556468498477875201 - -def tauc : ℤ := 11220834733149688954612293109742648973001387154451110330123156527399318768219914009427040389573419330089012496936225973381709920634294003642375969365742269909757573221709274165665855385981378260916328014885300459954192590836737511798781516530920110334806452717059152969522774385782544994445581864012771746972419264195560038496724328005979307357063996450497475540051023865444074538646288043235878135164516820372854638573929523044656845224637905260038529606113200723256457067589570662749956705493088524454728773867121734748784360044645863093860636980281040976703704920097158583418016785786598284461258075797350403252577973236695549255529736258235803401946076216426944537534159434845672326042203813512991312833915414169314198352624531485106722959330481804239405773804713721099156756569706122764543224451108137327220613878159977730160046019378198425598975128071087464847770176811480591445476195564689914849507908314475498578313783972484938110814425211081753583206067112104699394299846702024076354419816542431785034211712503151831819511584532850033608138531277878135489742131248039288274399182892256288662834736634156974205687450543293076103338904621317463584346798436938157848255901275726272824078031021866569121210785117869737981327363841151371235907324739743037738787977357336167049091498145880104660986133747033516758859190599324505184286520301673792584081574368025824364869745480219715428340421221990980504109462898464382774312679761909744634091410317343370268030420561313305156939520225962796791258104750705903550557527707344354568269402661788485604936632256490100035670175497973228339428362927496728733499743376853095291447567203291034582638053710307592695945621828235369990237589891637707818734892756773412987401332687404983284298892729622111599221749066357673153354135919953456164013809016817887170940672331541966444627637552009490541512485765373591685496170630432525527159589147842963967083621367782046348918799509163813682634744713798260897457479460783984870242488656944413607131140476960274100829071802658264213997139734894210030513525730309971842364034443951256713554859748286700340305888953785910909639556456826292187991496503514793819981879281934796684729329535824953377586748163440808010681747302727135149356302760844924674664888320450778175079125338979147300716968634313571605954540774164164711985900302786400820269708439841076847144677128900309371540974439073636716729113102028873968037289905998906567295840237187811061131233881260033 - -/-- The moment numerator at `n₀ = 32`, `k = 14`. -/ -def Nmomc : List ℤ := - [59549678807292649512946334425511900528640, 332633928694180287562160607985754646282240, 874357221396134098503924595673384965718016, 1437215916574767695779984225513051597307904, 1655981085108700351581518840877610488741888, 1421279437533682215559284491686599602700288, 942904731021335273964534250725312620544000, 495570450295347165112518776609036805537792, 210065305835209750183615816849805443252224, 72900880436411011709388360514268131000320, 21051940200633711455379773064054625419264, 5184384391913613967393211532420375773184, 1147365126536241552058076182025236660224, 270261533019050260091375677677806714880, 170957647046487888392074218346393092096, 12329521206256007992296411221786165248, 740795443843781039280826784317112320, 35922463394092100452261251973644288, 1391964859628668587835861843050496, 43018694711760261985695689605120, 1059599602681625613272444043264, 20743364411796390715896889344, 320587066968098761875652608, 3862833671266323583205376, 35533610536988267511808, 241080240660923023360, 1137269403675525120, 3332196957945856, 4567966154752] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 32) (gg1 32) (gg2 32) 14)) α := by - refine pev_moment_eq_of_packed_bounds 32 14 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 32 α t ^ 14) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 32 * (3 + α)) ^ 14) := - integral_moment_packed 32 14 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-30 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 30 * P α` is a positive combination of `αʲ (17-α)^(30-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 16) : - 0 < 383977583360819576313951392966054557440 + 1930634984998770141470327139790256873760 * α + 4528139655529657241697903448404234220551 * α ^ 2 + 6571116743547522810411224078221219285242 * α ^ 3 + 6597373572981213714180223077765169741761 * α ^ 4 + 4853145290868457132481352533313124037136 * α ^ 5 + 2701279688513765542055333848381676518287 * α ^ 6 + 1157769823809425762972955166775789744790 * α ^ 7 + 384826365482239087514233918976406892725 * α ^ 8 + 98972460520277767374027328895457052524 * α ^ 9 + 19429030643214541979169516429755259903 * α ^ 10 + 2812337464920293963928011188383752346 * α ^ 11 + 269412053495826821775011955678389445 * α ^ 12 + 3352473026131557768885960806993016 * α ^ 13 - 22950931900671630187087717249723635 * α ^ 14 + 1401665499631441401236402118586466 * α ^ 15 + 22766380179065358125804378947555 * α ^ 16 + 1462014916628262060084862591156 * α ^ 17 + 35132359566977040523019407180 * α ^ 18 - 1604603346728872922022402944 * α ^ 19 - 192243388845480689610974960 * α ^ 20 - 9672937893957196503857344 * α ^ 21 - 320523259524150064257216 * α ^ 22 - 7695435702924730354176 * α ^ 23 - 138216454665665111296 * α ^ 24 - 1869603872239262720 * α ^ 25 - 18853950116959232 * α ^ 26 - 137859411329024 * α ^ 27 - 692050472960 * α ^ 28 - 2136915968 * α ^ 29 - 3063808 * α ^ 30 := by - have hu : (0 : ℝ) ≤ 16 - α := by linarith - have hid : (16 : ℝ) ^ 30 * (383977583360819576313951392966054557440 + 1930634984998770141470327139790256873760 * α + 4528139655529657241697903448404234220551 * α ^ 2 + 6571116743547522810411224078221219285242 * α ^ 3 + 6597373572981213714180223077765169741761 * α ^ 4 + 4853145290868457132481352533313124037136 * α ^ 5 + 2701279688513765542055333848381676518287 * α ^ 6 + 1157769823809425762972955166775789744790 * α ^ 7 + 384826365482239087514233918976406892725 * α ^ 8 + 98972460520277767374027328895457052524 * α ^ 9 + 19429030643214541979169516429755259903 * α ^ 10 + 2812337464920293963928011188383752346 * α ^ 11 + 269412053495826821775011955678389445 * α ^ 12 + 3352473026131557768885960806993016 * α ^ 13 - 22950931900671630187087717249723635 * α ^ 14 + 1401665499631441401236402118586466 * α ^ 15 + 22766380179065358125804378947555 * α ^ 16 + 1462014916628262060084862591156 * α ^ 17 + 35132359566977040523019407180 * α ^ 18 - 1604603346728872922022402944 * α ^ 19 - 192243388845480689610974960 * α ^ 20 - 9672937893957196503857344 * α ^ 21 - 320523259524150064257216 * α ^ 22 - 7695435702924730354176 * α ^ 23 - 138216454665665111296 * α ^ 24 - 1869603872239262720 * α ^ 25 - 18853950116959232 * α ^ 26 - 137859411329024 * α ^ 27 - 692050472960 * α ^ 28 - 2136915968 * α ^ 29 - 3063808 * α ^ 30) = 383977583360819576313951392966054557440 * (16 - α) ^ 30 + 42409487260804909552943776025625746703360 * α ^ 1 * (16 - α) ^ 29 + 2222048633616978115213463931594396882372096 * α ^ 2 * (16 - α) ^ 28 + 73473353083404174858760833498075355240412160 * α ^ 3 * (16 - α) ^ 27 + 1720652985002569694625940957603172487457959168 * α ^ 4 * (16 - α) ^ 26 + 30363605055601889844187715226554004982348216320 * α ^ 5 * (16 - α) ^ 25 + 419419313440566659766595274985269607940848110592 * α ^ 6 * (16 - α) ^ 24 + 4651028177520748697700758854373515125968713340928 * α ^ 7 * (16 - α) ^ 23 + 42137577409585697471273190015560150932516267552512 * α ^ 8 * (16 - α) ^ 22 + 315813162774288007921028011965819893459606590098432 * α ^ 9 * (16 - α) ^ 21 + 1975705535276134028928012252827490436823332026530304 * α ^ 10 * (16 - α) ^ 20 + 10382688588871544644830770347967881283088055308155904 * α ^ 11 * (16 - α) ^ 19 + 46032559619183787080156358678834876487940673091005696 * α ^ 12 * (16 - α) ^ 18 + 172591747559291476479103054798864248406917335500124160 * α ^ 13 * (16 - α) ^ 17 + 545974175950014920103132403616690663895819828147984384 * α ^ 14 * (16 - α) ^ 16 + 1445130613022938433929608617595105884579474631328108544 * α ^ 15 * (16 - α) ^ 15 + 3161509852911810407500355299058617164221708297980898560 * α ^ 16 * (16 - α) ^ 14 + 5640295189041616515165641512647513399952299862475037696 * α ^ 17 * (16 - α) ^ 13 + 8096357711013760274749679034695047723667449284765784576 * α ^ 18 * (16 - α) ^ 12 + 9222746840024741255973982987098297227268540123123805184 * α ^ 19 * (16 - α) ^ 11 + 8223039813167952720182093497637178426661494992975589120 * α ^ 20 * (16 - α) ^ 10 + 5704256351282499932163905647696347181598873537091336192 * α ^ 21 * (16 - α) ^ 9 + 3201419973312332497561890234813360990647765548239842304 * α ^ 22 * (16 - α) ^ 8 + 1740681060211180094425255735717618532157429256988792832 * α ^ 23 * (16 - α) ^ 7 + 1171781379026559228219387738006839365835033511446179072 * α ^ 24 * (16 - α) ^ 6 + 856349049543820949149124961191230752126749714115924992 * α ^ 25 * (16 - α) ^ 5 + 505504390045160314727256739583393494736411020808873472 * α ^ 26 * (16 - α) ^ 4 + 207885993237921287478858446074371829024853091294110720 * α ^ 27 * (16 - α) ^ 3 + 54498421679605652502910205539029441943284379111601920 * α ^ 28 * (16 - α) ^ 2 + 7954898798277651559977779244576588075469014026035200 * α ^ 29 * (16 - α) ^ 1 + 458384953904887998462676380172134968211581830656000 * α ^ 30 := by - bernstein_ring α (16 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (16 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `32 ≤ n ≤ 33`.** -/ -theorem finite_range {n : ℕ} (h0 : 32 ≤ n) (h1 : n ≤ 33) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 16 := by - have hcast : ((n : ℕ) : ℝ) ≤ (33 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (33 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 31) + 1 / (4 * 31 * (3 + α)) - + (1 - 2 * α / 32) ^ 2 * 33 * 32 * (33 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 31 * (3 + α)) ^ 14)) - = 1 - (383977583360819576313951392966054557440 + 1930634984998770141470327139790256873760 * α + 4528139655529657241697903448404234220551 * α ^ 2 + 6571116743547522810411224078221219285242 * α ^ 3 + 6597373572981213714180223077765169741761 * α ^ 4 + 4853145290868457132481352533313124037136 * α ^ 5 + 2701279688513765542055333848381676518287 * α ^ 6 + 1157769823809425762972955166775789744790 * α ^ 7 + 384826365482239087514233918976406892725 * α ^ 8 + 98972460520277767374027328895457052524 * α ^ 9 + 19429030643214541979169516429755259903 * α ^ 10 + 2812337464920293963928011188383752346 * α ^ 11 + 269412053495826821775011955678389445 * α ^ 12 + 3352473026131557768885960806993016 * α ^ 13 - 22950931900671630187087717249723635 * α ^ 14 + 1401665499631441401236402118586466 * α ^ 15 + 22766380179065358125804378947555 * α ^ 16 + 1462014916628262060084862591156 * α ^ 17 + 35132359566977040523019407180 * α ^ 18 - 1604603346728872922022402944 * α ^ 19 - 192243388845480689610974960 * α ^ 20 - 9672937893957196503857344 * α ^ 21 - 320523259524150064257216 * α ^ 22 - 7695435702924730354176 * α ^ 23 - 138216454665665111296 * α ^ 24 - 1869603872239262720 * α ^ 25 - 18853950116959232 * α ^ 26 - 137859411329024 * α ^ 27 - 692050472960 * α ^ 28 - 2136915968 * α ^ 29 - 3063808 * α ^ 30) / (37572885123356984842662119654400 * (3 + α) ^ 15) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 32) (n₁ := 33) (k := 14) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B32_33 - -end Sendov diff --git a/Sendov/FiniteRange/Degree34_35.lean b/Sendov/FiniteRange/Degree34_35.lean deleted file mode 100644 index 419c169..0000000 --- a/Sendov/FiniteRange/Degree34_35.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 34 to 35 - -`Sendov.R_le_batch` bounds every `R n α` for `34 ≤ n ≤ 35` by the elementary part and -moment at `n₀ = 34` together with the prefactor at `n₁ = 35`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 32, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B34_35 - -lemma M_lo : M 34 = 33 := by norm_num [M] - -lemma M_hi : M 35 = 34 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 34 α = 1 - 2 * α / 33 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 35 α = 1 - 2 * α / 34 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 34 α = (198 + 27 * α - 2 * α ^ 2) / (66 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 34 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 144403552893600 - -def betac : ℤ := 194532526637905659592465965962408920281731033564023672012801 - -def tauc : ℤ := 2648846650177651160958460533548336251549413056081861585991214700848211963588299166944562243121910369185768288356779921185861091533376649140462848229659781535753264495916387575914377965634027664758956576715212234934291724790051449830050092028166936996756922513261811405339352375781031791705543630407853229343943519066398602864090623433076848286975066028013480375503313023257592183883878705002878407408542286332762045424908011931522898328397507175333566644211313357088797116971134083348699877444823194494749070478343765527400278499886952686383921751419496990274765143435903238360763061060093460009765590938567656566774879791505394589844357987061439667249104769468067980999644327145983513415779904704573571638323843277715010515935594910547322578979583085468712828922406396658563332453948135511751331265916469232605883476915927536201218852543629643894943603200359968247257251029857518539202926607788483317007292148200754413631616766486962798637182133391069431746104385520762184756067296427418869746935207926516243534641805753102582090823338262762492566453899805207678055883899205603781963955740658794848063435273096987910611035361118631025097305180003829803362562139134442240028379208453203461889030349463846868457400819801687828538107799248699284215718150462259699660817520687804092757667853324808650843754293429497069871731359558428443750201931682671782436936489932890759205561533205675520428586618131018662168840170863151874969729901835578545558603769740923156150908870777714440877855603842847815106565754242192817628317031011719903067247487161961525637311329323205508400774519283964256794210663158436183386186628030302242647944856660376843483634791545684874432448904102613234022374983545427772482416570619154631010464320641707618934640154870581350522370940519094736558294859785300796324841650227525396918601832890610406496157985947347690953527356950641891321091711779456657192138933965420131878573315245883453268155958958845255027599185851399785413747295539619507266287125150657012851750006467027752603657263323142683192986680453383119202689344259382794816939152064487580546727622676935536587250566313287758078580783738354754803703576184612845868964441507122701033628638085588014323748803063924600505610037853512506488347863128965200196308457272037765464529947029636404075768195281262027292214253663365276151318993330281425032731741913053749301363295755668357645774878411242134048227284109685036718568706494107419270659381166663620693027791876567204494789600172172828343698419704457774295707309720554084282614597824096975544678028476929337221558657767373981499527228679736867775377130535832708002309987521492323503567350846385767820695577858715200865687824244853509471588580618425271918069203790589572787856941325683557276990120853405232822935501178427012493955943965851649 - -/-- The moment numerator at `n₀ = 34`, `k = 15`. -/ -def Nmomc : List ℤ := - [21938273879001296537588129542955953306828800, 129497710702694173605888551502777617795481600, 360787425276121692072309632823094603962777600, 630590017015541909221212690739699253219819520, 775231976159843868056552434154408412302376960, 712464083448956123930400803253774487043604480, 507951544956070062975956553658816614620528640, 287857419499780197357003719650576636454830080, 131892113200428362238317773442146749881548800, 49496137683072496421316258834388040067809280, 15391209894332935872549267167778842980515840, 4020501293737351539829539182699656188395520, 902386144742639189763448900347642653736960, 183145837686377657982191106811971256811520, 40004227361114589492628423752103593246720, 25112118781813135540699114875911934443520, 1735553464890643124188225674063313305600, 102107343563870599467891980573430251520, 4932688966494400752295458633638215680, 193131587346462233464895283281264640, 6109150847331286554715980504760320, 156038574887822299918461000744960, 3213790671650786630087674429440, 53161466999823964285729505280, 700614459557013390014545920, 7256198310569919633162240, 57772009636424727920640, 341301160751136768000, 1409413346167357440, 3631899507425280, 4396972769280] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 34) (gg1 34) (gg2 34) 15)) α := by - refine pev_moment_eq_of_packed_bounds 34 15 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 34 α t ^ 15) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 34 * (3 + α)) ^ 15) := - integral_moment_packed 34 15 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-32 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 32 * P α` is a positive combination of `αʲ (17-α)^(32-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 13399266531718143561671329774091404024125 + 71849885492802810816842838949259978576823 * α + 180538945319091116404922710783631485776255 * α ^ 2 + 282156930875912547195503056499665223632869 * α ^ 3 + 306955881947816717076752055353611201997433 * α ^ 4 + 246444353252723432574425088492703243027965 * α ^ 5 + 151019226036657912949719936683240321200053 * α ^ 6 + 72028327083715746440304318235594953916857 * α ^ 7 + 27007117326925331098314143315441103261561 * α ^ 8 + 7979024241553623900285784858349597089245 * α ^ 9 + 1847320854708526473676328223562198887417 * α ^ 10 + 329938708337757813561795624655269556461 * α ^ 11 + 43878641971714608549212527982241857715 * α ^ 12 + 3911666704610568428372170990877699643 * α ^ 13 + 54464632768848512857832724331386693 * α ^ 14 - 300202584430678770107735269889128119 * α ^ 15 + 16644540127319447720784804793743786 * α ^ 16 + 228891055611380679685401624709920 * α ^ 17 + 16200353115196577039237473724202 * α ^ 18 + 510663548855848557629648901888 * α ^ 19 - 6873476290889727146869228680 * α ^ 20 - 1591901557063130972106786240 * α ^ 21 - 90385492060860172817322528 * α ^ 22 - 3241298369821124224491264 * α ^ 23 - 83924819944658782911360 * α ^ 24 - 1639999868886062272512 * α ^ 25 - 24549687196522919424 * α ^ 26 - 281209623855906816 * α ^ 27 - 2429673447720960 * α ^ 28 - 15359508856832 * α ^ 29 - 67149078528 * α ^ 30 - 181665792 * α ^ 31 - 229376 * α ^ 32 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 32 * (13399266531718143561671329774091404024125 + 71849885492802810816842838949259978576823 * α + 180538945319091116404922710783631485776255 * α ^ 2 + 282156930875912547195503056499665223632869 * α ^ 3 + 306955881947816717076752055353611201997433 * α ^ 4 + 246444353252723432574425088492703243027965 * α ^ 5 + 151019226036657912949719936683240321200053 * α ^ 6 + 72028327083715746440304318235594953916857 * α ^ 7 + 27007117326925331098314143315441103261561 * α ^ 8 + 7979024241553623900285784858349597089245 * α ^ 9 + 1847320854708526473676328223562198887417 * α ^ 10 + 329938708337757813561795624655269556461 * α ^ 11 + 43878641971714608549212527982241857715 * α ^ 12 + 3911666704610568428372170990877699643 * α ^ 13 + 54464632768848512857832724331386693 * α ^ 14 - 300202584430678770107735269889128119 * α ^ 15 + 16644540127319447720784804793743786 * α ^ 16 + 228891055611380679685401624709920 * α ^ 17 + 16200353115196577039237473724202 * α ^ 18 + 510663548855848557629648901888 * α ^ 19 - 6873476290889727146869228680 * α ^ 20 - 1591901557063130972106786240 * α ^ 21 - 90385492060860172817322528 * α ^ 22 - 3241298369821124224491264 * α ^ 23 - 83924819944658782911360 * α ^ 24 - 1639999868886062272512 * α ^ 25 - 24549687196522919424 * α ^ 26 - 281209623855906816 * α ^ 27 - 2429673447720960 * α ^ 28 - 15359508856832 * α ^ 29 - 67149078528 * α ^ 30 - 181665792 * α ^ 31 - 229376 * α ^ 32) = 13399266531718143561671329774091404024125 * (17 - α) ^ 32 + 1650224582392628377859810814908344564577991 * α ^ 1 * (17 - α) ^ 31 + 96686681051656613148087819110678844495289416 * α ^ 2 * (17 - α) ^ 30 + 3585943364127806535175218856650333719997862062 * α ^ 3 * (17 - α) ^ 29 + 94506835391773642943632702539240023655585239976 * α ^ 4 * (17 - α) ^ 28 + 1883536024491957754295155022173521798076402761306 * α ^ 5 * (17 - α) ^ 27 + 29498713431163207985062885810393117977995458611360 * α ^ 6 * (17 - α) ^ 26 + 372444567835409169626366992601449865136908523715554 * α ^ 7 * (17 - α) ^ 25 + 3859379869369491930046652624818040581445251700417436 * α ^ 8 * (17 - α) ^ 24 + 33247489122948312922756142978001205956348938877434094 * α ^ 9 * (17 - α) ^ 23 + 240361064800204816769332884725722337309385385508245284 * α ^ 10 * (17 - α) ^ 22 + 1468297579222476711150318215261328148465442277706125318 * α ^ 11 * (17 - α) ^ 21 + 7616476027067108231341929094010647728198437294881398882 * α ^ 12 * (17 - α) ^ 20 + 33663083667068151985435771538517917417846319467001398040 * α ^ 13 * (17 - α) ^ 19 + 127012191711700706943666066187667778984137340603569186202 * α ^ 14 * (17 - α) ^ 18 + 408483237363770470892000173862806063969919527704726536136 * α ^ 15 * (17 - α) ^ 17 + 1112699056508533083404960444025601114584826187986242644199 * α ^ 16 * (17 - α) ^ 16 + 2541228944450694617802464818664598037324243538753868594135 * α ^ 17 * (17 - α) ^ 15 + 4808963007779256297034335517823636520905050012269500452122 * α ^ 18 * (17 - α) ^ 14 + 7449105095546099705010373449780908551641339483192620776998 * α ^ 19 * (17 - α) ^ 13 + 9324511543492008692105399378290148512417024338959823894774 * α ^ 20 * (17 - α) ^ 12 + 9297740340616393778000297728009621202927136433782291562398 * α ^ 21 * (17 - α) ^ 11 + 7274130570772010006967162133652153552632813945113550333758 * α ^ 22 * (17 - α) ^ 10 + 4441828800293274983181495636158215106270810356077510048966 * α ^ 23 * (17 - α) ^ 9 + 2239471510489480023234027273281488727890334103099818233488 * α ^ 24 * (17 - α) ^ 8 + 1180013639374388482169007814986614403675247990630945641900 * α ^ 25 * (17 - α) ^ 7 + 818218224361787722039978747842931615637242518870584611650 * α ^ 26 * (17 - α) ^ 6 + 587927012852098590957570014487485323178262550641905003190 * α ^ 27 * (17 - α) ^ 5 + 327641901908612799526209846021045735379467528409310341680 * α ^ 28 * (17 - α) ^ 4 + 125868057563181650595391338568950934373772184543193971640 * α ^ 29 * (17 - α) ^ 3 + 30847873348677414400175155768102397838878364715388408640 * α ^ 30 * (17 - α) ^ 2 + 4226337377572378619631312225122710192128000000000000000 * α ^ 31 * (17 - α) ^ 1 + 229862066916150806363247669850238091264000000000000000 * α ^ 32 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `34 ≤ n ≤ 35`.** -/ -theorem finite_range {n : ℕ} (h0 : 34 ≤ n) (h1 : n ≤ 35) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (35 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (35 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 33) + 1 / (4 * 33 * (3 + α)) - + (1 - 2 * α / 34) ^ 2 * 35 * 34 * (35 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 33 * (3 + α)) ^ 15)) - = 1 - (13399266531718143561671329774091404024125 + 71849885492802810816842838949259978576823 * α + 180538945319091116404922710783631485776255 * α ^ 2 + 282156930875912547195503056499665223632869 * α ^ 3 + 306955881947816717076752055353611201997433 * α ^ 4 + 246444353252723432574425088492703243027965 * α ^ 5 + 151019226036657912949719936683240321200053 * α ^ 6 + 72028327083715746440304318235594953916857 * α ^ 7 + 27007117326925331098314143315441103261561 * α ^ 8 + 7979024241553623900285784858349597089245 * α ^ 9 + 1847320854708526473676328223562198887417 * α ^ 10 + 329938708337757813561795624655269556461 * α ^ 11 + 43878641971714608549212527982241857715 * α ^ 12 + 3911666704610568428372170990877699643 * α ^ 13 + 54464632768848512857832724331386693 * α ^ 14 - 300202584430678770107735269889128119 * α ^ 15 + 16644540127319447720784804793743786 * α ^ 16 + 228891055611380679685401624709920 * α ^ 17 + 16200353115196577039237473724202 * α ^ 18 + 510663548855848557629648901888 * α ^ 19 - 6873476290889727146869228680 * α ^ 20 - 1591901557063130972106786240 * α ^ 21 - 90385492060860172817322528 * α ^ 22 - 3241298369821124224491264 * α ^ 23 - 83924819944658782911360 * α ^ 24 - 1639999868886062272512 * α ^ 25 - 24549687196522919424 * α ^ 26 - 281209623855906816 * α ^ 27 - 2429673447720960 * α ^ 28 - 15359508856832 * α ^ 29 - 67149078528 * α ^ 30 - 181665792 * α ^ 31 - 229376 * α ^ 32) / (435539996816352082589992870143936 * (3 + α) ^ 16) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 34) (n₁ := 35) (k := 15) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B34_35 - -end Sendov diff --git a/Sendov/FiniteRange/Degree36_37.lean b/Sendov/FiniteRange/Degree36_37.lean deleted file mode 100644 index cc7c28b..0000000 --- a/Sendov/FiniteRange/Degree36_37.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 36 to 37 - -`Sendov.R_le_batch` bounds every `R n α` for `36 ≤ n ≤ 37` by the elementary part and -moment at `n₀ = 36` together with the prefactor at `n₁ = 37`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 34, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B36_37 - -lemma M_lo : M 36 = 35 := by norm_num [M] - -lemma M_hi : M 37 = 36 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 36 α = 1 - 2 * α / 35 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 37 α = 1 - 2 * α / 36 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 36 α = (210 + 29 * α - 2 * α ^ 2) / (70 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 36 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 144403552893600 - -def betac : ℤ := 493101693994714012918579148426670877772048312935276219151155201 - -def tauc : ℤ := 3070766870045131941162056875883773699776691624415567384379705192263955089829536314667728955320800559664255168291363152817345518222207478994174714115897337636138853237547336487099785111216673670202345397045212560622535927337176098812511538057418664176458152757037266016951316507769360869934394718846027137028838312228494653933772312536969457885402893012868274488248435916196600104330528009544929733890527456347463839667042881120362108669501983383999046337008525789095380814350496247041440423782321941171538937021468305829931895919806009116999495798947968186899236177989002966034244254411023244060767266147572997948952804610241423734102638607851298888827510195574894274094717970436648912969415925321195563712385053605073717830696296446607478376231548789686364445124641844284127066904423923417378963870708006151235774679266910825413616035845035705452506829226777185304365190932178305196696217726479597813422915172221670182300283051653265175469972208681196132114932937282285665206898885084940321990244877622276324552522436248391284780411370314721261293731328311736340196048994572558441774369806524022077454408577775789750163206255262773557805800046583672115490163730545302919494125960131785282055048209868918555886277884301264729842924191699687782142650727288937565702457517005143699921778068027828320574505461684648027590399066176116158658675948896544488519971759932946621793972129041277193693656041363621109485160978666012094693655509033327215142678978883558005633073938034121499792289617141070699064200438578321177476197339716421364764484874836134558039157592780601974480344459903842156517588868369497458374981781593640836917003129628276771914818552667292301921765849354957963462357237502051672022315196912941477386123641197771879017240021846971468536342485303136023436197722698289229019956695598924543078679530213175583555974327613757605066582848559502907745069047320496126273226656461772097738783909996927366088717215931090713581058328911040355299084547591408414956805491876639438387887106505745542749299712650260529957818360714226431199043869703234058465213021122104148224068392618972547366413880494313114797389100207868041836802963076512060810358827879014322286871868423840434775448498004044009288872700256062322072526682560155811389079544529394266788204875135795684781791948350394559001666110155689647533969632480359152253844413330268106453942234469500367983251302519585910343734814898770803770626272703726402263436549104904767030348324023948459009659370191996615157678670602643718098579004284277828872657605338032540945870822722166672169445743776263830909278162149462709144914544255892271555798265676421376289178530419901330641873633317485554259558051356299629679373372555195075327426103752980181251925044732182190918830932572040630051387926630078995205193560220605569171209499899435494843888316719731212324252427419303496836673462094673087701839766487885655696755736020621283529028368244597506265057972866700316193864441586243995291986140781135801897099910329244274124150082029812737907703440562151255161742870439765050251554284716677101054841702935138951485702218186376130547934607054456828861184790152866861023233 - -/-- The moment numerator at `n₀ = 36`, `k = 16`. -/ -def Nmomc : List ℤ := - [8767473114730778479826699158800000000000000000, 54549574660377181497219757715520000000000000000, 160634533160520688855921436031840000000000000000, 297642598645976019916400027959488000000000000000, 389174622455819447496292084474305600000000000000, 381714918376930360512621254769500928000000000000, 291493555544681062358929425792000691200000000000, 177578984502053790228296376740994816000000000000, 87761364494521421350052344791816058368000000000, 35614216444286729461697066533392374169600000000, 11981415170884785329538341041492946386944000000, 3372288844104931747914706855086013258137600000, 803517483798233150169870412760889770803200000, 165504621500304920008449570956784278568960000, 30978017450875324221782187005604526620672000, 6302896697748460838288175679730832318136320, 3949857253400785825299956715547060964425728, 261383972606251920242854688089660641509376, 15023804628961363745016842358166011248640, 720790123472958030726578141238489251840, 28401413040772774604418323227900641280, 914743502647699956673137012457340928, 24061928134819327652281243314159616, 516624332287756628100908853493760, 9033402261838841542644345077760, 127978539408868520675172679680, 1455708419765874620708683776, 13100594342353784329469952, 91170949349742959656960, 473256364500750172160, 1725112483892428800, 3940134277873664, 4243427688448] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 36) (gg1 36) (gg2 36) 16)) α := by - refine pev_moment_eq_of_packed_bounds 36 16 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 36 α t ^ 16) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 36 * (3 + α)) ^ 16) := - integral_moment_packed 36 16 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-34 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 34 * P α` is a positive combination of `αʲ (17-α)^(34-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 1340862494179159723457439116979158935546875000 + 7637969043915714340759947223349395751953125000 * α + 20469159372189815097433030931483526306152343750 * α ^ 2 + 34274361726863699928017616105749597900390625000 * α ^ 3 + 40158420010659405404629812835302538476562500000 * α ^ 4 + 34937401402816329855420946112276054381835937500 * α ^ 5 + 23367211725435618964676169025739806953662109375 * α ^ 6 + 12270122821734134505495363628244218847460937500 * α ^ 7 + 5119554315996410501630574472803506399777343750 * α ^ 8 + 1706085086162412699720364430591688420225000000 * α ^ 9 + 453657266969080072299236418096329864193140625 * α ^ 10 + 95512498825559724167251930963289431001100000 * α ^ 11 + 15651081746907280778533576463846724310987500 * α ^ 12 + 1925946170421648313592236215225863164072500 * α ^ 13 + 160780952585487184902439630853241164106375 * α ^ 14 + 2481149473011100292550908813010287159220 * α ^ 15 - 11166042731030257542258130633810209326742 * α ^ 16 + 567791382062622839648458479091876877544 * α ^ 17 + 6430218988186661251397393995576293933 * α ^ 18 + 498747834176692841464289681241746784 * α ^ 19 + 18702443537088721760797370916939480 * α ^ 20 + 57367909378421946482804755695328 * α ^ 21 - 35467391809924321679454804549376 * α ^ 22 - 2344076836762407866768807250432 * α ^ 23 - 91095016683709754039240857216 * α ^ 24 - 2528503186830718445641541120 * α ^ 25 - 53176733671797993730857984 * α ^ 26 - 866597180873027929669632 * α ^ 27 - 11005160172719761434624 * α ^ 28 - 108265710516964073472 * α ^ 29 - 810954254409318400 * α ^ 30 - 4477829562761216 * α ^ 31 - 17204805009408 * α ^ 32 - 41120301056 * α ^ 33 - 46071808 * α ^ 34 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 34 * (1340862494179159723457439116979158935546875000 + 7637969043915714340759947223349395751953125000 * α + 20469159372189815097433030931483526306152343750 * α ^ 2 + 34274361726863699928017616105749597900390625000 * α ^ 3 + 40158420010659405404629812835302538476562500000 * α ^ 4 + 34937401402816329855420946112276054381835937500 * α ^ 5 + 23367211725435618964676169025739806953662109375 * α ^ 6 + 12270122821734134505495363628244218847460937500 * α ^ 7 + 5119554315996410501630574472803506399777343750 * α ^ 8 + 1706085086162412699720364430591688420225000000 * α ^ 9 + 453657266969080072299236418096329864193140625 * α ^ 10 + 95512498825559724167251930963289431001100000 * α ^ 11 + 15651081746907280778533576463846724310987500 * α ^ 12 + 1925946170421648313592236215225863164072500 * α ^ 13 + 160780952585487184902439630853241164106375 * α ^ 14 + 2481149473011100292550908813010287159220 * α ^ 15 - 11166042731030257542258130633810209326742 * α ^ 16 + 567791382062622839648458479091876877544 * α ^ 17 + 6430218988186661251397393995576293933 * α ^ 18 + 498747834176692841464289681241746784 * α ^ 19 + 18702443537088721760797370916939480 * α ^ 20 + 57367909378421946482804755695328 * α ^ 21 - 35467391809924321679454804549376 * α ^ 22 - 2344076836762407866768807250432 * α ^ 23 - 91095016683709754039240857216 * α ^ 24 - 2528503186830718445641541120 * α ^ 25 - 53176733671797993730857984 * α ^ 26 - 866597180873027929669632 * α ^ 27 - 11005160172719761434624 * α ^ 28 - 108265710516964073472 * α ^ 29 - 810954254409318400 * α ^ 30 - 4477829562761216 * α ^ 31 - 17204805009408 * α ^ 32 - 41120301056 * α ^ 33 - 46071808 * α ^ 34) = 1340862494179159723457439116979158935546875000 * (17 - α) ^ 34 + 175434798548658574390472032774231131591796875000 * α ^ 1 * (17 - α) ^ 33 + 10952711551434080913184099676123058282165527343750 * α ^ 2 * (17 - α) ^ 32 + 434270856341448311475241819934694889103759765625000 * α ^ 3 * (17 - α) ^ 31 + 12278911436635306192132622790762987549533349609375000 * α ^ 4 * (17 - α) ^ 30 + 263557269216566555320865047728777428822756844726562500 * α ^ 5 * (17 - α) ^ 29 + 4463883671586096731770907085592494749976786136669921875 * α ^ 6 * (17 - α) ^ 28 + 61225965954407894273160354546600964058305754660156250000 * α ^ 7 * (17 - α) ^ 27 + 692587772613132439128122751366082049061109249880812500000 * α ^ 8 * (17 - α) ^ 26 + 6547796240902796556445336115711018473638408241918575000000 * α ^ 9 * (17 - α) ^ 25 + 52247549382615756077051379940154408637849061298491733812500 * α ^ 10 * (17 - α) ^ 24 + 354466647029909646510470656479599263564041502427407695300000 * α ^ 11 * (17 - α) ^ 23 + 2055889704738111710267568200183486826512215613684783110200000 * α ^ 12 * (17 - α) ^ 22 + 10234888840339768071474956793147766100757409148665132934370000 * α ^ 13 * (17 - α) ^ 21 + 43858398380617067829266771169258660902757314148335253721083000 * α ^ 14 * (17 - α) ^ 20 + 162055210405371666456160142527627828678422430377426835106958960 * α ^ 15 * (17 - α) ^ 19 + 516145320938971158929091669417239050325330885780111469198875088 * α ^ 16 * (17 - α) ^ 18 + 1412064392511895951084181534107896493318729250846824514725955712 * α ^ 17 * (17 - α) ^ 17 + 3296410975824492770073801068890863487757382337405699389044881152 * α ^ 18 * (17 - α) ^ 16 + 6510700656466073656283913487155596019027366109135146309819197400 * α ^ 19 * (17 - α) ^ 15 + 10778762671920232847172097564072974706837835927532659281695627000 * α ^ 20 * (17 - α) ^ 14 + 14812853870469700737370316477184138613188186623760145268072292500 * α ^ 21 * (17 - α) ^ 13 + 16720671608226908945079705353880617034286101018111021059080009375 * α ^ 22 * (17 - α) ^ 12 + 15317420704224111419919616448379092129752276964124634080685800000 * α ^ 23 * (17 - α) ^ 11 + 11238165133613859896218350103981386092933200214685034701456250000 * α ^ 24 * (17 - α) ^ 10 + 6544374325964212483346602292437892685413037367000381149781250000 * α ^ 25 * (17 - α) ^ 9 + 3087009276202780754337495361663231009012869918782181865781250000 * α ^ 26 * (17 - α) ^ 8 + 1334541850899219151104336491093618277155327063911213757812500000 * α ^ 27 * (17 - α) ^ 7 + 671021217962301496929047441300025617792685964844905141406250000 * α ^ 28 * (17 - α) ^ 6 + 390013014583991314611686405951849748841394880271566591796875000 * α ^ 29 * (17 - α) ^ 5 + 198126638262411132449557681354886342145672562882243054199218750 * α ^ 30 * (17 - α) ^ 4 + 72921376026239920902575443619361410154303245019324218750000000 * α ^ 31 * (17 - α) ^ 3 + 17546793780907574541651374555825605095190744540455322265625000 * α ^ 32 * (17 - α) ^ 2 + 2427279654890969862947772530516229556781067701712646484375000 * α ^ 33 * (17 - α) ^ 1 + 141776547693471981630558155006611207847406241325378417968750 * α ^ 34 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `36 ≤ n ≤ 37`.** -/ -theorem finite_range {n : ℕ} (h0 : 36 ≤ n) (h1 : n ≤ 37) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (37 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (37 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 35) + 1 / (4 * 35 * (3 + α)) - + (1 - 2 * α / 36) ^ 2 * 37 * 36 * (37 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 35 * (3 + α)) ^ 16)) - = 1 - (1340862494179159723457439116979158935546875000 + 7637969043915714340759947223349395751953125000 * α + 20469159372189815097433030931483526306152343750 * α ^ 2 + 34274361726863699928017616105749597900390625000 * α ^ 3 + 40158420010659405404629812835302538476562500000 * α ^ 4 + 34937401402816329855420946112276054381835937500 * α ^ 5 + 23367211725435618964676169025739806953662109375 * α ^ 6 + 12270122821734134505495363628244218847460937500 * α ^ 7 + 5119554315996410501630574472803506399777343750 * α ^ 8 + 1706085086162412699720364430591688420225000000 * α ^ 9 + 453657266969080072299236418096329864193140625 * α ^ 10 + 95512498825559724167251930963289431001100000 * α ^ 11 + 15651081746907280778533576463846724310987500 * α ^ 12 + 1925946170421648313592236215225863164072500 * α ^ 13 + 160780952585487184902439630853241164106375 * α ^ 14 + 2481149473011100292550908813010287159220 * α ^ 15 - 11166042731030257542258130633810209326742 * α ^ 16 + 567791382062622839648458479091876877544 * α ^ 17 + 6430218988186661251397393995576293933 * α ^ 18 + 498747834176692841464289681241746784 * α ^ 19 + 18702443537088721760797370916939480 * α ^ 20 + 57367909378421946482804755695328 * α ^ 21 - 35467391809924321679454804549376 * α ^ 22 - 2344076836762407866768807250432 * α ^ 23 - 91095016683709754039240857216 * α ^ 24 - 2528503186830718445641541120 * α ^ 25 - 53176733671797993730857984 * α ^ 26 - 866597180873027929669632 * α ^ 27 - 11005160172719761434624 * α ^ 28 - 108265710516964073472 * α ^ 29 - 810954254409318400 * α ^ 30 - 4477829562761216 * α ^ 31 - 17204805009408 * α ^ 32 - 41120301056 * α ^ 33 - 46071808 * α ^ 34) / (14484306327350467025497631835937500000 * (3 + α) ^ 17) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 36) (n₁ := 37) (k := 16) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B36_37 - -end Sendov diff --git a/Sendov/FiniteRange/Degree38_39.lean b/Sendov/FiniteRange/Degree38_39.lean deleted file mode 100644 index 1a51a12..0000000 --- a/Sendov/FiniteRange/Degree38_39.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 38 to 39 - -`Sendov.R_le_batch` bounds every `R n α` for `38 ≤ n ≤ 39` by the elementary part and -moment at `n₀ = 38` together with the prefactor at `n₁ = 39`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 36, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B38_39 - -lemma M_lo : M 38 = 37 := by norm_num [M] - -lemma M_hi : M 39 = 38 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 38 α = 1 - 2 * α / 37 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 39 α = 1 - 2 * α / 38 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 38 α = (222 + 31 * α - 2 * α ^ 2) / (74 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 38 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 5342931457063200 - -def betac : ℤ := 49215745997747131449615272463141316329123716299736310517076695449601 - -def tauc : ℤ := 89895144401887772946051248458972511851188839571487233716322659325368409985194010151392316814268695718263970480829783286161583148752627779437023960614078490835485422122394470616134545499721638344725344805304810782898280554384940111096395392429995078137985605742674214547482404468765629924717325612684547223310278455908561672561930780324286885835907399968322505484858828121918099960442309062014490933219339451155370519833096493582316088305246387351319278446724672182102073403455086734797831626028387608100619895446799729688531761184501878655479397067020288868974794078021843612421016891090344813970010559213275531932649255824126921448771067180636990258955293521842591857107506040509013227884950506664994434170495720705934599923969186547779772952367232273217828591536954540369684345932899761005069669367753327229707534425401144612662871019437999554086128053641796446946655461014210032690250874420673773368230394582216399875643365001861192415861399270445142738782759418727425017481632734570145374649217248553042363665035748443699347035987501568127267085422836701139088455213206928518345980887094127306651616252266939466672558808468281948296565242698704340857976025651530201637384576758240915443325619766816320954735867757517460534998448251113204888112445290174992232050041902585646541798754959092101865849236400002593911686938179151411643531093150894756037336392717346685336476157681467065733508534103849325975145325888159740522483036699999663991961699167495168080802314581238279162521765902740794273605118525239112937831531247097375327410164179234828844136852982792377844190459739544548919434692049119106180059834896400145652784496709271069531302994951748744757550154966644412653605807365432892755424415944448309991615968446741794267657288531514794587056848356997563802746105268130885712120997592172700506842667243329229780273219018316317592314828050358343440356094391224564886175224167759511769987451340402218731093215776562546942920811292202501960611463514595244401485283638113888083339016809324144295543882848807826165692414649400892333505912018153398868205730664853806853452980444471646137960690776615660994850153315547354386532571471022827208661677351666329247079883989735924332525870045488169458956950438044608837395029919707863939774714969073720660228521478441021257391125280299291199739528169696982326827252760149944677999528498216641027988366265490638359471766694317462750491864811039753550662150403863909133954854910498227282175830459976132111678350737147342592621652149222106810479224660496152587494653586856152014174380147497812257022088471646515564178274956389194398320878629893880479066403555196101512783471620486701107388264886757387892719109381388154984493854113352597434778466104879046881983158787598667992769869135879721523350419076048530885671965966420053358490258494286219519345093776918307331695244895444971015610266841183295421235931513648442671561082265991673699126927265113065907630324781167971627628447061602410525905009608440184220881754822311136984276659307454811101677371729529766787219064874060071912936083963714550400603252623335698802130449215952050610367985365199304959251859139673113177510779229946899088894192811396738078953245828879724625162870029945562937700749202580469193755585135189933500882870940979194158213818420674154205885349727765934853638675763211396101252515175467706275025650280825732298021324454717006095975258678555090857275705468359422891643345606136100103860920114078776283548437381830712369584636079954133515267731927641951545888045463921949838863083819862179265327309337106713767681601378176776564005252727107158432022529 - -/-- The moment numerator at `n₀ = 38`, `k = 17`. -/ -def Nmomc : List ℤ := - [139822013869614918336939834880671033373816746147840, 914778750309943084342004680020551819493179994931200, 2839868702487607363277754143993395365579366884966400, 5562844808182003378345978252907766326037866710302720, 7712565326361653932313146682798302386447784044134400, 8047464454046491997034901124405512634852242299027456, 6560288273992488450457724782120144764978964542259200, 4281917696431679960885764149611537239951458513715200, 2275588544505066198132576572444379068284962561589248, 996409996305788317854498102919263701519887895101440, 362634610093328265931789989590420776176541032775680, 110481063185316320076055904713392908835207055933440, 28382864898523387978769797385932077410980402298880, 6212059021126932030729841687445128508020838891520, 1181172360246583107732961965060917472876209111040, 204879740238888175404201307548459235247781838848, 38980119362162723496135736205787251168606945280, 24516342606301898665025044145285032179093995520, 1552552964492521693674391785970712516675764224, 87011917636146147409941031266792013100482560, 4134671294651461440822247154106531745628160, 163405663775694571046616007663151124316160, 5335832717231028320001749682099826196480, 143755072405313514389080336502378987520, 3194517839910252622317371860377927680, 58485395134840335981595442932613120, 879375558773867135070681547407360, 10793198005288417341700099276800, 107061473049406637744534323200, 845108429044719599537356800, 5185179795751517170958336, 23837520940288641597440, 77267149880599511040, 157496828701442048, 151870043586560] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 38) (gg1 38) (gg2 38) 17)) α := by - refine pev_moment_eq_of_packed_bounds 38 17 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 38 α t ^ 17) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 38 * (3 + α)) ^ 17) := - integral_moment_packed 38 17 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-36 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 36 * P α` is a positive combination of `αʲ (17-α)^(36-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 263016241667210021671084890841481617690003189110 + 1586061041777522258785370750920508059260325100670 * α + 4515569002916763022083813591656453793545843463960 * α ^ 2 + 8064535450447153538886731843043227730967854436080 * α ^ 3 + 10124049292126400106014356225197947036232792604485 * α ^ 4 + 9486490487762873429871569630238934346081556621609 * α ^ 5 + 6875502816855646349457849536822502570739478645343 * α ^ 6 + 3940536916491738744952644524802984325688545318839 * α ^ 7 + 1810118648803944257004276579444295893576974412957 * α ^ 8 + 671223601039568220250335587923837679954504671929 * α ^ 9 + 201302327242382412835780103712068254297083069927 * α ^ 10 + 48665320464285286858138805925504857552220130935 * α ^ 11 + 9395447364524194147939717327946455319249576385 * α ^ 12 + 1422463731757903542558687467068487748999154005 * α ^ 13 + 162936488968328754409221779604516446092275015 * α ^ 14 + 12804246766409474561270894860455521523191007 * α ^ 15 + 216069416334011168489825518695466581657549 * α ^ 16 - 808211600142399392096627843592018139890543 * α ^ 17 + 38042736580603120168867477319356142859621 * α ^ 18 + 344373790265831271857444699712655317117 * α ^ 19 + 29315226870352164747186119924985775776 * α ^ 20 + 1247198097855472249813750976434442560 * α ^ 21 + 16662184536264199136681220318869840 * α ^ 22 - 1406905416514864930658623327447840 * α ^ 23 - 115154592405960528415597818779200 * α ^ 24 - 4877945634325956011421670432000 * α ^ 25 - 144681078013665355320791476480 * α ^ 26 - 3249838030348665967746429440 * α ^ 27 - 56982963376184696008104960 * α ^ 28 - 788738718851438284800000 * α ^ 29 - 8618882420705188376576 * α ^ 30 - 73677168662756319232 * α ^ 31 - 483260148118798336 * α ^ 32 - 2351449584959488 * α ^ 33 - 8003806560256 * α ^ 34 - 17023172608 * α ^ 35 - 17039360 * α ^ 36 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 36 * (263016241667210021671084890841481617690003189110 + 1586061041777522258785370750920508059260325100670 * α + 4515569002916763022083813591656453793545843463960 * α ^ 2 + 8064535450447153538886731843043227730967854436080 * α ^ 3 + 10124049292126400106014356225197947036232792604485 * α ^ 4 + 9486490487762873429871569630238934346081556621609 * α ^ 5 + 6875502816855646349457849536822502570739478645343 * α ^ 6 + 3940536916491738744952644524802984325688545318839 * α ^ 7 + 1810118648803944257004276579444295893576974412957 * α ^ 8 + 671223601039568220250335587923837679954504671929 * α ^ 9 + 201302327242382412835780103712068254297083069927 * α ^ 10 + 48665320464285286858138805925504857552220130935 * α ^ 11 + 9395447364524194147939717327946455319249576385 * α ^ 12 + 1422463731757903542558687467068487748999154005 * α ^ 13 + 162936488968328754409221779604516446092275015 * α ^ 14 + 12804246766409474561270894860455521523191007 * α ^ 15 + 216069416334011168489825518695466581657549 * α ^ 16 - 808211600142399392096627843592018139890543 * α ^ 17 + 38042736580603120168867477319356142859621 * α ^ 18 + 344373790265831271857444699712655317117 * α ^ 19 + 29315226870352164747186119924985775776 * α ^ 20 + 1247198097855472249813750976434442560 * α ^ 21 + 16662184536264199136681220318869840 * α ^ 22 - 1406905416514864930658623327447840 * α ^ 23 - 115154592405960528415597818779200 * α ^ 24 - 4877945634325956011421670432000 * α ^ 25 - 144681078013665355320791476480 * α ^ 26 - 3249838030348665967746429440 * α ^ 27 - 56982963376184696008104960 * α ^ 28 - 788738718851438284800000 * α ^ 29 - 8618882420705188376576 * α ^ 30 - 73677168662756319232 * α ^ 31 - 483260148118798336 * α ^ 32 - 2351449584959488 * α ^ 33 - 8003806560256 * α ^ 34 - 17023172608 * α ^ 35 - 17039360 * α ^ 36) = 263016241667210021671084890841481617690003189110 * (17 - α) ^ 36 + 36431622410237439179510358835941975244265641519350 * α ^ 1 * (17 - α) ^ 35 + 2414405993950912571012301206016550860739344205122390 * α ^ 2 * (17 - α) ^ 34 + 101911987093790495993891637162656810587351337884854450 * α ^ 3 * (17 - α) ^ 33 + 3077136529375910511818308139163370204204710108135348945 * α ^ 4 * (17 - α) ^ 32 + 70767700416372118022916506935148443513144214212984079433 * α ^ 5 * (17 - α) ^ 31 + 1288872796711775738410766166408400924167189843482363181510 * α ^ 6 * (17 - α) ^ 30 + 19083400748229222868616813579365546608706181811242799713442 * α ^ 7 * (17 - α) ^ 29 + 234010152840381946349380212378698061303021231207480935794380 * α ^ 8 * (17 - α) ^ 28 + 2409083298538233479330794311735295130068631390190510305345916 * α ^ 9 * (17 - α) ^ 27 + 21034199072421691415654588980184171455732743682853035936388736 * α ^ 10 * (17 - α) ^ 26 + 156965739060943279756832920952171731542118382822579555902264320 * α ^ 11 * (17 - α) ^ 25 + 1007013809256349634438976269863634909802444822788284670764336920 * α ^ 12 * (17 - α) ^ 24 + 5578883286717752179555968646363028277131383001091676680613578600 * α ^ 13 * (17 - α) ^ 23 + 26778108682132812026449907006307737451347925518376385819177842180 * α ^ 14 * (17 - α) ^ 22 + 111626866485074002051921408370316196620668741767980677786122726476 * α ^ 15 * (17 - α) ^ 21 + 404749936967515936812332395113162625848731824975287760415129552520 * α ^ 16 * (17 - α) ^ 20 + 1276851853339474854752478301460896841716394369316599334161708835864 * α ^ 17 * (17 - α) ^ 19 + 3498152021559931653758754395800484089136347016702124578632888785870 * α ^ 18 * (17 - α) ^ 18 + 8288489989122825212327334609599909543398390901155522489744660111602 * α ^ 19 * (17 - α) ^ 17 + 16882651085623904442176264117055333605492167285591363946133352298205 * α ^ 20 * (17 - α) ^ 16 + 29353791640642678379569945946711713118769355441603863420459332583845 * α ^ 21 * (17 - α) ^ 15 + 43236117652901827874516888436407546705327794671242323926919339677542 * α ^ 22 * (17 - α) ^ 14 + 53514417120286757722309232459981186747567529389425853874706900031330 * α ^ 23 * (17 - α) ^ 13 + 55160684404854002133844526815694799322288761295220210026216244417256 * α ^ 24 * (17 - α) ^ 12 + 46859199139271497704482066786546595457658791134521569883679868639464 * α ^ 25 * (17 - α) ^ 11 + 32418496139685480362601229821482044096981462148753646754741401291900 * α ^ 26 * (17 - α) ^ 10 + 18064228253690987870059860955691584275196341087334183534685080363332 * α ^ 27 * (17 - α) ^ 9 + 8116057087439008484605418610430390304640800612633036742729214781010 * α ^ 28 * (17 - α) ^ 8 + 3094097281163451800860397134053738271256213921040320763043485148866 * α ^ 29 * (17 - α) ^ 7 + 1174308203032074417716759573429346434013837010515376831055725367856 * α ^ 30 * (17 - α) ^ 6 + 514147619716779490199856234417204230784802425196644936366761384400 * α ^ 31 * (17 - α) ^ 5 + 225918222596880524574644194822909829140432799329070928335788308150 * α ^ 32 * (17 - α) ^ 4 + 78378867100425150377346627184325309287549636198734508005978549750 * α ^ 33 * (17 - α) ^ 3 + 18415214840638052851390630908893866826964214257262459916509597440 * α ^ 34 * (17 - α) ^ 2 + 2542392303855460193752438935467117379253704583645900859266878840 * α ^ 35 * (17 - α) ^ 1 + 152938893321252958580549098618153156123487784458433341017459200 * α ^ 36 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `38 ≤ n ≤ 39`.** -/ -theorem finite_range {n : ℕ} (h0 : 38 ≤ n) (h1 : n ≤ 39) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (39 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (39 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 37) + 1 / (4 * 37 * (3 + α)) - + (1 - 2 * α / 38) ^ 2 * 39 * 38 * (39 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 37 * (3 + α)) ^ 17)) - = 1 - (263016241667210021671084890841481617690003189110 + 1586061041777522258785370750920508059260325100670 * α + 4515569002916763022083813591656453793545843463960 * α ^ 2 + 8064535450447153538886731843043227730967854436080 * α ^ 3 + 10124049292126400106014356225197947036232792604485 * α ^ 4 + 9486490487762873429871569630238934346081556621609 * α ^ 5 + 6875502816855646349457849536822502570739478645343 * α ^ 6 + 3940536916491738744952644524802984325688545318839 * α ^ 7 + 1810118648803944257004276579444295893576974412957 * α ^ 8 + 671223601039568220250335587923837679954504671929 * α ^ 9 + 201302327242382412835780103712068254297083069927 * α ^ 10 + 48665320464285286858138805925504857552220130935 * α ^ 11 + 9395447364524194147939717327946455319249576385 * α ^ 12 + 1422463731757903542558687467068487748999154005 * α ^ 13 + 162936488968328754409221779604516446092275015 * α ^ 14 + 12804246766409474561270894860455521523191007 * α ^ 15 + 216069416334011168489825518695466581657549 * α ^ 16 - 808211600142399392096627843592018139890543 * α ^ 17 + 38042736580603120168867477319356142859621 * α ^ 18 + 344373790265831271857444699712655317117 * α ^ 19 + 29315226870352164747186119924985775776 * α ^ 20 + 1247198097855472249813750976434442560 * α ^ 21 + 16662184536264199136681220318869840 * α ^ 22 - 1406905416514864930658623327447840 * α ^ 23 - 115154592405960528415597818779200 * α ^ 24 - 4877945634325956011421670432000 * α ^ 25 - 144681078013665355320791476480 * α ^ 26 - 3249838030348665967746429440 * α ^ 27 - 56982963376184696008104960 * α ^ 28 - 788738718851438284800000 * α ^ 29 - 8618882420705188376576 * α ^ 30 - 73677168662756319232 * α ^ 31 - 483260148118798336 * α ^ 32 - 2351449584959488 * α ^ 33 - 8003806560256 * α ^ 34 - 17023172608 * α ^ 35 - 17039360 * α ^ 36) / (944533280285743117909608355250454382800 * (3 + α) ^ 18) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 38) (n₁ := 39) (k := 17) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B38_39 - -end Sendov diff --git a/Sendov/FiniteRange/Degree40_41.lean b/Sendov/FiniteRange/Degree40_41.lean deleted file mode 100644 index e86625b..0000000 --- a/Sendov/FiniteRange/Degree40_41.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 40 to 41 - -`Sendov.R_le_batch` bounds every `R n α` for `40 ≤ n ≤ 41` by the elementary part and -moment at `n₀ = 40` together with the prefactor at `n₁ = 41`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 38, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B40_41 - -lemma M_lo : M 40 = 39 := by norm_num [M] - -lemma M_hi : M 41 = 40 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 40 α = 1 - 2 * α / 39 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 41 α = 1 - 2 * α / 40 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 40 α = (234 + 33 * α - 2 * α ^ 2) / (78 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 40 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 5342931457063200 - -def betac : ℤ := 140771311646190712242806590263718917259547439160455144794682105947750401 - -def tauc : ℤ := 388162163934891273307870566538705630123603802446971117446465661672239005539372743431833595050876101818979720333844327127310430605619495859259833440454201707569085043932794059777224971565807122144648923097559859774047283158021315460802101020615961678820431927416557733367831326200454431217719607555498651916101374668170226254545921061243704791226108352347243340297485384176858342974730060324040468737261226284794317850479098716835833717190723369752612570341569177040699279366373144069116183305273394515794448800615425419744149089066185651930646522832469109365908219217125501117507553980707191411651431104582280961538345878439939298596006696416278299784507963432946497077132346306804618216388745164299362050641267500561825621324509655085373001213922541028181009685182487298956656706897640614760548871297395276361124096614726283989982918482835229118906597437237781052209791851723402877656551024302943392933683765017514408635178772455074856582347419302566346546169871370340077178782069486315797092509832503121802412465891505577811413549629355779779931610287241349592356589163088671205072813733020798705709889303129496492336870764998791133184393573822083314332128747636146674766553027342453759657664997364255931714838026518124884778526189758949580959659972097815049725379159736951831952448534098110874197477838419658435436687867337004279083987856474833230529038210819163297113593882162909124511685986882768918349727421747635339578299711204379960936206768500751650295995648423386963347275657908297301047288612455536596412219381884282082154434128941244770494463568117354810340004378972906584886322430732700612191814816581845987388780070896691570363939540953248244469125877571961910750894787634780309805939089543120414087700442076130668113274108995491961857607968559540873955617604550954422122599378492550841339423402005821503440708686415708989422075944195425598978415694308561014872937097115690064306874177615489816665259257674757345164896461512836531425798002632137318355862601144495326301840032453973974824735501875330358661382206973208847162146853468220913482854740797921812138981594051767773983334810467161366965494008429875794469187198429477574845349099519178384882402547475285762237163614755702448081989598822993655321082407467888264459277326108603420516734114670503540513280721188860594499062104712203028858758856030897307721089734592226409250191594526131901671093841744046840425938212799587130871512865516796015610814635432655056681495732287901207830021778442138659592409668013150912762879047087807183724234435782299452916033036727607680723717432256132094598072546709510891102997771822731505181452301091415211912301910083761504740153207488637895535777011195507583427934438761586731513098849104877086986241740952340112210104737321596121449391912371617040812545611574687978049355205910853115917099038889656357401150877783690626390741001038227599898120681224280488511445814898203484672558550963748473400293172015770802312770124119228357512121547406179627857565829716935327458068201740565275284773839865227490052451896386218909875080712838273684174668519049317508337905419826990329247978883847380600359762680469855771453450088700961559007045759730932251494825405689422464336783352420993314486423748705007387573097074691743057441900898960271894141451634390933140413185847608532382155838199043792103487727706152938338407482219538710580367944204517690402791033657291520919399331234345244892725989612333544016967659891892118419075730284025912350315985259818971685457899114900872324357507034494565560593316674063185865047244783679566913360396253110670506432838746097286648233980904260476374512183189305330452639382525258201092695585409266495202180510456778821663165534058691874601507960357944131814344614995907445211208268751494223650712281844790515053649309963836390128887962979786130739822033823039388652195042485013320823296419285461289516481150933055830822097094477167791303556241016245495406050727267203935498638989557488455776194457391439024449092723223962813326147715073 - -/-- The moment numerator at `n₀ = 40`, `k = 18`. -/ -def Nmomc : List ℤ := - [64670522157568552167457363212785477079998348651397120, 443928785799573138321667028061391882959402583782850560, 1449401704009714778943896128515571550690605338926776320, 2993628004076870654281456663324496366723203568165191680, 4388587699311400723942924805346299484514209103101296640, 4856547691606816341849170828483193698100550515315179520, 4212655768515911998584943885962115290633571644245803008, 2935987889210574401124196278357659367328830690970042368, 1672180248363954353420597144375610376638481717526003712, 787600678062358267517895296867719732295947238853574656, 309396544239520913003283201005975922179460484371578880, 102014444415760722810101580339873764712955447804428288, 28382958547450636254540337967242803929257184411516928, 6702564147432040293980370767728666402284925020536832, 1355605275766909686197760236148047704061630591533056, 239161647917465627259687095258798211139582354784256, 38606207115455805822654376004869982867986029477888, 6891623326063709341407450655915487527123446398976, 4370836023942146549797183903787204142175870255104, 264783941635716435218873237386240353244054290432, 14444944882115852309697772096837164195385442304, 678246957742511527324639079894004142153138176, 26807292152038156363744253329413673265922048, 884327690732539531709078902442589601923072, 24292433408088112933954604631358445715456, 555510222279991670554325652274868649984, 10569676876074237332831980634278723584, 167022895439411249478990896924983296, 2183242579593696970222549843574784, 23445246643059736976498519703552, 204633356590459468118017179648, 1428490066333166044773875712, 7785591010347871157354496, 31921599633392909942784, 92611974667972902912, 169507996802482176, 147197119168512] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 40) (gg1 40) (gg2 40) 18)) α := by - refine pev_moment_eq_of_packed_bounds 40 18 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 40 α t ^ 18) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 40 * (3 + α)) ^ 18) := - integral_moment_packed 40 18 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-38 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 38 * P α` is a positive combination of `αʲ (17-α)^(38-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 653328533869198792815460418567456328463360027860000 + 4157882298167732116226370617284188848212873011241200 * α + 12532182988010399386002617462745633312768152237121570 * α ^ 2 + 23778313854745445633723704693422676769304621097023060 * α ^ 3 + 31839691004956228828005033576674262680347642949789970 * α ^ 4 + 31966947875077850162540664582127534223677059725715480 * α ^ 5 + 24954452263842718944480719755732872419125467194310990 * α ^ 6 + 15498456398852386516930447507216103141023058978163900 * α ^ 7 + 7770525510255924837049186376423929043180641908035178 * α ^ 8 + 3172282421659051612506049390871943668830947112996128 * α ^ 9 + 1058580212642493803810630674822381941853484677345557 * α ^ 10 + 288603554681274589435804606029301359165948874522986 * α ^ 11 + 63964171378367904791712568423672278670444648520985 * α ^ 12 + 11403554558448059539985445321284291979921951939708 * α ^ 13 + 1604683068013899575897130419685118852646893739688 * α ^ 14 + 171973766788073602692262435759609700705097645552 * α ^ 15 + 12777319017916275759622043304057680904260665896 * α ^ 16 + 232511338229217727198624028718607742301689616 * α ^ 17 - 736152391583269859036039443814447014605197787 * α ^ 18 + 32344027389559443630831441714104468449897746 * α ^ 19 + 226192739078384191702850277844962783099369 * α ^ 20 + 21321388850847068435151126284573459826132 * α ^ 21 + 1002825060545767936823647697965569833484 * α ^ 22 + 20605096429138626101144518690493027136 * α ^ 23 - 588379321688541475027751329888140192 * α ^ 24 - 68916522458163479393324809629479808 * α ^ 25 - 3219999749177967431080752136593024 * α ^ 26 - 101984865798504570834320095942656 * α ^ 27 - 2433981075208899701339322164736 * α ^ 28 - 45526079756647968714698102784 * α ^ 29 - 678401876172921453922277376 * α ^ 30 - 8091691517611230731255808 * α ^ 31 - 76978691001245722632192 * α ^ 32 - 577480811034021101568 * α ^ 33 - 3345672064015171584 * α ^ 34 - 14456978064408576 * α ^ 35 - 43900332474368 * α ^ 36 - 83629441024 * α ^ 37 - 75235328 * α ^ 38 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 38 * (653328533869198792815460418567456328463360027860000 + 4157882298167732116226370617284188848212873011241200 * α + 12532182988010399386002617462745633312768152237121570 * α ^ 2 + 23778313854745445633723704693422676769304621097023060 * α ^ 3 + 31839691004956228828005033576674262680347642949789970 * α ^ 4 + 31966947875077850162540664582127534223677059725715480 * α ^ 5 + 24954452263842718944480719755732872419125467194310990 * α ^ 6 + 15498456398852386516930447507216103141023058978163900 * α ^ 7 + 7770525510255924837049186376423929043180641908035178 * α ^ 8 + 3172282421659051612506049390871943668830947112996128 * α ^ 9 + 1058580212642493803810630674822381941853484677345557 * α ^ 10 + 288603554681274589435804606029301359165948874522986 * α ^ 11 + 63964171378367904791712568423672278670444648520985 * α ^ 12 + 11403554558448059539985445321284291979921951939708 * α ^ 13 + 1604683068013899575897130419685118852646893739688 * α ^ 14 + 171973766788073602692262435759609700705097645552 * α ^ 15 + 12777319017916275759622043304057680904260665896 * α ^ 16 + 232511338229217727198624028718607742301689616 * α ^ 17 - 736152391583269859036039443814447014605197787 * α ^ 18 + 32344027389559443630831441714104468449897746 * α ^ 19 + 226192739078384191702850277844962783099369 * α ^ 20 + 21321388850847068435151126284573459826132 * α ^ 21 + 1002825060545767936823647697965569833484 * α ^ 22 + 20605096429138626101144518690493027136 * α ^ 23 - 588379321688541475027751329888140192 * α ^ 24 - 68916522458163479393324809629479808 * α ^ 25 - 3219999749177967431080752136593024 * α ^ 26 - 101984865798504570834320095942656 * α ^ 27 - 2433981075208899701339322164736 * α ^ 28 - 45526079756647968714698102784 * α ^ 29 - 678401876172921453922277376 * α ^ 30 - 8091691517611230731255808 * α ^ 31 - 76978691001245722632192 * α ^ 32 - 577480811034021101568 * α ^ 33 - 3345672064015171584 * α ^ 34 - 14456978064408576 * α ^ 35 - 43900332474368 * α ^ 36 - 83629441024 * α ^ 37 - 75235328 * α ^ 38) = 653328533869198792815460418567456328463360027860000 * (17 - α) ^ 38 + 95510483355881000102835796399394550901226522249780400 * α ^ 1 * (17 - α) ^ 37 + 6696398808392555675010412239258164611825635220184428530 * α ^ 2 * (17 - α) ^ 36 + 299794710667200193646561985461117827680016512752986934460 * α ^ 3 * (17 - α) ^ 35 + 9627257466437286352224279116990630228292750401872068624570 * α ^ 4 * (17 - α) ^ 34 + 236169626370579092102401540068424043031156213235832488824240 * α ^ 5 * (17 - α) ^ 33 + 4602580155935131911540977878848744873896752358859535239239310 * α ^ 6 * (17 - α) ^ 32 + 73167568636523068791230387895812989143995323139339741955173340 * α ^ 7 * (17 - α) ^ 31 + 966819100697307203780359917617580768148731765217116962982472158 * α ^ 8 * (17 - α) ^ 30 + 10767130098246849195301111459928119363029994766661588897784000776 * α ^ 9 * (17 - α) ^ 29 + 102122724502527454683682344439666460359467859469480457468195144927 * α ^ 10 * (17 - α) ^ 28 + 831548691595541121952529230262845541710942265958095940858036487578 * α ^ 11 * (17 - α) ^ 27 + 5848940149873603781228937217250745230319503456527981662700527649479 * α ^ 12 * (17 - α) ^ 26 + 35707752760626549856948044943531072922885702324271579224065621550616 * α ^ 13 * (17 - α) ^ 25 + 189904423378547635211179836338153464631558375737888355414680794292332 * α ^ 14 * (17 - α) ^ 24 + 882263986278123132234428133435096956146433318787491830406424008581944 * α ^ 15 * (17 - α) ^ 23 + 3587848295098893896231452077434369033403531934780731646206410657559996 * α ^ 16 * (17 - α) ^ 22 + 12789017524790293159146747559828714620914231030244750348653705133535680 * α ^ 17 * (17 - α) ^ 21 + 39978318616507844028720464128037031241214473591909362382585304014435338 * α ^ 18 * (17 - α) ^ 20 + 109503304419314521695778687533175441622403892877574691241529360322168236 * α ^ 19 * (17 - α) ^ 19 + 262146994169564092167982595241915300650038077337630821023247107830038522 * α ^ 20 * (17 - α) ^ 18 + 546246295187027447378330498619919154502317914469485801874390148357919248 * α ^ 21 * (17 - α) ^ 17 + 985534144714139122250483741567233765101065359192115038605404874832119258 * α ^ 22 * (17 - α) ^ 16 + 1530417579360385957788702153622880731287836667255896423677766156573103972 * α ^ 23 * (17 - α) ^ 15 + 2032430461020079853532514261208602767750794542173780707088682857868910994 * α ^ 24 * (17 - α) ^ 14 + 2292218444285680589433098519469973212042230727005845801142745772952622648 * α ^ 25 * (17 - α) ^ 13 + 2178219997541878792508669700595426088654476354491195218415916040098361367 * α ^ 26 * (17 - α) ^ 12 + 1727949063757596178243483752801428201813213932341449769191552685893782458 * α ^ 27 * (17 - α) ^ 11 + 1131913488897144192892030857095843493930963307289300925015925127269708335 * α ^ 28 * (17 - α) ^ 10 + 605118754195259451063140144378285109492445949756638818759841365239660040 * α ^ 29 * (17 - α) ^ 9 + 261880298008050145266750753761576086552682439953827145257817540609824860 * α ^ 30 * (17 - α) ^ 8 + 92875679601113717412714391333499851806464327195844345337907650773348120 * α ^ 31 * (17 - α) ^ 7 + 29072995044312488455979921670033751326475480533216429941625836322969708 * α ^ 32 * (17 - α) ^ 6 + 9369857362358365457781039003340826933535211191808499527159369766606160 * α ^ 33 * (17 - α) ^ 5 + 3266469696161126128466003284878933770066029563371692346986063283168790 * α ^ 34 * (17 - α) ^ 4 + 1021356923480101951479641774555034890704687659508130011121545901779380 * α ^ 35 * (17 - α) ^ 3 + 230938112747876039693246783422362329462732319382520584715540384755870 * α ^ 36 * (17 - α) ^ 2 + 31563581230674524529692712927313637685716918468331288776448654765600 * α ^ 37 * (17 - α) ^ 1 + 1919753133109689509058670629650134022172078593720565270277159571400 * α ^ 38 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `40 ≤ n ≤ 41`.** -/ -theorem finite_range {n : ℕ} (h0 : 40 ≤ n) (h1 : n ≤ 41) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (41 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (41 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 39) + 1 / (4 * 39 * (3 + α)) - + (1 - 2 * α / 40) ^ 2 * 41 * 40 * (41 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 39 * (3 + α)) ^ 18)) - = 1 - (653328533869198792815460418567456328463360027860000 + 4157882298167732116226370617284188848212873011241200 * α + 12532182988010399386002617462745633312768152237121570 * α ^ 2 + 23778313854745445633723704693422676769304621097023060 * α ^ 3 + 31839691004956228828005033576674262680347642949789970 * α ^ 4 + 31966947875077850162540664582127534223677059725715480 * α ^ 5 + 24954452263842718944480719755732872419125467194310990 * α ^ 6 + 15498456398852386516930447507216103141023058978163900 * α ^ 7 + 7770525510255924837049186376423929043180641908035178 * α ^ 8 + 3172282421659051612506049390871943668830947112996128 * α ^ 9 + 1058580212642493803810630674822381941853484677345557 * α ^ 10 + 288603554681274589435804606029301359165948874522986 * α ^ 11 + 63964171378367904791712568423672278670444648520985 * α ^ 12 + 11403554558448059539985445321284291979921951939708 * α ^ 13 + 1604683068013899575897130419685118852646893739688 * α ^ 14 + 171973766788073602692262435759609700705097645552 * α ^ 15 + 12777319017916275759622043304057680904260665896 * α ^ 16 + 232511338229217727198624028718607742301689616 * α ^ 17 - 736152391583269859036039443814447014605197787 * α ^ 18 + 32344027389559443630831441714104468449897746 * α ^ 19 + 226192739078384191702850277844962783099369 * α ^ 20 + 21321388850847068435151126284573459826132 * α ^ 21 + 1002825060545767936823647697965569833484 * α ^ 22 + 20605096429138626101144518690493027136 * α ^ 23 - 588379321688541475027751329888140192 * α ^ 24 - 68916522458163479393324809629479808 * α ^ 25 - 3219999749177967431080752136593024 * α ^ 26 - 101984865798504570834320095942656 * α ^ 27 - 2433981075208899701339322164736 * α ^ 28 - 45526079756647968714698102784 * α ^ 29 - 678401876172921453922277376 * α ^ 30 - 8091691517611230731255808 * α ^ 31 - 76978691001245722632192 * α ^ 32 - 577480811034021101568 * α ^ 33 - 3345672064015171584 * α ^ 34 - 14456978064408576 * α ^ 35 - 43900332474368 * α ^ 36 - 83629441024 * α ^ 37 - 75235328 * α ^ 38) / (780218937072834586624023381831090266352000 * (3 + α) ^ 19) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 40) (n₁ := 41) (k := 18) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B40_41 - -end Sendov diff --git a/Sendov/FiniteRange/Degree42_43.lean b/Sendov/FiniteRange/Degree42_43.lean deleted file mode 100644 index dacddf3..0000000 --- a/Sendov/FiniteRange/Degree42_43.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 42 to 43 - -`Sendov.R_le_batch` bounds every `R n α` for `42 ≤ n ≤ 43` by the elementary part and -moment at `n₀ = 42` together with the prefactor at `n₁ = 43`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 40, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B42_43 - -lemma M_lo : M 42 = 41 := by norm_num [M] - -lemma M_hi : M 43 = 42 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 42 α = 1 - 2 * α / 41 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 43 α = 1 - 2 * α / 42 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 42 α = (246 + 35 * α - 2 * α ^ 2) / (82 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 42 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 219060189739591200 - -def betac : ℤ := 17448114526187346549066687205352958439346512716307303958331193503998646681601 - -def tauc : ℤ := 83675483362775555753871784702064678413959227633983273607609487632759602705227770533595584449516473956737567288236057061603520976258897995523890979347135284767270941683924013557206505670332292634477582642146466194274433383815085341767709732417404998902472632206034851057073329819704543651604703868326481236237618726009910094192269813889902445189127636922680927472956340696445214458372963166740672133059375556968866023925328773039250302636684525955230132952676529232408311425066154449382631856947634071963981869845001783271294893602087748622457538038623036680277961541785450158590880140513546980382840528596316112265919397754168418916766069412356032024388287068807758640743628726273300248358801038448742113326591868854437003690181972400504593137779928443399677428665512083494669391223178476697729850087413913311579082243234707334926859459435552650295599023578986084265320372727973475306199875313276121704691024494868446555315290996182115162230317515694265496198677373272395166580427578667476978250024494642093344855418139187302935771789406850550002910360076251281571202150000087337518413336716472341285468045028931534553253043152118144537704788186146495696216790533697336854971296514265122494112335583790671128996233613735502871928060207975560078117834672420266826014540038667420856738184280177742772874232850600833868909545470974523371499911434518489340512375382944670808494747938400046256358477974554397639522396560056469504653738763723788317040665524800685638205333391000363304900877437343348955029834506706182117229804908715016246910817151285289161954363230651186873553395760883969202338822650546339683343198156404687739836665680529599784686996842630887996230978782936883606988847223908123346716417067685458877706902848266846769905801977357566566873879454119173817360765158863369897335564008145432648325426862276173673334790431345745817659305500218292001346915221485610279836613408931261278292455386917284525034119289221511174661871490889137056484290588076183663783076472071386797828494409413214458982376709419332778349022759672105259645548898917063465023862539840581919110568126231641579155452725980660233351615228901689537415033130868640661033963377155910387772260833090151847324138642941703850680822880305561006291012514498019606239138011674838756153494724622867655970507431989861612729218986449491868488671022713100142961280100039920648395557893950412170846922576260698741612423655561092788671450123818557070835124980841963668538514847935168584108665128970854240544883959705515712260546313419581055645533722126558555166630567824614332323679635334686907673863501667673209156796556984157243312689319227184177062408568970335105621048809664235459159004296203815683512794353719359715365001041268526071491789255426042335602775917617346123307840425480646416382185828364050235401095156570820368629893237124300232164339499723650502514472091418669119176324284332609688921978061975127217834805179658203630110313441065775664110038173679214687229071624659415325995982076930719861906495563536297002535680012809818401653555799475605164465039004865242379926039330718652736351320563382816279965934107172874787257817504077876968811852840148609960231198605783217781809689555376868500085438493126391590943636440243150238168648708861654233526457181301714553054752325789903120557013837503726388466261621669860240394189332722229288059252739495210188176583550555465576267348067731137647220598508516888791210912544824316836576664404274435877281489632758321980125468783618622761032814918092040060393877262657049488229781438352577343614418752506523502744234309746290817511752949083750826702594664818311864290479728798868559914791548470725159631508477582482267575384327305152882608093052283088800313011390419805338481838489443476985753505389780397010019368985723606250878351689401307017391836291705099272826735707881090498897738542641182440819765775350574599116585109290573535890975921502617720156237156401987887209771985138809396901826637651833543479380470557465065679716536191223047710646697468133436733488742277952152837905503673412217964264244496615892008948937263675974188660545720885470357362356644834579054596997538222522824373437071251489961064478351142393171311700469341085521319261158537675662438003704477075901866472752480171888073274316011435969810640624446826961935523764734283869311253437064242046449108661574426274101599721164509541838531663540340483838074393110240207147084893450921538882743925972359031320176454917834257621455813147124965598399292478744038266622504583955165292415418369 - -/-- The moment numerator at `n₀ = 42`, `k = 19`. -/ -def Nmomc : List ℤ := - [1310158984431240513158758282541801338875827575969032437760, 9416965620683434064147691096511725685776136198093390479360, 32263806872014617509885508467707288834343060133876345077760, 70094826595607656517457481632653961019951053399215151513600, 108367046031903021112407403329833557109262406801704867594240, 126825252108632110881947812247355043641593452199645911449600, 116698377603063318999906233879843826076317633583420413050880, 86561396377375976948362710707967343495351062910114014953472, 52655364817890293660461984058821739091013807355473211424768, 26586277040006700950968084973595369270586510417359547662336, 11237735540512699882913048057700938629245136223601652924416, 4000885801242719767301979742462563023777093705282994831360, 1205207337344337963091004503399068914730701584132403625984, 308391977823152947155340299273870278612455297741077086208, 67347138823602776254945137974597335973121985461406924800, 12652584947994602054811536231146317726566634249988866048, 2080469673842755044416859176893902007793302732142542848, 313711959064060779783708525807153147416632173372899328, 52699111083378172800989746049789895014964245425029120, 33846494362462825353445433245153483242913703040909312, 1961121939466669610230791371581701264377468594159616, 103986496444645059151769894127774963443023730442240, 4814485189516846205268959100954170886191717548032, 189827586896308129765626386720228656212193837056, 6307044407114500771434812674005311646741823488, 175992758363145188544400825055364498541510656, 4122058758924467754177483772129741853687808, 81024478120487769472617558208825459212288, 1335296356524070231215193043272483209216, 18403234097606917133480010999876550656, 211115479132694253716575922184781824, 2000678968776445574732491725471744, 15486212176666329230812360212480, 96294801242910838182484377600, 469335683915152777059237888, 1726942819118549355724800, 4510712620291058565120, 7454258377519005696, 5859847220232192] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 42) (gg1 42) (gg2 42) 19)) α := by - refine pev_moment_eq_of_packed_bounds 42 19 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 42 α t ^ 19) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 42 * (3 + α)) ^ 19) := - integral_moment_packed 42 19 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-40 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 40 * P α` is a positive combination of `αʲ (17-α)^(40-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 1280928413415314397834869540387070773955050164531041030 + 8579596886133703000731870831081948314922065693350883370 * α + 27292297105154921952287403075281892231896279402880100950 * α ^ 2 + 54824009941858550176912358984664841592247597016637905770 * α ^ 3 + 77993650469489645959523814188253045468476206212378807150 * α ^ 4 + 83524935090318289329452750100125758268073947901595075110 * α ^ 5 + 69864044339248988241671793073316243248508325653371578960 * α ^ 6 + 46735744905970337877740011413866843308996677044757141876 * α ^ 7 + 25392412342651970229153408582081225972535817324636108157 * α ^ 8 + 11314456845720888558092495939704512751963595258860145451 * α ^ 9 + 4156583831931947231874280330967249614130082308880369711 * α ^ 10 + 1260841374442113914894353137980805411382131606623222097 * α ^ 11 + 315103088046242389807187425423229491723179974811052320 * α ^ 12 + 64474796856269342035203905269807575254628539228620830 * α ^ 13 + 10677851103479065036063092086580878016800993639429844 * α ^ 14 + 1403715274370741006129430385190458757679221958797478 * α ^ 15 + 141371440744366093378881819780110077583832470458881 * α ^ 16 + 9967433380699679025437124999852577310642665327515 * α ^ 17 + 193067019640064558163668388981876117360705214251 * α ^ 18 - 526348205714148288340590540843861549545919252135 * α ^ 19 + 21747004181067783415574645835305370950903835816 * α ^ 20 + 112680245244072016728446540389593488784136590 * α ^ 21 + 11981738273725154350817268365041623637172994 * α ^ 22 + 613973728602142293085684365363276715529976 * α ^ 23 + 15948973394297291153786386954935347707464 * α ^ 24 - 107684213318232680083685034683113736832 * α ^ 25 - 31027964293347059199661593149947343808 * α ^ 26 - 1633467609886255958992085630289238016 * α ^ 27 - 55350060514047685232072125284311296 * α ^ 28 - 1399005645314407761350477999499264 * α ^ 29 - 27739113827411317709592921773056 * α ^ 30 - 440917774047260414297889849344 * α ^ 31 - 5667329623457291353154629632 * α ^ 32 - 58939961119748330433282048 * α ^ 33 - 492976521437911894081536 * α ^ 34 - 3273203375389549068288 * α ^ 35 - 16876898137105432576 * α ^ 36 - 65205684590477312 * α ^ 37 - 177752858296320 * α ^ 38 - 305048059904 * α ^ 39 - 247988224 * α ^ 40 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 40 * (1280928413415314397834869540387070773955050164531041030 + 8579596886133703000731870831081948314922065693350883370 * α + 27292297105154921952287403075281892231896279402880100950 * α ^ 2 + 54824009941858550176912358984664841592247597016637905770 * α ^ 3 + 77993650469489645959523814188253045468476206212378807150 * α ^ 4 + 83524935090318289329452750100125758268073947901595075110 * α ^ 5 + 69864044339248988241671793073316243248508325653371578960 * α ^ 6 + 46735744905970337877740011413866843308996677044757141876 * α ^ 7 + 25392412342651970229153408582081225972535817324636108157 * α ^ 8 + 11314456845720888558092495939704512751963595258860145451 * α ^ 9 + 4156583831931947231874280330967249614130082308880369711 * α ^ 10 + 1260841374442113914894353137980805411382131606623222097 * α ^ 11 + 315103088046242389807187425423229491723179974811052320 * α ^ 12 + 64474796856269342035203905269807575254628539228620830 * α ^ 13 + 10677851103479065036063092086580878016800993639429844 * α ^ 14 + 1403715274370741006129430385190458757679221958797478 * α ^ 15 + 141371440744366093378881819780110077583832470458881 * α ^ 16 + 9967433380699679025437124999852577310642665327515 * α ^ 17 + 193067019640064558163668388981876117360705214251 * α ^ 18 - 526348205714148288340590540843861549545919252135 * α ^ 19 + 21747004181067783415574645835305370950903835816 * α ^ 20 + 112680245244072016728446540389593488784136590 * α ^ 21 + 11981738273725154350817268365041623637172994 * α ^ 22 + 613973728602142293085684365363276715529976 * α ^ 23 + 15948973394297291153786386954935347707464 * α ^ 24 - 107684213318232680083685034683113736832 * α ^ 25 - 31027964293347059199661593149947343808 * α ^ 26 - 1633467609886255958992085630289238016 * α ^ 27 - 55350060514047685232072125284311296 * α ^ 28 - 1399005645314407761350477999499264 * α ^ 29 - 27739113827411317709592921773056 * α ^ 30 - 440917774047260414297889849344 * α ^ 31 - 5667329623457291353154629632 * α ^ 32 - 58939961119748330433282048 * α ^ 33 - 492976521437911894081536 * α ^ 34 - 3273203375389549068288 * α ^ 35 - 16876898137105432576 * α ^ 36 - 65205684590477312 * α ^ 37 - 177752858296320 * α ^ 38 - 305048059904 * α ^ 39 - 247988224 * α ^ 40) = 1280928413415314397834869540387070773955050164531041030 * (17 - α) ^ 40 + 197090283600885526925836585743875952311877123368206658490 * α ^ 1 * (17 - α) ^ 39 + 14574870761360362764007488091265713791496293430458196852260 * α ^ 2 * (17 - α) ^ 38 + 689807122352331972850018568182567669403146541709879062869200 * α ^ 3 * (17 - α) ^ 37 + 23474981116788659940295903209229597513213621976643052103205180 * α ^ 4 * (17 - α) ^ 36 + 611866838450106888263269653882018737667714606579935222429231160 * α ^ 5 * (17 - α) ^ 35 + 12704966108874081414158869474590380254978128823530400951437383070 * α ^ 6 * (17 - α) ^ 34 + 215835205701475999098573854286109430455663338527171355584817462378 * α ^ 7 * (17 - α) ^ 33 + 3057463015648964051048726715818912718934404644565989436353377379661 * α ^ 8 * (17 - α) ^ 32 + 36627145478607558025819186137856364423514446441125420313957605902195 * α ^ 9 * (17 - α) ^ 31 + 375047859308149340518089344648422780629330440775991914316145068984356 * α ^ 10 * (17 - α) ^ 30 + 3309722847734299600989754701031358954177490834341008198660668294423486 * α ^ 11 * (17 - α) ^ 29 + 25334280905778547167991484601858053756995044929407956045911106763735047 * α ^ 12 * (17 - α) ^ 28 + 169053231472854221672538042658045160250622512820809581036739296186604987 * α ^ 13 * (17 - α) ^ 27 + 987295696101506016750123997135936935428967974131049275929891243289099020 * α ^ 14 * (17 - α) ^ 26 + 5061855600544715172298535944485508872496786942997547092399772690908724552 * α ^ 15 * (17 - α) ^ 25 + 22836459878606542127997069590698683872398300158025332179037971805498008466 * α ^ 16 * (17 - α) ^ 24 + 90815511641941473829215661492687510352960775737402151799341783414491782134 * α ^ 17 * (17 - α) ^ 23 + 318734183329134027469187419914043420985326381868548104315467322483762890280 * α ^ 18 * (17 - α) ^ 22 + 987849647539835196212635720362290798791340169209853062676349181616504012372 * α ^ 19 * (17 - α) ^ 21 + 2702794013053376717386235575702898281842016607777011413996179654284315020276 * α ^ 20 * (17 - α) ^ 20 + 6518481722287093687872286675516248686966900062551161802625983585543325193064 * α ^ 21 * (17 - α) ^ 19 + 13819577825963737277443482404663949106919306450306673694620269914296761836662 * α ^ 22 * (17 - α) ^ 18 + 25656213473396052436767203417861850495715135024347044339699650611836313451386 * α ^ 23 * (17 - α) ^ 17 + 41518212269954562717893522706197113635871186246049005811923337699275786209441 * α ^ 24 * (17 - α) ^ 16 + 58264237368783003337224503745095851911428895082867699051272864692889281810823 * α ^ 25 * (17 - α) ^ 15 + 70509961613749498938328718833682422186993284582226371629980357718310864201564 * α ^ 26 * (17 - α) ^ 14 + 73129293701134101287464321060861793455351594458440621340710860077426859412246 * α ^ 27 * (17 - α) ^ 13 + 64542036519874264738723665643239022405337439766598405390089713472010764525231 * α ^ 28 * (17 - α) ^ 12 + 48068721003017849550137162829500406726021869001249651041646233420511089834739 * α ^ 29 * (17 - α) ^ 11 + 29908472648708029501911019147420406642840298425192025295010509794183714590200 * α ^ 30 * (17 - α) ^ 10 + 15366480688785955559510007565183167290828149965129842034139827497171629495988 * α ^ 31 * (17 - α) ^ 9 + 6442852602434353997138149389259641709926610254417225973756279884877273521210 * α ^ 32 * (17 - α) ^ 8 + 2192109403287939599157040147405748715444730026475711367949290093543157305286 * α ^ 33 * (17 - α) ^ 7 + 617553044098254770008870419213467265211621023542309177891008000912439731428 * α ^ 34 * (17 - α) ^ 6 + 156511669279787056670653626987150971088769146525896634427590110835904143048 * α ^ 35 * (17 - α) ^ 5 + 40425174529035112350411546621406361023805738975780328231031555794395201242 * α ^ 36 * (17 - α) ^ 4 + 10426184083634003349248930440636043818034523209966796671645165924159912258 * α ^ 37 * (17 - α) ^ 3 + 2178083492795567226675987694618231233066113322011885814782838606188228664 * α ^ 38 * (17 - α) ^ 2 + 290493393201934314395217100992245864671975635874035159763234167124538720 * α ^ 39 * (17 - α) ^ 1 + 17674868145691221378279476901019271057432085542810612311003098402179200 * α ^ 40 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `42 ≤ n ≤ 43`.** -/ -theorem finite_range {n : ℕ} (h0 : 42 ≤ n) (h1 : n ≤ 43) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (43 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (43 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 41) + 1 / (4 * 41 * (3 + α)) - + (1 - 2 * α / 42) ^ 2 * 43 * 42 * (43 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 41 * (3 + α)) ^ 19)) - = 1 - (1280928413415314397834869540387070773955050164531041030 + 8579596886133703000731870831081948314922065693350883370 * α + 27292297105154921952287403075281892231896279402880100950 * α ^ 2 + 54824009941858550176912358984664841592247597016637905770 * α ^ 3 + 77993650469489645959523814188253045468476206212378807150 * α ^ 4 + 83524935090318289329452750100125758268073947901595075110 * α ^ 5 + 69864044339248988241671793073316243248508325653371578960 * α ^ 6 + 46735744905970337877740011413866843308996677044757141876 * α ^ 7 + 25392412342651970229153408582081225972535817324636108157 * α ^ 8 + 11314456845720888558092495939704512751963595258860145451 * α ^ 9 + 4156583831931947231874280330967249614130082308880369711 * α ^ 10 + 1260841374442113914894353137980805411382131606623222097 * α ^ 11 + 315103088046242389807187425423229491723179974811052320 * α ^ 12 + 64474796856269342035203905269807575254628539228620830 * α ^ 13 + 10677851103479065036063092086580878016800993639429844 * α ^ 14 + 1403715274370741006129430385190458757679221958797478 * α ^ 15 + 141371440744366093378881819780110077583832470458881 * α ^ 16 + 9967433380699679025437124999852577310642665327515 * α ^ 17 + 193067019640064558163668388981876117360705214251 * α ^ 18 - 526348205714148288340590540843861549545919252135 * α ^ 19 + 21747004181067783415574645835305370950903835816 * α ^ 20 + 112680245244072016728446540389593488784136590 * α ^ 21 + 11981738273725154350817268365041623637172994 * α ^ 22 + 613973728602142293085684365363276715529976 * α ^ 23 + 15948973394297291153786386954935347707464 * α ^ 24 - 107684213318232680083685034683113736832 * α ^ 25 - 31027964293347059199661593149947343808 * α ^ 26 - 1633467609886255958992085630289238016 * α ^ 27 - 55350060514047685232072125284311296 * α ^ 28 - 1399005645314407761350477999499264 * α ^ 29 - 27739113827411317709592921773056 * α ^ 30 - 440917774047260414297889849344 * α ^ 31 - 5667329623457291353154629632 * α ^ 32 - 58939961119748330433282048 * α ^ 33 - 492976521437911894081536 * α ^ 34 - 3273203375389549068288 * α ^ 35 - 16876898137105432576 * α ^ 36 - 65205684590477312 * α ^ 37 - 177752858296320 * α ^ 38 - 305048059904 * α ^ 39 - 247988224 * α ^ 40) / (508824949463896030944977981473879851039376800 * (3 + α) ^ 20) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 42) (n₁ := 43) (k := 19) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B42_43 - -end Sendov diff --git a/Sendov/FiniteRange/Degree44_45.lean b/Sendov/FiniteRange/Degree44_45.lean deleted file mode 100644 index af78c75..0000000 --- a/Sendov/FiniteRange/Degree44_45.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 44 to 45 - -`Sendov.R_le_batch` bounds every `R n α` for `44 ≤ n ≤ 45` by the elementary part and -moment at `n₀ = 44` together with the prefactor at `n₁ = 45`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 42, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B44_45 - -lemma M_lo : M 44 = 43 := by norm_num [M] - -lemma M_hi : M 45 = 44 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 44 α = 1 - 2 * α / 43 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 45 α = 1 - 2 * α / 44 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 44 α = (258 + 37 * α - 2 * α ^ 2) / (86 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 44 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 9419588158802421600 - -def betac : ℤ := 2390289318391773229344964722860880787962677879744753614007714635169522309608243201 - -def tauc : ℤ := 30895645272655873212373414359751171628524294919438719227704739509451568739542923660508315378175256317055179393322378542085265338691554547328826954800991577088772860159495278368736566354630380861590629462601808459636594988202337030778080927402857216431685323057492570639958915405605772779446225638451195428316411240127016566173070417991945819560857140771451116294342382466673793708859108635438330428609875568980886560074238461101558243072943461712056633597559703724114167409126213431635766096015346242948789819587367662652984421690854366192066275063529519272268345323341922817105130385063544543374559493222411261077522330019090234465488878795221153370266207605233694775894431211393216679578519800857204453894904560680858969273106338491263157760918746150380774110556684216184008613213292163612644631199293684349277567524648477520220921828584715296102220330960909494576134948285193722212325934223653976522706279042767471143881907354469206579399533073630980924296850252185278574283752154807142948962149477728313805391456901334567595085660100278932583120015519380526510855868522292318030964379752453945237759728283558892989624703003937495584136438854863844570164655351054145195808594479689195513377026461472889985329004864519055794969567175971809816153067610868266186639654634351148167162464396899955225516243327148154636223590155067354778487181926231695437118048860382552035940393713971436527849475350065511764234776344355748652121256153492705505833320860208481221894045192724135519840622363976627377862013040635835534223345189672394590993392782481552524485608464674233387372511348197591538040448381725106601523164730449704493703721140702320520351313206472988004843372550769793840291267134514501434620547629012679465249609788389463129361862765381878448624589665331336829618084142591323555895510728359822583003249491214417329717939699308938077817732405874992212713334288109196470176534363172741322489414869372431692517679212264759888071928350089918222740600712594429020954418458337950696796282589039860347919231405149934322640476156223778191674877104724705953914842099731417993416500401569874928785494136662118774341146572562294486441690649097706426731132087407959995039211160916547173368742980447520256843644238589466246764942008568922881767907839553446552389889943215068805332928725944927154690032771236679911525392146733434541990393143972189796671447081992885090601679277539233926222674611142541184008927294469213678488312662580523578021475641712536576239134747589838939672573763036753925634577407112230564784758881256822540749965465695052232626665861125097406789891411039060489171667793145292269337735461043498889497996784100665242169542571655130325135529304282492910747254664448765578634478743258607851785892190254018813607840683800434544079917937266525472224200137114807071888131900560098511056584338996482515234578246962161120698041700706293764921483911605205447875072816925530831628607012122733320447823872072969545068639235107002004277631326887120713768323376135216489970420234507053077403807596708541994521364470109694334770171724347455251828472714523414166476841569867760304908572680763196301205856388735747987251874883167579834032743031179076961396548214893688970658894234416841448077011262813659086495481622538879554797752798192546240530092807892685039118821388020757425467101916443905739933331690372519886661990122245971224299442729343464019763643029614337906347346552175602743285493070612155180678411933636997408649548024180156267641272723897480506576818901495435112362402704675351485498244146755085794709807513146221332119544603982409767505647303445944301799631732136774131994786985810054238020543617296862652319272433534690487057598889632402199341510945179551740621950934821440489877070196065512033501068110659536549341016663414084596060571461099407140410267821798530957178140978905900278056834459910237938598737482367806519728298697584234880584878096560168464884620511926772116107115996326227064121970559851934564068842899144457824536155684387407472016541797440722818180910626848792649636155867606131796134247622644166887173666335697993018124060222373231243034277989387190433206070124603413761296229209232550760518391396399255720423009191167518280224780914069104172536636205145891662071111940998699532675795635254648303406100957286737618985258843367967204857167883144434484290710653246412266186379833196557938055740296765158399471213312798686210380758768270116787968427312518623604484871280367400730281385320673456989088335512575137436708352593764808670221033557254812105160629259203499080580498571555345645761640215699497943087030270981327906069295273694630636551829504998736644601329615065698798215837783821424607002173127918980344774597661297105316261495010585932322883007417254554300355593922448264024231943800211643416550078799530290071881764608474804831493396439836319418864697550040721497948230295228545510166818474814252292428186456391962280286674388608212873563796732550737620062532916879534145183238007482917389258943934617049227548946764260768025456585383457136725664753946938483780198968312375281713153 - -/-- The moment numerator at `n₀ = 44`, `k = 20`. -/ -def Nmomc : List ℤ := - [29622588493274960680523891276232384437695166528349447546470400, 222519750414996484603132359195264216392243238608503741140172800, 798380205242313108181890582528029739005132395847123609636044800, 1820415011148535260648344778204164615571003000945433329323212800, 2960801077975295393846537091623757336918658237549860864550502400, 3654887933248511789932687636146316733707959705842325328075161600, 3557273587429108242774398299204237140914024030928031371912806400, 2799582837695897009700274416812717022326249700112667176127692800, 1812871960588012030396801043106548333437396746737968716164628480, 977857830307047526127852369039327396031007853365578620668477440, 443205250870840894128094342288416148664519703125073908906065920, 169834169083268671688230548627200277771778366064549243608104960, 55260268661757083229919972315372080001509486405949541182341120, 15316004702314096307516564212376146433172944490142876261416960, 3626206743427919248854701095351026405976258827647679096422400, 736149997155658480965596650242326013585748700328282292224000, 129053010442868743132849374964698195560873357869586369740800, 19856115399897482909269164494099900129142592255826570772480, 2806202259733571202666050754831208611035521451434683924480, 444779221294561277115371630916787171084660513545356574720, 290373838331741683646511062525894358284749391501878886400, 16092240013454615817093701739654935534034376811568168960, 828281688318844165802301926122973536646649712748789760, 37743003880197022162867431691566043438830264118149120, 1481226561516042064112028154463171645189243787018240, 49437189357069202418611636165470743049173100134400, 1396875810248512697947399939934547742728042577920, 33379516628918572655208663470536230610592071680, 674519958335488793530741980896934946186199040, 11521864782014081488765884430443735102259200, 166111626230642118894673459973903320350720, 2014870590890881775527624799322101514240, 20452651674459912251356564158582620160, 172338614210489982924071777096171520, 1191256141557218512833683631636480, 6640537318726594250852699996160, 29116621233892995084803112960, 96685513554623817842688000, 228557150695638549135360, 342726482509871185920, 245048156482437120] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 44) (gg1 44) (gg2 44) 20)) α := by - refine pev_moment_eq_of_packed_bounds 44 20 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 44 α t ^ 20) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 44 * (3 + α)) ^ 20) := - integral_moment_packed 44 20 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-42 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 42 * P α` is a positive combination of `αʲ (17-α)^(42-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 234355849074955263951049856572420428528087559257217338000 + 1647917825991745087828090979449220009324402935342213794192 * α + 5517259206635462357799308151379743852022400880405143709300 * α ^ 2 + 11697286850057325472448884282596125036178461096427071180160 * α ^ 3 + 17618194225546020573784427664650585416610740635319786403400 * α ^ 4 + 20046068608053045224231426681510601856273741292025591141480 * α ^ 5 + 17885461556571898483672892064956643539473640662999345701666 * α ^ 6 + 12820152657712533249363000294926617606868677915971896670240 * α ^ 7 + 7502523555651917287805352494007861019866814933742609160696 * α ^ 8 + 3622686298843516098851206612510488687148684155393129482472 * α ^ 9 + 1452571052316260978855070270500133585694231422375833061090 * α ^ 10 + 485064610274304784360415817487598469472479148412401415808 * α ^ 11 + 134868827326575807784515799657395435527619954194004227748 * α ^ 12 + 31113923159253038634767916248106358904477281041358348956 * α ^ 13 + 5912609861703141760519754094833940739302488844248812479 * α ^ 14 + 914297729950293095944937323513702712183136890515661088 * α ^ 15 + 112786258002906693411402876201621614411462995639363644 * α ^ 16 + 10715561597079704979556413609803278787797162405942296 * α ^ 17 + 719193622230655390355126847425184862615908011115060 * α ^ 18 + 14657836127065470780938993503699490899434597229512 * α ^ 19 - 34950338977013178639767569738567864677193896372240 * α ^ 20 + 1366801847725067991778952117668601561839569590900 * α ^ 21 + 4959220152208557382027853908303681091859164175 * α ^ 22 + 615471404273198116343750989411396892897296680 * α ^ 23 + 34101039377472481958974903669374217452733632 * α ^ 24 + 1034386808344405409707750019488517511355008 * α ^ 25 + 5291527796743143896670464285156657893296 * α ^ 26 - 1219504316386418556368987826914293621248 * α ^ 27 - 75185184777106907253176174218461272832 * α ^ 28 - 2739147805326680629369630717760523264 * α ^ 29 - 73210280752772515350101169959614464 * α ^ 30 - 1531828473996677645738094611644416 * α ^ 31 - 25792432980458262033466819153920 * α ^ 32 - 353823743440056079889063264256 * α ^ 33 - 3970096169377863374039531520 * α ^ 34 - 36356947826301657371639808 * α ^ 35 - 269616704004970519658496 * α ^ 36 - 1596209219881105096704 * α ^ 37 - 7373431975900938240 * α ^ 38 - 25626639771107328 * α ^ 39 - 63065268682752 * α ^ 40 - 98008301568 * α ^ 41 - 72351744 * α ^ 42 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 42 * (234355849074955263951049856572420428528087559257217338000 + 1647917825991745087828090979449220009324402935342213794192 * α + 5517259206635462357799308151379743852022400880405143709300 * α ^ 2 + 11697286850057325472448884282596125036178461096427071180160 * α ^ 3 + 17618194225546020573784427664650585416610740635319786403400 * α ^ 4 + 20046068608053045224231426681510601856273741292025591141480 * α ^ 5 + 17885461556571898483672892064956643539473640662999345701666 * α ^ 6 + 12820152657712533249363000294926617606868677915971896670240 * α ^ 7 + 7502523555651917287805352494007861019866814933742609160696 * α ^ 8 + 3622686298843516098851206612510488687148684155393129482472 * α ^ 9 + 1452571052316260978855070270500133585694231422375833061090 * α ^ 10 + 485064610274304784360415817487598469472479148412401415808 * α ^ 11 + 134868827326575807784515799657395435527619954194004227748 * α ^ 12 + 31113923159253038634767916248106358904477281041358348956 * α ^ 13 + 5912609861703141760519754094833940739302488844248812479 * α ^ 14 + 914297729950293095944937323513702712183136890515661088 * α ^ 15 + 112786258002906693411402876201621614411462995639363644 * α ^ 16 + 10715561597079704979556413609803278787797162405942296 * α ^ 17 + 719193622230655390355126847425184862615908011115060 * α ^ 18 + 14657836127065470780938993503699490899434597229512 * α ^ 19 - 34950338977013178639767569738567864677193896372240 * α ^ 20 + 1366801847725067991778952117668601561839569590900 * α ^ 21 + 4959220152208557382027853908303681091859164175 * α ^ 22 + 615471404273198116343750989411396892897296680 * α ^ 23 + 34101039377472481958974903669374217452733632 * α ^ 24 + 1034386808344405409707750019488517511355008 * α ^ 25 + 5291527796743143896670464285156657893296 * α ^ 26 - 1219504316386418556368987826914293621248 * α ^ 27 - 75185184777106907253176174218461272832 * α ^ 28 - 2739147805326680629369630717760523264 * α ^ 29 - 73210280752772515350101169959614464 * α ^ 30 - 1531828473996677645738094611644416 * α ^ 31 - 25792432980458262033466819153920 * α ^ 32 - 353823743440056079889063264256 * α ^ 33 - 3970096169377863374039531520 * α ^ 34 - 36356947826301657371639808 * α ^ 35 - 269616704004970519658496 * α ^ 36 - 1596209219881105096704 * α ^ 37 - 7373431975900938240 * α ^ 38 - 25626639771107328 * α ^ 39 - 63065268682752 * α ^ 40 - 98008301568 * α ^ 41 - 72351744 * α ^ 42) = 234355849074955263951049856572420428528087559257217338000 * (17 - α) ^ 42 + 37857548703007787579021640626678398156694527389620762697264 * α ^ 1 * (17 - α) ^ 41 + 2944867021487431429882033394933706308696266088891073674557524 * α ^ 2 * (17 - α) ^ 40 + 146910666364742997856783011317318114681608355643172977318910560 * α ^ 3 * (17 - α) ^ 39 + 5281338930363712858347930254940637802165598810816949523191508760 * α ^ 4 * (17 - α) ^ 38 + 145753437649734017761868379170413156812750014126479617274091172120 * α ^ 5 * (17 - α) ^ 37 + 3212433660877561136639288711614882650266994711330586733979437268666 * α ^ 6 * (17 - α) ^ 36 + 58080099103816679194960077966232290827409612456400212654077549294136 * α ^ 7 * (17 - α) ^ 35 + 878073000124467105754351061548458968812316660181611332798436479232076 * α ^ 8 * (17 - α) ^ 34 + 11259922048324651489289493311309309631891001644523667321376037356186888 * α ^ 9 * (17 - α) ^ 33 + 123812154859041152773858816918455744865935561732076455885319152132304488 * α ^ 10 * (17 - α) ^ 32 + 1177282729304429087196944522508776379491442707108602485795557386562286720 * α ^ 11 * (17 - α) ^ 31 + 9744718648999432569661305582435950678261853364124701152000275689844790852 * α ^ 12 * (17 - α) ^ 30 + 70584478999572099526210718832986814594230665767170003296124002517210218548 * α ^ 13 * (17 - α) ^ 29 + 449272053601042666671596079622675645227192899930246481044206503873022598127 * α ^ 14 * (17 - α) ^ 28 + 2521166194604692753878031098107876914463687672229082966575780993950448786492 * α ^ 15 * (17 - α) ^ 27 + 12505743633148390302761257035504316007036914113543301212072536616680265609966 * α ^ 16 * (17 - α) ^ 26 + 54941752319236926994034527846178330055107665824491889262114770438776772080688 * α ^ 17 * (17 - α) ^ 25 + 214108133336419833203656668659528095997912595237383503399365023725947428991765 * α ^ 18 * (17 - α) ^ 24 + 740907981283804161674373017608569262860463894016142577208923888370995315389936 * α ^ 19 * (17 - α) ^ 23 + 2278016136661934557373907941895735701975033136406032948359780173720186398978768 * α ^ 20 * (17 - α) ^ 22 + 6223044015900732285273426821948491350903940514086744466166738234457122088918648 * α ^ 21 * (17 - α) ^ 21 + 15091573130026048461544325185690904741676446061897994842743984569608882476868246 * α ^ 22 * (17 - α) ^ 20 + 32431472815063210198529045051946172792892281829735717630866526639188278809402520 * α ^ 23 * (17 - α) ^ 19 + 61589977160019028252201500272191461481719309803518295921163839432202796081677436 * α ^ 24 * (17 - α) ^ 18 + 103000834533491129063640284036092678067268542010637673258239410761540957030115384 * α ^ 25 * (17 - α) ^ 17 + 151071516679099175443820464035839365942459349434188215403085360254317550609833028 * α ^ 26 * (17 - α) ^ 16 + 193445346233280859296440806414848722181948957409609959791787404726401564917282096 * α ^ 27 * (17 - α) ^ 15 + 215172096945268414340053333093031776453400001175778749956470312358926404221592428 * α ^ 28 * (17 - α) ^ 14 + 206736790098352378662725797487880027357919714030453368776992727928497863099548756 * α ^ 29 * (17 - α) ^ 13 + 170462524827332695320086649521380810293612989490733605162878601757384672794284747 * α ^ 30 * (17 - α) ^ 12 + 119693210823537512228591503646550664793242492067851215311990782497984104429398428 * α ^ 31 * (17 - α) ^ 11 + 70908831093339465886818052612765873755388314931239009902767176459421394442785742 * α ^ 32 * (17 - α) ^ 10 + 35048237403311100028743507259452310464158209931947679191434306115144076602284800 * α ^ 33 * (17 - α) ^ 9 + 14268450259765073448679759926668655504802778135164107658390044566561421617189673 * α ^ 34 * (17 - α) ^ 8 + 4724185205300768110792705712599630650015863880955341087853206634323491488643616 * α ^ 35 * (17 - α) ^ 7 + 1265299135971789660909673234797601828374717278246484983747256160401664255750872 * α ^ 36 * (17 - α) ^ 6 + 280178539570804945484739775418806390334413870080009334057823189831955617940552 * α ^ 37 * (17 - α) ^ 5 + 55439566906689638975335374901816806066147146428085261656377329665751391494454 * α ^ 38 * (17 - α) ^ 4 + 10724868311110483392855160615399587116240195810586300982060213202048731748152 * α ^ 39 * (17 - α) ^ 3 + 1891608447746568174857958621996992326295338311284555046921110287910697380220 * α ^ 40 * (17 - α) ^ 2 + 236532288128129299669916971619583813438473071647279968567818223819695392000 * α ^ 41 * (17 - α) ^ 1 + 14180011930716980449379240294714564887587943224073955569876816155335397250 * α ^ 42 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `44 ≤ n ≤ 45`.** -/ -theorem finite_range {n : ℕ} (h0 : 44 ≤ n) (h1 : n ≤ 45) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (45 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (45 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 43) + 1 / (4 * 43 * (3 + α)) - + (1 - 2 * α / 44) ^ 2 * 45 * 44 * (45 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 43 * (3 + α)) ^ 20)) - = 1 - (234355849074955263951049856572420428528087559257217338000 + 1647917825991745087828090979449220009324402935342213794192 * α + 5517259206635462357799308151379743852022400880405143709300 * α ^ 2 + 11697286850057325472448884282596125036178461096427071180160 * α ^ 3 + 17618194225546020573784427664650585416610740635319786403400 * α ^ 4 + 20046068608053045224231426681510601856273741292025591141480 * α ^ 5 + 17885461556571898483672892064956643539473640662999345701666 * α ^ 6 + 12820152657712533249363000294926617606868677915971896670240 * α ^ 7 + 7502523555651917287805352494007861019866814933742609160696 * α ^ 8 + 3622686298843516098851206612510488687148684155393129482472 * α ^ 9 + 1452571052316260978855070270500133585694231422375833061090 * α ^ 10 + 485064610274304784360415817487598469472479148412401415808 * α ^ 11 + 134868827326575807784515799657395435527619954194004227748 * α ^ 12 + 31113923159253038634767916248106358904477281041358348956 * α ^ 13 + 5912609861703141760519754094833940739302488844248812479 * α ^ 14 + 914297729950293095944937323513702712183136890515661088 * α ^ 15 + 112786258002906693411402876201621614411462995639363644 * α ^ 16 + 10715561597079704979556413609803278787797162405942296 * α ^ 17 + 719193622230655390355126847425184862615908011115060 * α ^ 18 + 14657836127065470780938993503699490899434597229512 * α ^ 19 - 34950338977013178639767569738567864677193896372240 * α ^ 20 + 1366801847725067991778952117668601561839569590900 * α ^ 21 + 4959220152208557382027853908303681091859164175 * α ^ 22 + 615471404273198116343750989411396892897296680 * α ^ 23 + 34101039377472481958974903669374217452733632 * α ^ 24 + 1034386808344405409707750019488517511355008 * α ^ 25 + 5291527796743143896670464285156657893296 * α ^ 26 - 1219504316386418556368987826914293621248 * α ^ 27 - 75185184777106907253176174218461272832 * α ^ 28 - 2739147805326680629369630717760523264 * α ^ 29 - 73210280752772515350101169959614464 * α ^ 30 - 1531828473996677645738094611644416 * α ^ 31 - 25792432980458262033466819153920 * α ^ 32 - 353823743440056079889063264256 * α ^ 33 - 3970096169377863374039531520 * α ^ 34 - 36356947826301657371639808 * α ^ 35 - 269616704004970519658496 * α ^ 36 - 1596209219881105096704 * α ^ 37 - 7373431975900938240 * α ^ 38 - 25626639771107328 * α ^ 39 - 63065268682752 * α ^ 40 - 98008301568 * α ^ 41 - 72351744 * α ^ 42) / (30972068525792759965739480222844093512456083008 * (3 + α) ^ 21) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 44) (n₁ := 45) (k := 20) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B44_45 - -end Sendov diff --git a/Sendov/FiniteRange/Degree46_47.lean b/Sendov/FiniteRange/Degree46_47.lean deleted file mode 100644 index 3bb33a1..0000000 --- a/Sendov/FiniteRange/Degree46_47.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 46 to 47 - -`Sendov.R_le_batch` bounds every `R n α` for `46 ≤ n ≤ 47` by the elementary part and -moment at `n₀ = 46` together with the prefactor at `n₁ = 47`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 44, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B46_47 - -lemma M_lo : M 46 = 45 := by norm_num [M] - -lemma M_hi : M 47 = 46 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 46 α = 1 - 2 * α / 45 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 47 α = 1 - 2 * α / 46 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 46 α = (270 + 39 * α - 2 * α ^ 2) / (90 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 46 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 9419588158802421600 - -def betac : ℤ := 8004502266586906910644135897387874769115493744091408742845553868496139316215205068801 - -def tauc : ℤ := 5529675683574113215496465141747925616852745584176477922345327839900057628584904415709809582964753005173947960917927876804763546062721126436962836616950051888805571033773402864781892825745530152049979687478211396908735665603948983037117466225557809922914848084539993232502884578153442350004133117981481608054849250443696454336837507719530107053004293440704556970648164645542879872883944872656953340173861780696223804312991802957362246568312402677304112721698201866495242481410536979243220093230768430902757247556208190227641449624979722142962987687184899293471759891145001639830787934479344730480089915983926695898479969726051321735229879948478450960937236429400969359178410978656995135839682858635829910989060644463512829168058081153191895164648693148205112271405441025296234039705249955352888860297004775092267730028589389302076190719417296041056474800363750348903038709139629924020428126987923964847814304361987053968406884846202942645707083955974994642505315223441627168023888282525289809706027968418966934488460273987797693436564794031838854170025395566206384639112000860468935672555018847433458866333347798233488073697401822518734874233691090959019994547778151148789336733810281671285763895312635312050380587421080845331202565974083839222794326479376042587197446154065190519061274357112963009806525643898991922279831796529278832717157357536035805967588074269145682746700085169336134785947455531623586375854469477380188688723748500818294737045963856340212109052943583242268884321532064359440414678703522700468961366306127251240478513945066030464711919944879765187194390263545875928984372789421846040911769422185466952897690863893057412893964740965352334533776512045882402546092252639365352181068916118209070449550391469823128593782867455807419943732400401987591514793914139907358448155398504084379317010886275623494742133422959338384750468375136488707785614088278171217972089961341746011011309123697223574623022744780342379838869744721213724711341332358644859931972342846401999854465543207923888692548103744381319630663759119104965553856094406580351939991731757788792182853743648392655912399486014399273233418722656442245317146475774754723097236346049742676271046004590063904416654842778506262602682401245726993853715990362627855585356197481925227154210021000428960067973138261233966058935570561657390033384784945783390967211809741852877485039491281030372145836313076328326377904697008378179908369219182036839012582446327179386963504826895892065348280289605721640101913328219645690776831025703232598902198328050430184770964330221128703209004283352230382477882159900552789114803068080404950365687986729605625431937115151572981856004688732759376574425230026359553555636204700353395199816148980421739038154745805664823430168203617941230620667158680163026328067567699818773715419056639860000813531810680916848547617963592955348091252862008547466509223819202353101352664950967609787687650135149901531238698972751221526545439669463472803071794239403173498855703990614704431183527057440592610529661428024690241151240995134934530902209853061716191445506214864701668398628982552846005208546950280170908924794392776116124013154107937006858373792009853748221080990309299050661263406746296258073420730450323475133232351565189166231893746770070199383320270746728281410548625914676201340987369202313348743916064171924836645549187846485865116101351763911866654823121079553603289440416961920085477306864482465308722146790577928386339617139996948804399422296102418223817989910197209513680151915544017334713082359615710027417312265094006173814520644156651909885772350619149698665944750034033354988057763460107600227523836807766162989850439754558580439489490337760279744706115193741542610455825503197377540502050119066095257738304601324874209804933878035269673519637041298595728272054433739649755131375398385563444354109287634080195106240209610474120854573327662365331707936444573609652763553083318061415282130117590116041654788940643281199667826428038280118245927478705527004860587901186399688988756996494518216089029368474874597921324557523877587922186898235509429199347540394222769320968276512022761766665816533371941971675901791558321887157246034937854471254874601435092615946990971572326064185921331685456807606673273152374788692576108934656539468784557621859007284353642579353039252664550708959526516680790763738012314000385479633091489000112768576832127400253993546427669577934590319056029660535081643428404369606946155533317406695881001036803147110823502614044778021722737592558957007249467400111085377847754054892000020141930743174483386963509027978090694147973505662980667419115381570039982145183477206851805888622312026416837015589531512381390212420827747298047738113302526601936620838501212043821347208891460473654179981732469438254057318884834659468857923040611212178364640945958389564034458835258715978497089097382816975401185825803752387885725821638992483556915519746390179162984282139486420268356183379891779447391959867218850849961602299184305723034786145496573158793029955587857533063263290511178769011397892121273362284167996190948873157311038236983644872277441763986673834993201612649188028674813608820539058441064514459248771400340731119834567349961932032841848125671831089892426475798550608623628441305470629995004957587646211794587833696010577982746583901231847943048681831613998582205262082368440229871809427186524115878970276448116274789738865126790045713828048628258551730355942587684705133037803723102665115918565516421538151413897139856583124302503778358200580443993330487758622365319169 - -/-- The moment numerator at `n₀ = 46`, `k = 21`. -/ -def Nmomc : List ℤ := - [16516983512934610391847423833431135956724680000000000000000000000, 129441227432802998187383144285951650297171896000000000000000000000, 485426390615606421347865854625634740387325272000000000000000000000, 1159245979117431372792765895879253123033182113600000000000000000000, 1979083696923772431505285591326378142178320649760000000000000000000, 2570519914867877924329496222299668259665380295494400000000000000000, 2639310680395700360366002102933762267105131863047680000000000000000, 2197490413574592390070691430134991356210427456744960000000000000000, 1510083224344101530830242031762828711503088011126528000000000000000, 867274594668937360443194811390002999193322643755468800000000000000, 420030574453140194442567223016903158090837070101641216000000000000, 172632333979196489833213132576491900830886816086604595200000000000, 60475717696920747221746668747193930172399263533982310400000000000, 18111088719422555142373705220772995717907129094427811840000000000, 4646467063827947937672674250124412542082459797774761984000000000, 1023201899510279784922266924400099792079542239675568619520000000, 193978317039902504077191131698581928673777817372655878144000000, 31859650009374932911472979205629276114643913668523458560000000, 4603069737998020872570350023394432450261148255889721917440000, 611555492178564781673098561172525176926667912627344113664000, 91673601308467446828540119055766031896209770656250871152640, 61039323590384794686343504389281543303497342978925430571008, 3236022958130157275077503344670580556994479152594446974976, 161503210550472247818550483481290286579109900271610757120, 7230821721369562414545740625332404436911303243931320320, 281889568943431886847247071419000319070698283519180800, 9429215323885111464310549162178523629590885322194944, 269049458770466159231070104630611451688595948044288, 6537721830811047354460896653009845201098894213120, 135267574787816921107916648715815907402417438720, 2382851947168706680040504334566815017719562240, 35709078496202658750028103112300178358403072, 454295556348131461973960374557399847010304, 4888251215549201568398291082857718743040, 44226151872122850437473766372058071040, 333566157342704621251872635580579840, 2071741632440286111100666134921216, 10412679585010384122770192596992, 41293667520147699383465410560, 124369997546451803842805760, 267349158171025216634880, 365411549239540973568, 238655595878547456] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 46) (gg1 46) (gg2 46) 21)) α := by - refine pev_moment_eq_of_packed_bounds 46 21 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 46 α t ^ 21) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 46 * (3 + α)) ^ 21) := - integral_moment_packed 46 21 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-44 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 44 * P α` is a positive combination of `αʲ (17-α)^(44-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 842100496490164655863899050953513048577517889022827148437500 + 6202389537263705762292576691419085693567510900497436523437500 * α + 21800976172966131822633999416830068976610560420989990234375000 * α ^ 2 + 48647779340585710046299723714124054163748508466339111328125000 * α ^ 3 + 77335744367973576659808264003823907539197097243080139160156250 * α ^ 4 + 93163317164153721286069997796054376135656931010389709472656250 * α ^ 5 + 88315055516249458646175698818625653153167262528008728027343750 * α ^ 6 + 67525482393603249349320023657815936540710634750331726074218750 * α ^ 7 + 42343249160820224575714518101180101058857691214973571777343750 * α ^ 8 + 22022629774039619130278840067223760137223751259001110839843750 * α ^ 9 + 9569037722124326061646207068547925124389847238604876953125000 * α ^ 10 + 3487611243366543917723910686246986580789320695836231250000000 * α ^ 11 + 1067491157924455805861448662311325524405538803060341943359375 * α ^ 12 + 273968142184015848925560036581877108638855706237317490234375 * α ^ 13 + 58692019460587884114525551639474562464674600041476138671875 * α ^ 14 + 10411576695976844279717630513220926151802953315673888359375 * α ^ 15 + 1509986509025418223518044667529937663568415780777702125000 * α ^ 16 + 175469918947028739649743022943799878357086029596651812500 * α ^ 17 + 15779760028253605454031412572296146026014740194967383750 * α ^ 18 + 1010913062001619607789595546144718629262771585185507750 * α ^ 19 + 21462061397781700126941815631803690593259676260498115 * α ^ 20 - 45387057094906818237348334721211459766084329446075757 * α ^ 21 + 1689541722499339437202551579490531894232999398986279 * α ^ 22 + 3936001560036108693341101447415785391643174835443 * α ^ 23 + 607977630486171911031424776719828152869889423044 * α ^ 24 + 36336260809521268434231902077696447132341347400 * α ^ 25 + 1235785272488557483704068508469144496017205184 * α ^ 26 + 15739109405711750147519445570667095018389712 * α ^ 27 - 844836507113777181276666926325076953789696 * α ^ 28 - 65867488403154309232905535325099415940608 * α ^ 29 - 2603492828180830946162421054768504476160 * α ^ 30 - 73591830258372192880755514270838320128 * α ^ 31 - 1619902372241517858218483163123738624 * α ^ 32 - 28740854840777906929998653281886208 * α ^ 33 - 417683720829155224442216354095104 * α ^ 34 - 5006133645480122906718714101760 * α ^ 35 - 49524449888141405612129746944 * α ^ 36 - 402720876040696001365082112 * α ^ 37 - 2667361119757440577634304 * α ^ 38 - 14172645073027210739712 * α ^ 39 - 59000480246059499520 * α ^ 40 - 185464776902049792 * α ^ 41 - 414106827882496 * α ^ 42 - 585532178432 * α ^ 43 - 394264576 * α ^ 44 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 44 * (842100496490164655863899050953513048577517889022827148437500 + 6202389537263705762292576691419085693567510900497436523437500 * α + 21800976172966131822633999416830068976610560420989990234375000 * α ^ 2 + 48647779340585710046299723714124054163748508466339111328125000 * α ^ 3 + 77335744367973576659808264003823907539197097243080139160156250 * α ^ 4 + 93163317164153721286069997796054376135656931010389709472656250 * α ^ 5 + 88315055516249458646175698818625653153167262528008728027343750 * α ^ 6 + 67525482393603249349320023657815936540710634750331726074218750 * α ^ 7 + 42343249160820224575714518101180101058857691214973571777343750 * α ^ 8 + 22022629774039619130278840067223760137223751259001110839843750 * α ^ 9 + 9569037722124326061646207068547925124389847238604876953125000 * α ^ 10 + 3487611243366543917723910686246986580789320695836231250000000 * α ^ 11 + 1067491157924455805861448662311325524405538803060341943359375 * α ^ 12 + 273968142184015848925560036581877108638855706237317490234375 * α ^ 13 + 58692019460587884114525551639474562464674600041476138671875 * α ^ 14 + 10411576695976844279717630513220926151802953315673888359375 * α ^ 15 + 1509986509025418223518044667529937663568415780777702125000 * α ^ 16 + 175469918947028739649743022943799878357086029596651812500 * α ^ 17 + 15779760028253605454031412572296146026014740194967383750 * α ^ 18 + 1010913062001619607789595546144718629262771585185507750 * α ^ 19 + 21462061397781700126941815631803690593259676260498115 * α ^ 20 - 45387057094906818237348334721211459766084329446075757 * α ^ 21 + 1689541722499339437202551579490531894232999398986279 * α ^ 22 + 3936001560036108693341101447415785391643174835443 * α ^ 23 + 607977630486171911031424776719828152869889423044 * α ^ 24 + 36336260809521268434231902077696447132341347400 * α ^ 25 + 1235785272488557483704068508469144496017205184 * α ^ 26 + 15739109405711750147519445570667095018389712 * α ^ 27 - 844836507113777181276666926325076953789696 * α ^ 28 - 65867488403154309232905535325099415940608 * α ^ 29 - 2603492828180830946162421054768504476160 * α ^ 30 - 73591830258372192880755514270838320128 * α ^ 31 - 1619902372241517858218483163123738624 * α ^ 32 - 28740854840777906929998653281886208 * α ^ 33 - 417683720829155224442216354095104 * α ^ 34 - 5006133645480122906718714101760 * α ^ 35 - 49524449888141405612129746944 * α ^ 36 - 402720876040696001365082112 * α ^ 37 - 2667361119757440577634304 * α ^ 38 - 14172645073027210739712 * α ^ 39 - 59000480246059499520 * α ^ 40 - 185464776902049792 * α ^ 41 - 414106827882496 * α ^ 42 - 585532178432 * α ^ 43 - 394264576 * α ^ 44) = 842100496490164655863899050953513048577517889022827148437500 * (17 - α) ^ 44 + 142493043979050242816985361996079030928058472425460815429687500 * α ^ 1 * (17 - α) ^ 43 + 11631055935406676773424347895093264920192634352945327758789062500 * α ^ 2 * (17 - α) ^ 42 + 609992449449811389379816851349777566641910911240855026245117187500 * α ^ 3 * (17 - α) ^ 41 + 23098700643661062063264209577856576688439492919078299293518066406250 * α ^ 4 * (17 - α) ^ 40 + 672886788673347303113646845460420332103897531976657897846984863281250 * α ^ 5 * (17 - α) ^ 39 + 15689183510706334336751155501240168225930150393352115080165405273437500 * α ^ 6 * (17 - α) ^ 38 + 300787141414416123262875017253530680535010772323084607526017456054687500 * α ^ 7 * (17 - α) ^ 37 + 4834082125229902229160089626065942580696829879116404068575523803710937500 * α ^ 8 * (17 - α) ^ 36 + 66072765878867110841147420893730369943336026053933255103129270288085937500 * α ^ 9 * (17 - α) ^ 35 + 776562148162541303792514188712949580055222798582046568076665765594238281250 * α ^ 10 * (17 - α) ^ 34 + 7916165993961948987449580340899456664926175109154616993743620562742089843750 * α ^ 11 * (17 - α) ^ 33 + 70468708978108892817571764541075442041839869106980895974143854170172216796875 * α ^ 12 * (17 - α) ^ 32 + 550782470594884966715313206866948703867564604566371289578563249171289130859375 * α ^ 13 * (17 - α) ^ 31 + 3796271005225225067290420328594083801226095054076152502460026076879075960937500 * α ^ 14 * (17 - α) ^ 30 + 23154951045516208632207010063622078794447604241421409800591507255675276447500000 * α ^ 15 * (17 - α) ^ 29 + 125329005241909283645244852767369785798817688336457585844713864177983765701578125 * α ^ 16 * (17 - α) ^ 28 + 603309363715139594521494665743634826511126981458830526026064579534478738308515625 * α ^ 17 * (17 - α) ^ 27 + 2587364175724392722746563574797525717547108337555060272594625213670122377224922500 * α ^ 18 * (17 - α) ^ 26 + 9898549256162510047261715675023148365372355380576229013767998580288842214641264500 * α ^ 19 * (17 - α) ^ 25 + 33813519196392670210313059666995142454669959269244976653953740675056602158569578990 * α ^ 20 * (17 - α) ^ 24 + 103196149479405719489529062495189947552780951823855220313054805583706227764000739366 * α ^ 21 * (17 - α) ^ 23 + 281414632953734490932383578025410664595174480569956516679000280734682217487402570284 * α ^ 22 * (17 - α) ^ 22 + 685395337547723093442698987180372896387216615945658732837662652249972601215820937644 * α ^ 23 * (17 - α) ^ 21 + 1489149662951024487101091584274360794704873551266921796745007333128807261864150039440 * α ^ 24 * (17 - α) ^ 20 + 2880717800764736562237157455028656259513844924473937460829052015392479287411749584000 * α ^ 25 * (17 - α) ^ 19 + 4948638359187857502444997471872385263341628692259466992165339970591851807662058176250 * α ^ 26 * (17 - α) ^ 18 + 7524808365437321671268164297839989387020638669389928036404610340476432390943699968750 * α ^ 27 * (17 - α) ^ 17 + 10090745730787017626963337198418905561056134794018935219523451765642743556242036084375 * α ^ 28 * (17 - α) ^ 16 + 11884304827785561031887161390332218762155951913733146752455369428108543693253527796875 * α ^ 29 * (17 - α) ^ 15 + 12236134768064187298824467090486239622825767135842989738867807258895895376319098437500 * α ^ 30 * (17 - α) ^ 14 + 10956342185947834383371522495075810215688468611001591955872795308997953700512875000000 * α ^ 31 * (17 - α) ^ 13 + 8480200760430773875569783935490297001453280452983110658282869458743468575057900390625 * α ^ 32 * (17 - α) ^ 12 + 5633029575677093237429398107221916268853414367970165464924058295269805975873642578125 * α ^ 33 * (17 - α) ^ 11 + 3183457062375806825326758077695313148081656523121607548560593992595734846529882812500 * α ^ 34 * (17 - α) ^ 10 + 1514534325584221507212883373649465749871038738085239693277104497573823324223632812500 * α ^ 35 * (17 - α) ^ 9 + 598855676703127526215866064910890958440342074461336641457617262869261681970214843750 * α ^ 36 * (17 - α) ^ 8 + 193895710320064143314152952928304080530489756415618625370542369927247228210449218750 * α ^ 37 * (17 - α) ^ 7 + 50633726898981387585795045476023804360885506077389009794334574956167921386718750000 * α ^ 38 * (17 - α) ^ 6 + 10572386406974364669523632230312278886927530949116535421326834315982454833984375000 * α ^ 39 * (17 - α) ^ 5 + 1792713553761047052220517000286370236664409834359847244425465316189674377441406250 * α ^ 40 * (17 - α) ^ 4 + 262340726959871612498380595594270897589647597255618313914727785960884094238281250 * α ^ 41 * (17 - α) ^ 3 + 34914711121164009908327832512530464932432901098435282301515528343963623046875000 * α ^ 42 * (17 - α) ^ 2 + 3721215228917653403021576873516894679349471790204206905261547785186767578125000 * α ^ 43 * (17 - α) ^ 1 + 210713180134643197170850407242377156075926959031893252124925369262695312500000 * α ^ 44 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `46 ≤ n ≤ 47`.** -/ -theorem finite_range {n : ℕ} (h0 : 46 ≤ n) (h1 : n ≤ 47) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (47 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (47 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 45) + 1 / (4 * 45 * (3 + α)) - + (1 - 2 * α / 46) ^ 2 * 47 * 46 * (47 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 45 * (3 + α)) ^ 21)) - = 1 - (842100496490164655863899050953513048577517889022827148437500 + 6202389537263705762292576691419085693567510900497436523437500 * α + 21800976172966131822633999416830068976610560420989990234375000 * α ^ 2 + 48647779340585710046299723714124054163748508466339111328125000 * α ^ 3 + 77335744367973576659808264003823907539197097243080139160156250 * α ^ 4 + 93163317164153721286069997796054376135656931010389709472656250 * α ^ 5 + 88315055516249458646175698818625653153167262528008728027343750 * α ^ 6 + 67525482393603249349320023657815936540710634750331726074218750 * α ^ 7 + 42343249160820224575714518101180101058857691214973571777343750 * α ^ 8 + 22022629774039619130278840067223760137223751259001110839843750 * α ^ 9 + 9569037722124326061646207068547925124389847238604876953125000 * α ^ 10 + 3487611243366543917723910686246986580789320695836231250000000 * α ^ 11 + 1067491157924455805861448662311325524405538803060341943359375 * α ^ 12 + 273968142184015848925560036581877108638855706237317490234375 * α ^ 13 + 58692019460587884114525551639474562464674600041476138671875 * α ^ 14 + 10411576695976844279717630513220926151802953315673888359375 * α ^ 15 + 1509986509025418223518044667529937663568415780777702125000 * α ^ 16 + 175469918947028739649743022943799878357086029596651812500 * α ^ 17 + 15779760028253605454031412572296146026014740194967383750 * α ^ 18 + 1010913062001619607789595546144718629262771585185507750 * α ^ 19 + 21462061397781700126941815631803690593259676260498115 * α ^ 20 - 45387057094906818237348334721211459766084329446075757 * α ^ 21 + 1689541722499339437202551579490531894232999398986279 * α ^ 22 + 3936001560036108693341101447415785391643174835443 * α ^ 23 + 607977630486171911031424776719828152869889423044 * α ^ 24 + 36336260809521268434231902077696447132341347400 * α ^ 25 + 1235785272488557483704068508469144496017205184 * α ^ 26 + 15739109405711750147519445570667095018389712 * α ^ 27 - 844836507113777181276666926325076953789696 * α ^ 28 - 65867488403154309232905535325099415940608 * α ^ 29 - 2603492828180830946162421054768504476160 * α ^ 30 - 73591830258372192880755514270838320128 * α ^ 31 - 1619902372241517858218483163123738624 * α ^ 32 - 28740854840777906929998653281886208 * α ^ 33 - 417683720829155224442216354095104 * α ^ 34 - 5006133645480122906718714101760 * α ^ 35 - 49524449888141405612129746944 * α ^ 36 - 402720876040696001365082112 * α ^ 37 - 2667361119757440577634304 * α ^ 38 - 14172645073027210739712 * α ^ 39 - 59000480246059499520 * α ^ 40 - 185464776902049792 * α ^ 41 - 414106827882496 * α ^ 42 - 585532178432 * α ^ 43 - 394264576 * α ^ 44) / (37032941535730355418797437426924667358398437500000 * (3 + α) ^ 22) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 46) (n₁ := 47) (k := 21) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B46_47 - -end Sendov diff --git a/Sendov/FiniteRange/Degree48_49.lean b/Sendov/FiniteRange/Degree48_49.lean deleted file mode 100644 index 93f4502..0000000 --- a/Sendov/FiniteRange/Degree48_49.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 48 to 49 - -`Sendov.R_le_batch` bounds every `R n α` for `48 ≤ n ≤ 49` by the elementary part and -moment at `n₀ = 48` together with the prefactor at `n₁ = 49`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 46, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B48_49 - -lemma M_lo : M 48 = 47 := by norm_num [M] - -lemma M_hi : M 49 = 48 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 48 α = 1 - 2 * α / 47 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 49 α = 1 - 2 * α / 48 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 48 α = (282 + 41 * α - 2 * α ^ 2) / (94 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 48 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 442720643463713815200 - -def betac : ℤ := 1321115510607014153246618449084850699609261468625978019870644699379350975244444771968614401 - -def tauc : ℤ := 378306710547349654094589574054305238218556185762653904730283246678362710634222243926695579349664359022550511742876932364944600669261863164121029854560513054675225281716929754591508958316596056579952243135504164012984321186167959888582556810441970584552571048422355459718500442851125658657187739281391370968917951523455487937950747979846951282297187019365905860346933235008561389322565136686805523327189240328392529832527517397767646223857147191959693777859241275991272035068305317422940405793131104222001014870858303975931304953958729971956628516376604650161203828826408300942084521583336513042538940078676403461304208347780853157114122174956975911982754169823871402610285807340571235342068680398348033942484867926381569842910954405029138744488679677663833615984538319009926581919920459094501412237000103942258624599495427257136511639183024590307163092959062734567247438898224913740516370773078072064046046826241258414031095456301365270842820098045757913773273680126262726995208431206702338004643899947580280048994734438578107359281425685797021997544387156630680119855320103980667908283541702217637351311137325529127047097311153546840455440804126879287904107419763360419104146525482828641203224884156767185097400137547478563832403755865194233031572605617327490812204319630376212633396166770545349017293167732635352784570708649502723560184468462736106977535327060066760215757115157934910705243816716305230952301873281508306507255701327968353560077038739446259565008852944819625159327345250570593037561197408373581159498977449025315063715912854894177082531797267667636634597127508167383940081868689401302626379424633460768115178185749858318240894885270806806643618752598833199713702485207098008462435113080541689385226361148091570035718278770450902561209687482727373428546654862849608931047346521145968464756327505267109833898097545127700122590995682224808816030281522489909114299426274803919572276643001735649098063725033493493458487111059379738661847637723351793796913755444771388026646106627757141976852489659878425180036225989793489694861746604484521303781036931263128129085850597962053893356189858938862703022936624859270930661917507270878279522326149854955635665970977405841540043768244221850012704634368281023633481063064935661783661514693634995611516790129223263852519034983551438385184486139586299789539039554204055951146057405108286929704086206178053652010445413414323233480774521909018528532578710592749702811641533568620817075524646263902234375161461589895404385966033898863494172369039149090872179423030629960750924211981573634374603275612897806607162443012992212840690754504646574008098927532047057867609551787809834479578080434760283727442331848732225943537123605029612054575569391863109446403273280619971156538347087014452837295356247952210151414908924507141602734059272057304394841080057249734677371565020766266034586169866769503941394843495317985580989492751850884608947182274368326666502399453818075731625616206426850385605773676427748390642683733158569109008497493377529230599254307815685264385823141867061850851327039524807322645242824765360772182628193870700560708716481066214441638574489018580899788959640608224258709487611453288104261275651109222465138149179923220272268403908709704610971195764472766953473995206689627525858437290180459208039348134507369325316766160370109047033206796057451961932664617524167924886616689841934882420842319545871239590321965173300374912282421371998353712404459456122212774496669219907894887344798939329246214727893243986551776698142094414639439065008444426951897554522111448215129802559961641136762454338462842991134565902224127176839953585977122673705663745846717742048309704049963956806041084156977128843086107497477779742270484679550414371881529269752581269298862799919241088041304419061715997526937942539458741857578738072847404122104828507698961058169046939048310090060335973710621659818879856933161726994311784500872630169856180199999413785903428851406222762655211576595572783284739929743176229493366956874063506831229220198550063179091449073984957676888005502853239255839534753045826670800183366261678085015418170080490983063076556756838415455982665223859384146419423967215772827199591841415984574032788297930625908869267751466597311144070929630073146682004223531155843492559703106309294378112246468729146223917395276382853295579831479769022243308616647660307453781155251326881259188245788685150501140274318649866668671994906242657896732493932602489358405381140775179131971839313254252686957659203371784039636768401876186678156586701728850975729064462033827030278888656993879802087091097687613635232257732688323557229193283036461506858427137289759507117441220838899861058992683273334331744547915524867940669055297166045611293379939546148904060896913308196760820819346047667873286319692048530173624927088196030615260121412188449594141135578103370648466955066546491435190294171982851218155785766789185063783310332907747236526895775536370981329549005113006171953362709621445227734035632983606216108930796248876934343159708753693497256134791858704644948296361303736982201632948335969661915193005510289825222115158598628177535405880966289265127591888950753062319629625636277119714693443861822344376526462870551540527865568617620960407986561634737041100126965596084953416995262050409337026359153795814963653116136312426199350885822202295855691302247674697627625911302252033859891930162429487057513242357757062772182876002523495039931105912751372701696963511404902029551201181688518409300169993872949826712645232934668027259008302003393653293585348061931637770701987904420859143761709290240599248467392752962001607421302378663539393608352211114085325288675978544450391246015062417333027611524548076916790758945136762672517137864018395369406732416404101413912812493357917190331103216465974096328918272512386411561045721810307418180301763298962980089935591548046638837290272412228701267299824486363438727026641067600540248973320843176039807768469531936727763465396401939859648147007829132282014165534072407835090208588687630770075650000422264246936139890415006280548059253161141917743133909743839821865274436868691386666482483653489631016556407221515190273 - -/-- The moment numerator at `n₀ = 48`, `k = 22`. -/ -def Nmomc : List ℤ := - [457564124047019970822227354712188405308231791121126212360354807152640, 3734924707090057456043548042999538871631929959192567417073059443507200, 14614198929766478194987175833193291148633965504271697593953829676646400, 36482648189792333044698548642375401552369770871600066230290014242078720, 65240895577907678010051573002009348596495284177235401954843913145548800, 88957833585776903498858996733746977220675103963160328228574813141073920, 96118781201509606123477767434839070395124572038704759051559394030387200, 84438207246021411634744928614486632717520291541555051425585503928320000, 61397028208437085981356712620000948253111145984577536655458640341237760, 37426926514361151114511657099696177039736952893943656801048744008089600, 19303880746493490536932573041590007606992760385258213984138144637779968, 8479680313979187919668661573521060226256855723677603576952885147074560, 3186908028870543455451642809384865897020551360932953867102882333982720, 1027848289220909689826642626565906125485920189252423047691797543256064, 285025708197392969269463275023488308184831306530868788203192833802240, 68041093287939119436687466841933925279811118618785352746400810532864, 13999760555410767220136667491577020896549727175070557859333527306240, 2488503075661704754770306144500937101565705713439326213429400698880, 384296261565538981261663902662901943393276625751743808955389837312, 52304156248661345067194962915842973789597531214655208307954810880, 6550565610759161704065542795290659128943893513493918082268135424, 930689492986868669487255012349161603366410464517152099994173440, 633871092851156961316121729209580774924924445953143556454481920, 32157671800045367693772325888154435065040015211368412371484672, 1554725206173646440367641237649207490985757379657439683543040, 68287019475671763517992417240911314112377920017105720180736, 2639652761753108598251482609846404903035376379876626923520, 88311239102801440489666704004892982763628532035789783040, 2538600026942470096231441001880823968375673337369591808, 62551258884990110667174280307090159778908568897454080, 1320604056618580624797224676169084040426700580847616, 23890849043111223451312002931446238037614474035200, 370221796825348146595036953484433333919573606400, 4908068735713555470797173653054148901766955008, 55521374627175048036178591877550010909327360, 533672734295056638538508000367255058644992, 4331254771247122203560631819775393136640, 29414786601357994525915799953499750400, 165061949682043268546863368908046336, 751866749658214674199369891184640, 2709851569891021375035840397312, 7436522532182913447215759360, 14599515184878050711961600, 18263159250538490494976, 10938381477766758400] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 48) (gg1 48) (gg2 48) 22)) α := by - refine pev_moment_eq_of_packed_bounds 48 22 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 48 α t ^ 22) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 48 * (3 + α)) ^ 22) := - integral_moment_packed 48 22 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-46 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 46 * P α` is a positive combination of `αʲ (17-α)^(46-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 7591199764941595142535047667167496055166615766339109753578898560 + 58444846237165943551279131377341207077328035296269812484322869920 * α + 215183176025506919702531217941842711339737075266956526659211243010 * α ^ 2 + 504119825711981991953619761968878166062817925879996924390857878780 * α ^ 3 + 843499983730922829653379646526224878986727978586395545435732482710 * α ^ 4 + 1072503620634158239884244537293452959863774094675706145687308954160 * α ^ 5 + 1076446847966334979143656931502325139234331446767890824217309988610 * α ^ 6 + 874481274546832703168275213074859855200282043558515881767199205780 * α ^ 7 + 584940481506790593329950294203572360626072792868892731256510254790 * α ^ 8 + 325988305644965786771400276568642744850196724125639486229759912680 * α ^ 9 + 152567991163281517146520289154412206989708725501314740543815123242 * α ^ 10 + 60257769914462931158481100919633683041061465448481123420828204444 * α ^ 11 + 20129798805767351823723652441204102433547938067213802588532446662 * α ^ 12 + 5687016607145482595882099777086733334514360250477330630445824496 * α ^ 13 + 1355278557647407824791108174949033065263401718280146352590299132 * α ^ 14 + 271000424772480840244816322457048834002540366106552011600103312 * α ^ 15 + 45077206161318041189379028469239391861894842436881282720631712 * α ^ 16 + 6155423822307023556988091783956120485240591022903519939638936 * α ^ 17 + 676142880398770802271995740973508628770999664408861891669293 * α ^ 18 + 57725697116366115637265587909635903325806420371494216534326 * α ^ 19 + 3538202264412216996329718883610558594067822140944030875519 * α ^ 20 + 77574873286609722098225332819487251209357565591548524952 * α ^ 21 - 147315204845101536255433762427937191325421411462459722039 * α ^ 22 + 5245361991102819530624768487527000682291303265286717178 * α ^ 23 + 6658544653474755689275786385563045545487294797590331 * α ^ 24 + 1472968109561870214375834133381327743623319061135332 * α ^ 25 + 95171634843015522566439274462655369397323761963548 * α ^ 26 + 3545966415236624759599391868158380053883553245824 * α ^ 27 + 64377156482122958948701739689394929584223299312 * α ^ 28 - 1168656375434360221238828101326004753556536896 * α ^ 29 - 139417680493330544069384288780944967009327424 * α ^ 30 - 6070430434653508552057016796802025839583232 * α ^ 31 - 181826034173641815543270617357206754251776 * α ^ 32 - 4202739957608852026901130257441189900288 * α ^ 33 - 78263006650153541891015915303985934336 * α ^ 34 - 1198002545218365750178026069831352320 * α ^ 35 - 15219010328713364070284371473793024 * α ^ 36 - 160981724807992562843830338977792 * α ^ 37 - 1415946326039159376655312551936 * α ^ 38 - 10298650421826586803585810432 * α ^ 39 - 61314611371788369779294208 * α ^ 40 - 294083659089512872280064 * α ^ 41 - 1109163402380295012352 * α ^ 42 - 3168884055181623296 * α ^ 43 - 6448929882243072 * α ^ 44 - 8332022644736 * α ^ 45 - 5138022400 * α ^ 46 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 46 * (7591199764941595142535047667167496055166615766339109753578898560 + 58444846237165943551279131377341207077328035296269812484322869920 * α + 215183176025506919702531217941842711339737075266956526659211243010 * α ^ 2 + 504119825711981991953619761968878166062817925879996924390857878780 * α ^ 3 + 843499983730922829653379646526224878986727978586395545435732482710 * α ^ 4 + 1072503620634158239884244537293452959863774094675706145687308954160 * α ^ 5 + 1076446847966334979143656931502325139234331446767890824217309988610 * α ^ 6 + 874481274546832703168275213074859855200282043558515881767199205780 * α ^ 7 + 584940481506790593329950294203572360626072792868892731256510254790 * α ^ 8 + 325988305644965786771400276568642744850196724125639486229759912680 * α ^ 9 + 152567991163281517146520289154412206989708725501314740543815123242 * α ^ 10 + 60257769914462931158481100919633683041061465448481123420828204444 * α ^ 11 + 20129798805767351823723652441204102433547938067213802588532446662 * α ^ 12 + 5687016607145482595882099777086733334514360250477330630445824496 * α ^ 13 + 1355278557647407824791108174949033065263401718280146352590299132 * α ^ 14 + 271000424772480840244816322457048834002540366106552011600103312 * α ^ 15 + 45077206161318041189379028469239391861894842436881282720631712 * α ^ 16 + 6155423822307023556988091783956120485240591022903519939638936 * α ^ 17 + 676142880398770802271995740973508628770999664408861891669293 * α ^ 18 + 57725697116366115637265587909635903325806420371494216534326 * α ^ 19 + 3538202264412216996329718883610558594067822140944030875519 * α ^ 20 + 77574873286609722098225332819487251209357565591548524952 * α ^ 21 - 147315204845101536255433762427937191325421411462459722039 * α ^ 22 + 5245361991102819530624768487527000682291303265286717178 * α ^ 23 + 6658544653474755689275786385563045545487294797590331 * α ^ 24 + 1472968109561870214375834133381327743623319061135332 * α ^ 25 + 95171634843015522566439274462655369397323761963548 * α ^ 26 + 3545966415236624759599391868158380053883553245824 * α ^ 27 + 64377156482122958948701739689394929584223299312 * α ^ 28 - 1168656375434360221238828101326004753556536896 * α ^ 29 - 139417680493330544069384288780944967009327424 * α ^ 30 - 6070430434653508552057016796802025839583232 * α ^ 31 - 181826034173641815543270617357206754251776 * α ^ 32 - 4202739957608852026901130257441189900288 * α ^ 33 - 78263006650153541891015915303985934336 * α ^ 34 - 1198002545218365750178026069831352320 * α ^ 35 - 15219010328713364070284371473793024 * α ^ 36 - 160981724807992562843830338977792 * α ^ 37 - 1415946326039159376655312551936 * α ^ 38 - 10298650421826586803585810432 * α ^ 39 - 61314611371788369779294208 * α ^ 40 - 294083659089512872280064 * α ^ 41 - 1109163402380295012352 * α ^ 42 - 3168884055181623296 * α ^ 43 - 6448929882243072 * α ^ 44 - 8332022644736 * α ^ 45 - 5138022400 * α ^ 46) = 7591199764941595142535047667167496055166615766339109753578898560 * (17 - α) ^ 46 + 1342757575219134416928357426104505338852240925288185860898118122400 * α ^ 1 * (17 - α) ^ 45 + 114755136999517997583283831824376925408437409071957821349973204728290 * α ^ 2 * (17 - α) ^ 44 + 6311871144666629761637230662569825452491581180312292712701296505455700 * α ^ 3 * (17 - α) ^ 43 + 251117021819028982864973145165014954053157643806880139740425434345397070 * α ^ 4 * (17 - α) ^ 42 + 7700255582992438800428557545327513666900681197124798184091430231098133960 * α ^ 5 * (17 - α) ^ 41 + 189367631135786370984279829668504339679999112172842699082163134760932823050 * α ^ 6 * (17 - α) ^ 40 + 3837299018002887727841264180140203196909974021427614251792467066036834514460 * α ^ 7 * (17 - α) ^ 39 + 65330193691266612095267419404574125266102388594982857701230218272237672614950 * α ^ 8 * (17 - α) ^ 38 + 948167953912606041527211234549432129570826851527171582246349949742846207580480 * α ^ 9 * (17 - α) ^ 37 + 11862897220186135053544305256945784922859357773863352679820145643098022220785278 * α ^ 10 * (17 - α) ^ 36 + 129072115915064352802998192157149959447544106737793242351888060162304851138395580 * α ^ 11 * (17 - α) ^ 35 + 1229795769892025833353618429128543962117904449244422243628303524212233499528414042 * α ^ 12 * (17 - α) ^ 34 + 10318568580638790387954818617820003753357917586903069070216576765343271409771487800 * α ^ 13 * (17 - α) ^ 33 + 76586524069802882894078032032353528016591779712305320570499363273565575419847624376 * α ^ 14 * (17 - α) ^ 32 + 504684151077635699819713494479495670799591999023571346450099800467157372095419250912 * α ^ 15 * (17 - α) ^ 31 + 2961464831656022935314311202766885642337479869778047028701398651217449033783743537080 * α ^ 16 * (17 - α) ^ 30 + 15511312927367844114034275848806344502776248279233504803062812081346091041874500312424 * α ^ 17 * (17 - α) ^ 29 + 72656111586338879343047119765015961893678349787522472371632798641470861566691804080505 * α ^ 18 * (17 - α) ^ 28 + 304808185012857975724498725531184620292840658826980992018187980322769269404048114731402 * α ^ 19 * (17 - α) ^ 27 + 1146590392326781377506836763538391565844743608196668993927537593446331465448235657881983 * α ^ 20 * (17 - α) ^ 26 + 3870600448216253864751392890281906184377072807016812087208519577192080210828017341041740 * α ^ 21 * (17 - α) ^ 25 + 11731891593652584393540855221982594836705418299405024828972301429357123143028053536434669 * α ^ 22 * (17 - α) ^ 24 + 31934660245093795505928032518461564485995557345717410206365628000458801939061533187363710 * α ^ 23 * (17 - α) ^ 23 + 78047993066241081864729405263799058714155198199791825458167970252230959614239365881878947 * α ^ 24 * (17 - α) ^ 22 + 171134843936218514686150148288359364686859698322647460634859632067734173140627231359730584 * α ^ 25 * (17 - α) ^ 21 + 336206506050303051354999483042669483751718653067431091525204950883403868367567684342080020 * α ^ 26 * (17 - α) ^ 20 + 590632297194451478800263563954322310467842994277133756163742170600614302732421283888959208 * α ^ 27 * (17 - α) ^ 19 + 925516670394461047649865831225821273518368307653384139954083832567847096613665974954102740 * α ^ 28 * (17 - α) ^ 18 + 1289766645595527592343166744587741066182934225995347417854162835114044818241870914092204864 * α ^ 29 * (17 - α) ^ 17 + 1593002416141247767069378716733631264077333099250896896091743214673847829299190958471833770 * α ^ 30 * (17 - α) ^ 16 + 1737143176643046947303118633436476715799207563792300127093284518020249525152200860365809660 * α ^ 31 * (17 - α) ^ 15 + 1665311418235579100523754798782860220365664075295289918982682336006446972368945219112765174 * α ^ 32 * (17 - α) ^ 14 + 1396557360038252731643454796992613166665272986910499262544165249742942020476375868362815880 * α ^ 33 * (17 - α) ^ 13 + 1018684619224015379084223520647127025765305887834183888331474942254858102069742927480803487 * α ^ 34 * (17 - α) ^ 12 + 641932494254295073687856899416231301192107297550335297051507507404266419546500180865404214 * α ^ 35 * (17 - α) ^ 11 + 346616023624199508122240528681160766975802934453336786297349998221685206774349480865493785 * α ^ 36 * (17 - α) ^ 10 + 158769464897392551896561203035439621044410847226907537961532798384360622001611952908266388 * α ^ 37 * (17 - α) ^ 9 + 60938188611726643632686961457984989878294641295998164978961810053640858299331163879730855 * α ^ 38 * (17 - α) ^ 8 + 19303965900462850327232871938264169200849651337482672284417001334177009419208937264542474 * α ^ 39 * (17 - α) ^ 7 + 4956495620088219287305017176528775890173857965129426190480342928881513904895208113754297 * α ^ 40 * (17 - α) ^ 6 + 1011094459778786182680868888323794915088603327243667761590423358931583382786018989420280 * α ^ 41 * (17 - α) ^ 5 + 161129362690984017597830623141137027326076650900522288728417841096952993030031822930852 * α ^ 42 * (17 - α) ^ 4 + 20053630683210270088939005261620316062127222962442862223177250670635839018815183419080 * α ^ 43 * (17 - α) ^ 3 + 2007106897711885365446090180299995728598915866332529016566715378067994766096351142716 * α ^ 44 * (17 - α) ^ 2 + 160682627900417809962527853098762123815034415286611690425666398978372619671902878336 * α ^ 45 * (17 - α) ^ 1 + 7728635588004831865654878836695725660660992895290133611955913220528766346904639440 * α ^ 46 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `48 ≤ n ≤ 49`.** -/ -theorem finite_range {n : ℕ} (h0 : 48 ≤ n) (h1 : n ≤ 49) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (49 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (49 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 47) + 1 / (4 * 47 * (3 + α)) - + (1 - 2 * α / 48) ^ 2 * 49 * 48 * (49 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 47 * (3 + α)) ^ 22)) - = 1 - (7591199764941595142535047667167496055166615766339109753578898560 + 58444846237165943551279131377341207077328035296269812484322869920 * α + 215183176025506919702531217941842711339737075266956526659211243010 * α ^ 2 + 504119825711981991953619761968878166062817925879996924390857878780 * α ^ 3 + 843499983730922829653379646526224878986727978586395545435732482710 * α ^ 4 + 1072503620634158239884244537293452959863774094675706145687308954160 * α ^ 5 + 1076446847966334979143656931502325139234331446767890824217309988610 * α ^ 6 + 874481274546832703168275213074859855200282043558515881767199205780 * α ^ 7 + 584940481506790593329950294203572360626072792868892731256510254790 * α ^ 8 + 325988305644965786771400276568642744850196724125639486229759912680 * α ^ 9 + 152567991163281517146520289154412206989708725501314740543815123242 * α ^ 10 + 60257769914462931158481100919633683041061465448481123420828204444 * α ^ 11 + 20129798805767351823723652441204102433547938067213802588532446662 * α ^ 12 + 5687016607145482595882099777086733334514360250477330630445824496 * α ^ 13 + 1355278557647407824791108174949033065263401718280146352590299132 * α ^ 14 + 271000424772480840244816322457048834002540366106552011600103312 * α ^ 15 + 45077206161318041189379028469239391861894842436881282720631712 * α ^ 16 + 6155423822307023556988091783956120485240591022903519939638936 * α ^ 17 + 676142880398770802271995740973508628770999664408861891669293 * α ^ 18 + 57725697116366115637265587909635903325806420371494216534326 * α ^ 19 + 3538202264412216996329718883610558594067822140944030875519 * α ^ 20 + 77574873286609722098225332819487251209357565591548524952 * α ^ 21 - 147315204845101536255433762427937191325421411462459722039 * α ^ 22 + 5245361991102819530624768487527000682291303265286717178 * α ^ 23 + 6658544653474755689275786385563045545487294797590331 * α ^ 24 + 1472968109561870214375834133381327743623319061135332 * α ^ 25 + 95171634843015522566439274462655369397323761963548 * α ^ 26 + 3545966415236624759599391868158380053883553245824 * α ^ 27 + 64377156482122958948701739689394929584223299312 * α ^ 28 - 1168656375434360221238828101326004753556536896 * α ^ 29 - 139417680493330544069384288780944967009327424 * α ^ 30 - 6070430434653508552057016796802025839583232 * α ^ 31 - 181826034173641815543270617357206754251776 * α ^ 32 - 4202739957608852026901130257441189900288 * α ^ 33 - 78263006650153541891015915303985934336 * α ^ 34 - 1198002545218365750178026069831352320 * α ^ 35 - 15219010328713364070284371473793024 * α ^ 36 - 160981724807992562843830338977792 * α ^ 37 - 1415946326039159376655312551936 * α ^ 38 - 10298650421826586803585810432 * α ^ 39 - 61314611371788369779294208 * α ^ 40 - 294083659089512872280064 * α ^ 41 - 1109163402380295012352 * α ^ 42 - 3168884055181623296 * α ^ 43 - 6448929882243072 * α ^ 44 - 8332022644736 * α ^ 45 - 5138022400 * α ^ 46) / (111104789153591208606089611655419825719034010961907200 * (3 + α) ^ 23) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 48) (n₁ := 49) (k := 22) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B48_49 - -end Sendov diff --git a/Sendov/FiniteRange/Degree5.lean b/Sendov/FiniteRange/Degree5.lean deleted file mode 100644 index cf374a9..0000000 --- a/Sendov/FiniteRange/Degree5.lean +++ /dev/null @@ -1,113 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Moments -import Sendov.FiniteRange.OddBound - -/-! -# The finite-range claim in degree five - -The lowest degree, where the exponent `(n-4)/2` is `0 + 1/2`, so `Sendov.R 5 α` involves -`√Q` itself. - -The informal plan treats this degree separately, on the ground that bound `(O)` — the -tangent line at `q = 1` — is too wasteful here, and proposes instead the chord bound -`Q(t) ≤ 1 - (1-B)t`, the resulting formula for `∫ t³ √(1-(1-B)t) dt` in half-integer powers -of `B`, and the substitution `α = 3r²/(1-r²)` needed to make that rational. - -None of this is necessary. The waste in `(O)` comes entirely from the tangent line being -taken at `q = 1`, whereas the values of `Q` that matter here are small; taking the tangent -at `q = w²` for a smaller rational `w` fixes it. With `w = 1/3`, `Sendov.integral_rpow_le` -gives `√Q ≤ 3Q/2 + 1/6` and hence - - `∫ t in 0..1, t³ √Q dt ≤ (3/2) (1/4 - 2c/5 + A/6) + 1/24`, - -which is already enough. So degree five uses exactly the same machinery as every other -odd degree, with only the parameter `w` changed, and no square roots survive. - -With `M 5 = 4`, `A 5 α = 1 - α/2` and `c 5 α = (12 - α - α²)/(4(3+α))`, the resulting upper -bound for `R 5 α` is `1 - P α / (96 (3+α)²)` with - - `P α = -9α⁴ - 123α³ + 596α² + 30α + 234`, - -which is positive up to `α = 3.912`, while feasibility gives `α ≤ 2` outright (this is the -one degree where `Sendov.alpha_le_half_M` is exactly the bound `A 5 α ≥ 0`). For -orientation: over the feasible range `α ≤ 1.678` the exact maximum of `R 5 α` is about -`0.716`, against `0.737` for this upper bound — whereas `w = 1` would give `1.063`, above -`1`, and would prove nothing. --/ - -namespace Sendov - -open MeasureTheory - -variable {α : ℝ} - -lemma M_five : M 5 = 4 := by norm_num [M] - -lemma A_five (α : ℝ) : A 5 α = 1 - α / 2 := by - rw [A, M] - push_cast - ring - -lemma c_five (α : ℝ) : c 5 α = 1 - α / 4 - α / (2 * (3 + α)) := by - rw [c, M] - push_cast - ring - -lemma c_five' (hα : 0 ≤ α) : c 5 α = (12 - α - α ^ 2) / (4 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c_five] - field_simp - ring - -/-- The odd-degree bound in degree five, with the tangent line taken at `q = 1/9`. -/ -lemma integral_five (hfeas : c 5 α ^ 2 ≤ A 5 α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 5 α t ^ ((((5 : ℕ) : ℝ) - 4) / 2)) - ≤ 3 / 2 * (1 / 4 - 2 * c 5 α / 5 + A 5 α / 6) + 1 / 24 := by - have hk : ((((5 : ℕ) : ℝ) - 4) / 2) = ((0 : ℕ) : ℝ) + 1 / 2 := by norm_num - refine (integral_rpow_le hfeas 0 hk (by norm_num : (0:ℝ) < 1/3)).trans (le_of_eq ?_) - have hfun : (fun t : ℝ => - t ^ 3 * (Q 5 α t ^ 0 * (Q 5 α t / (2 * (1/3)) + (1/3) / 2))) - = fun t : ℝ => (3 / 2 * 1 + 1 / 6) * t ^ 3 + (3 / 2 * (-2 * c 5 α)) * t ^ 4 - + (3 / 2 * A 5 α) * t ^ 5 + 0 * t ^ 6 + 0 * t ^ 7 := by - funext t - simp only [Q] - ring - rw [hfun, integral_poly7] - ring - -/-- The upper bound for `R 5 α` obtained from `Sendov.integral_five`. -/ -lemma R_five_le (hα : 0 ≤ α) (hfeas : c 5 α ^ 2 ≤ A 5 α) : - R 5 α ≤ 1 / 6 + 1 / (4 * (3 + α)) + 1 / 8 + 1 / (16 * (3 + α)) - + 60 * A 5 α ^ 2 / (4 * (3 + α)) - * (3 / 2 * (1 / 4 - 2 * c 5 α / 5 + A 5 α / 6) + 1 / 24) := by - have h := R_le_of_integral_le (n := 5) (by norm_num) hα (integral_five hfeas) - rw [M_five] at h - push_cast at h - exact h.trans (le_of_eq (by ring)) - -/-- **The finite-range claim in degree five.** -/ -theorem finite_range_five (hα : 0 ≤ α) (hfeas : c 5 α ^ 2 ≤ A 5 α) : R 5 α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hle : α ≤ 2 := by - have h := alpha_le_half_M (n := 5) (by norm_num) hfeas - rw [M_five] at h - linarith - have hR := R_five_le hα hfeas - have hid : 1 / 6 + 1 / (4 * (3 + α)) + 1 / 8 + 1 / (16 * (3 + α)) - + 60 * A 5 α ^ 2 / (4 * (3 + α)) - * (3 / 2 * (1 / 4 - 2 * c 5 α / 5 + A 5 α / 6) + 1 / 24) - = 1 - (-9 * α ^ 4 - 123 * α ^ 3 + 596 * α ^ 2 + 30 * α + 234) / (96 * (3 + α) ^ 2) := by - rw [A_five, c_five' hα] - field_simp - ring - rw [hid] at hR - have hP : 0 < -9 * α ^ 4 - 123 * α ^ 3 + 596 * α ^ 2 + 30 * α + 234 := by - nlinarith only [hα, mul_nonneg (pow_nonneg hα 3) (sub_nonneg.2 hle), - mul_nonneg (pow_nonneg hα 2) (sub_nonneg.2 hle), sq_nonneg α] - exact hR.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) - -end Sendov diff --git a/Sendov/FiniteRange/Degree50_51.lean b/Sendov/FiniteRange/Degree50_51.lean deleted file mode 100644 index 9ea0021..0000000 --- a/Sendov/FiniteRange/Degree50_51.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 50 to 51 - -`Sendov.R_le_batch` bounds every `R n α` for `50 ≤ n ≤ 51` by the elementary part and -moment at `n₀ = 50` together with the prefactor at `n₁ = 51`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 48, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B50_51 - -lemma M_lo : M 50 = 49 := by norm_num [M] - -lemma M_hi : M 51 = 50 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 50 α = 1 - 2 * α / 49 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 51 α = 1 - 2 * α / 50 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 50 α = (294 + 43 * α - 2 * α ^ 2) / (98 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 50 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 3099044504245996706400 - -def betac : ℤ := 33981235006444834003773194078594346278954074399321062636764811967835770189517023966542377779201 - -def tauc : ℤ := 1685591979928152828908493097043051672554840728288153124106729985591287222378364648642964526681870497186095228589559494224103176502809006165439518791098891228424768085553271767778057462414147568355653807170039734814735137880745040692205035722008323246635271221640053863138952713146894935268535296144365316866992433551731803757296973270676463211568738244051089348879753349207273352335880574290679079199944809340129738085664985084179707008679372819438677791270683320988761989291569783315424534628630976485156843388343393747690293237429925839510211689519520549729606606598613208753940262555280102215310232544724983782954970651431911244498071944878295202761855711306911014652992209999286068672939651532418082127482015584330078321855972050879730026997598934538413719574969790556993234795614345694436042038867984867274867507259405875052555738389539839855378362035467143709710304453693805045324359978492146066992883229567856046608620110774456906797451592587838152008790518470289087133957413414561439111300760073457410324649943602379907481411517280565716700819835906466954375725416347578900819600293355752122538499829960991300735902936968186689616534051404239531858819471872668355032153332461614936455672983376188157648661408225714803965073820381122957527014978587795670447816632535641484090054471030559504430390091663648466033536864496325012688770292424754739226394267356446361113054148053521921213281742679028997484511471264300443422205855663150085302106966498093029407543430590561000499682424600013679565615044297468739619199167256762095025847468628452356456257940271652702076934679951051526031627827428942625859323049463635732894786877327141814111374198743427249209415022935988159675657659886122981639849308946692463427279053171794427128350855768614585623831587514103723885455545756613735611588177275819140856055262840902675717334517575359826280913018812799512042627105357887407232349560946354642190967687458967112855342578886558812187049530052964449695153265917254762355855496947219864343569504834325405735413600010871202475803891546088496561576613951666733134063237022594227241958495037122038718286756945306721145923620946173302571456152045827526467388536157734650562376824714961696044663042286405664409963468543928735158185754566735184802192665702923499370156252930717837742539812564231289797919437294773054502198375273684101185095364112779211382544410967550582247440330572895646993508736753647319615595007421841528862576593897546069452347855875887308292260122123650082874851282129533157693029176937932517009707988434590898059612534524918673081557302510572231054162695386025424527215849149182117957455699370069705137466965346964462936759413287185193389913898716854055028603990894032748692470290879136501334004641323395653594873618739868686535349023166210311712325478945280830689047482882850108270508113637646424464087948047855364725749356212276860855222925162841446970607089565408602841637979272180986148618882910407374454002982319938433771454740116410475118289241537682160956382863295407138419286212696224971015857654152078056507714708876198644226791271665436743014534924247486888142406369902641241745288877873545218626956137837640464735786324452509957648086456857333349577704938768833910359728975360649003035777864808653060863508101389845908721725898125201242200016521307370392164057710978387373518369279306418660678231674871127256328196305637034822775368369918287102844752900498274470408952013085159953749943456145312709191254056725880547528141232470510853996885515664502661853432989566753476715289351282165720895214494232623241796821169969556734859488473187917322118017057476024719121220234503206894698091533658106348009198812648586576620552503036562770031088406898675850542380979113743968378276035071322275942366644558360909182928908633727975323575995879213478682370577292360458870230219567634514678614166480781019030898172957664052876014255120480724867526176453234442032837935277990645980149530998188788303300256295256425115767955541280192665558813678195056103313459099093983132909942821610204584384043697401211730586579503259533545801842338641459428899315503710665824141227131340738166141566690208773452571470625590476245215088431047076635969261465502494368007678055376625882481912667733130617603683817380087715448185260401251047580599892648625162702058068906176645195875838105045051649681502930955534546185826854538640460818517229052303469886035002324804169419582303546616360777038673256948234153986109614095056489339295595730377939781786943508072511742731219290311399376122412098333247169973075937593024204086063579647005840422742422709172912687920910183330522758332839051746538991302077324327479548437495269739762686396138229631892845601385662675494074769557831878934591294482226694853985399504534232268089173185541288425411967787191007153899715052164561438744114531112589060532554681701357717598936912038649086268447727420688572038492357537728653394428285751663441923796348399308040308070782209353587101893232926999755221731191526462896008251454351894335189767638630137742370806289862962345970497478102611619826503132595620255972319153475926614967118802024465776582534887767313402150397333237996143896578442315115449932299644009557585472128337529766221776209315810467280971333197504881182614542187829432659490616650040815245969987894477380835918862929773057418341020729536598749843002694330782441771528049320627642628282052189144548181154201418905422326735860301800605239659565665671530367545694891495704450254958119200083646367314230515862815304844758393629957466506845474662570139769260609420989970960490987304180423391248163445326396588309286824139904845931225293445555200399529515638754154616441473338999117507035671807610988160125018599291332206549084419398228247026078997741811014429088283940074482734252703634779314592134215778920390626834568740088210010809080231598132059404062668177809394801815137288443276029218801853920007550485952083905811528301335535092496433494442705885088741826018913338574706419238150190522733139785817556957315043447859125039686403244581470131719906782627230927565771101254964955145906357816369289278847253737149440136431786041755599066973547701399306712092983728795844256444790103853827559641524735500266705969678860777946203257231612802853797747022535677436977010640143221319175517905948799107318554351912430705888770075816987818910754492935356097184153277608366723821056950737744232056476140543060950652554230994839836823036110938929459467902823028297629075578937800771427780385827995241988657281264996520544671414669025810823088269529925956094920556855671076330192080510805097094345287902897876699384123590626339288496806501905574214850150429520434525815185958699815346611664095910525304021898792398977963516654263395315095083075479920367894529 - -/-- The moment numerator at `n₀ = 50`, `k = 23`. -/ -def Nmomc : List ℤ := - [1990043103810474308869354328134101900306088761137079698464621757252763648, 16893555630306452730847859757576793985138082295034423351062862400382304256, 68856340505912981086295984350475787100638337917154188403651629573105254400, 179366953828727168837502363482442012928909994575168427696245277659590819840, 335338356588723015051975287589305359662566111976483184503676769328892477440, 479009750366922068421679120985197792581568271289337043463876356963422961664, 543415314747944102155090537077836542038223688106646186960888717110996369408, 502432545111995789135326069668884192779310641721633456894684342506267607040, 385519381713019335335158056879092444912611260333679904580453804162416640000, 248707685285026413906606422312961558904320114260020067547963612082596741120, 136178701697093483844828409048519583931789480350374528086054929743994683392, 63718636382402224133511228658977361075034815677346569514841111405537525760, 25600333991255939634569300433386193329485859451088983072409810347088674816, 8860191747790207461409578491950654049218910600997601608962879820895617024, 2646766592746368503371744819443467756336699499155329557685310166644293632, 683158961585335744394027838582383568482755116621332091026200384279412736, 152438294595499818313911799512634249156198304528265810578484580042407936, 29423844092645756111291993396002416529205475416685106902197040593240064, 4921498213465860144676116101203120621287212525528703050817761313816576, 716902924705346613942086303422402840543927614668437730802387111641088, 92182317399528723523121917775588711373930904727940872224790733127680, 10910290451313760940391680925934276613626784962907005712955378499584, 1472097573396593376045933089494317704013169217746275118755656761344, 1028211017415412488778045973378951762014092395250976701207948558336, 49939531581715405741318983917374504472101144557250686944645480448, 2337079554718058030903902388802085874755264412621374194689507328, 100560152591660842181950316026487697441775995119873242863501312, 3847943340758815853713010300697328786406792095928361362128896, 128518747512561280491966675180970813077980219371696070590464, 3714121210400595592135386883389147854750503042431898877952, 92572804135474706580699094121224218989665240167839956992, 1988487637745098830754769294189322214069733447650246656, 36813306846329095300496855605369909365328854795681792, 587367252521753312741292987229130225284869823397888, 8071119470859777688132437920538942567787721129984, 95352888174027566732346421501785341125856329728, 965602046057029780953644899812074569267675136, 8342700102001256125400595270287653056020480, 61087058088592215178250349339948330516480, 375546553825673830955163216465006428160, 1913513847860841674259525461436530688, 7936273364966532700583991831429120, 26110260089898893694830970404864, 65558773258586043048720859136, 118009467444929236888977408, 135618928954239503826944, 74756024270908817408] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 50) (gg1 50) (gg2 50) 23)) α := by - refine pev_moment_eq_of_packed_bounds 50 23 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 50 α t ^ 23) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 50 * (3 + α)) ^ 23) := - integral_moment_packed 50 23 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-48 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 48 * P α` is a positive combination of `αʲ (17-α)^(48-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 1983296105822518649150892894549250995892425255171116289185883918750 + 15931100140393602368014405057264748941230464487163945499694824056650 * α + 61313644372277040962442376585817692381801159938853766654339532342642 * α ^ 2 + 150465161025803906984244548536621322753695053837703089058231205826774 * α ^ 3 + 264322010781344595257900949490583824621999776392907846339168572698350 * α ^ 4 + 353743281892829023763479373880774443309366799073302434018471557825110 * α ^ 5 + 374746430716099889392649480753262242691492748868863233615818683113210 * α ^ 6 + 322333251095138331750810376734129960862151553108003622673897471115306 * α ^ 7 + 229084605395415458859385031638216501003980492983719572433329563703882 * α ^ 8 + 136186580162004849698169069937707109921050663415979174616099970789410 * α ^ 9 + 68297183570273843739235319574922178848744148149317657527481287867250 * α ^ 10 + 29054555352882187051825924818349071162009825742437693416815288122330 * α ^ 11 + 10517845843096179861634152822549541177919036751909714056461382791068 * α ^ 12 + 3243051149627232957975285323520147924344852995685877267136094949840 * α ^ 13 + 850730079576852202812092212763343774803138893059657454552260134214 * α ^ 14 + 189221714566801413370144763019660859707489277898806302228701929446 * α ^ 15 + 35474208966373153737428171347789581229469589042109433569563529953 * α ^ 16 + 5554556457876028787144312502202971828015473429833975918437514119 * α ^ 17 + 716629519575982953947167029297978855992566816319461607180223069 * α ^ 18 + 74636427766751024769605292454839153620634666149147834232905931 * α ^ 19 + 6065508382815751088971849224267373808540598230608937163606579 * α ^ 20 + 356427540055849162043883615776918801250352493347841025665727 * α ^ 21 + 8010922898128612953822450660739207750975492597821084469545 * α ^ 22 - 13811768035257687091848436534105252716200722593308688700839 * α ^ 23 + 472347189731554483068916734651482362647265909534029610926 * α ^ 24 + 200645576218037265363448556666064462492230746541192244 * α ^ 25 + 100792254939342885252420783865617430196525578985330442 * α ^ 26 + 7091638050698434724340077137596634135844686246524912 * α ^ 27 + 285507048268244527798843379331968858452479422433048 * α ^ 28 + 6365143148445153742308391864889359416478446278784 * α ^ 29 - 16632500105576540446570710610087487983679864544 * α ^ 30 - 8141192900297447634759131458865132803547534592 * α ^ 31 - 400672640084661107358183665488704704596271232 * α ^ 32 - 12769723604511066119766459310752455613515776 * α ^ 33 - 309725769188807086499063690021928273938432 * α ^ 34 - 6036271221838887663385231842606805557248 * α ^ 35 - 96889509859715053751265427510064881664 * α ^ 36 - 1296670055323112890407391552598540288 * α ^ 37 - 14548305968728835978279387666579456 * α ^ 38 - 136967029538617142794633045934080 * α ^ 39 - 1078901766843439405240321966080 * α ^ 40 - 7063554191969670305537064960 * α ^ 41 - 38017498823635237609013248 * α ^ 42 - 165453035363695795896320 * α ^ 43 - 568050178195987103744 * α ^ 44 - 1481574358823469056 * α ^ 45 - 2759526258311168 * α ^ 46 - 3270533709824 * α ^ 47 - 1853882368 * α ^ 48 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 48 * (1983296105822518649150892894549250995892425255171116289185883918750 + 15931100140393602368014405057264748941230464487163945499694824056650 * α + 61313644372277040962442376585817692381801159938853766654339532342642 * α ^ 2 + 150465161025803906984244548536621322753695053837703089058231205826774 * α ^ 3 + 264322010781344595257900949490583824621999776392907846339168572698350 * α ^ 4 + 353743281892829023763479373880774443309366799073302434018471557825110 * α ^ 5 + 374746430716099889392649480753262242691492748868863233615818683113210 * α ^ 6 + 322333251095138331750810376734129960862151553108003622673897471115306 * α ^ 7 + 229084605395415458859385031638216501003980492983719572433329563703882 * α ^ 8 + 136186580162004849698169069937707109921050663415979174616099970789410 * α ^ 9 + 68297183570273843739235319574922178848744148149317657527481287867250 * α ^ 10 + 29054555352882187051825924818349071162009825742437693416815288122330 * α ^ 11 + 10517845843096179861634152822549541177919036751909714056461382791068 * α ^ 12 + 3243051149627232957975285323520147924344852995685877267136094949840 * α ^ 13 + 850730079576852202812092212763343774803138893059657454552260134214 * α ^ 14 + 189221714566801413370144763019660859707489277898806302228701929446 * α ^ 15 + 35474208966373153737428171347789581229469589042109433569563529953 * α ^ 16 + 5554556457876028787144312502202971828015473429833975918437514119 * α ^ 17 + 716629519575982953947167029297978855992566816319461607180223069 * α ^ 18 + 74636427766751024769605292454839153620634666149147834232905931 * α ^ 19 + 6065508382815751088971849224267373808540598230608937163606579 * α ^ 20 + 356427540055849162043883615776918801250352493347841025665727 * α ^ 21 + 8010922898128612953822450660739207750975492597821084469545 * α ^ 22 - 13811768035257687091848436534105252716200722593308688700839 * α ^ 23 + 472347189731554483068916734651482362647265909534029610926 * α ^ 24 + 200645576218037265363448556666064462492230746541192244 * α ^ 25 + 100792254939342885252420783865617430196525578985330442 * α ^ 26 + 7091638050698434724340077137596634135844686246524912 * α ^ 27 + 285507048268244527798843379331968858452479422433048 * α ^ 28 + 6365143148445153742308391864889359416478446278784 * α ^ 29 - 16632500105576540446570710610087487983679864544 * α ^ 30 - 8141192900297447634759131458865132803547534592 * α ^ 31 - 400672640084661107358183665488704704596271232 * α ^ 32 - 12769723604511066119766459310752455613515776 * α ^ 33 - 309725769188807086499063690021928273938432 * α ^ 34 - 6036271221838887663385231842606805557248 * α ^ 35 - 96889509859715053751265427510064881664 * α ^ 36 - 1296670055323112890407391552598540288 * α ^ 37 - 14548305968728835978279387666579456 * α ^ 38 - 136967029538617142794633045934080 * α ^ 39 - 1078901766843439405240321966080 * α ^ 40 - 7063554191969670305537064960 * α ^ 41 - 38017498823635237609013248 * α ^ 42 - 165453035363695795896320 * α ^ 43 - 568050178195987103744 * α ^ 44 - 1481574358823469056 * α ^ 45 - 2759526258311168 * α ^ 46 - 3270533709824 * α ^ 47 - 1853882368 * α ^ 48) = 1983296105822518649150892894549250995892425255171116289185883918750 * (17 - α) ^ 48 + 366026915466172135415487744911864779803754308530000655375734437063050 * α ^ 1 * (17 - α) ^ 47 + 32685750243130354166431563659107402625750332035405750191561966328636888 * α ^ 2 * (17 - α) ^ 46 + 1881407841131145090841016986533759097730516052825808704231530487137780460 * α ^ 3 * (17 - α) ^ 45 + 78459256689743329963134594253570543442212800051291261295613679735466812720 * α ^ 4 * (17 - α) ^ 44 + 2526157710396158722925121199079871034544523911581723097994207618552592660140 * α ^ 5 * (17 - α) ^ 43 + 65348270578398047737901045538231544926735111377759221708810966322205125102460 * α ^ 6 * (17 - α) ^ 42 + 1395586695048529216219720727338181782409903542683661464665137976415266653947720 * α ^ 7 * (17 - α) ^ 41 + 25091358961567861189485447956384974798693774013704426176176831023955755758143760 * α ^ 8 * (17 - α) ^ 40 + 385389290374823447581872955370254873043506388116231648347871930606580590239210420 * α ^ 9 * (17 - α) ^ 39 + 5114292252486869911885110308469289761839173642500394020070108012031543397685206240 * α ^ 10 * (17 - α) ^ 38 + 59161256161938370784774347699829801724975303229316300011306943983966944681307590660 * α ^ 11 * (17 - α) ^ 37 + 600805106310323904417213469470448614536129232455343240574225543436663232620490973050 * α ^ 12 * (17 - α) ^ 36 + 5387148987622905002337912552695991101576356210279594139892815350033519190381631954018 * α ^ 13 * (17 - α) ^ 35 + 42848313014751656392801345211288230271187367670920575900488813020424662766115040908726 * α ^ 14 * (17 - α) ^ 34 + 303464032538826618020021810092246523076423327835808593359248630575577172669418455370662 * α ^ 15 * (17 - α) ^ 33 + 1919675052319908024894686554181462077949811954560704660857906175718223592208137349163213 * α ^ 16 * (17 - α) ^ 32 + 10874148852557470485141277547722227524021509120915887117480057293293644142032687753432339 * α ^ 17 * (17 - α) ^ 31 + 55271679208564823539840128254013152835651570970254641566356451199627461145310938188424982 * α ^ 18 * (17 - α) ^ 30 + 252503463116529357367558410529797790559166244171078469841324516308832648846176593953640464 * α ^ 19 * (17 - α) ^ 29 + 1038141469835606067593166733401008792243365429970694049028451636707468137313444745165939138 * α ^ 20 * (17 - α) ^ 28 + 3845092335628247042344655260236398462168031115874282430712913167859044335883180372818928032 * α ^ 21 * (17 - α) ^ 27 + 12839214422922060993100206502392817799511987618052955635827705879418137857456229303102002808 * α ^ 22 * (17 - α) ^ 26 + 38668985960763181946954732106269364443378192304730607843082220299380873795313006656808498078 * α ^ 23 * (17 - α) ^ 25 + 105069155536109812068244241812619770677190371101318523388390165019705025089023705073017992201 * α ^ 24 * (17 - α) ^ 24 + 257533243404978929099209346342414027031432812223519857139718344355911305954126811366525083697 * α ^ 25 * (17 - α) ^ 23 + 569147019919025772591890628632811032011859407504430878312206909813978377735116474357089719868 * α ^ 26 * (17 - α) ^ 22 + 1133018419963002695257135527792891577568016315310178309850366791483086891940574911149456141128 * α ^ 27 * (17 - α) ^ 21 + 2028823393084462551372573822881776536387839606739316015353770957756761466356425861534814818366 * α ^ 28 * (17 - α) ^ 20 + 3261422523223033546198612538770445764908099658312172165119166143094334561521557450816017566082 * α ^ 29 * (17 - α) ^ 19 + 4695570437669925151575494973682300710306869448714096516816247877812648326270233197019115846774 * α ^ 30 * (17 - α) ^ 18 + 6037682994028240913498413640341842161215563262372408190036046373359050231573990788555033536546 * α ^ 31 * (17 - α) ^ 17 + 6911350888808185279134128140957411320398266037074579187309898159530888623281682213973958805785 * α ^ 32 * (17 - α) ^ 16 + 7017723164655595521056126675946456567629553403101512610091781353726356232791660976553934912931 * α ^ 33 * (17 - α) ^ 15 + 6294935143237609226898430401643730433375800655100783828138379904195915445486580487224848524262 * α ^ 34 * (17 - α) ^ 14 + 4964878406314244868780111039956203509756923777921248038055860417036296541552216059906145098404 * α ^ 35 * (17 - α) ^ 13 + 3424306290318650239602511891398619048414623269656800653759902188565148030596558040360823787326 * α ^ 36 * (17 - α) ^ 12 + 2051958590995686906351648406832466203839543817560131729480349304645431078728413090667388003272 * α ^ 37 * (17 - α) ^ 11 + 1060005738961397201738580950863446006402895600697466546122050769062752312325491830374270906944 * α ^ 38 * (17 - α) ^ 10 + 467577400988976496475501234195271024537914612633016089768118387533173634164273126204352761938 * α ^ 39 * (17 - α) ^ 9 + 174055424381608100029944299500295460088946458918286120062437292805583013054742467588482744291 * α ^ 40 * (17 - α) ^ 8 + 53878846132574605007505800468792220908832004075393485465775528877910318074398454899271776059 * α ^ 41 * (17 - α) ^ 7 + 13614845621699809419890571355526634130837098707003964296944897175809602487667917307467989936 * α ^ 42 * (17 - α) ^ 6 + 2744159397807574020755344104224532395538285866763175087142310240707624213164183747296183828 * α ^ 43 * (17 - α) ^ 5 + 428866537260624574850004860175037680310285291204398039963565670689977450658379659200504216 * α ^ 44 * (17 - α) ^ 4 + 50333756227847631161716151257046024575567930432377627572895340197028609964017169960339112 * α ^ 45 * (17 - α) ^ 3 + 4302447045325735617429810226177479174756160321138468549855980238567434050919754100402688 * α ^ 46 * (17 - α) ^ 2 + 258744146897542242897425801777948395291136619450442877052536998228794692040701916234240 * α ^ 47 * (17 - α) ^ 1 + 9199351670117540067891308093632332055308176052079014496984569179145526721008475136000 * α ^ 48 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `50 ≤ n ≤ 51`.** -/ -theorem finite_range {n : ℕ} (h0 : 50 ≤ n) (h1 : n ≤ 51) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (51 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (51 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 49) + 1 / (4 * 49 * (3 + α)) - + (1 - 2 * α / 50) ^ 2 * 51 * 50 * (51 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 49 * (3 + α)) ^ 23)) - = 1 - (1983296105822518649150892894549250995892425255171116289185883918750 + 15931100140393602368014405057264748941230464487163945499694824056650 * α + 61313644372277040962442376585817692381801159938853766654339532342642 * α ^ 2 + 150465161025803906984244548536621322753695053837703089058231205826774 * α ^ 3 + 264322010781344595257900949490583824621999776392907846339168572698350 * α ^ 4 + 353743281892829023763479373880774443309366799073302434018471557825110 * α ^ 5 + 374746430716099889392649480753262242691492748868863233615818683113210 * α ^ 6 + 322333251095138331750810376734129960862151553108003622673897471115306 * α ^ 7 + 229084605395415458859385031638216501003980492983719572433329563703882 * α ^ 8 + 136186580162004849698169069937707109921050663415979174616099970789410 * α ^ 9 + 68297183570273843739235319574922178848744148149317657527481287867250 * α ^ 10 + 29054555352882187051825924818349071162009825742437693416815288122330 * α ^ 11 + 10517845843096179861634152822549541177919036751909714056461382791068 * α ^ 12 + 3243051149627232957975285323520147924344852995685877267136094949840 * α ^ 13 + 850730079576852202812092212763343774803138893059657454552260134214 * α ^ 14 + 189221714566801413370144763019660859707489277898806302228701929446 * α ^ 15 + 35474208966373153737428171347789581229469589042109433569563529953 * α ^ 16 + 5554556457876028787144312502202971828015473429833975918437514119 * α ^ 17 + 716629519575982953947167029297978855992566816319461607180223069 * α ^ 18 + 74636427766751024769605292454839153620634666149147834232905931 * α ^ 19 + 6065508382815751088971849224267373808540598230608937163606579 * α ^ 20 + 356427540055849162043883615776918801250352493347841025665727 * α ^ 21 + 8010922898128612953822450660739207750975492597821084469545 * α ^ 22 - 13811768035257687091848436534105252716200722593308688700839 * α ^ 23 + 472347189731554483068916734651482362647265909534029610926 * α ^ 24 + 200645576218037265363448556666064462492230746541192244 * α ^ 25 + 100792254939342885252420783865617430196525578985330442 * α ^ 26 + 7091638050698434724340077137596634135844686246524912 * α ^ 27 + 285507048268244527798843379331968858452479422433048 * α ^ 28 + 6365143148445153742308391864889359416478446278784 * α ^ 29 - 16632500105576540446570710610087487983679864544 * α ^ 30 - 8141192900297447634759131458865132803547534592 * α ^ 31 - 400672640084661107358183665488704704596271232 * α ^ 32 - 12769723604511066119766459310752455613515776 * α ^ 33 - 309725769188807086499063690021928273938432 * α ^ 34 - 6036271221838887663385231842606805557248 * α ^ 35 - 96889509859715053751265427510064881664 * α ^ 36 - 1296670055323112890407391552598540288 * α ^ 37 - 14548305968728835978279387666579456 * α ^ 38 - 136967029538617142794633045934080 * α ^ 39 - 1078901766843439405240321966080 * α ^ 40 - 7063554191969670305537064960 * α ^ 41 - 38017498823635237609013248 * α ^ 42 - 165453035363695795896320 * α ^ 43 - 568050178195987103744 * α ^ 44 - 1481574358823469056 * α ^ 45 - 2759526258311168 * α ^ 46 - 3270533709824 * α ^ 47 - 1853882368 * α ^ 48) / (9662005486581138944445785843849787039898391583452760000 * (3 + α) ^ 24) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 50) (n₁ := 51) (k := 23) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B50_51 - -end Sendov diff --git a/Sendov/FiniteRange/Degree52_53.lean b/Sendov/FiniteRange/Degree52_53.lean deleted file mode 100644 index b8c13e9..0000000 --- a/Sendov/FiniteRange/Degree52_53.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 52 to 53 - -`Sendov.R_le_batch` bounds every `R n α` for `52 ≤ n ≤ 53` by the elementary part and -moment at `n₀ = 52` together with the prefactor at `n₁ = 53`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 50, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B52_53 - -lemma M_lo : M 52 = 51 := by norm_num [M] - -lemma M_hi : M 53 = 52 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 52 α = 1 - 2 * α / 51 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 53 α = 1 - 2 * α / 52 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 52 α = (306 + 45 * α - 2 * α ^ 2) / (102 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 52 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 3099044504245996706400 - -def betac : ℤ := 130400366684642060415729771769864343577763270582220283647240586940099429199735588347087604731084801 - -def tauc : ℤ := 1094975297279786085100996379146108965359141711788481924059693871465099403019555911499935316390448429173186770232401422318390639302829405081981388802713131602141440371983184798119795744753538490516291726631005877695528172885996778903517687620330371798273078855698249245482003453096707472844758789889527665161927179386365482158870879522558105220301711827891543520852553858404987663208683930057350928942597487060972473504440590838376930042303949342468214647794041817847660928034827133308695045068403233773132506174605174572922442706497748459012797321274075716989034411260915645321280744442714276085862784352124830173805558393345663909605079224114869301074144569797808172581063136879970141705744003545370749574877442445712292906457145348316360390441225453865046396515185033439097430524979286354270154347156096905450954961193931204706210949623567759329755667163001815012764901071839014804361012773232355105659237958236951551196994035886278657027776482491637796174028270103768709236146438183642042517913287419192816410568716677666659030973910033070641151177011095072502290698483225085378161989671471279961969235162040709850552986014151225312178733994622990807823993182930101671721687979998153247618151947778961907386670948209622074312651723561691872145721678388696654994999846869337248548469574808773759794655586228457636279970291534253831457468455357680981296165140595049812070771080739517138581000456822098771810156567985785780618806155908385440631896460847477886132306271822735630399751611376796612761448249921959043845934417498890204286663633395869218586233679369295932850395635691431503549052081219667629107381103768506166061519353218565391831182123903375016647872273673365254886625254252214656516507831054109495828004323595281073611827936339491406471571151730247103572074826719851612633229684743761200367314455620220326204962300102552053261290565339351122520978167167321555339218556473663573160213702017155033660878043246847264273654198160472522782329504203656677948859084762399126621690592999858881630435371363689535838636032755162281850570324190395421283354145255946266218471628534780605191141070988325159948324214419000355028791783524417117887819938357241923180544817180750475786059649767881523466530664669781541191430062654025954365548387004306807963643809646916939242645983944777613709133542673340223060122646634482292383625536275641620576148614771859938604879808056840369978577209061546724091530119029938973513890220907055737866989957703779087525851977607450815198295435858497539098407723535641652322643508208779169693554619078623177074323631088637782300602903397547203351301366679512769415414843255101994390698354075546996642453277194336393038954722683945491939363949080230261776460553604696011463578485622733152569818776118856832757226180353692688399226373154018655208655149026423748194741197432934841837225757757759935827725369864631255490823448701835243587500984157661504109140818428981434101210430649110510836118941450306946621703411659957933319166767175714366341767774410940992473426397189424736730290669876617019770735173730642821242388078871273718842135776373687643759689580839690719153655347116650219019744279800528370673651143858861383131820349852470972738302730810579750032659901742510651112629924389680970145066864125585973126869947861187690732461133611755280478711691085500481131890742323119893540700758420569920755923845458599789286116003857668903013541986456758126194598058922879856716220321590051475161847614330048685736747615403422072999576387026552723822459123444268196373870025176584505431481761760169932010394198647616332944919653104619960342358980924960556813350471434411422450176820240311686217413513670231769761106394135678556373456536501800228877145310817830350689298915820322639120030417670340779868549726507025648701659408407927139074988615305292710843068212900462529858839533637099431853064697945103219496101518622909048111177157412798967010336647822329494865115617828248978986484642064103425751392855912952151884654876053182883013922384969673128190515011987533187864144781050120970606348861446484583812570926101650970238867251138288136007471066702177636972131300269204783098164682482051445708463738950685675674654239361900278095616782880282518219310953789150754713664861180130208985260922826766723300936978927335179853517048287539483307032909466016624727952745994425797248829368103594172506584106146406673285642954181294577479171985171771307150311346377992236945273178627155284477066966258834531710564928069659208026554217036663500899177602875500789894813804034223517029970430811091399589764482845318336555540508774866999130659719315138215111083160902824633382693497664456112963616243207365056366314553225136747235478548362699010097006841972782937285311214666409745439746249149578420964588715292309685927994645053593865857072941427338521164442600316705272764409209609092348820379796067919679856750739099601192441920508421967679274704078396898804955411067943813526100339705951274578337976142490266363589903501641512277996572144622180131796197720581049947481751960178651113849898928120935869618712430884772070774232207067036835966083484800199621713643086122273477787984935344018140727864437346542894929228588455105586196649522524297362940508880200572642755690178979279871762587935306727723789162093880329945380314258379505936076264143567199748765775094500454940876868946494628281001793074035689884658085489584498324829378127990940327268613864337481161559585669549984078944399066427593072642856268311701841994504170437949250838300508782552101756715871871922796834151500976542243150858827878162516181412332927521999546153780695190480982596070492439088426976058238791192665871287266628111936308594804749535892088263940402357510299020821739630531675139525665169137306163041050932051534643131519719801624073629294365004176866761922429164214289855435336865942588982976884308254769572076065160635533839446183921270275618530839617174216030000668876103566419490809561105861367848590939385203266606827982701901877718732953284812362199679371753771398908349294175099746480902488249585185801631736585577368676643606324247968311117335391342311680920951568802666400887259914467691216893959498530517161702815922904368252570369825436648320792392110811247598250535270649783004547458718802757471971052254460846592724525908134197791134590201760399890351964881510845293727458719315135294700466623886828750062403664391359989420710338245410934146854052972430445353892773148795450422600283448807832706182479532134562751124250536785847886558147123680724725426780238539030929772984415745985470924843562070966748870896070011248383411978092293132328307756351749504572748855830669861641859046637709396573451994578841731861947945973652574917600258584022878572594348311960101735896917623873656357845356768215272983779905274812356108746401236897464012287113292591927326999347938319390750228962188427031609589367069337299286765119932934120456247295736288210194335127859252856948861792035566980396498630328841052567534930638311713076745758998246744377706806114383869703969885330154373572418661943853916972705528885543819549483174267253697667986018916418487623664456020520094618489583890260645846600084925094086861942794683080934811694891643543766688728728822450903805597341518325293855408677888464917551223241897809330012311098929480080556033 - -/-- The moment numerator at `n₀ = 52`, `k = 24`. -/ -def Nmomc : List ℤ := - [1300030959398198507985883016110340656296766196780910159013439479997830004736, 11461098971215156808826733373568510116338449424436459524518983350569104572416, 48586505844658724662773488230843495355974122882507455089755298849581850165248, 131851284745648474200630944083689114216335184010246343578314078035839599771648, 257250214204464305777762877844633173114435328941546199909431929811129021235200, 384211862989308703590904823617086884013485688095513561970711388408830574460928, 456673045962150308704565358480728998639489201836806351538565414254853226496000, 443372725593516537102042659130054660243531597723850013317812772841135775154176, 358105730568357947038515067271686188312550010285238632999369489596006627540992, 243824915070380505174340505426439746559628409235206502878728636181560342609920, 141310238303492704273062936721242427242642779747951911104573592974188812959744, 70204720223961897902988731483429686696923971797160106398986026837338870513664, 30050473389635209600885889374280160905998171033266241125805446052971301306368, 11120653200394757658216568240986654590869682412572368161403084632770180284416, 3565695620296465719443256009803730932899934593966874669535022949555710722048, 991712465732715041831709180047553904320745354610787472228376224773848432640, 239339958802045322829563913263327621582892471460596956874949957461611642880, 50120306119022562093524614103631608435440732551165164730422412807059275776, 9108060256769575752687647886330898463875720148949409914154867287090266112, 1438125818869523132950284350800906701036112805486912075962865065666805760, 198177744571306110927525823805487783161731783697425661030582142432706560, 24138085976405618087092863720014927152006036564075435913671823956377600, 2706111911790883416186804990709202793249764874606919915203999031099392, 347386287414610676348612390522229154578985000328483822121814063054848, 249389476566339435079029752112491647361170120200440203718101749989376, 11602917420373450188471618639936793080099057514620079464584772059136, 525270410085774615958405948133651434997851502940925783609851248640, 22113026516284311002632521246117476078191582182170833925418516480, 836328872476552349405934661535799732405512556536935251110264832, 27838784652524513095946028094979261164742798002285646413037568, 807303917868611217283006574719811979107960397466434678030336, 20310374244793105361105835985671203027830629901466125467648, 442757421627840872908462476602302417383631070172442263552, 8363031691089499300214004091559294721809616289778368512, 136887703782550804325821625122315421341092637801709568, 1941064018952496463359517437337132960203133069295616, 23819076371148407627979067964748941327069488349184, 252406766439055281806055739794067673922328854528, 2301890756962624077301451467168689437703929856, 17976127927603723737403692013425962923327488, 119365859682489978526689071819920565600256, 667489277360258601527353372312659296256, 3102086011049187418157312796983820288, 11764392353520152213474533982601216, 35472516619070159340279831724032, 81800371885591824572570664960, 135496498205711844381818880, 143547803202701506904064, 73064711504598663168] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 52) (gg1 52) (gg2 52) 24)) α := by - refine pev_moment_eq_of_packed_bounds 52 24 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 52 α t ^ 24) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 52 * (3 + α)) ^ 24) := - integral_moment_packed 52 24 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-50 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 50 * P α` is a positive combination of `αʲ (17-α)^(50-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 2158786206398835455807414614345741946541113771140909309351827456752112 + 18060881628885317183903129865386184210636931259177004847461943403431248 * α + 72523751526913871689914498063741871627156282998221168488328768408227884 * α ^ 2 + 186043952493859430608709083701039329302003956855619351393577019518308656 * α ^ 3 + 342352186792731735464993586128215688813987853593111908601035784489017584 * α ^ 4 + 481039143350973516581843203115060631357333955017066302301078896484075192 * α ^ 5 + 536385148360730976146799557733557814318777038771883620685910931111117598 * α ^ 6 + 486973177459613828942749054605832894034828444342062183629433383012760968 * α ^ 7 + 366445983498710745663941283884031432424266298307553290495228389566314580 * α ^ 8 + 231462963120661901399357408339235733527085751003762699569336649733064704 * α ^ 9 + 123822723544233720819377342496077302912265601255690207194574592762760382 * α ^ 10 + 56444234764084989462828858083829787816765813106300946212401546188828432 * α ^ 11 + 22008608122728995449205242852102476325631469834261804695394906754027728 * α ^ 12 + 7353623809616680357566863259021705228111970073628547653529150957921848 * α ^ 13 + 2105293430360560851822138859793778045699608135112104910406227699186678 * α ^ 14 + 515430709094276322360222922253268287610570499499448923895934548603720 * α ^ 15 + 107478868042826110622436885067609215622378470268066806044658545978916 * α ^ 16 + 18965619675038957214919858400770522577747376668487077296700550484152 * α ^ 17 + 2805160201379690314111348362084950864952366379855375613165120590980 * α ^ 18 + 342991269135314358321380120239307230093856195186954782184086092504 * α ^ 19 + 33962560439249200363255807231186470161851488347615308016008248384 * α ^ 20 + 2633515219064481554671199294750396033142024306631342141117342380 * α ^ 21 + 148633574270813874422290547923622884359972747318157801476955959 * α ^ 22 + 3403031020239585108295877062230213266408608085674454931323988 * α ^ 23 - 5379021087810236884979508991939865813601169242801548152141926 * α ^ 24 + 177301236343156026391795710864319371980311028891458462428744 * α ^ 25 - 40911700701069253972939511638042802470451085773720769927 * α ^ 26 + 27847404177739803963243561747514551473461230777429543312 * α ^ 27 + 2163155861798102819189036458258553844449886588504682104 * α ^ 28 + 93357595651430156400551007018380753717170652754834528 * α ^ 29 + 2393234358116242034523747708494764119251642322824544 * α ^ 30 + 15013048286137658650612509829061430420471401902848 * α ^ 31 - 1842593441930339010973203854928850324437642558336 * α ^ 32 - 107353306964614466200187553508809370311222440448 * α ^ 33 - 3666162111111306744447755601199086059560935168 * α ^ 34 - 93356644345705005900818038532098756222427136 * α ^ 35 - 1900483230089570865170384480343133786767360 * α ^ 36 - 31876662776993730438299978705884181495808 * α ^ 37 - 447245036738485694487463467137714307072 * α ^ 38 - 5288819621114196078630291364843487232 * α ^ 39 - 52859730633810963643011459678732288 * α ^ 40 - 446161546901880234704034758393856 * α ^ 41 - 3167349500047341936592130605056 * α ^ 42 - 18770907855391026630248890368 * α ^ 43 - 91797189183100371092373504 * α ^ 44 - 364189492779598108164096 * α ^ 45 - 1143139551315216039936 * α ^ 46 - 2732815988096499712 * α ^ 47 - 4676225293352960 * α ^ 48 - 5102186266624 * α ^ 49 - 2667577344 * α ^ 50 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 50 * (2158786206398835455807414614345741946541113771140909309351827456752112 + 18060881628885317183903129865386184210636931259177004847461943403431248 * α + 72523751526913871689914498063741871627156282998221168488328768408227884 * α ^ 2 + 186043952493859430608709083701039329302003956855619351393577019518308656 * α ^ 3 + 342352186792731735464993586128215688813987853593111908601035784489017584 * α ^ 4 + 481039143350973516581843203115060631357333955017066302301078896484075192 * α ^ 5 + 536385148360730976146799557733557814318777038771883620685910931111117598 * α ^ 6 + 486973177459613828942749054605832894034828444342062183629433383012760968 * α ^ 7 + 366445983498710745663941283884031432424266298307553290495228389566314580 * α ^ 8 + 231462963120661901399357408339235733527085751003762699569336649733064704 * α ^ 9 + 123822723544233720819377342496077302912265601255690207194574592762760382 * α ^ 10 + 56444234764084989462828858083829787816765813106300946212401546188828432 * α ^ 11 + 22008608122728995449205242852102476325631469834261804695394906754027728 * α ^ 12 + 7353623809616680357566863259021705228111970073628547653529150957921848 * α ^ 13 + 2105293430360560851822138859793778045699608135112104910406227699186678 * α ^ 14 + 515430709094276322360222922253268287610570499499448923895934548603720 * α ^ 15 + 107478868042826110622436885067609215622378470268066806044658545978916 * α ^ 16 + 18965619675038957214919858400770522577747376668487077296700550484152 * α ^ 17 + 2805160201379690314111348362084950864952366379855375613165120590980 * α ^ 18 + 342991269135314358321380120239307230093856195186954782184086092504 * α ^ 19 + 33962560439249200363255807231186470161851488347615308016008248384 * α ^ 20 + 2633515219064481554671199294750396033142024306631342141117342380 * α ^ 21 + 148633574270813874422290547923622884359972747318157801476955959 * α ^ 22 + 3403031020239585108295877062230213266408608085674454931323988 * α ^ 23 - 5379021087810236884979508991939865813601169242801548152141926 * α ^ 24 + 177301236343156026391795710864319371980311028891458462428744 * α ^ 25 - 40911700701069253972939511638042802470451085773720769927 * α ^ 26 + 27847404177739803963243561747514551473461230777429543312 * α ^ 27 + 2163155861798102819189036458258553844449886588504682104 * α ^ 28 + 93357595651430156400551007018380753717170652754834528 * α ^ 29 + 2393234358116242034523747708494764119251642322824544 * α ^ 30 + 15013048286137658650612509829061430420471401902848 * α ^ 31 - 1842593441930339010973203854928850324437642558336 * α ^ 32 - 107353306964614466200187553508809370311222440448 * α ^ 33 - 3666162111111306744447755601199086059560935168 * α ^ 34 - 93356644345705005900818038532098756222427136 * α ^ 35 - 1900483230089570865170384480343133786767360 * α ^ 36 - 31876662776993730438299978705884181495808 * α ^ 37 - 447245036738485694487463467137714307072 * α ^ 38 - 5288819621114196078630291364843487232 * α ^ 39 - 52859730633810963643011459678732288 * α ^ 40 - 446161546901880234704034758393856 * α ^ 41 - 3167349500047341936592130605056 * α ^ 42 - 18770907855391026630248890368 * α ^ 43 - 91797189183100371092373504 * α ^ 44 - 364189492779598108164096 * α ^ 45 - 1143139551315216039936 * α ^ 46 - 2732815988096499712 * α ^ 47 - 4676225293352960 * α ^ 48 - 5102186266624 * α ^ 49 - 2667577344 * α ^ 50) = 2158786206398835455807414614345741946541113771140909309351827456752112 * (17 - α) ^ 50 + 414974298010992164916723938428852228907883519963054547874444410695936816 * α ^ 1 * (17 - α) ^ 49 + 38648591690978151565940680020861626232221593895027976635018801559557425260 * α ^ 2 * (17 - α) ^ 48 + 2323468774953773046737498344073410604963916757430810426040495562926126538992 * α ^ 3 * (17 - α) ^ 47 + 101349335991740593349006338670862435683901636675912397673964231014026337776992 * α ^ 4 * (17 - α) ^ 46 + 3418523402240372565025362732012218197017682799224385182741003587603019322270088 * α ^ 5 * (17 - α) ^ 45 + 92795830318460904167075752328056310590909312937624225610579756886634415607753926 * α ^ 6 * (17 - α) ^ 44 + 2083150548513343067461154384073343753088328081203102895466392639042540698472213552 * α ^ 7 * (17 - α) ^ 43 + 39441282325689010460905068005007464787875697034233161641025817719437629586599815832 * α ^ 8 * (17 - α) ^ 42 + 639183212529869482732967509857029817382349276322171871286037804499595169420221724576 * α ^ 9 * (17 - α) ^ 41 + 8967891289317846323424522756456515361904817651455107492105958263498697039942754607804 * α ^ 10 * (17 - α) ^ 40 + 109912662905773911775785651830599814138152716415593519404830837106463824445813386386608 * α ^ 11 * (17 - α) ^ 39 + 1185288664388902189248806437812380279610975615235779015443672285781708714559807760293128 * α ^ 12 * (17 - α) ^ 38 + 11312386017398730692131184641629356719495877419525070049772377844481537989327971120696960 * α ^ 13 * (17 - α) ^ 37 + 96008520633756064409983434244275286680745229190958399353722082141681347511927190938190428 * α ^ 14 * (17 - α) ^ 36 + 727433466208182128845968339617608516747540980223663657764849247640353461478732223298149376 * α ^ 15 * (17 - α) ^ 35 + 4936366709381111751784857730466957485889673194213489796538376360678509233705016565561219568 * α ^ 16 * (17 - α) ^ 34 + 30082088254960095366958957594286135042878514883960848835770199866562115806088375067362801128 * α ^ 17 * (17 - α) ^ 33 + 164985102649690123319061978345185000778850953533122226871900814573805405999712146966652623130 * α ^ 18 * (17 - α) ^ 32 + 815818288201891083392614882901171467483608622704000551448258747708939293642643211380800205624 * α ^ 19 * (17 - α) ^ 31 + 3642346364254930209461654350984048884263119419677776197894819995644826784702649307916488655048 * α ^ 20 * (17 - α) ^ 30 + 14699642422912871844500841018776542189279022499143301125114403207390856393770245321897888096820 * α ^ 21 * (17 - α) ^ 29 + 53673006585933151650707212393612027990337017921471920103972688477444212042080888181402531954623 * α ^ 22 * (17 - α) ^ 28 + 177424630381056553613555892437643150189372774889210179326490713116128958479669098035885345446552 * α ^ 23 * (17 - α) ^ 27 + 531217322618016492802133586903649391958733336005082950612572311095808910788505345175592814369580 * α ^ 24 * (17 - α) ^ 26 + 1440878297786625726057735963735191129687061087876632335989525965863749961422678931848398180994264 * α ^ 25 * (17 - α) ^ 25 + 3540528972380530248060021030700986765668663375909521118259073708483300881659592107503593191364768 * α ^ 26 * (17 - α) ^ 24 + 7878706067439138302871644596778500496033461935373897042861066792548444034343472542257091147209584 * α ^ 27 * (17 - α) ^ 23 + 15866985172027478682631903171788637970460063980973228429209846911200894587882339479475867198952036 * α ^ 28 * (17 - α) ^ 22 + 28888250810289606634245191706663186299318801988344278179610334690859848174281402135692480432780132 * α ^ 29 * (17 - α) ^ 21 + 47477629548102243528458217920917101013725287450823186845340936391317439940465355556234941946032657 * α ^ 30 * (17 - α) ^ 20 + 70302798619149431656063874867631560161982110726463060425195857474073971124206669994193325260431968 * α ^ 31 * (17 - α) ^ 19 + 93578532127885660914680781758934948491041981899416935218375174036595572222667517918310377720198808 * α ^ 32 * (17 - α) ^ 18 + 111671046495563139231753996807194588715349583644959990280095487148731493003528163756917394817921848 * α ^ 33 * (17 - α) ^ 17 + 119108317519314874116452075964414453573552081166001011602192516430347593073861906203222286276783210 * α ^ 34 * (17 - α) ^ 16 + 113156360454221734073606765068373900287501266200716732578873162490509611564763213724059111444879912 * α ^ 35 * (17 - α) ^ 15 + 95376447959581379971158449180838329759355945573810871902930153136280190435130420456031549759592432 * α ^ 36 * (17 - α) ^ 14 + 71000547856694915769126077715715772989720497286001979959236111644677764746629355003121324873743636 * α ^ 37 * (17 - α) ^ 13 + 46435247311237875241086804176274841256465196204557482607524607905695835753570599397044472496443683 * α ^ 38 * (17 - α) ^ 12 + 26514718964077437868313478305791884794282002198254450319170212656068940296217672260748146187929000 * α ^ 39 * (17 - α) ^ 11 + 13119684648080558068145400061379201620208126873006769889319790885496821503611538738560892688675108 * α ^ 40 * (17 - α) ^ 10 + 5574304384447257915334770015429223070725790686644478804358809424096493843062858412483691392992136 * α ^ 41 * (17 - α) ^ 9 + 2010881865895736598424115789062219791810721593821299429086893216589613227274491543685953304227120 * α ^ 42 * (17 - α) ^ 8 + 607237389577241841869363680453643402590101734012060773034199963895826888891782257735573905657616 * α ^ 43 * (17 - α) ^ 7 + 150749895847577632681470277527543538771101449370569486067541118295682832958042871499658490290684 * α ^ 44 * (17 - α) ^ 6 + 30052820272696317463395531462440009839882141116365183097551075391516536642298874821618150390348 * α ^ 45 * (17 - α) ^ 5 + 4663688556843488364172070998639274132596372023847717839521027547698552604606780971945788903755 * α ^ 46 * (17 - α) ^ 4 + 540081530702743610283233889828122230493014768961119305004582751972922686852640193916287106992 * α ^ 47 * (17 - α) ^ 3 + 43983793487190009087693541621146525651052894618594476651626932794533461019682370365887330080 * α ^ 48 * (17 - α) ^ 2 + 2295554691290398410917187961072648259042029375130142853380489371587928525721201467534862000 * α ^ 49 * (17 - α) ^ 1 + 61696825755958662910832536044204740555351244465959101505141229428727029482047853259288100 * α ^ 50 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `52 ≤ n ≤ 53`.** -/ -theorem finite_range {n : ℕ} (h0 : 52 ≤ n) (h1 : n ≤ 53) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (53 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (53 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 51) + 1 / (4 * 51 * (3 + α)) - + (1 - 2 * α / 52) ^ 2 * 53 * 52 * (53 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 51 * (3 + α)) ^ 24)) - = 1 - (2158786206398835455807414614345741946541113771140909309351827456752112 + 18060881628885317183903129865386184210636931259177004847461943403431248 * α + 72523751526913871689914498063741871627156282998221168488328768408227884 * α ^ 2 + 186043952493859430608709083701039329302003956855619351393577019518308656 * α ^ 3 + 342352186792731735464993586128215688813987853593111908601035784489017584 * α ^ 4 + 481039143350973516581843203115060631357333955017066302301078896484075192 * α ^ 5 + 536385148360730976146799557733557814318777038771883620685910931111117598 * α ^ 6 + 486973177459613828942749054605832894034828444342062183629433383012760968 * α ^ 7 + 366445983498710745663941283884031432424266298307553290495228389566314580 * α ^ 8 + 231462963120661901399357408339235733527085751003762699569336649733064704 * α ^ 9 + 123822723544233720819377342496077302912265601255690207194574592762760382 * α ^ 10 + 56444234764084989462828858083829787816765813106300946212401546188828432 * α ^ 11 + 22008608122728995449205242852102476325631469834261804695394906754027728 * α ^ 12 + 7353623809616680357566863259021705228111970073628547653529150957921848 * α ^ 13 + 2105293430360560851822138859793778045699608135112104910406227699186678 * α ^ 14 + 515430709094276322360222922253268287610570499499448923895934548603720 * α ^ 15 + 107478868042826110622436885067609215622378470268066806044658545978916 * α ^ 16 + 18965619675038957214919858400770522577747376668487077296700550484152 * α ^ 17 + 2805160201379690314111348362084950864952366379855375613165120590980 * α ^ 18 + 342991269135314358321380120239307230093856195186954782184086092504 * α ^ 19 + 33962560439249200363255807231186470161851488347615308016008248384 * α ^ 20 + 2633515219064481554671199294750396033142024306631342141117342380 * α ^ 21 + 148633574270813874422290547923622884359972747318157801476955959 * α ^ 22 + 3403031020239585108295877062230213266408608085674454931323988 * α ^ 23 - 5379021087810236884979508991939865813601169242801548152141926 * α ^ 24 + 177301236343156026391795710864319371980311028891458462428744 * α ^ 25 - 40911700701069253972939511638042802470451085773720769927 * α ^ 26 + 27847404177739803963243561747514551473461230777429543312 * α ^ 27 + 2163155861798102819189036458258553844449886588504682104 * α ^ 28 + 93357595651430156400551007018380753717170652754834528 * α ^ 29 + 2393234358116242034523747708494764119251642322824544 * α ^ 30 + 15013048286137658650612509829061430420471401902848 * α ^ 31 - 1842593441930339010973203854928850324437642558336 * α ^ 32 - 107353306964614466200187553508809370311222440448 * α ^ 33 - 3666162111111306744447755601199086059560935168 * α ^ 34 - 93356644345705005900818038532098756222427136 * α ^ 35 - 1900483230089570865170384480343133786767360 * α ^ 36 - 31876662776993730438299978705884181495808 * α ^ 37 - 447245036738485694487463467137714307072 * α ^ 38 - 5288819621114196078630291364843487232 * α ^ 39 - 52859730633810963643011459678732288 * α ^ 40 - 446161546901880234704034758393856 * α ^ 41 - 3167349500047341936592130605056 * α ^ 42 - 18770907855391026630248890368 * α ^ 43 - 91797189183100371092373504 * α ^ 44 - 364189492779598108164096 * α ^ 45 - 1143139551315216039936 * α ^ 46 - 2732815988096499712 * α ^ 47 - 4676225293352960 * α ^ 48 - 5102186266624 * α ^ 49 - 2667577344 * α ^ 50) / (3501052148609730436138801945234855464676764937608356932800 * (3 + α) ^ 25) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 52) (n₁ := 53) (k := 24) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B52_53 - -end Sendov diff --git a/Sendov/FiniteRange/Degree53Packed.lean b/Sendov/FiniteRange/Degree53Packed.lean deleted file mode 100644 index 58c7206..0000000 --- a/Sendov/FiniteRange/Degree53Packed.lean +++ /dev/null @@ -1,64 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.PackBridge - -/-! -# Degree fifty-three: the moment, without ever computing the row - -The numerically worst degree, and the first where the bounds are discharged by the general -lemmas rather than by `decide`. Nothing here computes `qrow`: the coefficient bound comes -from `Sendov.l1row_qrow`, the entry-length bound from `Sendov.qrow_entry_length_le`, the row -length from `Sendov.qrow_length`, and the packed magnitude from `Sendov.abs_pevZ_le`. The -only computation the kernel performs is one integer exponentiation and forty-nine digit -extractions. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 1000000 - -namespace Sendov - -/-- `lcm (4 .. 52)`. -/ -def L53 : ℤ := 3099044504245996706400 - -/-- Kronecker base for the coefficient polynomials in `α`; exceeds twice every coefficient -of the moment numerator, which `Sendov.wsum_bound` bounds by `L * 1544 ^ 24`. -/ -def beta53 : ℤ := 208830011639048571679172119093843847246029862674636395003776181764817937746163202350283645308108801 - -/-- Kronecker base for the row; exceeds twice every α-packed entry, which -`Sendov.rowZ_bound` bounds by `1544 ^ 24 * beta53 ^ 73`. -/ -def tau53 : ℤ := 1490897291309555529734217006693793886139103539872139364375427447071994920273053890442982671255258740599082774111120348509373209740620217352799676564362271261935740878076768321976613874506187607008056539567762137101217801736439331043379179331677863289955923031332335806602227502781527983902343833876364616736733329174734321033594095426757963210906011808012355724096665157632084600833194772692700482661608066159302680066567127031716927162946283410101803862941386289892116132727855984582494678817770788199749689971453185945687800044414471216266200904761435600855145758816477699151794711499276661973996617589509423181031759001662289404350129466493198464589593232641142316083383853357023113094653277764470002265368049902211135774558867673021807312400777094224254605317220812634892229703389990220517824345212128347263129416047489570041800766568242220299157989492329464495952234138109742948164156251608848569402667807728979010821284477821670158031363379165270442911068323013447164528770661828963573804396031599621659854741226591122775986673769194948737668020734742436888573993527013430648819392008275514796604224658251914006382663579796572600696453644978764971061826684060211498681819969582228015957708101755705289869743967644670049172033571021672636257328044431772695143394032834501888280350174480194911442682112725222919077879138223305154980865486105386040029016026217633404797820558063776491695667718011060112831007023732021950985787712730288214585796800863448537167782205082745121091757072087549271178665270290715834865947458423202086594866053031679605559215751387197690566787606786438886218715932069644434820140331082876957451566955737137050550491560015768081380526984264703955417909417886210449516510700909140454693420206573227816638204361902603878411213595228264101074067617543501093401517469850629115837536217184227924555268062190027048452409981345533249796764264082677521475372688581048339153913282983586808784760204759548475872137224200119511115012486138201651123273663263119755085094549054782992035340326359068939477726002367351448520499515107484773477824548094331573783785453474107021144987082337020967628179199702784236655561670189288715638318112211762659979175418708635582824685904643086146672229764451368962948648900407135331624154022394754584737267872833146461821603991754133048380300348654750052828621033985435274106746779779551413133378794085658513826005337857783046519732840707021408331549757960104457580607752117571580416533455138469178926903385141738516012201211677326334407609209655373010556396372562528446148761464797237050009261823912223376186794297999850606876591137473767366528759915601672907081628100480665536976947360065931840296040322928340561579664862424040203396552687025790445712305087201349131022335349678258339799578223549060580632874228637422828265439522274469727343934416446643903288057673429916225392401805717247691456188234535549283850250691203185628091354731511171396394879292358058043242397362448211973171937011165531615281849665079323534507502686456308734689281806843477456157568248880128715321999254402889125159743970163853005169872431215344113274073104843399616652000225164088299504046397224750187403774759483618562188934396806495973927149537620075028574958474910725819537513138815773545811523279803468241651238084619964409662186285901636416764774151874544477639302853496028508340568801946348679461858427071466315349029047817875048434352112253816147482764178905903610349901215148341505111552146359424462759144385233576599019288462342186922551204569582059861459285638268005722243592825765906217894475460418062646403589439358020451591769409966993548482494291126619839998025622192148629784312233026553325601628634351226154684879948887541116224715682105685707420787945844779507391227154823500273662329099594607608003666570565091515202795138636115880943368641882017367536695236140097193463018246296958306412430606733894494893316386319864997693239072850775880470661812462507545764752096611797756083207427525464218809182850426207508464253554448236749913051808098865873724501405606095148779683538766500549952377961426288170974779802439071175124277131930793462195992834687642526423303574754010009130740128527949037179204294925088515097036574058228954567440600014035764339549241922442875569142486621066892605253842342975072492769021316004658929577620441994765605505257951828378018741361385752050067784377343643507630293191523336393514308389751206667310739179368673900551816962788084492215811468426789206001224129125950155009995198841202802758830309717212000127210017307016232987850970196240211405375270795499148120331356347442245578856045536215400598429333838175396374250189533631840244251602329413309301955821640977333558566059142716094209785588993768543240392206875677159393440637759219382304686351819914447163815929097238248242681623325375667725781140659511595047758891420603278855108698214547367102734703122197385340234501070752167039500402941430291608490844352896152246703618022787183312693015722414592423575791118388899848735741072163435057504856568709717849324972819247128459474159041884179818320424932708920495222693289061635691430818323106908878278676507340713388810346099802549436316478044052207881731484047176041639616181188997210053978817899955496923774603971416078064612639382485852956380708432139449279655351257076035653241583763733479275232652687068943714767558461379692307391514186667443055994394616922010381231176069445828801009247599015440600800320051043407845554663550574317214067776385209548971367273382345806805583584875952562549818639177250616500624292895618065077069431719896409218261223251800191979336834065584537650173480201999879772495816757123304492480573827208910670662205709151487938614731191121025223043044972397806391530726434944456633224752878694227647443557939864824668560321390849994478973497647617617626120476064881749256145137024082767405927296841480391865774291843776103616144869657647953698572313987834222348642789224996325348555483576312997444933440799474508081473185038513044908419872490360816728219878589768464916705275273624715209306778902221141592542689051694045003732693173426826669793920627109770929767587131264926723065857409192098043594253524388216754049658193294540435697590787396953773898482288302408259325123268481777235371951737757859935753505512393572442082348675992207034494655050536927419001957707599281015522140399457268918796559579360084251948709476797870685495663853359224630802373623509014943320727317040254862717837658315224292630283731839402524814545159547459166690414305905076806459564340443888189187562041845284915180202339426168053908998976788244200350037023103458842093095635109989963226973772341678506651142952609566463926353766273494136493554618215726674151217263701658204752969414342319722635839128635002776287724088649638496385383650227550702823893477173355922174463076976808898568799277489857111464646817542234659913818336443222596489444207643576487942934365769233398004681365997938341669861721362774163454176995150017598770533832792058092475137029079181239534136759553342011249983812205278940312835594425474919519044947885045969467753760309635131838958228101783040259473165393143906703207436774168731455678713354130914810622597434846414892494428686287871694625634350264389875737258632619931578752576763362728263438394930062954147400767598401630853155040264193 - -/-- The moment numerator, supplied by the generator and verified below. -/ -def Nmom53 : List ℤ := - [2071809002061381320061244209804912700472595038998644845526852056645816549376, 18261984749757631199252330986261851882998209517240100801515192951023708667904, 77402255788886867164615437599673844798151201712078251850687162909746194808832, 210004015216683417069867539291904367589854553902195794655555918897042792906752, 409629757053808970871351171928664809415295231414411050635731161121568038322176, 611623399411803707837979166710762847766882401248531205065054141780400992681984, 726739300512901125775072932867153695390540054402841421697663834770573482786816, 705311998825653409741271837169468918416987474576715288904219463749680324673536, 569426405626690900321470942445334671004289737305253056080914576744022760488960, 387514835095284730341812993701457542004491634051428611735733258342788155572224, 224455999195484958319453645396530821323619315409064088690420021125225012789248, 111436225330324885975713001173995753705353701292211800264357850108841072525312, 47660476078008051554285157186040288869146597101605833682215711491177970663424, 17620365336972814610514401637067156087061317673334493481436598155927619633152, 5643112077399180246143173799599589777587978184798073772295181898696806629376, 1567248470736364733878245689193122238864522359556207357782228991946983997440, 377572416951011516278214756099768605035958047217176005524206500700147941376, 78893901487176163076847046003952233438023739872592362857189248836940333056, 14297311486695295879757309153510435998365388403568293854040464151147446272, 2249598598723500249538235927794436295410696423711962213815756296791523328, 308632144292243267866515178061564869492091863201789963327164804155572224, 37386561645942682362655203018117351963151791199846808562449603566239744, 4166460813690553043303720766478695657888892663745484373472447393955840, 534744913935177478817235309303875092210554908236337032344891058814976, 394249015554704551981613463626799250550039979425635711454261595340800, 17914649394866513736351273903470932348135009242436143896155303968768, 793142609039807217933535749436040515766796688784916796278036234240, 32701715560853320088013203029162259710001605665657178337153384448, 1212626718217712658946060570924571358981163889852812175836446720, 39602565638985174618985915990804060345118533900301211361345536, 1127190289395753835398933218092278817190260190753348929978368, 27838652400117040434586519147171428782103011178634694098944, 595803147883264054222492629593763571797853729396082343936, 11048884321650786325960904486505862427041896543295635456, 177555617520965674484947363992870447809149970952486912, 2471814290578290137989250736829854926620918963765248, 29777926250374482696486165382608501816235218960384, 309777951416436376443419761414506713621018443776, 2773323818421401364232658268422084245327970304, 21260099751720408033950531127256402674843648, 138576716388035847716068081109119417712640, 760648544793960397050645108420010573824, 3469866248521503712387495394487042048, 12916296069383031768378415358410752, 38226220372020292896354528657408, 86520207069207138575679750144, 140661747098269859708928000, 146259315829649946181632, 73064711504598663168] - -/-- The generator's numerator agrees with the moment numerator as a polynomial. -/ -theorem pev_Nmom53 (α : ℝ) : - pev Nmom53 α = pev (wsum L53 0 (qrow (gg0 53) (gg1 53) (gg2 53) 24)) α := by - refine pev_wsum_eq_of_packed (gg0 53) (gg1 53) (gg2 53) 24 73 L53 beta53 tau53 Nmom53 - (by decide) (by decide) ?_ ?_ ?_ ?_ ?_ ?_ α - -- Bound the packed row structurally, without expanding qrow. - · refine rowZ_bound (gg0 53) (gg1 53) (gg2 53) 24 3 beta53 tau53 (by decide) - (by decide) (by decide) (by decide) ?_ - norm_num [gg0, gg1, gg2, l1, beta53, tau53] - · decide -- Every supplied numerator coefficient fits in β. - · refine wsum_bound (gg0 53) (gg1 53) (gg2 53) 24 L53 beta53 (by decide) ?_ - norm_num [gg0, gg1, gg2, l1, L53, beta53] - · decide -- The supplied list satisfies the promised length bound. - · exact wsum_length_le L53 _ 0 - (qrow_entry_length_le (gg0 53) (gg1 53) (gg2 53) 3 (by decide) (by decide) (by decide) 24) - · rfl -- The remaining check is the exact packed integer equality. - -/-- The degree-53 moment. -/ -theorem integral_fiftythree (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 53 α t ^ 24) - = pev Nmom53 α / ((L53 : ℝ) * (2 * M 53 * (3 + α)) ^ 24) := - integral_moment_packed 53 24 (by norm_num) α hα L53 (by decide) Nmom53 - (by decide) (pev_Nmom53 α) - -end Sendov diff --git a/Sendov/FiniteRange/Degree54_55.lean b/Sendov/FiniteRange/Degree54_55.lean deleted file mode 100644 index 21d4509..0000000 --- a/Sendov/FiniteRange/Degree54_55.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 54 to 55 - -`Sendov.R_le_batch` bounds every `R n α` for `54 ≤ n ≤ 55` by the elementary part and -moment at `n₀ = 54` together with the prefactor at `n₁ = 55`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 52, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B54_55 - -lemma M_lo : M 54 = 53 := by norm_num [M] - -lemma M_hi : M 55 = 54 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 54 α = 1 - 2 * α / 53 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 55 α = 1 - 2 * α / 54 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 54 α = (318 + 47 * α - 2 * α ^ 2) / (106 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 54 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 164249358725037825439200 - -def betac : ℤ := 27647246130875274093918016051770909056602774105259065139354359395831971189538781052985361357499636121601 - -def tauc : ℤ := 6190004864449445543989139999745399752066718764343716864212357408893649895222491013856759743746337738262650933973020472101548391745841694444275043114605399196423510697807106558779320399577692152254276198415808806479997887590011665720809262909012885087181687614023006031924508954049383302375313480915608244217293288733115997343206386292022520677847337748257446830566443353940065578376879125244401191575922873802904881690386705538095656402280256208639469882401660815870341497753705686701348435519546436854571074178398891178757484310704760487604792863718900927947379391406083068379606265086825688013161078739209601498589304597474971426701867755342153666621482338613425062710985549460218627728857205235639681272799169725504662484963965108527026249196632678194853532410597026324089471201981743072144282669198252791008593885185618510046347738195389008286758028649010910791649919532463130378727963270307456768640767826395578232443955205644697246900315440530013536070780858889559378765568024137132659608801251487968602691234137302937063048577695878373261277489973545420548017515390162484371171099747923038495754250791790651385408346320721506088774087329880837301724513846456199472957593696968408822018259791659978163399481151250073769243062796244601709245448237300090419129048384889226167569013966602336411510711035046020432203875916010540619722084205551459967133948011302274394315287519877693154753467408821050808475260662309520882766003029060916434238874266983600437770129622500835267248266052199349158412226558989198530773862488059085858337391757750577332350548250320150575342470998998132878512613280726922521318854133000729677449698888610844467041058793733303978010508757391763594795551677581460926740716018603576693135706783516252593482848194136157414213855916408970846045323352974397740471464002861218053776050990741546309144702956959477441823169088115096767569774354573451174171877064746012498690454001530809031513495384863651771991690239326864894870954786559362658259109581735107883807737113699475957437458752173438916510228713496926302285167455149127606195168180735545498405228622086566876291505864475734891799687406497888826768392371871530048456940182578755975306078580654562923182743261386925289975685181060880087960119746186660188454696304858930122600939740483006657937147866428099140981030780367179110990840996489794379794180464484350391131286990301709727617439613431598192900003091680136698328554234570878062305164529056502413148200007364952709667801064657086638654006830261653541262838064023654321420425597080393014478031413037770511349080757075658344100128864242968114781149889879363013462463661361700956680066750474068273258530082756070494744873516781726448916280462254510815239808848472763422651667527703196300259350105304833353986972035452442218429360920945174930861398005873953001794433103252868645626016736801162426513411049957157384963639101561800710575258344680315654791014787648295914581637432475677775362318425806135507475915598688052900558726633353881343150479603061094844794566506921414811902763837914931931398896122603442503451042692230059110492132438508861503747250868467202353489534646104453070447790928455119672182224661160531926627663091896470784761069007571659406652045697493063175917078948833199012463942247002019708606074225475530970723099765242443992756809790047284089507712356884714954058703116900188695856208536120310243199762112795322647512141717429826969024667475210147389148009031346591760721435755934765223826737894026187880658561995255818704749682077166785067124419730360743400198372003115821689120849258885559742917496710210751029114359600385848270602094124006923387587644569838302342653115683320393340952942533728307898539689142776318482611977811587585707350558843996864434284171760290180678827343530699333480107027464055263588973101037998064921056223384171643700873082087307415981674674813766280101406177383199982445847933295320263421886626489840850274302550100435115329165301107871583874840924594758447268339055773490253256850322701535987562291239624907262980975728273948830670280098284866347361553697977373978527753142178132189380820100938165970195239545044148382036373746528933278248191368167110496377081535402852457710233220138360208106116257207735969452007288327269258793031235130755513799358118466062607030676315131513774634137569398586171850088429116326046564498549457761083333034363557009556098911042374938186999369686867667178265874245936162755878280539822644757919077526221714717265333310467542508636273142297108111496047714512250509983196526911052042623684851158528139182473311134954354781422918599127692791910118179210009269000153845806476839769854223634714478075360638478258895863019028524383650360797046334253356406110449973727380641361529311517604792389740531964624748923115012736116327435314402772515947126414777339307426185741551244860540985518668922914311108832035237808138790705518821887254676279486356368469874691770885732948196227829726829600539763849443229847687126230368650741763303977850718101426158080177681662191565217240011410541974101813434127737258006023855260985034915203868428593043809370458140209762697595888975428520915329962740883034039081350155128599802831921073491548306890360171435839076519406335977698852728897863424137648729399220175160659708304855295420548537037880545359222101091132968135243948432887462800277613659951344521537730880497265020151920051884768003266583787865180877844938134832975897364415436540057748816519056745490682833470461881771566278161719723878829406555295737208357631107235539548735750824092008316815650103839832236820746864488544890454527740972331367454710455296840000518012458542024443172838675752756616357458006514193756760689161437628382558591936376003478094167680213426418981564736588848471477395099313186918741774277841678760400766143347779979240776355005218457325581502854615844301470812968708045986914703520668365886070340366336612784540711806993842641153543320598374489167457400863860536599974215014938152473950143921278697596060801333572316370284370378476256330988585588674079245655666971001054803070959268165430646231845739690074779355669978288624637155091223133850297886596076799202107126783574659757384499862615833993910303999989370699933632547406667613516949469833962958425172039174015142411886648617956878384828155948217297678760194549434644588327335023510939570558945922267847318265126848420184231965890353796395647821679385208126880835589716937756640480178485445600201725524115152348792024904428053629422587915971258498688213149274293585415087621781181947514858291886501956555990208239443482091414551682082466386814739805227941493741470942929074427228178591090556886036208761168969885834050601909380312388174351388574459984894517460714758586904741619863872885277249309640664305272986178803751766191722547425369175403722091171892096770133053437662002712944577766927376871814429003243085473971716803022023854789458955325017608731568437940096620219523531211006763106482935992184495690957159213573502719483132233389083407139467087714718616040832693344447001236271051547319855422143786072504916198023246762482596833178683394906391522071263416938555019058886593632750804177034367905265703671938373760567902864533417579828594545493766769315913219568024757995489531800035231552963073696763423131892155737200046800493461609223706032093919310675621432124964030096669532141158531425321210493234137588776874218104725170571674943756440341059030125225662395686742056394892945791807261151705183193650731906580403439466071270416363914143995507211949972901775033886493816372378469282208440302189336210706320336968024108812891208401415593715376502743582229315063128155139046673406623241186483603990809292204041445668125048219761729385553862524540286520586872860903458279844132731792611289491762311344339440980021292461842736840760862070603054772187028907358183955556506445231129439382821465435741534155264479870655303426535646913363044884710316621365766670186382845523785142111066845487894817533023606437921373510564771359484213330650278658049 - -/-- The moment numerator at `n₀ = 54`, `k = 25`. -/ -def Nmomc : List ℤ := - [47216064286736971239763224212710479928976564648729245329540618229602201265766400, 431720032292938213349635836637255353446348804502827011877869980852544219172044800, 1900815588546424023703752507960914539132448538119713371192029486296978477075660800, 5365521537182416522114293886003923399743827305359392279373109335288020240800153600, 10906686015840381101690759606630378592378767800888257325733870756053329847831756800, 17001236936197173287602189144510364643446044582506256244706347022719568011958681600, 21130717706482955452095093576026263417210337986468192121234646800069069142333849600, 21496789111861971344867062532556279345558792775561097007827078654907158734936473600, 18234174108585928606878673430940468041899036311297090831177976358057535196259942400, 13070239184391811876536770816264532946835738996817762700949135547433947355938816000, 7995847503488125804013431285388900892442854609638430559177370384774199646145740800, 4205327285953484197066287520738214374377970018239909489080883865630666688928153600, 1911584498811526626358948616856209938380252053983531412062319005264622739102105600, 753804774463391715492888339019024534633238857571731115334588349160973309837312000, 258489891761074576281015783991647415782483509993981789469587403753334893025689600, 77183855271426628048509620236967240319626104682737375727109940837179960852480000, 20077300059689936108299831216855511280044885988654602608427125917442261175500800, 4548780378740603017774143601029330555898144394195744960295969531707489098137600, 897151749391402537128828959992088680186216844444514181541987837033664479232000, 153982998790714166215265590440858829080046349470443078666841509135190799155200, 23018250441638021790162386213399933704694433760837239464419664149808047718400, 3008636899530983093080025871505924280431169939940212299883005641639749222400, 347958025325176589761943191229300535852659518882550852066728864567944806400, 37030585591464732377158391856939140467341526681442810096151428677081497600, 4530365389620290795692328613666464889009656646914720098503481289500262400, 3349272754293667615749785027273262995754133095409040474745864609752678400, 149368771348369881660250466737426651082380168326431323865167589434982400, 6538116109295484400203225709234302620320046478067354733781015802675200, 268984648566692647807663562066487288726024765035811696144814178304000, 10040657320603332054753518371591953691998450561050677572091772928000, 332579253111600734915804084817860584862713961462628860846250393600, 9661461557129669613126965232358991009541438235108717748237107200, 244877968461413049747902102202462013358886332884688908478054400, 5405670258851122621695467989393898915374157702810515066060800, 103904901445057546847868606332664709927666706000941940736000, 1739349206145333786681215515484430271115965760253041049600, 25356672697289235904473177187966327573800282320220979200, 321731127153608277359179142431692770933078317491814400, 3547876065211157693347560327804763784564708265164800, 33918880763622328792209926566666133311354778419200, 280077601857562659116729323119537705741765836800, 1986828966932676948586850380910581993648947200, 12020073648262300189017077591363969404108800, 61406359763615804386068614709721536921600, 261362791078280706221159612263327334400, 909849119681047104296629402651852800, 2523544137830712626709059652812800, 5363284366102718025039872000000, 8202268056579952964586700800, 8036171130356719262105600, 3788540596534745497600] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 54) (gg1 54) (gg2 54) 25)) α := by - refine pev_moment_eq_of_packed_bounds 54 25 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 54 α t ^ 25) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 54 * (3 + α)) ^ 25) := - integral_moment_packed 54 25 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-52 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 52 * P α` is a positive combination of `αʲ (17-α)^(52-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 16494167009921791229556693354250558994004960089275608134952301595194145700 + 143495585732014632876947701159299432571935297872102967009453889788942630516 * α + 600146981561757364071810080610152109467421702720565940343744136045710714240 * α ^ 2 + 1606309613433661462999425062531603257368288440796455160921241994205807550800 * α ^ 3 + 3089935016411981969366335770505513109414946535522135899534602918518452400110 * α ^ 4 + 4548021756358959061868607547427969034568735681024830591427930680507708516630 * α ^ 5 + 5324472427116589963068442803453435582254682183625311260959169925128717206890 * α ^ 6 + 5088112301464007763161223382731859106222272351099136492562868432790050748010 * α ^ 7 + 4041350342582910718376698346793695673500055519225008392201038233346955184130 * α ^ 8 + 2702810799510161555412033309004487136564483291932054239796551253387958338250 * α ^ 9 + 1536279381058752516392997665745371680813310918710686404622076783423411472310 * α ^ 10 + 747035505761971294025842500370255312982388584883798779389925639599781539110 * α ^ 11 + 312120280284390297007832319287765858778034126483703719026036710712245847630 * α ^ 12 + 112328303645112191177480265164326260518118446637968730517219246030090061670 * α ^ 13 + 34847965479991464020760392422930205817393828567231232594447128943554577950 * α ^ 14 + 9311065733578254803436313728561027301061995457613177507038687159207136510 * α ^ 15 + 2137053395968205693740631086110584184448273974022381233594071100920418660 * α ^ 16 + 419415497303046617346927271099007566525536754801411545759490611489535020 * α ^ 17 + 69903195768650128169410986270066096062738214853608222509952701694930390 * α ^ 18 + 9796751930080145102336247171862671684216870902559058128633974960508990 * α ^ 19 + 1138373287745887689323718901024639495300275153431093749751357684888655 * α ^ 20 + 107431234099507044305505224510335533709977858803000709455555262812475 * α ^ 21 + 7965572671696337257969240111258550023673082988480052797472718090765 * α ^ 22 + 432489851677951286849434341419775059089962332363725955872440307245 * α ^ 23 + 10033042060175777949356539605564287060646991070535569056012261935 * α ^ 24 - 14665345174670112106333566037790518499419114767637006814333117685 * α ^ 25 + 467265281717233365794825008753399741068194685496332969035489307 * α ^ 26 - 338571739674856609859042128682071390079128171355900195378565 * α ^ 27 + 51828010052697170919200272082439937455364221416970311841360 * α ^ 28 + 4551610675134221759317748807561457084971246067804745378320 * α ^ 29 + 209779510423918524619133931870713143087995729911985149040 * α ^ 30 + 5970127197067432618593627815816805105135662362948064640 * α ^ 31 + 72450550286061369082689048114099286472057904479048640 * α ^ 32 - 2583219468428786599910558481880637801957466132337920 * α ^ 33 - 195852731109616002368456744436432386876454107873280 * α ^ 34 - 7247973580231951783404261339025545494805311297280 * α ^ 35 - 194124681108967495056283792222752779031406556160 * α ^ 36 - 4123433450448809567758812935503400791570882560 * α ^ 37 - 72082021160947668781050521228246549326725120 * α ^ 38 - 1056193512343203991501036178583787410636800 * α ^ 39 - 13096880010730035770569022035700611809280 * α ^ 40 - 138052872308930943537538309704895365120 * α ^ 41 - 1238136265130428487231808151440916480 * α ^ 42 - 9428378825017111932776968669429760 * α ^ 43 - 60659413041205873935423111168000 * α ^ 44 - 327048428909975887634922209280 * α ^ 45 - 1459908719275463855607644160 * α ^ 46 - 5302273507938488014602240 * α ^ 47 - 15275608180278584934400 * α ^ 48 - 33595607399404666880 * α ^ 49 - 52996826537656320 * α ^ 50 - 53409512161280 * α ^ 51 - 25836912640 * α ^ 52 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 52 * (16494167009921791229556693354250558994004960089275608134952301595194145700 + 143495585732014632876947701159299432571935297872102967009453889788942630516 * α + 600146981561757364071810080610152109467421702720565940343744136045710714240 * α ^ 2 + 1606309613433661462999425062531603257368288440796455160921241994205807550800 * α ^ 3 + 3089935016411981969366335770505513109414946535522135899534602918518452400110 * α ^ 4 + 4548021756358959061868607547427969034568735681024830591427930680507708516630 * α ^ 5 + 5324472427116589963068442803453435582254682183625311260959169925128717206890 * α ^ 6 + 5088112301464007763161223382731859106222272351099136492562868432790050748010 * α ^ 7 + 4041350342582910718376698346793695673500055519225008392201038233346955184130 * α ^ 8 + 2702810799510161555412033309004487136564483291932054239796551253387958338250 * α ^ 9 + 1536279381058752516392997665745371680813310918710686404622076783423411472310 * α ^ 10 + 747035505761971294025842500370255312982388584883798779389925639599781539110 * α ^ 11 + 312120280284390297007832319287765858778034126483703719026036710712245847630 * α ^ 12 + 112328303645112191177480265164326260518118446637968730517219246030090061670 * α ^ 13 + 34847965479991464020760392422930205817393828567231232594447128943554577950 * α ^ 14 + 9311065733578254803436313728561027301061995457613177507038687159207136510 * α ^ 15 + 2137053395968205693740631086110584184448273974022381233594071100920418660 * α ^ 16 + 419415497303046617346927271099007566525536754801411545759490611489535020 * α ^ 17 + 69903195768650128169410986270066096062738214853608222509952701694930390 * α ^ 18 + 9796751930080145102336247171862671684216870902559058128633974960508990 * α ^ 19 + 1138373287745887689323718901024639495300275153431093749751357684888655 * α ^ 20 + 107431234099507044305505224510335533709977858803000709455555262812475 * α ^ 21 + 7965572671696337257969240111258550023673082988480052797472718090765 * α ^ 22 + 432489851677951286849434341419775059089962332363725955872440307245 * α ^ 23 + 10033042060175777949356539605564287060646991070535569056012261935 * α ^ 24 - 14665345174670112106333566037790518499419114767637006814333117685 * α ^ 25 + 467265281717233365794825008753399741068194685496332969035489307 * α ^ 26 - 338571739674856609859042128682071390079128171355900195378565 * α ^ 27 + 51828010052697170919200272082439937455364221416970311841360 * α ^ 28 + 4551610675134221759317748807561457084971246067804745378320 * α ^ 29 + 209779510423918524619133931870713143087995729911985149040 * α ^ 30 + 5970127197067432618593627815816805105135662362948064640 * α ^ 31 + 72450550286061369082689048114099286472057904479048640 * α ^ 32 - 2583219468428786599910558481880637801957466132337920 * α ^ 33 - 195852731109616002368456744436432386876454107873280 * α ^ 34 - 7247973580231951783404261339025545494805311297280 * α ^ 35 - 194124681108967495056283792222752779031406556160 * α ^ 36 - 4123433450448809567758812935503400791570882560 * α ^ 37 - 72082021160947668781050521228246549326725120 * α ^ 38 - 1056193512343203991501036178583787410636800 * α ^ 39 - 13096880010730035770569022035700611809280 * α ^ 40 - 138052872308930943537538309704895365120 * α ^ 41 - 1238136265130428487231808151440916480 * α ^ 42 - 9428378825017111932776968669429760 * α ^ 43 - 60659413041205873935423111168000 * α ^ 44 - 327048428909975887634922209280 * α ^ 45 - 1459908719275463855607644160 * α ^ 46 - 5302273507938488014602240 * α ^ 47 - 15275608180278584934400 * α ^ 48 - 33595607399404666880 * α ^ 49 - 52996826537656320 * α ^ 50 - 53409512161280 * α ^ 51 - 25836912640 * α ^ 52) = 16494167009921791229556693354250558994004960089275608134952301595194145700 * (17 - α) ^ 52 + 3297121641960181902845058974129119421411157988468082062178235809362120295172 * α ^ 1 * (17 - α) ^ 51 + 319724415956160860091458945589182808902003352419736285543485329679451094270932 * α ^ 2 * (17 - α) ^ 50 + 20038710926027661432334875342791217340018851913295984793285523609822774454252700 * α ^ 3 * (17 - α) ^ 49 + 912506063164863213831944030666321098534650758920349287477777497262175240738402310 * α ^ 4 * (17 - α) ^ 48 + 32177823044530476695020659335002454111188404373175841794915018442377955651394113990 * α ^ 5 * (17 - α) ^ 47 + 914540681282828800807599319891793843292641936770051259660032453172015089441416681780 * α ^ 6 * (17 - α) ^ 46 + 21529723418168081854258856249066854725157410727767949291151621244500815386654814167180 * α ^ 7 * (17 - α) ^ 45 + 428187563876954541113963075618060221598963677578037826566438784007708913233247747176780 * α ^ 8 * (17 - α) ^ 44 + 7301844169441283547821796282852027526162858087792900418706107149330943728664004086739660 * α ^ 9 * (17 - α) ^ 43 + 107998890241658105222949402539269436370829457640263205565353289295418525536340771107662680 * α ^ 10 * (17 - α) ^ 42 + 1398093827433571704042090344538943552073638570463931753295281987815735454006786470999735160 * α ^ 11 * (17 - α) ^ 41 + 15957032127861583576984677012499030521875944161240621820452635989220785757028810049931646660 * α ^ 12 * (17 - α) ^ 40 + 161526877975623854315474231221259866905794267588621234412370551845474892520146496256658344580 * α ^ 13 * (17 - α) ^ 39 + 1457239742403607406416443184401351553341986505900117649824594649023236812024794234917099752380 * α ^ 14 * (17 - α) ^ 38 + 11764118385331183795485731464799855976003853373075619337664964031988252913700051042473465972420 * α ^ 15 * (17 - α) ^ 37 + 85266812327847025363233082778590085924666659056638604615146724746162734347495123483376596599070 * α ^ 16 * (17 - α) ^ 36 + 556412933665661316562603334092469787110651645009094640295939461919699008524178193574911456908110 * α ^ 17 * (17 - α) ^ 35 + 3276500502586555718746248192880369763373913284974973228696609120912342926842381883477115970971330 * α ^ 18 * (17 - α) ^ 34 + 17443973618063549860197174258607173645342170656659807634029925978540184960307013051100945108575830 * α ^ 19 * (17 - α) ^ 33 + 84097208992473763322482498841713994615424570017542204453635043962819422256085229322643661036553135 * α ^ 20 * (17 - α) ^ 32 + 367595670215331608081325934241054123019019558617664793950031213417886531914880453450235055639827695 * α ^ 21 * (17 - α) ^ 31 + 1458319292273003092992284569774617261635353524450745892916673491633645545947909275323789971386584010 * α ^ 22 * (17 - α) ^ 30 + 5254980271354566622530408171222928163731186808057577088774647757156770300739259401327506864767179590 * α ^ 23 * (17 - α) ^ 29 + 17209987305609188388593928884348304692679416452958887120667494264685355764336243613006433529300889900 * α ^ 24 * (17 - α) ^ 28 + 51245313767700576927493227999999199039753952598947831546238937797935220706183422086338270920360486300 * α ^ 25 * (17 - α) ^ 27 + 138766478666356226035473697072120508245376894603069112986887914209096091729659135725891961666489860662 * α ^ 26 * (17 - α) ^ 26 + 341725720150049744585959626125868368010499310869413614657759212314754963597840236324448419782451114282 * α ^ 27 * (17 - α) ^ 25 + 765136285933410012453175445478517650702161463656786558161202904376215029605986594283307478093304307385 * α ^ 28 * (17 - α) ^ 24 + 1556877403438278759283881545391171005360005954054145030966940257959498891624213557816408094093075864665 * α ^ 29 * (17 - α) ^ 23 + 2876564405128945633873865865688129358774847644012865518697098702186811357802016717785624061301955829430 * α ^ 30 * (17 - α) ^ 22 + 4820561162618100599568269482213420070663798726185647089067973322799735823546946658344673073602139469970 * α ^ 31 * (17 - α) ^ 21 + 7315920828232011027352935983664196353610979185130017647700999674444485613522154300362261069304268308590 * α ^ 32 * (17 - α) ^ 20 + 10036378526288476516030178366360979243689435681024753191393010979431912513169664181917187452264705749630 * α ^ 33 * (17 - α) ^ 19 + 12418173602350336332834011143730287052626259450406781462033191143152690802051403229595128207313656006650 * α ^ 34 * (17 - α) ^ 18 + 13822754463345097102831820242184258761738276008006821284534279176481079905732530814499207866955435085150 * α ^ 35 * (17 - α) ^ 17 + 13801040060918957888564788139270767298844994408740307330701472008264699451769662273654318158513511789155 * α ^ 36 * (17 - α) ^ 16 + 12318471680266652419845517118100896836955882316001519109947812762310692937531763121301079422467179937315 * α ^ 37 * (17 - α) ^ 15 + 9791961276777243139471730047869500129996328504872391696608131789839153344852214590773875133920134451090 * α ^ 38 * (17 - α) ^ 14 + 6901396925674586370353679055683314537328841096886193608522335358563478321818303138218149658902821023950 * α ^ 39 * (17 - α) ^ 13 + 4290696155282947318028543407039084473970660925581234584798657667133577612919565979582433162065644672980 * α ^ 40 * (17 - α) ^ 12 + 2338873380377640090710543794097867885941646034550384133409823471730993425571758516636190486584614953700 * α ^ 41 * (17 - α) ^ 11 + 1109732755852378588712211011650814187613669797876675740951121816904470151813091358110884216937743142050 * α ^ 42 * (17 - α) ^ 10 + 454286800542359954534080719815999805873534526512065733818696923800302006274839909248752230406180846110 * α ^ 43 * (17 - α) ^ 9 + 158713699307083273689749079467203333163770903148624457146145339447571976015368636000957338799724035275 * α ^ 44 * (17 - α) ^ 8 + 46680861352325638868600152099580545678224568597334155135966362508038806503807101375708916251637014315 * α ^ 45 * (17 - α) ^ 7 + 11358113255233464326610717370655147651105757900848936506289875029144788364049674739051630170475728510 * α ^ 46 * (17 - α) ^ 6 + 2234292960434683002788971594223923746722335287405129686566824534284185319130892757911313973235591050 * α ^ 47 * (17 - α) ^ 5 + 344434128456143069997502715027323329232394662376196306985663027670793467133639790028593418988513700 * α ^ 48 * (17 - α) ^ 4 + 39809789393720194364475874377808256220963899458735378967674739520923108380632695527160035322788100 * α ^ 49 * (17 - α) ^ 3 + 3224979637871433689973695689784750956991084495357901531836611031085730991516232539844546931899840 * α ^ 50 * (17 - α) ^ 2 + 162942207478993682465981071080743775591479135331458384477879849257595493096166794488597275948400 * α ^ 51 * (17 - α) ^ 1 + 3907984261693816830880565006531529193978954398787645698090073443074989996324628172410599696000 * α ^ 52 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `54 ≤ n ≤ 55`.** -/ -theorem finite_range {n : ℕ} (h0 : 54 ≤ n) (h1 : n ≤ 55) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (55 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (55 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 53) + 1 / (4 * 53 * (3 + α)) - + (1 - 2 * α / 54) ^ 2 * 55 * 54 * (55 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 53 * (3 + α)) ^ 25)) - = 1 - (16494167009921791229556693354250558994004960089275608134952301595194145700 + 143495585732014632876947701159299432571935297872102967009453889788942630516 * α + 600146981561757364071810080610152109467421702720565940343744136045710714240 * α ^ 2 + 1606309613433661462999425062531603257368288440796455160921241994205807550800 * α ^ 3 + 3089935016411981969366335770505513109414946535522135899534602918518452400110 * α ^ 4 + 4548021756358959061868607547427969034568735681024830591427930680507708516630 * α ^ 5 + 5324472427116589963068442803453435582254682183625311260959169925128717206890 * α ^ 6 + 5088112301464007763161223382731859106222272351099136492562868432790050748010 * α ^ 7 + 4041350342582910718376698346793695673500055519225008392201038233346955184130 * α ^ 8 + 2702810799510161555412033309004487136564483291932054239796551253387958338250 * α ^ 9 + 1536279381058752516392997665745371680813310918710686404622076783423411472310 * α ^ 10 + 747035505761971294025842500370255312982388584883798779389925639599781539110 * α ^ 11 + 312120280284390297007832319287765858778034126483703719026036710712245847630 * α ^ 12 + 112328303645112191177480265164326260518118446637968730517219246030090061670 * α ^ 13 + 34847965479991464020760392422930205817393828567231232594447128943554577950 * α ^ 14 + 9311065733578254803436313728561027301061995457613177507038687159207136510 * α ^ 15 + 2137053395968205693740631086110584184448273974022381233594071100920418660 * α ^ 16 + 419415497303046617346927271099007566525536754801411545759490611489535020 * α ^ 17 + 69903195768650128169410986270066096062738214853608222509952701694930390 * α ^ 18 + 9796751930080145102336247171862671684216870902559058128633974960508990 * α ^ 19 + 1138373287745887689323718901024639495300275153431093749751357684888655 * α ^ 20 + 107431234099507044305505224510335533709977858803000709455555262812475 * α ^ 21 + 7965572671696337257969240111258550023673082988480052797472718090765 * α ^ 22 + 432489851677951286849434341419775059089962332363725955872440307245 * α ^ 23 + 10033042060175777949356539605564287060646991070535569056012261935 * α ^ 24 - 14665345174670112106333566037790518499419114767637006814333117685 * α ^ 25 + 467265281717233365794825008753399741068194685496332969035489307 * α ^ 26 - 338571739674856609859042128682071390079128171355900195378565 * α ^ 27 + 51828010052697170919200272082439937455364221416970311841360 * α ^ 28 + 4551610675134221759317748807561457084971246067804745378320 * α ^ 29 + 209779510423918524619133931870713143087995729911985149040 * α ^ 30 + 5970127197067432618593627815816805105135662362948064640 * α ^ 31 + 72450550286061369082689048114099286472057904479048640 * α ^ 32 - 2583219468428786599910558481880637801957466132337920 * α ^ 33 - 195852731109616002368456744436432386876454107873280 * α ^ 34 - 7247973580231951783404261339025545494805311297280 * α ^ 35 - 194124681108967495056283792222752779031406556160 * α ^ 36 - 4123433450448809567758812935503400791570882560 * α ^ 37 - 72082021160947668781050521228246549326725120 * α ^ 38 - 1056193512343203991501036178583787410636800 * α ^ 39 - 13096880010730035770569022035700611809280 * α ^ 40 - 138052872308930943537538309704895365120 * α ^ 41 - 1238136265130428487231808151440916480 * α ^ 42 - 9428378825017111932776968669429760 * α ^ 43 - 60659413041205873935423111168000 * α ^ 44 - 327048428909975887634922209280 * α ^ 45 - 1459908719275463855607644160 * α ^ 46 - 5302273507938488014602240 * α ^ 47 - 15275608180278584934400 * α ^ 48 - 33595607399404666880 * α ^ 49 - 52996826537656320 * α ^ 50 - 53409512161280 * α ^ 51 - 25836912640 * α ^ 52) / (8905825603714907746191103330109125499618527182188584734005088 * (3 + α) ^ 26) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 54) (n₁ := 55) (k := 25) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B54_55 - -end Sendov diff --git a/Sendov/FiniteRange/Degree56_58.lean b/Sendov/FiniteRange/Degree56_58.lean deleted file mode 100644 index 85935cc..0000000 --- a/Sendov/FiniteRange/Degree56_58.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 56 to 58 - -`Sendov.R_le_batch` bounds every `R n α` for `56 ≤ n ≤ 58` by the elementary part and -moment at `n₀ = 56` together with the prefactor at `n₁ = 58`, so one moment and one -certificate serve all 3 degrees. The certificate has degree 54, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B56_58 - -lemma M_lo : M 56 = 55 := by norm_num [M] - -lemma M_hi : M 58 = 57 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 56 α = 1 - 2 * α / 55 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 58 α = 1 - 2 * α / 57 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 56 α = (330 + 49 * α - 2 * α ^ 2) / (110 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 56 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 164249358725037825439200 - -def betac : ℤ := 115103103983430041881668059927031677649607448586192616332003949610213871026290038646492588672285267093094401 - -def tauc : ℤ := 4693092880083288260025666340202716758462295736635746261187172973670803761348080289977718430172794223868972166270709150689766683002012964345276310170272127638801557906055315191737481557345311319125147550231968976718052724821397470663805896465914125461666625737324807246835964023673742145924871656368076577390194392061724738021591335391495509516764527490505510399864111735071592301714821324177110215073295398225133727948712987423962946755473184756061752268167581642999262301200878964880316018790314668494639913368488408107034480320555883365739317559402093492388177600270664813072401757266768540669826329041397497859893205382777686660550612714363175361805511533564904904490389550188823109618174631295617304833140001703020157375057912587878545346670001004502147585409622568052032336903741418966171538198401622933837683727475100022920176082888051631953708269170285922995874940808723874807430747250832868099232357765238406704326832287107270623291592136595054204141985108054386957802676776280506711358711041426943004450387951750409548218539478144490156877355883327764312428923662051936263003056869031026688388245903177361103548858509697516962824754175263671788787434172467265693052258305482488007106874707106446510155952400579499904011828528339917431400346959527930153015948872099072651950535075703606752994684064338227549539626612747451376893374699431473684411191282993657024712098494990130043263030063803933655666305017039116915113199528916461302751896190946713407672548035997210184118435933809969990873069984761021887060950608608978800172583254158195726716743702690548108959843324428986803683043061410282613844411124171526274420407186567885736535992177623028462108429926816879680454819947150935704717432357348468828738663535471537085124220555061538568168961471428198080813348893135282852501240654732427209216955532772170828992919010103255088848272634769592783269455901210972436902548206639940946910187637587290777462557902207593858152761644600436134555109766011814159207482353678997223831690330632238994836773940256574316535791300782794857414997683759248496223963567193895537594110702041580979533897205589515716139732026863783959693402998885368544700352938667665827545455738182183270343504011111170991665295139018259283373271348337005144786536012820171808284172594468743392099175823706362604019515121702642744174449845389506716688240830739479685284414506080190892335459195567198500638531261432083103653074809773639384964290600988504471122939214018776358560680591178587135665943883179719360995875631109619264815573819279445211600773968932443587178201107074923367072284418368871284563990081400969298859038100237507068707583425364414608635798602677629240497088921534516544612558370987548182261497282322120863549061179175932160556420106644698998558773799910403720555690039479943392084333185371760833919993830013834041422609576966376374185660874597024707861463558182786128875109143047297851776645577445147646196381049384165642250462902633835348322102240893859945916799324548931797997498204233707961858126162144560002710775279087126539658375486540824653979280622253580160186390278467934797383603364207703247144329779747491239266387917088827863706427116282315720852615437665681653383630905503147550501022599422844883798639228804966944216026199079243882826778102345692962544865449499658648522733260027815537585482407821301535525184824891068498119061812621663480376828651817413687389894868806084790014719309284151210676795984897434305090269934666166235765925442532534422426444302865851061742850804344749394357561844291841719357611597043509006432822661525570877602302822268617962539501162100416429706330054038072354227279614452628416761511033247265985199356167338980355670074481259935536901331544156938757913679334460787597655987475333781385480395005300630857888507532916197725966146764432753754366495984310198784025404185868605191040129866126669930877304432001201960290762478649265720652049698784650467533642731433841166887297629573809983773276410341518347604899399937483417532411437213985069994957646212111786834647103983992621174255145476776797205426147774922811753977367064344834131388983251700833792094137518387389244525949612548925162812425089281231345875699915393233687433969972363844386877995316696080091388427623948191123347156626311677688723709222683115455469735795917825835947741166852442767670691225634587280711775239769116392932534189663532865632812568798311309135254454728838022598525071500115602645612561089466053290195841289011827277708875365133188825643097295806991885957013490338809940593720290686485527608402551234588106557991076261330410759421839822103021863306184398512948870669518026703542225539424043492277723572547701646040705687119006012284155249522097498625915248155208302491825902456748349357709586299421676777879286848899616764302952809019929947717537742481578930245879905510620199517493484927050276384641373848289812659410408588984322378331870890671344897893291054062187347183098118452892515703832771642559683986270056260378016584518402923246618279777162188226451102545137361106762091659960314563426515178619221670625930685157955387559502860683800835983918854683085191354644777906016878158782613205088730921292245108880920171587993790333452768089008103178836011415987775134181569314143861395570746940065726782923569891051522727781114822831853229263099947290630877909209210184612749170225062932086047563745270799579235897132861159290331825627676892667720985377579523888811482642593475209898468809965564520998505775789123130722838421680293958820670725419895092782679571345802799661810107367996473811373322078369950756642847102387734389377964857272930815158522449331911573587551988239058640013235414617241184737726653662840281856130494452777880671010587886658750938434067040550130422659783459081170369852599871091149561624491556014060442034688612187144177662779452729966228892888124225803923134562445212495562521323511677955079839386675575244984301123982621479479071193648388620761063462371966196354669073266728237219376580442179969724675010536017529617208145253037134144053713015664842629850866072160248972062108555562928373833069273598860737911116830765263605358301987357977832321515142907766029468982430688940327557786547295926570572655004921977210973347355225401052371307310594937153100722831371972019732095606794699573608501689794554257549936727122184424547237330777112913032382599235720440539654557403804505801750283867336449502098884080336954839227099026384065845976854545916201975316797945268115103248672583995954935582184688411819570798606747220298373185965884741014417118721057162553844111318872735699674961956918110265346336156484537769456383208155353939339587653545678322067529863160610662183313188151481294230573928287628415486898083696325154174205369090181772992315098238089470058257864146152486145214506248972564233800903496108944595368671533760450015531287006152108409240497520846456651390386905130715436671895982593470749310621410690237887792840683760744356371984180539082590010448732896605400336672915464556522802742286510911505179637953271696743453096400828450831570372081292589687398435923642871771163063050751515076731281937842169659716964372751024410550235992285648047137648436265594918435817867681326330322536718001767898681486945970749182693712938696147040757996552764636415933353561447908206473264840678562084096264484462899863699152545759110187338874175010953765032682134114519372000717101952851781681130634490154786031989805974884403853998627808459178437115760519994306340767192968798416754069520517790464963207886068066081444289665402531135122027765179770589108787060430800846078610113336817947772789148185727044381562163312315625360902503869550655597398823355828192806606450217845456031753268771145596813679152238803670229474600396404453454138205522210064972536420291586230258982045672710461124463398711688753730396917961443185836096138486310222876953941083472176233676421389706414123156166001163171310445418128606177727899323989442996629527025292824304497780362889553872293734892921191627030644037361149269499428534245032218106117842307162336491318046759304972006638084649140697812399446232182862730484747700153845334898151941385069715068219172423945702605750851965856948352980164300620220698349151047813434409666645158551222899715981586235068166057397385213128445066253661647038354487915135269134590678430940267849334597154703149349514123786972750888178950828475153860087582100517491372789898658322232148765223308524958082700593614487904294390431257326110568927402973450554312045747544830455983150826222837421629404523848712223986854940529621328634455476730716694761282812808469442378269343122194433 - -/-- The moment numerator at `n₀ = 56`, `k = 26`. -/ -def Nmomc : List ℤ := - [33868582764593486614580198271976115909945381301431665278000000000000000000000000000, 320783574985576954266817702040765346435468423111908091026400000000000000000000000000, 1464944226771346229883235364508543692815754116999974490834800000000000000000000000000, 4295115136765919668519524376268312032880310840581088917202240000000000000000000000000, 9082273220345340571582057632561758215665009777928915319597136000000000000000000000000, 14751284758104105432077939677611377916650960687914409750600213760000000000000000000000, 19137140825264939693776052776262891311178314056483462141355029888000000000000000000000, 20360071640607291537880857112473816979755285790649204553690963456000000000000000000000, 18098169354762788988463121409931792683987974709983274480942260467200000000000000000000, 13625519195620228848992683755722258059883803192220805004939752852480000000000000000000, 8776463139807067760582569762737995383560203608259607100369333972070400000000000000000, 4873037428446808296629559311226387551868427417443101045063263537643520000000000000000, 2345312857656583806744638801805282188390679118534072041892680816599040000000000000000, 982303240459731677899573506650574396164657142679309449536943338668032000000000000000, 358999922574020348412584179216096208248549762846073489934083756059852800000000000000, 114665825582028445117360762218322789119057822571310583030713193523838976000000000000, 32029535611512239650319556425768665704842598681996221353545453997149388800000000000, 7823476034807414586554359962054392167911861412097999185219305886226841600000000000, 1669903668424626293053683633952751587559044221295377519875655553052835840000000000, 311184218595479121122107983311419552169507095646555034420546580031471616000000000, 50590477903643325235750809883523870362530219638946921913819324844857098240000000, 7178520133309593259519371618343534950578256464408935572198999127083712512000000, 892106478409766777941564873448017790756372122096647214142160628585857024000000, 98185816982660133827431812009314483888805893506515808758334087759921152000000, 9939119916963633437676393057789374643822127955775461391110611417222348800000, 1160702942716697816676165717017918703507609588377247568278550602657143193600, 885103188985964495082304868003268556919404521778024643790459364959772999680, 37866509791243107173228252377602677546078050946031365227732016072868495360, 1602052346923722092883721529151973040677240243504270754096634547666944000, 64343986788728864329495510919311534266655630087627140802893991378944000, 2367391036005924145537611563523741752007870943045425066555224358912000, 77917509209300817836063551626920532574519551770471519437227609292800, 2263969423642112116959862649062504882112286609771180810273659289600, 57711292797094350702236803227873014104624655713493568184123392000, 1287560685245640996382341052913393398756798865424054151544832000, 25128128553510660963646375794393285609017499188056012357632000, 429043489271119727945132142610350604090805919279874257715200, 6409950701800945563270351769563444706570837630462092902400, 83774287013172053226156110705304276399176872252932096000, 956918776848844618294111185030319115173185386971136000, 9536360828571019805323364732115306378641687969792000, 82682921172675210958965979129462156322782209638400, 621167503268387900847853291726272409929305292800, 4020890511748251669022692717461711920037888000, 22257001403658112235812283834692710432768000, 104289134216461900346362078898191073280000, 408052823266348851171690914760779366400, 1308552624077075698447423237835980800, 3349761809403351687282424807424000, 6582397587185967597715718144000, 9322878474654558727648051200, 8472072247083599145205760, 3709817675048309227520] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 56) (gg1 56) (gg2 56) 26)) α := by - refine pev_moment_eq_of_packed_bounds 56 26 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 56 α t ^ 26) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 56 * (3 + α)) ^ 26) := - integral_moment_packed 56 26 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-54 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 54 * P α` is a positive combination of `αʲ (17-α)^(54-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 4006776526237583458791916745921571399903640427998587971001863479614257812500 + 36193299233577005092404435186325555880909575118523570487124919891357421875000 * α + 157404458430456801566314898531435489082055275896144801637965440750122070312500 * α ^ 2 + 438789302805190644765999692456086768304410010456706455086051940917968750000000 * α ^ 3 + 880644388246065999407804638303739222032368746089754793927588987350463867187500 * α ^ 4 + 1354948378632315916086740220782422392456213284262767321014325168609619140625000 * α ^ 5 + 1661602897691580734737365439849633466188200353673006461916168213272094726562500 * α ^ 6 + 1667045608015110082374111106109377028467549691711516663117268814086914062500000 * α ^ 7 + 1393634964581423479006807950372755382512403362475605339704530439338684082031250 * α ^ 8 + 983739476273137944395322828805928193025534886625965973020494254135131835937500 * α ^ 9 + 592005671863910309809560316101676243798968926448970748675875927594299316406250 * α ^ 10 + 305845520279728243480763379048878002620628430303914474045381805538574218750000 * α ^ 11 + 136301035857816688759209743042609079523363637041425866478473082778930664062500 * α ^ 12 + 52557215535889563135879554015106695279244905727351138276424395612451171875000 * α ^ 13 + 17560188550728447991878218358662068709211261557084724400278409291245117187500 * α ^ 14 + 5083558311018366382022659794526798695920221466826180257750759952604687500000 * α ^ 15 + 1273131764429501958625291301675693164238362230486966503823878444190878906250 * α ^ 16 + 274960492120840016369195438376101201319262210714934208739555078202929687500 * α ^ 17 + 50954380823074628723812132018848659015398414173106367885877485025457031250 * α ^ 18 + 8043619315575642311782000673332751078848207374194599271764060475643750000 * α ^ 19 + 1070647032300550686760844315611512648892236354901418090931769834405593750 * α ^ 20 + 118447064950886641697648118438020073800095586622991278431631099619912500 * α ^ 21 + 10665844034582511896384387237050410144703560308738822660894704597031250 * α ^ 22 + 756055215489708905909989210679280265318059125676239214550223981550000 * α ^ 23 + 39319509582765585318317434167304155450155442605644113789923547061875 * α ^ 24 + 867126925428575278846841639739898919922847699797676292404824708330 * α ^ 25 - 1342664334700830923321502819993530701259788051847367543772214665281 * α ^ 26 + 39483777041359676646803092797859249221387704496311861748873113400 * α ^ 27 - 58711046556251894173073392026014465411610439743591823421605392 * α ^ 28 + 2490932168525853073760934875391654922167755426092527716004768 * α ^ 29 + 299316943768298507774611885828874444092265356390330098080400 * α ^ 30 + 15336692487146884782753132557947737242171025616954771587840 * α ^ 31 + 493116066063688255278336127843281464063956961803863360000 * α ^ 32 + 8923910394517508916121212299646048703215085675738298880 * α ^ 33 - 42485806368509927498334028885467492467879729762661120 * α ^ 34 - 9926741056642548036510544310918633673463407651072000 * α ^ 35 - 427541739200753198037475741948767076883193745367040 * α ^ 36 - 12336686560635193418143284676363319056265591808000 * α ^ 37 - 276403480622187214471125457231894057984922849280 * α ^ 38 - 5061460700774592700650136059515237541978439680 * α ^ 39 - 77589542792718274978754693243996574602035200 * α ^ 40 - 1008285668556426930549466452256224957562880 * α ^ 41 - 11180151867078112441929755167105458176000 * α ^ 42 - 106057325448908908308826107393838940160 * α ^ 43 - 860453519636632559264422458435829760 * α ^ 44 - 5953015798094365467380006676070400 * α ^ 45 - 34925450531279060313143566663680 * α ^ 46 - 172262764126427765287157760000 * α ^ 47 - 705448234661772873443573760 * α ^ 48 - 2356408942484969918300160 * α ^ 49 - 6257674902168236195840 * α ^ 50 - 12711757957239406592 * α ^ 51 - 18555990127411200 * α ^ 52 - 17333951135744 * α ^ 53 - 7784628224 * α ^ 54 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 54 * (4006776526237583458791916745921571399903640427998587971001863479614257812500 + 36193299233577005092404435186325555880909575118523570487124919891357421875000 * α + 157404458430456801566314898531435489082055275896144801637965440750122070312500 * α ^ 2 + 438789302805190644765999692456086768304410010456706455086051940917968750000000 * α ^ 3 + 880644388246065999407804638303739222032368746089754793927588987350463867187500 * α ^ 4 + 1354948378632315916086740220782422392456213284262767321014325168609619140625000 * α ^ 5 + 1661602897691580734737365439849633466188200353673006461916168213272094726562500 * α ^ 6 + 1667045608015110082374111106109377028467549691711516663117268814086914062500000 * α ^ 7 + 1393634964581423479006807950372755382512403362475605339704530439338684082031250 * α ^ 8 + 983739476273137944395322828805928193025534886625965973020494254135131835937500 * α ^ 9 + 592005671863910309809560316101676243798968926448970748675875927594299316406250 * α ^ 10 + 305845520279728243480763379048878002620628430303914474045381805538574218750000 * α ^ 11 + 136301035857816688759209743042609079523363637041425866478473082778930664062500 * α ^ 12 + 52557215535889563135879554015106695279244905727351138276424395612451171875000 * α ^ 13 + 17560188550728447991878218358662068709211261557084724400278409291245117187500 * α ^ 14 + 5083558311018366382022659794526798695920221466826180257750759952604687500000 * α ^ 15 + 1273131764429501958625291301675693164238362230486966503823878444190878906250 * α ^ 16 + 274960492120840016369195438376101201319262210714934208739555078202929687500 * α ^ 17 + 50954380823074628723812132018848659015398414173106367885877485025457031250 * α ^ 18 + 8043619315575642311782000673332751078848207374194599271764060475643750000 * α ^ 19 + 1070647032300550686760844315611512648892236354901418090931769834405593750 * α ^ 20 + 118447064950886641697648118438020073800095586622991278431631099619912500 * α ^ 21 + 10665844034582511896384387237050410144703560308738822660894704597031250 * α ^ 22 + 756055215489708905909989210679280265318059125676239214550223981550000 * α ^ 23 + 39319509582765585318317434167304155450155442605644113789923547061875 * α ^ 24 + 867126925428575278846841639739898919922847699797676292404824708330 * α ^ 25 - 1342664334700830923321502819993530701259788051847367543772214665281 * α ^ 26 + 39483777041359676646803092797859249221387704496311861748873113400 * α ^ 27 - 58711046556251894173073392026014465411610439743591823421605392 * α ^ 28 + 2490932168525853073760934875391654922167755426092527716004768 * α ^ 29 + 299316943768298507774611885828874444092265356390330098080400 * α ^ 30 + 15336692487146884782753132557947737242171025616954771587840 * α ^ 31 + 493116066063688255278336127843281464063956961803863360000 * α ^ 32 + 8923910394517508916121212299646048703215085675738298880 * α ^ 33 - 42485806368509927498334028885467492467879729762661120 * α ^ 34 - 9926741056642548036510544310918633673463407651072000 * α ^ 35 - 427541739200753198037475741948767076883193745367040 * α ^ 36 - 12336686560635193418143284676363319056265591808000 * α ^ 37 - 276403480622187214471125457231894057984922849280 * α ^ 38 - 5061460700774592700650136059515237541978439680 * α ^ 39 - 77589542792718274978754693243996574602035200 * α ^ 40 - 1008285668556426930549466452256224957562880 * α ^ 41 - 11180151867078112441929755167105458176000 * α ^ 42 - 106057325448908908308826107393838940160 * α ^ 43 - 860453519636632559264422458435829760 * α ^ 44 - 5953015798094365467380006676070400 * α ^ 45 - 34925450531279060313143566663680 * α ^ 46 - 172262764126427765287157760000 * α ^ 47 - 705448234661772873443573760 * α ^ 48 - 2356408942484969918300160 * α ^ 49 - 6257674902168236195840 * α ^ 50 - 12711757957239406592 * α ^ 51 - 18555990127411200 * α ^ 52 - 17333951135744 * α ^ 53 - 7784628224 * α ^ 54) = 4006776526237583458791916745921571399903640427998587971001863479614257812500 * (17 - α) ^ 54 + 831652019387638593345638902447299305570259360126824448715224266052246093750000 * α ^ 1 * (17 - α) ^ 53 + 83833748304900879170452634641877950866675611368241564068775231838226318359375000 * α ^ 2 * (17 - α) ^ 52 + 5468494358777378393080477785807867951674090671443673031117236424446105957031250000 * α ^ 3 * (17 - α) ^ 51 + 259497095119023070284911959202753696905030203192837428866594793371009826660156250000 * α ^ 4 * (17 - α) ^ 50 + 9548226194342856021369990031496637841520575254703619359937770099499221801757812500000 * α ^ 5 * (17 - α) ^ 49 + 283554795754116919933939967317880593392006022363436344694634037363653737640380859375000 * α ^ 6 * (17 - α) ^ 48 + 6985033324607242622400264323272167984455201909490308654941771836141864102172851562500000 * α ^ 7 * (17 - α) ^ 47 + 145585869325517123027631865241602024127251143700135843061398935728533566792640686035156250 * α ^ 8 * (17 - α) ^ 46 + 2605939606481930370231755414493637687294479329903418074328564748827833386281097412109375000 * α ^ 9 * (17 - α) ^ 45 + 40524996895639459847128154228148170371947695272650286201553195462882818721524821166992187500 * α ^ 10 * (17 - α) ^ 44 + 552551133383357806856520189290844564406656538250136666178295793900819727635981966064453125000 * α ^ 11 * (17 - α) ^ 43 + 6654537960345176614579520210501969964341553464814299926502106023232060321118045116027832031250 * α ^ 12 * (17 - α) ^ 42 + 71215632892928225012541089836574503427207341702460836120538723682777701285820760548632812500000 * α ^ 13 * (17 - α) ^ 41 + 680613583355729809602306987711530797435340161763367564193121313750649561609059057159169921875000 * α ^ 14 * (17 - α) ^ 40 + 5832875752360000513642484795718619279175379757851803276997150658226737011497871446091396093750000 * α ^ 15 * (17 - α) ^ 39 + 44979351085207558150078784978662679910370590969134326277300556578996443629331813144059755039062500 * α ^ 16 * (17 - α) ^ 38 + 312995911940481513520445963433861073963208442217604567895958294256991627351128534764956244218750000 * α ^ 17 * (17 - α) ^ 37 + 1970161029906836645506545335621217130652959793873949162987985608245722153781520858422880420890625000 * α ^ 18 * (17 - α) ^ 36 + 11240168074382975494983845291739726207752209032492025653981589349256891847236794547066229926806250000 * α ^ 19 * (17 - α) ^ 35 + 58220468052171150534543089230853402616213765163545474800357913943776071267588624931694422468683718750 * α ^ 20 * (17 - α) ^ 34 + 274162442806735488937328580878545767896445602338781689345873092416421648387300355873155086008186200000 * α ^ 21 * (17 - α) ^ 33 + 1175053053219549755923303158761313219677705229404659836838649889496146832750569917119434117241667287500 * α ^ 22 * (17 - α) ^ 32 + 4587918386962882020150348519193673004398898248795343130672609419407279340288027481893308532612882750000 * α ^ 23 * (17 - α) ^ 31 + 16330076475454767959070546693996088924163345527886054247186679311654325903066537139062302883030633149375 * α ^ 24 * (17 - α) ^ 30 + 53015531748660804101125233244023173725306131782343261679623854226624053438968135738999293061644801261060 * α ^ 25 * (17 - α) ^ 29 + 157042247362868043075174929076891424448113760391534609598267651251111262726701902052468899161352536565826 * α ^ 26 * (17 - α) ^ 28 + 424536028113530069741207063773543340247417183854664190521457558189988983776332421257010922807774328703468 * α ^ 27 * (17 - α) ^ 27 + 1047394825014464265044437577949313703859620376795552005549249263622157394802977948988963043499590064285701 * α ^ 28 * (17 - α) ^ 26 + 2357953243932795895351786030037214986312773901878377266600410243701385112182023007703278183236835882555920 * α ^ 29 * (17 - α) ^ 25 + 4841990819787898672356879612840738450763274999724268831092864647028159910497634849060319644324211875401000 * α ^ 30 * (17 - α) ^ 24 + 9063584503650178882271337601783826443148131765373991434810543048088202441000466212270593355824045378675000 * α ^ 31 * (17 - α) ^ 23 + 15451128490873801008027757078817526210012989527697672000297488543102153793093056771081079889530059921809375 * α ^ 32 * (17 - α) ^ 22 + 23958789035470262232279921076956417405034112471262464267273767085684019981430087645587646696528226066737500 * α ^ 33 * (17 - α) ^ 21 + 33738977176761179018990595988066513346352404262225555749812365323678028997756330293158647680594843998343750 * α ^ 34 * (17 - α) ^ 20 + 43066010152981647775428783321099345843672023374934640403912525283591537133423955925346616576791170076562500 * α ^ 35 * (17 - α) ^ 19 + 49716389232502500304027459338301800974067035710033081062048758917500248639945950282904415348908887986328125 * α ^ 36 * (17 - α) ^ 18 + 51772728585970415852508288051049002543845872981898134416451565218988426676405878702958035332866606796875000 * α ^ 37 * (17 - α) ^ 17 + 48489623083597730277404885225414500632015670930460944310500759458078933768686805720241794646887945820312500 * α ^ 38 * (17 - α) ^ 16 + 40706685418039446342456126818361030430892463367085468425983118729461107320981091338190269943859904687500000 * α ^ 39 * (17 - α) ^ 15 + 30510757875107724377755328842206506253240610141014079628356809193148547036423525594278170823630233154296875 * α ^ 40 * (17 - α) ^ 14 + 20325417185768341572644199400008775190356569699126770047800664408936401012312339590678833285411352539062500 * α ^ 41 * (17 - α) ^ 13 + 11970484403352576009251094586102294750081037384202884978488076602265682461511720826286535223334289550781250 * α ^ 42 * (17 - α) ^ 12 + 6193242030824480837746170022650419963156765230142047685904514800454071854093027706906593305633666992187500 * α ^ 43 * (17 - α) ^ 11 + 2793420712321765649092179680582709716866031666381458570060592097389668488933904453892321322512969970703125 * α ^ 44 * (17 - α) ^ 10 + 1088149422884559786015096896649994047996413331792775697347682065754794925880331083486662942138671875000000 * α ^ 45 * (17 - α) ^ 9 + 361802514627870134054227480223533630715173215487471596187535638974794633464984427234290066680908203125000 * α ^ 46 * (17 - α) ^ 8 + 101146608070751659320633087948602468401536695297326173484816516224027843212819017493162674713134765625000 * α ^ 47 * (17 - α) ^ 7 + 23308619653592257439475827609650039406713094584665162739531070571873085270495926103569096851348876953125 * α ^ 48 * (17 - α) ^ 6 + 4309056167008746262541403431206719244122955714616670864926279020311783589907259065312067031860351562500 * α ^ 49 * (17 - α) ^ 5 + 614552339408580729666564781265917271485257491177590074251947797114305883650016905691361427307128906250 * α ^ 50 * (17 - α) ^ 4 + 63623700305983189824220164500388274837272339260459679341376353550049617549841760780096054077148437500 * α ^ 51 * (17 - α) ^ 3 + 4296576620263370001927713368254137045425780398934810417013483195008307979207405258715152740478515625 * α ^ 52 * (17 - α) ^ 2 + 149430873582062166621125852273186331577668585046621031080994039368115021643902842998504638671875000 * α ^ 53 * (17 - α) ^ 1 + 947247377954257591039710592438900578151634152117436911287820530796278073275661468505859375000000 * α ^ 54 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `56 ≤ n ≤ 58`.** -/ -theorem finite_range {n : ℕ} (h0 : 56 ≤ n) (h1 : n ≤ 58) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (58 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (58 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 55) + 1 / (4 * 55 * (3 + α)) - + (1 - 2 * α / 57) ^ 2 * 58 * 57 * (58 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 55 * (3 + α)) ^ 26)) - = 1 - (4006776526237583458791916745921571399903640427998587971001863479614257812500 + 36193299233577005092404435186325555880909575118523570487124919891357421875000 * α + 157404458430456801566314898531435489082055275896144801637965440750122070312500 * α ^ 2 + 438789302805190644765999692456086768304410010456706455086051940917968750000000 * α ^ 3 + 880644388246065999407804638303739222032368746089754793927588987350463867187500 * α ^ 4 + 1354948378632315916086740220782422392456213284262767321014325168609619140625000 * α ^ 5 + 1661602897691580734737365439849633466188200353673006461916168213272094726562500 * α ^ 6 + 1667045608015110082374111106109377028467549691711516663117268814086914062500000 * α ^ 7 + 1393634964581423479006807950372755382512403362475605339704530439338684082031250 * α ^ 8 + 983739476273137944395322828805928193025534886625965973020494254135131835937500 * α ^ 9 + 592005671863910309809560316101676243798968926448970748675875927594299316406250 * α ^ 10 + 305845520279728243480763379048878002620628430303914474045381805538574218750000 * α ^ 11 + 136301035857816688759209743042609079523363637041425866478473082778930664062500 * α ^ 12 + 52557215535889563135879554015106695279244905727351138276424395612451171875000 * α ^ 13 + 17560188550728447991878218358662068709211261557084724400278409291245117187500 * α ^ 14 + 5083558311018366382022659794526798695920221466826180257750759952604687500000 * α ^ 15 + 1273131764429501958625291301675693164238362230486966503823878444190878906250 * α ^ 16 + 274960492120840016369195438376101201319262210714934208739555078202929687500 * α ^ 17 + 50954380823074628723812132018848659015398414173106367885877485025457031250 * α ^ 18 + 8043619315575642311782000673332751078848207374194599271764060475643750000 * α ^ 19 + 1070647032300550686760844315611512648892236354901418090931769834405593750 * α ^ 20 + 118447064950886641697648118438020073800095586622991278431631099619912500 * α ^ 21 + 10665844034582511896384387237050410144703560308738822660894704597031250 * α ^ 22 + 756055215489708905909989210679280265318059125676239214550223981550000 * α ^ 23 + 39319509582765585318317434167304155450155442605644113789923547061875 * α ^ 24 + 867126925428575278846841639739898919922847699797676292404824708330 * α ^ 25 - 1342664334700830923321502819993530701259788051847367543772214665281 * α ^ 26 + 39483777041359676646803092797859249221387704496311861748873113400 * α ^ 27 - 58711046556251894173073392026014465411610439743591823421605392 * α ^ 28 + 2490932168525853073760934875391654922167755426092527716004768 * α ^ 29 + 299316943768298507774611885828874444092265356390330098080400 * α ^ 30 + 15336692487146884782753132557947737242171025616954771587840 * α ^ 31 + 493116066063688255278336127843281464063956961803863360000 * α ^ 32 + 8923910394517508916121212299646048703215085675738298880 * α ^ 33 - 42485806368509927498334028885467492467879729762661120 * α ^ 34 - 9926741056642548036510544310918633673463407651072000 * α ^ 35 - 427541739200753198037475741948767076883193745367040 * α ^ 36 - 12336686560635193418143284676363319056265591808000 * α ^ 37 - 276403480622187214471125457231894057984922849280 * α ^ 38 - 5061460700774592700650136059515237541978439680 * α ^ 39 - 77589542792718274978754693243996574602035200 * α ^ 40 - 1008285668556426930549466452256224957562880 * α ^ 41 - 11180151867078112441929755167105458176000 * α ^ 42 - 106057325448908908308826107393838940160 * α ^ 43 - 860453519636632559264422458435829760 * α ^ 44 - 5953015798094365467380006676070400 * α ^ 45 - 34925450531279060313143566663680 * α ^ 46 - 172262764126427765287157760000 * α ^ 47 - 705448234661772873443573760 * α ^ 48 - 2356408942484969918300160 * α ^ 49 - 6257674902168236195840 * α ^ 50 - 12711757957239406592 * α ^ 51 - 18555990127411200 * α ^ 52 - 17333951135744 * α ^ 53 - 7784628224 * α ^ 54) / (720871145576788208016023138432681714844933807849884033203125000 * (3 + α) ^ 27) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 56) (n₁ := 58) (k := 26) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B56_58 - -end Sendov diff --git a/Sendov/FiniteRange/Degree58_60.lean b/Sendov/FiniteRange/Degree58_60.lean deleted file mode 100644 index b013b57..0000000 --- a/Sendov/FiniteRange/Degree58_60.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 58 to 60 - -`Sendov.R_le_batch` bounds every `R n α` for `58 ≤ n ≤ 60` by the elementary part and -moment at `n₀ = 58` together with the prefactor at `n₁ = 60`, so one moment and one -certificate serve all 3 degrees. The certificate has degree 56, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B58_60 - -lemma M_lo : M 58 = 57 := by norm_num [M] - -lemma M_hi : M 60 = 59 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 58 α = 1 - 2 * α / 57 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 60 α = 1 - 2 * α / 59 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 58 α = (342 + 51 * α - 2 * α ^ 2) / (114 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 58 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 164249358725037825439200 - -def betac : ℤ := 497961355142175787394055334183297030382724393469126411780705173462993215823282755131920085007900326512662937601 - -def tauc : ℤ := 448471087572926723063669239876154206304619326201258593972780358611690598231927778112087781385106362944742929814815358088655281472791766675192380386578197713402717438399489502342550615644431202381272448030834420719948436273455150272287176011549551487398208701469365221019172843556529599314294873676021662580517915072502849548535105480152501184157320292513150467618543681878443916739002320043731921024675936470734552816037996461919857428111661931630904509395053007900278594620144138547990044567751873678931975564730984448664554213173814306089347670298587914509453327032254441408889254545559958654557027862809780990814783784604565641478260475653119799986239044883966164615150983511246546984813225439648431602914838936809412661076854773429789561395258131639101434165235556498876099996030690538250276150056636678339921943870207163465591423904239157838298162240501462910163956816998225448107594669137255159521847437650494328770454089569946248568105227288923352896379674503981148310070999248598764647332421430609613476202780332450053666193093701181305308525830764021058400238423613953164565090362691246517800430518193492880391583783165229383030756105262275949980993904541715683704461104116141115330922286476243249884642113824064082605547499298030364643325697059083063842036318235023679445046032797356403690742589988234144648363788111380889467510683280209240316017419331826434565709165532557116138585658788273236867308068842587303268823441928301508368635941263673514225884232299041762676465826266885518625829931676784706926777584815215688813249606067503640500144023511966016112654977860797966031500910762602061597615510435884866193877476009999702727313296261809313130471092242046827232428200621916799122464144036407571433628245214589867475950163637350116267893882672606506062673034467345895002396522735300286755870225519012389201073521661420384347353588021361214308921824284156053765791356986585375828743736022367239635325813223714331247632052084519992744097361692147518401364242526891487246598416461484011588552441112126309888030632390118866455513932557712476920977248447849187807109857761995832579849498469003962104381113023725399598599751221371749484735829266858120900402091065925446747222692697728216949722257172390018839079567458734864502684456458145073113679544495399663757524363092046694068125364849274221683446333110738388627451029525269393079161451159834775899304412164051771976937033145396872511834837309390351210731077132444246602728620695805592231299983721057940024348109790711549441405099813012353485528424688571905333358946872625067161462184252237166136504168210583461996664212789399812878933047033876345776517246227891253066553229817264310002730952428022569216997964937286073346746466277367290072514198445981632112330900519518006310497326933957920831048356567406270461937647828080755465246423298993250003033556548650510563007650531146869382607460164146977499198878959888850317352627240693031518480686051502193939403605794140725527665005355475041852079690936056190711468370864879436865757122733435408128460559417923801625465365684760023575847444595229708181666610505319472313782469454545810754633162607956006257118231993844816169738765417358203956201835092930240838380151171056096616571277804718859544167584618828786036349012269256616069163908711214864988402504103720972387451484324738945653647274984448888409405422907673601356064185032582210172109541619351156591899153568766340896413215257411879209011469324398677631239333950063211889192504972476761596029812348493229424778430911246646757150661477346852923914343796233522734554786635980943289478667773890612446591078003777661935118834398710009536121907454807977365791249301910660294113444774868430254146802793683380460241434116786813401331912386569499402320362912265879574851392555801209510357348295773710625508625489108879798745670744925117302403085752161710130507562447278192325239806024674001396078756370632897850127016895129585422678700904491830654579000007290427674236780739610891244190000397440806855732198345007033169597806442696182488778128438130155668901420070628545538643568903061749822770610628574651180038292137139304780702688997910692846050494727963196512331254482268866992091428212494458160961622232398007042929042130055439378581682391823375640365384864965244729146070466179599872675575521210399040135676880224898608734735375914828562965866947321182796765345324936002001477319279168010454649525538435280633349577341835865534858824294324223564423709990084643145052030192424102407925094786711632107517708755857377779780556069242968082908337742367943150450156574808917753460290676459741469011587902531380152627120931683760309323832036691401827949435539168161500249695711486139283227760103018893265199752896586200862345525102407523886567105036152638203700595821029472609140583075532164174418286366702832037752016557003090206898679756146951552727665716139365098687356529177480901178577103160642727396877642623982397335958810249988056490602978067673282917134369948818607274412236878630848765681781874806835815381046020016759907736845553003925857240061932681408240948866273423038966007332428962971380643311609020954357886357433721932514051961594136050212058953206644805859062766379796315753909776649377714824572980062786652038594000477294052540430354061341716383343467955113315934376566432271098985621423048638615498660378896804460299780751987012961725457554249550941196699843513860457213109427890395018326955224200838804681133702045534572885509841628689493005986278635525684632064422880649016526052953381767332399225124354773132407729882815047668832527498753106496696249687478573289850669048933107513516281643802255932019834860660652575642928540905801343802515837388583932872595449330121856871933362303613659306078315980534837390800894847025582562426780860833567868271314616953593269346475220765744477085820777407442361547889433386402777255508622616174756724776021959594533934726902215622317335188481775162253253376606043915174117154069795258441512648078276467356007630390311227679429894181414132154096355602512578932128304322286633914821662476725450353686768977945087450285121601493208791275572673488462111597041368720987968308191179361264100894481904176813019541425764275325646362121805992774996530966951365730611489894232820505468386512029330139794596683736248802323503142145941816939837488771791949637090944032947058993806758675809819110233987410451987652021418877814769064285802811615412250516255967699104795818727844384217347025992908438653251191419324894950238874762163785665881822095737609434483837721362254585658830239557565062694580342843519944648472286957355485494324751646824011234199758579802179271075927308256104709448596774289083160380503608132766618312724942924711881115057946441493063365409634956673552176703056214922345237631174237694663986427936528855359582210955745258226297321957073921513386031168785411024222553538484146770946366988880735004655697605821525648654084086477565825669585135780251966687240656983124447379981405475910926501051822141019554194646949737370986415111962432915150661296128992920364162375278674794592336674922030396342752124815579203339456554732692151841618686939412762859705523717152167696953819923045282597899194502457239548513078174403028350673300952623616960610411693105340585232983146184713572034379656249258965863935994375887460028245126598727047421189455593209948763944707640687144749573597969719390625937492307641860995659373979991655417384581682402496044413682929551535139895863446115892408762048804875999191549003886851385964438662855385943851846918649164979476504781017827581184709227829154254337669706179754230971408427433727479533288015401174288781003594795896029044792209875334291101638340616793235570897513405827036870747777491444937752059496441860289289779756437367742227683577306973507266217484404063353459800108326164537346756912522296303522812441584525761990517039653380800248349761391011274776808123460826973480970122387666486512432246483804276679068291060400434668588580430609043211455899314349425647669358483089790469056682165578025590768977028380193294424719940470369000172744906734205783382907058512898608923529844082362064982180567318594211635145350412491599426207337582109745666981152592600184475767100813773091585529442651103008621115454250853462200144168741780188973068647323271325608354410365457721249804614924757873198127173282963796352806474310265032024127028400335807912010041103110126383312108622154114947475875613649293178271903777575666853660199457819757496628932453783513500590694073993597888943781307947816541805377793485601438326967858419216392222406520939546610843094411011262938268298976281250740001757269405737948324589642467751162768897782997238401287657016493291554562298893898140819327653547596706536363577959799647169425815612891269572909580808127091697113597053559918236727322267623639277811963424807013462492030495802572854093018110812291613600969540847452951900978893957795742632060490076867951229189701984572367913880846794709552840161975660737440113463838266640964849296197941225146490497206559460299899558514254903411236575198654250769649689533407135776131680615322087419748313923142296141072017889740450322009563890492278945395344304765286106670809581764993646056337330780278040336210133140094408435171329 - -/-- The moment numerator at `n₀ = 58`, `k = 27`. -/ -def Nmomc : List ℤ := - [25380853994369450022535770070426655654761373734262887847653813209619157899623813611520, 248725647965345106890821407790460490122214653890384903915852744147889827745237670297600, 1176686653480301704338618601355110387788283936517731294345360886156934402361668088627200, 3578624600586383194803660758397135401787509307784979535869146706308507746972368382197760, 7860497614322219586170068092961539492442334407185885596252977622799897948719473596825600, 13281855354764644366975952716413762238191227126495537897084170454493208570721797920522240, 17955207507602885341341883599778040700461918122888114771369557678902521989164994605875200, 19940941331493180176699089055325034607720335860774032351483805222051948869997196581273600, 18538998515914292550179419501118252695614262530264276784079507625027907259054211748331520, 14628273280420438705635827039061124440156442249826061889792986054372581019858654304665600, 9897592640350601729279749091948297608739647271018619419414474838038035785713001462497280, 5786930839786714330511758627771047682329742501368400480352570655126076736915491101081600, 2940706360291275464582157162944921429613146136831189573986099670846639472193212671590400, 1304266116341787409149893211161815801908712279743604368688973741460074819310750573527040, 506363687381203865486869892476892345560294052913246187239607513430244375060904987852800, 172401539827088048024651668238368191577520022578196864398501937484621350802075806597120, 51522552611252725893840114211793820196531816132593452928347673143268659800924225536000, 13516900084182274881519752027458288772401501155897817070306306024407939551177631334400, 3111245100795438057556060404484431755699023468585308591709912817067969204586083778560, 627633370128918892890965373184526625880544771157522641968543896122978469806289715200, 110823438872743816840489016008120268191523839398371983097663171239646710781265838080, 17110341487494451250793983652304441024488795632096102525461434911396002751997542400, 2310085945052642172765629748187946560829429166235545589888010250986916467127091200, 273559821597127538190548517509160623740538768961509253183546238888486970106839040, 28711293429325901578297414113499001460597893367470110122730651325498720570572800, 2769732669876388164961799900582989243743860224852055055754138048498381640171520, 309221109414926951033648007756815357604088588555237348580882736031542647193600, 243546855277802008290615817784313391353420683710722731930845806093055662489600, 10003682164598465070007434190912337434461448575973429139105601433677814824960, 408996721075433859179768200713232184347646963326340180720678969638335283200, 16021501239581601665519202723452066245408712523564084158920902697140879360, 580299978017523881858747602388165867854484924972029264345724034534604800, 18952305426231436421215804189551978170487335420083548889780794163200000, 550001785887837601624613301791455270250699067448460338604623873966080, 14078758551362061196937135537295818968688407264711786776006701875200, 316901767072019861836753229580825226875485792157679455391375687680, 6266977913251607995274705043330749008749777784129309671791001600, 108888140159549563333168154256951246657088401771573065180774400, 1662613258742966969174992896902806948128048564410693965578240, 22309323213380367941847607747617517602409705252373240217600, 262931856741648539978854857643819523900708930775039344640, 2718552181131665719468340837810303499561214680445747200, 24607865609256444274142496166932636663067987201228800, 194405946707911331240938411751093259011535635742720, 1334637045376305713493110632227004198454034432000, 7915718736912512456522345708150062809392087040, 40244469505251981085850971499899097658163200, 173589018384062857270854714512523028070400, 626525168659712258467802406879724830720, 1856857574898200210102314210846310400, 4400792791599485490657964767313920, 8019351639172792792679605862400, 10548765128140929715352371200, 8915600812135881124085760, 3635755979176201420800] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 58) (gg1 58) (gg2 58) 27)) α := by - refine pev_moment_eq_of_packed_bounds 58 27 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 58 α t ^ 27) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 58 * (3 + α)) ^ 27) := - integral_moment_packed 58 27 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-56 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 56 * P α` is a positive combination of `αʲ (17-α)^(56-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 1180273288616099684023784650402498199886255444730023274978571199510266513047596 + 11055102824011442029948266567510506642575381276841013106178383140649638883273740 * α + 49922645194024990734283616516471280600334184364447547102243551298880869797559488 * α ^ 2 + 144719942608174873104026182095524650959577750970144395839719569131273169856379216 * α ^ 3 + 302526482246635225757578631533959631447003848728875689601323895427543714021299068 * α ^ 4 + 485662255765025402514981086091947264736043236799566038683821482401809082117981716 * α ^ 5 + 622606333409943749753890815208648354755606137297243000849237534232491249017638372 * α ^ 6 + 654352069860427639900751348035281558837881303628117455206054590616141095225034932 * α ^ 7 + 574357399231416827070511854689853503943460240353865007966655407656850680547039034 * α ^ 8 + 426752571345870223801790426727818388140106457832728071034614633845667453226768626 * α ^ 9 + 271079935317622563319456334579591661701883897872193010593643933885082711035509852 * α ^ 10 + 148286371479076003045732417755582133525685636981220867944156217604240361014274724 * α ^ 11 + 70217169066647225915394151645973808431273168363378941311910545513943342491505944 * α ^ 12 + 28882635903906998561313897779843874583553384770520360078626138405360811163881868 * α ^ 13 + 10340675254845519580917140785070160244501596661998078491888557158268998114446532 * α ^ 14 + 3224423637549642502496418645711742177932306998129835583325750859424757337666996 * α ^ 15 + 875062504101721302059576940201180260130574140021726848117119157209427049292266 * α ^ 16 + 206253961710804940753907484420744734282964403780943395544748624256594408470306 * α ^ 17 + 42070236802464351764635254679415144786913128539020355841577805021278534599952 * α ^ 18 + 7386217051829558880237703381942358818281589489452528309990518263995367432488 * α ^ 19 + 1107793613576531791057535432236447149617292886122026324465700872270457547494 * α ^ 20 + 140459087137897856469559866359157699541937133355950394902889100420287426914 * α ^ 21 + 14838359760717420231756157247609092582149974794155897343599292760550967914 * α ^ 22 + 1279004725824261809420174464624373933895777466651732360112330465852550258 * α ^ 23 + 87033426312093344876434088654180488427125423854890952784009041976465947 * α ^ 24 + 4369112665592393971521458232346790403396711247658540001242310421975335 * α ^ 25 + 97654992764826340667007297954456940399851548824989983096539223841294 * α ^ 26 - 140180336953330902099623933788922389004727627031585783295797300519590 * α ^ 27 + 4011521197356040330478113154305443808925568648433687983973999832370 * α ^ 28 - 6836116057285781356883522416064683372386240155164063320736832232 * α ^ 29 + 136155913451608763461692617832470536736112881493096843133744560 * α ^ 30 + 23084190208503516369122355362110577411004819796039225427268288 * α ^ 31 + 1272092669921250187525125636594403706428638167041905626630688 * α ^ 32 + 43743288386492835342171671864673441962710429642110919385856 * α ^ 33 + 919770851750237042763795205605716932136524848257092998144 * α ^ 34 + 3589129787637507437982773070768409846725811870537367040 * α ^ 35 - 616787227367020803961294798626057817769112354291227136 * α ^ 36 - 30943009074599150760660807547437896432729575808956416 * α ^ 37 - 952040288448666548370356300676837076289373764554752 * α ^ 38 - 22303674458304714179931228274300996373189822005248 * α ^ 39 - 424667137052011465151087643604559827985297448960 * α ^ 40 - 6764616781706422065650823730243312809557557248 * α ^ 41 - 91516551558371359215307258976568083952304128 * α ^ 42 - 1060132719651553338827644611213921972781056 * α ^ 43 - 10557532799422900249752275241549216743424 * α ^ 44 - 90481973634654084996556237361914576896 * α ^ 45 - 666432341608325016551912342849323008 * α ^ 46 - 4202788903097596849838434642034688 * α ^ 47 - 22554190076903951857505928216576 * α ^ 48 - 102065451905712762371350462464 * α ^ 49 - 384517782188687390618419200 * α ^ 50 - 1184406710041525201403904 * α ^ 51 - 2906644614364092432384 * α ^ 52 - 5467069217104723968 * α ^ 53 - 7402337748385792 * α ^ 54 - 6424197332992 * α ^ 55 - 2684354560 * α ^ 56 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 56 * (1180273288616099684023784650402498199886255444730023274978571199510266513047596 + 11055102824011442029948266567510506642575381276841013106178383140649638883273740 * α + 49922645194024990734283616516471280600334184364447547102243551298880869797559488 * α ^ 2 + 144719942608174873104026182095524650959577750970144395839719569131273169856379216 * α ^ 3 + 302526482246635225757578631533959631447003848728875689601323895427543714021299068 * α ^ 4 + 485662255765025402514981086091947264736043236799566038683821482401809082117981716 * α ^ 5 + 622606333409943749753890815208648354755606137297243000849237534232491249017638372 * α ^ 6 + 654352069860427639900751348035281558837881303628117455206054590616141095225034932 * α ^ 7 + 574357399231416827070511854689853503943460240353865007966655407656850680547039034 * α ^ 8 + 426752571345870223801790426727818388140106457832728071034614633845667453226768626 * α ^ 9 + 271079935317622563319456334579591661701883897872193010593643933885082711035509852 * α ^ 10 + 148286371479076003045732417755582133525685636981220867944156217604240361014274724 * α ^ 11 + 70217169066647225915394151645973808431273168363378941311910545513943342491505944 * α ^ 12 + 28882635903906998561313897779843874583553384770520360078626138405360811163881868 * α ^ 13 + 10340675254845519580917140785070160244501596661998078491888557158268998114446532 * α ^ 14 + 3224423637549642502496418645711742177932306998129835583325750859424757337666996 * α ^ 15 + 875062504101721302059576940201180260130574140021726848117119157209427049292266 * α ^ 16 + 206253961710804940753907484420744734282964403780943395544748624256594408470306 * α ^ 17 + 42070236802464351764635254679415144786913128539020355841577805021278534599952 * α ^ 18 + 7386217051829558880237703381942358818281589489452528309990518263995367432488 * α ^ 19 + 1107793613576531791057535432236447149617292886122026324465700872270457547494 * α ^ 20 + 140459087137897856469559866359157699541937133355950394902889100420287426914 * α ^ 21 + 14838359760717420231756157247609092582149974794155897343599292760550967914 * α ^ 22 + 1279004725824261809420174464624373933895777466651732360112330465852550258 * α ^ 23 + 87033426312093344876434088654180488427125423854890952784009041976465947 * α ^ 24 + 4369112665592393971521458232346790403396711247658540001242310421975335 * α ^ 25 + 97654992764826340667007297954456940399851548824989983096539223841294 * α ^ 26 - 140180336953330902099623933788922389004727627031585783295797300519590 * α ^ 27 + 4011521197356040330478113154305443808925568648433687983973999832370 * α ^ 28 - 6836116057285781356883522416064683372386240155164063320736832232 * α ^ 29 + 136155913451608763461692617832470536736112881493096843133744560 * α ^ 30 + 23084190208503516369122355362110577411004819796039225427268288 * α ^ 31 + 1272092669921250187525125636594403706428638167041905626630688 * α ^ 32 + 43743288386492835342171671864673441962710429642110919385856 * α ^ 33 + 919770851750237042763795205605716932136524848257092998144 * α ^ 34 + 3589129787637507437982773070768409846725811870537367040 * α ^ 35 - 616787227367020803961294798626057817769112354291227136 * α ^ 36 - 30943009074599150760660807547437896432729575808956416 * α ^ 37 - 952040288448666548370356300676837076289373764554752 * α ^ 38 - 22303674458304714179931228274300996373189822005248 * α ^ 39 - 424667137052011465151087643604559827985297448960 * α ^ 40 - 6764616781706422065650823730243312809557557248 * α ^ 41 - 91516551558371359215307258976568083952304128 * α ^ 42 - 1060132719651553338827644611213921972781056 * α ^ 43 - 10557532799422900249752275241549216743424 * α ^ 44 - 90481973634654084996556237361914576896 * α ^ 45 - 666432341608325016551912342849323008 * α ^ 46 - 4202788903097596849838434642034688 * α ^ 47 - 22554190076903951857505928216576 * α ^ 48 - 102065451905712762371350462464 * α ^ 49 - 384517782188687390618419200 * α ^ 50 - 1184406710041525201403904 * α ^ 51 - 2906644614364092432384 * α ^ 52 - 5467069217104723968 * α ^ 53 - 7402337748385792 * α ^ 54 - 6424197332992 * α ^ 55 - 2684354560 * α ^ 56) = 1180273288616099684023784650402498199886255444730023274978571199510266513047596 * (17 - α) ^ 56 + 254032052170696096814452472070218512117411786611178526203832500563618785746318956 * α ^ 1 * (17 - α) ^ 55 + 26581786465992714133606222775502371032129394160055924210292174209129794157448936772 * α ^ 2 * (17 - α) ^ 54 + 1801905125284524294246494051997323405505883272969655457886034380748404658915029385356 * α ^ 3 * (17 - α) ^ 53 + 88960777843487839207354469588977939024483934333485516580514560192823003078437474637384 * α ^ 4 * (17 - α) ^ 52 + 3409710295444689753751021773779609449447011909852801588651071013422638895502085385574456 * α ^ 5 * (17 - α) ^ 51 + 105611745061099871040994619483246321125469657724218486870230193879528974892413607636605284 * α ^ 6 * (17 - α) ^ 50 + 2717077493210926098447489650385141874390859518222133351745212828060950258218810177908282556 * α ^ 7 * (17 - α) ^ 49 + 59226539189538299382222748715390123146365770386986878118026762708622792734361308033174370018 * α ^ 8 * (17 - α) ^ 48 + 1110347623085275380732784124563019672170207376288907445733220470280957735947728184470496756010 * α ^ 9 * (17 - α) ^ 47 + 18112519692658810410404967374345439836251270145825076491663143586046571832030458464477826206258 * α ^ 10 * (17 - α) ^ 46 + 259468406097457687929633525944011735968016319542087733822510053479299676655957583926253741360502 * α ^ 11 * (17 - α) ^ 45 + 3288616364869040104475987141993494253571602787363843112397732704776764511075222653495077733735718 * α ^ 12 * (17 - α) ^ 44 + 37103473125865952584340786773431223496072304382597727768926156417429611089103427290200640921026334 * α ^ 13 * (17 - α) ^ 43 + 374523382812426223233967303671275687297451096894379697013331090967253251615175373801177901144258730 * α ^ 14 * (17 - α) ^ 42 + 3396494550442924093336698525515677714454583693723746546679078674756021148647562726100992633195827670 * α ^ 15 * (17 - α) ^ 41 + 27771451470570936428940278209636484839068297258115446941354573210378654498093153647787388326291195220 * α ^ 16 * (17 - α) ^ 40 + 205336433200531842769564752332775005425876161312494024088869532088213815964669131170023033890476305980 * α ^ 17 * (17 - α) ^ 39 + 1376302917197732669050568166563895672822852883204651206746822345275035657680019417369627527115086850120 * α ^ 18 * (17 - α) ^ 38 + 8380155294397784796024596289754563707905478379672589828457151616147990659832389424273341383748688207080 * α ^ 19 * (17 - α) ^ 37 + 46434805880795731321224499533392807251809590691101718819109701496201837794500680135302573321020690890746 * α ^ 20 * (17 - α) ^ 36 + 234491333325177991679288999498604121924586729800797548175219657080832899570210449706339657838128968884354 * α ^ 21 * (17 - α) ^ 35 + 1080514930086925704280859540483502286254671084929525637672420222697615347555423346347115532203110643365136 * α ^ 22 * (17 - α) ^ 34 + 4547675284413232416488077752788320517949654297288884032643195010720956134703008952100555630475629759787488 * α ^ 23 * (17 - α) ^ 33 + 17496546097098586152071398152312222042613115074033174731514387311101666529876250406780911401607973057493255 * α ^ 24 * (17 - α) ^ 32 + 61573424970057153431741932997114452252230749510452379581517661469288846340022317444210252355996069897749331 * α ^ 25 * (17 - α) ^ 31 + 198297654024175037814903698649403184988215012123240470670091291048259056629782551733808484416396638864067091 * α ^ 26 * (17 - α) ^ 30 + 584610302749161753333489816331275650573703865862791211866486561498961706693997631039254643972613296017180617 * α ^ 27 * (17 - α) ^ 29 + 1578046905956627892814531753544431465414315118110738633436435926556242944082783767807930560452112935615842171 * α ^ 28 * (17 - α) ^ 28 + 3900276267502012608001991748970773203576515687854492513578111746545720357741690474840268134056865690598209279 * α ^ 29 * (17 - α) ^ 27 + 8825565680944180807206852648457428249507576570214954247410910715730515927908602962682166825659628608449565179 * α ^ 30 * (17 - α) ^ 26 + 18278222890683728517844209588507295086668349633646134150369498537778483167121641476779372484086759659269711781 * α ^ 31 * (17 - α) ^ 25 + 34630021303309994264801974849783975057715767549012563612835970835153541351334334084636838049899704411229419039 * α ^ 32 * (17 - α) ^ 24 + 59976325403926759553950096138547851891588162346459693279652757133352417289699475136155912596938565990681022967 * α ^ 33 * (17 - α) ^ 23 + 94859908857514726802312972207926527679144706496572092127703134483420755663937004295941931559564856864612372015 * α ^ 34 * (17 - α) ^ 22 + 136838029261198215465308944618229439296028860400759258689603958243702943063871561985963901374611376885862608933 * α ^ 35 * (17 - α) ^ 21 + 179750481304348065934713749450324777683615725218792657415497203296024872885988657067853702018371602813684069687 * α ^ 36 * (17 - α) ^ 20 + 214614205815431393733148792819846945536633335373334115752048809273342647443432539934607000062616305939408924323 * α ^ 37 * (17 - α) ^ 19 + 232391950882130480511841466255675296149805103394932221634682309682031574184073376765275830067134447105269029319 * α ^ 38 * (17 - α) ^ 18 + 227646786129095617123180754743680811362220841807439017659139374884333921571156246794142321243097055097178445825 * α ^ 39 * (17 - α) ^ 17 + 201151592000254076319111933803082921016858033652344635301102367059012097196101762301692963719714653038174763855 * α ^ 40 * (17 - α) ^ 16 + 159796714515585050308711763046365954383154641733651622252372673160438440025715520354135554841621456682694603135 * α ^ 41 * (17 - α) ^ 15 + 113694441321074008752288203116701595054184371599569875421293420056220499034682316015196771177249973056572181735 * α ^ 42 * (17 - α) ^ 14 + 72130500744694542887028943813151106507208801012210269142093276885199604435222351545247283246975115560376609205 * α ^ 43 * (17 - α) ^ 13 + 40593915959417627531746494374957888051425398581583793505319726935377556193558075899850407121984115730929357755 * α ^ 44 * (17 - α) ^ 12 + 20142112914146928990742750521398817973806574189219001955193033477789707030767693751116805380225357379276747519 * α ^ 45 * (17 - α) ^ 11 + 8746984555426014571216178944742661168209625273320645227018468690933303880145359024731425263277253405247586951 * α ^ 46 * (17 - α) ^ 10 + 3294813943512375946477459661112271578543735031048904613485581394105299356535226701518930871689765592849920009 * α ^ 47 * (17 - α) ^ 9 + 1064633594182767781418524670877965310710625221215403900701843563201440674916875929401734783421144317918768437 * α ^ 48 * (17 - α) ^ 8 + 290979947292633634820286085206318086271058595522743900697255282277868275830483412118913673100403134596829605 * α ^ 49 * (17 - α) ^ 7 + 66053632008286815218730609011172165768275118555864770965140596782012442105314066073321580207922244489207001 * α ^ 50 * (17 - α) ^ 6 + 12152795314691969352387359587094653935442718022653966020106284283370382118838609048927994949757671991794739 * α ^ 51 * (17 - α) ^ 5 + 1751156608268941082844684121012320147103407396012602177215161083358650243742317419805210038235339659097451 * α ^ 52 * (17 - α) ^ 4 + 187813139479594914512845605964389800598941841721249536400462885091353372097871422654926648798226033258823 * α ^ 53 * (17 - α) ^ 3 + 13802072582465965788484953766306541577986163631972344323322049452623866943671442557170586787638780254425 * α ^ 54 * (17 - α) ^ 2 + 594982734136165220266045344041112246141469375919551772765097596644107694713723809345475527250815129375 * α ^ 55 * (17 - α) ^ 1 + 10211558413705494402424769335540267701249567140173495481288972120637089282914579657148619242232312500 * α ^ 56 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `58 ≤ n ≤ 60`.** -/ -theorem finite_range {n : ℕ} (h0 : 58 ≤ n) (h1 : n ≤ 60) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (60 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (60 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 57) + 1 / (4 * 57 * (3 + α)) - + (1 - 2 * α / 59) ^ 2 * 60 * 59 * (60 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 57 * (3 + α)) ^ 27)) - = 1 - (1180273288616099684023784650402498199886255444730023274978571199510266513047596 + 11055102824011442029948266567510506642575381276841013106178383140649638883273740 * α + 49922645194024990734283616516471280600334184364447547102243551298880869797559488 * α ^ 2 + 144719942608174873104026182095524650959577750970144395839719569131273169856379216 * α ^ 3 + 302526482246635225757578631533959631447003848728875689601323895427543714021299068 * α ^ 4 + 485662255765025402514981086091947264736043236799566038683821482401809082117981716 * α ^ 5 + 622606333409943749753890815208648354755606137297243000849237534232491249017638372 * α ^ 6 + 654352069860427639900751348035281558837881303628117455206054590616141095225034932 * α ^ 7 + 574357399231416827070511854689853503943460240353865007966655407656850680547039034 * α ^ 8 + 426752571345870223801790426727818388140106457832728071034614633845667453226768626 * α ^ 9 + 271079935317622563319456334579591661701883897872193010593643933885082711035509852 * α ^ 10 + 148286371479076003045732417755582133525685636981220867944156217604240361014274724 * α ^ 11 + 70217169066647225915394151645973808431273168363378941311910545513943342491505944 * α ^ 12 + 28882635903906998561313897779843874583553384770520360078626138405360811163881868 * α ^ 13 + 10340675254845519580917140785070160244501596661998078491888557158268998114446532 * α ^ 14 + 3224423637549642502496418645711742177932306998129835583325750859424757337666996 * α ^ 15 + 875062504101721302059576940201180260130574140021726848117119157209427049292266 * α ^ 16 + 206253961710804940753907484420744734282964403780943395544748624256594408470306 * α ^ 17 + 42070236802464351764635254679415144786913128539020355841577805021278534599952 * α ^ 18 + 7386217051829558880237703381942358818281589489452528309990518263995367432488 * α ^ 19 + 1107793613576531791057535432236447149617292886122026324465700872270457547494 * α ^ 20 + 140459087137897856469559866359157699541937133355950394902889100420287426914 * α ^ 21 + 14838359760717420231756157247609092582149974794155897343599292760550967914 * α ^ 22 + 1279004725824261809420174464624373933895777466651732360112330465852550258 * α ^ 23 + 87033426312093344876434088654180488427125423854890952784009041976465947 * α ^ 24 + 4369112665592393971521458232346790403396711247658540001242310421975335 * α ^ 25 + 97654992764826340667007297954456940399851548824989983096539223841294 * α ^ 26 - 140180336953330902099623933788922389004727627031585783295797300519590 * α ^ 27 + 4011521197356040330478113154305443808925568648433687983973999832370 * α ^ 28 - 6836116057285781356883522416064683372386240155164063320736832232 * α ^ 29 + 136155913451608763461692617832470536736112881493096843133744560 * α ^ 30 + 23084190208503516369122355362110577411004819796039225427268288 * α ^ 31 + 1272092669921250187525125636594403706428638167041905626630688 * α ^ 32 + 43743288386492835342171671864673441962710429642110919385856 * α ^ 33 + 919770851750237042763795205605716932136524848257092998144 * α ^ 34 + 3589129787637507437982773070768409846725811870537367040 * α ^ 35 - 616787227367020803961294798626057817769112354291227136 * α ^ 36 - 30943009074599150760660807547437896432729575808956416 * α ^ 37 - 952040288448666548370356300676837076289373764554752 * α ^ 38 - 22303674458304714179931228274300996373189822005248 * α ^ 39 - 424667137052011465151087643604559827985297448960 * α ^ 40 - 6764616781706422065650823730243312809557557248 * α ^ 41 - 91516551558371359215307258976568083952304128 * α ^ 42 - 1060132719651553338827644611213921972781056 * α ^ 43 - 10557532799422900249752275241549216743424 * α ^ 44 - 90481973634654084996556237361914576896 * α ^ 45 - 666432341608325016551912342849323008 * α ^ 46 - 4202788903097596849838434642034688 * α ^ 47 - 22554190076903951857505928216576 * α ^ 48 - 102065451905712762371350462464 * α ^ 49 - 384517782188687390618419200 * α ^ 50 - 1184406710041525201403904 * α ^ 51 - 2906644614364092432384 * α ^ 52 - 5467069217104723968 * α ^ 53 - 7402337748385792 * α ^ 54 - 6424197332992 * α ^ 55 - 2684354560 * α ^ 56) / (70705400725025142717653694431177969790740772523753364892596242608 * (3 + α) ^ 28) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 58) (n₁ := 60) (k := 27) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B58_60 - -end Sendov diff --git a/Sendov/FiniteRange/Degree6.lean b/Sendov/FiniteRange/Degree6.lean deleted file mode 100644 index f1287fc..0000000 --- a/Sendov/FiniteRange/Degree6.lean +++ /dev/null @@ -1,85 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.Common.Basic -import Sendov.FiniteRange.Moments - -/-! -# The finite-range claim in degree six - -The first even degree, and the prototype for the general even-degree argument: the exponent -`(n - 4) / 2` is the natural number `1`, so `Sendov.R 6 α` is an explicit rational function -of `α` and the claim reduces to positivity of a quartic. - -Concretely, with `M 6 = 5`, `A 6 α = 1 - 2α/5` and `c 6 α = (30 - α - 2α²)/(10(3+α))`: - -* `∫ t in 0..1, t³ Q(t) dt = 1/4 - 2c/5 + A/6` (`Sendov.integral_six`); -* `1 - R 6 α = P α / (375 (3+α)²)` with - `P α = -24α⁴ - 342α³ + 2345α² - 900α + 1575` (`Sendov.one_sub_R_six`); -* feasibility enters only through `Sendov.alpha_le_half_M`, which gives `α ≤ 5/2`. - -`P` is positive up to `α = 4.856`, so there is ample room. The exact feasible range is -`α ≤ 2.194`, cut out by the quartic `-4α⁴ - 44α³ - 21α² + 300α ≥ 0`, but that finer -information is not needed. Note also that the hypothesis `α ≤ 17` of -`Sendov.finite_range` is unused in this degree, since feasibility already bounds `α`. --/ - -namespace Sendov - -open MeasureTheory - -variable {α : ℝ} - -lemma M_six : M 6 = 5 := by norm_num [M] - -lemma A_six (α : ℝ) : A 6 α = 1 - 2 * α / 5 := by norm_num [A, M] - -lemma c_six (α : ℝ) : c 6 α = 1 - α / 5 - α / (2 * (3 + α)) := by norm_num [c, M] - -lemma c_six' (hα : 0 ≤ α) : c 6 α = (30 - α - 2 * α ^ 2) / (10 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c_six] - field_simp - ring - -/-- In degree six the exponent `(n - 4) / 2` is `1`, so the integral is elementary. -/ -lemma integral_six (α : ℝ) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 6 α t ^ ((((6 : ℕ) : ℝ) - 4) / 2)) - = 1 / 4 - 2 * c 6 α / 5 + A 6 α / 6 := by - have hfun : (fun t : ℝ => t ^ 3 * Q 6 α t ^ ((((6 : ℕ) : ℝ) - 4) / 2)) - = fun t : ℝ => 1 * t ^ 3 + (-2 * c 6 α) * t ^ 4 + A 6 α * t ^ 5 + 0 * t ^ 6 - + 0 * t ^ 7 := by - funext t - rw [show ((((6 : ℕ) : ℝ) - 4) / 2) = 1 by norm_num, Real.rpow_one, Q] - ring - rw [hfun, integral_poly7] - ring - -/-- The cleared form of `1 - R 6 α`: the numerator is the quartic `P` and the denominator is -manifestly positive. -/ -lemma one_sub_R_six (hα : 0 ≤ α) : - 1 - R 6 α - = (-24 * α ^ 4 - 342 * α ^ 3 + 2345 * α ^ 2 - 900 * α + 1575) / (375 * (3 + α) ^ 2) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [R, integral_six, A_six, c_six, M_six] - push_cast - field_simp - ring - -/-- **The finite-range claim in degree six.** Note that no upper bound on `α` is assumed: -the feasibility constraint supplies one. -/ -theorem finite_range_six (hα : 0 ≤ α) (hfeas : c 6 α ^ 2 ≤ A 6 α) : R 6 α < 1 := by - have hle : α ≤ 3 := by - have h := alpha_le_half_M (n := 6) (by norm_num) hfeas - rw [M_six] at h - linarith - have hP : 0 < -24 * α ^ 4 - 342 * α ^ 3 + 2345 * α ^ 2 - 900 * α + 1575 := by - nlinarith only [hα, mul_nonneg (pow_nonneg hα 3) (sub_nonneg.2 hle), - mul_nonneg (pow_nonneg hα 2) (sub_nonneg.2 hle), sq_nonneg (1103 * α - 450)] - apply sub_pos.mp - rw [one_sub_R_six hα] - exact div_pos hP (by positivity) - -end Sendov diff --git a/Sendov/FiniteRange/Degree60_63.lean b/Sendov/FiniteRange/Degree60_63.lean deleted file mode 100644 index 3f97a9d..0000000 --- a/Sendov/FiniteRange/Degree60_63.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 60 to 63 - -`Sendov.R_le_batch` bounds every `R n α` for `60 ≤ n ≤ 63` by the elementary part and -moment at `n₀ = 60` together with the prefactor at `n₁ = 63`, so one moment and one -certificate serve all 4 degrees. The certificate has degree 58, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B60_63 - -lemma M_lo : M 60 = 59 := by norm_num [M] - -lemma M_hi : M 63 = 62 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 60 α = 1 - 2 * α / 59 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 63 α = 1 - 2 * α / 62 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 60 α = (354 + 53 * α - 2 * α ^ 2) / (118 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 60 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 9690712164777231700912800 - -def betac : ℤ := 131890702893372416829372378658384224849341109626978858112228574607061985481724751004366686722403664282558232369561601 - -def tauc : ℤ := 22493861898994125401138843645423111952318970959129184011773246643348972277013585420383573374777521968629082172320022548306319716190012481129994750330861049468693797522675158371543136005993782558048633997178566254500663866999695174529454471033560035745566460709533857579410294526715523490348906098822087142454230455543431117087972781711534150822393396609405515007367174771701283436713964858632679517047782421864418601886104902601674640144465520893220104508176601347144655143555044274938385331458163895284547252860995520667281770367045748870234890187664935988296927271857304542646428167719216480249719405077917194292878577361908175302850954503778668293247199043834843993518770663637750920202555082796646149274345266616270524277342909416499335515429212501551187050368290370558711359185533451152481337954073060282545294449086001420789453128983674276046225555925654463849685720528899463964567373555808499255508958018868908459864944996457106472508789905865242794652977581601979286039860446015135480883816593159203189542406181453232615067876895310461745323392992198871273516715036074125892530546284417343777046104246212261388917108108523906633635638711932488319635916929365345062457681843641504881523529483804649913614708548885297175580373033650684886355224832100209310648108665782012936612788677590421466269907634052042476279385841577564898354483874085049065001646302908693253949723093816064296095161160846986877885002935717417449149095840923025632751775799814967466076838455158022899410936108111893954156489156456996917255157214618493528545346233496824026205745947507426067642887129621205519479162839056168644388734063068929529158272927796360516146785044324344075074924707557945413288346830357671166650455739173484419545021318423250765428938562685079537855306569654629914901986879685595322328862138638392791523642114642092319810134741999504966043976823521441207437333955273823918919745617425027703682668515891237774360002531552437960196254074001022793662159556259678813317672571401386513676030623773552398316837754703438971454857126537307939587775371585303059315914737630947042727783343851901456460641704346735613143673391310488599143709039673135613873870349004660684364581665153557930694659313087374660018210589287163535856108073622848034283569163648214183115101285003369368506334085609318871330569757508455122611200628344241860879020448118499186834925988796424311748914701993204130738440714411141317137801791164903516787981383691646734747867973107407448676481960319672360581942826602107627541578944288694519117898441677750775011890912608660804199035892093571162093539647786016572946700335122189084193715032979692628761319226224050019270210911785876112137824830261419067468985784291597829791463423035574773327338111619483942266079860069643829548758618901765308691135114204828169697098791621866458953034399089486877263480106193853903501710467896606915753371270033593975323745423345789456542105121498526530726637271129918764914223868481935054695729027396645570480067225031975515899731189826855659874698393732438097796328757134723129791293788329690035871459365372956233467589800737265008535341143063409023238757557276924293987799401770782680597818174356174134260317796007400082816841282119256876654845548703743686703810465894850100790676209882123751353796298888954511673490693924839000926024436895766962709948846735051980353113397130087382568599144858150214583141165035150269330458538202700013318308700875533582593691067803419206331599581554133962517295574652637487065485966208217121878083938162542873008499356635707141745453123809203037077997784201575196902886750112578717028629117492569346282809086313156632860163031994494694213167436316167431895156570350829508143409222321179175149177864323786110686315613881904196827741152350200016687170766393330684164958860695079709461466396186344373502469466379914861497495754153589256350271223766092150106415197638944998952357572065971903888508878801380414666327004609245153109580741483747242759496009963731516063985693648944142529764105501437444636353234261544759806129078110372116007678730476086417735823033393824684464261542112691646525492498676413092986474743701166160606731577663176001709419065788914847623851019611559698682799614161519052066163818261498212508546375122040263537492198611709896050321919151428217103248271498913412042378435695148620551118205434674185648003331816684511524486326213731117285432559317463611757238462824035561865072794456115996509451699113418499419864666809568820760710348051533939279837854014205047314755097933149335873431502938802876903891212206492508246633297422387262378941228681607836546618078529161617148810038259557845726159500943451749897142849643783837813667623683691988501801915822978618025577937530607431499919751132647033072250650518370487056023002930228539279589352630767513045079012967643370859774392634613480770821712933527079815690078624031717437918192615231423132940748266250059307871224173572430964936841256559162013006999032974626576144376219098797404640028074698198704239523966329965892031931549564200329140971428707598495151332461586507663431282861385087170330362853978843644462998764809119308364493633442693192088480408989077406985994002939705594460446975109504956022370535845172176454743049792186943868243295414936098207538960063313261282527836131831267761051155938988547992845407052475480373034034818996014449360809128682545928757805195636789308804650300902177605745754505577738475502609812511065537320929032146910141130566285244297935293233041119291729696094389666304611317559593509343834208131312114871747725167894452904899377179099727586309582660373571639633324790468969161139607595515153133440657107553708390012535412277604805431215106280066279498416714453865398464082462614281479974475958760429616352323131621315795290057810196897110037243607207867193990923146577904753995549776269825357352971520784291637112868094656222108409542693866270457877799140929894091307628583237678145983085246548139174359294221682355706359088428574071679864951916247235300400944453263725915147044297276220286956274892989947552155717824550058645877014957979204265865619652606509304446493391626048923116733858879538664950854298413448312770138457754169415129611123456291283687838278094433736163094975446069142461259996491405894324029357566833803819805025094558181727377441653293231697110783902459068297344771378909493607719958523916538119082901722884659947645536319045874146472580064587196549541783125122082676247412527129640947949720371159530880280540217200400158743950768014176756499568258414188990326319917901310036328183191972908167121598990390873444627074544530731863259949507732584898093565047719987147514448359113177157374472890641509720544211484967253580531376073543782845254900200801705874041739894546309337587705785913799690206093126988178493717883830902237495191836402881095946429834326759868362465505581483386635297556703604328854818365110646299841273815451255958554947187552642046326606118764960728612819697191364777831070710861484101636324557573319471369512435801444126575332106951248871201083558233012021233156830434592943147085468547390780741347256496601477038145319827402179166709216822493305405966461605348238626849922578191674974375058735652711457458371106018714478344207569433729451797738792627394480296448884982480006024738544589847680920454836200108993278877552920477982568700757254856930272765018497083978932368899955843118215303505782883913643366172870205160058647998904274582874526397243920911618142650724149137940815724860431635639891579609118277408096142424001875343870377037212976648216743321554681610337135368573827380388493892765688955209655906032570380459551761977562209881078928119469637729621680556013996183900507497517970847864291740994155636328485837884038862719422556676962852616356725107223822635048190263044771612993014913267012041912187356285777381895338332474473663313611093087113157599842340782894247210321585307731656640686375053479851955256880173076008060267134475408443895313047794936411768045372639562139535253782018937948828001538777506781744692801561789222743497624394892820347087865545583462483443851504366760155437505464883331673797759674078109683653655174121495714574835855632828514634898125137832856937289206093682917846829157851917009824831976974556882977285770951070486539357734705634008030195560223586094244159726741071737291913921576046144230232090651759490736991223309483082663117017536443281563974163243302478814551515186472988686771044974885524139028279507907686576822909438694359665627680986955210089704493556348300198209390765560070615199000505839902991388006563322508525929765618088525757271131475788652250453888259421665468986833997653347299930905009660524894610523783972847734409703676046600097307066498385902541189893153417063518141022119435777880962404503444009931018541544685706061983505813208396076954432516199129510097802491243480470427230369432017690556894303565582799012873616418135199847326718992905518312708653375957606572907817473787996728722374807275486345957305238314018120666329673122797978442293633543380836605000033385695882847346856244559327976402066633895737058849715502817970730980593646762481946251985543296240993534416194517543557578948992476381076731274701815752330153842762548319496873018827750350609215980726310550199719213626777258784154077826963450054309143534054867199511244785252205564109623673872331249116475924597158399543643891939964248666530776232571675197946677825139823474076526563991189604013303461946493319757918584144801405586975726664563181619626471897572286014464834136398611946530412687750852626815111064147169597840194504257150952441524308094003113282946328693188903343447797662543782386469717872648399099062836953301727383215125013706334499574238531927622468358337875901175300308119140778272667365604705304782574812630700991013574058669486391223358685278096957142712649154054643379762899372674428958441385875607136568161435100120381393173640103037438501614169790027250995692805622382377395332711410828175709874375831914847599074420720115249740881486304392067422276594930176572027014479873 - -/-- The moment numerator at `n₀ = 60`, `k = 28`. -/ -def Nmomc : List ℤ := - [1170286432414455951789695637576773076251981987653082435682789023922201695661342269657579520, 11853132227638968345810373894716982569948168873404615116417359810860717739312619187286835200, 58022815731756508642689831102863982916416594069819725590102029365932899463002796209639260160, 182815567094371205658931113552441256106924151231407132489408531795201069567794618241478819840, 416560582481164515501190642053847631215351907693126034879809505342337403716742800489127608320, 731193666559325128610722600535876492176194481369442407411584955252212405620500154322989875200, 1028421134665433615302875962384422413802394377129892241452566628447959688182048517571823534080, 1190272589271964378955021737481264867891857069049881617890059909601764629171797757880518574080, 1155256052114030146807458403214966431694558644330414677974304942659972443508920716626724126720, 953479346658120665880369696571852064857018917515344141665146209579746393611463926607312322560, 676207830498922381958507595831741684682254221579363672024399374543809341355858349278332190720, 415352025805861074094000476607341548080203273214348349035994903989490102795682536447016960000, 222284586926015847763559259685204797272792996212239113649705398029786525276138304621311426560, 104107400109529363333714290166443331713617559975662767710310394176224276260428361140682096640, 42806315815453039970466175363858744023499663850690826257659218397767159047121092455453163520, 15484587130015826510620475753670434514823053868166282130612093732223312844808574197898936320, 4933632766852337568064503726306076245696782117833492612263493901480136109079371431794442240, 1385051180745515718354824683148078303485336998392291483298929805445279908278300016692428800, 342485983618483240121105564999418583124770087828935736340773282296474207933732489265152000, 74521567545772057724284314690358351312728462412242579409096818585101716758985466865254400, 14248640106860532047337206914503401765908609540977663834445507048236556089651673882951680, 2390145052266278719103705252893292885779509289408596229349539156458433537547613115514880, 351282651004339441206562719871845916823301550732945224436793792371832424658591096504320, 45224947711080341481323884551723715618989400712660075265582491332704807966543949332480, 5113599277554475008017984059592424686546264734571949444329428624752903329099588567040, 512772619174386190658034320937411210943929698445544285472252768051704930234773012480, 47224607902960616689257367771656094740370013176983083565602998263937920665565265920, 5047588645718186878806809790706355913710906302153503198241293354455609056910376960, 4110681382610715550040430216172251363061305614549492238237044955246396140515491840, 162254517327913801966574253754183021775169349075074064782800693868060768070533120, 6410035955429517302240469566936907832502642984738022902856907661394017601454080, 244703436012952439936963434842909882605185691673134240301466731498394028605440, 8715103746175843946153733020144567046580869416192743459900421830453839790080, 282080628704731770799219916882347846009860544684379124890520840491992350720, 8165135106103872947091458198644192347973620375934833037260213484844482560, 209583571930883727144773859122010269644571091557068083355213513894133760, 4752172440547349711407552507840510488474720969675300507473134013644800, 95060146879397213299428640870002805484618745923394301184350177198080, 1677319639955129774576715975414788668321403391348223837164451921920, 26112500708140543271228726514701351923739019122286985122215362560, 358725946238751992541257602569091993554726647290521421338378240, 4347748928474871198372952457611420161334541639581924589568000, 46453273127183626824441225413597533459847646068387579166720, 436891986332819582568623838217786187580556866985478062080, 3608481791692616266311876708641658544058532343987568640, 26086445581235168445312170881504253921505970099322880, 164309434846190739113766300012433387191921625006080, 896252793779203781261433397104132999540658667520, 4200013124839748839442133073942359097768673280, 16732436083963174669499692344452384544522240, 55884121364313080215033170436819915898880, 153532733129457236681936992504475811840, 337854979644729330784806813491527680, 572493539264678877330157779025920, 701253310425317667068927016960, 552631030695071494680084480, 210389079328329522216960] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 60) (gg1 60) (gg2 60) 28)) α := by - refine pev_moment_eq_of_packed_bounds 60 28 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 60 α t ^ 28) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 60 * (3 + α)) ^ 28) := - integral_moment_packed 60 28 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-58 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 58 * P α` is a positive combination of `αʲ (17-α)^(58-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 + 16985863033574280235844441932687847244474918343296922124467065830558560591641911607696 * α + 79535686565443616767714198705465441607069525916537281975943363396026310601750092892488 * α ^ 2 + 239403368066863055363036191982445140250970254028533507257869611464498452359820776516672 * α ^ 3 + 520412199687668549649368000742289832307395871986227854434049639793742028919048260538980 * α ^ 4 + 870157990458303443210342456693112304974391575125591793142671535717764222680483811054120 * α ^ 5 + 1163895406905166893909394336483096101920864956907539643884037297958617393209091960980980 * α ^ 6 + 1278712702347990314588936279615328559669420142052152673561809586945926657118282053100192 * α ^ 7 + 1175725999507118690334304481188590417967828338375807066246239349405176693210977652965164 * α ^ 8 + 917174565683194380325199349414315003531063568224297761645149376513377860921193466166360 * α ^ 9 + 613220450431269534465945368150179786921282701580434508261534043083701875736956664994572 * α ^ 10 + 354057578771667900301737961009087756507978666072508030411200442531544505558679233553472 * α ^ 11 + 177508212962690728847102755764000185519630950904902948797136565592445320434555097902358 * α ^ 12 + 77576143881435246639915934911657056385846898645191797585491387399418570120013455336412 * α ^ 13 + 29625606539961534087112448697426117322036816304400291238815402402574337305159894234710 * α ^ 14 + 9897983624006015895072166102753315050019559506815047218656308374776682178809801281072 * α ^ 15 + 2893024329186264383797233494270141942147451227576867206489337752203105179024976096612 * α ^ 16 + 738824037484601173560395482737511489082491085984005275312812825534063503137534438984 * α ^ 17 + 164441392895370259121202826289551958180582089330511860705087484253672173523954414324 * α ^ 18 + 31771089808007468337610992777240040391387210585565359776690610466850812101226150720 * α ^ 19 + 5298220195377128677201324507710581490774005592592493587530562214239637638718207838 * α ^ 20 + 756659597417575188091510844865331006747834890107597233256807850344151631080238572 * α ^ 21 + 91559608573015197712368058376578410389957871248555658418907655613710858144349974 * α ^ 22 + 9249930419338172598175237698997019936144549918443437721165100485815394918388112 * α ^ 23 + 763883913294738134810454963300633389711111356082193955572628106712061571529450 * α ^ 24 + 49887514803037691118937977551057551319824185688173200456490865107511572859188 * α ^ 25 + 2408300944763273858718491162262422770972533056902127038712768748993172577610 * α ^ 26 + 51725078185114864055621675260185352972397611437758098966549358454837797760 * α ^ 27 - 77510592929500392468407361123374953300216693743671418464304395453235289971 * α ^ 28 + 2067570494221092433188386134604931347621528152582381523034724429480663810 * α ^ 29 - 4580593295775337280722829599699027320935759304984497739306397718132427 * α ^ 30 + 167416972491317272532611766388094644865407567559322236979252017800 * α ^ 31 + 8389683035480047874686298369093744577278032988658533654716580671488 * α ^ 32 + 533168330392361738160636316662426153463437758146484284733956527840 * α ^ 33 + 20133734272551384350294239387428682262688585273913890267463998960 * α ^ 34 + 493961052258347053233401169722862536905607351132290352999275776 * α ^ 35 + 5693741143796291743936421907647419400331769333817148390864384 * α ^ 36 - 136838149185369327185106181434226275722488605188850651649536 * α ^ 37 - 10213381894013887312358741093692449757528996456249043806464 * α ^ 38 - 350916645279993747972377869550082945451923877049098721280 * α ^ 39 - 8752703600310726164117509854956335599020724135444320256 * α ^ 40 - 174795107690037567064791487247091959281487206843686912 * α ^ 41 - 2905560404482515211390475250648416164278477823340544 * α ^ 42 - 40986185232466565782519730515559353841538308898816 * α ^ 43 - 495823850271711791881581412818585367225361694720 * α ^ 44 - 5173168623120670073594814754124350179396943872 * α ^ 45 - 46665067131765629087874046716431817185624064 * α ^ 46 - 363947916336732295692730495412120808062976 * α ^ 47 - 2448922340507063244670480160751278358528 * α ^ 48 - 14156403192874033788431089246006149120 * α ^ 49 - 69840635580766128998624519726825472 * α ^ 50 - 291304208587694376741876403273728 * α ^ 51 - 1013847100270960749479253245952 * α ^ 52 - 2890985222950997734006456320 * α ^ 53 - 6580251459272551201505280 * α ^ 54 - 11498869995682148646912 * α ^ 55 - 14487778418579472384 * α ^ 56 - 11716883921240064 * α ^ 57 - 4568503025664 * α ^ 58 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 58 * (1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 + 16985863033574280235844441932687847244474918343296922124467065830558560591641911607696 * α + 79535686565443616767714198705465441607069525916537281975943363396026310601750092892488 * α ^ 2 + 239403368066863055363036191982445140250970254028533507257869611464498452359820776516672 * α ^ 3 + 520412199687668549649368000742289832307395871986227854434049639793742028919048260538980 * α ^ 4 + 870157990458303443210342456693112304974391575125591793142671535717764222680483811054120 * α ^ 5 + 1163895406905166893909394336483096101920864956907539643884037297958617393209091960980980 * α ^ 6 + 1278712702347990314588936279615328559669420142052152673561809586945926657118282053100192 * α ^ 7 + 1175725999507118690334304481188590417967828338375807066246239349405176693210977652965164 * α ^ 8 + 917174565683194380325199349414315003531063568224297761645149376513377860921193466166360 * α ^ 9 + 613220450431269534465945368150179786921282701580434508261534043083701875736956664994572 * α ^ 10 + 354057578771667900301737961009087756507978666072508030411200442531544505558679233553472 * α ^ 11 + 177508212962690728847102755764000185519630950904902948797136565592445320434555097902358 * α ^ 12 + 77576143881435246639915934911657056385846898645191797585491387399418570120013455336412 * α ^ 13 + 29625606539961534087112448697426117322036816304400291238815402402574337305159894234710 * α ^ 14 + 9897983624006015895072166102753315050019559506815047218656308374776682178809801281072 * α ^ 15 + 2893024329186264383797233494270141942147451227576867206489337752203105179024976096612 * α ^ 16 + 738824037484601173560395482737511489082491085984005275312812825534063503137534438984 * α ^ 17 + 164441392895370259121202826289551958180582089330511860705087484253672173523954414324 * α ^ 18 + 31771089808007468337610992777240040391387210585565359776690610466850812101226150720 * α ^ 19 + 5298220195377128677201324507710581490774005592592493587530562214239637638718207838 * α ^ 20 + 756659597417575188091510844865331006747834890107597233256807850344151631080238572 * α ^ 21 + 91559608573015197712368058376578410389957871248555658418907655613710858144349974 * α ^ 22 + 9249930419338172598175237698997019936144549918443437721165100485815394918388112 * α ^ 23 + 763883913294738134810454963300633389711111356082193955572628106712061571529450 * α ^ 24 + 49887514803037691118937977551057551319824185688173200456490865107511572859188 * α ^ 25 + 2408300944763273858718491162262422770972533056902127038712768748993172577610 * α ^ 26 + 51725078185114864055621675260185352972397611437758098966549358454837797760 * α ^ 27 - 77510592929500392468407361123374953300216693743671418464304395453235289971 * α ^ 28 + 2067570494221092433188386134604931347621528152582381523034724429480663810 * α ^ 29 - 4580593295775337280722829599699027320935759304984497739306397718132427 * α ^ 30 + 167416972491317272532611766388094644865407567559322236979252017800 * α ^ 31 + 8389683035480047874686298369093744577278032988658533654716580671488 * α ^ 32 + 533168330392361738160636316662426153463437758146484284733956527840 * α ^ 33 + 20133734272551384350294239387428682262688585273913890267463998960 * α ^ 34 + 493961052258347053233401169722862536905607351132290352999275776 * α ^ 35 + 5693741143796291743936421907647419400331769333817148390864384 * α ^ 36 - 136838149185369327185106181434226275722488605188850651649536 * α ^ 37 - 10213381894013887312358741093692449757528996456249043806464 * α ^ 38 - 350916645279993747972377869550082945451923877049098721280 * α ^ 39 - 8752703600310726164117509854956335599020724135444320256 * α ^ 40 - 174795107690037567064791487247091959281487206843686912 * α ^ 41 - 2905560404482515211390475250648416164278477823340544 * α ^ 42 - 40986185232466565782519730515559353841538308898816 * α ^ 43 - 495823850271711791881581412818585367225361694720 * α ^ 44 - 5173168623120670073594814754124350179396943872 * α ^ 45 - 46665067131765629087874046716431817185624064 * α ^ 46 - 363947916336732295692730495412120808062976 * α ^ 47 - 2448922340507063244670480160751278358528 * α ^ 48 - 14156403192874033788431089246006149120 * α ^ 49 - 69840635580766128998624519726825472 * α ^ 50 - 291304208587694376741876403273728 * α ^ 51 - 1013847100270960749479253245952 * α ^ 52 - 2890985222950997734006456320 * α ^ 53 - 6580251459272551201505280 * α ^ 54 - 11498869995682148646912 * α ^ 55 - 14487778418579472384 * α ^ 56 - 11716883921240064 * α ^ 57 - 4568503025664 * α ^ 58) = 1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 * (17 - α) ^ 58 + 390326433597525193146123071698409867301520390117218290267746409833092718425696728651808 * α ^ 1 * (17 - α) ^ 57 + 42339767414709412024800543085671455832484522045547354532982698096600368845688639786434272 * α ^ 2 * (17 - α) ^ 56 + 2978288251912812668426975142881017511384301236011339350466382171100719277406612535201202432 * α ^ 3 * (17 - α) ^ 55 + 152745949949503787162875767681479712010274958086345519055757721242134449740576558561672466100 * α ^ 4 * (17 - α) ^ 54 + 6088522642574857806357024467621421962247301068049055791879352484148857589737344570006424306432 * α ^ 5 * (17 - α) ^ 53 + 196353730172495768212131228592895964623220340501637536200602452342681588928305193631061786495128 * α ^ 6 * (17 - α) ^ 52 + 5266157866495799387947512134510522910378331486905487931902457256370064452591463479230852331820688 * α ^ 7 * (17 - α) ^ 51 + 119820143547425060414405575247909992318712489020361652433663435983410928998020585429365087295873272 * α ^ 8 * (17 - α) ^ 50 + 2347881458090802952975815753665509878263409227272937917396103015417709833460343242062605055065007520 * α ^ 9 * (17 - α) ^ 49 + 40087439558071587468650026480818375755059891510076862445505823029454511957690006955557287865611736368 * α ^ 10 * (17 - α) ^ 48 + 601952482871233638447257366201476457757370789071367246820395949483198507616680072154695375018993206080 * α ^ 11 * (17 - α) ^ 47 + 8009470199896280650115766696812280446758293363345211706745554624342950667301865303395190896548719848894 * α ^ 12 * (17 - α) ^ 46 + 95019362618823693655434560324233095572340322211181765633801354884655907381821543655651592610813813891216 * α ^ 13 * (17 - α) ^ 45 + 1010201707551433403309553561274371166022594138303310301376573778032472462922417174557444934419810264510660 * α ^ 14 * (17 - α) ^ 44 + 9666021740205241072831491648575295854988543778205392913804696971472866176266073951546563512467374588927208 * α ^ 15 * (17 - α) ^ 43 + 83539422247937309919557615020970488939815680020028362327882719748972398761527927690277222254506587818510230 * α ^ 16 * (17 - α) ^ 42 + 654118420001028745738306390006036203398367424921715171378029833094091806885053261792691008623047458390979656 * α ^ 17 * (17 - α) ^ 41 + 4652186358394523426651350117431277481053696460019422776379929513303869171324522998809216735658736365543149056 * α ^ 18 * (17 - α) ^ 40 + 30118791616775324911184234952445703914857411555877912743140868805910755261334373116907433215385078679006707440 * α ^ 19 * (17 - α) ^ 39 + 177826427793428069222664936517971981732084250622079798759954938089906960407318562179543208670385720641305484484 * α ^ 20 * (17 - α) ^ 38 + 958974728072861489890512212348583321104118795534766915893103879494275523886658791163551854756652905815510994528 * α ^ 21 * (17 - α) ^ 37 + 4729723071531116796957485128322656283636236954549201452338482026970860715184248091976900742259324658054589766592 * α ^ 22 * (17 - α) ^ 36 + 21357626391876046213696677013115319309126810433424794269849513349981113078786111769550369530995181611742183411536 * α ^ 23 * (17 - α) ^ 35 + 88378492075701468992449068981435994543226968075794931456837379496731600212606957395063382063437679158720468757170 * α ^ 24 * (17 - α) ^ 34 + 335374317924993519374894630236901278966604414721735688724835686564184905864027923099074702766636244586098764495656 * α ^ 25 * (17 - α) ^ 33 + 1167747403010750979143600445942797877583165267655942642217360148980523954073844543734436948340308328790173989450240 * α ^ 26 * (17 - α) ^ 32 + 3732406493950907275441950492949127432338499662676613602897135646128454363022292331302101040551201738067461761785664 * α ^ 27 * (17 - α) ^ 31 + 10954129200438058193458578123785740490187961119866684050714899067863611709664062247915680616127050262599212424644897 * α ^ 28 * (17 - α) ^ 30 + 29524937330321420901887693835267567366420221233340924484096603443964250287652843237880043795863468001106755829620680 * α ^ 29 * (17 - α) ^ 29 + 73087125140139025535278935287700443682500254736472038981634113551624541486231287807821582020794101152220739006249054 * α ^ 30 * (17 - α) ^ 28 + 166147644042440368311067169194067229624014747885167057075915274327610140356799603915688925405707986646551735878107548 * α ^ 31 * (17 - α) ^ 27 + 346772843057251234464569444053204287523460387723124946687308651228411784130792835892965479313436122483094189414638435 * α ^ 32 * (17 - α) ^ 26 + 664225955992969098770607024010663586597562367955519444707479326460670050391696600135144018377249349272512491633374996 * α ^ 33 * (17 - α) ^ 25 + 1166927452705629997542488080350699352093937922567202455194634401101839128946832909551419826543265369338614818217043960 * α ^ 34 * (17 - α) ^ 24 + 1878756607833380897964887521267252840224951551991841799719666838851961513969673042361037791640974884809523420884857896 * α ^ 35 * (17 - α) ^ 23 + 2769054221066722167360357163072398302792888941316285917570542419942819549648264402600819292556739224578295584544111593 * α ^ 36 * (17 - α) ^ 22 + 3731200624302652450167208268451073697815114712494349214865173019453170935880402861700349003895204451567678626785884944 * α ^ 37 * (17 - α) ^ 21 + 4589060320062131760404941760267700835789214136011164185047467243912104258380281276437542650223991907463154227654480250 * α ^ 38 * (17 - α) ^ 20 + 5142005613111678624089090068072653156514352316794579159234104771289794844001366200904371725907143894777202797701901140 * α ^ 39 * (17 - α) ^ 19 + 5237411173258795881045797059007984704429066340121408567111553635714834497251049352739808449923037569813646734054022299 * α ^ 40 * (17 - α) ^ 18 + 4836963127294992600059755436214556792844531244095433636867849886599932076358086832823383902964112824599524794814907660 * α ^ 41 * (17 - α) ^ 17 + 4038642993383808502646993082987941730662364203715934601149860715099116021657255631782766462484195430978656049244711644 * α ^ 42 * (17 - α) ^ 16 + 3038452569137952848001398255617645415509309374884449236698224469982642958671749123930862050454967951657624568575856688 * α ^ 43 * (17 - α) ^ 15 + 2051868663368925893596995729015571533363774183714583901584727359036447948070300988236179249392897564162618659414308125 * α ^ 44 * (17 - α) ^ 14 + 1238175994140035374637906473341260146948966827890334540274993830863642501653683339638928725989225430525272809854519160 * α ^ 45 * (17 - α) ^ 13 + 664157193310869042816823748632341892142095205218119162176744496952019558037232907168597445007823380125777368765119662 * α ^ 46 * (17 - α) ^ 12 + 314709886085135861297147136857650883344977185951101514937597344260222119762475730654304761445438390089176776231442524 * α ^ 47 * (17 - α) ^ 11 + 130752300650671071539193189087470650687679774298245936504525933790335489689909687270813505169056399644554354547239027 * α ^ 48 * (17 - α) ^ 10 + 47197367207696915154864396118931631129224589120774745992092456851672119895365941889175184835650784414267376300303620 * α ^ 49 * (17 - α) ^ 9 + 14634551667218002061058569723384799807420346162568828832552477052180173516934500629665142381604576011817456177436512 * α ^ 50 * (17 - α) ^ 8 + 3842020781478673446935098659029021030741590331823487291470293090299720569242182142621667182316185787786272194127544 * α ^ 51 * (17 - α) ^ 7 + 838031670173391441198956875841265626545050410662677811959134541401400325959689376985919100766189972881282787577763 * α ^ 52 * (17 - α) ^ 6 + 148041122984446508528033501826038847912820726117568892710474612036947233357823264896703744164136565988458171335488 * α ^ 53 * (17 - α) ^ 5 + 20425027753973244256487010270626798809629979580987772972987591577599400419675783451565774908699336057777964446110 * α ^ 54 * (17 - α) ^ 4 + 2082801294909426227172103997302542506576066130763213820723347100167035816595437754294159646550971592826080127596 * α ^ 55 * (17 - α) ^ 3 + 143053115347005574042966026900851192531277156875872861510463214959748868032658829240606333338274956129514869223 * α ^ 56 * (17 - α) ^ 2 + 5492607925836276782575645752168619846129179160632349319557999016078091770978332301317881391624780373381782060 * α ^ 57 * (17 - α) ^ 1 + 68316788541465931995562079450677157534774523435506193215243865134760205880356610515710383859614369923388540 * α ^ 58 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `60 ≤ n ≤ 63`.** -/ -theorem finite_range {n : ℕ} (h0 : 60 ≤ n) (h1 : n ≤ 63) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (63 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (63 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 59) + 1 / (4 * 59 * (3 + α)) - + (1 - 2 * α / 62) ^ 2 * 63 * 62 * (63 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 59 * (3 + α)) ^ 28)) - = 1 - (1751151069426938433392544117977870071473220315192596795720798115751675661513521229672 + 16985863033574280235844441932687847244474918343296922124467065830558560591641911607696 * α + 79535686565443616767714198705465441607069525916537281975943363396026310601750092892488 * α ^ 2 + 239403368066863055363036191982445140250970254028533507257869611464498452359820776516672 * α ^ 3 + 520412199687668549649368000742289832307395871986227854434049639793742028919048260538980 * α ^ 4 + 870157990458303443210342456693112304974391575125591793142671535717764222680483811054120 * α ^ 5 + 1163895406905166893909394336483096101920864956907539643884037297958617393209091960980980 * α ^ 6 + 1278712702347990314588936279615328559669420142052152673561809586945926657118282053100192 * α ^ 7 + 1175725999507118690334304481188590417967828338375807066246239349405176693210977652965164 * α ^ 8 + 917174565683194380325199349414315003531063568224297761645149376513377860921193466166360 * α ^ 9 + 613220450431269534465945368150179786921282701580434508261534043083701875736956664994572 * α ^ 10 + 354057578771667900301737961009087756507978666072508030411200442531544505558679233553472 * α ^ 11 + 177508212962690728847102755764000185519630950904902948797136565592445320434555097902358 * α ^ 12 + 77576143881435246639915934911657056385846898645191797585491387399418570120013455336412 * α ^ 13 + 29625606539961534087112448697426117322036816304400291238815402402574337305159894234710 * α ^ 14 + 9897983624006015895072166102753315050019559506815047218656308374776682178809801281072 * α ^ 15 + 2893024329186264383797233494270141942147451227576867206489337752203105179024976096612 * α ^ 16 + 738824037484601173560395482737511489082491085984005275312812825534063503137534438984 * α ^ 17 + 164441392895370259121202826289551958180582089330511860705087484253672173523954414324 * α ^ 18 + 31771089808007468337610992777240040391387210585565359776690610466850812101226150720 * α ^ 19 + 5298220195377128677201324507710581490774005592592493587530562214239637638718207838 * α ^ 20 + 756659597417575188091510844865331006747834890107597233256807850344151631080238572 * α ^ 21 + 91559608573015197712368058376578410389957871248555658418907655613710858144349974 * α ^ 22 + 9249930419338172598175237698997019936144549918443437721165100485815394918388112 * α ^ 23 + 763883913294738134810454963300633389711111356082193955572628106712061571529450 * α ^ 24 + 49887514803037691118937977551057551319824185688173200456490865107511572859188 * α ^ 25 + 2408300944763273858718491162262422770972533056902127038712768748993172577610 * α ^ 26 + 51725078185114864055621675260185352972397611437758098966549358454837797760 * α ^ 27 - 77510592929500392468407361123374953300216693743671418464304395453235289971 * α ^ 28 + 2067570494221092433188386134604931347621528152582381523034724429480663810 * α ^ 29 - 4580593295775337280722829599699027320935759304984497739306397718132427 * α ^ 30 + 167416972491317272532611766388094644865407567559322236979252017800 * α ^ 31 + 8389683035480047874686298369093744577278032988658533654716580671488 * α ^ 32 + 533168330392361738160636316662426153463437758146484284733956527840 * α ^ 33 + 20133734272551384350294239387428682262688585273913890267463998960 * α ^ 34 + 493961052258347053233401169722862536905607351132290352999275776 * α ^ 35 + 5693741143796291743936421907647419400331769333817148390864384 * α ^ 36 - 136838149185369327185106181434226275722488605188850651649536 * α ^ 37 - 10213381894013887312358741093692449757528996456249043806464 * α ^ 38 - 350916645279993747972377869550082945451923877049098721280 * α ^ 39 - 8752703600310726164117509854956335599020724135444320256 * α ^ 40 - 174795107690037567064791487247091959281487206843686912 * α ^ 41 - 2905560404482515211390475250648416164278477823340544 * α ^ 42 - 40986185232466565782519730515559353841538308898816 * α ^ 43 - 495823850271711791881581412818585367225361694720 * α ^ 44 - 5173168623120670073594814754124350179396943872 * α ^ 45 - 46665067131765629087874046716431817185624064 * α ^ 46 - 363947916336732295692730495412120808062976 * α ^ 47 - 2448922340507063244670480160751278358528 * α ^ 48 - 14156403192874033788431089246006149120 * α ^ 49 - 69840635580766128998624519726825472 * α ^ 50 - 291304208587694376741876403273728 * α ^ 51 - 1013847100270960749479253245952 * α ^ 52 - 2890985222950997734006456320 * α ^ 53 - 6580251459272551201505280 * α ^ 54 - 11498869995682148646912 * α ^ 55 - 14487778418579472384 * α ^ 56 - 11716883921240064 * α ^ 57 - 4568503025664 * α ^ 58) / (34956176830804188618864971427671197206330339979080770327319313608079680 * (3 + α) ^ 29) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 60) (n₁ := 63) (k := 28) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B60_63 - -end Sendov diff --git a/Sendov/FiniteRange/Degree64_69.lean b/Sendov/FiniteRange/Degree64_69.lean deleted file mode 100644 index ec85162..0000000 --- a/Sendov/FiniteRange/Degree64_69.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 64 to 69 - -`Sendov.R_le_batch` bounds every `R n α` for `64 ≤ n ≤ 69` by the elementary part and -moment at `n₀ = 64` together with the prefactor at `n₁ = 69`, so one moment and one -certificate serve all 6 degrees. The certificate has degree 62, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B64_69 - -lemma M_lo : M 64 = 63 := by norm_num [M] - -lemma M_hi : M 69 = 68 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 64 α = 1 - 2 * α / 63 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 69 α = 1 - 2 * α / 68 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 64 α = (378 + 57 * α - 2 * α ^ 2) / (126 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 64 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 1182266884102822267511361600 - -def betac : ℤ := 360440112992905200430070440542682349057506311493896185948717579976126833046728758532500717201250065630471887791651588092723201 - -def tauc : ℤ := 14319612112968315221187644159823155325868920603956395389717787364246891581758568219927620415659946395149605881624765246445660393662929812512772773078414270145772732508472599309962618737002536535024120751775978859240702903886545696349156301257598266799449180110855684135045235204116178378392081792438855100733433169590130448038409068154473733539634666229449026947859481531085890164151964496393258591175191808601188299477604160464231739905753127133372544173463613820856084162195241904702238073703534599995282137360128166676294559706217777247407822875738134547760499225810117876509028240510436897801570098673988519994663076759056213298744887767376334547891794637327963432913268729586877181879769806730380835260384589140608039643970702390167369511003032058927626659893272013226414423160143094825077648124307534110975895952688912226996819607559455910322090401799985957075356001782473629289889080718430004801494452136585843891657280332176434684724853778044133149083090909530300625843701530467908365731665248136291496859195262665425616102178645840988583937415381880118108883614971521160370643604532690728494764825234700134121936644422536554639218399726263899610730863948607558178871186825085909483796620535279523061287423792880082149444642966915102775438123261152539658024776276116313883344858144832947064322795840411962834794138573400185119550562602082346961850939268636042051599096033337796636194723644310800328541646804263256752888392375722859525461636831738640031652687944590254380647741187106249802625137199566915975357209709135813018316711672931257038579756226964749454360485437594557190649600479994193561991175400096972212266272784897165861553800074738416969790024133657899827595047172589345852033657114652278788023478607262361879737011733887447700618447068293956968666319730513242359532599398287054864156995901755913658427612327687072223807508558118408827764726313553212346265089230314281023786708167252698616488831836297755232819466749734110689113102139123796191653285097797657573726931491569141034710934829720610173553156977091778121962451591182907356673409245993822270439993498177731952178806251281758474658757856893188996499112030040160498253322277760271921693778221091590266647972198453316253940891578846563932437156350380345925216994418679281138054726532524112113359062833665758049351669026093637757105486354482998562012421449148374957546144097433386331934590187240793982787964571178615891604778419377041132902521936220478110172719576212781267368127824349388623874411593629034170443624862465614565573989940554118404435297534844587371811415803720871323643476612752008573275830860113922157651208363087556530341298652468166017324516679226418180147499923676177450742087540262238264144681227668205440003579341272045891785547365343445376534078760811171610151502917484210340231293470780837235120506734429280879323990815105959288087199313356856898255912557853766378622208403867658489966086332960607034441719422584863453102763584972305025706042795252815188852024126035617497758856448150106552595410251005579044318064331630359110041704635263350548950876919370835458192634785901615849782535096484239509341482158934553629555720498597591125065612988483224956145062175511594304576003712342013665097207143480251946106305947697124772263623290130641482369715419001300437580925323826823675483454596758462465143117700519027891411229287513591101326693957084742845668369504964646470903394556977217419103657769167798647304141464332594944482747858291790704746170637656138712084186237928729099198317614425661361651476532903882248066149539088560527736781097911095174294499359525244542017380362650638489759644137435238194845216705988399029336809228793769613209164394135828909160755067493004499820431574139221105612446409500047986182615469201101841559346079595419116094177500366260455723892429406628425372214467480925027521968310209281943031712534698480447355120770969950758758243164776495041949834088160684034238961856279675893127883458603997784966352907487747666449396001478636233928411944557559853343215172185925720355937737561903170913428093690945550476088317027242270161549575195107345669829663789368003851585175937189589038912917388507451191876436718971140232400926376912917608274882904976019346646415071838904945330069659064050769366136066965042514332985811523605089735396589074766570650775082683824782059398141709610788757814492135672466216785297266332388793980078835637231971417688271311579691662648015943766821847325196653836322693331861824023218859615797466584537192090769366015519883429505329817721804601738801417031488285497807474120302543532671989633629801869900539575551957210255050878199044803213142052811053867567341836855111989159344133735874526738975964045664865906948680539427850834274448097132497108709977421598586486244523453040224507764238989125433490410013363617019494521262713666039804174960110850777590169609997054272067501248021502876927351642635712955278773043313237747061045062023664698570959807433810763110528364914045379466220605401485196760407108762696725574822117433419941782504068308445681632913400374669040794966719065669872348967487045803366956891838260990127614871437463455296328113834344420636372210079876062984810918288150125124311438994920459339394396275329151940386718296888002928580229613950938169652046008314100794088958043169189635274561635245601830888714609468469155922430219816935991695376930701937958405790219704780784393465449765147097693108128492303862572379655579177250915723481220722616086482595377089697508623199141528059023061042079920357164742935264996646774416035538423985146555343544875480453324069486851922617087126153082728540596123906219530965059731303578995042705838060533050887020239421905505686863966507730314949323260558978832552128747835388972937849306097908287751875315416696586078409817048634537716530606653373086388659328040145352325050748651615437159230542793849207973113650822702586510504792971149437546324045908733121793178783916800977480771792160671156098722534282188053136439777719197748786090960465909915701072077162411489121395025155951573988777805969982511217507249267988912695441433246584860429551384028503462161422455755660862315602355078608743940127525053229569490908229057398222955477933834982050786100368715756809407363558739374679489306663169787634863580947871478361725823565164488592904697778888430511527649756082361426497173603588979463896789942995035528246616123975086778003437122601867743785523597213303235491404922312120882731372149940131862006966309685891788961151026289263893328467891342465720110259208514160911317685756064844293114091461541376016597154254990647770009934223958533938747560934690739706919685563042478363049045826238594841028333828151232813643984636659156973597006754488946048212563843337948122631068287111234752146566031821241128093420046209332668445964119272797854371739850079584479023878678661842110579286649175747509897734518804727315769047126095580301362008579579765007553773250126726506987396732835154993255194095616441951523176357811676066827065731999204464147445514401110533690951627624925088862416772412579827293714309955760055054248189887097550188215584515327497154671297241902899910437949100324110498105189771464580629848331181638220977554574763268362212633568865443587595795133636072569260931564097519140490980692920943051813642498865719355866456026413486276891732363230403103351727516626935127905780101406229233011374819834081701009636718299335216310649700464390339829724626605031953222739168338940545958498463780641606961057436514732163563369358794901608683243929416554516743736186820501276298667788073811868909373965558091956049931295441719913131951458203677777632040489800659511128797786262437728590005547688268248674957860960388260128671321439937893198767131353868464957584534612755974931409485930272243699452262693625405665098653909948686404651410832873551518815623953523316096846005550437869228247861259149079407298309994117887130623372787669944758463176423307777212957855199633287850898339567142655292640161978316495388055783767369876204837236045042916528158579642003456138598673569647992450797688470071607367391597125136835329296593860096129294204831951111845051056378200037987980930231958496377100686827178415111059320893720010085095669605968564647284501768324257689307603683750717091826266882349049233190854798923356292226451407298161635685288774027142117091360902330893586587578264251797878694879398651849164574833436569716755738691135694751255687855254750960527061229557241136129247906745084573538474241745353040964380496364242633217038965316389684131138048219694475767648551686322774116194191065701424519507017438136909690756715473359517641216712605824563194906818326190454599398797457312134154214014380168213262064490120970372496122053542417292377017122952238795314501592757367736409225844699210463535439571818526035586063636275487180272808576863207588904758973618429573825244421564964244920780796492626486366036607886184371632717128638214992661981882148923686230834769343682662798748436054015856840935174503758415910831438829363256685714068501123326755563627057581359579633009464842740828359439876534125227933601263090914745711766288221229328234138277057654102814380726627307855077741587494394888412194947728828801408615076610835659971331817384900516114524405003499995777841649687666511280250365324842051038440501489794334701914679489517522666540576417783947115049762240186942459045130267716785728194735569176614550481816935627226194703358618146111415607896134406581518158794263831929671497295779163488029426610881067167787548625744373301032926200603722791913884304694472443865707460995809674729876098003243997197080984291222295799125823516367021443995599204749614171364526474569650257983834855109634382608095622995657720587884521968880645191049658152469047887326950585514720419390675458277323468200352839158150748890663502964483364927160717433432271359600766931210141705424104233402412706254976584920679438547934418735321853551169563095270831207338233492644580077094851294530511171333438961600964872983889532106151251273380821464266978841395005139642317754586107501817791967527598432506496978001456959657575447334323707202153503614502460150137223691285799211978770543782160385909853672789777462708893494037373473152214078048374964289353731697685144929691354124107642711526547748887099191893289126750039557220636011574507883570729501527198394262715489521428461600549128331438508822190773717609188040045945208670299520197138998934881072577550483441755306142591890141486086826125006388774421288997359796029361283596994855468740212716889419034735898416660055778225159974309967698192482481445451742117912769975979014419252809304779072197713873768026877173527339106401810800534610529585878644376492450212265113195094052995243529758477570877984827933190435758250074297146297779886063220742360996079600254466756346089335720055456125735192651470794248045670165879830906392734484544146356602011618520474183767144445379831201929263801806287580829629431742813799896222355730490094241158529104911769508910055418041039632907233416680652014335018553990116061530045421559780891632691134803578396942634057975326768937442640054814641521629835829527168892004435336717743742657200859480853920321758193440691834692811740365707438547934625449255765194710945496537003082192216207978673168884612805785538547853269913009773913125771010054270252655075600144183614835864322012547254834210077146560833177276176836344880728770326222995969540222633829694999204039073469574061778724334926151605284665595540084023553089604407691842399284136091467722285220166305476599842365614698822052673219170584451615774354401542656636627248447160805230641153 - -/-- The moment numerator at `n₀ = 64`, `k = 30`. -/ -def Nmomc : List ℤ := - [98260444066110477984836116462146975177565987674838144210723047333873516205794578773093226486169600, 1059901599243108287415662968370546360712760481526758287324382528868529663372377681282862475850547200, 5537147441454075868420675150363631640995433612849527316895704103204174810822008488047143002780467200, 18660582924852091593634716817012794295370400112287649437897097835276054090654093795380018744708300800, 45588121340933473192722993558709977069272671518440136646314470586525781099802596768616798002505318400, 86015714127742929378199716691138181101926893579160296153280945831076094109300071526554012228989747200, 130400663242020557509552523704074049102616547768111954289642253523482455826059845317586712696297881600, 163154856961459341981698797080834235361099672397517899366686895608450005492563146095048479910291046400, 171734412525851093853909466445163221898838617915115326143353802869283326825780884545941270906168934400, 154243485736753262806540143355256481511535569273495821620027486109693445050078377812928515446669312000, 119482839363511487459786992900768903617340541026760048565599169056161968580492680583648873787739340800, 80486067444309593522685584039188524595161119593641781704530570496266026736240057019377004505045401600, 47445261414097912163642717468895562150541255176878978433900754785174246253557258315961217912825446400, 24592991428052627616760673402394682976106695261407043737622705134322034834336046805996897997894451200, 11249551310432187185892878259814765112469774748309744669687439554991414399200566001750620591724953600, 4552786272851131118747814512748665373354721892190504503484760746790134226938942731060995350016819200, 1632917920873191946267719554699769149805927033950058525127323442638457689685515482696602426225459200, 519494077293044006011905475394588413729023773768568962276869289588621537186572932009604228841472000, 146622325958464964473006027849217895557838280878302838003394179882409726922386938761247520613990400, 36695609936120983062608613975629834154621872803663090203812010515885240372915000914377872454451200, 8135017084841340184075123584755171209197719716184720255379371645779622031931243289158571419238400, 1594958886884790981123526277152511114598686701776386072248663152222450750620490133440901310054400, 276020296223312561829633547334385619844997403541153117306901001314588576372000698886639530803200, 42075055832403906229427095816865838885022714305289037556063287772031513213663564249900567756800, 5639146264704638318872755835723034778966329320013079328680781328157305507352103580558426112000, 664025551260323460136672941631545776626738798462800650174587843453045443789065964400253337600, 68828339141471950121676658873040971153111493277442865689468591283139001870575273109566259200, 6333242342186879103842537768204819142410793140394008743101656302035709342572929782854451200, 534239900114573058053922931610633427495257705275805409660814160443325003432490416524492800, 52552683203010488538585297092480031922870899082101312102535306268256626340584979274137600, 45866497973844810438612906601484054625371390298152941823740438892312949725775391201689600, 1676609094888077161899473374771323071273070705064612265181308114970184551921624494899200, 61858859358876104860202125317306435943135156666141618336128656271596387800036304486400, 2238196207692148030795300468606624501792069185946154046002444423956466144480801587200, 76828449341252834667768890161773151181544355052705654128899471477578018720002867200, 2433678020966848222287649601414896077079695416017444790870583794233963596428083200, 69828177033469716189246260158705146561740783402037822293087263285143045931008000, 1795322638213067815875997716304812008010943589521272320410099577292746391552000, 41136536106768394444089514532129975109256117360982200727079663128246275276800, 838070594272317175397504932908214755224096531721824051204009289640103116800, 15171082727373776290148510116667826888444973340561455516610347033794969600, 244047271283364020096974778009849182007483289567547518419984314898841600, 3489602396284278390994409823135387238224102250804687208220198961152000, 44359626692691824750065673460856777312065925727907293481802924032000, 501219463391132951707172104573182823021554811193707277868387532800, 5030436992998100479993695417466807451714322656696613723124531200, 44789191277478329073798895579142843637056631313972754959564800, 353083559840751507181568279393958662612462597733909685862400, 2457578012332105308479058728572791201702363926607849062400, 15046179757888608782521069180149666281786217373001318400, 80627522569971754037391614443795802249009213472768000, 375741162250935957975313587598497563629101200179200, 1510204426271279572450457959315051060438813900800, 5178872360835964859294587685430152138430873600, 14938473986232021216928582473082940581478400, 35555676657067884072777222854288395468800, 67980454508376523397624348199931084800, 100355593649325402804858377994240000, 107363886921106370323272223948800, 74072390919622254520801689600, 24742531356953776069017600] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 64) (gg1 64) (gg2 64) 30)) α := by - refine pev_moment_eq_of_packed_bounds 64 30 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 64 α t ^ 30) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 64 * (3 + α)) ^ 30) := - integral_moment_packed 64 30 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-62 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 62 * P α` is a positive combination of `αʲ (17-α)^(62-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 + 61381176382803809362111499051840544591370805103230496041366966719316985769735186577074210428 * α + 307875927191106748261011216414410411442655519490352054541897661765849218694794523337461209647 * α ^ 2 + 995139520442941110972922094595461359252165093278183682740950849972307343163433414772266439134 * α ^ 3 + 2329135965026413320254515390788191269701711986947806984107173389521959680472053301869564187977 * α ^ 4 + 4205152400427897818943955614854872603184778207497298031576474014041708453522600564012661712908 * α ^ 5 + 6092227728539116602774802993811227514150357030998079498007336022099744281828374410394763218967 * α ^ 6 + 7273914911154976681674028920562209810638892503140251984517953529760649706898772999266377410618 * α ^ 7 + 7294841936549908246762850463172756077551550164308271524011607481986853316219925718877268241253 * α ^ 8 + 6231636865479569934304365225476315224178754021865462499626075023963516933948459908031199504392 * α ^ 9 + 4582454355475931479184872096047779444629884546826401854025935798959693699768306789254756052107 * α ^ 10 + 2923936751602144899711097457334391073444202579871680510494335159924208835914470439635141162662 * α ^ 11 + 1628646305582237968027987059869036927850582412822128278929774316093217652148166106137543210729 * α ^ 12 + 795445013477937519140644933077682364729772242866058887702125127747950219835128702530435684436 * α ^ 13 + 341732386485246488082914550033328759932103344872452353652503157863279852435899383534716977739 * α ^ 14 + 129398024588904114703104106088147845845858920384624466782691337832071760366611282163240673066 * α ^ 15 + 43227083179690319937679095035602516318669269367605716008461368393810348604333859857847549497 * α ^ 16 + 12739734973954297734917244488839138405165723257781387930800239709000470619130237106664340656 * α ^ 17 + 3309003690560409027996242316235318569343087760556101911245828294749346009825368969657069031 * α ^ 18 + 755904091146328721648601114370911122594719522671458365690647375941659996310302273197058470 * α ^ 19 + 151378877572074703874732245694134372432105936678872727794384094115460812902730719423948317 * α ^ 20 + 26454923472459858634887234579799069438230123457614797089205636430511024677434784809220924 * α ^ 21 + 4009557348845189672922466111254379827931543987777056770742617262249980072703900044793759 * α ^ 22 + 522684797686516768766815870526767734538930901093141236380109988654434790535464480525226 * α ^ 23 + 57960196328928756537267261570029521956658673559059668642752896597993471772708261591453 * α ^ 24 + 5385398873189231308982589874195610465961820936268053590519181757629535422805253399024 * α ^ 25 + 410397478215636804806491132412571076795910317178146076050633000481647199256305822637 * α ^ 26 + 24812014519928905914570908638577043729393183935810050156873373621420956394826529722 * α ^ 27 + 1113510388782381458493062026644349844210314014993864209186922164992790354371374639 * α ^ 28 + 22409773065959463084902151065290205378008886892907135598840606673031087144995204 * α ^ 29 - 35763698158235183891226289780431937498580930947719484832564827737501564744289629 * α ^ 30 + 840760995622979288098811692316543958334461895228266842721825922823541893315826 * α ^ 31 - 2476024715094217195652794819915917218077074423531979390443969076889551332351 * α ^ 32 - 42343131706354479044867362267674031525737275327352243122650061208773859828 * α ^ 33 + 1121663574053726688315155444107301037632747178037371530068223719748652900 * α ^ 34 + 127119237016866360421264159870103175079883989461074891879168221493189568 * α ^ 35 + 5840998162333194724309799734276135965778520891167491660434664446065776 * α ^ 36 + 175992443424517154194105688439948495022759467456834921814514733630912 * α ^ 37 + 3457340410083421419722141826010375932802380080806011689658236008128 * α ^ 38 + 24387290416155856471527726331603437910487483092148051628143522304 * α ^ 39 - 1239885867289330313685948822187720768399781886302021720494414080 * α ^ 40 - 65142911505809786191440265839050522466645141325685819456216064 * α ^ 41 - 1919845972367683574507152058644769097612240398422850416591872 * α ^ 42 - 42690755951658679674359660598349223111852496540029559373824 * α ^ 43 - 774277941425789906408100254236527798872560249769923817472 * α ^ 44 - 11837447748695307877084872298248109006399402655405555712 * α ^ 45 - 155160542836944884945355229969272241433459624584396800 * α ^ 46 - 1760282021481048069096957321992926156742736627499008 * α ^ 47 - 17375591117616735181132725973057892264379050557440 * α ^ 48 - 149596040045196039764745879558857285877770747904 * α ^ 49 - 1123758519054636222507004226738421820190097408 * α ^ 50 - 7354587732063594511120345756955829080162304 * α ^ 51 - 41799839163275444256118641007392250134528 * α ^ 52 - 205261854328197847356177208926730715136 * α ^ 53 - 864576623781254196788511741560487936 * α ^ 54 - 3092645524632136056284929849294848 * α ^ 55 - 9268224902397535157105681498112 * α ^ 56 - 22840148173664707695687499776 * α ^ 57 - 45078822391172061959553024 * α ^ 58 - 68515609003558969540608 * α ^ 59 - 75294374818201206784 * α ^ 60 - 53251155240681472 * α ^ 61 - 18200997658624 * α ^ 62 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 62 * (5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 + 61381176382803809362111499051840544591370805103230496041366966719316985769735186577074210428 * α + 307875927191106748261011216414410411442655519490352054541897661765849218694794523337461209647 * α ^ 2 + 995139520442941110972922094595461359252165093278183682740950849972307343163433414772266439134 * α ^ 3 + 2329135965026413320254515390788191269701711986947806984107173389521959680472053301869564187977 * α ^ 4 + 4205152400427897818943955614854872603184778207497298031576474014041708453522600564012661712908 * α ^ 5 + 6092227728539116602774802993811227514150357030998079498007336022099744281828374410394763218967 * α ^ 6 + 7273914911154976681674028920562209810638892503140251984517953529760649706898772999266377410618 * α ^ 7 + 7294841936549908246762850463172756077551550164308271524011607481986853316219925718877268241253 * α ^ 8 + 6231636865479569934304365225476315224178754021865462499626075023963516933948459908031199504392 * α ^ 9 + 4582454355475931479184872096047779444629884546826401854025935798959693699768306789254756052107 * α ^ 10 + 2923936751602144899711097457334391073444202579871680510494335159924208835914470439635141162662 * α ^ 11 + 1628646305582237968027987059869036927850582412822128278929774316093217652148166106137543210729 * α ^ 12 + 795445013477937519140644933077682364729772242866058887702125127747950219835128702530435684436 * α ^ 13 + 341732386485246488082914550033328759932103344872452353652503157863279852435899383534716977739 * α ^ 14 + 129398024588904114703104106088147845845858920384624466782691337832071760366611282163240673066 * α ^ 15 + 43227083179690319937679095035602516318669269367605716008461368393810348604333859857847549497 * α ^ 16 + 12739734973954297734917244488839138405165723257781387930800239709000470619130237106664340656 * α ^ 17 + 3309003690560409027996242316235318569343087760556101911245828294749346009825368969657069031 * α ^ 18 + 755904091146328721648601114370911122594719522671458365690647375941659996310302273197058470 * α ^ 19 + 151378877572074703874732245694134372432105936678872727794384094115460812902730719423948317 * α ^ 20 + 26454923472459858634887234579799069438230123457614797089205636430511024677434784809220924 * α ^ 21 + 4009557348845189672922466111254379827931543987777056770742617262249980072703900044793759 * α ^ 22 + 522684797686516768766815870526767734538930901093141236380109988654434790535464480525226 * α ^ 23 + 57960196328928756537267261570029521956658673559059668642752896597993471772708261591453 * α ^ 24 + 5385398873189231308982589874195610465961820936268053590519181757629535422805253399024 * α ^ 25 + 410397478215636804806491132412571076795910317178146076050633000481647199256305822637 * α ^ 26 + 24812014519928905914570908638577043729393183935810050156873373621420956394826529722 * α ^ 27 + 1113510388782381458493062026644349844210314014993864209186922164992790354371374639 * α ^ 28 + 22409773065959463084902151065290205378008886892907135598840606673031087144995204 * α ^ 29 - 35763698158235183891226289780431937498580930947719484832564827737501564744289629 * α ^ 30 + 840760995622979288098811692316543958334461895228266842721825922823541893315826 * α ^ 31 - 2476024715094217195652794819915917218077074423531979390443969076889551332351 * α ^ 32 - 42343131706354479044867362267674031525737275327352243122650061208773859828 * α ^ 33 + 1121663574053726688315155444107301037632747178037371530068223719748652900 * α ^ 34 + 127119237016866360421264159870103175079883989461074891879168221493189568 * α ^ 35 + 5840998162333194724309799734276135965778520891167491660434664446065776 * α ^ 36 + 175992443424517154194105688439948495022759467456834921814514733630912 * α ^ 37 + 3457340410083421419722141826010375932802380080806011689658236008128 * α ^ 38 + 24387290416155856471527726331603437910487483092148051628143522304 * α ^ 39 - 1239885867289330313685948822187720768399781886302021720494414080 * α ^ 40 - 65142911505809786191440265839050522466645141325685819456216064 * α ^ 41 - 1919845972367683574507152058644769097612240398422850416591872 * α ^ 42 - 42690755951658679674359660598349223111852496540029559373824 * α ^ 43 - 774277941425789906408100254236527798872560249769923817472 * α ^ 44 - 11837447748695307877084872298248109006399402655405555712 * α ^ 45 - 155160542836944884945355229969272241433459624584396800 * α ^ 46 - 1760282021481048069096957321992926156742736627499008 * α ^ 47 - 17375591117616735181132725973057892264379050557440 * α ^ 48 - 149596040045196039764745879558857285877770747904 * α ^ 49 - 1123758519054636222507004226738421820190097408 * α ^ 50 - 7354587732063594511120345756955829080162304 * α ^ 51 - 41799839163275444256118641007392250134528 * α ^ 52 - 205261854328197847356177208926730715136 * α ^ 53 - 864576623781254196788511741560487936 * α ^ 54 - 3092645524632136056284929849294848 * α ^ 55 - 9268224902397535157105681498112 * α ^ 56 - 22840148173664707695687499776 * α ^ 57 - 45078822391172061959553024 * α ^ 58 - 68515609003558969540608 * α ^ 59 - 75294374818201206784 * α ^ 60 - 53251155240681472 * α ^ 61 - 18200997658624 * α ^ 62) = 5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 * (17 - α) ^ 62 + 1410592329453155093339211289542411736609735429121847896493629858906716014852004156892167552548 * α ^ 1 * (17 - α) ^ 61 + 163825348961034855748532998133187489244150138166953116803112907190951119777389438269950378047615 * α ^ 2 * (17 - α) ^ 60 + 12361195960575736306163012120329422246578502920843748763821862084625502483053715706760463722075322 * α ^ 3 * (17 - α) ^ 59 + 681335583687244816837155518706910028522515498128290805387946937709694218848663276792277722205885165 * α ^ 4 * (17 - α) ^ 58 + 29246467299582416554371726277124312659485967608331036186864901441962932711378452493174003728374440456 * α ^ 5 * (17 - α) ^ 57 + 1017843449098855324693227940286198056557561324301642345041220834540478580971172148752686938326750596235 * α ^ 6 * (17 - α) ^ 56 + 29523351481445963795800452678069515843407715524336444192954336309944099949871809204575864476533589605302 * α ^ 7 * (17 - α) ^ 55 + 728152422115299748757980286386613270210125867312784076185146979717429960990761502520944266554529234032105 * α ^ 8 * (17 - α) ^ 54 + 15503254854319433781737681560944871435301212863859242862611647178701987248949779238980829394743551131411876 * α ^ 9 * (17 - α) ^ 53 + 288328427720996697724483216206576565555295259358381796122313701494259650958770973285158322571941967268217143 * α ^ 10 * (17 - α) ^ 52 + 4728226481516661217868239930012852768555767163427788258399165321871029858334868657036824174585537128584095058 * α ^ 11 * (17 - α) ^ 51 + 68892078096367493868938707195995003059858819884647635693839050805569143627035213407543911684688112707333940917 * α ^ 12 * (17 - α) ^ 50 + 897489256219895957725717014821990251236531986784876454449072801996710996644666496224561803033929426140365957072 * α ^ 13 * (17 - α) ^ 49 + 10508734440253299052373528881880146721004546284790249412377062790386529187304727179044043353704708859442299500759 * α ^ 14 * (17 - α) ^ 48 + 111081473282973163902827719026653126099023149223026091072328009130583311867466584644887598351195354843454575061078 * α ^ 15 * (17 - α) ^ 47 + 1063941006387245192155551249879696393695003441753984944370011723535983307131499226741597118204956342316757068738269 * α ^ 16 * (17 - α) ^ 46 + 9262986013458072655807408147636790265923148648024710835072780996730402742732552216518640508409071199773338460467580 * α ^ 17 * (17 - α) ^ 45 + 73504432944628644806132381782654602892005780151536635377604343542798349874150577323370221243526662142861029485765267 * α ^ 18 * (17 - α) ^ 44 + 532852613339223838375512331827090700606511743950503229897754718887488029896868379807709267119939501223065295366693602 * α ^ 19 * (17 - α) ^ 43 + 3535814546782694307375152520118433313583952495849109269521484647041374707696487816679620238442969871612220462861303513 * α ^ 20 * (17 - α) ^ 42 + 21512685649336335238232172882299955129752294290179941353113200512198826289055015641521741143998370572855870359074246104 * α ^ 21 * (17 - α) ^ 41 + 120184751154982212109537129094706701776062091437923605319229141083097993817265572578568789467586467189277588039631049315 * α ^ 22 * (17 - α) ^ 40 + 617286849338083584591749927075053814330691243681016327221117622061037920401281200900095661642210214781389352540371769782 * α ^ 23 * (17 - α) ^ 39 + 2917821849269728689002023193436139836170048452644874266623784725971608066582467147212148057605900165316289226284189316377 * α ^ 24 * (17 - α) ^ 38 + 12704073587524590432537550601733909995628450893588885496540802041053069795718152620703039939205080151846264466052385716508 * α ^ 25 * (17 - α) ^ 37 + 50986252288170844090494680336411030634809274601549641047867345938670169429122180568151839986046629584836753070752554325549 * α ^ 26 * (17 - α) ^ 36 + 188731245384436542993876553440655528970657000032064943068315442235001403174655449380246936385673578684853218729590355262518 * α ^ 27 * (17 - α) ^ 35 + 644638862330020323974120509999798597971327969663585928073571369717884850872334505415491868174223509023103931648896623159239 * α ^ 28 * (17 - α) ^ 34 + 2032465294997125297900965524691015077382636066034389731503867693576128697782554799572131661348538947203921438149968717062968 * α ^ 29 * (17 - α) ^ 33 + 5916563574791151204959096743639378777667289023700421621098488569051297390955699005328526305783519890090961210344520200855839 * α ^ 30 * (17 - α) ^ 32 + 15904395842739942400691632117874198526447327814312513603909114134462651263485542388901837738413027124647322988507344907172326 * α ^ 31 * (17 - α) ^ 31 + 39480621688975930462788359812689019736710921053310451812820878220682147479485730376139224433028788139612764026510819938357313 * α ^ 32 * (17 - α) ^ 30 + 90498905447243483519998876972476498394113495417286506436759680590889186513026023767081117347518009234654646481535950533463192 * α ^ 33 * (17 - α) ^ 29 + 191523061794373512741555851851454724489150681013895009425168301404571522764467282969120404401773322532157478133115443560285302 * α ^ 34 * (17 - α) ^ 28 + 374102432352617119867752270588761366904228295175272818014486180253881707053636572216880029501969121629062410575837741541045540 * α ^ 35 * (17 - α) ^ 27 + 674163867855629078514194069974085158409299328199490452497247676315473162081360642182363547674290072742445351524110985068872354 * α ^ 36 * (17 - α) ^ 26 + 1120190445035094331280254183489294295074052698129528674820873994885643430165035917680757332898500267079209483615084452103804008 * α ^ 37 * (17 - α) ^ 25 + 1714900723005197968608097741871663993547860800425642883240541486610428452579319183757683479188744534283136109042046984240571814 * α ^ 38 * (17 - α) ^ 24 + 2416521455885624032995813409015090294329753742015754392681809119734841244318096451186191210367408907919148396327456308763254204 * α ^ 39 * (17 - α) ^ 23 + 3130667990811173505654112986656672677984543765718045066563298172181269932987292074370043542684045671485290799340932412432127666 * α ^ 40 * (17 - α) ^ 22 + 3723632079113581550914531608562041601402119257773277980450525464260286884296416621721582409231033706311054972465336219853088080 * α ^ 41 * (17 - α) ^ 21 + 4059377708897210330188497275486334922259944254887440167982165880025056118561927845076658189142750307922329495731330184747118638 * α ^ 42 * (17 - α) ^ 20 + 4048339098511651153484403478604219407237868497167064020335159037949103178704020226621821552775015074419425081166608975426397828 * α ^ 43 * (17 - α) ^ 19 + 3685125185916007961192554820161330975941990328916335627053257624724395938552675772827896673200200979526558921356874703197634202 * α ^ 44 * (17 - α) ^ 18 + 3054048224733814016209061368888708478509554580679361743439116448337817549920283187451853860165586457447146488334169873043392888 * α ^ 45 * (17 - α) ^ 17 + 2297607116406960807358259781678168246891645615834759456321137666589029442664420364955901391909484370982081566881227744010874086 * α ^ 46 * (17 - α) ^ 16 + 1563834963456883771498309022248496753805125281048581681606795606079693488022698265201311315270316165083707358234478370753591340 * α ^ 47 * (17 - α) ^ 15 + 959258589419178016234935333453270943911310250588295913774272713867179363938066640752243714741723229316103934660921840058331018 * α ^ 48 * (17 - α) ^ 14 + 527900112010660650248359261223300285284919503338654858382838983941810697808740176247054336097235620277146518114081044914641704 * α ^ 49 * (17 - α) ^ 13 + 259264801192497118934660971527450137059592143267324741721675524446679377229923273369087143487942107768190580548411748863625788 * α ^ 50 * (17 - α) ^ 12 + 112925257755528735753324539726634534462874074768785640447769616735919582936276633211358842716251496812674695066733945373630376 * α ^ 51 * (17 - α) ^ 11 + 43294208295108225572313363454714123552240387039341439399675327329984812526400837615036809250708210257269984868804715221768900 * α ^ 52 * (17 - α) ^ 10 + 14477109131118555980678814863672526273272305897056735808931397755854119363286698878099100454732834934400199349504635868575272 * α ^ 53 * (17 - α) ^ 9 + 4174569243543245209284931467152030006445783333411091743019898951807503568926775515227295551582461714654886147011664393698640 * α ^ 54 * (17 - α) ^ 8 + 1023195555636300366841604521638282501064465993225005460684172679015270094224232028670477159664015610240056559067645353077104 * α ^ 55 * (17 - α) ^ 7 + 209198594431248589503412319008039641002648327066847874065351685585470814434000466355080564735310580499259736416826148144344 * α ^ 56 * (17 - α) ^ 6 + 34783976201620581654146479854021503178010426501131959915156711925834764330476282903763164286902924648174181467158619488528 * α ^ 57 * (17 - α) ^ 5 + 4537117170708547774244512797745793493972596799818372048598224751094284949822133549967909771513344000829119085557004800874 * α ^ 58 * (17 - α) ^ 4 + 439587616858133764615021615831943232239201592269473877183402700593166522993563786139416926646861354484165239718064288908 * α ^ 59 * (17 - α) ^ 3 + 28864689907498275516712488927232990145839965615854349188000067895024636971944883064300818736721726097224141170690557182 * α ^ 60 * (17 - α) ^ 2 + 1070072225555048253521045141065543739116562978962155304409124790881546160712961916037048669936728578132382704101086352 * α ^ 61 * (17 - α) ^ 1 + 13265174660695058386402183278677678416743473633987916452549678002795064626597224750728225831441096471610791877259904 * α ^ 62 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `64 ≤ n ≤ 69`.** -/ -theorem finite_range {n : ℕ} (h0 : 64 ≤ n) (h1 : n ≤ 69) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (69 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (69 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 63) + 1 / (4 * 63 * (3 + α)) - + (1 - 2 * α / 68) ^ 2 * 69 * 68 * (69 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 63 * (3 + α)) ^ 30)) - = 1 - (5921166628153069906182512994534233525103737780111765545006313301263342851072677178740418956 + 61381176382803809362111499051840544591370805103230496041366966719316985769735186577074210428 * α + 307875927191106748261011216414410411442655519490352054541897661765849218694794523337461209647 * α ^ 2 + 995139520442941110972922094595461359252165093278183682740950849972307343163433414772266439134 * α ^ 3 + 2329135965026413320254515390788191269701711986947806984107173389521959680472053301869564187977 * α ^ 4 + 4205152400427897818943955614854872603184778207497298031576474014041708453522600564012661712908 * α ^ 5 + 6092227728539116602774802993811227514150357030998079498007336022099744281828374410394763218967 * α ^ 6 + 7273914911154976681674028920562209810638892503140251984517953529760649706898772999266377410618 * α ^ 7 + 7294841936549908246762850463172756077551550164308271524011607481986853316219925718877268241253 * α ^ 8 + 6231636865479569934304365225476315224178754021865462499626075023963516933948459908031199504392 * α ^ 9 + 4582454355475931479184872096047779444629884546826401854025935798959693699768306789254756052107 * α ^ 10 + 2923936751602144899711097457334391073444202579871680510494335159924208835914470439635141162662 * α ^ 11 + 1628646305582237968027987059869036927850582412822128278929774316093217652148166106137543210729 * α ^ 12 + 795445013477937519140644933077682364729772242866058887702125127747950219835128702530435684436 * α ^ 13 + 341732386485246488082914550033328759932103344872452353652503157863279852435899383534716977739 * α ^ 14 + 129398024588904114703104106088147845845858920384624466782691337832071760366611282163240673066 * α ^ 15 + 43227083179690319937679095035602516318669269367605716008461368393810348604333859857847549497 * α ^ 16 + 12739734973954297734917244488839138405165723257781387930800239709000470619130237106664340656 * α ^ 17 + 3309003690560409027996242316235318569343087760556101911245828294749346009825368969657069031 * α ^ 18 + 755904091146328721648601114370911122594719522671458365690647375941659996310302273197058470 * α ^ 19 + 151378877572074703874732245694134372432105936678872727794384094115460812902730719423948317 * α ^ 20 + 26454923472459858634887234579799069438230123457614797089205636430511024677434784809220924 * α ^ 21 + 4009557348845189672922466111254379827931543987777056770742617262249980072703900044793759 * α ^ 22 + 522684797686516768766815870526767734538930901093141236380109988654434790535464480525226 * α ^ 23 + 57960196328928756537267261570029521956658673559059668642752896597993471772708261591453 * α ^ 24 + 5385398873189231308982589874195610465961820936268053590519181757629535422805253399024 * α ^ 25 + 410397478215636804806491132412571076795910317178146076050633000481647199256305822637 * α ^ 26 + 24812014519928905914570908638577043729393183935810050156873373621420956394826529722 * α ^ 27 + 1113510388782381458493062026644349844210314014993864209186922164992790354371374639 * α ^ 28 + 22409773065959463084902151065290205378008886892907135598840606673031087144995204 * α ^ 29 - 35763698158235183891226289780431937498580930947719484832564827737501564744289629 * α ^ 30 + 840760995622979288098811692316543958334461895228266842721825922823541893315826 * α ^ 31 - 2476024715094217195652794819915917218077074423531979390443969076889551332351 * α ^ 32 - 42343131706354479044867362267674031525737275327352243122650061208773859828 * α ^ 33 + 1121663574053726688315155444107301037632747178037371530068223719748652900 * α ^ 34 + 127119237016866360421264159870103175079883989461074891879168221493189568 * α ^ 35 + 5840998162333194724309799734276135965778520891167491660434664446065776 * α ^ 36 + 175992443424517154194105688439948495022759467456834921814514733630912 * α ^ 37 + 3457340410083421419722141826010375932802380080806011689658236008128 * α ^ 38 + 24387290416155856471527726331603437910487483092148051628143522304 * α ^ 39 - 1239885867289330313685948822187720768399781886302021720494414080 * α ^ 40 - 65142911505809786191440265839050522466645141325685819456216064 * α ^ 41 - 1919845972367683574507152058644769097612240398422850416591872 * α ^ 42 - 42690755951658679674359660598349223111852496540029559373824 * α ^ 43 - 774277941425789906408100254236527798872560249769923817472 * α ^ 44 - 11837447748695307877084872298248109006399402655405555712 * α ^ 45 - 155160542836944884945355229969272241433459624584396800 * α ^ 46 - 1760282021481048069096957321992926156742736627499008 * α ^ 47 - 17375591117616735181132725973057892264379050557440 * α ^ 48 - 149596040045196039764745879558857285877770747904 * α ^ 49 - 1123758519054636222507004226738421820190097408 * α ^ 50 - 7354587732063594511120345756955829080162304 * α ^ 51 - 41799839163275444256118641007392250134528 * α ^ 52 - 205261854328197847356177208926730715136 * α ^ 53 - 864576623781254196788511741560487936 * α ^ 54 - 3092645524632136056284929849294848 * α ^ 55 - 9268224902397535157105681498112 * α ^ 56 - 22840148173664707695687499776 * α ^ 57 - 45078822391172061959553024 * α ^ 58 - 68515609003558969540608 * α ^ 59 - 75294374818201206784 * α ^ 60 - 53251155240681472 * α ^ 61 - 18200997658624 * α ^ 62) / (13124052596236045911528558813876389304261669684415149295591106226549152703744 * (3 + α) ^ 31) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 64) (n₁ := 69) (k := 30) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B64_69 - -end Sendov diff --git a/Sendov/FiniteRange/Degree6_6.lean b/Sendov/FiniteRange/Degree6_6.lean deleted file mode 100644 index 1414207..0000000 --- a/Sendov/FiniteRange/Degree6_6.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 6 to 6 - -`Sendov.R_le_batch` bounds every `R n α` for `6 ≤ n ≤ 6` by the elementary part and -moment at `n₀ = 6` together with the prefactor at `n₁ = 6`, so one moment and one -certificate serve all 1 degrees. The certificate has degree 4, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B6_6 - -lemma M_lo : M 6 = 5 := by norm_num [M] - -lemma M_hi : M 6 = 5 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 6 α = 1 - 2 * α / 5 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 6 α = 1 - 2 * α / 5 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 6 α = (30 - 1 * α - 2 * α ^ 2) / (10 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 5 / 2) : 0 ≤ c 6 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 60 - -def betac : ℤ := 17041 - -def tauc : ℤ := 23949621038340868125 - -/-- The moment numerator at `n₀ = 6`, `k = 1`. -/ -def Nmomc : List ℤ := - [30, 154, 8] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 6) (gg1 6) (gg2 6) 1)) α := by - refine pev_moment_eq_of_packed_bounds 6 1 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 6 α t ^ 1) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 6 * (3 + α)) ^ 1) := - integral_moment_packed 6 1 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-4 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 4 * P α` is a positive combination of `αʲ (17-α)^(4-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 5 / 2) : - 0 < 1575 - 900 * α + 2345 * α ^ 2 - 342 * α ^ 3 - 24 * α ^ 4 := by - have hu : (0 : ℝ) ≤ 5 - 2 * α := by linarith - have hid : (5 : ℝ) ^ 4 * (1575 - 900 * α + 2345 * α ^ 2 - 342 * α ^ 3 - 24 * α ^ 4) = 1575 * (5 - 2 * α) ^ 4 + 8100 * α ^ 1 * (5 - 2 * α) ^ 3 + 69425 * α ^ 2 * (5 - 2 * α) ^ 2 + 188150 * α ^ 3 * (5 - 2 * α) ^ 1 + 123200 * α ^ 4 := by - bernstein_ring α (5 - 2 * α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (5 - 2 * α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `6 ≤ n ≤ 6`.** -/ -theorem finite_range {n : ℕ} (h0 : 6 ≤ n) (h1 : n ≤ 6) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 5 / 2 := by - have hcast : ((n : ℕ) : ℝ) ≤ (6 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (6 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 5) + 1 / (4 * 5 * (3 + α)) - + (1 - 2 * α / 5) ^ 2 * 6 * 5 * (6 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 5 * (3 + α)) ^ 1)) - = 1 - (1575 - 900 * α + 2345 * α ^ 2 - 342 * α ^ 3 - 24 * α ^ 4) / (375 * (3 + α) ^ 2) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 6) (n₁ := 6) (k := 1) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B6_6 - -end Sendov diff --git a/Sendov/FiniteRange/Degree7.lean b/Sendov/FiniteRange/Degree7.lean deleted file mode 100644 index 38f5e9d..0000000 --- a/Sendov/FiniteRange/Degree7.lean +++ /dev/null @@ -1,110 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Moments -import Sendov.FiniteRange.OddBound - -/-! -# The finite-range claim in degree seven - -The first odd degree, and the prototype for the general odd-degree argument. Here the -exponent `(n-4)/2` is `1 + 1/2`, so `Sendov.integral_rpow_le` replaces the square root by -the average of the moments of `Q` and `Q ^ 2`, after which the argument runs exactly as in -degree six. - -With `M 7 = 6`, `A 7 α = 1 - α/3` and `c 7 α = (18 - α²)/(6(3+α))`: - -* `∫ t in 0..1, t³ (Q + Q²)/2 dt = 1/4 - 3c/5 + (4c² + 3A)/12 - 2cA/7 + A²/16`; -* the resulting upper bound for `R 7 α` is `1 - P α / (2592 (3+α)³)` with - `P α = -5α⁶ - 222α⁵ - 2619α⁴ + 17388α³ + 19413α² - 5022α + 33291`; -* feasibility enters only through `Sendov.alpha_le_half_M`, which gives `α ≤ 3`. - -`P` is positive up to `α = 5.338`, so once again there is ample room. The exact feasible -range is `α ≤ 2.710`, cut out by `-α⁴ - 12α³ + 108α ≥ 0`, but that is not needed. Since -the odd-degree bound is an inequality rather than an identity, the loss it incurs is real -but small: the exact maximum of `R 7 α` over the feasible range is about `0.598`, against -`0.664` for this upper bound. --/ - -namespace Sendov - -open MeasureTheory - -variable {α : ℝ} - -lemma M_seven : M 7 = 6 := by norm_num [M] - -lemma A_seven (α : ℝ) : A 7 α = 1 - α / 3 := by - rw [A, M] - push_cast - ring - -lemma c_seven (α : ℝ) : c 7 α = 1 - α / 6 - α / (2 * (3 + α)) := by - rw [c, M] - push_cast - ring - -lemma c_seven' (hα : 0 ≤ α) : c 7 α = (18 - α ^ 2) / (6 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c_seven] - field_simp - ring - -/-- The odd-degree bound in degree seven: the exponent is `1 + 1/2`, so the integral is -bounded by the average of the first two moments, which is computed exactly. -/ -lemma integral_seven (hfeas : c 7 α ^ 2 ≤ A 7 α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 7 α t ^ ((((7 : ℕ) : ℝ) - 4) / 2)) - ≤ 1 / 4 - 3 * c 7 α / 5 + (4 * c 7 α ^ 2 + 3 * A 7 α) / 12 - - 2 * c 7 α * A 7 α / 7 + A 7 α ^ 2 / 16 := by - have hk : ((((7 : ℕ) : ℝ) - 4) / 2) = ((1 : ℕ) : ℝ) + 1 / 2 := by norm_num - refine (integral_rpow_le hfeas 1 hk one_pos).trans (le_of_eq ?_) - have hfun : (fun t : ℝ => t ^ 3 * (Q 7 α t ^ 1 * (Q 7 α t / (2 * 1) + 1 / 2))) - = fun t : ℝ => 1 * t ^ 3 + (-3 * c 7 α) * t ^ 4 - + ((4 * c 7 α ^ 2 + 3 * A 7 α) / 2) * t ^ 5 + (-2 * c 7 α * A 7 α) * t ^ 6 - + (A 7 α ^ 2 / 2) * t ^ 7 := by - funext t - simp only [Q] - ring - rw [hfun, integral_poly7] - ring - -/-- The upper bound for `R 7 α` obtained from `Sendov.integral_seven`. -/ -lemma R_seven_le (hα : 0 ≤ α) (hfeas : c 7 α ^ 2 ≤ A 7 α) : - R 7 α ≤ 1 / 6 + 1 / (4 * (3 + α)) + 1 / 12 + 1 / (24 * (3 + α)) - + 210 * A 7 α ^ 2 / (4 * (3 + α)) - * (1 / 4 - 3 * c 7 α / 5 + (4 * c 7 α ^ 2 + 3 * A 7 α) / 12 - - 2 * c 7 α * A 7 α / 7 + A 7 α ^ 2 / 16) := by - have h := R_le_of_integral_le (n := 7) (by norm_num) hα (integral_seven hfeas) - rw [M_seven] at h - push_cast at h - exact h.trans (le_of_eq (by ring)) - -/-- **The finite-range claim in degree seven.** -/ -theorem finite_range_seven (hα : 0 ≤ α) (hfeas : c 7 α ^ 2 ≤ A 7 α) : R 7 α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hle : α ≤ 3 := by - have h := alpha_le_half_M (n := 7) (by norm_num) hfeas - rw [M_seven] at h - linarith - have hR := R_seven_le hα hfeas - have hid : 1 / 6 + 1 / (4 * (3 + α)) + 1 / 12 + 1 / (24 * (3 + α)) - + 210 * A 7 α ^ 2 / (4 * (3 + α)) - * (1 / 4 - 3 * c 7 α / 5 + (4 * c 7 α ^ 2 + 3 * A 7 α) / 12 - - 2 * c 7 α * A 7 α / 7 + A 7 α ^ 2 / 16) - = 1 - (-5 * α ^ 6 - 222 * α ^ 5 - 2619 * α ^ 4 + 17388 * α ^ 3 + 19413 * α ^ 2 - - 5022 * α + 33291) / (2592 * (3 + α) ^ 3) := by - rw [A_seven, c_seven' hα] - field_simp - ring - rw [hid] at hR - have hP : 0 < -5 * α ^ 6 - 222 * α ^ 5 - 2619 * α ^ 4 + 17388 * α ^ 3 + 19413 * α ^ 2 - - 5022 * α + 33291 := by - nlinarith only [hα, pow_nonneg hα 3, mul_nonneg (pow_nonneg hα 3) (sub_nonneg.2 hle), - mul_nonneg (pow_nonneg hα 4) (sub_nonneg.2 hle), - mul_nonneg (pow_nonneg hα 5) (sub_nonneg.2 hle), - sq_nonneg (19413 * α - 2511)] - exact hR.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) - -end Sendov diff --git a/Sendov/FiniteRange/Degree70_79.lean b/Sendov/FiniteRange/Degree70_79.lean deleted file mode 100644 index d350358..0000000 --- a/Sendov/FiniteRange/Degree70_79.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 70 to 79 - -`Sendov.R_le_batch` bounds every `R n α` for `70 ≤ n ≤ 79` by the elementary part and -moment at `n₀ = 70` together with the prefactor at `n₁ = 79`, so one moment and one -certificate serve all 10 degrees. The certificate has degree 68, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B70_79 - -lemma M_lo : M 70 = 69 := by norm_num [M] - -lemma M_hi : M 79 = 78 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 70 α = 1 - 2 * α / 69 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 79 α = 1 - 2 * α / 78 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 70 α = (414 + 63 * α - 2 * α ^ 2) / (138 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 70 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 79211881234889091923261227200 - -def betac : ℤ := 3278195267035189732574107128719797489600321312155742117491270208073267246210781686792718452029143697184594291832651357836033683181115801601 - -def tauc : ℤ := 151469915988328255991360112134687464898489568653334568690191052313753163962171747756523194012094160152430044758152209348095715428681922620437329468854124777206193600733741547517844893332020566520916364109975824081865365338199917721355542498000586283045006572680221337120011397113327983832237857955140958180044560711833986571100725499677328788411349374495817882090096014875888117988374120072841089577769295003797161312733439574219621708510346094683690970956905039604282505503511607737855742089542072234627935360380600468390691103869229746026296920986133753215782343427598336098134669054723362682433381593411083089469150370086573477244243791018715168733591319160383560780233379197719537531864382565577857065222955225713962696955654884961840544855060038149293707183932670893760397125426769409886148953015366386779238708714240594276766119008455393969984713167788675338848595546817781843524952151669080720874150878584565582203331103287869447346871792419544083545958532626694880902428870850325437958674823764637282349221636838682993344695766626000663064939150030985829652322495736945983656754163798816238102518262469226879176468426049687886034609689697293189826308150081639998076423420441196454548393111205819401288589419765688818841040619685063443817007931109625771016266526865459625354351578507303907825962447467581935638484452394820350210482554804006752884523810704277205318244983570747045343192058265160467122960127589489746029533415598201583957765663156780153140442272561007534082581369812757076445056810439012803923790641922188932016664701101440711043084659341757483000626979506752942322513574314083429624985150214888660285018804403242539115712857554992140474923520785669314371049668502595309630634218896797999061983651315587596498741026267827216018395001605520423043736163744537119103833789817065641587493785178666603564286032724816035475743260308637264970859774860446556927973178243812766577923350999986233705126734289931303319290582337309102953828826512126797850052735211656930695987419749393533190368860092537730631071811160476365637203307792526692919551540342922684562689791049970280326279355373233661318953174849662355165050040405826027024856534121015829791440283407688064605000334405462336603587760510425559504374426460350988459685458417434512217137078807711502373679662639363860931999207101147417850213599235396073641372699294558818871293814195907839553060912920000162836634780464723720481925635142588570196141176342061174106373479485345081028956818052917899725720913886840171107020011682017588218505016859459233210109048224804603932820885908085255849461737452338861169574074379187773637762339400790488802958768099265850947157163761292200514277059465425814445192332351037488787821816552098330785559704469393619154134106749790230481932281476853265528402803157573114716434138638692799281409069386161098753580817891471407562556922322402676968992525860805766181382218994561379979629186217456283921498213870341437051193194330207864308718354259527217448769180167758442190242387412871506895815420477085492961327294584257756968469423154422913579295746578949081148997682436072634564255445555388978329549211764190216012992024722609304857949802677206462570348464720376964580049796312192668619179926564474133602875631983340141994928847851778650283639850907423571053038525349996941897644419098811353542762363204735114629644544906989747976262933715313907080017706397646898446090407335395314548874914560681699388524971849648597312973603752298180998303745339492698809371192676724343538742994173407467707258310962378871610981022605915392919257397876327919887143338473917095949182434399241515148938039567842280615422042011652583541051719895004952490368833749754880698329357189883827449304387903250481284075490272187765797052837255426078162951831217962172716011106799826117032496519618758829329964032874487717358566334661936681375485292066805506355974625007807581655006179616508070258928089744499386206425611872952625208809820115650308212604139986601977764229350995549319423635336978329229194267653161179067221103424518174075453703754783261744192015109486782838946907514915825180832070714785740828439103923020419711444275362104687828676828746813790230406758661994370860743038282316902503477852136406489088035216528515061047954952782226431108945967569578309874541813759684746962427778533092444375174197382777007872026837773534543477472337773641358911301747915148137599786456570419858363083255855965086277085189836534001868160197378718601858494038084008325169717066309037208616381546186893916199053863750785695834767503117352981957444450321350647844481367601672411433069397362279959930005031994655089010460094711885740056116469536105783457613035973229513075877765310242451391237913904103545640547257160539902101951376267834763200639386801524170421140574824966822195459010418500928988611551666461851548708422993579460042880190551522919663337626709149829210394325290525252028859020447831937298656210880848882391569737103320008299312456734523378905098475936575019534270118857514598590883044238523538404173726300584553182558123360734940908517513184437630496445293955091917614417004677667411214157714820379045640777757577726756779279168304491377956926086637417543273880413741354498726785978892172519372287400075668031431706782760491440637395329738954714564999903676272209157795446960676134537544935695866584804359138437436907588119397542119092651412744361854583780237047144075545266668475712339973985673020434482384964862501058763710227313024022223554353748382402539661039168059752522672688329766473751599948700650008408571334136463329842132088722007948791804345304638735100855935607303623092903640071289071301076784464692813492490121982158523744048504594014391165020373886432582672051815131276685311040334577609334552916992592813034282002154619964826383401500932788129526634403729005985339936773762472870463267936557775335498765939674921273558465167734688101453628134791443189191764657654066813639132507382767992993918461007602722370077542011411047428483122289924331150549352564406610209224806670630532871232299370265079595253525222420679212864485099707370581466543255420763543219481000573953047654898626031685649188687628847913399130315498765426469190313680734971793347729414886225006801689202962757076052044773599160032115965144323334580878727690651967963107552407293964999132125788296607365244474460519321697057243740125711631254691229058158706303522316305407221644535627956457294879617017888294031848704766905500825735684285427690251361437266311692707293427606235993987346293175613378768655970904894038028615056952059541364327200900800139632714289437252422315182502241653834867391064411637425172314542467098240285620445451319624770672915714919822088474716767375576394962308767780942134483592844496613671329248051354104480034724632387353960051582569142220308788145850568025788037186984457185549680263301888125455259981250206854745919666895691051365855085821604578431854327289435100481591408026089241512512028198367430316873015843578161488546471038396003552024583119300794764087576470992500551277255058751953188962213525549155186808136411452567753627894987978830335544415030263059958408064077088138714835619473776623496942613595655091386953000110390601857823860258232183020734733992258909083872230655014856060544963916598007337118184656504173282035199499482499720904842290320312573890746376685016978654923562624959051621024881616762701088371310499960335534853884625333662710909209564252204989737114117465583178565651544866533260923683726569014560629892420675470931139602579028623503723002910474652064623404685920033955460350383052516157190838169535462596051964020410192393222930522990829609256622714589706734919198370371802413849611863650151573366665830639528582648807092089698240252493463396217727568695904679171706295884633362220557297420550260896383419756107548215267301974701414224191120328881728779375621809039584990428722041435033421197420691165698560259219134128906099328381595604141345471231626960737973926232858033939733721149224253132867550746383472545722716673007477998840911379126402766508295614972893387055076977784827997420069517801079730943379483000769907120212706271835613467238460555611100390276040319682894038607741988858052101981880010193044267416641489522217526639565245773953899831531057895375350844962487071241126985017456690727755750135496028247184498275275047413499587270891148961023662744006088942707484840539864604315612926991826044262801270775284847293681566006793933813074187525592135685540417063031404244765925311939245080948557482707725039156525283082645875882257430920676541273844279983982803731537192336121844870161959859660017364395744120557827560949970191108070215629501704098324816363766504659587460072708641500477618313147020149473810613291299126925390262410358598946976568541181371416426790905897737639357563555684801972547284183988625826339517445066157706537415335770555021066093057327017905620176418208363974793204894914705593451134916914954261767926939694167158365107248360305775883442258793817258578546091034733392155231660273802076335905645809307453938570205722244721781806477912022793946075418933863547845539254001068193962101644279463894834887910008941634687787809935054255118371776591587873065855607221485044426567601307221425920123203400898900719242174580162194294190660668147257336857119676442030941908837225507045722755857072867460108463929640847130569167852156275928372749112386479056596423831199836489284213502534042226607349436495337414232214086699395212056312234372487897090049644298717993639484217836864289413407677458194094999651940962698643361084146588411977476583129704476156886963859171492333138028039973794510375133730649191869401686780925579379087713145774541066572117535457642694363433951260614871836619920687544423806196458940661237375066559971983829126752537703384278319860451092699803732008170156523596971553064087716059924382599997701131387552418702572116770774562270444589250689268693052706447009657395190885078296376441999184918669560524761327369680516743291287750693337422983171546400399619944268524575232877230017409237723819299948530484749657163593832966189383197880725758148884234720193904951235685590732247313219249174189269265284165488261427522362917528143502266376283389061398140474433431313797267050267173215150010337824413243454334637569308049666413183952503370281381457504878388623179306991217517526603612917732232501785600076036317251785282923914234516351827185397602763472715704778437249508023891683027119573992917547123046093396897433819533127220921643304741159066282996745027515916967995633293795006084910572856938564740785846001377823114902310646682784877392721850332397917672754587485793811917577548008568505259768986100333851441756189245457690675481646388838975479888390954939261463032444785371886683408042116401205155108211500627381562099519119090902091100339497590659142961283671332881420233285364826529185182477846878602635923122006221329221475418450955892742098508022030487241237165706489880104499036787712088204850429534184500508331553364744415819032291384616610238871064051140871111834240068052759256519667395476253389198760642845663513743423593883858782104079926663851895360995609894329299971088474787597395297131245725981970202752893543356753775082660790013082255957350793974305148185864567514812758364637476042059165201385427866920416644050888225934028348540116268647253634166850896531788043609960398235455394607381975602809247049457259095348453482886852147324552331016957233511197782053270593522235771726105612708178995524043574503560313118087740054747685627330129539640666170208454534517441310266191377014767370828885084330770231569301690599540630922605088802583801468447171624267793525736141176993354176963684332413835116655675358794587685105791033783922626194190816324579551807929673845197697294838520146203368586817158649957417118881626814717799978683028361965978431082907487496796185691148196587599553724530050414208800518702124032993241434532864816454114866699565885208512240253518315952295829659952302941257624056291610881693422349842799370074953778046551214516344115772502239211518414627012910172630491905563152427695533048624615270741232789590713138359677706343091016404634545596987154908552600144861386181960516069340650788037182488766956681104042273790747515248639108878232168450850721939156329572030815765625297289591696003889644272387780522512337448130481022272731407909535712450885717588680721207963515966359197568299664115078899083955971699493798895671356762509299526309880663130773131660396007422160877906522176550715803507041884119502703332925761380409167804604981437852626073359816276191221072631039763722387698769707262914478639994882223837790094418228537468868175658077089101363874099687878829817033108389414001607313898121589792843838441105150658463015937265997757786211402222839530373388954005866228491650125406920728244806337149023312235092908679926727896651316823201272380542109132552071633124288370294851727378500064410056757115453654474284025642742719446836613312249497946546479243266077669169572830919513572296124437333713669062055745992907942730720399514990461533353627112998354887024910968514192103143871220132626335015152224633142181712850342338792430155046136500242028945126262109984942830706041292467721131680256560333926500839365535596157438764383099571525487134472296250623409228669503130802897829923368695190781729165921060306412248038502259288294146480458412845726664999883453661825291985265182972846003114747628947886650240137080141609515046734086263916207765060120123671347772176387741774012128060720568298365726963549974420202477034470230022021805915854666283242979098085606965846776789225352792925918586378793657679103625349092970432278183634502600497532338168829468196155243532947655219363812449167501108327271227321581477162983820707060679378846055729127327564232139198805502305244364544169422945339564484104764764226356807267251569189759985252522208723305064264588464043534963184236413100857234825357860000051896687815033699433014577280446969497510550098400157496544552959903587828851094122435517589857803219841991395136630088315625933897729 - -/-- The moment numerator at `n₀ = 70`, `k = 33`. -/ -def Nmomc : List ℤ := - [4959318365057365747547303994591327832101812039936199035096598697228765627224336854985615458865610570554408960, 58400534994538410692689155066742693300436388604064738470150916431245765128618361426101511808246872304087203840, 333981308828561223540237456642268557659818260425865752309410402034820677596071065885171155061614492835874078720, 1235652657246223352269146644533457260647596513347272659602243862441763259821486388239768469857550532752787374080, 3324212152492263270427971204935632558288619516499768815672259773217264225029708553947569846905013508575057674240, 6929460330022416915039530177479122612080069078655269169137306811497480319851470622084440536629257622168241438720, 11646658646758649331804801011962166106488435113914891811672962810590153652697289453224437368919814253188554424320, 16215976580113365450441077812790799608367636548091437595194119680412059248458769076809594772623831741146784071680, 19070440704967449779810447365185945815903177364185860364869550685135921494626010942081847234957609675904065208320, 19219346790987745549333467077138953124886955996209080019039058216047018672630661327250633549763975332021151989760, 16783283438268192202422372039398794598660614069181108173871844273360907282826888374998588982145483015812326359040, 12808596149607273027811914574302044749858116188157616304562644121763714502030389322637081307080536171064223334400, 8600603800357077252027766066874670269685687258306174203645029960380495140829070942500414174219329559366803128320, 5107919434511249151729410245336123103072895720601271047928135620848109815597448201830251892905121735248424468480, 2694156436237477139073015322447397952188537668327879663880230136314194438967496449175952609173750970864359178240, 1265956532238906098886839036308868529009881980165706021474086620532642250796696505482990383681275888933514772480, 531159223667219476941175042727426502223382964057719722309855950028863685071210761002559455052276234612794982400, 199304307974335458807042602553448267807047567652980257079144659784457777508584622143649189391510269515467325440, 66939987658443118457093003155993600040819769199480754828651878306579403848563472052179937447883653890871132160, 20130743296949748412276356292504162170166982615509965519754820243461341726136033683812476742939818984137031680, 5419021240856258008600426399954782144275564692470589826205455451036862556724230115786790304302734902380462080, 1304716161087401565419625709879908199549671054362325441363588153956090302406406480679082019181840680741765120, 280588534504488882345128770108257755902112595805030146995434848250312018793926963400459356665584069388533760, 53802126161260056266281112024845383973275588709943585550795986389033322534755799168997453842241558927114240, 9177817899191595703646851805652409279830334498539883041511548598487876610920128412223193814048536705105920, 1389280490789730746144423418024826761570735913418788802082210988692371165046288136998552641211340569968640, 186125206006119280108189150165526721680656362505578262067856798158857604463462627520638196537406521344000, 22017099608120584045584130888492670685936944326442633975679266617039808325443120825946731651496274821120, 2296471680321753890865757797277432456692695865952140692971217211565936329300845736654452751476855930880, 211422808747714029451197774017938224387154012702865413249522304800871312246132553797184509458608291840, 17296818871127112472390092357783675175855460221406327277919239749617854118355249253213617694619729920, 1293343079440150041846387946125479637106289789691379216954399124264721900882527567949942588828549120, 113398489132577211058184314618753833519811459551186541075202897556778706925280307883745861309562880, 110149962850730371602781749779479289899329795265088577924994405352397311616615459709453394792939520, 3615273324466369934279043292791025662994787391631150526666725307227467916730036591562662986383360, 120634552455680385726858425287472974974000059911804289072730982420332392835346833134741933260800, 4013840782459306478518776023046613332575016525556139933368310602982499622969579784503925145600, 129492814314667232688006526272455400774033323851722088400632951959031037805448514596188979200, 3939792840870932743155686422875194554431068733109362059461795062709325883958818240882278400, 110637059712870622722268088559925994368272707184823088440411834437932716145735683276800000, 2827552126743901066860202768371231315462095632044905949594244109457723015003929900482560, 65234165717275791246534516489763458069850538723709515594520537411039263225628925624320, 1352986618482973642804787730316205346735037818072031657322286896046006587392367001600, 25182397918265868047706847058383998812031910546417734618020952362123163423945523200, 420413867798212684406686692845793423531025226684313267409781612750027386729267200, 6296326499102713587013326483953985930372847767937956204510678026825782662266880, 84617924407775711830806116122309047323930033996805690712507858758798661386240, 1020719248166341955330673001725059914733296533848040134020589522312578990080, 11051510464803813805147119586943743163125113435758730520075370173374136320, 107364793804661710782815381725256668394996648171695949406824156847144960, 935179784323229803507804061677088089083173589907266290563502718320640, 7294094458960184393702956402417679396550866848514002587367306690560, 50849777021567815493800364438543315582304924126344626435082158080, 316049482819089386242459746425234436825372479899542291920977920, 1745561221878856550927602099561410074611156277425145968066560, 8530753263966735323025993834102720054787419954479187886080, 36692166582558708349053343241744524713075646327160832000, 137953367238920151364824025523822895903207572153303040, 449471141724124073206288748518782684885678198620160, 1255022278023425441662568391976035905150889492480, 2959862528263970605471348550824008149159116800, 5782359216112393599755834000643528830484480, 9107221093314090797919750761801979002880, 11112874270007015506462441140985528320, 9858573830889557277250390704783360, 5657043925248177874815292538880, 1576107522532054851240591360] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 70) (gg1 70) (gg2 70) 33)) α := by - refine pev_moment_eq_of_packed_bounds 70 33 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 70 α t ^ 33) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 70 * (3 + α)) ^ 33) := - integral_moment_packed 70 33 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-68 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 68 * P α` is a positive combination of `αʲ (17-α)^(68-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 + 55048255682073709607204036059519252499577954075805344228144067353398773939360654388786551620754044174 * α + 303631470940991973002262259034385880105972184753330155102383400602879297569999672180560254047614733064 * α ^ 2 + 1082629940665673044764709543433093878486364849040990099597525143450118708087349123259727336344728664544 * α ^ 3 + 2804599610843097204574458002687246299093134788634086599591559738125527989079685417982892820063924460373 * α ^ 4 + 5624645401139815516982667151087561797773568501921017826805664176655117168979590819326893993434748481137 * α ^ 5 + 9086529173583154645809008602511982564716590500042635425568606924621639922909196505882243392404835758015 * α ^ 6 + 12147764349688852841301807848655896145357577978996235836231868297037709466427619171816150975300099741791 * α ^ 7 + 13702180594674637952993181456614636961007303430300258709825461099491823680923881039132440258291527607905 * α ^ 8 + 13228790758953813166525229226864556895698491358332563699351209388421354345605839944544173983846341165317 * α ^ 9 + 11051940590803482762640027098441612629424377433949792947689615004158487742382763237735051674050718363307 * α ^ 10 + 8057730499045200268719730173861520782106924341107579339386385608691893710110000816392557161453112592131 * α ^ 11 + 5160484214825899033659577721795935067593212006301594642310233538545527417677809202356341306165128799909 * α ^ 12 + 2917926196608374844731210581375035036343917943893823360466936440450011366221495240241631678212028102353 * α ^ 13 + 1462315101539635752571716649246230545438507378471968670138935884045737693317302923326515165319274353863 * α ^ 14 + 651362758608261532683053553948901251603409142895470962454343186012266250060431761761109117155529185351 * α ^ 15 + 258382911131744978730219354901244362207736065992848531597126642760778004801626888171716412430540285505 * α ^ 16 + 91380564667115290929103952618176877475251392601510902630099986346625474504164568221576682912080867653 * α ^ 17 + 28823701484229764785510610641119924329640879766929838579606063832811514346965585992079347095184066891 * α ^ 18 + 8105512742405337827384222403832648005310429131045055117867656987105207137736030417145103472632533011 * α ^ 19 + 2029737755516453702412381601616827618446965035012177295868811221050918334739516968406653005043323145 * α ^ 20 + 451715825606281157427809648282481163078916909506829474305720867391455366362160566615805697668034469 * α ^ 21 + 89083872539236033065296789508746088826183108150642030163709620396857932007741467883529598127701027 * α ^ 22 + 15507062046600275350060333043623953591886937497826357117111310333499555606548238470938828041232307 * α ^ 23 + 2370291817598182097124474831710334939044419386117776585894929734754031639676722325611554692802929 * α ^ 24 + 315999149372391878452912834168990330419105934995500914232394089420371940254905369886539160346853 * α ^ 25 + 36423009146013699028116153780709317964569427476167451734283550363318237494233399180783337169695 * α ^ 26 + 3588163263018483116273779737008794180190405472634090416966530935626554841121047871569879767559 * α ^ 27 + 297471336921909919923207632811348664497121895483393172379791904969696166207311294171026521523 * α ^ 28 + 20305725467845794109711961738383951154160346509672805134214469944833591189715035234346686183 * α ^ 29 + 1103609488904163566431208273520751297004151033048526881874218221163688540301268998957942157 * α ^ 30 + 44705334211106925450419755417917993038028222392715074881553657780646344635657758883181805 * α ^ 31 + 805515192221430510609334948188870016650885857492958289044650012247928862875245764497551 * α ^ 32 - 1482048260833901649795245609960707851397885375498496335550472054736679501095164961700205 * α ^ 33 + 28550595118000674813695237772389123615483889198973830073821326304976753853122397016687 * α ^ 34 - 110293125322577848844861697626305509333317224753061067523753150512274273997930489889 * α ^ 35 - 2944264371932464496615000679541333014546134952187144901035323438838119921163626816 * α ^ 36 - 42753460721496719482279714802299033215763752656049106329252818812714655687701920 * α ^ 37 + 892039301043622007789612879017665871347081871863607139597567473234375585298160 * α ^ 38 + 90290182213750286064408757160215991459134539105309106871418780497371434069600 * α ^ 39 + 3686520145576645994835054065141215370192750469525569878892121423026501980224 * α ^ 40 + 101266458446089775184406440743070690042012917626596066692722657223969408256 * α ^ 41 + 1921165999972257449345542825175329806471062302564814176599267497713370880 * α ^ 42 + 18910079844664677393253742829163990204177395135122636437886747825783808 * α ^ 43 - 267203790007683385371238236401248869931744610843957702759988424811520 * α ^ 44 - 18630321688593096100250955298980358254132585106002718798371125157888 * α ^ 45 - 549431692437424587483251682306834452811394511706522157550126837760 * α ^ 46 - 11827470008686810839474011121751705014739559837533303829463834624 * α ^ 47 - 206601161707202641093681870196336457333557666704999087205793792 * α ^ 48 - 3050100062225303864539589793145445854252294435418792706244608 * α ^ 49 - 38831214153718995312467487136862135070778219830730009018368 * α ^ 50 - 431130925861351878296650698743841679980168113965805076480 * α ^ 51 - 4201734530680545401568837521217272752627836979325435904 * α ^ 52 - 36075335848543051909606823878062380154340083870203904 * α ^ 53 - 273302433216495374400156548854470569604061187801088 * α ^ 54 - 1826924843542958932998763336695299600883344474112 * α ^ 55 - 10760219439515367849051421269035765266542231552 * α ^ 56 - 55683568301576061216924181665153394893914112 * α ^ 57 - 252108560765968990302771636780305076977664 * α ^ 58 - 992726472130728702576289249214808981504 * α ^ 59 - 3372896548691756253399508431270838272 * α ^ 60 - 9784355714995137510417248525746176 * α ^ 61 - 23895590924284630456363042996224 * α ^ 62 - 48203390780462373975323836416 * α ^ 63 - 78197438735478405231280128 * α ^ 64 - 98061705121359087009792 * α ^ 65 - 89226089066196369408 * α ^ 66 - 52420526819246080 * α ^ 67 - 14929306320896 * α ^ 68 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 68 * (4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 + 55048255682073709607204036059519252499577954075805344228144067353398773939360654388786551620754044174 * α + 303631470940991973002262259034385880105972184753330155102383400602879297569999672180560254047614733064 * α ^ 2 + 1082629940665673044764709543433093878486364849040990099597525143450118708087349123259727336344728664544 * α ^ 3 + 2804599610843097204574458002687246299093134788634086599591559738125527989079685417982892820063924460373 * α ^ 4 + 5624645401139815516982667151087561797773568501921017826805664176655117168979590819326893993434748481137 * α ^ 5 + 9086529173583154645809008602511982564716590500042635425568606924621639922909196505882243392404835758015 * α ^ 6 + 12147764349688852841301807848655896145357577978996235836231868297037709466427619171816150975300099741791 * α ^ 7 + 13702180594674637952993181456614636961007303430300258709825461099491823680923881039132440258291527607905 * α ^ 8 + 13228790758953813166525229226864556895698491358332563699351209388421354345605839944544173983846341165317 * α ^ 9 + 11051940590803482762640027098441612629424377433949792947689615004158487742382763237735051674050718363307 * α ^ 10 + 8057730499045200268719730173861520782106924341107579339386385608691893710110000816392557161453112592131 * α ^ 11 + 5160484214825899033659577721795935067593212006301594642310233538545527417677809202356341306165128799909 * α ^ 12 + 2917926196608374844731210581375035036343917943893823360466936440450011366221495240241631678212028102353 * α ^ 13 + 1462315101539635752571716649246230545438507378471968670138935884045737693317302923326515165319274353863 * α ^ 14 + 651362758608261532683053553948901251603409142895470962454343186012266250060431761761109117155529185351 * α ^ 15 + 258382911131744978730219354901244362207736065992848531597126642760778004801626888171716412430540285505 * α ^ 16 + 91380564667115290929103952618176877475251392601510902630099986346625474504164568221576682912080867653 * α ^ 17 + 28823701484229764785510610641119924329640879766929838579606063832811514346965585992079347095184066891 * α ^ 18 + 8105512742405337827384222403832648005310429131045055117867656987105207137736030417145103472632533011 * α ^ 19 + 2029737755516453702412381601616827618446965035012177295868811221050918334739516968406653005043323145 * α ^ 20 + 451715825606281157427809648282481163078916909506829474305720867391455366362160566615805697668034469 * α ^ 21 + 89083872539236033065296789508746088826183108150642030163709620396857932007741467883529598127701027 * α ^ 22 + 15507062046600275350060333043623953591886937497826357117111310333499555606548238470938828041232307 * α ^ 23 + 2370291817598182097124474831710334939044419386117776585894929734754031639676722325611554692802929 * α ^ 24 + 315999149372391878452912834168990330419105934995500914232394089420371940254905369886539160346853 * α ^ 25 + 36423009146013699028116153780709317964569427476167451734283550363318237494233399180783337169695 * α ^ 26 + 3588163263018483116273779737008794180190405472634090416966530935626554841121047871569879767559 * α ^ 27 + 297471336921909919923207632811348664497121895483393172379791904969696166207311294171026521523 * α ^ 28 + 20305725467845794109711961738383951154160346509672805134214469944833591189715035234346686183 * α ^ 29 + 1103609488904163566431208273520751297004151033048526881874218221163688540301268998957942157 * α ^ 30 + 44705334211106925450419755417917993038028222392715074881553657780646344635657758883181805 * α ^ 31 + 805515192221430510609334948188870016650885857492958289044650012247928862875245764497551 * α ^ 32 - 1482048260833901649795245609960707851397885375498496335550472054736679501095164961700205 * α ^ 33 + 28550595118000674813695237772389123615483889198973830073821326304976753853122397016687 * α ^ 34 - 110293125322577848844861697626305509333317224753061067523753150512274273997930489889 * α ^ 35 - 2944264371932464496615000679541333014546134952187144901035323438838119921163626816 * α ^ 36 - 42753460721496719482279714802299033215763752656049106329252818812714655687701920 * α ^ 37 + 892039301043622007789612879017665871347081871863607139597567473234375585298160 * α ^ 38 + 90290182213750286064408757160215991459134539105309106871418780497371434069600 * α ^ 39 + 3686520145576645994835054065141215370192750469525569878892121423026501980224 * α ^ 40 + 101266458446089775184406440743070690042012917626596066692722657223969408256 * α ^ 41 + 1921165999972257449345542825175329806471062302564814176599267497713370880 * α ^ 42 + 18910079844664677393253742829163990204177395135122636437886747825783808 * α ^ 43 - 267203790007683385371238236401248869931744610843957702759988424811520 * α ^ 44 - 18630321688593096100250955298980358254132585106002718798371125157888 * α ^ 45 - 549431692437424587483251682306834452811394511706522157550126837760 * α ^ 46 - 11827470008686810839474011121751705014739559837533303829463834624 * α ^ 47 - 206601161707202641093681870196336457333557666704999087205793792 * α ^ 48 - 3050100062225303864539589793145445854252294435418792706244608 * α ^ 49 - 38831214153718995312467487136862135070778219830730009018368 * α ^ 50 - 431130925861351878296650698743841679980168113965805076480 * α ^ 51 - 4201734530680545401568837521217272752627836979325435904 * α ^ 52 - 36075335848543051909606823878062380154340083870203904 * α ^ 53 - 273302433216495374400156548854470569604061187801088 * α ^ 54 - 1826924843542958932998763336695299600883344474112 * α ^ 55 - 10760219439515367849051421269035765266542231552 * α ^ 56 - 55683568301576061216924181665153394893914112 * α ^ 57 - 252108560765968990302771636780305076977664 * α ^ 58 - 992726472130728702576289249214808981504 * α ^ 59 - 3372896548691756253399508431270838272 * α ^ 60 - 9784355714995137510417248525746176 * α ^ 61 - 23895590924284630456363042996224 * α ^ 62 - 48203390780462373975323836416 * α ^ 63 - 78197438735478405231280128 * α ^ 64 - 98061705121359087009792 * α ^ 65 - 89226089066196369408 * α ^ 66 - 52420526819246080 * α ^ 67 - 14929306320896 * α ^ 68) = 4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 * (17 - α) ^ 68 + 1265157032653140923172696358781045157064900401217905487833243537047108668589294636491165982694547047750 * α ^ 1 * (17 - α) ^ 67 + 161482237306767878745241819415998746410809769680683392204930507623070859153937168257049914988047412112214 * α ^ 2 * (17 - α) ^ 66 + 13422247499165700437689764267709730212036079924252530397947436539414938500806129414515249428924591360471250 * α ^ 3 * (17 - α) ^ 65 + 816972781682827686607611010623394023676328688115620152082292022403046953548356768129403300216449427112754113 * α ^ 4 * (17 - α) ^ 64 + 38824370988158138726941311700115756071290366487538089829867353036362853363011105712229404919753034517698319713 * α ^ 5 * (17 - α) ^ 63 + 1499833600292598822014341704041896176361474668441008024749667474678088913996818119654158697311930608272571456030 * α ^ 6 * (17 - α) ^ 62 + 48422932809787295787390564041245327912518154539781119501099341947995210984379450371937423256131589899210941134514 * α ^ 7 * (17 - α) ^ 61 + 1333124974240927854482159425251402107245186286978279403787625094573367841803246952758768754029487309692347318336240 * α ^ 8 * (17 - α) ^ 60 + 31777797124891464951721548329322036172531399956667440482696617718123564246691425958497694319690617969140927686684080 * α ^ 9 * (17 - α) ^ 59 + 663714337585641075862710458977346289450664855026176138573830637339763833070986663739178423777505821459460189852947968 * α ^ 10 * (17 - α) ^ 58 + 12262485846674184769453169937509946039571704829287751556559418951991378092254593946982159731229796032255503955934621616 * α ^ 11 * (17 - α) ^ 57 + 201969028018565162730161510400745329670143714141289296191558060115320430534002168054679415522116383859539020895554723776 * α ^ 12 * (17 - α) ^ 56 + 2984596421743417793782332651870684512173959536289036391110144204303743763821125710106900081031600434022380226544823660080 * α ^ 13 * (17 - α) ^ 55 + 39784321437763110285727312524497427978490644060968737608182005051306614478428882059166898040103949867844194968529236966504 * α ^ 14 * (17 - α) ^ 54 + 480543938548422612890741989991526270246304382173993722693724388642176377466756024411416886199383755538111290823987013369160 * α ^ 15 * (17 - α) ^ 53 + 5279901417754954883742431587978703767626877114504290728644469223047973916917301789839124306590322937367972095259516102221832 * α ^ 16 * (17 - α) ^ 52 + 52945203354166745644230222209580146500462821416245712770967147511123795041025063164899837137984308325228112243872402797720184 * α ^ 17 * (17 - α) ^ 51 + 485928342569266463087021622036455747024462941842401506731286158733175889455343816199003845608430478859161164238309759380850320 * α ^ 18 * (17 - α) ^ 50 + 4091958406668774678507241930361086964473233452855436917980174792821511603462125609865012423204529448494332739565952940847535008 * α ^ 19 * (17 - α) ^ 49 + 31683212460188578387342804176945072229413086255880741845271045566233563281959233289534062862735569422810201289901710942585691872 * α ^ 20 * (17 - α) ^ 48 + 225979630689303507786898260664009071625270094449716362704636848456295027690433997904251442068696550669529118551488817387880290256 * α ^ 21 * (17 - α) ^ 47 + 1487128617430673014516169749515363875219566281808091046150030684893815735850131065805579647668091571852789526355428971538991078216 * α ^ 22 * (17 - α) ^ 46 + 9042148580683115945632798662691502266143017079630193956758831416930496458610190341296994016055070448189744269126207258222640342120 * α ^ 23 * (17 - α) ^ 45 + 50858358010848454557731664420671103160817707432587833055365526944577128658034548080461931999630601918157623952028511496302491645436 * α ^ 24 * (17 - α) ^ 44 + 264894421723415244260430513144029948945395618262574763973851002784217525442701126127347374644597622077075226262022822088501696204428 * α ^ 25 * (17 - α) ^ 43 + 1278767873696353424101636053219073837545595922525849403166724782352583013823834674590289275813557084219485073578825413587799211967436 * α ^ 26 * (17 - α) ^ 42 + 5725993526407220170131735130796235929803474480006433589234997891028171711914835354674252789493105774845667439300549950141552174204148 * α ^ 27 * (17 - α) ^ 41 + 23797472948050627920664370923139924765880312522674540655463364156321698714682589900985886207317662923270995738996512039485735022862410 * α ^ 28 * (17 - α) ^ 40 + 91847188399449607906860584187806753120315922783214799014025827204769651430206806052585878934846199020273478297324347000279002931574522 * α ^ 29 * (17 - α) ^ 39 + 329342373949609101951511940154131075827972185993638085640480145831458749736060460017623365544223280262966286218021296303864864015746416 * α ^ 30 * (17 - α) ^ 38 + 1097560558892751992700895204428590904051076121281041797677676037125864755311439126982165925162500305191774580034834400855567800165723472 * α ^ 31 * (17 - α) ^ 37 + 3400354684972857879605435169696913406951341446392821917656396040731072702340906869893233782691459204642830241785914469379158439677051796 * α ^ 32 * (17 - α) ^ 36 + 9795255185712404229440153808939878082728601957977592077724575912171144463816508150030377679174644938546737146393361620285646830422256420 * α ^ 33 * (17 - α) ^ 35 + 26239203554755141459745089973391959355052889674186027464718372088695695988893799042814172271546870765144481886268457658334065389516464974 * α ^ 34 * (17 - α) ^ 34 + 65364772208973664575034750355459656935183422873874505526092428372633233840636570937545030505946122798332726471550017157961822599578476434 * α ^ 35 * (17 - α) ^ 33 + 151417890873929453489601556690033520410995454719040770050368045093177324038829603093684868348571248298437596387498225961228162231792553093 * α ^ 36 * (17 - α) ^ 32 + 326136561459197293128988773328742282995557141736905381102626192805005586172364773727221188473432861214419687642701273642338530960261384661 * α ^ 37 * (17 - α) ^ 31 + 653015723122962185079373689805649153519043802243690625985998409467892401539972839267641852663543640591936858448032520844893189758926012070 * α ^ 38 * (17 - α) ^ 30 + 1215133738838743206101520047205100561581201889449447221306287657871682157019672294661855343053509410150028759117930302323754459334908148634 * α ^ 39 * (17 - α) ^ 29 + 2100547367169647162309522500534430225020946624321317667617084318982110113730770172930764538999209173828708805485472118278853696220026559040 * α ^ 40 * (17 - α) ^ 28 + 3371572226105498605533309421720928970740445870449689033321124541953074173720243492689723243231990142125903392944525071646763046153799712752 * α ^ 41 * (17 - α) ^ 27 + 5021731712866329267615629279744145209979569686428333572284923100300160062927127615408116117696235006051137970230291268323176361338022571184 * α ^ 42 * (17 - α) ^ 26 + 6935282526605279700851082376753425399984816075966925438156290984812989264949621990948332423313032156685195715186548440728089466656780320080 * α ^ 43 * (17 - α) ^ 25 + 8872887599583942844730285240702268137994535894273818319558203225690794212214876544716058828209821312295910996151845255442057724010075373248 * α ^ 44 * (17 - α) ^ 24 + 10504640550563806719417324418003161655867163727170635219980235187136023481938024960895708709168710341339951422197356602510535614885945508256 * α ^ 45 * (17 - α) ^ 23 + 11493574135707887540289576369636114410520335535521279072065981221823553796516692389915466887949431055195475567153283570135491233527632506928 * α ^ 46 * (17 - α) ^ 22 + 11604808627242697256579914136813566676833914505736299110704677968571962615410435000953138171276194970496716595805082770429385722453886399056 * α ^ 47 * (17 - α) ^ 21 + 10793967840695396334802012163192802178890797549077696640851371801953999538826236827198386902657587341524929692133771331237779053672003790160 * α ^ 48 * (17 - α) ^ 20 + 9230499922489526427651509591753374367209146684551244899464268618430259566127381498045470358588046512126019036255090586145820433029559234480 * α ^ 49 * (17 - α) ^ 19 + 7240815654095776003678341965368139318124068790043794347929887962009532007602522612129159417690713015083966661427793715858516996767469271084 * α ^ 50 * (17 - α) ^ 18 + 5196910721982371088216812572801559409316958643069477659778573971072818964949630354690214200347540577616724298122257242598606667131480040052 * α ^ 51 * (17 - α) ^ 17 + 3402631899636205416266590253352818738890126853621420549170291181525659701590036840082549061908694049445145596493472438472698439652700425890 * α ^ 52 * (17 - α) ^ 16 + 2025465883034696535913461632694517262359063545972119023350389907385898500473981148635068061077366719947869607252392209033800465429303336450 * α ^ 53 * (17 - α) ^ 15 + 1091892060376371705496056687719844206882169207141786444740932042075723042341165731755946837934817210431949903331903986496675369334494701764 * α ^ 54 * (17 - α) ^ 14 + 530656327268367909969479070273109187787062122866155559515976559252491925394512132156718870616555877823790538113874300155722493907068691260 * α ^ 55 * (17 - α) ^ 13 + 231274284789425659234396174824508586685686100786488695662129653371227054848548241907361605558199603413655338792402925999207216602489857076 * α ^ 56 * (17 - α) ^ 12 + 89827076778691705270449318543458115575152231899967166072570553309114042367109650873526097636925926390123634607634695515051611658499946996 * α ^ 57 * (17 - α) ^ 11 + 30860904487494092370763766510390952712726910195346707673456930961614703228983522639588565939176152364301734964159970624603354686308829140 * α ^ 58 * (17 - α) ^ 10 + 9293886338970220832863344149731277643249660026631312547931533444041183229427806614161759486641998156855793362317993688595988612988379260 * α ^ 59 * (17 - α) ^ 9 + 2426161101634452818983962562364451171736421102519269820482811118536093138975233934291550597521985218265397595876703167336388333325163886 * α ^ 60 * (17 - α) ^ 8 + 541326371175450174067359875320150061071720972908442799245727828526206560614239255074965243639722409936039557063502412543527181027654830 * α ^ 61 * (17 - α) ^ 7 + 101368480597397327160028924375975580286493435206169413993404105377621448331740368126390317293582211745281779073436064732857223060861736 * α ^ 62 * (17 - α) ^ 6 + 15547562252184505730936231501759499165264416461623728410208958056020346369720300266147477570730217995958466276171125428082524576695080 * α ^ 63 * (17 - α) ^ 5 + 1887656008153650149223340824201972880431295033490416452460837788376128006557577215350851966367675841189217496088025419715076251556542 * α ^ 64 * (17 - α) ^ 4 + 172441329568599584346229934517512403814851421579063304992333529980418530837648814241006023742701428622424347746365799682216705162958 * α ^ 65 * (17 - α) ^ 3 + 10912136951540694390745084178080768035297012709958710219152508683320236507590661219843460673650554961847278661895402354571440431696 * α ^ 66 * (17 - α) ^ 2 + 409247002638066659293933857623421051407334490908373427758260767055975950442905835798620454491056045234820861455361280121831050520 * α ^ 67 * (17 - α) ^ 1 + 6145809855889991363427473372969457107085687932679016036884496519288814567653275417252009402531892559405828541206858545507410560 * α ^ 68 := by - bernstein_ring α (17 - α) - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `70 ≤ n ≤ 79`.** -/ -theorem finite_range {n : ℕ} (h0 : 70 ≤ n) (h1 : n ≤ 79) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (79 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (79 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 69) + 1 / (4 * 69 * (3 + α)) - + (1 - 2 * α / 78) ^ 2 * 79 * 78 * (79 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 69 * (3 + α)) ^ 33)) - = 1 - (4843186559674821468385702143664968596648164440135509352276388118225433994414169292379332428554827894 + 55048255682073709607204036059519252499577954075805344228144067353398773939360654388786551620754044174 * α + 303631470940991973002262259034385880105972184753330155102383400602879297569999672180560254047614733064 * α ^ 2 + 1082629940665673044764709543433093878486364849040990099597525143450118708087349123259727336344728664544 * α ^ 3 + 2804599610843097204574458002687246299093134788634086599591559738125527989079685417982892820063924460373 * α ^ 4 + 5624645401139815516982667151087561797773568501921017826805664176655117168979590819326893993434748481137 * α ^ 5 + 9086529173583154645809008602511982564716590500042635425568606924621639922909196505882243392404835758015 * α ^ 6 + 12147764349688852841301807848655896145357577978996235836231868297037709466427619171816150975300099741791 * α ^ 7 + 13702180594674637952993181456614636961007303430300258709825461099491823680923881039132440258291527607905 * α ^ 8 + 13228790758953813166525229226864556895698491358332563699351209388421354345605839944544173983846341165317 * α ^ 9 + 11051940590803482762640027098441612629424377433949792947689615004158487742382763237735051674050718363307 * α ^ 10 + 8057730499045200268719730173861520782106924341107579339386385608691893710110000816392557161453112592131 * α ^ 11 + 5160484214825899033659577721795935067593212006301594642310233538545527417677809202356341306165128799909 * α ^ 12 + 2917926196608374844731210581375035036343917943893823360466936440450011366221495240241631678212028102353 * α ^ 13 + 1462315101539635752571716649246230545438507378471968670138935884045737693317302923326515165319274353863 * α ^ 14 + 651362758608261532683053553948901251603409142895470962454343186012266250060431761761109117155529185351 * α ^ 15 + 258382911131744978730219354901244362207736065992848531597126642760778004801626888171716412430540285505 * α ^ 16 + 91380564667115290929103952618176877475251392601510902630099986346625474504164568221576682912080867653 * α ^ 17 + 28823701484229764785510610641119924329640879766929838579606063832811514346965585992079347095184066891 * α ^ 18 + 8105512742405337827384222403832648005310429131045055117867656987105207137736030417145103472632533011 * α ^ 19 + 2029737755516453702412381601616827618446965035012177295868811221050918334739516968406653005043323145 * α ^ 20 + 451715825606281157427809648282481163078916909506829474305720867391455366362160566615805697668034469 * α ^ 21 + 89083872539236033065296789508746088826183108150642030163709620396857932007741467883529598127701027 * α ^ 22 + 15507062046600275350060333043623953591886937497826357117111310333499555606548238470938828041232307 * α ^ 23 + 2370291817598182097124474831710334939044419386117776585894929734754031639676722325611554692802929 * α ^ 24 + 315999149372391878452912834168990330419105934995500914232394089420371940254905369886539160346853 * α ^ 25 + 36423009146013699028116153780709317964569427476167451734283550363318237494233399180783337169695 * α ^ 26 + 3588163263018483116273779737008794180190405472634090416966530935626554841121047871569879767559 * α ^ 27 + 297471336921909919923207632811348664497121895483393172379791904969696166207311294171026521523 * α ^ 28 + 20305725467845794109711961738383951154160346509672805134214469944833591189715035234346686183 * α ^ 29 + 1103609488904163566431208273520751297004151033048526881874218221163688540301268998957942157 * α ^ 30 + 44705334211106925450419755417917993038028222392715074881553657780646344635657758883181805 * α ^ 31 + 805515192221430510609334948188870016650885857492958289044650012247928862875245764497551 * α ^ 32 - 1482048260833901649795245609960707851397885375498496335550472054736679501095164961700205 * α ^ 33 + 28550595118000674813695237772389123615483889198973830073821326304976753853122397016687 * α ^ 34 - 110293125322577848844861697626305509333317224753061067523753150512274273997930489889 * α ^ 35 - 2944264371932464496615000679541333014546134952187144901035323438838119921163626816 * α ^ 36 - 42753460721496719482279714802299033215763752656049106329252818812714655687701920 * α ^ 37 + 892039301043622007789612879017665871347081871863607139597567473234375585298160 * α ^ 38 + 90290182213750286064408757160215991459134539105309106871418780497371434069600 * α ^ 39 + 3686520145576645994835054065141215370192750469525569878892121423026501980224 * α ^ 40 + 101266458446089775184406440743070690042012917626596066692722657223969408256 * α ^ 41 + 1921165999972257449345542825175329806471062302564814176599267497713370880 * α ^ 42 + 18910079844664677393253742829163990204177395135122636437886747825783808 * α ^ 43 - 267203790007683385371238236401248869931744610843957702759988424811520 * α ^ 44 - 18630321688593096100250955298980358254132585106002718798371125157888 * α ^ 45 - 549431692437424587483251682306834452811394511706522157550126837760 * α ^ 46 - 11827470008686810839474011121751705014739559837533303829463834624 * α ^ 47 - 206601161707202641093681870196336457333557666704999087205793792 * α ^ 48 - 3050100062225303864539589793145445854252294435418792706244608 * α ^ 49 - 38831214153718995312467487136862135070778219830730009018368 * α ^ 50 - 431130925861351878296650698743841679980168113965805076480 * α ^ 51 - 4201734530680545401568837521217272752627836979325435904 * α ^ 52 - 36075335848543051909606823878062380154340083870203904 * α ^ 53 - 273302433216495374400156548854470569604061187801088 * α ^ 54 - 1826924843542958932998763336695299600883344474112 * α ^ 55 - 10760219439515367849051421269035765266542231552 * α ^ 56 - 55683568301576061216924181665153394893914112 * α ^ 57 - 252108560765968990302771636780305076977664 * α ^ 58 - 992726472130728702576289249214808981504 * α ^ 59 - 3372896548691756253399508431270838272 * α ^ 60 - 9784355714995137510417248525746176 * α ^ 61 - 23895590924284630456363042996224 * α ^ 62 - 48203390780462373975323836416 * α ^ 63 - 78197438735478405231280128 * α ^ 64 - 98061705121359087009792 * α ^ 65 - 89226089066196369408 * α ^ 66 - 52420526819246080 * α ^ 67 - 14929306320896 * α ^ 68) / (397402644038401809557590389565008829884509406750026281207302771191507751602453558160 * (3 + α) ^ 34) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 70) (n₁ := 79) (k := 33) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B70_79 - -end Sendov diff --git a/Sendov/FiniteRange/Degree8.lean b/Sendov/FiniteRange/Degree8.lean deleted file mode 100644 index 18dd48e..0000000 --- a/Sendov/FiniteRange/Degree8.lean +++ /dev/null @@ -1,87 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Reduce - -/-! -# The finite-range claim in degree eight - -The first degree proved entirely through the general machinery of -`Sendov.FiniteRange.Reduce`, with no hand computation of the integral: `Sendov.integral_eq_mom` -turns the integral into `Sendov.mom 8 α 2`, `Sendov.mom_two` evaluates it, and -`Sendov.alpha_le_half_M` supplies `α ≤ 7/2`. Degrees five, six and seven predate that -machinery and still compute their integrals by hand; this file is the template for the -remaining degrees. - -With `M 8 = 7`, `A 8 α = 1 - 2α/7` and `c 8 α = (42 + α - 2α²)/(14(3+α))`, the bound is -`1 - P α / (72030 (3+α)³)` with - - `P α = -240α⁶ - 7488α⁵ - 60624α⁴ + 747712α³ - 700161α² + 882882α + 1102059`, - -positive up to `α = 5.852`, where only `α ≤ 7/2` is needed. --/ - -namespace Sendov - -open MeasureTheory - -variable {α : ℝ} - -lemma M_eight : M 8 = 7 := by norm_num [M] - -lemma A_eight (α : ℝ) : A 8 α = 1 - 2 * α / 7 := by - rw [A, M] - push_cast - ring - -lemma c_eight (α : ℝ) : c 8 α = 1 - α / 7 - α / (2 * (3 + α)) := by - rw [c, M] - push_cast - ring - -lemma c_eight' (hα : 0 ≤ α) : c 8 α = (42 + α - 2 * α ^ 2) / (14 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c_eight] - field_simp - ring - -/-- The upper bound for `R 8 α`, obtained from the general moment formula. -/ -lemma R_eight_le (hα : 0 ≤ α) : - R 8 α ≤ 1 / 6 + 1 / (4 * (3 + α)) + 1 / 14 + 1 / (28 * (3 + α)) - + 84 * A 8 α ^ 2 / (3 + α) * mom 8 α 2 := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - have hk : ((((8 : ℕ) : ℝ) - 4) / 2) = ((2 : ℕ) : ℝ) := by norm_num - have h := R_le_of_integral_le (n := 8) (by norm_num) hα (le_of_eq (integral_eq_mom 2 hk)) - rw [M_eight] at h - push_cast at h - refine h.trans (le_of_eq ?_) - field_simp - ring - -/-- **The finite-range claim in degree eight.** -/ -theorem finite_range_eight (hα : 0 ≤ α) (hfeas : c 8 α ^ 2 ≤ A 8 α) : R 8 α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hle : α ≤ 7 / 2 := by - have h := alpha_le_half_M (n := 8) (by norm_num) hfeas - rw [M_eight] at h - linarith - have hR := R_eight_le hα - have hid : 1 / 6 + 1 / (4 * (3 + α)) + 1 / 14 + 1 / (28 * (3 + α)) - + 84 * A 8 α ^ 2 / (3 + α) * mom 8 α 2 - = 1 - (-240 * α ^ 6 - 7488 * α ^ 5 - 60624 * α ^ 4 + 747712 * α ^ 3 - 700161 * α ^ 2 - + 882882 * α + 1102059) / (72030 * (3 + α) ^ 3) := by - rw [mom_two, A_eight, c_eight' hα] - field_simp - ring - rw [hid] at hR - have hP : 0 < -240 * α ^ 6 - 7488 * α ^ 5 - 60624 * α ^ 4 + 747712 * α ^ 3 - 700161 * α ^ 2 - + 882882 * α + 1102059 := by - nlinarith only [hα, mul_nonneg (pow_nonneg hα 5) (sub_nonneg.2 hle), - mul_nonneg (pow_nonneg hα 4) (sub_nonneg.2 hle), - mul_nonneg (pow_nonneg hα 3) (sub_nonneg.2 hle), - mul_nonneg hα (sq_nonneg (867020 * α - 700161)), sq_nonneg α] - exact hR.trans_lt (sub_lt_self _ (div_pos hP (by positivity))) - -end Sendov diff --git a/Sendov/FiniteRange/Degree80_100.lean b/Sendov/FiniteRange/Degree80_100.lean deleted file mode 100644 index eda9bee..0000000 --- a/Sendov/FiniteRange/Degree80_100.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 80 to 100 - -`Sendov.R_le_batch` bounds every `R n α` for `80 ≤ n ≤ 100` by the elementary part and -moment at `n₀ = 80` together with the prefactor at `n₁ = 100`, so one moment and one -certificate serve all 21 degrees. The certificate has degree 78, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B80_100 - -lemma M_lo : M 80 = 79 := by norm_num [M] - -lemma M_hi : M 100 = 99 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 80 α = 1 - 2 * α / 79 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 100 α = 1 - 2 * α / 99 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 80 α = (474 + 73 * α - 2 * α ^ 2) / (158 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 17) : 0 ≤ c 80 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 32433859254793982911622772305630400 - -def betac : ℤ := 8723164184970649540136980820083385467316299498187180406471657614659015745109425388765298374654413765304824563761911907475766835157373953177019305931030836071628801 - -def tauc : ℤ := 404753666982985231802836739943762627969484039018328915373473173621023363236199826758779601644582354375195402103752357583053812406057302556689418439891453419028960415456074108892113244540354801120209284280696191437692858038588451339785731634743113882619666491627745394397740429144355507259602476145287050296711702273248628101066955158137070311892771312204935825691582576942320061242709163225345256751206938287778950080011462444292648943308369222108286339689596271329472084475110725777780696268916513552891273789380760175820843559054870021994048269193303611017531292210192217156992211484317734043941743947842234641387272006641791022928330359220984433497606370850764991491542171135946092040139390394793806859181607345242033297995773005306048540883906807738898192379665333448587546798928994245547116236895010144345994198330641839370410243355528862155673953423056617769670625165717599486790956014594965152472901318183466768198595673325051890409967728556850137352558548777025152999589015328077306856737381170501043830473872898862885922512240209139403660955729698127429556162235053725626145672145500250354556823769697587536815881971130012516638882806117440008165599951234046248016328873281830329818742498982168992169677951246025989014319736930079898186870852551356074395667323675374432912441441519238894151643548225106462110745740987168380113944407691536676038787456968827084251313373871914415288427329282202226672585890975222699528482211858013818107996655342598938606351665221365690641568960786030997538586126334798038962916566570213146174483983796233203536547695773484566777855991238241523068214823471328336491943709905470923999170561749043578450905791113689241492622050368896489022525604181367219384012617012173138721109710160157416848353608854193950929282934845291125136238595771888110675387614029588775256128662188228738433432364184945730471530844868490276410927130416478213629976562242800228003339431103156669633016997107393101653161344931354462775633365063204222288038505086158095839811259534526538858661289054320216565722674555619757987622563355903125030609316910742000046654700767752925966571991422599409702123645457592488826461949684442415687187337766740290933080753816212409941394939068587653421465009963150175953142167816307488925074697433512912966012416794498594502356050026391506258394999237401061274943541218194873643048593948697424890455457428509748936193769955821961997475504662382458751237944520714328035723916042372369677036358637432041286718898103108465239662636224932693791283358099840199295779359234470419985943548201574774352544549334958644805038168419320143638574431705501528494316972822054017896968986106503983881385268052067163088187240661932788947092357411232512553459577920077543153707186849885404268486890558632707760108759046022614632615450248183384433910994534462694763761872047648707507665501960389779949461053272444328831973511569125081920666114016426256327889949104491711165904403453600153193628371610812660297311376840216773770846007410421245789005587114772703650831472688063013475184476092846186066570923729008686554546839838558253604762978102685941485019199383321124128769219018208480556006643546012644982621476743377777394834920475254822210178124332472632755992631776432713060524763227614227326350867080210095429334095024689270654257093668340057132598425193971384362219543494081098828974284957850178905246318741084698205501812671570971595419821809503092707083063361285672318062815108037542760697587033066649096165276126852436078793526404294663612802685249544224902812211258608662962802905900307789666028672603631498990702015547190745222749478184064449656665678776935824976776961593634966062824142633193930299675825184946776383178421853909553100775261454804783816590440968761586633241512246083645465754947618466702580298195520512003352574869348779656333343954809376788429751797576913950767068635179930945666811591707328056903111196696655455315732772254424251225366468010799570411483994268805356514609785332448789601473208929556876271015455232120803215610697868784596361610126464940072249435809147948051587388186573321072200298718936762829118591947892458996178907256773611317810797112605053847544079603286424048464765837757439316805067605903568510440296475120957801484194178575832799944268850643190516113008239842763241346455550127286928824523410244333549673298638999731501081396636472028814163396593665006411047081298769495027201845170557639933896051762204099737014146614843207503911068392591643383262356577998545728405484867029306754111881634460718477001332296152856458156249105217488711288096065270517849001139044674794524889069588923588664237578189804418023575507673485363921078162211365853339699498650984568654516388351905132723285751990572003241558427792349230757377095738580219081132954902177427477002890986131796334905533293356284981802961073296813179439742817665048103822318246567143239560841998885266603287302258751100732747606275512004731189931244391660696621029635913311525188129129280147641093077149025445955450604438854557226721501042366854149390473864849587031474503423657965787140154875582788771755225096429890901576089358925263578610871615397625619035375804773364740675945182141499871828163012262743459016417549670772200507035787707272153513863556404299744362484059722751967300785934464514091799909574452159909571804687970910605140364747526093885796586727885792458567556548181894260476359024822557648038400158374177359234360752795905877537536512487573532406670927908981364800872330251644978365579796730317858394141110811321097485755143421929285506822795293130222851541473113498081750253175114822720117109710446703448368624335638914800055732263504421229150910596965720109787572497202434014105268982606148290694077195960672091773401038395851632088122682384060505339876326340062661507957965515345318041546967952427112978040019161147619590398552436419491798884533563209978851997379437553677519193237447634953935119186714534769204136194147598421869486498657693406561201819546741683666158379778563860074590830214631004711158363361458572374459604464700315489845966038099525416342313293485610848722442148301934221188058100475862990093629702898287040858327961452051611439154228733250218323353414634246096726053427685380865946484294977187282696831568245431424630427323594326172449464121936738061635880012110352982357489750418331671372549700280172668215111094163860852369108696821072858748980901469315689031532706521438560076829223714663703029808696912148474269276145015607178111164964699128586495072088255907364564503582317266430353726873164223110375642911190859926959648368446778132132380167661133847588131778798628208670327444944341611555230822552103913633669463056379220470679581600035902403133071224096764724403786779768387429460789479626460700103964503198654421758173707359465445357951538445528274287800853447084177456373152364908926551497339434635030202988695987589147552430785824568758796892754191192460078438386192027039011922060869763491425364108595017990544982250000533954741056648906774659186152462978047234492213706250579447242582388382931081712569577284842507423119807694087472674593722596374752196731266986797466081997877849770945077137027385119150240960222163397073998552834009828350170621100447725415155851620811735647523581667503781326660479452920800131200099016752592426374461585018832947039351271450982125983961271965411246494460881697829810525150386613663079865524393572780960452522342347432878959456195803798360735775513311216310853375442293904386490783008936050460626175093734772184356536295609416590929226335742181197551700579296172794565864357355928330120786896946496336494336726974258795582968879397913807584385696306081809556815285333725870862730916079663195786956462169884915742449498129564935123631105805450566983996611269192614100387254267510866834608845465569082510090583384754290181234100019881054524670599052751687886770389793685160621432180334900128881095261560515173510800209836819973432604511462829057915290527445037727464852621304912153141322553016569255155810602897874698071002172074181882726950301097106038373247527564750791163981281356435859852285740399170095840249907368890777806851207336610297508384230946095303438833784472810965375443609899779886019761125355263631988549126411953191848238746120231666257844069411646836614166964698611077597119527068536369368139742960936144571825738132706959547169041339061894427383433866340601242637141794653011165405290897760973564847101007729443702011714070806825649127984838357356854908809870214466832384818090682138720677111632121939563151041789706684116761389173366728721537587086783572600968005041960255178598157691886138501638844025309308424539282253091091689470020905491730899233102797827522162139387057945671322499395735624190238032884858008171575152028098324859427166007667245445039058726904917508663380799358211167419281696377132985298806561833107056441283158392089267287969132211262552812533946319479121101600113292226135282055508847900926424895235161309952367218569648666031575022887263488060950995642128966686982305544541573142654360583449157920126123621944621391766295317226060176030491645991597686570616357134582769979232461372058519412622794324795730144985695273229713889866593937941417115525166057765023428132826828610086134699402441081984792116683922635338883811843355521256973329037843265515928877472207151159044181778955410920006290861339492065465898983329853632200788785007484581447597669832886073483604463151733631616790089770783298465366619771202075843879146067406288695639839272980064539464284294470953465436421593973552344749982018261596722599456939955700132739544928060281855466375770311873163005396716514249101696829783239173063446884267156353113144350888494922870019410748442377210194885907587234411314731909705646980911959049870490277444805524080153657667969768622105563628988222371744684009804100895927931598750677332479189062533803139099697277683277673188983831836188026422162386048191384678452857643292287875752439406112920711144129945477719343088118470315754352509480376086811692969845182947729700314044744947134255502273351797953408982988397093647766949650078204534852415392758336884027078205951813894170715629131413142046146244880321774195365463147374123362459171812245543719449244341095245660043482589230546953204535763658779728475125426123803975763154720321675461048186537812773884594105026990452876991133963542049968727744821475981467467357997120715188604906249687254359865533159610732387680137626539879064749607988996009003558222913801200576601385932703558649575504071790438347884188894246444270025175515807873122441136339280895368316076951974151279038913561587484880730042741486490709196997957452090613283840563410942358196660789295839331392560634078356113187025117709692399631322154076856561436914665302883045643812221313959089111740842899978722147929623629595119744235233910934426798758860646941155042873085255075537368302988050438076572915454181859257377848859193660682175408755560071197108817650831997753074471194481540145386182604966530098527818483257521448444065796403605906309442316875173574293452888788902347094933983827827811363045889147032458129928409479971123195248517433635091861555714585558516545863970282488826328989940765515665866102607624318899783204535314073992064842333233327456253390981895777949650773103354761154647635544336474102120514160596391303310276038208929355828407475136738088475565919867944399326148225646756380124346281024511943367750884248276948773276876131357481329462436611443698096888906463966084535113149026470561707132503914215702188600996511252576067091133752828940736256315414355303371507007372204673175941132292113054715162272670988473421792238922171082264528086985464355710109668616504677567281725686367874116369083431468350599119286403201815995564126870102288161993168019632885561637204061872701485712244825240038764134184518557800081209590662892483596196828385271559179813674567460440356442952250550531740437288423362507996457867493379027627780921433691813050046624527008812294160775381051570321670653630708104445390097215681444853880540275381795249569016075079633690908750995461101160384478089105825350611527162713660979006925918024065148099703981941363514626778014352451683956050011856161480393086327467847544739331401725053277234996517217400602153725712596895921444772539266043021560777620718457849259275593503423953695089320151676146585448961922222382220581469473173025123450315765752144611340403519234609416390257336074512983575968519575416015742492358617710749599325365945381858965843067182993667624890331970095494928287486536183811448868381530083401299811579330397799037082757950231540718107997871280941955374593243925200834811147407024174742432512006368919766415003730349855368855547988364337860813907469950177411284902457653762049366485982251387437057982442820482979220630780979837805360191055244068495812540602728235956622014034242107639561594467765836033501805397148625675710496526084554945634828270495083064537606307258260030419403151622242468556526014444836083708741570125152022339968581047745965907462677796753848356875834344735590178131782061746600529403308635584654459532644430455978832687358472257280448663707180647548673941355464930941407560949870981153161829976751483936196156367072373048151083424298475020703882259585279196264783735652386288552684673030852484806843839049256546952147908013986779968551701972409100579878730077075861980925294635136963681930699400762571091407854130413157297107718665797233712880527505513473212447813583675842685304689747456697049220427976948441646458182936689034321101888504561171261495684853426995244383384596836242098135106726772043865094172358349861060112854893203552644209695598182167474535628916144093995600319340891889197365333966559901534878980155457849510000443694548889895196031591201970033790782367292179054968272826451491122776814327822251148808982253111701959058882615350252202528568665119205292986468858255969088038950498908980956677159946963411415696260072057035675287012691042051400615123552460960505623409242061441110241104269048446566637032119534121857967484788691530223955501371325232397790970460807676746226369237349298085825903543181720173893484102067211568042898608128157175493224844638813481435933750945388450013930095858503633417995064384160536890858494926331502266846037312399659849630236938088000956835124870433316311308085884896966222626659212817796247385218949795852062496952819747459673105766556887931291003448775337025614090965959810691699592690496097589686204588294167973166067992896039477738882858495358991853746085372124009528335835006731924736262781586198644654575825861659591389978641986490234023742034424412142695039075177743055146576439821749279174209344797026359934778497547357285842618503024015552907457582634343871236289380095725096655256649811627977971487404425010265774830879772004098060928538209417166606949966230018265155012258229340120091465046232191613570599678042810641153912895416455599813820050000354979331769613636106742987198120126743549313720671912955159546005984365037449397543384385325384813902510243641665187626829692002889398811356795822008372998266079309146710243255156822810375291117106462122575975616623233495126499357741974472656269550100994829741351706218515787243251865980232835081506669239059139338293266745653896838888956113428518536725001923905630900466618870793433520959394629964182551495293797912576186051519878249461774341861453779780194910413369828440134707333022684818505498117851914334908341312782094543805195188179649601217832734082683129478617139587172201197779130294726888553780860727672212727272055882830867180453001162090689491013175614793771469431143491211479080538974760298440604687591438925233330019532245469228776206431111800682649340419165171197827437659694785925130624381419633611113565194731430850794936372012726559880635669845151972607664495676878761504566886806920749002774259636234610732253700759307045787650073428167573948254817324225636081963964167462301812864667394688840771296067428904933395163982902375916184966423367112344215952017955959378034223993840945760693241102868126154891366733274183120600044732595607361691635085220750871149480454759473603807085565558476618395380231707011336254804766596037645628494302726162539001468604080200413261162355548364725246422413391914940311475569817361434757205071444555094309662501995680474321630551866181102039193752972956804557013407917224979057707438822499776250650875324540830132376250458348161671008473656668151177374928430936400326369111166542665710275976113353392858602150555569133275950149512080266550612971299248557983027520696722991119541133529214855844178579301753859760515964011507188143403398689457998436610719700498540556779416649753257804799835489620467801461399854912015581348698330840742673338703349068405673733330656722268710710304666320085112831502259242846460061488505213129401234401525071523966889002002249095098665108229087564879053213587522576712569854451056470935045440989224964603545290678590952953165819476001216773699137591415665432736849612949036346827432904782867599146991106902830265037389371126170039608210322710751410332181143384726997621820240766968886471482476500916846447872112231346247263643658692810111730750016856834741871401938008040749724407498709594862624264873572132850674063126154789780839084925926911897139649248957527355538695732554424777301626207846430497786636019422598391231644334451268499145922267517602054326666027495714468728824163540540353264254459854080808642876796246739015922385786306199139131675181731311999503530571149403751567894893129224281844713763515135346915957323961590556690666266115828768765850746705047915679668241858954864785242404789341837389233383823092061469925066527030182579098907561513224206161149641696732269905650632510095195241592692450467511765109946191342639538976747780517344210713719013918404300097280195113917049391361518746479962184408243811677399435509776737976805369662115314683477771460747473448697913626735305475813821189034184983800330232401945324591485548308311157527969732189892595606224837776523707613725364163339143953076626388076402313285739796276092968501755644123551067140890399292884140525075474614574555844362957211922317826286996767204019241884165920413649589975939063083740756435853239101024131465396272418537591899169031011290430225212721333293917125474782312187510253237409421311997786329089841091011620417940070983894648081580393035739213919724989061673805715260374912317375498705197907775950187818479102945232247968537938625341337312670548853570563439552536723133244246326129691927996725309340584471788318996853237550897499370607323787719921967702714060018226256015577751364547605290573520808093766002696818914569607965724228313105559445703705762770039425310647746368266458476620491844728018436030533370592125210471337971906662058367826076027979322935838086469583946228239740004283604760462841177310951708762375612338138787764671041142320592040356240993468772360783930604751701315749885223292484190672753962010275491328447656468963419868711966030170948161704493800382082415212722831776284673 - -/-- The moment numerator at `n₀ = 80`, `k = 38`. -/ -def Nmomc : List ℤ := - [2451457992124935473501133615070262873921938387794729078375249398059349434752761847604814463108582305921734712367881387879662878720, 32919184705502157421658823211314826744102811464569557452455036783279106418066763735853342570992265012684042672016293022390814769152, 215458812285770777179089358424573080302766617643745463899989229598405974860698240914799621506659889371634408284677541651792351199232, 915835443628844511686539186578301305479070879565535109812947958136326719111498180087357381806467353420586935822889757294310654476288, 2842198038742088308951573820508526777252934462140297753223364398019892336843720838402490834923531536981594593164432765262323760758784, 6864044642187844834215556688458249735858364613712085404530679612032762863289525955657683365262169409163521617467267979511260973629440, 13427088427682447006680667927654728685318945208432137924852535011371840206189345840752973430082717645163144293471066437273840470982656, 21864158125852164064378014242761193837394610445987736952524802704633955624347771992395019643871780707116343216863636865250251428069376, 30227698520405358127647115803289101291269264312405980782099088643558209803959957476025851470148763458702532446423987088467696249995264, 36010774628601357518875702937883478133261265154452515974810411886835447739037891974183026302636111913496337365838585328576189884792832, 37392016018675068145192099157096072528352955213806759670476911387968170697020567137384941220396896109496541715296666839419197990109184, 34146836167851041732795552212460819592990038567753343073076119908794434665042365733893269436985417536562320559981233187211068095594496, 27622466647867936598786965726597394277200887499672685446937157751981732972995004205393742830465828410201038402571098726108136806023168, 19907615004305886809258957858995402928230114914921673848294466080233064133156085487416565830798108214968985777489076817898386365612032, 12842207900684637449720355185194046807377405010263701013658779450932398985930010621545160344392707957849881520452880495865836314034176, 7442975941904218965211539954205316217383117641532131057272118802037314121272847393927520297104881808485159066453631487728551674773504, 3887151377319415212895090666200769536732495435384235425870795983553395131403549245455508666034410478494600965740833479769844311130112, 1833588652291549942873081308682996222071503468725298985847670853156311958337545863614227030085794318353513855691331527934213707792384, 782558687550161344599527866100009025878545398305704876134174232161740734931718767202464033106847605330188659009745963452289595211776, 302560497182004927775621666752966075658438558829354989364373918684629075964859128383085477805684279658344182666230706308452982980608, 106051993477839308308702859189414904021140625603392646856653839053543472995758030156055795306557169996649895708137118973921389969408, 33711319268249472065082657352264392741200584328998602902949247419957155612054524114648785009430345941033552704111926557151170920448, 9717134249437909558409092270516974053630451614667506473941025484532583503048963117948418018670444025006071120525113589326594179072, 2538530219740669135064598239201183646012550837426648188362208623204269515603799799874971592063679203533902450592742319266094645248, 600491835599671373763025035201235478892819024392260622313528140091065132851417435660733438300601619576510753236508622303772278784, 128450094305989474794668335895102715441545851909808208710114168205205556896247292589472143832120288245018331593613279321036685312, 24803266945745496268709079579195646894352839234381676662117285896909392346729622995393886685294237948151157060400210880466255872, 4314188208059576544036087966906767334919501042539887746751247601903904382592341337225323179819695833740291145788419776706510848, 674223780595113902570931821070179016411769117545205638870527067898343637962053132548271689300269612483232896956162274211397632, 94399724004762523811364728006051660810239390517455982671738987702071065787482359872473000049560731601309524085268021013118976, 11804088398312409948455701459606933326132400587122259944819292485487512185717696365708590064544531370958740499556825049333760, 1313973531302205999013808188008659974631402916406496293046887872176369760972620515374802141306353563543909809312215035019264, 129819922486334676346158093676503662067455677117728975905665699744733521209597284929176535905183057414971468882477888569344, 11360182884373213016499790008235719495613078382456476447784072976480299296279787540281401488823800014735380011247118319616, 880420134093915051775172698501478679348485923973568604988403387824260814657485963126530745781477553332075488860551774208, 60706825211252738744764756963533891330672973781796238523363940783358521684317529454858032391371506481801803761132240896, 3807543873812733665044886871846464501356237414235179093772576683445188707487538953795997493293267599910613978955382784, 281915090032436267346476815866340299632754520438279260567429896118609672288221433286341410828390558771442734598193152, 327099336370581513667654126285245997971585733226292398611515904265208954384050376086085773332670521746116818551963648, 9149156055589856275689215356422246589261210595203523536350622373466814963520993541479285772084098775869715816382464, 260880540619863496662879262728185557758929735228281945768745558574653232287151887343843974823731926539508106919936, 7530121029802986951452715654121545621120499362802136210467441526703689311190407040903760624152515919278346600448, 216342612427489653447906026351484310844313602932613053453921131142496607198455126487392331641854181608255389696, 6046519886539670794154028371374416388953653826564234877955273230444829783232273487102107767643092461283180544, 160703800662245158239532378113828528707285389941209541419381892888788998275467622403320480570093819660337152, 3988492826544713183787818172020018739856993865343943892756895976477913337705179899257129364804683643748352, 91287508022945396600279560088175948087849031736685227380480281756010508318219171813626042127805874962432, 1911957323446348661157713632922329859866357876212255099683862903028078743659626995686697333898805772288, 36487079479011229827788382064367371038115860844725083876660366472738697621525625663058203158083796992, 633107071941323361039272515458954268968741249092313121812604746078640004807723072127477717544206336, 9980268797997618134501870435256369007627910280994459390008438426413443981147431373244605208199168, 142920181244321531222796982962161259772876620482895930814175075635874082700557851073778613747712, 1859666019344625450677058668677738139865067002393880902280655466664883299064356844164733730816, 21994329300376906421846789925448583550720994053174494779638277054342505401590772963574022144, 236504499496535655096170116071069732643156715536363374131431905723827544764729271508795392, 2312440655225372280997586421252957136202127125247832968615934851204184481942325700853760, 20556783311361049327630468940441702030195511244967368938421185301573474536274356338688, 166082103128222897473283723171643696107048435631128738596707216852904311853015891968, 1218605575048468158171037360500484874915303004745460507584543423740724454256279552, 8111606422808559872224862434398245641949256535300940452701531932722774960766976, 48910896762059962173537101594632484191832476882045264656440740080462795374592, 266629397940651077707964170984721882819662878979170168337053909583027765248, 1310780150099008317887089034249408017908243246652631651349519137960361984, 5793164467104267856002438515547159704816096736786653455826281945890816, 22929247739358792028893069032179234445217260145892980307474344050688, 80888679170291782849765039126975432682489080745391333143564255232, 252852427111386244978359397627846481887262530068454319887220736, 695312909805350646055954940892636032256191467531052947341312, 1666838136089110117006146767118676732931294941674228154368, 3443648889619244786662209759640098438509459811329900544, 6040913590125217669627879011657679726920583813791744, 8821754425601899407029602066954371908924105293824, 10434884333909184634136919541017446230058336256, 9605069968523214951549676507445952673480704, 6454717416401205395401186056664548114432, 2816840911512241803152568859540586496, 599100897802088020258310672351232] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 80) (gg1 80) (gg2 80) 38)) α := by - refine pev_moment_eq_of_packed_bounds 80 38 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 80 α t ^ 38) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 80 * (3 + α)) ^ 38) := - integral_moment_packed 80 38 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-78 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 78 * P α` is a positive combination of `αʲ (17-α)^(78-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 25811606424535915506326543401482443660479168162161070878750987845784640947537512918254143661443967851841624182260454 + 336370345330350208165234204307830830778265112065902973986047706784620119812179101529287799329664970700047233908530028 * α + 2135490323710205451177831007886434323850910269893926405766449302023972016567372609179660983528148958829173461437058426 * α ^ 2 + 8800193380808665214547458427848614541537421741398394617093689631071556593600442609061272206311515066984302690924269000 * α ^ 3 + 26462827687725576351409435396337556001601266481763435312645957683742611763538244106923991390112640216709155823432046446 * α ^ 4 + 61890317824100182817489513892770080906362674388551785381427868354803942587321704313688072997460165545388054174413205140 * α ^ 5 + 117172359697259929763030783557189322339080300100874585985220084088882745103145230216047487779174956161518920280447603674 * α ^ 6 + 184544739027532874709347195849421533711097651533181291373211062330869431152671413319813999120439419738468174182904364464 * α ^ 7 + 246608145764613286789878656386710073720610930090411123420903881172229605185065434892818764890373842116194248634263756798 * α ^ 8 + 283763693487574246430404620051411555790859557853657413692053633072552222818811355084552210214522447497912164915857007772 * α ^ 9 + 284375388167493337786979561808634395465424553508941556573930507406581722477890971264427055005741911794482115087411543730 * α ^ 10 + 250434456333498778687253731739220273422355020504490227298836915758303181227856673748711052077418442551670601820448469608 * α ^ 11 + 195186376833089073717511924197741339564583901408375396552289751612744737294639334816437871802096096044647044024483571528 * α ^ 12 + 135403325876044028593166865189418922031634343539481341612266706224679843802900374983571701066935649917189903585957861976 * α ^ 13 + 83987295633438700092517506437803590415296544388998812046873276158407316217262430264254188896692746403373298520205212844 * α ^ 14 + 46749761312162043935912318982126078666828249385834636225082169910759646501503433598091545864589766997203234619939545928 * α ^ 15 + 23418772546685983831264607439067708954491960164074800112819444923487497120280358300648725634717312663795784508649665131 * α ^ 16 + 10580616042971700828358189370081401738808367070894586162364463432933276777181125840333157268302229461101124643546709974 * α ^ 17 + 4318183659819981488074693370040938716545728929617703773317165795943654804101138834083140850940446923358733078548068645 * α ^ 18 + 1593587693765014079746102214238987350113694708675138266157201007419844029857283186926010079342854945184589138949560164 * α ^ 19 + 532047925009422644797257472015181516662587259482075864085888807106871007422932953581727885439598490014141304896691047 * α ^ 20 + 160701892364069140905358669813546549814319510910544697552500165178091918076856803958923921001593977227161490804746106 * α ^ 21 + 43889653627121057923774311030558057038777866396589839090993605786486211704353490599487695285745585770243180871001173 * α ^ 22 + 10827357706237228452243490602525886439138079007606319319715720331950005385599610283148806774807521304374526909486664 * α ^ 23 + 2408842256812625932290911263046890728148322122703071503064745543954110106028352314896838503963205885454006647328032 * α ^ 24 + 482237450846393383131287501498018968499665598348674814673101519961867723893846884326467389187302292657246662111488 * α ^ 25 + 86620744735037078123451064351322751112466467920961355862225908103410633498456796660448573578914072648246281297272 * α ^ 26 + 13908651519349479073873240534072463905809010212400405416347877534040408226391579668251784782713336166212519013104 * α ^ 27 + 1987136509055095540850907316692328719109975779097323211935130132295635949953814198439654077152611676110556260102 * α ^ 28 + 251138932516361376722297645486554574796035287318555929793528638706264274506637419055880639659286763175005448076 * α ^ 29 + 27871094123052914818399316975765472111564288696313684416212667809570265754686721498698986614959173244385297518 * α ^ 30 + 2690865047909357054511239261296500605261094896849533507003089976244070348637842057420543829564694293947173400 * α ^ 31 + 223291370726238703406997118812607738047342804101888528968918478200237656608670127439529056632663807296136083 * α ^ 32 + 15669985331287744715848606174054829999776651533612117903292549399606649200386705738963593063781305669960598 * α ^ 33 + 909073729758232176167878755737698432102154655242833248859457302905520734577946123899448989405380991348941 * α ^ 34 + 42091260471451636997926921594629293230252747899173824918202060597101883618323097768155200270442748875668 * α ^ 35 + 1450861895455204845787988647170733163350496179912678839329200986510884388428173389320127180407765638551 * α ^ 36 + 19698279579096177164787018164158789132912466550646401885212259058865017062230215250892367283766302154 * α ^ 37 - 57652053317489414390572934832324830300466266131622345505450510286650133357321127488185831111381791595 * α ^ 38 + 735839726136777192033003352499083088738558026604488978404480341017143472486567180936350888710307864 * α ^ 39 - 4556557091452941380040035385055147646930930624200910749123957637499614710015132762550103799821048 * α ^ 40 - 133385784303410256278801057965454595590178412725438433339158980224721485193506478868247418219456 * α ^ 41 - 3423096723020314850982421385371010756189634167048478694293828864372204445633272936186470719904 * α ^ 42 - 69804839903958953293946387520015029557798645931631581080348037608367532112774187909634522240 * α ^ 43 - 865452330871186953510596734828786492278941181396935228550729318386099014534564956306824064 * α ^ 44 + 6798618471243250403976624728656397719531634223766543816506986827945697172779099788420608 * α ^ 45 + 788561506471686257274486905164229697457259305541495354329419768350740667053416558054144 * α ^ 46 + 27404388758747154771370930189376580679701159098426606936627216153391035767084433846272 * α ^ 47 + 646649551478726098614980210707984819816807233831805276746361716798674738190577340416 * α ^ 48 + 11211130515851440319438235357551475100839553634180130203899774136494056161035911168 * α ^ 49 + 130654761491363390209265527305244677484674002463471732106539824077702885812797440 * α ^ 50 + 357370958717189390935129396104908992248522307474545437642970135644954582646784 * α ^ 51 - 29181736810016345568442240720495430859483450421903151495150669166766787592192 * α ^ 52 - 955989844135526470691849812345208816075517571032312722273829147296013484032 * α ^ 53 - 19693589749621923555627023816809550207524792367857705784556171741361864704 * α ^ 54 - 319527958823219288171919301676630081495413277792849934402743906350399488 * α ^ 55 - 4359916692864270231911575583538878442433933182393484084715401339994112 * α ^ 56 - 51487996872395271018065603117315986670053043845988016897449388933120 * α ^ 57 - 534287852041371238607889671805075544881560005268660814584293097472 * α ^ 58 - 4914742088163302214038533958003066516795399439930469941648556032 * α ^ 59 - 40286770643795091951577560453084774722804729349509280681689088 * α ^ 60 - 295170417808439805757992973335875121127546339919271705968640 * α ^ 61 - 1935804396482191076314681386409043851261791712104853536768 * α ^ 62 - 11366432523474642581662414816114955814707861565858643968 * α ^ 63 - 59703170845283859723339853111711322814822346376871936 * α ^ 64 - 280018128137086019618307155094771953353132297158656 * α ^ 65 - 1169385347161959260160465901639985114274911485952 * α ^ 66 - 4331161143994110763407260197680039459865755648 * α ^ 67 - 14153828793218044771011521216530198581739520 * α ^ 68 - 40537586126827346928475190951612417835008 * α ^ 69 - 100883783567908658123954038279633895424 * α ^ 70 - 215746527094612923562575346607849472 * α ^ 71 - 390762372880065519809958474940416 * α ^ 72 - 587839886222327464463148515328 * α ^ 73 - 714822291149465741724483584 * α ^ 74 - 675179423113136706682880 * α ^ 75 - 464818794079734202368 * α ^ 76 - 207493237324120064 * α ^ 77 - 45079976738816 * α ^ 78 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 78 * (25811606424535915506326543401482443660479168162161070878750987845784640947537512918254143661443967851841624182260454 + 336370345330350208165234204307830830778265112065902973986047706784620119812179101529287799329664970700047233908530028 * α + 2135490323710205451177831007886434323850910269893926405766449302023972016567372609179660983528148958829173461437058426 * α ^ 2 + 8800193380808665214547458427848614541537421741398394617093689631071556593600442609061272206311515066984302690924269000 * α ^ 3 + 26462827687725576351409435396337556001601266481763435312645957683742611763538244106923991390112640216709155823432046446 * α ^ 4 + 61890317824100182817489513892770080906362674388551785381427868354803942587321704313688072997460165545388054174413205140 * α ^ 5 + 117172359697259929763030783557189322339080300100874585985220084088882745103145230216047487779174956161518920280447603674 * α ^ 6 + 184544739027532874709347195849421533711097651533181291373211062330869431152671413319813999120439419738468174182904364464 * α ^ 7 + 246608145764613286789878656386710073720610930090411123420903881172229605185065434892818764890373842116194248634263756798 * α ^ 8 + 283763693487574246430404620051411555790859557853657413692053633072552222818811355084552210214522447497912164915857007772 * α ^ 9 + 284375388167493337786979561808634395465424553508941556573930507406581722477890971264427055005741911794482115087411543730 * α ^ 10 + 250434456333498778687253731739220273422355020504490227298836915758303181227856673748711052077418442551670601820448469608 * α ^ 11 + 195186376833089073717511924197741339564583901408375396552289751612744737294639334816437871802096096044647044024483571528 * α ^ 12 + 135403325876044028593166865189418922031634343539481341612266706224679843802900374983571701066935649917189903585957861976 * α ^ 13 + 83987295633438700092517506437803590415296544388998812046873276158407316217262430264254188896692746403373298520205212844 * α ^ 14 + 46749761312162043935912318982126078666828249385834636225082169910759646501503433598091545864589766997203234619939545928 * α ^ 15 + 23418772546685983831264607439067708954491960164074800112819444923487497120280358300648725634717312663795784508649665131 * α ^ 16 + 10580616042971700828358189370081401738808367070894586162364463432933276777181125840333157268302229461101124643546709974 * α ^ 17 + 4318183659819981488074693370040938716545728929617703773317165795943654804101138834083140850940446923358733078548068645 * α ^ 18 + 1593587693765014079746102214238987350113694708675138266157201007419844029857283186926010079342854945184589138949560164 * α ^ 19 + 532047925009422644797257472015181516662587259482075864085888807106871007422932953581727885439598490014141304896691047 * α ^ 20 + 160701892364069140905358669813546549814319510910544697552500165178091918076856803958923921001593977227161490804746106 * α ^ 21 + 43889653627121057923774311030558057038777866396589839090993605786486211704353490599487695285745585770243180871001173 * α ^ 22 + 10827357706237228452243490602525886439138079007606319319715720331950005385599610283148806774807521304374526909486664 * α ^ 23 + 2408842256812625932290911263046890728148322122703071503064745543954110106028352314896838503963205885454006647328032 * α ^ 24 + 482237450846393383131287501498018968499665598348674814673101519961867723893846884326467389187302292657246662111488 * α ^ 25 + 86620744735037078123451064351322751112466467920961355862225908103410633498456796660448573578914072648246281297272 * α ^ 26 + 13908651519349479073873240534072463905809010212400405416347877534040408226391579668251784782713336166212519013104 * α ^ 27 + 1987136509055095540850907316692328719109975779097323211935130132295635949953814198439654077152611676110556260102 * α ^ 28 + 251138932516361376722297645486554574796035287318555929793528638706264274506637419055880639659286763175005448076 * α ^ 29 + 27871094123052914818399316975765472111564288696313684416212667809570265754686721498698986614959173244385297518 * α ^ 30 + 2690865047909357054511239261296500605261094896849533507003089976244070348637842057420543829564694293947173400 * α ^ 31 + 223291370726238703406997118812607738047342804101888528968918478200237656608670127439529056632663807296136083 * α ^ 32 + 15669985331287744715848606174054829999776651533612117903292549399606649200386705738963593063781305669960598 * α ^ 33 + 909073729758232176167878755737698432102154655242833248859457302905520734577946123899448989405380991348941 * α ^ 34 + 42091260471451636997926921594629293230252747899173824918202060597101883618323097768155200270442748875668 * α ^ 35 + 1450861895455204845787988647170733163350496179912678839329200986510884388428173389320127180407765638551 * α ^ 36 + 19698279579096177164787018164158789132912466550646401885212259058865017062230215250892367283766302154 * α ^ 37 - 57652053317489414390572934832324830300466266131622345505450510286650133357321127488185831111381791595 * α ^ 38 + 735839726136777192033003352499083088738558026604488978404480341017143472486567180936350888710307864 * α ^ 39 - 4556557091452941380040035385055147646930930624200910749123957637499614710015132762550103799821048 * α ^ 40 - 133385784303410256278801057965454595590178412725438433339158980224721485193506478868247418219456 * α ^ 41 - 3423096723020314850982421385371010756189634167048478694293828864372204445633272936186470719904 * α ^ 42 - 69804839903958953293946387520015029557798645931631581080348037608367532112774187909634522240 * α ^ 43 - 865452330871186953510596734828786492278941181396935228550729318386099014534564956306824064 * α ^ 44 + 6798618471243250403976624728656397719531634223766543816506986827945697172779099788420608 * α ^ 45 + 788561506471686257274486905164229697457259305541495354329419768350740667053416558054144 * α ^ 46 + 27404388758747154771370930189376580679701159098426606936627216153391035767084433846272 * α ^ 47 + 646649551478726098614980210707984819816807233831805276746361716798674738190577340416 * α ^ 48 + 11211130515851440319438235357551475100839553634180130203899774136494056161035911168 * α ^ 49 + 130654761491363390209265527305244677484674002463471732106539824077702885812797440 * α ^ 50 + 357370958717189390935129396104908992248522307474545437642970135644954582646784 * α ^ 51 - 29181736810016345568442240720495430859483450421903151495150669166766787592192 * α ^ 52 - 955989844135526470691849812345208816075517571032312722273829147296013484032 * α ^ 53 - 19693589749621923555627023816809550207524792367857705784556171741361864704 * α ^ 54 - 319527958823219288171919301676630081495413277792849934402743906350399488 * α ^ 55 - 4359916692864270231911575583538878442433933182393484084715401339994112 * α ^ 56 - 51487996872395271018065603117315986670053043845988016897449388933120 * α ^ 57 - 534287852041371238607889671805075544881560005268660814584293097472 * α ^ 58 - 4914742088163302214038533958003066516795399439930469941648556032 * α ^ 59 - 40286770643795091951577560453084774722804729349509280681689088 * α ^ 60 - 295170417808439805757992973335875121127546339919271705968640 * α ^ 61 - 1935804396482191076314681386409043851261791712104853536768 * α ^ 62 - 11366432523474642581662414816114955814707861565858643968 * α ^ 63 - 59703170845283859723339853111711322814822346376871936 * α ^ 64 - 280018128137086019618307155094771953353132297158656 * α ^ 65 - 1169385347161959260160465901639985114274911485952 * α ^ 66 - 4331161143994110763407260197680039459865755648 * α ^ 67 - 14153828793218044771011521216530198581739520 * α ^ 68 - 40537586126827346928475190951612417835008 * α ^ 69 - 100883783567908658123954038279633895424 * α ^ 70 - 215746527094612923562575346607849472 * α ^ 71 - 390762372880065519809958474940416 * α ^ 72 - 587839886222327464463148515328 * α ^ 73 - 714822291149465741724483584 * α ^ 74 - 675179423113136706682880 * α ^ 75 - 464818794079734202368 * α ^ 76 - 207493237324120064 * α ^ 77 - 45079976738816 * α ^ 78) = 25811606424535915506326543401482443660479168162161070878750987845784640947537512918254143661443967851841624182260454 * (17 - α) ^ 78 + 7731601171729754948302451858548754728747882021768914086305388067309744030714970733621715794196933994344449662661325888 * α ^ 1 * (17 - α) ^ 77 + 1134977739682559152144183344552781855394081041684581420063129512966886926387568279248276946977482731207073356960903835128 * α ^ 2 * (17 - α) ^ 76 + 108834637037659199091355921419729186300121822584927223690221434809345565260667023227379040139264943526676297937882231816944 * α ^ 3 * (17 - α) ^ 75 + 7666861356053587141879051542023151513155253675338534070219208289734940750831143744550245239925873313943561985580954527982616 * α ^ 4 * (17 - α) ^ 74 + 423077887233518864483787884707532169136310014420797711374285732639883356220901878487666885430844058504013013662258662655409024 * α ^ 5 * (17 - α) ^ 73 + 19043789756155440424344440725874751801324872083267566506068169098722085040014291705260338415543274194102043673327180400129929832 * α ^ 6 * (17 - α) ^ 72 + 718947188407260825753518059058500078605524217441449955961763119488742316279761434573371789300650648290365793225194740365639829248 * α ^ 7 * (17 - α) ^ 71 + 23229944260791702898096600141389848573573933604759267334016067683455922366132699662001188778646003391197287922373361993488875467772 * α ^ 8 * (17 - α) ^ 70 + 652356286335394807010040506322513589425276848772982033180582110575315337819948577150432209238058606495049799638171924460488723115728 * α ^ 9 * (17 - α) ^ 69 + 16115244618115471773154398428945842467530527293496478962865411951374999566160962962621541576431428483629410984630108362973322526046352 * α ^ 10 * (17 - α) ^ 68 + 353590213705899227670735133595068406610777044757491438541768497813388671143323439181516543806998722646874310797601900004357046159618416 * α ^ 11 * (17 - α) ^ 67 + 6945545366374205473681219757999841297413797165201420435841487238189483615527433260434909542451873571311839418856181380505673028690189834 * α ^ 12 * (17 - α) ^ 66 + 122943429683776586616098034509418349763379413100200501385374144116228404023652411356804056379171036434910191105635835310497125437439368616 * α ^ 13 * (17 - α) ^ 65 + 1971943361675961854095978497179540085473722438976489160404258526153302499359290412285125679239602051452003303294340674036438891755271461344 * α ^ 14 * (17 - α) ^ 64 + 28794613849932432807185452777239504156831844265536120723695409096275314438957801587812894208037520422020805646713238048377079475740273188040 * α ^ 15 * (17 - α) ^ 63 + 384328560383502952032438759151017028938946671283519542604007361014389867788722109711367554903315805912734859044701209907625689918745997497675 * α ^ 16 * (17 - α) ^ 62 + 4705189064883150340603293176324983232690962514057066121441689655603425308970643761709274220489500917477746179322066734647863357743464493676520 * α ^ 17 * (17 - α) ^ 61 + 52996214890563273796160643818818348185528424059725114966862380369319342813162215520720537479664066314153467772804561608859372679443782254992220 * α ^ 18 * (17 - α) ^ 60 + 550617253247385218427009607064332121441409621321669095638902982534390077955117952713512591688404159855259550612508039696237055140143912070148080 * α ^ 19 * (17 - α) ^ 59 + 5289254261689909642998694788883801072432560837908488801188757508626280600068147475966012413534329068218714313264686298658627525464990766966507480 * α ^ 20 * (17 - α) ^ 58 + 47071723811940484288699822861559515707560341788285556322087973575337149744998528596195569152380487445854405880284205334835719251975349528608895960 * α ^ 21 * (17 - α) ^ 57 + 388797566873530668184175407886161066305517869569175948336046190337058590155012538967688933864691298489884730691529378580953514253496007438959580140 * α ^ 22 * (17 - α) ^ 56 + 2985179603519724471752085802643613314281923391910045186703182258691770626157427630859816171548924404331298520035371797680826375874045307985095169160 * α ^ 23 * (17 - α) ^ 55 + 21335697765899092801522874710986881769845405599093285192366939176739104568310936178280383293402533817032054113166202401026875457402502001299016941965 * α ^ 24 * (17 - α) ^ 54 + 142124309577284830558031748098405686449899656084274181428411809022465874914849955156662717515516567844716088626134776657964597427502198457271981932744 * α ^ 25 * (17 - α) ^ 53 + 883340987406927324886485469060737975106344280304169568718286595798294963628744880539858577253973934458679980792763078663809587077960963632717815152096 * α ^ 26 * (17 - α) ^ 52 + 5127488920008786553466393714789905427388213762697569627668475082844096754564454348757229349829628841608199919978811602705936439756284569017181261626624 * α ^ 27 * (17 - α) ^ 51 + 27820537271116488598533849210418200371695645263092839593736637431588817343110855564285745636333362483896532668071984474388396970246448477332845548675696 * α ^ 28 * (17 - α) ^ 50 + 141199792955232750444991232388282777593870842150187857240279059394142520379652599318770827523191507794494653442014857111518160506592547548123217567703264 * α ^ 29 * (17 - α) ^ 49 + 670800231791884784143046690550307121328633658472928365947843469281367978857427131528889056504264285777346962640789773628915428849835988530657823235764048 * α ^ 30 * (17 - α) ^ 48 + 2984619384354511629107356504926848471696327337771023943436513427949142667105830054851593100735343248824065325292573736440802608827461183426769246769291552 * α ^ 31 * (17 - α) ^ 47 + 12443245301685101113004238920453035362065480822223920063453295700954394658154324530222082866216981544902180469303864185921832037521423470739534568240530698 * α ^ 32 * (17 - α) ^ 46 + 48630498545566508730887646850031839032254744413887093356079449812021579883240090827460324033575160396265167473696926411553805741150177366589537208618389312 * α ^ 33 * (17 - α) ^ 45 + 178224283616173729873597347832665682938537443237014013583101955743465983895935219727459727536113766122912311165368553083312822196229416994722881465788897608 * α ^ 34 * (17 - α) ^ 44 + 612680644790166184991917379793912279464385512434753774369824036938764938304766938235637731701416442390635006960662151462757565543096111536600700611590433104 * α ^ 35 * (17 - α) ^ 43 + 1976111675207627574170813927131479302618451807610755803915352844606204227936969836964454024080255606582154150762724021578810678171015308008029327160761230036 * α ^ 36 * (17 - α) ^ 42 + 5981029220510678070817415728895653202641308066347103599758984876348600755271333269460791392164878746120136312582494705765569069531832293963655323002573446064 * α ^ 37 * (17 - α) ^ 41 + 16989543154359445469457986390510733383994704572611451201272330066228088393042712150225004932550683152805630464909266619414416501639238958482074875942132768616 * α ^ 38 * (17 - α) ^ 40 + 45296105880774016543608993638859556610721433636610042456973317141222907592128054856106393044377927691870302622862352603383769755644737397448590274359670368944 * α ^ 39 * (17 - α) ^ 39 + 113350571234050534076326107126518287982410454182311080227306939093496067875998083564452872849439161949940409925105928531974054521742151944897862268669201061520 * α ^ 40 * (17 - α) ^ 38 + 266231157835868807500470306762042513611189637040966950733290536030191636687157078964587562059672497373973922906293139029665558703936748610317140546883955859680 * α ^ 41 * (17 - α) ^ 37 + 586858197296154628798446528461843998024068971134701870886809269117315332250708613879369916177860732342900319979198468207186334042554992489311324197461026564960 * α ^ 42 * (17 - α) ^ 36 + 1213922719117161670068732317088234253543419578795181021310311760507171888098020651110360608663151069102950683003635002998812668248827290683460647339113637593920 * α ^ 43 * (17 - α) ^ 35 + 2355882656955618145368440772792310544302184458306643829069873721060849050791043491096322023978836887243291929862008841402040135117369951147006375023758607414630 * α ^ 44 * (17 - α) ^ 34 + 4288620425723236042270245525821460550276787699330226001900869309698399107377083284501409207640281375703914610994654965609663507351571250965113379319161632928200 * α ^ 45 * (17 - α) ^ 33 + 7320707928796224459121297405137632144399624953401924235118562284160734706017732510625383671234631311037891028803627184501344210399941335731279835946303059679200 * α ^ 46 * (17 - α) ^ 32 + 11713899213743447915704134395332202117298482214292060770979810663078726380483695637745416926561937897954981745807583035850470327859420144985559683638576277883400 * α ^ 47 * (17 - α) ^ 31 + 17561942867533342398436880431957294329537588050449243474998468656204324106460768754190028781389060814644401148893175783608534017391500137587346401404729767961775 * α ^ 48 * (17 - α) ^ 30 + 24657037500931233931100038936709405139583850503696185642594534868113339647480541733889215934553454050856843493087316935868401534155234466743591899388039722825000 * α ^ 49 * (17 - α) ^ 29 + 32399766183005623339431502134384903673258583171905972220491732685551275126382181817021974632337480906159861245942216595446130287593916379360777739204014519763740 * α ^ 50 * (17 - α) ^ 28 + 39816869923705792061452702806451616229648477329837692188071941553276215504100718506084662900753752185561490136348790335058840343832503703423988939862391056305232 * α ^ 51 * (17 - α) ^ 27 + 45725596948318007559653827457799417148215312861758852406937933348972792240139365978502472349006051930446814676684606316211695543376347509599898036528286933085224 * α ^ 52 * (17 - α) ^ 26 + 49023805818598732375036617236844617864434596645116211451566972339635320087833097798204901700925015829301327369649045560010979770125252618435350703761516463073848 * α ^ 53 * (17 - α) ^ 25 + 49015998485968580948941115202148896246224655491148535539418948950288060451674238170130060593823432628223618516376352101072100358750709310490151188159024541427052 * α ^ 54 * (17 - α) ^ 24 + 45647022194403892164725670688230786593406330796296866532743501180312044777291667628466008426907011381782621245185421119984904334692872397917622931589975159950376 * α ^ 55 * (17 - α) ^ 23 + 39538178387322663214678107833346063706962357676818250082020803464382411757712672815180178231414974228300278324399692737955948708504923951831175084051680088175165 * α ^ 56 * (17 - α) ^ 22 + 31801899439090094777334950705334813338730886166159685008908427150218448246372446469199745436135611138307188820293411565869844276004036024233170865193572905525320 * α ^ 57 * (17 - α) ^ 21 + 23709975953138035217254879474127618178276877789282349375912411789239026737801814945663600235688954031236781561111671014867771739568818009667175830050625483670800 * α ^ 58 * (17 - α) ^ 20 + 16351417027375290237568460048941744283542362032677807325524002415873874456253818166492303955129235315728196511827486827201910640986408449258178453972071138841280 * α ^ 59 * (17 - α) ^ 19 + 10406661000804048469244285454442048401950551096021855689021431743408141364929640862344616974092488532662628383447959199105412832327366951066981956912776793272828 * α ^ 60 * (17 - α) ^ 18 + 6096044218883636648858638385299408772703826861168771488836313560232401989614872890471308028293712697562093239071809816669597593582410767226213878470560164105360 * α ^ 61 * (17 - α) ^ 17 + 3276846591075729012589755509945912260769516795393912260645693976533757884223032498368536502265562067479892796636427846477439354731388021106706514152220778103040 * α ^ 62 * (17 - α) ^ 16 + 1610794513834802575152755949091561602421721957898331237110261276182871154723607727539375914584552916560724124724924463417208104868865606317263016841364405825680 * α ^ 63 * (17 - α) ^ 15 + 721246729451681999848797234165823691040492879910986098969913863731997028544659333437426233091222522940845475324110626012544305358208410635315439163726896332470 * α ^ 64 * (17 - α) ^ 14 + 292822391376166813009638824792532072858861097043830666638215128792614436289145455232446359525025830476319501900465615628266091285776053359537792998581547295600 * α ^ 65 * (17 - α) ^ 13 + 107224012150816902001912227507553282916599557139225796253173519533916191353535425807887044534914331713036619424330904015814415822193999401215526600838512604840 * α ^ 66 * (17 - α) ^ 12 + 35191006165935842226308618125286667631304103617509372764131233521722150894012101410223152943777334278979699369241450735115442948195848108495015472586714890880 * α ^ 67 * (17 - α) ^ 11 + 10275267801259336459300721782985532390900842929751059267873958488400935538863318074454099079440422678680619531094605908728254236555735059631933624997615828260 * α ^ 68 * (17 - α) ^ 10 + 2645336786640622909024119594938504328204268908990167832700614571718874779959845931540799248941313778802020955617601042505306160484123987291058458612715400640 * α ^ 69 * (17 - α) ^ 9 + 593906665872865965150458489550777045487297564791632460724893427149867065488464014938181589464594007951273185164028728407261435342265396855306832150409931320 * α ^ 70 * (17 - α) ^ 8 + 114690263695272628709900519325805172252624298016857930148989306502982113118510158582594826209607467459228127771008256970868516723274528081539115152119985440 * α ^ 71 * (17 - α) ^ 7 + 18716846109423476071035991682553676602728521782795818848220231089640237632710705010278610380508724798549109713393602376467223809385880736717949117062987530 * α ^ 72 * (17 - α) ^ 6 + 2521536870830508163836030824568047223988339893444693792826398274518701446642999471126321332113161322019782540488604986950909127037746871670766269501360960 * α ^ 73 * (17 - α) ^ 5 + 271493817296270881805641386430241155441908017852388246927155500054431367358594643258294586467756369131577116044199352316870588393438911740552090772405440 * α ^ 74 * (17 - α) ^ 4 + 22279566970411804598533929895269272846291071572877769238590666634237638229153811201206324018077221933863978836996195706320785275148859533443992017146000 * α ^ 75 * (17 - α) ^ 3 + 1291912491540789931050578781552895013123449146872856063262109993503327217135399912381220941445555078359565379700265238460988056930139111470428573934100 * α ^ 76 * (17 - α) ^ 2 + 46088990360704592332570841005323881782750533628800932523924974522918510553541700882043059731976492164473134284830339681303220274485070007892391252000 * α ^ 77 * (17 - α) ^ 1 + 725258734923967308075393848591202551763398627116692128836036203184259468021639559495815066910705200892668021559827725204513110094309349741193210000 * α ^ 78 := by - bernstein_ring α (17 - α) - -- The Bernstein summands are nonnegative. If α > 0 the last one is positive; - -- at α = 0 the first one is positive. No per-coefficient hypotheses are needed. - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `80 ≤ n ≤ 100`.** -/ -theorem finite_range {n : ℕ} (h0 : 80 ≤ n) (h1 : n ≤ 100) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 17 := by - have hcast : ((n : ℕ) : ℝ) ≤ (100 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (100 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 79) + 1 / (4 * 79 * (3 + α)) - + (1 - 2 * α / 99) ^ 2 * 100 * 99 * (100 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 79 * (3 + α)) ^ 38)) - = 1 - (25811606424535915506326543401482443660479168162161070878750987845784640947537512918254143661443967851841624182260454 + 336370345330350208165234204307830830778265112065902973986047706784620119812179101529287799329664970700047233908530028 * α + 2135490323710205451177831007886434323850910269893926405766449302023972016567372609179660983528148958829173461437058426 * α ^ 2 + 8800193380808665214547458427848614541537421741398394617093689631071556593600442609061272206311515066984302690924269000 * α ^ 3 + 26462827687725576351409435396337556001601266481763435312645957683742611763538244106923991390112640216709155823432046446 * α ^ 4 + 61890317824100182817489513892770080906362674388551785381427868354803942587321704313688072997460165545388054174413205140 * α ^ 5 + 117172359697259929763030783557189322339080300100874585985220084088882745103145230216047487779174956161518920280447603674 * α ^ 6 + 184544739027532874709347195849421533711097651533181291373211062330869431152671413319813999120439419738468174182904364464 * α ^ 7 + 246608145764613286789878656386710073720610930090411123420903881172229605185065434892818764890373842116194248634263756798 * α ^ 8 + 283763693487574246430404620051411555790859557853657413692053633072552222818811355084552210214522447497912164915857007772 * α ^ 9 + 284375388167493337786979561808634395465424553508941556573930507406581722477890971264427055005741911794482115087411543730 * α ^ 10 + 250434456333498778687253731739220273422355020504490227298836915758303181227856673748711052077418442551670601820448469608 * α ^ 11 + 195186376833089073717511924197741339564583901408375396552289751612744737294639334816437871802096096044647044024483571528 * α ^ 12 + 135403325876044028593166865189418922031634343539481341612266706224679843802900374983571701066935649917189903585957861976 * α ^ 13 + 83987295633438700092517506437803590415296544388998812046873276158407316217262430264254188896692746403373298520205212844 * α ^ 14 + 46749761312162043935912318982126078666828249385834636225082169910759646501503433598091545864589766997203234619939545928 * α ^ 15 + 23418772546685983831264607439067708954491960164074800112819444923487497120280358300648725634717312663795784508649665131 * α ^ 16 + 10580616042971700828358189370081401738808367070894586162364463432933276777181125840333157268302229461101124643546709974 * α ^ 17 + 4318183659819981488074693370040938716545728929617703773317165795943654804101138834083140850940446923358733078548068645 * α ^ 18 + 1593587693765014079746102214238987350113694708675138266157201007419844029857283186926010079342854945184589138949560164 * α ^ 19 + 532047925009422644797257472015181516662587259482075864085888807106871007422932953581727885439598490014141304896691047 * α ^ 20 + 160701892364069140905358669813546549814319510910544697552500165178091918076856803958923921001593977227161490804746106 * α ^ 21 + 43889653627121057923774311030558057038777866396589839090993605786486211704353490599487695285745585770243180871001173 * α ^ 22 + 10827357706237228452243490602525886439138079007606319319715720331950005385599610283148806774807521304374526909486664 * α ^ 23 + 2408842256812625932290911263046890728148322122703071503064745543954110106028352314896838503963205885454006647328032 * α ^ 24 + 482237450846393383131287501498018968499665598348674814673101519961867723893846884326467389187302292657246662111488 * α ^ 25 + 86620744735037078123451064351322751112466467920961355862225908103410633498456796660448573578914072648246281297272 * α ^ 26 + 13908651519349479073873240534072463905809010212400405416347877534040408226391579668251784782713336166212519013104 * α ^ 27 + 1987136509055095540850907316692328719109975779097323211935130132295635949953814198439654077152611676110556260102 * α ^ 28 + 251138932516361376722297645486554574796035287318555929793528638706264274506637419055880639659286763175005448076 * α ^ 29 + 27871094123052914818399316975765472111564288696313684416212667809570265754686721498698986614959173244385297518 * α ^ 30 + 2690865047909357054511239261296500605261094896849533507003089976244070348637842057420543829564694293947173400 * α ^ 31 + 223291370726238703406997118812607738047342804101888528968918478200237656608670127439529056632663807296136083 * α ^ 32 + 15669985331287744715848606174054829999776651533612117903292549399606649200386705738963593063781305669960598 * α ^ 33 + 909073729758232176167878755737698432102154655242833248859457302905520734577946123899448989405380991348941 * α ^ 34 + 42091260471451636997926921594629293230252747899173824918202060597101883618323097768155200270442748875668 * α ^ 35 + 1450861895455204845787988647170733163350496179912678839329200986510884388428173389320127180407765638551 * α ^ 36 + 19698279579096177164787018164158789132912466550646401885212259058865017062230215250892367283766302154 * α ^ 37 - 57652053317489414390572934832324830300466266131622345505450510286650133357321127488185831111381791595 * α ^ 38 + 735839726136777192033003352499083088738558026604488978404480341017143472486567180936350888710307864 * α ^ 39 - 4556557091452941380040035385055147646930930624200910749123957637499614710015132762550103799821048 * α ^ 40 - 133385784303410256278801057965454595590178412725438433339158980224721485193506478868247418219456 * α ^ 41 - 3423096723020314850982421385371010756189634167048478694293828864372204445633272936186470719904 * α ^ 42 - 69804839903958953293946387520015029557798645931631581080348037608367532112774187909634522240 * α ^ 43 - 865452330871186953510596734828786492278941181396935228550729318386099014534564956306824064 * α ^ 44 + 6798618471243250403976624728656397719531634223766543816506986827945697172779099788420608 * α ^ 45 + 788561506471686257274486905164229697457259305541495354329419768350740667053416558054144 * α ^ 46 + 27404388758747154771370930189376580679701159098426606936627216153391035767084433846272 * α ^ 47 + 646649551478726098614980210707984819816807233831805276746361716798674738190577340416 * α ^ 48 + 11211130515851440319438235357551475100839553634180130203899774136494056161035911168 * α ^ 49 + 130654761491363390209265527305244677484674002463471732106539824077702885812797440 * α ^ 50 + 357370958717189390935129396104908992248522307474545437642970135644954582646784 * α ^ 51 - 29181736810016345568442240720495430859483450421903151495150669166766787592192 * α ^ 52 - 955989844135526470691849812345208816075517571032312722273829147296013484032 * α ^ 53 - 19693589749621923555627023816809550207524792367857705784556171741361864704 * α ^ 54 - 319527958823219288171919301676630081495413277792849934402743906350399488 * α ^ 55 - 4359916692864270231911575583538878442433933182393484084715401339994112 * α ^ 56 - 51487996872395271018065603117315986670053043845988016897449388933120 * α ^ 57 - 534287852041371238607889671805075544881560005268660814584293097472 * α ^ 58 - 4914742088163302214038533958003066516795399439930469941648556032 * α ^ 59 - 40286770643795091951577560453084774722804729349509280681689088 * α ^ 60 - 295170417808439805757992973335875121127546339919271705968640 * α ^ 61 - 1935804396482191076314681386409043851261791712104853536768 * α ^ 62 - 11366432523474642581662414816114955814707861565858643968 * α ^ 63 - 59703170845283859723339853111711322814822346376871936 * α ^ 64 - 280018128137086019618307155094771953353132297158656 * α ^ 65 - 1169385347161959260160465901639985114274911485952 * α ^ 66 - 4331161143994110763407260197680039459865755648 * α ^ 67 - 14153828793218044771011521216530198581739520 * α ^ 68 - 40537586126827346928475190951612417835008 * α ^ 69 - 100883783567908658123954038279633895424 * α ^ 70 - 215746527094612923562575346607849472 * α ^ 71 - 390762372880065519809958474940416 * α ^ 72 - 587839886222327464463148515328 * α ^ 73 - 714822291149465741724483584 * α ^ 74 - 675179423113136706682880 * α ^ 75 - 464818794079734202368 * α ^ 76 - 207493237324120064 * α ^ 77 - 45079976738816 * α ^ 78) / (8726915358595123009554969816074437428683544448177575906986909934144882288031056240648490385586384 * (3 + α) ^ 39) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 80) (n₁ := 100) (k := 38) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B80_100 - -end Sendov diff --git a/Sendov/FiniteRange/Degree8_9.lean b/Sendov/FiniteRange/Degree8_9.lean deleted file mode 100644 index f05501f..0000000 --- a/Sendov/FiniteRange/Degree8_9.lean +++ /dev/null @@ -1,120 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch 8 to 9 - -`Sendov.R_le_batch` bounds every `R n α` for `8 ≤ n ≤ 9` by the elementary part and -moment at `n₀ = 8` together with the prefactor at `n₁ = 9`, so one moment and one -certificate serve all 2 degrees. The certificate has degree 6, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B8_9 - -lemma M_lo : M 8 = 7 := by norm_num [M] - -lemma M_hi : M 9 = 8 := by norm_num [M] - -lemma A_lo (α : ℝ) : A 8 α = 1 - 2 * α / 7 := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A 9 α = 1 - 2 * α / 8 := by rw [A, M]; push_cast; ring - -lemma c_lo {α : ℝ} (hα : 0 ≤ α) : c 8 α = (42 + 1 * α - 2 * α ^ 2) / (14 * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {α : ℝ} (hα : 0 ≤ α) (hU : α ≤ 4) : 0 ≤ c 8 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := 840 - -def betac : ℤ := 63228481 - -def tauc : ℤ := 304104393583393026770083796931785379693060776623910754345993 - -/-- The moment numerator at `n₀ = 8`, `k = 2`. -/ -def Nmomc : List ℤ := - [5292, 15960, 40620, 3056, 80] - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 8) (gg1 8) (gg2 8) 2)) α := by - refine pev_moment_eq_of_packed_bounds 8 2 Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 8 α t ^ 2) - = pev Nmomc α / ((Lc : ℝ) * (2 * M 8 * (3 + α)) ^ 2) := - integral_moment_packed 8 2 (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-6 Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ 6 * P α` is a positive combination of `αʲ (17-α)^(6-j)`. -/ -lemma P_pos {α : ℝ} (hα : 0 ≤ α) (hα' : α ≤ 4) : - 0 < 656208 + 407736 * α - 877827 * α ^ 2 + 621074 * α ^ 3 - 39267 * α ^ 4 - 5436 * α ^ 5 - 180 * α ^ 6 := by - have hu : (0 : ℝ) ≤ 4 - α := by linarith - have hid : (4 : ℝ) ^ 6 * (656208 + 407736 * α - 877827 * α ^ 2 + 621074 * α ^ 3 - 39267 * α ^ 4 - 5436 * α ^ 5 - 180 * α ^ 6) = 656208 * (4 - α) ^ 6 + 5568192 * α ^ 1 * (4 - α) ^ 5 + 3952608 * α ^ 2 * (4 - α) ^ 4 + 13001408 * α ^ 3 * (4 - α) ^ 3 + 51075024 * α ^ 4 * (4 - α) ^ 2 + 49486080 * α ^ 5 * (4 - α) ^ 1 + 11634560 * α ^ 6 := by - bernstein_ring α (4 - α) - -- The Bernstein summands are nonnegative. If α > 0 the last one is positive; - -- at α = 0 the first one is positive. No per-coefficient hypotheses are needed. - bernstein_cert α (4 - α) using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `8 ≤ n ≤ 9`.** -/ -theorem finite_range {n : ℕ} (h0 : 8 ≤ n) (h1 : n ≤ 9) {α : ℝ} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ 4 := by - have hcast : ((n : ℕ) : ℝ) ≤ (9 : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ (9 : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * 7) + 1 / (4 * 7 * (3 + α)) - + (1 - 2 * α / 8) ^ 2 * 9 * 8 * (9 - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * 7 * (3 + α)) ^ 2)) - = 1 - (656208 + 407736 * α - 877827 * α ^ 2 + 621074 * α ^ 3 - 39267 * α ^ 4 - 5436 * α ^ 5 - 180 * α ^ 6) / (47040 * (3 + α) ^ 3) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := 8) (n₁ := 9) (k := 2) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B8_9 - -end Sendov diff --git a/Sendov/FiniteRange/Degree97Packed.lean b/Sendov/FiniteRange/Degree97Packed.lean deleted file mode 100644 index 76a2c04..0000000 --- a/Sendov/FiniteRange/Degree97Packed.lean +++ /dev/null @@ -1,97 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.PackBridge - -/-! -# Degree ninety-seven: the largest exponents in the range - -`n = 97` is odd, so the odd-degree bound needs moments at `k = 46` and `k = 47`, and `k = 47` -is the largest exponent occurring anywhere in `5 ≤ n ≤ 97`. As in degree fifty-three, -nothing here computes `qrow`; the kernel performs one integer exponentiation per moment (to -8.5 and 9.1 million bits) and reads the row back off. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -/-- `lcm (4 .. 96)`. -/ -def L97_46 : ℤ := 718766754945489455304472257065075294400 - -/-- Kronecker base for the coefficient polynomials in `α`. -/ -def beta97_46 : ℤ := 1507914107839613461190462412295600359845707101095963881257278337011407729927103240612080185349189552679618587678780881774299520406818442056480017536483382141624485641328572456113429188944201567436801 - -/-- Kronecker base for the row. -/ -def tau97_46 : ℤ := 13065819027990959586704485898393540700861338189552640880901815470984692940050752220686015396012918184468680277204610796713866838090492793771442952088388750824761294522032764298223918548679291817450882144344156527625577110220508750642094689576541697461191609648502526757921955709734426491216086983188247543232608679617226969890394207828219082441356672697427892715425673493091747666409730072036191746453281062014765165828666270487765959897645448509666458099105468911865991790406220052447720879631146034611866644693675941926613596855590288186239241565320351405213634552256433255183868635665083185765153023579597499789139287115095063243916181755456338902191339825531158742446682682630327627625987717981236808751339780621347736079848690448362823033510820126197899324464582644653182406135346986353340525640441056549847892479156463344944680032699148586325529082290479847204231240300847127075067494441384436905504458283585873134340112019361966092575664711462046619732152112728577623568397936830355983554418356339936079504613993923957043217199687185478903075408011582574152113609376250018811183013305659402343225900449494943464372432248707483614028678824368873167376115550531449525295429802096570326359288487513032225404801363839900870269823291020153434322473523937733873749412841885786417848160549595064547416320713071659155578009337283285047943067379410940680441421992136140624528219941094907907260173029212776290163761396413238655628136595636539760595436600654281492490622552769577294720216611169317396164072961217777738913210812483448622882466514703118354136756764729095792936045148879949676725115518678356395311538930552226333968439011910162767000514879222364226625106280969065530806101540047234897704574482000834767863867395241539227215560005192184126639658595516602675071431290120425642841698683587817768196207874679269413083699569093485489672929766298542507967688721205387002075273587059488925370573355794609872510219210957097964591467175891125239420029220642940040744930984720711265709331967621771332522989061086529822916566371844026680354429868701075149859282141773132333630657128438392374962135770455800605454383656032802280547441839631111759216662902609911503608333425037894629554491923175558981942142238857516144162306316897921234740409417635555188776320262716471841224208416087832721177840714472136258404276584772479108584690839212490197427035778771086033368300008272484089379269318703954080766986997476127898199421563394140970048426643389052218562891681221541068339716541119331265710140759639389483254518089099809816696847497637358963640390342663172546149735384036173373927515166448592193981487087042338685225027079772457541368762477211320579061837244580527313714061589003719602423374485173323780268360347213762476477819185758763590677660227837973981018687271676582677958517385840404881980433499920187069254086972849431270087823113910329354937278298921903714157961060469014175345280762484279412572349861774211191371593219226586366409749833262956882492775444895243717442940250681121587627875665909777083279272048448543885282144098138407200290735094644343113274532563637504082695788929123636445208738375470519893311258432662086321500938190824957098555101403722238774442252208688726177943601436176290992684330856847232069318698927350161728745088380343493980425925737938155939292957260450368158938453577946195351023421034467610052993454531021993292743552502888983200138531544664736994367823883798302243675059839749636442813968342643205742221411318709174355769157627343147304061379514963341910322639193072920344004082929164398664060465604743278612269716992295087218054928310646694134184239929917982013695742362766029330988323449792140515961349747785527989039168521005527474980857053737999733708266728051746779523938547281534100787724070750814660643295790505804751678319401142667900892694061280361310010622081770882758658031051669991906405309919112647339759803208642606869464171721353576490189121944287715931826407318835427546298422509938846142621724922624196697166086917627712934228780391770164647207284433085172727089904631331093630731557151067778480096036632772555299993784401109340892460434972442675679887131187609224906683650951685049415641885749237580476966341317453839429100015814665921087189817416086634767067355942290807105240820121240408683185328594910715312885339461723129988055936211443978527806213468286852782708162585990284471102163785211055481596938221347291401911999453759447175166779531897635083884669100312312242687736534979860197957090374153421200128208215340710247612300924077563747312760221698874020765021153280706400317675367348730910378507669462242980657391089405068022399792578254894574853211582059956843272865755830390239859768314534718143997695029036370290903037883381697524742902327958940757346750984428452510976637598213150847370494370901432300625674352318104079323441528710702590998023118338160913714073970571510624201200219839774191109342751818782924569598392758626544018152331700390124737450360392159836790683414593410766136321939706444808237839761762142678169940917050153548969278880758473904972009837124700461897537493684737950608404509773939856401928679238261226543443068816646068540500845137431024958935983945678241031976396592874293591906134390813123884991816368096978252527082643853777217410967467363182441057965816274055173015723281049112753662037363303525533990922862350406171606662311212618740566777228224950563279402274236671139456849509886801144627010252579746913454685153111707945524144673225738358233032612210387892430102040757379808310519984549443708711526891180975846506320219789868168946263067782433192940991762463716926350750934329318931105631793347854237245834780316187504603982218553118054683716297469125990741236382969462040945296596321198101037149813708509549530635862835135597612205476154123283785711178285173826923917775804892867247271734957775749863941861045647412319717314220149886829953795028879344904987908813632934712245019172855498180519414971251588684457171279023478628381426366697468327834072565904257212752146008335050946120257742524486190015163956658518026269551295932092597437673909144767147549224041157103157987216572619330413012789967668634304389831192038218808260793781060464162145432331728265450514415747269996092782896232716892530663878718784473002668082158207294252959271741946433509022128647697926709240990613833655017936050839989826528685294673701369677919149616124858185970936077624593392094624520260570428914967780798222353702409664897272453944834641722474219234690427717219721944180726787414928461295728907884519696095179707766491308436180506847829034031823650576531157762839563024378244183368921387589447429037273922060557496636660690331791480127297632434376730665806156551323028654548150975831132472751848058230741615392893865047913039302865311387672908622078113724628907047925504202538970442915683636317982992306867333214114254778758452395849741422703225473897304266777936264066400574974189076245908354459685309069587175566808446237874064566938396031128995763878319552837619444442069581834863829289114278571591325908598514865214864530854072394054334735342094594409715931236139729406894460484166037628081285316336953477167721569554590003228186146072976491177650134874921958263411743817621388003269613212327935105116783005434062937915723572152426838622152723624012102382707384713698863297310742943516145686968549717510954461832226885917609893169323107959093667188501697161308018260110976022570727149124085345170240233747303514100906313211539933925867505053505733929593330800095443954437490887184023264257539486809143468432344152122915343047975773552136669255876612057628425962830059032320159759651721891327870598758019878855473503627955548552176977539583083780663140471063164485689938409773511447331316692821129322509637439268944890168539153064274907008224080006508662016394616368660222006776974168277977145389519791940313136672164798582045786803209612219535953536848433825889024934926562626425188596848993479473457351401524495106001588310639244001487932009775223692926968053058115694965450379370748074559516583452639043253668160059079219017008192464077642635457210867525677141058266292583729327326143588297635217171632319600146371477928308129594245433322346201520715622698267034931880318851581897762675240298319455548763544776077390977957698185598039657580485171593364056510437224450527104544431559816552491267418202441219198921626357052249618333885815385703552870396410850011600194709078175133298017633337509702437879000387133351042157498020040914069607602402166930376540914730747717693555627718361148363458964945630770994761275935677115134095509460386425731683474515019840353115153208724039893545150168828806933160254821429414701278488304496321704073427690094749747027650952803518279547495030827082818233276934989378761016362053710387772919612158053272270012600332317170497061592886529529254372295854850942597320914746389632737637245002127523671571055975679083734510128492461167409118787259940418224838609856846172824700015129893326934656031835311091194228972113133313698250361872008977866584779125351172423042833383025966701533622760950444448400693219001739367773543909674558011820196540032005648029828216257780264948839745594937119697390714390890289555414030070612293998277085816052994189248652569798787689279547944455230338704226792535164117702425609533782111755524764906566733875155967228802386001544965644869566146787561759900421112343586219787612271204773911549938494266803291134342746982285407544932886248178324796127506917386506484353747898455917269484055762039159166723258727084937832653292203539656902823164578556894240098729774631727143659785887196677235158136068021894246954725324717849118087338536564326403672782861149482433642053782229943480162998431991498128629509555545994336823414013851640090831849415592614228824858514224735117902065942571816493957359235242590458586352084552690259765285885935245201688874137312739868843748567091632002957756935404617182811928407927559676262453886649004872513236920432912244546297390155436127746102035661210304654782183815839969472508556454314068316772029830438105722577880387801401426734394415040957594530815587600278105675515917272343484494577114883280849046487682714180102483678871394719896018575482244735005844767456889495568785777877981512650113284003811689455074752314696232863167636614162083115866723991146859331541315407509943124590292201104416369291757416357945141136804984846632749646352200906216927083250232046293577457125309913467341750443093893792826232587403912823553367336742988886368383639554530496843170278394612465253739634899797201870426453746536897700586966415268042180082437508156256445558501025794227469238127779848460538101779980514577734760157696018528968114794091710117508093380485463036418750331133740710457956951364391798802935258938326827068332119426599163378965972902756232415296360198048712968199627018504943692954967237658272918513592468018073921391929335935836973694094437206355459450703597623803866247841574327656661465796398938023202104940197056830715109410444331900049971262224054818798287455809031836162362174580183588243240002308679324767369750925476290580259431904936704136433311664938133247145460134071910089313630344440499523808949271740561545848067772169350488775773840532836897675357857614690481537303880716626585759173696759048641418102425486316721503322924275347124931578823699090155150831391149355010597089555470242724973055290983333020367016056500561639429982306922893937255196033278249647562392909828596339171637590001234484926592691639636117227829113177035089768370196685139145759364484815400636191945798946574236119956157438039246946479068254963577284012390826751602952410377261921873795720910185813226863532904071238973902233642066567239260381077818968984324251290009676438894176837437824978865246811857105848204735409976906854399761343603485881298203124799408246353670136435428301323283788602851588146287817399689312109571341281300777705638489723853108860320762445802211044766941956860749243744067316236282295815372684283853301940802560998985194277881580172167726885315462751443855217947236161114000407986967896238098561209348670375680413886518674995684325048716095608488134774624175714929067323825672016312549525494855290639701098492980903990580359948476472920758191158269022631823646207407919990127689993918084904550617833468475859967548817261486129225229411564588245947576011679346282258719549999014647389587717951858899174033600112738733388569680210438896301023472916280485123872722190576438745176799392463667102632420685997822424068495021980457978667209939879737672688488954012853113658146868566437076697930501670617217181734484174239676352217227952933376396491982364718110166943999574160638237315920822990154499250285530238736825836067680803391671201795770858085160438463035919301295534358541221373223854286583008024449140761234573047386753317478180124137938580489805422229660947754526806099755610612363483332877379700409754563209744347410075667466332091075288729450231646004069763962350874385907127011676409398658569484860763573453000407678878293390863696825915258537961156337008311266282570024192419526678947641567299631347570122810687857386336747282517564548642387796523517987426575494121971021665299167730435159427176450089602543040284639063905378309178842677987808887504182927541317084703273714068472344424034324246794064579245522639655691351035643340689538022678360551753024460319537250223809435980401616998250340573177594239650763075719677503472503560268374885500738705475231713305426366563454305958419274575307625653627378707854790726000382916773266183775967061069858224980313157192803956762413370700596301130034241422413546435691788827472371110999333868670804743881206840427049380264618174251652418101867032609697681454289214371189779640128794949139648964144210672572059581151426976850997054889425112320277172461814813106661732071623452867705130015849491112904128906105181250190223812430679769261637328827094958758084687932726255463117486119528062922823818891564280297831624642938602072101809864271431458886142521308983446876422850586680439250163745322341820069164135711062564697870173238759463975759630885189620152576739514926926344410816753827290421598805017490811890542664117170736715202192145491645013029670418054728045648012915433521597134417346318030499620548201578426309724569188577383980288770376575508136086438625905301710129173941373145917244058060880274974237671930178652588239263181211362321999675432197410048685284814051797871414992310832246807178121856405600289270820145984762767382082857501528728065176335743496784003172447164154430519653624869331605386857267495092309997993129912611638968492286089126004138671629854156396171059478927378820967771383422172970742958349884361129827661303964849874086975542414309604451480829266415109702550035683294522294173342005252705143316894111633144572922496958073746625052091718734610533678784983419473689437382192304803491509423954757686393532071785741355331162640309489257927389356903033123709745626188199082604088112185301088471332911360215740508761760848557167849330322192285278256243142029278034241231039569352297159645231866684298278587766796807330582020119408904702226446266762557736390698029436753840193381904868983215033752411378237804145402745540060616673796232430099850870673532315183948127936157587569428009562053122589461790286170848150596143853298632294267522593433596813043828654167440690832885499889289067138500448427582743151048505495273878277631733510997827176490142329915220165468710853494579436155930913790694923398112998998808649826836182561804381084387148046703319156123717825021103499591263643003466905490894369611316198620599653777114858141884564623270395960140811919524044176878021997334098636291629089936496055842052952819080579429886173767178783528243452753242963737040015079984629591938136297211065249915299594744077367578956795092771271310007242074558401186491476513119757940661041283926063725401253441977310766403885657133565862072270777039257955198591841859922349534606056556222052666597508307788027251773799017428908607012077167543367664696101832662696208251018547771919216881375384083986309900011030284228897574487834888568476642471287570705389521155639072224896561538376259389586754695528488465646796858264612396455456107820608930226051879520344666236529125497877987196246790606782736396204773588099705682208159100085830634328035540208728699075782293918675267537154216162462719256792941615731478162222885765095338618568407815513150556951389659227287871320814610612359311294242864311385121205971461293462136795664038078215745385282034149187825131593555295442539770194747797434973632613040491425659143871716685484942047801271422533848466625554735411108733549076304391885049251735544344286200260082768631140518443537488247732958013953549069030831184004558704051507643093839987079940547427657015849286925335017555728998459722427867779259493986156240406817634881376195540414032203438220077516768770256908083112811136643621367954167133726959876645021072295335387446065147845541894540368556150223423462856833353205079119336675513922525802073673617788345870235235056391306730984096510676421265105312217165788658071808041500883147451245384618167533978498967231074573366320482453166441716770423275243361812115866246694578905126628981297340750341194504887326721520976756731137189613561155881272903318501946356232605875185899560175149561384911417322518357247200061912759395670325703592386896442865155963529254376435672102927089285185925884197880296217496162971762838234043035039217242986822241794241694641308896314625925453142804569873027491921551058923741395072259655068982622012180165684010691041263285934313759891238186611901356977680605830408524250294029591213249789832550215656773920656330232386522436920599450681569860257769158297437522092163787675736739685550943901941005687849620397776488646387414551033570986281581488290201063699228688610738667092433779365143024636898483155184444398519650393184087858756471466248720649620380401844211372679055512201781908960557988966428814503701474737160940035766948734187878778905438324954490271053981499590421434536129081494275771860217307584314983871587425540634520540792006790294960872960332920165843695807334590604350962610026451885624423953626631181464391514008411160496722712226690306629622700250735955490701087341046709160162789550092559764721357498784156535943093460897771490164433610929173204297796998624701469941173651317279310239521622795817327798389379541498837964105391989794344021611154856144275653891162944475334515972548488815958182697533897723069530056463456602912401833352744934361505623287838734022865485126345075176944716647210050138315490331228190229070869809321171650469188813659458216638581377436050295188581171858160614232423153594854177585180922386651586458329964760788446444217213698483306460107193985239660800217156915777843051781937970294173993054609209830497013374661986473403595572850731062020367069588190458355298736580323974850796833981223744257403284454761818025409505893116010480083596253986260289140976193694045607372358939660217500837301449997516151387976465985712646081966987070349990724475322921834398233690807388729567982524126624237389505630972914521742368159739529793981410464040152669848928344696936767009696518291398110366307046584547536953229027248398275448672366569170636070847711018147265547271862086719957249649916482015053122178124715970465605527335283625485876794298700076668411361561688542690379986566396051505988314517730318310545409689496051774622907206895325316553860080246885190539754367090135945592923996844121496751182633128531950814723479682528359307524103835804938291598426444129769372025663269397727175282344813327243363438900960041299327807243158104489560539789654128126881550799614834350261295481333668989852367242273838889093658654511423930977690023200906024555615892436863343870723425493902329102081750065478903252938991782113634169919235206011064286010057208133409042054430583165150800116929559003061004855680550149119545409074684815404230841312429571222549803279756040293855514667302417563919680983870239548153776145676241633611395988499611746496567457457061885082745440297510362074997075763377128938541236776775622644418236102354099938069142093012527676995462008061287762571409922159637598091921222353751312685692817743988436921358960744019896708159179585144519531781352555696271304657924319210396502315421649605721936606265507697422653608073423797171689653150137873386103180776742460248187356863640533281938517227171428534238416604010826792657842709867968635580377234741453346508558038257804495160248681441164387984915560087457599833476153537011118761697292255904433870697325633141672283056711072748606959551224077693613000829770278700967773380953887264019972575461680398921633954036722368044372360224844814027232272452973017201938782516845130086171560633356561381426864520959793929948037130743690791186508431474378866013084485552604715228391886900541388895503486602042106017285479308334287050557391504157426168132046367369566118511918058991339929847595732384690125215634356106992117891831299744744863791515197063254691878028504253696468643684572818512869231446618308209668835261846743267789653607288326846031897410778683538489702854038691317274412977350915407483502453529702811237653613876502980577398143696761319348248559727966311229378191104079919846412922237305806834586795381766663371551662649619310754387711910170545814184810080344733834276258866086434655413604927308184623747116635198212103106508070929586866749997127907542987988962576677688969023463172284394449122654460358352056246653951422703587709120541371138526373724852822208425961335061257330681995984624473285404321776197656854610293375471507975113349384565655214718153297090108878059210951803174325402136754455170330931483745250375940241968923891285177237481629744482835140476036173980982603582618683380618753756960347915390368521877456127210683610593072819607082697063492291107454916723811362893153853398003982722524049367439200151360697464037540493636294920874128629904482924180426478425896399658060962113066887028024473720030989841857260124403893381313984364495365025416816389371870277638388224100777948086750815773590804760046586553809627930147191161161937180428858611293782080624996237225064289366553872917991664452589630879269800607643070901969663398412705336524499422816450773260840029833046168583935720935856687034689728810802140370589138814744102950207805417849426020975760109094390712953623097479912536637826716820232849386876966355512770964647901673167181529836183756982892388647175324674218202019933499623250445665498167273480485580516188272252605896130731967091841243501350021639361487844970774357677719513429759597830845265324448760318814032777758405425922165209578666627894116009949715537334057867614113357636644061235482679728029476822186861446894741319904778616316907011942746648676778626986588095269345264349654213531840512456753195926307372011318179550861859518099205032319970486071696633213505022996886313513723609713886619522732164074454219125783781970315011666155823955089960436994377692795071719685664454095222781145131773181317807061544173891870804024819957617797933884525695143323785543709528405189519893440120828130436190522859068761857002564591453674092456735357393679968643194872284047011847201581877391685093953584497352666902594592741651664206195138497476544287887650093481587156355835314678892610618182585436620762755093363091507844272624861069708278793752752987234556163235519401863617447752678441817155098999429965350199295657168723156761143815224620816350573161377895638614829915147505597942719338978780819423020477978922719648895735999404616875362576165161374450574714180692110222353910205780442682149533196693252768114638988395896969950948956771459812664665319011198152987293825055088580437689755033453546124485826536227792658492056410193721565980226058106788987552711215496711591658836874803183470043704172659929955347190525770555127483786635651791164876752917057580897127021431710146452607539054936334724540035075095814118390907130278368012457974377772987891603528238347199328945914433427674478756246458171365900553107471945552782231764349046064558571910936976331167933798242184803851989189845618506867093684933871649216194433117383539004739864649480961816158074215954692577212840675821253188009321849398044450365624859939486774359530066317369036239585634111856162107119913369828570940055087478706127528816782452423612931247550633623568496389265297425803134844258411431212834110607009778877554309509396545036402438351677724277398423352328564104309786155458679008651614303086644388912694768097183755968605439253781059230309502455789381508613741893079295570347769016715714333314146286794535194279704274249674489425501363358292578549369261489179808237128755797172005684548998185328882391916940600941382253661884617246299191540889615518165285586950431002593089021745661596114572310189552861920269348238663813098246708283933768663466669517438774736863627376047488370332214223744206984678927143774387971117196596995573947405542956429725876510727160620997559204286512594526108600698276867740808519855491578029348303147226385673819194597982822957915842379256884714461432029852199355613997860590845696031318106939859601746295108008292086614939167204356543584439066366937542391907824581373970090646038236828055462877761097755712368490839343872123557143176262462879652783847397666985710537539001135814353205466690266549523685126682960721226894398222945059505426760748934782215285242403860944227020898033934290259833345131029443073253372412114352781973250880911100140149663798529354515380749711477439385970928999817879684735910191554096608223201638727678030514168179004465418702854696350567529222370446578130108926685938605550390230774280433929111837423643659282521304536800800530749909808148060086548359333576819751536755305696265442692451961887448150287700231873047430868428947689298869710705866734668631374275811981770328099530595572708183198358625831267178678856383442998156568403527780089189711162829282557903295325625885304625321351588634163755087565912887633313985644075890681765920975174735417586471406209968253011729945660875556377914264837919333146733468723770550341437997551168791038865522119133002215783962385509787474919385588310098339798381760562791984588152501326071030432798690814401528417364802679130318851268798603835992455622331045858763367760380705411185569809186956561909016773919911528184852393467699534162643900087962127055359837083549075420257379328754505216632068376344380903267633019685735863614678086159403906814468033505838443248211479654057117182200188256901143358920161029321235421333818896217070140384196400819992543270069381467375881404225557920780468483222106404858000989459520004877300802738391778227389242964632835357471571828286289224020886498122346273820556549991686354975494735754741789875409032463547108261736016557293435382462120522425183101592421853339733515933364574077562012775586330564553344160558860509957966801778522681984060197850493755366078003302322874881203485850587606536378980256779155654090492744630442019952154165693592623770809711766085196166498229852577235341461122982194472861532389589982301383159908265730134752012288058057037106338364657346200509114892858334358871266403796980882439130976315112923394070403394394867386966361916023693494789480943686991340236225626214256217992956469979752075092749518975256692872762986267236641718443337121630527296882486664335105315382819172563374867358114879200992024584443651622363576734742432302898547666028961426869230951287400406358212864229287109733113246978143937968340464837221360917266257436208264142538354627691061482649581962033582452517379348611783281542334874318557625934400335527580964609399371742806598100521063038900636254575915323248248433837623420578988507056344845897334691670872641692974048363096818929329780369860317501955413167207851624833995863386813868263291793904798376445735278842902440019493947348598170831208579073 - -/-- The moment numerator for `k = 46`, supplied by the generator and verified below. -/ -def Nmom97_46 : List ℤ := - [515902733389735050383071565105898209967231459510061043616785926145219403530934938880879020429415981401894632028759448270330977531209082008816202745167122268160, 8294837217481935116392654765885355147893467353798440268591317672431034503199991015935012272151530305369748170187677667588219906597255913342298974082666437017600, 65281732630635811483205527121093907779318143465401654421198049715407967681317109220667679785776719207758728479250766882901292295122708941094281660700190394286080, 335163155603443520078337454906690470681402202284937519270393651212624969805559879229289892389709809663249545823752775527937315207628235257142968783630230565683200, 1262244632615274762276937946012552446874455519315040383887237347021477127993285379428093875054665149604465204586613986513687835261541990579886406723596695948492800, 3717594246433299406187277092910152170993015300800046238191914142227721553581439421914043979173130712595277425846036673238848017915234191262478253849213773660815360, 8914767311897911701160979583535193196323677578008096723093668106854844470290994284033198799969777593537571148786043902752852778750094103336648086282695941816320000, 17892901251678107936298340791452336884582042367333382512564452632581923250757946795864584571400709422058462560411547019396449471520272504418785539321094715452948480, 30667339738233269862565701243261446109246778368484656501637417650890680123933909791264979936659330686183290992817237742802467208955845656923692563333268776996044800, 45569045136303525952739759008026177058228317058993569759169121446231645529327116140861042379300592341267879962857057683178615510904393512177900976674851678133944320, 59398881274509157477548542453022357980273167560802791621979192650499197016273619159113791686852228083637398470397832350163086361937981791691988645285540182123085824, 68560252856146670740779194510906940250746235748836489314925256468366262143048013956848427785954318103550310043930742681532453280712628780447616994093899789233029120, 70606931201346454114564956978124325908174955085984014873984192628438195469058156222613473773208942158222866006098603524576241812813682376655599582901271954857132032, 65283503238970816140148071715401064391937053492493037599150919121523231136639047075553127724601750943174643686589264727192416369032966390053104797280198530275737600, 54472067195747419805968973389799200010093504123635234448489938504163898018321864924995495083528357222757162248719769023392656609678719052664837292783626291018465280, 41192284475647732108073193373502006132453714839227367569831147120121196466379600244119006996283891343474538956366911675476617418796762489509207426153346969748111360, 28332073838099846116708639113029500585776245993855608467204109900491493957595218085570225964569574428490564109750255586013273327562841279417643238876065678722334720, 17776736758584964706125695877893413237395867366075216968394311083837849218323722589564551373743025015374651990982916653499674622825245949887178311987964801890385920, 10200176239136302881617409932164729429284874997311454970269235135815834312715979650818939408099447481032499611663154306382166149427386556538153909601935293625139200, 5363215909218672171306903370763790706490986022557698040746044797193693010471925282409994746411695385486088573243229112152614769910515581126258149077615602491719680, 2588311550128226527292399631938829928888209655713623743129580821630871602759085242473830552086747745835401535575096405757058465492573761496652584741698831340535808, 1148000482625040016906124806826398731480773877713527213074510452441922376784312609420542125251107365453312107660975924810234024257471421167088296019262956749455360, 468408114690255297722478797292222252585289930020807491324982354721453692702057963907598224590766750497669947506815127246304599727416518499216160663363777445494784, 175937277246278562820077005518418386315119935497381841427418435896102784714388421957120345732503521688913471402791974475177764995380526110235140500664854071214080, 60857686664178002451107451718479635761029000401963746947582916476091108846399462513558794711254268724561812490522120070322631534163515912741661057318487620321280, 19388911839395299556452938410112506762741694152380482070502909535191587169992134569110828724019539321778516509698661900709407331179057768748431287420342285369344, 5688712641892489302288710126045196979740091391223946707144799266904030056891123514332998510662764060471900256114169856173005213105872979608638126542694016614400, 1536475928808020073111193982724950738460766255369821444822182720990286195258450607482956973324181658319722657705123725040270628105175074158886000214730701012992, 381770894882821798932062494335787118907223287961077834910586936486125880159734352018863263275188728103119894921611174597165759286023123118884684048646537216000, 87185057883781692571880315292488191134784664998389938120018087995378238409896303526717211541220607447195066155882843298877103274099412091731180483869723852800, 18277597393280981866064383100411632124198039837274070065619899069431680763931079566802699745768755275294218265779454245871231100262832926571161113048041652224, 3512229641585092837224633403366984088476421097591072021719511475692492698235783338824704529657115068515158901690593848975755508056129165235950156403389235200, 617517633571027360977511361925323289522428106099634196814108647565433161767214409036093685525436540277891361080180137034943785826287844505342146649041928192, 99127584522161021408834694647202265120928161886498287525192640660784622267291500228370584106089551623610483263311272987091220884594742476567722056356986880, 14492662858665871869967863019956865834158208526421463808906319979335250113809306336336816252628382317985946724410476634197432715002891369389031165463101440, 1924375233960545623915450295851684246996599025393602990776382308437217335523235827357879522424847619387000493753229055048218408796629252732855004354838528, 231339208463252206359652333645645668361163678065864111523290338692989574357948958439336382776970344775037228385030912044631480782019638530884229042012160, 25091045865290280603950047410636317419341996858682525508954897249586598208562582372219675170992038157792625698341239586293119762217086400830106694057984, 2446152882977201459716131541310824899499370446882788863177119991578048305892130147445784345527048135487031320888215890048141240682710004073862151536640, 213544443824225543058976513557759666419784700102009946637714822664536083499886253772017458267316139415542444712830064101377383820966040652554751180800, 16632722205170420177927484843960743633653538509687797216697257522520158566534241596415802526846905408586228016467220526246470010185247347842236809216, 1152534953300180181353063623481648460226480593251013207936596792988106524941511966625119941921170319860973887434800131199637043668571613667451207680, 70961374085731311675768400757544837037033534292537276848309392905598692735771089618705431664435830533981946060285474964823554486360785867409195008, 3890815907718600318124866826125190703519547287063032226427771396107381445178015822421518667838353001340998056926917982007057802466249256258764800, 192915104215203667629252066008386502857971171873957839464670461647000443104713666558624088151614606633462178078819096832404112950435900377006080, 11468311497755944734471908285228924803744787626851118933610919715613268302745230316270280073827020449818741177955316705355504393504479435030528, 17722133075572796440475788446140955239512586432297878829297678345923642983067331295289997507585123820672058558472432807134653610863352149442560, 396240335205418842225384009698749245107242989178221885474850716718061254800532258748309946649669811933367518021130719377084784478937619103744, 8986134733460964013736324209412777721620177368275110951829581791183496830869128796979356255659985932782061072930463601356220374525337927680, 207042555700551774575538287679977680997654376086558722793423510683723995044148377351014558131084213745295922689601129560756380715219681280, 4832395762988924804404716412726071845011621010617095962085301999109643605256223294030806181415493154516967828875383532142692749262454784, 113173944631861293016073047308659548561471930068214691022547931158240780516663911886824288290277691983833495550148034627995009705574400, 2618995551559853800974537452962247582681155556565439995018704224366236652565377386771424602322772254315058952555361707569590894067712, 58830568130259190534213880983678955310101703925395321346780083658317865230942875967531922786989151098555521288690568044137886515200, 1261810158165216607225833008127485642648742252433248983556151659935623187300458853106557751042596758851711312677673858018312192000, 25505892656612371110455997844176103732095049358236167085953019758018248055056806725536135709247768563341331602660470045670375424, 481434321675797400182734221214431945026383800843654018559865908821007289394542332638148179753424663053203040248074575701606400, 8435098257634350422635174080172426090124848021670807152427282561213896193045824378823711437076130779069537000184980535508992, 136694227416382809291100775143104586397428480957728872381358487373985727448286594162433550149596262545108517088311042375680, 2044923912905196935719454201438264401683409977203904702165394164511837689651991503308174896031314405865953488420376412160, 28215375608504596568391710867193133089160365038870209515068198617607521774773228640999952543089261682696353385778511872, 358976872394110964300844494722918571680977458825326306053158667421459659942116625502425451555855138222384216308449280, 4211761536433483497962085030351687785072481318779746953061678758928012313064143892267529727126876743724041425125376, 45582351239254430194309410329844361187242911738757139383746156621633542759924674776477833786333121388757636874240, 455203520225076504002989312083643217100784458587901923805332116960324218563054215309963410036001767351102996480, 4195820634800187605145922710008692680802408330485878324989854821121027565187174292853333285299259596525797376, 35704218359845825284991571375988025235131550970683278897106692623204146236961094484563833827190016206438400, 280509885022645077248233965953901690469652211845446124156459721839498808309041004785656593851162849968128, 2034562692891874950540609376289925124760194700515716434583552828862697338724234460401951165737913548800, 13620096022198761263498062167626954374372393852455672730558005528101225597872582532448719518574837760, 84116716207601381049543077345986181604498112149062999421584587750814513434341133586487598871740416, 478950592690726366955506020321952082938273608114110964531622458832395109271496137820181175992320, 2511977498574839063177175332112843193884272401610007628074991844114692504125730192962531360768, 12121444892533627955868085987035011873887443075534033871719866013942985715335574200894095360, 53737539438287157862613879197147118605223321741380704347837485567922892600115905649704960, 218482120584738238965311445173821311386445292598024521314055545599460267127506236080128, 812902986286507390706495378670311340440863784486500712333643304626712793842502860800, 2760783298084082118041864939756201517140736898218864077868658343486163844495048704, 8532349323535222833950371855179390212348816450732402585098075267909831517798400, 23909270816112458563680353560141300555332761806440901876109706250291878297600, 60483900317062230650796918039462107016841221167351565987307382249292300288, 137414045386250140140493447680712704351606844852957920854270829133824000, 278623785976501871028313028577499461805428198738628955132496502063104, 500364949736772609808825002727735390890137928642381232850557992960, 788404387787232534164984877314405789849051877010516463572746240, 1077143854692736359846845543275816902191543786642558951620608, 1256822085522815030622021037662891560667089344078628782080, 1227540272535259777495212703095739997531366828072239104, 976238608640435813679223359881069375969291434721280, 607193143861019512441521799643040146581503344640, 277033069177326992381650182335049971942817792, 82455764115668611066728497627423016222720, 12013000450949252050871752099853500416] - -theorem pev_Nmom97_46 (α : ℝ) : - pev Nmom97_46 α = pev (wsum L97_46 0 (qrow (gg0 97) (gg1 97) (gg2 97) 46)) α := by - refine pev_wsum_eq_of_packed (gg0 97) (gg1 97) (gg2 97) 46 139 L97_46 beta97_46 tau97_46 - Nmom97_46 (by decide) (by decide) ?_ ?_ ?_ ?_ ?_ ?_ α - -- Bound the packed row structurally, without expanding qrow. - · refine rowZ_bound (gg0 97) (gg1 97) (gg2 97) 46 3 beta97_46 tau97_46 - (by decide) (by decide) (by decide) (by decide) ?_ - norm_num [gg0, gg1, gg2, l1, beta97_46, tau97_46] - · decide -- Every supplied numerator coefficient fits in β. - · refine wsum_bound (gg0 97) (gg1 97) (gg2 97) 46 L97_46 beta97_46 - (by decide) ?_ - norm_num [gg0, gg1, gg2, l1, L97_46, beta97_46] - · decide -- The supplied list satisfies the promised length bound. - · exact wsum_length_le L97_46 _ 0 - (qrow_entry_length_le (gg0 97) (gg1 97) (gg2 97) 3 (by decide) (by decide) (by decide) 46) - · rfl -- The remaining check is the exact packed integer equality. - -/-- The degree-97 moment at `k = 46`. -/ -theorem integral_ninetyseven_46 (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 97 α t ^ 46) - = pev Nmom97_46 α / ((L97_46 : ℝ) * (2 * M 97 * (3 + α)) ^ 46) := - integral_moment_packed 97 46 (by norm_num) α hα L97_46 (by decide) Nmom97_46 - (by decide) (pev_Nmom97_46 α) - -/-- `lcm (4 .. 98)`. -/ -def L97_47 : ℤ := 69720375229712477164533808935312303556800 - -/-- Kronecker base for the coefficient polynomials in `α`. -/ -def beta97_47 : ℤ := 418910602470707336426399981835016144768016198341267533924321980248465158635588697067960772131487651250819480605866759203954601165177417750826600711775375426000415107046208056887959536122210749046482534401 - -/-- Kronecker base for the row. -/ -def tau97_47 : ℤ := 13182375173008457897725172973600523153456957229859865438955697914318730501196992739553288756669226128576032690604184419795675365452088504060088263843800508988945940472561430547931779825792408972167203127922023638347626205606585714639305185910241117230007075535815661000320479974281043076648018692250545982495751229591362303291301828259940878747206006973237854254907983481235467605496425505124068976160470131705797122834277357881768477695964587298135615277223161202078258951298419620858996839285443377228395473414711281512194045565332532162298221130101670637401886361121780520958840191791665370656877983949280946555668866924879139956996611588210013773106542291473858538474067275646585161511138279406918194766291520540125543580287557700679903718724145686581421098668084783451057168415645572555903922012351527546471240677343797943916391539301776218859201913381801009111550438259968541205619352798778494157359710585922666677368926396228404355405503045217456759697063656356809177789538123075844416682530854480290983441163279460186901703940170185692332914594564404383722357465602920596593711982602385906471677283184425240642948329352225067177349360010654962877018077491203090797148859248401278155326303264718952182053694463742191345960688566530979396442924035046099714542391940113652101222876086000471594265153473352010915047008683812301616036915486532731949839008570444474138503258993785344425533682336013698144992228176422648059618956302967078263442818227257340923339564251554961054801522095074720826061509837623054753095833021307459048145822162929173009671714461960771184683572234743376906545081895688389704622029109514901705829799343347153289835694853187125105363855656127287614653683133579176339046945692733562162453558909076530182636883806601463862589806444272488217697449539389953283998779057183863715731774211642379186919579303473273307338865704033548236421446943173654614668965365955524327101825869812263553040842243611587661409278391266060417276553404427013807493835384257542011689098213835111408251064199597682341825037859046090297188822391958205698872229313061776901263716418010597757314242641854347880650092629619386758090301003964573027565161116209796416027909148344850871725798345338266160273043272928139333174349571612285786674795513954225833046337239666349684438819433573063626181696711659158563566279699406887474322791196198814656991101050791231804778179878314253580211067479215493124325521677583025098174508171985996397994783171467143843707229003727812178137205449932551643771936628656131341760772328173697221925797616535758035851459846244690570486969384468324698757442044340891551978848121697244877393194352314916727177427733814324720845455719581025076204646055034946735478552739727285656362825076771862030070107734951183930656595132856366827540399098959150361931218262026600926190975611362639925182731468070756592903321003335485461919507233589662512520292884789917743665978049770434776322542551719426249504955987711734938026776909512211682686292839817537423234665407502457642068854203174777726373024274507566388782829469131523442677744378553273444854219548451626587961204546288766149458316154331675985341694139118881209435364647490601327382326894161404417293168192618583987050865893934533275445770203216447315019679419186081551530011148120778868915107088409275649659971630124187134790314267250017126235263400954049659237259153940573799143401653968063153653837988129400203475759953601011317914157944384669146386583938120307368974138640882040724119365196493710732109506855288801360826661205085364743778459951194383812094485777710390837861934867829192152373401020486227264716290059265521861180947976433243392623433414726017038868520339479375066620698313025181113134239434875931654971968392519633641597423867178451361596391692260690475954407845883038475556513358258401598403644636031031382140038188798661143394238585812566361738793092970376204883865005146429065264354756150961186066363558490265610965440084059765545951263489987080675382896585447760798298131134546811082321993556838737662861085740656213143664623892770741950980029634400293090210503148125345258205360648327167651281702533071147351659834471115731197479880360564740119774452913194978155505648929715016531100534920227223772115113803303984758559737060154562750451845895153265636347081731026516905385048691649474723254610409569048907853921625965316018762517892312255785511259489573825060059706173448448097903384085080671583742467044778668322507533604184018144592151994681653451765863268561831654004930496276391257287693073387004744407073539025153544120338824241229321081185049231783964200515937512861671177023540277712865736606711397797659981274459231075003913405245501093643620011042817025641745676940682578597695697138508761272180621042034053841416646805721284411480168563560153631533887711916509212262881153228032426825415368324337315313118382981335194795950441754698277944843854644821666222120399385787327547942562693813302028946298474623392540852299262061808981193372214485223769499835054766347088193058061910766359699358569435338763203694474966766992753763912160768493106341246798359324641955083127288887535158582304662888474628157817923692775750947264713041317237666271237180353231960753355819517444899881879320635705739485330870175983064528184156471825923838824758234820452608052777915257302029966140269973431603339029119355397462685040486618239566443761727603057405097545457937851261764979235818410549516236887614663557908616168204753975599330219846755146398047654452046281895045342866562670141779935809972125099092882646994842294962595619203273767123475774387996763496001082256957066611281493363816878098458511805169731775047815591433573633210639986646482173408440531244206987117859777731772508692442676110300961221831995974851366616891059622017509929159292186884675078705283317135081626445310974171228734801853401086079199322218022692021880607781593529071425671335563367777456043244020473112273808568147306571981730866785814167925455566910102661711717676187601067165779572754083568556997902234245881517691138375906168545414054411955105154497303693306306274171493956842378767265191200567963931767107877864103134614618250614556052900396093626858892866332214090460713252228889609427739249742174360625182040512824206798240995570019986908730256325597218015759129850372524059328319726032930108077365748088622591289177475024214056329515461208361662947551140666248477360083222263863357494121232090149213671838783814993566589027187746214827461543554133184671074591776726679586794408292863373261627850798119205330758992919683153384126880450422262152711960608184587020256015993721805027382551382386438202743315119652915872113699325481685618347228393010682509911225497693747950078426344555318437188072272856528086228430359789859636370533962548988788262782991306462910058067441325662378450248500019663602568633263537899044489747127882260499746693292546859771813854525639547267660689649974184524275735636867395422529062981472571362843724891135282025091201294222314667796108494890821669951218819085820342236430036045359193962223676075143761065947646465647404517245743714101574580982968222907762383961638612162223458856688893938244227896810830825306748516353259472390760474614541181272764440256836962838965936187010890921250122359428818369972992980457636423842953906425743772571301892702261071681156256846004251663873319367069449929715880997634987518292354789551436033647049814187901668685904108420783172856705375604333453744928248894458423302259137077091361752380277175730928196004348181197906568834035533328530815256215558137981283156915890727415731882085510398485061017774659730565135930900330479948268689470597524935020950466479875928749909948623416584424879130429366181308928698177989413400732661641614478529540999477069847598275554133865465301619544415653964684610599130550970554519332431483234728012591333473842105602641900005248319784863457095978412579097906200165765800250565664958637752759664136567229217346259131675507092747949513107319944885425640411154383660864131740178256694666783028432766908300681105210270904478804000209196312422041216153165907816005901463276868656130792963803576378185773691378178580021995339633673266309334272162798429823307699577754119221288382598605819951471916626637661393351498754471883595863230461724230043102812625069900280265211630838283799987489016476541912571713755038444324331155192567822998004790119223035028038122715907154115939105406534146147246847978495693611263894972379963952247223932141099918816441813271266761171065949592737418306271694472008370724826798931508687473968782407955510306644281391138281814240183114646156902022987539079042056651930051623916649518863238645195194752218287263347571126645349345812328327857995378041883451157014774493871794276863084077910865477204557552332017844803409143610436391732799699333176841055887568207897264117026734544561100086290989627842168569706791392464190001462965040265579174476503946808828026358796848131661570179928483060199189340777205840289324574358908026478593160412960386217908462857692294743309955389095956417668785175994216475122939909624058670491946886615592450751525993083028864284309457022140653471622170036958745131850806981899632423302374743043795333393954445529636460767302318751183336311246306119598678350937084290836509365472230844789580541714043628621435306691420092963290500253064733165423808797615090388397579161795306556524088164416634096285463939814112219472544587937328687207963400935723152497717979959240463671880478870197022232398462445885294086095219299944852530540810378471316026635907572662780500606826376603957630616928102529172687524904287283099554912231925267412331030216150650932546373146837360906379284739052179069140780235499584748794453871812772732242932220789655376661550769948040292245811688769508375144483592482862042031260606419473983577684357692236458516624251387950742889307756928501331539568399862480468120471658612686727015189358054733318980815405851189261557189264458540967806896588559709636832385173090032359643498715877912583768893423321897367399525002182494608106389098575926735381677541452233556570262170995662174077937775174571548642143646497668586481400634039270812048378484250760801071315334450707213162179771066669860551493136391971101708724652981708541641020349791650211566653649009413472296170533519027422093176593584686102003876274747738269245127031808356017682385407583505721251042696729055790622117699090648915060557150820814871079868914261803932131891910610714236215257564029522192858849571709039579150597979419345490185751714399229068003999668331995004066828941143408492349293585760287750041396265469916660156910203381576059556629688701754768924591823386037437183360196532566875727456991335004917465347959029492643960720970897442011546501405616383849515323359702381598518932468327398136809693592859882363941386947360944263119427055737880909604806439304114802686465458110231346403746993784639890302492591238528019577956470482980101454292062724188303926322306388410594234088426797260767757377664900104440666133164996469052195527432440644529731349145584357291035428139521514677572086360468746353657812047760630775676254345988950060160863187066619430796644194899349009497714423963195777854980468757116396535132245536483237057586351606028311954702515576490801613250619566853262983543190866547682469864817515843258113026222255654360416756315118449941950196121726531418933933837585098378930323264973221299217268052175794834855768143849192347975475161266494806195970884384941785359505067494369485280665792169263518241972310386485876623892865567174310352817196980599652924548628744121331114427789428968897082711192916941720096419096009073729325502248153357209300448431330393606674030054695983005128903318699235970306960881464966026351294121127681696262973972767730007116791131431849308310809042596032903433115658790695470016972685293024726758587573802120638442946110638749804542476094703855414355935305485259554949706516119108361206283807987617837524207641559718422740971575512541758186711137926415778212111069910199108223738891326684512149854181465233721745390492334545302868307859306001418465886752388620730003569981651286801191281006531059069455411165541681830046863050135552456226579798066651228174704461145351853393588319213756529057783387174385282867435240604488030971050244080929136404479958486265628480067292631129752850347368138455777038914259158033016819417647797898901712182787280196505632836924513599433077550389239928188335331930723614755027067198920672462416003274653616574163028630333682390068788122069981040902290463918203910109958870098820246480891037531351095053807708418431597770033181878775597412602941967725379533897990733256346457806755784196017692068766880838971557042055674015490947558736688264437269642009175251875742936708320697884091359346807940863286418217210692737055848114313511250151010765197436944756103247254189737935573713738203491913831119326067641128514379873895451069653551904712665405600911888806002091727016695817418558784768810030103174871342682054557900835136632767246073524682951832337948517286328433730651880837480646414637879945842827527252646921667946415437324396962562864314922597582252451838291179797941030556568589866443574094545091608658006324623273250849072459917553097102900589873828762576613869505200632680029508462287809966438672716598707650848674994688076092045993506537473774203370859509220156418419846136406669126279919038431067953982562888552323344222973051946456592881799373192499389814329796305447732116357372455342053024339860863377576763435347182558956440996826472649945208729099671297601942300016512577059058651951987538164175027732383390323638408441000603153236036249155815333345146519959160167270085306848058157758312733372826174082296664363791140496554168548652957328047864546410725862064350366697652722912230911403126368016663022546071193461375466509540548469352840736270383671805310712682853797682055106690303875940115605012749159460142970264390033829891363187896168201196990465183492684082406818223163408929373820941262339831579148020692615803627504678410438166464430621872085254409755147053557056437882475226617926398294420771733940442920072034281336953309738866093361338553677806547878105991214491786669372172871601958976070464766789032075576056055842332258964698377000595540933174021319646817318990051576974846105512492580500788326987814137405310920910699828137298857786551933995815151009283367014476880279628126667616590001007832389321998584487338162684196124879998753319920872369686813281908612445464447805889469067566511108308151056845649155850478054518331112734852276220928622454802567556062028129223813392647429909007458766608401944245985268274356889304522713762237846226171664763112191986985398240619796791463921370105408820107606201194158600510634670978134342206640170051369324470842152512007197723562114355495071370548984063492712868873191254859520476123046883760942365213905636221660986280403073944324649145224991031897360736458448517700797665394744712732481276039367047341510652375185704401161008073671540752879085888540168648129326083236929552265887768559546201785938621099648002317470127836309124136682135088975792542855232428877017345194131677024039020276366300666838840707551902797404745009531132732273595149429826113567426700169205618431023881245106776463521502409991522262350683911898573261085678563298077256213150895595033902585787460760252377829031960226853642704410752459068480554008215596717834068743708147649896610575077698106594949796412415509795191553663893969645904810629610635588756392863623831318143682848372551740430593478891307491156493354210734619756657272829779183436846864093305492048590177232141645415529364861117340364439506873052691708405589007966082822509321175986475376978881484910769348348983126976846664287330571118438613254576833880012834125670393801635887549952052824543605586270994057113018773919364461343369884713525225469524555530932190424106278464882522162114050947307627771646806181195357234382738259495284842565015876789674253606454131365718261820694824457482176031513306569601694345097130639828961839438359102369991898684975976902472325527167549696306071226005945518670845180345906176634776399298213703380225738597610702688549783649203916474725153370329088489444033469473923399333333743925172077377952048778203099190294930717766031518716259720186949018438869010346709308813315134859414688493281496117929774525534242530594290912437292432964986578118323935531783984215724692324397155233854073170727750356484095557202504491414620985463463244477216379110560046455703382213439522663640401608750340418669859856459580499536813666640865655262717301222363102805519844289172054165144930129109832440364079359347298274993246348992877731794836320079823435623716304034150766052109715773131229169324860725839743142917151227483925972410444615559662704165394953568185419945257502884467109303615083315317811426504246785807136728134120440557315401371394316242019299389351399308420975400605828447257420483200201713058824958318058726323045215755637044019771153632154004897070151991957212142075360316990811031115024156222058010835265775493663339539228257194400369693845937833127061491666930199397512751874588819220341614072873453953298752402597809616507640281190002199038462535239134250309443466487500843010600012197143945804789653332696940291080019641107943815323777558861449588947869669797132794329657490228891213634620546785855466259093853374964337849041051086880345869585676993282694114461628462118385331953103991467242878284436294873755996021227081812618080396099964370114933770798742109687613124541089384469505153506291368471786895043609344922196648541416107683002633660844032935048385220328657364235896016856958670548690438443623348731313410999674593131416584233637927216590187096455414755558758604620896175761550595551217827311796050048579370850031523552732194898031061386610387785206770578579450137486286594469477223174930723704113047360074638602683650668765163200495487341391339353375562674128614487967554783772419874425677675757225515159802750314016361733805648773698737407054262606910713293053919599265142864878910259206416904312125701925869598275646216781077684714795342445858594838273713694329533359993460336488010703659177623581886880268402115904685406677064349421166666274333363789045467311476543618816715063963676102761624014404103947806793328934934858309910275474694792541535024396700862654052735554989499200599176122916657505550894295034848050155046724025252444721538194102024900132954011452808092947877478298239610031440350248639086512718739329159142234406452559051635211156098315285730494198358368160707176439721748102862755743282910280578060723506705952443209820825638542542951489059214555274980015493136284131668607675053450720136896700152034134300710242683080392334009857785512175122251199783002818964049831206021865174610896680566059338311136835737842646459876100592821152067470494754213272026104802090678101151037074092990270104104633987426855515728138495388505792068062155990278621092482312077908686310334759107042833010538318322729132248715724011670926270348845331657009402503712023327766249711454381796955465034693995435429938362124798510414985064433113143312888927464266543735163153106547125839810683789212943101453460053333043445644276654080662058173403927344017525592107391415190548192521976741529676590044707934620284244198305335751115321476237741753152874367289846432081849831612887754978248182478547462836700566303895709482115700054946500971589153440185728916891350003287712678380510803721978832263661217519094896728862367719890241504987115854978540983185021144720073970012050378881840155435537432406990261272119811163992570480706965162328195255495838803946730072305497625372931784352211432942069344974930008095471581576631834495838431391018257237397300793850433449806393775266151317774504725392084487233796650418727002874740610092500144073800124422750573381961365971897496230278576578915575346910093674196226325967669197035499798222249128159773770473098804458602108489780839570604300831366043348250164991870471193941048770980247712064827664753241791561234404067612454960766760524390501035933421465742968760370384817763655573872990979383386765487471313394395157447472336750965527067357977689941650546000262659587362290414212254290522849685244592540425263589353356194171904199319987160083588542450914513002633421187402108729473320816553458694928519472801678300845670894279079195158473632974176930340241500236925164864956845686336081372959139364050702576410500183045253468756302334402197758076778549902384942566694300081324452077217009452774806666864362033452194457991828616111149539824616177527226982669437555551671351893086355779001632271161912579733530785133354659979750472726935131714153532531984423799989338448508060930346452012466580712348143660430981163147954674921487123410045448238096079280568169715317047852639684462105512872892263823497184924787929455867630727780189281227087469934022293245392891141271021318049157810271433327846722810179112231940445066238854577187834305623187733786303826520478030792277073926502396062944007229881417870636355758655567893073008762608642194295793216876924465065322382701589235332847448187530402828514352012746791782571397615370279169193112065545374040046189679431775358381067756961096373452482008965759040611522633328020643497946307176550178607446274286520807598475909178620728518147140576595032513277637063650223005996527108960393615820760317595897092716782842162862632870760219965378491680689088077694359061079392359697064907986839022651544446186409063312009290938482776992758220361453503511220635012631580302843494976951203607740605549500458657783015410668857907584883095074023025524341781352597640448428097675268560961008125307804939003882426546096557811685667158623143331218464461842936699726237086448336474212670514468183497939858019924126112105456537070120234303317787391276936201988208332062866474314825448602397278127382672061834160446344713052092415730741584614484570625930877445378170098163541375641651954114628563028992799943796831807553707794641057813301036074671738462200152314765172668286730443223140158454714709995598131704793486990033393763660446716173970225045194789563865397539394857830902495552883798144073878446938065747794003398409294682270750810933780734635359468815733795771670462030011686887424954427588163653875869189215185953459741782841068546259347482508888575825110033627235802823149422457629787492137654272467156900699384135977637263381582523086328987127875406181247050096559562511992728893460900459308140937392344589558017962526027860463691943969654107769918173043487804114295509352419269015783470751061614304794150502597584770505458984460908240094212519410207629584837420692929414992589100229901604645052932672731338333633041537398354688236660708083544149395963954625217965526896207304118068377101292370645528597898136998529510210129263396027086559263517239726768380034099099694935459967642293831785584927115047217654422717692710631968370945907949623189062976732830264014212435279378803552306567896102409786907181573664603613712374085826718377019416074570307242542259716655736220788546496898502743375182763110611396218903464626160388406533974385001877337404076413959196057636773838457582041463512738796964343372927744928039867540824125224141349900371462703264075780665795607029395558680933604021940413347161670831508588977354392833387895601106081125987551794638642471530228853621424638887814720087063812001639493700841890620143643968170975154152044497700257525797588630575122408974279333785084738440929358889574359491307806880462006750403210253915274029769391581755001640830696629118430529370309880878471412673193877474237895388880195521056589845302675887485781075092974476085750156889083950515667220810983562496358526843579347496032621117742706539354480120476153092288813115052582843311927823390453420971323693640819269580735156704276390496451187299032783322970712982850545625236753781836086697339071835767815840632386151085638308689156891404941239884905331443409180354579430139472479416668898892539763133650661329305807080892524206796106193460356866806039597348357667433228738181816874201801311637291733254353176920728861033274245848848651902103538016279996992510386669665486711756983741023415956250538416462044552512024028322336839419884220099178941884880839579292909245853487399923054630942851811192482114156734789093422349335017803211703301390782990897428496697440335141458181885635491891138752046239136312267636927106761560609077648649372841586006040222455788766324037289927390232451040870287746434133889881131679520580189219424933038474897789007106684752471451183887659126758773310689727292683753367856910019188674220675225939609453199931687065503443898182063822810823097172637653752752271841295042142785828128630812189616131016101312656815104652569840866456919701551188743706055682984747125603116937014889244754506863377432886910727380383088056128180245322635038143123179073492840431849923088492659508103721759327302167064118845452575103115120082863558826056490037779200891610934243596006031010138528158594175713592702872765374610068520419723763321164906260912544516720892776959963720792966798251758192897520465719883642101234569915156880704683878307936293324244006889267703588342104966995189884287838309898319121941748914703965386853637744167002906251630521900879509251827287406230078861691039821806006086228515869983417066932206129027090432325314332929275359739951908167299922010465163501133645654637359041454329933227122340086974215969773083298053547955477565025523703431080948382834021506348130543658758044201684095488103197377169319630757306373876863848952159185321954281128494742198383357211684569282570245246265565512318368937231481087646783278076926788539579852718420247263281920966226399988506253088904840452683406220898710675850459332493896144195266904439590703559167887519176824193345802405551972526047638535216411675136599028964006976658128746536554802846958437586844254233200070578854528126536887554426180435406433377370018995753389271082315648552234663544027942607941328941101444307697999075376742485538597585560934316056211275734264602815887761295324755491054478540044521062552424117148087178586631448589730856598367707374648140503544333784336848728640131585688980295119418485717136368485027725240934069173100934819691314909910530149135494037640597333553927435124223709448466272738046107421386396477227340588592843510884235060817998225936717174291259553573113597981320350027987947221074721687522359753412799172130304930516900575431793473546247917862491758126673328039400444955318533407214634854577840537683766783753055677650442746061928011754293843958779484768550498255029492686941837491798848218760883940703502601497796000358031531521175339728566903347105330258711389908880026338863768456233444861229390344194168801233985765288278825730597965832590417984938352728278388343839714436716757333488717388458870390217153362805017816792829475828237662304918707187651330775393856682760915536613059160737782062186189065611688755411255302431736735123609121260968502417364661253989453506202415589018393719337009684769568121505929439864657281040388508773590313889169345605280388728054344555293259609633733683043069976101264381015875259415881967938536238164986019281409140225148989177126307334550986953209256599530246505974165649001598109775672362206506223157609298505498036557955903994788440304179267138137836955479475100150218183391218005768894937340197766508035646383384164207998701879431627363452951283493196795977413369941890170744024880640143240249411865149570973707858928603851507651184522747692121546483400774063418643326271186330399742521467354649134320385967794416879242983924626461384871164975229329122850509047866630889595592328896842836262981019966778274872992617122322238256105922796221644058593761602128419659197537980439039253005788253873893117517226935756349013247239738815004657057790034924419622938986126851775439849909825066579875129248248264173881598160397776337785494199635808993207396469064937401703133449498201978197217332867093862323864444924424316508652644030763388669031276406225557295555249107378341903920562071818911954158947578193560483198205096622372327387094372356011863225177742572450609935231450637644084870609803827016658145081406550152767220516766349143638941913097690317703477447488006630328056891985766771627164489785951407173444459127579982978703466078592641803759433146004531681693192533798040526273806131293173585169210922428941969313732706058255762817210065679448152340970989440853477010358233915702632024993099866544988687919936274045098962200521960494944926804267062374356935254784036956187312508076855835826164553699648659509391627623352141130225122924188359853058230760092980373332538490425560043747306959777447035566143946669822831572838448996694574614901374992140971433829452189799417412138960454018321123572151103901940499127677467511800793533764602485277421570004533382481833376247414772963303377910151534690285316072443703831603033361139965309318516659123260721253729079092225872554969234900813889455312919651906758714450963394087936064322946385115165414951443866116021117561589497362658053853982910314471613913358553566951252810128386644249672843243048582092894330229889436633913404920361490661893733615924176572626375411972457167109834651156708600424732425826376455327531037555528484527638218539009 - -/-- The moment numerator for `k = 47`, supplied by the generator and verified below. -/ -def Nmom97_47 : List ℤ := - [26507882617232701579780770350629785706972628095564135699383825696165598191677974936339460943246099973706622601638358119845290220539081243617724865034618021756272640, 435016681176799563694350285471872052267338886430295128374879100100739111184127483845509908104911019684990985338445976510668967512601257559351991075875010537146286080, 3496001830681054260289198677905662888866767835743856102778701032742605693772019921943563544992833025756035511760460025807076485763163503062488478323785275951672197120, 18336551526226520060227378916712810660095383036686504493789714521561725205707967743934674464915654490989497060730474940459986838552027129465654681339487708659727728640, 70582127901216369789172088394856820778802259712879383644994886853706177080666958700940419218990181423679205554021593194769021163423509203435565342479213614206025728000, 212579298126114930437620383016076321977916942562264192749857201029397893840399217702312865132614848068120144056522076691999701088645146124290948591945722798689579171840, 521560749803536046584076238217157779280878587860306107119301664457780548436991079542332746531612708308202079229335969492440172104523268066225693567097298224199216660480, 1071644204628488546273512893456039423798932232388307490990605420410979556827262594439960603205590290658177352405038129955979667158107840245463551717377396606976414187520, 1881359058672267295527102373978178931345917335385639792447180383489062246802858354267318539908726543944883385645835583214761475116432572592377397539817638532352929955840, 2865197603126719683100638594256867585856137036502748707809638743645506004032167408569678453453668124516490411259223636016269071491012745286660967661485763649365396684800, 3830265176340776377345942456041561079258463525353630853864992509151181111287686520158720449676178378154697083175419484146545189039066858819605025776606194297152896761856, 4537120794241448969661812747412380267326517381404596653566261177139541052623756584213806440624270756630996626660156938535338476079132859373435688804095861530210957524992, 4798657739306751493441685543483406448803542182130017627919560154691498983966365270156751568662753248412299177827562545047547877222419811322778269622000215824165427478528, 4559996949606576782436747412605095975992293646393535741879806929818863357221218576050858946141348571822145670688395112050283730462554753294037035437560263117404997943296, 3913507643444047904834422784153994241320488674287080058826461362136721640712394193344647643946635203023271153770206432330743143694204495738855823324890100460454842204160, 3046505638831777123237735653386296424924259738952808136851573829441873852990749280279275020855308026303602371721816590253594415132586027947032643924356598331458275246080, 2158949729506028469223110929118662920451130311191478069541644052111017796049679819204040138814389882081929302857565801598180379243479808709928069856423220094660058808320, 1397018687353351082722946174394104512651987803871584737169305659173857389929418837038248192853781064937013553744589769710112767951995562442944132552437859222665318891520, 827518401715419673699875757663395974970057396193797330142412079971149269052178439475894877757756335263648715073006061594795156718109727194760398316743888040747440537600, 449652654245456294600350149946079998823370321292026308835751830263763515251699550437385894211861838913038970948691637518927892253895771498163637761597621889858430566400, 224514001836626491482617041470776452079757780166948737908611135438249875251353842315514187573543779749339200885285764423632881289680431393507777180884717945024090734592, 103150455406044674541853221892570337903891452742330628690140176392659060809596094499434975818257501634840311928169395468870436917451349909426424717325617420549734006784, 43653638380629340922247967053189662686174288864147599729655743171601936982643108957372468368721978710381085461824168297230167026717730010528615590192784475452767993856, 17030488074984194300712222299486112803426874313105524296669464761658567004547121930859836714705293678474922228209621306340618614602722742475373996580375683448199708672, 6127876395990936937441063145190852562762858399480187777585075031396085133417370523143362756990796776375155395966250135630288020376027027865139771207195910677284782080, 2034119090050293702295742540142309845177132555756935430911124190554237491852967518215322399472093928802431171937569819538628450822490730513148765206253668570534772736, 622909520795889645468010257718297435697193821881738382676345090586998804058283270572605907942774083843185131877470598768393620242300554857150628956936085499147190272, 175933054108033322076957119660739987210729208332497741519498037123129652628395518638740588972387463089254184808893450690861101203725082648577413028540378989344063488, 45806612508787413792826281013524176785370649595277918008333378632944116568387611859918759392838962212946281320092517873434825607855246920055171519637511947593711616, 10986074636248366755326655019474518204860761536910510527587854240086477586145075936497511587747342579808384304533506464487885886462718314851925666775867196943892480, 2424676389576179112723143121662094431796183768699208976994910065155347382956125816963108578656376254987759373781903677727395302524818645662367473717761303134601216, 491822687911824327261838015810205249394941143269520824592589698337151953947771655424630244173680499056272101075930883367297927027057998031738435642384658865324032, 91544325158291487239653964813963243099035313625407803486105052437997582649058378897664459654214466926116133642323057158740649745766515734035915749068012265668608, 15606965557534431231820403137363332297578699354697269743583105485820308063250912737275353754643042416734810922198999271598125939264344492817752366432245740732416, 2431815796342490371430435843546849255234458157163552813114952281827421527652082337631251799690375711587172443957636384374328284723376556480775662607924954398720, 345452244104663290506634308563422161075588556526376944697862622766436982735360810088815515786583735624119377535107810925452523545806180329753807628182814195712, 44613476382443420102013686691576060815958153281843586509630823163385800289212767503849963005007623277728444151257648261358142117398968505373061400252135768064, 5221534246765513559442001388012262243332010949704547958069972028597954806266056855871461564200677987830876427091241384786588769131919825797836962594056830976, 551935560413738157137828313182664188575975725129465275355305386215786693863913683574968798344639822285809516992456201910717380256859450617019910867084378112, 52498270688169620275070232841403122694609817027329612623355575486551532182507482868592710333849726533638864232159512556121206935453272357358046410828677120, 4476605512542911478044795749532034927756788525169012297047971218727891708310985358516442374753875391700832584643430158105468620204470189466343569803444224, 341021933485119481634840902324013753248507399581380383264698171355313313881436201594696175775092690450724709762937091750639650029441806181862248711979008, 23145056147623398473561497318258877074662909733337461037668234637708485149993855369888421139854194842550555186393858499425179146450394164930114656141312, 1398015802437227978683169033685470777959242204009582360627837884997072438492913265071331417202273205932747627881623714010142880206558315838096816472064, 75327496202647699957491486085765041003688067625543401250998247900166638719622224583379880011721426099927788343619363299105492199740850812254106419200, 3673764103735820627632099249166179142073968511585126255599824064754674780147909684193506329216891710876665437889343800749066604205041775211626627072, 212551341453978089987755318168328115883325259864672889502310924621979765800324253607604863089768850954790936020042611126484893552332988385637433344, 323339040332654536575995692937466903161429481081198755304405662392028875781255391159209799486893702871709900434767360707492400045620776403464093696, 7228851325784130575204029448200031720246515092754356364946776727381791862373706667273822484946689157432342423463269373133978578925885090800074752, 163863267626410020850757450694923623628856019852847227945113323154905759578179138281058287746921013896136369315170958763728412848580078946222080, 3773152053573263105866419300871514682977617405792575138297633688353550912224271467538141325581235943026758447481262537557569455492926061674496, 88066698862216657638398097583428567800800124312539638490286231570979153120093313498031070832225104781291895741955280216464403021168002465792, 2066180964879396369201386063083109309560965011559529802969409917022733323884994404201527096384211716697509888961800190271820112239282618368, 48035949515527297653475980826600292715103053009195023167123517690272070681938801419125900399689523726701656653009642677167749678367768576, 1087779622422767578009513519600363733734677234841764272821890867989500410327462760354063146213135991812151947010735385313427664331079680, 23602492044005935717192472478448195186394379753970512745008177876909292644505868524957842749639815063208181102894023660362166767190016, 484197143809042155270144052626478267507584683616299232038763315119497936127681243532929553763883495255390683235349292084506742751232, 9301382339213287811373663993603883034469449041913571345236309750567680457340405826251011227132442915029920951069052437213801873408, 166251984519524769164969096310808801996385083106139590372017936628702812680172852338647167224801656478061398424085107062305980416, 2754160618707815933111048876723663090389893482707236953466235156337015622914196722744459618549730172160948970039791937147371520, 42195819676130817372257236799464187050102146773960716779026244157830204557507522079355871316434726174659265020863257927221248, 597239268090062307907015054721849719874246452832023096311465868128673922113510585583499206193611657800787449760516476502016, 7806708922717576726888918233678461801537635199220202616302664426670116932332978865395189723835513326195999303447550623744, 94242012803817999104788607793121930141845703758592265759862876044441357971774598076084215807844686110267903024444735488, 1050954713051264034890950209190086633827866393991740277305069551368887984899487057261086432659817059909445291060756480, 10829937621355504131710957337612965713188937859810181702724969082956617766438093846866537606239551436039964541845504, 103158840943235184279885217139107040969966744493896912447203855735872953932114909164401268591719058856586696982528, 908516607398492411527862204931079812084975706816712619460280786020013252611894717430165353221745638658573074432, 7398889729528743177551985247637774650063610793495333625961346362334701500540211339353968128152221601826340864, 55719893549885996293633430590036844814778273473043525906711767533458623718708782933576323349494276869324800, 387970316083246339237334190955714383912424779792837270516756742906111188907301389636357125566389586755584, 2496830692276015814106255785582259655791570123105072068214845555745575584017371756196871858615713005568, 14844158673237072264193699628937442045800327257124300972888741439298593600393413034838410796740902912, 81466512308244195512453611807563186533911598878133168533589343316664847129281160385960906529439744, 412324902974928277956350352536427630887517113713453348695234301490315000372563910621222676725760, 1922229001696690118614296189363471803787720103169699425554694224574970941230369326076298002432, 8241758911853192341963485455588640265498870237078534959875370014065641223209071816856305664, 32440581190953234431836233368990243746147999974682708030149238629945048385115656978169856, 116965458300272526242232932527298445639698512642644134937453713974767988259108255956992, 385292878835838521772597149454462902062561547832907916437657754761109558896896245760, 1155952785127869291634498026099158423105920440200202570710386469723218844521070592, 3147056418504010799634132280107576368505805084791648394174543342782275527901184, 7740710321513267070480875250744411560364940330402432059344531382881218461696, 17111751245404936682181480970370673813622114767210200624534553057287995392, 33783745674858707326647839518572547680755710248027226177004662884925440, 59114259946536798011182874662970432336780717036579222429854976704512, 90812605523199571606122032945270824316502349382350193807635513344, 121039143700728716685592068252541000002490718605201332970192896, 137858143518198566224329444703688868723352753608099870277632, 131504681255475498035728236100048220610626885403562475520, 102197018384692165280887972641013036985431298049835008, 62144979599232500382048290485355337472351106236416, 27734396566822368294619368875162847310453407744, 8078270128470118327518312863925999079784448, 1152267390193091523246882344271662284800] - -theorem pev_Nmom97_47 (α : ℝ) : - pev Nmom97_47 α = pev (wsum L97_47 0 (qrow (gg0 97) (gg1 97) (gg2 97) 47)) α := by - refine pev_wsum_eq_of_packed (gg0 97) (gg1 97) (gg2 97) 47 142 L97_47 beta97_47 tau97_47 - Nmom97_47 (by decide) (by decide) ?_ ?_ ?_ ?_ ?_ ?_ α - -- Bound the packed row structurally, without expanding qrow. - · refine rowZ_bound (gg0 97) (gg1 97) (gg2 97) 47 3 beta97_47 tau97_47 - (by decide) (by decide) (by decide) (by decide) ?_ - norm_num [gg0, gg1, gg2, l1, beta97_47, tau97_47] - · decide -- Every supplied numerator coefficient fits in β. - · refine wsum_bound (gg0 97) (gg1 97) (gg2 97) 47 L97_47 beta97_47 - (by decide) ?_ - norm_num [gg0, gg1, gg2, l1, L97_47, beta97_47] - · decide -- The supplied list satisfies the promised length bound. - · exact wsum_length_le L97_47 _ 0 - (qrow_entry_length_le (gg0 97) (gg1 97) (gg2 97) 3 (by decide) (by decide) (by decide) 47) - · rfl -- The remaining check is the exact packed integer equality. - -/-- The degree-97 moment at `k = 47`. -/ -theorem integral_ninetyseven_47 (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q 97 α t ^ 47) - = pev Nmom97_47 α / ((L97_47 : ℝ) * (2 * M 97 * (3 + α)) ^ 47) := - integral_moment_packed 97 47 (by norm_num) α hα L97_47 (by decide) Nmom97_47 - (by decide) (pev_Nmom97_47 α) - -end Sendov diff --git a/Sendov/FiniteRange/Moments.lean b/Sendov/FiniteRange/Moments.lean deleted file mode 100644 index 2ed9435..0000000 --- a/Sendov/FiniteRange/Moments.lean +++ /dev/null @@ -1,125 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.Common.Basic -import Mathlib.Analysis.SpecialFunctions.Integrals.Basic - -/-! -# Polynomial moments - -The integrals `∫ t in 0..1, t ^ 3 * Q ^ k` appearing in `Sendov.R` are, for natural `k`, -integrals of polynomials, hence exactly computable. This file computes them once and for -all. - -Expanding `Q = 1 + bt + dt²` by the binomial theorem twice gives - - `(1 + bt + dt²) ^ k = ∑ i < k+1, ∑ l < i+1, C(k,i) C(i,l) bˡ d^(i-l) t^(2i-l)` - -(`Sendov.quad_pow`), and integrating `t ^ 3` times this term by term gives - - `∫ t in 0..1, t ^ 3 * Q ^ k = ∑ i < k+1, ∑ l < i+1, C(k,i) C(i,l) bˡ d^(i-l) / (2i-l+4)` - -(`Sendov.integral_moment`), with `b = -2c` and `d = A`. This is formula `(M)` of the -informal plan. Every degree of the finite range reduces to this finite sum: even degrees -use it directly with `k = (n-4)/2`, and odd degrees use it for `k` and `k+1` after -`Sendov.integral_rpow_le` has removed the square root. - -Note that no hypothesis on `c`, `A` or `α` is needed here — the identity is a polynomial -one. Feasibility is required only for the odd-degree reduction, never for the moments. --/ - -namespace Sendov - -open MeasureTheory Finset - -/-- Every monomial is interval integrable on `[0,1]`. -/ -lemma intervalIntegrable_const_mul_pow (a : ℝ) (m : ℕ) : - IntervalIntegrable (fun t : ℝ => a * t ^ m) volume 0 1 := - (by fun_prop : Continuous fun t : ℝ => a * t ^ m).intervalIntegrable _ _ - -/-- The binomial expansion of a power of a quadratic. -/ -lemma quad_pow (b d t : ℝ) (k : ℕ) : - (1 + b * t + d * t ^ 2) ^ k - = ∑ i ∈ range (k + 1), ∑ l ∈ range (i + 1), - ((k.choose i : ℝ) * (i.choose l) * b ^ l * d ^ (i - l)) * t ^ (2 * i - l) := by - rw [show (1 + b * t + d * t ^ 2) = (b * t + d * t ^ 2) + 1 by ring, add_pow] - refine sum_congr rfl fun i _ => ?_ - rw [one_pow, mul_one, add_pow, sum_mul] - refine sum_congr rfl fun l hl => ?_ - have hl' : l ≤ i := Nat.lt_succ_iff.1 (mem_range.1 hl) - have hexp : l + 2 * (i - l) = 2 * i - l := by omega - rw [mul_pow, mul_pow, ← pow_mul] - calc b ^ l * t ^ l * (d ^ (i - l) * t ^ (2 * (i - l))) * (i.choose l : ℝ) * (k.choose i : ℝ) - = ((k.choose i : ℝ) * (i.choose l) * b ^ l * d ^ (i - l)) * (t ^ l * t ^ (2 * (i - l))) := by - ring - _ = ((k.choose i : ℝ) * (i.choose l) * b ^ l * d ^ (i - l)) * t ^ (2 * i - l) := by - rw [← pow_add, hexp] - -/-- The expansion of the integrand of `Sendov.R` as an explicit polynomial. -/ -lemma t3_mul_Q_pow (n : ℕ) (α t : ℝ) (k : ℕ) : - t ^ 3 * Q n α t ^ k - = ∑ i ∈ range (k + 1), ∑ l ∈ range (i + 1), - ((k.choose i : ℝ) * (i.choose l) * (-2 * c n α) ^ l * A n α ^ (i - l)) - * t ^ (2 * i - l + 3) := by - have hQ : Q n α t = 1 + (-2 * c n α) * t + A n α * t ^ 2 := by simp only [Q]; ring - rw [hQ, quad_pow, mul_sum] - refine sum_congr rfl fun i _ => ?_ - rw [mul_sum] - refine sum_congr rfl fun l _ => ?_ - rw [mul_left_comm, ← pow_add, Nat.add_comm 3] - -/-- The `k`-th moment `∫ t in 0..1, t ^ 3 * Q ^ k`, as an explicit finite double sum. This -is `(M)` of the informal plan. -/ -noncomputable def mom (n : ℕ) (α : ℝ) (k : ℕ) : ℝ := - ∑ i ∈ range (k + 1), ∑ l ∈ range (i + 1), - ((k.choose i : ℝ) * (i.choose l) * (-2 * c n α) ^ l * A n α ^ (i - l)) - / ((2 * i - l + 4 : ℕ) : ℝ) - -/-- **The moment formula.** The integrals appearing in `Sendov.R` are exactly the finite -double sum `Sendov.mom`, for every natural `k`, with no hypotheses at all. -/ -theorem integral_moment (n : ℕ) (α : ℝ) (k : ℕ) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ k) = mom n α k := by - rw [mom] - have hfun : (fun t : ℝ => t ^ 3 * Q n α t ^ k) - = fun t : ℝ => ∑ i ∈ range (k + 1), ∑ l ∈ range (i + 1), - ((k.choose i : ℝ) * (i.choose l) * (-2 * c n α) ^ l * A n α ^ (i - l)) - * t ^ (2 * i - l + 3) := - funext fun t => t3_mul_Q_pow n α t k - rw [hfun, intervalIntegral.integral_finsetSum] - · refine sum_congr rfl fun i _ => ?_ - rw [intervalIntegral.integral_finsetSum] - · refine sum_congr rfl fun l _ => ?_ - rw [intervalIntegral.integral_const_mul, integral_pow] - push_cast - rw [one_pow] - norm_num - ring - · exact fun l _ => intervalIntegrable_const_mul_pow _ _ - · intro i _ - refine (Continuous.intervalIntegrable ?_ _ _) - exact continuous_finsetSum _ fun l _ => by fun_prop - -/-- The moments of a polynomial supported in degrees three to seven, kept as a convenience -for the low degrees. -/ -lemma integral_poly7 (a₀ a₁ a₂ a₃ a₄ : ℝ) : - (∫ t in (0 : ℝ)..1, (a₀ * t ^ 3 + a₁ * t ^ 4 + a₂ * t ^ 5 + a₃ * t ^ 6 + a₄ * t ^ 7)) - = a₀ / 4 + a₁ / 5 + a₂ / 6 + a₃ / 7 + a₄ / 8 := by - have h₀ := intervalIntegrable_const_mul_pow a₀ 3 - have h₁ := intervalIntegrable_const_mul_pow a₁ 4 - have h₂ := intervalIntegrable_const_mul_pow a₂ 5 - have h₃ := intervalIntegrable_const_mul_pow a₃ 6 - have h₄ := intervalIntegrable_const_mul_pow a₄ 7 - rw [intervalIntegral.integral_add (((h₀.add h₁).add h₂).add h₃) h₄, - intervalIntegral.integral_add ((h₀.add h₁).add h₂) h₃, - intervalIntegral.integral_add (h₀.add h₁) h₂, - intervalIntegral.integral_add h₀ h₁, - intervalIntegral.integral_const_mul, intervalIntegral.integral_const_mul, - intervalIntegral.integral_const_mul, intervalIntegral.integral_const_mul, - intervalIntegral.integral_const_mul, - integral_pow, integral_pow, integral_pow, integral_pow, integral_pow] - norm_num - ring - -end Sendov diff --git a/Sendov/FiniteRange/OddBound.lean b/Sendov/FiniteRange/OddBound.lean deleted file mode 100644 index 6c465a5..0000000 --- a/Sendov/FiniteRange/OddBound.lean +++ /dev/null @@ -1,67 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.Common.Rpow - -/-! -# The odd-degree bound - -For odd `n` the exponent `(n-4)/2` is the half-integer `k + 1/2` with `k = (n-5)/2`, and -`Sendov.R` involves a genuine square root. Writing `Q ^ (k+1/2) = Q ^ k * √Q` and bounding -`√Q` by a tangent line to the square root replaces it by polynomial moments: - - `∫ t in 0..1, t ^ 3 * Q ^ (k+1/2) ≤ ∫ t in 0..1, t ^ 3 * (Q ^ k * (Q/(2w) + w/2))` - -for any `w > 0` (`Sendov.integral_rpow_le`). This is the only place where `Real.sqrt` -appears; the statement above is already free of it. - -The tangent line `√q ≤ q/(2w) + w/2` touches at `q = w²`, so `w` should be chosen near the -values of `Q` that matter. Taking `w = 1` recovers `2√u ≤ 1 + u`, which is bound `(O)` of -the informal plan and is sharp enough for every odd `n ≥ 7`. Degree five needs a smaller -`w`: there the relevant values of `Q` are small, `w = 1` overshoots (it gives an upper bound -exceeding `1`, so it proves nothing), and `w = 1/3` works comfortably. This is what lets -degree five avoid the chord bound and the substitution `α = 3r²/(1-r²)` proposed in the -plan. - -Note that only `0 ≤ Q` is needed, never `Q ≤ 1`: the tangent-line inequality is just -`(√q - w)² ≥ 0`. --/ - -namespace Sendov - -open MeasureTheory - -variable {n : ℕ} {α q w : ℝ} - -/-- The tangent line to `√·` at `q = w²`: `√q ≤ q/(2w) + w/2`. -/ -lemma sqrt_le_tangent (hq : 0 ≤ q) (hw : 0 < w) : Real.sqrt q ≤ q / (2 * w) + w / 2 := by - have hrw : q / (2 * w) + w / 2 = (q + w ^ 2) / (2 * w) := by field_simp - rw [hrw, le_div_iff₀ (by positivity)] - nlinarith [sq_nonneg (Real.sqrt q - w), Real.sq_sqrt hq] - -/-- The half-integer power bound `q ^ (k + 1/2) ≤ q ^ k * (q/(2w) + w/2)`. -/ -lemma rpow_add_half_le (hq : 0 ≤ q) (k : ℕ) (hw : 0 < w) : - q ^ ((k : ℝ) + 1 / 2) ≤ q ^ k * (q / (2 * w) + w / 2) := by - rw [Real.rpow_add_of_nonneg hq (Nat.cast_nonneg k) (by positivity), - Real.rpow_natCast, ← Real.sqrt_eq_rpow] - exact mul_le_mul_of_nonneg_left (sqrt_le_tangent hq hw) (pow_nonneg hq k) - -/-- **The odd-degree bound.** The square root is eliminated in favour of polynomial -moments, at the cost of a free parameter `w > 0`. -/ -lemma integral_rpow_le (hfeas : c n α ^ 2 ≤ A n α) (k : ℕ) - (hk : ((n : ℝ) - 4) / 2 = (k : ℝ) + 1 / 2) (hw : 0 < w) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ (((n : ℝ) - 4) / 2)) - ≤ ∫ t in (0 : ℝ)..1, t ^ 3 * (Q n α t ^ k * (Q n α t / (2 * w) + w / 2)) := by - have he : (0 : ℝ) ≤ ((n : ℝ) - 4) / 2 := by rw [hk]; positivity - refine intervalIntegral.integral_mono_on (by norm_num) - ((continuous_integrand n α he).intervalIntegrable _ _) - ((by simp only [Q]; fun_prop : Continuous fun t : ℝ => - t ^ 3 * (Q n α t ^ k * (Q n α t / (2 * w) + w / 2))).intervalIntegrable _ _) ?_ - intro t ht - refine mul_le_mul_of_nonneg_left ?_ (pow_nonneg ht.1 3) - rw [hk] - exact rpow_add_half_le (Q_nonneg hfeas t) k hw - -end Sendov diff --git a/Sendov/FiniteRange/Pack.lean b/Sendov/FiniteRange/Pack.lean deleted file mode 100644 index 3a1ae82..0000000 --- a/Sendov/FiniteRange/Pack.lean +++ /dev/null @@ -1,239 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Mathlib.Data.List.Basic -import Mathlib.Tactic.Linarith -import Mathlib.Tactic.Ring - -/-! -# Kronecker packing of dense polynomials - -`Sendov.qrow` computes the coefficients of `(g₀ + g₁t + g₂t²) ^ k` as a `List (List ℤ)`. -That is correct but the kernel evaluates list recursion by interpretation, which costs -`Θ(k³)` interpreted steps: measured, `k = 24` takes two minutes and `k = 32` over twenty. - -Kernel `Nat` arithmetic, by contrast, is GMP-backed and fast — a 4000-digit multiplication -and a 50th power are milliseconds. So the fix is to change the *representation*, not the -algorithm: pack a dense polynomial into a single natural number by evaluating it at a base -`b = 2 ^ B` larger than every coefficient. Multiplication of polynomials then becomes -multiplication of naturals, and the whole recurrence collapses to `base ^ k`, one -exponentiation. Measured on the real shapes, `k = 46` drops from hours to about half a -second. - -This file provides the arithmetic core: evaluation `Sendov.npev`, the digit extraction -`Sendov.unpackN`, and the round trip `Sendov.unpackN_npev` saying that packing is faithful -exactly when every coefficient is below the base. The bound hypothesis is what the caller -must supply, and it is the only genuinely new obligation the packing introduces. - -Everything here is about `ℕ`; signed coefficients are handled downstream by splitting a -`ℤ`-polynomial into its positive and negative parts. - -## Main statements - -* `Sendov.npev_cons`, `Sendov.npev_append`: how evaluation behaves; -* `Sendov.unpackN_npev`: `unpackN b p.length (npev p b) = p` for coefficients below `b`. --/ - -namespace Sendov - -/-- Evaluate a dense `ℕ`-polynomial (lowest degree first) at `b`, by Horner's rule. This is -the packing map: `npev p b` is the single natural number representing `p`. -/ -def npev : List ℕ → ℕ → ℕ - | [], _ => 0 - | a :: p, b => a + b * npev p b - -@[simp] lemma npev_nil (b : ℕ) : npev [] b = 0 := rfl - -@[simp] lemma npev_cons (a : ℕ) (p : List ℕ) (b : ℕ) : - npev (a :: p) b = a + b * npev p b := rfl - -/-- Recover the first `m` coefficients of a packed polynomial. -/ -def unpackN (b : ℕ) : ℕ → ℕ → List ℕ - | 0, _ => [] - | m + 1, x => (x % b) :: unpackN b m (x / b) - -@[simp] lemma unpackN_zero (b x : ℕ) : unpackN b 0 x = [] := rfl - -@[simp] lemma unpackN_succ (b m x : ℕ) : - unpackN b (m + 1) x = (x % b) :: unpackN b m (x / b) := rfl - -/-- **Packing is faithful.** If every coefficient is smaller than the base, evaluation at -the base loses nothing: the coefficients can be read back off by division with remainder. - -This is the standard Kronecker-substitution correctness statement, and the hypothesis -`∀ a ∈ p, a < b` is exactly the overflow condition the caller must discharge. -/ -theorem unpackN_npev (b : ℕ) (hb : 0 < b) : - ∀ p : List ℕ, (∀ a ∈ p, a < b) → unpackN b p.length (npev p b) = p := by - intro p - induction p with - | nil => intro _; rfl - | cons a p ih => - intro hlt - have ha : a < b := hlt a (List.mem_cons_self ..) - have hp : ∀ x ∈ p, x < b := fun x hx => hlt x (List.mem_cons_of_mem _ hx) - have hmod : (a + b * npev p b) % b = a := by - rw [Nat.add_mul_mod_self_left, Nat.mod_eq_of_lt ha] - have hdiv : (a + b * npev p b) / b = npev p b := by - rw [Nat.add_mul_div_left _ _ hb, Nat.div_eq_of_lt ha, Nat.zero_add] - simp only [List.length_cons, npev_cons, unpackN_succ, hmod, hdiv, ih hp] - -/-- Evaluation of a concatenation: the second block is shifted by `b ^ (length of the -first)`. This is what makes the two-dimensional packing work. -/ -lemma npev_append (p q : List ℕ) (b : ℕ) : - npev (p ++ q) b = npev p b + b ^ p.length * npev q b := by - induction p with - | nil => simp - | cons a p ih => - simp only [List.cons_append, npev_cons, ih, List.length_cons] - ring - -/-! ### Packing is a ring homomorphism -/ - -/-- Addition of dense `ℕ`-polynomials. -/ -def paddN : List ℕ → List ℕ → List ℕ - | [], q => q - | a :: p, [] => a :: p - | a :: p, c :: q => (a + c) :: paddN p q - -/-- Multiplication of dense `ℕ`-polynomials. -/ -def pmulN : List ℕ → List ℕ → List ℕ - | [], _ => [] - | a :: p, q => paddN (q.map (fun c => a * c)) (0 :: pmulN p q) - -/-- The `k`-th power of a dense `ℕ`-polynomial. -/ -def ppowN (p : List ℕ) : ℕ → List ℕ - | 0 => [1] - | k + 1 => pmulN p (ppowN p k) - -lemma npev_paddN (p q : List ℕ) (b : ℕ) : - npev (paddN p q) b = npev p b + npev q b := by - induction p generalizing q with - | nil => simp [paddN] - | cons a p ih => - cases q with - | nil => simp [paddN] - | cons c q => - simp only [paddN, npev_cons, ih] - ring - -lemma npev_map_mul (a : ℕ) (q : List ℕ) (b : ℕ) : - npev (q.map (fun c => a * c)) b = a * npev q b := by - induction q with - | nil => simp - | cons c q ih => - simp only [List.map_cons, npev_cons, ih] - ring - -lemma npev_pmulN (p q : List ℕ) (b : ℕ) : - npev (pmulN p q) b = npev p b * npev q b := by - induction p with - | nil => simp [pmulN] - | cons a p ih => - simp only [pmulN, npev_paddN, npev_map_mul, npev_cons, ih] - ring - -lemma npev_ppowN (p : List ℕ) (b k : ℕ) : npev (ppowN p k) b = npev p b ^ k := by - induction k with - | zero => simp [ppowN] - | succ k ih => simp only [ppowN, npev_pmulN, ih, pow_succ'] - -/-! ### The overflow bound -/ - -/-- Every coefficient is at most the sum of the coefficients, which is the value at `1`. -/ -lemma mem_le_npev_one : ∀ (q : List ℕ) (a : ℕ), a ∈ q → a ≤ npev q 1 := by - intro q - induction q with - | nil => intro a ha; cases ha - | cons c q ih => - intro a ha - rcases List.mem_cons.1 ha with h | h - · subst h; simp - · have := ih a h - simp only [npev_cons, one_mul] - omega - -/-- **Kronecker substitution.** The coefficients of `p ^ k` are recovered from the single -natural number `(npev p b) ^ k`, provided the base `b` exceeds every coefficient of `p ^ k` -— for which `(npev p 1) ^ k < b` suffices, `npev p 1` being the sum of the coefficients. - -This is the statement that lets the kernel replace `Θ(k³)` interpreted list steps by one -GMP-backed exponentiation. -/ -theorem unpackN_pow (b : ℕ) (hb : 0 < b) (p : List ℕ) (k : ℕ) - (hbound : npev p 1 ^ k < b) : - unpackN b (ppowN p k).length (npev p b ^ k) = ppowN p k := by - rw [← npev_ppowN p b k] - refine unpackN_npev b hb _ fun a ha => ?_ - exact lt_of_le_of_lt (by simpa [npev_ppowN] using mem_le_npev_one (ppowN p k) a ha) hbound - -/-! ### Signed coefficients - -The recurrence's middle coefficient `g₁ = -2Dc` is negative, so the polynomials that have to -be packed have coefficients in `ℤ`. Packing is still evaluation at the base — the same -homomorphism — but reading the coefficients back needs *balanced* digits: the representative -of `x % b` taken in `(-b/2, b/2)` rather than `[0, b)`. The overflow condition becomes -`2 * |c| < b`. -/ - -/-- Evaluate a dense `ℤ`-polynomial at an integer. This is the signed packing map. -/ -def pevZ : List ℤ → ℤ → ℤ - | [], _ => 0 - | a :: p, b => a + b * pevZ p b - -@[simp] lemma pevZ_nil (b : ℤ) : pevZ [] b = 0 := rfl - -@[simp] lemma pevZ_cons (a : ℤ) (p : List ℤ) (b : ℤ) : - pevZ (a :: p) b = a + b * pevZ p b := rfl - -/-- The balanced representative of `x` modulo `b`, lying in `(-b/2, b/2)` when `b` is -positive and `x` is a balanced digit. -/ -def bdig (b x : ℤ) : ℤ := if 2 * (x % b) < b then x % b else x % b - b - -/-- Recover the first `m` balanced digits of a packed `ℤ`-polynomial. -/ -def unpackZ (b : ℤ) : ℕ → ℤ → List ℤ - | 0, _ => [] - | m + 1, x => bdig b x :: unpackZ b m ((x - bdig b x) / b) - -@[simp] lemma unpackZ_zero (b x : ℤ) : unpackZ b 0 x = [] := rfl - -@[simp] lemma unpackZ_succ (b : ℤ) (m : ℕ) (x : ℤ) : - unpackZ b (m + 1) x = bdig b x :: unpackZ b m ((x - bdig b x) / b) := rfl - -/-- The balanced digit of `c + b * N` is `c`, provided `2 * |c| < b`. -/ -lemma bdig_add_mul (b c N : ℤ) (hb : 0 < b) (hc : 2 * |c| < b) : - bdig b (c + b * N) = c := by - have hmod : (c + b * N) % b = c % b := Int.add_mul_emod_self_left c b N - by_cases h : 0 ≤ c - · rw [abs_of_nonneg h] at hc - have hcb : c < b := by linarith - have hx : (c + b * N) % b = c := by rw [hmod, Int.emod_eq_of_lt h hcb] - simp only [bdig, hx] - split_ifs - omega - · have h' : c < 0 := not_le.1 h - rw [abs_of_neg h'] at hc - have hcb : c % b = c + b := by - have e1 : (c + b) % b = c % b := by simp - have e2 : (c + b) % b = c + b := Int.emod_eq_of_lt (by linarith) (by linarith) - omega - have hx : (c + b * N) % b = c + b := by rw [hmod, hcb] - simp only [bdig, hx] - split_ifs <;> omega - -/-- **Signed packing is faithful.** If `2 * |c| < b` for every coefficient `c`, the -coefficients are recovered from the single integer `pevZ p b` by balanced-digit extraction. -/ -theorem unpackZ_pevZ (b : ℤ) (hb : 0 < b) : - ∀ p : List ℤ, (∀ a ∈ p, 2 * |a| < b) → unpackZ b p.length (pevZ p b) = p := by - intro p - induction p with - | nil => intro _; rfl - | cons a p ih => - intro hlt - have ha : 2 * |a| < b := hlt a (List.mem_cons_self ..) - have hp : ∀ x ∈ p, 2 * |x| < b := fun x hx => hlt x (List.mem_cons_of_mem _ hx) - have hd : bdig b (a + b * pevZ p b) = a := bdig_add_mul b a _ hb ha - have hq : (a + b * pevZ p b - a) / b = pevZ p b := by - rw [add_sub_cancel_left, Int.mul_ediv_cancel_left _ hb.ne'] - simp only [List.length_cons, pevZ_cons, unpackZ_succ, hd, hq, ih hp] - -end Sendov diff --git a/Sendov/FiniteRange/PackBridge.lean b/Sendov/FiniteRange/PackBridge.lean deleted file mode 100644 index 395f723..0000000 --- a/Sendov/FiniteRange/PackBridge.lean +++ /dev/null @@ -1,613 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Pack -import Sendov.FiniteRange.Recurrence - -/-! -# Computing the recurrence by a single exponentiation - -`Sendov.rev_qrow` says that `qrow` computes the coefficients of `(g₀ + g₁t + g₂t²) ^ k`. -Evaluating that identity at *integer* points turns it into a statement about packed values, -and the packing is nothing but the same Horner evaluation read in `ℤ` instead of `ℝ`. So the -forward direction needs no new theory at all: `Sendov.pevZ_rowZ_qrow` follows from -`rev_qrow` by casting. - -Two bases are involved: - -* `β` packs a coefficient polynomial in `α` into one integer (`Sendov.pevZ`); -* `τ` packs the resulting row, a polynomial in `t`, into one integer. - -Together they are the two-dimensional Kronecker substitution, and the whole recurrence -becomes `G ^ k` for the single integer `G = pevZ g₀ β + pevZ g₁ β * τ + pevZ g₂ β * τ²`. -`Sendov.unpackZ_pevZ` then reads the row back off, given the overflow bounds — which is where -the numerical parameters `β` and `τ` have to be chosen, one per degree. - -## Main statements - -* `Sendov.pev_intCast`, `Sendov.rev_intCast`: evaluation over `ℝ` at an integer point agrees - with the packed evaluation over `ℤ`; -* `Sendov.pevZ_rowZ_qrow`: the recurrence as one integer exponentiation. --/ - -namespace Sendov - -/-- The row with each coefficient polynomial packed at the base `β`. -/ -def rowZ (r : List (List ℤ)) (β : ℤ) : List ℤ := r.map (fun p => pevZ p β) - -@[simp] lemma rowZ_nil (β : ℤ) : rowZ [] β = [] := rfl - -@[simp] lemma rowZ_cons (p : List ℤ) (r : List (List ℤ)) (β : ℤ) : - rowZ (p :: r) β = pevZ p β :: rowZ r β := rfl - -@[simp] lemma rowZ_length (r : List (List ℤ)) (β : ℤ) : (rowZ r β).length = r.length := by - simp [rowZ] - -/-- Evaluating a coefficient polynomial over `ℝ` at an integer point is the packed -evaluation over `ℤ`. -/ -lemma pev_intCast (p : List ℤ) (b : ℤ) : pev p (b : ℝ) = (pevZ p b : ℝ) := by - induction p with - | nil => simp [pev] - | cons a p ih => - simp only [pev, pevZ_cons, ih] - push_cast - ring - -/-- Evaluating a row over `ℝ` at integer points is the packed evaluation over `ℤ`. -/ -lemma rev_intCast (r : List (List ℤ)) (β τ : ℤ) : - rev r (β : ℝ) (τ : ℝ) = (pevZ (rowZ r β) τ : ℝ) := by - induction r with - | nil => simp [rev] - | cons p r ih => - simp only [rev_cons, rowZ_cons, pevZ_cons, ih, pev_intCast] - push_cast - ring - -/-- **The recurrence as one exponentiation.** The two-dimensionally packed row is the `k`-th -power of a single integer. In the kernel this replaces `Θ(k³)` interpreted list steps by one -GMP-backed exponentiation; measured at `k = 46`, hours become about half a second. -/ -theorem pevZ_rowZ_qrow (g₀ g₁ g₂ : List ℤ) (k : ℕ) (β τ : ℤ) : - pevZ (rowZ (qrow g₀ g₁ g₂ k) β) τ - = (pevZ g₀ β + pevZ g₁ β * τ + pevZ g₂ β * τ ^ 2) ^ k := by - have h := rev_qrow g₀ g₁ g₂ k (β : ℝ) (τ : ℝ) - rw [rev_intCast, pev_intCast, pev_intCast, pev_intCast] at h - exact_mod_cast h - -/-- Reading the packed row back, given the overflow bound on the packed coefficients. The -bound is a hypothesis: it is discharged per degree from explicit numerical parameters. -/ -theorem rowZ_qrow_eq (g₀ g₁ g₂ : List ℤ) (k : ℕ) (β τ : ℤ) (hτ : 0 < τ) - (hbound : ∀ a ∈ rowZ (qrow g₀ g₁ g₂ k) β, 2 * |a| < τ) : - unpackZ τ (qrow g₀ g₁ g₂ k).length - ((pevZ g₀ β + pevZ g₁ β * τ + pevZ g₂ β * τ ^ 2) ^ k) - = rowZ (qrow g₀ g₁ g₂ k) β := by - rw [← pevZ_rowZ_qrow, ← rowZ_length (qrow g₀ g₁ g₂ k) β] - exact unpackZ_pevZ τ hτ _ hbound - -/-! ### The moment as a single integer polynomial - -`Sendov.irow` has rational weights `1/(j+4)`. Scaling by a common multiple `L` of the -denominators clears them, turning the moment into one `ℤ`-polynomial in `α`. -/ - -/-- `∑ⱼ (L/(i+j+4)) • rⱼ`: the moment numerator, scaled by `L` to clear denominators. -/ -def wsum (L : ℤ) : ℕ → List (List ℤ) → List ℤ - | _, [] => [] - | i, p :: r => padd (p.map (fun c => (L / ((i : ℤ) + 4)) * c)) (wsum L (i + 1) r) - -@[simp] lemma wsum_nil (L : ℤ) (i : ℕ) : wsum L i [] = [] := rfl - -@[simp] lemma wsum_cons (L : ℤ) (i : ℕ) (p : List ℤ) (r : List (List ℤ)) : - wsum L i (p :: r) - = padd (p.map (fun c => (L / ((i : ℤ) + 4)) * c)) (wsum L (i + 1) r) := rfl - -/-- **The scaled moment is an integer polynomial.** Given that `L` clears every denominator -`i+j+4` occurring, `wsum` computes `L` times `Sendov.irow`. -/ -theorem pev_wsum (L : ℤ) : ∀ (r : List (List ℤ)) (i : ℕ) (α : ℝ), - (∀ j, j < r.length → ((i : ℤ) + j + 4) ∣ L) → - pev (wsum L i r) α = (L : ℝ) * irow r i α := by - intro r - induction r with - | nil => intro i α _; simp [irow] - | cons p r ih => - intro i α hdvd - have h0 : ((i : ℤ) + 4) ∣ L := by - have := hdvd 0 (by simp) - simpa using this - obtain ⟨m, hm⟩ := h0 - have hine : ((i : ℤ) + 4) ≠ 0 := by positivity - have hw : L / ((i : ℤ) + 4) = m := by rw [hm, Int.mul_ediv_cancel_left _ hine] - have hcast : ((m : ℤ) : ℝ) * ((i : ℝ) + 4) = (L : ℝ) := by - rw [hm]; push_cast; ring - have hi4 : ((i : ℝ) + 4) ≠ 0 := by positivity - have hrest : ∀ j, j < r.length → (((i + 1 : ℕ) : ℤ) + j + 4) ∣ L := by - intro j hj - have := hdvd (j + 1) (by simpa using Nat.succ_lt_succ hj) - push_cast at this ⊢ - convert this using 2 - ring - rw [wsum_cons, pev_padd, pev_map_mul, hw, ih (i + 1) α hrest] - simp only [irow] - field_simp - linear_combination (pev p α) * hcast - -/-! ### Coefficient bounds - -Injectivity of packing needs a bound on the coefficients of *both* lists compared — including -the true row, which is precisely the object we must not compute. So the bound has to be -proved rather than checked. The `L¹` norm does it: it is submultiplicative, so a coefficient -of the `k`-th power is at most `(l1 g₀ + l1 g₁ + l1 g₂) ^ k`. -/ - -/-- Sum of absolute values of the coefficients. -/ -def l1 : List ℤ → ℤ - | [] => 0 - | a :: p => |a| + l1 p - -@[simp] lemma l1_nil : l1 [] = 0 := rfl - -@[simp] lemma l1_cons (a : ℤ) (p : List ℤ) : l1 (a :: p) = |a| + l1 p := rfl - -lemma l1_nonneg (p : List ℤ) : 0 ≤ l1 p := by - induction p with - | nil => simp - | cons a p ih => have := abs_nonneg a; simp only [l1_cons]; omega - -lemma abs_le_l1 : ∀ (p : List ℤ) (a : ℤ), a ∈ p → |a| ≤ l1 p := by - intro p - induction p with - | nil => intro a ha; cases ha - | cons c p ih => - intro a ha - rcases List.mem_cons.1 ha with h | h - · subst h; have := l1_nonneg p; simp only [l1_cons]; omega - · have := ih a h; have := abs_nonneg c; simp only [l1_cons]; omega - -lemma l1_padd (p q : List ℤ) : l1 (padd p q) ≤ l1 p + l1 q := by - induction p generalizing q with - | nil => simp [padd] - | cons a p ih => - cases q with - | nil => simp [padd] - | cons b q => - have h1 := ih q - have h2 := abs_add_le a b - simp only [padd, l1_cons] - omega - -lemma l1_map_mul (c : ℤ) (q : List ℤ) : l1 (q.map (fun x => c * x)) = |c| * l1 q := by - induction q with - | nil => simp - | cons b q ih => - simp only [List.map_cons, l1_cons, ih, abs_mul] - ring - -lemma l1_pmul (p q : List ℤ) : l1 (pmul p q) ≤ l1 p * l1 q := by - induction p with - | nil => simp [pmul] - | cons a p ih => - have hstep : l1 (padd (q.map (fun c => a * c)) (0 :: pmul p q)) - ≤ |a| * l1 q + l1 (pmul p q) := by - have := l1_padd (q.map (fun c => a * c)) (0 :: pmul p q) - rw [l1_map_mul] at this - simpa using this - have hq := l1_nonneg q - simp only [pmul, l1_cons] - nlinarith [ih, hq, hstep] - -/-- The `L¹` norm of a row: the total of its coefficients' absolute values. -/ -def l1row : List (List ℤ) → ℤ - | [] => 0 - | p :: r => l1 p + l1row r - -@[simp] lemma l1row_nil : l1row [] = 0 := rfl - -@[simp] lemma l1row_cons (p : List ℤ) (r : List (List ℤ)) : - l1row (p :: r) = l1 p + l1row r := rfl - -lemma l1row_nonneg (r : List (List ℤ)) : 0 ≤ l1row r := by - induction r with - | nil => simp - | cons p r ih => have := l1_nonneg p; simp only [l1row_cons]; omega - -lemma l1row_radd (r s : List (List ℤ)) : l1row (radd r s) ≤ l1row r + l1row s := by - induction r generalizing s with - | nil => simp [radd] - | cons p r ih => - cases s with - | nil => simp [radd] - | cons q s => - have h1 := ih s - have h2 := l1_padd p q - simp only [radd, l1row_cons] - omega - -lemma l1row_rscale (g : List ℤ) (r : List (List ℤ)) : - l1row (rscale g r) ≤ l1 g * l1row r := by - induction r with - | nil => simp [rscale] - | cons p r ih => - have := l1_pmul g p - simp only [rscale, List.map_cons, l1row_cons] at * - nlinarith [ih, l1_nonneg g, l1row_nonneg r] - -lemma l1row_qstep (g₀ g₁ g₂ : List ℤ) (r : List (List ℤ)) : - l1row (qstep g₀ g₁ g₂ r) ≤ (l1 g₀ + l1 g₁ + l1 g₂) * l1row r := by - have h0 := l1row_rscale g₀ r - have h1 := l1row_rscale g₁ r - have h2 := l1row_rscale g₂ r - have e1 := l1row_radd (rscale g₀ r) (radd ([] :: rscale g₁ r) ([] :: [] :: rscale g₂ r)) - have e2 := l1row_radd ([] :: rscale g₁ r) ([] :: [] :: rscale g₂ r) - simp only [qstep, l1row_cons, l1_nil] at * - nlinarith [e1, e2, h0, h1, h2] - -/-- The coefficients of the `k`-th power are bounded by the `k`-th power of the `L¹` norm. -This is the bound that the packing base must exceed. -/ -theorem l1row_qrow (g₀ g₁ g₂ : List ℤ) (k : ℕ) : - l1row (qrow g₀ g₁ g₂ k) ≤ (l1 g₀ + l1 g₁ + l1 g₂) ^ k := by - induction k with - | zero => simp [qrow] - | succ k ih => - have hg : 0 ≤ l1 g₀ + l1 g₁ + l1 g₂ := by - have := l1_nonneg g₀; have := l1_nonneg g₁; have := l1_nonneg g₂; omega - calc l1row (qrow g₀ g₁ g₂ (k + 1)) - ≤ (l1 g₀ + l1 g₁ + l1 g₂) * l1row (qrow g₀ g₁ g₂ k) := l1row_qstep _ _ _ _ - _ ≤ (l1 g₀ + l1 g₁ + l1 g₂) * (l1 g₀ + l1 g₁ + l1 g₂) ^ k := by - exact mul_le_mul_of_nonneg_left ih hg - _ = (l1 g₀ + l1 g₁ + l1 g₂) ^ (k + 1) := by ring - -/-! ### Lengths, and the magnitude of a packed value -/ - -lemma padd_length (p q : List ℤ) : (padd p q).length = max p.length q.length := by - induction p generalizing q with - | nil => simp [padd] - | cons a p ih => - cases q with - | nil => simp [padd] - | cons c q => simp [padd, ih] - -lemma radd_length (r s : List (List ℤ)) : - (radd r s).length = max r.length s.length := by - induction r generalizing s with - | nil => simp [radd] - | cons p r ih => - cases s with - | nil => simp [radd] - | cons q s => simp [radd, ih] - -@[simp] lemma rscale_length (g : List ℤ) (r : List (List ℤ)) : - (rscale g r).length = r.length := by - simp [rscale] - -/-- The row of the `k`-th power has `2k+1` entries, whatever the multiplier. -/ -@[simp] lemma qrow_length (g₀ g₁ g₂ : List ℤ) (k : ℕ) : - (qrow g₀ g₁ g₂ k).length = 2 * k + 1 := by - induction k with - | zero => simp [qrow] - | succ k ih => - simp only [qrow, qstep, radd_length, rscale_length, List.length_cons, ih] - omega - -/-- A packed value is bounded by the `L¹` norm times a power of the base. -/ -lemma abs_pevZ_le (b : ℤ) (hb : 1 ≤ b) : - ∀ p : List ℤ, |pevZ p b| ≤ l1 p * b ^ p.length := by - intro p - induction p with - | nil => simp - | cons a p ih => - have hb0 : (0 : ℤ) < b := by omega - have hpow : (1 : ℤ) ≤ b ^ p.length := one_le_pow₀ hb - have hl1 := l1_nonneg p - have habs := abs_nonneg a - calc |pevZ (a :: p) b| = |a + b * pevZ p b| := rfl - _ ≤ |a| + |b * pevZ p b| := abs_add_le _ _ - _ = |a| + b * |pevZ p b| := by rw [abs_mul, abs_of_pos hb0] - _ ≤ |a| + b * (l1 p * b ^ p.length) := by nlinarith [ih] - _ ≤ (|a| + l1 p) * b ^ (p.length + 1) := by - have hbb : (1 : ℤ) ≤ b * b ^ p.length := by nlinarith [hpow, hb0] - have hkey := mul_le_mul_of_nonneg_left hbb habs - ring_nf - nlinarith [hkey, hpow, hl1, hb0] - _ = l1 (a :: p) * b ^ (a :: p).length := by simp [l1_cons] - -/-! ### The verification step - -The generator supplies the moment numerator; Lean checks it with one integer comparison. -Lengths need not match exactly: a shorter list is compared against its zero-padding, which -has the same value as a polynomial. -/ - -/-- Evaluation ignores trailing zeros. -/ -lemma pev_append_zeros (p : List ℤ) (j : ℕ) (α : ℝ) : - pev (p ++ List.replicate j 0) α = pev p α := by - induction p with - | nil => - induction j with - | zero => simp [pev] - | succ j ih => simp only [List.replicate_succ, List.nil_append, pev] at *; simp [ih] - | cons a p ih => simp only [List.cons_append, pev, ih] - -/-- The round trip, tolerating extra room: unpacking to length `m ≥ p.length` returns `p` -zero-padded. -/ -theorem unpackZ_pevZ_le (β : ℤ) (hβ : 0 < β) : - ∀ (m : ℕ) (p : List ℤ), p.length ≤ m → (∀ a ∈ p, 2 * |a| < β) → - unpackZ β m (pevZ p β) = p ++ List.replicate (m - p.length) 0 := by - intro m p hlen hb - -- Apply the exact round trip to the padded list, rather than repeat digit extraction. - have hlen' : (p ++ List.replicate (m - p.length) 0).length = m := by - simp only [List.length_append, List.length_replicate] - omega - have heval : pevZ (p ++ List.replicate (m - p.length) 0) β = pevZ p β := by - have h := pev_append_zeros p (m - p.length) (β : ℝ) - simp only [pev_intCast] at h - exact_mod_cast h - have hround := unpackZ_pevZ β hβ (p ++ List.replicate (m - p.length) 0) (by - intro a ha - rcases List.mem_append.1 ha with ha | ha - · exact hb a ha - · have ha0 : a = 0 := (List.mem_replicate.1 ha).2 - simpa [ha0] using hβ) - simpa only [hlen', heval] using hround - -/-- The weighted sum computed directly on the α-packed row. -/ -def wsumZ (L : ℤ) : ℕ → List ℤ → ℤ - | _, [] => 0 - | i, a :: s => (L / ((i : ℤ) + 4)) * a + wsumZ L (i + 1) s - -@[simp] lemma wsumZ_nil (L : ℤ) (i : ℕ) : wsumZ L i [] = 0 := rfl - -@[simp] lemma wsumZ_cons (L : ℤ) (i : ℕ) (a : ℤ) (s : List ℤ) : - wsumZ L i (a :: s) = (L / ((i : ℤ) + 4)) * a + wsumZ L (i + 1) s := rfl - -lemma pevZ_padd (p q : List ℤ) (b : ℤ) : pevZ (padd p q) b = pevZ p b + pevZ q b := by - have h := pev_padd p q (b : ℝ) - simp only [pev_intCast] at h - exact_mod_cast h - -lemma pevZ_map_mul (c : ℤ) (q : List ℤ) (b : ℤ) : - pevZ (q.map (fun x => c * x)) b = c * pevZ q b := by - have h := pev_map_mul c q (b : ℝ) - simp only [pev_intCast] at h - exact_mod_cast h - -/-- The packed weighted sum agrees with packing the weighted sum: this is what makes the -check a single integer comparison. -/ -lemma pevZ_wsum (L : ℤ) : ∀ (r : List (List ℤ)) (i : ℕ) (β : ℤ), - pevZ (wsum L i r) β = wsumZ L i (rowZ r β) := by - intro r - induction r with - | nil => intro i β; simp - | cons p r ih => - intro i β - simp only [wsum_cons, pevZ_padd, pevZ_map_mul, rowZ_cons, wsumZ_cons, ih] - -/-- Packing is injective on lists of the same length with coefficients below `β/2`. -/ -lemma pevZ_inj (β : ℤ) (hβ : 0 < β) (p q : List ℤ) - (hp : ∀ a ∈ p, 2 * |a| < β) (hq : ∀ a ∈ q, 2 * |a| < β) - (hlen : p.length = q.length) (h : pevZ p β = pevZ q β) : p = q := by - have h1 := unpackZ_pevZ β hβ p hp - have h2 := unpackZ_pevZ β hβ q hq - rw [← h1, ← h2, hlen, h] - -/-- **Verification of a supplied moment numerator.** Given the overflow bounds, checking a -generator-supplied `Nmom` is one integer comparison against the packed computation — which is -a single exponentiation and `2k+1` digit extractions. -/ -theorem wsum_eq_of_packed (g₀ g₁ g₂ : List ℤ) (k : ℕ) (L β τ : ℤ) (Nmom : List ℤ) - (hβ : 0 < β) (hτ : 0 < τ) - (hbτ : ∀ a ∈ rowZ (qrow g₀ g₁ g₂ k) β, 2 * |a| < τ) - (hbN : ∀ a ∈ Nmom, 2 * |a| < β) - (hbW : ∀ a ∈ wsum L 0 (qrow g₀ g₁ g₂ k), 2 * |a| < β) - (hlen : Nmom.length = (wsum L 0 (qrow g₀ g₁ g₂ k)).length) - (hcheck : wsumZ L 0 (unpackZ τ (qrow g₀ g₁ g₂ k).length - ((pevZ g₀ β + pevZ g₁ β * τ + pevZ g₂ β * τ ^ 2) ^ k)) = pevZ Nmom β) : - Nmom = wsum L 0 (qrow g₀ g₁ g₂ k) := by - rw [rowZ_qrow_eq g₀ g₁ g₂ k β τ hτ hbτ, ← pevZ_wsum] at hcheck - exact pevZ_inj β hβ _ _ hbN hbW hlen hcheck.symm - -/-! ### Entry lengths - -`qrow_length` counts the entries of a row; bounding the α-packed values also needs each -entry's *length*. Multiplying by a `g` of length at most `G` lengthens an entry by at most -`G`, so after `k` steps an entry has length at most `1 + G*k`. This is what lets the -hypotheses of `wsum_eq_of_packed` be discharged by arithmetic instead of by computing -`qrow`. -/ - -lemma pmul_length_le (p q : List ℤ) : (pmul p q).length ≤ p.length + q.length := by - induction p with - | nil => simp [pmul] - | cons a p ih => - simp only [pmul, padd_length, List.length_map, List.length_cons] - omega - -lemma mem_radd_length_le {m : ℕ} : ∀ (r s : List (List ℤ)), - (∀ p ∈ r, p.length ≤ m) → (∀ q ∈ s, q.length ≤ m) → - ∀ x ∈ radd r s, x.length ≤ m := by - intro r - induction r with - | nil => intro s _ hs x hx; exact hs x (by simpa [radd] using hx) - | cons p r ih => - intro s hr hs x hx - cases s with - | nil => exact hr x (by simpa [radd] using hx) - | cons q s => - rcases List.mem_cons.1 (by simpa [radd] using hx) with h | h - · subst h - have := hr p (List.mem_cons_self ..) - have := hs q (List.mem_cons_self ..) - rw [padd_length] - omega - · exact ih s (fun y hy => hr y (List.mem_cons_of_mem _ hy)) - (fun y hy => hs y (List.mem_cons_of_mem _ hy)) x h - -lemma mem_rscale_length_le {m : ℕ} (g : List ℤ) (r : List (List ℤ)) - (hr : ∀ p ∈ r, p.length ≤ m) : ∀ x ∈ rscale g r, x.length ≤ g.length + m := by - intro x hx - simp only [rscale, List.mem_map] at hx - obtain ⟨p, hp, rfl⟩ := hx - have := pmul_length_le g p - have := hr p hp - omega - -/-- Each entry of the `k`-th row has length at most `1 + G*k`, where `G` bounds the lengths -of the multipliers. -/ -theorem qrow_entry_length_le (g₀ g₁ g₂ : List ℤ) (G : ℕ) - (h0 : g₀.length ≤ G) (h1 : g₁.length ≤ G) (h2 : g₂.length ≤ G) : - ∀ (k : ℕ), ∀ p ∈ qrow g₀ g₁ g₂ k, p.length ≤ 1 + G * k := by - intro k - induction k with - | zero => - intro p hp - simp only [qrow, List.mem_singleton] at hp - subst hp - simp - | succ k ih => - intro p hp - have hGk : G * (k + 1) = G * k + G := by ring - have hb : ∀ q ∈ qrow g₀ g₁ g₂ k, q.length ≤ 1 + G * k := ih - have e0 : ∀ x ∈ rscale g₀ (qrow g₀ g₁ g₂ k), x.length ≤ 1 + G * (k + 1) := by - intro x hx; have := mem_rscale_length_le g₀ _ hb x hx; omega - have e1 : ∀ x ∈ ([] : List ℤ) :: rscale g₁ (qrow g₀ g₁ g₂ k), - x.length ≤ 1 + G * (k + 1) := by - intro x hx - rcases List.mem_cons.1 hx with h | h - · subst h; simp - · have := mem_rscale_length_le g₁ _ hb x h; omega - have e2 : ∀ x ∈ ([] : List ℤ) :: ([] : List ℤ) :: rscale g₂ (qrow g₀ g₁ g₂ k), - x.length ≤ 1 + G * (k + 1) := by - intro x hx - rcases List.mem_cons.1 hx with h | h - · subst h; simp - rcases List.mem_cons.1 h with h' | h' - · subst h'; simp - · have := mem_rscale_length_le g₂ _ hb x h'; omega - exact mem_radd_length_le _ _ e0 (mem_radd_length_le _ _ e1 e2) p hp - -/-- `l1` of an entry is at most `l1row` of the row. -/ -lemma l1_le_l1row : ∀ (r : List (List ℤ)) (p : List ℤ), p ∈ r → l1 p ≤ l1row r := by - intro r - induction r with - | nil => intro p hp; cases hp - | cons q r ih => - intro p hp - rcases List.mem_cons.1 hp with h | h - · subst h; have := l1row_nonneg r; simp only [l1row_cons]; omega - · have := ih p h; have := l1_nonneg q; simp only [l1row_cons]; omega - -/-- The weighted sum is no longer than the entries it combines. -/ -lemma wsum_length_le {m : ℕ} (L : ℤ) : ∀ (r : List (List ℤ)) (i : ℕ), - (∀ p ∈ r, p.length ≤ m) → (wsum L i r).length ≤ m := by - intro r - induction r with - | nil => intro i _; simp - | cons p r ih => - intro i hr - have hp := hr p (List.mem_cons_self ..) - have := ih (i + 1) (fun q hq => hr q (List.mem_cons_of_mem _ hq)) - simp only [wsum_cons, padd_length, List.length_map] - omega - -/-- The weighted sum's `L¹` norm is at most `L` times the row's. -/ -lemma l1_wsum_le (L : ℤ) (hL : 0 ≤ L) : ∀ (r : List (List ℤ)) (i : ℕ), - l1 (wsum L i r) ≤ L * l1row r := by - intro r - induction r with - | nil => intro i; simp - | cons p r ih => - intro i - have hd : (0 : ℤ) < (i : ℤ) + 4 := by positivity - have hw0 : 0 ≤ L / ((i : ℤ) + 4) := Int.ediv_nonneg hL hd.le - have hw1 : L / ((i : ℤ) + 4) ≤ L := Int.ediv_le_self _ hL - have h1 := l1_padd (p.map (fun c => (L / ((i : ℤ) + 4)) * c)) (wsum L (i + 1) r) - rw [l1_map_mul, abs_of_nonneg hw0] at h1 - have h2 := ih (i + 1) - have hp := l1_nonneg p - have hr := l1row_nonneg r - simp only [wsum_cons, l1row_cons] - nlinarith [h1, h2, hw0, hw1, hp, hr] - -/-! ### The bounds in usable form - -Each hypothesis of `Sendov.wsum_eq_of_packed` reduces to an inequality between explicit -numbers, so a degree file never computes `qrow`. -/ - -/-- The `τ` bound: the α-packed row entries are bounded by the `L¹` norm times a power of -`β`, the exponent coming from `Sendov.qrow_entry_length_le`. -/ -theorem rowZ_bound (g₀ g₁ g₂ : List ℤ) (k G : ℕ) (β τ : ℤ) (hβ : 1 ≤ β) - (h0 : g₀.length ≤ G) (h1 : g₁.length ≤ G) (h2 : g₂.length ≤ G) - (hτ : 2 * ((l1 g₀ + l1 g₁ + l1 g₂) ^ k * β ^ (1 + G * k)) < τ) : - ∀ a ∈ rowZ (qrow g₀ g₁ g₂ k) β, 2 * |a| < τ := by - intro a ha - simp only [rowZ, List.mem_map] at ha - obtain ⟨p, hp, rfl⟩ := ha - have hlen : p.length ≤ 1 + G * k := qrow_entry_length_le g₀ g₁ g₂ G h0 h1 h2 k p hp - have hl1p : l1 p ≤ (l1 g₀ + l1 g₁ + l1 g₂) ^ k := - le_trans (l1_le_l1row _ p hp) (l1row_qrow g₀ g₁ g₂ k) - have hpow : β ^ p.length ≤ β ^ (1 + G * k) := pow_le_pow_right₀ hβ hlen - have hbpos : (0 : ℤ) < β ^ p.length := by positivity - have habs := abs_pevZ_le β hβ p - have hl1nn := l1_nonneg p - have : |pevZ p β| ≤ (l1 g₀ + l1 g₁ + l1 g₂) ^ k * β ^ (1 + G * k) := by - calc |pevZ p β| ≤ l1 p * β ^ p.length := habs - _ ≤ (l1 g₀ + l1 g₁ + l1 g₂) ^ k * β ^ (1 + G * k) := by - apply mul_le_mul hl1p hpow hbpos.le - exact le_trans hl1nn hl1p - omega - -/-- The `β` bound for the moment numerator. -/ -theorem wsum_bound (g₀ g₁ g₂ : List ℤ) (k : ℕ) (L β : ℤ) (hL : 0 ≤ L) - (hβ : 2 * (L * (l1 g₀ + l1 g₁ + l1 g₂) ^ k) < β) : - ∀ a ∈ wsum L 0 (qrow g₀ g₁ g₂ k), 2 * |a| < β := by - intro a ha - have h1 : |a| ≤ l1 (wsum L 0 (qrow g₀ g₁ g₂ k)) := abs_le_l1 _ a ha - have h2 := l1_wsum_le L hL (qrow g₀ g₁ g₂ k) 0 - have h3 : L * l1row (qrow g₀ g₁ g₂ k) ≤ L * (l1 g₀ + l1 g₁ + l1 g₂) ^ k := - mul_le_mul_of_nonneg_left (l1row_qrow g₀ g₁ g₂ k) hL - omega - -/-- **Pad-tolerant verification.** Concludes equality of the polynomial *functions*, which -is all the moment needs, and so requires only length *bounds* rather than an exact match. -/ -theorem pev_wsum_eq_of_packed (g₀ g₁ g₂ : List ℤ) (k m : ℕ) (L β τ : ℤ) (Nmom : List ℤ) - (hβ : 0 < β) (hτ : 0 < τ) - (hbτ : ∀ a ∈ rowZ (qrow g₀ g₁ g₂ k) β, 2 * |a| < τ) - (hbN : ∀ a ∈ Nmom, 2 * |a| < β) - (hbW : ∀ a ∈ wsum L 0 (qrow g₀ g₁ g₂ k), 2 * |a| < β) - (hlenN : Nmom.length ≤ m) - (hlenW : (wsum L 0 (qrow g₀ g₁ g₂ k)).length ≤ m) - (hcheck : wsumZ L 0 (unpackZ τ (qrow g₀ g₁ g₂ k).length - ((pevZ g₀ β + pevZ g₁ β * τ + pevZ g₂ β * τ ^ 2) ^ k)) = pevZ Nmom β) - (α : ℝ) : - pev Nmom α = pev (wsum L 0 (qrow g₀ g₁ g₂ k)) α := by - rw [rowZ_qrow_eq g₀ g₁ g₂ k β τ hτ hbτ, ← pevZ_wsum] at hcheck - have hN := unpackZ_pevZ_le β hβ m Nmom hlenN hbN - have hW := unpackZ_pevZ_le β hβ m _ hlenW hbW - rw [hcheck, hN] at hW - have := congrArg (fun l => pev l α) hW - simpa [pev_append_zeros] using this - -/-- **The moment from a verified numerator.** Combining `Sendov.integral_moment_of` with -`Sendov.pev_wsum`, the integral is an explicit integer polynomial over an explicit -denominator. Everything on the right is either supplied by the generator or a kernel -computation on integers. -/ -theorem integral_moment_packed (n k : ℕ) (hn : 2 ≤ n) (α : ℝ) (hα : 0 ≤ α) - (L : ℤ) (hL : 0 < L) (Nmom : List ℤ) - (hdvd : ∀ j, j < 2 * k + 1 → ((0 : ℕ) + j + 4 : ℤ) ∣ L) - (hNmom : pev Nmom α = pev (wsum L 0 (qrow (gg0 n) (gg1 n) (gg2 n) k)) α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ k) - = pev Nmom α / ((L : ℝ) * (2 * M n * (3 + α)) ^ k) := by - have hM : 0 < M n := M_pos hn - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hD : (0 : ℝ) < 2 * M n * (3 + α) := by positivity - have hLR : (0 : ℝ) < (L : ℝ) := by exact_mod_cast hL - have hdvd' : ∀ j, j < (qrow (gg0 n) (gg1 n) (gg2 n) k).length → - ((0 : ℕ) + j + 4 : ℤ) ∣ L := by - intro j hj - rw [qrow_length] at hj - exact hdvd j hj - have hw := pev_wsum L (qrow (gg0 n) (gg1 n) (gg2 n) k) 0 α hdvd' - rw [integral_moment_of n k hn α hα, hNmom, hw] - field_simp - -/-- Every coefficient of every entry of a row is bounded by the row's `L¹` norm. -/ -lemma abs_le_l1row : ∀ (r : List (List ℤ)) (p : List ℤ), p ∈ r → ∀ a ∈ p, |a| ≤ l1row r := by - intro r p hp a ha - exact (abs_le_l1 p a ha).trans (l1_le_l1row r p hp) - -end Sendov diff --git a/Sendov/FiniteRange/PackedMomentCertificate.lean b/Sendov/FiniteRange/PackedMomentCertificate.lean deleted file mode 100644 index c679baa..0000000 --- a/Sendov/FiniteRange/PackedMomentCertificate.lean +++ /dev/null @@ -1,42 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.PackBridge - -/-! -# Numeric conditions for a packed batch moment - -The analytic recurrence bounds discharge the true row obligations uniformly. -Each batch still supplies its exact numerator and kernel-checked packed equality. --/ - -namespace Sendov - -/-- Numeric overflow and length bounds suffice to verify a supplied moment numerator. -The three recurrence multipliers have length at most three, so the true weighted row -has length at most `1 + 3*k`. Its coefficients and packed row are bounded analytically; -only the supplied numerator and the single packed equality are computed by the caller. -Trailing zeros are permitted, and no recurrence row needs to be expanded. -/ -theorem pev_moment_eq_of_packed_bounds (n k : ℕ) (L β τ : ℤ) (Nmom : List ℤ) - (hL : 0 ≤ L) (hβ : 1 ≤ β) (hτ : 0 < τ) - (hrow : 2 * ((l1 (gg0 n) + l1 (gg1 n) + l1 (gg2 n)) ^ k - * β ^ (1 + 3 * k)) < τ) - (hweight : 2 * (L * (l1 (gg0 n) + l1 (gg1 n) + l1 (gg2 n)) ^ k) < β) - (hN : ∀ a ∈ Nmom, 2 * |a| < β) (hlen : Nmom.length ≤ 1 + 3 * k) - (hcheck : wsumZ L 0 (unpackZ τ (2 * k + 1) - ((pevZ (gg0 n) β + pevZ (gg1 n) β * τ + pevZ (gg2 n) β * τ ^ 2) ^ k)) - = pevZ Nmom β) (α : ℝ) : - pev Nmom α = pev (wsum L 0 (qrow (gg0 n) (gg1 n) (gg2 n) k)) α := by - refine pev_wsum_eq_of_packed (gg0 n) (gg1 n) (gg2 n) k (1 + 3 * k) - L β τ Nmom (by omega) hτ ?_ hN ?_ hlen ?_ ?_ α - · exact rowZ_bound (gg0 n) (gg1 n) (gg2 n) k 3 β τ hβ - (by simp) (by simp) (by simp) hrow - · exact wsum_bound (gg0 n) (gg1 n) (gg2 n) k L β hL hweight - · exact wsum_length_le L _ 0 - (qrow_entry_length_le (gg0 n) (gg1 n) (gg2 n) 3 - (by simp) (by simp) (by simp) k) - · simpa only [qrow_length] using hcheck - -end Sendov diff --git a/Sendov/FiniteRange/Recurrence.lean b/Sendov/FiniteRange/Recurrence.lean deleted file mode 100644 index d9d7614..0000000 --- a/Sendov/FiniteRange/Recurrence.lean +++ /dev/null @@ -1,259 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.Common.Basic -import Mathlib.Analysis.SpecialFunctions.Integrals.Basic - -/-! -# Moments by a verified recurrence - -`Sendov.integral_moment` computes `∫ t in 0..1, t ^ 3 * Q ^ k` as the multinomial double -sum `(M)`. That formula is correct but has `Θ(k²)` terms, and expanding it with `simp` -becomes impossible around `k = 20`: at `n = 53` the 676-term expansion exhausts two million -heartbeats. - -This file computes the same integral by a recurrence instead. Clearing denominators with -`D = 2 (n-1) (3+α)`, the quadratic `D * Q` has *integer* coefficients as a polynomial in -`α`: - - `D * Q t = g₀ + g₁ t + g₂ t²`, `g₀ = D`, `g₁ = -2Dc`, `g₂ = DA`, - -so the coefficients of `(D * Q t) ^ k` in `t` satisfy - - `Rec (k+1) j = g₀ * Rec k j + g₁ * Rec k (j-1) + g₂ * Rec k (j-2)`, - -which is just multiplication of the previous row by a fixed quadratic. Integrating term by -term against `t ^ 3` then gives the moment. This replaces `Θ(k²)` summands by `k` steps on -vectors of length `≤ 2k+1`. - -The essential point is that the coefficients are held as *integers*, not as real -expressions: a recurrence carried out symbolically over `ℝ` would grow its terms by a factor -of three per step and reproduce the blow-up in another form. So polynomials in `α` are -represented here by `List ℤ` (dense, lowest degree first) with their own arithmetic, and -`Sendov.pev` is the evaluation homomorphism into `ℝ`. Everything a degree needs is then a -kernel computation on integer data. - -## Main statements - -* `Sendov.pev_padd`, `Sendov.pev_pmul`: evaluation is a ring homomorphism; -* `Sendov.rev_qrow`: `qrow` computes the coefficients of `(g₀ + g₁t + g₂t²) ^ k`; -* `Sendov.integral_irow`: integrating a row against `t ^ (i+3)` gives `irow`; -* `Sendov.integral_moment_rec`: the moment, via the recurrence. --/ - -namespace Sendov - -open MeasureTheory - -/-! ### Integer polynomials in `α`, densely represented, lowest degree first -/ - -/-- Evaluation of a dense integer polynomial at a real point, by Horner's rule. -/ -def pev : List ℤ → ℝ → ℝ - | [], _ => 0 - | a :: p, x => (a : ℝ) + x * pev p x - -/-- Addition of dense integer polynomials. -/ -def padd : List ℤ → List ℤ → List ℤ - | [], q => q - | a :: p, [] => a :: p - | a :: p, b :: q => (a + b) :: padd p q - -/-- Multiplication of dense integer polynomials. -/ -def pmul : List ℤ → List ℤ → List ℤ - | [], _ => [] - | a :: p, q => padd (q.map (fun b => a * b)) (0 :: pmul p q) - -@[simp] lemma pev_nil (x : ℝ) : pev [] x = 0 := rfl - -@[simp] lemma pev_cons (a : ℤ) (p : List ℤ) (x : ℝ) : - pev (a :: p) x = (a : ℝ) + x * pev p x := rfl - -lemma pev_padd (p q : List ℤ) (x : ℝ) : pev (padd p q) x = pev p x + pev q x := by - induction p generalizing q with - | nil => simp [padd] - | cons a p ih => - cases q with - | nil => simp [padd] - | cons b q => - simp only [padd, pev_cons, ih] - push_cast - ring - -lemma pev_map_mul (a : ℤ) (q : List ℤ) (x : ℝ) : - pev (q.map (fun b => a * b)) x = (a : ℝ) * pev q x := by - induction q with - | nil => simp - | cons b q ih => - simp only [List.map_cons, pev_cons, ih] - push_cast - ring - -lemma pev_pmul (p q : List ℤ) (x : ℝ) : pev (pmul p q) x = pev p x * pev q x := by - induction p with - | nil => simp [pmul] - | cons a p ih => - simp only [pmul, pev_padd, pev_map_mul, pev_cons, ih] - push_cast - ring - -/-! ### Rows: polynomials in `t` whose coefficients are polynomials in `α` -/ - -/-- Evaluation of a row at `α` (coefficientwise) and `t` (by Horner's rule). -/ -def rev : List (List ℤ) → ℝ → ℝ → ℝ - | [], _, _ => 0 - | p :: r, α, t => pev p α + t * rev r α t - -/-- Addition of rows. -/ -def radd : List (List ℤ) → List (List ℤ) → List (List ℤ) - | [], s => s - | p :: r, [] => p :: r - | p :: r, q :: s => padd p q :: radd r s - -/-- Multiply every coefficient of a row by a fixed polynomial in `α`. -/ -def rscale (g : List ℤ) (r : List (List ℤ)) : List (List ℤ) := r.map (pmul g) - -@[simp] lemma rev_nil (α t : ℝ) : rev [] α t = 0 := rfl - -@[simp] lemma rev_cons (p : List ℤ) (r : List (List ℤ)) (α t : ℝ) : - rev (p :: r) α t = pev p α + t * rev r α t := rfl - -lemma rev_radd (r s : List (List ℤ)) (α t : ℝ) : - rev (radd r s) α t = rev r α t + rev s α t := by - induction r generalizing s with - | nil => simp [radd] - | cons p r ih => - cases s with - | nil => simp [radd] - | cons q s => - simp only [radd, rev_cons, pev_padd, ih] - ring - -lemma rev_rscale (g : List ℤ) (r : List (List ℤ)) (α t : ℝ) : - rev (rscale g r) α t = pev g α * rev r α t := by - induction r with - | nil => simp [rscale] - | cons p r ih => - change rev (pmul g p :: rscale g r) α t = _ - rw [rev_cons, pev_pmul, ih, rev_cons] - ring - -lemma rev_shift (r : List (List ℤ)) (α t : ℝ) : - rev (([] : List ℤ) :: r) α t = t * rev r α t := by - simp - -/-! ### The recurrence -/ - -/-- One step of the recurrence: multiply a row by `g₀ + g₁ t + g₂ t²`. -/ -def qstep (g₀ g₁ g₂ : List ℤ) (r : List (List ℤ)) : List (List ℤ) := - radd (rscale g₀ r) (radd ([] :: rscale g₁ r) ([] :: [] :: rscale g₂ r)) - -/-- The coefficients of `(g₀ + g₁ t + g₂ t²) ^ k`, as a polynomial in `t` whose -coefficients are integer polynomials in `α`. -/ -def qrow (g₀ g₁ g₂ : List ℤ) : ℕ → List (List ℤ) - | 0 => [[1]] - | k + 1 => qstep g₀ g₁ g₂ (qrow g₀ g₁ g₂ k) - -lemma rev_qrow (g₀ g₁ g₂ : List ℤ) (k : ℕ) (α t : ℝ) : - rev (qrow g₀ g₁ g₂ k) α t = (pev g₀ α + pev g₁ α * t + pev g₂ α * t ^ 2) ^ k := by - induction k with - | zero => simp [qrow] - | succ k ih => - simp only [qrow, qstep, rev_radd, rev_rscale, rev_shift, ih, pow_succ] - ring - -/-! ### Integration -/ - -/-- `irow r i α = ∑ⱼ (coefficient j of r, at α) / (i + j + 4)`, the value of -`∫ t in 0..1, t ^ (i+3) * rev r α t`. -/ -noncomputable def irow : List (List ℤ) → ℕ → ℝ → ℝ - | [], _, _ => 0 - | p :: r, i, α => pev p α / (i + 4) + irow r (i + 1) α - -lemma continuous_rev (r : List (List ℤ)) (α : ℝ) : Continuous fun t : ℝ => rev r α t := by - induction r with - | nil => simpa using continuous_const - | cons p r ih => - simp only [rev_cons] - exact continuous_const.add (continuous_id.mul ih) - -lemma integral_irow (r : List (List ℤ)) (i : ℕ) (α : ℝ) : - (∫ t in (0 : ℝ)..1, t ^ (i + 3) * rev r α t) = irow r i α := by - induction r generalizing i with - | nil => simp [irow] - | cons p r ih => - have hfun : (fun t : ℝ => t ^ (i + 3) * rev (p :: r) α t) - = fun t : ℝ => pev p α * t ^ (i + 3) + t ^ (i + 1 + 3) * rev r α t := by - funext t - simp only [rev_cons] - ring - have h1 : IntervalIntegrable (fun t : ℝ => pev p α * t ^ (i + 3)) volume 0 1 := - (by fun_prop : Continuous fun t : ℝ => pev p α * t ^ (i + 3)).intervalIntegrable _ _ - have h2 : IntervalIntegrable (fun t : ℝ => t ^ (i + 1 + 3) * rev r α t) volume 0 1 := - ((continuous_pow _).mul (continuous_rev r α)).intervalIntegrable _ _ - rw [hfun, intervalIntegral.integral_add h1 h2, intervalIntegral.integral_const_mul, - integral_pow, ih] - simp only [irow] - push_cast - ring - -/-- **The moment, by the recurrence.** If `D * Q t` has the integer coefficient -polynomials `g₀, g₁, g₂` in `α`, then the moment is a kernel computation on those integers. -No hypothesis beyond `D ≠ 0` is needed: this is a polynomial identity. -/ -theorem integral_moment_rec {n k : ℕ} {α D : ℝ} {g₀ g₁ g₂ : List ℤ} (hD : D ≠ 0) - (hQ : ∀ t : ℝ, D * Q n α t = pev g₀ α + pev g₁ α * t + pev g₂ α * t ^ 2) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ k) = irow (qrow g₀ g₁ g₂ k) 0 α / D ^ k := by - have hpow : ∀ t : ℝ, t ^ 3 * Q n α t ^ k - = (t ^ (0 + 3) * rev (qrow g₀ g₁ g₂ k) α t) / D ^ k := by - intro t - rw [rev_qrow, ← hQ t, mul_pow] - field_simp - ring - simp only [hpow] - rw [intervalIntegral.integral_div, integral_irow] - -/-! ### The coefficients for a given degree - -With `D = 2 (n-1) (3+α)` one has `D * Q t = g₀ + g₁ t + g₂ t²` where, as polynomials in `α` -with integer coefficients, - - `g₀ = 6(n-1) + 2(n-1) α`, - `g₁ = -12(n-1) + (12 - 2(n-1)) α + 4 α²`, - `g₂ = 6(n-1) + (2(n-1) - 12) α - 4 α²`. -/ - -/-- `D` itself, as an integer polynomial in `α`. -/ -def gg0 (n : ℕ) : List ℤ := [6 * ((n : ℤ) - 1), 2 * ((n : ℤ) - 1)] - -/-- `-2 D c`, as an integer polynomial in `α`. -/ -def gg1 (n : ℕ) : List ℤ := [-12 * ((n : ℤ) - 1), 12 - 2 * ((n : ℤ) - 1), 4] - -/-- `D A`, as an integer polynomial in `α`. -/ -def gg2 (n : ℕ) : List ℤ := [6 * ((n : ℤ) - 1), 2 * ((n : ℤ) - 1) - 12, -4] - -@[simp] lemma gg0_length (n : ℕ) : (gg0 n).length = 2 := rfl - -@[simp] lemma gg1_length (n : ℕ) : (gg1 n).length = 3 := rfl - -@[simp] lemma gg2_length (n : ℕ) : (gg2 n).length = 3 := rfl - -lemma DQ_eq (n : ℕ) (hn : 2 ≤ n) (α t : ℝ) (hα : 0 ≤ α) : - (2 * M n * (3 + α)) * Q n α t - = pev (gg0 n) α + pev (gg1 n) α * t + pev (gg2 n) α * t ^ 2 := by - have hM : ((n : ℝ) - 1) ≠ 0 := (M_pos hn).ne' - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - simp only [gg0, gg1, gg2, pev_cons, pev_nil, Q, c, A, M] - push_cast - field_simp - ring - -/-- **The moment for a given degree, by the recurrence.** Every ingredient on the right is -a kernel computation on integers, apart from the final evaluation at `α`. -/ -theorem integral_moment_of (n k : ℕ) (hn : 2 ≤ n) (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ k) - = irow (qrow (gg0 n) (gg1 n) (gg2 n) k) 0 α / (2 * M n * (3 + α)) ^ k := by - have hM : 0 < M n := M_pos hn - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - exact integral_moment_rec (n := n) (k := k) (by positivity) (fun t => DQ_eq n hn α t hα) - -end Sendov diff --git a/Sendov/FiniteRange/Reduce.lean b/Sendov/FiniteRange/Reduce.lean deleted file mode 100644 index f97031d..0000000 --- a/Sendov/FiniteRange/Reduce.lean +++ /dev/null @@ -1,88 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Moments -import Sendov.FiniteRange.OddBound - -/-! -# Reduction of a single degree to a numerical inequality - -This file assembles the general machinery. For any degree `n`, proving `R n α < 1` reduces -to a numerical inequality in `α` alone, with no integrals and no square roots left: - -* `Sendov.integral_eq_mom`: if `(n-4)/2` is the natural number `k` (that is, `n` is even), - the integral in `Sendov.R` *equals* `Sendov.mom n α k`; -* `Sendov.integral_le_mom`: if `(n-4)/2 = k + 1/2` (that is, `n` is odd), the integral is at - most `mom n α (k+1) / (2w) + w/2 * mom n α k`, for any `w > 0`; -* `Sendov.finite_range_of_bound`: given any upper bound `J` for the integral, `R n α < 1` - follows from an inequality between explicit rational functions of `α`. - -So each degree of the finite range needs exactly three things: the exponent identity -(`norm_num`), an evaluation of `Sendov.mom` for the relevant `k` (a finite sum, expanded by -`Finset.sum_range_succ`), and a positivity proof for the resulting rational function on -`0 ≤ α ≤ min 17 ((n-1)/2)`, the bound on `α` coming from `Sendov.alpha_le_half_M`. - -`Sendov.mom_one` and `Sendov.mom_two` record the first two evaluations, which also serve as -a check on the general formula. --/ - -namespace Sendov - -open MeasureTheory Finset - -variable {n : ℕ} {α w : ℝ} - -/-- **Even degrees.** The integral in `Sendov.R` is exactly a moment. -/ -lemma integral_eq_mom (k : ℕ) (hk : ((n : ℝ) - 4) / 2 = (k : ℕ)) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ (((n : ℝ) - 4) / 2)) = mom n α k := by - rw [hk] - simp only [Real.rpow_natCast] - exact integral_moment n α k - -/-- **Odd degrees.** After `Sendov.integral_rpow_le` has removed the square root, the -integral in `Sendov.R` is bounded by a combination of two moments. -/ -lemma integral_le_mom (hfeas : c n α ^ 2 ≤ A n α) (k : ℕ) - (hk : ((n : ℝ) - 4) / 2 = (k : ℝ) + 1 / 2) (hw : 0 < w) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ (((n : ℝ) - 4) / 2)) - ≤ mom n α (k + 1) / (2 * w) + w / 2 * mom n α k := by - refine (integral_rpow_le hfeas k hk hw).trans (le_of_eq ?_) - have hfun : (fun t : ℝ => t ^ 3 * (Q n α t ^ k * (Q n α t / (2 * w) + w / 2))) - = fun t : ℝ => 1 / (2 * w) * (t ^ 3 * Q n α t ^ (k + 1)) - + w / 2 * (t ^ 3 * Q n α t ^ k) := by - funext t - rw [pow_succ] - ring - have hi : ∀ j : ℕ, ∀ a : ℝ, - IntervalIntegrable (fun t : ℝ => a * (t ^ 3 * Q n α t ^ j)) volume 0 1 := by - intro j a - exact (by simp only [Q]; fun_prop : - Continuous fun t : ℝ => a * (t ^ 3 * Q n α t ^ j)).intervalIntegrable _ _ - rw [hfun, intervalIntegral.integral_add (hi (k + 1) _) (hi k _), - intervalIntegral.integral_const_mul, intervalIntegral.integral_const_mul, - integral_moment, integral_moment] - ring - -/-- **The reduction.** Any upper bound `J` for the integral turns `R n α < 1` into an -inequality between explicit rational functions of `α`. -/ -theorem finite_range_of_bound (hn : 2 ≤ n) (hα : 0 ≤ α) {J : ℝ} - (hJ : (∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ (((n : ℝ) - 4) / 2)) ≤ J) - (h : 1 / 6 + 1 / (4 * (3 + α)) + 1 / (2 * M n) + 1 / (4 * M n * (3 + α)) - + A n α ^ 2 * n * M n * ((n : ℝ) - 2) / (4 * (3 + α)) * J < 1) : - R n α < 1 := - lt_of_le_of_lt (R_le_of_integral_le hn hα hJ) h - -/-- `∫ t in 0..1, t ^ 3 * Q` -/ -lemma mom_one (n : ℕ) (α : ℝ) : mom n α 1 = 1 / 4 - 2 * c n α / 5 + A n α / 6 := by - simp [mom, Finset.sum_range_succ] - ring - -/-- `∫ t in 0..1, t ^ 3 * Q ^ 2` -/ -lemma mom_two (n : ℕ) (α : ℝ) : - mom n α 2 = 1 / 4 - 4 * c n α / 5 + (2 * c n α ^ 2 / 3 + A n α / 3) - - 4 * c n α * A n α / 7 + A n α ^ 2 / 8 := by - simp [mom, Finset.sum_range_succ] - ring - -end Sendov diff --git a/Sendov/Interior.lean b/Sendov/Interior.lean index 396236d..2055787 100644 --- a/Sendov/Interior.lean +++ b/Sendov/Interior.lean @@ -25,11 +25,11 @@ disk, and `Sendov.exists_root_multiset` writes `p` over the other zeroes `zⱼ`. From `(⋆)` the argument branches on the degree. -* For `n ≥ 5`, AM–GM relaxes `(⋆)` to the raw polar inequality `(1Q)`, the centroid identity and +* For `n ≥ 6`, AM–GM relaxes `(⋆)` to the raw polar inequality `(1Q)`, the centroid identity and the two origin identities give `(origin-exact)`, and `Sendov.polar_origin_incompatible` says the two cannot hold together. * For `n ≤ 5`, `Sendov.low_degree_contradiction` shows `(⋆)` is already contradictory on its own, - with no recourse to the origin channel. The two branches overlap at degree five. + with no recourse to the origin channel. Degree five belongs only to this low-degree branch. The zero `a = 0` is excluded above (the polar identity divides by `a`) but needs none of this machinery: `p'(a)` two ways already says `(∏ⱼ qⱼ)(∏ⱼ (a - zⱼ)) = n`, and at `a = 0` both factors @@ -96,10 +96,9 @@ theorem sendov_interior {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegre (prod_sub_mul_prod (c := p.leadingCoeff) (a := ((a : ℝ) : ℂ)) (n := n) (z := z) (q := q) (p := p) hc0 hq0 hpz hpq') -- the branch: low degree needs nothing further - rcases (by omega : n < 5 ∨ 5 ≤ n) with hn5 | hn5 - · exact low_degree_contradiction hn (by omega) ha0 ha1 hqcard hq1 hstar - have hnR : (5 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn5 - have hn1 : (0 : ℝ) < (n : ℝ) - 1 := by linarith + rcases (by omega : n ≤ 5 ∨ 6 ≤ n) with hn5 | hn6 + · exact low_degree_contradiction hn hn5 ha0 ha1 hqcard hq1 hstar + have hn5 : 5 ≤ n := by omega -- `x + iy` is the centroid of the `qⱼ` obtain ⟨x, y, hxy⟩ : ∃ x y : ℝ, q.sum = ((n : ℂ) - 1) * ((x : ℂ) + (y : ℂ) * I) := by refine ⟨(q.sum / ((n : ℂ) - 1)).re, (q.sum / ((n : ℂ) - 1)).im, ?_⟩ @@ -116,7 +115,7 @@ theorem sendov_interior {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegre have horigin := origin_exact (n := n) (α := M n * (1 - a ^ 2) / 2) hn5 ha0 ha1 hqcard hqne hz1 hq1 hxy hcent hfirst hsecond rfl -- the two are incompatible - exact polar_origin_incompatible hn5 ha0 ha1 (by nlinarith [hx2, sq_nonneg y]) rfl hpolar + exact polar_origin_incompatible hn6 ha0 ha1 (by nlinarith [hx2, sq_nonneg y]) rfl hpolar horigin /-- **The conjecture at `a = 0`.** `p'(a)` two ways gives `(∏ⱼ qⱼ)(∏ⱼ (a - zⱼ)) = n`. At diff --git a/Sendov/LargeDegree/DistillationTail.lean b/Sendov/LargeDegree/DistillationTail.lean new file mode 100644 index 0000000..b6b3803 --- /dev/null +++ b/Sendov/LargeDegree/DistillationTail.lean @@ -0,0 +1,354 @@ +import Sendov.Common.DistillationFactors + +/-! +# Real-degree monotonicity for the regularized distillation components + +New Lean adaptation of Senjian An, *Proof Distillation for Sendov's Conjecture*, +revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, lines 898--950. +Paper: CC BY 4.0, https://creativecommons.org/licenses/by/4.0/ . +The finite degree-81 certificate is a separate obligation. No raw scalar value +at alpha zero is identified with a continuous extension. +-/ + +namespace Sendov + +private lemma slope_mul {f g : ℝ → ℝ} {x u v : ℝ} + (hf : HasDerivAt f (f x * u) x) (hg : HasDerivAt g (g x * v) x) : + HasDerivAt (fun y => f y * g y) ((f x * g x) * (u + v)) x := by + convert! hf.mul hg using 1 + ring + +private lemma slope_div {f g : ℝ → ℝ} {x u v : ℝ} + (hf : HasDerivAt f (f x * u) x) (hg : HasDerivAt g (g x * v) x) + (hg0 : g x ≠ 0) : + HasDerivAt (fun y => f y / g y) ((f x / g x) * (u - v)) x := by + convert! hf.div hg hg0 using 1 + field_simp + +private lemma slope_pow {f : ℝ → ℝ} {x u : ℝ} (n : ℕ) + (hf : HasDerivAt f (f x * u) x) : + HasDerivAt (fun y => f y ^ n) (f x ^ n * (n * u)) x := by + convert! hf.pow n using 1 + cases n with + | zero => simp + | succ n => simp only [Nat.add_sub_cancel, pow_succ, Nat.cast_add, Nat.cast_one]; ring + +private lemma slope_linear (x c : ℝ) (h : x + c ≠ 0) : + HasDerivAt (fun y : ℝ => y + c) ((x + c) * (1 / (x + c))) x := by + convert! (hasDerivAt_id' x).add_const c using 1 + exact mul_one_div_cancel h + +private lemma tail_antitone {f f' : ℝ → ℝ} + (hf : ∀ x : ℝ, 81 ≤ x → HasDerivAt f (f' x) x) + (hn : ∀ x : ℝ, 81 ≤ x → f' x ≤ 0) : AntitoneOn f (Set.Ici 81) := by + apply antitoneOn_of_deriv_nonpos (convex_Ici _) (fun x hx => + (hf x hx).continuousAt.continuousWithinAt) + · exact fun x hx => (hf x (interior_subset hx)).differentiableAt.differentiableWithinAt + · intro x hx + rw [(hf x (interior_subset hx)).deriv] + exact hn x (interior_subset hx) + +lemma distillEBudget_antitone : AntitoneOn distillEBudget (Set.Ici 81) := by + intro m hm n _ hmn + change 81 ≤ m at hm + dsimp only [distillEBudget] + apply add_le_add le_rfl + exact div_le_div_of_nonneg_left (by norm_num) + (by linarith : 0 < 12 * m) (by linarith) + +lemma distillEBudget_le_81 {m : ℝ} (hm : 81 ≤ m) : + distillEBudget m ≤ distillEBudget 81 := + distillEBudget_antitone (by simp) hm hm + +lemma cubicPolarEnvelope_le_five_sixths {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : + cubicPolarEnvelope α ≤ 5 / 6 := by + have h := cubicPolarEnvelope_mono hα hα17 + have h17 : cubicPolarEnvelope 17 = 199087 / 240000 := by + norm_num [cubicPolarEnvelope] + rw [h17] at h + linarith + +lemma distillNode_antitone_degree {α : ℝ} (hα : 0 ≤ α) : + AntitoneOn (fun m => distillNode m α) (Set.Ici 81) := by + intro m hm n _ hmn + change 81 ≤ m at hm + dsimp only [distillNode] + apply add_le_add le_rfl + exact div_le_div_of_nonneg_left (by positivity : 0 ≤ 12 * α) + (by linarith : 0 < 25 * m) (by linarith) + +lemma distillNode_lt_four_fifths {m α : ℝ} (hm : 81 ≤ m) + (hα : 0 ≤ α) (hα17 : α ≤ 17) : distillNode m α < 4 / 5 := by + have he := cubicPolarEnvelope_le_five_sixths hα hα17 + have ht : 12 * α / (25 * m) ≤ 68 / 675 := by + apply (div_le_iff₀ (by linarith : 0 < 25 * m)).mpr + linarith + unfold distillNode + linarith + +private lemma kappa_slope {m α : ℝ} (hm : 81 ≤ m) (hα17 : α ≤ 17) : + HasDerivAt (fun x => distillKappa x α) + (distillKappa m α * (1 / (m - 1) + 1 / (m + 1) - 1 / m + + 2 / (m - 2 * α))) m := by + have hm0 : m ≠ 0 := by linarith + have hm1 : m - 1 ≠ 0 := by linarith + have hmp1 : m + 1 ≠ 0 := by linarith + have hma : m - 2 * α ≠ 0 := by linarith + have h1 := slope_linear m (-1) (by linarith) + have h2 := slope_linear m 1 hmp1 + have h3 := slope_linear m 0 (by simpa using hm0) + have h4 := slope_pow 2 (slope_linear m (-2 * α) (by linarith)) + have hc := hasDerivAt_const m (distillRatio α / 4) + have hc' : HasDerivAt (fun _ : ℝ => distillRatio α / 4) + (distillRatio α / 4 * 0) m := by simpa using hc + convert! slope_mul (slope_mul (slope_div (slope_mul h1 h2) h3 + (by simpa using hm0)) hc') h4 using 1 + · funext x + dsimp [distillKappa] + ring + · dsimp [distillKappa] + ring + +private lemma kappa_slope_le {m α : ℝ} (hm : 81 ≤ m) (hα17 : α ≤ 17) : + 1 / (m - 1) + 1 / (m + 1) - 1 / m + 2 / (m - 2 * α) ≤ + 1 / 80 + 2 / 47 := by + have h1 : 1 / (m - 1) ≤ 1 / (80 : ℝ) := + div_le_div_of_nonneg_left (by norm_num) (by norm_num) (by linarith) + have h2 : 1 / (m + 1) ≤ 1 / m := + div_le_div_of_nonneg_left (by norm_num) (by linarith) (by linarith) + have h3 : 2 / (m - 2 * α) ≤ 2 / (47 : ℝ) := + div_le_div_of_nonneg_left (by norm_num) (by norm_num) (by linarith) + linarith + +private lemma kappa_rpow_antitone {α z : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) + (hz : 0 ≤ z) (hz1 : z ≤ 5 / 6) : + AntitoneOn (fun m => distillKappa m α * z ^ ((m - 3) / 2)) (Set.Ici 81) := by + rcases hz.eq_or_lt with rfl | hz + · intro m hm n hn _ + have hm' : (m - 3) / 2 ≠ 0 := by change 81 ≤ m at hm; linarith + have hn' : (n - 3) / 2 ≠ 0 := by change 81 ≤ n at hn; linarith + simp only [Real.zero_rpow hm', Real.zero_rpow hn', mul_zero, le_refl] + have hp (m : ℝ) : HasDerivAt (fun x : ℝ => z ^ ((x - 3) / 2)) + (z ^ ((m - 3) / 2) * (Real.log z / 2)) m := by + convert! (hasDerivAt_const m z).rpow + (((hasDerivAt_id' m).sub_const 3).div_const 2) hz using 1 + ring + apply tail_antitone (fun m hm => slope_mul (kappa_slope hm hα17) (hp m)) + intro m hm + apply mul_nonpos_of_nonneg_of_nonpos + · exact mul_nonneg (distillKappa_nonneg (by linarith) hα) (Real.rpow_nonneg hz.le _) + · have hk := kappa_slope_le hm hα17 + have hl := Real.log_le_sub_one_of_pos hz + linarith + +/-- Real-degree antitonicity; the node itself also decreases with the degree. -/ +lemma distillT1_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : + AntitoneOn (fun m => distillT1 m α) (Set.Ici 81) := by + intro m hm n hn hmn + have hm' : 81 ≤ m := hm + have hn' : 81 ≤ n := hn + have hz := distillNode_pos (by linarith : 0 < m) hα + have hz1 : distillNode m α ≤ 5 / 6 := by + have := distillNode_lt_four_fifths hm' hα hα17 + linarith + have hpow := Real.rpow_le_rpow (distillNode_pos (by linarith : 0 < n) hα).le + (distillNode_antitone_degree hα hm hn hmn) (by linarith : 0 ≤ (n - 3) / 2) + have hstep := (mul_le_mul_of_nonneg_left hpow + (distillKappa_nonneg (by linarith) hα)).trans + (kappa_rpow_antitone hα hα17 hz.le hz1 hm hn hmn) + have := mul_le_mul_of_nonneg_left hstep (by norm_num : (0 : ℝ) ≤ 259 / 3125) + simpa only [distillT1, mul_assoc] using this + +/-- The zero-alpha case is included by the zero-base real-power case. -/ +lemma distillT2_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : + AntitoneOn (fun m => distillT2 m α) (Set.Ici 81) := by + intro m hm n hn hmn + have hstep := kappa_rpow_antitone hα hα17 (cubicPolarEnvelope_nonneg hα) + (cubicPolarEnvelope_le_five_sixths hα hα17) hm hn hmn + have := mul_le_mul_of_nonneg_left hstep (by norm_num : (0 : ℝ) ≤ 421 / 3125) + simpa only [distillT2, mul_assoc] using this + +lemma distillT1_le_81 {m α : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : + distillT1 m α ≤ distillT1 81 α := + distillT1_antitone hα hα17 (by simp) hm hm + +lemma distillT2_le_81 {m α : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : + distillT2 m α ≤ distillT2 81 α := + distillT2_antitone hα hα17 (by simp) hm hm + +lemma distillT2_zero {m : ℝ} (hm : 81 ≤ m) : distillT2 m 0 = 0 := by + have hs : (m - 3) / 2 ≠ 0 := by linarith + simp [distillT2, cubicPolarEnvelope, Real.zero_rpow hs] + +/-- Exact positive tail certificate from the paper, valid for real degree. -/ +lemma distillTail_polynomial_pos {m : ℝ} (hm : 81 ≤ m) : + 0 < 7 * m ^ 4 - 510 * m ^ 3 - 4049 * m ^ 2 - 35462 * m - 104040 := by + have hx : 0 ≤ m - 81 := by linarith + have hid : 7 * m ^ 4 - 510 * m ^ 3 - 4049 * m ^ 2 - 35462 * m - 104040 = + 7 * (m - 81) ^ 4 + 1758 * (m - 81) ^ 3 + 147583 * (m - 81) ^ 2 + + 4150618 * (m - 81) + 750186 := by ring + rw [hid] + positivity + +private def tailP (m α : ℝ) : ℝ := + 7 * m ^ 4 - 30 * α * m ^ 3 - (8 * α ^ 2 + 96 * α + 105) * m ^ 2 + + (90 * α - 128 * α ^ 2) * m - 360 * α ^ 2 + +private lemma tailP_pos {m α : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : + 0 < tailP m α := by + have hm0 : 0 ≤ m := by linarith + have hgap : 0 ≤ 17 - α := by linarith + have hid : tailP m α = + (7 * m ^ 4 - 510 * m ^ 3 - 4049 * m ^ 2 - 35462 * m - 104040) + + (17 - α) * (α * (8 * m ^ 2 + 128 * m + 360) + + 30 * m ^ 3 + 232 * m ^ 2 + 2086 * m + 6120) := by + dsimp [tailP] + ring + rw [hid] + exact add_pos_of_pos_of_nonneg (distillTail_polynomial_pos hm) (by positivity) + +private noncomputable def tailQ (m α d : ℝ) : ℝ := + d * tailP m α / 7 + (21 / 25 - d) * (4 * α / 7) * + ((3 * m - 2 * α) * m ^ 2 + 32 * (m - α) * m + (75 * m - 90 * α)) + +private lemma tailQ_pos {m α d : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) + (hα17 : α ≤ 17) (hd : 0 < d) (hd1 : d ≤ 21 / 25) : 0 < tailQ m α d := by + have hm0 : 0 ≤ m := by linarith + have h1 : 0 ≤ 3 * m - 2 * α := by linarith + have h2 : 0 ≤ m - α := by linarith + have h3 : 0 ≤ 75 * m - 90 * α := by linarith + have h4 : 0 ≤ 21 / 25 - d := by linarith + unfold tailQ + exact add_pos_of_pos_of_nonneg (div_pos (mul_pos hd (tailP_pos hm hα hα17)) + (by norm_num)) (by positivity) + +private noncomputable def tailRational (m α d : ℝ) : ℝ := + m ^ 3 * (m - 2 * α) ^ 2 / ((m + 3) * (m + 5) * (d * m - 12 * α / 25) ^ 4) + +private lemma tail_den_pos {m α d : ℝ} (hm : 81 ≤ m) (hα17 : α ≤ 17) + (hd : 17 / 50 ≤ d) : 0 < d * m - 12 * α / 25 := by + have hm0 : 0 ≤ m := by linarith + have hd0 : 0 ≤ d - 17 / 50 := by linarith + nlinarith [mul_nonneg hd0 hm0] + +private lemma rational_slope {m α d : ℝ} (hm : 81 ≤ m) (hα17 : α ≤ 17) + (hd : 17 / 50 ≤ d) : + HasDerivAt (fun x => tailRational x α d) + (tailRational m α d * (3 / m + 2 / (m - 2 * α) - 1 / (m + 3) - + 1 / (m + 5) - 4 * d / (d * m - 12 * α / 25))) m := by + have hm0 : m ≠ 0 := by linarith + have hma : m - 2 * α ≠ 0 := by linarith + have hm3 : m + 3 ≠ 0 := by linarith + have hm5 : m + 5 ≠ 0 := by linarith + have hc : d * m - 12 * α / 25 ≠ 0 := (tail_den_pos hm hα17 hd).ne' + have h1 := slope_pow 3 (slope_linear m 0 (by simpa using hm0)) + have h2 := slope_pow 2 (slope_linear m (-2 * α) (by linarith)) + have h3 := slope_linear m 3 hm3 + have h5 := slope_linear m 5 hm5 + have hd' : HasDerivAt (fun x : ℝ => d * x - 12 * α / 25) + ((d * m - 12 * α / 25) * (d / (d * m - 12 * α / 25))) m := by + convert! ((hasDerivAt_id' m).const_mul d).sub_const (12 * α / 25) using 1 + simp [← mul_div_assoc, hc] + have hden := slope_mul (slope_mul h3 h5) (slope_pow 4 hd') + convert! slope_div (slope_mul h1 h2) hden + (mul_ne_zero (mul_ne_zero hm3 hm5) (pow_ne_zero 4 hc)) using 1 + · funext x + dsimp [tailRational] + ring + · dsimp [tailRational] + ring + +private lemma rational_slope_neg {m α d : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) + (hα17 : α ≤ 17) (hd : 17 / 50 ≤ d) (hd1 : d ≤ 21 / 25) : + 3 / m + 2 / (m - 2 * α) - 1 / (m + 3) - 1 / (m + 5) - + 4 * d / (d * m - 12 * α / 25) < 0 := by + have hm0 : 0 < m := by linarith + have hma : 0 < m - 2 * α := by linarith + have hm3 : 0 < m + 3 := by linarith + have hm5 : 0 < m + 5 := by linarith + have hc := tail_den_pos hm hα17 hd + have hid : 3 / m + 2 / (m - 2 * α) - 1 / (m + 3) - 1 / (m + 5) - + 4 * d / (d * m - 12 * α / 25) = + -tailQ m α d / (m * (m - 2 * α) * (m + 3) * (m + 5) * + (d * m - 12 * α / 25)) := by + generalize hdef : d * m - 12 * α / 25 = c at * + field_simp + rw [← hdef] + dsimp [tailQ, tailP] + ring + rw [hid] + exact div_neg_of_neg_of_pos (neg_neg_of_pos (tailQ_pos hm hα hα17 (by linarith) hd1)) + (by positivity) + +private lemma tailRational_antitone {α d : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) + (hd : 17 / 50 ≤ d) (hd1 : d ≤ 21 / 25) : + AntitoneOn (fun m => tailRational m α d) (Set.Ici 81) := by + apply tail_antitone (fun m hm => rational_slope hm hα17 hd) + intro m hm + have hm0 : 0 ≤ m := by linarith + have hm3 : 0 ≤ m + 3 := by linarith + have hm5 : 0 ≤ m + 5 := by linarith + exact mul_nonpos_of_nonneg_of_nonpos (by unfold tailRational; positivity) + (rational_slope_neg hm hα hα17 hd hd1).le + +private lemma distillT0_eq_rational {m α : ℝ} (hm : 81 ≤ m) + (hα : 0 ≤ α) (hα17 : α ≤ 17) : + distillT0 m α = (24 * (3 / 5) ^ 4 * distillRatio α) * + tailRational m α (21 / 25 - 3 / 5 * cubicPolarEnvelope α) := by + have hm0 : m ≠ 0 := by linarith + have hm1 : m - 1 ≠ 0 := by linarith + have hmp1 : m + 1 ≠ 0 := by linarith + have hm3 : m + 3 ≠ 0 := by linarith + have hm5 : m + 5 ≠ 0 := by linarith + have hn : 1 - distillNode m α ≠ 0 := by + have := distillNode_lt_four_fifths hm hα hα17 + linarith + have hc : (21 / 25 - 3 / 5 * cubicPolarEnvelope α) * m - 12 * α / 25 ≠ 0 := by + apply (tail_den_pos hm hα17 _).ne' + have := cubicPolarEnvelope_le_five_sixths hα hα17 + linarith + unfold distillT0 distillKappa tailRational + have hnode : 1 - distillNode m α = + ((21 / 25 - 3 / 5 * cubicPolarEnvelope α) * m - 12 * α / 25) / m := by + unfold distillNode + field_simp + ring + rw [hnode] + field_simp + ring + +/-- Real-degree antitonicity of the regularized rational component, including alpha zero. -/ +lemma distillT0_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : + AntitoneOn (fun m => distillT0 m α) (Set.Ici 81) := by + have he := cubicPolarEnvelope_nonneg hα + have he1 := cubicPolarEnvelope_le_five_sixths hα hα17 + have hd : 17 / 50 ≤ 21 / 25 - 3 / 5 * cubicPolarEnvelope α := by linarith + have hd1 : 21 / 25 - 3 / 5 * cubicPolarEnvelope α ≤ 21 / 25 := by linarith + intro m hm n hn hmn + change distillT0 n α ≤ distillT0 m α + rw [distillT0_eq_rational hn hα hα17, distillT0_eq_rational hm hα hα17] + exact mul_le_mul_of_nonneg_left (tailRational_antitone hα hα17 hd hd1 hm hn hmn) + (mul_nonneg (by norm_num) (distillRatio_nonneg hα)) + +lemma distillT0_le_81 {m α : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : + distillT0 m α ≤ distillT0 81 α := + distillT0_antitone hα hα17 (by simp) hm hm + +/-- Pointwise degree-81 reduction. This is not a certificate for the degree-81 base. -/ +lemma distillComponents_le_81 {m α : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α ≤ + distillEBudget 81 + distillT0 81 α + distillT1 81 α + distillT2 81 α := by + exact add_le_add (add_le_add (add_le_add (distillEBudget_le_81 hm) + (distillT0_le_81 hm hα hα17)) (distillT1_le_81 hm hα hα17)) + (distillT2_le_81 hm hα hα17) + +/-- The finite worker supplies the only extra hypothesis: the global degree-81 base. +No monotonicity or infinite-tail assertion is assumed. -/ +theorem distillComponents_lt_two_thirds_of_base + (hbase : ∀ α : ℝ, 0 ≤ α → α ≤ 17 → + distillEBudget 81 + distillT0 81 α + distillT1 81 α + distillT2 81 α < 2 / 3) + {m α : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 2 / 3 := + (distillComponents_le_81 hm hα hα17).trans_lt (hbase α hα hα17) + +end Sendov diff --git a/Sendov/LargeDegree/DistillationTailBound.lean b/Sendov/LargeDegree/DistillationTailBound.lean new file mode 100644 index 0000000..28f865a --- /dev/null +++ b/Sendov/LargeDegree/DistillationTailBound.lean @@ -0,0 +1,36 @@ +import Sendov.Common.DistillationMajorant +import Sendov.LargeDegree.DistillationTail +import Sendov.DistillationFinite.Row81 + +/-! +# The proved infinite tail + +The critical-point certificate at `m = 81` closes the base required by the +real-degree antitonicity argument. No finite base or monotonicity is assumed. +The degree convention is `m = n - 1`: this tail starts at polynomial degree 82. +The underlying mathematical route is Senjian An's *Proof Distillation for Sendov's +Conjecture*, revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, Sections 7--8 +(CC BY 4.0, https://creativecommons.org/licenses/by/4.0/). +-/ + +namespace Sendov + +/-- The regularized four-component bound is strictly below two thirds for every +real `m ≥ 81`, including alpha zero. The base is the actual critical certificate. -/ +theorem distillComponents_lt_two_thirds {m α : ℝ} (hm : 81 ≤ m) + (hα : 0 ≤ α) (h17 : α ≤ 17) : + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 2 / 3 := by + exact distillComponents_lt_two_thirds_of_base + (fun _ h0 hmax => distillFiniteTailBase h0 hmax) hm hα h17 + +/-- The raw scalar obstruction is bounded on the positive-alpha domain used by +actual polynomial data. This does not redefine its zero value by continuity. -/ +theorem distillScalar_lt_two_thirds {m α : ℝ} (hm : 81 ≤ m) + (hα : 0 < α) (h17 : α ≤ 17) : + scalarObstruction m α (cubicPolarEnvelope α) < 2 / 3 := by + have hm5 : 5 ≤ m := by linarith + have hαm : 2 * α ≤ m := by linarith + exact (distillScalar_le_majorant hm5 hα hαm).trans_lt + (distillComponents_lt_two_thirds hm hα.le h17) + +end Sendov diff --git a/Sendov/LargeDegree/Endgame.lean b/Sendov/LargeDegree/Endgame.lean deleted file mode 100644 index 864071f..0000000 --- a/Sendov/LargeDegree/Endgame.lean +++ /dev/null @@ -1,150 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.LargeDegree.Monotone -import Sendov.Common.BernsteinCert -import Sendov.Common.BernsteinRing - -/-! -# The large-degree claim - -`Sendov.U_le_Ut` removed the degree from the bound; what is left is the single inequality -`Ut α < 1` on `0 ≤ α ≤ 17`, and then `R n α < 1` for every `n ≥ 101`. - -`Ut` is a rational function of `α` times `(α/(3+α)) ^ 48`, so multiplying by - - `D = 865200 · (3+α) ^ 49 · γ ^ 4`, `γ = 300 + 47α - α²`, - -which is positive on `[0,17]`, turns the claim into positivity of the single polynomial -`F = D (1 - Ut)` of degree `58`. The two closed forms used are - - `c 101 α = γ / (100 (3+α))`, - `T1 101 α = 1600000 (100-2α)² (3+α)³ / (721 γ⁴)`. - -A Bernstein certificate on `[0,17]` settles it: all 59 coefficients of `F` in the basis -`α^m (17-α)^(58-m)` are positive, so no subdivision of the `α`-range is needed. (The -informal write-up splits at `α = 16` and estimates the two pieces separately; that is not -necessary once the sharp Beta constant is used, which is what leaves the margin — `Ut` peaks -at `α = 17` with value `0.9229`.) - -## Why the multiplication is distributed by hand - -`D (1 - Ut)` must not be handed to `field_simp`: it would clear `(3+α) ^ 49` and `γ ⁴` from -both sides at once, leaving `ring` a degree-115 identity that it does not close. `D` already -*contains* exactly those denominators, so each of the six terms of `Ut` cancels against it -separately. Doing that first (`Sendov.Ut_lt_one`, steps `t1`–`t6`, and `h48` for the `48`-th -power) keeps every `ring` call at degree at most `62`, which is the same size as the -certificate identity itself. `865200` rather than `865200` is used as the multiplier so that -each term separately, not merely their sum, comes out with integer coefficients. - -## Main statements - -* `Sendov.Ut_lt_one`: `Ut α < 1` on `0 ≤ α ≤ 17`; -* `Sendov.large_degree`: `R n α < 1` for `n ≥ 101`. --/ - -namespace Sendov - -variable {α : ℝ} - -set_option maxHeartbeats 4000000 in --- a degree-58 identity in one variable; `ring` needs more than the default budget -/-- The Bernstein certificate: `F` is positive on `[0,17]`. -/ -lemma F_pos (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < 1122702787291394736448332031899900000000 + 19046325083555631071589567727384404000000 * α + 158421799401305511319831453323336122340000 * α ^ 2 + 861086144839783899262522290902928965732400 * α ^ 3 + 3439408019860839882261371580238947745811319 * α ^ 4 + 10763976190978343059270128976319908699279230 * α ^ 5 + 27482264870203746404049226779511973140100922 * α ^ 6 + 58851751350273881387953189525455032864879976 * α ^ 7 + 107855247587877306122230293103712405510570475 * α ^ 8 + 171759728691636266490365540891679381811794330 * α ^ 9 + 240529488382582584529650966973246412375404200 * α ^ 10 + 299026713527922503750214218383542861883052640 * α ^ 11 + 332584383792637363818110693156644176263245770 * α ^ 12 + 333049929303875184857821696251322094451555300 * α ^ 13 + 301880762905153988961008260011013859110924020 * α ^ 14 + 248778383542817950458457719347804130388393200 * α ^ 15 + 187098708657492312991354787006951375606496810 * α ^ 16 + 128821377534531366266108990532541378516293180 * α ^ 17 + 81419630849957631346647265524754482691775400 * α ^ 18 + 47345231058420765609063602657623737762737040 * α ^ 19 + 25377634631717199993415818405387727249820325 * α ^ 20 + 12558381461678887884336588690871882873720170 * α ^ 21 + 5744808624780589326694261819822529221060710 * α ^ 22 + 2431706095253331452737540626239749451182200 * α ^ 23 + 953157993950838580367703259303917955151865 * α ^ 24 + 346144642670223976596034179062502690180750 * α ^ 25 + 116495518414609472010567246197077176778320 * α ^ 26 + 36336281152740288609221052030650841399360 * α ^ 27 + 10502010275079971287850469706276099760700 * α ^ 28 + 2811408048396859598615803016678577566616 * α ^ 29 + 696637045577195749563697260889295071320 * α ^ 30 + 159631247175312590035611267009797954208 * α ^ 31 + 33785522480785269776966858820750983964 * α ^ 32 + 6594450665275339854415586104207300200 * α ^ 33 + 1184779969344702509178802875319571760 * α ^ 34 + 195478905533580848831244517654808400 * α ^ 35 + 29535092351319878473338799170306705 * α ^ 36 + 4072478636506932555839271140088690 * α ^ 37 + 510306927013451786184096375133350 * α ^ 38 + 57808428584128470185954723726040 * α ^ 39 + 5881482509330352987406470588525 * α ^ 40 + 532894392271418064251604942870 * α ^ 41 + 42515012647728027357611076360 * α ^ 42 + 2939585612233076406278632800 * α ^ 43 + 171946491190832176774496730 * α ^ 44 + 8163588014241841361016900 * α ^ 45 + 287999399301298111575540 * α ^ 46 + 5555726484083859953520 * α ^ 47 - 536551383276446293350 * α ^ 48 - 269167118332858968420 * α ^ 49 - 48279425158933803000 * α ^ 50 - 1759012112154436560 * α ^ 51 + 273395914772406495 * α ^ 52 + 6240162359537050 * α ^ 53 - 1129204084343291 * α ^ 54 + 41554143448524 * α ^ 55 - 721404477395 * α ^ 56 + 6229533730 * α ^ 57 - 21627837 * α ^ 58 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ 58 * (1122702787291394736448332031899900000000 + 19046325083555631071589567727384404000000 * α + 158421799401305511319831453323336122340000 * α ^ 2 + 861086144839783899262522290902928965732400 * α ^ 3 + 3439408019860839882261371580238947745811319 * α ^ 4 + 10763976190978343059270128976319908699279230 * α ^ 5 + 27482264870203746404049226779511973140100922 * α ^ 6 + 58851751350273881387953189525455032864879976 * α ^ 7 + 107855247587877306122230293103712405510570475 * α ^ 8 + 171759728691636266490365540891679381811794330 * α ^ 9 + 240529488382582584529650966973246412375404200 * α ^ 10 + 299026713527922503750214218383542861883052640 * α ^ 11 + 332584383792637363818110693156644176263245770 * α ^ 12 + 333049929303875184857821696251322094451555300 * α ^ 13 + 301880762905153988961008260011013859110924020 * α ^ 14 + 248778383542817950458457719347804130388393200 * α ^ 15 + 187098708657492312991354787006951375606496810 * α ^ 16 + 128821377534531366266108990532541378516293180 * α ^ 17 + 81419630849957631346647265524754482691775400 * α ^ 18 + 47345231058420765609063602657623737762737040 * α ^ 19 + 25377634631717199993415818405387727249820325 * α ^ 20 + 12558381461678887884336588690871882873720170 * α ^ 21 + 5744808624780589326694261819822529221060710 * α ^ 22 + 2431706095253331452737540626239749451182200 * α ^ 23 + 953157993950838580367703259303917955151865 * α ^ 24 + 346144642670223976596034179062502690180750 * α ^ 25 + 116495518414609472010567246197077176778320 * α ^ 26 + 36336281152740288609221052030650841399360 * α ^ 27 + 10502010275079971287850469706276099760700 * α ^ 28 + 2811408048396859598615803016678577566616 * α ^ 29 + 696637045577195749563697260889295071320 * α ^ 30 + 159631247175312590035611267009797954208 * α ^ 31 + 33785522480785269776966858820750983964 * α ^ 32 + 6594450665275339854415586104207300200 * α ^ 33 + 1184779969344702509178802875319571760 * α ^ 34 + 195478905533580848831244517654808400 * α ^ 35 + 29535092351319878473338799170306705 * α ^ 36 + 4072478636506932555839271140088690 * α ^ 37 + 510306927013451786184096375133350 * α ^ 38 + 57808428584128470185954723726040 * α ^ 39 + 5881482509330352987406470588525 * α ^ 40 + 532894392271418064251604942870 * α ^ 41 + 42515012647728027357611076360 * α ^ 42 + 2939585612233076406278632800 * α ^ 43 + 171946491190832176774496730 * α ^ 44 + 8163588014241841361016900 * α ^ 45 + 287999399301298111575540 * α ^ 46 + 5555726484083859953520 * α ^ 47 - 536551383276446293350 * α ^ 48 - 269167118332858968420 * α ^ 49 - 48279425158933803000 * α ^ 50 - 1759012112154436560 * α ^ 51 + 273395914772406495 * α ^ 52 + 6240162359537050 * α ^ 53 - 1129204084343291 * α ^ 54 + 41554143448524 * α ^ 55 - 721404477395 * α ^ 56 + 6229533730 * α ^ 57 - 21627837 * α ^ 58) = 1122702787291394736448332031899900000000 * (17 - α) ^ 58 + 388904288083346622931025909215729068000000 * α ^ 1 * (17 - α) ^ 57 + 66095616740335374779150673987010161532260000 * α ^ 2 * (17 - α) ^ 56 + 7345821640480281350499142140546658776321841200 * α ^ 3 * (17 - α) ^ 55 + 600398748030850807066041679815685800572608040199 * α ^ 4 * (17 - α) ^ 54 + 38479987967757849353019399973163199134827376858856 * α ^ 5 * (17 - α) ^ 53 + 2013648131786096177205150562840212460891734276215217 * α ^ 6 * (17 - α) ^ 52 + 88459088337848664272764574750756035751708812314589560 * α ^ 7 * (17 - α) ^ 51 + 3328752627388631431253304215842302161184427248710824200 * α ^ 8 * (17 - α) ^ 50 + 108955148579598077254581984889507974501857717600550300000 * α ^ 9 * (17 - α) ^ 49 + 3139320986827193043298955183356728835782414071606732250000 * α ^ 10 * (17 - α) ^ 48 + 80389849002074687648105368735226451202772917094058768000000 * α ^ 11 * (17 - α) ^ 47 + 1843869779817877110104286469976591396926664444962705440000000 * α ^ 12 * (17 - α) ^ 46 + 38126021284745149595963616317393007484187425284263404800000000 * α ^ 13 * (17 - α) ^ 45 + 714519722771974812940511821448225512188719319523829280000000000 * α ^ 14 * (17 - α) ^ 44 + 12192162072496626088921760868440507818256588279501222400000000000 * α ^ 15 * (17 - α) ^ 43 + 190149195298252798424521646382266997826378949113808102400000000000 * α ^ 16 * (17 - α) ^ 42 + 2719453325782140875058402865898661993411332371079473152000000000000 * α ^ 17 * (17 - α) ^ 41 + 35765156781668343145270939254204039481078844597447447040000000000000 * α ^ 18 * (17 - α) ^ 40 + 433581369383490123337920330591320005197369743601113088000000000000000 * α ^ 19 * (17 - α) ^ 39 + 4855120840322429070915669670313005676027625016591872000000000000000000 * α ^ 20 * (17 - α) ^ 38 + 50303800927352895844904371767120477621293024508175810560000000000000000 * α ^ 21 * (17 - α) ^ 37 + 482953904720497092819809519030958414936076990756461772800000000000000000 * α ^ 22 * (17 - α) ^ 36 + 4301697515309799266557277840727716853246295229412212736000000000000000000 * α ^ 23 * (17 - α) ^ 35 + 35582005974740842580199098139010545771216816653126860800000000000000000000 * α ^ 24 * (17 - α) ^ 34 + 273535549248031302586908863638264651412739231630163968000000000000000000000 * α ^ 25 * (17 - α) ^ 33 + 1955426273644204648009173651834541693843095232637140992000000000000000000000 * α ^ 26 * (17 - α) ^ 32 + 13004222926412994888311248631808734105341900865415413760000000000000000000000 * α ^ 27 * (17 - α) ^ 31 + 80470387643773112884644249468688475191473557588882227200000000000000000000000 * α ^ 28 * (17 - α) ^ 30 + 463355476918012102672652719197790300193712035699097600000000000000000000000000 * α ^ 29 * (17 - α) ^ 29 + 2482344082055683113128185595725000998635940934141870080000000000000000000000000 * α ^ 30 * (17 - α) ^ 28 + 12369353793584370842106405783534323328114720329863004160000000000000000000000000 * α ^ 31 * (17 - α) ^ 27 + 57300834405504520484711032055319485636127102860053708800000000000000000000000000 * α ^ 32 * (17 - α) ^ 26 + 246613403330189144932245957910378250136137902552252416000000000000000000000000000 * α ^ 33 * (17 - α) ^ 25 + 985246695411671462829426238732411673050896371023872000000000000000000000000000000 * α ^ 34 * (17 - α) ^ 24 + 3649974776445129628396257437653948413551102593597440000000000000000000000000000000 * α ^ 35 * (17 - α) ^ 23 + 12522828085409243337307923676013931236910302987550720000000000000000000000000000000 * α ^ 36 * (17 - α) ^ 22 + 39731340789062838384502107867195079108983927708057600000000000000000000000000000000 * α ^ 37 * (17 - α) ^ 21 + 116365100653574128528674694068315721419971773857792000000000000000000000000000000000 * α ^ 38 * (17 - α) ^ 20 + 313971050757264181615490913824916376724876505907200000000000000000000000000000000000 * α ^ 39 * (17 - α) ^ 19 + 778602881203434272472350446775468799876667539456000000000000000000000000000000000000 * α ^ 40 * (17 - α) ^ 18 + 1769823234178269115425193251412793044953817153536000000000000000000000000000000000000 * α ^ 41 * (17 - α) ^ 17 + 3676061908648613727975384722760757591726652129280000000000000000000000000000000000000 * α ^ 42 * (17 - α) ^ 16 + 6952202666310032877475473290777345311129573785600000000000000000000000000000000000000 * α ^ 43 * (17 - α) ^ 15 + 11922241592723733002313059523572394705939333120000000000000000000000000000000000000000 * α ^ 44 * (17 - α) ^ 14 + 18450845478651168634684539530259247984017408000000000000000000000000000000000000000000 * α ^ 45 * (17 - α) ^ 13 + 25626302281194153741004424813630605199042150400000000000000000000000000000000000000000 * α ^ 46 * (17 - α) ^ 12 + 31735356381499745521943376637135285074788352000000000000000000000000000000000000000000 * α ^ 47 * (17 - α) ^ 11 + 34773986078859125604170241648646078618789153800477215677912265790935664780750000000000 * α ^ 48 * (17 - α) ^ 10 + 33406510810664082686608872230111026353099051641531587806834322064288344554180000000000 * α ^ 49 * (17 - α) ^ 9 + 27820946523539616021999756980494999341031737804699133246948994617042670678045550000000 * α ^ 50 * (17 - α) ^ 8 + 19791944456596303161181417657916215477628661862047060146272089595047078222827061000000 * α ^ 51 * (17 - α) ^ 7 + 11779484527176566489160923853925282151874607361320815965499241151163816336970531507500 * α ^ 52 * (17 - α) ^ 6 + 5685451710206041407628952698706724254113808400301600724661558108213464738446593549500 * α ^ 53 * (17 - α) ^ 5 + 2124220422337628714954562682925792634155465583908214661397004639843167881489238854787 * α ^ 54 * (17 - α) ^ 4 + 572909076732572616057605734230328840239193993814061157407956440967916397115623518120 * α ^ 55 * (17 - α) ^ 3 + 99530623246032452139763064572679576747235355843313027086842616874975359183988464200 * α ^ 56 * (17 - α) ^ 2 + 8820861539641882551843091227900257872626927159038875775406157756108783934565132000 * α ^ 57 * (17 - α) ^ 1 + 161598081294237579548393327166198311182821276785721838823669379905701080186270000 * α ^ 58 := by - bernstein_ring α (17 - α) - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 4000000 in -/-- **The bound in `α` alone is below `1`.** -/ -theorem Ut_lt_one (hα : 0 ≤ α) (hα' : α ≤ 17) : Ut α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hg : (0 : ℝ) < 300 + 47 * α - α ^ 2 := by nlinarith - have hgne : (300 : ℝ) + 47 * α - α ^ 2 ≠ 0 := hg.ne' - have hc : c 101 α = (300 + 47 * α - α ^ 2) / (100 * (3 + α)) := by - simp only [c, M] - norm_num - field_simp - ring - have hT1 : T1 101 α - = 1600000 * (100 - 2 * α) ^ 2 * (3 + α) ^ 3 / (721 * (300 + 47 * α - α ^ 2) ^ 4) := by - simp only [T1, hc] - norm_num - field_simp - ring - -- `(α/(3+α)) ^ 48` cancels against `(3+α) ^ 49` without expanding either - have h48 : (α / (3 + α)) ^ 48 * (3 + α) ^ 49 = α ^ 48 * (3 + α) := by - rw [div_pow, pow_succ (3 + α) 48, ← mul_assoc, - div_mul_cancel₀ _ (pow_ne_zero 48 h3.ne')] - -- The six terms of `Ut`, each multiplied by `D`. Composite powers are kept - -- as scalar factors: cancel denominators first, then normalize only the coefficients. - have t1 : (1 / 6 : ℝ) * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) = 144200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4 := by - norm_num [← mul_assoc] - have t2 : 1 / (4 * (3 + α)) * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) = 216300 * (3 + α) ^ 48 * (300 + 47 * α - α ^ 2) ^ 4 := by - rw [pow_succ (3 + α) 48] - -- Remove the single factor `3 + α`; the remaining powers stay opaque. - generalize (3 + α) ^ 48 = p, (300 + 47 * α - α ^ 2) ^ 4 = g - field_simp - ring - have t3 : (1 / 200 : ℝ) * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) = 4326 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4 := by - norm_num [← mul_assoc] - have t4 : 1 / (400 * (3 + α)) * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) = 2163 * (3 + α) ^ 48 * (300 + 47 * α - α ^ 2) ^ 4 := by - rw [pow_succ (3 + α) 48] - -- Remove the single factor `3 + α`; the remaining powers stay opaque. - generalize (3 + α) ^ 48 = p, (300 + 47 * α - α ^ 2) ^ 4 = g - field_simp - ring - have t5 : 101 / 100 * (1600000 * (100 - 2 * α) ^ 2 * (3 + α) ^ 3 - / (721 * (300 + 47 * α - α ^ 2) ^ 4)) * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) - = 1939200000 * (100 - 2 * α) ^ 2 * (3 + α) ^ 52 := by - -- Combine exponents by `pow_add`, and cancel only the scalar denominator γ⁴. - rw [show (3 + α) ^ 52 = (3 + α) ^ 3 * (3 + α) ^ 49 from pow_add _ 3 49] - have hg4 := pow_ne_zero 4 hgne - generalize (100 - 2 * α) ^ 2 = a, (3 + α) ^ 3 = b, (3 + α) ^ 49 = p - generalize (300 + 47 * α - α ^ 2) ^ 4 = g at hg4 ⊢ - field_simp - ring - have t6 : (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * (α / (3 + α)) ^ 48 - * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) - = (21627837 / 4) * (100 - 2 * α) ^ 2 * α ^ 48 * (300 + 47 * α - α ^ 2) ^ 4 := by - -- First expose the paired powers so that `h48` cancels 48 denominator factors. - rw [show (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * (α / (3 + α)) ^ 48 - * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) - = ((100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * (865200 * (300 + 47 * α - α ^ 2) ^ 4)) - * ((α / (3 + α)) ^ 48 * (3 + α) ^ 49) from by - -- This is only reassociation of scalar factors, not a polynomial identity. - generalize (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) = a, - (α / (3 + α)) ^ 48 = b, (3 + α) ^ 49 = p, - (300 + 47 * α - α ^ 2) ^ 4 = g - ring, h48] - -- Only one factor `3 + α` remains to cancel; do not expand α⁴⁸ or γ⁴. - generalize (100 - 2 * α) ^ 2 = a, α ^ 48 = p, (300 + 47 * α - α ^ 2) ^ 4 = g - field_simp - ring - have hD : (0 : ℝ) < 865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4 := by - have h49 := pow_pos h3 49 - have hg4 := pow_pos hg 4 - positivity - have hmul : (1 - Ut α) * (865200 * (3 + α) ^ 49 * (300 + 47 * α - α ^ 2) ^ 4) = 1122702787291394736448332031899900000000 + 19046325083555631071589567727384404000000 * α + 158421799401305511319831453323336122340000 * α ^ 2 + 861086144839783899262522290902928965732400 * α ^ 3 + 3439408019860839882261371580238947745811319 * α ^ 4 + 10763976190978343059270128976319908699279230 * α ^ 5 + 27482264870203746404049226779511973140100922 * α ^ 6 + 58851751350273881387953189525455032864879976 * α ^ 7 + 107855247587877306122230293103712405510570475 * α ^ 8 + 171759728691636266490365540891679381811794330 * α ^ 9 + 240529488382582584529650966973246412375404200 * α ^ 10 + 299026713527922503750214218383542861883052640 * α ^ 11 + 332584383792637363818110693156644176263245770 * α ^ 12 + 333049929303875184857821696251322094451555300 * α ^ 13 + 301880762905153988961008260011013859110924020 * α ^ 14 + 248778383542817950458457719347804130388393200 * α ^ 15 + 187098708657492312991354787006951375606496810 * α ^ 16 + 128821377534531366266108990532541378516293180 * α ^ 17 + 81419630849957631346647265524754482691775400 * α ^ 18 + 47345231058420765609063602657623737762737040 * α ^ 19 + 25377634631717199993415818405387727249820325 * α ^ 20 + 12558381461678887884336588690871882873720170 * α ^ 21 + 5744808624780589326694261819822529221060710 * α ^ 22 + 2431706095253331452737540626239749451182200 * α ^ 23 + 953157993950838580367703259303917955151865 * α ^ 24 + 346144642670223976596034179062502690180750 * α ^ 25 + 116495518414609472010567246197077176778320 * α ^ 26 + 36336281152740288609221052030650841399360 * α ^ 27 + 10502010275079971287850469706276099760700 * α ^ 28 + 2811408048396859598615803016678577566616 * α ^ 29 + 696637045577195749563697260889295071320 * α ^ 30 + 159631247175312590035611267009797954208 * α ^ 31 + 33785522480785269776966858820750983964 * α ^ 32 + 6594450665275339854415586104207300200 * α ^ 33 + 1184779969344702509178802875319571760 * α ^ 34 + 195478905533580848831244517654808400 * α ^ 35 + 29535092351319878473338799170306705 * α ^ 36 + 4072478636506932555839271140088690 * α ^ 37 + 510306927013451786184096375133350 * α ^ 38 + 57808428584128470185954723726040 * α ^ 39 + 5881482509330352987406470588525 * α ^ 40 + 532894392271418064251604942870 * α ^ 41 + 42515012647728027357611076360 * α ^ 42 + 2939585612233076406278632800 * α ^ 43 + 171946491190832176774496730 * α ^ 44 + 8163588014241841361016900 * α ^ 45 + 287999399301298111575540 * α ^ 46 + 5555726484083859953520 * α ^ 47 - 536551383276446293350 * α ^ 48 - 269167118332858968420 * α ^ 49 - 48279425158933803000 * α ^ 50 - 1759012112154436560 * α ^ 51 + 273395914772406495 * α ^ 52 + 6240162359537050 * α ^ 53 - 1129204084343291 * α ^ 54 + 41554143448524 * α ^ 55 - 721404477395 * α ^ 56 + 6229533730 * α ^ 57 - 21627837 * α ^ 58 := by - rw [Ut, hT1, sub_mul, one_mul, add_mul, add_mul, add_mul, add_mul, add_mul, - t1, t2, t3, t4, t5, t6] - ring - rw [← sub_pos] - have hF := F_pos hα hα' - nlinarith [hmul, hF, hD] - -/-- **The large-degree claim.** Every degree `n ≥ 101`. -/ -theorem large_degree {n : ℕ} (hn : 101 ≤ n) (hα : 0 ≤ α) (hα' : α ≤ 17) - (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have hcpos : (0 : ℝ) < c n α := by - have := c_ge_of_large hn hα hα' - linarith - exact lt_of_le_of_lt - (le_trans (R_le_U (by omega) hα hfeas hcpos) (U_le_Ut hn hα hα')) - (Ut_lt_one hα hα') - -end Sendov diff --git a/Sendov/LargeDegree/Monotone.lean b/Sendov/LargeDegree/Monotone.lean deleted file mode 100644 index df20fae..0000000 --- a/Sendov/LargeDegree/Monotone.lean +++ /dev/null @@ -1,359 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.LargeDegree.Tail - -/-! -# Monotonicity of the elementary bound in the degree - -`Sendov.U` bounds `Sendov.R` for every `n ≥ 5`. Here it is reduced to a single inequality -in `α` alone, by showing that `U n α` is essentially decreasing in `n` on `n ≥ 101`. - -Two features of the bound make this cheaper than it looks. - -First, the sharp Beta constant collapses. The exponent is `r = (n-4)/2`, so - - `(r+1)(r+2)(r+3)(r+4) = (n-2) n (n+2) (n+4) / 16`, - -and the `n (n-2)` in it cancels the `n (n-2)` in the prefactor of `Sendov.R` exactly. The -first tail term is therefore the *rational function* - - `T1 n α = 24 (n-1-2α)² / ((3+α) c⁴ (n-1)(n+2)(n+4))`, - -with no factorial-like growth left to control. (Had the cruder constant `6/r⁴` of the -informal write-up been used, no such cancellation would occur and the corresponding step -would need the degree-8 positivity certificate recorded there.) - -Second, the surviving real power is a square: writing `b = √B`, the second tail term is -`T2 n α = A² n (n-1)(n-2)/(16(3+α)) · b ^ (n-4)` with a *natural* exponent, so the geometric -decay can be run as an ordinary induction on `n` rather than as an estimate on `rpow`. - -## The two certificates - -`T1` is not monotone in `n` by itself — at `α = 17` the factor -`(n-1-2α)²/((n-1)(n+2)(n+4))` increases up to `n ≈ 108` — so it is bounded by its value at -`n = 101` only after a `1%` allowance, which the `c⁴` in the denominator more than pays for. -That allowance is `Sendov.tail1_poly`, a Bernstein certificate on `0 ≤ α ≤ 17`. Its top -coefficient is the only one in this development that is *not* a positive combination of -powers of the degree offset; it is handled by completing the square, its quadratic part -having negative discriminant. - -`Sendov.tail2_poly` is the geometric step, and is an ordinary all-positive certificate. - -## Main statements - -* `Sendov.U_eq`: `U` in closed form, `T1 + T2` plus four elementary terms; -* `Sendov.T1_le`, `Sendov.T2_le`: the two tail bounds at `n = 101`; -* `Sendov.U_le_Ut`: `U n α ≤ Ut α` for `n ≥ 101`, where `Ut` involves no `n` and no `rpow`. --/ - -namespace Sendov - -variable {n : ℕ} {α : ℝ} - -/-- The first tail term of `Sendov.U`, in closed form. -/ -noncomputable def T1 (n : ℕ) (α : ℝ) : ℝ := - 24 * ((n : ℝ) - 1 - 2 * α) ^ 2 / - ((3 + α) * c n α ^ 4 * ((n : ℝ) - 1) * ((n : ℝ) + 2) * ((n : ℝ) + 4)) - -/-- The second tail term of `Sendov.U`, with the real power of `B` replaced by a natural -power of `√B`. -/ -noncomputable def T2 (n : ℕ) (α : ℝ) : ℝ := - A n α ^ 2 * n * M n * ((n : ℝ) - 2) / (16 * (3 + α)) * Real.sqrt (α / (3 + α)) ^ (n - 4) - -/-! ### The two polynomial certificates -/ - -/-- The allowance for the first tail term: on `0 ≤ α ≤ 17` and `N = 100 + j ≥ 100`, - - `(N-2α)² / (N (N+3)(N+5)) ≤ (101/100) (100-2α)² / (100 · 103 · 105)`. - -A Bernstein certificate in `α` on `[0,17]`, whose coefficients are polynomials in `j`. The -top one, `439956 j³ + 27356448 j² - 366591060 j + 4711014000`, has a negative linear -coefficient; it is nonnegative because its quadratic part has negative discriminant. -/ -lemma tail1_poly {j α : ℝ} (hj : 0 ≤ j) (hα : 0 ≤ α) (hα' : α ≤ 17) : - 108150000 * (100 + j - 2 * α) ^ 2 - ≤ 101 * (100 - 2 * α) ^ 2 * ((100 + j) * (103 + j) * (105 + j)) := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hj2 : (0 : ℝ) ≤ j ^ 2 := sq_nonneg j - have hj3 : (0 : ℝ) ≤ j ^ 3 := pow_nonneg hj 3 - have h0 : (0 : ℝ) ≤ 1010000 * j ^ 3 + 202930000 * j ^ 2 + 10301150000 * j + 10815000000 := by - linarith - have h1 : (0 : ℝ) ≤ 1333200 * j ^ 3 + 194325600 * j ^ 2 + 6243318000 * j + 14275800000 := by - linarith - have h2 : (0 : ℝ) ≤ 439956 * j ^ 3 + 27356448 * j ^ 2 - 366591060 * j + 4711014000 := by - nlinarith [sq_nonneg (4559408 * j - 30549255), hj3] - have hid : (17 : ℝ) ^ 2 * - (101 * (100 - 2 * α) ^ 2 * ((100 + j) * (103 + j) * (105 + j)) - - 108150000 * (100 + j - 2 * α) ^ 2) - = (1010000 * j ^ 3 + 202930000 * j ^ 2 + 10301150000 * j + 10815000000) * (17 - α) ^ 2 - + (1333200 * j ^ 3 + 194325600 * j ^ 2 + 6243318000 * j + 14275800000) - * (α * (17 - α)) - + (439956 * j ^ 3 + 27356448 * j ^ 2 - 366591060 * j + 4711014000) * α ^ 2 := by - ring - nlinarith [mul_nonneg h0 (sq_nonneg (17 - α)), mul_nonneg h1 (mul_nonneg hα hu), - mul_nonneg h2 (sq_nonneg α)] - -/-- The geometric step for the second tail term: on `0 ≤ α ≤ 17` and `n = 101 + k ≥ 101`, - - `12 A_{n+1}² (n+1) n (n-1) ≤ 13 A_n² n (n-1)(n-2)`, - -after clearing the denominators `n²` and `(n-1)²` of `A_{n+1}` and `A_n`. Together with -`√B ≤ 12/13` this makes the step ratio less than one. A Bernstein certificate in `α` on -`[0,17]` with all coefficients positive combinations of powers of `k`. -/ -lemma tail2_poly {k α : ℝ} (hk : 0 ≤ k) (hα : 0 ≤ α) (hα' : α ≤ 17) : - 12 * (101 + k - 2 * α) ^ 2 * (102 + k) * (100 + k) ^ 2 - ≤ 13 * (100 + k - 2 * α) ^ 2 * (99 + k) * (101 + k) ^ 2 := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hk2 : (0 : ℝ) ≤ k ^ 2 := sq_nonneg k - have hk3 : (0 : ℝ) ≤ k ^ 3 := pow_nonneg hk 3 - have hk4 : (0 : ℝ) ≤ k ^ 4 := pow_nonneg hk 4 - have hk5 : (0 : ℝ) ≤ k ^ 5 := pow_nonneg hk 5 - have h0 : (0 : ℝ) ≤ k ^ 5 + 465 * k ^ 4 + 85927 * k ^ 3 + 7878063 * k ^ 2 - + 357802600 * k + 6426630000 := by linarith - have h1 : (0 : ℝ) ≤ 2 * k ^ 5 + 862 * k ^ 4 + 146218 * k ^ 3 + 12147842 * k ^ 2 - + 491029284 * k + 7642508400 := by linarith - have h2 : (0 : ℝ) ≤ k ^ 5 + 397 * k ^ 4 + 61447 * k ^ 3 + 4603863 * k ^ 2 - + 165348456 * k + 2243200572 := by linarith - have hid : (17 : ℝ) ^ 2 * - (13 * (100 + k - 2 * α) ^ 2 * (99 + k) * (101 + k) ^ 2 - - 12 * (101 + k - 2 * α) ^ 2 * (102 + k) * (100 + k) ^ 2) - = (k ^ 5 + 465 * k ^ 4 + 85927 * k ^ 3 + 7878063 * k ^ 2 + 357802600 * k + 6426630000) - * (17 - α) ^ 2 - + (2 * k ^ 5 + 862 * k ^ 4 + 146218 * k ^ 3 + 12147842 * k ^ 2 + 491029284 * k - + 7642508400) * (α * (17 - α)) - + (k ^ 5 + 397 * k ^ 4 + 61447 * k ^ 3 + 4603863 * k ^ 2 + 165348456 * k - + 2243200572) * α ^ 2 := by - ring - nlinarith [mul_nonneg h0 (sq_nonneg (17 - α)), mul_nonneg h1 (mul_nonneg hα hu), - mul_nonneg h2 (sq_nonneg α)] - -/-! ### The closed form of `U` -/ - -/-- `c` increases with `n`: raising the degree moves `c` towards `1 - B/2`. -/ -lemma c_mono {m n : ℕ} (hm : 2 ≤ m) (h : m ≤ n) (hα : 0 ≤ α) : c m α ≤ c n α := by - have hMm : 0 < M m := M_pos hm - have hMle : M m ≤ M n := by - simp only [M] - have : (m : ℝ) ≤ (n : ℝ) := by exact_mod_cast h - linarith - have : α / M n ≤ α / M m := div_le_div_of_nonneg_left hα hMm hMle - simp only [c] - linarith - -/-- The real power of `B` in `Sendov.U` is a natural power of `√B`. -/ -lemma rpow_B_eq (hn : 4 ≤ n) (hα : 0 ≤ α) : - (α / (3 + α)) ^ (((n : ℝ) - 4) / 2) = Real.sqrt (α / (3 + α)) ^ (n - 4) := by - have hB : (0 : ℝ) ≤ α / (3 + α) := div_nonneg hα (by linarith) - have hcast : ((n - 4 : ℕ) : ℝ) = (n : ℝ) - 4 := by - push_cast [Nat.cast_sub hn] - ring - rw [Real.sqrt_eq_rpow, ← Real.rpow_natCast ((α / (3 + α)) ^ ((1 : ℝ) / 2)) (n - 4), - ← Real.rpow_mul hB, hcast] - congr 1 - ring - -/-- The sharp Beta constant, factored. This is the cancellation that makes `T1` rational: -`(r+1)(r+2)(r+3)(r+4) = (n-2) n (n+2)(n+4)/16` at `r = (n-4)/2`. -/ -lemma beta_prod (n : ℕ) : - (((n : ℝ) - 4) / 2 + 1) * (((n : ℝ) - 4) / 2 + 2) * (((n : ℝ) - 4) / 2 + 3) - * (((n : ℝ) - 4) / 2 + 4) - = ((n : ℝ) - 2) * (n : ℝ) * ((n : ℝ) + 2) * ((n : ℝ) + 4) / 16 := by - ring - -/-- **`U` in closed form.** The `n (n-2)` of the prefactor cancels against the same factor -in the sharp Beta constant, leaving a rational function plus a natural power of `√B`. -/ -lemma U_eq (hn : 5 ≤ n) (hα : 0 ≤ α) (hc : c n α ≠ 0) : - U n α = 1 / 6 + 1 / (4 * (3 + α)) + 1 / (2 * M n) + 1 / (4 * M n * (3 + α)) - + T1 n α + T2 n α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hnR : (5 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn - have h1 : (n : ℝ) - 1 ≠ 0 := by linarith - have h2 : (n : ℝ) - 2 ≠ 0 := by linarith - have h0 : (n : ℝ) ≠ 0 := by linarith - have hp2 : (n : ℝ) + 2 ≠ 0 := by linarith - have hp4 : (n : ℝ) + 4 ≠ 0 := by linarith - simp only [U, beta_prod, T1, T2, M, A, rpow_B_eq (show 4 ≤ n by omega) hα] - field_simp - ring - -/-! ### The first tail term -/ - -/-- `T1` is bounded by its value at `n = 101`, up to `1%`. -/ -lemma T1_le (hn : 101 ≤ n) (hα : 0 ≤ α) (hα' : α ≤ 17) : - T1 n α ≤ 101 / 100 * T1 101 α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hnR : (101 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn - have hc1 : (0 : ℝ) < c 101 α := by - have := c_ge_of_large (n := 101) le_rfl hα hα' - linarith - have hcn : c 101 α ≤ c n α := c_mono (by omega) hn hα - have hcnp : (0 : ℝ) < c n α := lt_of_lt_of_le hc1 hcn - have hc4 : c 101 α ^ 4 ≤ c n α ^ 4 := by - exact pow_le_pow_left₀ hc1.le hcn 4 - have hN : (0 : ℝ) < (n : ℝ) - 1 := by linarith - have hN2 : (0 : ℝ) < (n : ℝ) + 2 := by linarith - have hN4 : (0 : ℝ) < (n : ℝ) + 4 := by linarith - have hD1 : (0 : ℝ) < (3 + α) * c 101 α ^ 4 * ((n : ℝ) - 1) * ((n : ℝ) + 2) * ((n : ℝ) + 4) := - mul_pos (mul_pos (mul_pos (mul_pos h3 (pow_pos hc1 4)) hN) hN2) hN4 - have hDle : (3 + α) * c 101 α ^ 4 * ((n : ℝ) - 1) * ((n : ℝ) + 2) * ((n : ℝ) + 4) - ≤ (3 + α) * c n α ^ 4 * ((n : ℝ) - 1) * ((n : ℝ) + 2) * ((n : ℝ) + 4) := by - exact mul_le_mul_of_nonneg_right - (mul_le_mul_of_nonneg_right - (mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left hc4 h3.le) hN.le) - hN2.le) hN4.le - -- step A: enlarge the denominator's `c` from `c n` down to `c 101` - have stepA : T1 n α - ≤ 24 * ((n : ℝ) - 1 - 2 * α) ^ 2 / - ((3 + α) * c 101 α ^ 4 * ((n : ℝ) - 1) * ((n : ℝ) + 2) * ((n : ℝ) + 4)) := by - rw [T1] - exact div_le_div_of_nonneg_left (by positivity) hD1 hDle - refine stepA.trans ?_ - -- step B: the certificate, with the same `c 101` on both sides - have hT101 : T1 101 α = 24 * (100 - 2 * α) ^ 2 / ((3 + α) * c 101 α ^ 4 * 1081500) := by - simp only [T1] - norm_num - ring_nf - have hD2 : (0 : ℝ) < 100 * ((3 + α) * c 101 α ^ 4 * 1081500) := by - have h4 := pow_pos hc1 4 - positivity - have hRHS : 101 / 100 * T1 101 α - = 101 * (24 * (100 - 2 * α) ^ 2) / (100 * ((3 + α) * c 101 α ^ 4 * 1081500)) := by - rw [hT101] - field_simp - rw [hRHS, div_le_div_iff₀ hD1 hD2] - have hj : (0 : ℝ) ≤ (n : ℝ) - 101 := by linarith - have hcert := tail1_poly (j := (n : ℝ) - 101) hj hα hα' - have hscale : (0 : ℝ) ≤ 24 * (3 + α) * c 101 α ^ 4 := by positivity - nlinarith [mul_le_mul_of_nonneg_left hcert hscale] - -/-! ### The second tail term -/ - -/-- `√B ≤ 12/13` on `0 ≤ α ≤ 17`, since `B ≤ 17/20 ≤ (12/13)²`. A rational bound is enough -here, and avoids carrying a square root into the step ratio. -/ -lemma sqrtB_le (hα : 0 ≤ α) (hα' : α ≤ 17) : Real.sqrt (α / (3 + α)) ≤ 12 / 13 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hB : α / (3 + α) ≤ 144 / 169 := by - rw [div_le_div_iff₀ h3 (by norm_num)] - linarith - calc Real.sqrt (α / (3 + α)) ≤ Real.sqrt (144 / 169) := Real.sqrt_le_sqrt hB - _ = 12 / 13 := by - rw [show (144 : ℝ) / 169 = (12 / 13) ^ 2 by norm_num, - Real.sqrt_sq (by norm_num : (0 : ℝ) ≤ 12 / 13)] - -/-- One step of the geometric decay: `T2` decreases with `n` on `n ≥ 101`. -/ -lemma T2_step (hn : 101 ≤ n) (hα : 0 ≤ α) (hα' : α ≤ 17) : T2 (n + 1) α ≤ T2 n α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hnR : (101 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn - have hn0 : (0 : ℝ) < (n : ℝ) := by linarith - have hn1 : (0 : ℝ) < (n : ℝ) - 1 := by linarith - have hb0 : (0 : ℝ) ≤ Real.sqrt (α / (3 + α)) := Real.sqrt_nonneg _ - have hb1 : Real.sqrt (α / (3 + α)) ≤ 12 / 13 := sqrtB_le hα hα' - have hA1 : A (n + 1) α = ((n : ℝ) - 2 * α) / (n : ℝ) := by - simp only [A, M] - push_cast - rw [show ((n : ℝ) + 1 - 1) = (n : ℝ) from by ring] - field_simp - have hA2 : A n α = ((n : ℝ) - 1 - 2 * α) / ((n : ℝ) - 1) := by - simp only [A, M] - field_simp - have hk : (0 : ℝ) ≤ (n : ℝ) - 101 := by linarith - have hcert := tail2_poly (k := (n : ℝ) - 101) hk hα hα' - have hCn1 : (0 : ℝ) ≤ A (n + 1) α ^ 2 * ((n + 1 : ℕ) : ℝ) * M (n + 1) - * (((n + 1 : ℕ) : ℝ) - 2) / (16 * (3 + α)) := by - have hM : (0 : ℝ) ≤ M (n + 1) := by simp only [M]; push_cast; linarith - have h2 : (0 : ℝ) ≤ ((n + 1 : ℕ) : ℝ) - 2 := by push_cast; linarith - have h1 : (0 : ℝ) ≤ ((n + 1 : ℕ) : ℝ) := by positivity - positivity - -- the coefficient inequality - have hstep : A (n + 1) α ^ 2 * ((n + 1 : ℕ) : ℝ) * M (n + 1) * (((n + 1 : ℕ) : ℝ) - 2) - / (16 * (3 + α)) * Real.sqrt (α / (3 + α)) - ≤ A n α ^ 2 * (n : ℝ) * M n * ((n : ℝ) - 2) / (16 * (3 + α)) := by - refine le_trans (mul_le_mul_of_nonneg_left hb1 hCn1) ?_ - rw [← sub_nonneg] - have key : A n α ^ 2 * (n : ℝ) * M n * ((n : ℝ) - 2) / (16 * (3 + α)) - - A (n + 1) α ^ 2 * ((n + 1 : ℕ) : ℝ) * M (n + 1) * (((n + 1 : ℕ) : ℝ) - 2) - / (16 * (3 + α)) * (12 / 13) - = (13 * ((n : ℝ) - 1 - 2 * α) ^ 2 * ((n : ℝ) - 2) * (n : ℝ) ^ 2 - - 12 * ((n : ℝ) - 2 * α) ^ 2 * ((n : ℝ) + 1) * ((n : ℝ) - 1) ^ 2) - / (208 * (3 + α) * (n : ℝ) * ((n : ℝ) - 1)) := by - simp only [hA1, hA2, M] - push_cast - field_simp - ring - rw [key] - refine div_nonneg ?_ (by positivity) - nlinarith [hcert] - have hexp : n + 1 - 4 = (n - 4) + 1 := by omega - calc T2 (n + 1) α - = A (n + 1) α ^ 2 * ((n + 1 : ℕ) : ℝ) * M (n + 1) * (((n + 1 : ℕ) : ℝ) - 2) - / (16 * (3 + α)) * Real.sqrt (α / (3 + α)) - * Real.sqrt (α / (3 + α)) ^ (n - 4) := by - rw [T2, hexp, pow_succ] - ring - _ ≤ A n α ^ 2 * (n : ℝ) * M n * ((n : ℝ) - 2) / (16 * (3 + α)) - * Real.sqrt (α / (3 + α)) ^ (n - 4) := - mul_le_mul_of_nonneg_right hstep (pow_nonneg hb0 _) - _ = T2 n α := by rw [T2] - -/-- `T2` is bounded by its value at `n = 101`. -/ -lemma T2_le (hn : 101 ≤ n) (hα : 0 ≤ α) (hα' : α ≤ 17) : T2 n α ≤ T2 101 α := by - induction n, hn using Nat.le_induction with - | base => exact le_rfl - | succ m hm ih => exact (T2_step hm hα hα').trans ih - -/-! ### The bound with no degree left in it -/ - -/-- The elementary bound at `n = 101`, with `√B` removed and `α` the only variable. -/ -noncomputable def Ut (α : ℝ) : ℝ := - 1 / 6 + 1 / (4 * (3 + α)) + 1 / 200 + 1 / (400 * (3 + α)) + 101 / 100 * T1 101 α - + (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * (α / (3 + α)) ^ 48 - -/-- **`U` is bounded by an expression in `α` alone**, for every `n ≥ 101`. This is where the -degree leaves the argument. -/ -theorem U_le_Ut (hn : 101 ≤ n) (hα : 0 ≤ α) (hα' : α ≤ 17) : U n α ≤ Ut α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hnR : (101 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn - have hM : (100 : ℝ) ≤ M n := by simp only [M]; linarith - have hcpos : (0 : ℝ) < c n α := by - have := c_ge_of_large hn hα hα' - linarith - rw [U_eq (by omega) hα (ne_of_gt hcpos), Ut] - have e1 : 1 / (2 * M n) ≤ 1 / 200 := by - rw [div_le_div_iff₀ (by linarith) (by norm_num)] - linarith - have e2 : 1 / (4 * M n * (3 + α)) ≤ 1 / (400 * (3 + α)) := by - rw [div_le_div_iff₀ (by positivity) (by positivity)] - nlinarith - have e3 := T1_le hn hα hα' - have hB : (0 : ℝ) ≤ α / (3 + α) := div_nonneg hα (by linarith) - have hb0 : (0 : ℝ) ≤ Real.sqrt (α / (3 + α)) := Real.sqrt_nonneg _ - have hb1 : Real.sqrt (α / (3 + α)) ≤ 1 := by - have hle : α / (3 + α) ≤ 1 := by rw [div_le_one h3]; linarith - calc Real.sqrt (α / (3 + α)) ≤ Real.sqrt 1 := Real.sqrt_le_sqrt hle - _ = 1 := Real.sqrt_one - have hpow : Real.sqrt (α / (3 + α)) ^ (101 - 4) ≤ (α / (3 + α)) ^ 48 := by - have h97 : Real.sqrt (α / (3 + α)) ^ (101 - 4) - = (α / (3 + α)) ^ 48 * Real.sqrt (α / (3 + α)) := by - rw [show (101 : ℕ) - 4 = 2 * 48 + 1 by norm_num, pow_succ, pow_mul, Real.sq_sqrt hB] - rw [h97] - exact mul_le_of_le_one_right (pow_nonneg hB 48) hb1 - have e4 : T2 101 α - ≤ (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * (α / (3 + α)) ^ 48 := by - have hA101 : A 101 α = (100 - 2 * α) / 100 := by - simp only [A, M] - norm_num - ring - have hT2 : T2 101 α = (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) - * Real.sqrt (α / (3 + α)) ^ (101 - 4) := by - simp only [T2, hA101, M] - norm_num - ring_nf - tauto - rw [hT2] - exact mul_le_mul_of_nonneg_left hpow (by positivity) - have e5 := (T2_le hn hα hα').trans e4 - linarith - -end Sendov diff --git a/Sendov/LargeDegree/Tail.lean b/Sendov/LargeDegree/Tail.lean deleted file mode 100644 index d2b2694..0000000 --- a/Sendov/LargeDegree/Tail.lean +++ /dev/null @@ -1,94 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.Common.Chord - -/-! -# The tail bound - -The large-degree argument replaces the integral in `Sendov.R` by an elementary expression: - - `∫₀¹ t³ Q^r dt ≤ 6 / (c⁴ (r+1)(r+2)(r+3)(r+4)) + Bʳ / 4`. - -This is the only part of the large-degree argument that touches integration; everything after -it is elementary inequalities in `α` and `n`. - -The work is done by `Sendov.integral_le_tail_cube` in `Sendov.Common.Chord`, which proves the -same split for the general quadratic `QQ c A` and an arbitrary weight `t^k` — the `α ≤ 17` -argument needs the `k = 1` instance of it. All that is left here is to read that bound -through `Q n α t = QQ (c n α) (A n α) t` and `Q n α 1 = α/(3+α)`. - -## Main statements - -* `Sendov.c_le_one`: `c ≤ 1`, so the chord's zero `1/c` is at least `1`; -* `Sendov.integral_le_tail`: the bound above. --/ - -namespace Sendov - -open MeasureTheory - -variable {n : ℕ} {α t : ℝ} - -/-- `c ≤ 1`, so the chord's zero `1/c` is at least `1`. -/ -lemma c_le_one (hn : 2 ≤ n) (hα : 0 ≤ α) : c n α ≤ 1 := by - have hM : 0 < M n := M_pos hn - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - simp only [c] - have h1 : 0 ≤ α / M n := by positivity - have h2 : 0 ≤ α / (2 * (3 + α)) := by positivity - linarith - -/-- **The tail bound**, read off from `Sendov.integral_le_tail_cube`. -/ -theorem integral_le_tail (hn : 2 ≤ n) (hα : 0 ≤ α) (hfeas : c n α ^ 2 ≤ A n α) - (hc : 0 < c n α) {r : ℝ} (hr : 0 < r) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ r) - ≤ 6 / (c n α ^ 4 * ((r + 1) * (r + 2) * (r + 3) * (r + 4))) - + (α / (3 + α)) ^ r / 4 := by - have h := integral_le_tail_cube hfeas hc (c_le_one hn hα) hr - rw [← Q_one hn hα] - simpa only [Q_eq_QQ] using h - -/-! ### The elementary upper bound `U` - -Everything after this point in the large-degree argument is an inequality in `α` and `n` -alone; no integral survives. -/ - -/-- The elementary bound replacing `Sendov.R`: `(11)` of the informal write-up, but with the -sharper Beta constant `6/((r+1)(r+2)(r+3)(r+4))` in place of `6/r⁴`. -/ -noncomputable def U (n : ℕ) (α : ℝ) : ℝ := - 1 / 6 + 1 / (4 * (3 + α)) + 1 / (2 * M n) + 1 / (4 * M n * (3 + α)) - + A n α ^ 2 * n * M n * ((n : ℝ) - 2) / (4 * (3 + α)) - * (6 / (c n α ^ 4 * - ((((n : ℝ) - 4) / 2 + 1) * (((n : ℝ) - 4) / 2 + 2) * (((n : ℝ) - 4) / 2 + 3) - * (((n : ℝ) - 4) / 2 + 4))) - + (α / (3 + α)) ^ (((n : ℝ) - 4) / 2) / 4) - -/-- On the large-degree range `c` is bounded below, hence positive. For `n ≥ 101` and -`α ≤ 17` this gives `c ≥ 81/200`, which is `(3)` of the write-up. -/ -lemma c_ge_of_large (hn : 101 ≤ n) (hα : 0 ≤ α) (hα' : α ≤ 17) : 81 / 200 ≤ c n α := by - have hM : (100 : ℝ) ≤ M n := by - have : (101 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn - simp only [M]; linarith - have hM0 : (0 : ℝ) < M n := by linarith - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - simp only [c] - have h1 : α / M n ≤ 17 / 100 := by - rw [div_le_iff₀ hM0] - nlinarith - have h2 : α / (2 * (3 + α)) ≤ 17 / 40 := by - rw [div_le_iff₀ (by positivity : (0:ℝ) < 2 * (3 + α))] - nlinarith - linarith - -/-- **`R` is bounded by the elementary expression `U`.** This is the bridge out of -integration: from here the large-degree argument is elementary. -/ -theorem R_le_U (hn : 5 ≤ n) (hα : 0 ≤ α) (hfeas : c n α ^ 2 ≤ A n α) (hc : 0 < c n α) : - R n α ≤ U n α := by - have hnR : (5 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn - have hr : (0 : ℝ) < ((n : ℝ) - 4) / 2 := by linarith - exact R_le_of_integral_le (by omega) hα (integral_le_tail (by omega) hα hfeas hc hr) - -end Sendov diff --git a/Sendov/Main.lean b/Sendov/Main.lean deleted file mode 100644 index f855fb7..0000000 --- a/Sendov/Main.lean +++ /dev/null @@ -1,53 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Cover -import Sendov.LargeDegree.Endgame - -/-! -# The numerical claim, for every degree - -This is the top of the development. `Sendov.Defs` fixes the notation of equation `stat` -of the blog post; everything else establishes that its right-hand side `R n α` is below `1`. -Two arguments meet here. - -* `Sendov.finite_range_le_100` certifies `5 ≤ n ≤ 100` by explicit polynomial arithmetic: - the integral is a finite sum of moments, the moments come from a packed recurrence, and - each of 31 batches of degrees carries one Bernstein certificate in `α`. -* `Sendov.large_degree` covers `n ≥ 101` analytically: the integral is bounded by a Beta - integral plus a geometric tail, the resulting elementary bound `U` is shown decreasing in - the degree, and its value at `n = 101` is below `1` by one more Bernstein certificate. - -The two ranges overlap in intent but not in method, and the seam is at `100/101` rather than -at the `97/98` of the blog post: the finite side was pushed three degrees further so that the -analytic side would start with margin `0.122` instead of `0.048`. - -## Main statements - -* `Sendov.stat_lt_one`: `R n α < 1` for every `n ≥ 5`, `0 ≤ α ≤ 17` with `c ^ 2 ≤ A`; -* `Sendov.stat_contradiction`: equation `stat` of the blog post is therefore unsatisfiable. --/ - -namespace Sendov - -variable {α : ℝ} - -/-- **The numerical claim.** The right-hand side of equation `stat` of the blog post is -strictly less than `1` for every degree `n ≥ 5` and every `0 ≤ α ≤ 17` satisfying the -feasibility constraint `c ^ 2 ≤ A`. -/ -theorem stat_lt_one {n : ℕ} (hn : 5 ≤ n) (hα : 0 ≤ α) (hα' : α ≤ 17) - (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - rcases Nat.lt_or_ge n 101 with h | h - · exact finite_range_le_100 hn (by omega) hα hα' hfeas - · exact large_degree h hα hα' hfeas - -/-- **Equation `stat` is unsatisfiable.** This is the form in which the blog post uses the -claim: the polynomial argument there produces `1 ≤ R n α` under exactly these hypotheses, so -the assumed counterexample to Sendov's conjecture cannot exist. -/ -theorem stat_contradiction {n : ℕ} (hn : 5 ≤ n) (hα : 0 ≤ α) (hα' : α ≤ 17) - (hfeas : c n α ^ 2 ≤ A n α) (hstat : 1 ≤ R n α) : False := - absurd hstat (not_le.2 (stat_lt_one hn hα hα' hfeas)) - -end Sendov diff --git a/Sendov/Reduction/Alpha17.lean b/Sendov/Reduction/Alpha17.lean index ab65d13..6b53864 100644 --- a/Sendov/Reduction/Alpha17.lean +++ b/Sendov/Reduction/Alpha17.lean @@ -3,7 +3,7 @@ Copyright (c) 2026 Terence Tao. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Terence Tao -/ -import Sendov.Reduction.Simplified +import Sendov.Reduction.Setup import Mathlib.Analysis.Complex.ExponentialBounds /-! diff --git a/Sendov/Reduction/CubicPolar.lean b/Sendov/Reduction/CubicPolar.lean new file mode 100644 index 0000000..d9a3c48 --- /dev/null +++ b/Sendov/Reduction/CubicPolar.lean @@ -0,0 +1,127 @@ +import Sendov.Common.DistillationHyperbolic +import Sendov.Reduction.DistillationBridge + +/-! +# The strict cubic polar envelope from the original weak polar constraint + +Adaptation of Senjian An (SJanPerth), *Proof Distillation for Sendov's +Conjecture*, revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, +paper lines 260–291 (CC BY 4.0, https://creativecommons.org/licenses/by/4.0/). +The integral evaluation is the existing Apache-2.0 BetaBound interface. + +Unlike the paper, the input is only `1 ≤ integral`. This gives `F(p) ≤ 0`, +which still contradicts the STRICT positivity of F at the cubic envelope. +The resulting strict envelope feeds the scalar obstruction comparison. +-/ + +namespace Sendov + +open MeasureTheory Real + +/-- A positive-coefficient certificate replaces the paper's Descartes argument. -/ +lemma cubicPolarEnvelope_center_lt_ten {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : + α * (1 - cubicPolarEnvelope α / 2) < 10 := by + have hd : α + 3 ≠ 0 := by positivity + have hid : 10 - α * (1 - cubicPolarEnvelope α / 2) = + ((17 - α) * (31 * α ^ 3 + 287 * α ^ 2 + 829 * α) + 487 * α + 16200) / + (60 * (α + 3) ^ 3) := by + unfold cubicPolarEnvelope + field_simp + ring + have hn : 0 < (17 - α) * (31 * α ^ 3 + 287 * α ^ 2 + 829 * α) + + 487 * α + 16200 := by + have := mul_nonneg (sub_nonneg.mpr h17) + (show 0 ≤ 31 * α ^ 3 + 287 * α ^ 2 + 829 * α by positivity) + positivity + have hp : 0 < 10 - α * (1 - cubicPolarEnvelope α / 2) := by + rw [hid] + exact div_pos hn (by positivity) + linarith + +/-- Strict positivity at the envelope. Clearing the paper's u-expression gives +an all-positive numerator, so no strict integral premise is necessary. -/ +lemma cubicPolarEnvelope_quadratic_pos {α : ℝ} (hα : 0 < α) : + 0 < (α * cubicPolarEnvelope α / 2) ^ 2 / 7 + + 2 * (α + 3) * (α * cubicPolarEnvelope α / 2) - α ^ 2 := by + have hd : α + 3 ≠ 0 := by positivity + have hid : (α * cubicPolarEnvelope α / 2) ^ 2 / 7 + + 2 * (α + 3) * (α * cubicPolarEnvelope α / 2) - α ^ 2 = + α ^ 4 * (α ^ 4 + 360 * α ^ 3 + 2700 * α ^ 2 + 6480 * α + 4860) / + (25200 * (α + 3) ^ 6) := by + unfold cubicPolarEnvelope + field_simp + ring + rw [hid] + positivity + +/-- Full integral-to-log bridge, with the original weak inequality. -/ +lemma polar_le_log_sinh {α η : ℝ} (hα : 0 < α) (hη : η < 2) + (hpolar : 1 ≤ ∫ t in (0 : ℝ)..1, exp (α * (-1 + (2 - η) * t))) : + α * η / 2 ≤ log (sinh (α - α * η / 2) / (α - α * η / 2)) := by + rw [integral_exp_eq hα hη] at hpolar + have hc : α * (2 - η) / 2 = α - α * η / 2 := by ring + rw [hc, Real.exp_neg, inv_mul_eq_div, + le_div_iff₀ (Real.exp_pos (α * η / 2)), one_mul] at hpolar + calc + α * η / 2 = log (exp (α * η / 2)) := (Real.log_exp _).symm + _ ≤ log (sinh (α - α * η / 2) / (α - α * η / 2)) := + Real.log_le_log (Real.exp_pos _) hpolar + +/-- The original weak polar constraint implies the STRICT cubic envelope. +Both `7/8` and `8/7` in the strong hyperbolic estimate are used unchanged. -/ +theorem eta_lt_cubicPolarEnvelope {α η : ℝ} (hα : 0 < α) (h17 : α ≤ 17) + (hη0 : 0 ≤ η) (hη1 : η < 1) + (hpolar : 1 ≤ ∫ t in (0 : ℝ)..1, exp (α * (-1 + (2 - η) * t))) : + η < cubicPolarEnvelope α := by + by_contra hnot + have hηc : cubicPolarEnvelope α ≤ η := le_of_not_gt hnot + set p := α * η / 2 with hpdef + set x := α - p with hxdef + set pc := α * cubicPolarEnvelope α / 2 with hpcdef + have hp0 : 0 ≤ p := by dsimp [p]; positivity + have hpc0 : 0 ≤ pc := by + dsimp [pc] + exact div_nonneg (mul_nonneg hα.le (cubicPolarEnvelope_nonneg hα.le)) (by norm_num) + have hpcp : pc ≤ p := by dsimp [pc, p]; gcongr + have hx0 : 0 < x := by + dsimp [x, p] + nlinarith [mul_pos hα (sub_pos.mpr hη1)] + have hx10 : x < 10 := by + have hc := cubicPolarEnvelope_center_lt_ten hα.le h17 + have hxp : x ≤ α * (1 - cubicPolarEnvelope α / 2) := by + dsimp [x, p, pc] at * + nlinarith + exact hxp.trans_lt hc + have hlog : p ≤ log (sinh x / x) := polar_le_log_sinh hα (by linarith) hpolar + have hstrong : p ≤ (7 / 8 : ℝ) * (sqrt (9 + (8 / 7 : ℝ) * x ^ 2) - 3) := + hlog.trans (DistillationHyperbolic.log_sinh_div_le hx0 hx10.le) + have hroot : (8 / 7 : ℝ) * p + 3 ≤ sqrt (9 + (8 / 7 : ℝ) * x ^ 2) := by + linarith + have hsq : sqrt (9 + (8 / 7 : ℝ) * x ^ 2) ^ 2 = + 9 + (8 / 7 : ℝ) * x ^ 2 := Real.sq_sqrt (by positivity) + have hsquare : ((8 / 7 : ℝ) * p + 3) ^ 2 ≤ 9 + (8 / 7 : ℝ) * x ^ 2 := by + nlinarith [sq_nonneg (sqrt (9 + (8 / 7 : ℝ) * x ^ 2) - ((8 / 7 : ℝ) * p + 3)), + mul_nonneg (show 0 ≤ (8 / 7 : ℝ) * p + 3 by positivity) + (sub_nonneg.mpr hroot)] + have hF : p ^ 2 / 7 + 2 * (α + 3) * p - α ^ 2 ≤ 0 := by + rw [hxdef] at hsquare + nlinarith + have hFc : 0 < pc ^ 2 / 7 + 2 * (α + 3) * pc - α ^ 2 := + cubicPolarEnvelope_quadratic_pos hα + have hmono : pc ^ 2 ≤ p ^ 2 := pow_le_pow_left₀ hpc0 hpcp 2 + nlinarith [mul_nonneg (show 0 ≤ 2 * (α + 3) by positivity) + (sub_nonneg.mpr hpcp)] + +/-- Old `a,x,n` coordinates: eta's domain follows from the original weak +polar hypothesis via the already proved Bridge, rather than an extra premise. +The separate original alpha bound may supply `h17`. -/ +theorem actualEta_lt_cubicPolarEnvelope_of_polar {n : ℕ} (hn : 2 ≤ n) + {a x α : ℝ} (ha : 0 ≤ a) (ha1 : a < 1) (hx : x ^ 2 ≤ 1) + (hα : α = M n * (1 - a ^ 2) / 2) (h17 : α ≤ 17) + (hpolar : 1 ≤ ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) : + QQ (a * x) (a ^ 2) 1 < cubicPolarEnvelope α := by + have hη := actualEta_mem_Ico_of_polar hn ha ha1 hx hα hpolar + exact eta_lt_cubicPolarEnvelope (alpha_pos hn ha1 ha hα) h17 hη.1 hη.2 + (polar_exp hn hx hα hpolar) + +end Sendov diff --git a/Sendov/Reduction/CubicScalar.lean b/Sendov/Reduction/CubicScalar.lean new file mode 100644 index 0000000..589fd84 --- /dev/null +++ b/Sendov/Reduction/CubicScalar.lean @@ -0,0 +1,48 @@ +import Sendov.Reduction.Alpha17 +import Sendov.Reduction.CubicPolar + +/-! +# Raw polar and origin inequalities imply the cubic scalar obstruction + +This is the geometric-to-scalar reduction for degrees at least six. It consumes +only the original weak polar integral and original origin inequality. In +particular, the alpha range and eta domain are conclusions, not extra inputs. + +The analytic origin reduction remains `one_le_of_origin` in `Simplified`, via +`one_le_scalarObstruction_of_polar_origin`. The strict cubic polar bound and +eta monotonicity then enlarge the actual scalar obstruction. No finite-range +certificate, tail bound, or old `R` enlargement is used here. +-/ + +namespace Sendov + +/-- The four facts required by the cubic finite/tail endgame, all derived from +raw geometric inputs. The final conjunction is a lower bound, not a premise. -/ +theorem cubicScalar_constraints_of_polar_origin {n : ℕ} (hn : 6 ≤ n) {a x α : ℝ} + (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 ≤ 1) + (hα : α = M n * (1 - a ^ 2) / 2) + (hpolar : 1 ≤ ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) + (horigin : 2 * α + a * x ≤ (1 - x ^ 2) / (2 * M n) + + a ^ 2 * n * M n * ∫ t in (0 : ℝ)..1, + t * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2)) : + (0 < α) ∧ (2 * α ≤ M n) ∧ (α ≤ 17) ∧ + (1 ≤ scalarObstruction (M n) α (cubicPolarEnvelope α)) := by + have hn2 : 2 ≤ n := by omega + have hn5 : 5 ≤ n := by omega + have hm : 5 ≤ M n := by + have hnR : (6 : ℝ) ≤ n := by exact_mod_cast hn + unfold M + linarith + have hα0 := alpha_pos hn2 ha1 ha.le hα + have hhalf : 2 * α ≤ M n := by linarith [alpha_le_half hn2 hα] + have hη := actualEta_mem_Ico_of_polar hn2 ha.le ha1 hx hα hpolar + have hlt := polar_exp hn2 hx hα hpolar + have hbeta := beta_le hα0 hη.1 hlt + have hlog := log_le_alpha_mul hα0 hη.2.le hlt + have h17 := alpha_le_seventeen hn5 ha ha1 hx hα hbeta hlog horigin + have hactual := one_le_scalarObstruction_of_polar_origin hn5 ha ha1 hx hα hpolar horigin + have hcubic := actualEta_lt_cubicPolarEnvelope_of_polar hn2 ha.le ha1 hx hα h17 hpolar + exact ⟨hα0, hhalf, h17, hactual.trans + (scalarObstruction_mono_eta hm hα0 hη.1 hcubic.le (cubicPolarEnvelope_lt_one hα0.le))⟩ + +end Sendov diff --git a/Sendov/Reduction/DistillationBridge.lean b/Sendov/Reduction/DistillationBridge.lean new file mode 100644 index 0000000..e49fd70 --- /dev/null +++ b/Sendov/Reduction/DistillationBridge.lean @@ -0,0 +1,169 @@ +import Sendov.Common.DistillationEnvelope +import Sendov.Reduction.Simplified + +/-! +# Actual scalar data and the distillation obstruction + +New Lean proofs of the coordinate change and eta comparison in Section 2 of +Senjian An, *Proof Distillation for Sendov's Conjecture*, revision +`e8ae601491ec171ab4f7f8456113dd6a047aa85d` (paper CC BY 4.0, +https://creativecommons.org/licenses/by/4.0/). + +The actual-data equality uses the existing `A_eq_sq` and `mul_eq_c` interfaces. +The origin wrapper converts `one_le_of_origin` directly into the scalar obstruction. +The polar wrapper uses the weak input `1 ≤ integral` to obtain eta < 1. +The strict cubic envelope and finite closure are established in downstream modules. +-/ + +namespace Sendov + +open MeasureTheory + +/-- Nonnegativity of the weighted integral on the enlarged scalar domain. -/ +lemma integral_polarKernel_nonneg {m α η r : ℝ} (hm : 0 ≤ m) + (hα : 0 ≤ α) (hη : 0 ≤ η) (k : ℕ) : + 0 ≤ ∫ t in (0 : ℝ)..1, t ^ k * polarKernel m α η t ^ r := by + refine intervalIntegral.integral_nonneg (by norm_num) ?_ + intro t ht + exact mul_nonneg (pow_nonneg ht.1 k) + (Real.rpow_nonneg (polarKernel_nonneg hm hα hη ht) r) + +/-- The squared factor stays nonnegative, including at alpha = m/2. -/ +lemma scalarObstruction_prefactor_nonneg {m α η : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hη : 0 ≤ η) : + 0 ≤ η * (m ^ 2 - 1) * (m - 2 * α) ^ 2 / (4 * α * m) := by + have hm0 : 0 ≤ m := by linarith + have hm2 : 0 ≤ m ^ 2 - 1 := by nlinarith + positivity + +/-- The full obstruction increases with eta. Both the coefficient and the +integral are compared, with their signs proved, not presumed from the formula. -/ +lemma scalarObstruction_mono_eta {m α η₁ η₂ : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hη₁ : 0 ≤ η₁) (hη : η₁ ≤ η₂) (hη₂ : η₂ < 1) : + scalarObstruction m α η₁ ≤ scalarObstruction m α η₂ := by + have hm0 : 0 ≤ m := by linarith + have hm2 : 0 ≤ m ^ 2 - 1 := by nlinarith + have hη₂0 : 0 ≤ η₂ := hη₁.trans hη + have hr : 0 ≤ (m - 3) / 2 := by linarith + have hd₁ : 0 < 2 * α * (1 - η₁) := + mul_pos (by positivity) (by linarith) + have hd₂ : 0 < 2 * α * (1 - η₂) := + mul_pos (by positivity) (by linarith) + have he₁ : η₁ / (2 * α * (1 - η₁)) ≤ η₂ / (2 * α * (1 - η₂)) := by + rw [div_le_div_iff₀ hd₁ hd₂] + nlinarith [mul_nonneg hα.le (sub_nonneg.mpr hη)] + have he₂ : η₁ / (4 * α) ≤ η₂ / (4 * α) := + div_le_div_of_nonneg_right hη (by positivity) + have he₄ : η₁ / (4 * α * m) ≤ η₂ / (4 * α * m) := + div_le_div_of_nonneg_right hη (by positivity) + have hk : η₁ * (m ^ 2 - 1) * (m - 2 * α) ^ 2 / (4 * α * m) ≤ + η₂ * (m ^ 2 - 1) * (m - 2 * α) ^ 2 / (4 * α * m) := by + gcongr + have hi := integral_polarKernel_mono_eta hm0 hα.le hη₁ hη hr 3 + have hi0 := integral_polarKernel_nonneg (r := (m - 3) / 2) hm0 hα.le hη₁ 3 + have hk0 := scalarObstruction_prefactor_nonneg hm hα hη₂0 + have hlast := mul_le_mul hk hi hi0 hk0 + unfold scalarObstruction + linarith + +/-- Exact actual-data coordinates; no polar or origin inequality is required. -/ +lemma polarKernel_actual {n : ℕ} {a x α : ℝ} (hn : 2 ≤ n) + (hα : α = M n * (1 - a ^ 2) / 2) (t : ℝ) : + polarKernel (M n) α (QQ (a * x) (a ^ 2) 1) t = QQ (a * x) (a ^ 2) t := by + rw [polarKernel_eq_QQ] + have hc := mul_eq_c (x := x) hn hα + have hA := A_eq_sq hn hα + change 1 - 2 * α / M n = a ^ 2 at hA + rw [hA, show 1 - α / M n - QQ (a * x) (a ^ 2) 1 / 2 = a * x by linarith] + +/-- The raw RHS of `(1le)` is exactly H at actual eta, not H at the old envelope. -/ +lemma scalarObstruction_actual_eq {n : ℕ} {a x α : ℝ} (hn : 2 ≤ n) + (hα : α = M n * (1 - a ^ 2) / 2) : + scalarObstruction (M n) α (QQ (a * x) (a ^ 2) 1) = + QQ (a * x) (a ^ 2) 1 / (2 * α * (1 - QQ (a * x) (a ^ 2) 1)) + + QQ (a * x) (a ^ 2) 1 / (4 * α) + 1 / (2 * M n) + + QQ (a * x) (a ^ 2) 1 / (4 * α * M n) + + (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) * QQ (a * x) (a ^ 2) 1 / (4 * α) + * ∫ t in (0 : ℝ)..1, t ^ 3 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 4) / 2) := by + have hm : M n ≠ 0 := (M_pos hn).ne' + have hA := A_eq_sq hn hα + have hs : M n - 2 * α = M n * a ^ 2 := by + change 1 - 2 * α / M n = a ^ 2 at hA + field_simp at hA + nlinarith [hA] + have hk : QQ (a * x) (a ^ 2) 1 * (M n ^ 2 - 1) * (M n - 2 * α) ^ 2 / + (4 * α * M n) = + (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) * QQ (a * x) (a ^ 2) 1 / (4 * α) := by + rw [hs] + by_cases ha0 : α = 0 + · simp [ha0] + · field_simp + unfold M + ring + have hi : (∫ t in (0 : ℝ)..1, + t ^ 3 * polarKernel (M n) α (QQ (a * x) (a ^ 2) 1) t ^ ((M n - 3) / 2)) = + ∫ t in (0 : ℝ)..1, t ^ 3 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 4) / 2) := by + apply intervalIntegral.integral_congr + intro t _ht + dsimp only + rw [polarKernel_actual hn hα] + congr 2 + unfold M + ring + unfold scalarObstruction + rw [hk, hi] + +/-- Direct `(1le)` bridge. The sole analytic input is the original weak inequality. -/ +theorem one_le_scalarObstruction_of_one_le {n : ℕ} {a x α : ℝ} (hn : 2 ≤ n) + (hα : α = M n * (1 - a ^ 2) / 2) + (h1le : 1 ≤ QQ (a * x) (a ^ 2) 1 / (2 * α * (1 - QQ (a * x) (a ^ 2) 1)) + + QQ (a * x) (a ^ 2) 1 / (4 * α) + 1 / (2 * M n) + + QQ (a * x) (a ^ 2) 1 / (4 * α * M n) + + (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) * QQ (a * x) (a ^ 2) 1 / (4 * α) + * ∫ t in (0 : ℝ)..1, t ^ 3 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 4) / 2)) : + 1 ≤ scalarObstruction (M n) α (QQ (a * x) (a ^ 2) 1) := by + rw [scalarObstruction_actual_eq hn hα] + exact h1le + +/-- Consume the existing raw origin reduction, before the old R enlargement. -/ +theorem one_le_scalarObstruction_of_origin {n : ℕ} (hn : 5 ≤ n) {a x α : ℝ} + (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 ≤ 1) + (hα : α = M n * (1 - a ^ 2) / 2) (hη : QQ (a * x) (a ^ 2) 1 < 1) + (horigin : 2 * α + a * x ≤ (1 - x ^ 2) / (2 * M n) + + a ^ 2 * n * M n * ∫ t in (0 : ℝ)..1, + t * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2)) : + 1 ≤ scalarObstruction (M n) α (QQ (a * x) (a ^ 2) 1) := by + have hn2 : 2 ≤ n := by omega + have hα0 := alpha_pos hn2 ha1 ha.le hα + exact one_le_scalarObstruction_of_one_le hn2 hα + (one_le_of_origin hn ha ha1 hx hα hα0 hη horigin) + +/-- The OLD polar upper bound already puts actual eta in the monotonicity domain. +The polar premise is `1 ≤ integral`, not the paper's strict inequality. -/ +lemma actualEta_mem_Ico_of_polar {n : ℕ} (hn : 2 ≤ n) {a x α : ℝ} + (ha : 0 ≤ a) (ha1 : a < 1) (hx : x ^ 2 ≤ 1) + (hα : α = M n * (1 - a ^ 2) / 2) + (hpolar : 1 ≤ ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) : + QQ (a * x) (a ^ 2) 1 ∈ Set.Ico (0 : ℝ) 1 := by + have hα0 := alpha_pos hn ha1 ha hα + have hf : (a * x) ^ 2 ≤ a ^ 2 := by nlinarith [sq_nonneg a] + have hη0 := QQ_nonneg hf 1 + have hb := beta_le hα0 hη0 (polar_exp hn hx hα hpolar) + refine ⟨hη0, hb.trans_lt ?_⟩ + exact (div_lt_one (by linarith : 0 < 3 + α)).mpr (by linarith) + +/-- Actual old-parameter wrapper: neither eta < 1 nor `(1le)` is left as an +extra premise. These follow from the original weak polar and origin inputs. -/ +theorem one_le_scalarObstruction_of_polar_origin {n : ℕ} (hn : 5 ≤ n) {a x α : ℝ} + (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 ≤ 1) + (hα : α = M n * (1 - a ^ 2) / 2) + (hpolar : 1 ≤ ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) + (horigin : 2 * α + a * x ≤ (1 - x ^ 2) / (2 * M n) + + a ^ 2 * n * M n * ∫ t in (0 : ℝ)..1, + t * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2)) : + 1 ≤ scalarObstruction (M n) α (QQ (a * x) (a ^ 2) 1) := by + have hn2 : 2 ≤ n := by omega + exact one_le_scalarObstruction_of_origin hn ha ha1 hx hα + (actualEta_mem_Ico_of_polar hn2 ha.le ha1 hx hα hpolar).2 horigin + +end Sendov diff --git a/Sendov/Reduction/Main.lean b/Sendov/Reduction/Main.lean index 7aa694d..ec107a8 100644 --- a/Sendov/Reduction/Main.lean +++ b/Sendov/Reduction/Main.lean @@ -3,87 +3,31 @@ Copyright (c) 2026 Terence Tao. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Terence Tao -/ -import Sendov.Reduction.Alpha17 -import Sendov.Main +import Sendov.Reduction.CubicScalar +import Sendov.Common.DistillationBounds /-! -# The polar and origin inequalities are incompatible +# Polar/origin incompatibility through the cubic scalar obstruction -This is the top of the development. The blog post's argument, after the complex-analytic part -that is not formalized here, produces two inequalities about a degree `n`, a zero `0 < a < 1` -and the real part `x` of the mean of the reciprocal critical-point data: - -* the **raw polar inequality** `(1Q)`, `1 ≤ ∫₀¹ P(t)^((n-1)/2) dt`; -* the **raw origin inequality** `(origin-exact)`. - -`Sendov.polar_origin_incompatible` says they cannot both hold for `n ≥ 5`. Neither statement -mentions a polynomial or a complex number, so the theorem is a self-contained assertion about -two real numbers. - -## The chain - -``` - polar_exp beta_le - (1Q) ─────────────────────▶ (lt) ─────────────────▶ β(1) ≤ α/(3+α) - │ │ - │ log_le_alpha_mul │ - ▼ │ - log α ≤ α(1-β(1)) │ - │ │ - (origin-exact) ─────────────────┴──────────────────▶ α ≤ 17 │ - │ alpha_le_seventeen │ - │ one_le_of_origin │ - ▼ ▼ - (1le) ───────────────────────────────────────────▶ 1 ≤ R n α - stat_of_one_le │ - │ stat_lt_one - ▼ - False -``` - -Both halves of `(beta-bound)` are needed, and each is used exactly once: the rational half -`β(1) ≤ α/(3+α)` by `Sendov.stat_of_one_le`, to substitute for `β(1)` in `(1le)`, and the -logarithmic half by `Sendov.alpha_le_seventeen`, to bound `1/x²`. - -## Main statements - -* `Sendov.polar_origin_incompatible`: the two raw inequalities have no common solution. +For `n ≥ 6`, the original geometric hypotheses produce the scalar domain and +`1 ≤ H`. The complete finite/tail bound proves `H < 1` on that same domain. +Degrees two through five are handled directly by the low-degree analytic argument +in `Interior`; no old `R` certificate route is needed. -/ namespace Sendov -open MeasureTheory - -/-- **The polar and origin inequalities are incompatible.** For `n ≥ 5` there is no -`0 < a < 1` and `|x| ≤ 1` satisfying both the raw polar inequality `(1Q)` and the raw origin -inequality `(origin-exact)`. -/ -theorem polar_origin_incompatible {n : ℕ} (hn : 5 ≤ n) {a x α : ℝ} +/-- The original polar and origin inequalities are incompatible in degrees at +least six. No scalar inequality is assumed as an extra hypothesis. -/ +theorem polar_origin_incompatible {n : ℕ} (hn : 6 ≤ n) {a x α : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 ≤ 1) (hα : α = M n * (1 - a ^ 2) / 2) (hpolar : 1 ≤ ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) (horigin : 2 * α + a * x ≤ (1 - x ^ 2) / (2 * M n) - + a ^ 2 * n * M n * ∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2)) : - False := by - have hn2 : 2 ≤ n := by omega - have hα0 : 0 < α := alpha_pos hn2 ha1 ha.le hα - have h3 : (0 : ℝ) < 3 + α := by linarith - have hfeas : (a * x) ^ 2 ≤ a ^ 2 := by nlinarith [sq_nonneg a, sq_nonneg x] - have hB0 : 0 ≤ QQ (a * x) (a ^ 2) 1 := QQ_nonneg hfeas 1 - -- `(1Q) ⟹ (lt) ⟹ (beta-bound)`, both halves - have hlt := polar_exp hn2 hx hα hpolar - have hbeta : QQ (a * x) (a ^ 2) 1 ≤ α / (3 + α) := beta_le hα0 hB0 hlt - have hB1lt : QQ (a * x) (a ^ 2) 1 < 1 := by - have : α / (3 + α) < 1 := by rw [div_lt_one h3]; linarith - linarith - have hlogb : Real.log α ≤ α * (1 - QQ (a * x) (a ^ 2) 1) := - log_le_alpha_mul hα0 hB1lt.le hlt - -- `α ≤ 17` - have h17 : α ≤ 17 := alpha_le_seventeen hn ha ha1 hx hα hbeta hlogb horigin - -- `(origin-exact) ⟹ (1le) ⟹ stat` - have h1le := one_le_of_origin hn ha ha1 hx hα hα0 hB1lt horigin - have hstat : 1 ≤ R n α := stat_of_one_le hn hx hα hα0 hbeta h1le - -- but `stat` is false - exact absurd hstat - (not_le.2 (stat_lt_one hn hα0.le h17 (feasible_of_beta hn2 hx hα hα0 hbeta))) + + a ^ 2 * n * M n * ∫ t in (0 : ℝ)..1, + t * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2)) : False := by + obtain ⟨hpos, hhalf, h17, hlower⟩ := + cubicScalar_constraints_of_polar_origin hn ha ha1 hx hα hpolar horigin + exact (not_lt_of_ge hlower) (distillScalar_lt_one hn hpos h17 hhalf) end Sendov diff --git a/Sendov/Reduction/Setup.lean b/Sendov/Reduction/Setup.lean index 5f027b3..eced975 100644 --- a/Sendov/Reduction/Setup.lean +++ b/Sendov/Reduction/Setup.lean @@ -6,31 +6,11 @@ Authors: Terence Tao import Sendov.Common.Chord /-! -# The raw inequalities, and the dictionary between them and `Sendov.R` +# Actual polar/origin coordinates -`Sendov.stat_lt_one` refutes equation `stat` of the blog post. `stat` is itself deduced there -from two inequalities that come out of the complex-analytic part of the argument: - -* the **raw polar inequality** `(1Q)`, `1 ≤ ∫₀¹ P(t)^((n-1)/2) dt` with - `P(t) = a² + 2atx(1-a²) + t²(1-a²)²`; -* the **raw origin inequality** `(origin-exact)`, - `2α + ax ≤ (1-x²)/(2(n-1)) + a²n(n-1) ∫₀¹ t β(t)^((n-2)/2) dt`. - -Both are statements about two real numbers `a ∈ (0,1)` and `x ∈ [-1,1]` and a degree `n`; no -polynomial, no complex number and no `q_j` survives into them. That is what makes the next -target — that the two are not simultaneously satisfiable for `n ≥ 5` — a self-contained -real-variable statement. - -This file fixes `P` and records the dictionary. The key entry is that `α` and `a` determine -each other: with `α = (n-1)(1-a²)/2` one has `A n α = a²` *exactly*, so the `A` of -`Sendov.Defs` and the `a²` of the blog post are the same thing, and `β(t)` is -`Sendov.QQ (a*x) (a^2) t` while `Q n α t` is `Sendov.QQ (c n α) (A n α) t`. - -## Main statements - -* `Sendov.Ppolar_eq`: `P` as a sum of squares, hence nonnegative for `|x| ≤ 1`; -* `Sendov.A_eq_sq`: `A n α = a²`; -* `Sendov.alpha_pos`, `Sendov.alpha_le_half`: the range of `α`. +The raw polar kernel, `A_eq_sq`, and `mul_eq_c` describe actual data, not an enlarged scalar +obstruction. +Positivity and the half-degree bound for alpha are shared by the selected reduction. -/ namespace Sendov @@ -61,6 +41,14 @@ lemma A_eq_sq (hn : 2 ≤ n) (hα : α = M n * (1 - a ^ 2) / 2) : A n α = a ^ 2 field_simp ring +/-- `ax = 1 - β(1)/2 - α/(n-1)`: the blog post's rearrangement of `β(1) = 1 - 2ax + a²`. -/ +lemma mul_eq_c (hn : 2 ≤ n) (hα : α = M n * (1 - a ^ 2) / 2) : + a * x = 1 - QQ (a * x) (a ^ 2) 1 / 2 - α / M n := by + have hM : M n ≠ 0 := (M_pos hn).ne' + simp only [QQ, hα] + field_simp + ring + lemma alpha_pos (hn : 2 ≤ n) (ha1 : a < 1) (_ha0 : 0 ≤ a) (hα : α = M n * (1 - a ^ 2) / 2) : 0 < α := by have hM : 0 < M n := M_pos hn diff --git a/Sendov/Reduction/Simplified.lean b/Sendov/Reduction/Simplified.lean index 5b7199a..46d611b 100644 --- a/Sendov/Reduction/Simplified.lean +++ b/Sendov/Reduction/Simplified.lean @@ -3,7 +3,7 @@ Copyright (c) 2026 Terence Tao. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Terence Tao -/ -import Sendov.Reduction.Stat +import Sendov.Reduction.BetaBound /-! # From the raw origin inequality to its `α`, `β(1)` form @@ -12,7 +12,7 @@ This is `(origin-exact) + (beta-bound) ⟹ (1le)`. The work is in replacing `∫₀¹ t β(t)^((n-2)/2) dt` -by a Beta value plus the `t³` integral that `stat` is stated with. Writing `β` as a sum of +by a Beta value plus the `t³` integral used in the scalar obstruction. Writing `β` as a sum of squares, `β(t) = (1-axt)² + a²t²(1-x²)`, the blog post applies the mean value theorem to `s ↦ ((1-axt)² + s)^((n-2)/2)`. Here that step is Bernoulli's inequality instead: dividing diff --git a/Sendov/Reduction/Stat.lean b/Sendov/Reduction/Stat.lean deleted file mode 100644 index b500597..0000000 --- a/Sendov/Reduction/Stat.lean +++ /dev/null @@ -1,133 +0,0 @@ -/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.Reduction.BetaBound - -/-! -# From `(1le)` to `stat` - -This is `(1le) + (beta-bound) ⟹ stat`. The right-hand side of `(1le)`, - - `β(1)/(2α(1-β(1))) + β(1)/(4α) + 1/(2(n-1)) + β(1)/(4α(n-1))` - `+ a⁴ n(n-1)(n-2) β(1)/(4α) ∫₀¹ t³ β(t)^((n-4)/2) dt`, - -is monotone increasing in `β(1)`, so `(beta-bound)` lets `β(1)` be replaced throughout by -`α/(3+α)`. Under that substitution every term becomes the corresponding term of `Sendov.R`: -`β(1)/(2α(1-β(1)))` becomes `1/6`, `β(1)/(4α)` becomes `1/(4(3+α))`, and `ax`, which is -`1 - β(1)/2 - α/(n-1)`, becomes exactly `Sendov.c n α`. - -Monotonicity of the integral term is the only part that is not immediate. `ax` *decreases* as -`β(1)` grows, and `Sendov.QQ` decreases in its first argument on `[0,1]`, so the integrand -grows — `Sendov.integral_QQ_anti`. Nonnegativity of `β(t)` is needed only at the actual value -`ax`, where it is `(ax)² ≤ a²`, i.e. `x² ≤ 1`; at the substituted value it comes free from the -pointwise comparison, the same way `Sendov.integral_anti` gets it in the batching argument. - -## Main statements - -* `Sendov.mul_eq_c`: `ax = 1 - β(1)/2 - α/(n-1)`, and hence `c n α ≤ ax` under `(beta-bound)`; -* `Sendov.stat_of_one_le`: `(1le) + (beta-bound) ⟹ 1 ≤ R n α`. --/ - -namespace Sendov - -open MeasureTheory - -variable {n : ℕ} {a x α : ℝ} - -/-- `ax = 1 - β(1)/2 - α/(n-1)`: the blog post's rearrangement of `β(1) = 1 - 2ax + a²`. -/ -lemma mul_eq_c (hn : 2 ≤ n) (hα : α = M n * (1 - a ^ 2) / 2) : - a * x = 1 - QQ (a * x) (a ^ 2) 1 / 2 - α / M n := by - have hM : M n ≠ 0 := (M_pos hn).ne' - simp only [QQ, hα] - field_simp - ring - -/-- Under `(beta-bound)`, `Sendov.c n α ≤ ax`: the substitution only ever lowers `ax`. -/ -lemma c_le_mul (hn : 2 ≤ n) (hα : α = M n * (1 - a ^ 2) / 2) (hα0 : 0 < α) - (hbeta : QQ (a * x) (a ^ 2) 1 ≤ α / (3 + α)) : c n α ≤ a * x := by - rw [mul_eq_c hn hα] - simp only [c] - have h3 : (0 : ℝ) < 3 + α := by linarith - have : α / (2 * (3 + α)) = (α / (3 + α)) / 2 := by field_simp - rw [this] - linarith - -/-- `(beta-bound)` supplies the feasibility constraint `c² ≤ A` that `Sendov.stat_lt_one` -requires. It is `c ≤ ax` squared, together with `x² ≤ 1`: the substitution can only lower -`ax`, and `ax` is already at most `a`. -/ -lemma feasible_of_beta (hn : 2 ≤ n) (hx : x ^ 2 ≤ 1) - (hα : α = M n * (1 - a ^ 2) / 2) (hα0 : 0 < α) - (hbeta : QQ (a * x) (a ^ 2) 1 ≤ α / (3 + α)) : c n α ^ 2 ≤ A n α := by - have hcpos : 0 < c n α := c_pos_of_le_half_M hn hα0.le (alpha_le_half hn hα) - have hcle : c n α ≤ a * x := c_le_mul hn hα hα0 hbeta - rw [A_eq_sq hn hα] - nlinarith [hcpos, hcle, sq_nonneg a, sq_nonneg x] - -/-- **`(1le) + (beta-bound) ⟹ stat`.** -/ -theorem stat_of_one_le (hn : 5 ≤ n) (hx : x ^ 2 ≤ 1) - (hα : α = M n * (1 - a ^ 2) / 2) (hα0 : 0 < α) - (hbeta : QQ (a * x) (a ^ 2) 1 ≤ α / (3 + α)) - (h1le : 1 ≤ QQ (a * x) (a ^ 2) 1 / (2 * α * (1 - QQ (a * x) (a ^ 2) 1)) - + QQ (a * x) (a ^ 2) 1 / (4 * α) - + 1 / (2 * M n) - + QQ (a * x) (a ^ 2) 1 / (4 * α * M n) - + (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) * QQ (a * x) (a ^ 2) 1 / (4 * α) - * ∫ t in (0 : ℝ)..1, t ^ 3 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 4) / 2)) : - 1 ≤ R n α := by - have hn2 : 2 ≤ n := by omega - have hM : (0 : ℝ) < M n := M_pos hn2 - have h3 : (0 : ℝ) < 3 + α := by linarith - have hA : A n α = a ^ 2 := A_eq_sq hn2 hα - set B1 : ℝ := QQ (a * x) (a ^ 2) 1 with hB1 - -- the standing facts about `β(1)` - have hfeas : (a * x) ^ 2 ≤ a ^ 2 := by nlinarith [sq_nonneg a, sq_nonneg x] - have hB0 : 0 ≤ B1 := QQ_nonneg hfeas 1 - have hkey : B1 * (3 + α) ≤ α := by - rw [← le_div_iff₀ h3]; exact hbeta - have hB1lt : B1 < 1 := by nlinarith [hα0, hB0] - -- the four elementary terms - have t1 : B1 / (2 * α * (1 - B1)) ≤ 1 / 6 := by - rw [div_le_div_iff₀ (by nlinarith) (by norm_num)] - nlinarith [hkey, hB0, hα0] - have t2 : B1 / (4 * α) ≤ 1 / (4 * (3 + α)) := by - rw [div_le_div_iff₀ (by linarith) (by linarith)] - nlinarith [hkey] - have t4 : B1 / (4 * α * M n) ≤ 1 / (4 * M n * (3 + α)) := by - -- This is the same scalar bound as `t2`, divided by the positive `M`. - simpa only [div_div, mul_assoc, mul_comm, mul_left_comm] using - div_le_div_of_nonneg_right t2 hM.le - -- the integral term - have hcle : c n α ≤ a * x := c_le_mul hn2 hα hα0 hbeta - have hr : (0 : ℝ) ≤ ((n : ℝ) - 4) / 2 := by - have : (5 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn - linarith - have hI : (∫ t in (0 : ℝ)..1, t ^ 3 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 4) / 2)) - ≤ ∫ t in (0 : ℝ)..1, t ^ 3 * QQ (c n α) (a ^ 2) t ^ (((n : ℝ) - 4) / 2) := - integral_QQ_anti hcle hfeas hr 3 - have hInn : (0 : ℝ) ≤ ∫ t in (0 : ℝ)..1, t ^ 3 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 4) / 2) := by - refine intervalIntegral.integral_nonneg (by norm_num) ?_ - intro u hu - exact mul_nonneg (pow_nonneg hu.1 3) (Real.rpow_nonneg (QQ_nonneg hfeas u) _) - have hpre : (0 : ℝ) ≤ (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) := by - have : (5 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn - have h2 : (0 : ℝ) ≤ (n : ℝ) - 2 := by linarith - positivity - have t5 : (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) * B1 / (4 * α) - * (∫ t in (0 : ℝ)..1, t ^ 3 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 4) / 2)) - ≤ A n α ^ 2 * n * M n * ((n : ℝ) - 2) / (4 * (3 + α)) - * ∫ t in (0 : ℝ)..1, t ^ 3 * Q n α t ^ (((n : ℝ) - 4) / 2) := by - have hcoef : (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) * B1 / (4 * α) - ≤ A n α ^ 2 * n * M n * ((n : ℝ) - 2) / (4 * (3 + α)) := by - rw [hA] - simpa only [← mul_div_assoc, mul_one] using mul_le_mul_of_nonneg_left t2 hpre - have hcnn : (0 : ℝ) ≤ A n α ^ 2 * n * M n * ((n : ℝ) - 2) / (4 * (3 + α)) := by - rw [hA]; positivity - -- Both the coefficient and the integral increase under the substitution. - apply mul_le_mul hcoef ?_ hInn hcnn - simpa only [Q_eq_QQ, hA] using hI - rw [R] - linarith - -end Sendov diff --git a/data/LICENSE-PAPER.txt b/data/LICENSE-PAPER.txt new file mode 100644 index 0000000..17e6f80 --- /dev/null +++ b/data/LICENSE-PAPER.txt @@ -0,0 +1,15 @@ +Creative Commons Attribution 4.0 International + +This work is licensed under the Creative Commons Attribution 4.0 International License. + +You are free to: +- Share — copy and redistribute the material in any medium or format. +- Adapt — remix, transform, and build upon the material for any purpose, even commercially. + +Under the following terms: +- Attribution — You must give appropriate credit, provide a link to the license, and indicate if changes were made. + +No additional restrictions — You may not apply legal terms or technological measures that legally restrict others from doing anything the license permits. + +The full legal code is available at: +https://creativecommons.org/licenses/by/4.0/legalcode diff --git a/data/README.md b/data/README.md new file mode 100644 index 0000000..3bcdd18 --- /dev/null +++ b/data/README.md @@ -0,0 +1,17 @@ +# Exact mathematical table + +`paper_certificate_table.json` is the unchanged mathematical certificate table +from Senjian An, *Proof Distillation for Sendov's Conjecture*, +[SJanPerth/Sendov-Proof-Distillation](https://github.com/SJanPerth/Sendov-Proof-Distillation/blob/e8ae601491ec171ab4f7f8456113dd6a047aa85d/verification/paper_certificate_table.json), +fixed revision **e8ae601491ec171ab4f7f8456113dd6a047aa85d**. + +The mathematical paper/table is attributed under +[Creative Commons Attribution 4.0 International](https://creativecommons.org/licenses/by/4.0/); +`LICENSE-PAPER.txt` retains the source's notice and legal-code link. No table +values, row order, component order or budgets were changed. The project generates +its own Lean certificate source; the table itself is not a formal proof. + +The upstream verification **code** has a separate MIT license. The small rational +checks adapted in `scripts/distillation_data.py` retain its notice in +`scripts/LICENSE-DISTILLATION-MIT.txt`; this does not relicense the mathematical +table as MIT or imply adoption of an upstream formal proof. diff --git a/data/paper_certificate_table.json b/data/paper_certificate_table.json new file mode 100644 index 0000000..3b750f0 --- /dev/null +++ b/data/paper_certificate_table.json @@ -0,0 +1,2851 @@ +[ + { + "m": 5, + "e": "11/30", + "components": [ + { + "index": 0, + "k": "2", + "lo": "1/2", + "hi": "3/4", + "u": 202, + "sq": "345663626000976562500000000000000/8532694281700697952441690868675249", + "sign_lo": "53567739/16", + "sign_hi": "-3208672845/2048" + }, + { + "index": 1, + "k": "0", + "lo": "0", + "hi": "1/4", + "u": 191, + "sq": "1071869163584569/29460504150390625", + "sign_lo": "-6269400", + "sign_hi": "766217111/1024" + }, + { + "index": 2, + "k": "2", + "lo": "1/2", + "hi": "3/4", + "u": 148, + "sq": "1121025015543257344/51519870758056640625", + "sign_lo": "-4359/2", + "sign_hi": "185031/64" + } + ], + "total": "2723/3000" + }, + { + "m": 6, + "e": "25/72", + "components": [ + { + "index": 0, + "k": "4", + "lo": "1", + "hi": "5/4", + "u": 207, + "sq": "10952359114935356720621750831675535140625/256807730774197088470206908996036412826624", + "sign_lo": "351048", + "sign_hi": "-758195025/64" + }, + { + "index": 1, + "k": "2", + "lo": "1/2", + "hi": "3/4", + "u": 171, + "sq": "5460665625610299/186920166015625000", + "sign_lo": "-38556423/8", + "sign_hi": "18990256815/1024" + }, + { + "index": 2, + "k": "3", + "lo": "3/4", + "hi": "1", + "u": 133, + "sq": "535464208891258298351/30720000000000000000000", + "sign_lo": "-298485/64", + "sign_hi": "2036" + } + ], + "total": "1931/2250" + }, + { + "m": 7, + "e": "1/3", + "components": [ + { + "index": 0, + "k": "5", + "lo": "5/4", + "hi": "3/2", + "u": 211, + "sq": "2811248271174366670825003329000000/63645499797462270227236485163847641", + "sign_lo": "9906562865/2048", + "sign_hi": "-185130279/16" + }, + { + "index": 1, + "k": "3", + "lo": "3/4", + "hi": "1", + "u": 164, + "sq": "1182743499424270247438801761/44100000000000000000000000000", + "sign_lo": "-20336773761/1024", + "sign_hi": "16145814" + }, + { + "index": 2, + "k": "4", + "lo": "1", + "hi": "5/4", + "u": 124, + "sq": "7416843437532623565289/483250188447852963840000", + "sign_lo": "-8442", + "sign_hi": "7555/64" + } + ], + "total": "2497/3000" + }, + { + "m": 8, + "e": "31/96", + "components": [ + { + "index": 0, + "k": "6", + "lo": "3/2", + "hi": "7/4", + "u": 215, + "sq": "148679430010467133298528786361621248632422400/3245952473515737982582781571806215372528951009", + "sign_lo": "106446393/8", + "sign_hi": "-8249772043/1024" + }, + { + "index": 1, + "k": "5", + "lo": "5/4", + "hi": "3/2", + "u": 157, + "sq": "377798596060495643265896750563477/15393232568314800000000000000000000", + "sign_lo": "-47198835/1024", + "sign_hi": "722525751/8" + }, + { + "index": 2, + "k": "6", + "lo": "3/2", + "hi": "7/4", + "u": 120, + "sq": "1538332665048978711275164426348211243/107571644398449235770918120000000000000", + "sign_lo": "-3159", + "sign_hi": "673123/64" + } + ], + "total": "9779/12000" + }, + { + "m": 9, + "e": "17/54", + "components": [ + { + "index": 0, + "k": "8", + "lo": "2", + "hi": "9/4", + "u": 220, + "sq": "139256190123085451332946176/2879809196797970285606555625", + "sign_lo": "546300", + "sign_hi": "-85403336337/2048" + }, + { + "index": 1, + "k": "6", + "lo": "3/2", + "hi": "7/4", + "u": 156, + "sq": "259159966184709869271004669152262950565331236/10686733714922552340096995507147312164306640625", + "sign_lo": "-170474463/4", + "sign_hi": "85903083723/1024" + }, + { + "index": 2, + "k": "7", + "lo": "7/4", + "hi": "2", + "u": 120, + "sq": "207943802139808519297719599609100544/14553143435926758684217929840087890625", + "sign_lo": "-519649/64", + "sign_hi": "8420" + } + ], + "total": "5473/6750" + }, + { + "m": 10, + "e": "37/120", + "components": [ + { + "index": 0, + "k": "9", + "lo": "9/4", + "hi": "5/2", + "u": 225, + "sq": "638293762541221093747816508114878880793600/12670638520251952131767561075962441202170201", + "sign_lo": "8519088897/512", + "sign_hi": "-568877325/16" + }, + { + "index": 1, + "k": "7", + "lo": "7/4", + "hi": "2", + "u": 155, + "sq": "39992206538790281750679741636522271281933/1671405449599205894628539681434631347656250", + "sign_lo": "-133895142933/1024", + "sign_hi": "40230640" + }, + { + "index": 2, + "k": "8", + "lo": "2", + "hi": "9/4", + "u": 121, + "sq": "30906246597347521204992829131708683421/2130683380444656398773193359375000000000", + "sign_lo": "-15116", + "sign_hi": "293463/64" + } + ], + "total": "607/750" + }, + { + "m": 11, + "e": "10/33", + "components": [ + { + "index": 0, + "k": "10", + "lo": "5/2", + "hi": "11/4", + "u": 229, + "sq": "270768145496851065976525637069732661192732900000000/5177630465344514816982506442433463167085530332106561", + "sign_lo": "346134085/8", + "sign_hi": "-41058196971/2048" + }, + { + "index": 1, + "k": "9", + "lo": "9/4", + "hi": "5/2", + "u": 154, + "sq": "25774045985593821375784246813470784975644433299961/1091596293147393410814963821091079711914062500000000", + "sign_lo": "-70180136721/1024", + "sign_hi": "1134770615/4" + }, + { + "index": 2, + "k": "10", + "lo": "5/2", + "hi": "11/4", + "u": 122, + "sq": "348705329536581989784912196711706323531582681/23742866139963781811525528755118604125976562500", + "sign_lo": "-1355", + "sign_hi": "1718871/64" + } + ], + "total": "5333/6600" + }, + { + "m": 12, + "e": "43/144", + "components": [ + { + "index": 0, + "k": "12", + "lo": "3", + "hi": "13/4", + "u": 235, + "sq": "26520865503698587417602539062500000000000000/482937844037254032100813776438682760806167409", + "sign_lo": "8660520", + "sign_hi": "-104015094267/1024" + }, + { + "index": 1, + "k": "10", + "lo": "5/2", + "hi": "11/4", + "u": 155, + "sq": "411535779455274768541650617194746668735655004975500313559771202653723/17323966715860733046200189982926496865335217500000000000000000000000000", + "sign_lo": "-2259439875/8", + "sign_hi": "172810506315/1024" + }, + { + "index": 2, + "k": "11", + "lo": "11/4", + "hi": "3", + "u": 125, + "sq": "122867860045464447609172630296457108866071/7919417137625252757504000000000000000000000", + "sign_lo": "-627061/64", + "sign_hi": "22842" + } + ], + "total": "2929/3600" + }, + { + "m": 13, + "e": "23/78", + "components": [ + { + "index": 0, + "k": "13", + "lo": "13/4", + "hi": "7/2", + "u": 239, + "sq": "10261487887363197834397469708157314007876/180296818648617353571477195328372072515625", + "sign_lo": "113267168547/2048", + "sign_hi": "-297427403/4" + }, + { + "index": 1, + "k": "12", + "lo": "3", + "hi": "13/4", + "u": 154, + "sq": "47722121814946760439811585176997743252260096594885332831227409002912841/2013026738709048149567060193021461600437760353088378906250000000000000000", + "sign_lo": "-92670480", + "sign_hi": "761200507431/1024" + }, + { + "index": 2, + "k": "12", + "lo": "3", + "hi": "13/4", + "u": 129, + "sq": "1181636795712106490656347650026063752159653585930396453711994929329/72023685843483620239169340493390336632728576660156250000000000000000", + "sign_lo": "-21168", + "sign_hi": "1041027/64" + } + ], + "total": "15929/19500" + }, + { + "m": 14, + "e": "7/24", + "components": [ + { + "index": 0, + "k": "14", + "lo": "7/2", + "hi": "15/4", + "u": 243, + "sq": "931732224047070511883660857541107339543622250000/15862443193197619493545506747144366925912619792641", + "sign_lo": "2010291801/16", + "sign_hi": "-12799209735/512" + }, + { + "index": 1, + "k": "13", + "lo": "13/4", + "hi": "7/2", + "u": 155, + "sq": "79883777618938672988321459316635177291889759782334208714149/3326166344477469187983121936213831738281250000000000000000000", + "sign_lo": "-591356590315/1024", + "sign_hi": "3615115413/8" + }, + { + "index": 2, + "k": "13", + "lo": "13/4", + "hi": "7/2", + "u": 132, + "sq": "126263305167394487826714216164913584397734348393124438290290547/7274325795372225114119087674499650011621093750000000000000000000", + "sign_lo": "-2298785/64", + "sign_hi": "13377/2" + } + ], + "total": "493/600" + }, + { + "m": 15, + "e": "13/45", + "components": [ + { + "index": 0, + "k": "16", + "lo": "4", + "hi": "17/4", + "u": 248, + "sq": "1488686634960976081550752780906145604133102500000000/24313124653786598685031896305554638743513954608688689", + "sign_lo": "53563692", + "sign_hi": "-384457669023/2048" + }, + { + "index": 1, + "k": "15", + "lo": "15/4", + "hi": "4", + "u": 156, + "sq": "723628356583696612772046448569698988880188312544077829283774464/30027213873897670110512823465045181592358858324587345123291015625", + "sign_lo": "-148173788025/1024", + "sign_hi": "1620722544" + }, + { + "index": 2, + "k": "15", + "lo": "15/4", + "hi": "4", + "u": 136, + "sq": "239942485521070994273626724216712223654146656620773376/13118557098965952137780652519381551398403263092041015625", + "sign_lo": "-407025/64", + "sign_hi": "50120" + } + ], + "total": "373/450" + }, + { + "m": 16, + "e": "55/192", + "components": [ + { + "index": 0, + "k": "17", + "lo": "17/4", + "hi": "9/2", + "u": 251, + "sq": "69735547485351562500000000000000000000/1107217223258472848854432556722827015361", + "sign_lo": "173820963103/1024", + "sign_hi": "-838909143/8" + }, + { + "index": 1, + "k": "16", + "lo": "4", + "hi": "17/4", + "u": 157, + "sq": "4153997784454318279837186805891153972139343015158471013410672833565845618192715067026221799941941759/169978506385079270493866310292814815088202965911994095784615542784000000000000000000000000000000000000", + "sign_lo": "-1184598144", + "sign_hi": "945916049041/1024" + }, + { + "index": 2, + "k": "16", + "lo": "4", + "hi": "17/4", + "u": 140, + "sq": "3293508622136713077980764008714648832693819105614030545555296840000180446441312133/168189265038967838695718824928581512577499101841730360221693738964843750000000000000", + "sign_lo": "-23376", + "sign_hi": "2551111/64" + } + ], + "total": "20027/24000" + }, + { + "m": 17, + "e": "29/102", + "components": [ + { + "index": 0, + "k": "19", + "lo": "19/4", + "hi": "5", + "u": 256, + "sq": "1227418617048630041167291089738524299729305600000000/18833511118948245571727665746196710518858636630828761", + "sign_lo": "48792555271/2048", + "sign_hi": "-393682155" + }, + { + "index": 1, + "k": "18", + "lo": "9/2", + "hi": "19/4", + "u": 157, + "sq": "73736936957566663364256745556643340794306184105186345168861458303146169487768007871808806413301247135143844562064/2999121654371641135853732569012436541634551848808823256327480371209142526521921672753023813129402697086334228515625", + "sign_lo": "-2942822097/8", + "sign_hi": "3113626213931/1024" + }, + { + "index": 2, + "k": "17", + "lo": "17/4", + "hi": "9/2", + "u": 145, + "sq": "4315063392497142436911899130565804971665271512643549297681/206370795799437622974892292404547333717346191406250000000000", + "sign_lo": "-2872677/64", + "sign_hi": "51111/2" + } + ], + "total": "21479/25500" + }, + { + "m": 18, + "e": "61/216", + "components": [ + { + "index": 0, + "k": "20", + "lo": "5", + "hi": "21/4", + "u": 259, + "sq": "4973995727176222495038879678800390625/74464108572646067850349626880398704656", + "sign_lo": "210282480", + "sign_hi": "-131671547703/512" + }, + { + "index": 1, + "k": "19", + "lo": "19/4", + "hi": "5", + "u": 158, + "sq": "19190711389019402801011458678792094731777275286268609806543261150599360073586921690381026373633/771251477700149520595490077300249406132439714782773248000000000000000000000000000000000000000000", + "sign_lo": "-2548723303977/1024", + "sign_hi": "1483401840" + }, + { + "index": 2, + "k": "18", + "lo": "9/2", + "hi": "19/4", + "u": 150, + "sq": "112008335495215130632874007087522219844601184687769942914361777982260447893360054218524021394736574751/5029126802898557611612698554139953040078290766852570995127775350650308440673828125000000000000000000000", + "sign_lo": "-71442", + "sign_hi": "426347/64" + } + ], + "total": "11467/13500" + }, + { + "m": 19, + "e": "16/57", + "components": [ + { + "index": 0, + "k": "21", + "lo": "21/4", + "hi": "11/2", + "u": 262, + "sq": "346357880916537048190021331124574544367187897516340250000/5078023369287431876477195468132354433627561616518782694721", + "sign_lo": "959258815749/2048", + "sign_hi": "-815511069/16" + }, + { + "index": 1, + "k": "21", + "lo": "21/4", + "hi": "11/2", + "u": 159, + "sq": "95034881763670320507506158189213513439172260397959272626850665660254735038139303264249784026259553722174941807568721/3792220498905088292313488954182468544591454362020924749149666528114065925373022280946373939514160156250000000000000000", + "sign_lo": "-1195908707673/1024", + "sign_hi": "39694891881/8" + }, + { + "index": 2, + "k": "20", + "lo": "5", + "hi": "21/4", + "u": 154, + "sq": "618700387502477191416126025360269406473680599217185635438494523846969282565979761/26144694679481366637798962847343377941175634965267324404736000000000000000000000000", + "sign_lo": "-17390", + "sign_hi": "5196771/64" + } + ], + "total": "1951/2280" + }, + { + "m": 20, + "e": "67/240", + "components": [ + { + "index": 0, + "k": "23", + "lo": "23/4", + "hi": "6", + "u": 265, + "sq": "5076176541391545719082859685025/72349808205694038357981429164161", + "sign_lo": "247221526935/1024", + "sign_hi": "-512236224" + }, + { + "index": 1, + "k": "22", + "lo": "11/2", + "hi": "23/4", + "u": 159, + "sq": "22195005908908006339127692644804714630090350442953587921865410098990403005009567792562428564045583934439495668727639540938970969/878196407337946788064260689643400167403577936724168306881210810388438403606414794921875000000000000000000000000000000000000000000", + "sign_lo": "-42354538721/8", + "sign_hi": "1748523396495/1024" + }, + { + "index": 2, + "k": "21", + "lo": "21/4", + "hi": "11/2", + "u": 160, + "sq": "10403283810191443915559584605203635677969611777768568218831548176682782494341615572638694551580577591/411224373198171286400060795987542531917850536898561290278346413099495506875000000000000000000000000000", + "sign_lo": "-3020625/64", + "sign_hi": "60958" + } + ], + "total": "5179/6000" + }, + { + "m": 21, + "e": "5/18", + "components": [ + { + "index": 0, + "k": "24", + "lo": "6", + "hi": "25/4", + "u": 268, + "sq": "7304961283546767847721430101718554257587095413401000000/102309671589518332589788177932976932173729961153558998569", + "sign_lo": "638962668", + "sign_hi": "-385457580285/2048" + }, + { + "index": 1, + "k": "24", + "lo": "6", + "hi": "25/4", + "u": 160, + "sq": "27735140698634445999393613038498325941432595096804879312799932494814048721203031127142555057721086150327096896234888978602108010249/1089327385337662774149348214789726350491137189234788047210424189531766488878775416236263467692593112587928771972656250000000000000000", + "sign_lo": "-3461741064", + "sign_hi": "7109884391895/1024" + }, + { + "index": 2, + "k": "22", + "lo": "11/2", + "hi": "23/4", + "u": 165, + "sq": "58555689253557068612259677896717177086686929453358646656895931374900790300865234912103907954910569341023737538576053688449/2172059205993341570405504972999185496287418150860524588510169711067844013074878972702208557166159152984619140625000000000000", + "sign_lo": "-83386", + "sign_hi": "2231135/64" + } + ], + "total": "7837/9000" + }, + { + "m": 22, + "e": "73/264", + "components": [ + { + "index": 0, + "k": "26", + "lo": "13/2", + "hi": "27/4", + "u": 271, + "sq": "393454895918196430471192730428579251637827600/5384472071354360808523478203580776932968239801", + "sign_lo": "4179532381/16", + "sign_hi": "-461497339215/512" + }, + { + "index": 1, + "k": "25", + "lo": "25/4", + "hi": "13/2", + "u": 160, + "sq": "10047365346100772517391627724639559774486716442239011108372472012122353867991997421358801785796556029191320990933672475192679482983778677/392974369789993708634431152590661429831899432359539117433112991766797673358340343461847437931580066680908203125000000000000000000000000000", + "sign_lo": "-11407621809855/1024", + "sign_hi": "4369475825/8" + }, + { + "index": 2, + "k": "23", + "lo": "23/4", + "hi": "6", + "u": 170, + "sq": "5681354213451082801613189599979880809040483152777672847878144/198337973047283602051368353775432446927879936993122100830078125", + "sign_lo": "-8103053/64", + "sign_hi": "2268" + } + ], + "total": "14479/16500" + }, + { + "m": 23, + "e": "19/69", + "components": [ + { + "index": 0, + "k": "27", + "lo": "27/4", + "hi": "7", + "u": 273, + "sq": "350054734693932971249121000000000000000000000000000000/4722466635015948035229880083532699571588888670499548049", + "sign_lo": "1764122088969/2048", + "sign_hi": "-401538301" + }, + { + "index": 1, + "k": "27", + "lo": "27/4", + "hi": "7", + "u": 161, + "sq": "65684021456017756328036188304904438836212679239799244235513010349843899755715529699739663901462798057620586088174750051620079382080009649/2550660482371861186937215972044429020606912672519683837890625000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-9278084145105/1024", + "sign_hi": "7774441634" + }, + { + "index": 2, + "k": "25", + "lo": "25/4", + "hi": "13/2", + "u": 175, + "sq": "23033360560313453277223271333016158477095229050914940317854183255792077665588508111285078667371825603535851714318576675681/757638788858751152137917914617278011502956291659641778268973440604364018511788115594053364157002197265625000000000000000000", + "sign_lo": "-2399525/64", + "sign_hi": "119736" + } + ], + "total": "61021/69000" + }, + { + "m": 24, + "e": "79/288", + "components": [ + { + "index": 0, + "k": "29", + "lo": "29/4", + "hi": "15/2", + "u": 275, + "sq": "15717303175066366312563294944175114496000000/208073051338066793077461358015741558767840121", + "sign_lo": "283347244119/1024", + "sign_hi": "-11616042735/8" + }, + { + "index": 1, + "k": "29", + "lo": "29/4", + "hi": "15/2", + "u": 161, + "sq": "698438622788453988425611353017360318169128715679399585578588016509743581360368300342319485884268912675014731563/27027356106463959056827727077560926298937562837165051611298699200000000000000000000000000000000000000000000000000", + "sign_lo": "-4235284902411/1024", + "sign_hi": "156670873515/8" + }, + { + "index": 2, + "k": "26", + "lo": "13/2", + "hi": "27/4", + "u": 180, + "sq": "9173422663553561659683130401057886390494294088968510363375137307126292760010926946406092298026963103946103/283800262209165852164507468934633734070788960217948026251113025341469150510142800000000000000000000000000000", + "sign_lo": "-170237/2", + "sign_hi": "5437611/64" + } + ], + "total": "32051/36000" + }, + { + "m": 25, + "e": "41/150", + "components": [ + { + "index": 0, + "k": "30", + "lo": "15/2", + "hi": "31/4", + "u": 277, + "sq": "105493009408241734632805695831765149666830449228515625000000000000/1380809103998266352997784608793875271373387284168892436264379454881", + "sign_lo": "9332955675/8", + "sign_hi": "-1423097239209/2048" + }, + { + "index": 1, + "k": "30", + "lo": "15/2", + "hi": "31/4", + "u": 161, + "sq": "1864531586952572261123760254002667296740112246052447864827391642340089551251144117264571717166181926052395012920854617276108589934062139064588485639131125639298584830125259381711904449/71950381657623463405052637224215112818828358538809672400386480980020289934944769036527659635536991928309331470138655025326001690808702671020569141546729952096939086914062500000000000000", + "sign_lo": "-21226985550", + "sign_hi": "5048704980651/1024" + }, + { + "index": 2, + "k": "27", + "lo": "27/4", + "hi": "7", + "u": 186, + "sq": "410172098148017170348031110894125763430224324644641211922230280019560109668936624040592687739545222505201801/11970924228286743164062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-9045513/64", + "sign_hi": "42204" + } + ], + "total": "673/750" + }, + { + "m": 26, + "e": "85/312", + "components": [ + { + "index": 0, + "k": "32", + "lo": "8", + "hi": "33/4", + "u": 279, + "sq": "4237044877656546923879493600279092788696289062500000000/54618988497115964036963584074927591663586263586670282641", + "sign_lo": "311059152", + "sign_hi": "-1116635152527/512" + }, + { + "index": 1, + "k": "32", + "lo": "8", + "hi": "33/4", + "u": 162, + "sq": "503819501028181779671595767438229500763155039131183227548864390434185170498945506834793805591265394311520191778013673688628612087763814059895422976/19375458632013934263921727237315602288460383367659279175975830914362739678204401464138076330915678883719146900765917251874270732514560222625732421875", + "sign_lo": "-16215347376", + "sign_hi": "20276031458025/1024" + }, + { + "index": 2, + "k": "29", + "lo": "29/4", + "hi": "15/2", + "u": 191, + "sq": "1484043684853453719884639961052865577815165164432061982826090892571835873082550048828125/41076015699246255913604274009604466963470140920615660207335904712177553691385470908366848", + "sign_lo": "-594081/64", + "sign_hi": "419715/2" + } + ], + "total": "35273/39000" + }, + { + "m": 27, + "e": "22/81", + "components": [ + { + "index": 0, + "k": "33", + "lo": "33/4", + "hi": "17/2", + "u": 280, + "sq": "26928447704834089062917481960104992265677099977321/344150050786083658683945628656384871176909339372025", + "sign_lo": "3294685544661/2048", + "sign_hi": "-1054324773" + }, + { + "index": 1, + "k": "34", + "lo": "17/2", + "hi": "35/4", + "u": 162, + "sq": "1804597005659090593692217482268641094136039729940835812383387161120498889296471800510657650888060508926772049880917312153105870157607059840310226205387093493442999452279711486788388064229057081632681/69352674944889878900011219452947626206682139742397172561829113517251025951662208404830791678201227605222313795495374612652304051932637120826450040049140999690280295908451080322265625000000000000000000", + "sign_lo": "-6195465276", + "sign_hi": "43591530258375/1024" + }, + { + "index": 2, + "k": "30", + "lo": "15/2", + "hi": "31/4", + "u": 196, + "sq": "306035795552009759312793869131934895304890421761675986275766697182407747116741712949436238080250100421814493597748321609348961212792476624439520246645860515329/7994043921043534055899091839501825802566845383909247874535065940053779592597988130174199731945718096143469679070463272951345632517328262329101562500000000000000", + "sign_lo": "-140535/2", + "sign_hi": "10548239/64" + } + ], + "total": "36839/40500" + }, + { + "m": 28, + "e": "13/48", + "components": [ + { + "index": 0, + "k": "35", + "lo": "35/4", + "hi": "9", + "u": 282, + "sq": "12110178061777046843369463585177600000000/152893581783201068017886371454064665785369", + "sign_lo": "422889484255/1024", + "sign_hi": "-3085052184" + }, + { + "index": 1, + "k": "35", + "lo": "35/4", + "hi": "9", + "u": 162, + "sq": "6663809171648796916337726545655491770443952524117906746183083398822709369593316525666885421028664610285469983554293831730339/256091666279147404638317254099691479090050375367835730314994384896000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-43221884492045/1024", + "sign_hi": "10785881592" + }, + { + "index": 2, + "k": "31", + "lo": "31/4", + "hi": "8", + "u": 202, + "sq": "633627232488424933654711591966650712917552690547446925620269274533635455117905148692718119799929319741074499398795264/15665295631900096198195953532373330109933209643339271955859045625093234093401718833286061374642643518745899200439453125", + "sign_lo": "-9059181/64", + "sign_hi": "110152" + } + ], + "total": "5501/6000" + }, + { + "m": 29, + "e": "47/174", + "components": [ + { + "index": 0, + "k": "36", + "lo": "9", + "hi": "37/4", + "u": 283, + "sq": "807707317262331019057967518917952217129032977058764582488795765625/10135162407748791626573960157186366097829246376741654098343219564544", + "sign_lo": "2275658793", + "sign_hi": "-2944382957117/2048" + }, + { + "index": 1, + "k": "37", + "lo": "37/4", + "hi": "19/2", + "u": 162, + "sq": "88183664478754631624013699724614020803357421859633634229172437714526567537983497975333771448614395455409657394889268687577853970989078229316479336084809541103009793858147239057908357279536818604920111809/3386701606299295215410985984328573999262196659406237110823755491220734962145767430518554199678666563133962091759059726652573129535268392584917984677872482279781252145767211914062500000000000000000000000000", + "sign_lo": "-34129222216537/1024", + "sign_hi": "37163292945" + }, + { + "index": 2, + "k": "32", + "lo": "8", + "hi": "33/4", + "u": 207, + "sq": "1208755783069986065409597899702551898364111117244676024058855469465772844383662601339983760440035852885819943121738658052659380457118360081/28360042470273430719221853142194632367000200701714782069299646070692621905619257294262069990509189665317535400390625000000000000000000000000", + "sign_lo": "-223956", + "sign_hi": "2883195/64" + } + ], + "total": "10028/10875" + }, + { + "m": 30, + "e": "97/360", + "components": [ + { + "index": 0, + "k": "38", + "lo": "19/2", + "hi": "39/4", + "u": 284, + "sq": "367353879381645389717887769262383252764944/4565661172260621337749024022758610200324025", + "sign_lo": "10697870985/16", + "sign_hi": "-2114428842423/512" + }, + { + "index": 1, + "k": "39", + "lo": "39/4", + "hi": "10", + "u": 162, + "sq": "360607699442052098417745093006223581739870369318723834423485464951797444856460318927400937951353114782017589114783191247916032144754124391972864/13869645470288764541313790565940290822056613529691088563686888129516810714191422256670951798145448289234678285186674884243984706699848175048828125", + "sign_lo": "-17005573453437/1024", + "sign_hi": "75930577200" + }, + { + "index": 2, + "k": "34", + "lo": "17/2", + "hi": "35/4", + "u": 212, + "sq": "96803363148650413439627725543865364934713044547827718853607262334640642454302530238098549476126645215822073697497479769350682830095924377114853939514621991072998046875/2162928992706138785221157924131871070087496966278661400797172712782791897051187407195969571512612965562982813727660902837742858158897055454162490541676108143668905377792", + "sign_lo": "-31333", + "sign_hi": "18137675/64" + } + ], + "total": "8347/9000" + }, + { + "m": 31, + "e": "25/93", + "components": [ + { + "index": 0, + "k": "39", + "lo": "39/4", + "hi": "10", + "u": 285, + "sq": "1370012501802155212072073608337573970561600710102015625/16961604807195104800847088606056723478949272415622376964", + "sign_lo": "6763683676329/2048", + "sign_hi": "-1761215460" + }, + { + "index": 1, + "k": "40", + "lo": "10", + "hi": "41/4", + "u": 161, + "sq": "55998102243494337652748694649011912128393149890530372486016716477193847585917608266268875665784027987056044091073845541502601501634406691436166684481948694997290314620180744815875435274929466098744440471891909618178665163420047058162805921/2161245252447042298973635372719011068998247548409457161987116088895522778517805675578851276777902193012803740287656906878179559441843337050863999143087417362762486089876537806402972168881706807042064610868692398071289062500000000000000000000", + "sign_lo": "-88682212800", + "sign_hi": "10940729043439/1024" + }, + { + "index": 2, + "k": "35", + "lo": "35/4", + "hi": "9", + "u": 218, + "sq": "11145318280788936864651132207230709038652778735541738706572075211924368985579583420900792475721/236553766550457946147512890282332069479311071163881457975296000000000000000000000000000000000000", + "sign_lo": "-7671545/64", + "sign_hi": "214974" + } + ], + "total": "10844/11625" + }, + { + "m": 32, + "e": "103/384", + "components": [ + { + "index": 0, + "k": "41", + "lo": "41/4", + "hi": "21/2", + "u": 286, + "sq": "41899219043964738475118657497129288079225640714240000/514959170417627120050112213996069837235391786225277809", + "sign_lo": "1245527721519/1024", + "sign_hi": "-41873975055/8" + }, + { + "index": 1, + "k": "42", + "lo": "21/2", + "hi": "43/4", + "u": 161, + "sq": "11152981218565371204051090368815249042780164584368480982721191099476492415864305684169887243229806602002617270903064152370153502114952565605579633040420017568282083611238597400652294792975523970142665880496940930164520089435089225712136195769345223/431087127942047774616680827233953277989930476631680464138424829292607279383085277002920954360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-613960113447/8", + "sign_hi": "53117664510419/1024" + }, + { + "index": 2, + "k": "36", + "lo": "9", + "hi": "37/4", + "u": 223, + "sq": "645558869609974248821201750239132809557355670579600913102783826392471283446131742013051000686972655754461728957876426868257697179379952472342286912651097384391434705571008658479819190558068474124226353/13047975641125999848982109164478791828140746860541542420598075875734308502314037904810960615355819031094271976819308698695147961012136466143001512803758126230323200000000000000000000000000000000000000000", + "sign_lo": "-221454", + "sign_hi": "8591983/64" + } + ], + "total": "9007/9600" + }, + { + "m": 33, + "e": "53/198", + "components": [ + { + "index": 0, + "k": "42", + "lo": "21/2", + "hi": "43/4", + "u": 286, + "sq": "28166826911416374936093505473693847656250000000000000000/345560027157622368121115804292644142489454181815039821321", + "sign_lo": "78212388483/16", + "sign_hi": "-3857312425593/2048" + }, + { + "index": 1, + "k": "44", + "lo": "11", + "hi": "45/4", + "u": 161, + "sq": "2013157485321119240703053530699773925085616614711197288945673337149531498302969808661625694820512254955404354184217054816316177570289680982242805642717571353411661128253906919202147897625133781778734322939529/78061453081796836909426525232446110386274785681730248216446521734613416773689811475494105275981636736004372698945316022540666102897376118820970552669905373477376997470855712890625000000000000000000000000000000", + "sign_lo": "-53731344348", + "sign_hi": "113639174154135/1024" + }, + { + "index": 2, + "k": "37", + "lo": "37/4", + "hi": "19/2", + "u": 228, + "sq": "260368545548813136237315115037622506258666749092722386614036948442210969188213320188636551504721240315595083192175465029091273222838069613020566123464981911779760619788471594082849/5023066055020658988359057736501507647149297998948417287126044476921976334347814026603849495690241026850457708966706839304183773720069439150393009185791015625000000000000000000000000", + "sign_lo": "-21569197/64", + "sign_hi": "40313" + } + ], + "total": "3733/3960" + }, + { + "m": 34, + "e": "109/408", + "components": [ + { + "index": 0, + "k": "44", + "lo": "11", + "hi": "45/4", + "u": 287, + "sq": "52211950991856029871407639829784041989554952250000/637133476632117529934660843719900945735712972317321", + "sign_lo": "2264545576", + "sign_hi": "-3202042873095/512" + }, + { + "index": 1, + "k": "46", + "lo": "23/2", + "hi": "47/4", + "u": 161, + "sq": "14091929269576974592237457527795653043026800298336846032706926435768832596539623520468805552616055462137758253456381800131103941547628084268042177704251124011900352095374850978081447935163008322450281539448683027731425537521390485699449595005589042180808437875361/548986821167722541315071792349867620527177844134800550755473758466947632737913113988661294035893372350420394421721751287548819514027153524493779725947494448689911684148314498634668465230368873575472691309971359988474463864616126329565304331481456756591796875000000", + "sign_lo": "-128660847891/8", + "sign_hi": "197422750853923/1024" + }, + { + "index": 2, + "k": "39", + "lo": "39/4", + "hi": "10", + "u": 233, + "sq": "83020569466720643349747721507976544065651636287368010213723862132822150039128198000628881657678462542481508000000000000000000000/1532232046432634854765227903352662914157339933914936455063351968484653192680279842529814796825213810835144522488898491883537047479", + "sign_lo": "-4337901/64", + "sign_hi": "366660" + } + ], + "total": "12089/12750" + }, + { + "m": 35, + "e": "4/15", + "components": [ + { + "index": 0, + "k": "45", + "lo": "45/4", + "hi": "23/2", + "u": 287, + "sq": "73700277720319733247931930080920379224436471713319396972656250000/899416323463051567165807476395654787879107028378494194659104428321", + "sign_lo": "14980449997125/2048", + "sign_hi": "-25372769503/16" + }, + { + "index": 1, + "k": "47", + "lo": "47/4", + "hi": "12", + "u": 160, + "sq": "1013288626246128660845689156433862435905809311206700891938930565095032533169094920322890252286883894289633626537082102676021700982091916866069595306470670336/39703978292674329281824415354028800284556452313679066532060504947853562585601899521213767406004229551512990176732041149032514937289306544698774814605712890625", + "sign_lo": "-185561742235713/1024", + "sign_hi": "40478279040" + }, + { + "index": 2, + "k": "40", + "lo": "10", + "hi": "41/4", + "u": 239, + "sq": "4774332678129393127948710356223343133951863168123962658336513391625653645340758931418012481126832387708125242170859649824695441150247694177967854599532326467272702828122503422694517749842783186861357154602327708401/84204664098266510734917724142403523431126845972388108760484085155516023366715050565437702676278313355431013955477853464508561921547881680784001697309573851278310133205082358711025390625000000000000000000000000000000", + "sign_lo": "-191000", + "sign_hi": "17164155/64" + } + ], + "total": "1429/1500" + }, + { + "m": 36, + "e": "115/432", + "components": [ + { + "index": 0, + "k": "47", + "lo": "47/4", + "hi": "12", + "u": 287, + "sq": "3801372382804402150213718414306640625/46221808608953758727469870915254699961", + "sign_lo": "4211639097543/1024", + "sign_hi": "-6959488896" + }, + { + "index": 1, + "k": "49", + "lo": "49/4", + "hi": "25/2", + "u": 160, + "sq": "3172803384636863355335502208863626528150693327608579503232198118569110249761676347436554791855488054158025609553058816474638071340829211202468027495569738526493300435998791643721787970299874151236373449073910431585838940271433486167/124892373709018480459001628622162920432576750295102968514709928463762497339003856156260377886662360555060506583378167161404671506001155562774737259417763221884472697362624704121191647823718717802421451779082417488098144531250000000000", + "sign_lo": "-160917797712111/1024", + "sign_hi": "968338811865/8" + }, + { + "index": 2, + "k": "41", + "lo": "41/4", + "hi": "21/2", + "u": 244, + "sq": "1569460100262200674694024079674702495467049598137772529909056874800654725667648899395838639067545926940413497160541116188247042782165749758329126738726224134776095507/26508953673075994378658378978560051374569737362372811485154425229912238915023894542652063587337170491350469570077305160908270000000000000000000000000000000000000000000", + "sign_lo": "-21142249/64", + "sign_hi": "308853/2" + } + ], + "total": "51689/54000" + }, + { + "m": 37, + "e": "59/222", + "components": [ + { + "index": 0, + "k": "48", + "lo": "12", + "hi": "49/4", + "u": 287, + "sq": "360493065727462756141648957307039554002742806310097322563519736384/4391078756503303783239787417440926274538703255382638901056643805225", + "sign_lo": "10969915212", + "sign_hi": "-1125462544029/2048" + }, + { + "index": 1, + "k": "51", + "lo": "51/4", + "hi": "13", + "u": 159, + "sq": "8653932218621805638726826478279685672703989078103908985950990349722339186267718551102968636225434842055204457353113971727520997478179759353222772421908215504653259816946293395505946638390799834538295429767898167507051443058249549933054260334063041/342638955126068320654041787909613341429698085801083791299134569458086885567394288207931587199967085206496339463130808895527264750877686113648128838032885479855622612582400000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-117382832516205/1024", + "sign_hi": "231617831556" + }, + { + "index": 2, + "k": "42", + "lo": "21/2", + "hi": "43/4", + "u": 249, + "sq": "22926810587846563904330079034750659504085270519056104737074687900055984089647468903039995488012071215504774128740898472976918699907430075622579013537304459576970196152739231149090630407826627829197015040705468432641743222690614660665381689/371599930188540179013917620592985372647314966093381226633408575820651772980639497362811912126409832541245532928072845853429340475859744038132352499462472164793344236053299319974069442676367636124723503598943352699279785156250000000000000000", + "sign_lo": "-973701/2", + "sign_hi": "1558647/64" + } + ], + "total": "21329/22200" + }, + { + "m": 38, + "e": "121/456", + "components": [ + { + "index": 0, + "k": "50", + "lo": "25/2", + "hi": "51/4", + "u": 287, + "sq": "3321596956380208888364845490732538132971479152511256250000/40372218128115972521845589209862189302399048646023720641049", + "sign_lo": "114836928285/16", + "sign_hi": "-3589922188863/512" + }, + { + "index": 1, + "k": "53", + "lo": "53/4", + "hi": "27/2", + "u": 159, + "sq": "930906834211384684835210736815225593653941393508969317065488163808781502568272795420251170126719702681716497646468190561592614177316191601887222763432152843391570418354027834449955794089840718953250885307379002680626172254190531140333/37114086979841206001380078366602496689591215177135007814277183065763722820197227258265203901188375866819438430036755994315292168480840366616522763245695328628849267715850146487355232238769531250000000000000000000000000000000000000000000", + "sign_lo": "-49654473098499/1024", + "sign_hi": "3033930905181/8" + }, + { + "index": 2, + "k": "44", + "lo": "11", + "hi": "45/4", + "u": 254, + "sq": "36999321434330625321503294898085720802012309828033233428462610993313674280112392858448175806079858493899929514014406715009818000423908233642578125/576268868943196848463091494654410346107016663099972291312617363615009593078572863617581746514261849457936301455673402275996928526448048681661759488", + "sign_lo": "-123072", + "sign_hi": "29303775/64" + } + ], + "total": "2201/2280" + }, + { + "m": 39, + "e": "31/117", + "components": [ + { + "index": 0, + "k": "52", + "lo": "13", + "hi": "53/4", + "u": 287, + "sq": "98361860325639846873188923578733542002737522125244140625/1194562690258813942840560865032522450223903417563852570624", + "sign_lo": "1670891001", + "sign_hi": "-32079024532815/2048" + }, + { + "index": 1, + "k": "54", + "lo": "27/2", + "hi": "55/4", + "u": 158, + "sq": "18806864657293553276518615039395257771975569833606810631292710048998250058421317150425144135986575312010050370433935926037990353402064726224140692795862874791478563641894305334889873707599004808835926435875752924826249458372655618355405022978129194030435577812222336588747068826119248577114381218806152609/756430501508222896124896939606748743379137643694828177119857721991321880437208355777277443255536847024255075424775706256563410194242663709816821813355979822456875333815332066276867806489298512399232752141129601764974692171417043128375543785714418820731452797190286219120025634765625000000000000000000000000", + "sign_lo": "-3218998084857/8", + "sign_hi": "48513797948295/1024" + }, + { + "index": 2, + "k": "45", + "lo": "45/4", + "hi": "23/2", + "u": 259, + "sq": "1874559116069106350577523378378983839080903810242036127107503705911173173750689038638469197091517048474616934304737371073423922400089015991095217225270042283178737269833013546435732986335536170213912692661981469403337238209/28051112812464294929100472064640500036095282823033026118665137623962303625560778202510527780735255497015027595024193272707854110084726803872355737241375523764983299927630149288446774316406250000000000000000000000000000000000", + "sign_lo": "-18491085/64", + "sign_hi": "643783/2" + } + ], + "total": "14171/14625" + }, + { + "m": 40, + "e": "127/480", + "components": [ + { + "index": 0, + "k": "53", + "lo": "53/4", + "hi": "27/2", + "u": 287, + "sq": "10165399005188922146132916256224431967037440000/123857955920143931888993140173300078563795728081", + "sign_lo": "12306886934695/1024", + "sign_hi": "-47460920247/8" + }, + { + "index": 1, + "k": "56", + "lo": "14", + "hi": "57/4", + "u": 158, + "sq": "206403357454822958098854563408621409297243206333973169528652719680792789055275238756459542049240883043877636321740836778980445333048248745396604742183559103468949377042962141490159134141008601706544295777830677850997835646081634518832283162499642987652709827688429107848909331537/8358404375211205321868793514387031789569017877674808813027291255124622099267917626866665745404765047947171949377187334781209347925795517666031334443925527623608398437500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-370942129856", + "sign_hi": "184423910858217/1024" + }, + { + "index": 2, + "k": "46", + "lo": "23/2", + "hi": "47/4", + "u": 264, + "sq": "42643097513680415451942270034789787371707072752000165248416489362246061994767011196382608693944792842315449654849923008565425201249699821442131223768857603663672264584771340897451859377847245716992255896870062650877702007495663053181378725339979363925140305355772172558043/614225329043894937607556876459910795877420041634846948331898379379112347052672585729397914098628618684427435337002902706286107740349108698984849023194630037229138078135558677993541789467893319588700098340772987575247657916062500000000000000000000000000000000000000000000000", + "sign_lo": "-474300", + "sign_hi": "10707187/64" + } + ], + "total": "11683/12000" + }, + { + "m": 41, + "e": "65/246", + "components": [ + { + "index": 0, + "k": "55", + "lo": "55/4", + "hi": "14", + "u": 287, + "sq": "1522408189531421776995276323473933667783727982659845675469140625/18555710627948082750768927612714808973871938469195036177190101124", + "sign_lo": "11630171668375/2048", + "sign_hi": "-16072703892" + }, + { + "index": 1, + "k": "58", + "lo": "29/2", + "hi": "59/4", + "u": 157, + "sq": "583784744452280255283866043343829430847409156541752160844110187983396539427406101359305953419410766691956204232578648827276752717316495140352166375317553953401268757910005155926929761165526483968570070132927820187990886842246312090909749265075977612339311377353797931871653359002055841459975872689413688376210077011486832763655381098897285471710281/23824422870679708130108718033732889678101203819285732587553173645875041268314798688880033216060423118399597969090724806404277893659351668491709544858762958708687781370896608233871133948500425862090254395840530091461163040745872562966415179711350160700976964074686330641030518547355491337791377759458555374294519424438476562500000000000000000000000000", + "sign_lo": "-2502775137635/8", + "sign_hi": "366552506271579/1024" + }, + { + "index": 2, + "k": "48", + "lo": "12", + "hi": "49/4", + "u": 269, + "sq": "472260386639649989781481146174579459180847224576343588402087912950146697880968071269212392388927148724581391693708357351464541802697743439270515920390225695014787195664588475734844849190790685375613216773788537288990416354475584124904876767166301206307770480429598769743681/6567788821475945465084096356008850251021431059497748323230768044530119062371883389728678596900477892812541306320758452999103996953540998355620740428129502672376098700245622422713616225373750422299338090884582548609985043243523597717285156250000000000000000000000000000000000", + "sign_lo": "-7020", + "sign_hi": "45787099/64" + } + ], + "total": "120199/123000" + }, + { + "m": 42, + "e": "19/72", + "components": [ + { + "index": 0, + "k": "56", + "lo": "14", + "hi": "57/4", + "u": 286, + "sq": "3506936358422527939629138238793091070897320505902240000/42943272869450096386833857349523957549601391893343032641", + "sign_lo": "19375040496", + "sign_hi": "-1573691990175/512" + }, + { + "index": 1, + "k": "60", + "lo": "15", + "hi": "61/4", + "u": 156, + "sq": "477999393506156990968406198057368729192269396673720502610374798521809053400740101261232652896386033703616602324610672900957268217580948199192445848068122136390777050805563528787455061166577561174554930965544809376817789641218508703853875105921202219496196464948738168564560057046064124761993181186110273155690921984/19675628501092962982239046297698260737121918465928277712003388139945346618342572245567361991454451397674564562270561661616120921482851811284450218984774078082193387159272164103374460753304577446023412977788738844905586760743880430668345336751363180755762487565700969609225139643482460627410546294413506984710693359375", + "sign_lo": "-221204115000", + "sign_hi": "604678532698005/1024" + }, + { + "index": 2, + "k": "49", + "lo": "49/4", + "hi": "25/2", + "u": 274, + "sq": "547934952128228586241730634630961379529321397665946357802218220588846896260256303150779838909190070703977718881624414245445759263824766837718504636437857117114735224416087914036700701192472706679836846888065338134765625/7343801640019264919102790491340740522466306923772264377483575398504110701998238762661497913020340125684829790237072623741740551807249854041081104410260643860110865524289377229657033279242523236385421088286999325102309376", + "sign_lo": "-12941593/64", + "sign_hi": "554720" + } + ], + "total": "8819/9000" + }, + { + "m": 43, + "e": "34/129", + "components": [ + { + "index": 0, + "k": "58", + "lo": "29/2", + "hi": "59/4", + "u": 286, + "sq": "409623834162785169913845110065844167327273038357470693971071819438336/5022745790327246703171471587315304860390978137165146919011572331824641", + "sign_lo": "98163082227/8", + "sign_hi": "-30166129179691/2048" + }, + { + "index": 1, + "k": "62", + "lo": "31/2", + "hi": "63/4", + "u": 156, + "sq": "223283810647691987441513829537269868865932938550247806885378729242278003780319903577666569129448846989140999547726067279096841399996906670460204179966784051244490548221424574438774649193930409199101675588358948372134349087581328273920685101005209277637871068048884084600230083561899516212118170881125192684331378481/9277337158566813803581243692197298941728212544236245862904325889149081000039946879417891519759414691836148277086981582825551108512732578618532930139592624992499885400824759778880425705613474492363027623283009666105774570146353543838764022121307940837997563221506425179541110992431640625000000000000000000000000000000", + "sign_lo": "-704135133685/8", + "sign_hi": "910019415135951/1024" + }, + { + "index": 2, + "k": "50", + "lo": "25/2", + "hi": "51/4", + "u": 279, + "sq": "3394158388447380975957978090721318808313812491428451244454611452452189554935232598779925131593297961948751178946661181391809162349284299936239929532188914679016227132399970769648109115930341841774310034975742063948590657006208641/43916384886161413932922750183897595235007772439504353909495065097870988581809183414105853347417640785664402480606816901627536285856374216642165667369848256918632761366385790186595985902404785156250000000000000000000000000000000000", + "sign_lo": "-419450", + "sign_hi": "23868999/64" + } + ], + "total": "127009/129000" + }, + { + "m": 44, + "e": "139/528", + "components": [ + { + "index": 0, + "k": "60", + "lo": "15", + "hi": "61/4", + "u": 286, + "sq": "264758333272256448541517789982876401864552729719626521094400000000/3254011474367032379178879447015868972737162834626773051755741887329", + "sign_lo": "2423341800", + "sign_hi": "-30562772052763/1024" + }, + { + "index": 1, + "k": "63", + "lo": "63/4", + "hi": "16", + "u": 155, + "sq": "76996894114391539093443520988160073607151971917989162166006260888943540379024315226983827967766186919529486817423994658121175699923746621638609115934225786120428476277617728561508006438949375132963556646992409408076252886276154945582399488/3235404740489583882667863027390012131351990784930099996763981641073602537705139855712606303456009487588314570208077003950933117234669335018687510511200760647250688489239204384590054245708687487046511335464504810488506336696445941925048828125", + "sign_lo": "-944428314357225/1024", + "sign_hi": "95942262656" + }, + { + "index": 2, + "k": "51", + "lo": "51/4", + "hi": "13", + "u": 283, + "sq": "3288070488300019407131515649897279793763851859727669385545123557179879322333601586035802807999304029919085082770018860984585451608347675650427315253501418287976688227068720994858346650023699657721871163318177939228875216083/41137908589540522089271408366948688062406844378882055943200810054535540163416101471736543789604212550644973068112101213267448872977622513462922107583273933183610570923835392000000000000000000000000000000000000000000000000000", + "sign_lo": "-42235749/64", + "sign_hi": "168934" + } + ], + "total": "65159/66000" + }, + { + "m": 45, + "e": "71/270", + "components": [ + { + "index": 0, + "k": "61", + "lo": "61/4", + "hi": "31/2", + "u": 285, + "sq": "68951601382420087432559202520943488650647073034016564965326562500/852408236699517927845209883901697264314432031250178387612020330449", + "sign_lo": "46028075870691/2048", + "sign_hi": "-10710049041" + }, + { + "index": 1, + "k": "65", + "lo": "65/4", + "hi": "33/2", + "u": 154, + "sq": "1849572338432898993359588216522365235706583650958895483252816151064471902616145475151201546384665049579538248983175402694571193972998775263334674039334213744153031050803547450527351119950537095212410572988993137273921030050520496737567489612790628809/78437011999712947095668433687533497894083501785050442958645069760273639221320466388467780409398820900588088974792844375568628341481805596653112486147776829876603968947669509592657277607941068708896636962890625000000000000000000000000000000000000000000", + "sign_lo": "-897423208163625/1024", + "sign_hi": "2730062129697/8" + }, + { + "index": 2, + "k": "53", + "lo": "53/4", + "hi": "27/2", + "u": 288, + "sq": "10676128204480959199819226010296252426779223329457874304191669663600046856606147649109671088362314100932913796632191040163067635708059696056598873143807850785206382784251323220266394481/129447314888176912062408466308736047480771643192195675820873012075936566414879644810728377693416130640959351951903169103521518501377105712890625000000000000000000000000000000000000000000", + "sign_lo": "-3747469/64", + "sign_hi": "866052" + } + ], + "total": "26729/27000" + }, + { + "m": 46, + "e": "145/552", + "components": [ + { + "index": 0, + "k": "63", + "lo": "63/4", + "hi": "16", + "u": 284, + "sq": "192762188060479913871564512376667727576072308017172644/2390480392089430846641333875165779317968999768047515625", + "sign_lo": "5973687227673/512", + "sign_hi": "-27745483632" + }, + { + "index": 1, + "k": "67", + "lo": "67/4", + "hi": "17", + "u": 153, + "sq": "5327678452603282871870861124238933765061819291966344105457333700475097719702532525752275753431008569906394641066375824880837369984703198449040323364426300087914480586911451341567533358128424083380540448709552498367610327532932047859997864613844503733101301602754395486831073479407399076972364168545322219643575108241/228178525629763606469562765865788017250903919157735699185913185688572096192692165732923257782146170880000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-807886348974849/1024", + "sign_hi": "660005312440" + }, + { + "index": 2, + "k": "54", + "lo": "27/2", + "hi": "55/4", + "u": 292, + "sq": "33881370441598725707726788782264012059500289582282986196537446842001526215277840208842806769481269820896524355405420203271141078917687459390290079785816771840048185409864652487472598516577280696288471093394432178515360793343423383665429203179836326627992093563079833984375/397691630697079175146122065833280202888493456302541040358019382760028726905311159159707864936500494764999512905589529334787629405695604839933141073492273569290548231753267824845755738776707475165600549199245083606790808423193868674951947673903957368385261897441980939501568", + "sign_lo": "-621513/2", + "sign_hi": "41877555/64" + } + ], + "total": "34213/34500" + }, + { + "m": 47, + "e": "37/141", + "components": [ + { + "index": 0, + "k": "64", + "lo": "16", + "hi": "65/4", + "u": 283, + "sq": "1208643499290733093373353210580348238504367095730126650624400526702724000000/15093543042703080644459120772267374392847971257013587713069095815803932902529", + "sign_lo": "37598089052", + "sign_hi": "-5774107965855/2048" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 138, + "sq": "4743487926628950605021700798348055777725434117788395367110257324449922931522924698765788277470768949886858283100009935198088681185544469145242536817619393486412484281905121557921399401055230832361785418909548068533076643600913436667228806906316792522084474082298227813998041083895965904609604739759193101411081449086356713103057969314729/249368232372990197774835590554404196320598264335835382752222842588054918487050882992731111435282677760000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-2152820201154", + "sign_hi": "-2152820201154" + }, + { + "index": 2, + "k": "55", + "lo": "55/4", + "hi": "14", + "u": 297, + "sq": "31116301469945849052731028268715753749870670257500600656322662557441449100683229642234163136297397888359073022375558543917527719168099429796263277402542945317416271622266596048499828842149600273291143332384137322606559278957145882624/354105422236656039353014321644743222515671112532079776483147440832607908900159245373108597297418469054895749840532472420186686284485156336425416728432935798972859828394858433190785119363362137539008589470768129103817045688629150390625", + "sign_lo": "-37692545/64", + "sign_hi": "417696" + } + ], + "total": "69119/70500" + }, + { + "m": 48, + "e": "151/576", + "components": [ + { + "index": 0, + "k": "66", + "lo": "33/2", + "hi": "67/4", + "u": 283, + "sq": "697044244289816667721268939263374854891502326028435345270374400/8738188288910343515497728685879910974215425843463908527875901489", + "sign_lo": "208528479513/8", + "sign_hi": "-22181092818483/1024" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 136, + "sq": "29252522156813354410293113011452809090062784173526434663506425665625419703985583355696257931261351028577665357660528979798952484940935889586874948161296111065307771260698416287489166245011983444234105191115080717148340015554700433225489756540088643309989416363380741521063/1604370290913852836269264994304000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-5124511031136", + "sign_hi": "-5124511031136" + }, + { + "index": 2, + "k": "56", + "lo": "14", + "hi": "57/4", + "u": 301, + "sq": "22256243155145652331992790594759864710247007668799102430373182592878435331118153456731014599495844148125346498557670412072879224291525076566767415742220400979278778840695126600570511546234067870580859384936003694564778842050943292843358987795796119353480792048656911/245908131138662974861075133458178140361860248011559898170364468966498505156465528267309129801258638794568084916041612574737451407807798579455305520307858983825203693595537643656853817701341535303692969577892352034931250000000000000000000000000000000000000000000000000", + "sign_lo": "-894424", + "sign_hi": "9909783/64" + } + ], + "total": "14143/14400" + }, + { + "m": 49, + "e": "11/42", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 261, + "sq": "226731525329919064081858560000000000000000000000000000/3350697821824282405808785553334973299280614906081607849", + "sign_lo": "10457952385", + "sign_hi": "10457952385" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 131, + "sq": "242175254484148440737987704325505081944797202632009559072685614813309516487770137871777414478888538563724826578733454007901621754257210236436809601505736222396252821552285759491630368985612310535528209963432479373990120430239420430947729247134642177160007178637880527759336891926089118314169126693079967580805258990424208131542712880577806921/14175004682950160276315848742688955600056433618261241600616530904540462300837426197462193135419995979776000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-8257413991640", + "sign_hi": "-8257413991640" + }, + { + "index": 2, + "k": "58", + "lo": "29/2", + "hi": "59/4", + "u": 306, + "sq": "14632288527747070725599662686499313086768730951685384040246870835171740213968569708637390769893545261425939157238397267938586943332911529185914418624317583006729206381939864225211178237679980197504481702776659940208696525223463398746058951657555985236398256445577526941399214241671213185146162728023903516978545230728486969489/157220779219787866427813155940336572657100695970259158984404261501249275350650954641661364860008564859831507848090018871222807633741408932218525290141243209638092292207050988145291272503447826580663187288138922397031447094639142401929229025769023392607733641076839215973596354538202285766601562500000000000000000000000000000000", + "sign_lo": "-271095/2", + "sign_hi": "65638519/64" + } + ], + "total": "10079/10500" + }, + { + "m": 50, + "e": "157/600", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 260, + "sq": "15829886789258636370640896000000000000000000/235636318223011240671712443943271264232153649", + "sign_lo": "97192809600", + "sign_hi": "97192809600" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 126, + "sq": "118569841129892748392490697577324327674803862739746714538562887785977725219970474720035634254648152912401843653468745537657756246440721280994026101015494439987819693465370307103274628335905523339528661120276619921939357023196558200920929156269665031534979256883302362384480399047/7555786372591432341913600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-11553875896800", + "sign_hi": "-11553875896800" + }, + { + "index": 2, + "k": "59", + "lo": "59/4", + "hi": "15", + "u": 310, + "sq": "615721409782928072474580502723987421268310866040440101829489368809130925890536382806658542460080064017459711475779602312781716467272563925944268703460693359375/6430209604048836086311103358776314070481685506201260548015229089106732521990253765931808879481901322397211457818529284706430809315266123561405594675258291388416", + "sign_lo": "-29108037/64", + "sign_hi": "753300" + } + ], + "total": "2873/3000" + }, + { + "m": 51, + "e": "40/153", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 258, + "sq": "183430610944000000000000000000000000/2764024563172579597072581051857294689", + "sign_lo": "183822045789", + "sign_hi": "183822045789" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 120, + "sq": "28049467964031454430399990775851745736812531074942041403497874202513850976209934065055139694234022902991737277224911637150958211236408741966821007367594031698109241801707842593032527654636498348909561447419060385921195337648032421816426424627180891833968106707287835036266952342081/1980704062856608439838598758400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-15016243560750", + "sign_hi": "-15016243560750" + }, + { + "index": 2, + "k": "60", + "lo": "15", + "hi": "61/4", + "u": 314, + "sq": "309828951632981422674192541706351291995572740823514133955143105471248521547797996937179811393122512866308319060051314049376720903805806901985195841486067044752844818918583060900914394846901905737882064598468268938808684298850442920871903585827362039073331728166366177377260320710912699521810411623940130896261446200496736342100659105227508635525438729/3149052958892764994778884837673609990030799493598678424230384430164701995965949291822289417379663636028757550701376375998671618763105773052341554950520445970448774254377947023429729116201771055495885194812115975452518679393617958794986215090947577328597445360978571646268238951100134377752599849729000000000000000000000000000000000000000000000000000000", + "sign_lo": "-804330", + "sign_hi": "28920851/64" + } + ], + "total": "36469/38250" + }, + { + "m": 52, + "e": "163/624", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 256, + "sq": "2124836554605108205587781386240000000000000000000000/32541433007931753756140467933867899649129216985421121", + "sign_lo": "270345660952", + "sign_hi": "270345660952" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 113, + "sq": "258051760218371391247841103729595048234377253883014919132669002507557819014214663909411181200384055089646474914601358075931455701433269726505940094353312685327678970784888098846152308397191322179656055617309697362904558656649117647605533234614298365508584293014251648305038451882838695406630650909128386275423750788735592034668491405460252402938531/20514009047371655285369941669651631583095957006727880129128971843502408876825869339852800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-18646863797624", + "sign_hi": "-18646863797624" + }, + { + "index": 2, + "k": "61", + "lo": "61/4", + "hi": "31/2", + "u": 318, + "sq": "518249494524407614145175981883162270580340631625143512432436856999584795558683749373188949299647225564536542018228855586278834266943590283335061051860554047420456198150536920215591849622803615062780818987920819315679032870245012077904645533186965362274457105967216784582194273723648887084794709880255216686403617678688734097979/5132852603594514499454144366095098346149327843341827364752063297465784946015682775213112912552160110401919470856086005395800861017351708173194439198595643329375951964239284467983683397414829177109555570511904724425919077567879523767504106776796217743705537167397387997500000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-75872001/64", + "sign_hi": "119977" + } + ], + "total": "73961/78000" + }, + { + "m": 53, + "e": "83/318", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 254, + "sq": "3476253760848225116499091193856000000000000000000000000/54282369687160592158110376013801193391599202888438407721", + "sign_lo": "356763655089", + "sign_hi": "356763655089" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 105, + "sq": "1002772932988752026908568576000650489256528145928765103648052072090319313795425064479649044771300281369460841243289887745843655819118111746306239956425906899368621852006892627758545625378405430121672605907476719752892513965958091691223347751620156493271234533077719072889510603827365462854539165861696451683445316247533069534533943464033569100268051719197726014100583197176394871068969/91025864375173611224680792127325439482441009587532512931023483058727922787807931133567823519342342972982933226719805440000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-22448083421556", + "sign_hi": "-22448083421556" + }, + { + "index": 2, + "k": "63", + "lo": "63/4", + "hi": "16", + "u": 322, + "sq": "8869029747634942785133248777345236641452028906084010543588219363109988677701019158069552748485628681176150701294467549923483763471159132150606086936229468444431805313303776542371541309853834705348980676664556019173768797617603009994171444191465103797333154685060644864/85693902311671922895943008891983173815904214019082273360495860907767538525488084499496003506564947630668116523342564724330158909092300974985332605887971723345805781209219229693155816485491806638785417115322401740303131997076994431916663330639494233764708042144775390625", + "sign_lo": "-15606513/64", + "sign_hi": "1190908" + } + ], + "total": "149779/159000" + }, + { + "m": 54, + "e": "169/648", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 251, + "sq": "3961940278027569321738240000000000000000000000000000/63243281254700073070644585624999629577531295004196481", + "sign_lo": "443076028200", + "sign_hi": "443076028200" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 98, + "sq": "1469717661167112088172025741638458809703138667454691479150808881829496229587289669061475438587938371074104304715608690248708322884433050152313840105129791735473112038474869026442299863307396973150808140770855454238987085009359965891610407771916737092429148457267510196675254672724459647338519195992630688521268390224183647295130315148172302348259263/154311245596222747736413854341664624979591195838870048838987426168609746828390301696000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-26422249246680", + "sign_hi": "-26422249246680" + }, + { + "index": 2, + "k": "64", + "lo": "16", + "hi": "65/4", + "u": 326, + "sq": "1540713499816691451450168760794815958548803324287307248866666376820739955947143408631346535613597057455246411205338911726882253965602116613903041802096935423717831951594561390237150711480272860699294978623944875353088922864228621922387934122931587625711784873469538280999634500917548779610406227727626385467374348081648349761962890625/14520790003925058683367279910693817968566063270753146295534456297865184605021529204697029481442530985645359216486647626304859856567949289045037866716525085939933462662690401958816783217115272033742450813246407314824384487276142321147941493765629874923284469296965620965990733106837958807678263974227195449346588464038454621575470645248", + "sign_lo": "-641044", + "sign_hi": "54248615/64" + } + ], + "total": "379/405" + }, + { + "m": 55, + "e": "43/165", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 248, + "sq": "14448031664094307067203525017600000000000000000000/236253291542505615720637955928526274661604422809641", + "sign_lo": "529282780285", + "sign_hi": "529282780285" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 91, + "sq": "277064168731605384328225627427251810587309067978737075076737777574424556744117840951282836334323691249058208430235211079120104695779490858287781647597507890065686307426422252100826329480077492679199124976403089143904449180768056270296594859832605494481785576504364776728765992105743594425237950781530688777363756788838261097849462910818264667086449002304303715689/34042746510276992396790454843552497556762937527859049242031008205499123537852959293440000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-30571708087130", + "sign_hi": "-30571708087130" + }, + { + "index": 2, + "k": "65", + "lo": "65/4", + "hi": "33/2", + "u": 330, + "sq": "768674250846312209883312565088717611221331600247515798191973781037932729868931974393983968356660460534687332434868467063011848464709335013614306297746577871360507350993399397467781635917242496121918322601363284578762977683651123771799155672012435721/7074784114767971108871824476511743376736146390290222958783650635066801403470453840372575214326394260419941039284643057207454431735603172642448919190015697093739065595255893520177201045395738516601562500000000000000000000000000000000000000000000000000", + "sign_lo": "-68676725/64", + "sign_hi": "470745" + } + ], + "total": "30677/33000" + }, + { + "m": 56, + "e": "25/96", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 245, + "sq": "6500950886507080314903330816000000000000000000000000/109077275790632816102301759708160835137523397863154721", + "sign_lo": "615383911344", + "sign_hi": "615383911344" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 83, + "sq": "229475183867012584380320481060051683813147494124867430966928875124106670122273346824528165582632309432148941414187703618348687491902212053318010585317316672007504207435887378717114836257432838413577269984067398281739455087464157579158795033398592529500376068982360898240919314444422147170117071931455757913532032242084491173508354958711030593597195384241/33350587111153081730291536833890673373855342382046560889787200129777585356800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-34898806757040", + "sign_hi": "-34898806757040" + }, + { + "index": 2, + "k": "66", + "lo": "33/2", + "hi": "67/4", + "u": 334, + "sq": "1023809637158695041287391891012858719018755247615852431798056713781171630669057956120432089884497271185856035108066902488605538404317352403117693615105076076040275246507552489185463380790457168032374428414797103953621527051880644835098871887785397527723635714861784976733209059919073682067586484653021970277918678026000086914241651292627101463653201011910057330892654482343668428941721988567/9212479294322018209732352558501960526960320154138321240717742942308235805258569240131702137532541496613307633746676952233651611024686216966732317228236584397665098199588528893216506751340994917128824153629140269684844054905589578631110475293370716416862263226119735620891175168551565346219308617030432777878625082745197397281733000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-3082887/2", + "sign_hi": "3759931/64" + } + ], + "total": "11069/12000" + }, + { + "m": 57, + "e": "89/342", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 241, + "sq": "18933060602415252041535324160000000000000000000000/326397279356000564240138335136244306492159398708241", + "sign_lo": "701379421377", + "sign_hi": "701379421377" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 76, + "sq": "241063939835339153718168664891791782028017978322876566796857900058267549677343941937629910075482283350735735660132959397674227215833971993177606929045022806820204181020762751710335560783797280446018215697558724604104791683810367839683609468747778870758518332686120928313153737314828231063944346473871634624703226115589258691801120227734823591481271176243886913577475411232518418952094010361/41849111184888226294830139378296772977403279401084519786407496761715079260578763865719453777133081460736000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-39405892070544", + "sign_hi": "-39405892070544" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 319, + "sq": "3944321443812641076228995391274653519777841054489922914829180399887307223301883716251449475960649193288006736754786682626911455133610751495434774220095167468433340442897679047173871084190447486168737869770321069879881739167866938071281478031706096376876585402118197818939799419907506317229375872457405545770001/38829277342286595270690095226128505630945697310322132335112807251962899726336000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-389872", + "sign_hi": "-389872" + } + ], + "total": "19157/21375" + }, + { + "m": 58, + "e": "181/696", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 238, + "sq": "187659156390323047152343842816000000000000000000000000/3327549251564828360424785067213737594822366401910034601", + "sign_lo": "787269310384", + "sign_hi": "787269310384" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 70, + "sq": "137726103743815937536065488465333695958681456063438133269784629990671362593988983922457720701625195719460691948176496437847375307646313155689002318150134181471449167291672830848984352667925014974868743726009069308475209852208591618280678715045929588498917947464260734759244325093453966321160599308195260509975694594293033901788185948657660128765124546916872994139572391485354911424106176614945230156335747/28819433961133959862483916253080076114072216217750687427024145596113392597733627912639129825290116138256919062118400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-44095310841776", + "sign_hi": "-44095310841776" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 322, + "sq": "85570290888240194998697911409905619553999470413284614314415689793940334415916433686774123956097978960089886618480581368291795202616046461457391814064117146110280946297027919751560545059212076817957746032641854488420482479940856591422396025431924785800790939552004050566496543133164572371785620996852095076028343/827235787519630012720605899255461274836710287254727653936693934288126607360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-2593352", + "sign_hi": "-2593352" + } + ], + "total": "15487/17400" + }, + { + "m": 59, + "e": "46/177", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 235, + "sq": "15182037537841674495248400000000000000000000000000000000/277125241898152397995822344336074685413819376482210503201", + "sign_lo": "873053578365", + "sign_hi": "873053578365" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 63, + "sq": "1672928870687096755250386949594607029176325671889970390202599125078806937621678065083525197353959216158516132268107115435785065050919351938427230784115353614960964530876968053222919291491011331745402608350979464980738877335776628328753692334743685770282781825978113069832251800023031595804589481017439089610196359641633384306616160069493073453489823066297547275979431275518074571686394203930912224961007592771347158073132721/425496676549827027669106369224484509171017013327583779192091489350976869418236047435221474234661228542785946543605925670878637241250349056000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-48969409884870", + "sign_hi": "-48969409884870" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 324, + "sq": "11401203075690201628893656569962720576046543800614995501835319937037876099826098132313358241133384539903008282649146403716670360981544234204114850300775011093144310759653719927573494491238962706294900399303284256915792011244286674506152018651511671087953725306716912291677650032741820392487907193019841352517907041/109056998766219172483401321108702991818383955421271693105192615210107896784182312960000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-4863630", + "sign_hi": "-4863630" + } + ], + "total": "78047/88500" + }, + { + "m": 60, + "e": "187/720", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 231, + "sq": "114277564107089510400000000000000000000/2148716008870371333169059618290011950721", + "sign_lo": "958732225320", + "sign_hi": "958732225320" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 57, + "sq": "1666550813942302733778014347861012562393367509906353239490025644811063160956733115100187705017804607609437782221347930430010801282199035764613773646467453250387475796416023028314746831282648468825274545361293760183763920657853040893908786004799600085609409710673008534194340634475762798107761715502248279743054184888133780250754740757127/519229685853482762853049632922009600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-54030536013960", + "sign_hi": "-54030536013960" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 324, + "sq": "998469240815300617365331540351445495113194004298528067830471005833440693785712496538941689894195656543157766132798021149707412462006574447358431720545692526992993490572854428143463465919023115463132701763432741458004438456662288006771960766614366520311507759156825300953074054720216330521069882572529599384365637171537211640807/9516249174156585361055200024926323977257720901813064286326416796917631039412633600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-7200706", + "sign_hi": "-7200706" + } + ], + "total": "15691/18000" + }, + { + "m": 61, + "e": "95/366", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 228, + "sq": "2803170496946934733907313263616000000000000000000000000/54319097954293509509886404129047312387176990686778996121", + "sign_lo": "1044305251249", + "sign_hi": "1044305251249" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 52, + "sq": "1779700891521289675727033856487613154386274283986867643728801812001935525275324079199220653195005722340277021836779133849792760073355329971637330364710096833818586865253990804885079115141616619333624748305555064325051831907050704551871074514651298384048172133684733156670130547826361489389654480321251422458563715115682391469713371085280576865519924218178669631225440203453724660983485457779188682728472234649763975498424755181163635543007749249/684147296318722016513825845747416635822083767747123024248784467192098299784463565636959965400081783934874474739453022928803838647708675997696000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-59281036043180", + "sign_hi": "-59281036043180" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 324, + "sq": "516373418510123557656385511038316889842519892780084733381203585843123882806691577500340845723832336663718250396279737333962557390923867043484579154257798184447308782596596452264388886254097134344006127760774582823842705806729283561082418840700609119078947674982614312577566631333114619840397876605625979459585621102679783609/4935562433715216654270098662253626916583399624186903184949292221537223023001600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-9604580", + "sign_hi": "-9604580" + } + ], + "total": "19754/22875" + }, + { + "m": 62, + "e": "193/744", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 224, + "sq": "82353144022138737321782826038722560000000000000000000000/1645222739087498577902561203668785019953622272295375836401", + "sign_lo": "1129772656152", + "sign_hi": "1129772656152" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 46, + "sq": "1021947000523303729408198497792612138237042159855658990635217337448748343437420736623616037546518594734417868174353063054710838433031652322819188368603697435916992595993294047969197114874749884714405005567353595489056766928557335651186839545105837592217853540203522090300099294575073058148828138015544615785834544569390888013696295737764012542347106275236728191433275176583392135281924188999304410867696734655713232997073501226573781113/488003389260134113302288714608771070206951859519149807766705719270481133194637700322949433865943773348443630370113544005877760000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-64723256786664", + "sign_hi": "-64723256786664" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 323, + "sq": "46830770440278560532978432467451817506571567341531115277855532188686930305524164519985668725389400987017049362612895686360330249547924190107579678054056345878483225624241795899010232683066014966819347103381133354928168233616406867272037491588645094522480351267450327226251757351999383738520590534713983922383251339730865862174663582687/451610639820468075653039369084157893439242952426782952057268471201868811302495846400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-12075252", + "sign_hi": "-12075252" + } + ], + "total": "39637/46500" + }, + { + "m": 63, + "e": "7/27", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 221, + "sq": "176652855831383309071470034944000000000000000000000000/3639284185771218935456378907204261455805273259065120889", + "sign_lo": "1215134440029", + "sign_hi": "1215134440029" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 41, + "sq": "888677733146756745422254117066397136737819182204235757233284133477998671696141507639500347516287468191226612000223844269382642539828544148466284548803674330266954714064686351096572564966018611442752899408022098474087517419712382503973983136525897663182942533747775349205772631140458988545890487737411870036256788544507956428708641404228346282391774990818361234001286292569037867764353358772778270556587836910294706957911690009/530484370180907138370183358221353162420616804360097481541006986576647971706179736569937560162890447468107923456000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-70359545058546", + "sign_hi": "-70359545058546" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 320, + "sq": "295423877573655249930494281962224381031109825058747224492258056577979623515345124719850090198684335907341979090166324810447476852763885473788351213006941460956455397859237464575808836072173409677013917229870338773567852092364852888915950041819861183381140933595459756177195698090061313106533831893145268070908911565507448133144408870989049/2890560686650062803420517007571370908092032723925718276971649102063730428221587456000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-14612722", + "sign_hi": "-14612722" + } + ], + "total": "11357/13500" + }, + { + "m": 64, + "e": "199/768", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 217, + "sq": "331711445709987840000000000000000000000000000/7048169714899769755878374652010748118000509401", + "sign_lo": "1300390602880", + "sign_hi": "1300390602880" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 37, + "sq": "11605008124897616096261888144944157554515701756469867301655547669841411546486592726842634202615519312330108866108433176402491741759159155878260180462108616753760742931584329624887609658569325866215992496470043042495466697472755652948025740537036753972655016320999552209635036039271913727966322209859109445172036269473244365565303020040911125511124555099663/8711228593176024664662389950253266213273600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-76192247672960", + "sign_hi": "-76192247672960" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 317, + "sq": "35111710085446301005286835125551650361266268036136512426402276673619853092152467291941181848950985973490921315792179932121268268097715134653367214826264950137216373716910286850222193162243499436806900830019507400901750479499549587507941602198104343276560239094232340806382311050533033484791115408513589386527005952915094527630598659614077567/350411342451899369931107991750659690430577495171319772079197017520801602538338034647040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-17216990", + "sign_hi": "-17216990" + } + ], + "total": "79691/96000" + }, + { + "m": 65, + "e": "101/390", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 214, + "sq": "34334340789477200651098678886400000000000000000000/752491988081647924044447477705043714526959478413249", + "sign_lo": "1385541144705", + "sign_hi": "1385541144705" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 33, + "sq": "67028099253983982210578301458545688459876254728695732007036977674293956489337971117238201842055266900602714053110060610624348379872185452488414328634147241068814748698171034722917910569991694818127897562415184129094860732558066523735941702796936407692643205905602803882383765420562885275337839261656519110431437064906129522066301131071680160439006579097976389524483011894770988985946951849772416813304729288409176493865376908422201/63622990611017036966757235610990171775788273116850987339477383422861603441190996832018620605774237270016000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-82223711444040", + "sign_hi": "-82223711444040" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 313, + "sq": "94328786027368357163508333634122177350833298740384829049352023307866757128329664351987144718009791133303943991346340938022345990943741920840889958576428612261916066827981725012609595848601537336205231659401988966198833859864512836645416797727484265813042103435701628096557806681817216714657108932610184538583546470654104298449453058339888452919149169/964947666259477755610997282527529251293932899443844718633498663207447787396441047040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-19888056", + "sign_hi": "-19888056" + } + ], + "total": "1597/1950" + }, + { + "m": 66, + "e": "205/792", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 211, + "sq": "1068572247761995850762420224000000000000000000000000/24157012391329495240490380875419103775001669888095569", + "sign_lo": "1470586065504", + "sign_hi": "1470586065504" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 29, + "sq": "42731835733678186630267278274282042449703341698724650000771593467089926039996613732868086320265600156900397377092074771425766308983673895365937920572450195339090587361290113396982063261285637573689762174551083689764628445614913707678821222258187655824220501904965986986338897889805928773919449221394805219538415734207285221932578718718676482829492356077455885879615921014103635807211528110865796679328935693507759096336931584672613/51559545123749720061894407155804674281971639261348798605794764299424493392898892855941864516513892925440000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-88456283185920", + "sign_hi": "-88456283185920" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 309, + "sq": "127494459460214201534549422466853837461446475495185170854046760889629279532104993656493549272674374996561226094674394763459886858265362300965360724295640115618253584762356518421153555274846546235244652430030352049653262261399522788695577977435567469770513850012748216535550383879996633340177142166135299905616513868932916844959350920278314097685767434503/1343070117445085180981309022397961778735882084844845740212107038782891706168878395555840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-22625920", + "sign_hi": "-22625920" + } + ], + "total": "9997/12375" + }, + { + "m": 67, + "e": "52/201", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 208, + "sq": "63756049401527131709522840125440000000000000000000000/1486662758945285781036823009555103654656148229077590561", + "sign_lo": "1555525365277", + "sign_hi": "1555525365277" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 26, + "sq": "1144694541565407030558652473852265226912428080290126567042291328215904771856339540791252797191322715236227751730603201835120033864642845959175021943047192101485620240478255042318008714796430226358197185603631516258858940402091402949550644633224871578642794665422824710649524115941693959858246150084675925876785097982106252478468338023899708672085036408103949603139354309002180951474531026927923433788210587959606019279288717198470917276414323227252473478024662495049469502160850759898595823969/1764397563018168477050619438416212114435324772936347459032712743994890330960428335828896793883674935265714789967103416423519325102987105946139299358543813017600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-94892309712734", + "sign_hi": "-94892309712734" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 303, + "sq": "17129782869270285828733222743090733471417005151033623491132876586721205202288073009257061482719945639344536094921599186391571281795760546967560190084647102937489318468077664787062235718507080970702538738431156021842871359238885801446897583913829648127331943920250930923591704295036518285425064137346544970258234942444239875211595909753822124463880748126800317409/186639723365614274415937860018260184635407986975217398934489377456622778169964679355432960000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-25430582", + "sign_hi": "-25430582" + } + ], + "total": "159937/201000" + }, + { + "m": 68, + "e": "211/816", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 204, + "sq": "4362904817672487174144000000000000000000000000/104926341231840161214500129528614172816738631169", + "sign_lo": "1640359044024", + "sign_hi": "1640359044024" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 23, + "sq": "6880368371440001138081185582747470684484362055328871011854344175773724845584520340050643565379984886445061751280239739989648140315373379263347811717643587970398510238012908136405709640720749206059472219719378654619906574353033067537081027040250866484957288363474689865491832415884425987231507703834183538499640466000418116877348067681609595195693292679697610748298476368096665263/13611294676837538538534984297270728458240000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-101534137838616", + "sign_hi": "-101534137838616" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 298, + "sq": "4571344243198537162841959708164982237633007580916751894437469424916508840313863790646816875155961009396322439593207363733515804543566333409087126711362385112069370057162550645828248396634872423613829518457812909937171047416891916237264558064484853932107093304292472575482622348832850724233587129030545460541781160726904550077354688201470171950669763041270642081742943/51728598401105514737654989512211760150587926280928153053761261718964534570715806519682662400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-28302042", + "sign_hi": "-28302042" + } + ], + "total": "3197/4080" + }, + { + "m": 69, + "e": "107/414", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 201, + "sq": "17970062828215979250524160000000000000000000000000000/445682618042768758803925685979993514032118234799929369", + "sign_lo": "1725087101745", + "sign_hi": "1725087101745" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 20, + "sq": "845005972193600746203306211124054336944584779066109027338421209598075512674770517117739888236537186539085680463482110451405917817473182824788299799915043545774133606876771924395027920950033884774366156405452280739152397570859439466124903820111723935214532601510113705664668111367653407261957599138385251639964300273837287252300064558608290131675709194186709107491943893301958059098081473233431143365413328913565372520128513255125636821780314727714980851296863783237120281/2155024822133800119634308892351844781971821189495922124482169247762955951775861007372882254705393201443479453356391677981645944651776000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-108384114377700", + "sign_hi": "-108384114377700" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 292, + "sq": "45088915740516893285604232179781162410180906793477063530723406157770593846747109157512891032813646195105885174097521049380450561459742163845816325591428927648103619451969196046710894081496458096302013640028317798600752404863196503618732486998997980700530935850641812287537955369602833666074945317259910829496642161586451558598792027973315477824452952477101217980324114089/531964491093352848238506874946102810566210092770757703248147912815018722036944382454851776282624000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-31240300", + "sign_hi": "-31240300" + } + ], + "total": "159691/207000" + }, + { + "m": 70, + "e": "31/120", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 198, + "sq": "5303390569468194168981984116736000000000000000000/135622850965394303288738153151864305824592258120209", + "sign_lo": "1809709538440", + "sign_hi": "1809709538440" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 18, + "sq": "44898731079325435517782484704831203181133806844116895239517220075129401197227860868027115684537550043917306923321048125771159449486105441590562532672109828512046154561018917021418568497391849233632391082303816907957223358638129746629629725293892219367328555484351909728190259097208378856053824988238327332590754526559086992431944863516674899904853723526980482623307202587386756424619744914207934300638718841719843410312142905233664983144153649/148236780646200095609679825837096966420810671642159361923901413744481963393759851692184043520000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-115444586144120", + "sign_hi": "-115444586144120" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 285, + "sq": "14368217741853268230922102170032774019898599675770121362824425071579682237826365976731981740411916531703722669144917953857092225089263972498532187150184322827772100006253794683062317049330045201406334489460684132774733815549825226097874212059734090063193975124127605464695287696413001088767167059193575770824730149066578545435616678981750656164356696131404755921557831807143/177395742116274056027623420823771468280479856930480634615093490119905811285033630040064000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-34245356", + "sign_hi": "-34245356" + } + ], + "total": "1139/1500" + }, + { + "m": 71, + "e": "55/213", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 195, + "sq": "41366755757353676949068334759936000000000000000000000000/1090581816728761922355722734136286934531460089807912131241", + "sign_lo": "1894226354109", + "sign_hi": "1894226354109" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 16, + "sq": "122856857395378958402542851423812625455242187824188082368561761393317931621831444447871196975340002573424910152059499117087370960994046818689853260498436488991440252811199716694725139291736186322078515416336568564618007952409065602399289624264798803620227417503044514557855625742800417881751214486704216001645589741666340394600358683778336074493894542357004861047712724696368015790618552228828684386006437951543618311612689904940910962016634175290349671371002727606118995551797116927904304528059959244593393784659044788881/527210251759413660632841939793951871725430680532506348550012059675640236823664735092449342570157197649015053006785984852346055556823949660169992904748739675879545136742400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-122717899952010", + "sign_hi": "-122717899952010" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 278, + "sq": "4826946552927276939141036861938319250076125406120570053027354544921623627027628326678286665745981025871919495979508082285229910135979884683377809438886205458471016670367978671521969017923757803418407297440178093049135879039566302077772124967176706122533632496963196184698185607545449807925266885628725328547409164122252785554740351509072881952409839985397840076090404542014000426809/62583327489593495950204512511454275900587296731718116690562524878072052505034811359772872278016000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-37317210", + "sign_hi": "-37317210" + } + ], + "total": "159157/213000" + }, + { + "m": 72, + "e": "223/864", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 192, + "sq": "144543551124781182379622400000000000000000000/3927786522590572582740036097728915871166856601", + "sign_lo": "1978637548752", + "sign_hi": "1978637548752" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 14, + "sq": "151425159351870780066972513821258060528435210071349283484242260317841862788701260450359146503884993224213120467536410094541810066545721609257005154452633500147258917745765928083141124615495419782285465569793263913721742716382674050245444227187248803947058717426972712537590300789883054301325970549871845951022751226024649976805131418745213080477527982448313308034149382106041760099561099094499595629972312289849417351886086660182137187029/847800165345269235368460957110334837197892071381657016957297463356262535135232000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-130206402615504", + "sign_hi": "-130206402615504" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 271, + "sq": "36634413038396955678019863655848875280188947989173732393423713094949239642336654123729368270805410121732935301736984840058234752585754962944553391214525743867124524622774437831002910705620086626312632440653653850997908625960464051140890028527517219126332952922296900077427894599466651738595020823980075222107789346440659705710773434310359524302091354993642996464847841546085208647747439611143/500452885624730343791622467699768070165637768636420343344586546092955533617757824480172692612317184000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-40455862", + "sign_hi": "-40455862" + } + ], + "total": "79391/108000" + }, + { + "m": 73, + "e": "113/438", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 189, + "sq": "54295557458725131710551789142016000000000000000000000000/1520417099025837456705391107838229298668809009907143013161", + "sign_lo": "2062943122369", + "sign_hi": "2062943122369" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 12, + "sq": "10715905446671541435946951891304010300136934917664079584708177726741186910856630905950739068419556829683040654350552095013292453376842599808631270148359772565492348005352069601300059572732742464777239066018460580564954929922424943668569656923510116731740021455690830869096720096541581210393777838360230792895682119441065695604139063665505433820079026351906609703846113674674723069585356893042445872569025916875619019852163668727712263021972726095539183007738223957865351409787867459951296831595174523659231002016690856076193191387616796761/78560702139019809801359642949714998594237114323076967669985031538586222352020093367397464317597086674851829394985480636820103897512796777504536913851079420443301027943913881600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-137912440948736", + "sign_hi": "-137912440948736" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 264, + "sq": "81457706083694398389158269930388689639636742337461380370963453809891026594149218351367066354857440155622056677410743338090718446771147746930655104841253577825977962667021149526543162735996870147526406911684679504790521397459342765701282045902900898801353542623325734895032137527772247795232942156075022800477334597259338593478185807878426506045696068133186799352809826493583040766005137452001/1176156590419162828957710673538459604661261052377882144526906725121544553503336673891792673832960000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-43661312", + "sign_hi": "-43661312" + } + ], + "total": "31667/43800" + }, + { + "m": 74, + "e": "229/888", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 187, + "sq": "505908683766655134769128407040000000000000000000000000000/14595544412639227982874644023871618393444422142338827603001", + "sign_lo": "2147143074960", + "sign_hi": "2147143074960" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 11, + "sq": "31824907833569419258809367288925451596573808653376812365580499800179169067634261825117968185902020330645979596997343308743803169876853123046892731002878638112236403494577643665310343641257411970882378431588512117416567427821758709554736667804289352414307511974488970406998627549928617800504756431810020281893309934442624050532076901141382330459370144489521866521948929875888468721952646676612235459480486481952914143288071686119194831605943247687751230672859171110334753247804284465076430625028839482326831085061379/306564457184540121304397578800232088429090393406858732269254452462872654159791715326359336441707891070367905846478686288631239841441872251214182753291468800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-145838361765840", + "sign_hi": "-145838361765840" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 256, + "sq": "2210262936112089462747014620787661728832134363159423527522147424942399628878517009480798331217945819149298610942350412235123473120537982540289798419171229332407700709952372589120623958182272744723559600699651494844688105130281708501833516150511956651369956785247607476434567199227785388604336195511777541394960425737707457404961960975647060721259623720737886550357314169970266126390796782647847/33833086440506461266702773248443579657123857050037503705616739832160796322109158603128711910432702464000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-46933560", + "sign_hi": "-46933560" + } + ], + "total": "79019/111000" + }, + { + "m": 75, + "e": "58/225", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 184, + "sq": "406371556223595053056000000000000000000/12075810663936142222840740747164239625049", + "sign_lo": "2231237406525", + "sign_hi": "2231237406525" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 9, + "sq": "1389128126895813547138312810246616738742610452608872768170867266787157010740205645426214864349054542245989612242065642494555051605302781528176086963044719696058485305507389554447265059354289508923130895638946249880258656901326899882710780190706492739910997463640399062024253159875170190295649739291511314200938237465839208937493457158434439065522025748536947574061902011868903928603343391446044661136549072992817859515049/17640237901181449945941339649262864081879040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-153986511880950", + "sign_hi": "-153986511880950" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 248, + "sq": "115315370872536767566686644591079889226916514709767868102489149365145002236511275692581764826197914854015267287922251749282819070934549052125950349684967155172771037604855814987552673291000467678426274135421069254577429184808729570704537762025484102167653972874888657644009940304573890083327856443938973176026303909514314089150516558878555876196373810055703343576458777980433161533139441749109077229648233209/1876698321092738789218584253874130263121141632386576287542199547848583251066591841800647597296189440000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-50272606", + "sign_hi": "-50272606" + } + ], + "total": "6289/9000" + }, + { + "m": 76, + "e": "235/912", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 181, + "sq": "21052643802835585248994000896000000000000000000000000/644221608014480744805165258986902057023283781908569601", + "sign_lo": "2315226117064", + "sign_hi": "2315226117064" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 8, + "sq": "685304689471663725583501312750102912793915245247686836606243106700860756241572017536433321887682477234530511886517544709704004225659168707042261438994382453654216274156157610551788485324014845715737301586757338593069053128791064506499797663026671856839554046568049356163230461420799590507926740929010085130419324562484443216582123571397158344914197038197382061688934070052631373098859767207026151762525048588690610598925943032056864971131473759580406532630170612429142354277532457332487302326724142019151615941990077/11508518523254354969652121833759470795947906216015773915966628226936572684777252626606799355580217059073356586346746910930658868907738933493760000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-162359238108200", + "sign_hi": "-162359238108200" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 241, + "sq": "234022511557805425536427431320012693033472387524623561112037572546314556101537729577079022195284500127429378130614236011946962857652650160601584365899028040190403170079365532813480638649632471719454965688104619984311749382204545411574435125639775933259164236487025403154998731639425622130921141065906826930521331732563461493911773213406838554867706866371767122400626576413173608667431673815330193332922019343/4060343824671172955992018170639606340514904144970396483997437387652264787473795960024988932605533487104000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-53678450", + "sign_hi": "-53678450" + } + ], + "total": "15679/22800" + }, + { + "m": 77, + "e": "17/66", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 179, + "sq": "420200053812608814876295390304010240000000000000000000000/13237556025709312535736661182551669997805285704448401100081", + "sign_lo": "2399109206577", + "sign_hi": "2399109206577" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 7, + "sq": "5025160080656206890515717588840441994976286666194549867549164152907372694548979619647783679521094283454299962460111808752007997197506644578034800671576868692707153248972459664563213295222377529835202649279893344167764737445549605259011237033641578540344953768384904458350173552584692345028883510980558783477976769005630518466101333859892448807492197808082988882521553469705652686738682364825677203440731115466039244836494104234110596357484741666581242701454184962137162233862020072984503414874639461616299792165631257346285005620418503728089846349944525668293959841/111935091165084203197865625851741287211393628232432528493082224446433025330974687022504321733059233234615435571287054302944729874400840298234017049622105305046212997255952310269378560000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-170958887261724", + "sign_hi": "-170958887261724" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 233, + "sq": "13931522371971385996310735500432309758583387520468363245296267212458126574564776461806586542816079029949262908681386326875688732414110485338347131888499758911845357575850210349539229384095158211025402566734357223688146844773688577118188100172194586928394090723083976821503856644494698309660643919374166593209948322773428980024556657263312924662335104757966228060743374077319762152241342283061595489832589005502818889/258367143085194118821488292657800262357513258688029275924031880862923176822394439518297155439318951526400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-57151092", + "sign_hi": "-57151092" + } + ], + "total": "22327/33000" + }, + { + "m": 78, + "e": "241/936", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 176, + "sq": "182189307229264471392256000000000000000000000000/5907209889179239206634962489672385114270158476721", + "sign_lo": "2482886675064", + "sign_hi": "2482886675064" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 6, + "sq": "44689828356456868626829311477848879788112954212889767609582951417531850214941426263282179349003450919893946458315616659067828032758332032115309706832436957684104007939596760606796635046053292043176419444103553284418672963914689892913738192537907888762000648100380462583432256441079149548563359030721034656127313982516703709785784716005706564948003548256969441758864659512341910744253387690771799831876418602603669610807952830420202834688189700357128314747961183376151886538212446646502932065907553473140589030998545579/1324211951528275309622078143937537387436915482958679743217625238431188547167936254897343440823798790596884077153858280165713379328000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-179787806155656", + "sign_hi": "-179787806155656" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 225, + "sq": "353001217932566716784609874655734700728674455244037290307244311942323120166276355064937683778739461752171504508055514484059792665806452809914559522718371800431208188616104251682559830519741985821460820545398679774488666876811187108030929974125132617071449895860526375893296202333330374273424400228114659843822767365584775334318260186854675803832996943764836500763750040637653724168037936136899887020920621650632518311198527/7015116340548540084391444439390336115197353384820693073965102314973663538886130543932502004910090170138624000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-60690532", + "sign_hi": "-60690532" + } + ], + "total": "9718/14625" + }, + { + "m": 79, + "e": "61/237", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 174, + "sq": "533177648627877167431634288640000000000000000000000000000/17787789877404094069234460831384448623027660326591126626961", + "sign_lo": "2566558522525", + "sign_hi": "2566558522525" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 6, + "sq": "9342672566113224030771016590605620708661581955199548785448175461672560091405800497674481070673228230906723636747735363932401579073844415641578019476922590855141896838297232957553755984438065485378538080194937151209272065344015644291541620467924031026493010519252731350949590416182537829005305135175298744688718403836684652550554567171720788514446821426565433180824346947909026322289714551529142331327685707618680380917789853454124662221844961888990578758095183533578481121723649932428424291078697671521708305791962690433076088108359353494553920917553764937114159928401100524946449/369277187039229186394733905236060175600874060355900688778300368114349559088770744935088099385818236365861185086253949372816909577734558024149467077590171558100476846642427868070806763257567641600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-188848341604130", + "sign_hi": "-188848341604130" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 217, + "sq": "21922972405556724960646940816494791476198305723833862755229046653280222752712512733093929187394526179022765011729682329539005069435267786046610981783726300697891066099851184557290583327558233387330576162430162844775960360470447897961642768732729631800875722814888234759969596615009180447049502066013000679536561120600422997134904295248491470910709665157120294014744480545599873364032798510389485764780104195118672807169/467970559737262980948221337081473373428504464797049759125170946192756870519371386639260497292541726556160000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-64296770", + "sign_hi": "-64296770" + } + ], + "total": "155089/237000" + }, + { + "m": 80, + "e": "247/960", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 171, + "sq": "422463545703213316020633600000000000000000000/14498100074324544140627021920836325645098005641", + "sign_lo": "2650124748960", + "sign_hi": "2650124748960" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 5, + "sq": "1727881366479538734485160999933473541291561196806847519590113136484096663466228361683450773157615499427975856766105805241160155667276262555395237211071852123917321196508280472540670351785115949122371196533892649166805654518576698900830518811563028185879518936204417817538108719084480742831071184280370164975448264250842780448458815031619737428801420275783326631676652941221242109724964584204758846639244765771190294745606507851166104922073673089583/91343852333181432387730302044767688728495783936000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-198142840421280", + "sign_hi": "-198142840421280" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 209, + "sq": "45104633844449588975055707848166240806464434479066131910621054200920525566416260088600746416439234188405004557349720297373659413932806476550127777251794345109099401953628676421300983755959449634844320273429419469285902078310457901040971904875777331704111139511144539531800392211530678305826098173900600773358061122559815528844985407447328738954926128782283281206704586661393688561379600429914459031516921141687418275948389409588247/1036568661722147644388433226055806427539760570638425872479789001789564329123504253949869750772648105738240000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-67969806", + "sign_hi": "-67969806" + } + ], + "total": "3083/4800" + }, + { + "m": 81, + "e": "125/486", + "components": [ + { + "index": 0, + "k": "B", + "lo": "17", + "hi": "17", + "u": 169, + "sq": "112354595222537012310243016704000000000000000000000000/3965196883689423067146616044472864997994887461426122649", + "sign_lo": "2733585354369", + "sign_hi": "2733585354369" + }, + { + "index": 1, + "k": "B", + "lo": "17", + "hi": "17", + "u": 4, + "sq": "13166494534609042047137136678883648965397864226237954343068944585618840416059341457901700641817245736724926152626109392531710905528535202003884116804200218414119338562113220346045731819625403332438102511764702738222282388120642214850198734288919249703451718519368942459616801785121025862609337992036876063094075272239343878705980816641834575118384841102415164081034362954068922908015970309447172479833420736037169528833204720317659367624183862437513422674132464114553955020011613390223563921216330337191472179036736320851902737175793901848487718937910898018416161/933309120494589822270875761775558033007171578202238867493386604896627109181261618401105644621678856564891971145707387236745779691087966808409140999335116653199360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-207673649421240", + "sign_hi": "-207673649421240" + }, + { + "index": 2, + "k": "B", + "lo": "17", + "hi": "17", + "u": 201, + "sq": "42175251639049901710354524464084932005929589066496892078275744947770583804135175023223966161797862753991758243866511409818638065236628742213921909845222913581555999339264765731308468191130072963280585440581343998695091696113788174750868815232629108627242829246901760235367731443362971415000889325091881966580861006761557642196053449421338702816386144161216651359989763375791680188826304772871044342775119995702899414510280627231236240009/1045801921371015683643658610370802258976034133384526025277009108568059602828085831924059167527727752474043351040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "sign_lo": "-71709640", + "sign_hi": "-71709640" + } + ], + "total": "76691/121500" + } +] \ No newline at end of file diff --git a/docs/design.md b/docs/design.md index 1b4d1cd..ec20c2b 100644 --- a/docs/design.md +++ b/docs/design.md @@ -1,669 +1,89 @@ -# Sendov finite-range formalization — design notes +# Proof design -A standing record of what this project is, what is proved, what is open, and why the -architecture is what it is. Written to be read cold, including by a reviewer who has not -seen the code. Numbers here were measured on this project's actual shapes, not estimated; -several of them overturned a design that looked obviously right on paper. +The active endgame implements the rational-envelope/critical-point method of +Senjian An on top of the existing polynomial and analytic reduction.[1][2] +It is a replacement for the old scalar certificate route, not an extra premise +added to the final statements. -Machine: Windows 11, Lean 4.34.0-rc1, mathlib pinned in `lake-manifest.json`. Timings -include Lean startup (~1.5–2 s) unless stated otherwise. +## Reduction contract ---- +For interior degree `n ≥ 6`, put `m = M n = n - 1`. The theorem +`cubicScalar_constraints_of_polar_origin` derives all four facts from the +original geometric hypotheses: -## 1. The claim +1. `0 < α`; +2. `2 * α ≤ M n`; +3. `α ≤ 17`; +4. `1 ≤ scalarObstruction (M n) α (cubicPolarEnvelope α)`. -From the blog post [*A digestion of the proof of Sendov's conjecture*](https://terrytao.wordpress.com/2026/08/12/a-digestion-of-the-proof-of-sendovs-conjecture/). After the polynomial -argument, one inequality — equation `stat` — remains unproved on a finite range. Writing -`M = n-1`, `A = a² = 1 - 2α/M`, `c = 1 - α/M - α/(2(3+α))`, `Q(t) = 1 - 2ct + At²`, -`B = α/(3+α)`, the claim is that +The range and the scalar lower bound are conclusions, not inputs smuggled into +Sendov's conjecture. The original weak polar integral bound remains weak: +its left side is `1 ≤ I`, not an assumed stronger inequality. -``` -R n α = 1/6 + 1/(4(3+α)) + 1/(2M) + 1/(4M(3+α)) - + A² n M (n-2)/(4(3+α)) · ∫₀¹ t³ Q(t)^((n-4)/2) dt -``` - -satisfies `R n α < 1` on `5 ≤ n ≤ 97`, `0 ≤ α ≤ 17`, subject to the feasibility constraint -`c² ≤ A`. (`n ≥ 98` is handled by a separate analytic argument; see §6.) The exponent is a -*real* exponent — half-integral for odd `n` — so `Real.rpow` is involved. - -`Sendov/Defs.lean` fixes the notation; `Sendov/FiniteRange/Cover.lean` states the claim and -derives the `False` form in which it is applied. - -**Numerically**, `R` attains max `0.8529` at `n = 53, α = 17`. So a bound may lose ~15% and -still succeed — a fact that matters repeatedly below. - ---- - -## 2. Status - -| component | file | state | -|---|---|---| -| Definitions of `stat` | `Defs.lean` | definitions only | -| **The claim, degrees 5–100** | **`FiniteRange/Cover.lean`** | **proved** | -| Basic properties (shared A/B) | `Common/Basic.lean` | proved | -| Real powers, integrability (shared A/B) | `Common/Rpow.lean` | proved | -| Moment formula (M) | `FiniteRange/Moments.lean` | proved | -| Odd-degree bound | `FiniteRange/OddBound.lean` | proved | -| Per-degree reduction | `FiniteRange/Reduce.lean` | proved | -| Batching machinery | `FiniteRange/Batch.lean` | proved | -| Degrees 5, 6, 7, 8, 20 (single) | `FiniteRange/Degree*.lean` | proved, no `sorryAx` | -| 31 degree batches covering 6–100 | `FiniteRange/Degree{n₀}_{n₁}.lean` | proved | -| Moment recurrence | `FiniteRange/Recurrence.lean` | proved; too slow to use (§4) | -| Kronecker packing core | `FiniteRange/Pack.lean` | proved | -| Packing bridge | `FiniteRange/PackBridge.lean` | proved | -| Degree 20 via packing | `FiniteRange/Degree20Packed.lean` | proved, cross-checked | -| Degree 53 moment via packing | `FiniteRange/Degree53Packed.lean` | proved, 10 s | -| Degree 97 moments (k = 46, 47) | `FiniteRange/Degree97Packed.lean` | proved, 17 s | -| The quadratic `QQ c A t` (shared) | `Common/Quadratic.lean` | proved | -| Beta integrals and the split (shared) | `Common/Chord.lean` | proved | -| The sinh lemma (shared) | `Common/Sinh.lean` | proved | -| Tail bound `R ≤ U` (B2) | `LargeDegree/Tail.lean` | proved | -| Degree monotonicity of `U` (B3) | `LargeDegree/Monotone.lean` | proved | -| `Ut < 1`, degrees ≥ 101 (B4–B5) | `LargeDegree/Endgame.lean` | proved | -| **The claim, every degree** | **`Main.lean`** | **proved** | -| `(1Q) ⟹ (lt)` | `Reduction/Polar.lean` | proved | -| `(lt) ⟹ (beta-bound)` | `Reduction/BetaBound.lean` | proved | -| `(origin-exact) ⟹ (1le)` | `Reduction/Simplified.lean` | proved | -| `(1le)+(beta-bound) ⟹ stat` | `Reduction/Stat.lean` | proved | -| `⟹ α ≤ 17` | `Reduction/Alpha17.lean` | proved | -| **`(1Q)` and `(origin-exact)` incompatible** | **`Reduction/Main.lean`** | **proved** | -| Maclaurin's inequality (top case) | `Analytic/Maclaurin.lean` | proved | -| The defect lemma | `Analytic/Defect.lean` | proved | -| The two factorizations | `Counterexample/Factor.lean` | proved | -| The four identities (Lemma 1) | `Counterexample/Identities.lean` | proved | -| The polar branch point and `(1Q)` | `Analytic/Polar.lean` | proved | -| The error bound, `F'`, and `(tri)` | `Analytic/Origin.lean` | proved | -| The defect estimate for `J ∑ 1/zⱼ` | `Analytic/Jsum.lean` | proved | -| `(f1aq)`, `(grow)`, `(origin-exact)` | `Analytic/OriginExact.lean` | proved | -| Low degrees `2 ≤ n ≤ 5` (branch at `(⋆)`) | `Analytic/LowDegree.lean` | proved | -| The centre `a = 0` | `Interior.lean` | proved | -| **Conjecture `interior`, real `0 ≤ a < 1`** | **`Interior.lean`** | **proved** | -| **Rubinstein at `a = 1`, with equality case** | **`Boundary.lean`** | **proved** | -| Rotation normalization | `Conjecture.lean` | proved | -| **Sendov + Phelps–Rodriguez, full** | **`Conjecture.lean`** | **proved** | -| Certificate generators | `scripts/*.py` | untrusted, self-checking | -| Trust audit | `scripts/audit.sh` | passes | -| Mutation test | `scripts/mutation_test.sh` | passes | - -Degree 20 has been reproduced through the packed path and cross-checked against the -multinomial route (`packed_agrees_twenty`), so the bridge is validated end to end. - -**The claim is proved.** `Sendov.stat_lt_one` gives `R n α < 1` for **every** `n ≥ 5` and -`0 ≤ α ≤ 17` under feasibility, so `Sendov.stat_contradiction` shows equation `stat` of the -blog post is unsatisfiable outright — there is no longer any range left open. `scripts/audit.sh` -reports no forbidden tokens and - -``` -'Sendov.stat_lt_one' depends on axioms: [propext, Classical.choice, Quot.sound] -``` - -**The A track.** `Sendov.finite_range_le_100` proves `R n α < 1` for every -`5 ≤ n ≤ 100`, `0 ≤ α ≤ 17` under feasibility, and `Sendov.finite_range` is the original -`n ≤ 97` challenge statement as a special case. Coverage is not asserted anywhere: the case -split in `Cover.lean` is generated from the batch plan and would not compile if a degree were -skipped. Three degrees beyond the original `97` were certified so that the finite range -meets the large-degree argument with room to spare (`U` has margin `0.122` at `n = 101` -against `0.048` at `n = 98`). - -The seam is at `100/101`, not the blog post's `97/98`. +`distillScalar_lt_one` proves a strict upper bound on exactly this domain. +`polar_origin_incompatible` combines the lower and upper bounds. The interior +proof covers degrees two through five with the already-proved elementary +integral argument; the unit-circle case and its equality classification stay +in the separate boundary proof. -The hypotheses are all derivable by arithmetic rather than by computing `qrow`: coefficient -size from `l1row_qrow`, entry length from `qrow_entry_length_le` (an entry of the `k`-th row -has length at most `1 + G*k`), row length from `qrow_length`, and packed magnitude from -`abs_pevZ_le`; `rowZ_bound` and `wsum_bound` package these as numeric inequalities. -`Degree53Packed.lean` uses them and builds in **10 s** at `k = 24`, so the route is validated -at the numerically worst degree. (`Degree20Packed.lean` still uses `decide`, which is -affordable at `k = 8` and exercises the same statements.) +## Scalar upper bound -Parameters from the *provable* bounds, and the measured cost: - -| n | k | β | τ | `G^k` | build | -|---|---|---|---|---|---| -| 20 | 8 | 104 b | 1,735 b | 0.003 MB | 11 s | -| 53 | 24 | 327 b | 24,098 b | 1.17 Mb | 10 s | -| 97 | 46 | 659 b | 92,038 b | 8.53 Mb | — | -| 97 | 47 | 677 b | 96,593 b | 9.14 Mb | 17 s (both) | - -`k = 47` is the largest exponent anywhere in `5 ≤ n ≤ 97`, so this is the worst case and it -costs seconds. - -### Batching adjacent degrees - -Every term of `R n α` is monotone in `n`: `base_n` decreases, the prefactor -`A_n² n (n-1) (n-2) / (4(3+α))` increases, and `I_n` decreases (since `Q_{n+1} ≤ Q_n`, and -the exponent grows while `Q ≤ 1`). So for a batch `[n₀, n₁]`, +The two-chord integral theorem gives +```text +raw cubic scalar obstruction ≤ E_budget(m) + T0(m,α) + T1(m,α) + T2(m,α). ``` -R n α ≤ base_{n₀}(α) + pref_{n₁}(α) · I_{n₀}(α) for every n in the batch, -``` - -one moment and one certificate for the whole batch. Taking `n₀` even makes `I_{n₀}` an exact -integer moment. Crucially the certificate's degree is set by `n₀`, the *smallest* member, so -a batch is not merely fewer certificates but cheaper ones. - -Measured, with certificate cost interpolated from (deg 18, 12 s), (deg 52, 99 s), -(deg 96, 129 s): - -| range | individually | batched | saving | -|---|---|---|---| -| `n ∈ [6,40]` | 14.2 min | 3.5 min | 4× | -| `n ∈ [42,60]` | 28.3 min | 10.2 min | 2.8× | -| `n ∈ [62,97]` | 69.8 min | 5.6 min | **12.5×** | -| total | 115 min | 21 min | 5.5× | - -Batch sizes track the slack: 2–3 through the tight middle around the `n = 53` peak, rising to -12 and 16 at the top. The high degrees — 61% of the cost when done individually — batch best -precisely because `R n α` falls away from the peak, so they drop to 22% of the batched total. -21–26 batches cover `6 ≤ n ≤ 97` depending on how much margin is left. - -Batches cannot be made arbitrarily large: the bound degrades as `pref_{n₁}/pref_{n₀}` grows -like `(n₁/n₀)³`, which the shrinking moment does not offset. Ending at 97, the bound is -`0.66` for `[82,97]`, `0.91` for `[78,97]`, `1.95` for `[70,97]` and `4.78` for `[62,97]`. -So about 20 degrees is the ceiling at the top of the range; `[78,97]` is the largest batch -admitting a certificate, at degree 76. - -**The plan must be driven by certificate feasibility, not by the numeric bound.** These do -not track each other: `[34,36]` at bound `0.9348` admits no single all-positive Bernstein -certificate, while `[52,53]` at `0.9475` does. So the generator should attempt a batch, -check the certificate, and shrink on failure — subdivision in `n`, which does pay, rather -than in `α`, which was shown unnecessary. `scripts/plan_batches.py` does the search. - -### Can degrees sharing a `k` share work? - -Each `k` serves up to three degrees: `n = 2k+3` (as its upper index), `n = 2k+4` (even), and -`n = 2k+5` (as its lower index). But the split is unfavourable: - -* `k` only, shareable: `L = lcm(4 .. 2k+4)`, `mlen = 1 + 3k`, the divisibility obligation; -* `n` only: `L1 = 30(n-1) - 16`; -* **both**: `β`, `τ`, `Nmom`, and the row itself, since `g₀,g₁,g₂` depend on `n`. - -The row is the expensive object, so three degrees sharing a `k` still need three separate -exponentiations. Measured at `k = 47`: the packed check alone is essentially the entire -per-moment cost, the shared items together being a 136-bit numeral and a divisibility fact. -Factoring them out would save under a second per degree, so it is not worth a separate -`k`-indexed module. - -(Treating `M = n-1` as a third Kronecker variable *would* let one computation serve all -degrees, but the row acquires an `M`-degree of `k`, making the packed object roughly `k` -times larger — about 430 Mbit at `k = 47`. That trades a factor of `93/k ≈ 2` at best for a -much larger object, and loses outright at small `k`.) `τ` exceeds the earlier estimate because the provable entry-length bound is -`1 + 3k` rather than the true `2k+1`; the multipliers have degree ≤ 2, so a sharper induction -would recover it, but the cost is a bigger `τ`, not a slower build. - ---- - -## 3. The reduction chain - -Each degree reduces to polynomial positivity in `α` alone: - -1. **`R_le_of_integral_le`** — the coefficient of the integral in `R` is nonnegative, so any - upper bound `J` for the integral bounds `R`. -2. **Even `n`** — `integral_eq_mom`: the integral *equals* the moment `mom n α k`, `k=(n-4)/2`. - No hypotheses at all; it is a polynomial identity. - **Odd `n`** — `integral_rpow_le`: `√q ≤ q/(2w) + w/2` (the tangent to `√·` at `q = w²`) - turns `Q^(k+1/2)` into a combination of `mom n α k` and `mom n α (k+1)`, for any `w > 0`. -3. **`alpha_le_half_M`** — feasibility gives `α ≤ (n-1)/2`, the only numerical input needed. -4. Clear denominators: `1 - R n α = P n (α) / D n (α)` with `D > 0`, `deg P = n - 2`. -5. **Bernstein certificate** — `U^d · P(α) = Σⱼ Γⱼ αʲ (U-α)^(d-j)` with all `Γⱼ > 0`, whence - `P > 0` on `[0, U]`. - -### Simplifications found along the way - -- **The tangent parameter `w` unifies degree 5.** The plan gave `n = 5` its own apparatus - (chord bound, `H(B)` in half-integer powers of `B`, the substitution `α = 3r²/(1-r²)`) - because bound (O) is too wasteful there. True — (O) gives `1.0625` at `α = 0`, proving - nothing — but the cause is narrow: (O) is the tangent taken at `q = 1`, and in degree 5 the - relevant `Q` values are small. Taking `w = 1/3` instead gives `0.737` against the exact - `0.716`. All odd degrees now share one code path and no square roots survive. -- **No subdivision.** One Bernstein certificate on the whole interval has all coefficients - positive at every degree tested (20, 53, 97). The plan's adaptive bisection is unnecessary. -- **No infeasibility branch.** Only the numerical step needs feasibility, and only as - `α ≤ (n-1)/2`. The exact feasible region (cut out by a quartic) is never required. This is - *not* the claim that `A ≥ 0` replaces feasibility: the odd-degree bound needs `0 ≤ Q` on - `[0,1]`, which is `Q_nonneg` and uses the full `c² ≤ A`. -- **Beta, not Gamma.** For `n ≥ 98` the write-up bounds the tail by `Q ≤ exp(-ct)` and the - Gamma integral. Keeping the chord as a *power* instead gives - `∫₀¹ t³(1-t)ˢ dt = 6/((s+1)(s+2)(s+3)(s+4))` — no improper integral, no `Real.exp`, and - strictly sharper, so every constant downstream survives unchanged. - ---- - -## 4. Computing the moment: representation, not algorithm - -`∫₀¹ t³ Qᵏ dt` is the bottleneck. The multinomial formula (M) has `Θ(k²)` terms and its -`simp` expansion dies around `k = 20` — at `n = 53` the 676-term expansion exhausts 2 M -heartbeats. `Recurrence.lean` replaces it with the coefficient recurrence -`R(k+1,j) = g₀R(k,j) + g₁R(k,j-1) + g₂R(k,j-2)`, where `D·Q = g₀ + g₁t + g₂t²` with -`D = 2(n-1)(3+α)` and the `gᵢ` integer polynomials in `α`. That is correct but still slow: - -| representation | k=24 | k=32 | k=46 | -|---|---|---|---| -| `List (List ℤ)` (`Recurrence.lean`) | 120 s | >20 min | hours | -| 1-D packed, `List ℤ` | — | — | 158 s | -| 2-D packed, single `Nat` (`Pack.lean`) | — | — | ~0.5 s | - -Kernel `Nat` arithmetic is GMP-backed — a 4000-digit multiplication and a 50th power are -milliseconds — while list recursion is interpreted at roughly 240 µs per coefficient -operation. `qrow` was never the wrong *algorithm*; it was the wrong *representation*. Under -Kronecker packing (evaluate at a base exceeding every coefficient) polynomial multiplication -becomes `Nat` multiplication and the whole recurrence becomes `base ^ k`, one exponentiation. - -Measured end to end through the verified `unpackN`: one exponentiation to a 3,042,311-bit -number plus extraction of all 93 coefficients, **7 s**. - -### Numerical parameters - -Two bases are needed per degree: `β` packs a coefficient polynomial in `α`, `τ` packs the -resulting row in `t`. With `L1 = 30(n-1) - 16` (the sum of `|coefficients|` of `g₀,g₁,g₂`, -which bounds every coefficient of the `k`-th power) and `L = lcm(4 .. 2k+4)` (clearing the -`1/(j+4)` weights): - -``` -β > 2 · (2k+1) · (L/4) · L1^k -- fits the moment numerator's coefficients -τ > 2 · L1^k · (β^(2k+1) - 1)/(β-1) -- fits the α-packed row entries -``` - -| n | k | L1 | L | β | τ | `G^k` | -|---|---|---|---|---|---|---| -| 20 | 8 | 554 | 28 b | 104 b | 1,735 b | 0.003 MB | -| 53 | 24 | 1544 | 72 b | 331 b | 16,107 b | 0.09 MB | -| 97 | 47 | 2864 | 136 b | 681 b | 64,554 b | 0.72 MB | - -Verified at `n = 53` with the real `g` coefficients: the `τ` bound holds, and the kernel -computes `G^24` (788,991 bits) and extracts all 49 α-packed row entries in **9 s** including -Lean startup. - -### The packing bound is essentially free - -`unpackN_pow` requires `(npev p 1)ᵏ < b`, the sum of coefficients to the `k`-th power. -Against the true maximum coefficient: - -| n | k | true max | bound `L1ᵏ` | slack | packed size | -|---|---|---|---|---|---| -| 53 | 24 | 249 b | 255 b | 6 b | 0.07 MB | -| 97 | 46 | 522 b | 529 b | 7 b | 0.54 MB | - -5–7 bits, under 1.5% of block size. Take `B = bitlength(L1ᵏ) + 1` with `L1 = 30(n-1) - 16`; -no per-degree tuning, packed objects under 0.6 MB. - ---- - -## 5. `ring` costs, and the build budget - -| task | time | peak memory | -|---|---|---| -| Bernstein identity, degree 18 (n=20) | ~12 s | small | -| Bernstein identity, degree 52 (n=53) | ~99 s | — | -| Bernstein identity, degree 96 (n=97) | 129 s | ~4 GB | -| 8-chord moment identity, degree 48 (n=53) | never finished | >10 GB, killed | - -`ring` handles the Bernstein identity at every degree needed, so the certificate layer needs -no packing. Two consequences: roughly **3 hours** for 93 degrees, and **4 GB peaks**, so -high-degree files must not compile in parallel. - -The last row is why the moment is not expanded symbolically: Bernstein terms are -`Γⱼ αʲ (U-α)^(d-j)`, one binomial expansion each, whereas chord terms are products of two -different high-degree powers. Same degree, entirely different cost. - ---- - -## 6. Approaches measured and rejected - -- **Interval arithmetic in `α`.** Needs ~200 α-boxes at `n = 53` (`p=8,N=60` still gives - 1.0999); the `m`-th power amplifies interval loss. -- **Extending the analytic `n ≥ 98` argument downward.** Its bound bottoms out at exactly - `n = 98`; the Beta improvement lowers `U₅₄` from 2.10 to 1.88, nowhere near 1. -- **Monotonicity `R_{n+2} ≤ R_n`.** True — verified over `53 ≤ n ≤ 95`, and `R_{n+1} ≤ R_n` - too — but the minimum relative margin is **1.48%** at `(53, 17)`, while proving `R_n < 1` - directly allows ~15%. Monotonicity demands ten times the sharpness of the actual goal, and - a chord-based sufficient condition loses 10%. Rejected on those grounds, not on difficulty. -- **Endpoint-power chord integrals.** ~8× algorithmically, but introduces `v⁴` denominators, - `v = 0` case splits *inside* the feasible region, and raises `deg P` from ~96 to ~164. - Superseded by packing, which is faster and touches nothing. - ---- - -## 6b. Next target: `{1Q}` and `{origin-exact}` are incompatible - -*Done.* `Sendov.polar_origin_incompatible` proves that **`{1Q}` and `{origin-exact}` are not -simultaneously satisfiable for `n ≥ 5`** — a statement with no complex numbers and no -polynomials in it, in the real variables `a ∈ (0,1)` and `x ∈ [-1,1]` alone. Everything the -blog post leaves to computation is now formalized; what remains outside Lean is the -complex-analytic derivation of the two raw inequalities themselves. - -The chain, all links checked numerically and symbolically before any Lean was written: - -| link | status | -|---|---| -| `{1Q} ⟹ {lt}` | **proved**, `Sendov.polar_exp`. The pointwise bound `(at)` is an *identity* up to `t² ≤ t`: rhs − lhs = `(2α/(n−1))²(t−t²)` | -| `{lt} ⟹ {beta-bound}` | **proved**, `Sendov.beta_le` | -| `{beta-bound}+{origin-exact} ⟹ {17}` | **proved**, `Sendov.alpha_le_seventeen` | -| `{origin-exact} ⟹ {1le}` | **proved**, `Sendov.one_le_of_origin` | -| `{1le}+{beta-bound} ⟹ {stat}` | **proved**, `Sendov.stat_of_one_le` | - -Four deliberate deviations from the write-up: - -* **`{17}` uses the Beta identity, not `∫₀^∞ t e^{-ct} dt`.** The chord bound `β(t) ≤ 1-axt` - plus `∫₀^{1/c} t(1-ct)^s dt = 1/(c²(s+1)(s+2))` reuses `LargeDegree` machinery, avoids an - improper integral, and improves the margin from `1.948` to `1.817`. -* **Everything is non-strict.** `{beta-bound}` is stated with `<`, but every downstream use - needs only `≤`, so no strict integral monotonicity is required anywhere. This removes the - need to argue that the integrand of `(lt)` is strictly smaller on a set of positive measure. -* **The mean value theorem is replaced by Bernoulli.** The write-up bounds - `((1-axt)² + s)^{(n-2)/2}` by the MVT. Dividing `(P+Q)^p ≤ P^p + pQ(P+Q)^{p-1}` through by - `(P+Q)^p` turns it into `1 ≤ θ^p + p(1-θ)` at `θ = P/(P+Q)`, which is Mathlib's - `one_add_mul_self_le_rpow_one_add` verbatim — no derivative, no differentiability side - conditions. -* **The `sinh` lemma is proved differently** — see below. - -### The `sinh` lemma (`Common/Sinh.lean`), *done* - -`log(sinh h/h) ≤ √(h²+9) - 3` is the crux: it is what produces the constant `3` in -`β(1) ≤ α/(3+α)`, and it is sharp — at `β = α/(3+α)` the slack in the integral inequality is -`-α⁵/540 + α⁶/648`, so the bound is tight to *three* orders at `α = 0` and no lossy step is -available. The write-up proves it from the Taylor expansion -`Σ_{k≥4} 2^{2k-3}(2k-1)(2k-6)²/(2k)! h^{2k}` (coefficients confirmed). - -Formalizing a series with nonnegative coefficients is unpleasant. Instead, with -`Φ(y) = e^{2y}(y³-10y²+36y-36) - e^y(y⁴+16y²-72) - (y³+10y²+36y+36)`: - -* `Φ(2h) = 16 e^{2h} G(h)`, `G(h) = h⁴sinh²h - (h²+9)(h cosh h - sinh h)²` — algebra only; -* the family `e^{2y}u - e^y v - w` (`u`, `w` cubic, `v` quartic) is **closed under - differentiation**, via `u ↦ 2u+u'`, `v ↦ v+v'`, `w ↦ w'`, so one `HasDerivAt` lemma with 13 - parameters covers all eight steps; -* `Φ⁽ʲ⁾(0) = 0` for `j ≤ 7`, and - `Φ⁽⁸⁾(y) = 256e^{2y}(y³+2y²-2y+10) - e^y(y⁴+32y³+352y²+1600y+2504)`; -* dividing `Φ⁽⁸⁾` by `e^y` and using **three** terms `e^y ≥ 1+y+y²/2` leaves - `128y⁵+511y⁴+480y³+928y²+448y+56`, every coefficient positive. - -So: no certificate, no series manipulation, one `ring` identity and eight applications of -"vanishes at `0`, has nonnegative derivative". The only analysis left is the limit -`sinh h/h → 1` at `0⁺`, which is just the derivative of `sinh` at `0` read through -`hasDerivAt_iff_tendsto_slope`. - ---- - -## 6c. Conjecture `interior`: the complex-analytic half - -The remaining target is Sendov's conjecture in the interior itself, for `n ≥ 5`: a counterexample -gives the four identities of the blog post's Lemma 1, those give `(1Q)` and `(origin-exact)`, and -`Sendov.polar_origin_incompatible` closes it. The blog signposts the split — *"the polynomial `p` -will play no further role"* — so the interface between the two stages is a structure carrying the -identities and the disk hypotheses, and nothing else. - -**Multisets throughout.** Roots arrive from Mathlib as a `Multiset`, repeated roots must be -allowed, and the alternative — indexing by `Fin (n-1)` — pays a bookkeeping tax at every step. -This decision already paid off twice; see below. - -### Constraints from the later stages - -Two plans for later stages (`n ≤ 4`, and the boundary case `a = 1`) constrain how this stage -should be built, and both were read before any of it was written: - -* The low-degree argument for `2 ≤ n ≤ 5` branches off **immediately after the exact polar - identity**, using only the Möbius bound and the integral triangle inequality — not the - `x`-relaxation. So the polar channel must expose - - `1 ≤ ∫₀¹ ∏ⱼ |a + t(1-a²)qⱼ| dt` - - as a named intermediate: high degree relaxes it by AM–GM to `(1Q)`, low degree bounds each - factor by `a + (1-a²)t`. Do not fuse those steps. -* The boundary case must **not** be forced into a structure carrying `a < 1`, and does not use - the polar identity at all (it degenerates at `a = 1`). So the factorization layer — roots, - critical points, `|zⱼ| ≤ 1`, `|1 - wⱼ| ≥ 1`, the two factorizations — must be - hypothesis-light, with `a < 1` and `a ≠ 0` entering only above it. - -Also worth knowing: the low-degree argument covers `2 ≤ n ≤ 5`, so degree 5 could eventually be -dropped from the finite-certificate machinery. - -### Two informal proofs that got shorter - -Both prerequisites turned out to need far less than the write-up suggests, and in both cases -because the multiset formulation made the right induction available. - -* **Maclaurin's inequality** (`e_{N-1} ≤ N μ^{N-1}`) normally comes from Newton's inequalities, - which need real-rootedness of derivatives via Rolle. The top case does not: splitting off one - element and applying the inductive hypothesis and AM–GM leaves `1 + N(w-1) ≤ wᴺ`, which is - Bernoulli. AM–GM for multisets is proved the same way rather than imported — Mathlib states it - for `Finset`-indexed families — and its step is Bernoulli at exponent `N+1`, so the two proofs - share their only ingredient and the file imports no AM–GM at all. -* **The defect lemma** is proved in the write-up by setting `‖wⱼ‖ = e^{-aⱼ}`, computing - `‖wⱼ⁻¹ - conj wⱼ‖ = 2 sinh aⱼ` and using superadditivity of `sinh`. Splitting off one point - instead leaves `1 - r²P² - [P(1-r²) + r(1-P²)] = (1-r)(1-P)(1-rP) ≥ 0`. No `sinh`, no - logarithms. The origin `wⱼ = 0`, which the informal proof reaches by a limiting argument, needs - no separate treatment: the pointwise fact `‖w‖·‖w⁻¹ - conj w‖ ≤ 1 - ‖w‖²` is true there as an - inequality, because the left side carries a factor `‖w‖` that kills Lean's junk `0⁻¹`. - -Neither statement mentions anything Sendov-specific; both are candidates for upstreaming. - ---- - -## 7. Open work - -Items 1–4 (packing bridge, degrees 9–100, composition, the analytic `n ≥ 101` argument) are -all **done**; see §2. What remains is assurance work, not mathematics: - -1. **Mutation test** — *done*, `scripts/mutation_test.sh`. Five load-bearing data are each - corrupted in turn (a Bernstein identity coefficient, a coefficient of the certified - polynomial, a moment datum, the endgame constant, a monotonicity coefficient) and every one - breaks the build. See §7b for what the first run got wrong. -2. **Clean rebuild** from the pinned toolchain in a fresh clone. -3. **Line-length and style lint** across the generated files (currently the generators emit - some lines past 100 characters). - -### The large-degree argument as actually taken - -The informal write-up's §4–§7 were followed in outline but not in detail, because using the -*sharp* Beta constant `6/((r+1)(r+2)(r+3)(r+4))` instead of `6/r⁴` changes what has to be -proved — and makes almost all of it easier. - -* With `r = (n-4)/2` the product is `(n-2) n (n+2)(n+4)/16`, and the `n(n-2)` cancels the - `n(n-2)` in the prefactor of `R` **exactly**. The first tail term collapses to the rational - function `24 (n-1-2α)²/((3+α) c⁴ (n-1)(n+2)(n+4))`. The write-up's degree-8 positivity - certificate `(18)` is for the `6/r⁴` version and is not needed. -* The write-up's `(16)` claims the first tail term decreases outright. It does not: at - `α = 17` the factor `(n-1-2α)²/((n-1)(n+2)(n+4))` *increases* up to `n ≈ 108`, by 0.37%. - It is `c⁴` in the denominator that pays for this — `c` rises from `0.405` to `0.416` over - the same span, an 11% gain. Rather than couple the two, a flat 1% allowance is taken and - discharged by its own certificate (`tail1_poly`); the 1% costs `0.0018` of margin. -* The `√B` in the geometric step is replaced by the rational bound `√B ≤ 12/13` - (since `B ≤ 17/20 ≤ (12/13)²`), which keeps the step ratio rational: `0.961 < 1`. Writing - `B^((n-4)/2)` as `(√B)^(n-4)`, a *natural* power, turns §4 into an ordinary induction on `n` - with no `rpow` reasoning at all. -* §7's split of `[0,17]` at `α = 16` is unnecessary. Clearing denominators by - `865200 (3+α)^49 γ⁴`, `γ = 300 + 47α - α²`, makes the whole of `Ut α < 1` a single - degree-58 polynomial positivity, and its Bernstein certificate on `[0,17]` has **all 59 - coefficients positive**. One `ring` call and one case split. - -Margins on the final bound: `Ut(0) = 0.3305`, `Ut(8) = 0.3456`, `Ut(16) = 0.7598`, -`Ut(17) = 0.9229`. The peak is at the endpoint `α = 17`, with 7.7% of room — against the -0.15% the write-up's route leaves at the same point. - ---- - -## 7a. What the two workstreams share - -The finite range (A) and the large-degree argument (B) are independent strategies but rest on -the same foundation, now collected under `Sendov/Common/`: - -* `Common/Basic.lean` — `Q_eq` (the sum-of-squares form) and `Q_nonneg` are exactly `(5)` of - the large-degree write-up; `Q_one` is its `(6)`; and `R_le_of_integral_le` is the shape of - *both* arguments, since each proceeds by bounding the integral and then bounding `R`. -* `Common/Rpow.lean` — `continuous_integrand` is used by A to compare integrals and is what B - needs to split `∫₀¹` at the vertex of `Q`; `rpow_add_nat_pos` serves the Beta integral and - the `B^((n-4)/2) = B^k √B` reduction alike; `rpow_le_rpow_of_le_one` drops the `√B`. - -Before this was factored out, `LargeDegree/Beta.lean` imported `FiniteRange/Basic.lean` — -B depending on A, which is backwards. Both now depend only on `Common`. - ---- - -## 7b. Gotchas - -Bugs met while building this, all of which produced *plausible-looking* wrong output. They -are recorded because each cost real time and several would have silently corrupted a -certificate. - -* **Python integer division in a symbolic expression.** `1/(2*M0)` with `M0` a plain Python - `int` is float division; sympy then carries floats through the whole computation. Worse, - `sp.Integer(x)` *truncates* a float without complaint, so the corrupted coefficients looked - like clean integers and the Bernstein check still reported "all positive". Caught only by - asserting that the denominator had the expected form `C·(3+α)^p`. Use `sp.Rational(1, 2*M0)` - and assert `c.is_Rational` on every coefficient. - -* **A dropped factor of `2ˡ`.** In `(-2c)ˡ` the `2ˡ` cancels against the denominator of `c`, - so the denominator is `Mⁱ`, not `(2M)ˡ M^(i-l)`. The resulting `P` was wrong by sign and - scale yet still admitted a Bernstein representation — with every coefficient negative. - **Positivity of a certificate is not evidence that `P` is right.** - -* **`sympy.simplify` returning a false mismatch.** Comparing two large rational expressions, - `simplify(lhs - rhs) == 0` reported `False` when they were in fact equal; it had simply - failed to reduce. A symbolic "not equal" from a CAS is weak evidence. Numerical agreement - at several points, or exact evaluation at several rational points, is strong. - -* **`sympy.nsimplify` on an exact rational.** Applied to a `Rational` it "simplified" it into - radicals — `32768·2^(29/52)·3^(6/13)·…` — producing unparseable Lean. Use `.p` and `.q`. - -* **Comparing two routes with different denominators.** The packed and multinomial routes - carry different powers of `(3+α)`, so their numerators differ by a factor of `(3+α)`, not by - a constant. A "compare up to scale" check fails spuriously. - -* **Shell and encoding.** Backticks inside a docstring passed through `python -c "..."` are - substituted by bash, mangling generated Lean. Python on Windows writes CRLF unless - `newline=" -"` is given, and Lean rejects isolated carriage returns. `/tmp` in Git Bash is - not `/tmp` to Windows Python. - -* **A certificate interval that the hypotheses do not justify.** The batch generator fixed - the Bernstein interval at `[0,17]`, but feasibility only gives `α ≤ (n-1)/2`, which is - `2.5` for the `[6,6]` batch and `8.5` for `[16,18]`. On `[0,17]` the polynomial genuinely - is not positive there (`A₆(17) = -5.8`), so the low batches failed — correctly. The - interval must be `min(17, (n₁-1)/2)`, and the batch theorem must *derive* `α ≤ U` from - `alpha_le_half_M` rather than from the ambient `α ≤ 17`. Nothing unsound resulted, but the - failure looked like a certificate-quality problem when it was a hypothesis-scope problem. - -* **A hypothesis that propagates the wrong way.** The batch bound was originally stated with - feasibility `c² ≤ A` required *at `n₀`*. Feasibility propagates *upward* in `n` (since `A` - increases), so it cannot be inherited from the hypothesis at `n`, and for `n₀ ≲ 36` it does - not follow from `α ≤ 17` either. The fix was to weaken what is actually needed: `Q ≤ 1` - only requires `0 ≤ c`, because `Q t - 1 = t(A t - 2c)` and `Q 1 = B < 1` already gives - `A ≤ 2c`, whether or not `A ≥ 0`. Nonnegativity of `Q` at `n₀` then comes free from - `Q_anti`. Worth generalising a lemma before generating thirty files that need it. - -* **Memory, not time, is the build limit.** Rebuilding all 31 batch files simultaneously - makes Lean exit with `0xC0000409` and spurious `failed to read file ...olean` errors — an - out-of-memory failure that reads like corruption. Each file builds fine alone. Lake in - this toolchain has no `--jobs` flag, so the workaround is to build in explicit groups - (`scripts/staged_build.sh`). Note any edit to `Defs.lean`, even to a docstring, - invalidates every one of them. - -* **Backslashes vanishing between the shell and Python.** Passing a Python patch script - through a heredoc silently collapsed `\\n` to `\n`, so string replacements aimed at - generator source either failed to match or wrote a literal newline into a string literal. - The generated Lean then still compiled, with the wrong linear form in a certificate. - Write patch scripts to a file rather than piping them through a shell. - -* **Half of a generated certificate is inert.** Each Bernstein coefficient `Gⱼ` appears twice: - in `have hⱼ : 0 ≤ Gⱼ αʲ (U-α)^(d-j)` and in the identity `hid`. Corrupting the *first* is - undetectable — `linarith` uses those hypotheses only as "this quantity is nonnegative", and - a positive rescaling of a nonnegative quantity is still nonnegative. The first mutation - test run reported two certificates as "not load-bearing" for exactly this reason; the - content is all in `hid`. (Module docstrings quoting a coefficient add a third occurrence, - which is inert for the same trivial reason.) `scripts/mutation_test.sh` therefore names the - occurrence index, and a reviewer reading a generated file should know that the `have` block - is bookkeeping, not evidence. - -* **`field_simp` distributes across an integral.** In `Reduction/Simplified.lean` the goal - contained `∫₀¹ t³ β(t)^r dt` as an opaque atom multiplied by a rational coefficient. - `field_simp` cleared denominators *through* the atom, producing a goal `ring` could not - close and a several-hundred-character error that reads like a mismatch. The fix is to - prove the scalar identity separately and finish with a division-free `ring`, so the atom is - only ever multiplied, never distributed over. The same reflex applies to - `LargeDegree/Endgame.lean`, where `field_simp` on `D(1 - Ut)` produced a degree-115 identity - in place of the degree-58 one that was wanted. - -* **A true rewrite that breaks a later match.** `ax = 1 - β(1)/2 - α/(n-1)` is an identity, - but `rw`-ing it into the origin inequality also rewrites the `a * x` *inside* - `∫₀¹ t β(t)^r dt`. The integral is then a different atom from the one in the bound being - combined with it, and `linarith` fails with no indication why. Passing the identity to - `linarith` as a hypothesis instead leaves the integral opaque. General rule: when an - integral is being treated as an atom, rewrite *around* it, never *into* it. - -* **A section `variable` can shadow a global definition.** `variable {c A t : ℝ}` in - `Common/Quadratic.lean` shadows `Sendov.c` and `Sendov.A`, so `Q n α t = QQ (c n α) (A n α) t` - stops parsing — and reports "Function expected", not a name clash. Any lemma mentioning the - globals has to come before the `variable` line. -* **`norm_num` normalises a fraction out of matchable shape.** `1/(c²((r+1)(r+2)))` becomes - `(r+2)⁻¹(r+1)⁻¹(c²)⁻¹`, which no longer matches the lemma statement it came from. Rewriting - only the specific cast that needs it (`show ((1:ℕ):ℝ) + 1 = 2`) is stable where - `norm_num at h` is not. +For `5 ≤ m ≤ 81`, fixed rational budgets and critical brackets are checked for +every integer parameter. The complete critical expressions are tied to the +actual derivatives of `T0`, `T1`, and `T2`. Their polynomial signs are certified +on entire outer intervals, while the middle interval uses monotone factors at +opposite endpoints. This establishes the bound without trusting a sampled +maximum or requiring a separate root-isolation oracle. -* **`hasDerivAt_id` produces `id`, not `fun x => x`.** `simpa` then normalises the goal into - point-free form (`(fun x ↦ exp x - 1) - id - …`) and fails to match. `hasDerivAt_id'` - together with `HasDerivAt.congr_deriv` is the robust idiom; probe it in a scratch file - before generating 250 lines against it. +The coefficient-list frontend constructs the existing Bernstein addition tree. +Scale positivity, interval membership, both endpoint supports and the complete +polynomial equality remain explicit Lean obligations. The Python coefficient +calculation is not in the trusted base. -* **The editor competes with the build for memory.** Beyond the batch-file case above: with - `Common/Sinh.lean` open, the Lean LSP held 7.4 GB of 32 GB — it re-elaborates eight - 13-parameter `HasDerivAt` steps on every keystroke — and `lake build` began failing - intermittently with `failed to read …olean.private` on *toolchain* files. Same OOM, but it - looks like a corrupted install. A retry loop gets through it; restarting the Lean server - fixes it properly. +For all real `m ≥ 81`, proved parameter antitonicity reduces the four-component +bound to the actual finite `m=81` certificate. `DistillationTailBound` discharges +that base; it is not left as a hypothesis of the final upper bound. -* **`set` introduces a local *definition*, which `linarith` unfolds.** After - `set v := M n / (2*α) - 1`, goals that were linear in `v` became nonlinear in `α`, because - `linarith`'s preprocessing zeta-reduces the binding. `obtain ⟨v, hvdef⟩ : ∃ w, w = … := - ⟨_, rfl⟩` gives an opaque local instead. The same binding also makes `rw … at h` appear to - do nothing, since the term refolds. +## Endpoints and definitions -* **`linarith` does not always evaluate `OfScientific` literals.** `α / 2.7 ≤ 0.1852 * (2*α)` - is linear in `α` with rational coefficients, but `linarith` failed on it; splitting out the - numeric step with an explicit `div_le_iff₀` and letting `norm_num` see `2.7` on its own - worked. Decimal literals are fine inside `nlinarith` hint terms and in `norm_num` goals — - it is the coefficient extraction that is fragile. +The regularized components are continuous at `α=0` and their closed-interval +certificates include that endpoint. The raw scalar definition is **not** silently +replaced by a continuous extension there. The geometric reduction supplies +`α>0` where the raw scalar comparison is used. -* **`rw` with a factorization loops against the thing being factored.** `p = C p.leadingCoeff * - (p.roots.map …).prod` cannot simply be rewritten into a goal that still mentions `p.roots` or - `p.leadingCoeff` — the rewrite hits its own right-hand side. Extracting the multiset first - with `obtain ⟨z, hz⟩ : ∃ z, p.roots = a ::ₘ z := ⟨_, rfl⟩` gives an *opaque* local, after which - the rewrite is one-directional and terminates. `set` does not work here: it introduces a local - definition that tactics unfold again — the same trap as in `Reduction/Alpha17.lean`, where it - made `linarith` goals nonlinear. `obtain … := ⟨_, rfl⟩` is the idiom in both cases. +The old specialized `c`, `Q`, `R` definitions and their moment/packed/batch +certificates are absent from the active source. `M`, `A`, `QQ`, the actual +coordinate identity `mul_eq_c`, the linear and cubic integral lemmas and the +global weak hyperbolic estimate remain because real consumers still need them. +A name containing `c` or a file containing `Tail` is not, by itself, a reason +to delete useful mathematics. -* **Truncated `ℕ` subtraction inside an exponent.** Stating the derivative evaluation as - `(-1)^(card z - 1) * sumEraseProd z` is *wrong* at `card z = 1` and forces a case split at - `z = 0`, because `card z - 1` truncates. Writing it as `-((-1)^(card z) * sumEraseProd z)` — - equal, since `((-1)^k)² = 1` — removes both, and the induction step closes by `ring`. +## Verification boundary -* **`convert` manufacturing instance goals that `exact` does not.** Composing `HasDerivAt` - across `ℝ → ℂ → ℂ` with `HasDerivAt.scomp` produces a derivative `f' • g'` and an - `AddCommGroup ℂ` instance that is not syntactically the ambient one. `convert … using 1` - leaves both as goals; plain `exact` succeeds, because scalar multiplication of `ℂ` on `ℂ` - *is* multiplication definitionally. Try `exact` before reaching for `convert`. +Acceptance distinguishes: -* **`intervalIntegral.integral_congr` leaves a beta-redex.** After `intro t _` the goal reads - `(fun t ↦ …) t = (fun t ↦ …) t`, and `rw` will not match inside it. `simp only []` beta-reduces - and the rewrite then fires. Relatedly, rewriting `← integral_const_mul` backwards leaves the - constant as a metavariable and the instance search gets stuck; state the congruence as its own - `have` and rewrite forwards. +- exact source generation and input coverage; +- Lean elaboration with the pinned project options; +- independent kernel replay over the pinned imported environment; +- original final-theorem type preservation; +- actual value and type/value dependency checks for both final theorems. -The habit that caught all of these: validate generated data against an *independent* -computation — quadrature for moments, exact evaluation at several rational points for -identities — before writing any Lean. `scripts/gen_moment.py` refuses to emit data that -fails its quadrature check. +Those dependency checks require all finite cases, the real tail base, the +geometric reduction and the certificate core, and reject the retired scalar +route. They do not equate a module import with proof consumption. -## 8. Trust policy +Readability is the first selection criterion, measured compilation cost second, +and line count third. Source counts include the shared certificate frontend; +generator, template and input-table costs are reported separately rather than +hidden by moving text out of Lean files. -No `sorry` (outside the stated goal), no `axiom`, no `native_decide`, no `unsafe`, no -floating point in any statement or proof. `maxHeartbeats` / `maxRecDepth` are raised in -generated files; these are resource knobs, not escape hatches, and are recorded here -deliberately. +## Sources -`scripts/gen_degree.py` is untrusted: Lean re-derives `P n` and checks the Bernstein identity -with `ring`, so a corrupted coefficient fails the build. Its `--check` mode compares against -numerical quadrature, and that check has already caught a real bug — a dropped `2ˡ` in -`(-2c)ˡ` produced a `P` wrong by sign and scale which nevertheless admitted a Bernstein -representation, with every coefficient negative. **Positivity of a certificate is not -evidence that `P` is right**; only agreement with an independent evaluation is. Two -generators written in this project were silently wrong and caught only this way. +[1] https://github.com/teorth/sendov +[2] https://github.com/SJanPerth/Sendov-Proof-Distillation/tree/e8ae601491ec171ab4f7f8456113dd6a047aa85d diff --git a/docs/finite-range.md b/docs/finite-range.md deleted file mode 100644 index bca78d8..0000000 --- a/docs/finite-range.md +++ /dev/null @@ -1,72 +0,0 @@ -# The finite-range check - -Reference material for the finite-range component of the proof: the Bernstein-certificate -verification of the numerical claim `stat` for degrees 5 to 100, and the analytic argument for -degrees 101 and above. This is one component; for the proof as a whole, and for where this -component is used, see the [repository README](../README.md). - -The two documents below are external hand-off material, and both have been superseded in -parts. A reviewer should know which claims still stand. - -| file | what it is | status | -|---|---|---| -| [`plan-finite-range.md`](plan-finite-range.md) | The original hand-off plan for formalizing the finite range, written before any code existed. | **External, superseded in parts.** See below. | -| [`proof-large-degree.md`](proof-large-degree.md) | An informal but formalization-ready proof that `stat` is impossible for `n > 100`, plus (in its §9) speculative strategies for lowering the finite cutoff. | **External. Formalized in outline, not in detail** — see below. Its §9 is explicitly labelled unproved by its author. | - -The project's own design record, including the measurements behind the decisions recorded -here, is [`design.md`](design.md). - -## Where the plan has been superseded - -`plan-finite-range.md` is still the best statement of the *goal* and of the trust policy, but -several of its technical recommendations were overturned by measurement. Recorded here so a -reader does not follow them by mistake: - -- **§2.4, degree five.** The chord bound, the `H(B)` formula in half-integer powers of `B`, - and the substitution `α = 3r²/(1-r²)` are all unnecessary. A tunable tangent parameter - `w = 1/3` folds degree five into the general odd-degree path. -- **§3, the infeasible/bound dichotomy.** No box ever needs an infeasibility certificate. - Only `α ≤ (n-1)/2` is used, which follows from `A ≥ 0`. -- **§4, adaptive subdivision.** One Bernstein certificate covers the whole interval at every - degree tested. The generator never bisects. -- **§2.2, formula (M).** Correct, and proved as `Sendov.integral_moment`, but with `Θ(k²)` - terms it cannot be expanded by `simp` beyond about `k = 20`. The plan anticipates this - ("if the closed multinomial formula is slow, prove a recurrence") — the recurrence is - `Recurrence.lean`, and it too needed a change of *representation* to be usable. - -What the plan gets right and should be kept: the trust policy (§7), the insistence that the -integral replacement be proved rather than assumed, and the acceptance criteria (§10). - -## Where `proof-large-degree.md` has been superseded - -Its §1–3 are formalized as written (`LargeDegree/Beta.lean`, `LargeDegree/Tail.lean`). Its -§4–§7 are formalized in outline only, because using the sharp Beta constant -`6/((r+1)(r+2)(r+3)(r+4))` in place of the write-up's `6/r⁴` changes what needs proving: - -- **§4.1 and its degree-8 certificate (17)–(18) are not needed.** With the sharp constant the - `n(n-2)` cancels and the first tail term is a rational function of `n`. -- **(16) is not true as stated.** The first tail term does not decrease with `n` on its own — - at `α = 17` it rises by 0.37% up to `n ≈ 108`. It is the `c⁴` in the denominator that makes - the product decrease. `Monotone.lean` takes a flat 1% allowance instead and certifies it. -- **§4.2 is kept**, but with `√B ≤ 12/13` (a rational bound) so nothing irrational enters the - step ratio, and with `B^((n-4)/2)` rewritten as the natural power `(√B)^(n-4)`. -- **§7's split of `[0,17]` at `α = 16` is unnecessary.** One degree-58 Bernstein certificate - covers the whole range, with all 59 coefficients positive. The tight `T̃₂(17) = 0.55719` - against `279/500` (0.15% of room) does not arise; the margin at `α = 17` is 7.7%. - -See `design.md` §7 for the details. - -## Note on §9 of `proof-large-degree.md` - -That section proposes lowering the finite cutoff via monotonicity `R_{n+2} ≤ R_n`, or via a -four-chord majorant. Both were investigated: - -- The monotonicity is **true** (verified numerically over `53 ≤ n ≤ 95`) but has a minimum - relative margin of 1.48%, against the ~15% a direct proof of `R_n < 1` is allowed. It - demands far more sharpness than the goal. -- The four-chord table in §9.3 **reproduces** to three decimals. Eight chords give a - comfortable margin (0.932 at `n = 53` against 0.989 for four). But the majorant does not - fix the cost problem, because `ring`'s cost is dominated by intermediate expansion rather - than term count. - -See `design.md` §6 for the measurements. diff --git a/docs/getting-started.md b/docs/getting-started.md index ce1ad4a..de9d083 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -1,139 +1,76 @@ -# Starting a project like this one - -*For someone who is new to Lean, to VS Code, to GitHub, or to coding agents — or to all four. -It describes the setup this repository actually started from, and the working habits that -turned out to matter. It is not a Lean tutorial; it is an account of how to get a formalization -project of this kind moving.* - -The companion document [`making-of.md`](making-of.md) is the transcript of what followed. - ---- - -## 1. The setup - -Four things, in this order. On a reasonable laptop the whole setup is well under an hour, most -of it downloads. - -**Lean.** Install via `elan`, the toolchain manager, and create a project with Mathlib as a -dependency, following the official instructions: -. Do not install Lean by hand and -do not build Mathlib from source — `lake exe cache get` downloads a prebuilt Mathlib, and the -difference is minutes against hours. - -**VS Code, with the Lean 4 extension.** This is what makes Lean usable: put the cursor anywhere -in a proof and the *infoview* shows the goal at that point — what is left to prove, and what is -available to prove it with. You will read the infoview constantly, including to check what the -agent has done. - -**A coding agent.** This project used [Claude Code](https://claude.com/claude-code), which runs -in the VS Code terminal (or as an extension) and can read and edit files, run `lake build`, and -read the compiler's errors. - -**Git and a GitHub account.** The agent will commit for you, but the history is yours, and it is -the thing that lets you undo an afternoon that went wrong. - -That is exactly how this repository started: a fresh `lake new` project, VS Code with the Lean -extension, Claude Code installed, and then a conversation. - ---- - -## 2. What to do before writing any mathematics - -Three things, all cheap, all of which paid for themselves many times over here. - -**Write down what you will not accept.** In Lean, a proof can be faked in several ways: `sorry` -leaves a hole, an `axiom` assumes the thing, `native_decide` trusts a compiled binary rather -than the kernel. Decide the rules up front and put them in a script that checks them. This -project's rules are: no `sorry`, no project-defined `axiom`, no `native_decide`, no `unsafe`, -no floating point in any statement or proof. See [`../scripts/audit.sh`](../scripts/audit.sh) — -it is under sixty lines and it ran after essentially every change. - -This matters more with an agent than without one. An agent under pressure to make a build pass -has a strong pull towards `sorry`, and in this project it twice reached for one and had to be -pulled back. A script that fails is a better guard than an instruction that is remembered. - -**Decide what is inside the trusted base.** Anything generated outside Lean — here, Bernstein -certificates emitted by Python — should be re-verified *inside* Lean rather than believed. Get -this right at the start and a generator bug becomes a build failure instead of a false theorem. - -**Make the final statement small and separate.** The thing a reader must audit is the -*statement*, not the proof. Keeping it in its own short file, importing only Mathlib and -defining nothing of its own, means someone can check what you proved without reading how. See -[`../Challenge.lean`](../Challenge.lean): 87 lines for a development of 15,000. - ---- - -## 3. Working with the agent - -**Give it a target, not a task list.** The productive messages in this project were of the form -"here is the next theorem I want, here is the informal argument, propose a plan" — not -step-by-step instructions. The agent is better at finding a route through Lean than you will be; -it is much worse than you at knowing which theorem is worth proving. - -**Ask it to plan before it builds, and read the plan.** Several times the plan revealed a -misunderstanding that would have cost hours of wrong Lean. - -**Ask it to check the mathematics first.** Before formalizing a chain of implications, have it -verify each one — on paper or numerically. In this project, one inequality was numerically -checked over 200,000 cases before any Lean was written, and a tempting shortcut was measured and -found to lose too much. Formalizing a false lemma is the most expensive mistake available. - -**Interrupt.** You can send a message while it is working. A correction delivered mid-task is -far cheaper than one delivered after the commit. One such interruption here — "use multisets -throughout" — changed the architecture of everything downstream, for the better. - -**Insist that it says when something failed.** "The build is green" and "the build is green -except for three files I stubbed out" are very different sentences. Ask for the second kind. - -**Keep a design record.** A file in which the agent writes down what was decided, what was -measured, and what Lean trap it just fell into. In this project -[`design.md`](design.md) accumulated a list of Lean pitfalls that visibly stopped repeat -mistakes. It also survives the conversation: long sessions get compacted and the agent forgets, -but the file does not. - ---- - -## 4. What to expect - -**It will not be one sitting.** This project ran over four days and a long conversation that -had to be compacted several times. Commit often; the commits are what carry state across the -gaps. - -**The compiler is the referee, and it is strict but honest.** A Lean proof either compiles or -it does not. This is what makes the arrangement work: you do not have to trust the agent's -assurance that a proof is correct, and neither does the agent. Everything else — is this the -right theorem, is the statement faithful, is the citation accurate — remains entirely yours. - -**Expect resource problems that look like bugs.** Building many heavy files at once here -produced errors that looked exactly like disk corruption and were in fact out-of-memory. If -something inexplicable happens after a parallel build, suspect memory first. Restarting the -Lean server in VS Code (`Ctrl+Shift+P` → "Lean 4: Restart Server") clears a surprising amount. - -**Expect the agent to be strongest at the middle of the difficulty range.** Routine Lean -plumbing it does far faster than a human. A genuinely novel mathematical idea it will usually -not find. The interesting zone is in between — "here is the argument, make Lean accept it" — -and that is most of a formalization. - ---- - -## 5. If you are new to Lean specifically - -You do not need to be fluent to run a project like this, but you should be able to *read* a -statement, or you cannot check what you are getting. Two things worth learning early: - -- how to read a theorem statement — the hypotheses before the colon, the conclusion after; -- how to use the infoview to see the goal in the middle of a proof. - -The standard entry points are -[Mathematics in Lean](https://leanprover-community.github.io/mathematics_in_lean/) and the -[Natural Number Game](https://adam.math.hhu.de/). The -[Lean Zulip](https://leanprover.zulipchat.com/) is where questions get answered, usually -quickly and kindly. - -A useful early exercise: take a theorem the agent has just proved, and satisfy yourself that -the *statement* says what you think it says. That skill — not the ability to write tactic -proofs — is what the arrangement in this repository actually depends on. - ---- - -*Part of [teorth/sendov](https://github.com/teorth/sendov).* +# Build and verification + +## Pinned environment + +Install Lean through elan and use this repository's `lean-toolchain` and +`lake-manifest.json`. Do not upgrade Mathlib as part of replaying these proofs. + +```sh +lake exe cache get +lake build +lake env lean scripts/axioms.lean +sh scripts/audit.sh +``` + +The default build includes `Sendov`, `Solution`, and the original `Challenge` +specification. `Solution.lean` supplies the two exact statement-of-record +declarations. The two intentional `Challenge.lean` holes are specification +placeholders, not imported proof dependencies. + +## Independent kernel replay + +A successful elaboration is not the same check as independent kernel replay. +After the build, the installed toolchain can replay each project module: + +```sh +set -eu +python3 -c 'from pathlib import Path; print("\n".join(".".join(p.with_suffix("").parts) for p in sorted(Path("Sendov").rglob("*.lean"))))' | +while IFS= read -r module; do + lake env leanchecker --verbose "$module" || exit 1 +done +lake env leanchecker --verbose Solution +``` + +The import-only `Sendov.lean` facade has no local theorem to replay. Checking +`Solution` alone does not replay every imported project theorem, which is why +the loop covers the proof modules separately. These checks use the pinned +imported environment; they are not described as a fresh re-proof of Mathlib. + +The final theorem types must also agree with the original specification. +[`comparator.json`](../comparator.json) records the public comparison targets. +Axiom checks, independent kernel replay, type comparison and actual proof +consumption address different questions and are not interchangeable. + +## Regenerate the selected finite certificates + +Python prepares exact rational/integer data. It neither proves the final +inequalities nor replaces the Lean checks. + +```sh +set -eu +out=$(mktemp -d) +python3 scripts/gen_distillation.py --output "$out/generated" +diff -ru Sendov/DistillationFinite "$out/generated/Sendov/DistillationFinite" +diff -u Sendov/Common/DistillationFinite.lean "$out/generated/Sendov/Common/DistillationFinite.lean" +python3 -m unittest discover -s tests +``` + +The output is the entire finite family, in one selected grouped layout with the +tail base kept separately. Use a fresh output root; generation must not replace +a nonempty directory. See [`scripts/GENERATORS.md`](../scripts/GENERATORS.md) for +the retained global `sinh` generator and its SymPy dependency. + +If certificate data or generated proofs change, verify the complete affected +import cone, its kernel checks and final consumers. Do not count previously +compiled objects from a different source projection as a successful new build. + +## Interpreting results + +- A Python success means generation or a tool test succeeded. +- A Lean success means that particular source/module elaborated. +- A kernel success means the named module replayed over its imports. +- Full completion also requires both unchanged final contracts and their real + proof dependencies, including every finite case and the infinite tail. + +The active branch does not include the retired packed/moment/`R` certificate +system as a compatibility fallback. diff --git a/docs/making-of.md b/docs/making-of.md deleted file mode 100644 index 40e0cec..0000000 --- a/docs/making-of.md +++ /dev/null @@ -1,326 +0,0 @@ -# Making of - -*How this formalization actually happened: a curated transcript of the conversation between -Terence Tao and Claude (Opus 5, running in Claude Code) that produced the Lean development in -this repository. Four days, 10–13 August 2026, in one long-running conversation that had to be -compacted several times, plus an earlier session that created the repository.* - -**How to read this** - -- Tao's messages appear in `>` blockquotes, verbatim, trimmed with `[…]` where long. Replies - of the form "yes", "ok, continue", "resume" are folded into the narration — there were many. -- Claude's side is compressed into *italic* summaries of what actually changed. -- The stage headings follow the git history, which is the authoritative record; `git log - --reverse` reads as a more granular version of this document. -- Dead ends and mistakes are kept in. They are the instructive part, and leaving them out - would misrepresent how the work went. - -A companion document, [`getting-started.md`](getting-started.md), describes how to set up to do -something like this. - ---- - -## 0. Before the transcript - -The repository was created from a fresh Lean project — `lake new`, following the -[leanprover-community project instructions](https://leanprover-community.github.io/install/project.html) -— with VS Code, the Lean 4 extension, and Claude Code already installed. Then the conversation -was launched, and everything below happened inside it. - -The first four commits (10 August) set the target and proved the easiest cases: - -- `Initial commit: state the finite-range numerical claim` -- `Milestone 1: prove the finite-range claim in degree six` -- `Milestone 2: prove the finite-range claim in degree seven` -- `Milestone 3: degree five, and a simplification of the remaining plan` - -The goal at this point was narrow: **not** Sendov's conjecture, but the single numerical -inequality that a blog-post proof left to computation on a finite range of degrees. The -polynomial argument was deliberately kept outside the project — that scope, and the trust -policy below, come from an externally supplied hand-off plan written before any code existed: -[`plan-finite-range.md`](plan-finite-range.md). The blog post it refers to is -[*A digestion of the proof of Sendov's conjecture*](https://terrytao.wordpress.com/2026/08/12/a-digestion-of-the-proof-of-sendovs-conjecture/). - -Two decisions made here shaped everything after. The first was a **trust policy**, fixed before -any real code: no `sorry`, no project-defined `axiom`, no `native_decide`, no `unsafe`, no -floating point in any statement or proof — with [`scripts/audit.sh`](../scripts/audit.sh) -written to enforce it and run every time. The second was that the Python certificate generators -would live **outside the trusted base**: they emit Lean source that Lean re-verifies from -scratch, so a bug in a generator causes a build failure rather than a false theorem. Where the -plan's technical recommendations were later overturned by measurement is recorded in -[`finite-range.md`](finite-range.md). - ---- - -## 1. General machinery, and the first real degree - -> ok, let's build the general degree machinery - -*Generalized the per-degree proofs into a moment formula and a reduction that works at any -degree, then attempted degree 20.* - -> ok, try n=20 - -*Degree 20 became the first certificate-backed degree. Also corrected a feasibility claim that -had been stated too strongly, which pulled the provable range back to `n ≤ 97`, and committed -the generator so the certificates were reproducible rather than magic constants.* - -Then a request that turned out to matter: - -> Can you summarize what steps (1)-(2) are again? - -*This kind of question was load-bearing throughout. Restating the plan repeatedly caught drift -between what had been agreed and what was being built.* - ---- - -## 2. The representation problem - -The moment computation would not scale. The obvious fix — replace the closed formula by a -recurrence — was tried and did not work either. - -> ok lets measure 46 - -*Measured it. The recurrence was correct and provable, but far too slow: `List (List ℤ)` -arithmetic at `k = 46` ran for hours. Commit: `Moments by a verified recurrence`, immediately -followed by the realization that the recurrence was unusable as represented.* - -The fix was **Kronecker packing** — encode the whole coefficient array in the digits of a -single natural number, so the recurrence becomes one big-integer exponentiation: - -| representation | k=24 | k=32 | k=46 | -|---|---|---|---| -| `List (List ℤ)` | 120 s | >20 min | hours | -| 2-D packed, single `Nat` | — | — | ~0.5 s | - -*Commit: `Kronecker packing: the fix is representation, not algorithm`. This is the single -largest speedup in the project, and it came from changing the data structure, not the -algorithm. The measurements are in [`design.md`](design.md) §4; the Lean is -[`Pack.lean`](../Sendov/FiniteRange/Pack.lean) and -[`PackBridge.lean`](../Sendov/FiniteRange/PackBridge.lean).* - -Degrees 53 and 97 then went through: - -> Let's do n=53 - -> ok let's do n=97 - ---- - -## 3. Batching, from a suggestion - -> if there is enough slack it still might be possible to batch together adjacent values of n by -> a cheap interval arithmetic type method: for say n = 66, 67, 68 upper bound each term of the -> desired expression by the worst case choice of n in this range (which could be 66 in some -> terms and 68 in others). - -*This worked, and paid better than expected — one certificate covering twenty degrees at once. -Overall the dominant cost fell about 5.5×, and on the hardest range `n ∈ [62,97]` about 12.5×.* - -| range | individually | batched | saving | -|---|---|---|---| -| `n ∈ [6,40]` | 14.2 min | 3.5 min | 4× | -| `n ∈ [42,60]` | 28.3 min | 10.2 min | 2.8× | -| `n ∈ [62,97]` | 69.8 min | 5.6 min | **12.5×** | - -*Machinery in [`Batch.lean`](../Sendov/FiniteRange/Batch.lean); measurements in -[`design.md`](design.md) §3.* - ---- - -## 4. Widening the target - -> GPT has supplied some possible approaches to handle the 50 < n < 100 range, as well as an -> analytic argument that can handle n > 100; the original blog post handles n > 200. So one -> might be able to broaden the goal to handle all n >= 5, not just 5 <= n <= 100 (which is -> towards my long term goal to completely formalize the proof of Sendov). In any event one can -> compare the options provided here with the ones you are empirically testing. - -*The analytic argument for large degrees went in — the Beta integral replacing a cruder Gamma -tail bound, the tail estimate, the degree monotonicity — and met the certificates at the seam -`100/101`. Commit: `The claim, for every degree`. The finite-range goal was now closed on both -sides, with no range left open. The supplied analytic argument is -[`proof-large-degree.md`](proof-large-degree.md); the Lean is -[`LargeDegree/`](../Sendov/LargeDegree/), and [`finite-range.md`](finite-range.md) records the -several points at which the write-up had to be departed from.* - -Then a check on whether the certificates were doing any work at all: - -*Wrote [`scripts/mutation_test.sh`](../scripts/mutation_test.sh), which perturbs a certificate -and confirms the build fails. -Its first run found that part of what it was testing did not bite — recorded in the commit -message rather than quietly fixed.* - ---- - -## 5. The reduction chain - -> Fantastic! Now I'd like to be a bit more ambitious. I've revised the reference blog post -> […] We've now shown that {stat} is infeasible for any alpha \leq 17 and n \geq 5. But {stat} -> can ultimately be deduced from {1Q} and {origin-exact}, and these inequalities also imply -> alpha \leq 17, so this shows that {1Q} and {origin-exact} are not simultaneously satisfiable -> for n \geq 5. I'd like this to be the next formalization target. As per the blog post, this -> splits up into several separate subgoals […] Can you check all of these implications and -> propose a plan to formalize them? You are encouraged to re-use lemmas that can be placed in -> the Common directory. - -*Checked each implication first, then built them in order. The crux was a sharp bound -`log(sinh h / h) ≤ √(h²+9) - 3`, needed to three orders at `h = 0`. The textbook route is an -infinite series, which is painful in Lean; instead a family of functions closed under -differentiation reduced the whole thing to one `ring` identity, eight monotonicity steps, and -a polynomial with all coefficients positive — [`Common/Sinh.lean`](../Sendov/Common/Sinh.lean). -Commits: `The sinh lemma, without the series` through `The chain closes: {1Q} and -{origin-exact} are incompatible`; the chain itself is [`Reduction/`](../Sendov/Reduction/).* - ---- - -## 6. From a counterexample to the inequalities - -> Great! I'm now interested in formalizing Conjecture \ref{interior} in the blog post. This -> requires combining polar_origin_incompatible with a derivation of Lemma \ref{identities} from -> the existence of a counterexample to Conjecture \ref{interior}, and then a derivation of the -> polar and origin inequalities from those identities. Can you plan a path towards doing this? - -*Planned, then built bottom-up. Two ingredients were missing from Mathlib and had to be proved -from scratch: **Maclaurin's inequality** (the standard route needs Newton's inequalities plus -real-rootedness and Rolle; an elementary multiset induction reducing to Bernoulli turned out to -be much shorter — [`Maclaurin.lean`](../Sendov/Analytic/Maclaurin.lean)) and the **defect -lemma** (the write-up's proof goes through `sinh` and a limiting argument; a direct induction -avoided both — [`Defect.lean`](../Sendov/Analytic/Defect.lean)).* - -Mid-stream, an instruction that changed the architecture of everything downstream: - -> One should use multisets throughout including for Maclaurin (one can use multiset induction -> for this) - -*This paid off twice: multiset AM–GM came free from the same Bernoulli step, and a large amount -of index bookkeeping simply never arose.* - -> The later components are "[…]sendov-low-degrees-lean-plan.md" and -> "[…]sendov-boundary-rubinstein-lean-plan.md". You can read them to see if it affects the -> current plan, and then go for the defect lemma - -*Those two are now [`plan-low-degrees.md`](plan-low-degrees.md) and -[`plan-boundary-rubinstein.md`](plan-boundary-rubinstein.md); they were followed closely, and -became §7 below.* - -*Two mistakes belong here. Twice, drafting a file, Claude wrote `sorry` placeholders intending -to fill them in — a direct violation of the project's own trust policy. Both were removed -before any commit, and both were reported rather than quietly deleted. The policy is only worth -anything if breaking it gets said out loud.* - -Then the identities, the polar branch point, and the origin channel, over several sessions: - -> ok let's do the identities - -> OK, let's get to 1Q - -> ok let's do origin-exact! - -*The origin channel was the largest single piece: the pointwise error bound via Maclaurin, -Cauchy–Schwarz and the quadratic mean; the derivative of `F(t) = ∏(1 - a t qⱼ)`; the triangle -inequality by FTC; the defect estimate for `J ∑ 1/zⱼ`; and finally `(origin-exact)` itself, -landing exactly on the hypothesis the reduction chain wanted: -[`Origin.lean`](../Sendov/Analytic/Origin.lean), -[`Jsum.lean`](../Sendov/Analytic/Jsum.lean), -[`OriginExact.lean`](../Sendov/Analytic/OriginExact.lean).* - -A recurring theme in this stretch: everything was kept **division-free**. The blog post's -convention of "removing singularities" when some `zⱼ` vanishes was made *unnecessary* rather -than formalized, by clearing denominators in the statements themselves. - ---- - -## 7. All degrees, and the remaining cases - -> Lets extend the interior conjecture to n >= 2! - -*The high-degree argument genuinely fails below `n = 5` — the discriminant `(3n-1)² - 4(n-1)³` -turns positive. But the low degrees do not need it: bounding each factor of the branch point by -a scalar already contradicts itself for `n ≤ 5` — -[`LowDegree.lean`](../Sendov/Analytic/LowDegree.lean), following -[`plan-low-degrees.md`](plan-low-degrees.md). Degree 5 is now proved twice, by independent -routes.* - -> Let's do the a=1 Rubinstein theorem and the a=0 case next - -*`a = 0` turned out to be three lines of consequence from a lemma that was already there. The -boundary case `|a| = 1` needed a genuinely different argument, since the polar identity -degenerates there, and it is where the Phelps–Rodriguez equality classification comes from — -[`Boundary.lean`](../Sendov/Boundary.lean), following -[`plan-boundary-rubinstein.md`](plan-boundary-rubinstein.md).* - -> Let's formalize the full Sendov and Phelps-Rodriguez conjecture! - -*Only a rotation was left — [`Conjecture.lean`](../Sendov/Conjecture.lean). Both conjectures, -in full generality, on `propext`, `Classical.choice` and `Quot.sound` alone.* - ---- - -## 8. Registration, and a correction - -> I would like to prepare this repository for registration at the Palomar registry -> https://palomar-registry.org/ . What would need to be done to do this? - -*Read the registry's own policy repository rather than guessing, and found the repository had -**no `LICENSE` file** — while all 76 Lean files claimed one. Added the -[`Challenge.lean`](../Challenge.lean)/[`Solution.lean`](../Solution.lean) pair, -[`comparator.json`](../comparator.json) and [`formalization.yaml`](../formalization.yaml), and -validated the metadata by running the registry's own validator locally.* - -Registration succeeded, with one reviewer comment: - -> The Palomar registry succeeded with the following comment: The narrow novelty claims about the -> Rubinstein boundary proof and the formalization are unsupported by a documented literature -> search. […] I can disclaim any novelty claim on the Rubinstein result, and stress more heavily -> that this is the second formalizaton of the Sendov conjecture result (though the first of the -> Phelps-Rodriguez version). - -*The comment was fair, and checking it against the published blog post turned up something -worse: the post is a digestion **of** the earlier proof, not an independent argument — it says -so, and cites specific inequalities as extracted from it. So the submitted metadata's claim of -independence from the earlier Lean formalization was simply wrong, and was corrected to -`builds-on`. Every novelty claim in the repository is now qualified as unknown, with an explicit -statement that no literature search was performed — see -[Provenance and novelty](../README.md#provenance-and-novelty).* - -*A postscript, and a vindication of the reviewer's point. The boundary argument of §7 — the one -the documentation had called "a new proof of Rubinstein's theorem" — turned out not to be new. -Its two ingredients are equation (5.1) and Remark 5.1 of a 2025 preprint of Tang and Zhang, -[arXiv:2508.10341](https://arxiv.org/abs/2508.10341), which combines them to give the `a = 1` -case of Sendov's conjecture; the reciprocal identity and the half-plane bound are both there. -It was reached here independently, from the blog post, but a literature search would have found -it, which is exactly what the reviewer said. The documentation now says so.* - ---- - -## What the process actually looked like - -Some observations that are not visible in the final source. - -**Memory, not time, was the binding constraint.** Building 31 certificate files in parallel -produced `0xC0000409` crashes and "failed to read … olean" errors on *toolchain* files — which -look exactly like disk corruption and are actually out-of-memory. The fix was -[`scripts/staged_build.sh`](../scripts/staged_build.sh). At one point the VS Code Lean server -holding 7.4 GB had to be restarted. - -**Numerical claims were checked before being proved.** Maclaurin's inequality was verified -numerically over 200,000 cases before any Lean was written; the cheap AM–GM alternative was -measured and found to lose a factor of `e`, which would have broken a later step. Several hours -were saved by finding that out first. - -**The design record was maintained continuously.** [`design.md`](design.md) accumulated not -just what -was proved but the measurements behind each decision and a running list of Lean traps — `set` -introducing a definition that `linarith` zeta-reduces, `field_simp` distributing across an -integral atom, `rw [h]` where `h : p = …` also rewriting the `p` inside `p.leadingCoeff`. That -list stopped several repeat mistakes. - -**Verification beat assertion, repeatedly.** Where a claim could be checked mechanically it was: -link targets in the README resolved against the files, the audit script mutation-tested to -confirm it bites, the registry metadata run through the registry's own code, the Challenge and -Solution types compared under `pp.all` rather than by eye. - ---- - -*Part of [teorth/sendov](https://github.com/teorth/sendov).* diff --git a/docs/plan-finite-range.md b/docs/plan-finite-range.md deleted file mode 100644 index 7e5c5b6..0000000 --- a/docs/plan-finite-range.md +++ /dev/null @@ -1,398 +0,0 @@ -# Lean verification plan for the finite Sendov range - -## 1. Objective and scope - -The goal is to formalize only the finite-dimensional numerical implication left open in the blog post. The full polynomial argument should remain outside this project initially. - -Write - -\[ -M=n-1,\qquad -A=1-\frac{2\alpha}{M},\qquad -B=\frac{\alpha}{3+\alpha}, -\] - -\[ -c=1-\frac{\alpha}{M}-\frac{\alpha}{2(3+\alpha)}, -\qquad -Q(t)=1-2ct+At^2. -\] - -The domain to be certified is - -\[ -5\le n\le 200,\qquad 0\le\alpha\le17, -\qquad c^2\le A. -\tag{D} -\] - -The last condition is the feasibility condition occurring in the blog post. The target is to prove that, on this domain, - -\[ -\begin{split} -R_n(\alpha):={}&\frac16+\frac1{4(3+\alpha)} -+\frac1{2M}+\frac1{4M(3+\alpha)}\\ -&+\frac{A^2nM(n-2)}{4(3+\alpha)} - \int_0^1 t^3Q(t)^{(n-4)/2}\,dt -<1. -\end{split} -\tag{F} -\] - -This contradicts equation `stat` of the blog post, which asserts \(1\le R_n(\alpha)\). Here \(A=a^2\), so the factor \(A^2\) in (F) is the blog post's \(a^4\). - -A useful final interface is therefore something like: - -```lean -theorem finite_range_contradiction - (n : ℕ) (α : ℝ) - (hn_lo : 5 ≤ n) (hn_hi : n ≤ 200) - (hα_lo : 0 ≤ α) (hα_hi : α ≤ 17) - (hfeas : c n α ^ 2 ≤ A n α) - (hstat : 1 ≤ finiteRangeRHS n α) : False -``` - -The original argument has \(\alpha>0\), because an earlier inequality was divided by \(\alpha\). It is harmless and convenient for the numerical lemma to include \(\alpha=0\), since the upper bound in (F) extends continuously there and is still strictly below one. - -## 2. Eliminate numerical integration first - -It is preferable not to certify a quadrature routine. The integral in (F) admits an exact algebraic treatment in even degrees and a simple algebraic upper bound in odd degrees. - -### 2.1 Basic bounds on the quadratic - -The feasibility condition gives - -\[ -Q(t)=(1-ct)^2+(A-c^2)t^2\ge0. -\] - -Moreover, \(Q\) is convex, \(Q(0)=1\), and \(Q(1)=B<1\). Hence - -\[ -0\le Q(t)\le1\qquad(0\le t\le1). -\tag{Q} -\] - -The identity \(Q(1)=B\) should be checked in Lean directly from the definitions. Positivity of every denominator should be recorded explicitly; in particular, \(M>0\) and \(3+\alpha>0\). - -### 2.2 Exact polynomial moments - -For an integer \(k\ge0\), define - -\[ -I_k(n,\alpha)=\int_0^1t^3Q(t)^k\,dt. -\] - -The multinomial theorem gives the exact finite sum - -\[ -I_k= -\sum_{\substack{i,j\ge0\\i+j\le k}} -\frac{k!}{i!j!(k-i-j)!} -\frac{(-2c)^iA^j}{4+i+2j}. -\tag{M} -\] - -This follows by expanding - -\[ -(1+(-2c)t+At^2)^k -\] - -and integrating each monomial. It can instead be implemented recursively if the triple sum causes performance problems. Either representation is exact and rational in \(\alpha\). - -For even \(n\), put \(k=(n-4)/2\). The integral in (F) is exactly \(I_k\). - -### 2.3 Odd degrees at least seven - -If \(n\ge7\) is odd, put \(k=(n-5)/2\). By (Q) and - -\[ -2\sqrt u\le1+u\qquad(0\le u\le1), -\] - -one has - -\[ -Q(t)^{k+1/2} -\le \frac{Q(t)^k+Q(t)^{k+1}}2. -\] - -Consequently, - -\[ -\int_0^1t^3Q(t)^{(n-4)/2}\,dt -\le\frac{I_k+I_{k+1}}2. -\tag{O} -\] - -This removes every square root and reduces the problem to a rational inequality in \(\alpha\). - -### 2.4 The special case \(n=5\) - -The bound (O) is a little too wasteful in degree five. Use convexity of \(Q\) instead: - -\[ -Q(t)\le(1-t)Q(0)+tQ(1)=1-(1-B)t. -\] - -Thus - -\[ -\int_0^1t^3\sqrt{Q(t)}\,dt\le H(B), -\] - -where - -\[ -H(B)=\frac{1}{(1-B)^4} -\left[ -\frac{32}{315} --\left( -\frac23B^{3/2}-\frac65B^{5/2} -+\frac67B^{7/2}-\frac29B^{9/2} -\right) -\right]. -\tag{H} -\] - -Introduce \(r=\sqrt B\) only inside the degree-five module. Then - -\[ -B=r^2,qquad -\alpha=\frac{3r^2}{1-r^2}, -\] - -and the right side of (H), as well as the degree-five instance of (F), becomes rational in \(r\). Since \(\alpha\le17\), it is enough to work with \(0\le r<1\); one may choose a convenient rational outer endpoint and exclude its extraneous portion by the transformed constraints. For example, \(r\le19/20\) contains the entire range implied by \(B\le17/20\). - -An alternative is to use several rational affine upper bounds for \(\sqrt u\) and keep \(\alpha\) as the sole variable. The substitution above is probably simpler. - -## 3. Reduce each degree to polynomial positivity - -Define `upperRHS n α` by replacing the integral in (F) as follows: - -- if \(n\) is even, use (M) exactly; -- if \(n\ge7\) is odd, use (O); -- if \(n=5\), use (H). - -The desired statement is - -\[ -1-\operatorname{upperRHS}_n(\alpha)>0. -\] - -For \(n\ge6\), this is a rational function of \(\alpha\). Clear a known-positive denominator and write it as - -\[ -1-\operatorname{upperRHS}_n(\alpha) -=\frac{P_n(\alpha)}{D_n(\alpha)}, -\qquad D_n(\alpha)>0. -\] - -The certificate only has to prove \(P_n(\alpha)>0\). It is fine for \(D_n\) to be larger than the least common denominator; a uniform, easily verified positive denominator is preferable to a minimal one. - -The feasibility constraint can likewise be written, after clearing a positive denominator, as a polynomial inequality - -\[ -G_n(\alpha)\ge0, -\] - -where \(G_n\) represents \(A-c^2\). Thus a box may be closed in either of two ways: - -1. prove \(G_n<0\) throughout the box, so the box contains no feasible point; or -2. prove \(P_n>0\) throughout the box. - -This avoids finding the exact endpoint imposed by \(c^2\le A\). Simply cover all of \([0,17]\) and let each interval certificate establish either infeasibility or the desired upper bound. - -For \(n=5\), do the same after the substitution \(\alpha=3r^2/(1-r^2)\). - -## 4. Recommended certificate: rational Bernstein bounds - -Use exact rational Bernstein certificates on rational subintervals. - -If \(p\in\mathbb Q[X]\) and \([\ell,u]\) is a rational interval, transform - -\[ -p(\ell+(u-\ell)s) -=\sum_{j=0}^d b_j {d\choose j}s^j(1-s)^{d-j}. -\] - -For \(0\le s\le1\), every Bernstein basis function is nonnegative and their sum is one. Therefore - -\[ -\min_j b_j>0\quad\Longrightarrow\quad -p(x)>0\quad(\ell\le x\le u). -\tag{B} -\] - -Bernstein bounds are preferable here to a naive interval evaluation of a fully expanded polynomial: they substantially reduce dependency and wrapping losses. - -The untrusted generator may adaptively subdivide intervals. Lean must verify all of the following using exact rational arithmetic: - -- the boxes are ordered and cover the entire outer interval; -- every endpoint is the exact endpoint claimed in the data; -- a box labeled `infeasible` has a Bernstein certificate for \(-G_n>0\); -- a box labeled `bound` has a Bernstein certificate for \(P_n>0\); -- every strict certificate has a positive rational lower margin, not merely a nonnegative one. - -The safest design is for the certificate data to contain only rational endpoints and a box label, with Lean recomputing the Bernstein coefficients. If this is too slow, the generator may also emit coefficients, but Lean must then verify the exact polynomial identity relating them to \(P_n\) or \(-G_n\). - -## 5. Suggested Lean project structure - -```text -SendovFinite/ - Basic.lean - Moments.lean - OddBound.lean - DegreeFive.lean - Bernstein.lean - CertificateData.lean - Verify.lean -``` - -### `Basic.lean` - -- Define `M`, `A`, `B`, `c`, and `Q` using exact real expressions. -- Define the finite-range feasibility predicate. -- Prove denominator positivity. -- Prove `Q_nonneg`, `Q_le_one`, and `Q_one` from (D). -- Keep casts between `ℕ`, `ℚ`, and `ℝ` explicit and localized. - -### `Moments.lean` - -- Define the rational moment expression in (M). -- Prove it equals the interval integral of \(t^3Q(t)^k\). -- Isolate all finite-sum and integration library work here. -- If the closed multinomial formula is slow, prove a recurrence for the coefficient vector of \(Q^k\) and integrate that vector termwise. - -### `OddBound.lean` - -- Prove `two_mul_sqrt_le_add` in the precise form needed for \(0\le u\). -- Deduce (O) from `Q_nonneg` and `Q_le_one`. -- Avoid carrying `Real.sqrt` past this module. - -### `DegreeFive.lean` - -- Prove the convex chord bound for `Q`. -- Prove (H), either by a direct antiderivative or by the substitution used above. -- Introduce \(r\) locally and reduce the resulting statement to rational polynomial positivity. - -### `Bernstein.lean` - -- Define the Bernstein basis over `ℚ` and its evaluation in `ℝ`. -- Prove nonnegativity on \([0,1]\), the partition-of-unity identity, and theorem (B). -- Define a small verified checker for a polynomial and rational box. -- Prove the checker's soundness once; certificate data should not contain proofs. - -### `CertificateData.lean` - -- Store generated rational subdivision data. -- It is reasonable to generate one definition per degree to reduce elaboration pressure. -- Keep all numerical constants rational or dyadic. Do not use floating-point literals. - -### `Verify.lean` - -- Dispatch the finite range of `n`, perhaps with `interval_cases n`. -- For each degree, invoke the corresponding checked certificate. -- Combine the integral upper-bound theorem with polynomial positivity. -- Export `finite_range_contradiction`. - -If a single `interval_cases` call produces an unwieldy term, generate 196 small degree-specific theorems and combine them with a balanced decision tree. - -## 6. External certificate generator - -The generator can be written in Python, Sage, Julia, or another convenient language. It is not part of the trusted computing base because Lean rechecks its output exactly. - -High-level pseudocode: - -```text -for n in 5..200: - construct the exact rational upper bound - construct the cleared numerator P_n - construct the cleared feasibility polynomial G_n - queue := [outer interval] - - while queue is nonempty: - box := pop(queue) - - if Bernstein(-G_n, box) has all coefficients > 0: - emit (box, infeasible) - else if Bernstein(P_n, box) has all coefficients > 0: - emit (box, bound) - else: - bisect box at a rational midpoint -``` - -Use exact rational arithmetic when generating the final certificate. Floating point is useful only for choosing initial splits and diagnosing hard boxes. - -For degree five, run the same algorithm in \(r\), with the transformed feasibility and bound polynomials. - -## 7. Trusted-computing-base policy - -The formalization should be deliberately conservative because the purpose is to rule out a numerical or formalization loophole. - -Recommended: - -- `ring`, `ring_nf`, `field_simp`, `norm_num`, and `positivity`; -- a proved-in-Lean Bernstein checker; -- kernel-checked reduction via `decide` only if performance is acceptable; -- a pinned Lean toolchain and pinned mathlib commit. - -Avoid: - -- `sorry`, `admit`, or new `axiom` declarations; -- `unsafe` definitions in the proof path; -- `native_decide` or any mechanism whose correctness depends on trusting generated native code; -- custom metaprogramming that manufactures proof terms without a small proved soundness theorem; -- floating-point comparisons in the theorem or certificate checker; -- an FFI or external oracle whose answer is accepted without an exact Lean-side check. - -The last stage of CI should include: - -```lean -#print axioms finite_range_contradiction -``` - -and a source audit such as - -```text -rg -n '\b(sorry|admit|axiom|unsafe|native_decide|ofReduceBool)\b' SendovFinite -``` - -Any standard axioms imported by mathlib, such as classical choice or propositional extensionality, should be reported explicitly. There should be no project-specific axioms. - -## 8. Development milestones - -1. **Degree 6:** verify one even degree using the exact moment formula. -2. **Degree 7:** verify one odd degree using the averaged-moment bound (O). -3. **Degree 5:** verify the chord bound and the \(r\)-substitution. -4. **Checker:** prove the Bernstein checker's soundness and test it on hand-written low-degree polynomials. -5. **Generator:** generate and check certificates for all degrees. -6. **Composition:** prove the single theorem `finite_range_contradiction`. -7. **Audit:** run the axiom printout, forbidden-token audit, and a clean rebuild from the pinned lockfile. - -Do not begin by generating all 196 certificates. The three prototype degrees above expose the parity, square-root, integration, denominator, and certificate issues with much shorter compile cycles. - -## 9. Numerical diagnostics, not proof inputs - -Previous floating-point exploration suggests generous slack: - -- for \(6\le n\le200\), the conservative odd-degree rationalization above gave a largest upper RHS of approximately `0.8554015065`, observed at \(n=53,\alpha=17\); -- for \(n=5\), the chord bound gave a largest upper RHS of approximately `0.9037698413`, observed at \(\alpha=0\). - -These figures should be reproduced independently by the generator, but they must not appear as assumptions in Lean. They indicate that coarse rational subdivisions ought to suffice; the expected difficulty is expression size and proof-engineering performance, not a tiny mathematical margin. - -## 10. Acceptance criteria - -The handoff is complete only when all of the following hold: - -- `lake build` succeeds from a clean checkout with pinned versions; -- the exported theorem has exactly the finite-range hypotheses (D), plus `hstat`, and concludes `False`; -- the integral replacement is proved in Lean, not silently built into the theorem statement; -- every external certificate is checked using exact arithmetic by a proved sound checker; -- all 196 degrees are covered, including the separate \(n=5\) argument; -- `#print axioms` reveals no project-specific axioms; -- no prohibited escape hatch occurs in the dependency path of the final theorem; -- deleting or corrupting a certificate box causes verification to fail. - -Once this standalone theorem is stable, it can be imported into a larger formalization and applied directly to the blog post's `stat` inequality. Keeping the numerical certificate independent of the polynomial material makes both the audit and any future correction much easier. diff --git a/docs/proof-large-degree.md b/docs/proof-large-degree.md deleted file mode 100644 index 2db6ede..0000000 --- a/docs/proof-large-degree.md +++ /dev/null @@ -1,1025 +0,0 @@ -# A formalization-ready proof that `stat` is impossible for \(n>100\), \(0\le\alpha\le17\) - -## 1. Statement - -Let \(n\) be a natural number with \(n>100\), and let \(0\le\alpha\le17\). Set - -\[ -A_n:=a^2=1-\frac{2\alpha}{n-1},\qquad -B:=\frac{\alpha}{3+\alpha}, -\] - -\[ -c_n:=1-\frac{\alpha}{n-1}-\frac{\alpha}{2(3+\alpha)}, -\qquad -Q_n(t):=1-2c_nt+A_nt^2. -\] - -Assume the feasibility condition - -\[ -c_n^2\le A_n. -\tag{1} -\] - -Equation `stat` in the blog post is - -\[ -\begin{split} -1\le{}&\frac16+\frac1{4(3+\alpha)} -+\frac1{2(n-1)}+\frac1{4(n-1)(3+\alpha)}\\ -&+\frac{A_n^2n(n-1)(n-2)}{4(3+\alpha)} - \int_0^1t^3Q_n(t)^{(n-4)/2}\,dt. -\end{split} -\tag{stat} -\] - -The exponent in this formula is a real exponent, not natural-number division. We prove that the right-hand side is strictly less than one. - -The proof has four steps: - -1. replace the integral by the exponential-tail estimate already used in the blog post; -2. prove discretely that the resulting upper bound decreases with \(n\) for \(n\ge101\); -3. at \(n=101\), replace the half-integral power by an integral power; -4. split \(0\le\alpha\le17\) into \([0,16]\) and \([16,17]\), and use exact rational endpoint estimates. - -## 2. Preliminary bounds - -For \(n\ge101\) and \(0\le\alpha\le17\), - -\[ -A_n\ge1-\frac{34}{100}=\frac{33}{50}>0, -\tag{2} -\] - -and - -\[ -c_n\ge1-\frac{17}{100}-\frac{17}{40} -=\frac{81}{200}>0. -\tag{3} -\] - -Also - -\[ -0\le B\le\frac{17}{20}<1. -\tag{4} -\] - -Condition (1) gives - -\[ -Q_n(t)=(1-c_nt)^2+(A_n-c_n^2)t^2\ge0. -\tag{5} -\] - -Finally, direct simplification gives - -\[ -Q_n(1)=1-2c_n+A_n=B. -\tag{6} -\] - -## 3. The integral upper bound - -Put \(r=(n-4)/2\), so \(r>0\). The quadratic \(Q_n\) has its vertex at - -\[ -t_0=\frac{c_n}{A_n}. -\] - -If \(0\le t\le t_0\), then \(A_nt^2\le c_nt\), and hence - -\[ -Q_n(t)\le1-c_nt\le e^{-c_nt}. -\] - -Here \(1-c_nt\ge0\): indeed, (1) and \(t\le c_n/A_n\) give -\(c_nt\le c_n^2/A_n\le1\). Thus all real powers used below are applied to -nonnegative quantities. - -Using (5), raising to the positive power \(r\) gives - -\[ -Q_n(t)^r\le e^{-rc_nt}. -\tag{7} -\] - -If \(t_0\le1\), then \(Q_n\) is increasing on \([t_0,1]\), so by (6) - -\[ -Q_n(t)\le Q_n(1)=B\qquad(t_0\le t\le1). -\tag{8} -\] - -If \(t_0>1\), this second interval is empty. Extending both resulting nonnegative integrals gives, in either case, - -\[ -\begin{split} -\int_0^1t^3Q_n(t)^r\,dt -&\le \int_0^\infty t^3e^{-rc_nt}\,dt - +\int_0^1t^3B^r\,dt\\ -&=\frac{6}{r^4c_n^4}+\frac14B^r\\ -&=\frac{96}{(n-4)^4c_n^4}+\frac14B^{(n-4)/2}. -\end{split} -\tag{9} -\] - -Consequently, `stat` implies - -\[ -1\le U_n(\alpha), -\tag{10} -\] - -where - -\[ -\begin{split} -U_n(\alpha):={}&\frac16+\frac1{4(3+\alpha)} -+\frac1{2(n-1)}+\frac1{4(n-1)(3+\alpha)}\\ -&+T_{1,n}(\alpha)+T_{2,n}(\alpha), -\end{split} -\tag{11} -\] - -with - -\[ -T_{1,n}(\alpha):= -\frac{24A_n^2n(n-1)(n-2)} -{(3+\alpha)(n-4)^4c_n^4}, -\tag{12} -\] - -\[ -T_{2,n}(\alpha):= -\frac{A_n^2n(n-1)(n-2)}{16(3+\alpha)} -B^{(n-4)/2}. -\tag{13} -\] - -Everything after this point is an elementary inequality. - -## 4. Discrete monotonicity in \(n\) - -We prove - -\[ -U_{n+1}(\alpha)\le U_n(\alpha) -\qquad(n\ge101). -\tag{14} -\] - -The first four terms in (11) plainly decrease with \(n\). It remains to treat (12) and (13). - -### 4.1 The first tail term - -One has - -\[ -A_{n+1}-A_n=\frac{2\alpha}{n(n-1)} -\] - -and, by (2), - -\[ -\frac{A_{n+1}}{A_n} -=1+\frac{2\alpha}{n(n-1)A_n} -\le1+\frac{1700}{33n(n-1)}. -\tag{15} -\] - -Also \(c_{n+1}\ge c_n\). Therefore - -\[ -\frac{T_{1,n+1}}{T_{1,n}} -\le -\left(1+\frac{1700}{33n(n-1)}\right)^2 -\frac{n+1}{n-2} -\left(\frac{n-4}{n-3}\right)^4. -\tag{16} -\] - -The right-hand side is strictly less than one for every \(n\ge101\). This can be checked without analysis. After multiplying by the positive denominator - -\[ -33^2n^2(n-1)^2(n-2)(n-3)^4, -\] - -the desired inequality is - -\[ -\begin{split} -&33^2n^2(n-1)^2(n-2)(n-3)^4\\ -&\qquad-\bigl(33n(n-1)+1700\bigr)^2(n+1)(n-4)^4>0. -\end{split} -\tag{17} -\] - -Writing \(k=n-101\ge0\), the left side of (17) expands exactly as - -\[ -\begin{split} -{}&1011812007899760000\\ -&+171120966977415200k\\ -&+9227125609237658k^2\\ -&+250975969057803k^3\\ -&+3989097576248k^4\\ -&+38904262097k^5\\ -&+230383461k^6\\ -&+763356k^7+1089k^8. -\end{split} -\tag{18} -\] - -Every coefficient is positive. This proves that \(T_{1,n}\) decreases with \(n\). - -### 4.2 The second tail term - -If \(\alpha=0\), then \(B=0\) and \(T_{2,n}=0\), so there is nothing to prove. Suppose \(\alpha>0\). Then - -\[ -\frac{T_{2,n+1}}{T_{2,n}} -=\left(\frac{A_{n+1}}{A_n}\right)^2 - \frac{n+1}{n-2}\sqrt B. -\tag{19} -\] - -For \(n\ge101\), (15) and (4) give - -\[ -\frac{T_{2,n+1}}{T_{2,n}} -\le -\left(\frac{3350}{3333}\right)^2 -\frac{34}{33}\sqrt{\frac{17}{20}}<1. -\tag{20} -\] - -The last inequality is an exact rational check after squaring the nonnegative quantities: - -\[ -\frac{17}{20} -\left(\frac{3350}{3333}\right)^4 -\left(\frac{34}{33}\right)^2 -=\frac{123753071841250000}{134390674732795569}<1. -\tag{21} -\] - -Thus \(T_{2,n}\) also decreases with \(n\). This proves (14), and hence - -\[ -U_n(\alpha)\le U_{101}(\alpha) -\qquad(n\ge101). -\tag{22} -\] - -This discrete argument is recommended for Lean: it avoids differentiating with respect to the degree. - -## 5. Reduction at \(n=101\) - -At \(n=101\), the exponent in (13) is \(97/2\). Since \(0\le B\le1\), - -\[ -B^{97/2}=B^{48}\sqrt B\le B^{48}. -\tag{23} -\] - -Define - -\[ -\widetilde T_2(\alpha):= -\frac{A_{101}^2\,101\cdot100\cdot99}{16(3+\alpha)}B^{48}. -\tag{24} -\] - -It is enough to prove that - -\[ -\begin{split} -\widetilde U(\alpha):={}&\frac16+\frac1{4(3+\alpha)} -+\frac1{200}+\frac1{400(3+\alpha)}\\ -&+T_{1,101}(\alpha)+\widetilde T_2(\alpha)<1. -\end{split} -\tag{25} -\] - -All powers in (25) are now natural powers, so (25) is a rational inequality in \(\alpha\). - -## 6. Monotonicity in \(\alpha\) at \(n=101\) - -The first four terms of (25) decrease with \(\alpha\). Both tail terms increase with \(\alpha\) on \([0,17]\). - -Indeed, - -\[ -A_{101}=1-\frac{\alpha}{50}=\frac{50-\alpha}{50}, -\] - -\[ -c_{101} -=1-\frac{\alpha}{100}-\frac{\alpha}{2(3+\alpha)} -=\frac{300+47\alpha-\alpha^2}{100(3+\alpha)}. -\tag{26} -\] - -After differentiating \(T_{1,101}\) and clearing positive factors, the sign of the derivative is the sign of - -\[ -p_1(\alpha):=15000-2368\alpha+185\alpha^2-3\alpha^3. -\tag{27} -\] - -For \(0\le\alpha\le17\), - -\[ -p_1(\alpha) -\ge15000-2368\alpha+134\alpha^2>0. -\tag{28} -\] - -The first inequality uses \(-3\alpha^3\ge-51\alpha^2\). The second follows from the exact identity - -\[ -134\bigl(15000-2368\alpha+134\alpha^2\bigr) -=(134\alpha-1184)^2+608144>0. -\tag{29} -\] - -Thus \(T_{1,101}\) is increasing. - -For \(\alpha>0\), differentiating \(\widetilde T_2\) and clearing positive factors reduces the sign to - -\[ -p_2(\alpha):=7200-200\alpha-\alpha^2. -\tag{30} -\] - -On \([0,17]\), - -\[ -p_2(\alpha)\ge7200-3400-289=3511>0. -\tag{31} -\] - -Continuity handles \(\alpha=0\), so \(\widetilde T_2\) is increasing on the closed interval. - -For Lean, one can either use the standard theorem that a nonnegative derivative implies monotonicity on an interval, or prove the two endpoint-domination lemmas directly after rewriting the tail terms as rational functions. The derivative route produces only the cubic and quadratic polynomials above. - -## 7. Exact rational endpoint estimates - -Split into two intervals. - -### 7.1 The interval \(0\le\alpha\le16\) - -The elementary part of (25) is decreasing, while both tail terms are increasing. Hence - -\[ -\begin{split} -\widetilde U(\alpha) -\le{}&\left(\frac16+\frac1{12}+\frac1{200}+\frac1{1200}\right) -+T_{1,101}(16)+\widetilde T_2(16). -\end{split} -\tag{32} -\] - -At \(\alpha=16\), - -\[ -A_{101}=\frac{17}{25},\qquad -c_{101}=\frac{199}{475},\qquad -B=\frac{16}{19}. -\] - -Direct rational arithmetic gives - -\[ -\frac16+\frac1{12}+\frac1{200}+\frac1{1200} -=\frac{307}{1200}<\frac{32}{125}, -\tag{33} -\] - -\[ -T_{1,101}(16) -= -\frac{24(17/25)^2\,101\cdot100\cdot99} -{19\cdot97^4(199/475)^4} -<\frac{43}{200}, -\tag{34} -\] - -and - -\[ -\widetilde T_2(16) -=\frac{(17/25)^2\,101\cdot100\cdot99}{16\cdot19} - \left(\frac{16}{19}\right)^{48} -<\frac{199}{500}. -\tag{35} -\] - -The right side of (32) is therefore less than - -\[ -\frac{32}{125}+\frac{43}{200}+\frac{199}{500} -=\frac{869}{1000}<1. -\tag{36} -\] - -### 7.2 The interval \(16\le\alpha\le17\) - -Now use \(\alpha=16\) for the decreasing elementary part and \(\alpha=17\) for the increasing tail terms: - -\[ -\begin{split} -\widetilde U(\alpha) -\le{}&\left(\frac16+\frac1{76}+\frac1{200}+\frac1{7600}\right) -+T_{1,101}(17)+\widetilde T_2(17). -\end{split} -\tag{37} -\] - -At \(\alpha=17\), - -\[ -A_{101}=\frac{33}{50},\qquad -c_{101}=\frac{81}{200},\qquad -B=\frac{17}{20}. -\] - -Exact rational arithmetic gives - -\[ -\frac16+\frac1{76}+\frac1{200}+\frac1{7600} -<\frac{37}{200}, -\tag{38} -\] - -\[ -T_{1,101}(17) -=\frac{24(33/50)^2\,101\cdot100\cdot99} -{20\cdot97^4(81/200)^4} -<\frac{11}{50}, -\tag{39} -\] - -and - -\[ -\widetilde T_2(17) -=\frac{(33/50)^2\,101\cdot100\cdot99}{16\cdot20} - \left(\frac{17}{20}\right)^{48} -<\frac{279}{500}. -\tag{40} -\] - -It follows that - -\[ -\widetilde U(\alpha) -<\frac{37}{200}+\frac{11}{50}+\frac{279}{500} -=\frac{963}{1000}<1. -\tag{41} -\] - -Combining (36) and (41) proves - -\[ -\widetilde U(\alpha)<1 -\qquad(0\le\alpha\le17). -\tag{42} -\] - -By (22), (23), and (25), this implies \(U_n(\alpha)<1\) for every \(n>100\). This contradicts (10), completing the proof. - -## 8. Suggested Lean decomposition - -A convenient formalization order is: - -```lean --- Definitions -def A (n : ℕ) (α : ℝ) : ℝ := 1 - 2 * α / (n - 1) -def B (α : ℝ) : ℝ := α / (3 + α) -def c (n : ℕ) (α : ℝ) : ℝ := - 1 - α / (n - 1) - α / (2 * (3 + α)) - --- Mathematical reduction -lemma integral_tail_bound ... : - integralTerm n α ≤ - 96 / ((n - 4)^4 * c n α ^ 4) + - (1 / 4) * (B α) ^ ((n - 4 : ℝ) / 2) - --- Discrete monotonicity -lemma T1_antitone_nat ... : T1 (n + 1) α < T1 n α -lemma T2_antitone_nat ... : T2 (n + 1) α < T2 n α -lemma U_le_U101 ... : U n α ≤ U 101 α - --- Degree 101 -lemma T1_mono_alpha_101 : - MonotoneOn (T1 101) (Set.Icc 0 17) -lemma T2star_mono_alpha_101 : - MonotoneOn T2star (Set.Icc 0 17) - --- Exact endpoint checks -lemma low_alpha_bound ... : α ∈ Set.Icc 0 16 → Ustar α < 869 / 1000 -lemma high_alpha_bound ... : α ∈ Set.Icc 16 17 → Ustar α < 963 / 1000 - -theorem stat_unsatisfiable_of_gt_100 ... - (hstat : 1 ≤ statRHS n α) : False -``` - -In actual Lean definitions, cast `n` to `ℝ` before subtracting; the schematic definitions above should not be copied literally because natural-number subtraction would otherwise occur first. For example, use `((n : ℝ) - 1)`. - -The endpoint inequalities (33)--(35) and (38)--(40) should close with `norm_num` after unfolding definitions. The polynomial identities (18), (29), and the derivative reductions should close with `ring`. No floating-point value is part of the proof. - -For the real powers in Sections 3--5, it may be simplest to use `Real.rpow`. Keep the facts \(0\le B\le1\) available as named lemmas. In particular, isolate the identities - -\[ -B^{(n-3)/2}=B^{(n-4)/2}\sqrt B -\] - -and - -\[ -B^{97/2}=B^{48}\sqrt B -\] - -behind small lemmas, since the exact mathlib rewriting API for `Real.rpow` can otherwise obscure the elementary argument. - -Finally, run - -```lean -#print axioms stat_unsatisfiable_of_gt_100 -``` - -and ensure that the result depends on no project-specific axioms, `sorry`, `native_decide`, or external numerical oracle. - -## 9. Optional hybrid strategy for lowering the finite certification cutoff - -This section describes a possible replacement for the division of labor - -\[ -5\le n\le100\quad\hbox{(one certificate for every degree)}, -\qquad n\ge101\quad\hbox{(the analytic argument above)}. -\] - -It is **not part of the proved argument in Sections 1--8**. The principal -monotonicity assertion below has substantial numerical support but still needs -an analytic proof. The purpose of this section is to give a coding agent exact -targets to investigate without building the degree-97 moment expansion first. - -### 9.1 The exact right-hand side - -Retain the definitions (A_n,c_n,Q_n,B) from Section 1, and define locally - -\[ -I_n(\alpha):=\int_0^1t^3Q_n(t)^{(n-4)/2}\,dt, -\] - -\[ -P_n(\alpha):= -\frac{A_n^2n(n-1)(n-2)}{4(3+\alpha)}. -\] - -Thus the exact right-hand side of `stat` is - -\[ -R_n(\alpha):= -\frac16+\frac1{4(3+\alpha)} -+\frac1{2(n-1)}+\frac1{4(n-1)(3+\alpha)} -+P_n(\alpha)I_n(\alpha). -\tag{43} -\] - -This (R_n) is the exact expression, not the cruder (U_n) from (11). - -The key calculation is - -\[ -A_{n+1}-A_n=\frac{2\alpha}{n(n-1)}, -\qquad -c_{n+1}-c_n=\frac{\alpha}{n(n-1)}, -\] - -and hence - -\[ -\boxed{ -Q_{n+1}(t)=Q_n(t)-\frac{2\alpha}{n(n-1)}t(1-t). -} -\tag{44} -\] - -In particular, - -\[ -Q_{n+1}(t)\le Q_n(t) -\qquad(0\le t\le1). -\tag{45} -\] - -The two-step version is - -\[ -\boxed{ -Q_{n+2}(t)=Q_n(t) --\frac{4\alpha}{(n-1)(n+1)}t(1-t). -} -\tag{46} -\] - -These identities should be proved in Lean before introducing integrals. They -are just `field_simp`/`ring` identities once positivity of the natural-number -denominators has been recorded. - -The feasibility hypothesis gives - -\[ -Q_n(t)=(1-c_nt)^2+(A_n-c_n^2)t^2\ge0. -\tag{47} -\] - -There is also a useful upper bound, valid on \(0\le t\le1\): - -\[ -Q_n(t)\le (1-t)Q_n(0)+tQ_n(1) -=1-(1-B)t\le1. -\tag{48} -\] - -Here the first inequality is simply convexity of the quadratic \(Q_n\), and -\(Q_n(0)=1,\ Q_n(1)=B\). Thus all bases in (44)--(48) lie in \([0,1]\). - -Feasibility propagates in the direction in which it is needed. Indeed, put - -\[ -b:=\frac{\alpha}{2(3+\alpha)},\qquad s_n:=\frac{\alpha}{n-1}. -\] - -Then - -\[ -A_n-c_n^2=2b-b^2-s_n^2-2bs_n. -\tag{48a} -\] - -For \(\alpha\ge0\), both \(b\ge0\) and \(s_{n+1}\le s_n\). The right-hand -side of (48a) therefore increases with \(n\). Consequently - -\[ -c_n^2\le A_n\quad\Longrightarrow\quad -c_{n+1}^2\le A_{n+1}. -\tag{48b} -\] - -This lemma should be available when comparing the exact moments at different -degrees. - -### 9.2 The strongest proposed hybrid - -Floating-point reconnaissance suggests - -\[ -R_{n+1}(\alpha)\le R_n(\alpha) -\qquad -(n\ge53, 0\le\alpha\le17, c_n^2\le A_n). -\tag{49?} -\] - -Some observed maxima of the exact expression are - -\[ -\begin{array}{c|c} -n&\max R_n(\alpha)\\ \hline -50&0.84015\\ -51&0.84802\\ -52&0.85255\\ -53&0.85285\\ -54&0.84943\\ -55&0.84278\\ -60&0.77633\\ -70&0.59148\\ -97&0.29175. -\end{array} -\] - -These decimals are motivation only and must not enter the formal proof. - -If (49?) can be proved, the existing degree-53 Bernstein certificate proves -(R_{53}<1), and no degree above 53 needs a separate certificate. The odd -degree tangent bound used in the certificate need not itself be monotone: use -it only to prove (R_{53}<1), while applying (49?) to the exact real-power -expression (43). - -The following parity-preserving assertion is a slightly weaker but probably -cleaner target: - -\[ -R_{n+2}(\alpha)\le R_n(\alpha) -\qquad(n\ge53). -\tag{50?} -\] - -It would require endpoint certificates at (n=53) and (n=54), but (46) has -the advantage that the exponent rises by exactly one: - -\[ -\frac{n+2-4}{2}=\frac{n-4}{2}+1. -\] - -The elementary part of (43) already decreases with (n). Consequently it is -enough to prove - -\[ -P_{n+2}I_{n+2}\le P_nI_n. -\tag{51?} -\] - -Writing (r=(n-4)/2) and - -\[ -\varepsilon_n:=\frac{4\alpha}{(n-1)(n+1)}, -\] - -the exact integral inequality to be proved is - -\[ -\int_0^1t^3 - \bigl(Q_n(t)-\varepsilon_nt(1-t)\bigr)^{r+1}\,dt -\le -\left(\frac{A_n}{A_{n+2}}\right)^2 -\frac{(n-1)(n-2)}{(n+1)(n+2)} -\int_0^1t^3Q_n(t)^r\,dt. -\tag{52?} -\] - -Equation (52?) retains the decrement in (46). Merely replacing -(Q_{n+2}) by (Q_n) loses too much near (alpha=17), so the decrement -should not be discarded at the start of the proof. A plausible analytic -route is to apply a logarithmic or Bernoulli estimate to - -\[ -\left(1-\frac{\varepsilon_nt(1-t)}{Q_n(t)}\right)^{r+1} -\] - -on regions where (Q_n>0), treating a zero of (Q_n), if present, by -continuity. Splitting into a small-(alpha) and a large-(alpha) range is -acceptable if a uniform proof of (52?) proves awkward. - -The Lean target should initially be stated directly, rather than hidden behind -a general theory of parameter-dependent moments: - -```lean -lemma Q_succ_sub - (hn : 2 ≤ n) : - Q (n + 1) α t = - Q n α t - (2 * α / ((n : ℝ) * ((n : ℝ) - 1))) * t * (1 - t) := by - field_simp - ring - -lemma Q_add_two_sub - (hn : 2 ≤ n) : - Q (n + 2) α t = - Q n α t - - (4 * α / (((n : ℝ) - 1) * ((n : ℝ) + 1))) * t * (1 - t) := by - field_simp - ring - -lemma Q_nonneg - (hfeas : c n α ^ 2 ≤ A n α) (ht : t ∈ Set.Icc (0 : ℝ) 1) : - 0 ≤ Q n α t := by - -- Rewrite as (1-c*t)^2 + (A-c^2)*t^2. - ... - -lemma Q_le_one - (hA : 0 ≤ A n α) (hB : B α ≤ 1) - (ht : t ∈ Set.Icc (0 : ℝ) 1) : - Q n α t ≤ 1 := by - -- Use Q(t) ≤ (1-t)Q(0)+tQ(1). - ... - -lemma feasibility_mono_succ - (hn : 2 ≤ n) (hα0 : 0 ≤ α) - (hfeas : c n α ^ 2 ≤ A n α) : - c (n + 1) α ^ 2 ≤ A (n + 1) α := by - -- Use (48a) and α/(n : ℝ) ≤ α/((n : ℝ)-1). - ... - -lemma exact_tail_antitone_add_two - (hn : 53 ≤ n) (hα0 : 0 ≤ α) (hα17 : α ≤ 17) - (hfeas : c n α ^ 2 ≤ A n α) : - P (n + 2) α * I (n + 2) α ≤ P n α * I n α := by - -- This is the genuinely new analytic lemma, equivalent to (52?). - ... - -lemma exact_stat_antitone_add_two ... : - exactStatRHS (n + 2) α ≤ exactStatRHS n α := by - ... -``` - -Do not put a `sorry`-backed version of `exact_tail_antitone_add_two` on the -dependency path of the final theorem. It is useful first as an isolated -experimental target. - -### 9.3 A Lean-friendly algebraic chord majorant - -If exact monotonicity is resistant, the following intermediate majorant may be -more useful than the exponential secants suggested initially. It involves -only natural powers and polynomial integration. - -Divide ([0,1]) into the four intervals - -\[ -\left[0,\frac14\right],\quad -\left[\frac14,\frac12\right],\quad -\left[\frac12,\frac34\right],\quad -\left[\frac34,1\right]. -\] - -For (j=0,1,2,3), let (L_{j,n}) be the affine chord joining the values of -(Q_n) at (j/4) and ((j+1)/4). Convexity and (47)--(48) give - -\[ -0\le Q_n(t)\le L_{j,n}(t)\le1 -\qquad\left(\frac j4\le t\le\frac{j+1}4\right). -\tag{53} -\] - -Put - -\[ -k_n:=\left\lfloor\frac{n-4}{2}\right\rfloor -=\frac{n-4}{2}\quad\hbox{using natural-number division}. -\] - -Since the bases lie in ([0,1]), - -\[ -Q_n(t)^{(n-4)/2}\le L_{j,n}(t)^{k_n}. -\tag{54} -\] - -For even (n) this only uses (Q_n\le L_{j,n}); for odd (n), it also uses -(x^{k+1/2}\le x^k) on (0\le x\le1). Therefore - -\[ -I_n(\alpha)\le -\sum_{j=0}^3 -\int_{j/4}^{(j+1)/4}t^3L_{j,n}(t)^{k_n}\,dt. -\tag{55} -\] - -This is useful computationally because (L_{j,n}) is affine. If -(L(t)=u+vt), one may expand - -\[ -\int_a^bt^3(u+vt)^k\,dt -=\sum_{\ell=0}^k {k\choose\ell}u^{k-\ell}v^\ell - \frac{b^{\ell+4}-a^{\ell+4}}{\ell+4}. -\tag{56} -\] - -Thus a generated expression has (O(k)), rather than (O(k^2)), summands. -This directly avoids the 676-term quadratic-moment expansion that exhausted -the heartbeat limit at (n=53). A constant-size endpoint-power formula is -also available after substituting (y=u+vt), but it divides by (v^4) and -therefore requires a separate (v=0) case; (56) is safer initially. - -Floating-point tests, restricted to the feasibility region (c_n^2\le A_n), -give the following maxima for the right-hand side obtained from (55): - -\[ -\begin{array}{c|c} -n&\hbox{maximum of the four-chord upper bound}\\ \hline -6&0.652\\ -7&0.885\\ -20&0.607\\ -40&0.804\\ -50&0.901\\ -51&0.975\\ -52&0.920\\ -53&0.989\\ -54&0.924\\ -55&0.987\\ -60&0.864\\ -70&0.674\\ -97&0.340. -\end{array} -\] - -Again, these values are non-rigorous diagnostics. They suggest that the -four-chord bound may already prove `stat` impossible for every (n\ge6); -degree (5) loses too much in (54) and should retain the existing tunable -tangent argument. - -There are two ways to exploit (55): - -1. **Engineering-only improvement.** Generate a Bernstein certificate for - the four-chord upper bound at each remaining degree. This does not lower - the formal cutoff by itself, but it replaces the problematic quadratic - moment expansion by four linear-power expansions. The already successful - Bernstein and `ring` layers can remain unchanged. -2. **Genuine hybrid.** Prove that the four-chord upper bound is - parity-wise decreasing after (n=53), and certify only (n=53,54). - Formula (46) implies that every chord (L_{j,n+2}) is pointwise no larger - than (L_{j,n}), while (k_{n+2}=k_n+1). The only remaining difficulty is - to show that the resulting decay beats the increase in (P_n). This is a - simpler algebraic problem than (52?), because all four integrals have the - explicit form (56). - -A reasonable Lean decomposition is: - -```lean -def node (j : ℕ) : ℝ := (j : ℝ) / 4 - -def chordQ (n j : ℕ) (α t : ℝ) : ℝ := - (node (j + 1) - t) * 4 * Q n α (node j) + - (t - node j) * 4 * Q n α (node (j + 1)) - -lemma Q_le_chordQ - (hj : j < 4) (ht : t ∈ Set.Icc (node j) (node (j + 1))) - (hA : 0 ≤ A n α) : - Q n α t ≤ chordQ n j α t := by - -- For a quadratic, chordQ - Q is an explicit nonnegative multiple - -- of (t-node j)*(node (j+1)-t). - ... - -lemma chordQ_mem_Icc ... : - chordQ n j α t ∈ Set.Icc (0 : ℝ) 1 := by - ... - -lemma rpow_le_chord_natPow ... : - Real.rpow (Q n α t) (((n : ℝ) - 4) / 2) ≤ - chordQ n j α t ^ ((n - 4) / 2) := by - -- In actual code, parenthesize the Real.rpow exponent explicitly; - -- the displayed syntax here is schematic. - ... - -lemma integral_affine_pow ... : - ∫ t in a..b, t^3 * (u + v*t)^k = - ∑ ℓ in Finset.range (k + 1), - (Nat.choose k ℓ : ℝ) * u^(k-ℓ) * v^ℓ * - (b^(ℓ+4) - a^(ℓ+4)) / (ℓ+4) := by - ... - -lemma exact_moment_le_four_chords ... : - I n α ≤ chordMomentBound n α := by - ... -``` - -Be careful not to write `Q n α t ^ ((n : ℝ) - 4) / 2` when the intention is -`Real.rpow (Q n α t) (((n : ℝ) - 4) / 2)`: ordinary `^` and `/` would parse -differently. Keeping the exact moment and the natural-power chord moment as -different definitions will prevent this class of error. - -### 9.4 Exponential-secant fallback - -A second fallback starts from - -\[ -Q_n(t)^{(n-4)/2} -\le -\exp\left(\frac{n-4}{2}\bigl(-2c_nt+A_nt^2\bigr)\right), -\tag{57} -\] - -using (log x\le x-1). Majorize the convex quadratic exponent by affine -secants and integrate (t^3e^{ut+v}) explicitly. Floating-point tests suggest -cutoffs near - -\[ -\begin{array}{c|c} -\hbox{equal secant intervals}&\hbox{approximate cutoff}\\ \hline -2&n\ge84\\ -4&n\ge71\\ -8&n\ge67. -\end{array} -\] - -This would reduce the largest finite Bernstein degree from about (96) to -about (68) with four intervals. Nevertheless, (55) is probably preferable -in Lean because it avoids `Real.exp` and transcendental endpoint estimates. - -## 10. Recommended implementation order - -1. Keep the proved (n>100) theorem from Sections 1--8 intact as the fallback. -2. Prove (44), (46), (47), and (48) in a small file. These are reusable and - should be inexpensive. -3. Spend a bounded amount of time on the exact two-step lemma (52?). If it - succeeds, combine it with the existing (n=53,54) certificates and stop. -4. If (52?) stalls, formalize the generic four-chord majorant (53)--(56). - First regenerate (n=53) and (n=54) using this majorant and verify the - numerical generator against direct quadrature at several rational values - of (alpha). -5. Attempt parity-wise monotonicity of the four-chord bound. If this also - stalls, use the chord bound merely to generate the degrees (54,ldots,100): - it removes the present `mom` expansion bottleneck even though it does not - lower the analytic cutoff. -6. Only then consider the exponential-secant route. -7. For every generated degree, independently compare the generated rational - function with direct high-precision evaluation before committing the Lean - file. This is a diagnostic against generator errors, not part of the proof. -8. Finish with `#print axioms` on the theorem that combines the finite and - analytic ranges. It should contain no `sorryAx`, project-defined axiom, - `native_decide`, or unverified external certificate oracle. diff --git a/formalization.yaml b/formalization.yaml index 9ec8665..a8f8733 100644 --- a/formalization.yaml +++ b/formalization.yaml @@ -1,459 +1,228 @@ # yaml-language-server: $schema=https://raw.githubusercontent.com/mathlib-initiative/formalization.yaml/main/schema/formalization.schema.json -version: "v0.4" - +version: v0.4 project: - name: "Sendov's conjecture and the Phelps-Rodriguez conjecture" - description: >- - A Lean formalization of Sendov's conjecture, and of its Phelps-Rodriguez - strengthening, in full generality: if every zero of a complex polynomial p - of degree n >= 2 lies in the closed unit disk, then every zero a of p has - a critical point of p within distance 1 of it, and within distance - strictly less than 1 unless |a| = 1 and p is a scalar multiple of z^n - - a^n. The proof is by contradiction. Degrees 2 to 4 fall to an elementary - integral computation; degree 5 upward goes through two estimates on the - same integral -- a polar channel and an origin channel -- which are shown - to be incompatible, reducing the theorem to a single numerical inequality. - That inequality is discharged by exact rational Bernstein certificates, - generated outside Lean and re-verified inside it, in both of its ranges: - per-degree certificates for 5 <= n <= 100, and, for n >= 101, a single - degree-58 certificate closing the one-variable inequality that the - analytic large-degree reduction leaves behind. The boundary case |a| = 1 - is proved separately from a reciprocal identity, and it is there that the - equality classification is extracted. Nothing here is claimed to be new: - the informal proof being formalized is a digestion of Lech Mazur's proof, - which had already been formalized in Lean, so this is a second and - independently checkable machine-checked proof of Sendov's conjecture, - whose additional content is the Phelps-Rodriguez equality case. The Lean - source was written by an AI agent under the direction and review of the - author. There is no sorry outside the two deliberate holes in - Challenge.lean, no project-defined axiom, no native_decide, and no - floating point in any statement or proof. + name: Sendov's conjecture and the Phelps-Rodriguez conjecture + description: 'Local Lean development of both complete conjectures, retaining the original polynomial, + analytic and boundary arguments and replacing the old scalar endgame by a proved cubic polar envelope + and exact critical-point certificates. Degrees 2 through 5 use the elementary analytic proof. + For n >= 6, m = n - 1: the finite range 5 <= m <= 81 is fully certified, and a real-parameter + tail uses the actual m=81 base. Final statements are unchanged; no numerical bound is assumed.' authors: - - "Terence Tao" - license: "Apache-2.0" - responsible_maintainers: - - "Terence Tao" - + - Terence Tao + license: Apache-2.0 repository: role: substantive-development - classification: - arxiv: [math.CV] - msc2020: ["30C15", "30C10", "12D10"] - + arxiv: + - math.CV + msc2020: + - 30C15 + - 30C10 + - 12D10 status: - scope: >- - Complete, with no unproved step. Both conjectures in full generality: every - complex polynomial of degree at least two with all zeroes in the closed - unit disk, and every zero of it. No restriction on the degree beyond - n >= 2, on the modulus or argument of the distinguished zero, or on - multiplicities. Nothing is assumed from the literature; the two compared - theorems are proved from Mathlib alone. - # The proof development contains no sorry at all. The only two in the - # repository are the deliberate placeholders in Challenge.lean, which these - # counts exclude by convention. + scope: 'Complete, with no unproved step. Both conjectures in full generality: every complex polynomial + of degree at least two with all zeroes in the closed unit disk, and every zero of it. No restriction + on the degree beyond n >= 2, on the modulus or argument of the distinguished zero, or on multiplicities. + Nothing is assumed from the literature; the two compared theorems are proved from Mathlib alone.' sorry_count: 0 sorry_in_definitions: 0 - axioms: ["propext", "Classical.choice", "Quot.sound"] + axioms: + - propext + - Classical.choice + - Quot.sound main_results: - - declaration: "SendovConjecture.sendov" - file: "Solution.lean" - sorry_count: 0 - axioms: ["propext", "Classical.choice", "Quot.sound"] - comparator_config: "comparator.json" - literature_dependencies: [] - - declaration: "SendovConjecture.phelps_rodriguez" - file: "Solution.lean" - sorry_count: 0 - axioms: ["propext", "Classical.choice", "Quot.sound"] - comparator_config: "comparator.json" - literature_dependencies: [] - + - declaration: SendovConjecture.sendov + file: Solution.lean + sorry_count: 0 + axioms: + - propext + - Classical.choice + - Quot.sound + comparator_config: comparator.json + literature_dependencies: [] + - declaration: SendovConjecture.phelps_rodriguez + file: Solution.lean + sorry_count: 0 + axioms: + - propext + - Classical.choice + - Quot.sound + comparator_config: comparator.json + literature_dependencies: [] fidelity: - divergences: >- - Faithful to the source, and in two respects stronger than it. The blog post - argues Sendov's conjecture for n >= 5; this development proves all n >= 2, - adding degrees 2 to 4 in Sendov/Analytic/LowDegree.lean. The blog post - states the non-strict conclusion; this development additionally extracts - the Phelps-Rodriguez equality classification, strengthening the distance - bound to a strict inequality except for p = c(z^n - a^n) with |a| = 1. - Both are generalizations rather than weakenings: no hypothesis of the - source was strengthened, and no part of its statement was dropped. One - step is proved by a different route than the informal account: for - n >= 101 the write-up in docs/proof-large-degree.md splits 0 <= alpha <= 17 - at alpha = 16 and estimates the two pieces by exact rational endpoint - bounds, whereas Sendov/LargeDegree/Endgame.lean settles the whole interval - with one generated Bernstein certificate, Sendov.F_pos, which the sharp - Beta constant leaves enough margin for. The conclusion is the same. Lemma - names differ from the informal text throughout; the roadmap in README.md - records the correspondence. - -# --------------------------------------------------------------------------- -# Mathematical sources. -# -# This is a source-based formalization. The result is not new, is not claimed -# to be new, and no literature or formalization search was performed. It -# formalizes the informal proof in the blog post below, which is itself a -# digestion and simplification of Lech Mazur's proof -- so the mathematics here -# descends from that work rather than reaching the theorem independently. See -# related_formalizations. -# -# NOTE TO REVIEWER: the blog post carries the full literature account. The -# entries below record the sources this formalization actually used to choose, -# state and justify the result. -# --------------------------------------------------------------------------- + divergences: The original final theorem types and polynomial semantics are unchanged. The local + variant uses Senjian An's stronger rational polar envelope and 7/7/4-degree critical-polynomial + bounds in place of the old R/packed/moment route. All analytic bridges, derivative signs, interval + endpoints, finite budgets and the infinite tail are proved in Lean. The raw scalar at alpha zero + is not silently redefined by regularization. The degree-five case now uses the existing elementary + low-degree theorem. Obsolete intermediate interfaces are retired, not maintained as a second proof + system. sources: - - title: "A digestion of the proof of Sendov's conjecture" - authors: ["Terence Tao"] - type: "web post" - id: "https://terrytao.wordpress.com/2026/08/12/a-digestion-of-the-proof-of-sendovs-conjecture/" - relationship: formalizes - note: >- - The informal proof that this development formalizes, including the - treatment of Rubinstein's boundary theorem that it derives from the same - arguments. The formalization follows its - architecture closely and extends it from n >= 5 to n >= 2. It is a - published blog post rather than an archived preprint; that URL is the - most stable identifier that exists for it. - - - title: "Research Problems in Function Theory (statement of Sendov's conjecture)" - authors: ["W. K. Hayman"] - type: "book" - id: "https://zbmath.org/3254142" - relationship: background - note: >- - Where the conjecture, due to Blagovest Sendov, was first recorded as a - research problem. Used to fix the standard statement that Challenge.lean - is checked against. - - - title: "Some properties of extremal polynomials for the Ilieff conjecture" - authors: ["D. Phelps", "R. S. Rodriguez"] - type: "article" - id: "https://zbmath.org/3386011" - relationship: formalizes - note: >- - The source of the strengthened conjecture with the equality - classification, formalized here as SendovConjecture.phelps_rodriguez. - Two sources carry "formalizes", and they supply different things: the - blog post supplies the proof that this development follows, and this - paper supplies the statement of the stronger of the two theorems proved. - The submitted statement does not extend the conjecture recorded here -- - it is proved exactly as stated -- which is why this is "formalizes" - rather than "adapts". - - - title: "On a problem of Ilyeff" - authors: ["Z. Rubinstein"] - type: "article" - location: "Pacific J. Math. 26 (1968), 159-161" - relationship: background - note: >- - The boundary case |a| = 1, with the same equality classification. This - development proves that case from scratch in Sendov/Boundary.lean, from - p''(1)/p'(1), following the blog post rather than transcribing - Rubinstein's paper, on which it does not depend. The argument used is not - new either: see the Tang-Zhang entry below. - - - title: "Sharp Schoenberg type inequalities and the de Bruin-Sharma problem" - authors: ["Quanyu Tang", "Teng Zhang"] - type: "preprint" - id: "arXiv:2508.10341" - location: "Equation (5.1) and Remark 5.1" - relationship: background - note: >- - Equation (5.1) and Remark 5.1 of this preprint are the two ingredients of - the boundary case |a| = 1 in Sendov/Boundary.lean: their identity - sum_k 1/w_k = 2 sum_j 1/z_j is Sendov.boundary_reciprocal after moving - the distinguished zero from 0 to 1, and their Re(1/z_j) <= -1/2 is - Sendov.half_le_re_inv_one_sub. Remark 5.1 combines them to give the a = 1 - case of Sendov's conjecture in the non-strict form min_k |w_k| <= 1. This - development reaches the same two ingredients from the blog post rather - than from this preprint, and goes one step further, extracting equality - term by term to obtain the classification p = c(z^n - a^n); that step - recovers Rubinstein's 1968 theorem and is likewise not claimed as new. - The correspondence was checked against the preprint after the - formalization was complete. - - - title: "On a conjecture of Ilieff" - authors: ["D. A. Brannan"] - type: "article" - location: "Proc. Cambridge Philos. Soc. 64 (1968), 83-85" - relationship: background - note: >- - The cubic case, which falls out of the low-degree branch here. No - comparison with Brannan's argument was made. - - - title: "On Ilyeff's conjecture" - authors: ["A. Meir", "A. Sharma"] - type: "article" - location: "Pacific J. Math. 31 (1969), 459-467" - relationship: background - note: >- - Degree five, and the reciprocal identities of which the boundary identity - used here is the k = nu = 1 specialization. - - - title: "Sendov's conjecture for sufficiently high degree polynomials" - authors: ["Terence Tao"] - type: "article" - id: "https://zbmath.org/7681950" - relationship: background - note: >- - The earlier high-degree result. Its use of analytic continuation is what - the digested argument replaces by an explicit finite check, which is why - this development can be fully formalized. - - - title: "Sendov conjecture proof (ProofAtlas manuscript)" - authors: ["Lech Mazur"] - type: "other" - id: "https://www.proofatlas.ai/papers/sendov-conjecture/" - relationship: adapts - note: >- - The first complete proof of Sendov's conjecture for all n >= 2, produced - with an AI tool. The blog post above is a digestion and simplification of - this argument, so the mathematics formalized here descends from it; the - extension to the Phelps-Rodriguez form is what "adapts" records. The - adaptation reached this repository through the blog post; this manuscript - was not worked from directly. The corresponding Lean work is recorded - under related_formalizations. - +- title: A digestion of the proof of Sendov's conjecture + authors: + - Terence Tao + type: web post + id: https://terrytao.wordpress.com/2026/08/12/a-digestion-of-the-proof-of-sendovs-conjecture/ + relationship: formalizes + note: Source of the retained polynomial, analytic and boundary reduction. The scalar endgame in + this local variant is replaced by the separately listed distillation method; the full conjecture + statements are preserved. +- title: Research Problems in Function Theory (statement of Sendov's conjecture) + authors: + - W. K. Hayman + type: book + id: https://zbmath.org/3254142 + relationship: background + note: Where the conjecture, due to Blagovest Sendov, was first recorded as a research problem. Used + to fix the standard statement that Challenge.lean is checked against. +- title: Some properties of extremal polynomials for the Ilieff conjecture + authors: + - D. Phelps + - R. S. Rodriguez + type: article + id: https://zbmath.org/3386011 + relationship: formalizes + note: 'The source of the strengthened conjecture with the equality classification, formalized here + as SendovConjecture.phelps_rodriguez. Two sources carry "formalizes", and they supply different + things: the blog post supplies the proof that this development follows, and this paper supplies + the statement of the stronger of the two theorems proved. The submitted statement does not extend + the conjecture recorded here -- it is proved exactly as stated -- which is why this is "formalizes" + rather than "adapts".' +- title: On a problem of Ilyeff + authors: + - Z. Rubinstein + type: article + location: Pacific J. Math. 26 (1968), 159-161 + relationship: background + note: 'The boundary case |a| = 1, with the same equality classification. This development proves + that case from scratch in Sendov/Boundary.lean, from p''''(1)/p''(1), following the blog post + rather than transcribing Rubinstein''s paper, on which it does not depend. The argument used is + not new either: see the Tang-Zhang entry below.' +- title: Sharp Schoenberg type inequalities and the de Bruin-Sharma problem + authors: + - Quanyu Tang + - Teng Zhang + type: preprint + id: arXiv:2508.10341 + location: Equation (5.1) and Remark 5.1 + relationship: background + note: 'Equation (5.1) and Remark 5.1 of this preprint are the two ingredients of the boundary case + |a| = 1 in Sendov/Boundary.lean: their identity sum_k 1/w_k = 2 sum_j 1/z_j is Sendov.boundary_reciprocal + after moving the distinguished zero from 0 to 1, and their Re(1/z_j) <= -1/2 is Sendov.half_le_re_inv_one_sub. + Remark 5.1 combines them to give the a = 1 case of Sendov''s conjecture in the non-strict form + min_k |w_k| <= 1. This development reaches the same two ingredients from the blog post rather + than from this preprint, and goes one step further, extracting equality term by term to obtain + the classification p = c(z^n - a^n); that step recovers Rubinstein''s 1968 theorem and is likewise + not claimed as new. The correspondence was checked against the preprint after the formalization + was complete.' +- title: On a conjecture of Ilieff + authors: + - D. A. Brannan + type: article + location: Proc. Cambridge Philos. Soc. 64 (1968), 83-85 + relationship: background + note: The cubic case, which falls out of the low-degree branch here. No comparison with Brannan's + argument was made. +- title: On Ilyeff's conjecture + authors: + - A. Meir + - A. Sharma + type: article + location: Pacific J. Math. 31 (1969), 459-467 + relationship: background + note: Degree five, and the reciprocal identities of which the boundary identity used here is the + k = nu = 1 specialization. +- title: Sendov's conjecture for sufficiently high degree polynomials + authors: + - Terence Tao + type: article + id: https://zbmath.org/7681950 + relationship: background + note: The earlier high-degree result. Its use of analytic continuation is what the digested argument + replaces by an explicit finite check, which is why this development can be fully formalized. +- title: Sendov conjecture proof (ProofAtlas manuscript) + authors: + - Lech Mazur + type: other + id: https://www.proofatlas.ai/papers/sendov-conjecture/ + relationship: adapts + note: The first complete proof of Sendov's conjecture for all n >= 2, produced with an AI tool. + The blog post above is a digestion and simplification of this argument, so the mathematics formalized + here descends from it; the extension to the Phelps-Rodriguez form is what "adapts" records. The + adaptation reached this repository through the blog post; this manuscript was not worked from + directly. The corresponding Lean work is recorded under related_formalizations. +- title: Proof Distillation for Sendov's Conjecture + authors: + - Senjian An + type: other + id: https://github.com/SJanPerth/Sendov-Proof-Distillation/tree/e8ae601491ec171ab4f7f8456113dd6a047aa85d + relationship: adapts + note: Cubic rational envelope, two-chord estimate, complete low-degree critical expressions, original + finite budgets and real-parameter tail. The source paper is CC BY 4.0. Python verification is + not a trusted premise; the adapted method is proved in Lean. related_formalizations: - - id: "https://www.proofatlas.ai/formalizations/sendov-conjecture/" - relationship: builds-on - note: >- - The earlier Lean formalization of Sendov's conjecture for all n >= 2, by - Lech Mazur, reported there as 1160 files and 92816 lines with a single - main theorem. Priority for the first machine-checked proof of Sendov's - conjecture belongs to that work, and this repository is the second - formalization of it. "builds-on" rather than "independent": no code is - shared and that development was never read, but the informal proof - formalized here is a digestion of its argument, so the mathematics - descends from it. What is additional here is the Phelps-Rodriguez - equality classification, which that formalization does not state; as far - as we are aware this is its first formalization, but that is an - observation about the one earlier formalization we know of and not the - result of a search. The two developments are separately checkable - evidence for the same theorem; no comparison of their internal arguments - has been carried out. - -# --------------------------------------------------------------------------- -# How this was produced. -# --------------------------------------------------------------------------- +- id: https://www.proofatlas.ai/formalizations/sendov-conjecture/ + relationship: builds-on + note: 'The earlier Lean formalization of Sendov''s conjecture for all n >= 2, by Lech Mazur, reported + there as 1160 files and 92816 lines with a single main theorem. Priority for the first machine-checked + proof of Sendov''s conjecture belongs to that work, and this repository is the second formalization + of it. "builds-on" rather than "independent": no code is shared and that development was never + read, but the informal proof formalized here is a digestion of its argument, so the mathematics + descends from it. What is additional here is the Phelps-Rodriguez equality classification, which + that formalization does not state; as far as we are aware this is its first formalization, but + that is an observation about the one earlier formalization we know of and not the result of a + search. The two developments are separately checkable evidence for the same theorem; no comparison + of their internal arguments has been carried out.' automation: methods: - - method: agent - models: ["Claude Opus 5 (Anthropic)"] - framework: "Claude Code" - role: >- - Wrote essentially all of the Lean source in this repository, working - interactively in Claude Code under the direction and review of the - author across many sessions: choosing the Lean formulations, finding - and repairing proofs, and designing the certificate machinery. The - author set the targets, supplied the informal proof and the staged - plans in docs/, made the mathematical decisions, and reviewed the - output as it was produced. - # AI-assisted, upstream of this repository. - - method: other - models: [] - role: >- - The informal proof being formalized was itself digested from earlier - work with heavy AI assistance, as the blog post records; the models - used there are unspecified. That work is a mathematical source here, - not part of this repository. - # Script generation. - - method: other - framework: "Python scripts in scripts/" - role: >- - Every Bernstein certificate in the development is emitted by the Python - scripts in scripts/ (about 1300 lines): the per-degree certificates for - 5 <= n <= 100 in Sendov/FiniteRange/, and the degree-58 endgame - certificate Sendov.F_pos in Sendov/LargeDegree/Endgame.lean, which - scripts/gen_endgame.py generates. Those - scripts are outside the trusted base: they write Lean source that Lean - re-verifies from scratch, so a bug in them causes a build failure, not - an unsound theorem. scripts/mutation_test.sh checks that the - certificates are load-bearing. - + - method: agent + framework: Hermes Agent + role: Local implementation, independent agent source reviews, and executable verification of this + adaptation. This is not an assertion of new upstream-maintainer or human peer review. + - method: other + framework: Python exact arithmetic + role: scripts/gen_distillation.py generates every selected finite case and the aggregate into + a fresh output root. scripts/gen_sinh.py reproduces the retained global hyperbolic proof source. + Generator output is rechecked by Lean; compiler and kernel acceptance are separate. review: status: self-assessed - reviewers: - - "Terence Tao" - notes: >- - The author directed and reviewed the development as it was produced. No - external or independent review has been performed, and no mathematician - other than the author has read the Lean source. Every step is checked by - Lean, and scripts/audit.sh checks the trust conditions below. - -# --------------------------------------------------------------------------- -# Limitations, stated so that a reader can calibrate the claim. -# --------------------------------------------------------------------------- + notes: The local variant has independent agent source review and Lean kernel replay, with exact + final-theorem type comparison and actual dependency audits. These are not claims of independent + human mathematical review or endorsement by the upstream authors. known_gaps: [] - limitations: - - >- - No novelty is claimed anywhere, and no literature or formalization search - was performed. Sendov's conjecture was proved, and formalized in Lean, - before this work, and the informal proof formalized here is a digestion of - that proof; see related_formalizations. Where the documentation notes a - difference from earlier work it is describing this development, not - claiming priority. In particular the boundary argument in - Sendov/Boundary.lean is not new: its two ingredients are equation (5.1) and - Remark 5.1 of the Tang-Zhang preprint listed above, and the equality case it - additionally extracts is Rubinstein's 1968 theorem. - - >- - The proof depends on a computational component, in both degree ranges. - Every degree from 5 upward reaches a numerical inequality that is - discharged by Bernstein certificates generated outside Lean and re-verified - inside it. For 5 <= n <= 100 these are the per-degree certificates in - Sendov/FiniteRange/. For n >= 101 an analytic argument first removes the - degree, reducing the claim to Ut(alpha) < 1 on [0,17] in a single variable; - that residual inequality is then closed by Sendov.F_pos in - Sendov/LargeDegree/Endgame.lean, a generated degree-58 Bernstein - certificate, so the large-degree branch is not purely analytic either. - This is about half the Lean source by line count. It uses no - interval arithmetic and no floating point: the certificates are exact - rationals, and scripts/audit.sh fails if Float appears in any statement or - proof. - - >- - The compared theorems depend on propext, Classical.choice and Quot.sound, - and on nothing else. There is no sorry outside the two deliberate holes in - Challenge.lean, no project-defined axiom, no native_decide, no unsafe, and - no floating point in any statement or proof. - - >- - Challenge.lean states the result but does not prove it; that is the - Comparator convention, and Solution.lean supplies the proofs. - -# --------------------------------------------------------------------------- -# How the cited statements correspond to Lean declarations. -# -# This is the source-to-formal map, not a lemma index: it lists the statements -# that the `sources` entries above actually contribute, and where each is -# discharged. README.md carries the full roadmap of intermediate lemmas. -# --------------------------------------------------------------------------- +- The two deliberate placeholders in Challenge.lean are specifications, not imported proof premises. +- Independent kernel replay is over the fixed imported environment; it is not a fresh re-proof of + Mathlib. +- Timing evidence belongs to its stated source trees and resource configuration, not a claim of exclusive-machine + performance. alignment: - # The proof development lives in the `Sendov` namespace. The two compared - # declarations live in `SendovConjecture`, which is what comparator.json - # names and what Challenge.lean states. - namespace: "Sendov" + namespace: Sendov statements: - - source: "Sendov's conjecture, as stated in Hayman, Research Problems in Function Theory" - lean: "SendovConjecture.sendov" - module: "Challenge (statement), Solution (proof)" - status: proved - note: >- - The statement of record, compared by Comparator. Challenge.lean states - it with a sorry; Solution.lean discharges that from Sendov.sendov. - Stated for p.natDegree, with the zero-containment hypothesis given as - a condition on p.roots. - - - source: "Sendov's conjecture (development-internal form)" - lean: "Sendov.sendov" - module: "Sendov.Conjecture" - status: proved - note: >- - The same theorem with the degree carried as an explicit n, which is the - form the rest of the development uses. - - - source: "The Phelps-Rodriguez conjecture: the distance is strictly less than 1 unless p = c(z^n - a^n) with |a| = 1" - lean: "SendovConjecture.phelps_rodriguez" - module: "Challenge (statement), Solution (proof)" - status: proved - note: >- - The second compared declaration, discharged from - Sendov.phelps_rodriguez. This is the strengthening; Sendov's conjecture - follows from it by weakening the strict inequality, which is how - Sendov.sendov is derived. - - - source: "Rubinstein, On a problem of Ilyeff: the boundary case |a| = 1 with its equality classification" - lean: "Sendov.rubinstein_one" - module: "Sendov.Boundary" - status: proved-independently - note: >- - Proved from scratch, at the normalized point a = 1; the general - |a| = 1 case follows by the rotation in Sendov.Conjecture. Rubinstein's - paper was not transcribed and is not depended on, and the argument used - is not new -- see the Tang-Zhang rows below. The closed-disk corollary - is Sendov.sendov_boundary_one. - - - source: "Tang-Zhang, equation (5.1): sum_k 1/w_k = 2 sum_j 1/z_j" - lean: "Sendov.boundary_reciprocal" - module: "Sendov.Boundary" - status: proved-independently - note: >- - Stated in division-free form over two multisets, from the two readings - of p'(1) and p''(1); it becomes (5.1) after moving the distinguished - zero from 0 to 1. Reached from the blog post, not from the preprint. - - - source: "Tang-Zhang, Remark 5.1: Re(1/z_j) <= -1/2 for |z_j| <= 1" - lean: "Sendov.half_le_re_inv_one_sub" - module: "Sendov.Boundary" - status: proved-independently - note: >- - Stated as a bound on Re(1/(1 - z)) for ‖z‖ <= 1, z != 1. Together with - the row above this gives the non-strict a = 1 case, as Remark 5.1 does; - Sendov.all_q_eq_one is the extra step that pins the equality case and - so recovers Rubinstein's classification. - - - source: "Meir-Sharma, On Ilyeff's conjecture: the reciprocal identities" - lean: "Sendov.boundary_reciprocal" - module: "Sendov.Boundary" - status: specialized - note: >- - The identity used here is the k = nu = 1 case of theirs. Only that - specialization is formalized; the general family is not. - - - source: "Brannan, On a conjecture of Ilieff: the cubic case" - lean: "Sendov.low_degree_contradiction" - module: "Sendov.Analytic.LowDegree" - status: subsumed - note: >- - Degree three is not treated separately: it falls inside the elementary - branch, which contradicts the scalar bound 1 <= J_(n-1)(a) directly. - No comparison with Brannan's argument was made. - - - source: "Tao, A digestion of the proof of Sendov's conjecture: the polar channel" - lean: "Sendov.one_le_integral_Ppolar" - module: "Sendov.Analytic.Polar" - status: proved - note: "The AM-GM relaxation of the main integral inequality to a scalar inequality in x alone." - - - source: "Tao, A digestion of the proof of Sendov's conjecture: the origin channel" - lean: "Sendov.origin_exact" - module: "Sendov.Analytic.OriginExact" - status: proved - note: >- - The second estimate on the same integral. Its final step is where - n >= 5 is used, and it is the only place that hypothesis is needed. - - - source: "Tao, A digestion of the proof of Sendov's conjecture: the two channels are incompatible" - lean: "Sendov.polar_origin_incompatible" - module: "Sendov.Reduction.Main" - status: proved - note: >- - The contradiction that closes the main branch, by way of - Sendov.alpha_le_seventeen and the numerical claim Sendov.stat_lt_one. - - - source: "Tao, A digestion of the proof of Sendov's conjecture: the residual numerical inequality" - lean: "Sendov.stat_lt_one" - module: "Sendov.Main" - status: proved-by-computation - note: >- - Split at the degree, but generated exact rational Bernstein - certificates close both halves. Sendov.finite_range_le_100 - (Sendov.FiniteRange.Cover) discharges 5 <= n <= 100 from the per-degree - certificates in Sendov/FiniteRange/. Sendov.large_degree - (Sendov.LargeDegree.Endgame) handles n >= 101 by an analytic argument - that removes the degree, leaving Ut(alpha) < 1 on [0,17] in one - variable; that is closed by Sendov.F_pos, a generated degree-58 - certificate, so this half is not purely analytic. See - docs/finite-range.md and docs/proof-large-degree.md. - - - source: "Tao, A digestion of the proof of Sendov's conjecture: the low degrees" - lean: "Sendov.low_degree_contradiction" - module: "Sendov.Analytic.LowDegree" - status: extends-source - note: >- - The blog post argues n >= 5; this row is the extension down to n >= 2, - by an elementary integral computation done once at m = 4. No - certificates and no Real.rpow are used here. The lemma is stated for - 2 <= n <= 5, but the recorded proof invokes it only for n <= 4: - Sendov.sendov_interior splits at n < 5, so degree 5 goes through - the two-channel branch and its certificates like every larger degree. + - source: Sendov's conjecture + lean: SendovConjecture.sendov + module: Solution + status: proved + note: Complete original evaluation-based statement for every polynomial of degree at least two + and every zero. + - source: Phelps-Rodriguez equality classification + lean: SendovConjecture.phelps_rodriguez + module: Solution + status: proved + note: Complete original strict-distance alternative or the unit-circle nonzero scalar-multiple + form. + - source: Original polar/origin reduction with a cubic envelope + lean: Sendov.cubicScalar_constraints_of_polar_origin + module: Sendov.Reduction.CubicScalar + status: proved + note: Derives all scalar-domain conditions and the lower bound from the original geometric inputs. + - source: Complete finite critical-point certificate range + lean: Sendov.distillFinite_scalar + module: Sendov.Common.DistillationFinite + status: proved + note: All integer m from 5 through 81; entire alpha domain, not samples. + - source: Real-parameter infinite tail + lean: Sendov.distillScalar_lt_two_thirds + module: Sendov.LargeDegree.DistillationTailBound + status: proved + note: All real m >= 81 and positive alpha <= 17; the actual m=81 base is discharged. diff --git a/scripts/GENERATORS.md b/scripts/GENERATORS.md new file mode 100644 index 0000000..8e0de2e --- /dev/null +++ b/scripts/GENERATORS.md @@ -0,0 +1,69 @@ +# Active proof generators + +Use Python 3.10+; only `gen_sinh.py` needs SymPy (tested with 1.13.1). +`gen_distillation.py`, its exact-data validator and bundler use only the standard +library. Run these commands from the repository root: + +```sh +python3 -m pip install 'sympy==1.13.1' # if not already installed +python3 -B scripts/gen_sinh.py --output /tmp/sendov-Sinh.lean +python3 -B scripts/gen_distillation.py --output /tmp/sendov-distillation-new +python3 -B -m unittest discover -s tests -v +``` + +The finite output directory must be new or empty. The generator emits all +`m = 5,...,81`, components `0,1,2`, with the unchanged table brackets/budgets. +Rows 5–80 are grouped in batches of eight (last batch 77–80); Row81 is separate +because it supplies the infinite-tail base. The output contains exactly these +11 row modules and `Sendov/Common/DistillationFinite.lean`. No second per-row +source tree is published. `bundle_rows.py` is the source-packaging helper, not a +certificate checker or an alternative proof route. + +`--output` is required for distillation; there is no subset/mutation CLI or +workspace restriction. Paths can be absolute or relative to the caller's cwd. +`--table /path/to/table.json` explicitly overrides the default project-local +`data/paper_certificate_table.json`; the same exact schema, ordered coverage, +bracket, sign, squared-envelope and budget checks apply. Editing that input +changes a proposed certificate, not the proof trust base. Keep the shipped table +unchanged to reproduce the accepted source. + +All data validation and exact row rendering finish before staging. The complete +grouped snapshot is then staged beside the target and committed by one directory +rename. Nonempty targets, regular files and symlinks are rejected; handled +render/write/rename failures leave prior target contents intact and clean private +staging. This is an atomic publication guarantee on a local filesystem with a +trusted parent directory, **not** a power-loss durability guarantee or protection +against malicious concurrent same-user namespace changes. Interrupted runs may +leave private `.distillation-*` staging; no partially published Lean tree is used. + +Sinh's optional default is `Sendov/Common/Sinh.lean` relative to the script's +repository, not the caller's cwd. Its existing atomic single-file writer replaces +that file only after complete rendering. Imports perform no generation; `-B` +suppresses Python's own bytecode cache writes. Explicit outputs are recommended. + +**Python生成≠Lean验收** — exact Python checks and byte-identical regeneration are +not Lean elaboration or kernel replay. After integrating the generated modules +into the selected proof and building it with the pinned project toolchain, run: + +```sh +lake env lean scripts/axioms.lean +sh scripts/audit.sh +``` + +The two public conjectures and the finite/tail seams are queried, not retired +route names. The shell audit fails if the Lean query itself fails. Full Lean +build/kernel replay and the two headline type contracts remain separate gates. + +## Attribution and licenses + +- Sinh, its analytic tail and the retained proof templates derive from Terence + Tao's Sendov development (Apache-2.0); original notices are preserved. +- Mathematical table/route: Senjian An, *Proof Distillation for Sendov's + Conjecture*, [fixed revision e8ae601491ec171ab4f7f8456113dd6a047aa85d](https://github.com/SJanPerth/Sendov-Proof-Distillation/tree/e8ae601491ec171ab4f7f8456113dd6a047aa85d). + The table is unchanged; see `../data/README.md` for CC BY 4.0 attribution. +- The rational envelope checks in `distillation_data.py` adapt that revision's + explicitly MIT-licensed `verification/verify_paper.py`; the original Senjian An + copyright/permission notice is retained in `LICENSE-DISTILLATION-MIT.txt`. + This is licensed adaptation, not copying code from an unlicensed donor. +- New renderer, schema/CLI integration, bundling and test changes are Apache-2.0; + see the project `LICENSE` and the retained `LICENSE-APACHE-2.0.txt` copy. diff --git a/scripts/LICENSE-APACHE-2.0.txt b/scripts/LICENSE-APACHE-2.0.txt new file mode 100644 index 0000000..44c57c5 --- /dev/null +++ b/scripts/LICENSE-APACHE-2.0.txt @@ -0,0 +1,202 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright 2026 Terence Tao + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + diff --git a/scripts/LICENSE-DISTILLATION-MIT.txt b/scripts/LICENSE-DISTILLATION-MIT.txt new file mode 100644 index 0000000..9862d99 --- /dev/null +++ b/scripts/LICENSE-DISTILLATION-MIT.txt @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2026 Senjian An + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/scripts/audit.sh b/scripts/audit.sh index 7032b68..68bc6cf 100644 --- a/scripts/audit.sh +++ b/scripts/audit.sh @@ -1,5 +1,5 @@ #!/bin/sh -# Trust audit for the Sendov development. See docs/design.md §8 for the policy. +# Trust audit for the Sendov development. See docs/design.md for the policy. # # 1. no forbidden tokens anywhere in Sendov/ or in Solution.lean # 2. Challenge.lean holds exactly the two deliberate holes it is supposed to @@ -13,8 +13,15 @@ rc=0 echo "=== 1. forbidden tokens ===" # Challenge.lean is excluded here and audited separately in step 2: it is the Palomar # statement of record, and Comparator requires its declarations to be deliberate holes. -hits=$(grep -rnE '\bsorry\b|^ *axiom |native_decide|\bunsafe \b|\bpartial def\b|Float' \ +hits=$(grep -rnE '\bsorry\b|^ *axiom |native_decide|\bunsafe \b|Float' \ Sendov/ Solution.lean --include=*.lean | grep -vE ':[0-9]+: *--' | grep -vE '`sorry`') +# These pre-existing helpers manipulate Lean syntax only. Their generated proofs +# are checked by Lean; arbitrary mathematical partial definitions remain forbidden. +partial_hits=$(grep -rnE '\bpartial def\b' Sendov/ Solution.lean --include=*.lean | grep -vE \ +'^(Sendov/Common/BernsteinRing\.lean:[0-9]+:private partial def flatten \(e : Expr\) \(op : Name\) : Array Expr :=|Sendov/Common/BernsteinCert\.lean:[0-9]+:private partial def factors \(e : Expr\) : Array Expr :=|Sendov/Common/BernsteinCert\.lean:[0-9]+:private partial def reify \(e x y : Expr\) : TacticM \(TSyntax `term × Nat\) := do)$') +if [ -n "$partial_hits" ]; then + hits="${hits}${partial_hits}" +fi if [ -n "$hits" ]; then echo "$hits" rc=1 @@ -44,7 +51,12 @@ grep -rn "set_option max" Sendov/ --include=*.lean \ echo echo "=== 4. axioms of the top-level results ===" -out=$(lake env lean scripts/axioms.lean 2>&1) +if out=$(lake env lean scripts/axioms.lean 2>&1); then + : +else + echo "!! Lean axiom query failed" + rc=1 +fi echo "$out" if echo "$out" | grep -qE "sorryAx|ofReduceBool|ofReduceNat"; then echo "!! non-standard axiom present" diff --git a/scripts/axioms.lean b/scripts/axioms.lean index 369e9ed..251e0ab 100644 --- a/scripts/axioms.lean +++ b/scripts/axioms.lean @@ -1,29 +1,44 @@ -import Sendov.Reduction.Main -import Sendov.Interior -import Sendov.Boundary -import Sendov.Conjecture +import Lean +import Solution +import Sendov.Common.DistillationFinite +import Sendov.LargeDegree.DistillationTailBound /-! -Run with `lake env lean scripts/axioms.lean`. This file is deliberately *not* part of the -library: it exists so that the axiom check is an explicit, separately-run audit step rather -than something buried in a build log. +Run after building the selected proof with `lake env lean scripts/axioms.lean`. +This separate audit checks the two exact public conjecture statements and their +active finite/tail seams, not retired intermediate names. -Every result below must depend on `propext`, `Classical.choice` and `Quot.sound` only. In -particular `sorryAx` must not appear, and neither must `Lean.ofReduceBool` (which is what -`native_decide` introduces). +Only `propext`, `Classical.choice` and `Quot.sound` are permitted. In particular, +`sorryAx` and `Lean.ofReduceBool` are not permitted. These assertions do not +replace the complete build, kernel replay or theorem-type contract check. -/ -#print axioms Sendov.stat_lt_one -#print axioms Sendov.stat_contradiction -#print axioms Sendov.finite_range -#print axioms Sendov.finite_range_le_100 -#print axioms Sendov.large_degree -#print axioms Sendov.polar_origin_incompatible -#print axioms Sendov.alpha_le_seventeen -#print axioms Sendov.sendov_interior -#print axioms Sendov.sendov_center -#print axioms Sendov.sendov_interior_real -#print axioms Sendov.rubinstein_one -#print axioms Sendov.sendov_boundary_one -#print axioms Sendov.phelps_rodriguez -#print axioms Sendov.sendov +namespace SendovAudit +open Lean Elab Command + +-- collectAxioms is transitive, including imported declarations. Check existence +-- first: collecting an unknown name alone can silently return an empty array. +syntax "#sendov_axioms " ident : command +elab_rules : command + | `(#sendov_axioms $decl:ident) => do + let env := (← getEnv).setExporting false + let name := decl.getId + unless (env.find? name).isSome do + throwError "missing audit declaration {name}" + let axioms ← withEnv env <| Lean.collectAxioms name + let allowed := #[``propext, ``Classical.choice, ``Quot.sound] + unless axioms.all allowed.contains do + throwError "unexpected mathematical premise in {name}: {axioms}" + logInfo m!"SENDOV_AXIOMS {(Json.mkObj [("name", toJson name.toString), + ("axioms", toJson (axioms.map Name.toString))]).compress}" + +end SendovAudit + +#sendov_axioms SendovConjecture.sendov +#sendov_axioms SendovConjecture.phelps_rodriguez +#sendov_axioms Sendov.distillFinite_components +#sendov_axioms Sendov.distillFinite_scalar +#sendov_axioms Sendov.distillFiniteTailBase +#sendov_axioms Sendov.distillComponents_lt_two_thirds +#sendov_axioms Sendov.distillScalar_lt_two_thirds +#sendov_axioms Sendov.polar_origin_incompatible diff --git a/scripts/bundle_rows.py b/scripts/bundle_rows.py new file mode 100644 index 0000000..9e919cf --- /dev/null +++ b/scripts/bundle_rows.py @@ -0,0 +1,74 @@ +"""Bundle this generator's self-contained RowN modules, preserving each body. + +This is source packaging, not a certificate checker or a general Lean parser. +Row81 remains separate because it is the independently used infinite-tail base. +""" +from pathlib import Path +import argparse +import json + +ROWS = tuple(range(5, 82)) +PREFIX = 'Sendov.DistillationFinite.' + + +def split_row(text): + lines = text.splitlines(keepends=True) + imports = [line.rstrip('\r\n') for line in lines if line.startswith('import ')] + if not imports or any(PREFIX in line for line in imports): + raise ValueError('rows must import shared helpers, not one another') + return imports, ''.join(line for line in lines if not line.startswith('import ')) + + +def bundle(source, output, size=8): + source, output = Path(source), Path(output) + if not isinstance(size, int) or size < 1: + raise ValueError('positive rows-per-module required') + rows_dir = source / 'Sendov/DistillationFinite' + expected = {f'Row{m}.lean' for m in ROWS} + if {p.name for p in rows_dir.glob('Row*.lean')} != expected: + raise ValueError('rows must be exactly Row5 through Row81') + rows = {m: split_row((rows_dir / f'Row{m}.lean').read_text()) for m in ROWS} + aggregate = (source / 'Sendov/Common/DistillationFinite.lean').read_text() + row_imports = [line for line in aggregate.splitlines() if line.startswith(f'import {PREFIX}Row')] + if row_imports != [f'import {PREFIX}Row{m}' for m in ROWS]: + raise ValueError('aggregate must import each row exactly once in original order') + groups = [list(range(start, min(start + size, 81))) for start in range(5, 81, size)] + [[81]] + rendered, manifest = {}, [] + for group in groups: + name = 'Row81' if group == [81] else f'Rows{group[0]}_{group[-1]}' + path = f'Sendov/DistillationFinite/{name}.lean' + if group == [81]: + text = (rows_dir / 'Row81.lean').read_text() + else: + imports = list(dict.fromkeys(line for m in group for line in rows[m][0])) + text = '\n'.join(imports) + '\n\n' + text += '\n'.join('section\n' + rows[m][1] + '\nend\n' for m in group) + rendered[path] = text + manifest.append({'module': PREFIX + name, 'path': path, 'rows': group}) + replacements = ''.join(f"import {group['module']}\n" for group in manifest) + new_aggregate, inserted = [], False + for line in aggregate.splitlines(keepends=True): + if line.startswith(f'import {PREFIX}Row'): + if not inserted: + new_aggregate.append(replacements); inserted = True + else: + new_aggregate.append(line) + rendered['Sendov/Common/DistillationFinite.lean'] = ''.join(new_aggregate) + # Complete validation/render first, and never overwrite an existing projection. + output.mkdir(parents=True, exist_ok=False) + for path, text in rendered.items(): + target = output / path; target.parent.mkdir(parents=True, exist_ok=True) + target.write_text(text) + return {'groups': manifest, 'candidate_paths': sorted(rendered), 'rows': list(ROWS), + 'source_lines': sum(len(text.splitlines()) for text in rendered.values()), + 'source_bytes': sum(len(text.encode()) for text in rendered.values()), + 'scope': 'Source bodies preserved; complete compiler/kernel acceptance still required.'} + + +if __name__ == '__main__': + parser = argparse.ArgumentParser(description=__doc__) + parser.add_argument('--source', required=True, type=Path) + parser.add_argument('--output', required=True, type=Path) + parser.add_argument('--rows-per-module', type=int, default=8) + args = parser.parse_args() + print(json.dumps(bundle(args.source, args.output, args.rows_per_module), indent=2)) diff --git a/scripts/distillation_data.py b/scripts/distillation_data.py new file mode 100644 index 0000000..98c1720 --- /dev/null +++ b/scripts/distillation_data.py @@ -0,0 +1,112 @@ +"""Exact input validation for the selected finite certificate renderer. + +The rational envelope checks adapt Senjian An's MIT-licensed verify_paper.py, +SJanPerth/Sendov-Proof-Distillation, e8ae601491ec171ab4f7f8456113dd6a047aa85d. +Copyright (c) 2026 Senjian An; see LICENSE-DISTILLATION-MIT.txt. +Schema/coverage validation and integration changes: Apache-2.0. +No sampled arithmetic and no Python assertions authorize generation. +""" +from fractions import Fraction as F +import json +from pathlib import Path + + +def require(condition, message): + if not condition: + raise ValueError(message) + + +def object_pairs(pairs): + result = {} + for key, value in pairs: + require(key not in result, f'duplicate JSON key: {key}') + result[key] = value + return result + + +def reject_constant(value): + raise ValueError(f'non-finite JSON constant: {value}') + + +def fields(obj, keys, context): + require(type(obj) is dict and set(obj) == set(keys.split()), + f'{context}: wrong object fields') + + +def rational(value): + require(type(value) is str, 'rational must be a string') + try: + result = F(value) + except (ValueError, ZeroDivisionError) as error: + raise ValueError(f'invalid rational: {value}') from error + require(str(result) == value, f'noncanonical rational: {value}') + return result + + +def eta(a): + u = a / (a + 3) + return u - u**3 / 30 + + +def candidate_squared(m, j, lo, hi): + """The paper's exact squared bracket envelope, not a floating root check.""" + ratio = F(1, 3) if lo == 0 else eta(lo) / lo + kappa = F(m*m - 1, 4*m) * ratio * (m - 2*lo)**2 + node = F(4, 25) + F(3, 5)*eta(hi) + F(12, 25*m)*hi + require(0 < node < 1, 'invalid chord node') + if j == 0: + chord = 96*F(3, 5)**4 / ((m-1)*(m+1)*(m+3)*(m+5)) + return (kappa*chord / (1-node)**4)**2 + if j == 1: + return (F(259, 3125)*kappa)**2 * node**(m-3) + return (F(421, 3125)*kappa)**2 * eta(hi)**(m-3) + + +def load_table(path, coefficients): + rows = json.loads(Path(path).read_text(encoding='utf-8'), + object_pairs_hook=object_pairs, parse_constant=reject_constant) + require(type(rows) is list and len(rows) == 77, 'exactly 77 rows required') + for m, row in zip(range(5, 82), rows): + fields(row, 'm e components total', f'row {m}') + require(type(row['m']) is int and row['m'] == m, + 'rows must be m=5..81 exactly once in order') + e = rational(row['e']) + require(e == F(1, 4) + F(7, 12*m), f'E budget mismatch at {m}') + parts = row['components'] + require(type(parts) is list and len(parts) == 3, 'exactly three components required') + total = e + for j, part in enumerate(parts): + fields(part, 'index k lo hi u sq sign_lo sign_hi', f'{m}, component {j}') + require(type(part['index']) is int and part['index'] == j, + 'components must be 0..2 exactly once in order') + require(type(part['u']) is int and part['u'] > 0, 'positive integer budget required') + require(type(part['k']) is str, 'bracket classification must be a string') + lo, hi = rational(part['lo']), rational(part['hi']) + require(0 <= lo <= hi <= min(F(17), F(m, 2)), 'bracket outside domain') + boundary = m >= (49, 47, 57)[j] + if boundary: + require(part['k'] == 'B' and lo == hi == 17, 'boundary classification mismatch') + else: + k = rational(part['k']) + require(k.denominator == 1 and lo == k/4 and hi == (k+1)/4, + 'quarter bracket mismatch') + p = coefficients(m, j) + left = sum(c * lo**i for i, c in enumerate(p)) + right = sum(c * hi**i for i, c in enumerate(p)) + require(left == rational(part['sign_lo']) and right == rational(part['sign_hi']), + 'stored sign-value mismatch') + if boundary: + require(left > 0 if j == 0 else left < 0, 'boundary sign mismatch') + else: + require((left > 0 and right < 0) if j == 0 else (left < 0 and right > 0), + 'isolating sign mismatch') + square = candidate_squared(m, j, lo, hi) + require(square == rational(part['sq']), 'stored squared envelope mismatch') + budget = F(part['u'], 1000) + require(square < budget**2, 'component budget does not bound envelope') + total += budget + require(total == rational(row['total']), 'total budget mismatch') + require(total < F(199, 200), 'finite bound failed') + if m == 81: + require(total < F(2, 3), 'tail base bound failed') + return rows diff --git a/scripts/emit_batch.py b/scripts/emit_batch.py deleted file mode 100644 index f26ba78..0000000 --- a/scripts/emit_batch.py +++ /dev/null @@ -1,151 +0,0 @@ -import sys, io, pickle, sympy as sp -sys.set_int_max_str_digits(50000000) -r = pickle.load(open(sys.argv[1],"rb")) -n0,n1,k,M0,M1 = r['n0'],r['n1'],r['k'],r['M0'],r['M1'] -L,beta,tau,Nmom,mlen = r['L'],r['beta'],r['tau'],r['Nmom'],r['mlen'] -cf,G,d,const,p = r['cf'],r['G'],r['d'],r['const'],r['p'] -feas, cnum = r['feas'], r['cnum'] -up, uq = r['up'], r['uq'] -Us = f"{up} / {uq}" if uq != 1 else f"{up}" -LIN = f"({up} - {uq} * α)" if uq != 1 else f"({up} - α)" -# for a singleton batch `M_lo` and `M_hi` are the same rewrite, so listing both fails -MRW = "M_lo, M_hi" if n0 != n1 else "M_lo" -LIN0 = LIN[1:-1] # `hu` states the bare linear form, without the wrapping parentheses -def poly(cs, var="α"): - ts=[] - for i,v in enumerate(cs): - v=sp.Integer(v) - if v==0: continue - s=("+ " if v>0 else "- ")+str(abs(v)) - if i==1: s+=f" * {var}" - elif i>1: s+=f" * {var} ^ {i}" - ts.append(s) - t=" ".join(ts); return t[2:] if t.startswith("+ ") else "-"+t[2:] -P = poly(cf); FE = poly(feas); CN = poly(cnum) -bern = " + ".join((f"{G[0]} * {LIN} ^ {d}" if j==0 else - f"{G[d]} * α ^ {d}" if j==d else - f"{G[j]} * α ^ {j} * {LIN} ^ {d-j}") for j in range(d+1)) -src = f'''/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.FiniteRange.Batch -import Sendov.FiniteRange.PackBridge -import Sendov.Common.BernsteinCert -import Sendov.FiniteRange.BatchCertificate -import Sendov.FiniteRange.PackedMomentCertificate -import Sendov.Common.BernsteinRing - -/-! -# The batch {n0} to {n1} - -`Sendov.R_le_batch` bounds every `R n α` for `{n0} ≤ n ≤ {n1}` by the elementary part and -moment at `n₀ = {n0}` together with the prefactor at `n₁ = {n1}`, so one moment and one -certificate serve all {n1-n0+1} degrees. The certificate has degree {d}, set by `n₀` rather -than `n₁`. - -Feasibility at `n₀` is proved rather than assumed: for `n ≥ 36` it follows from -`0 ≤ α ≤ 17`, since `A - c²` increases with `n`. This matters because feasibility propagates -*upward* in `n`, so it could not be inherited from the hypothesis at `n`. --/ - --- Generated numerals cannot be wrapped, so the long-line linter is off in this file. -set_option linter.style.longLine false -set_option maxRecDepth 4000000 - -namespace Sendov - -namespace B{n0}_{n1} - -lemma M_lo : M {n0} = {M0} := by norm_num [M] - -lemma M_hi : M {n1} = {M1} := by norm_num [M] - -lemma A_lo (α : ℝ) : A {n0} α = 1 - 2 * α / {M0} := by rw [A, M]; push_cast; ring - -lemma A_hi (α : ℝ) : A {n1} α = 1 - 2 * α / {M1} := by rw [A, M]; push_cast; ring - -lemma c_lo {{α : ℝ}} (hα : 0 ≤ α) : c {n0} α = ({CN}) / ({2*M0} * (3 + α)) := by - have h3 : (3 : ℝ) + α ≠ 0 := (three_add_pos hα).ne' - rw [c, M] - push_cast - field_simp - ring - -/-- `c` is nonnegative at `n₀` on the batch's `α`-range. This replaces feasibility at `n₀`, -which for `n₀ < 36` does not follow from `α ≤ 17`. -/ -lemma c_lo_nonneg {{α : ℝ}} (hα : 0 ≤ α) (hU : α ≤ {Us}) : 0 ≤ c {n0} α := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - rw [c_lo hα] - apply div_nonneg _ (by positivity) - nlinarith [mul_nonneg hα (sub_nonneg.2 hU), sq_nonneg α] - -def Lc : ℤ := {L} - -def betac : ℤ := {beta} - -def tauc : ℤ := {tau} - -/-- The moment numerator at `n₀ = {n0}`, `k = {k}`. -/ -def Nmomc : List ℤ := - {Nmom} - -theorem pev_Nmomc (α : ℝ) : - pev Nmomc α = pev (wsum Lc 0 (qrow (gg0 {n0}) (gg1 {n0}) (gg2 {n0}) {k})) α := by - refine pev_moment_eq_of_packed_bounds {n0} {k} Lc betac tauc Nmomc - (by norm_num [Lc]) (by norm_num [betac]) (by norm_num [tauc]) ?_ ?_ - (by decide) (by decide) (by rfl) α - · norm_num [gg0, gg1, gg2, l1, betac, tauc] - · norm_num [gg0, gg1, gg2, l1, Lc, betac] - -theorem integral_lo (α : ℝ) (hα : 0 ≤ α) : - (∫ t in (0 : ℝ)..1, t ^ 3 * Q {n0} α t ^ {k}) - = pev Nmomc α / ((Lc : ℝ) * (2 * M {n0} * (3 + α)) ^ {k}) := - integral_moment_packed {n0} {k} (by norm_num) α hα Lc (by norm_num [Lc]) Nmomc - (by decide) (pev_Nmomc α) - -set_option maxHeartbeats 2000000 in --- the degree-{d} Bernstein identity exceeds the default budget -/-- The certificate: `17 ^ {d} * P α` is a positive combination of `αʲ (17-α)^({d}-j)`. -/ -lemma P_pos {{α : ℝ}} (hα : 0 ≤ α) (hα' : α ≤ {Us}) : - 0 < {P} := by - have hu : (0 : ℝ) ≤ {LIN0} := by linarith - have hid : ({up} : ℝ) ^ {d} * ({P}) = {bern} := by - bernstein_ring α {LIN} - -- The certificate checks coefficient signs. The last summand is positive for α > 0; - -- at α = 0 the first summand is positive. The identity above checks every coefficient. - bernstein_cert α {LIN} using hid - -set_option maxHeartbeats 2000000 in --- clearing denominators across the batch identity exceeds the default budget -/-- **The batch `{n0} ≤ n ≤ {n1}`.** -/ -theorem finite_range {{n : ℕ}} (h0 : {n0} ≤ n) (h1 : n ≤ {n1}) {{α : ℝ}} - (hα : 0 ≤ α) (_hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hMn := alpha_le_half_M (n := n) (by omega) hfeas - -- feasibility caps α at M n / 2, which for a low batch is sharper than the ambient α ≤ 17 - have hUn : α ≤ {Us} := by - have hcast : ((n : ℕ) : ℝ) ≤ ({n1} : ℝ) := by exact_mod_cast h1 - have hMle : M n ≤ ({n1} : ℝ) - 1 := by simp only [M]; linarith - linarith [_hα'] - have hid : (1 : ℝ) / 6 + 1 / (4 * (3 + α)) + 1 / (2 * {M0}) + 1 / (4 * {M0} * (3 + α)) - + (1 - 2 * α / {M1}) ^ 2 * {n1} * {M1} * ({n1} - 2) / (4 * (3 + α)) - * (pev Nmomc α / ((Lc : ℝ) * (2 * {M0} * (3 + α)) ^ {k})) - = 1 - ({P}) / ({const} * (3 + α) ^ {p}) := by - simp only [pev, Lc, Nmomc] - push_cast - field_simp - ring - exact R_lt_one_of_batch_certificate (n₀ := {n0}) (n₁ := {n1}) (k := {k}) - (by norm_num) h0 h1 hα (c_lo_nonneg hα hUn) hfeas - (by norm_num) M_lo M_hi (by simpa only [M_lo] using integral_lo α hα) - hid (P_pos hα hUn) (by positivity) - -end B{n0}_{n1} - -end Sendov -''' -out = f"Degree{n0}_{n1}.lean" -io.open(out,"w",encoding="utf-8",newline="\n").write(src) -print("written", out, len(src), "bytes") diff --git a/scripts/gen_all_batches.py b/scripts/gen_all_batches.py deleted file mode 100644 index 70965a5..0000000 --- a/scripts/gen_all_batches.py +++ /dev/null @@ -1,21 +0,0 @@ -import sys, subprocess, pickle, io, os -PLAN = [(6,6),(8,9),(10,11),(12,13),(14,15),(16,18),(18,20),(20,22),(22,24),(24,26), - (26,27),(28,29),(30,31),(32,33),(34,35),(36,37),(38,39),(40,41),(42,43),(44,45), - (46,47),(48,49),(50,51),(52,53),(54,55),(56,58),(58,60),(60,63),(64,69),(70,79),(80,100)] -REPO = r"c:/Users/teort/Github/sendov/Sendov/FiniteRange" -import mk_batch -ok, fail = [], [] -for (n0, n1) in PLAN: - try: - r = mk_batch.build(n0, n1) - pickle.dump(r, open(f"batch_{n0}_{n1}.pkl", "wb")) - subprocess.run([sys.executable, "emit_batch.py", f"batch_{n0}_{n1}.pkl"], check=True) - src = f"Degree{n0}_{n1}.lean" - io.open(os.path.join(REPO, src), "w", encoding="utf-8", newline="\n").write( - io.open(src, encoding="utf-8").read()) - ok.append((n0, n1)) - except Exception as e: - print(f" [{n0},{n1}] FAILED: {type(e).__name__}: {e}") - fail.append((n0, n1)) - sys.stdout.flush() -print(f"\ngenerated {len(ok)} / {len(PLAN)}; failures: {fail if fail else 'none'}") diff --git a/scripts/gen_batch.py b/scripts/gen_batch.py deleted file mode 100644 index 129e93e..0000000 --- a/scripts/gen_batch.py +++ /dev/null @@ -1,95 +0,0 @@ -"""Generate a Lean file proving R n a < 1 for a batch n0 <= n <= n1 (n0 even).""" -import sys, io, sympy as sp -from math import lcm, comb -sys.set_int_max_str_digits(50000000) - -def build(n0, n1): - assert n0 % 2 == 0, "n0 must be even so the moment has an integer exponent" - k = (n0-4)//2; M0, M1 = n0-1, n1-1; a = sp.symbols('alpha') - # ---- packed moment data at n0 ---- - g0=[6*M0,2*M0]; g1=[-12*M0,12-2*M0,4]; g2=[6*M0,2*M0-12,-4] - L1n = sum(abs(x) for x in g0+g1+g2); L = lcm(*range(4,2*k+5)); mlen = 1+3*k - beta = 2*(L*L1n**k)+1; tau = 2*(L1n**k * beta**mlen)+1 - def padd(p,q): - r=[0]*max(len(p),len(q)) - for i,x in enumerate(p): r[i]+=x - for i,x in enumerate(q): r[i]+=x - return r - def pmul(p,q): - if not p or not q: return [] - r=[0]*(len(p)+len(q)-1) - for i,x in enumerate(p): - if x: - for j,y in enumerate(q): r[i+j]+=x*y - return r - row=[[1]] - for _ in range(k): - new=[[] for _ in range(len(row)+2)] - for i,e in enumerate(row): - for s,g in enumerate((g0,g1,g2)): new[i+s]=padd(new[i+s],pmul(g,e)) - row=new - Nmom=[] - for j,e in enumerate(row): Nmom=padd(Nmom,[(L//(j+4))*x for x in e]) - def pevZ(p,b): - s=0 - for x in reversed(p): s=x+b*s - return s - Gv = pevZ(g0,beta)+pevZ(g1,beta)*tau+pevZ(g2,beta)*tau**2 - X = Gv**k - blocks=[]; y=X - for _ in range(2*k+1): - r=y%tau; d=r if 2*r0 for g in G), f"Bernstein certificate not all-positive on [0,{Uf}]" - def ev(cs,x): - s=sp.Integer(0) - for c in reversed(cs): s=c+x*s - return s - for v in [sp.Rational(1,2), sp.Integer(7), sp.Integer(17)]: - assert sp.simplify((1-bound).subs(a,v) - ev(cf,v)/(const*(3+v)**p)) == 0 - # ---- feasibility quartic at n0 ---- - c0s = 1 - a/M0 - a/(2*(3+a)); A0s = 1 - 2*a/M0 - feas = sp.Poly(sp.expand(sp.cancel((A0s - c0s**2)*(2*M0*(3+a))**2)), a) - cnum = sp.Poly(sp.expand(sp.cancel(c0s*(2*M0*(3+a)))), a) - print(f"[{n0},{n1}] k={k} degP={d} pole={p} Nmom={len(Nmom)} beta={beta.bit_length()}b " - f"tau={tau.bit_length()}b G^k={X.bit_length()}b ALL CHECKS PASS") - return dict(n0=n0,n1=n1,k=k,M0=M0,M1=M1,L=L,beta=beta,tau=tau,Nmom=Nmom,mlen=mlen, - cf=cf,G=G,d=d,const=const,p=p,feas=feas.all_coeffs()[::-1], - cnum=cnum.all_coeffs()[::-1],up=up,uq=uq) -if __name__ == "__main__": - import pickle - r = build(int(sys.argv[1]), int(sys.argv[2])) - pickle.dump(r, open(f"batch_{sys.argv[1]}_{sys.argv[2]}.pkl","wb")) diff --git a/scripts/gen_cover.py b/scripts/gen_cover.py deleted file mode 100644 index 621e981..0000000 --- a/scripts/gen_cover.py +++ /dev/null @@ -1,96 +0,0 @@ -import io -PLAN = [(6,6),(8,9),(10,11),(12,13),(14,15),(16,18),(18,20),(20,22),(22,24),(24,26), - (26,27),(28,29),(30,31),(32,33),(34,35),(36,37),(38,39),(40,41),(42,43),(44,45), - (46,47),(48,49),(50,51),(52,53),(54,55),(56,58),(58,60),(60,63),(64,69),(70,79), - (80,100)] - -# Each degree 5..100 must be covered; 5 and 7 come from the single-degree files. -cov = {5: "five", 7: "seven"} -for n0, n1 in PLAN: - for n in range(n0, n1 + 1): - cov.setdefault(n, (n0, n1)) -missing = [n for n in range(5, 101) if n not in cov] -assert not missing, f"degrees not covered: {missing}" - -# Walk 5..100 and collect maximal runs handled by the same source. -runs, cur = [], None -for n in range(5, 101): - src = cov[n] - if cur and cur[0] == src: - cur[2] = n - else: - cur = [src, n, n] - runs.append(cur) - -L = [] -for i, (src, lo, hi) in enumerate(runs): - last = (i == len(runs) - 1) - L.append(f" -- degrees {lo}..{hi}") - ind = " " if last else " · " - cont = " " if last else " " - if not last: - L.append(f" rcases Nat.lt_or_ge n {hi + 1} with h | h") - if src in ("five", "seven"): - L.append(f"{ind}obtain rfl : n = {lo} := by omega") - L.append(f"{cont}exact finite_range_{src} hα hfeas") - else: - n0, n1 = src - L.append(f"{ind}exact B{n0}_{n1}.finite_range (by omega) (by omega) hα hα' hfeas") - -head = """/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -""" -imports = ("import Sendov.FiniteRange.Degree5\nimport Sendov.FiniteRange.Degree7\n" - + "".join(f"import Sendov.FiniteRange.Degree{a}_{b}\n" for a, b in PLAN)) -doc = """ -/-! -# The finite range `5 ≤ n ≤ 100` - -This file does nothing but assemble the individual degree files and the degree *batches* into -a single statement. Its only content is the case split, so it is also where the claim "every -degree in the range is covered" gets checked: the branches below are generated from the batch -plan, and the file would not compile if a degree were skipped. - -Degrees `5` and `7` are handled one at a time (`Sendov.finite_range_five`, -`Sendov.finite_range_seven`); every other degree is covered by a batch `B n₀ n₁`, whose proof -is a single Bernstein certificate valid simultaneously for all `n₀ ≤ n ≤ n₁`. --/ - -namespace Sendov - -variable {α : ℝ} - -/-- **The finite range.** Every degree from `5` to `100` inclusive. -/ -theorem finite_range_le_100 {n : ℕ} (h0 : 5 ≤ n) (h1 : n ≤ 100) - (hα : 0 ≤ α) (hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by -""" -tail = ''' - -/-- **The finite-range claim.** The right-hand side of equation `stat` of the blog post is -strictly less than `1` on the range of degrees and of `α` left open there, that is, on -`5 ≤ n ≤ 97`, `0 ≤ α ≤ 17`, subject to the feasibility constraint `c ^ 2 ≤ A`. - -This is the original challenge statement. It is a special case of `finite_range_le_100`, -which covers three more degrees: the finite certification was pushed from `97` to `100` so -that it meets the large-degree argument of `Sendov.LargeDegree` with room to spare. -/ -theorem finite_range (n : ℕ) (α : ℝ) (hn : 5 ≤ n) (hn' : n ≤ 97) - (hα : 0 ≤ α) (hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) : - R n α < 1 := - finite_range_le_100 hn (by omega) hα hα' hfeas - -/-- Equation `stat` of the blog post is infeasible on the range -`5 ≤ n ≤ 97`, `0 ≤ α ≤ 17`, `c ^ 2 ≤ A`. This is the form in which the claim is used. -/ -theorem finite_range_contradiction (n : ℕ) (α : ℝ) (hn : 5 ≤ n) (hn' : n ≤ 97) - (hα : 0 ≤ α) (hα' : α ≤ 17) (hfeas : c n α ^ 2 ≤ A n α) (hstat : 1 ≤ R n α) : - False := - absurd hstat (not_le.2 (finite_range n α hn hn' hα hα' hfeas)) - -end Sendov -''' -src = head + imports + doc + "\n".join(L) + tail -io.open(r"c:/Users/teort/Github/sendov/Sendov/FiniteRange/Cover.lean", "w", - encoding="utf-8", newline="\n").write(src) -print(f"{len(runs)} branches covering degrees 5..100") diff --git a/scripts/gen_degree.py b/scripts/gen_degree.py deleted file mode 100644 index 21de418..0000000 --- a/scripts/gen_degree.py +++ /dev/null @@ -1,226 +0,0 @@ -#!/usr/bin/env python3 -"""Certificate generator for the Sendov finite-range claim. - -UNTRUSTED. Nothing this script emits is believed by the Lean development on its -own authority: Lean re-derives the polynomial `P n` from `Sendov.mom` and checks the -Bernstein identity with `ring`, so a wrong coefficient makes the build fail rather -than the theorem weaken. The checks below exist to catch generator bugs early, not -to license trusting the output. - - python gen_degree.py --check validate P n against numerical quadrature - python gen_degree.py emit Degree.lean - -A worked example of why `--check` matters: an early version of `Ppoly` dropped the -factor `2^l` in `(-2c)^l` (the `2^l` cancels against the denominator of `c`, so the -denominator is `M^i`, not `(2M)^l M^(i-l)`). The resulting `P` was wrong by a sign -and scale, yet still admitted a Bernstein representation -- with every coefficient -negative. Positivity of the certificate is therefore NOT evidence that `P` is right; -only agreement with an independent evaluation of `1 - R` is. -""" -from fractions import Fraction as F -from math import comb, lcm - -def mul(p,q): - r=[F(0)]*(len(p)+len(q)-1) - for i,x in enumerate(p): - if x: - for j,y in enumerate(q): r[i+j]+=x*y - return r -def add(*ps): - n=max(len(p) for p in ps); r=[F(0)]*n - for p in ps: - for i,x in enumerate(p): r[i]+=x - return r -def smul(s,p): return [s*x for x in p] -def powp(p,k): - r=[F(1)] - for _ in range(k): r=mul(r,p) - return r -def Ppoly(n): - # n = 5 is excluded: this uses the odd-degree tangent bound with w = 1, which - # overshoots in degree five (it gives an upper bound of 1.0625 at alpha = 0 and - # so proves nothing). Degree five is done separately in Lean with w = 1/3; see - # `Sendov.FiniteRange.Degree5`. - assert n >= 6, "degree 5 needs w = 1/3; see Sendov/FiniteRange/Degree5.lean" - M=n-1; Nc=[F(6*M),F(M-6),F(-2)]; NA=[F(M),F(-2)]; sh=[F(3),F(1)] - def mom(k): - N=[F(0)] - for i in range(k+1): - for l in range(i+1): - coef=F(comb(k,i)*comb(i,l)*(-1)**l, 2*i-l+4)*F(1, M**i) - N=add(N, smul(coef, mul(powp(Nc,l), mul(powp(NA,i-l), powp(sh,k-l))))) - return N - if n%2==0: k=(n-4)//2; N=mom(k); K=k - else: k=(n-5)//2; N=add(smul(F(1,2),mom(k+1)), smul(F(1,2),mul(mom(k),sh))); K=k+1 - b1=F(1,6)+F(1,2*M); b0=F(1,4)+F(1,4*M) - num=add(powp(sh,K+1), smul(F(-1), mul(add(smul(b1,sh),[b0]), powp(sh,K))), - smul(F(-n*M*(n-2),4*M*M), mul(powp(NA,2), N))) - L=lcm(*[c.denominator for c in num]) - ints=[int(c*L) for c in num] - while len(ints)>1 and ints[-1]==0: ints.pop() - return ints, L, K+1 - - -def _check(): - """Validate P n against numerical quadrature of 1 - R n alpha.""" - import numpy as np - X, W = np.polynomial.legendre.leggauss(600); T = 0.5*(X+1); W = 0.5*W - def Rnum(n, al): - M = n-1.0; A = 1-2*al/M; c = 1-al/M-al/(2*(3+al)); Q = 1-2*c*T+A*T*T - if n % 2 == 0: J = np.sum(W*T**3*np.maximum(Q,0)**((n-4)//2)) - else: - k = (n-5)//2; J = (np.sum(W*T**3*Q**(k+1))+np.sum(W*T**3*Q**k))/2 - return 1/6+1/(4*(3+al))+1/(2*M)+1/(4*M*(3+al))+A**2*n*M*(n-2)/(4*(3+al))*J - def ev(cs, x): - s = F(0) - for i in range(len(cs)-1, -1, -1): s = s*x+cs[i] - return s - bad = 0 - for n in [6,7,8,20,53,97]: - cf, L, pole = Ppoly(n) - for al in [0, 5, 17]: - if al > (n-1)/2: continue - mine = float(ev(cf, F(al))/L)/(3+al)**pole - ref = 1-Rnum(n, al) - ok = abs(mine-ref) < 1e-6 - bad += not ok - print(f" n={n:>3} a={al:>2}: P/D={mine:>10.6f} 1-R={ref:>10.6f} {'ok' if ok else 'MISMATCH'}") - d = len(cf)-1 - U = F(17) if F(17) <= F(n-1,2) else F(n-1,2); p, q = U.numerator, U.denominator - G = [sum(cf[i]*q**(j-i)*comb(d-i,j-i)*p**i for i in range(j+1)) for j in range(d+1)] - print(f" n={n:>3} deg={d:>3} Bernstein on [0,{U}] all positive: {all(g>0 for g in G)}") - raise SystemExit(1 if bad else 0) - -if __name__ == "__main__": - import sys - if "--check" in sys.argv: _check() - n = int(sys.argv[1]); M = n-1 -cf, L, pole = Ppoly(n); d = len(cf)-1 -U = F(17) if F(17) <= F(M,2) else F(M,2); p,q = U.numerator, U.denominator -G = [sum(cf[i]*q**(j-i)*comb(d-i,j-i)*p**i for i in range(j+1)) for j in range(d+1)] -assert all(g>0 for g in G) -even = (n%2==0); k = (n-4)//2 if even else (n-5)//2 -NAMES={5:"five",6:"six",7:"seven",8:"eight",20:"twenty"} -nm = NAMES.get(n, "d%d"%n) -def wrap(body, indent, width=96): - out=[]; cur=indent - for w in body.split(" "): - if len(cur)+1+len(w) > width and cur.strip(): - out.append(cur.rstrip()); cur = indent+" "+w - else: cur = (cur+" "+w) if cur.strip() else cur+w - out.append(cur.rstrip()); return "\n".join(out).lstrip() -def poly(cs, var="α"): - ts=[] - for i,v in enumerate(cs): - if v==0: continue - s=("+ " if v>0 else "- ")+str(abs(v)) - if i==1: s+=" * "+var - elif i>1: s+=f" * {var} ^ {i}" - ts.append(s) - r=" ".join(ts); return r[2:] if r.startswith("+ ") else "-"+r[2:] -P = poly(cf) -lin = f"({p} - {q} * α)" if q!=1 else f"({p} - α)" -def bterm(j): - if j==0: return f"{G[0]} * {lin} ^ {d}" - if j==d: return f"{G[d]} * α ^ {d}" - return f"{G[j]} * α ^ {j} * {lin} ^ {d-j}" -bern = " + ".join(bterm(j) for j in range(d+1)) -haves = "\n".join(f" have h{j} : (0:ℝ) ≤ {bterm(j)} :=\n" - f" mul_nonneg (mul_nonneg (by norm_num) (pow_nonneg hα {j})) (pow_nonneg hu {d-j})" - if 0 try rw [mom] - simp only [Finset.sum_range_succ, Finset.sum_range_zero, Nat.choose, Nat.cast_one] - norm_num - field_simp - ring - rw [hid] at hR - have hP := P_{nm}_pos hα hle - have hq : 0 < ({wrap(P, " ")}) - / ({L} * (3 + α) ^ {pole}) := div_pos hP (by positivity) - linarith - -end Sendov -''' -io.open(f"Degree{n}.lean","w",encoding="utf-8").write(src) -print(f"n={n} deg={d} bytes={len(src)} maxGammaDigits={max(len(str(g)) for g in G)}") diff --git a/scripts/gen_distillation.py b/scripts/gen_distillation.py new file mode 100644 index 0000000..8e20827 --- /dev/null +++ b/scripts/gen_distillation.py @@ -0,0 +1,222 @@ +#!/usr/bin/env python3 +"""Suggest small exact critical-polynomial certificates; Lean checks every identity. + +No Python truth enters Lean. Output needs subsequent strict pinned-Lean compilation. +Mathematical data: Senjian An, SJanPerth/Sendov-Proof-Distillation, +e8ae601491ec171ab4f7f8456113dd6a047aa85d, paper CC BY 4.0 / upstream code MIT. +New generator and Lean template: Apache-2.0 as the Sendov baseline. +Explicit fresh/empty output directory required; no production default. +""" +import argparse +import json +import textwrap +import os +import tempfile +from bundle_rows import bundle +from distillation_data import load_table +from fractions import Fraction as F +from math import comb, gcd, lcm +from pathlib import Path + +TABLE = Path(__file__).resolve().parents[1] / 'data/paper_certificate_table.json' + +def coefficients(m, j): + """Ascending powers, independently checked against the actual Lean definitions.""" + if j == 0: + return [43740*m*(13*m-36), 972*(743*m*m-3330*m-2160), + 486*(665*m*m-4752*m-9360), 1134*(49*m*m-566*m-3600), + 12*(103*m*m-1323*m-161676), -377*m*m+22092*m-514512, + 2*(1363*m-36072), -4176] + if j == 1: + return [-14580*m*(15*m*m-17*m-204), -648*(450*m**3-934*m*m-11655*m-1620), + -216*(660*m**3-2164*m*m-37581*m-6480), + -216*(140*m**3-609*m*m-21974*m-2610), + -3*(783*m**3-m*m-538848*m+6048), + -2*(2914*m*m-158961*m+34992), -4*(174*m*m-8279*m+4392), 1392*(m-1)] + if j == 2: + return [-810*m*(m-3), -540*(m*m-7*m-3), -3*(27*m*m-565*m-720), + 2*(110*m+453), 116] + raise ValueError('component must be 0, 1 or 2') + +def certificate(p, a, b): + """scale*p(x) = sum cs[i]*(x-a)^i*(b-x)^(n-i), exact rationals.""" + if not p: + raise ValueError('empty polynomial data') + if not a < b: + raise ValueError('nonempty interval required') + n = len(p)-1 + h = b-a + q = [sum(F(p[i])*comb(i,k)*a**(i-k)*h**k for i in range(k,n+1)) for k in range(n+1)] + cs = [sum(q[k]*F(comb(j,k),comb(n,k)) for k in range(j+1))*comb(n,j)/h**n for j in range(n+1)] + scale = lcm(*(c.denominator for c in cs)) + ns = [int(c*scale) for c in cs] + common = gcd(scale, gcd(*ns)) if len(ns)>1 else gcd(scale, ns[0]) + return scale//common, [c//common for c in ns] + +def sign_cover(p, a, b): + """One certificate for the entire flank; fail rather than grow a subdivision.""" + scale, cs = certificate(p,a,b) + if min(cs) >= 0 and cs[0] > 0 and cs[-1] > 0: + return [(a,b,scale,cs)] + raise ValueError(f'no single strictly positive certificate on [{a},{b}]') + +def validate_cover(intervals, a, b): + if not intervals or intervals[0][0] != a or intervals[-1][1] != b: + raise ValueError('missing sign region at boundary') + cursor = a + for lo,hi in intervals: + if lo != cursor or not lo < hi: + raise ValueError('sign coverage has gap, overlap or reversal') + cursor = hi + +def rat(x): + x = F(x) + return str(x.numerator) if x.denominator == 1 else f'({x.numerator} / {x.denominator})' + +def signed(j,m,side): + positive = (j == 0) == (side == 'left') + return ('' if positive else '-')+f'distillCritical{j} {m} x' + +def sign_source(m,j,side,a,b): + name=f'sign_{j}_{side}' + target=signed(j,m,side) + if a == b: + return f'''private lemma {name} (x : ℝ) (hx : x ∈ Set.Ioo {rat(a)} {rat(b)}) : + 0 ≤ {target} := by + exact False.elim (lt_irrefl {rat(a)} (hx.1.trans hx.2)) + +''', 0 + p=coefficients(m,j) + if target.startswith('-'): + p=[-c for c in p] + cells=sign_cover(p,a,b) + validate_cover([(v[0],v[1]) for v in cells],a,b) + [(lo,hi,scale,cs)]=cells + data=textwrap.fill('['+', '.join(map(str,cs))+']', width=92, + initial_indent=' ', subsequent_indent=' ') + return f'''private lemma {name} (x : ℝ) (hx : x ∈ Set.Ioo {rat(a)} {rat(b)}) : + 0 ≤ {target} := by + refine (BernsteinCert.coeffs_pos +{data} + (lo := {rat(lo)}) (hi := {rat(hi)}) (s := {scale}) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical{j} + norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, + List.length_cons, List.length_nil] + bernstein_ring (x - {rat(lo)}) ({rat(hi)} - x) + +''', 1 + +def row_source(row): + m=row['m']; d=min(F(17),F(m,2)) + s='import Sendov.Common.DistillationCriticalFinite\nimport Sendov.Common.BernsteinList\n\n' + s+='/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions.\nGenerated by scripts/gen_distillation.py. See the shared helper for provenance. -/\n\n' + s+=f'namespace Sendov\nnamespace CriticalRow{m}\n\n' + for c in row['components']: + j=c['index']; lo=F(c['lo']); hi=F(c['hi']); u=F(c['u'],1000) + for side,a,b in [('left',F(0),lo),('right',hi,d)]: + source, _ = sign_source(m,j,side,a,b) + s += source + s+=f'''theorem component{j} (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ {rat(d)}) : + distillT{j} {m} α ≤ {rat(u)} := by + apply distillT{j}_le_of_critical (l := {rat(lo)}) (r := {rat(hi)}) (d := {rat(d)}) +''' + if j: + s+=f' {m-3} (by norm_num) (by norm_num)\n' + s+=' (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num)\n' + s+=f' sign_{j}_left sign_{j}_right ?_ ⟨hα, hd⟩\n' + s+=' norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope]\n\n' + s+=f'end CriticalRow{m}\n\n' + total=rat(row['total']) + s+=f'''theorem distillFinite_{m} (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ {rat(d)}) : + distillEBudget {m} + distillT0 {m} α + distillT1 {m} α + distillT2 {m} α ≤ {total} := by + have h0 := CriticalRow{m}.component0 α hα hd + have h1 := CriticalRow{m}.component1 α hα hd + have h2 := CriticalRow{m}.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_{m} : ({total} : ℝ) < 199 / 200 := by norm_num + +''' + if m==81: + s+='''theorem distillFiniteTailBase {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : + distillEBudget 81 + distillT0 81 α + distillT1 81 α + distillT2 81 α < 2 / 3 := by + exact (distillFinite_81 α hα h17).trans_lt (by norm_num) + +''' + s+='end Sendov\n' + return s + +def aggregate_source(): + s=''.join(f'import Sendov.DistillationFinite.Row{m}\n' for m in range(5,82)) + s+=''' +/-! Exact finite-domain critical-bracket closure. Fixed original paper budgets; +see DistillationCriticalFinite for attribution. No sampled truth or global T grid. -/ +namespace Sendov + +theorem distillFinite_components {m : ℕ} (hm : 5 ≤ m) (hm81 : m ≤ 81) + {α : ℝ} (hα : 0 ≤ α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := by + interval_cases m +''' + for m in range(5,82): + s+=f' · exact (distillFinite_{m} α hα (by linarith)).trans_lt distillFiniteBound_{m}\n' + s+=''' +theorem distillFinite_scalar {m : ℕ} (hm : 5 ≤ m) (hm81 : m ≤ 81) + {α : ℝ} (hα : 0 < α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : + scalarObstruction m α (cubicPolarEnvelope α) < 199 / 200 := by + have hmR : (5 : ℝ) ≤ m := by exact_mod_cast hm + exact (distillScalar_le_majorant hmR hα (by linarith)).trans_lt + (distillFinite_components hm hm81 hα.le hαm h17) + +end Sendov +''' + return s + + +def require_empty_output(output): + if output.is_symlink() or (output.exists() and + (not output.is_dir() or any(output.iterdir()))): + raise ValueError('output must be a new or empty directory (not a symlink)') + + +def generate(output, table=TABLE): + output = Path(output).absolute() + require_empty_output(output) + rows = load_table(table, coefficients) + rendered = {f'Sendov/DistillationFinite/Row{r["m"]}.lean': row_source(r) + for r in rows} + rendered['Sendov/Common/DistillationFinite.lean'] = aggregate_source() + # All exact calculations and row rendering precede staging. Only the grouped + # snapshot is published; individual rows are temporary packaging inputs. + output.parent.mkdir(parents=True, exist_ok=True) + with tempfile.TemporaryDirectory(prefix='.distillation-', dir=output.parent) as temporary: + work = Path(temporary) + raw = work / 'rows' + for rel, text in rendered.items(): + target = raw / rel + target.parent.mkdir(parents=True, exist_ok=True) + target.write_text(text, encoding='utf-8', newline='\n') + result = bundle(raw, work / 'grouped', size=8) + require_empty_output(output) + os.replace(work / 'grouped', output) + return result + + +def main(): + parser = argparse.ArgumentParser(description=__doc__) + parser.add_argument('--output', type=Path, required=True, + help='new or empty output directory; never the project source tree') + parser.add_argument('--table', type=Path, default=TABLE, + help='exact table JSON (default: project data/paper_certificate_table.json)') + args = parser.parse_args() + try: + result = generate(args.output, args.table) + except (ValueError, OSError) as error: + parser.exit(1, f'error: {error}\n') + print(json.dumps(result, indent=2)) + + +if __name__ == '__main__': + main() diff --git a/scripts/gen_endgame.py b/scripts/gen_endgame.py deleted file mode 100644 index 45519e4..0000000 --- a/scripts/gen_endgame.py +++ /dev/null @@ -1,252 +0,0 @@ -import sympy as sp - -a = sp.symbols('a') -g = 300 + 47*a - a**2 -T1cf = sp.Rational(1600000, 721)*(100-2*a)**2*(3+a)**3/g**4 -terms = [sp.Rational(1, 6), 1/(4*(3+a)), sp.Rational(1, 200), 1/(400*(3+a)), - sp.Rational(101, 100)*T1cf, - (100-2*a)**2/100*101*99/(16*(3+a)) * (a/(3+a))**48] -Ut = sum(terms) - -# The multiplier D = Lp (3+a)^49 g^4. Lp is chosen so that *every* term of Ut, multiplied -# by D, is an integer polynomial -- not merely their sum. (With the smaller multiplier the -# last term alone carries a factor 1/4.) -Dbase = (3+a)**49 * g**4 -Fq = sp.Poly(sp.expand(sp.simplify(Dbase * (1 - Ut))), a, domain=sp.QQ) -L = sp.ilcm(*[sp.Rational(x).q for x in Fq.all_coeffs()]) -Lp = L -print(f"L = {L}, Lp = {Lp}") - -# each term of Ut, times D, in *natural* (unexpanded) form -nat = [] -for t in terms: - q = sp.simplify(sp.cancel(Lp*Dbase*t)) - nat.append(sp.factor(q)) - assert sp.simplify(q - Lp*Dbase*t) == 0 - -F = sp.Poly(sp.expand(sp.cancel(sp.together(Lp * Dbase * (1 - Ut)))), a) -d = F.degree() -cf = [F.coeff_monomial(a**i) for i in range(d+1)] -assert all(sp.Rational(x).is_Integer for x in cf), "F is not integral" -cf = [sp.Integer(x) for x in cf] -G = [sum(cf[i]*sp.binomial(d-i, m-i)*17**i for i in range(m+1)) for m in range(d+1)] -assert all(x > 0 for x in G), "certificate not all-positive" -assert sp.expand(17**d*F.as_expr() - sum(G[m]*a**m*(17-a)**(d-m) for m in range(d+1))) == 0 -for i in range(0, 171): - v = sp.Rational(i, 10) - assert Ut.subs(a, v) < 1, f"Ut({v}) >= 1" - assert F.as_expr().subs(a, v) > 0, f"F({v}) <= 0" - -# the constants of the six per-term identities, read off rather than hand-derived -k16 = sp.simplify(nat[0] / (Dbase)) -k4 = sp.simplify(nat[1] / ((3+a)**48 * g**4)) -k200 = sp.simplify(nat[2] / (Dbase)) -k400 = sp.simplify(nat[3] / ((3+a)**48 * g**4)) -kT1 = sp.simplify(nat[4] / ((100-2*a)**2 * (3+a)**52)) -kT2 = sp.simplify(nat[5] / ((100-2*a)**2 * a**48 * g**4)) -def lean_const(k): - k = sp.Rational(k) - assert k > 0 - return str(k.p) if k.q == 1 else f"({k.p} / {k.q})" - - -for nm, k in (("1/6", k16), ("1/(4(3+a))", k4), ("1/200", k200), ("1/(400(3+a))", k400), - ("T1", kT1), ("T2", kT2)): - assert sp.Rational(k).is_Rational, f"{nm} constant not rational: {k}" -print(" constants:", k16, k4, k200, k400, kT1, kT2) -k16, k4, k200, k400, kT1, kT2 = map(lean_const, (k16, k4, k200, k400, kT1, kT2)) -print(f"degree {d}; |G| up to {max(len(str(x)) for x in G)} digits; ALL CHECKS PASS") - -G4 = "(300 + 47 * α - α ^ 2) ^ 4" -DD = f"{Lp} * (3 + α) ^ 49 * {G4}" -# the factor left over after 721 * γ⁴ is cancelled out of `101/100 * D` -kT1div = sp.Rational(101, 100) * Lp / 721 -assert kT1div.is_Integer, kT1div -kT1div = int(kT1div) - - -def poly(cs, var="α"): - ts = [] - for i, v in enumerate(cs): - v = sp.Integer(v) - if v == 0: - continue - s = ("+ " if v > 0 else "- ") + str(abs(v)) - if i == 1: - s += f" * {var}" - elif i > 1: - s += f" * {var} ^ {i}" - ts.append(s) - t = " ".join(ts) - return t[2:] if t.startswith("+ ") else "-" + t[2:] - - -P = poly(cf) -bern = " + ".join((f"{G[0]} * (17 - α) ^ {d}" if m == 0 else - f"{G[d]} * α ^ {d}" if m == d else - f"{G[m]} * α ^ {m} * (17 - α) ^ {d-m}") for m in range(d+1)) - - -src = f'''/- -Copyright (c) 2026 Terence Tao. All rights reserved. -Released under Apache 2.0 license as described in the file LICENSE. -Authors: Terence Tao --/ -import Sendov.LargeDegree.Monotone -import Sendov.Common.BernsteinCert -import Sendov.Common.BernsteinRing - -/-! -# The large-degree claim - -`Sendov.U_le_Ut` removed the degree from the bound; what is left is the single inequality -`Ut α < 1` on `0 ≤ α ≤ 17`, and then `R n α < 1` for every `n ≥ 101`. - -`Ut` is a rational function of `α` times `(α/(3+α)) ^ 48`, so multiplying by - - `D = {Lp} · (3+α) ^ 49 · γ ^ 4`, `γ = 300 + 47α - α²`, - -which is positive on `[0,17]`, turns the claim into positivity of the single polynomial -`F = D (1 - Ut)` of degree `{d}`. The two closed forms used are - - `c 101 α = γ / (100 (3+α))`, - `T1 101 α = 1600000 (100-2α)² (3+α)³ / (721 γ⁴)`. - -A Bernstein certificate on `[0,17]` settles it: all {d+1} coefficients of `F` in the basis -`α^m (17-α)^({d}-m)` are positive, so no subdivision of the `α`-range is needed. (The -informal write-up splits at `α = 16` and estimates the two pieces separately; that is not -necessary once the sharp Beta constant is used, which is what leaves the margin — `Ut` peaks -at `α = 17` with value `0.9229`.) - -## Why the multiplication is distributed by hand - -`D (1 - Ut)` must not be handed to `field_simp`: it would clear `(3+α) ^ 49` and `γ ⁴` from -both sides at once, leaving `ring` a degree-115 identity that it does not close. `D` already -*contains* exactly those denominators, so each of the six terms of `Ut` cancels against it -separately. Doing that first (`Sendov.Ut_lt_one`, steps `t1`–`t6`, and `h48` for the `48`-th -power) keeps every `ring` call at degree at most `{d+4}`, which is the same size as the -certificate identity itself. `{Lp}` rather than `{L}` is used as the multiplier so that -each term separately, not merely their sum, comes out with integer coefficients. - -## Main statements - -* `Sendov.Ut_lt_one`: `Ut α < 1` on `0 ≤ α ≤ 17`; -* `Sendov.large_degree`: `R n α < 1` for `n ≥ 101`. --/ - -namespace Sendov - -variable {{α : ℝ}} - -set_option maxHeartbeats 4000000 in --- a degree-{d} identity in one variable; `ring` needs more than the default budget -/-- The Bernstein certificate: `F` is positive on `[0,17]`. -/ -lemma F_pos (hα : 0 ≤ α) (hα' : α ≤ 17) : - 0 < {P} := by - have hu : (0 : ℝ) ≤ 17 - α := by linarith - have hid : (17 : ℝ) ^ {d} * ({P}) = {bern} := by - bernstein_ring α (17 - α) - bernstein_cert α (17 - α) using hid - -set_option maxHeartbeats 4000000 in -/-- **The bound in `α` alone is below `1`.** -/ -theorem Ut_lt_one (hα : 0 ≤ α) (hα' : α ≤ 17) : Ut α < 1 := by - have h3 : (0 : ℝ) < 3 + α := three_add_pos hα - have hg : (0 : ℝ) < 300 + 47 * α - α ^ 2 := by nlinarith - have hgne : (300 : ℝ) + 47 * α - α ^ 2 ≠ 0 := hg.ne' - have hc : c 101 α = (300 + 47 * α - α ^ 2) / (100 * (3 + α)) := by - simp only [c, M] - norm_num - field_simp - ring - have hT1 : T1 101 α - = 1600000 * (100 - 2 * α) ^ 2 * (3 + α) ^ 3 / (721 * (300 + 47 * α - α ^ 2) ^ 4) := by - simp only [T1, hc] - norm_num - field_simp - ring - -- `(α/(3+α)) ^ 48` cancels against `(3+α) ^ 49` without expanding either - have h48 : (α / (3 + α)) ^ 48 * (3 + α) ^ 49 = α ^ 48 * (3 + α) := by - rw [div_pow, pow_succ (3 + α) 48, ← mul_assoc, - div_mul_cancel₀ _ (pow_ne_zero 48 h3.ne')] - -- The six terms of `Ut`, each multiplied by `D`. Composite powers are kept - -- as scalar factors: cancel denominators first, then normalize only the coefficients. - have t1 : (1 / 6 : ℝ) * ({DD}) = {k16} * (3 + α) ^ 49 * {G4} := by - norm_num [← mul_assoc] - have t2 : 1 / (4 * (3 + α)) * ({DD}) = {k4} * (3 + α) ^ 48 * {G4} := by - rw [pow_succ (3 + α) 48] - -- Remove the single factor `3 + α`; the remaining powers stay opaque. - generalize (3 + α) ^ 48 = p, {G4} = g - field_simp - ring - have t3 : (1 / 200 : ℝ) * ({DD}) = {k200} * (3 + α) ^ 49 * {G4} := by - norm_num [← mul_assoc] - have t4 : 1 / (400 * (3 + α)) * ({DD}) = {k400} * (3 + α) ^ 48 * {G4} := by - rw [pow_succ (3 + α) 48] - -- Remove the single factor `3 + α`; the remaining powers stay opaque. - generalize (3 + α) ^ 48 = p, {G4} = g - field_simp - ring - have t5 : 101 / 100 * (1600000 * (100 - 2 * α) ^ 2 * (3 + α) ^ 3 - / (721 * {G4})) * ({DD}) - = {kT1} * (100 - 2 * α) ^ 2 * (3 + α) ^ 52 := by - -- Combine exponents by `pow_add`, and cancel only the scalar denominator γ⁴. - rw [show (3 + α) ^ 52 = (3 + α) ^ 3 * (3 + α) ^ 49 from pow_add _ 3 49] - have hg4 := pow_ne_zero 4 hgne - generalize (100 - 2 * α) ^ 2 = a, (3 + α) ^ 3 = b, (3 + α) ^ 49 = p - generalize {G4} = g at hg4 ⊢ - field_simp - ring - have t6 : (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * (α / (3 + α)) ^ 48 - * ({DD}) - = {kT2} * (100 - 2 * α) ^ 2 * α ^ 48 * {G4} := by - -- First expose the paired powers so that `h48` cancels 48 denominator factors. - rw [show (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * (α / (3 + α)) ^ 48 - * ({DD}) - = ((100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) * ({Lp} * {G4})) - * ((α / (3 + α)) ^ 48 * (3 + α) ^ 49) from by - -- This is only reassociation of scalar factors, not a polynomial identity. - generalize (100 - 2 * α) ^ 2 / 100 * 101 * 99 / (16 * (3 + α)) = a, - (α / (3 + α)) ^ 48 = b, (3 + α) ^ 49 = p, - {G4} = g - ring, h48] - -- Only one factor `3 + α` remains to cancel; do not expand α⁴⁸ or γ⁴. - generalize (100 - 2 * α) ^ 2 = a, α ^ 48 = p, {G4} = g - field_simp - ring - have hD : (0 : ℝ) < {DD} := by - have h49 := pow_pos h3 49 - have hg4 := pow_pos hg 4 - positivity - have hmul : (1 - Ut α) * ({DD}) = {P} := by - rw [Ut, hT1, sub_mul, one_mul, add_mul, add_mul, add_mul, add_mul, add_mul, - t1, t2, t3, t4, t5, t6] - ring - rw [← sub_pos] - have hF := F_pos hα hα' - nlinarith [hmul, hF, hD] - -/-- **The large-degree claim.** Every degree `n ≥ 101`. -/ -theorem large_degree {{n : ℕ}} (hn : 101 ≤ n) (hα : 0 ≤ α) (hα' : α ≤ 17) - (hfeas : c n α ^ 2 ≤ A n α) : R n α < 1 := by - have hcpos : (0 : ℝ) < c n α := by - have := c_ge_of_large hn hα hα' - linarith - exact lt_of_le_of_lt - (le_trans (R_le_U (by omega) hα hfeas hcpos) (U_le_Ut hn hα hα')) - (Ut_lt_one hα hα') - -end Sendov -''' -# Resolve relative to this checkout; --output supports isolated regeneration checks. -import argparse -from pathlib import Path -parser = argparse.ArgumentParser() -parser.add_argument("--output", type=Path, - default=Path(__file__).resolve().parents[1] / "Sendov/LargeDegree/Endgame.lean", - help="Output Lean file; overwrites it if present. Default: this checkout's Endgame.lean.") -output = parser.parse_args().output -output.parent.mkdir(parents=True, exist_ok=True) -with output.open("w", encoding="utf-8", newline="\n") as stream: - stream.write(src) -print(f"written Endgame.lean, {len(src.encode('utf-8'))} bytes") diff --git a/scripts/gen_moment.py b/scripts/gen_moment.py deleted file mode 100644 index e58a8df..0000000 --- a/scripts/gen_moment.py +++ /dev/null @@ -1,65 +0,0 @@ -import sys, io -from math import lcm -sys.set_int_max_str_digits(20000000) -def build(n, k): - M = n-1; G = 3 - g0 = [6*M, 2*M]; g1 = [-12*M, 12-2*M, 4]; g2 = [6*M, 2*M-12, -4] - L1 = sum(abs(c) for c in g0+g1+g2) - L = lcm(*range(4, 2*k+5)) - mlen = 1 + G*k - beta = 2*(L * L1**k) + 1 - tau = 2*(L1**k * beta**mlen) + 1 - def padd(p,q): - r=[0]*max(len(p),len(q)) - for i,x in enumerate(p): r[i]+=x - for i,x in enumerate(q): r[i]+=x - return r - def pmul(p,q): - if not p or not q: return [] - r=[0]*(len(p)+len(q)-1) - for i,x in enumerate(p): - if x: - for j,y in enumerate(q): r[i+j]+=x*y - return r - row=[[1]] - for _ in range(k): - new=[[] for _ in range(len(row)+2)] - for i,e in enumerate(row): - for s,g in enumerate((g0,g1,g2)): new[i+s]=padd(new[i+s], pmul(g,e)) - row=new - Nmom=[] - for j,e in enumerate(row): Nmom = padd(Nmom, [(L//(j+4))*c for c in e]) - def pevZ(p,b): - s=0 - for c in reversed(p): s=c+b*s - return s - Gv = pevZ(g0,beta) + pevZ(g1,beta)*tau + pevZ(g2,beta)*tau**2 - X = Gv**k - blocks=[]; y=X - for _ in range(2*k+1): - r=y%tau; d=r if 2*r positive definite)") -print(f" 4*{c2}*(that quadratic) = ({2*c2} j + {c1})^2 + {4*c2*c0 - c1**2}") - -print() -n = 101 + k -S = sp.expand(13*(n-1-2*a)**2*(n-2)*n**2 - 12*(n-2*a)**2*(n+1)*(n-1)**2) -GS = show("S", S, a, 17, k) diff --git a/scripts/gen_sinh.py b/scripts/gen_sinh.py index 1cbf83f..4b0a26a 100644 --- a/scripts/gen_sinh.py +++ b/scripts/gen_sinh.py @@ -1,68 +1,70 @@ import sympy as sp, io -y = sp.symbols('y', real=True) -U = y**3 - 10*y**2 + 36*y - 36 -V = y**4 + 16*y**2 - 72 -W = y**3 + 10*y**2 + 36*y + 36 - -rows = [] -for j in range(9): - u = sp.Poly(U, y).all_coeffs()[::-1] + [0]*4 - v = sp.Poly(V, y).all_coeffs()[::-1] + [0]*5 - w = sp.Poly(W, y).all_coeffs()[::-1] + [0]*4 if W != 0 else [0]*4 - u, v, w = u[:4], v[:5], w[:4] - assert sp.Poly(U, y).degree() <= 3 and sp.Poly(V, y).degree() <= 4 - rows.append((u, v, w)) - U, V, W = sp.expand(2*U + sp.diff(U, y)), sp.expand(V + sp.diff(V, y)), sp.expand(sp.diff(W, y)) - -# sanity: Phi_j(0) = u0 - v0 - w0 is 0 for j <= 7 and 56 for j = 8 -for j, (u, v, w) in enumerate(rows): - val = u[0] - v[0] - w[0] - assert val == (0 if j < 8 else 56), (j, val) - -# the base case polynomial -A = y**3 + 2*y**2 - 2*y + 10 -u8, v8, _w8 = rows[8] -assert sp.expand(sum(u8[i]*y**i for i in range(4)) - 256*A) == 0 -V8 = sum(v8[i]*y**i for i in range(5)) -base = sp.expand(256*(1 + y + y**2/2)*A - V8) -bc = sp.Poly(base, y).all_coeffs()[::-1] -assert all(c > 0 for c in bc), bc -print("base polynomial coefficients (ascending):", bc) - - -def num(c): - c = sp.Rational(c) - assert c.q == 1 - return f"({c.p})" if c.p < 0 else str(c.p) - - -def args(j): - u, v, w = rows[j] - return " ".join(num(c) for c in (u[3], u[2], u[1], u[0])) + " " \ - + " ".join(num(c) for c in (v[4], v[3], v[2], v[1], v[0])) + " " \ - + " ".join(num(c) for c in (w[3], w[2], w[1], w[0])) - - -def poly_str(cs, var="y"): - ts = [] - for i, c in enumerate(cs): - c = sp.Integer(c) - if c == 0: - continue - s = ("+ " if c > 0 else "- ") + str(abs(c)) - if i == 1: - s += f" * {var}" - elif i > 1: - s += f" * {var} ^ {i}" - ts.append(s) - t = " ".join(ts) - return t[2:] if t.startswith("+ ") else "-" + t[2:] - - -steps = [] -for j in range(7, -1, -1): - steps.append(f''' +# Modified for round6: generator entry/output fixes; see GENERATORS.md (Apache-2.0). +if __name__ == "__main__": + y = sp.symbols('y', real=True) + U = y**3 - 10*y**2 + 36*y - 36 + V = y**4 + 16*y**2 - 72 + W = y**3 + 10*y**2 + 36*y + 36 + + rows = [] + for j in range(9): + u = sp.Poly(U, y).all_coeffs()[::-1] + [0]*4 + v = sp.Poly(V, y).all_coeffs()[::-1] + [0]*5 + w = sp.Poly(W, y).all_coeffs()[::-1] + [0]*4 if W != 0 else [0]*4 + u, v, w = u[:4], v[:5], w[:4] + assert sp.Poly(U, y).degree() <= 3 and sp.Poly(V, y).degree() <= 4 + rows.append((u, v, w)) + U, V, W = sp.expand(2*U + sp.diff(U, y)), sp.expand(V + sp.diff(V, y)), sp.expand(sp.diff(W, y)) + + # sanity: Phi_j(0) = u0 - v0 - w0 is 0 for j <= 7 and 56 for j = 8 + for j, (u, v, w) in enumerate(rows): + val = u[0] - v[0] - w[0] + assert val == (0 if j < 8 else 56), (j, val) + + # the base case polynomial + A = y**3 + 2*y**2 - 2*y + 10 + u8, v8, _w8 = rows[8] + assert sp.expand(sum(u8[i]*y**i for i in range(4)) - 256*A) == 0 + V8 = sum(v8[i]*y**i for i in range(5)) + base = sp.expand(256*(1 + y + y**2/2)*A - V8) + bc = sp.Poly(base, y).all_coeffs()[::-1] + assert all(c > 0 for c in bc), bc + print("base polynomial coefficients (ascending):", bc) + + + def num(c): + c = sp.Rational(c) + assert c.q == 1 + return f"({c.p})" if c.p < 0 else str(c.p) + + + def args(j): + u, v, w = rows[j] + return " ".join(num(c) for c in (u[3], u[2], u[1], u[0])) + " " \ + + " ".join(num(c) for c in (v[4], v[3], v[2], v[1], v[0])) + " " \ + + " ".join(num(c) for c in (w[3], w[2], w[1], w[0])) + + + def poly_str(cs, var="y"): + ts = [] + for i, c in enumerate(cs): + c = sp.Integer(c) + if c == 0: + continue + s = ("+ " if c > 0 else "- ") + str(abs(c)) + if i == 1: + s += f" * {var}" + elif i > 1: + s += f" * {var} ^ {i}" + ts.append(s) + t = " ".join(ts) + return t[2:] if t.startswith("+ ") else "-" + t[2:] + + + steps = [] + for j in range(7, -1, -1): + steps.append(f''' private lemma step{j} (y : ℝ) (hy : 0 ≤ y) : 0 ≤ Sf {args(j)} y := by refine nonneg_Sf_of_deriv (by norm_num) ?_ hy @@ -70,7 +72,7 @@ def poly_str(cs, var="y"): convert step{j+1} z hz using 1 norm_num''') -src = f'''/- + src = f'''/- Copyright (c) 2026 Terence Tao. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Terence Tao @@ -244,16 +246,17 @@ def poly_str(cs, var="y"): end Sendov ''' -# The analytic tail carries no generated data, and contains brace characters that an -# f-string would swallow, so it is kept beside this script rather than inlined. -from pathlib import Path -import argparse - -parser = argparse.ArgumentParser(description="Emit Sinh.lean from the symbolic derivative recurrence") -parser.add_argument("--output", type=Path, default=Path("Sinh.lean")) -options = parser.parse_args() -src = src.replace("\nend Sendov\n", "\n") + io.open( - Path(__file__).with_name("sinh_tail.lean.txt"), encoding="utf-8").read() -io.open(options.output, "w", - encoding="utf-8", newline="\n").write(src) -print(f"written Sinh.lean, {len(src)} bytes") + # The analytic tail carries no generated data, and contains brace characters that an + # f-string would swallow, so it is kept beside this script rather than inlined. + from pathlib import Path + import argparse + + parser = argparse.ArgumentParser(description="Emit Sinh.lean from the symbolic derivative recurrence") + parser.add_argument("--output", type=Path, + default=Path(__file__).resolve().parents[1] / "Sendov/Common/Sinh.lean") + options = parser.parse_args() + src = src.replace("\nend Sendov\n", "\n") + io.open( + Path(__file__).with_name("sinh_tail.lean.txt"), encoding="utf-8").read() + from generator_output import write_lean + write_lean(options.output, src) + print(f"written Sinh.lean, {len(src)} bytes") diff --git a/scripts/generator_output.py b/scripts/generator_output.py new file mode 100644 index 0000000..64b9222 --- /dev/null +++ b/scripts/generator_output.py @@ -0,0 +1,24 @@ +"""Publish a fully rendered Lean file without truncating a previous target. + +Modified for the round6 generator integration; Apache-2.0, see ../LICENSE. +""" +import os +from pathlib import Path +import tempfile + + +def write_lean(output, source): + """Stage UTF-8/LF text beside the destination and replace only after close.""" + output = Path(output) + output.parent.mkdir(parents=True, exist_ok=True) + temporary = None + try: + with tempfile.NamedTemporaryFile(mode='w', encoding='utf-8', newline='\n', + dir=output.parent, prefix='.' + output.name + '.', + suffix='.tmp', delete=False) as stream: + temporary = Path(stream.name) + stream.write(source) + os.replace(temporary, output) + finally: + if temporary is not None: + temporary.unlink(missing_ok=True) diff --git a/scripts/mutation_test.sh b/scripts/mutation_test.sh deleted file mode 100644 index e105ccf..0000000 --- a/scripts/mutation_test.sh +++ /dev/null @@ -1,56 +0,0 @@ -#!/bin/sh -# Mutation test: corrupt one *load-bearing* datum and confirm the build fails. -# -# Which occurrence is mutated matters. Each certificate coefficient appears twice in a -# generated file: once in a `have hⱼ : 0 ≤ Gⱼ αʲ (U-α)^(d-j)` and once in the identity `hid`. -# Perturbing the first is invisible — `linarith` only uses those hypotheses as "this quantity -# is nonnegative", and a positive rescaling of a nonnegative quantity is still nonnegative. -# The identity is what carries the content, so that is the occurrence to corrupt. Likewise -# the moment data (`Nmomc`) is load-bearing and is checked against the packed recurrence. -cd "$(dirname "$0")/.." || exit 1 -rc=0 - -mutate () { - file=$1; from=$2; to=$3; nth=$4; label=$5; target=$6 - python - "$file" "$from" "$to" "$nth" <<'PY' || exit 1 -import io, sys -p, a, b, nth = sys.argv[1], sys.argv[2], sys.argv[3], int(sys.argv[4]) -s = io.open(p, encoding="utf-8").read() -assert s.count(a) >= nth, f"only {s.count(a)} occurrences of {a}, wanted #{nth}" -i = -1 -for _ in range(nth): - i = s.index(a, i + 1) -io.open(p, "w", encoding="utf-8", newline="\n").write(s[:i] + b + s[i+len(a):]) -PY - if lake build "$target" >/dev/null 2>&1; then - echo "!! SURVIVED: $label" - rc=1 - else - echo "ok, build fails: $label" - fi - git checkout -- "$file" -} - -# the Bernstein identity of the smallest batch (2nd occurrence = inside `hid`) -mutate Sendov/FiniteRange/Degree6_6.lean "69425" "69426" 2 \ - "Degree6_6, Bernstein identity coefficient" Sendov.FiniteRange.Degree6_6 - -# a coefficient of the certified polynomial P itself -mutate Sendov/FiniteRange/Degree6_6.lean "2345" "2346" 1 \ - "Degree6_6, coefficient of P" Sendov.FiniteRange.Degree6_6 - -# a moment datum, checked against the packed recurrence rather than against a certificate -mutate Sendov/FiniteRange/Degree6_6.lean "def Nmomc : List ℤ :=" "def Nmomc : List ℤ := [0] ++" 1 \ - "Degree6_6, moment data" Sendov.FiniteRange.Degree6_6 - -# the degree-58 endgame certificate -mutate Sendov/LargeDegree/Endgame.lean "1939200000" "1939200001" 1 \ - "Endgame, the T1 constant" Sendov.LargeDegree.Endgame - -# the tail-1 monotonicity certificate. Here the 1st occurrence is in the module docstring -# and the 2nd is the inert `have h2`, so the identity is the 3rd. -mutate Sendov/LargeDegree/Monotone.lean "27356448" "27356449" 3 \ - "Monotone, tail1_poly identity coefficient" Sendov.LargeDegree.Monotone - -echo "=== mutation test finished (rc=$rc) ===" -exit $rc diff --git a/scripts/pack_params.py b/scripts/pack_params.py deleted file mode 100644 index ec9ba77..0000000 --- a/scripts/pack_params.py +++ /dev/null @@ -1,39 +0,0 @@ -#!/usr/bin/env python3 -"""Numerical parameters for the packed moment computation, one set per degree. - -Emits the two Kronecker bases used by Sendov/FiniteRange/PackBridge.lean: - beta -- packs a coefficient polynomial in alpha into one integer - tau -- packs the resulting row, a polynomial in t, into one integer -together with L = lcm(4 .. 2k+4), which clears the 1/(j+4) weights of irow. - -These are the values that discharge the overflow hypotheses of unpackZ_pevZ. -""" -from math import lcm -# Numerical parameters for the packed moment computation, per degree. -# L1 = sum of |coefficients| of g0,g1,g2 (bounds every coefficient of the k-th power) -# L = lcm(4 .. 2k+4) (clears the 1/(j+4) weights) -# beta > 2 * max|moment-numerator coefficient| <= 2 * (2k+1) * (L/4) * L1^k -# tau > 2 * max|alpha-packed row entry| <= 2 * L1^k * (beta^(2k+1)-1)/(beta-1) -def params(n, k): - M = n - 1 - L1 = 8*M + (12*M + abs(12-2*M) + 4) + (6*M + abs(2*M-12) + 4) # = 30M - 16 - L = lcm(*range(4, 2*k+5)) - coefmax = L1**k - nmommax = (2*k+1) * (L//4 + 1) * coefmax - beta = 2*nmommax + 1 - packmax = coefmax * ((beta**(2*k+1) - 1)//(beta-1) + 1) - tau = 2*packmax + 1 - G_bits = (tau**2).bit_length() + max(x.bit_length() for x in [L1]) - return L1, L, beta, tau, G_bits, k -print(f"{'n':>4} {'k':>3} {'L1':>6} {'L bits':>7} {'beta bits':>10} {'tau bits':>10} {'G^k bits':>10} {'G^k MB':>8}") -for n, k in [(20,8),(53,24),(53,25),(97,46),(97,47)]: - L1, L, beta, tau, Gb, k = params(n, k) - Gk = Gb * k - print(f"{n:>4} {k:>3} {L1:>6} {L.bit_length():>7} {beta.bit_length():>10} " - f"{tau.bit_length():>10} {Gk:>10} {Gk/8/1024/1024:>8.2f}") -print() -print("sanity: bound vs truth at n=53,k=24 (true max coeff measured earlier: 249 bits)") -L1,L,beta,tau,_,_ = params(53,24) -print(f" L1^k = {(L1**24).bit_length()} bits (bound on any coefficient)") -print(f" L = lcm(4..52) = {L.bit_length()} bits") -print(f" beta = {beta.bit_length()} bits, tau = {tau.bit_length()} bits") diff --git a/scripts/plan_batches.py b/scripts/plan_batches.py deleted file mode 100644 index 8584b0d..0000000 --- a/scripts/plan_batches.py +++ /dev/null @@ -1,43 +0,0 @@ -import numpy as np, sympy as sp -X,W = np.polynomial.legendre.leggauss(800); T=0.5*(X+1); W=0.5*W -def base(n, al): - M=n-1.0; return 1/6+1/(4*(3+al))+1/(2*M)+1/(4*M*(3+al)) -def pref(n, al): - M=n-1.0; A=1-2*al/M; return A**2*n*M*(n-2)/(4*(3+al)) -def I(n, al): - M=n-1.0; A=1-2*al/M; c=1-al/M-al/(2*(3+al)) - return np.sum(W*T**3*np.maximum(1-2*c*T+A*T*T,0.0)**((n-4)/2)) -def batch_max(n0, n1): - amax = min(17.0, (n1-1)/2); best = 0.0 - for al in np.linspace(0, amax, 400): - if 1-2*al/(n0-1.0) < 0: continue - best = max(best, base(n0, al) + pref(n1, al)*I(n0, al)) - return best -a = sp.symbols('alpha') -def bern_ok(n0, n1): - M0=sp.Integer(n0-1); M1=sp.Integer(n1-1); k0=(n0-4)//2 - A0=1-2*a/M0; c0=sp.cancel(1-a/M0-a/(2*(3+a))); A1=1-2*a/M1 - mom = sum(sp.binomial(k0,i)*sp.binomial(i,l)*(-2*c0)**l*A0**(i-l)/sp.Integer(2*i-l+4) - for i in range(k0+1) for l in range(i+1)) - R = (sp.Rational(1,6)+1/(4*(3+a))+1/(2*M0)+1/(4*M0*(3+a)) - + A1**2*n1*M1*(n1-2)/(4*(3+a))*mom) - num, _ = sp.fraction(sp.cancel(sp.together(1-R))) - P = sp.Poly(sp.expand(num), a); d = P.degree() - cf = [sp.Integer(x) for x in P.all_coeffs()][::-1] - U = sp.Rational(17) if sp.Rational(17) <= sp.Rational(n1-1,2) else sp.Rational(n1-1,2) - p_,q_ = U.p, U.q - G = [sum(cf[i]*q_**(j-i)*sp.binomial(d-i,j-i)*p_**i for i in range(j+1)) for j in range(d+1)] - return d, all(g>0 for g in G), sum(1 for g in G if g<=0) -def plan(th): - n0=6; out=[] - while n0 <= 97: - n1=n0 - while n1+1 <= 97 and batch_max(n0,n1+1) < th: n1 += 1 - out.append((n0,n1,batch_max(n0,n1))); n0=n1+1 - if n0 % 2 == 1: n0 += 1 - return out -p = plan(0.95); p.sort(key=lambda x:-x[2]) -print("tightest batches in the 0.95 plan (Bernstein checked):") -for n0,n1,b in p[:6]: - d, ok, neg = bern_ok(n0,n1) - print(f" [{n0},{n1}] bound={b:.4f} degP={d} certificate={ok}" + (f" ({neg} bad)" if not ok else "")) diff --git a/scripts/staged_build.sh b/scripts/staged_build.sh deleted file mode 100644 index 7db4699..0000000 --- a/scripts/staged_build.sh +++ /dev/null @@ -1,49 +0,0 @@ -#!/bin/sh -# Lake in this toolchain has no --jobs flag, and a simultaneous rebuild of all 31 batch -# files exhausts memory (Lean exits 0xC0000409, reported as `failed to read file ...olean`). -# Build them a few at a time instead. Note that any edit to Defs.lean, even to a -# docstring, invalidates every one of them. -cd "$(dirname "$0")/.." || exit 1 -set -- \ - "Sendov.Common.Basic Sendov.Common.Rpow Sendov.FiniteRange.Batch" \ - "Sendov.FiniteRange.Moments Sendov.FiniteRange.OddBound Sendov.FiniteRange.Pack" \ - "Sendov.FiniteRange.Recurrence Sendov.FiniteRange.PackBridge Sendov.FiniteRange.Reduce" \ - "Sendov.FiniteRange.Degree5 Sendov.FiniteRange.Degree6 Sendov.FiniteRange.Degree7" \ - "Sendov.FiniteRange.Degree8 Sendov.FiniteRange.Degree20" \ - "Sendov.FiniteRange.Degree20Packed Sendov.FiniteRange.Degree53Packed" \ - "Sendov.FiniteRange.Degree97Packed" \ - "Sendov.FiniteRange.Degree6_6 Sendov.FiniteRange.Degree8_9 Sendov.FiniteRange.Degree10_11" \ - "Sendov.FiniteRange.Degree12_13 Sendov.FiniteRange.Degree14_15 Sendov.FiniteRange.Degree16_18" \ - "Sendov.FiniteRange.Degree18_20 Sendov.FiniteRange.Degree20_22 Sendov.FiniteRange.Degree22_24" \ - "Sendov.FiniteRange.Degree24_26 Sendov.FiniteRange.Degree26_27 Sendov.FiniteRange.Degree28_29" \ - "Sendov.FiniteRange.Degree30_31 Sendov.FiniteRange.Degree32_33" \ - "Sendov.FiniteRange.Degree34_35 Sendov.FiniteRange.Degree36_37" \ - "Sendov.FiniteRange.Degree38_39 Sendov.FiniteRange.Degree40_41" \ - "Sendov.FiniteRange.Degree42_43 Sendov.FiniteRange.Degree44_45" \ - "Sendov.FiniteRange.Degree46_47 Sendov.FiniteRange.Degree48_49" \ - "Sendov.FiniteRange.Degree50_51 Sendov.FiniteRange.Degree52_53" \ - "Sendov.FiniteRange.Degree54_55 Sendov.FiniteRange.Degree56_58" \ - "Sendov.FiniteRange.Degree58_60 Sendov.FiniteRange.Degree60_63" \ - "Sendov.FiniteRange.Degree64_69" \ - "Sendov.FiniteRange.Degree70_79" \ - "Sendov.FiniteRange.Degree80_100" \ - "Sendov.FiniteRange.Cover" \ - "Sendov.LargeDegree.Beta Sendov.LargeDegree.Tail" \ - "Sendov.LargeDegree.Monotone" \ - "Sendov.LargeDegree.Endgame" \ - "Sendov.Main" \ - "Sendov" -fail=0 -for g in "$@"; do - out=$(lake build $g 2>&1) - if echo "$out" | grep -q "^error"; then - echo "=== FAILED: $g" - echo "$out" | grep -v "^info" \ - | grep -viE "longLine|linter|missing space|should be written|This part of the code|This line exceeds" \ - | tail -30 - fail=1 - else - echo "ok: $g" - fi -done -echo "=== staged build finished (fail=$fail) ===" diff --git a/tests/BoundaryConsumer.lean b/tests/BoundaryConsumer.lean new file mode 100644 index 0000000..321d3d4 --- /dev/null +++ b/tests/BoundaryConsumer.lean @@ -0,0 +1,42 @@ +import Lean +import Sendov.Common.DistillationCritical +import Sendov.LargeDegree.DistillationTail + +namespace MathPolishBoundary + +/-- The totalized raw obstruction retains its actual zero-endpoint value. -/ +theorem raw_zero (m : ℝ) : + Sendov.scalarObstruction m 0 (Sendov.cubicPolarEnvelope 0) = 1 / (2 * m) := + Sendov.scalarObstruction_zero m + +/-- The tail component vanishes at the closed left endpoint. -/ +theorem tail_zero {m : ℝ} (hm : 81 ≤ m) : Sendov.distillT2 m 0 = 0 := + Sendov.distillT2_zero hm + +/-- Both boundary identities are consumed together at the real tail threshold. -/ +theorem threshold_boundary : + Sendov.scalarObstruction 81 0 (Sendov.cubicPolarEnvelope 0) = 1 / 162 ∧ + Sendov.distillT2 81 0 = 0 := by + constructor + · convert raw_zero 81 using 1 + norm_num + · exact tail_zero (by norm_num) + +end MathPolishBoundary + +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + for (consumer, target) in #[ + (`MathPolishBoundary.raw_zero, `Sendov.scalarObstruction_zero), + (`MathPolishBoundary.tail_zero, `Sendov.distillT2_zero)] do + let some info := env.find? consumer | throwError "missing consumer {consumer}" + let some value := info.value? (allowOpaque := true) | throwError "missing proof value" + unless value.getUsedConstants.contains target do + throwError "not a real value consumer: {consumer} -> {target}" + logInfo m!"BOUNDARY_VALUE_CONSUMER {consumer} -> {target}" + for target in #[`Sendov.distillComponents_le_of_mixed, `Sendov.distillL_eq, + `Sendov.distillT0_nonneg, `Sendov.distillT1_nonneg, `Sendov.distillT2_nonneg, + `Sendov.QQ_zero, `Sendov.QQ_le_one] do + if env.contains target then throwError "retired declaration remains: {target}" + logInfo "BOUNDARY_PASS: actual zero identities consumed; seven retired declarations absent" diff --git a/tests/expected.json b/tests/expected.json new file mode 100644 index 0000000..a995e41 --- /dev/null +++ b/tests/expected.json @@ -0,0 +1,20 @@ +{ + "distillation": { + "Sendov/Common/DistillationFinite.lean": "97670634929b5a00e89af11202a4c86b2b5c17b2b7f858ef73fcee19df353ac2", + "Sendov/DistillationFinite/Row81.lean": "7f0565233bdc4eef09a2b63c6bcfa57dafee71958f25bc65fe62bcdb8fa15431", + "Sendov/DistillationFinite/Rows13_20.lean": "7cfbd3aac6f3639f5e8d0ecd9773386c000aa27479d2c75a5d196e252e812110", + "Sendov/DistillationFinite/Rows21_28.lean": "4259d6f25898cdee240186ef412cc47881909fe1d91ff613f46e116a642edd68", + "Sendov/DistillationFinite/Rows29_36.lean": "f3dfd178a770b4e1101f54f9bd1e82f9ed3e36cedc2960adc676a71b8d680a49", + "Sendov/DistillationFinite/Rows37_44.lean": "5b4a6770bf94696e2e9a9db986af37273eaaea6da3f3297756a51fa7378f81c1", + "Sendov/DistillationFinite/Rows45_52.lean": "0b6b601e18f4369f0faa0a2f15f3c59975efe564ebbf3bfafb938e4b48e2bd5f", + "Sendov/DistillationFinite/Rows53_60.lean": "ad156609407557c02747118bfd833813835fa781507df406e1707523d33d5ee5", + "Sendov/DistillationFinite/Rows5_12.lean": "f783474650bc285a809277a6998cb9c3767e143497271c596a686c7bbba3af24", + "Sendov/DistillationFinite/Rows61_68.lean": "05c54742bd3642cab76e77cfa0dafc4d98305ee5a98c5c5626c2e72e21bf4e9b", + "Sendov/DistillationFinite/Rows69_76.lean": "e4458cf4b612829411e207e52c649252bbc602a0c69b4505eb4e2a163e127333", + "Sendov/DistillationFinite/Rows77_80.lean": "bd82f21e648d564fc16f8146502258da08f1847734b8b7e014f8e49ca6af3bbd" + }, + "sinh": { + "sha256": "d04df2219415aa8e4f838c9c1b246b35af087e4ba41d4c449f95fe0f436c4acb", + "bytes": 15024 + } +} diff --git a/tests/test_axiom_audit.py b/tests/test_axiom_audit.py new file mode 100644 index 0000000..7281fbb --- /dev/null +++ b/tests/test_axiom_audit.py @@ -0,0 +1,153 @@ +"""Real offline Lean fixtures for the auditor, not proofs of Sendov.""" +import os +from pathlib import Path +import re +import shutil +import subprocess +import tempfile +import unittest + +REPO = Path(__file__).resolve().parents[1] +TOOLCHAIN = (REPO / 'lean-toolchain').read_text().strip() +ENV = dict(os.environ, ELAN_TOOLCHAIN=TOOLCHAIN) +ENV['PATH'] = str(Path.home() / '.elan/bin') + os.pathsep + ENV['PATH'] +TARGETS = ['SendovConjecture.sendov', 'SendovConjecture.phelps_rodriguez', 'Sendov.distillFinite_components', 'Sendov.distillFinite_scalar', 'Sendov.distillFiniteTailBase', 'Sendov.distillComponents_lt_two_thirds', 'Sendov.distillScalar_lt_two_thirds', 'Sendov.polar_origin_incompatible'] + + +def put(path, text): + path.parent.mkdir(parents=True, exist_ok=True) + path.write_text(text) + +def command(cmd, cwd, log): + run = subprocess.run(cmd, cwd=cwd, env=ENV, text=True, + stdout=subprocess.PIPE, stderr=subprocess.STDOUT) + put(LOGS / log, '$ ' + ' '.join(cmd) + '\n' + run.stdout + + f'\nPROCESS_EXIT={run.returncode}\n') + return run.returncode, run.stdout + +def fixture(name, mode, script_root, bad_target=None): + project = ROOT / 'work' / name + if project.exists(): + shutil.rmtree(project) + project.mkdir(parents=True) + put(project / 'lean-toolchain', TOOLCHAIN + '\n') + put(project / 'lakefile.toml', '''name = "audit_fixture" +version = "0.0.0" +[[lean_lib]] +name = "Fixture" +roots = ["Dependency", "Solution", "Sendov.Common.DistillationFinite", "Sendov.LargeDegree.DistillationTailBound"] +''') + dependency = 'theorem dependencyBridge : True := True.intro\n' + if mode == 'external': + dependency = ('axiom externalAssumption : True\n' + 'theorem dependencyBridge : True := externalAssumption\n') + elif mode == 'standard': + dependency = '''theorem dependencyBridge : True := + Eq.mp (propext (Iff.rfl : True ↔ True)) + (Eq.mp (congrArg (fun _ : Quot (fun _ _ : Nat => True) => True) + (Quot.sound (a := 0) (b := 1) (r := fun _ _ : Nat => True) True.intro)) + (Classical.choice (α := True) ⟨True.intro⟩)) +''' + put(project / 'Dependency.lean', dependency) + modules = { 'Solution.lean': TARGETS[:2], + 'Sendov/Common/DistillationFinite.lean': TARGETS[2:4], + 'Sendov/LargeDegree/DistillationTailBound.lean': TARGETS[4:] } + for module, targets in modules.items(): + text = 'import Dependency\n\n' + for target in targets: + if mode == 'missing' and target == bad_target: + continue + proof = ('dependencyBridge' if bad_target is None or target == bad_target + else 'True.intro') + text += f'theorem {target} : True := {proof}\n' + put(project / module, text) + # Deliberate statement-only holes required by audit.sh step 2, not imported. + put(project / 'Challenge.lean', 'theorem challengeA : True := by sorry\n' + 'theorem challengeB : True := by sorry\n') + for file in ['audit.sh', 'axioms.lean']: + put(project / 'scripts' / file, (script_root / 'scripts' / file).read_text()) + if mode == 'lean_error': + with (project / 'scripts/axioms.lean').open('a') as f: + f.write('\nexample : (0 : Nat) = 1 := by rfl\n') + scanned = [project / 'Solution.lean', *project.glob('Sendov/**/*.lean')] + assert not any(re.search(r'^\s*axiom\s', p.read_text(), re.M) for p in scanned) + return project + +def audit_case(name, mode, scripts, bad_target=None): + project = fixture(name, mode, scripts, bad_target) + code, output = command(['lake', 'build', 'Fixture'], project, name + '.build.log') + assert code == 0, f'fixture build failed: {name}: {output}' + return command(['sh', 'scripts/audit.sh'], project, name + '.audit.log') + +class AxiomAuditTests(unittest.TestCase): + @classmethod + def setUpClass(cls): + global ROOT, LOGS + cls.temporary = tempfile.TemporaryDirectory(prefix='sendov-audit-test-') + ROOT = Path(cls.temporary.name) + LOGS = ROOT / 'logs' + + @classmethod + def tearDownClass(cls): + cls.temporary.cleanup() + + def test_empty_and_standard_axioms_pass(self): + for mode in ['empty', 'standard']: + with self.subTest(mode=mode): + code, output = audit_case(mode, mode, REPO) + self.assertEqual(code, 0, output) + + def test_every_target_rejects_an_imported_nonstandard_axiom(self): + for i, target in enumerate(TARGETS): + with self.subTest(target=target): + code, output = audit_case(f'external-{i}', 'external', REPO, target) + self.assertNotEqual(code, 0, output) + self.assertIn(f'unexpected mathematical premise in {target}', output) + self.assertIn('externalAssumption', output) + + def test_every_missing_target_and_real_lean_error_fail(self): + for i, target in enumerate(TARGETS): + with self.subTest(target=target): + code, output = audit_case(f'missing-{i}', 'missing', REPO, target) + self.assertNotEqual(code, 0, output) + self.assertIn(f'missing audit declaration {target}', output) + code, output = audit_case('lean-error', 'lean_error', REPO) + self.assertNotEqual(code, 0, output) + self.assertIn('Lean axiom query failed', output) + + def test_only_the_known_tactic_partial_signatures_are_allowed(self): + for mode in ['known', 'extra', 'wrong-signature']: + with self.subTest(mode=mode): + project = fixture('partial-' + mode, 'empty', REPO) + for rel in ['Sendov/Common/BernsteinCert.lean', 'Sendov/Common/BernsteinRing.lean']: + put(project / rel, (REPO / rel).read_text()) + if mode == 'extra': + put(project / 'Sendov/Unexpected.lean', 'partial def unexpected (n : Nat) : Nat := n\n') + elif mode == 'wrong-signature': + path = project / 'Sendov/Common/BernsteinRing.lean' + path.write_text(path.read_text().replace('flatten (e : Expr) (op : Name)', + 'flatten (e : Expr) (op : Nat)')) + code, output = command(['lake', 'build', 'Fixture'], project, mode + '.build.log') + self.assertEqual(code, 0, output) + code, output = command(['sh', 'scripts/audit.sh'], project, mode + '.audit.log') + if mode == 'known': + self.assertEqual(code, 0, output) + else: + self.assertNotEqual(code, 0, output) + self.assertIn('partial def', output) + + def test_removing_the_allowlist_reopens_the_actual_false_green(self): + mutant = ROOT / 'mutant' + for name in ['audit.sh', 'axioms.lean']: + put(mutant / 'scripts' / name, (REPO / 'scripts' / name).read_text()) + path = mutant / 'scripts/axioms.lean' + source = path.read_text() + old = 'unless axioms.all allowed.contains do' + self.assertEqual(source.count(old), 1) + path.write_text(source.replace(old, 'unless axioms.all (fun a => allowed.contains a || true) do')) + code, output = audit_case('mutant-external', 'external', mutant) + self.assertEqual(code, 0, output) + self.assertIn('externalAssumption', output) + +if __name__ == '__main__': + unittest.main() diff --git a/tests/test_bundle_rows.py b/tests/test_bundle_rows.py new file mode 100644 index 0000000..a54a23c --- /dev/null +++ b/tests/test_bundle_rows.py @@ -0,0 +1,60 @@ +from pathlib import Path +import importlib.util +import tempfile +import unittest + +ROOT = Path(__file__).resolve().parents[1] / 'scripts' +spec = importlib.util.spec_from_file_location('bundle_rows', ROOT / 'bundle_rows.py') +bundle_rows = importlib.util.module_from_spec(spec) +spec.loader.exec_module(bundle_rows) + +class Bundling(unittest.TestCase): + def fixture(self, root): + source = root / 'input' + rows = source / 'Sendov/DistillationFinite' + rows.mkdir(parents=True) + (source / 'Sendov/Common').mkdir() + for m in range(5, 82): + (rows / f'Row{m}.lean').write_text( + 'import Mathlib.Data.Nat.Basic\n\n' + f'namespace FixtureRow{m}\ntheorem value : (1 : Nat) = 1 := rfl\nend FixtureRow{m}\n') + (source / 'Sendov/Common/DistillationFinite.lean').write_text(''.join( + f'import Sendov.DistillationFinite.Row{m}\n' for m in range(5, 82)) + '\n-- aggregate body\n') + return source + + def test_all_rows_once_in_original_order_and_bodies_preserved(self): + with tempfile.TemporaryDirectory() as temporary: + root = Path(temporary); source = self.fixture(root) + result = bundle_rows.bundle(source, root / 'out', size=8) + self.assertEqual([m for group in result['groups'] for m in group['rows']], list(range(5, 82))) + for group in result['groups']: + text = (root / 'out' / group['path']).read_text() + for m in group['rows']: + original = (source / f'Sendov/DistillationFinite/Row{m}.lean').read_text() + body = ''.join(x for x in original.splitlines(keepends=True) if not x.startswith('import ')) + self.assertIn(body, text) + self.assertTrue((root / 'out/Sendov/DistillationFinite/Row81.lean').is_file()) + self.assertFalse((root / 'out/Sendov/DistillationFinite/Row46.lean').exists()) + aggregate = (root / 'out/Sendov/Common/DistillationFinite.lean').read_text() + self.assertNotIn('import Sendov.DistillationFinite.Row46\n', aggregate) + self.assertTrue(aggregate.endswith('\n-- aggregate body\n')) + + def test_missing_row_fails_before_output(self): + with tempfile.TemporaryDirectory() as temporary: + root = Path(temporary); source = self.fixture(root) + (source / 'Sendov/DistillationFinite/Row6.lean').unlink() + with self.assertRaisesRegex(ValueError, 'rows'): + bundle_rows.bundle(source, root / 'out') + self.assertFalse((root / 'out').exists()) + + def test_duplicate_or_omitted_aggregate_import_is_not_repaired(self): + with tempfile.TemporaryDirectory() as temporary: + root = Path(temporary); source = self.fixture(root) + aggregate = source / 'Sendov/Common/DistillationFinite.lean' + aggregate.write_text(aggregate.read_text().replace('Row6\n', 'Row5\n')) + with self.assertRaisesRegex(ValueError, 'aggregate'): + bundle_rows.bundle(source, root / 'out') + self.assertFalse((root / 'out').exists()) + +if __name__ == '__main__': + unittest.main() diff --git a/tests/test_generator_core.py b/tests/test_generator_core.py new file mode 100644 index 0000000..7544341 --- /dev/null +++ b/tests/test_generator_core.py @@ -0,0 +1,143 @@ +"""Exact-core regressions and publication I/O fault injection (never mocked math).""" +from fractions import Fraction as F +import json +from math import comb +from pathlib import Path +import sys +import tempfile +import unittest +from unittest.mock import patch + +sys.path.insert(0, str(Path(__file__).resolve().parents[1] / 'scripts')) +import gen_distillation as g +import generator_output + + +class ExactCoreTests(unittest.TestCase): + def test_real_pilot_uses_raw_coefficient_list(self): + row = next(r for r in json.loads(g.TABLE.read_text()) if r['m'] == 46) + text = g.row_source(row) + self.assertIn('BernsteinCert.coeffs_pos', text) + self.assertNotIn('have hid', text) + self.assertNotIn('sign_0_left_0', text) + + def test_empty_polynomial_and_bad_interval_are_rejected(self): + with self.assertRaisesRegex(ValueError, 'empty'): + g.certificate([], F(0), F(1)) + with self.assertRaisesRegex(ValueError, 'interval'): + g.certificate([1], F(1), F(0)) + with self.assertRaisesRegex(ValueError, 'component'): + g.coefficients(5, 3) + + def test_all_actual_sign_certificates_by_coefficient_reconstruction(self): + # Expand the Bernstein basis back into powers, independently of the + # renderer's change-of-basis implementation. No sampled evaluations. + rows = json.loads(g.TABLE.read_text()) + for row in rows: + m = row['m'] + for component in row['components']: + j = component['index'] + for side, a, b in [('left', F(0), F(component['lo'])), + ('right', F(component['hi']), min(F(17), F(m, 2)))]: + if a == b: + continue # empty flank has an explicit False.elim proof + with self.subTest(m=m, component=j, side=side): + p = g.coefficients(m, j) + if (j == 0) != (side == 'left'): + p = [-c for c in p] + [(lo, hi, scale, cs)] = g.sign_cover(p, a, b) + n = len(p) - 1 + reconstructed = [F(0)] * len(p) + for i, coefficient in enumerate(cs): + for u in range(i + 1): + for v in range(n - i + 1): + reconstructed[u+v] += (coefficient * comb(i, u) + * (-lo)**(i-u) * comb(n-i, v) * hi**(n-i-v) * (-1)**v) + self.assertEqual(reconstructed, [scale*c for c in p]) + self.assertGreaterEqual(min(cs), 0) + self.assertGreater(cs[0], 0) + self.assertGreater(cs[-1], 0) + + def test_sign_cover_gap_overlap_and_negative_polynomial_are_rejected(self): + for intervals in ([], [(F(0), F(1)), (F(2), F(3))], + [(F(0), F(2)), (F(1), F(3))]): + with self.assertRaises(ValueError): + g.validate_cover(intervals, F(0), F(3)) + with self.assertRaises(ValueError): + g.sign_cover([-1], F(0), F(1)) + + +class PublicationTests(unittest.TestCase): + def test_staging_write_failure_leaves_empty_target_and_cleans_staging(self): + with tempfile.TemporaryDirectory() as temporary: + parent = Path(temporary) + output = parent / 'output' + output.mkdir() + before = output.stat().st_ino + actual_write = Path.write_text + calls = 0 + + def fail_seventh(path, *args, **kwargs): + nonlocal calls + calls += 1 + if calls == 7: + raise OSError('injected seventh staging write failure') + return actual_write(path, *args, **kwargs) + + with patch.object(Path, 'write_text', fail_seventh): + with self.assertRaisesRegex(OSError, 'seventh'): + g.generate(output) + self.assertEqual(output.stat().st_ino, before) + self.assertEqual(list(output.iterdir()), []) + self.assertEqual(list(parent.iterdir()), [output]) + + def test_publish_failure_preserves_empty_target(self): + with tempfile.TemporaryDirectory() as temporary: + parent = Path(temporary) + output = parent / 'output' + output.mkdir() + before = output.stat().st_ino + with patch.object(g.os, 'replace', side_effect=OSError('injected publish failure')): + with self.assertRaisesRegex(OSError, 'publish'): + g.generate(output) + self.assertEqual(output.stat().st_ino, before) + self.assertEqual(list(output.iterdir()), []) + self.assertEqual(list(parent.iterdir()), [output]) + + def test_real_rename_refuses_late_nonempty_target(self): + with tempfile.TemporaryDirectory() as temporary: + parent = Path(temporary) + output = parent / 'output' + actual_replace = g.os.replace + + def competing_output(source, target): + target.mkdir() + (target / 'sentinel').write_bytes(b'competing output') + return actual_replace(source, target) + + with patch.object(g.os, 'replace', competing_output): + with self.assertRaises(OSError): + g.generate(output) + self.assertEqual((output / 'sentinel').read_bytes(), b'competing output') + self.assertEqual(list(parent.iterdir()), [output]) + + def test_writer_success_replaces_target_and_cleans_staging(self): + with tempfile.TemporaryDirectory() as temporary: + output = Path(temporary) / 'file.lean' + output.write_bytes(b'old') + generator_output.write_lean(output, 'new α\n') + self.assertEqual(output.read_bytes(), 'new α\n'.encode()) + self.assertEqual(list(Path(temporary).iterdir()), [output]) + + def test_writer_rejected_source_preserves_previous_file(self): + with tempfile.TemporaryDirectory() as temporary: + output = Path(temporary) / 'file.lean' + output.write_bytes(b'old') + with self.assertRaises(TypeError): + generator_output.write_lean(output, object()) + self.assertEqual(output.read_bytes(), b'old') + self.assertEqual(list(Path(temporary).iterdir()), [output]) + + +if __name__ == '__main__': + unittest.main() diff --git a/tests/test_generators.py b/tests/test_generators.py new file mode 100644 index 0000000..6b0eee2 --- /dev/null +++ b/tests/test_generators.py @@ -0,0 +1,237 @@ +"""Portable active-route generator tests. Run with unittest, using Python with SymPy. + +The digest fixture pins the accepted mathematical source (only the generator-path +comment changed). It is shipped here; no workspace report or external fixture is read. +These are Python regressions, not Lean acceptance tests. +""" +import hashlib +import json +import os +from pathlib import Path +import shutil +import subprocess +import sys +import tempfile +import unittest + +ROOT = Path(__file__).resolve().parents[1] +EXPECTED = json.loads((Path(__file__).with_name('expected.json')).read_text()) + + +def digest(path): + return hashlib.sha256(path.read_bytes()).hexdigest() + + +def inventory(root): + result = {} + for path in root.rglob('*'): + if path.is_symlink(): + value = ('symlink', os.readlink(path)) + elif path.is_dir(): + value = ('directory',) + else: + value = ('file', path.read_bytes()) + result[str(path.relative_to(root))] = value + return result + + +class GeneratorTests(unittest.TestCase): + def setUp(self): + self.temp = tempfile.TemporaryDirectory() + self.addCleanup(self.temp.cleanup) + self.work = Path(self.temp.name) + self.repo = self.work / 'relocated-source' + self.repo.mkdir() + for directory in ('scripts', 'data'): + if (ROOT / directory).exists(): + shutil.copytree(ROOT / directory, self.repo / directory, + ignore=shutil.ignore_patterns('__pycache__')) + (self.repo / 'scripts').mkdir(exist_ok=True) + self.elsewhere = self.work / 'unrelated' + self.elsewhere.mkdir() + + def cli(self, script, *args, cwd=None, optimized=False): + return subprocess.run([sys.executable, '-B', *(['-O'] if optimized else []), + str(self.repo / 'scripts' / script), *map(str, args)], + cwd=cwd or self.elsewhere, capture_output=True, text=True, + env={**os.environ, 'PYTHONDONTWRITEBYTECODE': '1'}, timeout=120) + + def assert_success(self, result): + self.assertEqual(result.returncode, 0, result.stdout + result.stderr) + + def assert_distillation(self, output): + actual = {str(p.relative_to(output)): digest(p) for p in output.rglob('*') if p.is_file()} + self.assertEqual(actual, EXPECTED['distillation']) + aggregate = (output / 'Sendov/Common/DistillationFinite.lean').read_text() + self.assertEqual(aggregate.count(' · exact (distillFinite_'), 77) + self.assertTrue((output / 'Sendov/DistillationFinite/Row81.lean').is_file()) + self.assertFalse((output / 'Sendov/DistillationFinite/Row5.lean').exists()) + + def test_complete_cli_regeneration_from_all_cwds(self): + for i, cwd in enumerate((self.repo, self.repo / 'scripts', self.elsewhere)): + with self.subTest(cwd=cwd): + output = self.work / f'generated-{i}' + if i == 1: + output.mkdir() # explicitly empty targets are accepted too + result = self.cli('gen_distillation.py', '--output', output, cwd=cwd) + self.assert_success(result) + self.assert_distillation(output) + + def test_sinh_explicit_and_default_outputs_from_all_cwds(self): + for i, cwd in enumerate((self.repo, self.repo / 'scripts', self.elsewhere)): + with self.subTest(cwd=cwd): + output = self.work / f'Sinh-{i}.lean' + self.assert_success(self.cli('gen_sinh.py', '--output', output, cwd=cwd)) + self.assertEqual(digest(output), EXPECTED['sinh']['sha256']) + self.assertEqual(output.stat().st_size, EXPECTED['sinh']['bytes']) + self.assert_success(self.cli('gen_sinh.py', cwd=cwd)) + self.assertEqual(output.read_bytes(), + (self.repo / 'Sendov/Common/Sinh.lean').read_bytes()) + + + def test_bad_data_is_rejected_before_any_publication(self): + original = json.loads((self.repo / 'data/paper_certificate_table.json').read_text()) + mutations = { + 'missing row': lambda r: r.pop(), + 'duplicate row': lambda r: r.__setitem__(1, r[0]), + 'row order': lambda r: r.reverse(), + 'missing component': lambda r: r[0]['components'].pop(), + 'component order': lambda r: r[0]['components'].reverse(), + 'boolean index': lambda r: r[0]['components'][0].__setitem__('index', False), + 'boolean degree': lambda r: r[0].__setitem__('m', True), + 'float degree': lambda r: r[0].__setitem__('m', 5.0), + 'false metadata': lambda r: r[0].__setitem__('e', '1/2'), + 'bad rational': lambda r: r[0].__setitem__('total', '1/0'), + 'changed total': lambda r: r[0].__setitem__('total', '1'), + 'changed square': lambda r: r[0]['components'][0].__setitem__('sq', '0'), + 'changed sign': lambda r: r[0]['components'][0].__setitem__('sign_lo', '0'), + 'bad budget': lambda r: r[0]['components'][0].__setitem__('u', 0), + 'bad bracket': lambda r: r[0]['components'][0].__setitem__('hi', '1/4'), + 'bad classification': lambda r: r[0]['components'][0].__setitem__('k', 'B'), + 'unknown field': lambda r: r[0].__setitem__('unused', 1), + 'missing field': lambda r: r[0]['components'][0].pop('sq'), + 'wrong container': lambda r: r[0].__setitem__('components', {}), + } + for name, mutation in mutations.items(): + with self.subTest(mutation=name): + rows = json.loads(json.dumps(original)) + mutation(rows) + table = self.work / 'bad.json' + table.write_text(json.dumps(rows)) + output = self.work / ('invalid-' + name.replace(' ', '-')) + output.mkdir(exist_ok=True) + before = inventory(self.work) + result = self.cli('gen_distillation.py', '--table', table, '--output', output, + optimized=True) + self.assertNotEqual(result.returncode, 0, name) + self.assertNotIn('Traceback', result.stderr) + self.assertEqual(inventory(self.work), before) + self.assertEqual(list(output.iterdir()), []) + + def test_invalid_json_and_missing_inputs_do_not_create_output(self): + for text in ('{', '{"a":1,"a":2}', '[NaN]', '[Infinity]'): + with self.subTest(text=text): + table = self.work / 'bad.json' + table.write_text(text) + output = self.work / 'never-created' + result = self.cli('gen_distillation.py', '--table', table, '--output', output) + self.assertNotEqual(result.returncode, 0) + self.assertNotIn('Traceback', result.stderr) + self.assertFalse(output.exists()) + missing = self.cli('gen_distillation.py', '--table', self.work / 'missing.json', + '--output', self.work / 'never-created') + self.assertNotEqual(missing.returncode, 0) + self.assertFalse((self.work / 'never-created').exists()) + + + def test_output_argument_is_required_and_subset_options_are_removed(self): + before = inventory(self.work) + for args in ((), ('--rows', '5'), ('--mutation', 'budget')): + result = self.cli('gen_distillation.py', *args) + self.assertNotEqual(result.returncode, 0) + self.assertIn('--output', result.stderr) + self.assertEqual(inventory(self.work), before) + + def test_nonempty_file_and_symlink_targets_are_preserved(self): + directory = self.work / 'old' + directory.mkdir() + (directory / 'sentinel').write_bytes(b'original\x00bytes') + regular = self.work / 'regular' + regular.write_bytes(b'old-file') + link = self.work / 'link' + link.symlink_to(directory, target_is_directory=True) + for output in (directory, regular, link): + with self.subTest(output=output): + before = inventory(self.work) + result = self.cli('gen_distillation.py', '--output', output) + self.assertNotEqual(result.returncode, 0) + self.assertIn('new or empty directory', result.stderr) + self.assertEqual(inventory(self.work), before) + self.assertTrue(link.is_symlink()) + + def test_missing_default_table_or_helper_has_no_output(self): + for rel in ('data/paper_certificate_table.json', 'scripts/bundle_rows.py'): + with self.subTest(missing=rel): + path = self.repo / rel + saved = path.read_bytes() + path.unlink() + before = inventory(self.work) + result = self.cli('gen_distillation.py', '--output', self.work / 'out') + self.assertNotEqual(result.returncode, 0) + self.assertEqual(inventory(self.work), before) + self.assertFalse((self.work / 'out').exists()) + path.write_bytes(saved) + + def test_imports_have_no_generation_side_effects(self): + for cwd in (self.repo, self.repo / 'scripts', self.elsewhere): + with self.subTest(cwd=cwd): + before = inventory(self.work) + program = ('import sys; sys.path.insert(0, ' + repr(str(self.repo / 'scripts')) + + '); import gen_sinh, gen_distillation, generator_output, ' + 'bundle_rows, distillation_data') + result = subprocess.run([sys.executable, '-B', '-c', program], cwd=cwd, + capture_output=True, text=True, timeout=30) + self.assert_success(result) + self.assertEqual(result.stdout, '') + self.assertEqual(result.stderr, '') + self.assertEqual(inventory(self.work), before) + + def test_sinh_missing_tail_preserves_existing_target(self): + output = self.work / 'Sinh.lean' + output.write_bytes(b'old theorem source\n') + (self.repo / 'scripts/sinh_tail.lean.txt').unlink() + before = inventory(self.work) + result = self.cli('gen_sinh.py', '--output', output) + self.assertNotEqual(result.returncode, 0) + self.assertEqual(inventory(self.work), before) + + def test_sinh_actual_replace_failure_preserves_target(self): + output = self.work / 'Sinh.lean' + output.mkdir() + (output / 'sentinel').write_bytes(b'old theorem source\n') + before = inventory(self.work) + result = self.cli('gen_sinh.py', '--output', output) + self.assertNotEqual(result.returncode, 0) + self.assertEqual(inventory(self.work), before) + self.assertEqual(set(self.work.glob('.Sinh.lean.*.tmp')), set()) + + + def test_audit_propagates_lean_command_failure(self): + # A deliberately failing executable models a missing/broken Lean command, + # not a proof result. The shell audit must not turn its failure into PASS. + (self.repo / 'Sendov').mkdir() + (self.repo / 'Solution.lean').write_text('-- no proof in this I/O fixture\n') + (self.repo / 'Challenge.lean').write_text('sorry\nsorry\n') + bin_dir = self.work / 'bin' + bin_dir.mkdir() + lake = bin_dir / 'lake' + lake.write_text('#!/bin/sh\nexit 42\n') + lake.chmod(0o755) + result = subprocess.run(['sh', str(self.repo / 'scripts/audit.sh')], + cwd=self.elsewhere, capture_output=True, text=True, + env={**os.environ, 'PATH': str(bin_dir) + os.pathsep + os.environ['PATH']}) + self.assertNotEqual(result.returncode, 0, result.stdout + result.stderr) + + +if __name__ == '__main__': + unittest.main() From 29a7f572ca2dc5a6cd75106632f14724c6a80ae0 Mon Sep 17 00:00:00 2001 From: Methode Date: Sun, 13 Sep 2026 02:15:44 -0700 Subject: [PATCH 06/24] refactor(sendov): lower the proved tail to 64 and retire redundant certificates --- README.md | 14 +- Sendov/Common/DistillationBounds.lean | 13 +- Sendov/Common/DistillationFinite.lean | 29 +- Sendov/DistillationFinite/Row81.lean | 96 --- .../{Rows77_80.lean => Rows61_64.lean} | 192 ++--- Sendov/DistillationFinite/Rows61_68.lean | 754 ------------------ Sendov/DistillationFinite/Rows69_76.lean | 754 ------------------ Sendov/LargeDegree/DistillationTail.lean | 208 ++--- Sendov/LargeDegree/DistillationTailBound.lean | 33 +- data/README.md | 10 +- data/paper_certificate_table.json | 631 +-------------- docs/design.md | 32 +- docs/getting-started.md | 7 +- formalization.yaml | 18 +- scripts/GENERATORS.md | 17 +- scripts/axioms.lean | 10 +- scripts/bundle_rows.py | 19 +- scripts/distillation_data.py | 14 +- scripts/gen_distillation.py | 26 +- tests/BoundaryConsumer.lean | 18 +- tests/EarlierTail.lean | 144 ++++ tests/expected.json | 8 +- tests/test_axiom_audit.py | 54 +- tests/test_bundle_rows.py | 22 +- tests/test_generator_core.py | 46 ++ tests/test_generators.py | 21 +- 26 files changed, 621 insertions(+), 2569 deletions(-) delete mode 100644 Sendov/DistillationFinite/Row81.lean rename Sendov/DistillationFinite/{Rows77_80.lean => Rows61_64.lean} (70%) delete mode 100644 Sendov/DistillationFinite/Rows61_68.lean delete mode 100644 Sendov/DistillationFinite/Rows69_76.lean create mode 100644 tests/EarlierTail.lean diff --git a/README.md b/README.md index 9daf2c1..fca8b1a 100644 --- a/README.md +++ b/README.md @@ -34,10 +34,14 @@ trusted facts.[2] | Real-parameter tail using the actual base certificate | [`DistillationTailBound`](Sendov/LargeDegree/DistillationTailBound.lean) | | Complete contradiction | [`DistillationBounds`](Sendov/Common/DistillationBounds.lean), [`Reduction/Main`](Sendov/Reduction/Main.lean) | -The convention is **`m = n - 1`**. The finite proof covers all `5 ≤ m ≤ 81`; -the tail is proved for every real `m ≥ 81` and uses the certified `m=81` case. -The final degree split uses the finite proof through `n=82`, then the tail. -Both are parts of the same scalar argument. +The convention is **`m = n - 1`**. The final degree split now uses the finite +proof for `5 ≤ m ≤ 63` (through `n=64`), then the real-parameter tail for +`m ≥ 64` (from `n=65`). The latter reuses the existing row-64 certificate +to prove a bound of `<199/200`, which is sufficient for the scalar `<1`. +Exactly 60 unchanged certificate records, `5 ≤ m ≤ 64`, are retained. The finite +aggregate consumes 59 cases; the tail consumes row 64 from the shared final +group `Rows61_64`. Rows 65–81 and the old `<2/3` tail interfaces are retired. +There is no separate duplicate row-64 module or second certificate representation. Each finite case uses the complete critical polynomials of degrees **7, 7, 4**. Exact Bernstein identities prove derivative signs on the full outer intervals; @@ -70,7 +74,7 @@ is not reported as all of them. See [`docs/getting-started.md`](docs/getting-started.md) for verification and [`scripts/GENERATORS.md`](scripts/GENERATORS.md) for reproducible generation. -The finite generator emits the entire table in one command to a fresh output +The finite generator emits the entire selected table in one command to a fresh output root. Python prepares exact data; Lean verifies the complete identities and inequalities. A successful generator run is **not** a completed proof check. diff --git a/Sendov/Common/DistillationBounds.lean b/Sendov/Common/DistillationBounds.lean index a107351..7ca452d 100644 --- a/Sendov/Common/DistillationBounds.lean +++ b/Sendov/Common/DistillationBounds.lean @@ -5,8 +5,9 @@ import Sendov.LargeDegree.DistillationTailBound # The complete scalar upper bound The original degree is `n`; the scalar parameter is `m = n - 1`. -The certified finite range covers `5 ≤ m ≤ 81`. Above it, the proved -real-degree tail uses the same degree-81 critical-point certificate. +The scalar consumer uses finite rows for `5 ≤ m ≤ 63` and the real-degree +tail based on the existing row 64 for `m ≥ 64`. These disjoint ranges cover +every natural `m ≥ 5`; exactly the 60 records from 5 through 64 are retained. -/ namespace Sendov @@ -21,9 +22,9 @@ theorem distillScalar_lt_one {n : ℕ} (hn : 6 ≤ n) {α : ℝ} simp [M] have hm : 5 ≤ n - 1 := by omega rw [← hM] at hhalf ⊢ - by_cases hfinite : n - 1 ≤ 81 - · exact (distillFinite_scalar hm hfinite hα (by linarith) h17).trans (by norm_num) - · have hlarge : (81 : ℝ) ≤ (n - 1 : ℕ) := by exact_mod_cast (show 81 ≤ n - 1 by omega) - exact (distillScalar_lt_two_thirds hlarge hα h17).trans (by norm_num) + by_cases hfinite : n - 1 < 64 + · exact (distillFinite_scalar hm (by omega) hα (by linarith) h17).trans (by norm_num) + · have hlarge : (64 : ℝ) ≤ (n - 1 : ℕ) := by exact_mod_cast (show 64 ≤ n - 1 by omega) + exact (distillScalar_lt_199_200 hlarge hα h17).trans (by norm_num) end Sendov diff --git a/Sendov/Common/DistillationFinite.lean b/Sendov/Common/DistillationFinite.lean index f57ebbc..9a9ecd2 100644 --- a/Sendov/Common/DistillationFinite.lean +++ b/Sendov/Common/DistillationFinite.lean @@ -5,16 +5,13 @@ import Sendov.DistillationFinite.Rows29_36 import Sendov.DistillationFinite.Rows37_44 import Sendov.DistillationFinite.Rows45_52 import Sendov.DistillationFinite.Rows53_60 -import Sendov.DistillationFinite.Rows61_68 -import Sendov.DistillationFinite.Rows69_76 -import Sendov.DistillationFinite.Rows77_80 -import Sendov.DistillationFinite.Row81 +import Sendov.DistillationFinite.Rows61_64 /-! Exact finite-domain critical-bracket closure. Fixed original paper budgets; see DistillationCriticalFinite for attribution. No sampled truth or global T grid. -/ namespace Sendov -theorem distillFinite_components {m : ℕ} (hm : 5 ≤ m) (hm81 : m ≤ 81) +theorem distillFinite_components {m : ℕ} (hm : 5 ≤ m) (hm63 : m ≤ 63) {α : ℝ} (hα : 0 ≤ α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := by interval_cases m @@ -77,30 +74,12 @@ theorem distillFinite_components {m : ℕ} (hm : 5 ≤ m) (hm81 : m ≤ 81) · exact (distillFinite_61 α hα (by linarith)).trans_lt distillFiniteBound_61 · exact (distillFinite_62 α hα (by linarith)).trans_lt distillFiniteBound_62 · exact (distillFinite_63 α hα (by linarith)).trans_lt distillFiniteBound_63 - · exact (distillFinite_64 α hα (by linarith)).trans_lt distillFiniteBound_64 - · exact (distillFinite_65 α hα (by linarith)).trans_lt distillFiniteBound_65 - · exact (distillFinite_66 α hα (by linarith)).trans_lt distillFiniteBound_66 - · exact (distillFinite_67 α hα (by linarith)).trans_lt distillFiniteBound_67 - · exact (distillFinite_68 α hα (by linarith)).trans_lt distillFiniteBound_68 - · exact (distillFinite_69 α hα (by linarith)).trans_lt distillFiniteBound_69 - · exact (distillFinite_70 α hα (by linarith)).trans_lt distillFiniteBound_70 - · exact (distillFinite_71 α hα (by linarith)).trans_lt distillFiniteBound_71 - · exact (distillFinite_72 α hα (by linarith)).trans_lt distillFiniteBound_72 - · exact (distillFinite_73 α hα (by linarith)).trans_lt distillFiniteBound_73 - · exact (distillFinite_74 α hα (by linarith)).trans_lt distillFiniteBound_74 - · exact (distillFinite_75 α hα (by linarith)).trans_lt distillFiniteBound_75 - · exact (distillFinite_76 α hα (by linarith)).trans_lt distillFiniteBound_76 - · exact (distillFinite_77 α hα (by linarith)).trans_lt distillFiniteBound_77 - · exact (distillFinite_78 α hα (by linarith)).trans_lt distillFiniteBound_78 - · exact (distillFinite_79 α hα (by linarith)).trans_lt distillFiniteBound_79 - · exact (distillFinite_80 α hα (by linarith)).trans_lt distillFiniteBound_80 - · exact (distillFinite_81 α hα (by linarith)).trans_lt distillFiniteBound_81 -theorem distillFinite_scalar {m : ℕ} (hm : 5 ≤ m) (hm81 : m ≤ 81) +theorem distillFinite_scalar {m : ℕ} (hm : 5 ≤ m) (hm63 : m ≤ 63) {α : ℝ} (hα : 0 < α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : scalarObstruction m α (cubicPolarEnvelope α) < 199 / 200 := by have hmR : (5 : ℝ) ≤ m := by exact_mod_cast hm exact (distillScalar_le_majorant hmR hα (by linarith)).trans_lt - (distillFinite_components hm hm81 hα.le hαm h17) + (distillFinite_components hm hm63 hα.le hαm h17) end Sendov diff --git a/Sendov/DistillationFinite/Row81.lean b/Sendov/DistillationFinite/Row81.lean deleted file mode 100644 index 612e137..0000000 --- a/Sendov/DistillationFinite/Row81.lean +++ /dev/null @@ -1,96 +0,0 @@ -import Sendov.Common.DistillationCriticalFinite -import Sendov.Common.BernsteinList - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow81 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 81 x := by - refine (BernsteinCert.coeffs_pos - [3603169980, 101281054752, 1089452610954, 5569802774496, 13692055572072, 15406547380731, - 10739679509790, 2733585354369] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 81 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 81 α ≤ (169 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 81 x := by - refine (BernsteinCert.coeffs_pos - [114359017320, 3357049129056, 38559316406976, 219267310218336, 647941970508930, - 983688471433584, 773066148894270, 207673649421240] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 81 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 81 α ≤ (1 / 250) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 78 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 81 x := by - refine (BernsteinCert.coeffs_pos - [5117580, 75467700, 308981574, 320029530, 71709640] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 81 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 81 α ≤ (201 / 1000) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 78 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow81 - -theorem distillFinite_81 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 81 + distillT0 81 α + distillT1 81 α + distillT2 81 α ≤ (76691 / 121500) := by - have h0 := CriticalRow81.component0 α hα hd - have h1 := CriticalRow81.component1 α hα hd - have h2 := CriticalRow81.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_81 : ((76691 / 121500) : ℝ) < 199 / 200 := by norm_num - -theorem distillFiniteTailBase {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : - distillEBudget 81 + distillT0 81 α + distillT1 81 α + distillT2 81 α < 2 / 3 := by - exact (distillFinite_81 α hα h17).trans_lt (by norm_num) - -end Sendov diff --git a/Sendov/DistillationFinite/Rows77_80.lean b/Sendov/DistillationFinite/Rows61_64.lean similarity index 70% rename from Sendov/DistillationFinite/Rows77_80.lean rename to Sendov/DistillationFinite/Rows61_64.lean index e831e2c..e4c47ef 100644 --- a/Sendov/DistillationFinite/Rows77_80.lean +++ b/Sendov/DistillationFinite/Rows61_64.lean @@ -7,13 +7,13 @@ section Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ namespace Sendov -namespace CriticalRow77 +namespace CriticalRow61 private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 77 x := by + 0 ≤ distillCritical0 61 x := by refine (BernsteinCert.coeffs_pos - [3250100700, 91270395648, 980442853722, 5002636649328, 12265694207832, 13795938783251, - 9753142170998, 2399109206577] + [2019781980, 56430214272, 601686039834, 3036073584816, 7326547127832, 8167105809971, + 6087236209110, 1044305251249] (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 @@ -22,21 +22,21 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : bernstein_ring (x - 0) (17 - x) private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 77 x := by + 0 ≤ -distillCritical0 61 x := by exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 77 α ≤ (179 / 1000) := by + distillT0 61 α ≤ (57 / 250) := by apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 77 x := by + 0 ≤ -distillCritical1 61 x := by refine (BernsteinCert.coeffs_pos - [98145182520, 2879234526384, 33041479591152, 187650567483408, 553508517114798, - 838312789511740, 656563885788802, 170958887261724] + [48537024120, 1418814495216, 16199029223856, 91304072373456, 266199727275870, + 395856838633324, 299684953990290, 59281036043180] (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 @@ -45,21 +45,21 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : bernstein_ring (x - 0) (17 - x) private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 77 x := by + 0 ≤ distillCritical1 61 x := by exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 77 α ≤ (7 / 1000) := by + distillT1 61 α ≤ (13 / 250) := by apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 74 (by norm_num) (by norm_num) + 58 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 77 x := by + 0 ≤ -distillCritical2 61 x := by refine (BernsteinCert.coeffs_pos - [4615380, 67914180, 276499146, 280039874, 57151092] + [2865780, 41674500, 164428314, 144912610, 9604580] (lo := 0) (hi := 17) (s := 83521) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 @@ -68,28 +68,28 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : bernstein_ring (x - 0) (17 - x) private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 77 x := by + 0 ≤ distillCritical2 61 x := by exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 77 α ≤ (233 / 1000) := by + distillT2 61 α ≤ (81 / 250) := by apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 74 (by norm_num) (by norm_num) + 58 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] -end CriticalRow77 +end CriticalRow61 -theorem distillFinite_77 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 77 + distillT0 77 α + distillT1 77 α + distillT2 77 α ≤ (22327 / 33000) := by - have h0 := CriticalRow77.component0 α hα hd - have h1 := CriticalRow77.component1 α hα hd - have h2 := CriticalRow77.component2 α hα hd +theorem distillFinite_61 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 61 + distillT0 61 α + distillT1 61 α + distillT2 61 α ≤ (19754 / 22875) := by + have h0 := CriticalRow61.component0 α hα hd + have h1 := CriticalRow61.component1 α hα hd + have h2 := CriticalRow61.component2 α hα hd norm_num [distillEBudget] at * linarith -theorem distillFiniteBound_77 : ((22327 / 33000) : ℝ) < 199 / 200 := by norm_num +theorem distillFiniteBound_61 : ((19754 / 22875) : ℝ) < 199 / 200 := by norm_num end Sendov @@ -101,13 +101,13 @@ section Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ namespace Sendov -namespace CriticalRow78 +namespace CriticalRow62 private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 78 x := by + 0 ≤ distillCritical0 62 x := by refine (BernsteinCert.coeffs_pos - [3336662160, 93724287408, 1007158272264, 5141595979656, 12615100501608, 14190963419340, - 9997149223884, 2482886675064] + [2088147600, 58363860528, 622673236872, 3144822771528, 7599323583912, 8480770304396, + 6303218922668, 1129772656152] (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 @@ -116,21 +116,21 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : bernstein_ring (x - 0) (17 - x) private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 78 x := by + 0 ≤ -distillCritical0 62 x := by exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 78 α ≤ (22 / 125) := by + distillT0 62 α ≤ (28 / 125) := by apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 78 x := by + 0 ≤ -distillCritical1 62 x := by refine (BernsteinCert.coeffs_pos - [102044545200, 2994130674144, 34368065563968, 195250108084416, 576202373391132, - 873252628707960, 684593930448708, 179787806155656] + [50985151920, 1490806806624, 17028105515712, 96038256547008, 280290993952668, + 417554234747800, 317279147669572, 64723256786664] (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 @@ -139,21 +139,21 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : bernstein_ring (x - 0) (17 - x) private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 78 x := by + 0 ≤ distillCritical1 62 x := by exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 78 α ≤ (3 / 500) := by + distillT1 62 α ≤ (23 / 500) := by apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 75 (by norm_num) (by norm_num) + 59 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 78 x := by + 0 ≤ -distillCritical2 62 x := by refine (BernsteinCert.coeffs_pos - [4738500, 69765300, 284452326, 289804494, 60690532] + [2962980, 43128180, 170595606, 152194094, 12075252] (lo := 0) (hi := 17) (s := 83521) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 @@ -162,28 +162,28 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : bernstein_ring (x - 0) (17 - x) private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 78 x := by + 0 ≤ distillCritical2 62 x := by exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 78 α ≤ (9 / 40) := by + distillT2 62 α ≤ (323 / 1000) := by apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 75 (by norm_num) (by norm_num) + 59 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] -end CriticalRow78 +end CriticalRow62 -theorem distillFinite_78 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 78 + distillT0 78 α + distillT1 78 α + distillT2 78 α ≤ (9718 / 14625) := by - have h0 := CriticalRow78.component0 α hα hd - have h1 := CriticalRow78.component1 α hα hd - have h2 := CriticalRow78.component2 α hα hd +theorem distillFinite_62 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 62 + distillT0 62 α + distillT1 62 α + distillT2 62 α ≤ (39637 / 46500) := by + have h0 := CriticalRow62.component0 α hα hd + have h1 := CriticalRow62.component1 α hα hd + have h2 := CriticalRow62.component2 α hα hd norm_num [distillEBudget] at * linarith -theorem distillFiniteBound_78 : ((9718 / 14625) : ℝ) < 199 / 200 := by norm_num +theorem distillFiniteBound_62 : ((39637 / 46500) : ℝ) < 199 / 200 := by norm_num end Sendov @@ -195,13 +195,13 @@ section Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ namespace Sendov -namespace CriticalRow79 +namespace CriticalRow63 private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 79 x := by + 0 ≤ distillCritical0 63 x := by refine (BernsteinCert.coeffs_pos - [3424360860, 96210694512, 1034231704650, 5282443443960, 12969296160240, 14591073064283, - 10242907797978, 2566558522525] + [2157650460, 60330022128, 644018447754, 3255460092216, 7876889404848, 8799519807675, + 6520953157434, 1215134440029] (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 @@ -210,21 +210,21 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : bernstein_ring (x - 0) (17 - x) private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 79 x := by + 0 ≤ -distillCritical0 63 x := by exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 79 α ≤ (87 / 500) := by + distillT0 63 α ≤ (221 / 1000) := by apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 79 x := by + 0 ≤ -distillCritical1 63 x := by refine (BernsteinCert.coeffs_pos - [106045763760, 3112039204776, 35729598214584, 203050999083960, 599500663992096, - 909120638348446, 713348642030520, 188848341604130] + [53514140400, 1565188643304, 17884877054328, 100931879360376, 294861005590032, + 439990591421070, 335461676533128, 70359545058546] (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 @@ -233,21 +233,21 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : bernstein_ring (x - 0) (17 - x) private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 79 x := by + 0 ≤ distillCritical1 63 x := by exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 79 α ≤ (3 / 500) := by + distillT1 63 α ≤ (41 / 1000) := by apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 76 (by norm_num) (by norm_num) + 60 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 79 x := by + 0 ≤ -distillCritical2 63 x := by refine (BernsteinCert.coeffs_pos - [4863240, 71641260, 292517124, 299724310, 64296770] + [3061800, 44606700, 176874516, 159630774, 14612722] (lo := 0) (hi := 17) (s := 83521) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 @@ -256,28 +256,28 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : bernstein_ring (x - 0) (17 - x) private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 79 x := by + 0 ≤ distillCritical2 63 x := by exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 79 α ≤ (217 / 1000) := by + distillT2 63 α ≤ (8 / 25) := by apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 76 (by norm_num) (by norm_num) + 60 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] -end CriticalRow79 +end CriticalRow63 -theorem distillFinite_79 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 79 + distillT0 79 α + distillT1 79 α + distillT2 79 α ≤ (155089 / 237000) := by - have h0 := CriticalRow79.component0 α hα hd - have h1 := CriticalRow79.component1 α hα hd - have h2 := CriticalRow79.component2 α hα hd +theorem distillFinite_63 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 63 + distillT0 63 α + distillT1 63 α + distillT2 63 α ≤ (11357 / 13500) := by + have h0 := CriticalRow63.component0 α hα hd + have h1 := CriticalRow63.component1 α hα hd + have h2 := CriticalRow63.component2 α hα hd norm_num [distillEBudget] at * linarith -theorem distillFiniteBound_79 : ((155089 / 237000) : ℝ) < 199 / 200 := by norm_num +theorem distillFiniteBound_63 : ((11357 / 13500) : ℝ) < 199 / 200 := by norm_num end Sendov @@ -289,13 +289,13 @@ section Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ namespace Sendov -namespace CriticalRow80 +namespace CriticalRow64 private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 80 x := by + 0 ≤ distillCritical0 64 x := by refine (BernsteinCert.coeffs_pos - [3513196800, 98729616960, 1061663150880, 5425179042240, 13328281183728, 14996267718080, - 10490417893280, 2650124748960] + [2228290560, 62328699072, 665721672480, 3367985546880, 8159244590640, 9123354319808, + 6740438913408, 1300390602880] (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 @@ -304,21 +304,21 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : bernstein_ring (x - 0) (17 - x) private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 80 x := by + 0 ≤ -distillCritical0 64 x := by exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 80 α ≤ (171 / 1000) := by + distillT0 64 α ≤ (217 / 1000) := by apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 80 x := by + 0 ≤ -distillCritical1 64 x := by refine (BernsteinCert.coeffs_pos - [110150150400, 3232999046880, 37126530757440, 211055859966960, 623411244502944, - 945928644051040, 742836541267840, 198142840421280] + [56125301760, 1641998933856, 18769797054144, 105987560298480, 309917617773216, + 463177734270976, 354241061314560, 76192247672960] (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 @@ -327,21 +327,21 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : bernstein_ring (x - 0) (17 - x) private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 80 x := by + 0 ≤ distillCritical1 64 x := by exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 80 α ≤ (1 / 200) := by + distillT1 64 α ≤ (37 / 1000) := by apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 77 (by norm_num) (by norm_num) + 61 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 80 x := by + 0 ≤ -distillCritical2 64 x := by refine (BernsteinCert.coeffs_pos - [4989600, 73542060, 300693540, 309799322, 67969806] + [3162240, 46110060, 183265044, 167222650, 17216990] (lo := 0) (hi := 17) (s := 83521) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 @@ -350,28 +350,28 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : bernstein_ring (x - 0) (17 - x) private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 80 x := by + 0 ≤ distillCritical2 64 x := by exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 80 α ≤ (209 / 1000) := by + distillT2 64 α ≤ (317 / 1000) := by apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 77 (by norm_num) (by norm_num) + 61 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] -end CriticalRow80 +end CriticalRow64 -theorem distillFinite_80 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 80 + distillT0 80 α + distillT1 80 α + distillT2 80 α ≤ (3083 / 4800) := by - have h0 := CriticalRow80.component0 α hα hd - have h1 := CriticalRow80.component1 α hα hd - have h2 := CriticalRow80.component2 α hα hd +theorem distillFinite_64 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 64 + distillT0 64 α + distillT1 64 α + distillT2 64 α ≤ (79691 / 96000) := by + have h0 := CriticalRow64.component0 α hα hd + have h1 := CriticalRow64.component1 α hα hd + have h2 := CriticalRow64.component2 α hα hd norm_num [distillEBudget] at * linarith -theorem distillFiniteBound_80 : ((3083 / 4800) : ℝ) < 199 / 200 := by norm_num +theorem distillFiniteBound_64 : ((79691 / 96000) : ℝ) < 199 / 200 := by norm_num end Sendov diff --git a/Sendov/DistillationFinite/Rows61_68.lean b/Sendov/DistillationFinite/Rows61_68.lean deleted file mode 100644 index 88e85a3..0000000 --- a/Sendov/DistillationFinite/Rows61_68.lean +++ /dev/null @@ -1,754 +0,0 @@ -import Sendov.Common.DistillationCriticalFinite -import Sendov.Common.BernsteinList - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow61 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 61 x := by - refine (BernsteinCert.coeffs_pos - [2019781980, 56430214272, 601686039834, 3036073584816, 7326547127832, 8167105809971, - 6087236209110, 1044305251249] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 61 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 61 α ≤ (57 / 250) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 61 x := by - refine (BernsteinCert.coeffs_pos - [48537024120, 1418814495216, 16199029223856, 91304072373456, 266199727275870, - 395856838633324, 299684953990290, 59281036043180] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 61 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 61 α ≤ (13 / 250) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 58 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 61 x := by - refine (BernsteinCert.coeffs_pos - [2865780, 41674500, 164428314, 144912610, 9604580] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 61 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 61 α ≤ (81 / 250) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 58 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow61 - -theorem distillFinite_61 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 61 + distillT0 61 α + distillT1 61 α + distillT2 61 α ≤ (19754 / 22875) := by - have h0 := CriticalRow61.component0 α hα hd - have h1 := CriticalRow61.component1 α hα hd - have h2 := CriticalRow61.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_61 : ((19754 / 22875) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow62 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 62 x := by - refine (BernsteinCert.coeffs_pos - [2088147600, 58363860528, 622673236872, 3144822771528, 7599323583912, 8480770304396, - 6303218922668, 1129772656152] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 62 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 62 α ≤ (28 / 125) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 62 x := by - refine (BernsteinCert.coeffs_pos - [50985151920, 1490806806624, 17028105515712, 96038256547008, 280290993952668, - 417554234747800, 317279147669572, 64723256786664] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 62 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 62 α ≤ (23 / 500) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 59 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 62 x := by - refine (BernsteinCert.coeffs_pos - [2962980, 43128180, 170595606, 152194094, 12075252] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 62 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 62 α ≤ (323 / 1000) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 59 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow62 - -theorem distillFinite_62 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 62 + distillT0 62 α + distillT1 62 α + distillT2 62 α ≤ (39637 / 46500) := by - have h0 := CriticalRow62.component0 α hα hd - have h1 := CriticalRow62.component1 α hα hd - have h2 := CriticalRow62.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_62 : ((39637 / 46500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow63 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 63 x := by - refine (BernsteinCert.coeffs_pos - [2157650460, 60330022128, 644018447754, 3255460092216, 7876889404848, 8799519807675, - 6520953157434, 1215134440029] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 63 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 63 α ≤ (221 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 63 x := by - refine (BernsteinCert.coeffs_pos - [53514140400, 1565188643304, 17884877054328, 100931879360376, 294861005590032, - 439990591421070, 335461676533128, 70359545058546] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 63 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 63 α ≤ (41 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 60 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 63 x := by - refine (BernsteinCert.coeffs_pos - [3061800, 44606700, 176874516, 159630774, 14612722] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 63 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 63 α ≤ (8 / 25) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 60 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow63 - -theorem distillFinite_63 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 63 + distillT0 63 α + distillT1 63 α + distillT2 63 α ≤ (11357 / 13500) := by - have h0 := CriticalRow63.component0 α hα hd - have h1 := CriticalRow63.component1 α hα hd - have h2 := CriticalRow63.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_63 : ((11357 / 13500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow64 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 64 x := by - refine (BernsteinCert.coeffs_pos - [2228290560, 62328699072, 665721672480, 3367985546880, 8159244590640, 9123354319808, - 6740438913408, 1300390602880] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 64 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 64 α ≤ (217 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 64 x := by - refine (BernsteinCert.coeffs_pos - [56125301760, 1641998933856, 18769797054144, 105987560298480, 309917617773216, - 463177734270976, 354241061314560, 76192247672960] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 64 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 64 α ≤ (37 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 61 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 64 x := by - refine (BernsteinCert.coeffs_pos - [3162240, 46110060, 183265044, 167222650, 17216990] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 64 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 64 α ≤ (317 / 1000) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 61 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow64 - -theorem distillFinite_64 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 64 + distillT0 64 α + distillT1 64 α + distillT2 64 α ≤ (79691 / 96000) := by - have h0 := CriticalRow64.component0 α hα hd - have h1 := CriticalRow64.component1 α hα hd - have h2 := CriticalRow64.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_64 : ((79691 / 96000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow65 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 65 x := by - refine (BernsteinCert.coeffs_pos - [2300067900, 64359891360, 687782911050, 3482399135520, 8446389141288, 9452273840795, - 6961676190590, 1385541144705] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 65 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 65 α ≤ (107 / 500) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 65 x := by - refine (BernsteinCert.coeffs_pos - [58819948200, 1721276606880, 19683318729600, 111207918846240, 325468686087474, - 487127488915360, 373625822747470, 82223711444040] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 65 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 65 α ≤ (33 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 62 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 65 x := by - refine (BernsteinCert.coeffs_pos - [3264300, 47638260, 189767190, 174969722, 19888056] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 65 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 65 α ≤ (313 / 1000) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 62 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow65 - -theorem distillFinite_65 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 65 + distillT0 65 α + distillT1 65 α + distillT2 65 α ≤ (1597 / 1950) := by - have h0 := CriticalRow65.component0 α hα hd - have h1 := CriticalRow65.component1 α hα hd - have h2 := CriticalRow65.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_65 : ((1597 / 1950) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow66 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 66 x := by - refine (BernsteinCert.coeffs_pos - [2372982480, 66423598992, 710202163464, 3598700858136, 8738323056792, 9786278370636, - 7184664988980, 1470586065504] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 66 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 66 α ≤ (211 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 66 x := by - refine (BernsteinCert.coeffs_pos - [61599391920, 1803060590976, 20625895295136, 116595574488576, 341522066118060, - 511851680972064, 393624481565460, 88456283185920] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 66 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 66 α ≤ (29 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 63 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 66 x := by - refine (BernsteinCert.coeffs_pos - [3367980, 49191300, 196380954, 182871990, 22625920] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 66 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 66 α ≤ (309 / 1000) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 63 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow66 - -theorem distillFinite_66 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 66 + distillT0 66 α + distillT1 66 α + distillT2 66 α ≤ (9997 / 12375) := by - have h0 := CriticalRow66.component0 α hα hd - have h1 := CriticalRow66.component1 α hα hd - have h2 := CriticalRow66.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_66 : ((9997 / 12375) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow67 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 67 x := by - refine (BernsteinCert.coeffs_pos - [2447034300, 68519821968, 732979429722, 3716890714728, 9035046337152, 10125367909331, - 7409405308578, 1555525365277] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 67 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 67 α ≤ (26 / 125) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 67 x := by - refine (BernsteinCert.coeffs_pos - [64464945120, 1887389814744, 21597979965192, 122153146710408, 358085613450228, - 537362136058930, 414245558502132, 94892309712734] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 67 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 67 α ≤ (13 / 500) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 64 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 67 x := by - refine (BernsteinCert.coeffs_pos - [3473280, 50769180, 203106336, 190929454, 25430582] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 67 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 67 α ≤ (303 / 1000) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 64 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow67 - -theorem distillFinite_67 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 67 + distillT0 67 α + distillT1 67 α + distillT2 67 α ≤ (159937 / 201000) := by - have h0 := CriticalRow67.component0 α hα hd - have h1 := CriticalRow67.component1 α hα hd - have h2 := CriticalRow67.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_67 : ((159937 / 201000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow68 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 68 x := by - refine (BernsteinCert.coeffs_pos - [148366080, 4155797664, 44477335872, 225704041488, 549209351904, 615855438640, - 449170420552, 96491708472] - (lo := 0) (hi := 17) (s := 24137569) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 68 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 68 α ≤ (51 / 250) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 68 x := by - refine (BernsteinCert.coeffs_pos - [3965760000, 116135482752, 1329413291424, 7522544411568, 22068657862896, 33157098811400, - 25617504370064, 5972596343448] - (lo := 0) (hi := 17) (s := 24137569) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 68 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 68 α ≤ (23 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 65 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 68 x := by - refine (BernsteinCert.coeffs_pos - [210600, 3080700, 12349608, 11714242, 1664826] - (lo := 0) (hi := 17) (s := 4913) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 68 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 68 α ≤ (149 / 500) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 65 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow68 - -theorem distillFinite_68 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 68 + distillT0 68 α + distillT1 68 α + distillT2 68 α ≤ (3197 / 4080) := by - have h0 := CriticalRow68.component0 α hα hd - have h1 := CriticalRow68.component1 α hα hd - have h2 := CriticalRow68.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_68 : ((3197 / 4080) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end diff --git a/Sendov/DistillationFinite/Rows69_76.lean b/Sendov/DistillationFinite/Rows69_76.lean deleted file mode 100644 index 794b53c..0000000 --- a/Sendov/DistillationFinite/Rows69_76.lean +++ /dev/null @@ -1,754 +0,0 @@ -import Sendov.Common.DistillationCriticalFinite -import Sendov.Common.BernsteinList - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow69 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 69 x := by - refine (BernsteinCert.coeffs_pos - [2598549660, 72809813952, 779608003770, 3958934829840, 9642860992440, 10818802013283, - 7864140511398, 1725087101745] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 69 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 69 α ≤ (201 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 69 x := by - refine (BernsteinCert.coeffs_pos - [70459628760, 2063839695696, 23632486476624, 133788518832240, 392774632360326, - 590789137794516, 457389049665930, 108384114377700] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 69 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 69 α ≤ (1 / 50) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 66 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 69 x := by - refine (BernsteinCert.coeffs_pos - [3688740, 53999460, 216891954, 207509970, 31240300] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 69 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 69 α ≤ (73 / 250) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 66 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow69 - -theorem distillFinite_69 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 69 + distillT0 69 α + distillT1 69 α + distillT2 69 α ≤ (159691 / 207000) := by - have h0 := CriticalRow69.component0 α hα hd - have h1 := CriticalRow69.component1 α hα hd - have h2 := CriticalRow69.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_69 : ((159691 / 207000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow70 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 70 x := by - refine (BernsteinCert.coeffs_pos - [2676013200, 75003582960, 803459311560, 4082789088360, 9953952367368, 11173146578540, - 8094135394620, 1809709538440] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 70 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 70 α ≤ (99 / 500) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 70 x := by - refine (BernsteinCert.coeffs_pos - [73591383600, 2156038210080, 24695814746880, 139871557702080, 410915815108764, - 618729335678920, 479928505360260, 115444586144120] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 70 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 70 α ≤ (9 / 500) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 67 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 70 x := by - refine (BernsteinCert.coeffs_pos - [3798900, 55651860, 223952190, 216033022, 34245356] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 70 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 70 α ≤ (57 / 200) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 67 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow70 - -theorem distillFinite_70 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 70 + distillT0 70 α + distillT1 70 α + distillT2 70 α ≤ (1139 / 1500) := by - have h0 := CriticalRow70.component0 α hα hd - have h1 := CriticalRow70.component1 α hα hd - have h2 := CriticalRow70.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_70 : ((1139 / 1500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow71 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 71 x := by - refine (BernsteinCert.coeffs_pos - [2754613980, 77229867312, 827668633194, 4208531480856, 10269833107152, 11532576152651, - 8325881799050, 1894226354109] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 71 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 71 α ≤ (39 / 200) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 71 x := by - refine (BernsteinCert.coeffs_pos - [76814496720, 2250937678536, 25790463979416, 146134991091096, 429598587499800, - 647503099064854, 503124462107680, 122717899952010] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 71 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 71 α ≤ (2 / 125) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 68 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 71 x := by - refine (BernsteinCert.coeffs_pos - [230040, 3372300, 13595532, 13218310, 2195130] - (lo := 0) (hi := 17) (s := 4913) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 71 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 71 α ≤ (139 / 500) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 68 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow71 - -theorem distillFinite_71 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 71 + distillT0 71 α + distillT1 71 α + distillT2 71 α ≤ (159157 / 213000) := by - have h0 := CriticalRow71.component0 α hα hd - have h1 := CriticalRow71.component1 α hα hd - have h2 := CriticalRow71.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_71 : ((159157 / 213000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow72 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 72 x := by - refine (BernsteinCert.coeffs_pos - [2834352000, 79488667008, 852235968672, 4336162007328, 10590503211792, 11897090735616, - 8559379724688, 1978637548752] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 72 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 72 α ≤ (24 / 125) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 72 x := by - refine (BernsteinCert.coeffs_pos - [80130280320, 2348577029664, 26916887388672, 152581438484208, 448830805118688, - 677122253570160, 526985440641792, 130206402615504] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 72 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 72 α ≤ (7 / 500) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 69 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 72 x := by - refine (BernsteinCert.coeffs_pos - [4024080, 59031180, 238407516, 233544714, 40455862] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 72 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 72 α ≤ (271 / 1000) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 69 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow72 - -theorem distillFinite_72 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 72 + distillT0 72 α + distillT1 72 α + distillT2 72 α ≤ (79391 / 108000) := by - have h0 := CriticalRow72.component0 α hα hd - have h1 := CriticalRow72.component1 α hα hd - have h2 := CriticalRow72.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_72 : ((79391 / 108000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow73 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 73 x := by - refine (BernsteinCert.coeffs_pos - [2915227260, 81779982048, 877161317994, 4465680667776, 10915962681288, 12266690327435, - 8794629171534, 2062943122369] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 73 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 73 α ≤ (189 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 73 x := by - refine (BernsteinCert.coeffs_pos - [83540046600, 2448995192064, 28075538189088, 159213519366336, 468620323550682, - 707598624812680, 551519961696198, 137912440948736] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 73 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 73 α ≤ (3 / 250) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 70 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 73 x := by - refine (BernsteinCert.coeffs_pos - [4139100, 60758100, 245802606, 242533354, 43661312] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 73 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 73 α ≤ (33 / 125) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 70 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow73 - -theorem distillFinite_73 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 73 + distillT0 73 α + distillT1 73 α + distillT2 73 α ≤ (31667 / 43800) := by - have h0 := CriticalRow73.component0 α hα hd - have h1 := CriticalRow73.component1 α hα hd - have h2 := CriticalRow73.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_73 : ((31667 / 43800) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow74 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 74 x := by - refine (BernsteinCert.coeffs_pos - [2997239760, 84103812432, 902444681160, 4597087462200, 11246211515640, 12641374928108, - 9031630139588, 2147143074960] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 74 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 74 α ≤ (187 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 74 x := by - refine (BernsteinCert.coeffs_pos - [87045107760, 2552231094336, 29266869595104, 166033853222400, 488974998381036, - 738944038410256, 576736546004500, 145838361765840] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 74 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 74 α ≤ (11 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 71 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 74 x := by - refine (BernsteinCert.coeffs_pos - [4255740, 62509860, 253309314, 251677190, 46933560] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 74 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 74 α ≤ (32 / 125) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 71 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow74 - -theorem distillFinite_74 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 74 + distillT0 74 α + distillT1 74 α + distillT2 74 α ≤ (79019 / 111000) := by - have h0 := CriticalRow74.component0 α hα hd - have h1 := CriticalRow74.component1 α hα hd - have h2 := CriticalRow74.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_74 : ((79019 / 111000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow75 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 75 x := by - refine (BernsteinCert.coeffs_pos - [3080389500, 86460158160, 928086058170, 4730382390600, 11581249714848, 13021144537635, - 9270382628850, 2231237406525] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 75 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 75 α ≤ (23 / 125) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 75 x := by - refine (BernsteinCert.coeffs_pos - [90646776000, 2658323665080, 30491334821160, 173045059537320, 509902685195004, - 771170319980730, 602643714300300, 153986511880950] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 75 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 75 α ≤ (9 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 72 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 75 x := by - refine (BernsteinCert.coeffs_pos - [4374000, 64286460, 260927640, 260976222, 50272606] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 75 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 75 α ≤ (31 / 125) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 72 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow75 - -theorem distillFinite_75 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 75 + distillT0 75 α + distillT1 75 α + distillT2 75 α ≤ (6289 / 9000) := by - have h0 := CriticalRow75.component0 α hα hd - have h1 := CriticalRow75.component1 α hα hd - have h2 := CriticalRow75.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_75 : ((6289 / 9000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow76 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 76 x := by - refine (BernsteinCert.coeffs_pos - [186157440, 5226412896, 56122673472, 286209732528, 701239839936, 788588185648, - 559463919960, 136189771592] - (lo := 0) (hi := 17) (s := 24137569) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 76 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 76 α ≤ (181 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 76 x := by - refine (BernsteinCert.coeffs_pos - [94346363520, 2767311832896, 31749387081696, 180249757796016, 531411239577840, - 804289295141944, 629249987317200, 162359238108200] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 76 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 76 α ≤ (1 / 125) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 73 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 76 x := by - refine (BernsteinCert.coeffs_pos - [4493880, 66087900, 268657584, 270430450, 53678450] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 76 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 76 α ≤ (241 / 1000) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 73 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow76 - -theorem distillFinite_76 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 76 + distillT0 76 α + distillT1 76 α + distillT2 76 α ≤ (15679 / 22800) := by - have h0 := CriticalRow76.component0 α hα hd - have h1 := CriticalRow76.component1 α hα hd - have h2 := CriticalRow76.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_76 : ((15679 / 22800) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end diff --git a/Sendov/LargeDegree/DistillationTail.lean b/Sendov/LargeDegree/DistillationTail.lean index b6b3803..aae6f1c 100644 --- a/Sendov/LargeDegree/DistillationTail.lean +++ b/Sendov/LargeDegree/DistillationTail.lean @@ -6,8 +6,10 @@ import Sendov.Common.DistillationFactors New Lean adaptation of Senjian An, *Proof Distillation for Sendov's Conjecture*, revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, lines 898--950. Paper: CC BY 4.0, https://creativecommons.org/licenses/by/4.0/ . -The finite degree-81 certificate is a separate obligation. No raw scalar value -at alpha zero is identified with a continuous extension. +The degree-64 reduction uses the actual dependence of the rational denominator +on alpha; the old independent denominator bound only starts at 81. +Finite base certificates remain separate. No raw scalar value at alpha zero +is identified with a continuous extension. -/ namespace Sendov @@ -38,9 +40,9 @@ private lemma slope_linear (x c : ℝ) (h : x + c ≠ 0) : convert! (hasDerivAt_id' x).add_const c using 1 exact mul_one_div_cancel h -private lemma tail_antitone {f f' : ℝ → ℝ} - (hf : ∀ x : ℝ, 81 ≤ x → HasDerivAt f (f' x) x) - (hn : ∀ x : ℝ, 81 ≤ x → f' x ≤ 0) : AntitoneOn f (Set.Ici 81) := by +private lemma tail_antitone {f f' : ℝ → ℝ} {K : ℝ} + (hf : ∀ x : ℝ, K ≤ x → HasDerivAt f (f' x) x) + (hn : ∀ x : ℝ, K ≤ x → f' x ≤ 0) : AntitoneOn f (Set.Ici K) := by apply antitoneOn_of_deriv_nonpos (convex_Ici _) (fun x hx => (hf x hx).continuousAt.continuousWithinAt) · exact fun x hx => (hf x (interior_subset hx)).differentiableAt.differentiableWithinAt @@ -48,17 +50,17 @@ private lemma tail_antitone {f f' : ℝ → ℝ} rw [(hf x (interior_subset hx)).deriv] exact hn x (interior_subset hx) -lemma distillEBudget_antitone : AntitoneOn distillEBudget (Set.Ici 81) := by +lemma distillEBudget_antitone_on {K : ℝ} (hK : 0 < K) : + AntitoneOn distillEBudget (Set.Ici K) := by intro m hm n _ hmn - change 81 ≤ m at hm + change K ≤ m at hm dsimp only [distillEBudget] apply add_le_add le_rfl exact div_le_div_of_nonneg_left (by norm_num) (by linarith : 0 < 12 * m) (by linarith) -lemma distillEBudget_le_81 {m : ℝ} (hm : 81 ≤ m) : - distillEBudget m ≤ distillEBudget 81 := - distillEBudget_antitone (by simp) hm hm +lemma distillEBudget_antitone : AntitoneOn distillEBudget (Set.Ici 64) := + distillEBudget_antitone_on (by norm_num) lemma cubicPolarEnvelope_le_five_sixths {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : cubicPolarEnvelope α ≤ 5 / 6 := by @@ -68,25 +70,29 @@ lemma cubicPolarEnvelope_le_five_sixths {α : ℝ} (hα : 0 ≤ α) (hα17 : α rw [h17] at h linarith -lemma distillNode_antitone_degree {α : ℝ} (hα : 0 ≤ α) : - AntitoneOn (fun m => distillNode m α) (Set.Ici 81) := by +lemma distillNode_antitone_degree_on {K α : ℝ} (hK : 0 < K) (hα : 0 ≤ α) : + AntitoneOn (fun m => distillNode m α) (Set.Ici K) := by intro m hm n _ hmn - change 81 ≤ m at hm + change K ≤ m at hm dsimp only [distillNode] apply add_le_add le_rfl exact div_le_div_of_nonneg_left (by positivity : 0 ≤ 12 * α) (by linarith : 0 < 25 * m) (by linarith) -lemma distillNode_lt_four_fifths {m α : ℝ} (hm : 81 ≤ m) +lemma distillNode_antitone_degree {α : ℝ} (hα : 0 ≤ α) : + AntitoneOn (fun m => distillNode m α) (Set.Ici 64) := + distillNode_antitone_degree_on (by norm_num) hα + +lemma distillNode_lt_four_fifths {m α : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : distillNode m α < 4 / 5 := by have he := cubicPolarEnvelope_le_five_sixths hα hα17 - have ht : 12 * α / (25 * m) ≤ 68 / 675 := by + have ht : 12 * α / (25 * m) ≤ 51 / 400 := by apply (div_le_iff₀ (by linarith : 0 < 25 * m)).mpr linarith unfold distillNode linarith -private lemma kappa_slope {m α : ℝ} (hm : 81 ≤ m) (hα17 : α ≤ 17) : +private lemma kappa_slope {m α : ℝ} (hm : 34 < m) (hα17 : α ≤ 17) : HasDerivAt (fun x => distillKappa x α) (distillKappa m α * (1 / (m - 1) + 1 / (m + 1) - 1 / m + 2 / (m - 2 * α))) m := by @@ -109,44 +115,53 @@ private lemma kappa_slope {m α : ℝ} (hm : 81 ≤ m) (hα17 : α ≤ 17) : · dsimp [distillKappa] ring -private lemma kappa_slope_le {m α : ℝ} (hm : 81 ≤ m) (hα17 : α ≤ 17) : +private lemma kappa_slope_le {K m α : ℝ} (hK : 34 < K) (hm : K ≤ m) + (hα17 : α ≤ 17) : 1 / (m - 1) + 1 / (m + 1) - 1 / m + 2 / (m - 2 * α) ≤ - 1 / 80 + 2 / 47 := by - have h1 : 1 / (m - 1) ≤ 1 / (80 : ℝ) := - div_le_div_of_nonneg_left (by norm_num) (by norm_num) (by linarith) + 1 / (K - 1) + 2 / (K - 34) := by + have h1 : 1 / (m - 1) ≤ 1 / (K - 1) := + div_le_div_of_nonneg_left (by norm_num) (by linarith) (by linarith) have h2 : 1 / (m + 1) ≤ 1 / m := div_le_div_of_nonneg_left (by norm_num) (by linarith) (by linarith) - have h3 : 2 / (m - 2 * α) ≤ 2 / (47 : ℝ) := - div_le_div_of_nonneg_left (by norm_num) (by norm_num) (by linarith) + have h3 : 2 / (m - 2 * α) ≤ 2 / (K - 34) := + div_le_div_of_nonneg_left (by norm_num) (by linarith) (by linarith) linarith -private lemma kappa_rpow_antitone {α z : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) +/-- Explicit sufficient conditions on the start, rather than an assumed derivative sign. -/ +lemma distillKappa_rpow_antitone_on {K α z : ℝ} (hK : 34 < K) + (hdecay : 1 / (K - 1) + 2 / (K - 34) ≤ 1 / 12) + (hα : 0 ≤ α) (hα17 : α ≤ 17) (hz : 0 ≤ z) (hz1 : z ≤ 5 / 6) : - AntitoneOn (fun m => distillKappa m α * z ^ ((m - 3) / 2)) (Set.Ici 81) := by + AntitoneOn (fun m => distillKappa m α * z ^ ((m - 3) / 2)) (Set.Ici K) := by rcases hz.eq_or_lt with rfl | hz · intro m hm n hn _ - have hm' : (m - 3) / 2 ≠ 0 := by change 81 ≤ m at hm; linarith - have hn' : (n - 3) / 2 ≠ 0 := by change 81 ≤ n at hn; linarith + have hm' : (m - 3) / 2 ≠ 0 := by change K ≤ m at hm; linarith + have hn' : (n - 3) / 2 ≠ 0 := by change K ≤ n at hn; linarith simp only [Real.zero_rpow hm', Real.zero_rpow hn', mul_zero, le_refl] have hp (m : ℝ) : HasDerivAt (fun x : ℝ => z ^ ((x - 3) / 2)) (z ^ ((m - 3) / 2) * (Real.log z / 2)) m := by convert! (hasDerivAt_const m z).rpow (((hasDerivAt_id' m).sub_const 3).div_const 2) hz using 1 ring - apply tail_antitone (fun m hm => slope_mul (kappa_slope hm hα17) (hp m)) + apply tail_antitone (fun m hm => slope_mul (kappa_slope (hK.trans_le hm) hα17) (hp m)) intro m hm apply mul_nonpos_of_nonneg_of_nonpos · exact mul_nonneg (distillKappa_nonneg (by linarith) hα) (Real.rpow_nonneg hz.le _) - · have hk := kappa_slope_le hm hα17 + · have hk := kappa_slope_le hK hm hα17 have hl := Real.log_le_sub_one_of_pos hz linarith +private lemma kappa_rpow_antitone {α z : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) + (hz : 0 ≤ z) (hz1 : z ≤ 5 / 6) : + AntitoneOn (fun m => distillKappa m α * z ^ ((m - 3) / 2)) (Set.Ici 64) := + distillKappa_rpow_antitone_on (by norm_num) (by norm_num) hα hα17 hz hz1 + /-- Real-degree antitonicity; the node itself also decreases with the degree. -/ lemma distillT1_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : - AntitoneOn (fun m => distillT1 m α) (Set.Ici 81) := by + AntitoneOn (fun m => distillT1 m α) (Set.Ici 64) := by intro m hm n hn hmn - have hm' : 81 ≤ m := hm - have hn' : 81 ≤ n := hn + have hm' : 64 ≤ m := hm + have hn' : 64 ≤ n := hn have hz := distillNode_pos (by linarith : 0 < m) hα have hz1 : distillNode m α ≤ 5 / 6 := by have := distillNode_lt_four_fifths hm' hα hα17 @@ -161,77 +176,89 @@ lemma distillT1_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : /-- The zero-alpha case is included by the zero-base real-power case. -/ lemma distillT2_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : - AntitoneOn (fun m => distillT2 m α) (Set.Ici 81) := by + AntitoneOn (fun m => distillT2 m α) (Set.Ici 64) := by intro m hm n hn hmn have hstep := kappa_rpow_antitone hα hα17 (cubicPolarEnvelope_nonneg hα) (cubicPolarEnvelope_le_five_sixths hα hα17) hm hn hmn have := mul_le_mul_of_nonneg_left hstep (by norm_num : (0 : ℝ) ≤ 421 / 3125) simpa only [distillT2, mul_assoc] using this -lemma distillT1_le_81 {m α : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : - distillT1 m α ≤ distillT1 81 α := - distillT1_antitone hα hα17 (by simp) hm hm - -lemma distillT2_le_81 {m α : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : - distillT2 m α ≤ distillT2 81 α := - distillT2_antitone hα hα17 (by simp) hm hm - -lemma distillT2_zero {m : ℝ} (hm : 81 ≤ m) : distillT2 m 0 = 0 := by +lemma distillT2_zero {m : ℝ} (hm : 64 ≤ m) : distillT2 m 0 = 0 := by have hs : (m - 3) / 2 ≠ 0 := by linarith simp [distillT2, cubicPolarEnvelope, Real.zero_rpow hs] -/-- Exact positive tail certificate from the paper, valid for real degree. -/ -lemma distillTail_polynomial_pos {m : ℝ} (hm : 81 ≤ m) : - 0 < 7 * m ^ 4 - 510 * m ^ 3 - 4049 * m ^ 2 - 35462 * m - 104040 := by - have hx : 0 ≤ m - 81 := by linarith - have hid : 7 * m ^ 4 - 510 * m ^ 3 - 4049 * m ^ 2 - 35462 * m - 104040 = - 7 * (m - 81) ^ 4 + 1758 * (m - 81) ^ 3 + 147583 * (m - 81) ^ 2 + - 4150618 * (m - 81) + 750186 := by ring - rw [hid] - positivity - private def tailP (m α : ℝ) : ℝ := 7 * m ^ 4 - 30 * α * m ^ 3 - (8 * α ^ 2 + 96 * α + 105) * m ^ 2 + (90 * α - 128 * α ^ 2) * m - 360 * α ^ 2 -private lemma tailP_pos {m α : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : +private lemma tailP_pos {m α : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) (hα12 : α ≤ 12) : 0 < tailP m α := by have hm0 : 0 ≤ m := by linarith - have hgap : 0 ≤ 17 - α := by linarith + have hx : 0 ≤ m - 64 := by linarith + have hgap : 0 ≤ 12 - α := by linarith have hid : tailP m α = - (7 * m ^ 4 - 510 * m ^ 3 - 4049 * m ^ 2 - 35462 * m - 104040) + - (17 - α) * (α * (8 * m ^ 2 + 128 * m + 360) + - 30 * m ^ 3 + 232 * m ^ 2 + 2086 * m + 6120) := by + 7 * (m - 64) ^ 4 + 1432 * (m - 64) ^ 3 + 100503 * (m - 64) ^ 2 + + 2590648 * (m - 64) + 12039040 + + (12 - α) * (α * (8 * m ^ 2 + 128 * m + 360) + + 30 * m ^ 3 + 192 * m ^ 2 + 1446 * m + 4320) := by dsimp [tailP] ring rw [hid] - exact add_pos_of_pos_of_nonneg (distillTail_polynomial_pos hm) (by positivity) + positivity private noncomputable def tailQ (m α d : ℝ) : ℝ := d * tailP m α / 7 + (21 / 25 - d) * (4 * α / 7) * ((3 * m - 2 * α) * m ^ 2 + 32 * (m - α) * m + (75 * m - 90 * α)) -private lemma tailQ_pos {m α d : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) - (hα17 : α ≤ 17) (hd : 0 < d) (hd1 : d ≤ 21 / 25) : 0 < tailQ m α d := by +private lemma tailQ_cap_pos {m α : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) + (hα17 : α ≤ 17) : 0 < tailQ m α (2 / 5) := by + have hm0 : 0 ≤ m := by linarith + have hx : 0 ≤ m - 64 := by linarith + have hgap : 0 ≤ 17 - α := by linarith + have hquad : 0 ≤ 24 * m ^ 2 - 64 * m - 600 := by nlinarith + have hid : tailQ m α (2 / 5) = + (2 / 5) * (m - 64) ^ 4 + (2152 / 25) * (m - 64) ^ 3 + + (161426 / 25) * (m - 64) ^ 2 + (4603736 / 25) * (m - 64) + + 29487816 / 25 + + (17 - α) * ((24 / 25) * (α + 17) * (m ^ 2 + 16 * m + 45) + + m * (24 * m ^ 2 - 64 * m - 600) / 25) := by + dsimp [tailQ, tailP] + ring + rw [hid] + positivity + +private lemma tailQ_pos {m α d : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) + (hα17 : α ≤ 17) (hd : 0 < d) (hd1 : d ≤ 21 / 25) + (hdα : 12 ≤ α → d ≤ 2 / 5) : 0 < tailQ m α d := by have hm0 : 0 ≤ m := by linarith have h1 : 0 ≤ 3 * m - 2 * α := by linarith have h2 : 0 ≤ m - α := by linarith have h3 : 0 ≤ 75 * m - 90 * α := by linarith have h4 : 0 ≤ 21 / 25 - d := by linarith - unfold tailQ - exact add_pos_of_pos_of_nonneg (div_pos (mul_pos hd (tailP_pos hm hα hα17)) - (by norm_num)) (by positivity) + by_cases hα12 : α ≤ 12 + · unfold tailQ + exact add_pos_of_pos_of_nonneg (div_pos (mul_pos hd (tailP_pos hm hα hα12)) + (by norm_num)) (by positivity) + · have hd2 : 0 ≤ 2 / 5 - d := sub_nonneg.mpr (hdα (by linarith)) + have hid : tailQ m α d = d * (5 / 2 * tailQ m α (2 / 5)) + + (2 / 5 - d) * (6 * α / 5) * + ((3 * m - 2 * α) * m ^ 2 + 32 * (m - α) * m + (75 * m - 90 * α)) := by + dsimp [tailQ, tailP] + ring + rw [hid] + exact add_pos_of_pos_of_nonneg + (mul_pos hd (mul_pos (by norm_num) (tailQ_cap_pos hm hα hα17))) (by positivity) private noncomputable def tailRational (m α d : ℝ) : ℝ := m ^ 3 * (m - 2 * α) ^ 2 / ((m + 3) * (m + 5) * (d * m - 12 * α / 25) ^ 4) -private lemma tail_den_pos {m α d : ℝ} (hm : 81 ≤ m) (hα17 : α ≤ 17) +private lemma tail_den_pos {m α d : ℝ} (hm : 64 ≤ m) (hα17 : α ≤ 17) (hd : 17 / 50 ≤ d) : 0 < d * m - 12 * α / 25 := by have hm0 : 0 ≤ m := by linarith have hd0 : 0 ≤ d - 17 / 50 := by linarith nlinarith [mul_nonneg hd0 hm0] -private lemma rational_slope {m α d : ℝ} (hm : 81 ≤ m) (hα17 : α ≤ 17) +private lemma rational_slope {m α d : ℝ} (hm : 64 ≤ m) (hα17 : α ≤ 17) (hd : 17 / 50 ≤ d) : HasDerivAt (fun x => tailRational x α d) (tailRational m α d * (3 / m + 2 / (m - 2 * α) - 1 / (m + 3) - @@ -258,8 +285,9 @@ private lemma rational_slope {m α d : ℝ} (hm : 81 ≤ m) (hα17 : α ≤ 17) · dsimp [tailRational] ring -private lemma rational_slope_neg {m α d : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) - (hα17 : α ≤ 17) (hd : 17 / 50 ≤ d) (hd1 : d ≤ 21 / 25) : +private lemma rational_slope_neg {m α d : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) + (hα17 : α ≤ 17) (hd : 17 / 50 ≤ d) (hd1 : d ≤ 21 / 25) + (hdα : 12 ≤ α → d ≤ 2 / 5) : 3 / m + 2 / (m - 2 * α) - 1 / (m + 3) - 1 / (m + 5) - 4 * d / (d * m - 12 * α / 25) < 0 := by have hm0 : 0 < m := by linarith @@ -277,21 +305,22 @@ private lemma rational_slope_neg {m α d : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) dsimp [tailQ, tailP] ring rw [hid] - exact div_neg_of_neg_of_pos (neg_neg_of_pos (tailQ_pos hm hα hα17 (by linarith) hd1)) + exact div_neg_of_neg_of_pos + (neg_neg_of_pos (tailQ_pos hm hα hα17 (by linarith) hd1 hdα)) (by positivity) private lemma tailRational_antitone {α d : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) - (hd : 17 / 50 ≤ d) (hd1 : d ≤ 21 / 25) : - AntitoneOn (fun m => tailRational m α d) (Set.Ici 81) := by + (hd : 17 / 50 ≤ d) (hd1 : d ≤ 21 / 25) (hdα : 12 ≤ α → d ≤ 2 / 5) : + AntitoneOn (fun m => tailRational m α d) (Set.Ici 64) := by apply tail_antitone (fun m hm => rational_slope hm hα17 hd) intro m hm have hm0 : 0 ≤ m := by linarith have hm3 : 0 ≤ m + 3 := by linarith have hm5 : 0 ≤ m + 5 := by linarith exact mul_nonpos_of_nonneg_of_nonpos (by unfold tailRational; positivity) - (rational_slope_neg hm hα hα17 hd hd1).le + (rational_slope_neg hm hα hα17 hd hd1 hdα).le -private lemma distillT0_eq_rational {m α : ℝ} (hm : 81 ≤ m) +private lemma distillT0_eq_rational {m α : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : distillT0 m α = (24 * (3 / 5) ^ 4 * distillRatio α) * tailRational m α (21 / 25 - 3 / 5 * cubicPolarEnvelope α) := by @@ -319,36 +348,31 @@ private lemma distillT0_eq_rational {m α : ℝ} (hm : 81 ≤ m) /-- Real-degree antitonicity of the regularized rational component, including alpha zero. -/ lemma distillT0_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : - AntitoneOn (fun m => distillT0 m α) (Set.Ici 81) := by + AntitoneOn (fun m => distillT0 m α) (Set.Ici 64) := by have he := cubicPolarEnvelope_nonneg hα have he1 := cubicPolarEnvelope_le_five_sixths hα hα17 have hd : 17 / 50 ≤ 21 / 25 - 3 / 5 * cubicPolarEnvelope α := by linarith have hd1 : 21 / 25 - 3 / 5 * cubicPolarEnvelope α ≤ 21 / 25 := by linarith + have hdα : 12 ≤ α → 21 / 25 - 3 / 5 * cubicPolarEnvelope α ≤ 2 / 5 := by + intro h12 + have he12 := cubicPolarEnvelope_mono (by norm_num : (0 : ℝ) ≤ 12) h12 + have hval : cubicPolarEnvelope 12 = 1468 / 1875 := by norm_num [cubicPolarEnvelope] + rw [hval] at he12 + linarith intro m hm n hn hmn change distillT0 n α ≤ distillT0 m α rw [distillT0_eq_rational hn hα hα17, distillT0_eq_rational hm hα hα17] - exact mul_le_mul_of_nonneg_left (tailRational_antitone hα hα17 hd hd1 hm hn hmn) + exact mul_le_mul_of_nonneg_left (tailRational_antitone hα hα17 hd hd1 hdα hm hn hmn) (mul_nonneg (by norm_num) (distillRatio_nonneg hα)) -lemma distillT0_le_81 {m α : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : - distillT0 m α ≤ distillT0 81 α := - distillT0_antitone hα hα17 (by simp) hm hm - -/-- Pointwise degree-81 reduction. This is not a certificate for the degree-81 base. -/ -lemma distillComponents_le_81 {m α : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : +/-- The earlier pointwise reduction holds on the full closed alpha interval. -/ +lemma distillComponents_le_64 {m α : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α ≤ - distillEBudget 81 + distillT0 81 α + distillT1 81 α + distillT2 81 α := by - exact add_le_add (add_le_add (add_le_add (distillEBudget_le_81 hm) - (distillT0_le_81 hm hα hα17)) (distillT1_le_81 hm hα hα17)) - (distillT2_le_81 hm hα hα17) - -/-- The finite worker supplies the only extra hypothesis: the global degree-81 base. -No monotonicity or infinite-tail assertion is assumed. -/ -theorem distillComponents_lt_two_thirds_of_base - (hbase : ∀ α : ℝ, 0 ≤ α → α ≤ 17 → - distillEBudget 81 + distillT0 81 α + distillT1 81 α + distillT2 81 α < 2 / 3) - {m α : ℝ} (hm : 81 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 2 / 3 := - (distillComponents_le_81 hm hα hα17).trans_lt (hbase α hα hα17) + distillEBudget 64 + distillT0 64 α + distillT1 64 α + distillT2 64 α := by + exact add_le_add (add_le_add (add_le_add + (distillEBudget_antitone (by simp) hm hm) + (distillT0_antitone hα hα17 (by simp) hm hm)) + (distillT1_antitone hα hα17 (by simp) hm hm)) + (distillT2_antitone hα hα17 (by simp) hm hm) end Sendov diff --git a/Sendov/LargeDegree/DistillationTailBound.lean b/Sendov/LargeDegree/DistillationTailBound.lean index 28f865a..7c314d9 100644 --- a/Sendov/LargeDegree/DistillationTailBound.lean +++ b/Sendov/LargeDegree/DistillationTailBound.lean @@ -1,13 +1,12 @@ import Sendov.Common.DistillationMajorant import Sendov.LargeDegree.DistillationTail -import Sendov.DistillationFinite.Row81 +import Sendov.DistillationFinite.Rows61_64 /-! # The proved infinite tail -The critical-point certificate at `m = 81` closes the base required by the -real-degree antitonicity argument. No finite base or monotonicity is assumed. -The degree convention is `m = n - 1`: this tail starts at polynomial degree 82. +The existing critical-point row at `m = 64` supplies the earlier `<199/200` +tail, starting at polynomial degree 65. No finite base or monotonicity is assumed. The underlying mathematical route is Senjian An's *Proof Distillation for Sendov's Conjecture*, revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, Sections 7--8 (CC BY 4.0, https://creativecommons.org/licenses/by/4.0/). @@ -15,22 +14,20 @@ Conjecture*, revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, Sections 7--8 namespace Sendov -/-- The regularized four-component bound is strictly below two thirds for every -real `m ≥ 81`, including alpha zero. The base is the actual critical certificate. -/ -theorem distillComponents_lt_two_thirds {m α : ℝ} (hm : 81 ≤ m) +/-- The existing finite row closes the earlier tail on the full closed alpha +domain, including zero. No stronger degree-64 certificate is required. -/ +theorem distillComponents_lt_199_200 {m α : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) (h17 : α ≤ 17) : - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 2 / 3 := by - exact distillComponents_lt_two_thirds_of_base - (fun _ h0 hmax => distillFiniteTailBase h0 hmax) hm hα h17 + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := + (distillComponents_le_64 hm hα h17).trans_lt + ((distillFinite_64 α hα h17).trans_lt distillFiniteBound_64) -/-- The raw scalar obstruction is bounded on the positive-alpha domain used by -actual polynomial data. This does not redefine its zero value by continuity. -/ -theorem distillScalar_lt_two_thirds {m α : ℝ} (hm : 81 ≤ m) +/-- Earlier raw scalar tail. Positive alpha is intentional; all of `α ≤ 17` +is covered, and `2 * α ≤ m` follows from the degree threshold. -/ +theorem distillScalar_lt_199_200 {m α : ℝ} (hm : 64 ≤ m) (hα : 0 < α) (h17 : α ≤ 17) : - scalarObstruction m α (cubicPolarEnvelope α) < 2 / 3 := by - have hm5 : 5 ≤ m := by linarith - have hαm : 2 * α ≤ m := by linarith - exact (distillScalar_le_majorant hm5 hα hαm).trans_lt - (distillComponents_lt_two_thirds hm hα.le h17) + scalarObstruction m α (cubicPolarEnvelope α) < 199 / 200 := by + exact (distillScalar_le_majorant (by linarith) hα (by linarith)).trans_lt + (distillComponents_lt_199_200 hm hα.le h17) end Sendov diff --git a/data/README.md b/data/README.md index 3bcdd18..a27330c 100644 --- a/data/README.md +++ b/data/README.md @@ -1,14 +1,18 @@ # Exact mathematical table -`paper_certificate_table.json` is the unchanged mathematical certificate table -from Senjian An, *Proof Distillation for Sendov's Conjecture*, +`paper_certificate_table.json` is the unchanged ordered subset of records +`m = 5,...,64` (60 records) from Senjian An's mathematical certificate table, +*Proof Distillation for Sendov's Conjecture*, [SJanPerth/Sendov-Proof-Distillation](https://github.com/SJanPerth/Sendov-Proof-Distillation/blob/e8ae601491ec171ab4f7f8456113dd6a047aa85d/verification/paper_certificate_table.json), fixed revision **e8ae601491ec171ab4f7f8456113dd6a047aa85d**. The mathematical paper/table is attributed under [Creative Commons Attribution 4.0 International](https://creativecommons.org/licenses/by/4.0/); `LICENSE-PAPER.txt` retains the source's notice and legal-code link. No table -values, row order, component order or budgets were changed. The project generates +values, retained row order, component IDs/order or budgets were changed. Records +65 through 81 were removed because the proved real-parameter tail now starts +at 64 and uses the original row-64 budget. This is a selected subset, not a +verbatim copy of the complete donor table. The project generates its own Lean certificate source; the table itself is not a formal proof. The upstream verification **code** has a separate MIT license. The small rational diff --git a/data/paper_certificate_table.json b/data/paper_certificate_table.json index 3b750f0..2bfde37 100644 --- a/data/paper_certificate_table.json +++ b/data/paper_certificate_table.json @@ -2218,634 +2218,5 @@ } ], "total": "79691/96000" - }, - { - "m": 65, - "e": "101/390", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 214, - "sq": "34334340789477200651098678886400000000000000000000/752491988081647924044447477705043714526959478413249", - "sign_lo": "1385541144705", - "sign_hi": "1385541144705" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 33, - "sq": "67028099253983982210578301458545688459876254728695732007036977674293956489337971117238201842055266900602714053110060610624348379872185452488414328634147241068814748698171034722917910569991694818127897562415184129094860732558066523735941702796936407692643205905602803882383765420562885275337839261656519110431437064906129522066301131071680160439006579097976389524483011894770988985946951849772416813304729288409176493865376908422201/63622990611017036966757235610990171775788273116850987339477383422861603441190996832018620605774237270016000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-82223711444040", - "sign_hi": "-82223711444040" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 313, - "sq": "94328786027368357163508333634122177350833298740384829049352023307866757128329664351987144718009791133303943991346340938022345990943741920840889958576428612261916066827981725012609595848601537336205231659401988966198833859864512836645416797727484265813042103435701628096557806681817216714657108932610184538583546470654104298449453058339888452919149169/964947666259477755610997282527529251293932899443844718633498663207447787396441047040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-19888056", - "sign_hi": "-19888056" - } - ], - "total": "1597/1950" - }, - { - "m": 66, - "e": "205/792", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 211, - "sq": "1068572247761995850762420224000000000000000000000000/24157012391329495240490380875419103775001669888095569", - "sign_lo": "1470586065504", - "sign_hi": "1470586065504" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 29, - "sq": "42731835733678186630267278274282042449703341698724650000771593467089926039996613732868086320265600156900397377092074771425766308983673895365937920572450195339090587361290113396982063261285637573689762174551083689764628445614913707678821222258187655824220501904965986986338897889805928773919449221394805219538415734207285221932578718718676482829492356077455885879615921014103635807211528110865796679328935693507759096336931584672613/51559545123749720061894407155804674281971639261348798605794764299424493392898892855941864516513892925440000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-88456283185920", - "sign_hi": "-88456283185920" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 309, - "sq": "127494459460214201534549422466853837461446475495185170854046760889629279532104993656493549272674374996561226094674394763459886858265362300965360724295640115618253584762356518421153555274846546235244652430030352049653262261399522788695577977435567469770513850012748216535550383879996633340177142166135299905616513868932916844959350920278314097685767434503/1343070117445085180981309022397961778735882084844845740212107038782891706168878395555840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-22625920", - "sign_hi": "-22625920" - } - ], - "total": "9997/12375" - }, - { - "m": 67, - "e": "52/201", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 208, - "sq": "63756049401527131709522840125440000000000000000000000/1486662758945285781036823009555103654656148229077590561", - "sign_lo": "1555525365277", - "sign_hi": "1555525365277" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 26, - "sq": "1144694541565407030558652473852265226912428080290126567042291328215904771856339540791252797191322715236227751730603201835120033864642845959175021943047192101485620240478255042318008714796430226358197185603631516258858940402091402949550644633224871578642794665422824710649524115941693959858246150084675925876785097982106252478468338023899708672085036408103949603139354309002180951474531026927923433788210587959606019279288717198470917276414323227252473478024662495049469502160850759898595823969/1764397563018168477050619438416212114435324772936347459032712743994890330960428335828896793883674935265714789967103416423519325102987105946139299358543813017600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-94892309712734", - "sign_hi": "-94892309712734" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 303, - "sq": "17129782869270285828733222743090733471417005151033623491132876586721205202288073009257061482719945639344536094921599186391571281795760546967560190084647102937489318468077664787062235718507080970702538738431156021842871359238885801446897583913829648127331943920250930923591704295036518285425064137346544970258234942444239875211595909753822124463880748126800317409/186639723365614274415937860018260184635407986975217398934489377456622778169964679355432960000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-25430582", - "sign_hi": "-25430582" - } - ], - "total": "159937/201000" - }, - { - "m": 68, - "e": "211/816", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 204, - "sq": "4362904817672487174144000000000000000000000000/104926341231840161214500129528614172816738631169", - "sign_lo": "1640359044024", - "sign_hi": "1640359044024" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 23, - "sq": "6880368371440001138081185582747470684484362055328871011854344175773724845584520340050643565379984886445061751280239739989648140315373379263347811717643587970398510238012908136405709640720749206059472219719378654619906574353033067537081027040250866484957288363474689865491832415884425987231507703834183538499640466000418116877348067681609595195693292679697610748298476368096665263/13611294676837538538534984297270728458240000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-101534137838616", - "sign_hi": "-101534137838616" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 298, - "sq": "4571344243198537162841959708164982237633007580916751894437469424916508840313863790646816875155961009396322439593207363733515804543566333409087126711362385112069370057162550645828248396634872423613829518457812909937171047416891916237264558064484853932107093304292472575482622348832850724233587129030545460541781160726904550077354688201470171950669763041270642081742943/51728598401105514737654989512211760150587926280928153053761261718964534570715806519682662400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-28302042", - "sign_hi": "-28302042" - } - ], - "total": "3197/4080" - }, - { - "m": 69, - "e": "107/414", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 201, - "sq": "17970062828215979250524160000000000000000000000000000/445682618042768758803925685979993514032118234799929369", - "sign_lo": "1725087101745", - "sign_hi": "1725087101745" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 20, - "sq": "845005972193600746203306211124054336944584779066109027338421209598075512674770517117739888236537186539085680463482110451405917817473182824788299799915043545774133606876771924395027920950033884774366156405452280739152397570859439466124903820111723935214532601510113705664668111367653407261957599138385251639964300273837287252300064558608290131675709194186709107491943893301958059098081473233431143365413328913565372520128513255125636821780314727714980851296863783237120281/2155024822133800119634308892351844781971821189495922124482169247762955951775861007372882254705393201443479453356391677981645944651776000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-108384114377700", - "sign_hi": "-108384114377700" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 292, - "sq": "45088915740516893285604232179781162410180906793477063530723406157770593846747109157512891032813646195105885174097521049380450561459742163845816325591428927648103619451969196046710894081496458096302013640028317798600752404863196503618732486998997980700530935850641812287537955369602833666074945317259910829496642161586451558598792027973315477824452952477101217980324114089/531964491093352848238506874946102810566210092770757703248147912815018722036944382454851776282624000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-31240300", - "sign_hi": "-31240300" - } - ], - "total": "159691/207000" - }, - { - "m": 70, - "e": "31/120", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 198, - "sq": "5303390569468194168981984116736000000000000000000/135622850965394303288738153151864305824592258120209", - "sign_lo": "1809709538440", - "sign_hi": "1809709538440" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 18, - "sq": "44898731079325435517782484704831203181133806844116895239517220075129401197227860868027115684537550043917306923321048125771159449486105441590562532672109828512046154561018917021418568497391849233632391082303816907957223358638129746629629725293892219367328555484351909728190259097208378856053824988238327332590754526559086992431944863516674899904853723526980482623307202587386756424619744914207934300638718841719843410312142905233664983144153649/148236780646200095609679825837096966420810671642159361923901413744481963393759851692184043520000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-115444586144120", - "sign_hi": "-115444586144120" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 285, - "sq": "14368217741853268230922102170032774019898599675770121362824425071579682237826365976731981740411916531703722669144917953857092225089263972498532187150184322827772100006253794683062317049330045201406334489460684132774733815549825226097874212059734090063193975124127605464695287696413001088767167059193575770824730149066578545435616678981750656164356696131404755921557831807143/177395742116274056027623420823771468280479856930480634615093490119905811285033630040064000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-34245356", - "sign_hi": "-34245356" - } - ], - "total": "1139/1500" - }, - { - "m": 71, - "e": "55/213", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 195, - "sq": "41366755757353676949068334759936000000000000000000000000/1090581816728761922355722734136286934531460089807912131241", - "sign_lo": "1894226354109", - "sign_hi": "1894226354109" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 16, - "sq": "122856857395378958402542851423812625455242187824188082368561761393317931621831444447871196975340002573424910152059499117087370960994046818689853260498436488991440252811199716694725139291736186322078515416336568564618007952409065602399289624264798803620227417503044514557855625742800417881751214486704216001645589741666340394600358683778336074493894542357004861047712724696368015790618552228828684386006437951543618311612689904940910962016634175290349671371002727606118995551797116927904304528059959244593393784659044788881/527210251759413660632841939793951871725430680532506348550012059675640236823664735092449342570157197649015053006785984852346055556823949660169992904748739675879545136742400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-122717899952010", - "sign_hi": "-122717899952010" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 278, - "sq": "4826946552927276939141036861938319250076125406120570053027354544921623627027628326678286665745981025871919495979508082285229910135979884683377809438886205458471016670367978671521969017923757803418407297440178093049135879039566302077772124967176706122533632496963196184698185607545449807925266885628725328547409164122252785554740351509072881952409839985397840076090404542014000426809/62583327489593495950204512511454275900587296731718116690562524878072052505034811359772872278016000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-37317210", - "sign_hi": "-37317210" - } - ], - "total": "159157/213000" - }, - { - "m": 72, - "e": "223/864", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 192, - "sq": "144543551124781182379622400000000000000000000/3927786522590572582740036097728915871166856601", - "sign_lo": "1978637548752", - "sign_hi": "1978637548752" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 14, - "sq": "151425159351870780066972513821258060528435210071349283484242260317841862788701260450359146503884993224213120467536410094541810066545721609257005154452633500147258917745765928083141124615495419782285465569793263913721742716382674050245444227187248803947058717426972712537590300789883054301325970549871845951022751226024649976805131418745213080477527982448313308034149382106041760099561099094499595629972312289849417351886086660182137187029/847800165345269235368460957110334837197892071381657016957297463356262535135232000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-130206402615504", - "sign_hi": "-130206402615504" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 271, - "sq": "36634413038396955678019863655848875280188947989173732393423713094949239642336654123729368270805410121732935301736984840058234752585754962944553391214525743867124524622774437831002910705620086626312632440653653850997908625960464051140890028527517219126332952922296900077427894599466651738595020823980075222107789346440659705710773434310359524302091354993642996464847841546085208647747439611143/500452885624730343791622467699768070165637768636420343344586546092955533617757824480172692612317184000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-40455862", - "sign_hi": "-40455862" - } - ], - "total": "79391/108000" - }, - { - "m": 73, - "e": "113/438", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 189, - "sq": "54295557458725131710551789142016000000000000000000000000/1520417099025837456705391107838229298668809009907143013161", - "sign_lo": "2062943122369", - "sign_hi": "2062943122369" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 12, - "sq": "10715905446671541435946951891304010300136934917664079584708177726741186910856630905950739068419556829683040654350552095013292453376842599808631270148359772565492348005352069601300059572732742464777239066018460580564954929922424943668569656923510116731740021455690830869096720096541581210393777838360230792895682119441065695604139063665505433820079026351906609703846113674674723069585356893042445872569025916875619019852163668727712263021972726095539183007738223957865351409787867459951296831595174523659231002016690856076193191387616796761/78560702139019809801359642949714998594237114323076967669985031538586222352020093367397464317597086674851829394985480636820103897512796777504536913851079420443301027943913881600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-137912440948736", - "sign_hi": "-137912440948736" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 264, - "sq": "81457706083694398389158269930388689639636742337461380370963453809891026594149218351367066354857440155622056677410743338090718446771147746930655104841253577825977962667021149526543162735996870147526406911684679504790521397459342765701282045902900898801353542623325734895032137527772247795232942156075022800477334597259338593478185807878426506045696068133186799352809826493583040766005137452001/1176156590419162828957710673538459604661261052377882144526906725121544553503336673891792673832960000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-43661312", - "sign_hi": "-43661312" - } - ], - "total": "31667/43800" - }, - { - "m": 74, - "e": "229/888", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 187, - "sq": "505908683766655134769128407040000000000000000000000000000/14595544412639227982874644023871618393444422142338827603001", - "sign_lo": "2147143074960", - "sign_hi": "2147143074960" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 11, - "sq": "31824907833569419258809367288925451596573808653376812365580499800179169067634261825117968185902020330645979596997343308743803169876853123046892731002878638112236403494577643665310343641257411970882378431588512117416567427821758709554736667804289352414307511974488970406998627549928617800504756431810020281893309934442624050532076901141382330459370144489521866521948929875888468721952646676612235459480486481952914143288071686119194831605943247687751230672859171110334753247804284465076430625028839482326831085061379/306564457184540121304397578800232088429090393406858732269254452462872654159791715326359336441707891070367905846478686288631239841441872251214182753291468800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-145838361765840", - "sign_hi": "-145838361765840" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 256, - "sq": "2210262936112089462747014620787661728832134363159423527522147424942399628878517009480798331217945819149298610942350412235123473120537982540289798419171229332407700709952372589120623958182272744723559600699651494844688105130281708501833516150511956651369956785247607476434567199227785388604336195511777541394960425737707457404961960975647060721259623720737886550357314169970266126390796782647847/33833086440506461266702773248443579657123857050037503705616739832160796322109158603128711910432702464000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-46933560", - "sign_hi": "-46933560" - } - ], - "total": "79019/111000" - }, - { - "m": 75, - "e": "58/225", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 184, - "sq": "406371556223595053056000000000000000000/12075810663936142222840740747164239625049", - "sign_lo": "2231237406525", - "sign_hi": "2231237406525" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 9, - "sq": "1389128126895813547138312810246616738742610452608872768170867266787157010740205645426214864349054542245989612242065642494555051605302781528176086963044719696058485305507389554447265059354289508923130895638946249880258656901326899882710780190706492739910997463640399062024253159875170190295649739291511314200938237465839208937493457158434439065522025748536947574061902011868903928603343391446044661136549072992817859515049/17640237901181449945941339649262864081879040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-153986511880950", - "sign_hi": "-153986511880950" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 248, - "sq": "115315370872536767566686644591079889226916514709767868102489149365145002236511275692581764826197914854015267287922251749282819070934549052125950349684967155172771037604855814987552673291000467678426274135421069254577429184808729570704537762025484102167653972874888657644009940304573890083327856443938973176026303909514314089150516558878555876196373810055703343576458777980433161533139441749109077229648233209/1876698321092738789218584253874130263121141632386576287542199547848583251066591841800647597296189440000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-50272606", - "sign_hi": "-50272606" - } - ], - "total": "6289/9000" - }, - { - "m": 76, - "e": "235/912", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 181, - "sq": "21052643802835585248994000896000000000000000000000000/644221608014480744805165258986902057023283781908569601", - "sign_lo": "2315226117064", - "sign_hi": "2315226117064" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 8, - "sq": "685304689471663725583501312750102912793915245247686836606243106700860756241572017536433321887682477234530511886517544709704004225659168707042261438994382453654216274156157610551788485324014845715737301586757338593069053128791064506499797663026671856839554046568049356163230461420799590507926740929010085130419324562484443216582123571397158344914197038197382061688934070052631373098859767207026151762525048588690610598925943032056864971131473759580406532630170612429142354277532457332487302326724142019151615941990077/11508518523254354969652121833759470795947906216015773915966628226936572684777252626606799355580217059073356586346746910930658868907738933493760000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-162359238108200", - "sign_hi": "-162359238108200" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 241, - "sq": "234022511557805425536427431320012693033472387524623561112037572546314556101537729577079022195284500127429378130614236011946962857652650160601584365899028040190403170079365532813480638649632471719454965688104619984311749382204545411574435125639775933259164236487025403154998731639425622130921141065906826930521331732563461493911773213406838554867706866371767122400626576413173608667431673815330193332922019343/4060343824671172955992018170639606340514904144970396483997437387652264787473795960024988932605533487104000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-53678450", - "sign_hi": "-53678450" - } - ], - "total": "15679/22800" - }, - { - "m": 77, - "e": "17/66", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 179, - "sq": "420200053812608814876295390304010240000000000000000000000/13237556025709312535736661182551669997805285704448401100081", - "sign_lo": "2399109206577", - "sign_hi": "2399109206577" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 7, - "sq": "5025160080656206890515717588840441994976286666194549867549164152907372694548979619647783679521094283454299962460111808752007997197506644578034800671576868692707153248972459664563213295222377529835202649279893344167764737445549605259011237033641578540344953768384904458350173552584692345028883510980558783477976769005630518466101333859892448807492197808082988882521553469705652686738682364825677203440731115466039244836494104234110596357484741666581242701454184962137162233862020072984503414874639461616299792165631257346285005620418503728089846349944525668293959841/111935091165084203197865625851741287211393628232432528493082224446433025330974687022504321733059233234615435571287054302944729874400840298234017049622105305046212997255952310269378560000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-170958887261724", - "sign_hi": "-170958887261724" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 233, - "sq": "13931522371971385996310735500432309758583387520468363245296267212458126574564776461806586542816079029949262908681386326875688732414110485338347131888499758911845357575850210349539229384095158211025402566734357223688146844773688577118188100172194586928394090723083976821503856644494698309660643919374166593209948322773428980024556657263312924662335104757966228060743374077319762152241342283061595489832589005502818889/258367143085194118821488292657800262357513258688029275924031880862923176822394439518297155439318951526400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-57151092", - "sign_hi": "-57151092" - } - ], - "total": "22327/33000" - }, - { - "m": 78, - "e": "241/936", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 176, - "sq": "182189307229264471392256000000000000000000000000/5907209889179239206634962489672385114270158476721", - "sign_lo": "2482886675064", - "sign_hi": "2482886675064" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 6, - "sq": "44689828356456868626829311477848879788112954212889767609582951417531850214941426263282179349003450919893946458315616659067828032758332032115309706832436957684104007939596760606796635046053292043176419444103553284418672963914689892913738192537907888762000648100380462583432256441079149548563359030721034656127313982516703709785784716005706564948003548256969441758864659512341910744253387690771799831876418602603669610807952830420202834688189700357128314747961183376151886538212446646502932065907553473140589030998545579/1324211951528275309622078143937537387436915482958679743217625238431188547167936254897343440823798790596884077153858280165713379328000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-179787806155656", - "sign_hi": "-179787806155656" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 225, - "sq": "353001217932566716784609874655734700728674455244037290307244311942323120166276355064937683778739461752171504508055514484059792665806452809914559522718371800431208188616104251682559830519741985821460820545398679774488666876811187108030929974125132617071449895860526375893296202333330374273424400228114659843822767365584775334318260186854675803832996943764836500763750040637653724168037936136899887020920621650632518311198527/7015116340548540084391444439390336115197353384820693073965102314973663538886130543932502004910090170138624000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-60690532", - "sign_hi": "-60690532" - } - ], - "total": "9718/14625" - }, - { - "m": 79, - "e": "61/237", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 174, - "sq": "533177648627877167431634288640000000000000000000000000000/17787789877404094069234460831384448623027660326591126626961", - "sign_lo": "2566558522525", - "sign_hi": "2566558522525" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 6, - "sq": "9342672566113224030771016590605620708661581955199548785448175461672560091405800497674481070673228230906723636747735363932401579073844415641578019476922590855141896838297232957553755984438065485378538080194937151209272065344015644291541620467924031026493010519252731350949590416182537829005305135175298744688718403836684652550554567171720788514446821426565433180824346947909026322289714551529142331327685707618680380917789853454124662221844961888990578758095183533578481121723649932428424291078697671521708305791962690433076088108359353494553920917553764937114159928401100524946449/369277187039229186394733905236060175600874060355900688778300368114349559088770744935088099385818236365861185086253949372816909577734558024149467077590171558100476846642427868070806763257567641600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-188848341604130", - "sign_hi": "-188848341604130" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 217, - "sq": "21922972405556724960646940816494791476198305723833862755229046653280222752712512733093929187394526179022765011729682329539005069435267786046610981783726300697891066099851184557290583327558233387330576162430162844775960360470447897961642768732729631800875722814888234759969596615009180447049502066013000679536561120600422997134904295248491470910709665157120294014744480545599873364032798510389485764780104195118672807169/467970559737262980948221337081473373428504464797049759125170946192756870519371386639260497292541726556160000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-64296770", - "sign_hi": "-64296770" - } - ], - "total": "155089/237000" - }, - { - "m": 80, - "e": "247/960", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 171, - "sq": "422463545703213316020633600000000000000000000/14498100074324544140627021920836325645098005641", - "sign_lo": "2650124748960", - "sign_hi": "2650124748960" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 5, - "sq": "1727881366479538734485160999933473541291561196806847519590113136484096663466228361683450773157615499427975856766105805241160155667276262555395237211071852123917321196508280472540670351785115949122371196533892649166805654518576698900830518811563028185879518936204417817538108719084480742831071184280370164975448264250842780448458815031619737428801420275783326631676652941221242109724964584204758846639244765771190294745606507851166104922073673089583/91343852333181432387730302044767688728495783936000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-198142840421280", - "sign_hi": "-198142840421280" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 209, - "sq": "45104633844449588975055707848166240806464434479066131910621054200920525566416260088600746416439234188405004557349720297373659413932806476550127777251794345109099401953628676421300983755959449634844320273429419469285902078310457901040971904875777331704111139511144539531800392211530678305826098173900600773358061122559815528844985407447328738954926128782283281206704586661393688561379600429914459031516921141687418275948389409588247/1036568661722147644388433226055806427539760570638425872479789001789564329123504253949869750772648105738240000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-67969806", - "sign_hi": "-67969806" - } - ], - "total": "3083/4800" - }, - { - "m": 81, - "e": "125/486", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 169, - "sq": "112354595222537012310243016704000000000000000000000000/3965196883689423067146616044472864997994887461426122649", - "sign_lo": "2733585354369", - "sign_hi": "2733585354369" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 4, - "sq": "13166494534609042047137136678883648965397864226237954343068944585618840416059341457901700641817245736724926152626109392531710905528535202003884116804200218414119338562113220346045731819625403332438102511764702738222282388120642214850198734288919249703451718519368942459616801785121025862609337992036876063094075272239343878705980816641834575118384841102415164081034362954068922908015970309447172479833420736037169528833204720317659367624183862437513422674132464114553955020011613390223563921216330337191472179036736320851902737175793901848487718937910898018416161/933309120494589822270875761775558033007171578202238867493386604896627109181261618401105644621678856564891971145707387236745779691087966808409140999335116653199360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-207673649421240", - "sign_hi": "-207673649421240" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 201, - "sq": "42175251639049901710354524464084932005929589066496892078275744947770583804135175023223966161797862753991758243866511409818638065236628742213921909845222913581555999339264765731308468191130072963280585440581343998695091696113788174750868815232629108627242829246901760235367731443362971415000889325091881966580861006761557642196053449421338702816386144161216651359989763375791680188826304772871044342775119995702899414510280627231236240009/1045801921371015683643658610370802258976034133384526025277009108568059602828085831924059167527727752474043351040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-71709640", - "sign_hi": "-71709640" - } - ], - "total": "76691/121500" } -] \ No newline at end of file +] diff --git a/docs/design.md b/docs/design.md index ec20c2b..bead07c 100644 --- a/docs/design.md +++ b/docs/design.md @@ -34,8 +34,9 @@ The two-chord integral theorem gives raw cubic scalar obstruction ≤ E_budget(m) + T0(m,α) + T1(m,α) + T2(m,α). ``` -For `5 ≤ m ≤ 81`, fixed rational budgets and critical brackets are checked for -every integer parameter. The complete critical expressions are tied to the +For `5 ≤ m ≤ 63`, fixed rational budgets and critical brackets are checked for +every integer parameter; the same existing row-64 certificate supplies the tail +base. The complete critical expressions are tied to the actual derivatives of `T0`, `T1`, and `T2`. Their polynomial signs are certified on entire outer intervals, while the middle interval uses monotone factors at opposite endpoints. This establishes the bound without trusting a sampled @@ -46,9 +47,20 @@ Scale positivity, interval membership, both endpoint supports and the complete polynomial equality remain explicit Lean obligations. The Python coefficient calculation is not in the trusted base. -For all real `m ≥ 81`, proved parameter antitonicity reduces the four-component -bound to the actual finite `m=81` certificate. `DistillationTailBound` discharges -that base; it is not left as a hypothesis of the final upper bound. +For all real `m ≥ 64`, proved parameter antitonicity reduces the four-component +bound to the existing finite `m=64` certificate. `DistillationTailBound` discharges +that base with its already-certified `<199/200` budget; no base or monotonicity +premise is left to the final caller. The rational component uses the actual +envelope-dependent denominator, with a split at `α=12`, rather than the old +independent worst-case bounds that required 81. + +The natural-number split `m < 64` versus `64 ≤ m` has no gap. The finite +aggregate proves exactly 5 through 63, and both it and the tail import the final +group `Rows61_64`; row 64 is emitted only once. The generator and validator share +an explicit 5-through-64 range, paired with the real tail theorem. They reject +missing64, extra65, duplicated/reordered rows and mismatched components rather +than inferring a smaller cutoff from truncated data. Rows 65 through 81 and all +old row-81-only/two-thirds interfaces have been retired. ## Endpoints and definitions @@ -74,9 +86,13 @@ Acceptance distinguishes: - original final-theorem type preservation; - actual value and type/value dependency checks for both final theorems. -Those dependency checks require all finite cases, the real tail base, the -geometric reduction and the certificate core, and reject the retired scalar -route. They do not equate a module import with proof consumption. +The earlier-tail consumer test checks actual proof-value edges from both final +theorems through the geometric reduction and the tail to row 64. Its recursive +project-value audit requires exactly cases 5 through 63 in the finite aggregate +and all 60 cases, including each of their three components and strict budgets, +in each final theorem. Retired cases and tail interfaces must be absent from +both the imported environment and the actual value closure. Dependency checks +do not equate a module import with proof consumption. Readability is the first selection criterion, measured compilation cost second, and line count third. Source counts include the shared certificate frontend; diff --git a/docs/getting-started.md b/docs/getting-started.md index de9d083..bf89060 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -55,9 +55,10 @@ diff -u Sendov/Common/DistillationFinite.lean "$out/generated/Sendov/Common/Dist python3 -m unittest discover -s tests ``` -The output is the entire finite family, in one selected grouped layout with the -tail base kept separately. Use a fresh output root; generation must not replace -a nonempty directory. See [`scripts/GENERATORS.md`](../scripts/GENERATORS.md) for +The output contains all 60 retained records (`m = 5..64`) in eight groups. +The finite aggregate consumes `m = 5..63`; the tail shares row 64 in the final +`Rows61_64` group. Use a fresh output root; generation must not replace a +nonempty directory. See [`scripts/GENERATORS.md`](../scripts/GENERATORS.md) for the retained global `sinh` generator and its SymPy dependency. If certificate data or generated proofs change, verify the complete affected diff --git a/formalization.yaml b/formalization.yaml index a8f8733..82a5256 100644 --- a/formalization.yaml +++ b/formalization.yaml @@ -5,8 +5,9 @@ project: description: 'Local Lean development of both complete conjectures, retaining the original polynomial, analytic and boundary arguments and replacing the old scalar endgame by a proved cubic polar envelope and exact critical-point certificates. Degrees 2 through 5 use the elementary analytic proof. - For n >= 6, m = n - 1: the finite range 5 <= m <= 81 is fully certified, and a real-parameter - tail uses the actual m=81 base. Final statements are unchanged; no numerical bound is assumed.' + For n >= 6, m = n - 1: the finite range 5 <= m <= 63 is fully certified, and the real-parameter + tail for m >= 64 uses the actual m=64 base. Exactly 60 unchanged records, m=5 through 64, + remain. Final statements are unchanged; no numerical bound is assumed.' authors: - Terence Tao license: Apache-2.0 @@ -186,9 +187,10 @@ automation: Generator output is rechecked by Lean; compiler and kernel acceptance are separate. review: status: self-assessed - notes: The local variant has independent agent source review and Lean kernel replay, with exact - final-theorem type comparison and actual dependency audits. These are not claims of independent - human mathematical review or endorsement by the upstream authors. + notes: The K64 pruning candidate has local exact-source compilation, kernel replay, original-contract + and actual proof-value dependency probes. Parent independent review and final whole-library gates + remain pending. These are not claims of independent human mathematical review or endorsement by + the upstream authors. known_gaps: [] limitations: - The two deliberate placeholders in Challenge.lean are specifications, not imported proof premises. @@ -220,9 +222,9 @@ alignment: lean: Sendov.distillFinite_scalar module: Sendov.Common.DistillationFinite status: proved - note: All integer m from 5 through 81; entire alpha domain, not samples. + note: All integer m from 5 through 63; entire alpha domain, not samples. - source: Real-parameter infinite tail - lean: Sendov.distillScalar_lt_two_thirds + lean: Sendov.distillScalar_lt_199_200 module: Sendov.LargeDegree.DistillationTailBound status: proved - note: All real m >= 81 and positive alpha <= 17; the actual m=81 base is discharged. + note: All real m >= 64 and positive alpha <= 17; the actual m=64 base is discharged. diff --git a/scripts/GENERATORS.md b/scripts/GENERATORS.md index 8e0de2e..9b8ef51 100644 --- a/scripts/GENERATORS.md +++ b/scripts/GENERATORS.md @@ -12,10 +12,11 @@ python3 -B -m unittest discover -s tests -v ``` The finite output directory must be new or empty. The generator emits all -`m = 5,...,81`, components `0,1,2`, with the unchanged table brackets/budgets. -Rows 5–80 are grouped in batches of eight (last batch 77–80); Row81 is separate -because it supplies the infinite-tail base. The output contains exactly these -11 row modules and `Sendov/Common/DistillationFinite.lean`. No second per-row +`m = 5,...,64`, components `0,1,2`, with the unchanged selected table records. +Rows are grouped in batches of eight, ending in `Rows61_64`. The finite +aggregate covers 5–63; the real tail starts at 64 and uses the original row-64 +`<199/200` budget from that same group. The output contains exactly these +eight row modules and `Sendov/Common/DistillationFinite.lean`. No second per-row source tree is published. `bundle_rows.py` is the source-packaging helper, not a certificate checker or an alternative proof route. @@ -25,7 +26,10 @@ workspace restriction. Paths can be absolute or relative to the caller's cwd. `data/paper_certificate_table.json`; the same exact schema, ordered coverage, bracket, sign, squared-envelope and budget checks apply. Editing that input changes a proposed certificate, not the proof trust base. Keep the shipped table -unchanged to reproduce the accepted source. +unchanged to reproduce the selected source. `distillation_data.py` is the explicit +range authority, paired with `distillComponents_lt_199_200`; truncated inputs +cannot select a different cutoff. In particular, missing64, extra65, duplicate +or reordered rows, and duplicate/reordered/mismatched components are rejected. All data validation and exact row rendering finish before staging. The complete grouped snapshot is then staged beside the target and committed by one directory @@ -60,7 +64,8 @@ build/kernel replay and the two headline type contracts remain separate gates. Tao's Sendov development (Apache-2.0); original notices are preserved. - Mathematical table/route: Senjian An, *Proof Distillation for Sendov's Conjecture*, [fixed revision e8ae601491ec171ab4f7f8456113dd6a047aa85d](https://github.com/SJanPerth/Sendov-Proof-Distillation/tree/e8ae601491ec171ab4f7f8456113dd6a047aa85d). - The table is unchanged; see `../data/README.md` for CC BY 4.0 attribution. + Retained records are an unchanged ordered subset, not the full donor table; + see `../data/README.md` for CC BY 4.0 attribution. - The rational envelope checks in `distillation_data.py` adapt that revision's explicitly MIT-licensed `verification/verify_paper.py`; the original Senjian An copyright/permission notice is retained in `LICENSE-DISTILLATION-MIT.txt`. diff --git a/scripts/axioms.lean b/scripts/axioms.lean index 251e0ab..0fe837a 100644 --- a/scripts/axioms.lean +++ b/scripts/axioms.lean @@ -38,7 +38,11 @@ end SendovAudit #sendov_axioms SendovConjecture.phelps_rodriguez #sendov_axioms Sendov.distillFinite_components #sendov_axioms Sendov.distillFinite_scalar -#sendov_axioms Sendov.distillFiniteTailBase -#sendov_axioms Sendov.distillComponents_lt_two_thirds -#sendov_axioms Sendov.distillScalar_lt_two_thirds +#sendov_axioms Sendov.distillFinite_64 +#sendov_axioms Sendov.distillFiniteBound_64 +#sendov_axioms Sendov.distillComponents_le_64 +#sendov_axioms Sendov.distillT2_zero +#sendov_axioms Sendov.distillComponents_lt_199_200 +#sendov_axioms Sendov.distillScalar_lt_199_200 +#sendov_axioms Sendov.distillScalar_lt_one #sendov_axioms Sendov.polar_origin_incompatible diff --git a/scripts/bundle_rows.py b/scripts/bundle_rows.py index 9e919cf..0704e26 100644 --- a/scripts/bundle_rows.py +++ b/scripts/bundle_rows.py @@ -1,13 +1,13 @@ """Bundle this generator's self-contained RowN modules, preserving each body. This is source packaging, not a certificate checker or a general Lean parser. -Row81 remains separate because it is the independently used infinite-tail base. +The last group includes the row-64 base shared with the infinite tail. """ from pathlib import Path import argparse import json +from distillation_data import ROWS -ROWS = tuple(range(5, 82)) PREFIX = 'Sendov.DistillationFinite.' @@ -26,23 +26,20 @@ def bundle(source, output, size=8): rows_dir = source / 'Sendov/DistillationFinite' expected = {f'Row{m}.lean' for m in ROWS} if {p.name for p in rows_dir.glob('Row*.lean')} != expected: - raise ValueError('rows must be exactly Row5 through Row81') + raise ValueError('rows must be exactly Row5 through Row64') rows = {m: split_row((rows_dir / f'Row{m}.lean').read_text()) for m in ROWS} aggregate = (source / 'Sendov/Common/DistillationFinite.lean').read_text() row_imports = [line for line in aggregate.splitlines() if line.startswith(f'import {PREFIX}Row')] if row_imports != [f'import {PREFIX}Row{m}' for m in ROWS]: raise ValueError('aggregate must import each row exactly once in original order') - groups = [list(range(start, min(start + size, 81))) for start in range(5, 81, size)] + [[81]] + groups = [list(ROWS[start:start + size]) for start in range(0, len(ROWS), size)] rendered, manifest = {}, [] for group in groups: - name = 'Row81' if group == [81] else f'Rows{group[0]}_{group[-1]}' + name = f'Rows{group[0]}_{group[-1]}' path = f'Sendov/DistillationFinite/{name}.lean' - if group == [81]: - text = (rows_dir / 'Row81.lean').read_text() - else: - imports = list(dict.fromkeys(line for m in group for line in rows[m][0])) - text = '\n'.join(imports) + '\n\n' - text += '\n'.join('section\n' + rows[m][1] + '\nend\n' for m in group) + imports = list(dict.fromkeys(line for m in group for line in rows[m][0])) + text = '\n'.join(imports) + '\n\n' + text += '\n'.join('section\n' + rows[m][1] + '\nend\n' for m in group) rendered[path] = text manifest.append({'module': PREFIX + name, 'path': path, 'rows': group}) replacements = ''.join(f"import {group['module']}\n" for group in manifest) diff --git a/scripts/distillation_data.py b/scripts/distillation_data.py index 98c1720..37df6aa 100644 --- a/scripts/distillation_data.py +++ b/scripts/distillation_data.py @@ -10,6 +10,12 @@ import json from pathlib import Path +# Paired with distillComponents_lt_199_200: real m >= 64 uses the row-64 base. +# Never derive an allowed lower tail threshold from the supplied table. +TAIL_START = 64 +ROWS = tuple(range(5, TAIL_START + 1)) +FINITE_ROWS = ROWS[:-1] + def require(condition, message): if not condition: @@ -65,11 +71,11 @@ def candidate_squared(m, j, lo, hi): def load_table(path, coefficients): rows = json.loads(Path(path).read_text(encoding='utf-8'), object_pairs_hook=object_pairs, parse_constant=reject_constant) - require(type(rows) is list and len(rows) == 77, 'exactly 77 rows required') - for m, row in zip(range(5, 82), rows): + require(type(rows) is list and len(rows) == len(ROWS), 'exactly 60 rows required') + for m, row in zip(ROWS, rows): fields(row, 'm e components total', f'row {m}') require(type(row['m']) is int and row['m'] == m, - 'rows must be m=5..81 exactly once in order') + 'rows must be m=5..64 exactly once in order') e = rational(row['e']) require(e == F(1, 4) + F(7, 12*m), f'E budget mismatch at {m}') parts = row['components'] @@ -107,6 +113,4 @@ def load_table(path, coefficients): total += budget require(total == rational(row['total']), 'total budget mismatch') require(total < F(199, 200), 'finite bound failed') - if m == 81: - require(total < F(2, 3), 'tail base bound failed') return rows diff --git a/scripts/gen_distillation.py b/scripts/gen_distillation.py index 8e20827..9a1e864 100644 --- a/scripts/gen_distillation.py +++ b/scripts/gen_distillation.py @@ -13,7 +13,7 @@ import os import tempfile from bundle_rows import bundle -from distillation_data import load_table +from distillation_data import FINITE_ROWS, ROWS, load_table from fractions import Fraction as F from math import comb, gcd, lcm from pathlib import Path @@ -138,37 +138,31 @@ def row_source(row): theorem distillFiniteBound_{m} : ({total} : ℝ) < 199 / 200 := by norm_num -''' - if m==81: - s+='''theorem distillFiniteTailBase {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : - distillEBudget 81 + distillT0 81 α + distillT1 81 α + distillT2 81 α < 2 / 3 := by - exact (distillFinite_81 α hα h17).trans_lt (by norm_num) - ''' s+='end Sendov\n' return s def aggregate_source(): - s=''.join(f'import Sendov.DistillationFinite.Row{m}\n' for m in range(5,82)) - s+=''' + s=''.join(f'import Sendov.DistillationFinite.Row{m}\n' for m in ROWS) + s+=f''' /-! Exact finite-domain critical-bracket closure. Fixed original paper budgets; see DistillationCriticalFinite for attribution. No sampled truth or global T grid. -/ namespace Sendov -theorem distillFinite_components {m : ℕ} (hm : 5 ≤ m) (hm81 : m ≤ 81) - {α : ℝ} (hα : 0 ≤ α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : +theorem distillFinite_components {{m : ℕ}} (hm : 5 ≤ m) (hm63 : m ≤ {FINITE_ROWS[-1]}) + {{α : ℝ}} (hα : 0 ≤ α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := by interval_cases m ''' - for m in range(5,82): + for m in FINITE_ROWS: s+=f' · exact (distillFinite_{m} α hα (by linarith)).trans_lt distillFiniteBound_{m}\n' - s+=''' -theorem distillFinite_scalar {m : ℕ} (hm : 5 ≤ m) (hm81 : m ≤ 81) - {α : ℝ} (hα : 0 < α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : + s+=f''' +theorem distillFinite_scalar {{m : ℕ}} (hm : 5 ≤ m) (hm63 : m ≤ {FINITE_ROWS[-1]}) + {{α : ℝ}} (hα : 0 < α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : scalarObstruction m α (cubicPolarEnvelope α) < 199 / 200 := by have hmR : (5 : ℝ) ≤ m := by exact_mod_cast hm exact (distillScalar_le_majorant hmR hα (by linarith)).trans_lt - (distillFinite_components hm hm81 hα.le hαm h17) + (distillFinite_components hm hm63 hα.le hαm h17) end Sendov ''' diff --git a/tests/BoundaryConsumer.lean b/tests/BoundaryConsumer.lean index 321d3d4..867555c 100644 --- a/tests/BoundaryConsumer.lean +++ b/tests/BoundaryConsumer.lean @@ -1,6 +1,6 @@ import Lean import Sendov.Common.DistillationCritical -import Sendov.LargeDegree.DistillationTail +import Sendov.LargeDegree.DistillationTailBound namespace MathPolishBoundary @@ -10,18 +10,23 @@ theorem raw_zero (m : ℝ) : Sendov.scalarObstruction_zero m /-- The tail component vanishes at the closed left endpoint. -/ -theorem tail_zero {m : ℝ} (hm : 81 ≤ m) : Sendov.distillT2 m 0 = 0 := +theorem tail_zero {m : ℝ} (hm : 64 ≤ m) : Sendov.distillT2 m 0 = 0 := Sendov.distillT2_zero hm /-- Both boundary identities are consumed together at the real tail threshold. -/ theorem threshold_boundary : - Sendov.scalarObstruction 81 0 (Sendov.cubicPolarEnvelope 0) = 1 / 162 ∧ - Sendov.distillT2 81 0 = 0 := by + Sendov.scalarObstruction 64 0 (Sendov.cubicPolarEnvelope 0) = 1 / 128 ∧ + Sendov.distillT2 64 0 = 0 := by constructor - · convert raw_zero 81 using 1 + · convert raw_zero 64 using 1 norm_num · exact tail_zero (by norm_num) +theorem closed_tail {m α : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) (h17 : α ≤ 17) : + Sendov.distillEBudget m + Sendov.distillT0 m α + + Sendov.distillT1 m α + Sendov.distillT2 m α < 199 / 200 := + Sendov.distillComponents_lt_199_200 hm hα h17 + end MathPolishBoundary open Lean Elab Command in @@ -29,7 +34,8 @@ run_cmd do let env := (← getEnv).setExporting false for (consumer, target) in #[ (`MathPolishBoundary.raw_zero, `Sendov.scalarObstruction_zero), - (`MathPolishBoundary.tail_zero, `Sendov.distillT2_zero)] do + (`MathPolishBoundary.tail_zero, `Sendov.distillT2_zero), + (`MathPolishBoundary.closed_tail, `Sendov.distillComponents_lt_199_200)] do let some info := env.find? consumer | throwError "missing consumer {consumer}" let some value := info.value? (allowOpaque := true) | throwError "missing proof value" unless value.getUsedConstants.contains target do diff --git a/tests/EarlierTail.lean b/tests/EarlierTail.lean new file mode 100644 index 0000000..61c93ab --- /dev/null +++ b/tests/EarlierTail.lean @@ -0,0 +1,144 @@ +import Lean +import Solution + +open Sendov + +namespace EarlierTailTest + +example {m : ℕ} (hm : 5 ≤ m) : (5 ≤ m ∧ m ≤ 63) ∨ 64 ≤ m := by omega + +example {m : ℕ} (hm : 5 ≤ m) (hm63 : m ≤ 63) : + distillEBudget m + distillT0 m 0 + distillT1 m 0 + distillT2 m 0 < 199 / 200 := + distillFinite_components hm hm63 (by norm_num) (by positivity) (by norm_num) + +example {m α : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) (h17 : α ≤ 17) : + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := + distillComponents_lt_199_200 hm hα h17 + +example {m α : ℝ} (hm : 64 ≤ m) (hα : 0 < α) (h17 : α ≤ 17) : + scalarObstruction m α (cubicPolarEnvelope α) < 1 := + (distillScalar_lt_199_200 hm hα h17).trans (by norm_num) + +example : + distillEBudget 64 + distillT0 64 0 + distillT1 64 0 + distillT2 64 0 < 199 / 200 := + distillComponents_lt_199_200 (by norm_num) (by norm_num) (by norm_num) + +example : + scalarObstruction 64 0 (cubicPolarEnvelope 0) = 1 / 128 := by + rw [scalarObstruction_zero] + norm_num + +example : + distillEBudget (129 / 2) + distillT0 (129 / 2) 17 + + distillT1 (129 / 2) 17 + distillT2 (129 / 2) 17 < 199 / 200 := + distillComponents_lt_199_200 (by norm_num) (by norm_num) (by norm_num) + +example {n : ℕ} (hn : 6 ≤ n) {α : ℝ} + (hα : 0 < α) (h17 : α ≤ 17) (hhalf : 2 * α ≤ M n) : + scalarObstruction (M n) α (cubicPolarEnvelope α) < 1 := + distillScalar_lt_one hn hα h17 hhalf + +example : scalarObstruction (M 6) (5 / 2) (cubicPolarEnvelope (5 / 2)) < 1 := + distillScalar_lt_one (by norm_num) (by norm_num) (by norm_num) (by norm_num [M]) + +example : scalarObstruction (M 64) 17 (cubicPolarEnvelope 17) < 1 := + distillScalar_lt_one (by norm_num) (by norm_num) (by norm_num) (by norm_num [M]) + +example : scalarObstruction (M 65) 17 (cubicPolarEnvelope 17) < 1 := + distillScalar_lt_one (by norm_num) (by norm_num) (by norm_num) (by norm_num [M]) + +open Polynomial in +example {p : ℂ[X]} (hdeg : 2 ≤ p.natDegree) + (hzeroes : ∀ w : ℂ, p.eval w = 0 → ‖w‖ ≤ 1) {a : ℂ} (hpa : p.eval a = 0) : + ∃ ζ : ℂ, (derivative p).eval ζ = 0 ∧ ‖ζ - a‖ ≤ 1 := + SendovConjecture.sendov hdeg hzeroes hpa + +open Polynomial in +example {p : ℂ[X]} (hdeg : 2 ≤ p.natDegree) + (hzeroes : ∀ w : ℂ, p.eval w = 0 → ‖w‖ ≤ 1) {a : ℂ} (hpa : p.eval a = 0) : + (∃ ζ : ℂ, (derivative p).eval ζ = 0 ∧ ‖ζ - a‖ < 1) ∨ + (‖a‖ = 1 ∧ ∃ c : ℂ, c ≠ 0 ∧ + p = C c * (X ^ p.natDegree - C (a ^ p.natDegree))) := + SendovConjecture.phelps_rodriguez hdeg hzeroes hpa + +end EarlierTailTest + +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + for (consumer, targets) in #[ + (`Sendov.distillComponents_lt_199_200, + #[`Sendov.distillComponents_le_64, `Sendov.distillFinite_64, + `Sendov.distillFiniteBound_64]), + (`Sendov.distillScalar_lt_199_200, + #[`Sendov.distillScalar_le_majorant, `Sendov.distillComponents_lt_199_200]), + (`Sendov.distillScalar_lt_one, + #[`Sendov.distillFinite_scalar, `Sendov.distillScalar_lt_199_200]), + (`Sendov.polar_origin_incompatible, #[`Sendov.distillScalar_lt_one]), + (`Sendov.sendov_interior, #[`Sendov.polar_origin_incompatible]), + (`Sendov.sendov_interior_real, #[`Sendov.sendov_interior]), + (`Sendov.phelps_rodriguez, #[`Sendov.sendov_interior_real]), + (`Sendov.sendov, #[`Sendov.phelps_rodriguez]), + (`SendovConjecture.sendov, #[`Sendov.sendov]), + (`SendovConjecture.phelps_rodriguez, #[`Sendov.phelps_rodriguez])] do + let some info := env.find? consumer | throwError "missing declaration {consumer}" + let some value := info.value? (allowOpaque := true) | throwError "missing proof {consumer}" + for target in targets do + unless value.getUsedConstants.contains target do + throwError "not an actual proof consumer: {consumer} -> {target}" + logInfo m!"EARLIER_TAIL_CONSUMER {consumer} -> {target}" + for target in #[`Sendov.distillComponents_lt_199_200, `Sendov.distillScalar_lt_199_200, + `Sendov.distillScalar_lt_one, `SendovConjecture.sendov, + `SendovConjecture.phelps_rodriguez] do + let axioms ← withEnv env <| Lean.collectAxioms target + unless axioms.all (#[``propext, ``Classical.choice, ``Quot.sound].contains) do + throwError "unexpected axiom in {target}: {axioms}" + logInfo m!"EARLIER_TAIL_AXIOMS {target}: {axioms}" + +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + let retired := #[ + `Sendov.distillFiniteTailBase, `Sendov.distillComponents_lt_two_thirds, + `Sendov.distillScalar_lt_two_thirds, `Sendov.distillComponents_lt_two_thirds_of_base, + `Sendov.distillEBudget_le_81, `Sendov.distillT0_le_81, `Sendov.distillT1_le_81, + `Sendov.distillT2_le_81, `Sendov.distillComponents_le_81, `Sendov.distillTail_polynomial_pos] + for name in retired do + if env.contains name then throwError "retired declaration still imported: {name}" + -- Only project values can reference project cases: earlier imported libraries + -- cannot depend on declarations introduced later by Sendov. + for (root, upper) in #[(`Sendov.distillFinite_components, 63), + (`SendovConjecture.sendov, 64), (`SendovConjecture.phelps_rodriguez, 64)] do + let mut pending := [root] + let mut visited : Std.HashSet Name := {} + while !pending.isEmpty do + let name := pending.head! + pending := pending.tail! + unless visited.contains name do + visited := visited.insert name + let some info := env.find? name | throwError "missing closure declaration {name}" + if let some value := info.value? (allowOpaque := true) then + for used in value.getUsedConstants do + let text := used.toString + if text.startsWith "Sendov." || text.startsWith "SendovConjecture." || + text.startsWith "_private.Sendov." then + pending := used :: pending + for m in [5:82] do + for stem in ["distillFinite_", "distillFiniteBound_"] do + let name := Name.str `Sendov s!"{stem}{m}" + unless visited.contains name == (m ≤ upper) do + throwError "wrong actual case closure: {root}, {name}" + if 65 ≤ m && env.contains name then + throwError "retired case still imported: {name}" + for j in [0:3] do + let name := Name.str (Name.str `Sendov s!"CriticalRow{m}") s!"component{j}" + unless visited.contains name == (m ≤ upper) do + throwError "wrong actual component closure: {root}, {name}" + if 65 ≤ m && env.contains name then + throwError "retired component still imported: {name}" + for name in visited do + let text := name.toString + if retired.contains name || (text.splitOn "two_thirds").length > 1 || + (text.splitOn "_le_81").length > 1 then + throwError "retired tail in actual value closure: {root}, {name}" + logInfo m!"K64_VALUE_CLOSURE {root}: 5..{upper}, three components, no retired names" diff --git a/tests/expected.json b/tests/expected.json index a995e41..bfbdd63 100644 --- a/tests/expected.json +++ b/tests/expected.json @@ -1,7 +1,6 @@ { "distillation": { - "Sendov/Common/DistillationFinite.lean": "97670634929b5a00e89af11202a4c86b2b5c17b2b7f858ef73fcee19df353ac2", - "Sendov/DistillationFinite/Row81.lean": "7f0565233bdc4eef09a2b63c6bcfa57dafee71958f25bc65fe62bcdb8fa15431", + "Sendov/Common/DistillationFinite.lean": "e5ae2b52fbda2e65368248e34647d4c9516036a9ab1f2e7c0443f045fc4e0cd2", "Sendov/DistillationFinite/Rows13_20.lean": "7cfbd3aac6f3639f5e8d0ecd9773386c000aa27479d2c75a5d196e252e812110", "Sendov/DistillationFinite/Rows21_28.lean": "4259d6f25898cdee240186ef412cc47881909fe1d91ff613f46e116a642edd68", "Sendov/DistillationFinite/Rows29_36.lean": "f3dfd178a770b4e1101f54f9bd1e82f9ed3e36cedc2960adc676a71b8d680a49", @@ -9,10 +8,9 @@ "Sendov/DistillationFinite/Rows45_52.lean": "0b6b601e18f4369f0faa0a2f15f3c59975efe564ebbf3bfafb938e4b48e2bd5f", "Sendov/DistillationFinite/Rows53_60.lean": "ad156609407557c02747118bfd833813835fa781507df406e1707523d33d5ee5", "Sendov/DistillationFinite/Rows5_12.lean": "f783474650bc285a809277a6998cb9c3767e143497271c596a686c7bbba3af24", - "Sendov/DistillationFinite/Rows61_68.lean": "05c54742bd3642cab76e77cfa0dafc4d98305ee5a98c5c5626c2e72e21bf4e9b", - "Sendov/DistillationFinite/Rows69_76.lean": "e4458cf4b612829411e207e52c649252bbc602a0c69b4505eb4e2a163e127333", - "Sendov/DistillationFinite/Rows77_80.lean": "bd82f21e648d564fc16f8146502258da08f1847734b8b7e014f8e49ca6af3bbd" + "Sendov/DistillationFinite/Rows61_64.lean": "0725e96ed60c19486537a16b1a2d370ae20c887754edbb25b611249b4a899113" }, + "table_sha256": "3cc794c71cb0eb7f052f8623016da364cf5ed18f18be29599092111bfb451964", "sinh": { "sha256": "d04df2219415aa8e4f838c9c1b246b35af087e4ba41d4c449f95fe0f436c4acb", "bytes": 15024 diff --git a/tests/test_axiom_audit.py b/tests/test_axiom_audit.py index 7281fbb..9cd9308 100644 --- a/tests/test_axiom_audit.py +++ b/tests/test_axiom_audit.py @@ -1,4 +1,5 @@ """Real offline Lean fixtures for the auditor, not proofs of Sendov.""" +import json import os from pathlib import Path import re @@ -11,7 +12,31 @@ TOOLCHAIN = (REPO / 'lean-toolchain').read_text().strip() ENV = dict(os.environ, ELAN_TOOLCHAIN=TOOLCHAIN) ENV['PATH'] = str(Path.home() / '.elan/bin') + os.pathsep + ENV['PATH'] -TARGETS = ['SendovConjecture.sendov', 'SendovConjecture.phelps_rodriguez', 'Sendov.distillFinite_components', 'Sendov.distillFinite_scalar', 'Sendov.distillFiniteTailBase', 'Sendov.distillComponents_lt_two_thirds', 'Sendov.distillScalar_lt_two_thirds', 'Sendov.polar_origin_incompatible'] +# Independent expected audit surface: do not derive this from scripts/axioms.lean. +TARGETS = [ + 'SendovConjecture.sendov', + 'SendovConjecture.phelps_rodriguez', + 'Sendov.distillFinite_components', + 'Sendov.distillFinite_scalar', + 'Sendov.distillFinite_64', + 'Sendov.distillFiniteBound_64', + 'Sendov.distillComponents_le_64', + 'Sendov.distillT2_zero', + 'Sendov.distillComponents_lt_199_200', + 'Sendov.distillScalar_lt_199_200', + 'Sendov.distillScalar_lt_one', + 'Sendov.polar_origin_incompatible', +] + +MODULES = { + 'Sendov.DistillationFinite.Rows61_64': TARGETS[4:6], + 'Sendov.Common.DistillationFinite': TARGETS[2:4], + 'Sendov.LargeDegree.DistillationTail': TARGETS[6:8], + 'Sendov.LargeDegree.DistillationTailBound': TARGETS[8:10], + 'Sendov.Common.DistillationBounds': TARGETS[10:11], + 'Sendov.Reduction.Main': TARGETS[11:], + 'Solution': TARGETS[:2], +} def put(path, text): @@ -31,11 +56,11 @@ def fixture(name, mode, script_root, bad_target=None): shutil.rmtree(project) project.mkdir(parents=True) put(project / 'lean-toolchain', TOOLCHAIN + '\n') - put(project / 'lakefile.toml', '''name = "audit_fixture" + put(project / 'lakefile.toml', f'''name = "audit_fixture" version = "0.0.0" [[lean_lib]] name = "Fixture" -roots = ["Dependency", "Solution", "Sendov.Common.DistillationFinite", "Sendov.LargeDegree.DistillationTailBound"] +roots = {json.dumps(['Dependency', *MODULES])} ''') dependency = 'theorem dependencyBridge : True := True.intro\n' if mode == 'external': @@ -49,18 +74,19 @@ def fixture(name, mode, script_root, bad_target=None): (Classical.choice (α := True) ⟨True.intro⟩)) ''' put(project / 'Dependency.lean', dependency) - modules = { 'Solution.lean': TARGETS[:2], - 'Sendov/Common/DistillationFinite.lean': TARGETS[2:4], - 'Sendov/LargeDegree/DistillationTailBound.lean': TARGETS[4:] } - for module, targets in modules.items(): - text = 'import Dependency\n\n' + # A dependency chain keeps the tiny fixture compilers serial. These are + # auditor fixtures, not replacements for the real mathematical modules. + previous = 'Dependency' + for module, targets in MODULES.items(): + text = f'import {previous}\n\n' for target in targets: if mode == 'missing' and target == bad_target: continue proof = ('dependencyBridge' if bad_target is None or target == bad_target else 'True.intro') text += f'theorem {target} : True := {proof}\n' - put(project / module, text) + put(project / (module.replace('.', '/') + '.lean'), text) + previous = module # Deliberate statement-only holes required by audit.sh step 2, not imported. put(project / 'Challenge.lean', 'theorem challengeA : True := by sorry\n' 'theorem challengeB : True := by sorry\n') @@ -89,8 +115,18 @@ def setUpClass(cls): @classmethod def tearDownClass(cls): + if destination := os.environ.get('SENDOV_AUDIT_LOG_DIR'): + shutil.copytree(LOGS, destination, dirs_exist_ok=True) cls.temporary.cleanup() + def test_query_targets_match_independent_fixture_targets(self): + queries = re.findall(r'^#sendov_axioms[ \t]+(\S+)', + (REPO / 'scripts/axioms.lean').read_text(), re.M) + self.assertEqual(len(TARGETS), len(set(TARGETS)), 'duplicate fixture target') + self.assertCountEqual(queries, TARGETS) + self.assertCountEqual([target for targets in MODULES.values() for target in targets], + TARGETS) + def test_empty_and_standard_axioms_pass(self): for mode in ['empty', 'standard']: with self.subTest(mode=mode): diff --git a/tests/test_bundle_rows.py b/tests/test_bundle_rows.py index a54a23c..b900b2e 100644 --- a/tests/test_bundle_rows.py +++ b/tests/test_bundle_rows.py @@ -1,9 +1,11 @@ from pathlib import Path import importlib.util +import sys import tempfile import unittest ROOT = Path(__file__).resolve().parents[1] / 'scripts' +sys.path.insert(0, str(ROOT)) spec = importlib.util.spec_from_file_location('bundle_rows', ROOT / 'bundle_rows.py') bundle_rows = importlib.util.module_from_spec(spec) spec.loader.exec_module(bundle_rows) @@ -14,26 +16,27 @@ def fixture(self, root): rows = source / 'Sendov/DistillationFinite' rows.mkdir(parents=True) (source / 'Sendov/Common').mkdir() - for m in range(5, 82): + for m in range(5, 65): (rows / f'Row{m}.lean').write_text( 'import Mathlib.Data.Nat.Basic\n\n' f'namespace FixtureRow{m}\ntheorem value : (1 : Nat) = 1 := rfl\nend FixtureRow{m}\n') (source / 'Sendov/Common/DistillationFinite.lean').write_text(''.join( - f'import Sendov.DistillationFinite.Row{m}\n' for m in range(5, 82)) + '\n-- aggregate body\n') + f'import Sendov.DistillationFinite.Row{m}\n' for m in range(5, 65)) + '\n-- aggregate body\n') return source def test_all_rows_once_in_original_order_and_bodies_preserved(self): with tempfile.TemporaryDirectory() as temporary: root = Path(temporary); source = self.fixture(root) result = bundle_rows.bundle(source, root / 'out', size=8) - self.assertEqual([m for group in result['groups'] for m in group['rows']], list(range(5, 82))) + self.assertEqual([m for group in result['groups'] for m in group['rows']], list(range(5, 65))) for group in result['groups']: text = (root / 'out' / group['path']).read_text() for m in group['rows']: original = (source / f'Sendov/DistillationFinite/Row{m}.lean').read_text() body = ''.join(x for x in original.splitlines(keepends=True) if not x.startswith('import ')) self.assertIn(body, text) - self.assertTrue((root / 'out/Sendov/DistillationFinite/Row81.lean').is_file()) + self.assertEqual(result['groups'][-1]['module'], 'Sendov.DistillationFinite.Rows61_64') + self.assertFalse((root / 'out/Sendov/DistillationFinite/Row64.lean').exists()) self.assertFalse((root / 'out/Sendov/DistillationFinite/Row46.lean').exists()) aggregate = (root / 'out/Sendov/Common/DistillationFinite.lean').read_text() self.assertNotIn('import Sendov.DistillationFinite.Row46\n', aggregate) @@ -42,7 +45,16 @@ def test_all_rows_once_in_original_order_and_bodies_preserved(self): def test_missing_row_fails_before_output(self): with tempfile.TemporaryDirectory() as temporary: root = Path(temporary); source = self.fixture(root) - (source / 'Sendov/DistillationFinite/Row6.lean').unlink() + (source / 'Sendov/DistillationFinite/Row64.lean').unlink() + with self.assertRaisesRegex(ValueError, 'rows'): + bundle_rows.bundle(source, root / 'out') + self.assertFalse((root / 'out').exists()) + + def test_extra_row65_fails_before_output(self): + with tempfile.TemporaryDirectory() as temporary: + root = Path(temporary); source = self.fixture(root) + (source / 'Sendov/DistillationFinite/Row65.lean').write_text( + 'import Mathlib.Data.Nat.Basic\n') with self.assertRaisesRegex(ValueError, 'rows'): bundle_rows.bundle(source, root / 'out') self.assertFalse((root / 'out').exists()) diff --git a/tests/test_generator_core.py b/tests/test_generator_core.py index 7544341..94cc166 100644 --- a/tests/test_generator_core.py +++ b/tests/test_generator_core.py @@ -10,10 +10,56 @@ sys.path.insert(0, str(Path(__file__).resolve().parents[1] / 'scripts')) import gen_distillation as g +from distillation_data import load_table import generator_output class ExactCoreTests(unittest.TestCase): + def test_k64_exact_allowed_domain_and_components(self): + selected = [r for r in json.loads(g.TABLE.read_text()) if 5 <= r['m'] <= 64] + self.assertEqual([r['m'] for r in selected], list(range(5, 65))) + with tempfile.TemporaryDirectory() as temporary: + table = Path(temporary) / 'table.json' + table.write_text(json.dumps(selected)) + self.assertEqual(load_table(table, g.coefficients), selected) + mutations = { + 'missing64': lambda r: r.pop(), + 'extra65': lambda r: r.append(dict(r[-1], m=65)), + 'duplicate': lambda r: r.__setitem__(1, r[0]), + 'reordered': lambda r: r.reverse(), + 'duplicate component': lambda r: r[0]['components'].__setitem__( + 1, r[0]['components'][0]), + 'reordered components': lambda r: r[0]['components'].reverse(), + 'mismatched components': lambda r: r[0].__setitem__( + 'components', r[1]['components']), + } + for name, mutate in mutations.items(): + with self.subTest(mutation=name): + rows = json.loads(json.dumps(selected)) + mutate(rows) + table.write_text(json.dumps(rows)) + with self.assertRaises(ValueError): + load_table(table, g.coefficients) + + def test_k64_generator_covers_59_finite_cases_and_one_shared_base(self): + with tempfile.TemporaryDirectory() as temporary: + output = Path(temporary) / 'output' + result = g.generate(output) + self.assertEqual(result['rows'], list(range(5, 65))) + self.assertEqual(result['groups'][-1]['rows'], [61, 62, 63, 64]) + self.assertEqual(len(result['groups']), 8) + self.assertTrue((output / 'Sendov/DistillationFinite/Rows61_64.lean').is_file()) + self.assertFalse((output / 'Sendov/DistillationFinite/Row64.lean').exists()) + aggregate = (output / 'Sendov/Common/DistillationFinite.lean').read_text() + cases = [f' · exact (distillFinite_{m} α hα (by linarith)).trans_lt ' + f'distillFiniteBound_{m}' for m in range(5, 64)] + self.assertEqual([line for line in aggregate.splitlines() + if line.startswith(' · exact (distillFinite_')], cases) + self.assertIn('(hm63 : m ≤ 63)', aggregate) + for path in output.rglob('*.lean'): + self.assertNotIn('two_thirds', path.read_text()) + self.assertNotIn('distillFiniteTailBase', path.read_text()) + def test_real_pilot_uses_raw_coefficient_list(self): row = next(r for r in json.loads(g.TABLE.read_text()) if r['m'] == 46) text = g.row_source(row) diff --git a/tests/test_generators.py b/tests/test_generators.py index 6b0eee2..785b3c2 100644 --- a/tests/test_generators.py +++ b/tests/test_generators.py @@ -1,7 +1,7 @@ """Portable active-route generator tests. Run with unittest, using Python with SymPy. -The digest fixture pins the accepted mathematical source (only the generator-path -comment changed). It is shipped here; no workspace report or external fixture is read. +The digest fixture pins the selected mathematical source. It is shipped here; +no workspace report or external fixture is read. These are Python regressions, not Lean acceptance tests. """ import hashlib @@ -36,6 +36,11 @@ def inventory(root): class GeneratorTests(unittest.TestCase): + def test_retained_table_matches_pinned_original_subset(self): + table = ROOT / 'data/paper_certificate_table.json' + self.assertEqual(digest(table), EXPECTED['table_sha256']) + self.assertEqual([r['m'] for r in json.loads(table.read_text())], list(range(5, 65))) + def setUp(self): self.temp = tempfile.TemporaryDirectory() self.addCleanup(self.temp.cleanup) @@ -63,8 +68,9 @@ def assert_distillation(self, output): actual = {str(p.relative_to(output)): digest(p) for p in output.rglob('*') if p.is_file()} self.assertEqual(actual, EXPECTED['distillation']) aggregate = (output / 'Sendov/Common/DistillationFinite.lean').read_text() - self.assertEqual(aggregate.count(' · exact (distillFinite_'), 77) - self.assertTrue((output / 'Sendov/DistillationFinite/Row81.lean').is_file()) + self.assertEqual(aggregate.count(' · exact (distillFinite_'), 59) + self.assertTrue((output / 'Sendov/DistillationFinite/Rows61_64.lean').is_file()) + self.assertFalse((output / 'Sendov/DistillationFinite/Row64.lean').exists()) self.assertFalse((output / 'Sendov/DistillationFinite/Row5.lean').exists()) def test_complete_cli_regeneration_from_all_cwds(self): @@ -92,11 +98,16 @@ def test_sinh_explicit_and_default_outputs_from_all_cwds(self): def test_bad_data_is_rejected_before_any_publication(self): original = json.loads((self.repo / 'data/paper_certificate_table.json').read_text()) mutations = { - 'missing row': lambda r: r.pop(), + 'missing64': lambda r: r.pop(), + 'extra65': lambda r: r.append(dict(r[-1], m=65)), 'duplicate row': lambda r: r.__setitem__(1, r[0]), 'row order': lambda r: r.reverse(), 'missing component': lambda r: r[0]['components'].pop(), 'component order': lambda r: r[0]['components'].reverse(), + 'duplicate component': lambda r: r[0]['components'].__setitem__( + 1, r[0]['components'][0]), + 'mismatched components': lambda r: r[0].__setitem__( + 'components', r[1]['components']), 'boolean index': lambda r: r[0]['components'][0].__setitem__('index', False), 'boolean degree': lambda r: r[0].__setitem__('m', True), 'float degree': lambda r: r[0].__setitem__('m', 5.0), From 57fa60c295d870d1566d1753e3e1a91040fecb12 Mon Sep 17 00:00:00 2001 From: Methode Date: Sun, 13 Sep 2026 03:48:45 -0700 Subject: [PATCH 07/24] refactor(sendov): clarify local tail monotonicity proofs --- Sendov/LargeDegree/DistillationTail.lean | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/Sendov/LargeDegree/DistillationTail.lean b/Sendov/LargeDegree/DistillationTail.lean index aae6f1c..342c686 100644 --- a/Sendov/LargeDegree/DistillationTail.lean +++ b/Sendov/LargeDegree/DistillationTail.lean @@ -43,12 +43,10 @@ private lemma slope_linear (x c : ℝ) (h : x + c ≠ 0) : private lemma tail_antitone {f f' : ℝ → ℝ} {K : ℝ} (hf : ∀ x : ℝ, K ≤ x → HasDerivAt f (f' x) x) (hn : ∀ x : ℝ, K ≤ x → f' x ≤ 0) : AntitoneOn f (Set.Ici K) := by - apply antitoneOn_of_deriv_nonpos (convex_Ici _) (fun x hx => - (hf x hx).continuousAt.continuousWithinAt) - · exact fun x hx => (hf x (interior_subset hx)).differentiableAt.differentiableWithinAt - · intro x hx - rw [(hf x (interior_subset hx)).deriv] - exact hn x (interior_subset hx) + exact antitoneOn_of_hasDerivWithinAt_nonpos (convex_Ici _) + (fun x hx => (hf x hx).continuousAt.continuousWithinAt) + (fun x hx => (hf x (interior_subset hx)).hasDerivWithinAt) + (fun x hx => hn x (interior_subset hx)) lemma distillEBudget_antitone_on {K : ℝ} (hK : 0 < K) : AntitoneOn distillEBudget (Set.Ici K) := by @@ -64,11 +62,9 @@ lemma distillEBudget_antitone : AntitoneOn distillEBudget (Set.Ici 64) := lemma cubicPolarEnvelope_le_five_sixths {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : cubicPolarEnvelope α ≤ 5 / 6 := by - have h := cubicPolarEnvelope_mono hα hα17 - have h17 : cubicPolarEnvelope 17 = 199087 / 240000 := by - norm_num [cubicPolarEnvelope] - rw [h17] at h - linarith + calc + cubicPolarEnvelope α ≤ cubicPolarEnvelope 17 := cubicPolarEnvelope_mono hα hα17 + _ ≤ 5 / 6 := by norm_num [cubicPolarEnvelope] lemma distillNode_antitone_degree_on {K α : ℝ} (hK : 0 < K) (hα : 0 ≤ α) : AntitoneOn (fun m => distillNode m α) (Set.Ici K) := by @@ -90,7 +86,7 @@ lemma distillNode_lt_four_fifths {m α : ℝ} (hm : 64 ≤ m) apply (div_le_iff₀ (by linarith : 0 < 25 * m)).mpr linarith unfold distillNode - linarith + linarith only [he, ht] private lemma kappa_slope {m α : ℝ} (hm : 34 < m) (hα17 : α ≤ 17) : HasDerivAt (fun x => distillKappa x α) @@ -125,7 +121,7 @@ private lemma kappa_slope_le {K m α : ℝ} (hK : 34 < K) (hm : K ≤ m) div_le_div_of_nonneg_left (by norm_num) (by linarith) (by linarith) have h3 : 2 / (m - 2 * α) ≤ 2 / (K - 34) := div_le_div_of_nonneg_left (by norm_num) (by linarith) (by linarith) - linarith + linarith only [h1, h2, h3] /-- Explicit sufficient conditions on the start, rather than an assumed derivative sign. -/ lemma distillKappa_rpow_antitone_on {K α z : ℝ} (hK : 34 < K) From 55cb2385a90aa0059bb49d0bba1385ee147d686c Mon Sep 17 00:00:00 2001 From: Methode Date: Sun, 13 Sep 2026 04:27:28 -0700 Subject: [PATCH 08/24] refactor(sendov): simplify local proofs across the full module corpus --- Sendov/Analytic/Defect.lean | 16 +- Sendov/Analytic/Jsum.lean | 23 +- Sendov/Analytic/LowDegree.lean | 4 +- Sendov/Analytic/Origin.lean | 66 ++---- Sendov/Analytic/OriginExact.lean | 16 +- Sendov/Analytic/Polar.lean | 18 +- Sendov/Boundary.lean | 15 +- Sendov/Common/BernsteinCert.lean | 6 +- Sendov/Common/BernsteinList.lean | 3 +- Sendov/Common/Chord.lean | 43 +--- Sendov/Common/DistillationCritical.lean | 33 +-- Sendov/Common/DistillationCriticalFinite.lean | 2 +- Sendov/Common/DistillationEnvelope.lean | 8 +- Sendov/Common/DistillationFactors.lean | 9 +- Sendov/Common/DistillationFinite.lean | 60 ++--- Sendov/Common/DistillationHyperbolic.lean | 29 +-- Sendov/Common/DistillationKernel.lean | 6 +- Sendov/Common/TwoChord.lean | 2 +- Sendov/Conjecture.lean | 2 +- Sendov/Counterexample/Identities.lean | 5 +- Sendov/Interior.lean | 23 +- Sendov/Reduction/Alpha17.lean | 50 ++-- Sendov/Reduction/BetaBound.lean | 46 ++-- Sendov/Reduction/CubicPolar.lean | 26 +- Sendov/Reduction/CubicScalar.lean | 7 +- Sendov/Reduction/DistillationBridge.lean | 35 ++- Sendov/Reduction/Polar.lean | 16 +- Sendov/Reduction/Simplified.lean | 54 +++-- scripts/gen_distillation.py | 3 +- tests/Localanalytic.lean | 224 ++++++++++++++++++ tests/Localcommon.lean | 112 +++++++++ tests/Localgenerators.lean | 88 +++++++ tests/Localreduction.lean | 91 +++++++ tests/expected.json | 2 +- tests/test_generator_core.py | 4 +- 35 files changed, 780 insertions(+), 367 deletions(-) create mode 100644 tests/Localanalytic.lean create mode 100644 tests/Localcommon.lean create mode 100644 tests/Localgenerators.lean create mode 100644 tests/Localreduction.lean diff --git a/Sendov/Analytic/Defect.lean b/Sendov/Analytic/Defect.lean index d5edb34..c4a0c9b 100644 --- a/Sendov/Analytic/Defect.lean +++ b/Sendov/Analytic/Defect.lean @@ -64,18 +64,12 @@ lemma norm_mul_norm_inv_sub_conj_le {w : ℂ} (hw : ‖w‖ ≤ 1) : ‖w‖ * ‖w⁻¹ - (starRingEnd ℂ) w‖ ≤ 1 - ‖w‖ ^ 2 := by rcases eq_or_ne w 0 with rfl | hne · simp - · have hkey : w * (w⁻¹ - (starRingEnd ℂ) w) = 1 - ((‖w‖ : ℝ) : ℂ) ^ 2 := by - rw [mul_sub, mul_inv_cancel₀ hne, Complex.mul_conj] - norm_cast - rw [Complex.normSq_eq_norm_sq] - have h1 : ‖w‖ * ‖w⁻¹ - (starRingEnd ℂ) w‖ = ‖(1 : ℂ) - ((‖w‖ : ℝ) : ℂ) ^ 2‖ := by - rw [← norm_mul, hkey] - rw [h1] - have h2 : ((1 : ℂ) - ((‖w‖ : ℝ) : ℂ) ^ 2) = ((1 - ‖w‖ ^ 2 : ℝ) : ℂ) := by + · have hkey : w * (w⁻¹ - (starRingEnd ℂ) w) = ((1 - ‖w‖ ^ 2 : ℝ) : ℂ) := by + rw [mul_sub, mul_inv_cancel₀ hne, Complex.mul_conj, Complex.normSq_eq_norm_sq] push_cast - ring - rw [h2, Complex.norm_real, Real.norm_eq_abs, - abs_of_nonneg (by nlinarith [norm_nonneg w])] + rfl + rw [← norm_mul, hkey, Complex.norm_real, Real.norm_eq_abs, + abs_of_nonneg (sub_nonneg.2 (pow_le_one₀ (norm_nonneg w) hw))] /-! ### The lemma -/ diff --git a/Sendov/Analytic/Jsum.lean b/Sendov/Analytic/Jsum.lean index 35c09c7..14dd792 100644 --- a/Sendov/Analytic/Jsum.lean +++ b/Sendov/Analytic/Jsum.lean @@ -62,15 +62,12 @@ lemma norm_prod_le_one : ∀ (s : Multiset ℂ), (∀ w ∈ s, ‖w‖ ≤ 1) no `sⱼ` vanishes. -/ lemma prod_mul_sum_inv : ∀ (s : Multiset ℂ), (∀ w ∈ s, w ≠ 0) → s.prod * (s.map (fun w => w⁻¹)).sum = sumEraseProd s := by - intro s - induction s using Multiset.induction_on with - | empty => simp [sumEraseProd] - | cons v t ih => - intro hs - have hv := hs v (Multiset.mem_cons_self v t) - have ht : ∀ u ∈ t, u ≠ 0 := fun u hu => hs u (Multiset.mem_cons_of_mem hu) - rw [Multiset.prod_cons, Multiset.map_cons, Multiset.sum_cons, sumEraseProd_cons, ← ih ht] - field_simp + classical + intro s hs + rw [sumEraseProd, ← Multiset.sum_map_mul_left] + refine congrArg Multiset.sum (Multiset.map_congr rfl ?_) + intro w hw + rw [← Multiset.prod_erase hw, mul_right_comm, mul_inv_cancel₀ (hs w hw), one_mul] /-- The degenerate case. If `∏ sⱼ = 0` then some `sⱼ` vanishes, so at most one term of `∑ⱼ ∏_{k≠j} sₖ` is nonzero — and that term is a product of points of the closed unit disk. -/ @@ -86,12 +83,10 @@ lemma sumEraseProd_norm_le_one : ∀ (s : Multiset ℂ), (∀ w ∈ s, ‖w‖ rw [sumEraseProd_cons] rcases eq_or_ne t.prod 0 with ht0 | ht0 · rw [ht0, zero_add, norm_mul] - nlinarith [ih ht ht0, norm_nonneg v, norm_nonneg (sumEraseProd t), hv] + exact mul_le_one₀ hv (norm_nonneg _) (ih ht ht0) · have hv0 : v = 0 := by rw [Multiset.prod_cons] at hp - rcases mul_eq_zero.1 hp with h | h - · exact h - · exact absurd h ht0 + exact (mul_eq_zero.1 hp).resolve_right ht0 rw [hv0, zero_mul, add_zero] exact norm_prod_le_one t ht @@ -117,7 +112,7 @@ theorem Jsum_estimate {n : ℕ} (hn : 2 ≤ n) {a x y : ℝ} {z q : Multiset ℂ · -- degenerate: `J = 0`, and `sumEraseProd z` has at most one surviving term rw [hz0, mul_zero, mul_zero, sub_zero, norm_zero, mul_zero, norm_mul] have h2 : ‖sumEraseProd z‖ ≤ 1 := sumEraseProd_norm_le_one z hz1 hz0 - nlinarith [norm_nonneg q.prod, norm_nonneg (sumEraseProd z)] + simpa using (mul_le_one₀ hqpnorm (norm_nonneg _) h2).trans hratio · -- the main case: every `zⱼ` is nonzero, so denominators may be cleared have hzne : ∀ w ∈ z, w ≠ 0 := by intro w hw hw0 diff --git a/Sendov/Analytic/LowDegree.lean b/Sendov/Analytic/LowDegree.lean index f01d8a9..6d566d5 100644 --- a/Sendov/Analytic/LowDegree.lean +++ b/Sendov/Analytic/LowDegree.lean @@ -65,8 +65,8 @@ lemma norm_le_lowX {a t : ℝ} (ha0 : 0 ≤ a) (ha1 : a ≤ 1) (ht0 : 0 ≤ t) { refine (norm_add_le _ _).trans ?_ rw [norm_mul, Complex.norm_real, Complex.norm_real, Real.norm_eq_abs, Real.norm_eq_abs, abs_of_nonneg ha0, abs_of_nonneg (mul_nonneg ht0 hb)] - simp only [lowX] - nlinarith [hv, norm_nonneg v, mul_nonneg ht0 hb] + simpa only [lowX, mul_comm t] using + add_le_add_right (mul_le_of_le_one_right (mul_nonneg ht0 hb) hv) a lemma prod_norm_le_lowX_pow {a t : ℝ} (ha0 : 0 ≤ a) (ha1 : a ≤ 1) (ht0 : 0 ≤ t) : ∀ (q : Multiset ℂ), (∀ v ∈ q, ‖v‖ ≤ 1) → diff --git a/Sendov/Analytic/Origin.lean b/Sendov/Analytic/Origin.lean index beb75a0..f06d372 100644 --- a/Sendov/Analytic/Origin.lean +++ b/Sendov/Analytic/Origin.lean @@ -122,26 +122,13 @@ theorem sum_norm_sq_one_sub_le {n : ℕ} {a x t : ℝ} {q : Multiset ℂ} lemma sq_sum_le_card_mul_sum_sq (s : Multiset ℝ) (hs : ∀ b ∈ s, 0 ≤ b) : (s.sum) ^ 2 ≤ (s.card : ℝ) * (s.map (fun b => b ^ 2)).sum := by - induction s using Multiset.induction_on with - | empty => simp - | cons b t ih => - have hb := hs b (Multiset.mem_cons_self b t) - have ht : ∀ u ∈ t, 0 ≤ u := fun u hu => hs u (Multiset.mem_cons_of_mem hu) - rcases eq_or_ne t 0 with rfl | ht0 - · simp - · have hIH := ih ht - have hcard : (0 : ℝ) < (t.card : ℕ) := by - have := Multiset.card_pos.2 ht0 - exact_mod_cast this - have hsum : 0 ≤ t.sum := Multiset.sum_nonneg ht - have hQ : (0 : ℝ) ≤ (t.map (fun b => b ^ 2)).sum := - Multiset.sum_nonneg (by - intro y hy - obtain ⟨u, _, rfl⟩ := Multiset.mem_map.1 hy - exact sq_nonneg u) - simp only [Multiset.sum_cons, Multiset.card_cons, Multiset.map_cons] - push_cast - nlinarith [hIH, sq_nonneg (t.sum - (t.card : ℝ) * b), hcard, hsum, hb, hQ] + -- Apply Cauchy–Schwarz with f = 1 and g = l.get on list positions, preserving repeats. + -- The original nonnegativity hypothesis hs is retained for interface compatibility. + induction s using Quotient.inductionOn with + | h l => + have h := Finset.sum_mul_sq_le_sq_mul_sq Finset.univ + (fun _ : Fin l.length => (1 : ℝ)) l.get + simpa [← List.sum_ofFn, List.ofFn_getElem_eq_map l (fun b : ℝ => b ^ 2)] using h /-- **The error bound.** `∑ⱼ ∏_{k≠j} ‖1 - a t q_k‖ ≤ (n-1) β(t)^{(n-2)/2}`: Maclaurin's inequality, then Cauchy–Schwarz, then the quadratic mean. Nonnegativity of `β(t)` is not @@ -250,18 +237,16 @@ lemma sumEraseProdC_cons (v : ℂ) (t : Multiset ℂ) (g f : ℂ → ℂ) : /-- A weighted erasure sum with unit-size weights is dominated by the unweighted one. -/ lemma norm_sumEraseProdC_le (g f : ℂ → ℂ) : ∀ (s : Multiset ℂ), (∀ v ∈ s, ‖g v‖ ≤ 1) → ‖sumEraseProdC s g f‖ ≤ sumEraseProdMap s (fun v => ‖f v‖) := by - intro s - induction s using Multiset.induction_on with - | empty => intro _; simp [sumEraseProdMap] - | cons v t ih => - intro hg - have hv := hg v (Multiset.mem_cons_self v t) - have ht : ∀ u ∈ t, ‖g u‖ ≤ 1 := fun u hu => hg u (Multiset.mem_cons_of_mem hu) - rw [sumEraseProdC_cons, sumEraseProdMap_cons] - refine (norm_add_le _ _).trans ?_ - rw [norm_mul, norm_mul, norm_prod_map] - have h2 : (0 : ℝ) ≤ (t.map (fun v => ‖f v‖)).prod := prod_map_norm_nonneg t f - nlinarith [ih ht, norm_nonneg (f v), norm_nonneg (sumEraseProdC t g f), h2, hv] + classical + intro s hg + unfold sumEraseProdC sumEraseProdMap + refine (norm_multiset_sum_le _).trans ?_ + rw [Multiset.map_map] + refine Multiset.sum_map_le_sum_map _ _ ?_ + intro v hv + dsimp only [Function.comp_def] + rw [norm_mul, norm_prod_map] + exact mul_le_of_le_one_left (prod_map_norm_nonneg _ _) (hg v hv) /-- `F(t) = ∏ⱼ (1 - a t qⱼ)`. -/ noncomputable def Fprod (a : ℝ) (q : Multiset ℂ) (t : ℝ) : ℂ := @@ -294,27 +279,20 @@ lemma hasDerivAt_Fprod (a t : ℝ) : ∀ (q : Multiset ℂ), induction q using Multiset.induction_on with | empty => have he : Fprod a 0 = fun _ : ℝ => (1 : ℂ) := by funext s; simp [Fprod] - have hz : -(a : ℂ) * sumEraseProdC 0 id (fun v => 1 - (a : ℂ) * (t : ℂ) * v) = 0 := by simp - rw [he, hz] + rw [he, sumEraseProdC_zero, mul_zero] exact hasDerivAt_const t 1 | cons v r ih => have h0 : HasDerivAt (fun s : ℝ => (s : ℂ)) 1 t := Complex.ofRealCLM.hasDerivAt have h1 : HasDerivAt (fun s : ℝ => 1 - (a : ℂ) * (s : ℂ) * v) (-((a : ℂ) * v)) t := by simpa using ((h0.const_mul (a : ℂ)).mul_const v).const_sub 1 - have h2 := h1.mul ih have hfun : Fprod a (v ::ₘ r) = fun s : ℝ => (1 - (a : ℂ) * (s : ℂ) * v) * Fprod a r s := by funext s simp only [Fprod, Multiset.map_cons, Multiset.prod_cons] - have hderiv : -(a : ℂ) * ((v : ℂ) * (r.map (fun w => 1 - (a : ℂ) * (t : ℂ) * w)).prod - + (1 - (a : ℂ) * (t : ℂ) * v) * sumEraseProdC r id (fun w => 1 - (a : ℂ) * (t : ℂ) * w)) - = -((a : ℂ) * v) * Fprod a r t - + (1 - (a : ℂ) * (t : ℂ) * v) - * (-(a : ℂ) * sumEraseProdC r id (fun w => 1 - (a : ℂ) * (t : ℂ) * w)) := by - simp only [Fprod] - ring - rw [hfun, sumEraseProdC_cons, id_eq, hderiv] - exact h2 + rw [hfun, sumEraseProdC_cons, id_eq] + apply (h1.mul ih).congr_deriv + simp only [Fprod] + ring /-- **The pointwise estimate.** `‖F'(t) + (n-1) a (x+iy) F(t)‖ ≤ a² t (n-1) β(t)^{(n-2)/2}`. -/ theorem norm_deriv_add_le {n : ℕ} (hn : 2 ≤ n) {a x y t : ℝ} {q : Multiset ℂ} diff --git a/Sendov/Analytic/OriginExact.lean b/Sendov/Analytic/OriginExact.lean index a9550a5..c152646 100644 --- a/Sendov/Analytic/OriginExact.lean +++ b/Sendov/Analytic/OriginExact.lean @@ -126,7 +126,7 @@ lemma norm_Worigin_le {n : ℕ} {a x y : ℝ} (ha0 : 0 < a) (ha1 : a < 1) ≤ (1 - x ^ 2) / (2 * ((n : ℝ) - 1)) := by rw [div_le_div_iff₀ hs hden] nlinarith [hy2, hslow, ha2, sq_nonneg y, hn1] - linarith [hmain, htail] + exact hmain.trans (add_le_add_right htail _) /-- `x` and `y` are determined by `q.sum`, and inherit two bounds from `‖qⱼ‖ ≤ 1`: the real part is what the polar and origin estimates need, and `x² + y² ≤ 1` is what eliminates `y`. -/ @@ -151,17 +151,13 @@ lemma xy_bounds {n : ℕ} (hn : 2 ≤ n) {x y : ℝ} {q : Multiset ℂ} simp · have hxynorm : ‖(x : ℂ) + (y : ℂ) * I‖ ^ 2 = x ^ 2 + y ^ 2 := by rw [← Complex.normSq_eq_norm_sq, Complex.normSq_add_mul_I] - have h2 : ‖q.sum‖ ≤ (q.map (fun v => ‖v‖)).sum := by - have h := norm_sum_map_le q (fun v => v) - simpa using h + have h2 : ‖q.sum‖ ≤ (q.map (fun v => ‖v‖)).sum := norm_multiset_sum_le q have h3 := sum_norm_le_card q hq1 rw [hqcardR] at h3 have h1 : ‖q.sum‖ ≤ (n : ℝ) - 1 := h2.trans h3 rw [hxy, norm_mul, hnc] at h1 - have h4 : ‖(x : ℂ) + (y : ℂ) * I‖ ≤ 1 := by - by_contra hcon - rw [not_le] at hcon - nlinarith [h1, hn1] + have h4 : ‖(x : ℂ) + (y : ℂ) * I‖ ≤ 1 := + (mul_le_mul_iff_right₀ hn1).mp (by simpa only [mul_one] using h1) nlinarith [hxynorm, h4, norm_nonneg ((x : ℂ) + (y : ℂ) * I)] /-! ### The origin inequality -/ @@ -210,9 +206,7 @@ theorem origin_exact {n : ℕ} (hn : 5 ≤ n) {a x y α : ℝ} {z q : Multiset rw [Complex.norm_real, Real.norm_eq_abs, abs_of_nonneg (le_of_lt ha0)] have hPJ0 : (0 : ℝ) ≤ ‖q.prod‖ * ‖z.prod‖ := by positivity have hPJ1 : ‖q.prod‖ * ‖z.prod‖ ≤ 1 := by - have h1 : ‖q.prod‖ ≤ 1 := norm_prod_le_one q hq1 - have h2 : ‖z.prod‖ ≤ 1 := norm_prod_le_one z hz1 - nlinarith [norm_nonneg q.prod, norm_nonneg z.prod] + exact mul_le_one₀ (norm_prod_le_one q hq1) (norm_nonneg _) (norm_prod_le_one z hz1) have hstep1 : (n : ℝ) * ‖Fprod a q 1 + ((n : ℂ) - 1) * (a : ℂ) * ((x : ℂ) + (y : ℂ) * I) * ∫ t in (0 : ℝ)..1, Fprod a q t‖ ≤ ‖q.prod‖ * ‖z.prod‖ * ‖Worigin n a x y‖ diff --git a/Sendov/Analytic/Polar.lean b/Sendov/Analytic/Polar.lean index f2b8289..932fec5 100644 --- a/Sendov/Analytic/Polar.lean +++ b/Sendov/Analytic/Polar.lean @@ -59,16 +59,10 @@ lemma norm_sub_le_norm_one_sub_mul {a : ℝ} (ha : |a| ≤ 1) {z : ℂ} (hz : nlinarith [this.1, this.2] have hz2 : Complex.normSq z ≤ 1 := by rw [Complex.normSq_eq_norm_sq] - nlinarith [norm_nonneg z] - have hdiff : 0 ≤ Complex.normSq (1 - (a : ℂ) * z) - Complex.normSq ((a : ℂ) - z) := by - rw [hkey] - have h1 : (0 : ℝ) ≤ 1 - a ^ 2 := by linarith - have h2 : (0 : ℝ) ≤ 1 - Complex.normSq z := by linarith - positivity - have hsq : ‖(a : ℂ) - z‖ ^ 2 ≤ ‖1 - (a : ℂ) * z‖ ^ 2 := by - rw [← Complex.normSq_eq_norm_sq, ← Complex.normSq_eq_norm_sq] - linarith - nlinarith [norm_nonneg ((a : ℂ) - z), norm_nonneg (1 - (a : ℂ) * z), hsq] + exact pow_le_one₀ (norm_nonneg z) hz + apply (sq_le_sq₀ (norm_nonneg _) (norm_nonneg _)).1 + rw [Complex.sq_norm, Complex.sq_norm, ← sub_nonneg, hkey] + exact mul_nonneg (sub_nonneg.2 ha2) (sub_nonneg.2 hz2) /-! ### Products of norms over a multiset -/ @@ -127,7 +121,7 @@ theorem one_le_integral_prod_norm {n : ℕ} (hn : 2 ≤ n) {a : ℝ} (ha : |a| (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod‖ := by rw [← h2, h1] exact mul_le_mul_of_nonneg_left hmob (norm_nonneg _) - nlinarith [hstep, hnpos] + exact (mul_le_mul_iff_right₀ hnpos).mp (by simpa only [mul_one] using hstep) -- and the triangle inequality moves the norm inside refine h3.trans ?_ refine (intervalIntegral.norm_integral_le_integral_norm (by norm_num)).trans_eq ?_ @@ -237,7 +231,7 @@ lemma prod_norm_le_Ppolar {n : ℕ} (hn : 2 ≤ n) {a x t : ℝ} refine hamgm.trans ?_ exact pow_le_pow_left₀ hM0' hMle _ rw [← hsq] at hchain - nlinarith [hchain, hP0, Real.rpow_nonneg (le_trans hM0' hMle) (((n : ℝ) - 1) / 2)] + exact (sq_le_sq₀ hP0 (Real.rpow_nonneg hb _)).1 hchain /-- **The raw polar inequality `(1Q)`.** -/ theorem one_le_integral_Ppolar {n : ℕ} (hn : 2 ≤ n) {a x : ℝ} diff --git a/Sendov/Boundary.lean b/Sendov/Boundary.lean index 9c2d3eb..b7dbee4 100644 --- a/Sendov/Boundary.lean +++ b/Sendov/Boundary.lean @@ -79,20 +79,19 @@ lemma half_le_re_inv_one_sub {z : ℂ} (hz : ‖z‖ ≤ 1) (hz1 : z ≠ 1) : have hne : (1 : ℂ) - z ≠ 0 := sub_ne_zero.2 (Ne.symm hz1) have hd : 0 < Complex.normSq ((1 : ℂ) - z) := Complex.normSq_pos.2 hne have hsq : z.re ^ 2 + z.im ^ 2 ≤ 1 := by - have h := Complex.normSq_eq_norm_sq z - rw [Complex.normSq_apply] at h - nlinarith [hz, norm_nonneg z, h] + have h := pow_le_one₀ (norm_nonneg z) hz (n := 2) + rw [Complex.sq_norm, Complex.normSq_apply] at h + nlinarith only [h] rw [Complex.inv_re, le_div_iff₀ hd, Complex.normSq_apply] simp only [Complex.sub_re, Complex.sub_im, Complex.one_re, Complex.one_im] nlinarith [hsq] /-- A point of the closed unit disk with real part `1` is `1`. -/ lemma eq_one_of_re_eq_one_of_norm_le_one {v : ℂ} (hre : v.re = 1) (hv : ‖v‖ ≤ 1) : v = 1 := by - have hsq : v.re ^ 2 + v.im ^ 2 ≤ 1 := by - have h := Complex.normSq_eq_norm_sq v - rw [Complex.normSq_apply] at h - nlinarith [hv, norm_nonneg v, h] - have him : v.im = 0 := by nlinarith [hsq, hre, sq_nonneg v.im] + have him : v.im = 0 := by + have hsq := pow_le_one₀ (norm_nonneg v) hv (n := 2) + rw [Complex.sq_norm, Complex.normSq_apply] at hsq + nlinarith only [hsq, hre, sq_nonneg v.im] apply Complex.ext <;> simp [hre, him] /-- A multiset of nonnegative reals summing to zero is all zeroes. -/ diff --git a/Sendov/Common/BernsteinCert.lean b/Sendov/Common/BernsteinCert.lean index 4d170f9..5ffe4b3 100644 --- a/Sendov/Common/BernsteinCert.lean +++ b/Sendov/Common/BernsteinCert.lean @@ -59,9 +59,9 @@ theorem Cert.pos_right (a : Cert) {x y : ℝ} (hx : 0 < x) (hy : 0 ≤ y) theorem Cert.pos (a : Cert) {x y : ℝ} (hx : 0 ≤ x) (hy : 0 ≤ y) (hxy : 0 < x + y) (hl : a.edge true = true) (hr : a.edge false = true) : 0 < a.eval x y := by - rcases lt_or_eq_of_le hx with h | h - · exact a.pos_right h hy hr - · exact a.pos_left hx (by linarith) hl + rcases eq_or_lt_of_le hx with rfl | hx + · exact a.pos_left le_rfl (by simpa only [zero_add] using hxy) hl + · exact a.pos_right hx hy hr theorem scaled_pos (a : Cert) {x y s P : ℝ} (hid : s * P = a.eval x y) (hs : 0 < s) (hx : 0 ≤ x) (hy : 0 ≤ y) diff --git a/Sendov/Common/BernsteinList.lean b/Sendov/Common/BernsteinList.lean index 8356f64..d489664 100644 --- a/Sendov/Common/BernsteinList.lean +++ b/Sendov/Common/BernsteinList.lean @@ -26,6 +26,7 @@ theorem coeffs_pos (cs : List ℕ) {lo hi s P x : ℝ} (hr : (coeffTree cs 0).edge false = true) (hid : s * P = (coeffTree cs 0).eval (x - lo) (hi - x)) : 0 < P := by exact scaled_pos (coeffTree cs 0) hid hs (sub_nonneg.mpr hx.1) - (sub_nonneg.mpr hx.2) (by linarith) hl hr + (sub_nonneg.mpr hx.2) + (by simpa only [sub_add_sub_cancel'] using sub_pos.mpr hab) hl hr end BernsteinCert diff --git a/Sendov/Common/Chord.lean b/Sendov/Common/Chord.lean index 0585e6e..26ce2a5 100644 --- a/Sendov/Common/Chord.lean +++ b/Sendov/Common/Chord.lean @@ -93,19 +93,10 @@ lemma integral_chord_lin {s c : ℝ} (hs : 0 < s) (hc : 0 < c) : have hc' : c ≠ 0 := hc.ne' have h := intervalIntegral.integral_comp_mul_left (a := (0 : ℝ)) (b := 1 / c) (fun y : ℝ => (y / c) * (1 - y) ^ s) hc' - have hfun : (fun t : ℝ => ((c * t) / c) * (1 - c * t) ^ s) - = fun t : ℝ => t * (1 - c * t) ^ s := by - funext t - rw [mul_div_cancel_left₀ t hc'] - simp only [hfun] at h - rw [show c * (1 / c) = 1 by field_simp, mul_zero] at h - have hg : (fun y : ℝ => (y / c) * (1 - y) ^ s) - = fun y : ℝ => (1 / c) * (y * (1 - y) ^ s) := by - funext y - field_simp - rw [hg, intervalIntegral.integral_const_mul, integral_lin_mul_rpow hs] at h + simp only [mul_div_cancel_left₀ _ hc', mul_one_div_cancel hc', mul_zero, + div_mul_eq_mul_div, intervalIntegral.integral_div, integral_lin_mul_rpow hs, + smul_eq_mul] at h rw [h] - simp only [smul_eq_mul] field_simp /-- The chord integral with weight `t³`, over `[0, 1/c]`. -/ @@ -115,19 +106,10 @@ lemma integral_chord_pow {s c : ℝ} (hs : 0 < s) (hc : 0 < c) : have hc' : c ≠ 0 := hc.ne' have h := intervalIntegral.integral_comp_mul_left (a := (0 : ℝ)) (b := 1 / c) (fun y : ℝ => (y / c) ^ 3 * (1 - y) ^ s) hc' - have hfun : (fun t : ℝ => ((c * t) / c) ^ 3 * (1 - c * t) ^ s) - = fun t : ℝ => t ^ 3 * (1 - c * t) ^ s := by - funext t - rw [mul_div_cancel_left₀ t hc'] - simp only [hfun] at h - rw [show c * (1 / c) = 1 by field_simp, mul_zero] at h - have hg : (fun y : ℝ => (y / c) ^ 3 * (1 - y) ^ s) - = fun y : ℝ => (1 / c ^ 3) * (y ^ 3 * (1 - y) ^ s) := by - funext y - field_simp - rw [hg, intervalIntegral.integral_const_mul, integral_cube_mul_rpow hs] at h + simp only [mul_div_cancel_left₀ _ hc', mul_one_div_cancel hc', mul_zero, + div_pow, div_mul_eq_mul_div, intervalIntegral.integral_div, integral_cube_mul_rpow hs, + smul_eq_mul] at h rw [h] - simp only [smul_eq_mul] field_simp /-! ### The split -/ @@ -160,9 +142,9 @@ theorem integral_le_tail_gen {c A : ℝ} (hfeas : c ^ 2 ≤ A) (hc : 0 < c) (hc1 have hsc : s ≤ 1 / c := by rcases min_cases t₀ 1 with ⟨h, _⟩ | ⟨h, _⟩ · rw [hsdef, h, ht₀def, le_div_iff₀ hc, div_mul_eq_mul_div, div_le_one hA] - nlinarith [hfeas] + simpa only [pow_two] using hfeas · rw [hsdef, h, le_div_iff₀ hc] - linarith + simpa only [one_mul] using hc1 rw [← intervalIntegral.integral_add_adjacent_intervals (hint 0 s) (hint s 1)] have hfirst : (∫ u in (0 : ℝ)..s, u ^ k * QQ c A u ^ r) ≤ ∫ u in (0 : ℝ)..1 / c, u ^ k * (1 - c * u) ^ r := by @@ -192,7 +174,7 @@ theorem integral_le_tail_gen {c A : ℝ} (hfeas : c ^ 2 ≤ A) (hc : 0 < c) (hc1 = ∫ u in (0 : ℝ)..1 / c, u ^ k * (1 - c * u) ^ r := intervalIntegral.integral_add_adjacent_intervals (hchordcont.intervalIntegrable 0 s) (hchordcont.intervalIntegrable s (1 / c)) - linarith + exact (le_add_of_nonneg_right hrest).trans_eq hadd have hsecond : (∫ u in s..1, u ^ k * QQ c A u ^ r) ≤ QQ c A 1 ^ r / (k + 1) := by have hBnn : (0 : ℝ) ≤ QQ c A 1 ^ r := Real.rpow_nonneg (QQ_nonneg hfeas 1) _ have hQB : ∀ u ∈ Set.Icc s 1, QQ c A u ≤ QQ c A 1 := by @@ -210,15 +192,16 @@ theorem integral_le_tail_gen {c A : ℝ} (hfeas : c ^ 2 ≤ A) (hc : 0 < c) (hc1 refine intervalIntegral.integral_mono_on hs1 (hint s 1) ((by fun_prop : Continuous fun u : ℝ => QQ c A 1 ^ r * u ^ k).intervalIntegrable _ _) ?_ intro u hu - have := Real.rpow_le_rpow (QQ_nonneg hfeas u) (hQB u hu) hr.le - nlinarith [pow_nonneg (le_trans hs0.le hu.1) k, this, hBnn] + simpa only [mul_comm] using mul_le_mul_of_nonneg_left + (Real.rpow_le_rpow (QQ_nonneg hfeas u) (hQB u hu) hr.le) + (pow_nonneg (le_trans hs0.le hu.1) k) refine hle.trans ?_ rw [intervalIntegral.integral_const_mul, integral_pow] have hsk : (0 : ℝ) ≤ s ^ (k + 1) := pow_nonneg hs0.le _ rw [one_pow, ← mul_div_assoc] gcongr nlinarith [mul_nonneg hBnn hsk] - linarith + exact add_le_add hfirst hsecond /-- The instance with weight `t`, used for `α ≤ 17`. -/ theorem integral_le_tail_lin {c A : ℝ} (hfeas : c ^ 2 ≤ A) (hc : 0 < c) (hc1 : c ≤ 1) diff --git a/Sendov/Common/DistillationCritical.lean b/Sendov/Common/DistillationCritical.lean index 63f1dbf..a0b56da 100644 --- a/Sendov/Common/DistillationCritical.lean +++ b/Sendov/Common/DistillationCritical.lean @@ -425,15 +425,8 @@ lemma distillT0_deriv_nonpos_iff {m α : ℝ} (hm : 5 ≤ m) rw [(hasDerivAt_distillT0 hm hα hαm).deriv] have ht := distillT0_pos hm hα.le hαm have hd := distillT0_denom_pos hm hα hαm - constructor - · intro h - have hnum := (div_le_iff₀ hd).mp (nonpos_of_mul_nonpos_right h ht) - simp only [zero_mul] at hnum - exact hnum - · intro hp - apply mul_nonpos_of_nonneg_of_nonpos ht.le - apply div_nonpos_of_nonpos_of_nonneg _ hd.le - exact hp + nth_rw 1 [← mul_zero (distillT0 m α)] + rw [mul_le_mul_iff_right₀ ht, div_le_iff₀ hd, zero_mul] lemma distillT0_deriv_nonpos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) (hp : distillCritical0 m α ≤ 0) : @@ -460,15 +453,8 @@ lemma distillT1_deriv_nonpos_iff {m α : ℝ} (hm : 5 ≤ m) rw [(hasDerivAt_distillT1 hm hα hαm).deriv] have ht := distillT1_pos hm hα.le hαm have hd := distillT1_denom_pos hm hα hαm - constructor - · intro h - have hnum := (div_le_iff₀ hd).mp (nonpos_of_mul_nonpos_right h ht) - simp only [zero_mul] at hnum - exact neg_nonpos.mp hnum - · intro hp - apply mul_nonpos_of_nonneg_of_nonpos ht.le - apply div_nonpos_of_nonpos_of_nonneg _ hd.le - exact neg_nonpos.mpr hp + nth_rw 1 [← mul_zero (distillT1 m α)] + rw [mul_le_mul_iff_right₀ ht, div_le_iff₀ hd, zero_mul, neg_nonpos] lemma distillT1_deriv_nonpos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) (hp : 0 ≤ distillCritical1 m α) : @@ -495,15 +481,8 @@ lemma distillT2_deriv_nonpos_iff {m α : ℝ} (hm : 5 ≤ m) rw [(hasDerivAt_distillT2 hm hα hαm).deriv] have ht := distillT2_pos hm hα hαm have hd := distillT2_denom_pos hm hα hαm - constructor - · intro h - have hnum := (div_le_iff₀ hd).mp (nonpos_of_mul_nonpos_right h ht) - simp only [zero_mul] at hnum - exact neg_nonpos.mp hnum - · intro hp - apply mul_nonpos_of_nonneg_of_nonpos ht.le - apply div_nonpos_of_nonpos_of_nonneg _ hd.le - exact neg_nonpos.mpr hp + nth_rw 1 [← mul_zero (distillT2 m α)] + rw [mul_le_mul_iff_right₀ ht, div_le_iff₀ hd, zero_mul, neg_nonpos] lemma distillT2_deriv_nonpos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) (hp : 0 ≤ distillCritical2 m α) : diff --git a/Sendov/Common/DistillationCriticalFinite.lean b/Sendov/Common/DistillationCriticalFinite.lean index e5d0700..a7df625 100644 --- a/Sendov/Common/DistillationCriticalFinite.lean +++ b/Sendov/Common/DistillationCriticalFinite.lean @@ -57,7 +57,7 @@ lemma distillMulRpow_le_of_sq {a b c m : ℝ} (n : ℕ) (hsq : a ^ 2 * b ^ n ≤ c ^ 2) : a * b ^ ((m - 3) / 2) ≤ c := by have hid : (a * b ^ ((m - 3) / 2)) ^ 2 = a ^ 2 * b ^ n := by rw [mul_pow, hn, distillRpow_half_sq hb] - nlinarith [sq_nonneg (a * b ^ ((m - 3) / 2) - c)] + exact le_of_sq_le_sq (by rwa [hid]) hc /-- Component 0: exact flanks from the critical derivative API and one mixed bracket. -/ lemma distillT0_le_of_critical {m d l r b α : ℝ} diff --git a/Sendov/Common/DistillationEnvelope.lean b/Sendov/Common/DistillationEnvelope.lean index 51bff22..e4b0ed3 100644 --- a/Sendov/Common/DistillationEnvelope.lean +++ b/Sendov/Common/DistillationEnvelope.lean @@ -24,16 +24,16 @@ lemma cubicPolarEnvelope_nonneg {α : ℝ} (hα : 0 ≤ α) : have hd : 0 < α + 3 := by linarith have hu : 0 ≤ α / (α + 3) := div_nonneg hα hd.le have hu1 : α / (α + 3) ≤ 1 := (div_le_one hd).mpr (by linarith) - have hu3 := pow_le_pow_left₀ hu hu1 3 + have hu3 : (α / (α + 3)) ^ 3 ≤ α / (α + 3) := + pow_le_of_le_one hu hu1 (by decide) unfold cubicPolarEnvelope - nlinarith [pow_nonneg hu 3, mul_nonneg hu (sub_nonneg.mpr hu1), - mul_nonneg (sq_nonneg (α / (α + 3))) (sub_nonneg.mpr hu1)] + exact sub_nonneg.mpr ((div_le_self (pow_nonneg hu 3) (by norm_num)).trans hu3) lemma cubicPolarEnvelope_le_linear {α : ℝ} (hα : 0 ≤ α) : cubicPolarEnvelope α ≤ α / (α + 3) := by have hu : 0 ≤ α / (α + 3) := div_nonneg hα (by linarith) unfold cubicPolarEnvelope - linarith [pow_nonneg hu 3] + exact sub_le_self _ (div_nonneg (pow_nonneg hu 3) (by norm_num)) lemma cubicPolarEnvelope_lt_one {α : ℝ} (hα : 0 ≤ α) : cubicPolarEnvelope α < 1 := by diff --git a/Sendov/Common/DistillationFactors.lean b/Sendov/Common/DistillationFactors.lean index b01e890..c8b593f 100644 --- a/Sendov/Common/DistillationFactors.lean +++ b/Sendov/Common/DistillationFactors.lean @@ -131,13 +131,12 @@ lemma distillElementary_le_budget {m α : ℝ} (hm : 0 < m) (hα : 0 < α) : apply (div_le_iff₀ (by positivity : 0 < 4 * α)).mpr linarith have hlast : cubicPolarEnvelope α / (4 * α * m) ≤ 1 / (12 * m) := by - rw [div_le_div_iff₀ (by positivity : 0 < 4 * α * m) (by positivity : 0 < 12 * m)] - nlinarith [mul_le_mul_of_nonneg_right her hm.le] + simpa only [div_div] using div_le_div_of_nonneg_right hsecond hm.le have hid : (1 : ℝ) / 6 + 1 / 12 + 1 / (2 * m) + 1 / (12 * m) = distillEBudget m := by unfold distillEBudget ring - linarith + exact (add_le_add (add_le_add (add_le_add hfirst hsecond) le_rfl) hlast).trans_eq hid /-- The prefactor is regularized only after cancelling a positive alpha. -/ lemma distillKappa_eq {m α : ℝ} (hα : 0 < α) : @@ -215,6 +214,8 @@ lemma distillScalar_le_components {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) unfold scalarObstruction rw [← distillKappa_eq hα] unfold distillT0 distillT1 distillT2 - nlinarith + calc + _ ≤ distillEBudget m + distillKappa m α * _ := add_le_add hE hK + _ = _ := by ring end Sendov diff --git a/Sendov/Common/DistillationFinite.lean b/Sendov/Common/DistillationFinite.lean index 9a9ecd2..f0a5c20 100644 --- a/Sendov/Common/DistillationFinite.lean +++ b/Sendov/Common/DistillationFinite.lean @@ -44,36 +44,36 @@ theorem distillFinite_components {m : ℕ} (hm : 5 ≤ m) (hm63 : m ≤ 63) · exact (distillFinite_31 α hα (by linarith)).trans_lt distillFiniteBound_31 · exact (distillFinite_32 α hα (by linarith)).trans_lt distillFiniteBound_32 · exact (distillFinite_33 α hα (by linarith)).trans_lt distillFiniteBound_33 - · exact (distillFinite_34 α hα (by linarith)).trans_lt distillFiniteBound_34 - · exact (distillFinite_35 α hα (by linarith)).trans_lt distillFiniteBound_35 - · exact (distillFinite_36 α hα (by linarith)).trans_lt distillFiniteBound_36 - · exact (distillFinite_37 α hα (by linarith)).trans_lt distillFiniteBound_37 - · exact (distillFinite_38 α hα (by linarith)).trans_lt distillFiniteBound_38 - · exact (distillFinite_39 α hα (by linarith)).trans_lt distillFiniteBound_39 - · exact (distillFinite_40 α hα (by linarith)).trans_lt distillFiniteBound_40 - · exact (distillFinite_41 α hα (by linarith)).trans_lt distillFiniteBound_41 - · exact (distillFinite_42 α hα (by linarith)).trans_lt distillFiniteBound_42 - · exact (distillFinite_43 α hα (by linarith)).trans_lt distillFiniteBound_43 - · exact (distillFinite_44 α hα (by linarith)).trans_lt distillFiniteBound_44 - · exact (distillFinite_45 α hα (by linarith)).trans_lt distillFiniteBound_45 - · exact (distillFinite_46 α hα (by linarith)).trans_lt distillFiniteBound_46 - · exact (distillFinite_47 α hα (by linarith)).trans_lt distillFiniteBound_47 - · exact (distillFinite_48 α hα (by linarith)).trans_lt distillFiniteBound_48 - · exact (distillFinite_49 α hα (by linarith)).trans_lt distillFiniteBound_49 - · exact (distillFinite_50 α hα (by linarith)).trans_lt distillFiniteBound_50 - · exact (distillFinite_51 α hα (by linarith)).trans_lt distillFiniteBound_51 - · exact (distillFinite_52 α hα (by linarith)).trans_lt distillFiniteBound_52 - · exact (distillFinite_53 α hα (by linarith)).trans_lt distillFiniteBound_53 - · exact (distillFinite_54 α hα (by linarith)).trans_lt distillFiniteBound_54 - · exact (distillFinite_55 α hα (by linarith)).trans_lt distillFiniteBound_55 - · exact (distillFinite_56 α hα (by linarith)).trans_lt distillFiniteBound_56 - · exact (distillFinite_57 α hα (by linarith)).trans_lt distillFiniteBound_57 - · exact (distillFinite_58 α hα (by linarith)).trans_lt distillFiniteBound_58 - · exact (distillFinite_59 α hα (by linarith)).trans_lt distillFiniteBound_59 - · exact (distillFinite_60 α hα (by linarith)).trans_lt distillFiniteBound_60 - · exact (distillFinite_61 α hα (by linarith)).trans_lt distillFiniteBound_61 - · exact (distillFinite_62 α hα (by linarith)).trans_lt distillFiniteBound_62 - · exact (distillFinite_63 α hα (by linarith)).trans_lt distillFiniteBound_63 + · exact (distillFinite_34 α hα h17).trans_lt distillFiniteBound_34 + · exact (distillFinite_35 α hα h17).trans_lt distillFiniteBound_35 + · exact (distillFinite_36 α hα h17).trans_lt distillFiniteBound_36 + · exact (distillFinite_37 α hα h17).trans_lt distillFiniteBound_37 + · exact (distillFinite_38 α hα h17).trans_lt distillFiniteBound_38 + · exact (distillFinite_39 α hα h17).trans_lt distillFiniteBound_39 + · exact (distillFinite_40 α hα h17).trans_lt distillFiniteBound_40 + · exact (distillFinite_41 α hα h17).trans_lt distillFiniteBound_41 + · exact (distillFinite_42 α hα h17).trans_lt distillFiniteBound_42 + · exact (distillFinite_43 α hα h17).trans_lt distillFiniteBound_43 + · exact (distillFinite_44 α hα h17).trans_lt distillFiniteBound_44 + · exact (distillFinite_45 α hα h17).trans_lt distillFiniteBound_45 + · exact (distillFinite_46 α hα h17).trans_lt distillFiniteBound_46 + · exact (distillFinite_47 α hα h17).trans_lt distillFiniteBound_47 + · exact (distillFinite_48 α hα h17).trans_lt distillFiniteBound_48 + · exact (distillFinite_49 α hα h17).trans_lt distillFiniteBound_49 + · exact (distillFinite_50 α hα h17).trans_lt distillFiniteBound_50 + · exact (distillFinite_51 α hα h17).trans_lt distillFiniteBound_51 + · exact (distillFinite_52 α hα h17).trans_lt distillFiniteBound_52 + · exact (distillFinite_53 α hα h17).trans_lt distillFiniteBound_53 + · exact (distillFinite_54 α hα h17).trans_lt distillFiniteBound_54 + · exact (distillFinite_55 α hα h17).trans_lt distillFiniteBound_55 + · exact (distillFinite_56 α hα h17).trans_lt distillFiniteBound_56 + · exact (distillFinite_57 α hα h17).trans_lt distillFiniteBound_57 + · exact (distillFinite_58 α hα h17).trans_lt distillFiniteBound_58 + · exact (distillFinite_59 α hα h17).trans_lt distillFiniteBound_59 + · exact (distillFinite_60 α hα h17).trans_lt distillFiniteBound_60 + · exact (distillFinite_61 α hα h17).trans_lt distillFiniteBound_61 + · exact (distillFinite_62 α hα h17).trans_lt distillFiniteBound_62 + · exact (distillFinite_63 α hα h17).trans_lt distillFiniteBound_63 theorem distillFinite_scalar {m : ℕ} (hm : 5 ≤ m) (hm63 : m ≤ 63) {α : ℝ} (hα : 0 < α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : diff --git a/Sendov/Common/DistillationHyperbolic.lean b/Sendov/Common/DistillationHyperbolic.lean index e817bf8..feedf4e 100644 --- a/Sendov/Common/DistillationHyperbolic.lean +++ b/Sendov/Common/DistillationHyperbolic.lean @@ -40,12 +40,10 @@ open Real Set Filter private lemma nonneg_of_deriv {f g : ℝ → ℝ} (hd : ∀ z, HasDerivAt f (g z) z) (h0 : f 0 = 0) (hg : ∀ z, 0 ≤ z → 0 ≤ g z) {y : ℝ} (hy : 0 ≤ y) : 0 ≤ f y := by have hmono : MonotoneOn f (Ici 0) := by - refine monotoneOn_of_deriv_nonneg (convex_Ici 0) + refine monotoneOn_of_hasDerivWithinAt_nonneg (convex_Ici 0) (fun z _ => (hd z).continuousAt.continuousWithinAt) - (fun z _ => (hd z).differentiableAt.differentiableWithinAt) (fun z hz => ?_) - rw [(hd z).deriv] - rw [interior_Ici] at hz - exact hg z (le_of_lt hz) + (fun z _ => (hd z).hasDerivWithinAt) + (fun z hz => hg z (interior_subset hz)) simpa [h0] using hmono (mem_Ici.2 le_rfl) (mem_Ici.2 hy) hy /-- The numerator polynomial in the donor Padé majorant. -/ @@ -369,7 +367,7 @@ private lemma P_nonpos {y : ℝ} (hy : 0 ≤ y) (hy100 : y ≤ 100) : P y ≤ 0 unfold P ring rw [hid] at h - nlinarith + exact nonpos_of_mul_nonneg_right h (by norm_num) /-- Rational square comparison, with the essential factor `8/7`. -/ theorem pade_square_le {x : ℝ} (hx : 0 ≤ x) (hx10 : x ≤ 10) : @@ -378,26 +376,25 @@ theorem pade_square_le {x : ℝ} (hx : 0 ≤ x) (hx10 : x ≤ 10) : have hid : 7 * ((9 + (8 / 7 : ℝ) * x ^ 2) * A x ^ 2 - D x ^ 2) = x ^ 2 * P (x ^ 2) := by unfold A D P; ring have hh := mul_nonpos_of_nonneg_of_nonpos (sq_nonneg x) hP - nlinarith + linarith only [hid, hh] /-- Cleared derivative comparison for the stronger, interval-restricted bound. -/ theorem sqrt_mul_sub_le {x : ℝ} (hx : 0 ≤ x) (hx10 : x ≤ 10) : sqrt (9 + (8 / 7 : ℝ) * x ^ 2) * (x * cosh x - sinh x) ≤ x ^ 2 * sinh x := by - have hA : 0 ≤ A x := by unfold A; positivity have hD : 0 < D x := by unfold D; positivity have hs := pade_square_le hx hx10 have hr : 0 ≤ 9 + (8 / 7 : ℝ) * x ^ 2 := by positivity have hroot : sqrt (9 + (8 / 7 : ℝ) * x ^ 2) * A x ≤ D x := by have heq : (sqrt (9 + (8 / 7 : ℝ) * x ^ 2) * A x) ^ 2 = (9 + (8 / 7 : ℝ) * x ^ 2) * A x ^ 2 := by rw [mul_pow, sq_sqrt hr] - have hpos := mul_nonneg (sqrt_nonneg (9 + (8 / 7 : ℝ) * x ^ 2)) hA - nlinarith + exact le_of_sq_le_sq (by rwa [heq]) hD.le have hp := pade_nonneg hx have hsinh : 0 ≤ sinh x := sinh_nonneg_iff.mpr hx have hmul := mul_le_mul_of_nonneg_left hroot (mul_nonneg (sq_nonneg x) hsinh) have hmul2 := mul_nonneg (sqrt_nonneg (9 + (8 / 7 : ℝ) * x ^ 2)) hp have hh : D x * (sqrt (9 + (8 / 7 : ℝ) * x ^ 2) * - (x * cosh x - sinh x)) ≤ D x * (x ^ 2 * sinh x) := by nlinarith + (x * cosh x - sinh x)) ≤ D x * (x ^ 2 * sinh x) := by + nlinarith only [hmul, hmul2] exact (mul_le_mul_iff_right₀ hD).mp hh /-- Strong SJanPerth bound on `(0,10]`; both rational scale factors are retained. -/ @@ -419,19 +416,19 @@ theorem log_sinh_div_le {h : ℝ} (hh : 0 < h) (hh10 : h ≤ 10) : · exact (((hasDerivAt_sinh z).log hsinh).sub ((hasDerivAt_id' z).log (ne_of_gt hz))).congr_deriv (by field_simp) have hmono : MonotoneOn ψ (Ioc 0 10) := by - refine monotoneOn_of_deriv_nonneg (convex_Ioc 0 10) + refine monotoneOn_of_hasDerivWithinAt_nonneg (convex_Ioc 0 10) (fun z hz => (hderiv z hz.1).continuousAt.continuousWithinAt) (fun z hz => (hderiv z (by rw [interior_Ioc] at hz; exact - hz.1)).differentiableAt.differentiableWithinAt) + hz.1)).hasDerivWithinAt) (fun z hz => ?_) rw [interior_Ioc, mem_Ioo] at hz have hzpos : 0 < z := hz.1 - rw [(hderiv z hz.1).deriv, sub_nonneg, div_sub_div _ _ (ne_of_gt (sinh_pos_iff.2 hz.1)) + rw [sub_nonneg, div_sub_div _ _ (ne_of_gt (sinh_pos_iff.2 hz.1)) (ne_of_gt hz.1), div_le_div_iff₀ (by positivity) (by positivity)] - nlinarith [sqrt_mul_sub_le (le_of_lt hz.1) (le_of_lt hz.2)] + nlinarith only [sqrt_mul_sub_le (le_of_lt hz.1) (le_of_lt hz.2)] -- `ψ → 0` as `z → 0⁺` have hslope : Tendsto (fun z => sinh z / z) (nhdsWithin 0 {(0 : ℝ)}ᶜ) (nhds 1) := by - simpa [slope_fun_def, div_eq_inv_mul, hasDerivAt_iff_tendsto_slope] using hasDerivAt_sinh 0 + simpa [slope_fun_def, div_eq_inv_mul] using (hasDerivAt_sinh 0).tendsto_slope have hlog : Tendsto ψ (nhdsWithin 0 (Ioi 0)) (nhds 0) := by have hsub : nhdsWithin (0 : ℝ) (Ioi 0) ≤ nhdsWithin 0 {(0 : ℝ)}ᶜ := nhdsWithin_mono _ (fun z hz => ne_of_gt hz) diff --git a/Sendov/Common/DistillationKernel.lean b/Sendov/Common/DistillationKernel.lean index c640d0e..cb7b8e0 100644 --- a/Sendov/Common/DistillationKernel.lean +++ b/Sendov/Common/DistillationKernel.lean @@ -69,10 +69,10 @@ lemma QQ_secant_gap (c A l r t : ℝ) (hlr : l ≠ r) : lemma QQ_le_secant {c A l r t : ℝ} (hA : 0 ≤ A) (hlr : l < r) (ht : t ∈ Set.Icc l r) : QQ c A t ≤ ((r - t) * QQ c A l + (t - l) * QQ c A r) / (r - l) := by - have h := QQ_secant_gap c A l r t hlr.ne - have hn := mul_nonneg (mul_nonneg hA (sub_nonneg.mpr ht.1)) + apply sub_nonneg.mp + rw [QQ_secant_gap c A l r t hlr.ne] + exact mul_nonneg (mul_nonneg hA (sub_nonneg.mpr ht.1)) (sub_nonneg.mpr ht.2) - linarith /-- Integral comparison with exactly the positivity needed on the interval. This generalization serves both actual polynomial data and the enlarged scalar domain. -/ diff --git a/Sendov/Common/TwoChord.lean b/Sendov/Common/TwoChord.lean index 8a8fcdc..4cff6b4 100644 --- a/Sendov/Common/TwoChord.lean +++ b/Sendov/Common/TwoChord.lean @@ -199,7 +199,7 @@ theorem integral_polarKernel_two_chord_rpow {m α η s : ℝ} (hm : 0 < m) (hcont.intervalIntegrable 0 (3 / 5)) (hcont.intervalIntegrable (3 / 5) 1)] have hfirst := integral_polarKernel_first_chord hm hα hαm hη hη1 (show 0 < s by linarith) have hsecond := integral_polarKernel_second_chord hm hα hαm hη hs - linarith + simpa only [add_assoc] using add_le_add hfirst hsecond /-- The paper's two-chord estimate with real degree, arbitrary admissible eta, and all endpoints. -/ theorem integral_polarKernel_two_chord {m α η : ℝ} (hm : 5 ≤ m) diff --git a/Sendov/Conjecture.lean b/Sendov/Conjecture.lean index 72a6fa2..e932850 100644 --- a/Sendov/Conjecture.lean +++ b/Sendov/Conjecture.lean @@ -148,7 +148,7 @@ theorem phelps_rodriguez {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegr rw [← C_mul, ← mul_pow, inv_mul_cancel₀ hωne, one_pow, C_1] have hgoal : rotate ω⁻¹ (rotate ω p) = C (c * ω⁻¹ ^ n) * (X ^ n - C (a ^ n)) := by rw [hext', hcomp, haω, C_mul] - linear_combination (C c) * h1 + simp only [mul_sub, mul_assoc, h1, mul_one] exact (rotate_rotate_inv hωne p).symm.trans hgoal /-! ### Sendov's conjecture -/ diff --git a/Sendov/Counterexample/Identities.lean b/Sendov/Counterexample/Identities.lean index 28a1cfe..91f7da5 100644 --- a/Sendov/Counterexample/Identities.lean +++ b/Sendov/Counterexample/Identities.lean @@ -121,10 +121,7 @@ lemma prod_map_neg (s : Multiset ℂ) : lemma eval_prod_zero (z : Multiset ℂ) : ((z.map (fun w => X - C w)).prod).eval 0 = (-1) ^ (Multiset.card z) * z.prod := by rw [eval_multiset_prod, Multiset.map_map] - rw [show (z.map ((fun r : ℂ[X] => r.eval 0) ∘ (fun w => X - C w))).prod - = (z.map (fun w => -w)).prod from - congrArg Multiset.prod (Multiset.map_congr rfl fun w _ => by simp)] - exact prod_map_neg z + simpa only [Function.comp_apply, eval_sub, eval_X, eval_C, zero_sub] using prod_map_neg z /-- The derivative of `∏ⱼ (X - zⱼ)` at the origin. Proved by induction rather than through `Polynomial.derivative_prod`, which would need the evaluation of a multiset sum. -/ diff --git a/Sendov/Interior.lean b/Sendov/Interior.lean index 2055787..1aeae62 100644 --- a/Sendov/Interior.lean +++ b/Sendov/Interior.lean @@ -73,10 +73,8 @@ theorem sendov_interior {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegre exact hpq -- basic numerology have hne : ((n : ℂ) - 1) ≠ 0 := by - intro h - have h1 : (n : ℂ) = 1 := by linear_combination h - have h2 : n = 1 := by exact_mod_cast h1 - omega + apply sub_ne_zero.mpr + exact_mod_cast (show n ≠ 1 by omega) have hqne : q ≠ 0 := by intro h rw [h, Multiset.card_zero] at hqcard @@ -85,12 +83,10 @@ theorem sendov_interior {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegre simpa using ne_of_gt ha0 have haC2 : ((a : ℝ) : ℂ) ^ 2 ≠ 1 := by intro h - have : (a : ℂ) ^ 2 = ((a ^ 2 : ℝ) : ℂ) := by push_cast; ring - rw [this] at h have h1 : a ^ 2 = 1 := by exact_mod_cast h - nlinarith [h1, ha0, ha1] + nlinarith only [h1, ha0, ha1] have hstar := one_le_integral_prod_norm hn (a := a) - (by rw [abs_of_nonneg (le_of_lt ha0)]; linarith) hz1 + (by rw [abs_of_nonneg ha0.le]; linarith only [ha1]) hz1 (polar_identity (c := p.leadingCoeff) (a := ((a : ℝ) : ℂ)) (n := n) (z := z) (q := q) (p := p) hc0 haC0 haC2 hzcard hqcard hq0 hpa hpz hpq') (prod_sub_mul_prod (c := p.leadingCoeff) (a := ((a : ℝ) : ℂ)) (n := n) (z := z) (q := q) @@ -115,8 +111,8 @@ theorem sendov_interior {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegre have horigin := origin_exact (n := n) (α := M n * (1 - a ^ 2) / 2) hn5 ha0 ha1 hqcard hqne hz1 hq1 hxy hcent hfirst hsecond rfl -- the two are incompatible - exact polar_origin_incompatible hn6 ha0 ha1 (by nlinarith [hx2, sq_nonneg y]) rfl hpolar - horigin + exact polar_origin_incompatible hn6 ha0 ha1 + ((le_add_of_nonneg_right (sq_nonneg y)).trans hx2) rfl hpolar horigin /-- **The conjecture at `a = 0`.** `p'(a)` two ways gives `(∏ⱼ qⱼ)(∏ⱼ (a - zⱼ)) = n`. At `a = 0` the second factor is `∏ⱼ zⱼ` up to sign, so both factors have norm at most one and @@ -154,8 +150,11 @@ theorem sendov_center {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegree simpa using hz1 w hw have h3 : ‖(n : ℂ)‖ = (n : ℝ) := by simp rw [h3] at hnorm - have h4 : (2 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn - nlinarith [hnorm, h1, h2, norm_nonneg q.prod, norm_nonneg (z.map (fun w => (0 : ℂ) - w)).prod] + have hn1 : (n : ℝ) ≤ 1 := by + rw [← hnorm] + exact mul_le_one₀ h1 (norm_nonneg _) h2 + have : n ≤ 1 := by exact_mod_cast hn1 + omega /-- **The conjecture for a real zero in `[0,1)`**, every degree `n ≥ 2`. -/ theorem sendov_interior_real {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegree = n) diff --git a/Sendov/Reduction/Alpha17.lean b/Sendov/Reduction/Alpha17.lean index 6b53864..e7153e2 100644 --- a/Sendov/Reduction/Alpha17.lean +++ b/Sendov/Reduction/Alpha17.lean @@ -57,16 +57,10 @@ lemma log_le_div_exp_one {t : ℝ} (ht : 0 < t) : Real.log t ≤ t / exp 1 := by /-- `exp z ≤ 1/(1-z)` for `z < 1`, from `1 - z ≤ e^{-z}`. -/ lemma exp_le_one_div_one_sub {z : ℝ} (hz : z < 1) : exp z ≤ 1 / (1 - z) := by - have hpos := Real.exp_pos z - have h1 : (0 : ℝ) < 1 - z := by linarith - have h := Real.add_one_le_exp (-z) - rw [Real.exp_neg] at h - have h2 : (1 - z) * exp z ≤ 1 := by - have := mul_le_mul_of_nonneg_right h hpos.le - rw [inv_mul_cancel₀ hpos.ne'] at this - linarith - rw [le_div_iff₀ h1] - linarith + have h : 1 - z ≤ exp (-z) := by + simpa only [sub_eq_add_neg, add_comm] using Real.add_one_le_exp (-z) + have hbound := one_div_le_one_div_of_le (sub_pos.mpr hz) h + simpa only [Real.exp_neg, one_div, inv_inv] using hbound /-- `2.83 ≤ log 17`, via `log 16 + log(17/16) ≥ 4 log 2 + 1/17`. -/ lemma log_seventeen_ge : (2.83 : ℝ) ≤ Real.log 17 := by @@ -115,10 +109,10 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) rw [not_le] at hcon have hn2 : 2 ≤ n := by omega have hM : (0 : ℝ) < M n := M_pos hn2 - have hα0 : (0 : ℝ) < α := by linarith + have hα0 : (0 : ℝ) < α := lt_trans (by norm_num) hcon -- feasibility forces `n - 1 ≥ 2α > 34` - have hMge : 2 * α ≤ M n := by linarith [alpha_le_half hn2 hα] - have hM34 : (34 : ℝ) < M n := by linarith + have hMge : 2 * α ≤ M n := by linarith only [alpha_le_half hn2 hα] + have hM34 : (34 : ℝ) < M n := by linarith only [hMge, hcon] have hMn : M n = (n : ℝ) - 1 := rfl -- the standing facts about `β(1)` set B1 : ℝ := QQ (a * x) (a ^ 2) 1 with hB1def @@ -126,17 +120,16 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) have hfeas : (a * x) ^ 2 ≤ a ^ 2 := by simpa only [mul_pow, mul_one] using mul_le_mul_of_nonneg_left hx (sq_nonneg a) have hB0 : 0 ≤ B1 := QQ_nonneg hfeas 1 - have h3 : (0 : ℝ) < 3 + α := by linarith + have h3 : (0 : ℝ) < 3 + α := by positivity have hB1lt : B1 < 1 := by - have : α / (3 + α) < 1 := by rw [div_lt_one h3]; linarith - linarith + exact hbeta.trans_lt ((div_lt_one h3).mpr (by linarith only [])) have hB1eq : B1 = 1 - 2 * (a * x) + a ^ 2 := by rw [hB1def, QQ_one] have hax : 0 < a * x := by nlinarith only [hB1lt, hB1eq, sq_nonneg a] have haxle : a * x ≤ 1 := by have hxle : x ≤ 1 := by nlinarith only [hx] calc a * x ≤ a * 1 := mul_le_mul_of_nonneg_left hxle ha.le _ ≤ 1 := by simpa only [mul_one] using ha1.le - have hxpos : 0 < x := by nlinarith only [hax, ha] + have hxpos : 0 < x := (mul_pos_iff_of_pos_left ha).mp hax have hr : (0 : ℝ) < r := by rw [hrdef]; rw [hMn] at hM34; linarith -- `log α ≥ 2.83` have hlog17 : (2.83 : ℝ) ≤ Real.log α := @@ -194,8 +187,8 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) obtain ⟨v, hvdef⟩ : ∃ w : ℝ, w = M n / (2 * α) - 1 := ⟨_, rfl⟩ have h2α : (0 : ℝ) < 2 * α := by linarith have hv0 : 0 ≤ v := by - rw [hvdef, sub_nonneg, le_div_iff₀ h2α] - linarith + rw [hvdef, sub_nonneg, le_div_iff₀ h2α, one_mul] + exact hMge have hMv : M n = 2 * α * (v + 1) := by rw [hvdef] field_simp @@ -209,10 +202,12 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) field_simp -- `β(1) ≤ exp(-log α/α)`, hence `β(1)^r ≤ exp(-(v+1)log α) exp(log α/(2α))` have hB1exp : B1 ≤ exp (-(Real.log α / α)) := by - have h1 : B1 ≤ exp (B1 - 1) := by linarith [Real.add_one_le_exp (B1 - 1)] + have h1 : B1 ≤ exp (B1 - 1) := by + simpa only [sub_add_cancel] using Real.add_one_le_exp (B1 - 1) refine h1.trans (Real.exp_le_exp.2 ?_) - have : Real.log α / α ≤ 1 - B1 := by rw [div_le_iff₀ hα0]; linarith - linarith + have : Real.log α / α ≤ 1 - B1 := + (div_le_iff₀ hα0).mpr (by simpa only [mul_comm] using hlogb) + linarith only [this] have hrM : r = (M n - 1) / 2 := by rw [hrdef, hMn]; ring have hB1r : B1 ^ r ≤ exp (-(v * Real.log α)) / α * exp (Real.log α / (2 * α)) := by have h1 : B1 ^ r ≤ exp (-(Real.log α / α) * r) := by @@ -243,7 +238,7 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) have hlast : α / 2.7 ≤ 0.1852 * (2 * α) := by rw [div_le_iff₀ (by norm_num : (0 : ℝ) < 2.7)] linarith only [hα0] - linarith only [h, h27, hlast] + exact h.trans (h27.trans hlast) -- assemble the geometric term have hnv : (n : ℝ) = 2 * α * (v + 1) + 1 := by rw [← hMv, hMn] @@ -267,8 +262,8 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) rw [hfinal] have hbound : v * (2 * (v + 1) + 1 / α) * exp (-(2.83 * v)) ≤ 0.4118 := by refine le_trans ?_ (tail_poly_bound hv0) - have hinv : (1 : ℝ) / α ≤ 1 / 17 := by - rw [div_le_div_iff₀ hα0 (by norm_num)]; linarith + have hinv : (1 : ℝ) / α ≤ 1 / 17 := + one_div_le_one_div_of_le (by norm_num) hcon.le exact mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left (add_le_add le_rfl hinv) hv0) hexpnn have hscale : α * (v * (2 * (v + 1) + 1 / α) * exp (-(2.83 * v))) ≤ α * 0.4118 := @@ -278,9 +273,8 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) have hlogterm : 4 * α / Real.log α ≤ 1.41343 * α := by rw [div_le_iff₀ hlogpos] linarith only [mul_le_mul_of_nonneg_right hlog17 hα0.le, hα0] - have hMterm : 1 / (2 * M n) ≤ 1 / 68 := by - rw [div_le_div_iff₀ (by positivity) (by norm_num)] - linarith + have hMterm : 1 / (2 * M n) ≤ 1 / 68 := + one_div_le_one_div_of_le (by norm_num) (by linarith only [hM34]) linarith only [hmain, hlogterm, hMterm, hthird, hcon] end Sendov diff --git a/Sendov/Reduction/BetaBound.lean b/Sendov/Reduction/BetaBound.lean index fa2a099..28a4c54 100644 --- a/Sendov/Reduction/BetaBound.lean +++ b/Sendov/Reduction/BetaBound.lean @@ -50,9 +50,7 @@ lemma integral_exp_mul (hc : c ≠ 0) (a b : ℝ) : lemma integral_exp_eq' (hα : 0 < α) (hB : B < 2) : (∫ t in (0 : ℝ)..1, exp (α * (-1 + (2 - B) * t))) = (exp (α * (1 - B)) - exp (-α)) / (α * (2 - B)) := by - have hkpos : 0 < α * (2 - B) := by - have : 0 < 2 - B := by linarith - positivity + have hkpos : 0 < α * (2 - B) := mul_pos hα (sub_pos.mpr hB) have hrw : ∀ t : ℝ, α * (-1 + (2 - B) * t) = -α + α * (2 - B) * t := by intro t; ring simp only [hrw, Real.exp_add] @@ -91,12 +89,11 @@ lemma beta_lt_two (hα : 0 < α) ((by fun_prop : Continuous fun _ : ℝ => exp (-α)).intervalIntegrable _ _) ?_ intro u hu refine Real.exp_le_exp.2 ?_ - nlinarith [mul_nonneg (mul_nonneg hα.le hu.1) (sub_nonneg.2 hcon)] + nlinarith only [mul_nonneg (mul_nonneg hα.le hu.1) (sub_nonneg.2 hcon)] have hval : (∫ _t in (0 : ℝ)..1, exp (-α)) = exp (-α) := by simp - have hone : exp (-α) < 1 := by - rw [Real.exp_lt_one_iff]; linarith + have hone : exp (-α) < 1 := Real.exp_lt_one_iff.mpr (neg_lt_zero.mpr hα) rw [hval] at hmono - linarith + exact (not_lt_of_ge hlt) (hmono.trans_lt hone) /-- **`(lt) ⟹ (beta-bound)`.** The `α/(3+α)` of the blog post. -/ theorem beta_le (hα : 0 < α) (hB0 : 0 ≤ B) @@ -105,45 +102,38 @@ theorem beta_le (hα : 0 < α) (hB0 : 0 ≤ B) rw [integral_exp_eq hα hB2] at hlt set u : ℝ := α * B / 2 with hudef set h : ℝ := α * (2 - B) / 2 with hhdef - have hhpos : 0 < h := by - rw [hhdef] - have : 0 < 2 - B := by linarith - positivity + have hhpos : 0 < h := div_pos (mul_pos hα (sub_pos.mpr hB2)) (by norm_num) have hu0 : 0 ≤ u := by rw [hudef]; positivity -- `1 ≤ e^{-u} sinh h / h` is `e^u ≤ sinh h / h` have h1 : exp u ≤ sinh h / h := by - rw [Real.exp_neg, inv_mul_eq_div, le_div_iff₀ (Real.exp_pos u)] at hlt - linarith + rwa [Real.exp_neg, inv_mul_eq_div, le_div_iff₀ (Real.exp_pos u), one_mul] at hlt have h2 : u ≤ Real.log (sinh h / h) := by rw [← Real.log_exp u] exact Real.log_le_log (Real.exp_pos u) h1 have h3 : u ≤ Real.sqrt (h ^ 2 + 9) - 3 := h2.trans (log_sinh_div_le hhpos) -- square; `h = α - u` have hhu : h = α - u := by rw [hhdef, hudef]; ring - have hsq : Real.sqrt (h ^ 2 + 9) ^ 2 = h ^ 2 + 9 := Real.sq_sqrt (by positivity) have h4 : (u + 3) ^ 2 ≤ h ^ 2 + 9 := by - have hnn : (0 : ℝ) ≤ u + 3 := by linarith - nlinarith [h3, hsq, Real.sqrt_nonneg (h ^ 2 + 9)] - have h5 : u * (6 + 2 * α) ≤ α ^ 2 := by rw [hhu] at h4; nlinarith [h4] - rw [le_div_iff₀ (by linarith : (0 : ℝ) < 3 + α)] + exact (Real.le_sqrt (by positivity) (by positivity)).mp (by linarith only [h3]) + have h5 : u * (6 + 2 * α) ≤ α ^ 2 := by + rw [hhu] at h4 + nlinarith only [h4] + rw [le_div_iff₀ (by positivity : (0 : ℝ) < 3 + α)] rw [hudef] at h5 - nlinarith [h5, hα] + nlinarith only [h5, hα] /-- **The logarithmic half of `(beta-bound)`:** `log α ≤ α(1 - β(1))`. From `(lt)`, `e^{α(1-B)} ≥ α(2-B) + e^{-α} > α`, since `B ≤ 1` makes `2 - B ≥ 1`. -/ theorem log_le_alpha_mul (hα : 0 < α) (hB1 : B ≤ 1) (hlt : 1 ≤ ∫ t in (0 : ℝ)..1, exp (α * (-1 + (2 - B) * t))) : Real.log α ≤ α * (1 - B) := by - have hB2 : B < 2 := by linarith + have hB2 : B < 2 := hB1.trans_lt (by norm_num) rw [integral_exp_eq' hα hB2] at hlt - have hden : (0 : ℝ) < α * (2 - B) := by - have : (0 : ℝ) < 2 - B := by linarith - positivity + have hden : (0 : ℝ) < α * (2 - B) := mul_pos hα (sub_pos.mpr hB2) rw [le_div_iff₀ hden, one_mul] at hlt - have hge : α ≤ α * (2 - B) := by nlinarith - have hlt' : α < exp (α * (1 - B)) := by - have := Real.exp_pos (-α) - linarith - exact (Real.log_le_iff_le_exp hα).2 hlt'.le + have hge : α ≤ α * (2 - B) := + le_mul_of_one_le_right hα.le (by linarith only [hB1]) + exact (Real.log_le_iff_le_exp hα).2 + (hge.trans (hlt.trans (sub_le_self _ (Real.exp_pos _).le))) end Sendov diff --git a/Sendov/Reduction/CubicPolar.lean b/Sendov/Reduction/CubicPolar.lean index d9a3c48..142a089 100644 --- a/Sendov/Reduction/CubicPolar.lean +++ b/Sendov/Reduction/CubicPolar.lean @@ -36,7 +36,7 @@ lemma cubicPolarEnvelope_center_lt_ten {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ have hp : 0 < 10 - α * (1 - cubicPolarEnvelope α / 2) := by rw [hid] exact div_pos hn (by positivity) - linarith + exact sub_pos.mp hp /-- Strict positivity at the envelope. Clearing the paper's u-expression gives an all-positive numerator, so no strict integral premise is necessary. -/ @@ -85,32 +85,30 @@ theorem eta_lt_cubicPolarEnvelope {α η : ℝ} (hα : 0 < α) (h17 : α ≤ 17) have hpcp : pc ≤ p := by dsimp [pc, p]; gcongr have hx0 : 0 < x := by dsimp [x, p] - nlinarith [mul_pos hα (sub_pos.mpr hη1)] + nlinarith only [hα, mul_pos hα (sub_pos.mpr hη1)] have hx10 : x < 10 := by have hc := cubicPolarEnvelope_center_lt_ten hα.le h17 have hxp : x ≤ α * (1 - cubicPolarEnvelope α / 2) := by - dsimp [x, p, pc] at * - nlinarith + calc x = α - p := hxdef + _ ≤ α - pc := sub_le_sub_left hpcp α + _ = α * (1 - cubicPolarEnvelope α / 2) := by rw [hpcdef]; ring exact hxp.trans_lt hc - have hlog : p ≤ log (sinh x / x) := polar_le_log_sinh hα (by linarith) hpolar + have hlog : p ≤ log (sinh x / x) := + polar_le_log_sinh hα (hη1.trans (by norm_num)) hpolar have hstrong : p ≤ (7 / 8 : ℝ) * (sqrt (9 + (8 / 7 : ℝ) * x ^ 2) - 3) := hlog.trans (DistillationHyperbolic.log_sinh_div_le hx0 hx10.le) have hroot : (8 / 7 : ℝ) * p + 3 ≤ sqrt (9 + (8 / 7 : ℝ) * x ^ 2) := by - linarith - have hsq : sqrt (9 + (8 / 7 : ℝ) * x ^ 2) ^ 2 = - 9 + (8 / 7 : ℝ) * x ^ 2 := Real.sq_sqrt (by positivity) + linarith only [hstrong] have hsquare : ((8 / 7 : ℝ) * p + 3) ^ 2 ≤ 9 + (8 / 7 : ℝ) * x ^ 2 := by - nlinarith [sq_nonneg (sqrt (9 + (8 / 7 : ℝ) * x ^ 2) - ((8 / 7 : ℝ) * p + 3)), - mul_nonneg (show 0 ≤ (8 / 7 : ℝ) * p + 3 by positivity) - (sub_nonneg.mpr hroot)] + exact (Real.le_sqrt (by positivity) (by positivity)).mp hroot have hF : p ^ 2 / 7 + 2 * (α + 3) * p - α ^ 2 ≤ 0 := by rw [hxdef] at hsquare - nlinarith + nlinarith only [hsquare] have hFc : 0 < pc ^ 2 / 7 + 2 * (α + 3) * pc - α ^ 2 := cubicPolarEnvelope_quadratic_pos hα have hmono : pc ^ 2 ≤ p ^ 2 := pow_le_pow_left₀ hpc0 hpcp 2 - nlinarith [mul_nonneg (show 0 ≤ 2 * (α + 3) by positivity) - (sub_nonneg.mpr hpcp)] + nlinarith only [hF, hFc, hmono, mul_le_mul_of_nonneg_left hpcp + (show 0 ≤ 2 * (α + 3) by positivity)] /-- Old `a,x,n` coordinates: eta's domain follows from the original weak polar hypothesis via the already proved Bridge, rather than an extra premise. diff --git a/Sendov/Reduction/CubicScalar.lean b/Sendov/Reduction/CubicScalar.lean index 589fd84..0b31d80 100644 --- a/Sendov/Reduction/CubicScalar.lean +++ b/Sendov/Reduction/CubicScalar.lean @@ -9,7 +9,8 @@ only the original weak polar integral and original origin inequality. In particular, the alpha range and eta domain are conclusions, not extra inputs. The analytic origin reduction remains `one_le_of_origin` in `Simplified`, via -`one_le_scalarObstruction_of_polar_origin`. The strict cubic polar bound and +`one_le_scalarObstruction_of_origin`, reusing the established eta domain. +The strict cubic polar bound and eta monotonicity then enlarge the actual scalar obstruction. No finite-range certificate, tail bound, or old `R` enlargement is used here. -/ @@ -40,8 +41,8 @@ theorem cubicScalar_constraints_of_polar_origin {n : ℕ} (hn : 6 ≤ n) {a x α have hbeta := beta_le hα0 hη.1 hlt have hlog := log_le_alpha_mul hα0 hη.2.le hlt have h17 := alpha_le_seventeen hn5 ha ha1 hx hα hbeta hlog horigin - have hactual := one_le_scalarObstruction_of_polar_origin hn5 ha ha1 hx hα hpolar horigin - have hcubic := actualEta_lt_cubicPolarEnvelope_of_polar hn2 ha.le ha1 hx hα h17 hpolar + have hactual := one_le_scalarObstruction_of_origin hn5 ha ha1 hx hα hη.2 horigin + have hcubic := eta_lt_cubicPolarEnvelope hα0 h17 hη.1 hη.2 hlt exact ⟨hα0, hhalf, h17, hactual.trans (scalarObstruction_mono_eta hm hα0 hη.1 hcubic.le (cubicPolarEnvelope_lt_one hα0.le))⟩ diff --git a/Sendov/Reduction/DistillationBridge.lean b/Sendov/Reduction/DistillationBridge.lean index e49fd70..29c02b9 100644 --- a/Sendov/Reduction/DistillationBridge.lean +++ b/Sendov/Reduction/DistillationBridge.lean @@ -45,13 +45,11 @@ lemma scalarObstruction_mono_eta {m α η₁ η₂ : ℝ} (hm : 5 ≤ m) have hm2 : 0 ≤ m ^ 2 - 1 := by nlinarith have hη₂0 : 0 ≤ η₂ := hη₁.trans hη have hr : 0 ≤ (m - 3) / 2 := by linarith - have hd₁ : 0 < 2 * α * (1 - η₁) := - mul_pos (by positivity) (by linarith) have hd₂ : 0 < 2 * α * (1 - η₂) := - mul_pos (by positivity) (by linarith) - have he₁ : η₁ / (2 * α * (1 - η₁)) ≤ η₂ / (2 * α * (1 - η₂)) := by - rw [div_le_div_iff₀ hd₁ hd₂] - nlinarith [mul_nonneg hα.le (sub_nonneg.mpr hη)] + mul_pos (by positivity) (sub_pos.mpr hη₂) + have he₁ : η₁ / (2 * α * (1 - η₁)) ≤ η₂ / (2 * α * (1 - η₂)) := + div_le_div₀ hη₂0 hη hd₂ + (mul_le_mul_of_nonneg_left (sub_le_sub_left hη 1) (by positivity)) have he₂ : η₁ / (4 * α) ≤ η₂ / (4 * α) := div_le_div_of_nonneg_right hη (by positivity) have he₄ : η₁ / (4 * α * m) ≤ η₂ / (4 * α * m) := @@ -64,7 +62,7 @@ lemma scalarObstruction_mono_eta {m α η₁ η₂ : ℝ} (hm : 5 ≤ m) have hk0 := scalarObstruction_prefactor_nonneg hm hα hη₂0 have hlast := mul_le_mul hk hi hi0 hk0 unfold scalarObstruction - linarith + linarith only [he₁, he₂, he₄, hlast] /-- Exact actual-data coordinates; no polar or origin inequality is required. -/ lemma polarKernel_actual {n : ℕ} {a x α : ℝ} (hn : 2 ≤ n) @@ -74,7 +72,7 @@ lemma polarKernel_actual {n : ℕ} {a x α : ℝ} (hn : 2 ≤ n) have hc := mul_eq_c (x := x) hn hα have hA := A_eq_sq hn hα change 1 - 2 * α / M n = a ^ 2 at hA - rw [hA, show 1 - α / M n - QQ (a * x) (a ^ 2) 1 / 2 = a * x by linarith] + rw [hA, show 1 - α / M n - QQ (a * x) (a ^ 2) 1 / 2 = a * x by linarith only [hc]] /-- The raw RHS of `(1le)` is exactly H at actual eta, not H at the old envelope. -/ lemma scalarObstruction_actual_eq {n : ℕ} {a x α : ℝ} (hn : 2 ≤ n) @@ -86,20 +84,20 @@ lemma scalarObstruction_actual_eq {n : ℕ} {a x α : ℝ} (hn : 2 ≤ n) + (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) * QQ (a * x) (a ^ 2) 1 / (4 * α) * ∫ t in (0 : ℝ)..1, t ^ 3 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 4) / 2) := by have hm : M n ≠ 0 := (M_pos hn).ne' - have hA := A_eq_sq hn hα have hs : M n - 2 * α = M n * a ^ 2 := by - change 1 - 2 * α / M n = a ^ 2 at hA - field_simp at hA - nlinarith [hA] + rw [hα] + ring have hk : QQ (a * x) (a ^ 2) 1 * (M n ^ 2 - 1) * (M n - 2 * α) ^ 2 / (4 * α * M n) = (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) * QQ (a * x) (a ^ 2) 1 / (4 * α) := by rw [hs] - by_cases ha0 : α = 0 - · simp [ha0] - · field_simp - unfold M - ring + calc + _ = ((a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) * QQ (a * x) (a ^ 2) 1 * M n) / + (4 * α * M n) := by + congr 1 + unfold M + ring + _ = _ := mul_div_mul_right _ _ hm have hi : (∫ t in (0 : ℝ)..1, t ^ 3 * polarKernel (M n) α (QQ (a * x) (a ^ 2) 1) t ^ ((M n - 3) / 2)) = ∫ t in (0 : ℝ)..1, t ^ 3 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 4) / 2) := by @@ -146,7 +144,8 @@ lemma actualEta_mem_Ico_of_polar {n : ℕ} (hn : 2 ≤ n) {a x α : ℝ} (hpolar : 1 ≤ ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) : QQ (a * x) (a ^ 2) 1 ∈ Set.Ico (0 : ℝ) 1 := by have hα0 := alpha_pos hn ha1 ha hα - have hf : (a * x) ^ 2 ≤ a ^ 2 := by nlinarith [sq_nonneg a] + have hf : (a * x) ^ 2 ≤ a ^ 2 := by + simpa only [mul_pow, mul_one] using mul_le_mul_of_nonneg_left hx (sq_nonneg a) have hη0 := QQ_nonneg hf 1 have hb := beta_le hα0 hη0 (polar_exp hn hx hα hpolar) refine ⟨hη0, hb.trans_lt ?_⟩ diff --git a/Sendov/Reduction/Polar.lean b/Sendov/Reduction/Polar.lean index 04613a6..ec0aa8c 100644 --- a/Sendov/Reduction/Polar.lean +++ b/Sendov/Reduction/Polar.lean @@ -45,22 +45,22 @@ variable {n : ℕ} {a x t α : ℝ} lemma Ppolar_le_lin (a x : ℝ) (ht0 : 0 ≤ t) (ht1 : t ≤ 1) : Ppolar a x t ≤ 1 + (1 - a ^ 2) * (-1 + (2 - QQ (a * x) (a ^ 2) 1) * t) := by have hid : 1 + (1 - a ^ 2) * (-1 + (2 - QQ (a * x) (a ^ 2) 1) * t) - Ppolar a x t - = (1 - a ^ 2) ^ 2 * (t - t ^ 2) := by + = (1 - a ^ 2) ^ 2 * (t * (1 - t)) := by simp only [Ppolar, QQ]; ring - nlinarith [mul_nonneg (sq_nonneg (1 - a ^ 2)) (mul_nonneg ht0 (sub_nonneg.2 ht1))] + rw [← sub_nonneg, hid] + exact mul_nonneg (sq_nonneg _) (mul_nonneg ht0 (sub_nonneg.mpr ht1)) /-- The pointwise bound after raising to the power `(n-1)/2`. -/ lemma Ppolar_rpow_le (hn : 2 ≤ n) (hx : x ^ 2 ≤ 1) (hα : α = M n * (1 - a ^ 2) / 2) (ht0 : 0 ≤ t) (ht1 : t ≤ 1) : Ppolar a x t ^ (((n : ℝ) - 1) / 2) ≤ Real.exp (α * (-1 + (2 - QQ (a * x) (a ^ 2) 1) * t)) := by - have hM : (0 : ℝ) < M n := M_pos hn - have he : (0 : ℝ) ≤ ((n : ℝ) - 1) / 2 := by simp only [M] at hM; linarith + have he : (0 : ℝ) ≤ ((n : ℝ) - 1) / 2 := + div_nonneg (M_pos hn).le (by norm_num) set y : ℝ := (1 - a ^ 2) * (-1 + (2 - QQ (a * x) (a ^ 2) 1) * t) with hy have h1 : Ppolar a x t ≤ Real.exp y := by refine le_trans (Ppolar_le_lin a x ht0 ht1) ?_ - have := Real.add_one_le_exp y - linarith + simpa only [add_comm] using Real.add_one_le_exp y have h2 : Ppolar a x t ^ (((n : ℝ) - 1) / 2) ≤ Real.exp y ^ (((n : ℝ) - 1) / 2) := Real.rpow_le_rpow (Ppolar_nonneg hx a t) h1 he refine h2.trans_eq ?_ @@ -74,8 +74,8 @@ lemma Ppolar_rpow_le (hn : 2 ≤ n) (hx : x ^ 2 ≤ 1) (hα : α = M n * (1 - a theorem polar_exp (hn : 2 ≤ n) (hx : x ^ 2 ≤ 1) (hα : α = M n * (1 - a ^ 2) / 2) (hpolar : 1 ≤ ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) : 1 ≤ ∫ t in (0 : ℝ)..1, Real.exp (α * (-1 + (2 - QQ (a * x) (a ^ 2) 1) * t)) := by - have hM : (0 : ℝ) < M n := M_pos hn - have he : (0 : ℝ) ≤ ((n : ℝ) - 1) / 2 := by simp only [M] at hM; linarith + have he : (0 : ℝ) ≤ ((n : ℝ) - 1) / 2 := + div_nonneg (M_pos hn).le (by norm_num) have hc1 : Continuous fun t : ℝ => Ppolar a x t ^ (((n : ℝ) - 1) / 2) := (continuous_rpow_const he).comp (continuous_Ppolar a x) have hc2 : Continuous fun t : ℝ => diff --git a/Sendov/Reduction/Simplified.lean b/Sendov/Reduction/Simplified.lean index 46d611b..69a410f 100644 --- a/Sendov/Reduction/Simplified.lean +++ b/Sendov/Reduction/Simplified.lean @@ -47,13 +47,12 @@ obtained from Bernoulli's inequality after dividing by `(P+Q)^p`. -/ lemma rpow_add_le_of_one_le {P Q p : ℝ} (hP : 0 ≤ P) (hPQ : 0 < P + Q) (hp : 1 ≤ p) : (P + Q) ^ p ≤ P ^ p + p * Q * (P + Q) ^ (p - 1) := by have hθ : (0 : ℝ) ≤ P / (P + Q) := div_nonneg hP hPQ.le - have hb := one_add_mul_self_le_rpow_one_add (s := P / (P + Q) - 1) (by linarith) hp + have hb := one_add_mul_self_le_rpow_one_add (s := P / (P + Q) - 1) + (by linarith only [hθ]) hp rw [show (1 : ℝ) + (P / (P + Q) - 1) = P / (P + Q) by ring] at hb have hpow : (0 : ℝ) < (P + Q) ^ p := Real.rpow_pos_of_pos hPQ p have hfrac : (P / (P + Q)) ^ p * (P + Q) ^ p = P ^ p := by - rw [← Real.mul_rpow hθ hPQ.le] - congr 1 - field_simp + rw [← Real.mul_rpow hθ hPQ.le, div_mul_cancel₀ _ hPQ.ne'] have hsub : (P + Q) ^ (p - 1) = (P + Q) ^ p / (P + Q) := by rw [Real.rpow_sub hPQ, Real.rpow_one] have key : (P + Q) ^ p - p * Q * ((P + Q) ^ p / (P + Q)) ≤ P ^ p := by @@ -64,17 +63,14 @@ lemma rpow_add_le_of_one_le {P Q p : ℝ} (hP : 0 ≤ P) (hPQ : 0 < P + Q) (hp : _ ≤ (P / (P + Q)) ^ p * (P + Q) ^ p := mul_le_mul_of_nonneg_right hb hpow.le _ = P ^ p := hfrac rw [hsub] - linarith + linarith only [key] /-- `ax t < 1` on `[0,1]`, so the chord `1 - axt` is positive. -/ lemma one_sub_mul_pos (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 ≤ 1) (ht0 : 0 ≤ t) (ht1 : t ≤ 1) : 0 < 1 - a * x * t := by - rcases le_or_gt x 0 with h | h - · nlinarith [mul_nonneg ht0 (mul_nonneg ha.le (neg_nonneg.2 h))] - · have hx1 : x ≤ 1 := by nlinarith - have h1 : a * x * t ≤ a * x * 1 := - mul_le_mul_of_nonneg_left ht1 (mul_pos ha h).le - nlinarith [h1] + have hx1 : x ≤ 1 := by nlinarith only [hx] + rw [sub_pos, mul_assoc] + exact (mul_le_of_le_one_right ha.le (mul_le_one₀ hx1 ht0 ht1)).trans_lt ha1 /-- The pointwise step: `β^((n-2)/2)` split into a chord power and a `β^((n-4)/2)` remainder. -/ lemma beta_split (hn : 5 ≤ n) (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 ≤ 1) @@ -87,13 +83,13 @@ lemma beta_split (hn : 5 ≤ n) (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 ≤ 1) have hy : (0 : ℝ) < 1 - a * x * t := one_sub_mul_pos ha ha1 hx ht0 ht1 have hP : (0 : ℝ) ≤ (1 - a * x * t) ^ 2 := sq_nonneg _ have hQ : (0 : ℝ) ≤ a ^ 2 * t ^ 2 * (1 - x ^ 2) := by - have : (0 : ℝ) ≤ 1 - x ^ 2 := by linarith + have : (0 : ℝ) ≤ 1 - x ^ 2 := sub_nonneg.mpr hx positivity have hsum : QQ (a * x) (a ^ 2) t = (1 - a * x * t) ^ 2 + a ^ 2 * t ^ 2 * (1 - x ^ 2) := by rw [QQ_eq]; ring have hPQ : (0 : ℝ) < (1 - a * x * t) ^ 2 + a ^ 2 * t ^ 2 * (1 - x ^ 2) := by positivity - have hp : (1 : ℝ) ≤ ((n : ℝ) - 2) / 2 := by linarith + have hp : (1 : ℝ) ≤ ((n : ℝ) - 2) / 2 := by linarith only [hnR] have hb := rpow_add_le_of_one_le hP hPQ hp rw [← hsum] at hb -- `((1-axt)²)^((n-2)/2) = (1-axt)^(n-2)` @@ -119,7 +115,9 @@ lemma integral_beta_split (hn : 5 ≤ n) (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 have hs : (0 : ℝ) < (n : ℝ) - 2 := by linarith have hr2 : (0 : ℝ) ≤ ((n : ℝ) - 2) / 2 := by linarith have hr4 : (0 : ℝ) ≤ ((n : ℝ) - 4) / 2 := by linarith - have haxle : a * x ≤ 1 := by nlinarith [sq_nonneg (x - 1), sq_nonneg (x + 1), ha.le] + have haxle : a * x ≤ 1 := by + have hx1 : x ≤ 1 := by nlinarith only [hx] + exact (mul_le_of_le_one_right ha.le hx1).trans ha1.le -- the three continuous integrands have hc1 : Continuous fun t : ℝ => t * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2) := by simpa using continuous_pow_mul_QQ (a * x) (a ^ 2) 1 hr2 @@ -153,7 +151,7 @@ lemma integral_beta_split (hn : 5 ≤ n) (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 -- the chord piece: enlarge to `[0, 1/(ax)]` and evaluate have hrest : (∫ t in (0 : ℝ)..1, t * (1 - a * x * t) ^ ((n : ℝ) - 2)) ≤ ∫ t in (0 : ℝ)..1 / (a * x), t * (1 - a * x * t) ^ ((n : ℝ) - 2) := by - have hone : (1 : ℝ) ≤ 1 / (a * x) := by rw [le_div_iff₀ hax]; linarith + have hone : (1 : ℝ) ≤ 1 / (a * x) := (le_div_iff₀ hax).mpr (by simpa using haxle) have hadd : (∫ t in (0 : ℝ)..1, t * (1 - a * x * t) ^ ((n : ℝ) - 2)) + (∫ t in (1 : ℝ)..1 / (a * x), t * (1 - a * x * t) ^ ((n : ℝ) - 2)) = ∫ t in (0 : ℝ)..1 / (a * x), t * (1 - a * x * t) ^ ((n : ℝ) - 2) := @@ -165,9 +163,9 @@ lemma integral_beta_split (hn : 5 ≤ n) (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 have : (0 : ℝ) ≤ 1 - a * x * u := by have := hu.2 rw [le_div_iff₀ hax] at this - linarith - exact mul_nonneg (by linarith [hu.1]) (Real.rpow_nonneg this _) - linarith + linarith only [this] + exact mul_nonneg (zero_le_one.trans hu.1) (Real.rpow_nonneg this _) + exact (le_add_of_nonneg_right hnn).trans_eq hadd refine hrest.trans_eq ?_ rw [integral_chord_lin hs hax] congr 1 @@ -193,21 +191,24 @@ theorem one_le_of_origin (hn : 5 ≤ n) (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 set I3 : ℝ := ∫ t in (0 : ℝ)..1, t ^ 3 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 4) / 2) with hI3def -- `1 - β(1) = 2ax - a²`, so `β(1) < 1` gives `ax > 0` have hB1eq : B1 = 1 - 2 * (a * x) + a ^ 2 := by rw [hB1def, QQ_one] - have hax : 0 < a * x := by nlinarith [sq_nonneg a] - have hxpos : 0 < x := by nlinarith [hax, ha] + have hax : 0 < a * x := by nlinarith only [hB1lt, hB1eq, sq_nonneg a] + have hxpos : 0 < x := (mul_pos_iff_of_pos_left ha).mp hax -- `x² ≥ 1 - β(1)`, which is `(x-a)² ≥ 0` - have hxsq : 1 - B1 ≤ x ^ 2 := by rw [hB1eq]; nlinarith [sq_nonneg (x - a)] + have hxsq : 1 - B1 ≤ x ^ 2 := by + rw [hB1eq] + nlinarith only [sq_nonneg (x - a)] have hx2pos : (0 : ℝ) < x ^ 2 := by positivity have hinv : 1 / x ^ 2 ≤ 1 / (1 - B1) := by - apply one_div_le_one_div_of_le (by linarith) hxsq - have hone_sub : 1 - x ^ 2 ≤ B1 := by linarith + exact one_div_le_one_div_of_le (sub_pos.mpr hB1lt) hxsq + have hone_sub : 1 - x ^ 2 ≤ B1 := by linarith only [hxsq] -- the integral bound have hsplit := integral_beta_split hn ha ha1 hx hax have hI3nn : (0 : ℝ) ≤ I3 := by rw [hI3def] refine intervalIntegral.integral_nonneg (by norm_num) ?_ intro u hu - have hfe : (a * x) ^ 2 ≤ a ^ 2 := by nlinarith [sq_nonneg a] + have hfe : (a * x) ^ 2 ≤ a ^ 2 := by + simpa only [mul_pow, mul_one] using mul_le_mul_of_nonneg_left hx (sq_nonneg a) exact mul_nonneg (pow_nonneg hu.1 3) (Real.rpow_nonneg (QQ_nonneg hfe u) _) -- multiply the split by `a² n M` and simplify the Beta term to `1/x²` have hcoef : (0 : ℝ) ≤ a ^ 2 * n * M n := by positivity @@ -235,7 +236,8 @@ theorem one_le_of_origin (hn : 5 ≤ n) (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 have hc : (0 : ℝ) ≤ (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) / 2 := by have : (0 : ℝ) ≤ (n : ℝ) - 2 := by linarith positivity - nlinarith [mul_nonneg (mul_nonneg hc (sub_nonneg.2 hone_sub)) hI3nn] + simpa only [mul_div_right_comm] using + mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left hone_sub hc) hI3nn have hfirst : (1 - x ^ 2) / (2 * M n) ≤ B1 / (2 * M n) := by apply div_le_div_of_nonneg_right hone_sub (by positivity) have hne1 : (1 : ℝ) - B1 ≠ 0 := by linarith @@ -245,7 +247,7 @@ theorem one_le_of_origin (hn : 5 ≤ n) (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 have hinv' : 1 / x ^ 2 ≤ 1 + B1 / (1 - B1) := by rw [← hrec]; exact hinv -- do NOT rewrite `hax_eq` into `horigin`: it would also rewrite the `a * x` inside the -- integral, and the resulting atom would no longer match `hkey` - linarith [horigin, hkey, hinv', hfirst, hlast, hax_eq] + linarith only [horigin, hkey, hinv', hfirst, hlast, hax_eq] -- divide by `2α` have h2α : (0 : ℝ) < 2 * α := by linarith -- Divide the assembled inequality once; normalize all five terms together. diff --git a/scripts/gen_distillation.py b/scripts/gen_distillation.py index 9a1e864..11e9305 100644 --- a/scripts/gen_distillation.py +++ b/scripts/gen_distillation.py @@ -155,7 +155,8 @@ def aggregate_source(): interval_cases m ''' for m in FINITE_ROWS: - s+=f' · exact (distillFinite_{m} α hα (by linarith)).trans_lt distillFiniteBound_{m}\n' + bound = 'h17' if F(m, 2) >= 17 else '(by linarith)' + s+=f' · exact (distillFinite_{m} α hα {bound}).trans_lt distillFiniteBound_{m}\n' s+=f''' theorem distillFinite_scalar {{m : ℕ}} (hm : 5 ≤ m) (hm63 : m ≤ {FINITE_ROWS[-1]}) {{α : ℝ}} (hα : 0 < α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : diff --git a/tests/Localanalytic.lean b/tests/Localanalytic.lean new file mode 100644 index 0000000..1895ef8 --- /dev/null +++ b/tests/Localanalytic.lean @@ -0,0 +1,224 @@ +import Sendov.Analytic.OriginExact +import Sendov.Analytic.LowDegree +import Sendov.Boundary + +open Sendov + +example (s : Multiset ℝ) (hs : ∀ b ∈ s, 0 ≤ b) : + s.sum ^ 2 ≤ (s.card : ℝ) * (s.map (fun b => b ^ 2)).sum := by + induction s using Quotient.inductionOn with + | h l => + have h := Finset.sum_mul_sq_le_sq_mul_sq Finset.univ + (fun _ : Fin l.length => (1 : ℝ)) l.get + simpa [← List.sum_ofFn, List.ofFn_getElem_eq_map l (fun b : ℝ => b ^ 2)] using h + +open scoped Classical in +example (s : Multiset ℂ) (hs : ∀ w ∈ s, w ≠ 0) : + s.prod * (s.map (fun w => w⁻¹)).sum = sumEraseProd s := by + rw [sumEraseProd, ← Multiset.sum_map_mul_left] + refine congrArg Multiset.sum (Multiset.map_congr rfl ?_) + intro w hw + rw [← Multiset.prod_erase hw, mul_right_comm, mul_inv_cancel₀ (hs w hw), one_mul] + +example {w : ℂ} (hw : ‖w‖ ≤ 1) : + ‖w‖ * ‖w⁻¹ - (starRingEnd ℂ) w‖ ≤ 1 - ‖w‖ ^ 2 := by + rcases eq_or_ne w 0 with rfl | hne + · simp + · have hkey : w * (w⁻¹ - (starRingEnd ℂ) w) = ((1 - ‖w‖ ^ 2 : ℝ) : ℂ) := by + rw [mul_sub, mul_inv_cancel₀ hne, Complex.mul_conj, Complex.normSq_eq_norm_sq] + push_cast + rfl + rw [← norm_mul, hkey, Complex.norm_real, Real.norm_eq_abs, + abs_of_nonneg (sub_nonneg.2 (pow_le_one₀ (norm_nonneg w) hw))] + +example {v : ℂ} (hre : v.re = 1) (hv : ‖v‖ ≤ 1) : v = 1 := by + have him : v.im = 0 := by + have hsq := pow_le_one₀ (norm_nonneg v) hv (n := 2) + rw [Complex.sq_norm, Complex.normSq_apply] at hsq + nlinarith only [hsq, hre, sq_nonneg v.im] + apply Complex.ext <;> simp [hre, him] + +example (g f : ℂ → ℂ) : ∀ (s : Multiset ℂ), (∀ v ∈ s, ‖g v‖ ≤ 1) → + ‖sumEraseProdC s g f‖ ≤ sumEraseProdMap s (fun v => ‖f v‖) := by + classical + intro s hg + unfold sumEraseProdC sumEraseProdMap + refine (norm_multiset_sum_le _).trans ?_ + rw [Multiset.map_map] + refine Multiset.sum_map_le_sum_map _ _ ?_ + intro v hv + dsimp only [Function.comp_def] + rw [norm_mul, norm_prod_map] + exact mul_le_of_le_one_left (prod_map_norm_nonneg _ _) (hg v hv) + +example (a t : ℝ) : ∀ (q : Multiset ℂ), + HasDerivAt (Fprod a q) + (-(a : ℂ) * sumEraseProdC q id (fun v => 1 - (a : ℂ) * (t : ℂ) * v)) t := by + intro q + induction q using Multiset.induction_on with + | empty => + have he : Fprod a 0 = fun _ : ℝ => (1 : ℂ) := by funext s; simp [Fprod] + rw [he, sumEraseProdC_zero, mul_zero] + exact hasDerivAt_const t 1 + | cons v r ih => + have h0 : HasDerivAt (fun s : ℝ => (s : ℂ)) 1 t := Complex.ofRealCLM.hasDerivAt + have h1 : HasDerivAt (fun s : ℝ => 1 - (a : ℂ) * (s : ℂ) * v) (-((a : ℂ) * v)) t := by + simpa using ((h0.const_mul (a : ℂ)).mul_const v).const_sub 1 + have hfun : Fprod a (v ::ₘ r) + = fun s : ℝ => (1 - (a : ℂ) * (s : ℂ) * v) * Fprod a r s := by + funext s + simp only [Fprod, Multiset.map_cons, Multiset.prod_cons] + rw [hfun, sumEraseProdC_cons, id_eq] + apply (h1.mul ih).congr_deriv + simp only [Fprod] + ring + +example {a t : ℝ} (ha0 : 0 ≤ a) (ha1 : a ≤ 1) (ht0 : 0 ≤ t) {v : ℂ} + (hv : ‖v‖ ≤ 1) : ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖ ≤ lowX a t := by + have hb : (0 : ℝ) ≤ 1 - a ^ 2 := by nlinarith + have hcast : (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v + = ((a : ℝ) : ℂ) + ((t * (1 - a ^ 2) : ℝ) : ℂ) * v := by push_cast; ring + rw [hcast] + refine (norm_add_le _ _).trans ?_ + rw [norm_mul, Complex.norm_real, Complex.norm_real, Real.norm_eq_abs, Real.norm_eq_abs, + abs_of_nonneg ha0, abs_of_nonneg (mul_nonneg ht0 hb)] + simpa only [lowX, mul_comm t] using + add_le_add_right (mul_le_of_le_one_right (mul_nonneg ht0 hb) hv) a + +open Polynomial in +example (z : Multiset ℂ) : + ((z.map (fun w => X - C w)).prod).eval 0 = (-1) ^ z.card * z.prod := by + rw [eval_multiset_prod, Multiset.map_map] + simpa only [Function.comp_apply, eval_sub, eval_X, eval_C, zero_sub] using prod_map_neg z + +example {r x : ℝ} (hr : 0 < r) (h : r * x ≤ r) : x ≤ 1 := by + exact (mul_le_mul_iff_right₀ hr).mp (by simpa only [mul_one] using h) + +/-! Regression cases exercise the compiled declarations, including multiplicities and zeros. -/ + +example : (0 : Multiset ℂ).prod * ((0 : Multiset ℂ).map (fun w => w⁻¹)).sum + = sumEraseProd 0 := + prod_mul_sum_inv 0 (by simp) + +example : + (2 ::ₘ 2 ::ₘ 0 : Multiset ℂ).prod * + ((2 ::ₘ 2 ::ₘ 0 : Multiset ℂ).map (fun w => w⁻¹)).sum + = sumEraseProd (2 ::ₘ 2 ::ₘ 0) := + prod_mul_sum_inv _ (by simp) + +example : sumEraseProd (0 ::ₘ 1 ::ₘ 0 : Multiset ℂ) = 1 := by + norm_num [sumEraseProd_cons] + +example : sumEraseProd (0 ::ₘ 0 ::ₘ 1 ::ₘ 0 : Multiset ℂ) = 0 := by + norm_num [sumEraseProd_cons] + +example : ‖sumEraseProd (0 ::ₘ 1 ::ₘ 0 : Multiset ℂ)‖ ≤ 1 := + sumEraseProd_norm_le_one _ (by simp) (by simp) + +example : ‖sumEraseProd (1 ::ₘ 0 ::ₘ 0 : Multiset ℂ)‖ ≤ 1 := + sumEraseProd_norm_le_one _ (by simp) (by simp) + +example : + ((0 ::ₘ 1 ::ₘ 0 : Multiset ℂ).map (fun z => ‖z‖)).prod * + ((0 ::ₘ 1 ::ₘ 0 : Multiset ℂ).map (fun z => ‖z⁻¹ - (starRingEnd ℂ) z‖)).sum + ≤ 1 - (((0 ::ₘ 1 ::ₘ 0 : Multiset ℂ).map (fun z => ‖z‖)).prod) ^ 2 := + defect _ (by simp) + +example (s : Multiset ℝ) (hs : ∀ b ∈ s, 0 ≤ b) : + s.sum ^ 2 ≤ (s.card : ℝ) * (s.map (fun b => b ^ 2)).sum := + sq_sum_le_card_mul_sum_sq s hs + +example : (0 : Multiset ℝ).sum ^ 2 ≤ ((0 : Multiset ℝ).card : ℝ) * + ((0 : Multiset ℝ).map (fun b => b ^ 2)).sum := + sq_sum_le_card_mul_sum_sq 0 (by simp) + +example : (2 + 2 : ℝ) ^ 2 ≤ 2 * (2 ^ 2 + 2 ^ 2) := by + simpa using sq_sum_le_card_mul_sum_sq (2 ::ₘ 2 ::ₘ 0) (by simp) + +example : + sumEraseProdMap (1 ::ₘ 1 ::ₘ 0 : Multiset ℂ) (fun _ => 2) + = ((1 ::ₘ 1 ::ₘ 0 : Multiset ℂ).map (fun _ => (2 : ℝ))).esymm 1 := by + simpa using sumEraseProdMap_eq_esymm (1 ::ₘ 1 ::ₘ 0 : Multiset ℂ) + (fun _ => 2) (by simp) + +example : + ‖sumEraseProdC (1 ::ₘ 1 ::ₘ 0) (fun _ => 1) (fun _ => 0)‖ + ≤ sumEraseProdMap (1 ::ₘ 1 ::ₘ 0 : Multiset ℂ) (fun _ => ‖(0 : ℂ)‖) := + norm_sumEraseProdC_le (fun _ => 1) (fun _ => 0) (1 ::ₘ 1 ::ₘ 0) (by simp) + +example (a t : ℝ) : HasDerivAt (Fprod a 0) 0 t := by + simpa using hasDerivAt_Fprod a t 0 + +example : HasDerivAt (Fprod 1 (1 ::ₘ 1 ::ₘ 0)) 0 1 := by + simpa [sumEraseProdC_cons] using hasDerivAt_Fprod 1 1 (1 ::ₘ 1 ::ₘ 0) + +example : ‖sumEraseProd (0 ::ₘ 0 : Multiset ℂ)‖ ≤ 2 := by + simpa [show (2 : ℝ) - 1 = 1 by norm_num] using + Jsum_estimate (n := 2) (a := 2) (x := 1) (y := 0) + (z := 0 ::ₘ 0) (q := 1 ::ₘ 0) + (by decide) (by simp) (by simp) (by simp) (by norm_num) (by norm_num) + +example : + ‖(1 ::ₘ 0 : Multiset ℂ).prod * sumEraseProd (1 ::ₘ 0) + - ((3 : ℂ) * (2 - 1) - 2 * (1 + 0 * Complex.I)) * + ((1 ::ₘ 0 : Multiset ℂ).prod * (1 ::ₘ 0 : Multiset ℂ).prod)‖ + ≤ (2 : ℝ) / (2 - 1) * + (1 - (‖(1 ::ₘ 0 : Multiset ℂ).prod‖ * ‖(1 ::ₘ 0 : Multiset ℂ).prod‖) ^ 2) := + Jsum_estimate (n := 2) (a := 3) (x := 1) (y := 0) + (z := 1 ::ₘ 0) (q := 1 ::ₘ 0) + (by decide) (by simp) (by simp) (by simp) (by norm_num) (by norm_num) + +example : (0 : Multiset ℝ).prod ≤ + ((0 : Multiset ℝ).sum / (0 : Multiset ℝ).card) ^ (0 : Multiset ℝ).card := + Sendov.Multiset.prod_le_mean_pow 0 (by simp) + +example (k : ℕ) (hk : 0 < k) : + (Multiset.replicate k (0 : ℝ)).esymm (k - 1) + ≤ k * ((Multiset.replicate k (0 : ℝ)).sum / k) ^ (k - 1) := by + simpa using Sendov.Multiset.esymm_card_pred_le (Multiset.replicate k (0 : ℝ)) + (by + intro b hb + obtain ⟨_, rfl⟩ := Multiset.mem_replicate.mp hb + exact le_rfl) + (by + intro h + have hc := congrArg Multiset.card h + simp only [Multiset.card_replicate, Multiset.card_zero] at hc + omega) + +example {a : ℝ} (ha0 : 0 < a) (ha1 : a < 1) : + ∀ m ∈ Finset.Icc 1 4, lowJ m a < 1 := by + intro m hm + exact lowJ_lt_one ha0 ha1 (Finset.mem_Icc.mp hm).1 (Finset.mem_Icc.mp hm).2 + +example (t : ℝ) (ht : 0 ≤ t) : ‖(1 : ℂ) + (t : ℂ) * (1 - (1 : ℂ) ^ 2)‖ ≤ lowX 1 t := by + simpa using norm_le_lowX (a := 1) (v := 1) (by norm_num) (by norm_num) ht (by norm_num) + +example : 2 * (1 : ℝ) * 5 / (5 - 1) ≤ ‖Worigin 5 1 1 0‖ := + grow (by decide) (by norm_num) (by norm_num) + +example : + ((1 ::ₘ 0 : Multiset ℂ).map (fun v => v.re)).sum = (2 - 1 : ℝ) * 1 + ∧ (1 : ℝ) ^ 2 + 0 ^ 2 ≤ 1 := + xy_bounds (n := 2) (by decide) (by simp) (by simp) (by norm_num) + +example : (1 : ℝ) / 2 ≤ (((1 : ℂ) - (-1))⁻¹).re := + half_le_re_inv_one_sub (by norm_num) (by norm_num) + +open Polynomial in +example {p : ℂ[X]} (hdeg : p.natDegree = 2) + (hroots : ∀ w ∈ p.roots, ‖w‖ ≤ 1) (hp1 : p.eval 1 = 0) : + ∃ ζ : ℂ, (derivative p).eval ζ = 0 ∧ ‖ζ - 1‖ ≤ 1 := + sendov_boundary_one (by decide) hdeg hroots hp1 + +open Polynomial in +example {p : ℂ[X]} (hdeg : p.natDegree = 1) + (hroots : ∀ w ∈ p.roots, ‖w‖ ≤ 1) {a : ℂ} (hpa : p.eval a = 0) : + ∃ z : Multiset ℂ, z.card = 0 ∧ (∀ w ∈ z, ‖w‖ ≤ 1) ∧ + p = C p.leadingCoeff * ((X - C a) * (z.map (fun w => X - C w)).prod) := + exists_root_multiset (by decide) hdeg hroots hpa + +open Polynomial in +example : ∃ ζ : ℂ, (derivative ((X - C 1) ^ 2 : ℂ[X])).eval ζ = 0 ∧ ‖ζ - 1‖ < 1 := by + refine ⟨1, ?_, by norm_num⟩ + simp [derivative_pow, derivative_sub, derivative_X] diff --git a/tests/Localcommon.lean b/tests/Localcommon.lean new file mode 100644 index 0000000..c117525 --- /dev/null +++ b/tests/Localcommon.lean @@ -0,0 +1,112 @@ +import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.DistillationHyperbolic +import Sendov.Common.DistillationBounds + +open Sendov + +example {s c : ℝ} (hs : 0 < s) (hc : 0 < c) : + (∫ t in (0 : ℝ)..1 / c, t * (1 - c * t) ^ s) = + 1 / (c ^ 2 * ((s + 1) * (s + 2))) := + integral_chord_lin hs hc + +example {s c : ℝ} (hs : 0 < s) (hc : 0 < c) : + (∫ t in (0 : ℝ)..1 / c, t ^ 3 * (1 - c * t) ^ s) = + 6 / (c ^ 4 * ((s + 1) * (s + 2) * (s + 3) * (s + 4))) := + integral_chord_pow hs hc + +-- The split covers a vertex at one and a vertex beyond the integration interval. +example {r : ℝ} (hr : 0 < r) (k : ℕ) : + (∫ t in (0 : ℝ)..1, t ^ k * QQ 1 1 t ^ r) ≤ + (∫ t in (0 : ℝ)..1, t ^ k * (1 - t) ^ r) + QQ 1 1 1 ^ r / (k + 1) := by + simpa only [div_one, one_mul] using + integral_le_tail_gen (c := 1) (A := 1) (by norm_num) (by norm_num) (by norm_num) hr k + +example {r : ℝ} (hr : 0 < r) (k : ℕ) : + (∫ t in (0 : ℝ)..1, t ^ k * QQ (1 / 2) (1 / 4) t ^ r) ≤ + (∫ t in (0 : ℝ)..2, t ^ k * (1 - (1 / 2) * t) ^ r) + + QQ (1 / 2) (1 / 4) 1 ^ r / (k + 1) := by + convert integral_le_tail_gen (c := 1 / 2) (A := 1 / 4) + (by norm_num) (by norm_num) (by norm_num) hr k using 1 + norm_num + +example {c A l r : ℝ} (hA : 0 ≤ A) (hlr : l < r) : + QQ c A l ≤ ((r - l) * QQ c A l + (l - l) * QQ c A r) / (r - l) := + QQ_le_secant hA hlr ⟨le_rfl, hlr.le⟩ + +example : 0 ≤ cubicPolarEnvelope 0 := cubicPolarEnvelope_nonneg le_rfl + +example {α : ℝ} (hα : 0 ≤ α) : cubicPolarEnvelope α ≤ α / (α + 3) := + cubicPolarEnvelope_le_linear hα + +example {m : ℝ} (hm : 5 ≤ m) : + ContinuousWithinAt (distillT0 m) (Set.Icc 0 (m / 2)) 0 := + distillT0_continuousOn hm 0 ⟨le_rfl, by linarith⟩ + +example {m : ℝ} (hm : 5 ≤ m) : + ContinuousWithinAt (distillT2 m) (Set.Icc 0 (m / 2)) (m / 2) := + distillT2_continuousOn hm (m / 2) ⟨by linarith, le_rfl⟩ + +example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : + deriv (distillT0 m) α ≤ 0 ↔ distillCritical0 m α ≤ 0 := + distillT0_deriv_nonpos_iff hm hα hαm + +example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : + deriv (distillT1 m) α ≤ 0 ↔ 0 ≤ distillCritical1 m α := + distillT1_deriv_nonpos_iff hm hα hαm + +example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : + deriv (distillT2 m) α ≤ 0 ↔ 0 ≤ distillCritical2 m α := + distillT2_deriv_nonpos_iff hm hα hαm + +-- Neither square recovery nor the zero-base case requires a nonnegative coefficient. +example {a c : ℝ} (hc : 0 ≤ c) (hsq : a ^ 2 ≤ c ^ 2) : + a * (0 : ℝ) ^ (((3 : ℝ) - 3) / 2) ≤ c := by + apply distillMulRpow_le_of_sq 0 (by norm_num) hc (by norm_num) + simpa only [pow_zero, mul_one] using hsq + +example {a c : ℝ} (hc : 0 ≤ c) : + a * (0 : ℝ) ^ (((4 : ℝ) - 3) / 2) ≤ c := by + apply distillMulRpow_le_of_sq 1 (by norm_num) hc (by norm_num) + simpa only [pow_one, mul_zero] using sq_nonneg c + +example {f : ℝ → ℝ} {b : ℝ} (hc : ContinuousOn f (Set.Icc 0 0)) + (hb : f 0 ≤ b) : f 0 ≤ b := by + apply distillPeak_le (l := 0) (r := 0) (d := 0) le_rfl le_rfl le_rfl hc + · simp + · simp + · simp + · simpa using hb + · exact ⟨le_rfl, le_rfl⟩ + +example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α ≤ m) : + scalarObstruction m α (cubicPolarEnvelope α) ≤ + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α := + distillScalar_le_majorant hm hα hαm + +example : Filter.Tendsto (fun z => Real.sinh z / z) + (nhdsWithin 0 {(0 : ℝ)}ᶜ) (nhds 1) := by + simpa [slope_fun_def, div_eq_inv_mul] using (Real.hasDerivAt_sinh 0).tendsto_slope + +example : Real.sinh 0 ≤ 0 * Real.exp + ((7 / 8 : ℝ) * (Real.sqrt (9 + (8 / 7 : ℝ) * 0 ^ 2) - 3)) := + DistillationHyperbolic.sinh_le_mul_exp le_rfl (by norm_num) + +example : Real.log (Real.sinh 10 / 10) ≤ + (7 / 8 : ℝ) * (Real.sqrt (9 + (8 / 7 : ℝ) * 10 ^ 2) - 3) := + DistillationHyperbolic.log_sinh_div_le (by norm_num) le_rfl + +example {m : ℝ} (hm : 64 ≤ m) : distillT2 m 0 = 0 := distillT2_zero hm + +example {m : ℝ} (hm : 64 ≤ m) : + distillEBudget m + distillT0 m 0 + distillT1 m 0 + distillT2 m 0 ≤ + distillEBudget 64 + distillT0 64 0 + distillT1 64 0 + distillT2 64 0 := + distillComponents_le_64 hm le_rfl (by norm_num) + +example {m : ℝ} (hm : 64 ≤ m) : + scalarObstruction m 17 (cubicPolarEnvelope 17) < 199 / 200 := + distillScalar_lt_199_200 hm (by norm_num) le_rfl + +example {n : ℕ} (hn : 6 ≤ n) {α : ℝ} (hα : 0 < α) (h17 : α ≤ 17) + (hhalf : 2 * α ≤ M n) : + scalarObstruction (M n) α (cubicPolarEnvelope α) < 1 := + distillScalar_lt_one hn hα h17 hhalf diff --git a/tests/Localgenerators.lean b/tests/Localgenerators.lean new file mode 100644 index 0000000..f20d611 --- /dev/null +++ b/tests/Localgenerators.lean @@ -0,0 +1,88 @@ +import Sendov.Common.BernsteinList +import Sendov.Common.DistillationFinite +import Sendov.Common.Sinh + +namespace Localgenerators + +open BernsteinCert + +example (a : Cert) {x y : ℝ} (hx : 0 ≤ x) (hy : 0 ≤ y) + (hxy : 0 < x + y) (hl : a.edge true = true) (hr : a.edge false = true) : + 0 < a.eval x y := by + rcases eq_or_lt_of_le hx with rfl | hx + · exact a.pos_left le_rfl (by simpa only [zero_add] using hxy) hl + · exact a.pos_right hx hy hr + +example {lo hi x : ℝ} (hab : lo < hi) : 0 < (x - lo) + (hi - x) := by + simpa only [sub_add_sub_cancel'] using sub_pos.mpr hab + +example : (coeffTree [] 0).edge true = false ∧ + (coeffTree [] 0).edge false = false := by decide + +example : (coeffTree [1] 0).edge true = true ∧ + (coeffTree [1] 0).edge false = true := by decide + +example : (coeffTree [0, 1] 0).edge true = false ∧ + (coeffTree [1, 0] 0).edge false = false := by decide + +example : (coeffTree [2, 3, 5] 0).eval 2 3 = 56 := by + norm_num [coeffTree, Cert.eval] + +example (x : ℝ) : 0 < (coeffTree [1] 0).eval x (-x) := by + norm_num [coeffTree, Cert.eval] + +example (x : ℝ) (hx : x ∈ Set.Icc 0 1) : 0 < x ^ 2 + (1 - x) ^ 2 := by + refine coeffs_pos [1, 0, 1] (lo := 0) (hi := 1) (s := 1) + (by norm_num) (by norm_num) hx (by decide) (by decide) ?_ + norm_num only [coeffTree, Cert.eval, List.length_cons, List.length_nil] + ring + +example : 0 < (coeffTree [2, 0, 3] 0).eval 0 1 := + (coeffTree [2, 0, 3] 0).pos (by norm_num) (by norm_num) + (by norm_num) (by decide) (by decide) + +example : 0 < (coeffTree [2, 0, 3] 0).eval 1 0 := + (coeffTree [2, 0, 3] 0).pos (by norm_num) (by norm_num) + (by norm_num) (by decide) (by decide) + +example (x y : ℝ) (hx : 0 ≤ x) (hy : 0 ≤ y) (hxy : 0 < x + y) : 0 < x + y := by + have hid : 1 * (x + y) = x + y := one_mul _ + bernstein_cert x y using hid + +example (x y : ℝ) : (x + y) ^ 2 = y ^ 2 + 2 * x * y + x ^ 2 := by + bernstein_ring x y + +example (x y : ℝ) : x + y + 1 = 1 + (x + y) := by + fail_if_success bernstein_ring x y + ring + +example (x y : ℝ) : y - x = -1 * x + y := by + fail_if_success bernstein_ring x y + ring + +example {m : ℕ} (hm : 5 ≤ m) (hm63 : m ≤ 63) {α : ℝ} (hα : 0 ≤ α) + (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : + Sendov.distillEBudget m + Sendov.distillT0 m α + Sendov.distillT1 m α + + Sendov.distillT2 m α < 199 / 200 := + Sendov.distillFinite_components hm hm63 hα hαm h17 + +example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : + Sendov.distillT0 64 α ≤ 217 / 1000 := + Sendov.CriticalRow64.component0 α hα h17 + +example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : + Sendov.distillT1 64 α ≤ 37 / 1000 := + Sendov.CriticalRow64.component1 α hα h17 + +example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : + Sendov.distillT2 64 α ≤ 317 / 1000 := + Sendov.CriticalRow64.component2 α hα h17 + +example : Real.sinh 0 ≤ 0 * Real.exp (Real.sqrt (0 ^ 2 + 9) - 3) := + Sendov.sinh_le_mul_exp le_rfl + +example {h : ℝ} (hh : 0 < h) : + Real.log (Real.sinh h / h) ≤ Real.sqrt (h ^ 2 + 9) - 3 := + Sendov.log_sinh_div_le hh + +end Localgenerators diff --git a/tests/Localreduction.lean b/tests/Localreduction.lean new file mode 100644 index 0000000..d6f5f64 --- /dev/null +++ b/tests/Localreduction.lean @@ -0,0 +1,91 @@ +import Sendov +import Solution + +open Sendov Real + +-- Cancellation must remain valid at alpha = 0; no division by alpha is justified. +example {n : ℕ} (hn : 2 ≤ n) (x t : ℝ) : + polarKernel (M n) 0 (QQ x 1 1) t = QQ x 1 t := by + simpa using polarKernel_actual (a := 1) (x := x) (α := 0) hn (by simp) t + +example {n : ℕ} (hn : 2 ≤ n) (x : ℝ) : + scalarObstruction (M n) 0 (QQ x 1 1) = 1 / (2 * M n) := by + simpa using scalarObstruction_actual_eq (a := 1) (x := x) (α := 0) hn (by simp) + +-- The opposite feasibility endpoint has a zero origin coefficient. +example {n : ℕ} (hn : 2 ≤ n) (t : ℝ) : + polarKernel (M n) (M n / 2) 1 t = 1 := by + simpa [QQ] using polarKernel_actual (a := 0) (x := 0) (α := M n / 2) hn (by simp) t + +-- The chord bound covers both signs of x without a sign case split. +example {a : ℝ} (ha : 0 < a) (ha1 : a < 1) : + 0 < 1 - a * (-1) * 1 ∧ 0 < 1 - a * 1 * 1 := by + constructor + · exact one_sub_mul_pos ha ha1 (by norm_num) (by norm_num) le_rfl + · exact one_sub_mul_pos ha ha1 (by norm_num) (by norm_num) le_rfl + +example (a x : ℝ) : + Ppolar a x 0 ≤ 1 + (1 - a ^ 2) * (-1 + (2 - QQ (a * x) (a ^ 2) 1) * 0) := + Ppolar_le_lin a x le_rfl (by norm_num) + +example (a x : ℝ) : + Ppolar a x 1 ≤ 1 + (1 - a ^ 2) * (-1 + (2 - QQ (a * x) (a ^ 2) 1) * 1) := + Ppolar_le_lin a x (by norm_num) le_rfl + +-- Bernoulli's public interface does not require Q to be nonnegative. +example {p : ℝ} (hp : 1 ≤ p) : + (2 + (-1) : ℝ) ^ p ≤ (2 : ℝ) ^ p + p * (-1) * (2 + (-1) : ℝ) ^ (p - 1) := + rpow_add_le_of_one_le (by norm_num) (by norm_num) hp + +example : exp (-1) ≤ 1 / (1 - (-1)) := + exp_le_one_div_one_sub (by norm_num) + +example : exp 0 ≤ 1 / (1 - 0) := + exp_le_one_div_one_sub (by norm_num) + +example : scalarObstruction 5 17 0 ≤ scalarObstruction 5 17 (99 / 100) := + scalarObstruction_mono_eta (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) + +example : (17 : ℝ) * (1 - cubicPolarEnvelope 17 / 2) < 10 := + cubicPolarEnvelope_center_lt_ten (by norm_num) le_rfl + +example {α : ℝ} (hα : 0 < α) + (h : 1 ≤ ∫ t in (0 : ℝ)..1, exp (α * (-1 + (2 - 2) * t))) : False := + (lt_irrefl (2 : ℝ)) (beta_lt_two hα h) + +open Lean in +run_elab do + let names : List Name := [ + `Sendov.M, `Sendov.A, + `Sendov.Ppolar, `Sendov.Ppolar_eq, `Sendov.Ppolar_nonneg, + `Sendov.continuous_Ppolar, `Sendov.A_eq_sq, `Sendov.mul_eq_c, + `Sendov.alpha_pos, `Sendov.alpha_le_half, + `Sendov.Ppolar_le_lin, `Sendov.Ppolar_rpow_le, `Sendov.polar_exp, + `Sendov.integral_exp_mul, `Sendov.integral_exp_eq', `Sendov.integral_exp_eq, + `Sendov.beta_lt_two, `Sendov.beta_le, `Sendov.log_le_alpha_mul, + `Sendov.rpow_add_le_of_one_le, `Sendov.one_sub_mul_pos, `Sendov.beta_split, + `Sendov.integral_beta_split, `Sendov.one_le_of_origin, + `Sendov.integral_polarKernel_nonneg, `Sendov.scalarObstruction_prefactor_nonneg, + `Sendov.scalarObstruction_mono_eta, `Sendov.polarKernel_actual, + `Sendov.scalarObstruction_actual_eq, `Sendov.one_le_scalarObstruction_of_one_le, + `Sendov.one_le_scalarObstruction_of_origin, `Sendov.actualEta_mem_Ico_of_polar, + `Sendov.one_le_scalarObstruction_of_polar_origin, + `Sendov.quartic_le_exp, `Sendov.log_le_div_exp_one, `Sendov.exp_le_one_div_one_sub, + `Sendov.log_seventeen_ge, `Sendov.tail_poly_bound, `Sendov.alpha_le_seventeen, + `Sendov.cubicPolarEnvelope_center_lt_ten, `Sendov.cubicPolarEnvelope_quadratic_pos, + `Sendov.polar_le_log_sinh, `Sendov.eta_lt_cubicPolarEnvelope, + `Sendov.actualEta_lt_cubicPolarEnvelope_of_polar, + `Sendov.cubicScalar_constraints_of_polar_origin, `Sendov.polar_origin_incompatible, + `Sendov.sendov_interior, `Sendov.sendov_center, `Sendov.sendov_interior_real, + `Sendov.rotate, `Sendov.eval_rotate, `Sendov.natDegree_rotate, + `Sendov.derivative_rotate, `Sendov.eval_derivative_rotate, `Sendov.rotate_rotate_inv, + `Sendov.roots_rotate, `Sendov.phelps_rodriguez, `Sendov.sendov, + `SendovConjecture.sendov, `SendovConjecture.phelps_rodriguez] + for name in names do + let info ← getConstInfo name + logInfo m!"TYPE {name}: {repr info.type}" + for name in [`Sendov.M, `Sendov.A, `SendovConjecture.sendov, + `SendovConjecture.phelps_rodriguez] do + let info ← getConstInfo name + logInfo m!"VALUE {name}: {repr (info.value?)}" diff --git a/tests/expected.json b/tests/expected.json index bfbdd63..798c667 100644 --- a/tests/expected.json +++ b/tests/expected.json @@ -1,6 +1,6 @@ { "distillation": { - "Sendov/Common/DistillationFinite.lean": "e5ae2b52fbda2e65368248e34647d4c9516036a9ab1f2e7c0443f045fc4e0cd2", + "Sendov/Common/DistillationFinite.lean": "4b5a88e50e801126c2de6127142a8a346182e6a7258fb7af1d8497c60ccef11f", "Sendov/DistillationFinite/Rows13_20.lean": "7cfbd3aac6f3639f5e8d0ecd9773386c000aa27479d2c75a5d196e252e812110", "Sendov/DistillationFinite/Rows21_28.lean": "4259d6f25898cdee240186ef412cc47881909fe1d91ff613f46e116a642edd68", "Sendov/DistillationFinite/Rows29_36.lean": "f3dfd178a770b4e1101f54f9bd1e82f9ed3e36cedc2960adc676a71b8d680a49", diff --git a/tests/test_generator_core.py b/tests/test_generator_core.py index 94cc166..b097937 100644 --- a/tests/test_generator_core.py +++ b/tests/test_generator_core.py @@ -52,7 +52,9 @@ def test_k64_generator_covers_59_finite_cases_and_one_shared_base(self): self.assertFalse((output / 'Sendov/DistillationFinite/Row64.lean').exists()) aggregate = (output / 'Sendov/Common/DistillationFinite.lean').read_text() cases = [f' · exact (distillFinite_{m} α hα (by linarith)).trans_lt ' - f'distillFiniteBound_{m}' for m in range(5, 64)] + f'distillFiniteBound_{m}' for m in range(5, 34)] + cases += [f' · exact (distillFinite_{m} α hα h17).trans_lt ' + f'distillFiniteBound_{m}' for m in range(34, 64)] self.assertEqual([line for line in aggregate.splitlines() if line.startswith(' · exact (distillFinite_')], cases) self.assertIn('(hm63 : m ≤ 63)', aggregate) From 663a56df2921e93f9dceb7fa9d0ef23af7ce4702 Mon Sep 17 00:00:00 2001 From: Methode Date: Sun, 13 Sep 2026 05:21:13 -0700 Subject: [PATCH 09/24] refactor(sendov): combine earlier tail with cheaper certificate identities --- README.md | 14 +- Sendov/Common/BernsteinList.lean | 31 ++ Sendov/Common/DistillationBounds.lean | 10 +- Sendov/Common/DistillationCritical.lean | 3 +- Sendov/Common/DistillationFinite.lean | 11 +- Sendov/Common/DistillationHyperbolic.lean | 15 +- Sendov/DistillationFinite/Rows13_20.lean | 288 ++++++------- Sendov/DistillationFinite/Rows21_28.lean | 288 ++++++------- Sendov/DistillationFinite/Rows29_36.lean | 288 ++++++------- Sendov/DistillationFinite/Rows37_44.lean | 288 ++++++------- Sendov/DistillationFinite/Rows45_52.lean | 222 +++++----- Sendov/DistillationFinite/Rows53_60.lean | 168 ++++---- Sendov/DistillationFinite/Rows5_12.lean | 282 ++++++------- Sendov/DistillationFinite/Rows61_61.lean | 96 +++++ Sendov/DistillationFinite/Rows61_64.lean | 378 ------------------ Sendov/LargeDegree/DistillationTail.lean | 100 +++-- Sendov/LargeDegree/DistillationTailBound.lean | 16 +- Sendov/Reduction/Alpha17.lean | 24 +- Sendov/Reduction/Simplified.lean | 12 +- data/README.md | 6 +- data/paper_certificate_table.json | 111 ----- docs/design.md | 33 +- docs/getting-started.md | 6 +- scripts/GENERATORS.md | 8 +- scripts/axioms.lean | 6 +- scripts/bundle_rows.py | 4 +- scripts/distillation_data.py | 8 +- scripts/gen_distillation.py | 12 +- tests/BoundaryConsumer.lean | 13 +- tests/EarlierTail.lean | 41 +- tests/Localcertificates.lean | 165 ++++++++ tests/Localcommon.lean | 10 +- tests/Localgenerators.lean | 16 +- tests/Localhotspots.lean | 147 +++++++ tests/Localmathematics.lean | 59 +++ tests/expected.json | 20 +- tests/test_axiom_audit.py | 8 +- tests/test_bundle_rows.py | 16 +- tests/test_generator_core.py | 60 ++- tests/test_generators.py | 12 +- 40 files changed, 1689 insertions(+), 1606 deletions(-) create mode 100644 Sendov/DistillationFinite/Rows61_61.lean delete mode 100644 Sendov/DistillationFinite/Rows61_64.lean create mode 100644 tests/Localcertificates.lean create mode 100644 tests/Localhotspots.lean create mode 100644 tests/Localmathematics.lean diff --git a/README.md b/README.md index fca8b1a..a70ae63 100644 --- a/README.md +++ b/README.md @@ -35,13 +35,15 @@ trusted facts.[2] | Complete contradiction | [`DistillationBounds`](Sendov/Common/DistillationBounds.lean), [`Reduction/Main`](Sendov/Reduction/Main.lean) | The convention is **`m = n - 1`**. The final degree split now uses the finite -proof for `5 ≤ m ≤ 63` (through `n=64`), then the real-parameter tail for -`m ≥ 64` (from `n=65`). The latter reuses the existing row-64 certificate +proof for `5 ≤ m ≤ 60` (through `n=61`), then the real-parameter tail for +`m ≥ 61` (from `n=62`). The latter reuses the existing row-61 certificate to prove a bound of `<199/200`, which is sufficient for the scalar `<1`. -Exactly 60 unchanged certificate records, `5 ≤ m ≤ 64`, are retained. The finite -aggregate consumes 59 cases; the tail consumes row 64 from the shared final -group `Rows61_64`. Rows 65–81 and the old `<2/3` tail interfaces are retired. -There is no separate duplicate row-64 module or second certificate representation. +Exactly 57 unchanged certificate records, `5 ≤ m ≤ 61`, are retained. The finite +aggregate consumes 56 cases; the tail consumes row 61 from the shared final +group `Rows61_61`. Rows 62–81 and the old `<2/3` tail interfaces are retired. +There is no separate duplicate row-61 module or second certificate representation. +The earlier tail uses the rational fourth-power envelope cap `(21/22)^4` +to retain stronger logarithmic decay, with the same rational-component alpha split. Each finite case uses the complete critical polynomials of degrees **7, 7, 4**. Exact Bernstein identities prove derivative signs on the full outer intervals; diff --git a/Sendov/Common/BernsteinList.lean b/Sendov/Common/BernsteinList.lean index d489664..3981eda 100644 --- a/Sendov/Common/BernsteinList.lean +++ b/Sendov/Common/BernsteinList.lean @@ -8,6 +8,9 @@ The raw list `[c₀, …, cₙ]` denotes `∑ cᵢ X^i Y^(n-i)` (no extra binomi factors). Natural coefficients give nonnegativity; both axis supports are checked by the existing `Cert.edge`. Empty data denotes zero and cannot have either support. Every application still supplies a complete polynomial identity proved in Lean. +`coeffTree_eval_cons` factors the existing evaluation into Horner form, so a +single `ring1` can check that identity after structural simplification. No new +certificate representation or positivity checker is involved. -/ namespace BernsteinCert @@ -18,6 +21,34 @@ def coeffTree : List ℕ → ℕ → Cert | [c], i => .mono c i 0 | c :: d :: cs, i => .add (.mono c i (cs.length + 1)) (coeffTree (d :: cs) (i + 1)) +/-- Factor the common X power without expanding either coordinate. -/ +theorem coeffTree_eval_shift (cs : List ℕ) (i : ℕ) (x y : ℝ) : + (coeffTree cs i).eval x y = x ^ i * (coeffTree cs 0).eval x y := by + induction cs generalizing i with + | nil => simp [coeffTree, Cert.eval] + | cons c cs ih => + cases cs with + | nil => simp [coeffTree, Cert.eval, mul_comm] + | cons d cs => + simp only [coeffTree, Cert.eval, ih (i + 1), ih 1] + ring + +/-- One Horner step for the complete supplied coefficient list. +Rewriting with this identity shares X powers; it does not replace the data or +assume an identity for the polynomial being certified. -/ +theorem coeffTree_eval_cons (c : ℕ) (cs : List ℕ) (x y : ℝ) : + (coeffTree (c :: cs) 0).eval x y = + (c : ℝ) * y ^ cs.length + x * (coeffTree cs 0).eval x y := by + cases cs with + | nil => simp [coeffTree, Cert.eval] + | cons d cs => + simp only [coeffTree, Cert.eval, coeffTree_eval_shift (d :: cs) 1, + List.length_cons, pow_zero, pow_one, mul_one] + +theorem coeffTree_eval_nil (x y : ℝ) : + (coeffTree [] 0).eval x y = 0 := by + simp [coeffTree, Cert.eval] + /-- Closed-interval positivity from raw coefficients; no new positivity checker. The interval, scale, two endpoint supports and full identity are explicit obligations. -/ theorem coeffs_pos (cs : List ℕ) {lo hi s P x : ℝ} diff --git a/Sendov/Common/DistillationBounds.lean b/Sendov/Common/DistillationBounds.lean index 7ca452d..353a48f 100644 --- a/Sendov/Common/DistillationBounds.lean +++ b/Sendov/Common/DistillationBounds.lean @@ -5,9 +5,9 @@ import Sendov.LargeDegree.DistillationTailBound # The complete scalar upper bound The original degree is `n`; the scalar parameter is `m = n - 1`. -The scalar consumer uses finite rows for `5 ≤ m ≤ 63` and the real-degree -tail based on the existing row 64 for `m ≥ 64`. These disjoint ranges cover -every natural `m ≥ 5`; exactly the 60 records from 5 through 64 are retained. +The scalar consumer uses finite rows for `5 ≤ m ≤ 60` and the real-degree +tail based on the existing row 61 for `m ≥ 61`. These disjoint ranges cover +every natural `m ≥ 5`; exactly the 57 records from 5 through 61 are retained. -/ namespace Sendov @@ -22,9 +22,9 @@ theorem distillScalar_lt_one {n : ℕ} (hn : 6 ≤ n) {α : ℝ} simp [M] have hm : 5 ≤ n - 1 := by omega rw [← hM] at hhalf ⊢ - by_cases hfinite : n - 1 < 64 + by_cases hfinite : n - 1 < 61 · exact (distillFinite_scalar hm (by omega) hα (by linarith) h17).trans (by norm_num) - · have hlarge : (64 : ℝ) ≤ (n - 1 : ℕ) := by exact_mod_cast (show 64 ≤ n - 1 by omega) + · have hlarge : (61 : ℝ) ≤ (n - 1 : ℕ) := by exact_mod_cast (show 61 ≤ n - 1 by omega) exact (distillScalar_lt_199_200 hlarge hα h17).trans (by norm_num) end Sendov diff --git a/Sendov/Common/DistillationCritical.lean b/Sendov/Common/DistillationCritical.lean index a0b56da..ade090c 100644 --- a/Sendov/Common/DistillationCritical.lean +++ b/Sendov/Common/DistillationCritical.lean @@ -95,8 +95,7 @@ lemma distillNode_compact {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : lemma distillD_eq {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : distillD m α = 50 * m * (α + 3) ^ 3 * (1 - distillNode m α) := by rw [distillNode_compact hm hα, distillD] - have ht : α + 3 ≠ 0 := by linarith - field_simp [ht, hm.ne'] + rw [mul_one_sub, mul_div_cancel₀ _ (by positivity)] lemma distillN_pos {α : ℝ} (hα : 0 ≤ α) : 0 < distillN α := by unfold distillN diff --git a/Sendov/Common/DistillationFinite.lean b/Sendov/Common/DistillationFinite.lean index f0a5c20..e88bb36 100644 --- a/Sendov/Common/DistillationFinite.lean +++ b/Sendov/Common/DistillationFinite.lean @@ -5,13 +5,13 @@ import Sendov.DistillationFinite.Rows29_36 import Sendov.DistillationFinite.Rows37_44 import Sendov.DistillationFinite.Rows45_52 import Sendov.DistillationFinite.Rows53_60 -import Sendov.DistillationFinite.Rows61_64 +import Sendov.DistillationFinite.Rows61_61 /-! Exact finite-domain critical-bracket closure. Fixed original paper budgets; see DistillationCriticalFinite for attribution. No sampled truth or global T grid. -/ namespace Sendov -theorem distillFinite_components {m : ℕ} (hm : 5 ≤ m) (hm63 : m ≤ 63) +theorem distillFinite_components {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) {α : ℝ} (hα : 0 ≤ α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := by interval_cases m @@ -71,15 +71,12 @@ theorem distillFinite_components {m : ℕ} (hm : 5 ≤ m) (hm63 : m ≤ 63) · exact (distillFinite_58 α hα h17).trans_lt distillFiniteBound_58 · exact (distillFinite_59 α hα h17).trans_lt distillFiniteBound_59 · exact (distillFinite_60 α hα h17).trans_lt distillFiniteBound_60 - · exact (distillFinite_61 α hα h17).trans_lt distillFiniteBound_61 - · exact (distillFinite_62 α hα h17).trans_lt distillFiniteBound_62 - · exact (distillFinite_63 α hα h17).trans_lt distillFiniteBound_63 -theorem distillFinite_scalar {m : ℕ} (hm : 5 ≤ m) (hm63 : m ≤ 63) +theorem distillFinite_scalar {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) {α : ℝ} (hα : 0 < α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : scalarObstruction m α (cubicPolarEnvelope α) < 199 / 200 := by have hmR : (5 : ℝ) ≤ m := by exact_mod_cast hm exact (distillScalar_le_majorant hmR hα (by linarith)).trans_lt - (distillFinite_components hm hm63 hα.le hαm h17) + (distillFinite_components hm hm60 hα.le hαm h17) end Sendov diff --git a/Sendov/Common/DistillationHyperbolic.lean b/Sendov/Common/DistillationHyperbolic.lean index feedf4e..0ae39b5 100644 --- a/Sendov/Common/DistillationHyperbolic.lean +++ b/Sendov/Common/DistillationHyperbolic.lean @@ -333,9 +333,9 @@ theorem pade_nonneg {x : ℝ} (hx : 0 ≤ x) : have he : exp x ≠ 0 := (exp_pos x).ne' have hid : f0 x = 2 * exp x * (x ^ 2 * A x * sinh x - D x * (x * cosh x - sinh x)) := by - simp only [f0, A, D, sinh_eq, cosh_eq, exp_neg, - show exp (2 * x) = exp x ^ 2 by simp [← exp_nat_mul]] + simp only [sinh_eq, cosh_eq, exp_neg] field_simp + simp only [f0, A, D, show exp (2 * x) = exp x ^ 2 by simp [← exp_nat_mul]] ring rw [hid] at h exact nonneg_of_mul_nonneg_right h (by positivity) @@ -390,11 +390,16 @@ theorem sqrt_mul_sub_le {x : ℝ} (hx : 0 ≤ x) (hx10 : x ≤ 10) : exact le_of_sq_le_sq (by rwa [heq]) hD.le have hp := pade_nonneg hx have hsinh : 0 ≤ sinh x := sinh_nonneg_iff.mpr hx - have hmul := mul_le_mul_of_nonneg_left hroot (mul_nonneg (sq_nonneg x) hsinh) - have hmul2 := mul_nonneg (sqrt_nonneg (9 + (8 / 7 : ℝ) * x ^ 2)) hp + have hmul := mul_le_mul_of_nonneg_right hroot (mul_nonneg (sq_nonneg x) hsinh) + have hmul2 := mul_le_mul_of_nonneg_left (sub_nonneg.mp hp) + (sqrt_nonneg (9 + (8 / 7 : ℝ) * x ^ 2)) have hh : D x * (sqrt (9 + (8 / 7 : ℝ) * x ^ 2) * (x * cosh x - sinh x)) ≤ D x * (x ^ 2 * sinh x) := by - nlinarith only [hmul, hmul2] + calc + _ = sqrt (9 + (8 / 7 : ℝ) * x ^ 2) * (D x * (x * cosh x - sinh x)) := by ring + _ ≤ sqrt (9 + (8 / 7 : ℝ) * x ^ 2) * (x ^ 2 * A x * sinh x) := hmul2 + _ = (sqrt (9 + (8 / 7 : ℝ) * x ^ 2) * A x) * (x ^ 2 * sinh x) := by ring + _ ≤ _ := hmul exact (mul_le_mul_iff_right₀ hD).mp hh /-- Strong SJanPerth bound on `(0,10]`; both rational scale factors are retained. -/ diff --git a/Sendov/DistillationFinite/Rows13_20.lean b/Sendov/DistillationFinite/Rows13_20.lean index d6f0260..a9b459f 100644 --- a/Sendov/DistillationFinite/Rows13_20.lean +++ b/Sendov/DistillationFinite/Rows13_20.lean @@ -17,9 +17,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 4)) : (lo := 0) (hi := (13 / 4)) (s := 4826809) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((13 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 2) (13 / 2)) : 0 ≤ -distillCritical0 13 x := by @@ -29,9 +29,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 2) (13 / 2)) : (lo := (7 / 2)) (hi := (13 / 2)) (s := 34992) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (7 / 2)) ((13 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : distillT0 13 α ≤ (239 / 1000) := by @@ -47,9 +47,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 3) : (lo := 0) (hi := 3) (s := 9) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (3 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 4) (13 / 2)) : 0 ≤ distillCritical1 13 x := by @@ -59,9 +59,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 4) (13 / 2)) : (lo := (13 / 4)) (hi := (13 / 2)) (s := 4826809) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (13 / 4)) ((13 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : distillT1 13 α ≤ (77 / 500) := by @@ -78,9 +78,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 3) : (lo := 0) (hi := 3) (s := 3) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (3 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 4) (13 / 2)) : 0 ≤ distillCritical2 13 x := by @@ -89,9 +89,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 4) (13 / 2)) : (lo := (13 / 4)) (hi := (13 / 2)) (s := 2197) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (13 / 4)) ((13 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : distillT2 13 α ≤ (129 / 1000) := by @@ -133,9 +133,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (7 / 2)) : (lo := 0) (hi := (7 / 2)) (s := 117649) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((7 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 4) 7) : 0 ≤ -distillCritical0 14 x := by @@ -145,9 +145,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 4) 7) : (lo := (15 / 4)) (hi := 7) (s := 4826809) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (15 / 4)) (7 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : distillT0 14 α ≤ (243 / 1000) := by @@ -164,9 +164,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 4)) : (lo := 0) (hi := (13 / 4)) (s := 62748517) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((13 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 2) 7) : 0 ≤ distillCritical1 14 x := by @@ -176,9 +176,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 2) 7) : (lo := (7 / 2)) (hi := 7) (s := 117649) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (7 / 2)) (7 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : distillT1 14 α ≤ (31 / 200) := by @@ -195,9 +195,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 4)) : (lo := 0) (hi := (13 / 4)) (s := 28561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((13 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 2) 7) : 0 ≤ distillCritical2 14 x := by @@ -206,9 +206,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 2) 7) : (lo := (7 / 2)) (hi := 7) (s := 343) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (7 / 2)) (7 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : distillT2 14 α ≤ (33 / 250) := by @@ -250,9 +250,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 4) : (lo := 0) (hi := 4) (s := 4096) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (4 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 4) (15 / 2)) : 0 ≤ -distillCritical0 15 x := by @@ -262,9 +262,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 4) (15 / 2)) : (lo := (17 / 4)) (hi := (15 / 2)) (s := 62748517) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (17 / 4)) ((15 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : distillT0 15 α ≤ (31 / 125) := by @@ -281,9 +281,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 4)) : (lo := 0) (hi := (15 / 4)) (s := 3125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((15 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 4 (15 / 2)) : 0 ≤ distillCritical1 15 x := by @@ -293,9 +293,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 4 (15 / 2)) : (lo := 4) (hi := (15 / 2)) (s := 117649) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 4) ((15 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : distillT1 15 α ≤ (39 / 250) := by @@ -312,9 +312,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 4)) : (lo := 0) (hi := (15 / 4)) (s := 25) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((15 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 4 (15 / 2)) : 0 ≤ distillCritical2 15 x := by @@ -323,9 +323,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 4 (15 / 2)) : (lo := 4) (hi := (15 / 2)) (s := 343) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 4) ((15 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : distillT2 15 α ≤ (17 / 125) := by @@ -367,9 +367,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 4)) : (lo := 0) (hi := (17 / 4)) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((17 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 2) 8) : 0 ≤ -distillCritical0 16 x := by @@ -379,9 +379,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 2) 8) : (lo := (9 / 2)) (hi := 8) (s := 823543) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (9 / 2)) (8 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : distillT0 16 α ≤ (251 / 1000) := by @@ -397,9 +397,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 4) : (lo := 0) (hi := 4) (s := 128) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (4 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 4) 8) : 0 ≤ distillCritical1 16 x := by @@ -409,9 +409,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 4) 8) : (lo := (17 / 4)) (hi := 8) (s := 170859375) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (17 / 4)) (8 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : distillT1 16 α ≤ (157 / 1000) := by @@ -428,9 +428,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 4) : (lo := 0) (hi := 4) (s := 16) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (4 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 4) 8) : 0 ≤ distillCritical2 16 x := by @@ -439,9 +439,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 4) 8) : (lo := (17 / 4)) (hi := 8) (s := 50625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (17 / 4)) (8 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : distillT2 16 α ≤ (7 / 50) := by @@ -483,9 +483,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (19 / 4)) : (lo := 0) (hi := (19 / 4)) (s := 893871739) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((19 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 5 (17 / 2)) : 0 ≤ -distillCritical0 17 x := by @@ -495,9 +495,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 5 (17 / 2)) : (lo := 5) (hi := (17 / 2)) (s := 823543) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 5) ((17 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : distillT0 17 α ≤ (32 / 125) := by @@ -514,9 +514,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 2)) : (lo := 0) (hi := (9 / 2)) (s := 6561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((9 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 4) (17 / 2)) : 0 ≤ distillCritical1 17 x := by @@ -526,9 +526,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 4) (17 / 2)) : (lo := (19 / 4)) (hi := (17 / 2)) (s := 170859375) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (19 / 4)) ((17 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : distillT1 17 α ≤ (157 / 1000) := by @@ -545,9 +545,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 4)) : (lo := 0) (hi := (17 / 4)) (s := 4913) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((17 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 2) (17 / 2)) : 0 ≤ distillCritical2 17 x := by @@ -556,9 +556,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 2) (17 / 2)) : (lo := (9 / 2)) (hi := (17 / 2)) (s := 512) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (9 / 2)) ((17 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : distillT2 17 α ≤ (29 / 200) := by @@ -600,9 +600,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 5) : (lo := 0) (hi := 5) (s := 15625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (5 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 4) 9) : 0 ≤ -distillCritical0 18 x := by @@ -612,9 +612,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 4) 9) : (lo := (21 / 4)) (hi := 9) (s := 78125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (21 / 4)) (9 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : distillT0 18 α ≤ (259 / 1000) := by @@ -631,9 +631,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (19 / 4)) : (lo := 0) (hi := (19 / 4)) (s := 893871739) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((19 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 5 9) : 0 ≤ distillCritical1 18 x := by @@ -643,9 +643,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 5 9) : (lo := 5) (hi := 9) (s := 1024) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 5) (9 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : distillT1 18 α ≤ (79 / 500) := by @@ -662,9 +662,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 2)) : (lo := 0) (hi := (9 / 2)) (s := 9) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((9 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 4) 9) : 0 ≤ distillCritical2 18 x := by @@ -673,9 +673,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 4) 9) : (lo := (19 / 4)) (hi := 9) (s := 83521) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (19 / 4)) (9 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : distillT2 18 α ≤ (3 / 20) := by @@ -717,9 +717,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 4)) : (lo := 0) (hi := (21 / 4)) (s := 7411887) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((21 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 2) (19 / 2)) : 0 ≤ -distillCritical0 19 x := by @@ -729,9 +729,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 2) (19 / 2)) : (lo := (11 / 2)) (hi := (19 / 2)) (s := 262144) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (11 / 2)) ((19 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : distillT0 19 α ≤ (131 / 500) := by @@ -748,9 +748,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 4)) : (lo := 0) (hi := (21 / 4)) (s := 7411887) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((21 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 2) (19 / 2)) : 0 ≤ distillCritical1 19 x := by @@ -760,9 +760,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 2) (19 / 2)) : (lo := (11 / 2)) (hi := (19 / 2)) (s := 131072) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (11 / 2)) ((19 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : distillT1 19 α ≤ (159 / 1000) := by @@ -779,9 +779,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 5) : (lo := 0) (hi := 5) (s := 125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (5 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 4) (19 / 2)) : 0 ≤ distillCritical2 19 x := by @@ -790,9 +790,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 4) (19 / 2)) : (lo := (21 / 4)) (hi := (19 / 2)) (s := 83521) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (21 / 4)) ((19 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : distillT2 19 α ≤ (77 / 500) := by @@ -834,9 +834,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 4)) : (lo := 0) (hi := (23 / 4)) (s := 3404825447) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((23 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 6 10) : 0 ≤ -distillCritical0 20 x := by @@ -846,9 +846,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 6 10) : (lo := 6) (hi := 10) (s := 256) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 6) (10 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : distillT0 20 α ≤ (53 / 200) := by @@ -865,9 +865,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (11 / 2)) : (lo := 0) (hi := (11 / 2)) (s := 1771561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((11 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 4) 10) : 0 ≤ distillCritical1 20 x := by @@ -877,9 +877,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 4) 10) : (lo := (23 / 4)) (hi := 10) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (23 / 4)) (10 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : distillT1 20 α ≤ (159 / 1000) := by @@ -896,9 +896,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 4)) : (lo := 0) (hi := (21 / 4)) (s := 7203) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((21 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 2) 10) : 0 ≤ distillCritical2 20 x := by @@ -907,9 +907,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 2) 10) : (lo := (11 / 2)) (hi := 10) (s := 6561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (11 / 2)) (10 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : distillT2 20 α ≤ (4 / 25) := by diff --git a/Sendov/DistillationFinite/Rows21_28.lean b/Sendov/DistillationFinite/Rows21_28.lean index 038f3a2..80234f9 100644 --- a/Sendov/DistillationFinite/Rows21_28.lean +++ b/Sendov/DistillationFinite/Rows21_28.lean @@ -16,9 +16,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 6) : (lo := 0) (hi := 6) (s := 32) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (6 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 4) (21 / 2)) : 0 ≤ -distillCritical0 21 x := by @@ -28,9 +28,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 4) (21 / 2)) : (lo := (25 / 4)) (hi := (21 / 2)) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (25 / 4)) ((21 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : distillT0 21 α ≤ (67 / 250) := by @@ -46,9 +46,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 6) : (lo := 0) (hi := 6) (s := 16) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (6 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 4) (21 / 2)) : 0 ≤ distillCritical1 21 x := by @@ -58,9 +58,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 4) (21 / 2)) : (lo := (25 / 4)) (hi := (21 / 2)) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (25 / 4)) ((21 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : distillT1 21 α ≤ (4 / 25) := by @@ -77,9 +77,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (11 / 2)) : (lo := 0) (hi := (11 / 2)) (s := 14641) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((11 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 4) (21 / 2)) : 0 ≤ distillCritical2 21 x := by @@ -88,9 +88,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 4) (21 / 2)) : (lo := (23 / 4)) (hi := (21 / 2)) (s := 130321) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (23 / 4)) ((21 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : distillT2 21 α ≤ (33 / 200) := by @@ -132,9 +132,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 2)) : (lo := 0) (hi := (13 / 2)) (s := 62748517) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((13 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 4) 11) : 0 ≤ -distillCritical0 22 x := by @@ -144,9 +144,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 4) 11) : (lo := (27 / 4)) (hi := 11) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (27 / 4)) (11 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : distillT0 22 α ≤ (271 / 1000) := by @@ -163,9 +163,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 4)) : (lo := 0) (hi := (25 / 4)) (s := 1220703125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((25 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 2) 11) : 0 ≤ distillCritical1 22 x := by @@ -175,9 +175,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 2) 11) : (lo := (13 / 2)) (hi := 11) (s := 4782969) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (13 / 2)) (11 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : distillT1 22 α ≤ (4 / 25) := by @@ -194,9 +194,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 4)) : (lo := 0) (hi := (23 / 4)) (s := 279841) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((23 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 6 11) : 0 ≤ distillCritical2 22 x := by @@ -205,9 +205,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 6 11) : (lo := 6) (hi := 11) (s := 625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 6) (11 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : distillT2 22 α ≤ (17 / 100) := by @@ -249,9 +249,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 4)) : (lo := 0) (hi := (27 / 4)) (s := 4782969) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((27 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 7 (23 / 2)) : 0 ≤ -distillCritical0 23 x := by @@ -261,9 +261,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 7 (23 / 2)) : (lo := 7) (hi := (23 / 2)) (s := 4782969) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 7) ((23 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : distillT0 23 α ≤ (273 / 1000) := by @@ -280,9 +280,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 4)) : (lo := 0) (hi := (27 / 4)) (s := 14348907) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((27 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 7 (23 / 2)) : 0 ≤ distillCritical1 23 x := by @@ -292,9 +292,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 7 (23 / 2)) : (lo := 7) (hi := (23 / 2)) (s := 4782969) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 7) ((23 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : distillT1 23 α ≤ (161 / 1000) := by @@ -311,9 +311,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 4)) : (lo := 0) (hi := (25 / 4)) (s := 15625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((25 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 2) (23 / 2)) : 0 ≤ distillCritical2 23 x := by @@ -322,9 +322,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 2) (23 / 2)) : (lo := (13 / 2)) (hi := (23 / 2)) (s := 1250) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (13 / 2)) ((23 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : distillT2 23 α ≤ (7 / 40) := by @@ -366,9 +366,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 4)) : (lo := 0) (hi := (29 / 4)) (s := 17249876309) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((29 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 2) 12) : 0 ≤ -distillCritical0 24 x := by @@ -378,9 +378,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 2) 12) : (lo := (15 / 2)) (hi := 12) (s := 2187) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (15 / 2)) (12 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : distillT0 24 α ≤ (11 / 40) := by @@ -397,9 +397,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 4)) : (lo := 0) (hi := (29 / 4)) (s := 17249876309) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((29 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 2) 12) : 0 ≤ distillCritical1 24 x := by @@ -409,9 +409,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 2) 12) : (lo := (15 / 2)) (hi := 12) (s := 243) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (15 / 2)) (12 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : distillT1 24 α ≤ (161 / 1000) := by @@ -428,9 +428,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 2)) : (lo := 0) (hi := (13 / 2)) (s := 28561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((13 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 4) 12) : 0 ≤ distillCritical2 24 x := by @@ -439,9 +439,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 4) 12) : (lo := (27 / 4)) (hi := 12) (s := 2401) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (27 / 4)) (12 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : distillT2 24 α ≤ (9 / 50) := by @@ -483,9 +483,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 2)) : (lo := 0) (hi := (15 / 2)) (s := 28125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((15 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 4) (25 / 2)) : 0 ≤ -distillCritical0 25 x := by @@ -495,9 +495,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 4) (25 / 2)) : (lo := (31 / 4)) (hi := (25 / 2)) (s := 893871739) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (31 / 4)) ((25 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : distillT0 25 α ≤ (277 / 1000) := by @@ -514,9 +514,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 2)) : (lo := 0) (hi := (15 / 2)) (s := 28125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((15 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 4) (25 / 2)) : 0 ≤ distillCritical1 25 x := by @@ -526,9 +526,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 4) (25 / 2)) : (lo := (31 / 4)) (hi := (25 / 2)) (s := 893871739) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (31 / 4)) ((25 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : distillT1 25 α ≤ (161 / 1000) := by @@ -545,9 +545,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 4)) : (lo := 0) (hi := (27 / 4)) (s := 6561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((27 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 7 (25 / 2)) : 0 ≤ distillCritical2 25 x := by @@ -556,9 +556,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 7 (25 / 2)) : (lo := 7) (hi := (25 / 2)) (s := 14641) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 7) ((25 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : distillT2 25 α ≤ (93 / 500) := by @@ -600,9 +600,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 8) : (lo := 0) (hi := 8) (s := 131072) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (8 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 4) 13) : 0 ≤ -distillCritical0 26 x := by @@ -612,9 +612,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 4) 13) : (lo := (33 / 4)) (hi := 13) (s := 893871739) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (33 / 4)) (13 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : distillT0 26 α ≤ (279 / 1000) := by @@ -631,9 +631,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 8) : (lo := 0) (hi := 8) (s := 131072) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (8 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 4) 13) : 0 ≤ distillCritical1 26 x := by @@ -643,9 +643,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 4) 13) : (lo := (33 / 4)) (hi := 13) (s := 893871739) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (33 / 4)) (13 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : distillT1 26 α ≤ (81 / 500) := by @@ -662,9 +662,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 4)) : (lo := 0) (hi := (29 / 4)) (s := 707281) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((29 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 2) 13) : 0 ≤ distillCritical2 26 x := by @@ -673,9 +673,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 2) 13) : (lo := (15 / 2)) (hi := 13) (s := 14641) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (15 / 2)) (13 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : distillT2 26 α ≤ (191 / 1000) := by @@ -717,9 +717,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (33 / 4)) : (lo := 0) (hi := (33 / 4)) (s := 19487171) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((33 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 2) (27 / 2)) : 0 ≤ -distillCritical0 27 x := by @@ -729,9 +729,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 2) (27 / 2)) : (lo := (17 / 2)) (hi := (27 / 2)) (s := 1250000) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (17 / 2)) ((27 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : distillT0 27 α ≤ (7 / 25) := by @@ -748,9 +748,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 2)) : (lo := 0) (hi := (17 / 2)) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((17 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (35 / 4) (27 / 2)) : 0 ≤ distillCritical1 27 x := by @@ -760,9 +760,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (35 / 4) (27 / 2)) : (lo := (35 / 4)) (hi := (27 / 2)) (s := 893871739) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (35 / 4)) ((27 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : distillT1 27 α ≤ (81 / 500) := by @@ -779,9 +779,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 2)) : (lo := 0) (hi := (15 / 2)) (s := 125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((15 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 4) (27 / 2)) : 0 ≤ distillCritical2 27 x := by @@ -790,9 +790,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 4) (27 / 2)) : (lo := (31 / 4)) (hi := (27 / 2)) (s := 279841) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (31 / 4)) ((27 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : distillT2 27 α ≤ (49 / 250) := by @@ -834,9 +834,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (35 / 4)) : (lo := 0) (hi := (35 / 4)) (s := 1838265625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((35 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 9 14) : 0 ≤ -distillCritical0 28 x := by @@ -846,9 +846,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 9 14) : (lo := 9) (hi := 14) (s := 78125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 9) (14 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : distillT0 28 α ≤ (141 / 500) := by @@ -865,9 +865,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (35 / 4)) : (lo := 0) (hi := (35 / 4)) (s := 1838265625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((35 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 9 14) : 0 ≤ distillCritical1 28 x := by @@ -877,9 +877,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 9 14) : (lo := 9) (hi := 14) (s := 78125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 9) (14 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : distillT1 28 α ≤ (81 / 500) := by @@ -896,9 +896,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (31 / 4)) : (lo := 0) (hi := (31 / 4)) (s := 923521) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((31 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 8 14) : 0 ≤ distillCritical2 28 x := by @@ -907,9 +907,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 8 14) : (lo := 8) (hi := 14) (s := 162) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 8) (14 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : distillT2 28 α ≤ (101 / 500) := by diff --git a/Sendov/DistillationFinite/Rows29_36.lean b/Sendov/DistillationFinite/Rows29_36.lean index aa2824a..0280d9c 100644 --- a/Sendov/DistillationFinite/Rows29_36.lean +++ b/Sendov/DistillationFinite/Rows29_36.lean @@ -16,9 +16,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 9) : (lo := 0) (hi := 9) (s := 2187) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (9 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (37 / 4) (29 / 2)) : 0 ≤ -distillCritical0 29 x := by @@ -28,9 +28,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (37 / 4) (29 / 2)) : (lo := (37 / 4)) (hi := (29 / 2)) (s := 257298363) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (37 / 4)) ((29 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : distillT0 29 α ≤ (283 / 1000) := by @@ -47,9 +47,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (37 / 4)) : (lo := 0) (hi := (37 / 4)) (s := 94931877133) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((37 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 2) (29 / 2)) : 0 ≤ distillCritical1 29 x := by @@ -59,9 +59,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 2) (29 / 2)) : (lo := (19 / 2)) (hi := (29 / 2)) (s := 125000) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (19 / 2)) ((29 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : distillT1 29 α ≤ (81 / 500) := by @@ -78,9 +78,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 8) : (lo := 0) (hi := 8) (s := 1024) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (8 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 4) (29 / 2)) : 0 ≤ distillCritical2 29 x := by @@ -89,9 +89,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 4) (29 / 2)) : (lo := (33 / 4)) (hi := (29 / 2)) (s := 78125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (33 / 4)) ((29 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : distillT2 29 α ≤ (207 / 1000) := by @@ -133,9 +133,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (19 / 2)) : (lo := 0) (hi := (19 / 2)) (s := 893871739) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((19 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (39 / 4) 15) : 0 ≤ -distillCritical0 30 x := by @@ -145,9 +145,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (39 / 4) 15) : (lo := (39 / 4)) (hi := 15) (s := 823543) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (39 / 4)) (15 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : distillT0 30 α ≤ (71 / 250) := by @@ -164,9 +164,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (39 / 4)) : (lo := 0) (hi := (39 / 4)) (s := 62748517) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((39 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 10 15) : 0 ≤ distillCritical1 30 x := by @@ -176,9 +176,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 10 15) : (lo := 10) (hi := 15) (s := 3125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 10) (15 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : distillT1 30 α ≤ (81 / 500) := by @@ -195,9 +195,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 2)) : (lo := 0) (hi := (17 / 2)) (s := 83521) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((17 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (35 / 4) 15) : 0 ≤ distillCritical2 30 x := by @@ -206,9 +206,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (35 / 4) 15) : (lo := (35 / 4)) (hi := 15) (s := 15625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (35 / 4)) (15 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : distillT2 30 α ≤ (53 / 250) := by @@ -250,9 +250,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (39 / 4)) : (lo := 0) (hi := (39 / 4)) (s := 564736653) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((39 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 10 (31 / 2)) : 0 ≤ -distillCritical0 31 x := by @@ -262,9 +262,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 10 (31 / 2)) : (lo := 10) (hi := (31 / 2)) (s := 19487171) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 10) ((31 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : distillT0 31 α ≤ (57 / 200) := by @@ -281,9 +281,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 10) : (lo := 0) (hi := 10) (s := 125000) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (10 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (41 / 4) (31 / 2)) : 0 ≤ distillCritical1 31 x := by @@ -293,9 +293,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (41 / 4) (31 / 2)) : (lo := (41 / 4)) (hi := (31 / 2)) (s := 1801088541) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (41 / 4)) ((31 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : distillT1 31 α ≤ (161 / 1000) := by @@ -312,9 +312,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (35 / 4)) : (lo := 0) (hi := (35 / 4)) (s := 42875) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((35 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 9 (31 / 2)) : 0 ≤ distillCritical2 31 x := by @@ -323,9 +323,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 9 (31 / 2)) : (lo := 9) (hi := (31 / 2)) (s := 28561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 9) ((31 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : distillT2 31 α ≤ (109 / 500) := by @@ -367,9 +367,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (41 / 4)) : (lo := 0) (hi := (41 / 4)) (s := 194754273881) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((41 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 2) 16) : 0 ≤ -distillCritical0 32 x := by @@ -379,9 +379,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 2) 16) : (lo := (21 / 2)) (hi := 16) (s := 1771561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (21 / 2)) (16 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : distillT0 32 α ≤ (143 / 500) := by @@ -398,9 +398,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 2)) : (lo := 0) (hi := (21 / 2)) (s := 7411887) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((21 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (43 / 4) 16) : 0 ≤ distillCritical1 32 x := by @@ -410,9 +410,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (43 / 4) 16) : (lo := (43 / 4)) (hi := 16) (s := 1801088541) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (43 / 4)) (16 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : distillT1 32 α ≤ (161 / 1000) := by @@ -429,9 +429,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 9) : (lo := 0) (hi := 9) (s := 81) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (9 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (37 / 4) 16) : 0 ≤ distillCritical2 32 x := by @@ -440,9 +440,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (37 / 4) 16) : (lo := (37 / 4)) (hi := 16) (s := 531441) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (37 / 4)) (16 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : distillT2 32 α ≤ (223 / 1000) := by @@ -484,9 +484,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 2)) : (lo := 0) (hi := (21 / 2)) (s := 823543) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((21 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (43 / 4) (33 / 2)) : 0 ≤ -distillCritical0 33 x := by @@ -496,9 +496,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (43 / 4) (33 / 2)) : (lo := (43 / 4)) (hi := (33 / 2)) (s := 3404825447) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (43 / 4)) ((33 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : distillT0 33 α ≤ (143 / 500) := by @@ -515,9 +515,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 11) : (lo := 0) (hi := 11) (s := 1771561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (11 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (45 / 4) (33 / 2)) : 0 ≤ distillCritical1 33 x := by @@ -527,9 +527,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (45 / 4) (33 / 2)) : (lo := (45 / 4)) (hi := (33 / 2)) (s := 117649) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (45 / 4)) ((33 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : distillT1 33 α ≤ (161 / 1000) := by @@ -546,9 +546,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (37 / 4)) : (lo := 0) (hi := (37 / 4)) (s := 1874161) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((37 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 2) (33 / 2)) : 0 ≤ distillCritical2 33 x := by @@ -557,9 +557,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 2) (33 / 2)) : (lo := (19 / 2)) (hi := (33 / 2)) (s := 686) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (19 / 2)) ((33 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : distillT2 33 α ≤ (57 / 250) := by @@ -601,9 +601,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 11) : (lo := 0) (hi := 11) (s := 19487171) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (11 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (45 / 4) 17) : 0 ≤ -distillCritical0 34 x := by @@ -613,9 +613,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (45 / 4) 17) : (lo := (45 / 4)) (hi := 17) (s := 3404825447) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (45 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 34 α ≤ (287 / 1000) := by @@ -632,9 +632,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 2)) : (lo := 0) (hi := (23 / 2)) (s := 3404825447) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((23 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (47 / 4) 17) : 0 ≤ distillCritical1 34 x := by @@ -644,9 +644,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (47 / 4) 17) : (lo := (47 / 4)) (hi := 17) (s := 257298363) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (47 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT1 34 α ≤ (161 / 1000) := by @@ -663,9 +663,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (39 / 4)) : (lo := 0) (hi := (39 / 4)) (s := 85683) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((39 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 10 17) : 0 ≤ distillCritical2 34 x := by @@ -674,9 +674,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 10 17) : (lo := 10) (hi := 17) (s := 343) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 10) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 34 α ≤ (233 / 1000) := by @@ -718,9 +718,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (45 / 4)) : (lo := 0) (hi := (45 / 4)) (s := 6834375) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((45 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 2) 17) : 0 ≤ -distillCritical0 35 x := by @@ -730,9 +730,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 2) 17) : (lo := (23 / 2)) (hi := 17) (s := 19487171) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (23 / 2)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 35 α ≤ (287 / 1000) := by @@ -749,9 +749,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (47 / 4)) : (lo := 0) (hi := (47 / 4)) (s := 506623120463) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((47 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 12 17) : 0 ≤ distillCritical1 35 x := by @@ -761,9 +761,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 12 17) : (lo := 12) (hi := 17) (s := 15625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 12) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT1 35 α ≤ (4 / 25) := by @@ -780,9 +780,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 10) : (lo := 0) (hi := 10) (s := 50) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (10 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (41 / 4) 17) : 0 ≤ distillCritical2 35 x := by @@ -791,9 +791,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (41 / 4) 17) : (lo := (41 / 4)) (hi := 17) (s := 177147) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (41 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 35 α ≤ (239 / 1000) := by @@ -835,9 +835,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (47 / 4)) : (lo := 0) (hi := (47 / 4)) (s := 506623120463) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((47 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 12 17) : 0 ≤ -distillCritical0 36 x := by @@ -847,9 +847,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 12 17) : (lo := 12) (hi := 17) (s := 78125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 12) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 36 α ≤ (287 / 1000) := by @@ -866,9 +866,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (49 / 4)) : (lo := 0) (hi := (49 / 4)) (s := 678223072849) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((49 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 2) 17) : 0 ≤ distillCritical1 36 x := by @@ -878,9 +878,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 2) 17) : (lo := (25 / 2)) (hi := 17) (s := 1594323) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (25 / 2)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT1 36 α ≤ (4 / 25) := by @@ -897,9 +897,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (41 / 4)) : (lo := 0) (hi := (41 / 4)) (s := 2825761) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((41 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 2) 17) : 0 ≤ distillCritical2 36 x := by @@ -908,9 +908,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 2) 17) : (lo := (21 / 2)) (hi := 17) (s := 28561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (21 / 2)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 36 α ≤ (61 / 250) := by diff --git a/Sendov/DistillationFinite/Rows37_44.lean b/Sendov/DistillationFinite/Rows37_44.lean index 88a5f2d..b9aa485 100644 --- a/Sendov/DistillationFinite/Rows37_44.lean +++ b/Sendov/DistillationFinite/Rows37_44.lean @@ -16,9 +16,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 12) : (lo := 0) (hi := 12) (s := 36864) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (12 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (49 / 4) 17) : 0 ≤ -distillCritical0 37 x := by @@ -28,9 +28,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (49 / 4) 17) : (lo := (49 / 4)) (hi := 17) (s := 893871739) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (49 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 37 α ≤ (287 / 1000) := by @@ -47,9 +47,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (51 / 4)) : (lo := 0) (hi := (51 / 4)) (s := 3693048057) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((51 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 13 17) : 0 ≤ distillCritical1 37 x := by @@ -59,9 +59,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 13 17) : (lo := 13) (hi := 17) (s := 4096) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 13) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT1 37 α ≤ (159 / 1000) := by @@ -78,9 +78,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 2)) : (lo := 0) (hi := (21 / 2)) (s := 7203) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((21 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (43 / 4) 17) : 0 ≤ distillCritical2 37 x := by @@ -89,9 +89,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (43 / 4) 17) : (lo := (43 / 4)) (hi := 17) (s := 390625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (43 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 37 α ≤ (249 / 1000) := by @@ -133,9 +133,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 2)) : (lo := 0) (hi := (25 / 2)) (s := 1220703125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((25 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (51 / 4) 17) : 0 ≤ -distillCritical0 38 x := by @@ -145,9 +145,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (51 / 4) 17) : (lo := (51 / 4)) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (51 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 38 α ≤ (287 / 1000) := by @@ -164,9 +164,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (53 / 4)) : (lo := 0) (hi := (53 / 4)) (s := 1174711139837) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((53 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 2) 17) : 0 ≤ distillCritical1 38 x := by @@ -176,9 +176,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 2) 17) : (lo := (27 / 2)) (hi := 17) (s := 823543) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (27 / 2)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT1 38 α ≤ (159 / 1000) := by @@ -195,9 +195,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 11) : (lo := 0) (hi := 11) (s := 14641) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (11 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (45 / 4) 17) : 0 ≤ distillCritical2 38 x := by @@ -206,9 +206,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (45 / 4) 17) : (lo := (45 / 4)) (hi := 17) (s := 279841) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (45 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 38 α ≤ (127 / 500) := by @@ -250,9 +250,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 13) : (lo := 0) (hi := 13) (s := 4826809) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (13 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (53 / 4) 17) : 0 ≤ -distillCritical0 39 x := by @@ -262,9 +262,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (53 / 4) 17) : (lo := (53 / 4)) (hi := 17) (s := 11390625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (53 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 39 α ≤ (287 / 1000) := by @@ -281,9 +281,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 2)) : (lo := 0) (hi := (27 / 2)) (s := 1594323) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((27 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (55 / 4) 17) : 0 ≤ distillCritical1 39 x := by @@ -293,9 +293,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (55 / 4) 17) : (lo := (55 / 4)) (hi := 17) (s := 62748517) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (55 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT1 39 α ≤ (79 / 500) := by @@ -312,9 +312,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (45 / 4)) : (lo := 0) (hi := (45 / 4)) (s := 1125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((45 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 2) 17) : 0 ≤ distillCritical2 39 x := by @@ -323,9 +323,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 2) 17) : (lo := (23 / 2)) (hi := 17) (s := 14641) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (23 / 2)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 39 α ≤ (259 / 1000) := by @@ -367,9 +367,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (53 / 4)) : (lo := 0) (hi := (53 / 4)) (s := 1174711139837) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((53 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 2) 17) : 0 ≤ -distillCritical0 40 x := by @@ -379,9 +379,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 2) 17) : (lo := (27 / 2)) (hi := 17) (s := 823543) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (27 / 2)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 40 α ≤ (287 / 1000) := by @@ -398,9 +398,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 14) : (lo := 0) (hi := 14) (s := 1647086) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (14 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (57 / 4) 17) : 0 ≤ distillCritical1 40 x := by @@ -410,9 +410,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (57 / 4) 17) : (lo := (57 / 4)) (hi := 17) (s := 19487171) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (57 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT1 40 α ≤ (79 / 500) := by @@ -429,9 +429,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 2)) : (lo := 0) (hi := (23 / 2)) (s := 279841) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((23 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (47 / 4) 17) : 0 ≤ distillCritical2 40 x := by @@ -440,9 +440,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (47 / 4) 17) : (lo := (47 / 4)) (hi := 17) (s := 194481) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (47 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 40 α ≤ (33 / 125) := by @@ -484,9 +484,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (55 / 4)) : (lo := 0) (hi := (55 / 4)) (s := 304487046875) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((55 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 14 17) : 0 ≤ -distillCritical0 41 x := by @@ -496,9 +496,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 14 17) : (lo := 14) (hi := 17) (s := 729) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 14) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 41 α ≤ (287 / 1000) := by @@ -515,9 +515,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 2)) : (lo := 0) (hi := (29 / 2)) (s := 17249876309) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((29 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (59 / 4) 17) : 0 ≤ distillCritical1 41 x := by @@ -527,9 +527,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (59 / 4) 17) : (lo := (59 / 4)) (hi := 17) (s := 1594323) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (59 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT1 41 α ≤ (157 / 1000) := by @@ -546,9 +546,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 12) : (lo := 0) (hi := 12) (s := 192) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (12 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (49 / 4) 17) : 0 ≤ distillCritical2 41 x := by @@ -557,9 +557,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (49 / 4) 17) : (lo := (49 / 4)) (hi := 17) (s := 130321) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (49 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 41 α ≤ (269 / 1000) := by @@ -601,9 +601,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 14) : (lo := 0) (hi := 14) (s := 941192) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (14 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (57 / 4) 17) : 0 ≤ -distillCritical0 42 x := by @@ -613,9 +613,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (57 / 4) 17) : (lo := (57 / 4)) (hi := 17) (s := 19487171) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (57 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 42 α ≤ (143 / 500) := by @@ -631,9 +631,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 15) : (lo := 0) (hi := 15) (s := 15625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (15 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (61 / 4) 17) : 0 ≤ distillCritical1 42 x := by @@ -643,9 +643,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (61 / 4) 17) : (lo := (61 / 4)) (hi := 17) (s := 823543) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (61 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT1 42 α ≤ (39 / 250) := by @@ -662,9 +662,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (49 / 4)) : (lo := 0) (hi := (49 / 4)) (s := 823543) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((49 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 2) 17) : 0 ≤ distillCritical2 42 x := by @@ -673,9 +673,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 2) 17) : (lo := (25 / 2)) (hi := 17) (s := 6561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (25 / 2)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 42 α ≤ (137 / 500) := by @@ -717,9 +717,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 2)) : (lo := 0) (hi := (29 / 2)) (s := 17249876309) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((29 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (59 / 4) 17) : 0 ≤ -distillCritical0 43 x := by @@ -729,9 +729,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (59 / 4) 17) : (lo := (59 / 4)) (hi := 17) (s := 4782969) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (59 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 43 α ≤ (143 / 500) := by @@ -748,9 +748,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (31 / 2)) : (lo := 0) (hi := (31 / 2)) (s := 27512614111) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((31 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (63 / 4) 17) : 0 ≤ distillCritical1 43 x := by @@ -760,9 +760,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (63 / 4) 17) : (lo := (63 / 4)) (hi := 17) (s := 78125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (63 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT1 43 α ≤ (39 / 250) := by @@ -779,9 +779,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 2)) : (lo := 0) (hi := (25 / 2)) (s := 15625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((25 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (51 / 4) 17) : 0 ≤ distillCritical2 43 x := by @@ -790,9 +790,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (51 / 4) 17) : (lo := (51 / 4)) (hi := 17) (s := 83521) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (51 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 43 α ≤ (279 / 1000) := by @@ -833,9 +833,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 15) : (lo := 0) (hi := 15) (s := 140625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (15 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (61 / 4) 17) : 0 ≤ -distillCritical0 44 x := by @@ -845,9 +845,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (61 / 4) 17) : (lo := (61 / 4)) (hi := 17) (s := 823543) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (61 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 44 α ≤ (143 / 500) := by @@ -864,9 +864,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (63 / 4)) : (lo := 0) (hi := (63 / 4)) (s := 5403265623) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((63 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 16 17) : 0 ≤ distillCritical1 44 x := by @@ -876,9 +876,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 16 17) : (lo := 16) (hi := 17) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 16) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT1 44 α ≤ (31 / 200) := by @@ -895,9 +895,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (51 / 4)) : (lo := 0) (hi := (51 / 4)) (s := 250563) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((51 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 13 17) : 0 ≤ distillCritical2 44 x := by @@ -906,9 +906,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 13 17) : (lo := 13) (hi := 17) (s := 128) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 13) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 44 α ≤ (283 / 1000) := by diff --git a/Sendov/DistillationFinite/Rows45_52.lean b/Sendov/DistillationFinite/Rows45_52.lean index e064c4f..c85e728 100644 --- a/Sendov/DistillationFinite/Rows45_52.lean +++ b/Sendov/DistillationFinite/Rows45_52.lean @@ -17,9 +17,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (61 / 4)) : (lo := 0) (hi := (61 / 4)) (s := 51520374361) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((61 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 2) 17) : 0 ≤ -distillCritical0 45 x := by @@ -29,9 +29,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 2) 17) : (lo := (31 / 2)) (hi := 17) (s := 81) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (31 / 2)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 45 α ≤ (57 / 200) := by @@ -48,9 +48,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (65 / 4)) : (lo := 0) (hi := (65 / 4)) (s := 15083778125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((65 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 2) 17) : 0 ≤ distillCritical1 45 x := by @@ -60,9 +60,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 2) 17) : (lo := (33 / 2)) (hi := 17) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (33 / 2)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT1 45 α ≤ (77 / 500) := by @@ -79,9 +79,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (53 / 4)) : (lo := 0) (hi := (53 / 4)) (s := 7890481) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((53 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 2) 17) : 0 ≤ distillCritical2 45 x := by @@ -90,9 +90,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 2) 17) : (lo := (27 / 2)) (hi := 17) (s := 2401) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (27 / 2)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 45 α ≤ (36 / 125) := by @@ -134,9 +134,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (63 / 4)) : (lo := 0) (hi := (63 / 4)) (s := 1801088541) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((63 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 16 17) : 0 ≤ -distillCritical0 46 x := by @@ -146,9 +146,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 16 17) : (lo := 16) (hi := 17) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 16) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 46 α ≤ (71 / 250) := by @@ -165,9 +165,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (67 / 4)) : (lo := 0) (hi := (67 / 4)) (s := 6060711605323) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((67 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 46 x := by @@ -188,9 +188,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 2)) : (lo := 0) (hi := (27 / 2)) (s := 6561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((27 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (55 / 4) 17) : 0 ≤ distillCritical2 46 x := by @@ -199,9 +199,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (55 / 4) 17) : (lo := (55 / 4)) (hi := 17) (s := 28561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (55 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 46 α ≤ (73 / 250) := by @@ -243,9 +243,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 16) : (lo := 0) (hi := 16) (s := 67108864) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (16 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (65 / 4) 17) : 0 ≤ -distillCritical0 47 x := by @@ -255,9 +255,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (65 / 4) 17) : (lo := (65 / 4)) (hi := 17) (s := 729) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (65 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 47 α ≤ (283 / 1000) := by @@ -274,9 +274,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 47 x := by @@ -297,9 +297,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (55 / 4)) : (lo := 0) (hi := (55 / 4)) (s := 166375) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((55 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 14 17) : 0 ≤ distillCritical2 47 x := by @@ -308,9 +308,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 14 17) : (lo := 14) (hi := 17) (s := 27) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 14) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 47 α ≤ (297 / 1000) := by @@ -352,9 +352,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (33 / 2)) : (lo := 0) (hi := (33 / 2)) (s := 19487171) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((33 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (67 / 4) 17) : 0 ≤ -distillCritical0 48 x := by @@ -364,9 +364,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (67 / 4) 17) : (lo := (67 / 4)) (hi := 17) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (67 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT0 48 α ≤ (283 / 1000) := by @@ -383,9 +383,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 48 x := by @@ -406,9 +406,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 14) : (lo := 0) (hi := 14) (s := 4802) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (14 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (57 / 4) 17) : 0 ≤ distillCritical2 48 x := by @@ -417,9 +417,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (57 / 4) 17) : (lo := (57 / 4)) (hi := 17) (s := 14641) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (57 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 48 α ≤ (301 / 1000) := by @@ -461,9 +461,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ -distillCritical0 49 x := by @@ -484,9 +484,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 49 x := by @@ -507,9 +507,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 2)) : (lo := 0) (hi := (29 / 2)) (s := 707281) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((29 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (59 / 4) 17) : 0 ≤ distillCritical2 49 x := by @@ -518,9 +518,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (59 / 4) 17) : (lo := (59 / 4)) (hi := 17) (s := 6561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (59 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 49 α ≤ (153 / 500) := by @@ -562,9 +562,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ -distillCritical0 50 x := by @@ -585,9 +585,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 50 x := by @@ -608,9 +608,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (59 / 4)) : (lo := 0) (hi := (59 / 4)) (s := 12117361) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((59 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 15 17) : 0 ≤ distillCritical2 50 x := by @@ -619,9 +619,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 15 17) : (lo := 15) (hi := 17) (s := 4) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 15) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 50 α ≤ (31 / 100) := by @@ -663,9 +663,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 24137569) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ -distillCritical0 51 x := by @@ -686,9 +686,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 24137569) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 51 x := by @@ -709,9 +709,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 15) : (lo := 0) (hi := 15) (s := 125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (15 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (61 / 4) 17) : 0 ≤ distillCritical2 51 x := by @@ -720,9 +720,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (61 / 4) 17) : (lo := (61 / 4)) (hi := 17) (s := 2401) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (61 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 51 α ≤ (157 / 500) := by @@ -764,9 +764,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ -distillCritical0 52 x := by @@ -787,9 +787,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 52 x := by @@ -810,9 +810,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (61 / 4)) : (lo := 0) (hi := (61 / 4)) (s := 13845841) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((61 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 2) 17) : 0 ≤ distillCritical2 52 x := by @@ -821,9 +821,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 2) 17) : (lo := (31 / 2)) (hi := 17) (s := 81) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (31 / 2)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 52 α ≤ (159 / 500) := by diff --git a/Sendov/DistillationFinite/Rows53_60.lean b/Sendov/DistillationFinite/Rows53_60.lean index aa31b2f..00ffa6d 100644 --- a/Sendov/DistillationFinite/Rows53_60.lean +++ b/Sendov/DistillationFinite/Rows53_60.lean @@ -17,9 +17,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ -distillCritical0 53 x := by @@ -40,9 +40,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 53 x := by @@ -63,9 +63,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (63 / 4)) : (lo := 0) (hi := (63 / 4)) (s := 194481) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((63 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 16 17) : 0 ≤ distillCritical2 53 x := by @@ -74,9 +74,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 16 17) : (lo := 16) (hi := 17) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 16) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 53 α ≤ (161 / 500) := by @@ -118,9 +118,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ -distillCritical0 54 x := by @@ -141,9 +141,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 54 x := by @@ -164,9 +164,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 16) : (lo := 0) (hi := 16) (s := 16384) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (16 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (65 / 4) 17) : 0 ≤ distillCritical2 54 x := by @@ -175,9 +175,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (65 / 4) 17) : (lo := (65 / 4)) (hi := 17) (s := 81) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (65 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 54 α ≤ (163 / 500) := by @@ -219,9 +219,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ -distillCritical0 55 x := by @@ -242,9 +242,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 55 x := by @@ -265,9 +265,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (65 / 4)) : (lo := 0) (hi := (65 / 4)) (s := 54925) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((65 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 2) 17) : 0 ≤ distillCritical2 55 x := by @@ -276,9 +276,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 2) 17) : (lo := (33 / 2)) (hi := 17) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (33 / 2)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 55 α ≤ (33 / 100) := by @@ -320,9 +320,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ -distillCritical0 56 x := by @@ -343,9 +343,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 56 x := by @@ -366,9 +366,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (33 / 2)) : (lo := 0) (hi := (33 / 2)) (s := 43923) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((33 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (67 / 4) 17) : 0 ≤ distillCritical2 56 x := by @@ -377,9 +377,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (67 / 4) 17) : (lo := (67 / 4)) (hi := 17) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (67 / 4)) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : distillT2 56 α ≤ (167 / 500) := by @@ -421,9 +421,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ -distillCritical0 57 x := by @@ -444,9 +444,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 57 x := by @@ -467,9 +467,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 83521) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical2 57 x := by @@ -515,9 +515,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ -distillCritical0 58 x := by @@ -538,9 +538,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 58 x := by @@ -561,9 +561,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 83521) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical2 58 x := by @@ -609,9 +609,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 24137569) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ -distillCritical0 59 x := by @@ -632,9 +632,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 59 x := by @@ -655,9 +655,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 83521) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical2 59 x := by @@ -703,9 +703,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ -distillCritical0 60 x := by @@ -726,9 +726,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 410338673) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical1 60 x := by @@ -749,9 +749,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : (lo := 0) (hi := 17) (s := 83521) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : 0 ≤ distillCritical2 60 x := by diff --git a/Sendov/DistillationFinite/Rows5_12.lean b/Sendov/DistillationFinite/Rows5_12.lean index c1d3474..ac5fc39 100644 --- a/Sendov/DistillationFinite/Rows5_12.lean +++ b/Sendov/DistillationFinite/Rows5_12.lean @@ -17,9 +17,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (1 / 2)) : (lo := 0) (hi := (1 / 2)) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((1 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 4) (5 / 2)) : 0 ≤ -distillCritical0 5 x := by @@ -29,9 +29,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 4) (5 / 2)) : (lo := (3 / 4)) (hi := (5 / 2)) (s := 117649) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (3 / 4)) ((5 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : distillT0 5 α ≤ (101 / 500) := by @@ -52,9 +52,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (1 / 4) (5 / 2)) : (lo := (1 / 4)) (hi := (5 / 2)) (s := 4782969) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (1 / 4)) ((5 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : distillT1 5 α ≤ (191 / 1000) := by @@ -71,9 +71,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (1 / 2)) : (lo := 0) (hi := (1 / 2)) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((1 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 4) (5 / 2)) : 0 ≤ distillCritical2 5 x := by @@ -82,9 +82,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 4) (5 / 2)) : (lo := (3 / 4)) (hi := (5 / 2)) (s := 343) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (3 / 4)) ((5 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : distillT2 5 α ≤ (37 / 250) := by @@ -125,9 +125,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 1) : (lo := 0) (hi := 1) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (1 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 4) 3) : 0 ≤ -distillCritical0 6 x := by @@ -137,9 +137,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 4) 3) : (lo := (5 / 4)) (hi := 3) (s := 117649) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (5 / 4)) (3 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : distillT0 6 α ≤ (207 / 1000) := by @@ -156,9 +156,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (1 / 2)) : (lo := 0) (hi := (1 / 2)) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((1 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 4) 3) : 0 ≤ distillCritical1 6 x := by @@ -168,9 +168,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 4) 3) : (lo := (3 / 4)) (hi := 3) (s := 243) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (3 / 4)) (3 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : distillT1 6 α ≤ (171 / 1000) := by @@ -187,9 +187,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 4)) : (lo := 0) (hi := (3 / 4)) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((3 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 1 3) : 0 ≤ distillCritical2 6 x := by @@ -198,9 +198,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 1 3) : (lo := 1) (hi := 3) (s := 4) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 1) (3 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : distillT2 6 α ≤ (133 / 1000) := by @@ -242,9 +242,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 4)) : (lo := 0) (hi := (5 / 4)) (s := 15625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((5 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 2) (7 / 2)) : 0 ≤ -distillCritical0 7 x := by @@ -254,9 +254,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 2) (7 / 2)) : (lo := (3 / 2)) (hi := (7 / 2)) (s := 2048) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (3 / 2)) ((7 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : distillT0 7 α ≤ (211 / 1000) := by @@ -273,9 +273,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 4)) : (lo := 0) (hi := (3 / 4)) (s := 9) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((3 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 1 (7 / 2)) : 0 ≤ distillCritical1 7 x := by @@ -285,9 +285,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 1 (7 / 2)) : (lo := 1) (hi := (7 / 2)) (s := 78125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 1) ((7 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : distillT1 7 α ≤ (41 / 250) := by @@ -304,9 +304,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 1) : (lo := 0) (hi := 1) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (1 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 4) (7 / 2)) : 0 ≤ distillCritical2 7 x := by @@ -315,9 +315,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 4) (7 / 2)) : (lo := (5 / 4)) (hi := (7 / 2)) (s := 6561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (5 / 4)) ((7 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : distillT2 7 α ≤ (31 / 250) := by @@ -358,9 +358,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 2)) : (lo := 0) (hi := (3 / 2)) (s := 9) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((3 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 4) 4) : 0 ≤ -distillCritical0 8 x := by @@ -370,9 +370,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 4) 4) : (lo := (7 / 4)) (hi := 4) (s := 4782969) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (7 / 4)) (4 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : distillT0 8 α ≤ (43 / 200) := by @@ -389,9 +389,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 4)) : (lo := 0) (hi := (5 / 4)) (s := 15625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((5 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 2) 4) : 0 ≤ distillCritical1 8 x := by @@ -401,9 +401,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 2) 4) : (lo := (3 / 2)) (hi := 4) (s := 78125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (3 / 2)) (4 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : distillT1 8 α ≤ (157 / 1000) := by @@ -420,9 +420,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 2)) : (lo := 0) (hi := (3 / 2)) (s := 3) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((3 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 4) 4) : 0 ≤ distillCritical2 8 x := by @@ -431,9 +431,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 4) 4) : (lo := (7 / 4)) (hi := 4) (s := 6561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (7 / 4)) (4 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : distillT2 8 α ≤ (3 / 25) := by @@ -474,9 +474,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 2) : (lo := 0) (hi := 2) (s := 32) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (2 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 4) (9 / 2)) : 0 ≤ -distillCritical0 9 x := by @@ -486,9 +486,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 4) (9 / 2)) : (lo := (9 / 4)) (hi := (9 / 2)) (s := 81) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (9 / 4)) ((9 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : distillT0 9 α ≤ (11 / 50) := by @@ -504,9 +504,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 2)) : (lo := 0) (hi := (3 / 2)) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((3 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 4) (9 / 2)) : 0 ≤ distillCritical1 9 x := by @@ -516,9 +516,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 4) (9 / 2)) : (lo := (7 / 4)) (hi := (9 / 2)) (s := 19487171) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (7 / 4)) ((9 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : distillT1 9 α ≤ (39 / 250) := by @@ -535,9 +535,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (7 / 4)) : (lo := 0) (hi := (7 / 4)) (s := 2401) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((7 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 2 (9 / 2)) : 0 ≤ distillCritical2 9 x := by @@ -546,9 +546,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 2 (9 / 2)) : (lo := 2) (hi := (9 / 2)) (s := 125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 2) ((9 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : distillT2 9 α ≤ (3 / 25) := by @@ -590,9 +590,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 4)) : (lo := 0) (hi := (9 / 4)) (s := 2187) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((9 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 2) 5) : 0 ≤ -distillCritical0 10 x := by @@ -602,9 +602,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 2) 5) : (lo := (5 / 2)) (hi := 5) (s := 3125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (5 / 2)) (5 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : distillT0 10 α ≤ (9 / 40) := by @@ -621,9 +621,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (7 / 4)) : (lo := 0) (hi := (7 / 4)) (s := 823543) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((7 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 2 5) : 0 ≤ distillCritical1 10 x := by @@ -633,9 +633,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 2 5) : (lo := 2) (hi := 5) (s := 2187) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 2) (5 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : distillT1 10 α ≤ (31 / 200) := by @@ -652,9 +652,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 2) : (lo := 0) (hi := 2) (s := 4) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (2 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 4) 5) : 0 ≤ distillCritical2 10 x := by @@ -663,9 +663,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 4) 5) : (lo := (9 / 4)) (hi := 5) (s := 14641) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (9 / 4)) (5 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : distillT2 10 α ≤ (121 / 1000) := by @@ -707,9 +707,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 2)) : (lo := 0) (hi := (5 / 2)) (s := 15625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((5 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 4) (11 / 2)) : 0 ≤ -distillCritical0 11 x := by @@ -719,9 +719,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 4) (11 / 2)) : (lo := (11 / 4)) (hi := (11 / 2)) (s := 1771561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (11 / 4)) ((11 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : distillT0 11 α ≤ (229 / 1000) := by @@ -738,9 +738,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 4)) : (lo := 0) (hi := (9 / 4)) (s := 6561) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((9 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 2) (11 / 2)) : 0 ≤ distillCritical1 11 x := by @@ -750,9 +750,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 2) (11 / 2)) : (lo := (5 / 2)) (hi := (11 / 2)) (s := 17496) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (5 / 2)) ((11 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : distillT1 11 α ≤ (77 / 500) := by @@ -769,9 +769,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 2)) : (lo := 0) (hi := (5 / 2)) (s := 125) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((5 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 4) (11 / 2)) : 0 ≤ distillCritical2 11 x := by @@ -780,9 +780,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 4) (11 / 2)) : (lo := (11 / 4)) (hi := (11 / 2)) (s := 1331) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (11 / 4)) ((11 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : distillT2 11 α ≤ (61 / 500) := by @@ -823,9 +823,9 @@ private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 3) : (lo := 0) (hi := 3) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (3 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 4) 6) : 0 ≤ -distillCritical0 12 x := by @@ -835,9 +835,9 @@ private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 4) 6) : (lo := (13 / 4)) (hi := 6) (s := 19487171) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (13 / 4)) (6 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : distillT0 12 α ≤ (47 / 200) := by @@ -854,9 +854,9 @@ private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 2)) : (lo := 0) (hi := (5 / 2)) (s := 15625) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((5 / 2) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 4) 6) : 0 ≤ distillCritical1 12 x := by @@ -866,9 +866,9 @@ private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 4) 6) : (lo := (11 / 4)) (hi := 6) (s := 62748517) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - (11 / 4)) (6 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : distillT1 12 α ≤ (31 / 200) := by @@ -885,9 +885,9 @@ private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (11 / 4)) : (lo := 0) (hi := (11 / 4)) (s := 14641) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) ((11 / 4) - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 3 6) : 0 ≤ distillCritical2 12 x := by @@ -896,9 +896,9 @@ private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 3 6) : (lo := 3) (hi := 6) (s := 1) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 3) (6 - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : distillT2 12 α ≤ (1 / 8) := by diff --git a/Sendov/DistillationFinite/Rows61_61.lean b/Sendov/DistillationFinite/Rows61_61.lean new file mode 100644 index 0000000..32aca56 --- /dev/null +++ b/Sendov/DistillationFinite/Rows61_61.lean @@ -0,0 +1,96 @@ +import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.BernsteinList + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow61 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 61 x := by + refine (BernsteinCert.coeffs_pos + [2019781980, 56430214272, 601686039834, 3036073584816, 7326547127832, 8167105809971, + 6087236209110, 1044305251249] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 61 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 61 α ≤ (57 / 250) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 61 x := by + refine (BernsteinCert.coeffs_pos + [48537024120, 1418814495216, 16199029223856, 91304072373456, 266199727275870, + 395856838633324, 299684953990290, 59281036043180] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 61 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 61 α ≤ (13 / 250) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 58 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical2 61 x := by + refine (BernsteinCert.coeffs_pos + [2865780, 41674500, 164428314, 144912610, 9604580] + (lo := 0) (hi := 17) (s := 83521) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical2 61 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 61 α ≤ (81 / 250) := by + apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) + 58 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow61 + +theorem distillFinite_61 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 61 + distillT0 61 α + distillT1 61 α + distillT2 61 α ≤ (19754 / 22875) := by + have h0 := CriticalRow61.component0 α hα hd + have h1 := CriticalRow61.component1 α hα hd + have h2 := CriticalRow61.component2 α hα hd + norm_num [distillEBudget] at * + linarith + +theorem distillFiniteBound_61 : ((19754 / 22875) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end diff --git a/Sendov/DistillationFinite/Rows61_64.lean b/Sendov/DistillationFinite/Rows61_64.lean deleted file mode 100644 index e4c47ef..0000000 --- a/Sendov/DistillationFinite/Rows61_64.lean +++ /dev/null @@ -1,378 +0,0 @@ -import Sendov.Common.DistillationCriticalFinite -import Sendov.Common.BernsteinList - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow61 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 61 x := by - refine (BernsteinCert.coeffs_pos - [2019781980, 56430214272, 601686039834, 3036073584816, 7326547127832, 8167105809971, - 6087236209110, 1044305251249] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 61 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 61 α ≤ (57 / 250) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 61 x := by - refine (BernsteinCert.coeffs_pos - [48537024120, 1418814495216, 16199029223856, 91304072373456, 266199727275870, - 395856838633324, 299684953990290, 59281036043180] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 61 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 61 α ≤ (13 / 250) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 58 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 61 x := by - refine (BernsteinCert.coeffs_pos - [2865780, 41674500, 164428314, 144912610, 9604580] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 61 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 61 α ≤ (81 / 250) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 58 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow61 - -theorem distillFinite_61 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 61 + distillT0 61 α + distillT1 61 α + distillT2 61 α ≤ (19754 / 22875) := by - have h0 := CriticalRow61.component0 α hα hd - have h1 := CriticalRow61.component1 α hα hd - have h2 := CriticalRow61.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_61 : ((19754 / 22875) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow62 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 62 x := by - refine (BernsteinCert.coeffs_pos - [2088147600, 58363860528, 622673236872, 3144822771528, 7599323583912, 8480770304396, - 6303218922668, 1129772656152] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 62 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 62 α ≤ (28 / 125) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 62 x := by - refine (BernsteinCert.coeffs_pos - [50985151920, 1490806806624, 17028105515712, 96038256547008, 280290993952668, - 417554234747800, 317279147669572, 64723256786664] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 62 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 62 α ≤ (23 / 500) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 59 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 62 x := by - refine (BernsteinCert.coeffs_pos - [2962980, 43128180, 170595606, 152194094, 12075252] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 62 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 62 α ≤ (323 / 1000) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 59 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow62 - -theorem distillFinite_62 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 62 + distillT0 62 α + distillT1 62 α + distillT2 62 α ≤ (39637 / 46500) := by - have h0 := CriticalRow62.component0 α hα hd - have h1 := CriticalRow62.component1 α hα hd - have h2 := CriticalRow62.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_62 : ((39637 / 46500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow63 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 63 x := by - refine (BernsteinCert.coeffs_pos - [2157650460, 60330022128, 644018447754, 3255460092216, 7876889404848, 8799519807675, - 6520953157434, 1215134440029] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 63 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 63 α ≤ (221 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 63 x := by - refine (BernsteinCert.coeffs_pos - [53514140400, 1565188643304, 17884877054328, 100931879360376, 294861005590032, - 439990591421070, 335461676533128, 70359545058546] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 63 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 63 α ≤ (41 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 60 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 63 x := by - refine (BernsteinCert.coeffs_pos - [3061800, 44606700, 176874516, 159630774, 14612722] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 63 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 63 α ≤ (8 / 25) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 60 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow63 - -theorem distillFinite_63 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 63 + distillT0 63 α + distillT1 63 α + distillT2 63 α ≤ (11357 / 13500) := by - have h0 := CriticalRow63.component0 α hα hd - have h1 := CriticalRow63.component1 α hα hd - have h2 := CriticalRow63.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_63 : ((11357 / 13500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow64 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 64 x := by - refine (BernsteinCert.coeffs_pos - [2228290560, 62328699072, 665721672480, 3367985546880, 8159244590640, 9123354319808, - 6740438913408, 1300390602880] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 64 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 64 α ≤ (217 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 64 x := by - refine (BernsteinCert.coeffs_pos - [56125301760, 1641998933856, 18769797054144, 105987560298480, 309917617773216, - 463177734270976, 354241061314560, 76192247672960] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 64 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 64 α ≤ (37 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 61 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 64 x := by - refine (BernsteinCert.coeffs_pos - [3162240, 46110060, 183265044, 167222650, 17216990] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - 0) (17 - x) - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 64 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 64 α ≤ (317 / 1000) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 61 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow64 - -theorem distillFinite_64 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 64 + distillT0 64 α + distillT1 64 α + distillT2 64 α ≤ (79691 / 96000) := by - have h0 := CriticalRow64.component0 α hα hd - have h1 := CriticalRow64.component1 α hα hd - have h2 := CriticalRow64.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_64 : ((79691 / 96000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end diff --git a/Sendov/LargeDegree/DistillationTail.lean b/Sendov/LargeDegree/DistillationTail.lean index 342c686..bb4cda9 100644 --- a/Sendov/LargeDegree/DistillationTail.lean +++ b/Sendov/LargeDegree/DistillationTail.lean @@ -6,8 +6,8 @@ import Sendov.Common.DistillationFactors New Lean adaptation of Senjian An, *Proof Distillation for Sendov's Conjecture*, revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, lines 898--950. Paper: CC BY 4.0, https://creativecommons.org/licenses/by/4.0/ . -The degree-64 reduction uses the actual dependence of the rational denominator -on alpha; the old independent denominator bound only starts at 81. +The m=61 reduction uses the actual dependence of the rational denominator +on alpha and the stronger decay from `cubicPolarEnvelope 17 <= (21/22)^4`. Finite base certificates remain separate. No raw scalar value at alpha zero is identified with a continuous extension. -/ @@ -57,7 +57,7 @@ lemma distillEBudget_antitone_on {K : ℝ} (hK : 0 < K) : exact div_le_div_of_nonneg_left (by norm_num) (by linarith : 0 < 12 * m) (by linarith) -lemma distillEBudget_antitone : AntitoneOn distillEBudget (Set.Ici 64) := +lemma distillEBudget_antitone : AntitoneOn distillEBudget (Set.Ici 61) := distillEBudget_antitone_on (by norm_num) lemma cubicPolarEnvelope_le_five_sixths {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : @@ -66,6 +66,10 @@ lemma cubicPolarEnvelope_le_five_sixths {α : ℝ} (hα : 0 ≤ α) (hα17 : α cubicPolarEnvelope α ≤ cubicPolarEnvelope 17 := cubicPolarEnvelope_mono hα hα17 _ ≤ 5 / 6 := by norm_num [cubicPolarEnvelope] +lemma cubicPolarEnvelope_le_decay_base {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : + cubicPolarEnvelope α ≤ (21 / 22) ^ 4 := + (cubicPolarEnvelope_mono hα hα17).trans (by norm_num [cubicPolarEnvelope]) + lemma distillNode_antitone_degree_on {K α : ℝ} (hK : 0 < K) (hα : 0 ≤ α) : AntitoneOn (fun m => distillNode m α) (Set.Ici K) := by intro m hm n _ hmn @@ -76,13 +80,13 @@ lemma distillNode_antitone_degree_on {K α : ℝ} (hK : 0 < K) (hα : 0 ≤ α) (by linarith : 0 < 25 * m) (by linarith) lemma distillNode_antitone_degree {α : ℝ} (hα : 0 ≤ α) : - AntitoneOn (fun m => distillNode m α) (Set.Ici 64) := + AntitoneOn (fun m => distillNode m α) (Set.Ici 61) := distillNode_antitone_degree_on (by norm_num) hα -lemma distillNode_lt_four_fifths {m α : ℝ} (hm : 64 ≤ m) +lemma distillNode_lt_four_fifths {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : distillNode m α < 4 / 5 := by have he := cubicPolarEnvelope_le_five_sixths hα hα17 - have ht : 12 * α / (25 * m) ≤ 51 / 400 := by + have ht : 12 * α / (25 * m) ≤ 204 / 1525 := by apply (div_le_iff₀ (by linarith : 0 < 25 * m)).mpr linarith unfold distillNode @@ -123,11 +127,13 @@ private lemma kappa_slope_le {K m α : ℝ} (hK : 34 < K) (hm : K ≤ m) div_le_div_of_nonneg_left (by norm_num) (by linarith) (by linarith) linarith only [h1, h2, h3] -/-- Explicit sufficient conditions on the start, rather than an assumed derivative sign. -/ -lemma distillKappa_rpow_antitone_on {K α z : ℝ} (hK : 34 < K) - (hdecay : 1 / (K - 1) + 2 / (K - 34) ≤ 1 / 12) +/-- A rational power cap retains stronger logarithmic decay without a log estimate +or a derivative sign as a caller premise. Since `K > 34`, the positive left side +of `hdecay` already forces `n > 0` and `q < 1`; no extra premises are needed. -/ +lemma distillKappa_rpow_antitone_of_pow {K α z q : ℝ} (n : ℕ) (hK : 34 < K) + (hdecay : 1 / (K - 1) + 2 / (K - 34) ≤ n * (1 - q) / 2) (hα : 0 ≤ α) (hα17 : α ≤ 17) - (hz : 0 ≤ z) (hz1 : z ≤ 5 / 6) : + (hz : 0 ≤ z) (hq : 0 < q) (hz1 : z ≤ q ^ n) : AntitoneOn (fun m => distillKappa m α * z ^ ((m - 3) / 2)) (Set.Ici K) := by rcases hz.eq_or_lt with rfl | hz · intro m hm n hn _ @@ -144,24 +150,36 @@ lemma distillKappa_rpow_antitone_on {K α z : ℝ} (hK : 34 < K) apply mul_nonpos_of_nonneg_of_nonpos · exact mul_nonneg (distillKappa_nonneg (by linarith) hα) (Real.rpow_nonneg hz.le _) · have hk := kappa_slope_le hK hm hα17 - have hl := Real.log_le_sub_one_of_pos hz + have hl := Real.log_le_log hz hz1 + rw [Real.log_pow] at hl + have hqlog := mul_le_mul_of_nonneg_left (Real.log_le_sub_one_of_pos hq) + (Nat.cast_nonneg n : (0 : ℝ) ≤ n) linarith -private lemma kappa_rpow_antitone {α z : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) +/-- The original sufficient condition remains a special case. -/ +lemma distillKappa_rpow_antitone_on {K α z : ℝ} (hK : 34 < K) + (hdecay : 1 / (K - 1) + 2 / (K - 34) ≤ 1 / 12) + (hα : 0 ≤ α) (hα17 : α ≤ 17) (hz : 0 ≤ z) (hz1 : z ≤ 5 / 6) : - AntitoneOn (fun m => distillKappa m α * z ^ ((m - 3) / 2)) (Set.Ici 64) := - distillKappa_rpow_antitone_on (by norm_num) (by norm_num) hα hα17 hz hz1 + AntitoneOn (fun m => distillKappa m α * z ^ ((m - 3) / 2)) (Set.Ici K) := + distillKappa_rpow_antitone_of_pow 1 hK (by norm_num at *; exact hdecay) + hα hα17 hz (by norm_num : (0 : ℝ) < 5 / 6) (by simpa using hz1) + +private lemma kappa_rpow_antitone {α z : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) + (hz : 0 ≤ z) (hz1 : z ≤ (21 / 22) ^ 4) : + AntitoneOn (fun m => distillKappa m α * z ^ ((m - 3) / 2)) (Set.Ici 61) := + distillKappa_rpow_antitone_of_pow 4 (by norm_num) (by norm_num) + hα hα17 hz (by norm_num : (0 : ℝ) < 21 / 22) hz1 /-- Real-degree antitonicity; the node itself also decreases with the degree. -/ lemma distillT1_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : - AntitoneOn (fun m => distillT1 m α) (Set.Ici 64) := by + AntitoneOn (fun m => distillT1 m α) (Set.Ici 61) := by intro m hm n hn hmn - have hm' : 64 ≤ m := hm - have hn' : 64 ≤ n := hn + have hm' : 61 ≤ m := hm + have hn' : 61 ≤ n := hn have hz := distillNode_pos (by linarith : 0 < m) hα - have hz1 : distillNode m α ≤ 5 / 6 := by - have := distillNode_lt_four_fifths hm' hα hα17 - linarith + have hz1 : distillNode m α ≤ (21 / 22) ^ 4 := + (distillNode_lt_four_fifths hm' hα hα17).le.trans (by norm_num) have hpow := Real.rpow_le_rpow (distillNode_pos (by linarith : 0 < n) hα).le (distillNode_antitone_degree hα hm hn hmn) (by linarith : 0 ≤ (n - 3) / 2) have hstep := (mul_le_mul_of_nonneg_left hpow @@ -172,14 +190,14 @@ lemma distillT1_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : /-- The zero-alpha case is included by the zero-base real-power case. -/ lemma distillT2_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : - AntitoneOn (fun m => distillT2 m α) (Set.Ici 64) := by + AntitoneOn (fun m => distillT2 m α) (Set.Ici 61) := by intro m hm n hn hmn have hstep := kappa_rpow_antitone hα hα17 (cubicPolarEnvelope_nonneg hα) - (cubicPolarEnvelope_le_five_sixths hα hα17) hm hn hmn + (cubicPolarEnvelope_le_decay_base hα hα17) hm hn hmn have := mul_le_mul_of_nonneg_left hstep (by norm_num : (0 : ℝ) ≤ 421 / 3125) simpa only [distillT2, mul_assoc] using this -lemma distillT2_zero {m : ℝ} (hm : 64 ≤ m) : distillT2 m 0 = 0 := by +lemma distillT2_zero {m : ℝ} (hm : 61 ≤ m) : distillT2 m 0 = 0 := by have hs : (m - 3) / 2 ≠ 0 := by linarith simp [distillT2, cubicPolarEnvelope, Real.zero_rpow hs] @@ -187,14 +205,14 @@ private def tailP (m α : ℝ) : ℝ := 7 * m ^ 4 - 30 * α * m ^ 3 - (8 * α ^ 2 + 96 * α + 105) * m ^ 2 + (90 * α - 128 * α ^ 2) * m - 360 * α ^ 2 -private lemma tailP_pos {m α : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) (hα12 : α ≤ 12) : +private lemma tailP_pos {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (hα12 : α ≤ 12) : 0 < tailP m α := by have hm0 : 0 ≤ m := by linarith - have hx : 0 ≤ m - 64 := by linarith + have hx : 0 ≤ m - 61 := by linarith have hgap : 0 ≤ 12 - α := by linarith have hid : tailP m α = - 7 * (m - 64) ^ 4 + 1432 * (m - 64) ^ 3 + 100503 * (m - 64) ^ 2 + - 2590648 * (m - 64) + 12039040 + + 7 * (m - 61) ^ 4 + 1348 * (m - 61) ^ 3 + 87993 * (m - 61) ^ 2 + + 2025538 * (m - 61) + 5133526 + (12 - α) * (α * (8 * m ^ 2 + 128 * m + 360) + 30 * m ^ 3 + 192 * m ^ 2 + 1446 * m + 4320) := by dsimp [tailP] @@ -206,16 +224,16 @@ private noncomputable def tailQ (m α d : ℝ) : ℝ := d * tailP m α / 7 + (21 / 25 - d) * (4 * α / 7) * ((3 * m - 2 * α) * m ^ 2 + 32 * (m - α) * m + (75 * m - 90 * α)) -private lemma tailQ_cap_pos {m α : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) +private lemma tailQ_cap_pos {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : 0 < tailQ m α (2 / 5) := by have hm0 : 0 ≤ m := by linarith - have hx : 0 ≤ m - 64 := by linarith + have hx : 0 ≤ m - 61 := by linarith have hgap : 0 ≤ 17 - α := by linarith have hquad : 0 ≤ 24 * m ^ 2 - 64 * m - 600 := by nlinarith have hid : tailQ m α (2 / 5) = - (2 / 5) * (m - 64) ^ 4 + (2152 / 25) * (m - 64) ^ 3 + - (161426 / 25) * (m - 64) ^ 2 + (4603736 / 25) * (m - 64) + - 29487816 / 25 + + (2 / 5) * (m - 61) ^ 4 + (2032 / 25) * (m - 61) ^ 3 + + (142598 / 25) * (m - 61) ^ 2 + (3692204 / 25) * (m - 61) + + 17072148 / 25 + (17 - α) * ((24 / 25) * (α + 17) * (m ^ 2 + 16 * m + 45) + m * (24 * m ^ 2 - 64 * m - 600) / 25) := by dsimp [tailQ, tailP] @@ -223,7 +241,7 @@ private lemma tailQ_cap_pos {m α : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) rw [hid] positivity -private lemma tailQ_pos {m α d : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) +private lemma tailQ_pos {m α d : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) (hd : 0 < d) (hd1 : d ≤ 21 / 25) (hdα : 12 ≤ α → d ≤ 2 / 5) : 0 < tailQ m α d := by have hm0 : 0 ≤ m := by linarith @@ -248,13 +266,13 @@ private lemma tailQ_pos {m α d : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) private noncomputable def tailRational (m α d : ℝ) : ℝ := m ^ 3 * (m - 2 * α) ^ 2 / ((m + 3) * (m + 5) * (d * m - 12 * α / 25) ^ 4) -private lemma tail_den_pos {m α d : ℝ} (hm : 64 ≤ m) (hα17 : α ≤ 17) +private lemma tail_den_pos {m α d : ℝ} (hm : 61 ≤ m) (hα17 : α ≤ 17) (hd : 17 / 50 ≤ d) : 0 < d * m - 12 * α / 25 := by have hm0 : 0 ≤ m := by linarith have hd0 : 0 ≤ d - 17 / 50 := by linarith nlinarith [mul_nonneg hd0 hm0] -private lemma rational_slope {m α d : ℝ} (hm : 64 ≤ m) (hα17 : α ≤ 17) +private lemma rational_slope {m α d : ℝ} (hm : 61 ≤ m) (hα17 : α ≤ 17) (hd : 17 / 50 ≤ d) : HasDerivAt (fun x => tailRational x α d) (tailRational m α d * (3 / m + 2 / (m - 2 * α) - 1 / (m + 3) - @@ -281,7 +299,7 @@ private lemma rational_slope {m α d : ℝ} (hm : 64 ≤ m) (hα17 : α ≤ 17) · dsimp [tailRational] ring -private lemma rational_slope_neg {m α d : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) +private lemma rational_slope_neg {m α d : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) (hd : 17 / 50 ≤ d) (hd1 : d ≤ 21 / 25) (hdα : 12 ≤ α → d ≤ 2 / 5) : 3 / m + 2 / (m - 2 * α) - 1 / (m + 3) - 1 / (m + 5) - @@ -307,7 +325,7 @@ private lemma rational_slope_neg {m α d : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) private lemma tailRational_antitone {α d : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) (hd : 17 / 50 ≤ d) (hd1 : d ≤ 21 / 25) (hdα : 12 ≤ α → d ≤ 2 / 5) : - AntitoneOn (fun m => tailRational m α d) (Set.Ici 64) := by + AntitoneOn (fun m => tailRational m α d) (Set.Ici 61) := by apply tail_antitone (fun m hm => rational_slope hm hα17 hd) intro m hm have hm0 : 0 ≤ m := by linarith @@ -316,7 +334,7 @@ private lemma tailRational_antitone {α d : ℝ} (hα : 0 ≤ α) (hα17 : α exact mul_nonpos_of_nonneg_of_nonpos (by unfold tailRational; positivity) (rational_slope_neg hm hα hα17 hd hd1 hdα).le -private lemma distillT0_eq_rational {m α : ℝ} (hm : 64 ≤ m) +private lemma distillT0_eq_rational {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : distillT0 m α = (24 * (3 / 5) ^ 4 * distillRatio α) * tailRational m α (21 / 25 - 3 / 5 * cubicPolarEnvelope α) := by @@ -344,7 +362,7 @@ private lemma distillT0_eq_rational {m α : ℝ} (hm : 64 ≤ m) /-- Real-degree antitonicity of the regularized rational component, including alpha zero. -/ lemma distillT0_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : - AntitoneOn (fun m => distillT0 m α) (Set.Ici 64) := by + AntitoneOn (fun m => distillT0 m α) (Set.Ici 61) := by have he := cubicPolarEnvelope_nonneg hα have he1 := cubicPolarEnvelope_le_five_sixths hα hα17 have hd : 17 / 50 ≤ 21 / 25 - 3 / 5 * cubicPolarEnvelope α := by linarith @@ -362,9 +380,9 @@ lemma distillT0_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : (mul_nonneg (by norm_num) (distillRatio_nonneg hα)) /-- The earlier pointwise reduction holds on the full closed alpha interval. -/ -lemma distillComponents_le_64 {m α : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : +lemma distillComponents_le_61 {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α ≤ - distillEBudget 64 + distillT0 64 α + distillT1 64 α + distillT2 64 α := by + distillEBudget 61 + distillT0 61 α + distillT1 61 α + distillT2 61 α := by exact add_le_add (add_le_add (add_le_add (distillEBudget_antitone (by simp) hm hm) (distillT0_antitone hα hα17 (by simp) hm hm)) diff --git a/Sendov/LargeDegree/DistillationTailBound.lean b/Sendov/LargeDegree/DistillationTailBound.lean index 7c314d9..aa86f91 100644 --- a/Sendov/LargeDegree/DistillationTailBound.lean +++ b/Sendov/LargeDegree/DistillationTailBound.lean @@ -1,12 +1,12 @@ import Sendov.Common.DistillationMajorant import Sendov.LargeDegree.DistillationTail -import Sendov.DistillationFinite.Rows61_64 +import Sendov.DistillationFinite.Rows61_61 /-! # The proved infinite tail -The existing critical-point row at `m = 64` supplies the earlier `<199/200` -tail, starting at polynomial degree 65. No finite base or monotonicity is assumed. +The existing critical-point row at `m = 61` supplies the earlier `<199/200` +tail, starting at polynomial degree 62. No finite base or monotonicity is assumed. The underlying mathematical route is Senjian An's *Proof Distillation for Sendov's Conjecture*, revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, Sections 7--8 (CC BY 4.0, https://creativecommons.org/licenses/by/4.0/). @@ -15,16 +15,16 @@ Conjecture*, revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, Sections 7--8 namespace Sendov /-- The existing finite row closes the earlier tail on the full closed alpha -domain, including zero. No stronger degree-64 certificate is required. -/ -theorem distillComponents_lt_199_200 {m α : ℝ} (hm : 64 ≤ m) +domain, including zero. No stronger row certificate at m=61 is required. -/ +theorem distillComponents_lt_199_200 {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (h17 : α ≤ 17) : distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := - (distillComponents_le_64 hm hα h17).trans_lt - ((distillFinite_64 α hα h17).trans_lt distillFiniteBound_64) + (distillComponents_le_61 hm hα h17).trans_lt + ((distillFinite_61 α hα h17).trans_lt distillFiniteBound_61) /-- Earlier raw scalar tail. Positive alpha is intentional; all of `α ≤ 17` is covered, and `2 * α ≤ m` follows from the degree threshold. -/ -theorem distillScalar_lt_199_200 {m α : ℝ} (hm : 64 ≤ m) +theorem distillScalar_lt_199_200 {m α : ℝ} (hm : 61 ≤ m) (hα : 0 < α) (h17 : α ≤ 17) : scalarObstruction m α (cubicPolarEnvelope α) < 199 / 200 := by exact (distillScalar_le_majorant (by linarith) hα (by linarith)).trans_lt diff --git a/Sendov/Reduction/Alpha17.lean b/Sendov/Reduction/Alpha17.lean index e7153e2..6891cb7 100644 --- a/Sendov/Reduction/Alpha17.lean +++ b/Sendov/Reduction/Alpha17.lean @@ -88,7 +88,7 @@ lemma tail_poly_bound {v : ℝ} (hv : 0 ≤ v) : have hneg : exp (-(2.83 * v)) = (exp (2.83 * v))⁻¹ := Real.exp_neg _ rw [hneg, mul_inv_le_iff₀ hpos] refine le_trans ?_ (mul_le_mul_of_nonneg_left hexp (by norm_num : (0:ℝ) ≤ 0.4118)) - nlinarith [hv, sq_nonneg v, sq_nonneg (v - 1 / 2), pow_nonneg hv 3] + nlinarith only [hv, sq_nonneg v, sq_nonneg (v - 1 / 2), pow_nonneg hv 3] /-! ### The bound -/ @@ -130,11 +130,11 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) calc a * x ≤ a * 1 := mul_le_mul_of_nonneg_left hxle ha.le _ ≤ 1 := by simpa only [mul_one] using ha1.le have hxpos : 0 < x := (mul_pos_iff_of_pos_left ha).mp hax - have hr : (0 : ℝ) < r := by rw [hrdef]; rw [hMn] at hM34; linarith + have hr : (0 : ℝ) < r := by rw [hrdef]; rw [hMn] at hM34; linarith only [hM34] -- `log α ≥ 2.83` have hlog17 : (2.83 : ℝ) ≤ Real.log α := le_trans log_seventeen_ge (Real.log_le_log (by norm_num) hcon.le) - have hlogpos : (0 : ℝ) < Real.log α := by linarith + have hlogpos : (0 : ℝ) < Real.log α := lt_of_lt_of_le (by norm_num) hlog17 -- `x² ≥ 1 - β(1) ≥ log α / α` have hxsq : Real.log α / α ≤ x ^ 2 := by have h1 : 1 - B1 ≤ x ^ 2 := by @@ -149,12 +149,12 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) have hprod : (r + 1) * (r + 2) = (n : ℝ) * ((n : ℝ) + 2) / 4 := by rw [hrdef]; ring have hane : (a : ℝ) ≠ 0 := ha.ne' have hxne : (x : ℝ) ≠ 0 := hxpos.ne' - have hnpos : (0 : ℝ) < (n : ℝ) := by rw [hMn] at hM34; linarith + have hnpos : (0 : ℝ) < (n : ℝ) := by rw [hMn] at hM34; linarith only [hM34] have hbeta_term : a ^ 2 * n * M n * (1 / ((a * x) ^ 2 * ((r + 1) * (r + 2)))) = 4 * M n / (x ^ 2 * ((n : ℝ) + 2)) := by rw [hprod] have hn0 : (n : ℝ) ≠ 0 := hnpos.ne' - have hn2' : (n : ℝ) + 2 ≠ 0 := by linarith + have hn2' : (n : ℝ) + 2 ≠ 0 := by positivity field_simp have hcoefnn : (0 : ℝ) ≤ a ^ 2 * n * M n := by positivity have hstep : a ^ 2 * n * M n * I1 @@ -177,7 +177,7 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) linarith only [hlogx] exact h1.trans h2 have hfirst : (1 - x ^ 2) / (2 * M n) ≤ 1 / (2 * M n) := by - have hD : (0 : ℝ) < 2 * M n := by linarith + have hD : (0 : ℝ) < 2 * M n := by positivity exact div_le_div_of_nonneg_right (sub_le_self 1 (sq_nonneg x)) hD.le have hmain : 2 * α ≤ 1 / (2 * M n) + 4 * α / Real.log α + a ^ 2 * n * M n * (B1 ^ r / 2) := by linarith only [horigin, hstep, hfourx, hfirst, hax] @@ -185,21 +185,19 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) -- `obtain` rather than `set`: a `set` binding is a local *definition*, which `linarith` -- zeta-reduces back into `M n / (2 * α) - 1`, making its goals nonlinear in `α` obtain ⟨v, hvdef⟩ : ∃ w : ℝ, w = M n / (2 * α) - 1 := ⟨_, rfl⟩ - have h2α : (0 : ℝ) < 2 * α := by linarith + have h2α : (0 : ℝ) < 2 * α := by positivity have hv0 : 0 ≤ v := by rw [hvdef, sub_nonneg, le_div_iff₀ h2α, one_mul] exact hMge have hMv : M n = 2 * α * (v + 1) := by - rw [hvdef] - field_simp - ring + rw [hvdef, sub_add_cancel, mul_div_cancel₀ _ h2α.ne'] have ha2 : a ^ 2 = 1 - 2 * α / M n := by rw [hα] field_simp ring have hav : a ^ 2 * M n / (2 * α) = v := by - rw [ha2, hvdef] - field_simp + rw [ha2, sub_mul, one_mul, div_mul_cancel₀ _ hM.ne', sub_div, + div_self h2α.ne', hvdef] -- `β(1) ≤ exp(-log α/α)`, hence `β(1)^r ≤ exp(-(v+1)log α) exp(log α/(2α))` have hB1exp : B1 ≤ exp (-(Real.log α / α)) := by have h1 : B1 ≤ exp (B1 - 1) := by @@ -228,7 +226,7 @@ theorem alpha_le_seventeen {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) have hvexp : exp (-(v * Real.log α)) ≤ exp (-(2.83 * v)) := Real.exp_le_exp.2 (by simpa only [mul_comm] using neg_le_neg (mul_le_mul_of_nonneg_right hlog17 hv0)) - have he1 : (2.7 : ℝ) < exp 1 := by linarith [Real.exp_one_gt_d9] + have he1 : (2.7 : ℝ) < exp 1 := lt_trans (by norm_num) Real.exp_one_gt_d9 have hsecexp : exp (Real.log α / (2 * α)) ≤ 1 / (1 - 0.1852) := by refine le_trans (Real.exp_le_exp.2 ?_) (exp_le_one_div_one_sub (by norm_num)) have h := log_le_div_exp_one hα0 diff --git a/Sendov/Reduction/Simplified.lean b/Sendov/Reduction/Simplified.lean index 69a410f..fabc3d1 100644 --- a/Sendov/Reduction/Simplified.lean +++ b/Sendov/Reduction/Simplified.lean @@ -216,8 +216,8 @@ theorem one_le_of_origin (hn : 5 ≤ n) (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 * (1 / ((a * x) ^ 2 * (((n : ℝ) - 1) * (n : ℝ)))) = 1 / x ^ 2 := by have hane : (a : ℝ) ≠ 0 := ha.ne' have hxne : (x : ℝ) ≠ 0 := hxpos.ne' - have hn1 : ((n : ℝ) - 1) ≠ 0 := by linarith - have hn0 : (n : ℝ) ≠ 0 := by linarith + have hn1 : ((n : ℝ) - 1) ≠ 0 := by linarith only [hnR] + have hn0 : (n : ℝ) ≠ 0 := by linarith only [hnR] rw [hMn] field_simp have hkey : a ^ 2 * n * M n @@ -234,13 +234,13 @@ theorem one_le_of_origin (hn : 5 ≤ n) (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 have hlast : (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) * (1 - x ^ 2) / 2 * I3 ≤ (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) * B1 / 2 * I3 := by have hc : (0 : ℝ) ≤ (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) / 2 := by - have : (0 : ℝ) ≤ (n : ℝ) - 2 := by linarith + have : (0 : ℝ) ≤ (n : ℝ) - 2 := by linarith only [hnR] positivity simpa only [mul_div_right_comm] using mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left hone_sub hc) hI3nn have hfirst : (1 - x ^ 2) / (2 * M n) ≤ B1 / (2 * M n) := by apply div_le_div_of_nonneg_right hone_sub (by positivity) - have hne1 : (1 : ℝ) - B1 ≠ 0 := by linarith + have hne1 : (1 : ℝ) - B1 ≠ 0 := (sub_pos.mpr hB1lt).ne' have hrec : 1 / (1 - B1) = 1 + B1 / (1 - B1) := by field_simp ring @@ -249,10 +249,10 @@ theorem one_le_of_origin (hn : 5 ≤ n) (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 -- integral, and the resulting atom would no longer match `hkey` linarith only [horigin, hkey, hinv', hfirst, hlast, hax_eq] -- divide by `2α` - have h2α : (0 : ℝ) < 2 * α := by linarith + have h2α : (0 : ℝ) < 2 * α := by positivity -- Divide the assembled inequality once; normalize all five terms together. have hscaled := div_le_div_of_nonneg_right hmain h2α.le - have hne : (1 : ℝ) - B1 ≠ 0 := by linarith + have hne : (1 : ℝ) - B1 ≠ 0 := (sub_pos.mpr hB1lt).ne' convert hscaled using 1 · rfl · exact (div_self h2α.ne').symm diff --git a/data/README.md b/data/README.md index a27330c..3b7fd2d 100644 --- a/data/README.md +++ b/data/README.md @@ -1,7 +1,7 @@ # Exact mathematical table `paper_certificate_table.json` is the unchanged ordered subset of records -`m = 5,...,64` (60 records) from Senjian An's mathematical certificate table, +`m = 5,...,61` (57 records) from Senjian An's mathematical certificate table, *Proof Distillation for Sendov's Conjecture*, [SJanPerth/Sendov-Proof-Distillation](https://github.com/SJanPerth/Sendov-Proof-Distillation/blob/e8ae601491ec171ab4f7f8456113dd6a047aa85d/verification/paper_certificate_table.json), fixed revision **e8ae601491ec171ab4f7f8456113dd6a047aa85d**. @@ -10,8 +10,8 @@ The mathematical paper/table is attributed under [Creative Commons Attribution 4.0 International](https://creativecommons.org/licenses/by/4.0/); `LICENSE-PAPER.txt` retains the source's notice and legal-code link. No table values, retained row order, component IDs/order or budgets were changed. Records -65 through 81 were removed because the proved real-parameter tail now starts -at 64 and uses the original row-64 budget. This is a selected subset, not a +62 through 81 were removed because the proved real-parameter tail now starts +at 61 and uses the original row-61 budget. This is a selected subset, not a verbatim copy of the complete donor table. The project generates its own Lean certificate source; the table itself is not a formal proof. diff --git a/data/paper_certificate_table.json b/data/paper_certificate_table.json index 2bfde37..aa0b06c 100644 --- a/data/paper_certificate_table.json +++ b/data/paper_certificate_table.json @@ -2107,116 +2107,5 @@ } ], "total": "19754/22875" - }, - { - "m": 62, - "e": "193/744", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 224, - "sq": "82353144022138737321782826038722560000000000000000000000/1645222739087498577902561203668785019953622272295375836401", - "sign_lo": "1129772656152", - "sign_hi": "1129772656152" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 46, - "sq": "1021947000523303729408198497792612138237042159855658990635217337448748343437420736623616037546518594734417868174353063054710838433031652322819188368603697435916992595993294047969197114874749884714405005567353595489056766928557335651186839545105837592217853540203522090300099294575073058148828138015544615785834544569390888013696295737764012542347106275236728191433275176583392135281924188999304410867696734655713232997073501226573781113/488003389260134113302288714608771070206951859519149807766705719270481133194637700322949433865943773348443630370113544005877760000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-64723256786664", - "sign_hi": "-64723256786664" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 323, - "sq": "46830770440278560532978432467451817506571567341531115277855532188686930305524164519985668725389400987017049362612895686360330249547924190107579678054056345878483225624241795899010232683066014966819347103381133354928168233616406867272037491588645094522480351267450327226251757351999383738520590534713983922383251339730865862174663582687/451610639820468075653039369084157893439242952426782952057268471201868811302495846400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-12075252", - "sign_hi": "-12075252" - } - ], - "total": "39637/46500" - }, - { - "m": 63, - "e": "7/27", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 221, - "sq": "176652855831383309071470034944000000000000000000000000/3639284185771218935456378907204261455805273259065120889", - "sign_lo": "1215134440029", - "sign_hi": "1215134440029" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 41, - "sq": "888677733146756745422254117066397136737819182204235757233284133477998671696141507639500347516287468191226612000223844269382642539828544148466284548803674330266954714064686351096572564966018611442752899408022098474087517419712382503973983136525897663182942533747775349205772631140458988545890487737411870036256788544507956428708641404228346282391774990818361234001286292569037867764353358772778270556587836910294706957911690009/530484370180907138370183358221353162420616804360097481541006986576647971706179736569937560162890447468107923456000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-70359545058546", - "sign_hi": "-70359545058546" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 320, - "sq": "295423877573655249930494281962224381031109825058747224492258056577979623515345124719850090198684335907341979090166324810447476852763885473788351213006941460956455397859237464575808836072173409677013917229870338773567852092364852888915950041819861183381140933595459756177195698090061313106533831893145268070908911565507448133144408870989049/2890560686650062803420517007571370908092032723925718276971649102063730428221587456000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-14612722", - "sign_hi": "-14612722" - } - ], - "total": "11357/13500" - }, - { - "m": 64, - "e": "199/768", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 217, - "sq": "331711445709987840000000000000000000000000000/7048169714899769755878374652010748118000509401", - "sign_lo": "1300390602880", - "sign_hi": "1300390602880" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 37, - "sq": "11605008124897616096261888144944157554515701756469867301655547669841411546486592726842634202615519312330108866108433176402491741759159155878260180462108616753760742931584329624887609658569325866215992496470043042495466697472755652948025740537036753972655016320999552209635036039271913727966322209859109445172036269473244365565303020040911125511124555099663/8711228593176024664662389950253266213273600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-76192247672960", - "sign_hi": "-76192247672960" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 317, - "sq": "35111710085446301005286835125551650361266268036136512426402276673619853092152467291941181848950985973490921315792179932121268268097715134653367214826264950137216373716910286850222193162243499436806900830019507400901750479499549587507941602198104343276560239094232340806382311050533033484791115408513589386527005952915094527630598659614077567/350411342451899369931107991750659690430577495171319772079197017520801602538338034647040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-17216990", - "sign_hi": "-17216990" - } - ], - "total": "79691/96000" } ] diff --git a/docs/design.md b/docs/design.md index bead07c..6951357 100644 --- a/docs/design.md +++ b/docs/design.md @@ -34,8 +34,8 @@ The two-chord integral theorem gives raw cubic scalar obstruction ≤ E_budget(m) + T0(m,α) + T1(m,α) + T2(m,α). ``` -For `5 ≤ m ≤ 63`, fixed rational budgets and critical brackets are checked for -every integer parameter; the same existing row-64 certificate supplies the tail +For `5 ≤ m ≤ 60`, fixed rational budgets and critical brackets are checked for +every integer parameter; the same existing row-61 certificate supplies the tail base. The complete critical expressions are tied to the actual derivatives of `T0`, `T1`, and `T2`. Their polynomial signs are certified on entire outer intervals, while the middle interval uses monotone factors at @@ -47,19 +47,22 @@ Scale positivity, interval membership, both endpoint supports and the complete polynomial equality remain explicit Lean obligations. The Python coefficient calculation is not in the trusted base. -For all real `m ≥ 64`, proved parameter antitonicity reduces the four-component -bound to the existing finite `m=64` certificate. `DistillationTailBound` discharges +For all real `m ≥ 61`, proved parameter antitonicity reduces the four-component +bound to the existing finite `m=61` certificate. `DistillationTailBound` discharges that base with its already-certified `<199/200` budget; no base or monotonicity premise is left to the final caller. The rational component uses the actual envelope-dependent denominator, with a split at `α=12`, rather than the old -independent worst-case bounds that required 81. - -The natural-number split `m < 64` versus `64 ≤ m` has no gap. The finite -aggregate proves exactly 5 through 63, and both it and the tail import the final -group `Rows61_64`; row 64 is emitted only once. The generator and validator share -an explicit 5-through-64 range, paired with the real tail theorem. They reject -missing64, extra65, duplicated/reordered rows and mismatched components rather -than inferring a smaller cutoff from truncated data. Rows 65 through 81 and all +independent worst-case bounds that required 81. The exponential components use +`η ≤ (21/22)^4`, hence `log η / 2 ≤ 2 log(21/22) ≤ -1/11`. +This dominates `1/60 + 2/27`, the kappa slope bound at 61, without assuming +a logarithmic estimate or derivative sign. Zero bases are handled separately. + +The natural-number split `m < 61` versus `61 ≤ m` has no gap. The finite +aggregate proves exactly 5 through 60, and both it and the tail import the final +group `Rows61_61`; row 61 is emitted only once. The generator and validator share +an explicit 5-through-61 range, paired with the real tail theorem. They reject +missing61, extra62, duplicated/reordered rows and mismatched components rather +than inferring a smaller cutoff from truncated data. Rows 62 through 81 and all old row-81-only/two-thirds interfaces have been retired. ## Endpoints and definitions @@ -87,9 +90,9 @@ Acceptance distinguishes: - actual value and type/value dependency checks for both final theorems. The earlier-tail consumer test checks actual proof-value edges from both final -theorems through the geometric reduction and the tail to row 64. Its recursive -project-value audit requires exactly cases 5 through 63 in the finite aggregate -and all 60 cases, including each of their three components and strict budgets, +theorems through the geometric reduction and the tail to row 61. Its recursive +project-value audit requires exactly cases 5 through 60 in the finite aggregate +and all 57 cases, including each of their three components and strict budgets, in each final theorem. Retired cases and tail interfaces must be absent from both the imported environment and the actual value closure. Dependency checks do not equate a module import with proof consumption. diff --git a/docs/getting-started.md b/docs/getting-started.md index bf89060..0ea06e1 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -55,9 +55,9 @@ diff -u Sendov/Common/DistillationFinite.lean "$out/generated/Sendov/Common/Dist python3 -m unittest discover -s tests ``` -The output contains all 60 retained records (`m = 5..64`) in eight groups. -The finite aggregate consumes `m = 5..63`; the tail shares row 64 in the final -`Rows61_64` group. Use a fresh output root; generation must not replace a +The output contains all 57 retained records (`m = 5..61`) in eight groups. +The finite aggregate consumes `m = 5..60`; the tail shares row 61 in the final +`Rows61_61` group. Use a fresh output root; generation must not replace a nonempty directory. See [`scripts/GENERATORS.md`](../scripts/GENERATORS.md) for the retained global `sinh` generator and its SymPy dependency. diff --git a/scripts/GENERATORS.md b/scripts/GENERATORS.md index 9b8ef51..26f15c8 100644 --- a/scripts/GENERATORS.md +++ b/scripts/GENERATORS.md @@ -12,9 +12,9 @@ python3 -B -m unittest discover -s tests -v ``` The finite output directory must be new or empty. The generator emits all -`m = 5,...,64`, components `0,1,2`, with the unchanged selected table records. -Rows are grouped in batches of eight, ending in `Rows61_64`. The finite -aggregate covers 5–63; the real tail starts at 64 and uses the original row-64 +`m = 5,...,61`, components `0,1,2`, with the unchanged selected table records. +Rows are grouped in batches of eight, ending in `Rows61_61`. The finite +aggregate covers 5–60; the real tail starts at 61 and uses the original row-61 `<199/200` budget from that same group. The output contains exactly these eight row modules and `Sendov/Common/DistillationFinite.lean`. No second per-row source tree is published. `bundle_rows.py` is the source-packaging helper, not a @@ -28,7 +28,7 @@ bracket, sign, squared-envelope and budget checks apply. Editing that input changes a proposed certificate, not the proof trust base. Keep the shipped table unchanged to reproduce the selected source. `distillation_data.py` is the explicit range authority, paired with `distillComponents_lt_199_200`; truncated inputs -cannot select a different cutoff. In particular, missing64, extra65, duplicate +cannot select a different cutoff. In particular, missing61, extra62, duplicate or reordered rows, and duplicate/reordered/mismatched components are rejected. All data validation and exact row rendering finish before staging. The complete diff --git a/scripts/axioms.lean b/scripts/axioms.lean index 0fe837a..b55f893 100644 --- a/scripts/axioms.lean +++ b/scripts/axioms.lean @@ -38,9 +38,9 @@ end SendovAudit #sendov_axioms SendovConjecture.phelps_rodriguez #sendov_axioms Sendov.distillFinite_components #sendov_axioms Sendov.distillFinite_scalar -#sendov_axioms Sendov.distillFinite_64 -#sendov_axioms Sendov.distillFiniteBound_64 -#sendov_axioms Sendov.distillComponents_le_64 +#sendov_axioms Sendov.distillFinite_61 +#sendov_axioms Sendov.distillFiniteBound_61 +#sendov_axioms Sendov.distillComponents_le_61 #sendov_axioms Sendov.distillT2_zero #sendov_axioms Sendov.distillComponents_lt_199_200 #sendov_axioms Sendov.distillScalar_lt_199_200 diff --git a/scripts/bundle_rows.py b/scripts/bundle_rows.py index 0704e26..ab68e4c 100644 --- a/scripts/bundle_rows.py +++ b/scripts/bundle_rows.py @@ -1,7 +1,7 @@ """Bundle this generator's self-contained RowN modules, preserving each body. This is source packaging, not a certificate checker or a general Lean parser. -The last group includes the row-64 base shared with the infinite tail. +The last group includes the row-61 base shared with the infinite tail. """ from pathlib import Path import argparse @@ -26,7 +26,7 @@ def bundle(source, output, size=8): rows_dir = source / 'Sendov/DistillationFinite' expected = {f'Row{m}.lean' for m in ROWS} if {p.name for p in rows_dir.glob('Row*.lean')} != expected: - raise ValueError('rows must be exactly Row5 through Row64') + raise ValueError('rows must be exactly Row5 through Row61') rows = {m: split_row((rows_dir / f'Row{m}.lean').read_text()) for m in ROWS} aggregate = (source / 'Sendov/Common/DistillationFinite.lean').read_text() row_imports = [line for line in aggregate.splitlines() if line.startswith(f'import {PREFIX}Row')] diff --git a/scripts/distillation_data.py b/scripts/distillation_data.py index 37df6aa..0e6c332 100644 --- a/scripts/distillation_data.py +++ b/scripts/distillation_data.py @@ -10,9 +10,9 @@ import json from pathlib import Path -# Paired with distillComponents_lt_199_200: real m >= 64 uses the row-64 base. +# Paired with distillComponents_lt_199_200: real m >= 61 uses the row-61 base. # Never derive an allowed lower tail threshold from the supplied table. -TAIL_START = 64 +TAIL_START = 61 ROWS = tuple(range(5, TAIL_START + 1)) FINITE_ROWS = ROWS[:-1] @@ -71,11 +71,11 @@ def candidate_squared(m, j, lo, hi): def load_table(path, coefficients): rows = json.loads(Path(path).read_text(encoding='utf-8'), object_pairs_hook=object_pairs, parse_constant=reject_constant) - require(type(rows) is list and len(rows) == len(ROWS), 'exactly 60 rows required') + require(type(rows) is list and len(rows) == len(ROWS), 'exactly 57 rows required') for m, row in zip(ROWS, rows): fields(row, 'm e components total', f'row {m}') require(type(row['m']) is int and row['m'] == m, - 'rows must be m=5..64 exactly once in order') + 'rows must be m=5..61 exactly once in order') e = rational(row['e']) require(e == F(1, 4) + F(7, 12*m), f'E budget mismatch at {m}') parts = row['components'] diff --git a/scripts/gen_distillation.py b/scripts/gen_distillation.py index 11e9305..277f11a 100644 --- a/scripts/gen_distillation.py +++ b/scripts/gen_distillation.py @@ -101,9 +101,9 @@ def sign_source(m,j,side,a,b): (lo := {rat(lo)}) (hi := {rat(hi)}) (s := {scale}) (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le unfold distillCritical{j} - norm_num only [BernsteinCert.coeffTree, BernsteinCert.Cert.eval, - List.length_cons, List.length_nil] - bernstein_ring (x - {rat(lo)}) ({rat(hi)} - x) + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 ''', 1 @@ -149,7 +149,7 @@ def aggregate_source(): see DistillationCriticalFinite for attribution. No sampled truth or global T grid. -/ namespace Sendov -theorem distillFinite_components {{m : ℕ}} (hm : 5 ≤ m) (hm63 : m ≤ {FINITE_ROWS[-1]}) +theorem distillFinite_components {{m : ℕ}} (hm : 5 ≤ m) (hm60 : m ≤ {FINITE_ROWS[-1]}) {{α : ℝ}} (hα : 0 ≤ α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := by interval_cases m @@ -158,12 +158,12 @@ def aggregate_source(): bound = 'h17' if F(m, 2) >= 17 else '(by linarith)' s+=f' · exact (distillFinite_{m} α hα {bound}).trans_lt distillFiniteBound_{m}\n' s+=f''' -theorem distillFinite_scalar {{m : ℕ}} (hm : 5 ≤ m) (hm63 : m ≤ {FINITE_ROWS[-1]}) +theorem distillFinite_scalar {{m : ℕ}} (hm : 5 ≤ m) (hm60 : m ≤ {FINITE_ROWS[-1]}) {{α : ℝ}} (hα : 0 < α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : scalarObstruction m α (cubicPolarEnvelope α) < 199 / 200 := by have hmR : (5 : ℝ) ≤ m := by exact_mod_cast hm exact (distillScalar_le_majorant hmR hα (by linarith)).trans_lt - (distillFinite_components hm hm63 hα.le hαm h17) + (distillFinite_components hm hm60 hα.le hαm h17) end Sendov ''' diff --git a/tests/BoundaryConsumer.lean b/tests/BoundaryConsumer.lean index 867555c..f81bf4e 100644 --- a/tests/BoundaryConsumer.lean +++ b/tests/BoundaryConsumer.lean @@ -10,11 +10,20 @@ theorem raw_zero (m : ℝ) : Sendov.scalarObstruction_zero m /-- The tail component vanishes at the closed left endpoint. -/ -theorem tail_zero {m : ℝ} (hm : 64 ≤ m) : Sendov.distillT2 m 0 = 0 := +theorem tail_zero {m : ℝ} (hm : 61 ≤ m) : Sendov.distillT2 m 0 = 0 := Sendov.distillT2_zero hm /-- Both boundary identities are consumed together at the real tail threshold. -/ theorem threshold_boundary : + Sendov.scalarObstruction 61 0 (Sendov.cubicPolarEnvelope 0) = 1 / 122 ∧ + Sendov.distillT2 61 0 = 0 := by + constructor + · convert raw_zero 61 using 1 + norm_num + · exact tail_zero (by norm_num) + +/-- The former threshold remains covered by the stronger tail interface. -/ +theorem former_threshold_boundary : Sendov.scalarObstruction 64 0 (Sendov.cubicPolarEnvelope 0) = 1 / 128 ∧ Sendov.distillT2 64 0 = 0 := by constructor @@ -22,7 +31,7 @@ theorem threshold_boundary : norm_num · exact tail_zero (by norm_num) -theorem closed_tail {m α : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) (h17 : α ≤ 17) : +theorem closed_tail {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (h17 : α ≤ 17) : Sendov.distillEBudget m + Sendov.distillT0 m α + Sendov.distillT1 m α + Sendov.distillT2 m α < 199 / 200 := Sendov.distillComponents_lt_199_200 hm hα h17 diff --git a/tests/EarlierTail.lean b/tests/EarlierTail.lean index 61c93ab..ae0db3e 100644 --- a/tests/EarlierTail.lean +++ b/tests/EarlierTail.lean @@ -5,32 +5,32 @@ open Sendov namespace EarlierTailTest -example {m : ℕ} (hm : 5 ≤ m) : (5 ≤ m ∧ m ≤ 63) ∨ 64 ≤ m := by omega +example {m : ℕ} (hm : 5 ≤ m) : (5 ≤ m ∧ m ≤ 60) ∨ 61 ≤ m := by omega -example {m : ℕ} (hm : 5 ≤ m) (hm63 : m ≤ 63) : +example {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) : distillEBudget m + distillT0 m 0 + distillT1 m 0 + distillT2 m 0 < 199 / 200 := - distillFinite_components hm hm63 (by norm_num) (by positivity) (by norm_num) + distillFinite_components hm hm60 (by norm_num) (by positivity) (by norm_num) -example {m α : ℝ} (hm : 64 ≤ m) (hα : 0 ≤ α) (h17 : α ≤ 17) : +example {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (h17 : α ≤ 17) : distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := distillComponents_lt_199_200 hm hα h17 -example {m α : ℝ} (hm : 64 ≤ m) (hα : 0 < α) (h17 : α ≤ 17) : +example {m α : ℝ} (hm : 61 ≤ m) (hα : 0 < α) (h17 : α ≤ 17) : scalarObstruction m α (cubicPolarEnvelope α) < 1 := (distillScalar_lt_199_200 hm hα h17).trans (by norm_num) example : - distillEBudget 64 + distillT0 64 0 + distillT1 64 0 + distillT2 64 0 < 199 / 200 := + distillEBudget 61 + distillT0 61 0 + distillT1 61 0 + distillT2 61 0 < 199 / 200 := distillComponents_lt_199_200 (by norm_num) (by norm_num) (by norm_num) example : - scalarObstruction 64 0 (cubicPolarEnvelope 0) = 1 / 128 := by + scalarObstruction 61 0 (cubicPolarEnvelope 0) = 1 / 122 := by rw [scalarObstruction_zero] norm_num example : - distillEBudget (129 / 2) + distillT0 (129 / 2) 17 + - distillT1 (129 / 2) 17 + distillT2 (129 / 2) 17 < 199 / 200 := + distillEBudget (123 / 2) + distillT0 (123 / 2) 17 + + distillT1 (123 / 2) 17 + distillT2 (123 / 2) 17 < 199 / 200 := distillComponents_lt_199_200 (by norm_num) (by norm_num) (by norm_num) example {n : ℕ} (hn : 6 ≤ n) {α : ℝ} @@ -41,6 +41,12 @@ example {n : ℕ} (hn : 6 ≤ n) {α : ℝ} example : scalarObstruction (M 6) (5 / 2) (cubicPolarEnvelope (5 / 2)) < 1 := distillScalar_lt_one (by norm_num) (by norm_num) (by norm_num) (by norm_num [M]) +example : scalarObstruction (M 61) 17 (cubicPolarEnvelope 17) < 1 := + distillScalar_lt_one (by norm_num) (by norm_num) (by norm_num) (by norm_num [M]) + +example : scalarObstruction (M 62) 17 (cubicPolarEnvelope 17) < 1 := + distillScalar_lt_one (by norm_num) (by norm_num) (by norm_num) (by norm_num [M]) + example : scalarObstruction (M 64) 17 (cubicPolarEnvelope 17) < 1 := distillScalar_lt_one (by norm_num) (by norm_num) (by norm_num) (by norm_num [M]) @@ -68,8 +74,8 @@ run_cmd do let env := (← getEnv).setExporting false for (consumer, targets) in #[ (`Sendov.distillComponents_lt_199_200, - #[`Sendov.distillComponents_le_64, `Sendov.distillFinite_64, - `Sendov.distillFiniteBound_64]), + #[`Sendov.distillComponents_le_61, `Sendov.distillFinite_61, + `Sendov.distillFiniteBound_61]), (`Sendov.distillScalar_lt_199_200, #[`Sendov.distillScalar_le_majorant, `Sendov.distillComponents_lt_199_200]), (`Sendov.distillScalar_lt_one, @@ -102,13 +108,14 @@ run_cmd do `Sendov.distillFiniteTailBase, `Sendov.distillComponents_lt_two_thirds, `Sendov.distillScalar_lt_two_thirds, `Sendov.distillComponents_lt_two_thirds_of_base, `Sendov.distillEBudget_le_81, `Sendov.distillT0_le_81, `Sendov.distillT1_le_81, - `Sendov.distillT2_le_81, `Sendov.distillComponents_le_81, `Sendov.distillTail_polynomial_pos] + `Sendov.distillT2_le_81, `Sendov.distillComponents_le_81, `Sendov.distillTail_polynomial_pos, + `Sendov.distillComponents_le_64] for name in retired do if env.contains name then throwError "retired declaration still imported: {name}" -- Only project values can reference project cases: earlier imported libraries -- cannot depend on declarations introduced later by Sendov. - for (root, upper) in #[(`Sendov.distillFinite_components, 63), - (`SendovConjecture.sendov, 64), (`SendovConjecture.phelps_rodriguez, 64)] do + for (root, upper) in #[(`Sendov.distillFinite_components, 60), + (`SendovConjecture.sendov, 61), (`SendovConjecture.phelps_rodriguez, 61)] do let mut pending := [root] let mut visited : Std.HashSet Name := {} while !pending.isEmpty do @@ -128,17 +135,17 @@ run_cmd do let name := Name.str `Sendov s!"{stem}{m}" unless visited.contains name == (m ≤ upper) do throwError "wrong actual case closure: {root}, {name}" - if 65 ≤ m && env.contains name then + if 62 ≤ m && env.contains name then throwError "retired case still imported: {name}" for j in [0:3] do let name := Name.str (Name.str `Sendov s!"CriticalRow{m}") s!"component{j}" unless visited.contains name == (m ≤ upper) do throwError "wrong actual component closure: {root}, {name}" - if 65 ≤ m && env.contains name then + if 62 ≤ m && env.contains name then throwError "retired component still imported: {name}" for name in visited do let text := name.toString if retired.contains name || (text.splitOn "two_thirds").length > 1 || (text.splitOn "_le_81").length > 1 then throwError "retired tail in actual value closure: {root}, {name}" - logInfo m!"K64_VALUE_CLOSURE {root}: 5..{upper}, three components, no retired names" + logInfo m!"K61_VALUE_CLOSURE {root}: 5..{upper}, three components, no retired names" diff --git a/tests/Localcertificates.lean b/tests/Localcertificates.lean new file mode 100644 index 0000000..e0f9121 --- /dev/null +++ b/tests/Localcertificates.lean @@ -0,0 +1,165 @@ +import Sendov.Common.BernsteinList +import Sendov.Common.DistillationFinite + +namespace Localcertificates + +open BernsteinCert Sendov + +example (cs : List ℕ) (i : ℕ) (x y : ℝ) : + (coeffTree cs i).eval x y = x ^ i * (coeffTree cs 0).eval x y := + coeffTree_eval_shift cs i x y + +example (c : ℕ) (cs : List ℕ) (x y : ℝ) : + (coeffTree (c :: cs) 0).eval x y = + (c : ℝ) * y ^ cs.length + x * (coeffTree cs 0).eval x y := + coeffTree_eval_cons c cs x y + +example (x y : ℝ) : (coeffTree [] 0).eval x y = 0 := + coeffTree_eval_nil x y + +example (x y : ℝ) : (coeffTree [7] 0).eval x y = 7 := by + simp only [coeffTree_eval_cons, coeffTree_eval_nil, List.length_nil, Nat.cast_ofNat] + ring1 + +example (x y : ℝ) : (coeffTree [2, 0, 3] 0).eval x y = 2 * y ^ 2 + 3 * x ^ 2 := by + simp only [coeffTree_eval_cons, coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +example : (coeffTree [2, 0, 3] 0).eval 0 1 = 2 ∧ + (coeffTree [2, 0, 3] 0).eval 1 0 = 3 := by + norm_num [coeffTree_eval_cons, coeffTree_eval_nil] + +example : (coeffTree [] 0).edge true = false ∧ + (coeffTree [] 0).edge false = false := by decide + +example : (coeffTree [0, 1] 0).edge true = false ∧ + (coeffTree [1, 0] 0).edge false = false := by decide + +example (x : ℝ) (hx : x ∈ Set.Icc 0 1) : 0 < x ^ 2 + (1 - x) ^ 2 := by + refine coeffs_pos [1, 0, 1] (lo := 0) (hi := 1) (s := 1) + (by norm_num) (by norm_num) hx (by decide) (by decide) ?_ + simp only [coeffTree_eval_cons, coeffTree_eval_nil, + List.length_cons, List.length_nil] + ring1 + +theorem critical0_identity (x : ℝ) : + 117649 * -distillCritical0 5 x = + (coeffTree [3667054680, 133443712440, 939063315600, 3006831250944, + 5267101731840, 5254197895040, 2819499598080, 635350144000] 0).eval + (x - 3 / 4) (5 / 2 - x) := by + unfold distillCritical0 + simp only [coeffTree_eval_cons, coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +theorem critical1_identity (x : ℝ) : + 4782969 * distillCritical1 5 x = + (coeffTree [12259473776, 1574964910352, 13907088807648, 52400775960064, + 105639358896640, 119707352275200, 72226624540160, 18128870144000] 0).eval + (x - 1 / 4) (5 / 2 - x) := by + unfold distillCritical1 + simp only [coeffTree_eval_cons, coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +theorem critical2_identity (x : ℝ) : + -distillCritical2 5 x = + (coeffTree [129600, 462240, 574680, 277028, 34872] 0).eval (x - 0) (1 / 2 - x) := by + unfold distillCritical2 + simp only [coeffTree_eval_cons, coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +example (x : ℝ) (hx : x ∈ Set.Icc 0 (1 / 2)) : 0 < -distillCritical2 5 x := by + exact coeffs_pos [129600, 462240, 574680, 277028, 34872] + (lo := 0) (hi := 1 / 2) (s := 1) (by norm_num) (by norm_num) + hx (by decide) (by decide) (by simpa only [one_mul] using critical2_identity x) + +-- A changed interior coefficient preserves both endpoint values and supports. +-- The complete identity must still fail, not merely a frontend shape check. +example (x : ℝ) : x = x := by + fail_if_success + have h : -distillCritical2 5 x = + (coeffTree [129600, 462240, 574681, 277028, 34872] 0).eval + (x - 0) (1 / 2 - x) := by + unfold distillCritical2 + simp only [coeffTree_eval_cons, coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + rfl + +example : (coeffTree [129600, 462240, 574681, 277028, 34872] 0).edge true = true ∧ + (coeffTree [129600, 462240, 574681, 277028, 34872] 0).edge false = true := by decide + +example : ¬ (∀ x : ℝ, -distillCritical2 5 x = + (coeffTree [129600, 462240, 574681, 277028, 34872] 0).eval (x - 0) (1 / 2 - x)) := by + intro h + have hq := h (1 / 4) + norm_num [distillCritical2, coeffTree, Cert.eval] at hq + +example (x : ℝ) : x = x := by + fail_if_success + have h : 2 * -distillCritical2 5 x = + (coeffTree [129600, 462240, 574680, 277028, 34872] 0).eval + (x - 0) (1 / 2 - x) := by + unfold distillCritical2 + simp only [coeffTree_eval_cons, coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + fail_if_success + have h : -distillCritical2 5 x = + (coeffTree [34872, 277028, 574680, 462240, 129600] 0).eval + (x - 0) (1 / 2 - x) := by + unfold distillCritical2 + simp only [coeffTree_eval_cons, coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + fail_if_success + have h : -distillCritical2 5 x = + (coeffTree [129600, 462240, 574680, 277028] 0).eval (x - 0) (1 / 2 - x) := by + unfold distillCritical2 + simp only [coeffTree_eval_cons, coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + fail_if_success + have h : -distillCritical2 5 x = + (coeffTree [129600, 462240, 574680, 277028, 34872] 0).eval (x - 0) (3 / 4 - x) := by + unfold distillCritical2 + simp only [coeffTree_eval_cons, coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + rfl + +example (x y : ℝ) : (x + y) ^ 2 = y ^ 2 + 2 * x * y + x ^ 2 := by + bernstein_ring x y + +example (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5 / 2) : + distillT1 5 α ≤ 191 / 1000 := + CriticalRow5.component1 α hα hd + +example (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 46 α ≤ 153 / 1000 := + CriticalRow46.component1 α hα hd + +example (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 61 α ≤ 57 / 250 ∧ distillT1 61 α ≤ 13 / 250 ∧ + distillT2 61 α ≤ 81 / 250 := + ⟨CriticalRow61.component0 α hα hd, CriticalRow61.component1 α hα hd, + CriticalRow61.component2 α hα hd⟩ + +example {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) {α : ℝ} (hα : 0 ≤ α) + (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := + distillFinite_components hm hm60 hα hαm h17 + +example {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) {α : ℝ} (hα : 0 < α) + (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : + scalarObstruction m α (cubicPolarEnvelope α) < 199 / 200 := + distillFinite_scalar hm hm60 hα hαm h17 + +example : distillEBudget 61 + distillT0 61 17 + distillT1 61 17 + distillT2 61 17 < + 199 / 200 := + (distillFinite_61 17 (by norm_num) le_rfl).trans_lt distillFiniteBound_61 + +end Localcertificates diff --git a/tests/Localcommon.lean b/tests/Localcommon.lean index c117525..556d5fc 100644 --- a/tests/Localcommon.lean +++ b/tests/Localcommon.lean @@ -95,14 +95,14 @@ example : Real.log (Real.sinh 10 / 10) ≤ (7 / 8 : ℝ) * (Real.sqrt (9 + (8 / 7 : ℝ) * 10 ^ 2) - 3) := DistillationHyperbolic.log_sinh_div_le (by norm_num) le_rfl -example {m : ℝ} (hm : 64 ≤ m) : distillT2 m 0 = 0 := distillT2_zero hm +example {m : ℝ} (hm : 61 ≤ m) : distillT2 m 0 = 0 := distillT2_zero hm -example {m : ℝ} (hm : 64 ≤ m) : +example {m : ℝ} (hm : 61 ≤ m) : distillEBudget m + distillT0 m 0 + distillT1 m 0 + distillT2 m 0 ≤ - distillEBudget 64 + distillT0 64 0 + distillT1 64 0 + distillT2 64 0 := - distillComponents_le_64 hm le_rfl (by norm_num) + distillEBudget 61 + distillT0 61 0 + distillT1 61 0 + distillT2 61 0 := + distillComponents_le_61 hm le_rfl (by norm_num) -example {m : ℝ} (hm : 64 ≤ m) : +example {m : ℝ} (hm : 61 ≤ m) : scalarObstruction m 17 (cubicPolarEnvelope 17) < 199 / 200 := distillScalar_lt_199_200 hm (by norm_num) le_rfl diff --git a/tests/Localgenerators.lean b/tests/Localgenerators.lean index f20d611..4208386 100644 --- a/tests/Localgenerators.lean +++ b/tests/Localgenerators.lean @@ -60,23 +60,23 @@ example (x y : ℝ) : y - x = -1 * x + y := by fail_if_success bernstein_ring x y ring -example {m : ℕ} (hm : 5 ≤ m) (hm63 : m ≤ 63) {α : ℝ} (hα : 0 ≤ α) +example {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) {α : ℝ} (hα : 0 ≤ α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : Sendov.distillEBudget m + Sendov.distillT0 m α + Sendov.distillT1 m α + Sendov.distillT2 m α < 199 / 200 := - Sendov.distillFinite_components hm hm63 hα hαm h17 + Sendov.distillFinite_components hm hm60 hα hαm h17 example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : - Sendov.distillT0 64 α ≤ 217 / 1000 := - Sendov.CriticalRow64.component0 α hα h17 + Sendov.distillT0 61 α ≤ 57 / 250 := + Sendov.CriticalRow61.component0 α hα h17 example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : - Sendov.distillT1 64 α ≤ 37 / 1000 := - Sendov.CriticalRow64.component1 α hα h17 + Sendov.distillT1 61 α ≤ 13 / 250 := + Sendov.CriticalRow61.component1 α hα h17 example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : - Sendov.distillT2 64 α ≤ 317 / 1000 := - Sendov.CriticalRow64.component2 α hα h17 + Sendov.distillT2 61 α ≤ 81 / 250 := + Sendov.CriticalRow61.component2 α hα h17 example : Real.sinh 0 ≤ 0 * Real.exp (Real.sqrt (0 ^ 2 + 9) - 3) := Sendov.sinh_le_mul_exp le_rfl diff --git a/tests/Localhotspots.lean b/tests/Localhotspots.lean new file mode 100644 index 0000000..347a54b --- /dev/null +++ b/tests/Localhotspots.lean @@ -0,0 +1,147 @@ +import Sendov.Reduction.CubicScalar +import Sendov.Common.DistillationCriticalFinite + +open Sendov Real + +example {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) + (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 ≤ 1) + (hα : α = M n * (1 - a ^ 2) / 2) + (hbeta : QQ (a * x) (a ^ 2) 1 ≤ α / (3 + α)) + (hlogb : log α ≤ α * (1 - QQ (a * x) (a ^ 2) 1)) + (horigin : 2 * α + a * x ≤ (1 - x ^ 2) / (2 * M n) + + a ^ 2 * n * M n * ∫ t in (0 : ℝ)..1, + t * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2)) : + α ≤ 17 := + alpha_le_seventeen hn ha ha1 hx hα hbeta hlogb horigin + +example {n : ℕ} (hn : 6 ≤ n) {a x α : ℝ} + (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 ≤ 1) + (hα : α = M n * (1 - a ^ 2) / 2) + (hpolar : 1 ≤ ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) + (horigin : 2 * α + a * x ≤ (1 - x ^ 2) / (2 * M n) + + a ^ 2 * n * M n * ∫ t in (0 : ℝ)..1, + t * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2)) : + (0 < α) ∧ (2 * α ≤ M n) ∧ (α ≤ 17) ∧ + (1 ≤ scalarObstruction (M n) α (cubicPolarEnvelope α)) := + cubicScalar_constraints_of_polar_origin hn ha ha1 hx hα hpolar horigin + +example : (0 : ℝ) * (2 * (0 + 1) + 1 / 17) * exp (-(2.83 * 0)) ≤ 0.4118 := + tail_poly_bound le_rfl + +-- Bernoulli's interface still permits a negative Q and a zero P. +example {p : ℝ} (hp : 1 ≤ p) : + (2 + (-1) : ℝ) ^ p ≤ (2 : ℝ) ^ p + p * (-1) * (2 + (-1) : ℝ) ^ (p - 1) := + rpow_add_le_of_one_le (by norm_num) (by norm_num) hp + +example {Q p : ℝ} (hQ : 0 < Q) (hp : 1 ≤ p) : + (0 + Q) ^ p ≤ (0 : ℝ) ^ p + p * Q * (0 + Q) ^ (p - 1) := + rpow_add_le_of_one_le le_rfl (by simpa using hQ) hp + +-- All three identities are symbolic polynomial equalities, not evaluations. +example (m α : ℝ) : + distillCritical0 m α = distillK m α * distillD m α + + 4 * (m - 2 * α) * distillN α * distillRp m α := + distillCritical0_eq m α + +example (m α : ℝ) : + distillCritical1 m α = -2 * distillK m α * distillB m α - + (m - 3) * (m - 2 * α) * distillN α * distillRp m α := + distillCritical1_eq m α + +example (m α : ℝ) : + distillCritical2 m α = -2 * α * distillK m α - + (m - 3) * (m - 2 * α) * distillL α := + distillCritical2_eq m α + +example (α : ℝ) : distillN α = 29 * α ^ 2 + 180 * α + 270 := rfl + +example (x : ℝ) : + DistillationHyperbolic.A x = + x ^ 8 + 1430 * x ^ 6 + 289575 * x ^ 4 + 16081065 * x ^ 2 + 218243025 := rfl + +example (x : ℝ) : + DistillationHyperbolic.D x = + 55 * x ^ 8 + 25740 * x ^ 6 + 2837835 * x ^ 4 + 91891800 * x ^ 2 + 654729075 := rfl + +example {m : ℝ} (hm : 0 < m) : + distillD m 0 = 50 * m * (0 + 3) ^ 3 * (1 - distillNode m 0) := + distillD_eq hm le_rfl + +example {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : + distillD m α = 50 * m * (α + 3) ^ 3 * (1 - distillNode m α) := + distillD_eq hm hα + +example {m : ℝ} (hm : 0 < m) : + HasDerivAt (distillKappa m) + (distillKappa m 0 * (distillK m 0 / ((0 + 3) * (m - 2 * 0) * distillN 0))) 0 := + hasDerivAt_distillKappa le_rfl (by simpa using hm) + +example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : + HasDerivAt (distillT0 m) + (distillT0 m α * (distillCritical0 m α / + ((α + 3) * (m - 2 * α) * distillN α * distillD m α))) α := + hasDerivAt_distillT0 hm hα hαm + +example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : + HasDerivAt (distillT1 m) + (distillT1 m α * (-distillCritical1 m α / + (2 * (α + 3) * (m - 2 * α) * distillN α * distillB m α))) α := + hasDerivAt_distillT1 hm hα hαm + +example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : + HasDerivAt (distillT2 m) + (distillT2 m α * (-distillCritical2 m α / + (2 * α * (α + 3) * (m - 2 * α) * distillN α))) α := + hasDerivAt_distillT2 hm hα hαm + +example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : + (deriv (distillT0 m) α ≤ 0 ↔ distillCritical0 m α ≤ 0) ∧ + (deriv (distillT1 m) α ≤ 0 ↔ 0 ≤ distillCritical1 m α) ∧ + (deriv (distillT2 m) α ≤ 0 ↔ 0 ≤ distillCritical2 m α) := + ⟨distillT0_deriv_nonpos_iff hm hα hαm, distillT1_deriv_nonpos_iff hm hα hαm, + distillT2_deriv_nonpos_iff hm hα hαm⟩ + +example {m : ℝ} (hm : 5 ≤ m) : + ContinuousWithinAt (distillT0 m) (Set.Icc 0 (m / 2)) 0 := + distillT0_continuousOn hm 0 ⟨le_rfl, by linarith⟩ + +example {m : ℝ} (hm : 5 ≤ m) : + ContinuousWithinAt (distillT1 m) (Set.Icc 0 (m / 2)) 0 := + distillT1_continuousOn hm 0 ⟨le_rfl, by linarith⟩ + +example {m : ℝ} (hm : 5 ≤ m) : + ContinuousWithinAt (distillT2 m) (Set.Icc 0 (m / 2)) (m / 2) := + distillT2_continuousOn hm (m / 2) ⟨by linarith, le_rfl⟩ + +example {x : ℝ} (hx : 0 ≤ x) : + 0 ≤ x ^ 2 * DistillationHyperbolic.A x * sinh x - + DistillationHyperbolic.D x * (x * cosh x - sinh x) := + DistillationHyperbolic.pade_nonneg hx + +example {x : ℝ} (hx : 0 ≤ x) (hx10 : x ≤ 10) : + sqrt (9 + (8 / 7 : ℝ) * x ^ 2) * (x * cosh x - sinh x) ≤ x ^ 2 * sinh x := + DistillationHyperbolic.sqrt_mul_sub_le hx hx10 + +example : sinh 0 ≤ 0 * exp ((7 / 8 : ℝ) * (sqrt (9 + (8 / 7 : ℝ) * 0 ^ 2) - 3)) := + DistillationHyperbolic.sinh_le_mul_exp le_rfl (by norm_num) + +example : log (sinh 10 / 10) ≤ (7 / 8 : ℝ) * (sqrt (9 + (8 / 7 : ℝ) * 10 ^ 2) - 3) := + DistillationHyperbolic.log_sinh_div_le (by norm_num) le_rfl + +example {h : ℝ} (hh : 0 ≤ h) (hh10 : h ≤ 10) : + sinh h ≤ h * exp ((7 / 8 : ℝ) * (sqrt (9 + (8 / 7 : ℝ) * h ^ 2) - 3)) := + DistillationHyperbolic.sinh_le_mul_exp hh hh10 + +-- Direct consumer of the original n >= 5 interface, without a polar premise. +example {n : ℕ} {a x α : ℝ} (hn : 5 ≤ n) (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 ≤ 1) + (hα : α = M n * (1 - a ^ 2) / 2) (hα0 : 0 < α) + (hB1lt : QQ (a * x) (a ^ 2) 1 < 1) + (horigin : 2 * α + a * x ≤ (1 - x ^ 2) / (2 * M n) + + a ^ 2 * n * M n * ∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2)) : + 1 ≤ QQ (a * x) (a ^ 2) 1 / (2 * α * (1 - QQ (a * x) (a ^ 2) 1)) + + QQ (a * x) (a ^ 2) 1 / (4 * α) + + 1 / (2 * M n) + + QQ (a * x) (a ^ 2) 1 / (4 * α * M n) + + (a ^ 2) ^ 2 * n * M n * ((n : ℝ) - 2) * QQ (a * x) (a ^ 2) 1 / (4 * α) + * ∫ t in (0 : ℝ)..1, t ^ 3 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 4) / 2) := + one_le_of_origin hn ha ha1 hx hα hα0 hB1lt horigin diff --git a/tests/Localmathematics.lean b/tests/Localmathematics.lean new file mode 100644 index 0000000..fb3285b --- /dev/null +++ b/tests/Localmathematics.lean @@ -0,0 +1,59 @@ +import Sendov.LargeDegree.DistillationTail + +namespace MathematicsFeasibility +open Sendov + +theorem decay_base : cubicPolarEnvelope 17 ≤ (21 / 22 : ℝ) ^ 4 := by + norm_num [cubicPolarEnvelope] + +theorem log_decay {z : ℝ} (hz : 0 < z) (hcap : z ≤ (21 / 22 : ℝ) ^ 4) : + Real.log z / 2 ≤ -(1 / 11) := by + have hlog := Real.log_le_log hz hcap + rw [Real.log_pow] at hlog + have hlinear := Real.log_le_sub_one_of_pos (by norm_num : (0 : ℝ) < 21 / 22) + norm_num only [Nat.cast_ofNat] at hlog + linarith + +theorem start61 : (1 / (61 - 1) + 2 / (61 - 34) : ℝ) ≤ 1 / 11 := by + norm_num + +theorem start60_not_this_certificate : + ¬ (1 / (60 - 1) + 2 / (60 - 34) : ℝ) ≤ 1 / 11 := by norm_num + +example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : + AntitoneOn (fun m : ℝ => distillKappa m α * (5 / 6 : ℝ) ^ ((m - 3) / 2)) + (Set.Ici 64) := + distillKappa_rpow_antitone_on (by norm_num) (by norm_num) + hα h17 (by norm_num) le_rfl + +example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : + AntitoneOn (fun m : ℝ => distillKappa m α * (0 : ℝ) ^ ((m - 3) / 2)) + (Set.Ici 61) := + distillKappa_rpow_antitone_of_pow 4 (by norm_num) (by norm_num) + hα h17 le_rfl (by norm_num : (0 : ℝ) < 21 / 22) (by norm_num) + +theorem zero34 : distillT2 34 17 = 0 := by + norm_num [distillT2, distillKappa] + +theorem positive35 : 0 < distillT2 35 17 := by + have hk : 0 < distillKappa 35 17 := by norm_num [distillKappa, distillRatio] + have he : 0 < cubicPolarEnvelope 17 := by norm_num [cubicPolarEnvelope] + exact mul_pos (mul_pos (by norm_num) hk) (Real.rpow_pos_of_pos he _) + +theorem increase59_61 : distillT2 59 17 < distillT2 61 17 := by + norm_num [distillT2, distillKappa, distillRatio, cubicPolarEnvelope, + show ((59 : ℝ) - 3) / 2 = (28 : ℕ) by norm_num, + show ((61 : ℝ) - 3) / 2 = (29 : ℕ) by norm_num, Real.rpow_natCast] + +theorem no_antitone_start_le_59 {K : ℝ} (hK : K ≤ 59) : + ¬ AntitoneOn (fun m : ℝ => distillT2 m 17) (Set.Ici K) := by + intro h + exact (not_le_of_gt increase59_61) + (h hK (hK.trans (by norm_num)) (by norm_num)) + +example : 2 * (17 : ℝ) ≤ 34 ∧ 2 * (17 : ℝ) ≤ 35 ∧ + 2 * (17 : ℝ) ≤ 59 ∧ 2 * (17 : ℝ) ≤ 61 := by norm_num + +#print axioms no_antitone_start_le_59 +#print axioms log_decay +end MathematicsFeasibility diff --git a/tests/expected.json b/tests/expected.json index 798c667..607b8a3 100644 --- a/tests/expected.json +++ b/tests/expected.json @@ -1,16 +1,16 @@ { "distillation": { - "Sendov/Common/DistillationFinite.lean": "4b5a88e50e801126c2de6127142a8a346182e6a7258fb7af1d8497c60ccef11f", - "Sendov/DistillationFinite/Rows13_20.lean": "7cfbd3aac6f3639f5e8d0ecd9773386c000aa27479d2c75a5d196e252e812110", - "Sendov/DistillationFinite/Rows21_28.lean": "4259d6f25898cdee240186ef412cc47881909fe1d91ff613f46e116a642edd68", - "Sendov/DistillationFinite/Rows29_36.lean": "f3dfd178a770b4e1101f54f9bd1e82f9ed3e36cedc2960adc676a71b8d680a49", - "Sendov/DistillationFinite/Rows37_44.lean": "5b4a6770bf94696e2e9a9db986af37273eaaea6da3f3297756a51fa7378f81c1", - "Sendov/DistillationFinite/Rows45_52.lean": "0b6b601e18f4369f0faa0a2f15f3c59975efe564ebbf3bfafb938e4b48e2bd5f", - "Sendov/DistillationFinite/Rows53_60.lean": "ad156609407557c02747118bfd833813835fa781507df406e1707523d33d5ee5", - "Sendov/DistillationFinite/Rows5_12.lean": "f783474650bc285a809277a6998cb9c3767e143497271c596a686c7bbba3af24", - "Sendov/DistillationFinite/Rows61_64.lean": "0725e96ed60c19486537a16b1a2d370ae20c887754edbb25b611249b4a899113" + "Sendov/Common/DistillationFinite.lean": "08ecbb1e3d2d571718579467ac752a4a4b944973c02a1fa355eec785360e0ab6", + "Sendov/DistillationFinite/Rows13_20.lean": "d4797d14dc0932db445dd421d8117b84b3748ea98160b105fa296af07a7de0b7", + "Sendov/DistillationFinite/Rows21_28.lean": "c8eae11289b2d45e244ee083da84418babdc395af0ee05454cc711b085e1d318", + "Sendov/DistillationFinite/Rows29_36.lean": "60ef832981cf7f3c6056d079e0abcfc663a3a4f53523b690f3cf21f82132517b", + "Sendov/DistillationFinite/Rows37_44.lean": "cacca609ff5a960d97220629eea75c087c2f7971395d0280b1a770ad1eeffa84", + "Sendov/DistillationFinite/Rows45_52.lean": "21ef52d413d69addc9916ebab6830f75c18a213e82d91ba32b702a0874383c25", + "Sendov/DistillationFinite/Rows53_60.lean": "4e09662cc6311402ac606523821bb139f89fb877a782c438484136e824744217", + "Sendov/DistillationFinite/Rows5_12.lean": "6c2058e9eb2c6b9f73daa869e699640492cfd8f1df5412ebf1fe467bdecdbfc5", + "Sendov/DistillationFinite/Rows61_61.lean": "12914a847c6360f43e32fe9ecdfbc2ca5a098388cef6f41a973cf34dca8bc08d" }, - "table_sha256": "3cc794c71cb0eb7f052f8623016da364cf5ed18f18be29599092111bfb451964", + "table_sha256": "e29363bce9ae130a080e1b02ccbbfddbb5e63a31a769900ab08d389c519cd528", "sinh": { "sha256": "d04df2219415aa8e4f838c9c1b246b35af087e4ba41d4c449f95fe0f436c4acb", "bytes": 15024 diff --git a/tests/test_axiom_audit.py b/tests/test_axiom_audit.py index 9cd9308..e73cc1b 100644 --- a/tests/test_axiom_audit.py +++ b/tests/test_axiom_audit.py @@ -18,9 +18,9 @@ 'SendovConjecture.phelps_rodriguez', 'Sendov.distillFinite_components', 'Sendov.distillFinite_scalar', - 'Sendov.distillFinite_64', - 'Sendov.distillFiniteBound_64', - 'Sendov.distillComponents_le_64', + 'Sendov.distillFinite_61', + 'Sendov.distillFiniteBound_61', + 'Sendov.distillComponents_le_61', 'Sendov.distillT2_zero', 'Sendov.distillComponents_lt_199_200', 'Sendov.distillScalar_lt_199_200', @@ -29,7 +29,7 @@ ] MODULES = { - 'Sendov.DistillationFinite.Rows61_64': TARGETS[4:6], + 'Sendov.DistillationFinite.Rows61_61': TARGETS[4:6], 'Sendov.Common.DistillationFinite': TARGETS[2:4], 'Sendov.LargeDegree.DistillationTail': TARGETS[6:8], 'Sendov.LargeDegree.DistillationTailBound': TARGETS[8:10], diff --git a/tests/test_bundle_rows.py b/tests/test_bundle_rows.py index b900b2e..b271c5d 100644 --- a/tests/test_bundle_rows.py +++ b/tests/test_bundle_rows.py @@ -16,27 +16,27 @@ def fixture(self, root): rows = source / 'Sendov/DistillationFinite' rows.mkdir(parents=True) (source / 'Sendov/Common').mkdir() - for m in range(5, 65): + for m in range(5, 62): (rows / f'Row{m}.lean').write_text( 'import Mathlib.Data.Nat.Basic\n\n' f'namespace FixtureRow{m}\ntheorem value : (1 : Nat) = 1 := rfl\nend FixtureRow{m}\n') (source / 'Sendov/Common/DistillationFinite.lean').write_text(''.join( - f'import Sendov.DistillationFinite.Row{m}\n' for m in range(5, 65)) + '\n-- aggregate body\n') + f'import Sendov.DistillationFinite.Row{m}\n' for m in range(5, 62)) + '\n-- aggregate body\n') return source def test_all_rows_once_in_original_order_and_bodies_preserved(self): with tempfile.TemporaryDirectory() as temporary: root = Path(temporary); source = self.fixture(root) result = bundle_rows.bundle(source, root / 'out', size=8) - self.assertEqual([m for group in result['groups'] for m in group['rows']], list(range(5, 65))) + self.assertEqual([m for group in result['groups'] for m in group['rows']], list(range(5, 62))) for group in result['groups']: text = (root / 'out' / group['path']).read_text() for m in group['rows']: original = (source / f'Sendov/DistillationFinite/Row{m}.lean').read_text() body = ''.join(x for x in original.splitlines(keepends=True) if not x.startswith('import ')) self.assertIn(body, text) - self.assertEqual(result['groups'][-1]['module'], 'Sendov.DistillationFinite.Rows61_64') - self.assertFalse((root / 'out/Sendov/DistillationFinite/Row64.lean').exists()) + self.assertEqual(result['groups'][-1]['module'], 'Sendov.DistillationFinite.Rows61_61') + self.assertFalse((root / 'out/Sendov/DistillationFinite/Row61.lean').exists()) self.assertFalse((root / 'out/Sendov/DistillationFinite/Row46.lean').exists()) aggregate = (root / 'out/Sendov/Common/DistillationFinite.lean').read_text() self.assertNotIn('import Sendov.DistillationFinite.Row46\n', aggregate) @@ -45,15 +45,15 @@ def test_all_rows_once_in_original_order_and_bodies_preserved(self): def test_missing_row_fails_before_output(self): with tempfile.TemporaryDirectory() as temporary: root = Path(temporary); source = self.fixture(root) - (source / 'Sendov/DistillationFinite/Row64.lean').unlink() + (source / 'Sendov/DistillationFinite/Row61.lean').unlink() with self.assertRaisesRegex(ValueError, 'rows'): bundle_rows.bundle(source, root / 'out') self.assertFalse((root / 'out').exists()) - def test_extra_row65_fails_before_output(self): + def test_extra_row62_fails_before_output(self): with tempfile.TemporaryDirectory() as temporary: root = Path(temporary); source = self.fixture(root) - (source / 'Sendov/DistillationFinite/Row65.lean').write_text( + (source / 'Sendov/DistillationFinite/Row62.lean').write_text( 'import Mathlib.Data.Nat.Basic\n') with self.assertRaisesRegex(ValueError, 'rows'): bundle_rows.bundle(source, root / 'out') diff --git a/tests/test_generator_core.py b/tests/test_generator_core.py index b097937..0ad54d8 100644 --- a/tests/test_generator_core.py +++ b/tests/test_generator_core.py @@ -15,16 +15,16 @@ class ExactCoreTests(unittest.TestCase): - def test_k64_exact_allowed_domain_and_components(self): - selected = [r for r in json.loads(g.TABLE.read_text()) if 5 <= r['m'] <= 64] - self.assertEqual([r['m'] for r in selected], list(range(5, 65))) + def test_k61_exact_allowed_domain_and_components(self): + selected = [r for r in json.loads(g.TABLE.read_text()) if 5 <= r['m'] <= 61] + self.assertEqual([r['m'] for r in selected], list(range(5, 62))) with tempfile.TemporaryDirectory() as temporary: table = Path(temporary) / 'table.json' table.write_text(json.dumps(selected)) self.assertEqual(load_table(table, g.coefficients), selected) mutations = { - 'missing64': lambda r: r.pop(), - 'extra65': lambda r: r.append(dict(r[-1], m=65)), + 'missing61': lambda r: r.pop(), + 'extra62': lambda r: r.append(dict(r[-1], m=62)), 'duplicate': lambda r: r.__setitem__(1, r[0]), 'reordered': lambda r: r.reverse(), 'duplicate component': lambda r: r[0]['components'].__setitem__( @@ -41,23 +41,23 @@ def test_k64_exact_allowed_domain_and_components(self): with self.assertRaises(ValueError): load_table(table, g.coefficients) - def test_k64_generator_covers_59_finite_cases_and_one_shared_base(self): + def test_k61_generator_covers_56_finite_cases_and_one_shared_base(self): with tempfile.TemporaryDirectory() as temporary: output = Path(temporary) / 'output' result = g.generate(output) - self.assertEqual(result['rows'], list(range(5, 65))) - self.assertEqual(result['groups'][-1]['rows'], [61, 62, 63, 64]) + self.assertEqual(result['rows'], list(range(5, 62))) + self.assertEqual(result['groups'][-1]['rows'], [61]) self.assertEqual(len(result['groups']), 8) - self.assertTrue((output / 'Sendov/DistillationFinite/Rows61_64.lean').is_file()) - self.assertFalse((output / 'Sendov/DistillationFinite/Row64.lean').exists()) + self.assertTrue((output / 'Sendov/DistillationFinite/Rows61_61.lean').is_file()) + self.assertFalse((output / 'Sendov/DistillationFinite/Row61.lean').exists()) aggregate = (output / 'Sendov/Common/DistillationFinite.lean').read_text() cases = [f' · exact (distillFinite_{m} α hα (by linarith)).trans_lt ' f'distillFiniteBound_{m}' for m in range(5, 34)] cases += [f' · exact (distillFinite_{m} α hα h17).trans_lt ' - f'distillFiniteBound_{m}' for m in range(34, 64)] + f'distillFiniteBound_{m}' for m in range(34, 61)] self.assertEqual([line for line in aggregate.splitlines() if line.startswith(' · exact (distillFinite_')], cases) - self.assertIn('(hm63 : m ≤ 63)', aggregate) + self.assertIn('(hm60 : m ≤ 60)', aggregate) for path in output.rglob('*.lean'): self.assertNotIn('two_thirds', path.read_text()) self.assertNotIn('distillFiniteTailBase', path.read_text()) @@ -69,6 +69,42 @@ def test_real_pilot_uses_raw_coefficient_list(self): self.assertNotIn('have hid', text) self.assertNotIn('sign_0_left_0', text) + def test_every_flank_keeps_the_complete_original_identity(self): + identities = empty = 0 + for row in g.load_table(g.TABLE, g.coefficients): + m = row['m'] + for component in row['components']: + j = component['index'] + for side, a, b in [('left', F(0), F(component['lo'])), + ('right', F(component['hi']), min(F(17), F(m, 2)))]: + with self.subTest(m=m, component=j, side=side): + text, count = g.sign_source(m, j, side, a, b) + self.assertIn(f'0 ≤ {g.signed(j, m, side)}', text) + if a == b: + empty += 1 + self.assertEqual(count, 0) + self.assertIn('False.elim', text) + self.assertNotIn('coeffs_pos', text) + continue + identities += 1 + self.assertEqual(count, 1) + p = g.coefficients(m, j) + if (j == 0) != (side == 'left'): + p = [-c for c in p] + scale, cs = g.certificate(p, a, b) + compact = ''.join(text.split()) + self.assertIn('BernsteinCert.coeffs_pos[' + + ','.join(map(str, cs)) + ']', compact) + self.assertIn(f'(lo:={g.rat(a)})(hi:={g.rat(b)})(s:={scale})' + .replace(' ', ''), compact) + self.assertIn(f'unfold distillCritical{j}', text) + self.assertIn('simp only [BernsteinCert.coeffTree_eval_cons,', text) + self.assertIn('BernsteinCert.coeffTree_eval_nil', text) + self.assertEqual(text.count(' ring1\n'), 1) + self.assertNotIn('norm_num only', text) + self.assertNotIn('bernstein_ring', text) + self.assertEqual((identities, empty), (307, 35)) + def test_empty_polynomial_and_bad_interval_are_rejected(self): with self.assertRaisesRegex(ValueError, 'empty'): g.certificate([], F(0), F(1)) diff --git a/tests/test_generators.py b/tests/test_generators.py index 785b3c2..2a897d2 100644 --- a/tests/test_generators.py +++ b/tests/test_generators.py @@ -39,7 +39,7 @@ class GeneratorTests(unittest.TestCase): def test_retained_table_matches_pinned_original_subset(self): table = ROOT / 'data/paper_certificate_table.json' self.assertEqual(digest(table), EXPECTED['table_sha256']) - self.assertEqual([r['m'] for r in json.loads(table.read_text())], list(range(5, 65))) + self.assertEqual([r['m'] for r in json.loads(table.read_text())], list(range(5, 62))) def setUp(self): self.temp = tempfile.TemporaryDirectory() @@ -68,9 +68,9 @@ def assert_distillation(self, output): actual = {str(p.relative_to(output)): digest(p) for p in output.rglob('*') if p.is_file()} self.assertEqual(actual, EXPECTED['distillation']) aggregate = (output / 'Sendov/Common/DistillationFinite.lean').read_text() - self.assertEqual(aggregate.count(' · exact (distillFinite_'), 59) - self.assertTrue((output / 'Sendov/DistillationFinite/Rows61_64.lean').is_file()) - self.assertFalse((output / 'Sendov/DistillationFinite/Row64.lean').exists()) + self.assertEqual(aggregate.count(' · exact (distillFinite_'), 56) + self.assertTrue((output / 'Sendov/DistillationFinite/Rows61_61.lean').is_file()) + self.assertFalse((output / 'Sendov/DistillationFinite/Row61.lean').exists()) self.assertFalse((output / 'Sendov/DistillationFinite/Row5.lean').exists()) def test_complete_cli_regeneration_from_all_cwds(self): @@ -98,8 +98,8 @@ def test_sinh_explicit_and_default_outputs_from_all_cwds(self): def test_bad_data_is_rejected_before_any_publication(self): original = json.loads((self.repo / 'data/paper_certificate_table.json').read_text()) mutations = { - 'missing64': lambda r: r.pop(), - 'extra65': lambda r: r.append(dict(r[-1], m=65)), + 'missing61': lambda r: r.pop(), + 'extra62': lambda r: r.append(dict(r[-1], m=62)), 'duplicate row': lambda r: r.__setitem__(1, r[0]), 'row order': lambda r: r.reverse(), 'missing component': lambda r: r[0]['components'].pop(), From 971df74e21b1582f7c470deb1e82634f0890db5d Mon Sep 17 00:00:00 2001 From: Methode Date: Sun, 13 Sep 2026 06:52:13 -0700 Subject: [PATCH 10/24] refactor(sendov): share bounded-degree estimates and simplify budget proofs --- README.md | 13 +- Sendov/Common/DistillationBounds.lean | 6 +- Sendov/Common/DistillationFinite.lean | 13 +- Sendov/DistillationFinite/Rows13_20.lean | 96 ++- Sendov/DistillationFinite/Rows21_28.lean | 96 ++- Sendov/DistillationFinite/Rows29_36.lean | 96 ++- Sendov/DistillationFinite/Rows37_44.lean | 96 ++- Sendov/DistillationFinite/Rows45_52.lean | 96 ++- Sendov/DistillationFinite/Rows53_55.lean | 311 +++++++ Sendov/DistillationFinite/Rows53_60.lean | 782 ------------------ Sendov/DistillationFinite/Rows5_12.lean | 96 ++- Sendov/DistillationFinite/Rows61_61.lean | 12 +- Sendov/LargeDegree/DistillationTail.lean | 151 +++- Sendov/LargeDegree/DistillationTailBound.lean | 42 +- data/README.md | 8 +- data/paper_certificate_table.json | 185 ----- docs/design.md | 32 +- docs/getting-started.md | 5 +- scripts/GENERATORS.md | 10 +- scripts/axioms.lean | 3 + scripts/bundle_rows.py | 8 +- scripts/distillation_data.py | 11 +- scripts/gen_distillation.py | 18 +- tests/BoundaryConsumer.lean | 18 +- tests/EarlierTail.lean | 18 +- tests/Localbudgets.lean | 154 ++++ tests/Localranges.lean | 54 ++ tests/expected.json | 20 +- tests/test_axiom_audit.py | 9 +- tests/test_bundle_rows.py | 17 +- tests/test_generator_core.py | 76 +- tests/test_generators.py | 9 +- 32 files changed, 1234 insertions(+), 1327 deletions(-) create mode 100644 Sendov/DistillationFinite/Rows53_55.lean delete mode 100644 Sendov/DistillationFinite/Rows53_60.lean create mode 100644 tests/Localbudgets.lean create mode 100644 tests/Localranges.lean diff --git a/README.md b/README.md index a70ae63..84a723f 100644 --- a/README.md +++ b/README.md @@ -38,12 +38,17 @@ The convention is **`m = n - 1`**. The final degree split now uses the finite proof for `5 ≤ m ≤ 60` (through `n=61`), then the real-parameter tail for `m ≥ 61` (from `n=62`). The latter reuses the existing row-61 certificate to prove a bound of `<199/200`, which is sufficient for the scalar `<1`. -Exactly 57 unchanged certificate records, `5 ≤ m ≤ 61`, are retained. The finite -aggregate consumes 56 cases; the tail consumes row 61 from the shared final -group `Rows61_61`. Rows 62–81 and the old `<2/3` tail interfaces are retired. +Exactly 52 unchanged certificate records, `5 ≤ m ≤ 55` and `m=61`, are retained. +The finite aggregate uses 50 individual cases for `5 ≤ m ≤ 54` and a single +real interval theorem for `55 ≤ m ≤ 61`, with the original row-55 budgets +constructed internally. The tail still consumes row 61 from `Rows61_61`. +Rows 56–60, 62–81 and the old `<2/3` tail interfaces are retired. There is no separate duplicate row-61 module or second certificate representation. The earlier tail uses the rational fourth-power envelope cap `(21/22)^4` -to retain stronger logarithmic decay, with the same rational-component alpha split. +to retain stronger logarithmic decay. The rational component is antitone already +from 55, using an alpha split at 10. On the bounded interval, the two exponential +components may grow: linear weights bound that growth, giving the exact total +`58135011269/58896123000 < 199/200`. No new Bernstein certificates are introduced. Each finite case uses the complete critical polynomials of degrees **7, 7, 4**. Exact Bernstein identities prove derivative signs on the full outer intervals; diff --git a/Sendov/Common/DistillationBounds.lean b/Sendov/Common/DistillationBounds.lean index 353a48f..9f59396 100644 --- a/Sendov/Common/DistillationBounds.lean +++ b/Sendov/Common/DistillationBounds.lean @@ -5,9 +5,9 @@ import Sendov.LargeDegree.DistillationTailBound # The complete scalar upper bound The original degree is `n`; the scalar parameter is `m = n - 1`. -The scalar consumer uses finite rows for `5 ≤ m ≤ 60` and the real-degree -tail based on the existing row 61 for `m ≥ 61`. These disjoint ranges cover -every natural `m ≥ 5`; exactly the 57 records from 5 through 61 are retained. +The scalar consumer uses finite rows for `5 ≤ m ≤ 54`, the real interval +`55 ≤ m ≤ 61` based on row 55, and the real-degree tail based on row 61. +Exactly the 52 original records 5 through 55 and 61 are retained. -/ namespace Sendov diff --git a/Sendov/Common/DistillationFinite.lean b/Sendov/Common/DistillationFinite.lean index e88bb36..d0870ff 100644 --- a/Sendov/Common/DistillationFinite.lean +++ b/Sendov/Common/DistillationFinite.lean @@ -4,8 +4,9 @@ import Sendov.DistillationFinite.Rows21_28 import Sendov.DistillationFinite.Rows29_36 import Sendov.DistillationFinite.Rows37_44 import Sendov.DistillationFinite.Rows45_52 -import Sendov.DistillationFinite.Rows53_60 +import Sendov.DistillationFinite.Rows53_55 import Sendov.DistillationFinite.Rows61_61 +import Sendov.LargeDegree.DistillationTailBound /-! Exact finite-domain critical-bracket closure. Fixed original paper budgets; see DistillationCriticalFinite for attribution. No sampled truth or global T grid. -/ @@ -14,6 +15,10 @@ namespace Sendov theorem distillFinite_components {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) {α : ℝ} (hα : 0 ≤ α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := by + by_cases hinterval : 55 ≤ m + · exact distillComponents_interval_55_61 + ⟨by exact_mod_cast hinterval, by exact_mod_cast (show m ≤ 61 by omega)⟩ hα h17 + have hm54 : m ≤ 54 := by omega interval_cases m · exact (distillFinite_5 α hα (by linarith)).trans_lt distillFiniteBound_5 · exact (distillFinite_6 α hα (by linarith)).trans_lt distillFiniteBound_6 @@ -65,12 +70,6 @@ theorem distillFinite_components {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) · exact (distillFinite_52 α hα h17).trans_lt distillFiniteBound_52 · exact (distillFinite_53 α hα h17).trans_lt distillFiniteBound_53 · exact (distillFinite_54 α hα h17).trans_lt distillFiniteBound_54 - · exact (distillFinite_55 α hα h17).trans_lt distillFiniteBound_55 - · exact (distillFinite_56 α hα h17).trans_lt distillFiniteBound_56 - · exact (distillFinite_57 α hα h17).trans_lt distillFiniteBound_57 - · exact (distillFinite_58 α hα h17).trans_lt distillFiniteBound_58 - · exact (distillFinite_59 α hα h17).trans_lt distillFiniteBound_59 - · exact (distillFinite_60 α hα h17).trans_lt distillFiniteBound_60 theorem distillFinite_scalar {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) {α : ℝ} (hα : 0 < α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : diff --git a/Sendov/DistillationFinite/Rows13_20.lean b/Sendov/DistillationFinite/Rows13_20.lean index a9b459f..ee407d7 100644 --- a/Sendov/DistillationFinite/Rows13_20.lean +++ b/Sendov/DistillationFinite/Rows13_20.lean @@ -38,7 +38,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : apply distillT0_le_of_critical (l := (13 / 4)) (r := (7 / 2)) (d := (13 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 3) : 0 ≤ -distillCritical1 13 x := by @@ -69,7 +69,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : 10 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 3) : 0 ≤ -distillCritical2 13 x := by @@ -99,7 +99,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : 10 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow13 @@ -108,8 +108,10 @@ theorem distillFinite_13 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : have h0 := CriticalRow13.component0 α hα hd have h1 := CriticalRow13.component1 α hα hd have h2 := CriticalRow13.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 13 + (239 / 1000) + (77 / 500) + (129 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (15929 / 19500) := by norm_num only [distillEBudget] theorem distillFiniteBound_13 : ((15929 / 19500) : ℝ) < 199 / 200 := by norm_num @@ -154,7 +156,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : apply distillT0_le_of_critical (l := (7 / 2)) (r := (15 / 4)) (d := 7) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 4)) : 0 ≤ -distillCritical1 14 x := by @@ -186,7 +188,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : 11 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 4)) : 0 ≤ -distillCritical2 14 x := by @@ -216,7 +218,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : 11 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow14 @@ -225,8 +227,10 @@ theorem distillFinite_14 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : have h0 := CriticalRow14.component0 α hα hd have h1 := CriticalRow14.component1 α hα hd have h2 := CriticalRow14.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 14 + (243 / 1000) + (31 / 200) + (33 / 250) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (493 / 600) := by norm_num only [distillEBudget] theorem distillFiniteBound_14 : ((493 / 600) : ℝ) < 199 / 200 := by norm_num @@ -271,7 +275,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : apply distillT0_le_of_critical (l := 4) (r := (17 / 4)) (d := (15 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 4)) : 0 ≤ -distillCritical1 15 x := by @@ -303,7 +307,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : 12 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 4)) : 0 ≤ -distillCritical2 15 x := by @@ -333,7 +337,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : 12 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow15 @@ -342,8 +346,10 @@ theorem distillFinite_15 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : have h0 := CriticalRow15.component0 α hα hd have h1 := CriticalRow15.component1 α hα hd have h2 := CriticalRow15.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 15 + (31 / 125) + (39 / 250) + (17 / 125) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (373 / 450) := by norm_num only [distillEBudget] theorem distillFiniteBound_15 : ((373 / 450) : ℝ) < 199 / 200 := by norm_num @@ -388,7 +394,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : apply distillT0_le_of_critical (l := (17 / 4)) (r := (9 / 2)) (d := 8) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 4) : 0 ≤ -distillCritical1 16 x := by @@ -419,7 +425,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : 13 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 4) : 0 ≤ -distillCritical2 16 x := by @@ -449,7 +455,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : 13 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow16 @@ -458,8 +464,10 @@ theorem distillFinite_16 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : have h0 := CriticalRow16.component0 α hα hd have h1 := CriticalRow16.component1 α hα hd have h2 := CriticalRow16.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 16 + (251 / 1000) + (157 / 1000) + (7 / 50) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (20027 / 24000) := by norm_num only [distillEBudget] theorem distillFiniteBound_16 : ((20027 / 24000) : ℝ) < 199 / 200 := by norm_num @@ -504,7 +512,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : apply distillT0_le_of_critical (l := (19 / 4)) (r := 5) (d := (17 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 2)) : 0 ≤ -distillCritical1 17 x := by @@ -536,7 +544,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : 14 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 4)) : 0 ≤ -distillCritical2 17 x := by @@ -566,7 +574,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : 14 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow17 @@ -575,8 +583,10 @@ theorem distillFinite_17 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : have h0 := CriticalRow17.component0 α hα hd have h1 := CriticalRow17.component1 α hα hd have h2 := CriticalRow17.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 17 + (32 / 125) + (157 / 1000) + (29 / 200) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (21479 / 25500) := by norm_num only [distillEBudget] theorem distillFiniteBound_17 : ((21479 / 25500) : ℝ) < 199 / 200 := by norm_num @@ -621,7 +631,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : apply distillT0_le_of_critical (l := 5) (r := (21 / 4)) (d := 9) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (19 / 4)) : 0 ≤ -distillCritical1 18 x := by @@ -653,7 +663,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : 15 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 2)) : 0 ≤ -distillCritical2 18 x := by @@ -683,7 +693,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : 15 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow18 @@ -692,8 +702,10 @@ theorem distillFinite_18 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : have h0 := CriticalRow18.component0 α hα hd have h1 := CriticalRow18.component1 α hα hd have h2 := CriticalRow18.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 18 + (259 / 1000) + (79 / 500) + (3 / 20) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (11467 / 13500) := by norm_num only [distillEBudget] theorem distillFiniteBound_18 : ((11467 / 13500) : ℝ) < 199 / 200 := by norm_num @@ -738,7 +750,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : apply distillT0_le_of_critical (l := (21 / 4)) (r := (11 / 2)) (d := (19 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 4)) : 0 ≤ -distillCritical1 19 x := by @@ -770,7 +782,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : 16 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 5) : 0 ≤ -distillCritical2 19 x := by @@ -800,7 +812,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : 16 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow19 @@ -809,8 +821,10 @@ theorem distillFinite_19 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : have h0 := CriticalRow19.component0 α hα hd have h1 := CriticalRow19.component1 α hα hd have h2 := CriticalRow19.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 19 + (131 / 500) + (159 / 1000) + (77 / 500) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (1951 / 2280) := by norm_num only [distillEBudget] theorem distillFiniteBound_19 : ((1951 / 2280) : ℝ) < 199 / 200 := by norm_num @@ -855,7 +869,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : apply distillT0_le_of_critical (l := (23 / 4)) (r := 6) (d := 10) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (11 / 2)) : 0 ≤ -distillCritical1 20 x := by @@ -887,7 +901,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : 17 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 4)) : 0 ≤ -distillCritical2 20 x := by @@ -917,7 +931,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : 17 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow20 @@ -926,8 +940,10 @@ theorem distillFinite_20 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : have h0 := CriticalRow20.component0 α hα hd have h1 := CriticalRow20.component1 α hα hd have h2 := CriticalRow20.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 20 + (53 / 200) + (159 / 1000) + (4 / 25) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (5179 / 6000) := by norm_num only [distillEBudget] theorem distillFiniteBound_20 : ((5179 / 6000) : ℝ) < 199 / 200 := by norm_num diff --git a/Sendov/DistillationFinite/Rows21_28.lean b/Sendov/DistillationFinite/Rows21_28.lean index 80234f9..158365e 100644 --- a/Sendov/DistillationFinite/Rows21_28.lean +++ b/Sendov/DistillationFinite/Rows21_28.lean @@ -37,7 +37,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : apply distillT0_le_of_critical (l := 6) (r := (25 / 4)) (d := (21 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 6) : 0 ≤ -distillCritical1 21 x := by @@ -68,7 +68,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : 18 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (11 / 2)) : 0 ≤ -distillCritical2 21 x := by @@ -98,7 +98,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : 18 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow21 @@ -107,8 +107,10 @@ theorem distillFinite_21 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : have h0 := CriticalRow21.component0 α hα hd have h1 := CriticalRow21.component1 α hα hd have h2 := CriticalRow21.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 21 + (67 / 250) + (4 / 25) + (33 / 200) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (7837 / 9000) := by norm_num only [distillEBudget] theorem distillFiniteBound_21 : ((7837 / 9000) : ℝ) < 199 / 200 := by norm_num @@ -153,7 +155,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : apply distillT0_le_of_critical (l := (13 / 2)) (r := (27 / 4)) (d := 11) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 4)) : 0 ≤ -distillCritical1 22 x := by @@ -185,7 +187,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : 19 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 4)) : 0 ≤ -distillCritical2 22 x := by @@ -215,7 +217,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : 19 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow22 @@ -224,8 +226,10 @@ theorem distillFinite_22 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : have h0 := CriticalRow22.component0 α hα hd have h1 := CriticalRow22.component1 α hα hd have h2 := CriticalRow22.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 22 + (271 / 1000) + (4 / 25) + (17 / 100) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (14479 / 16500) := by norm_num only [distillEBudget] theorem distillFiniteBound_22 : ((14479 / 16500) : ℝ) < 199 / 200 := by norm_num @@ -270,7 +274,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : apply distillT0_le_of_critical (l := (27 / 4)) (r := 7) (d := (23 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 4)) : 0 ≤ -distillCritical1 23 x := by @@ -302,7 +306,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : 20 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 4)) : 0 ≤ -distillCritical2 23 x := by @@ -332,7 +336,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : 20 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow23 @@ -341,8 +345,10 @@ theorem distillFinite_23 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : have h0 := CriticalRow23.component0 α hα hd have h1 := CriticalRow23.component1 α hα hd have h2 := CriticalRow23.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 23 + (273 / 1000) + (161 / 1000) + (7 / 40) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (61021 / 69000) := by norm_num only [distillEBudget] theorem distillFiniteBound_23 : ((61021 / 69000) : ℝ) < 199 / 200 := by norm_num @@ -387,7 +393,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : apply distillT0_le_of_critical (l := (29 / 4)) (r := (15 / 2)) (d := 12) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 4)) : 0 ≤ -distillCritical1 24 x := by @@ -419,7 +425,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : 21 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 2)) : 0 ≤ -distillCritical2 24 x := by @@ -449,7 +455,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : 21 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow24 @@ -458,8 +464,10 @@ theorem distillFinite_24 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : have h0 := CriticalRow24.component0 α hα hd have h1 := CriticalRow24.component1 α hα hd have h2 := CriticalRow24.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 24 + (11 / 40) + (161 / 1000) + (9 / 50) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (32051 / 36000) := by norm_num only [distillEBudget] theorem distillFiniteBound_24 : ((32051 / 36000) : ℝ) < 199 / 200 := by norm_num @@ -504,7 +512,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : apply distillT0_le_of_critical (l := (15 / 2)) (r := (31 / 4)) (d := (25 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 2)) : 0 ≤ -distillCritical1 25 x := by @@ -536,7 +544,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : 22 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 4)) : 0 ≤ -distillCritical2 25 x := by @@ -566,7 +574,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : 22 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow25 @@ -575,8 +583,10 @@ theorem distillFinite_25 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : have h0 := CriticalRow25.component0 α hα hd have h1 := CriticalRow25.component1 α hα hd have h2 := CriticalRow25.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 25 + (277 / 1000) + (161 / 1000) + (93 / 500) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (673 / 750) := by norm_num only [distillEBudget] theorem distillFiniteBound_25 : ((673 / 750) : ℝ) < 199 / 200 := by norm_num @@ -621,7 +631,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : apply distillT0_le_of_critical (l := 8) (r := (33 / 4)) (d := 13) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 8) : 0 ≤ -distillCritical1 26 x := by @@ -653,7 +663,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : 23 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 4)) : 0 ≤ -distillCritical2 26 x := by @@ -683,7 +693,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : 23 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow26 @@ -692,8 +702,10 @@ theorem distillFinite_26 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : have h0 := CriticalRow26.component0 α hα hd have h1 := CriticalRow26.component1 α hα hd have h2 := CriticalRow26.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 26 + (279 / 1000) + (81 / 500) + (191 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (35273 / 39000) := by norm_num only [distillEBudget] theorem distillFiniteBound_26 : ((35273 / 39000) : ℝ) < 199 / 200 := by norm_num @@ -738,7 +750,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : apply distillT0_le_of_critical (l := (33 / 4)) (r := (17 / 2)) (d := (27 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 2)) : 0 ≤ -distillCritical1 27 x := by @@ -770,7 +782,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : 24 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 2)) : 0 ≤ -distillCritical2 27 x := by @@ -800,7 +812,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : 24 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow27 @@ -809,8 +821,10 @@ theorem distillFinite_27 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : have h0 := CriticalRow27.component0 α hα hd have h1 := CriticalRow27.component1 α hα hd have h2 := CriticalRow27.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 27 + (7 / 25) + (81 / 500) + (49 / 250) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (36839 / 40500) := by norm_num only [distillEBudget] theorem distillFiniteBound_27 : ((36839 / 40500) : ℝ) < 199 / 200 := by norm_num @@ -855,7 +869,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : apply distillT0_le_of_critical (l := (35 / 4)) (r := 9) (d := 14) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (35 / 4)) : 0 ≤ -distillCritical1 28 x := by @@ -887,7 +901,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : 25 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (31 / 4)) : 0 ≤ -distillCritical2 28 x := by @@ -917,7 +931,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : 25 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow28 @@ -926,8 +940,10 @@ theorem distillFinite_28 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : have h0 := CriticalRow28.component0 α hα hd have h1 := CriticalRow28.component1 α hα hd have h2 := CriticalRow28.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 28 + (141 / 500) + (81 / 500) + (101 / 500) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (5501 / 6000) := by norm_num only [distillEBudget] theorem distillFiniteBound_28 : ((5501 / 6000) : ℝ) < 199 / 200 := by norm_num diff --git a/Sendov/DistillationFinite/Rows29_36.lean b/Sendov/DistillationFinite/Rows29_36.lean index 0280d9c..413e522 100644 --- a/Sendov/DistillationFinite/Rows29_36.lean +++ b/Sendov/DistillationFinite/Rows29_36.lean @@ -37,7 +37,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : apply distillT0_le_of_critical (l := 9) (r := (37 / 4)) (d := (29 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (37 / 4)) : 0 ≤ -distillCritical1 29 x := by @@ -69,7 +69,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : 26 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 8) : 0 ≤ -distillCritical2 29 x := by @@ -99,7 +99,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : 26 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow29 @@ -108,8 +108,10 @@ theorem distillFinite_29 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : have h0 := CriticalRow29.component0 α hα hd have h1 := CriticalRow29.component1 α hα hd have h2 := CriticalRow29.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 29 + (283 / 1000) + (81 / 500) + (207 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (10028 / 10875) := by norm_num only [distillEBudget] theorem distillFiniteBound_29 : ((10028 / 10875) : ℝ) < 199 / 200 := by norm_num @@ -154,7 +156,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : apply distillT0_le_of_critical (l := (19 / 2)) (r := (39 / 4)) (d := 15) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (39 / 4)) : 0 ≤ -distillCritical1 30 x := by @@ -186,7 +188,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : 27 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 2)) : 0 ≤ -distillCritical2 30 x := by @@ -216,7 +218,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : 27 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow30 @@ -225,8 +227,10 @@ theorem distillFinite_30 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : have h0 := CriticalRow30.component0 α hα hd have h1 := CriticalRow30.component1 α hα hd have h2 := CriticalRow30.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 30 + (71 / 250) + (81 / 500) + (53 / 250) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (8347 / 9000) := by norm_num only [distillEBudget] theorem distillFiniteBound_30 : ((8347 / 9000) : ℝ) < 199 / 200 := by norm_num @@ -271,7 +275,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : apply distillT0_le_of_critical (l := (39 / 4)) (r := 10) (d := (31 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 10) : 0 ≤ -distillCritical1 31 x := by @@ -303,7 +307,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : 28 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (35 / 4)) : 0 ≤ -distillCritical2 31 x := by @@ -333,7 +337,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : 28 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow31 @@ -342,8 +346,10 @@ theorem distillFinite_31 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : have h0 := CriticalRow31.component0 α hα hd have h1 := CriticalRow31.component1 α hα hd have h2 := CriticalRow31.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 31 + (57 / 200) + (161 / 1000) + (109 / 500) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (10844 / 11625) := by norm_num only [distillEBudget] theorem distillFiniteBound_31 : ((10844 / 11625) : ℝ) < 199 / 200 := by norm_num @@ -388,7 +394,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : apply distillT0_le_of_critical (l := (41 / 4)) (r := (21 / 2)) (d := 16) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 2)) : 0 ≤ -distillCritical1 32 x := by @@ -420,7 +426,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : 29 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 9) : 0 ≤ -distillCritical2 32 x := by @@ -450,7 +456,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : 29 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow32 @@ -459,8 +465,10 @@ theorem distillFinite_32 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : have h0 := CriticalRow32.component0 α hα hd have h1 := CriticalRow32.component1 α hα hd have h2 := CriticalRow32.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 32 + (143 / 500) + (161 / 1000) + (223 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (9007 / 9600) := by norm_num only [distillEBudget] theorem distillFiniteBound_32 : ((9007 / 9600) : ℝ) < 199 / 200 := by norm_num @@ -505,7 +513,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : apply distillT0_le_of_critical (l := (21 / 2)) (r := (43 / 4)) (d := (33 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 11) : 0 ≤ -distillCritical1 33 x := by @@ -537,7 +545,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : 30 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (37 / 4)) : 0 ≤ -distillCritical2 33 x := by @@ -567,7 +575,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : 30 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow33 @@ -576,8 +584,10 @@ theorem distillFinite_33 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : have h0 := CriticalRow33.component0 α hα hd have h1 := CriticalRow33.component1 α hα hd have h2 := CriticalRow33.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 33 + (143 / 500) + (161 / 1000) + (57 / 250) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (3733 / 3960) := by norm_num only [distillEBudget] theorem distillFiniteBound_33 : ((3733 / 3960) : ℝ) < 199 / 200 := by norm_num @@ -622,7 +632,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := 11) (r := (45 / 4)) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 2)) : 0 ≤ -distillCritical1 34 x := by @@ -654,7 +664,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 31 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (39 / 4)) : 0 ≤ -distillCritical2 34 x := by @@ -684,7 +694,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 31 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow34 @@ -693,8 +703,10 @@ theorem distillFinite_34 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow34.component0 α hα hd have h1 := CriticalRow34.component1 α hα hd have h2 := CriticalRow34.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 34 + (287 / 1000) + (161 / 1000) + (233 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (12089 / 12750) := by norm_num only [distillEBudget] theorem distillFiniteBound_34 : ((12089 / 12750) : ℝ) < 199 / 200 := by norm_num @@ -739,7 +751,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := (45 / 4)) (r := (23 / 2)) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (47 / 4)) : 0 ≤ -distillCritical1 35 x := by @@ -771,7 +783,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 32 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 10) : 0 ≤ -distillCritical2 35 x := by @@ -801,7 +813,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 32 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow35 @@ -810,8 +822,10 @@ theorem distillFinite_35 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow35.component0 α hα hd have h1 := CriticalRow35.component1 α hα hd have h2 := CriticalRow35.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 35 + (287 / 1000) + (4 / 25) + (239 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (1429 / 1500) := by norm_num only [distillEBudget] theorem distillFiniteBound_35 : ((1429 / 1500) : ℝ) < 199 / 200 := by norm_num @@ -856,7 +870,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := (47 / 4)) (r := 12) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (49 / 4)) : 0 ≤ -distillCritical1 36 x := by @@ -888,7 +902,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 33 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (41 / 4)) : 0 ≤ -distillCritical2 36 x := by @@ -918,7 +932,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 33 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow36 @@ -927,8 +941,10 @@ theorem distillFinite_36 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow36.component0 α hα hd have h1 := CriticalRow36.component1 α hα hd have h2 := CriticalRow36.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 36 + (287 / 1000) + (4 / 25) + (61 / 250) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (51689 / 54000) := by norm_num only [distillEBudget] theorem distillFiniteBound_36 : ((51689 / 54000) : ℝ) < 199 / 200 := by norm_num diff --git a/Sendov/DistillationFinite/Rows37_44.lean b/Sendov/DistillationFinite/Rows37_44.lean index b9aa485..0419e39 100644 --- a/Sendov/DistillationFinite/Rows37_44.lean +++ b/Sendov/DistillationFinite/Rows37_44.lean @@ -37,7 +37,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := 12) (r := (49 / 4)) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (51 / 4)) : 0 ≤ -distillCritical1 37 x := by @@ -69,7 +69,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 34 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 2)) : 0 ≤ -distillCritical2 37 x := by @@ -99,7 +99,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 34 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow37 @@ -108,8 +108,10 @@ theorem distillFinite_37 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow37.component0 α hα hd have h1 := CriticalRow37.component1 α hα hd have h2 := CriticalRow37.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 37 + (287 / 1000) + (159 / 1000) + (249 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (21329 / 22200) := by norm_num only [distillEBudget] theorem distillFiniteBound_37 : ((21329 / 22200) : ℝ) < 199 / 200 := by norm_num @@ -154,7 +156,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := (25 / 2)) (r := (51 / 4)) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (53 / 4)) : 0 ≤ -distillCritical1 38 x := by @@ -186,7 +188,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 35 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 11) : 0 ≤ -distillCritical2 38 x := by @@ -216,7 +218,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 35 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow38 @@ -225,8 +227,10 @@ theorem distillFinite_38 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow38.component0 α hα hd have h1 := CriticalRow38.component1 α hα hd have h2 := CriticalRow38.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 38 + (287 / 1000) + (159 / 1000) + (127 / 500) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (2201 / 2280) := by norm_num only [distillEBudget] theorem distillFiniteBound_38 : ((2201 / 2280) : ℝ) < 199 / 200 := by norm_num @@ -271,7 +275,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := 13) (r := (53 / 4)) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 2)) : 0 ≤ -distillCritical1 39 x := by @@ -303,7 +307,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 36 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (45 / 4)) : 0 ≤ -distillCritical2 39 x := by @@ -333,7 +337,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 36 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow39 @@ -342,8 +346,10 @@ theorem distillFinite_39 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow39.component0 α hα hd have h1 := CriticalRow39.component1 α hα hd have h2 := CriticalRow39.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 39 + (287 / 1000) + (79 / 500) + (259 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (14171 / 14625) := by norm_num only [distillEBudget] theorem distillFiniteBound_39 : ((14171 / 14625) : ℝ) < 199 / 200 := by norm_num @@ -388,7 +394,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := (53 / 4)) (r := (27 / 2)) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 14) : 0 ≤ -distillCritical1 40 x := by @@ -420,7 +426,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 37 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 2)) : 0 ≤ -distillCritical2 40 x := by @@ -450,7 +456,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 37 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow40 @@ -459,8 +465,10 @@ theorem distillFinite_40 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow40.component0 α hα hd have h1 := CriticalRow40.component1 α hα hd have h2 := CriticalRow40.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 40 + (287 / 1000) + (79 / 500) + (33 / 125) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (11683 / 12000) := by norm_num only [distillEBudget] theorem distillFiniteBound_40 : ((11683 / 12000) : ℝ) < 199 / 200 := by norm_num @@ -505,7 +513,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := (55 / 4)) (r := 14) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 2)) : 0 ≤ -distillCritical1 41 x := by @@ -537,7 +545,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 38 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 12) : 0 ≤ -distillCritical2 41 x := by @@ -567,7 +575,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 38 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow41 @@ -576,8 +584,10 @@ theorem distillFinite_41 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow41.component0 α hα hd have h1 := CriticalRow41.component1 α hα hd have h2 := CriticalRow41.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 41 + (287 / 1000) + (157 / 1000) + (269 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (120199 / 123000) := by norm_num only [distillEBudget] theorem distillFiniteBound_41 : ((120199 / 123000) : ℝ) < 199 / 200 := by norm_num @@ -622,7 +632,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := 14) (r := (57 / 4)) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 15) : 0 ≤ -distillCritical1 42 x := by @@ -653,7 +663,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 39 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (49 / 4)) : 0 ≤ -distillCritical2 42 x := by @@ -683,7 +693,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 39 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow42 @@ -692,8 +702,10 @@ theorem distillFinite_42 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow42.component0 α hα hd have h1 := CriticalRow42.component1 α hα hd have h2 := CriticalRow42.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 42 + (143 / 500) + (39 / 250) + (137 / 500) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (8819 / 9000) := by norm_num only [distillEBudget] theorem distillFiniteBound_42 : ((8819 / 9000) : ℝ) < 199 / 200 := by norm_num @@ -738,7 +750,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := (29 / 2)) (r := (59 / 4)) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (31 / 2)) : 0 ≤ -distillCritical1 43 x := by @@ -770,7 +782,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 40 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 2)) : 0 ≤ -distillCritical2 43 x := by @@ -800,7 +812,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 40 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow43 @@ -809,8 +821,10 @@ theorem distillFinite_43 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow43.component0 α hα hd have h1 := CriticalRow43.component1 α hα hd have h2 := CriticalRow43.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 43 + (143 / 500) + (39 / 250) + (279 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (127009 / 129000) := by norm_num only [distillEBudget] theorem distillFiniteBound_43 : ((127009 / 129000) : ℝ) < 199 / 200 := by norm_num @@ -854,7 +868,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := 15) (r := (61 / 4)) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (63 / 4)) : 0 ≤ -distillCritical1 44 x := by @@ -886,7 +900,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 41 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (51 / 4)) : 0 ≤ -distillCritical2 44 x := by @@ -916,7 +930,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 41 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow44 @@ -925,8 +939,10 @@ theorem distillFinite_44 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow44.component0 α hα hd have h1 := CriticalRow44.component1 α hα hd have h2 := CriticalRow44.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 44 + (143 / 500) + (31 / 200) + (283 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (65159 / 66000) := by norm_num only [distillEBudget] theorem distillFiniteBound_44 : ((65159 / 66000) : ℝ) < 199 / 200 := by norm_num diff --git a/Sendov/DistillationFinite/Rows45_52.lean b/Sendov/DistillationFinite/Rows45_52.lean index c85e728..9467f0d 100644 --- a/Sendov/DistillationFinite/Rows45_52.lean +++ b/Sendov/DistillationFinite/Rows45_52.lean @@ -38,7 +38,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := (61 / 4)) (r := (31 / 2)) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (65 / 4)) : 0 ≤ -distillCritical1 45 x := by @@ -70,7 +70,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 42 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (53 / 4)) : 0 ≤ -distillCritical2 45 x := by @@ -100,7 +100,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 42 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow45 @@ -109,8 +109,10 @@ theorem distillFinite_45 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow45.component0 α hα hd have h1 := CriticalRow45.component1 α hα hd have h2 := CriticalRow45.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 45 + (57 / 200) + (77 / 500) + (36 / 125) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (26729 / 27000) := by norm_num only [distillEBudget] theorem distillFiniteBound_45 : ((26729 / 27000) : ℝ) < 199 / 200 := by norm_num @@ -155,7 +157,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := (63 / 4)) (r := 16) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (67 / 4)) : 0 ≤ -distillCritical1 46 x := by @@ -179,7 +181,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 43 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 2)) : 0 ≤ -distillCritical2 46 x := by @@ -209,7 +211,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 43 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow46 @@ -218,8 +220,10 @@ theorem distillFinite_46 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow46.component0 α hα hd have h1 := CriticalRow46.component1 α hα hd have h2 := CriticalRow46.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 46 + (71 / 250) + (153 / 1000) + (73 / 250) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (34213 / 34500) := by norm_num only [distillEBudget] theorem distillFiniteBound_46 : ((34213 / 34500) : ℝ) < 199 / 200 := by norm_num @@ -264,7 +268,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := 16) (r := (65 / 4)) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : 0 ≤ -distillCritical1 47 x := by @@ -288,7 +292,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 44 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (55 / 4)) : 0 ≤ -distillCritical2 47 x := by @@ -318,7 +322,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 44 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow47 @@ -327,8 +331,10 @@ theorem distillFinite_47 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow47.component0 α hα hd have h1 := CriticalRow47.component1 α hα hd have h2 := CriticalRow47.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 47 + (283 / 1000) + (69 / 500) + (297 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (69119 / 70500) := by norm_num only [distillEBudget] theorem distillFiniteBound_47 : ((69119 / 70500) : ℝ) < 199 / 200 := by norm_num @@ -373,7 +379,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := (33 / 2)) (r := (67 / 4)) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : 0 ≤ -distillCritical1 48 x := by @@ -397,7 +403,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 45 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 14) : 0 ≤ -distillCritical2 48 x := by @@ -427,7 +433,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 45 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow48 @@ -436,8 +442,10 @@ theorem distillFinite_48 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow48.component0 α hα hd have h1 := CriticalRow48.component1 α hα hd have h2 := CriticalRow48.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 48 + (283 / 1000) + (17 / 125) + (301 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (14143 / 14400) := by norm_num only [distillEBudget] theorem distillFiniteBound_48 : ((14143 / 14400) : ℝ) < 199 / 200 := by norm_num @@ -474,7 +482,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : 0 ≤ -distillCritical1 49 x := by @@ -498,7 +506,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 46 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 2)) : 0 ≤ -distillCritical2 49 x := by @@ -528,7 +536,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 46 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow49 @@ -537,8 +545,10 @@ theorem distillFinite_49 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow49.component0 α hα hd have h1 := CriticalRow49.component1 α hα hd have h2 := CriticalRow49.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 49 + (261 / 1000) + (131 / 1000) + (153 / 500) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (10079 / 10500) := by norm_num only [distillEBudget] theorem distillFiniteBound_49 : ((10079 / 10500) : ℝ) < 199 / 200 := by norm_num @@ -575,7 +585,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : 0 ≤ -distillCritical1 50 x := by @@ -599,7 +609,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 47 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (59 / 4)) : 0 ≤ -distillCritical2 50 x := by @@ -629,7 +639,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 47 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow50 @@ -638,8 +648,10 @@ theorem distillFinite_50 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow50.component0 α hα hd have h1 := CriticalRow50.component1 α hα hd have h2 := CriticalRow50.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 50 + (13 / 50) + (63 / 500) + (31 / 100) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (2873 / 3000) := by norm_num only [distillEBudget] theorem distillFiniteBound_50 : ((2873 / 3000) : ℝ) < 199 / 200 := by norm_num @@ -676,7 +688,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : 0 ≤ -distillCritical1 51 x := by @@ -700,7 +712,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 48 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 15) : 0 ≤ -distillCritical2 51 x := by @@ -730,7 +742,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 48 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow51 @@ -739,8 +751,10 @@ theorem distillFinite_51 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow51.component0 α hα hd have h1 := CriticalRow51.component1 α hα hd have h2 := CriticalRow51.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 51 + (129 / 500) + (3 / 25) + (157 / 500) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (36469 / 38250) := by norm_num only [distillEBudget] theorem distillFiniteBound_51 : ((36469 / 38250) : ℝ) < 199 / 200 := by norm_num @@ -777,7 +791,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : 0 ≤ -distillCritical1 52 x := by @@ -801,7 +815,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 49 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (61 / 4)) : 0 ≤ -distillCritical2 52 x := by @@ -831,7 +845,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 49 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow52 @@ -840,8 +854,10 @@ theorem distillFinite_52 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow52.component0 α hα hd have h1 := CriticalRow52.component1 α hα hd have h2 := CriticalRow52.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 52 + (32 / 125) + (113 / 1000) + (159 / 500) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (73961 / 78000) := by norm_num only [distillEBudget] theorem distillFiniteBound_52 : ((73961 / 78000) : ℝ) < 199 / 200 := by norm_num diff --git a/Sendov/DistillationFinite/Rows53_55.lean b/Sendov/DistillationFinite/Rows53_55.lean new file mode 100644 index 0000000..72f5c0a --- /dev/null +++ b/Sendov/DistillationFinite/Rows53_55.lean @@ -0,0 +1,311 @@ +import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.BernsteinList + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow53 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 53 x := by + refine (BernsteinCert.coeffs_pos + [1513797660, 42131596608, 446676961914, 2234052914256, 5316752614008, 5840850173315, + 4422429264134, 356763655089] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 53 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 53 α ≤ (127 / 500) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 53 x := by + refine (BernsteinCert.coeffs_pos + [31705522200, 924227481744, 10509062039568, 58856051828016, 169761742211382, + 247461175693060, 179088983157658, 22448083421556] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 53 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 53 α ≤ (21 / 200) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 50 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (63 / 4)) : + 0 ≤ -distillCritical2 53 x := by + refine (BernsteinCert.coeffs_pos + [6784000, 92588800, 343321056, 280846744, 770692] + (lo := 0) (hi := (63 / 4)) (s := 194481) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 16 17) : + 0 ≤ distillCritical2 53 x := by + refine (BernsteinCert.coeffs_pos + [1190908, 10662876, 25488990, 23772974, 7756068] + (lo := 16) (hi := 17) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 53 α ≤ (161 / 500) := by + apply distillT2_le_of_critical (l := (63 / 4)) (r := 16) (d := 17) + 50 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow53 + +theorem distillFinite_53 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 53 + distillT0 53 α + distillT1 53 α + distillT2 53 α ≤ (149779 / 159000) := by + have h0 := CriticalRow53.component0 α hα hd + have h1 := CriticalRow53.component1 α hα hd + have h2 := CriticalRow53.component2 α hα hd + calc + _ ≤ distillEBudget 53 + (127 / 500) + (21 / 200) + (161 / 500) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (149779 / 159000) := by norm_num only [distillEBudget] + +theorem distillFiniteBound_53 : ((149779 / 159000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow54 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 54 x := by + refine (BernsteinCert.coeffs_pos + [1573065360, 43805120112, 464800048200, 2327697029160, 5551214151240, 6113834596908, + 4624399808028, 443076028200] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 54 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 54 α ≤ (251 / 1000) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 54 x := by + refine (BernsteinCert.coeffs_pos + [33554003760, 978505020576, 11132892077184, 62409028340160, 180305850272796, + 263672609579496, 192283241772420, 26422249246680] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 54 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 54 α ≤ (49 / 500) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 51 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 16) : + 0 ≤ -distillCritical2 54 x := by + refine (BernsteinCert.coeffs_pos + [557685, 7706340, 28893294, 23805444, 160261] + (lo := 0) (hi := 16) (s := 16384) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (65 / 4) 17) : + 0 ≤ distillCritical2 54 x := by + refine (BernsteinCert.coeffs_pos + [216994460, 2042940200, 4922556096, 4586464640, 1489863680] + (lo := (65 / 4)) (hi := 17) (s := 81) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 54 α ≤ (163 / 500) := by + apply distillT2_le_of_critical (l := 16) (r := (65 / 4)) (d := 17) + 51 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow54 + +theorem distillFinite_54 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 54 + distillT0 54 α + distillT1 54 α + distillT2 54 α ≤ (379 / 405) := by + have h0 := CriticalRow54.component0 α hα hd + have h1 := CriticalRow54.component1 α hα hd + have h2 := CriticalRow54.component2 α hα hd + calc + _ ≤ distillEBudget 54 + (251 / 1000) + (49 / 500) + (163 / 500) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (379 / 405) := by norm_num only [distillEBudget] + +theorem distillFiniteBound_54 : ((379 / 405) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end + +section + +/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. +Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ + +namespace Sendov +namespace CriticalRow55 + +private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ distillCritical0 55 x := by + refine (BernsteinCert.coeffs_pos + [1633470300, 45511158960, 483281148330, 2423229278040, 5790465053328, 6391904029355, + 4828121873130, 529282780285] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical0 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ -distillCritical0 55 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 55 α ≤ (31 / 125) := by + apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_0_left sign_0_right ?_ ⟨hα, hd⟩ + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : + 0 ≤ -distillCritical1 55 x := by + refine (BernsteinCert.coeffs_pos + [35472848400, 1034860655880, 11780791646040, 66100487612760, 191265858612744, + 280528399081990, 205997669702640, 30571708087130] + (lo := 0) (hi := 17) (s := 410338673) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical1 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : + 0 ≤ distillCritical1 55 x := by + exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) + +theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT1 55 α ≤ (91 / 1000) := by + apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) + 52 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_1_left sign_1_right ?_ ⟨hα, hd⟩ + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (65 / 4)) : + 0 ≤ -distillCritical2 55 x := by + refine (BernsteinCert.coeffs_pos + [1824768, 25526016, 96754560, 80269864, 845252] + (lo := 0) (hi := (65 / 4)) (s := 54925) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 2) 17) : + 0 ≤ distillCritical2 55 x := by + refine (BernsteinCert.coeffs_pos + [7531920, 80886852, 200203608, 187915664, 61067104] + (lo := (33 / 2)) (hi := 17) (s := 1) + (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le + unfold distillCritical2 + simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, + List.length_cons, List.length_nil, Nat.cast_ofNat] + ring1 + +theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT2 55 α ≤ (33 / 100) := by + apply distillT2_le_of_critical (l := (65 / 4)) (r := (33 / 2)) (d := 17) + 52 (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) + sign_2_left sign_2_right ?_ ⟨hα, hd⟩ + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +end CriticalRow55 + +theorem distillFinite_55 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillEBudget 55 + distillT0 55 α + distillT1 55 α + distillT2 55 α ≤ (30677 / 33000) := by + have h0 := CriticalRow55.component0 α hα hd + have h1 := CriticalRow55.component1 α hα hd + have h2 := CriticalRow55.component2 α hα hd + calc + _ ≤ distillEBudget 55 + (31 / 125) + (91 / 1000) + (33 / 100) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (30677 / 33000) := by norm_num only [distillEBudget] + +theorem distillFiniteBound_55 : ((30677 / 33000) : ℝ) < 199 / 200 := by norm_num + +end Sendov + +end diff --git a/Sendov/DistillationFinite/Rows53_60.lean b/Sendov/DistillationFinite/Rows53_60.lean deleted file mode 100644 index 00ffa6d..0000000 --- a/Sendov/DistillationFinite/Rows53_60.lean +++ /dev/null @@ -1,782 +0,0 @@ -import Sendov.Common.DistillationCriticalFinite -import Sendov.Common.BernsteinList - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow53 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 53 x := by - refine (BernsteinCert.coeffs_pos - [1513797660, 42131596608, 446676961914, 2234052914256, 5316752614008, 5840850173315, - 4422429264134, 356763655089] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 53 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 53 α ≤ (127 / 500) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 53 x := by - refine (BernsteinCert.coeffs_pos - [31705522200, 924227481744, 10509062039568, 58856051828016, 169761742211382, - 247461175693060, 179088983157658, 22448083421556] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 53 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 53 α ≤ (21 / 200) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 50 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (63 / 4)) : - 0 ≤ -distillCritical2 53 x := by - refine (BernsteinCert.coeffs_pos - [6784000, 92588800, 343321056, 280846744, 770692] - (lo := 0) (hi := (63 / 4)) (s := 194481) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 16 17) : - 0 ≤ distillCritical2 53 x := by - refine (BernsteinCert.coeffs_pos - [1190908, 10662876, 25488990, 23772974, 7756068] - (lo := 16) (hi := 17) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 53 α ≤ (161 / 500) := by - apply distillT2_le_of_critical (l := (63 / 4)) (r := 16) (d := 17) - 50 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow53 - -theorem distillFinite_53 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 53 + distillT0 53 α + distillT1 53 α + distillT2 53 α ≤ (149779 / 159000) := by - have h0 := CriticalRow53.component0 α hα hd - have h1 := CriticalRow53.component1 α hα hd - have h2 := CriticalRow53.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_53 : ((149779 / 159000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow54 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 54 x := by - refine (BernsteinCert.coeffs_pos - [1573065360, 43805120112, 464800048200, 2327697029160, 5551214151240, 6113834596908, - 4624399808028, 443076028200] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 54 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 54 α ≤ (251 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 54 x := by - refine (BernsteinCert.coeffs_pos - [33554003760, 978505020576, 11132892077184, 62409028340160, 180305850272796, - 263672609579496, 192283241772420, 26422249246680] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 54 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 54 α ≤ (49 / 500) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 51 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 16) : - 0 ≤ -distillCritical2 54 x := by - refine (BernsteinCert.coeffs_pos - [557685, 7706340, 28893294, 23805444, 160261] - (lo := 0) (hi := 16) (s := 16384) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (65 / 4) 17) : - 0 ≤ distillCritical2 54 x := by - refine (BernsteinCert.coeffs_pos - [216994460, 2042940200, 4922556096, 4586464640, 1489863680] - (lo := (65 / 4)) (hi := 17) (s := 81) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 54 α ≤ (163 / 500) := by - apply distillT2_le_of_critical (l := 16) (r := (65 / 4)) (d := 17) - 51 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow54 - -theorem distillFinite_54 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 54 + distillT0 54 α + distillT1 54 α + distillT2 54 α ≤ (379 / 405) := by - have h0 := CriticalRow54.component0 α hα hd - have h1 := CriticalRow54.component1 α hα hd - have h2 := CriticalRow54.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_54 : ((379 / 405) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow55 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 55 x := by - refine (BernsteinCert.coeffs_pos - [1633470300, 45511158960, 483281148330, 2423229278040, 5790465053328, 6391904029355, - 4828121873130, 529282780285] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 55 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 55 α ≤ (31 / 125) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 55 x := by - refine (BernsteinCert.coeffs_pos - [35472848400, 1034860655880, 11780791646040, 66100487612760, 191265858612744, - 280528399081990, 205997669702640, 30571708087130] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 55 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 55 α ≤ (91 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 52 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (65 / 4)) : - 0 ≤ -distillCritical2 55 x := by - refine (BernsteinCert.coeffs_pos - [1824768, 25526016, 96754560, 80269864, 845252] - (lo := 0) (hi := (65 / 4)) (s := 54925) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 2) 17) : - 0 ≤ distillCritical2 55 x := by - refine (BernsteinCert.coeffs_pos - [7531920, 80886852, 200203608, 187915664, 61067104] - (lo := (33 / 2)) (hi := 17) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 55 α ≤ (33 / 100) := by - apply distillT2_le_of_critical (l := (65 / 4)) (r := (33 / 2)) (d := 17) - 52 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow55 - -theorem distillFinite_55 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 55 + distillT0 55 α + distillT1 55 α + distillT2 55 α ≤ (30677 / 33000) := by - have h0 := CriticalRow55.component0 α hα hd - have h1 := CriticalRow55.component1 α hα hd - have h2 := CriticalRow55.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_55 : ((30677 / 33000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow56 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 56 x := by - refine (BernsteinCert.coeffs_pos - [1695012480, 47249713152, 502120262304, 2520649660896, 6034505320272, 6675058470656, - 5033595459440, 615383911344] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 56 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 56 α ≤ (49 / 200) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 56 x := by - refine (BernsteinCert.coeffs_pos - [37463368320, 1093333316256, 12453213960576, 69933049130736, 202649622816480, - 298040369818384, 220240787681920, 34898806757040] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 56 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 56 α ≤ (83 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 53 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (33 / 2)) : - 0 ≤ -distillCritical2 56 x := by - refine (BernsteinCert.coeffs_pos - [1424640, 20171040, 77284288, 64546404, 913448] - (lo := 0) (hi := (33 / 2)) (s := 43923) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (67 / 4) 17) : - 0 ≤ distillCritical2 56 x := by - refine (BernsteinCert.coeffs_pos - [15039724, 480971352, 1363922784, 1345174400, 447183360] - (lo := (67 / 4)) (hi := 17) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 56 α ≤ (167 / 500) := by - apply distillT2_le_of_critical (l := (33 / 2)) (r := (67 / 4)) (d := 17) - 53 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow56 - -theorem distillFinite_56 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 56 + distillT0 56 α + distillT1 56 α + distillT2 56 α ≤ (11069 / 12000) := by - have h0 := CriticalRow56.component0 α hα hd - have h1 := CriticalRow56.component1 α hα hd - have h2 := CriticalRow56.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_56 : ((11069 / 12000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow57 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 57 x := by - refine (BernsteinCert.coeffs_pos - [1757691900, 49020782688, 521317390122, 2619958177728, 6283334952072, 6963297920811, - 5240820566958, 701379421377] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 57 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 57 α ≤ (241 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 57 x := by - refine (BernsteinCert.coeffs_pos - [39526875720, 1153961930304, 13150612235232, 73909332379008, 214464998469258, - 316220347406520, 235021116443862, 39405892070544] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 57 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 57 α ≤ (19 / 250) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 54 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 57 x := by - refine (BernsteinCert.coeffs_pos - [2493180, 36108180, 140875326, 117338634, 389872] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 57 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 57 α ≤ (319 / 1000) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 54 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow57 - -theorem distillFinite_57 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 57 + distillT0 57 α + distillT1 57 α + distillT2 57 α ≤ (19157 / 21375) := by - have h0 := CriticalRow57.component0 α hα hd - have h1 := CriticalRow57.component1 α hα hd - have h2 := CriticalRow57.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_57 : ((19157 / 21375) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow58 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 58 x := by - refine (BernsteinCert.coeffs_pos - [1821508560, 50824367568, 540872531784, 2721154828536, 6536953948728, 7256622379820, - 5449797195684, 787269310384] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 58 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 58 α ≤ (119 / 500) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 58 x := by - refine (BernsteinCert.coeffs_pos - [41664682800, 1216785426624, 13873439684448, 78031956842496, 226719841156332, - 335080157464240, 250347176722068, 44095310841776] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 58 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 58 α ≤ (7 / 100) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 55 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 58 x := by - refine (BernsteinCert.coeffs_pos - [2583900, 37462500, 146596146, 123999334, 2593352] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 58 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 58 α ≤ (161 / 500) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 55 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow58 - -theorem distillFinite_58 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 58 + distillT0 58 α + distillT1 58 α + distillT2 58 α ≤ (15487 / 17400) := by - have h0 := CriticalRow58.component0 α hα hd - have h1 := CriticalRow58.component1 α hα hd - have h2 := CriticalRow58.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_58 : ((15487 / 17400) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow59 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 59 x := by - refine (BernsteinCert.coeffs_pos - [110968380, 3097674576, 32987393370, 166131741960, 399727194720, 444413638099, - 332972079154, 51356092845] - (lo := 0) (hi := 17) (s := 24137569) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 59 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 59 α ≤ (47 / 200) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 59 x := by - refine (BernsteinCert.coeffs_pos - [43878101760, 1281842733816, 14622149522664, 82303542006120, 239422006462956, - 354631625609386, 266227489250140, 48969409884870] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 59 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 59 α ≤ (63 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 56 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 59 x := by - refine (BernsteinCert.coeffs_pos - [2676240, 38841660, 152428584, 130815230, 4863630] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 59 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 59 α ≤ (81 / 250) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 56 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow59 - -theorem distillFinite_59 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 59 + distillT0 59 α + distillT1 59 α + distillT2 59 α ≤ (78047 / 88500) := by - have h0 := CriticalRow59.component0 α hα hd - have h1 := CriticalRow59.component1 α hα hd - have h2 := CriticalRow59.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_59 : ((78047 / 88500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow60 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 60 x := by - refine (BernsteinCert.coeffs_pos - [1952553600, 54529083360, 581056856640, 2929212532080, 7058560036608, 7858526324400, - 5873005016760, 958732225320] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 60 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 60 α ≤ (231 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 60 x := by - refine (BernsteinCert.coeffs_pos - [46168444800, 1349172780480, 15397194964320, 86726707354800, 252579349974384, - 374886577459800, 282670574761680, 54030536013960] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 60 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 60 α ≤ (57 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 57 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 60 x := by - refine (BernsteinCert.coeffs_pos - [2770200, 40245660, 158372640, 137786322, 7200706] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 60 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 60 α ≤ (81 / 250) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 57 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow60 - -theorem distillFinite_60 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 60 + distillT0 60 α + distillT1 60 α + distillT2 60 α ≤ (15691 / 18000) := by - have h0 := CriticalRow60.component0 α hα hd - have h1 := CriticalRow60.component1 α hα hd - have h2 := CriticalRow60.component2 α hα hd - norm_num [distillEBudget] at * - linarith - -theorem distillFiniteBound_60 : ((15691 / 18000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end diff --git a/Sendov/DistillationFinite/Rows5_12.lean b/Sendov/DistillationFinite/Rows5_12.lean index ac5fc39..8df588f 100644 --- a/Sendov/DistillationFinite/Rows5_12.lean +++ b/Sendov/DistillationFinite/Rows5_12.lean @@ -38,7 +38,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : apply distillT0_le_of_critical (l := (1 / 2)) (r := (3 / 4)) (d := (5 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 0) : 0 ≤ -distillCritical1 5 x := by @@ -62,7 +62,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : 2 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (1 / 2)) : 0 ≤ -distillCritical2 5 x := by @@ -92,7 +92,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : 2 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow5 @@ -101,8 +101,10 @@ theorem distillFinite_5 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : have h0 := CriticalRow5.component0 α hα hd have h1 := CriticalRow5.component1 α hα hd have h2 := CriticalRow5.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 5 + (101 / 500) + (191 / 1000) + (37 / 250) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (2723 / 3000) := by norm_num only [distillEBudget] theorem distillFiniteBound_5 : ((2723 / 3000) : ℝ) < 199 / 200 := by norm_num @@ -146,7 +148,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : apply distillT0_le_of_critical (l := 1) (r := (5 / 4)) (d := 3) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (1 / 2)) : 0 ≤ -distillCritical1 6 x := by @@ -178,7 +180,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : 3 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 4)) : 0 ≤ -distillCritical2 6 x := by @@ -208,7 +210,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : 3 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow6 @@ -217,8 +219,10 @@ theorem distillFinite_6 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : have h0 := CriticalRow6.component0 α hα hd have h1 := CriticalRow6.component1 α hα hd have h2 := CriticalRow6.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 6 + (207 / 1000) + (171 / 1000) + (133 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (1931 / 2250) := by norm_num only [distillEBudget] theorem distillFiniteBound_6 : ((1931 / 2250) : ℝ) < 199 / 200 := by norm_num @@ -263,7 +267,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : apply distillT0_le_of_critical (l := (5 / 4)) (r := (3 / 2)) (d := (7 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 4)) : 0 ≤ -distillCritical1 7 x := by @@ -295,7 +299,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : 4 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 1) : 0 ≤ -distillCritical2 7 x := by @@ -325,7 +329,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : 4 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow7 @@ -334,8 +338,10 @@ theorem distillFinite_7 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : have h0 := CriticalRow7.component0 α hα hd have h1 := CriticalRow7.component1 α hα hd have h2 := CriticalRow7.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 7 + (211 / 1000) + (41 / 250) + (31 / 250) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (2497 / 3000) := by norm_num only [distillEBudget] theorem distillFiniteBound_7 : ((2497 / 3000) : ℝ) < 199 / 200 := by norm_num @@ -379,7 +385,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : apply distillT0_le_of_critical (l := (3 / 2)) (r := (7 / 4)) (d := 4) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 4)) : 0 ≤ -distillCritical1 8 x := by @@ -411,7 +417,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : 5 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 2)) : 0 ≤ -distillCritical2 8 x := by @@ -441,7 +447,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : 5 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow8 @@ -450,8 +456,10 @@ theorem distillFinite_8 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : have h0 := CriticalRow8.component0 α hα hd have h1 := CriticalRow8.component1 α hα hd have h2 := CriticalRow8.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 8 + (43 / 200) + (157 / 1000) + (3 / 25) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (9779 / 12000) := by norm_num only [distillEBudget] theorem distillFiniteBound_8 : ((9779 / 12000) : ℝ) < 199 / 200 := by norm_num @@ -495,7 +503,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : apply distillT0_le_of_critical (l := 2) (r := (9 / 4)) (d := (9 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 2)) : 0 ≤ -distillCritical1 9 x := by @@ -526,7 +534,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : 6 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (7 / 4)) : 0 ≤ -distillCritical2 9 x := by @@ -556,7 +564,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : 6 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow9 @@ -565,8 +573,10 @@ theorem distillFinite_9 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : have h0 := CriticalRow9.component0 α hα hd have h1 := CriticalRow9.component1 α hα hd have h2 := CriticalRow9.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 9 + (11 / 50) + (39 / 250) + (3 / 25) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (5473 / 6750) := by norm_num only [distillEBudget] theorem distillFiniteBound_9 : ((5473 / 6750) : ℝ) < 199 / 200 := by norm_num @@ -611,7 +621,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : apply distillT0_le_of_critical (l := (9 / 4)) (r := (5 / 2)) (d := 5) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (7 / 4)) : 0 ≤ -distillCritical1 10 x := by @@ -643,7 +653,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : 7 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 2) : 0 ≤ -distillCritical2 10 x := by @@ -673,7 +683,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : 7 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow10 @@ -682,8 +692,10 @@ theorem distillFinite_10 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : have h0 := CriticalRow10.component0 α hα hd have h1 := CriticalRow10.component1 α hα hd have h2 := CriticalRow10.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 10 + (9 / 40) + (31 / 200) + (121 / 1000) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (607 / 750) := by norm_num only [distillEBudget] theorem distillFiniteBound_10 : ((607 / 750) : ℝ) < 199 / 200 := by norm_num @@ -728,7 +740,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : apply distillT0_le_of_critical (l := (5 / 2)) (r := (11 / 4)) (d := (11 / 2)) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 4)) : 0 ≤ -distillCritical1 11 x := by @@ -760,7 +772,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : 8 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 2)) : 0 ≤ -distillCritical2 11 x := by @@ -790,7 +802,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : 8 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow11 @@ -799,8 +811,10 @@ theorem distillFinite_11 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : have h0 := CriticalRow11.component0 α hα hd have h1 := CriticalRow11.component1 α hα hd have h2 := CriticalRow11.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 11 + (229 / 1000) + (77 / 500) + (61 / 500) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (5333 / 6600) := by norm_num only [distillEBudget] theorem distillFiniteBound_11 : ((5333 / 6600) : ℝ) < 199 / 200 := by norm_num @@ -844,7 +858,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : apply distillT0_le_of_critical (l := 3) (r := (13 / 4)) (d := 6) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 2)) : 0 ≤ -distillCritical1 12 x := by @@ -876,7 +890,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : 9 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (11 / 4)) : 0 ≤ -distillCritical2 12 x := by @@ -906,7 +920,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : 9 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow12 @@ -915,8 +929,10 @@ theorem distillFinite_12 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : have h0 := CriticalRow12.component0 α hα hd have h1 := CriticalRow12.component1 α hα hd have h2 := CriticalRow12.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 12 + (47 / 200) + (31 / 200) + (1 / 8) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (2929 / 3600) := by norm_num only [distillEBudget] theorem distillFiniteBound_12 : ((2929 / 3600) : ℝ) < 199 / 200 := by norm_num diff --git a/Sendov/DistillationFinite/Rows61_61.lean b/Sendov/DistillationFinite/Rows61_61.lean index 32aca56..7c372a3 100644 --- a/Sendov/DistillationFinite/Rows61_61.lean +++ b/Sendov/DistillationFinite/Rows61_61.lean @@ -30,7 +30,7 @@ theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : 0 ≤ -distillCritical1 61 x := by @@ -54,7 +54,7 @@ theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 58 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : 0 ≤ -distillCritical2 61 x := by @@ -77,7 +77,7 @@ theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : 58 (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] end CriticalRow61 @@ -86,8 +86,10 @@ theorem distillFinite_61 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : have h0 := CriticalRow61.component0 α hα hd have h1 := CriticalRow61.component1 α hα hd have h2 := CriticalRow61.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget 61 + (57 / 250) + (13 / 250) + (81 / 250) := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = (19754 / 22875) := by norm_num only [distillEBudget] theorem distillFiniteBound_61 : ((19754 / 22875) : ℝ) < 199 / 200 := by norm_num diff --git a/Sendov/LargeDegree/DistillationTail.lean b/Sendov/LargeDegree/DistillationTail.lean index bb4cda9..b4fd4e2 100644 --- a/Sendov/LargeDegree/DistillationTail.lean +++ b/Sendov/LargeDegree/DistillationTail.lean @@ -1,13 +1,15 @@ import Sendov.Common.DistillationFactors /-! -# Real-degree monotonicity for the regularized distillation components +# Real-degree monotonicity and bounded growth of distillation components New Lean adaptation of Senjian An, *Proof Distillation for Sendov's Conjecture*, revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, lines 898--950. Paper: CC BY 4.0, https://creativecommons.org/licenses/by/4.0/ . The m=61 reduction uses the actual dependence of the rational denominator on alpha and the stronger decay from `cubicPolarEnvelope 17 <= (21/22)^4`. +The rational component is antitone already from 55; a finite-interval growth +lemma retains exponential decay even when a power component is not antitone. Finite base certificates remain separate. No raw scalar value at alpha zero is identified with a continuous extension. -/ @@ -127,6 +129,72 @@ private lemma kappa_slope_le {K m α : ℝ} (hK : 34 < K) (hm : K ≤ m) div_le_div_of_nonneg_left (by norm_num) (by linarith) (by linarith) linarith only [h1, h2, h3] +/-- On a bounded degree interval, a small positive logarithmic slope consumes +only a linear budget. Unlike an infinite antitone tail, this permits growth. -/ +lemma distillKappa_rpow_interval {K U m α z q ε : ℝ} (n : ℕ) + (hK : 34 < K) (hm : m ∈ Set.Icc K U) (hε : 0 ≤ ε) + (hroom : ε * (U - K) < 1) + (hdecay : 1 / (K - 1) + 2 / (K - 34) ≤ n * (1 - q) / 2 + ε) + (hα : 0 ≤ α) (hα17 : α ≤ 17) (hz : 0 ≤ z) (hq : 0 < q) + (hzq : z ≤ q ^ n) : + (distillKappa m α * z ^ ((m - 3) / 2)) * (1 - ε * (U - K)) ≤ + distillKappa K α * z ^ ((K - 3) / 2) := by + rcases hz.eq_or_lt with rfl | hz + · have hm' : (m - 3) / 2 ≠ 0 := by have := hm.1; linarith + have hK' : (K - 3) / 2 ≠ 0 := by linarith + simp [Real.zero_rpow hm', Real.zero_rpow hK'] + let f := fun t => distillKappa t α * z ^ ((t - 3) / 2) + let w := fun t => 1 - ε * (t - K) + have hf0 (t : ℝ) (ht : K ≤ t) : 0 ≤ f t := + mul_nonneg (distillKappa_nonneg (by linarith) hα) (Real.rpow_nonneg hz.le _) + have hw (t : ℝ) (ht : t ≤ U) : 0 ≤ w t := by + have := mul_le_mul_of_nonneg_left (sub_le_sub_right ht K) hε + dsimp [w] + linarith + have hlog : Real.log z / 2 ≤ -(n * (1 - q) / 2) := by + have hl := Real.log_le_log hz hzq + rw [Real.log_pow] at hl + have hqlog := mul_le_mul_of_nonneg_left (Real.log_le_sub_one_of_pos hq) + (Nat.cast_nonneg n : (0 : ℝ) ≤ n) + linarith + let s := fun t => 1 / (t - 1) + 1 / (t + 1) - 1 / t + + 2 / (t - 2 * α) + Real.log z / 2 + have hs (t : ℝ) (ht : K ≤ t) : s t ≤ ε := by + have := kappa_slope_le hK ht hα17 + dsimp [s] + linarith + have hd (t : ℝ) (ht : K ≤ t) : + HasDerivAt (fun t => f t * w t) (f t * (s t * w t - ε)) t := by + have hp : HasDerivAt (fun t : ℝ => z ^ ((t - 3) / 2)) + (z ^ ((t - 3) / 2) * (Real.log z / 2)) t := by + convert! (hasDerivAt_const t z).rpow + (((hasDerivAt_id' t).sub_const 3).div_const 2) hz using 1 + ring + have hf := slope_mul (kappa_slope (hK.trans_le ht) hα17) hp + have hw' := (((hasDerivAt_id' t).sub_const K).const_mul ε).const_sub 1 + convert! hf.mul hw' using 1 + dsimp [f, w, s] + ring + have hanti : AntitoneOn (fun t => f t * w t) (Set.Icc K U) := by + apply antitoneOn_of_hasDerivWithinAt_nonpos (convex_Icc _ _) + (fun t ht => (hd t ht.1).continuousAt.continuousWithinAt) + (fun t ht => (hd t (interior_subset ht).1).hasDerivWithinAt) + intro t ht + have ht' : t ∈ Set.Icc K U := interior_subset ht + apply mul_nonpos_of_nonneg_of_nonpos (hf0 t ht'.1) + have hsw := mul_le_mul_of_nonneg_right (hs t ht'.1) (hw t ht'.2) + have hprod : 0 ≤ ε * (ε * (t - K)) := by + exact mul_nonneg hε (mul_nonneg hε (sub_nonneg.mpr ht'.1)) + dsimp [w] at * + nlinarith + have hstep := hanti ⟨le_rfl, hm.1.trans hm.2⟩ hm hm.1 + have hweight : 1 - ε * (U - K) ≤ w m := by + dsimp [w] + have := mul_le_mul_of_nonneg_left (sub_le_sub_right hm.2 K) hε + linarith + exact (mul_le_mul_of_nonneg_left hweight (hf0 m hm.1)).trans + (by simpa [w, f] using hstep) + /-- A rational power cap retains stronger logarithmic decay without a log estimate or a derivative sign as a caller premise. Since `K > 34`, the positive left side of `hdecay` already forces `n > 0` and `q < 1`; no extra premises are needed. -/ @@ -205,16 +273,16 @@ private def tailP (m α : ℝ) : ℝ := 7 * m ^ 4 - 30 * α * m ^ 3 - (8 * α ^ 2 + 96 * α + 105) * m ^ 2 + (90 * α - 128 * α ^ 2) * m - 360 * α ^ 2 -private lemma tailP_pos {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (hα12 : α ≤ 12) : +private lemma tailP_pos {m α : ℝ} (hm : 55 ≤ m) (hα : 0 ≤ α) (hα10 : α ≤ 10) : 0 < tailP m α := by have hm0 : 0 ≤ m := by linarith - have hx : 0 ≤ m - 61 := by linarith - have hgap : 0 ≤ 12 - α := by linarith + have hx : 0 ≤ m - 55 := by linarith + have hgap : 0 ≤ 10 - α := by linarith have hid : tailP m α = - 7 * (m - 61) ^ 4 + 1348 * (m - 61) ^ 3 + 87993 * (m - 61) ^ 2 + - 2025538 * (m - 61) + 5133526 + - (12 - α) * (α * (8 * m ^ 2 + 128 * m + 360) + - 30 * m ^ 3 + 192 * m ^ 2 + 1446 * m + 4320) := by + 7 * (m - 55) ^ 4 + 1240 * (m - 55) ^ 3 + 75685 * (m - 55) ^ 2 + + 1718950 * (m - 55) + 7809750 + + (10 - α) * (α * (8 * m ^ 2 + 128 * m + 360) + + 30 * m ^ 3 + 176 * m ^ 2 + 1190 * m + 3600) := by dsimp [tailP] ring rw [hid] @@ -224,38 +292,37 @@ private noncomputable def tailQ (m α d : ℝ) : ℝ := d * tailP m α / 7 + (21 / 25 - d) * (4 * α / 7) * ((3 * m - 2 * α) * m ^ 2 + 32 * (m - α) * m + (75 * m - 90 * α)) -private lemma tailQ_cap_pos {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) - (hα17 : α ≤ 17) : 0 < tailQ m α (2 / 5) := by +private lemma tailQ_cap_pos {m α : ℝ} (hm : 55 ≤ m) (hα : 0 ≤ α) + (hα17 : α ≤ 17) : 0 < tailQ m α (39 / 100) := by have hm0 : 0 ≤ m := by linarith - have hx : 0 ≤ m - 61 := by linarith + have hx : 0 ≤ m - 55 := by linarith have hgap : 0 ≤ 17 - α := by linarith - have hquad : 0 ≤ 24 * m ^ 2 - 64 * m - 600 := by nlinarith - have hid : tailQ m α (2 / 5) = - (2 / 5) * (m - 61) ^ 4 + (2032 / 25) * (m - 61) ^ 3 + - (142598 / 25) * (m - 61) ^ 2 + (3692204 / 25) * (m - 61) + - 17072148 / 25 + - (17 - α) * ((24 / 25) * (α + 17) * (m ^ 2 + 16 * m + 45) + - m * (24 * m ^ 2 - 64 * m - 600) / 25) := by + have hid : tailQ m α (39 / 100) = + (39 / 100) * (m - 55) ^ 4 + (141 / 2) * (m - 55) ^ 3 + + (431967 / 100) * (m - 55) ^ 2 + (4544763 / 50) * (m - 55) + + 160893 / 2 + + (17 - α) * (3 / 50) * (16 * α * m ^ 2 + 256 * α * m + 720 * α + + 15 * m ^ 3 + 224 * m ^ 2 + 3947 * m + 12240) := by dsimp [tailQ, tailP] ring rw [hid] positivity -private lemma tailQ_pos {m α d : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) +private lemma tailQ_pos {m α d : ℝ} (hm : 55 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) (hd : 0 < d) (hd1 : d ≤ 21 / 25) - (hdα : 12 ≤ α → d ≤ 2 / 5) : 0 < tailQ m α d := by + (hdα : 10 ≤ α → d ≤ 39 / 100) : 0 < tailQ m α d := by have hm0 : 0 ≤ m := by linarith have h1 : 0 ≤ 3 * m - 2 * α := by linarith have h2 : 0 ≤ m - α := by linarith have h3 : 0 ≤ 75 * m - 90 * α := by linarith have h4 : 0 ≤ 21 / 25 - d := by linarith - by_cases hα12 : α ≤ 12 + by_cases hα10 : α ≤ 10 · unfold tailQ - exact add_pos_of_pos_of_nonneg (div_pos (mul_pos hd (tailP_pos hm hα hα12)) + exact add_pos_of_pos_of_nonneg (div_pos (mul_pos hd (tailP_pos hm hα hα10)) (by norm_num)) (by positivity) - · have hd2 : 0 ≤ 2 / 5 - d := sub_nonneg.mpr (hdα (by linarith)) - have hid : tailQ m α d = d * (5 / 2 * tailQ m α (2 / 5)) + - (2 / 5 - d) * (6 * α / 5) * + · have hd2 : 0 ≤ 39 / 100 - d := sub_nonneg.mpr (hdα (by linarith)) + have hid : tailQ m α d = d * (100 / 39 * tailQ m α (39 / 100)) + + (39 / 100 - d) * (16 * α / 13) * ((3 * m - 2 * α) * m ^ 2 + 32 * (m - α) * m + (75 * m - 90 * α)) := by dsimp [tailQ, tailP] ring @@ -266,13 +333,13 @@ private lemma tailQ_pos {m α d : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) private noncomputable def tailRational (m α d : ℝ) : ℝ := m ^ 3 * (m - 2 * α) ^ 2 / ((m + 3) * (m + 5) * (d * m - 12 * α / 25) ^ 4) -private lemma tail_den_pos {m α d : ℝ} (hm : 61 ≤ m) (hα17 : α ≤ 17) +private lemma tail_den_pos {m α d : ℝ} (hm : 55 ≤ m) (hα17 : α ≤ 17) (hd : 17 / 50 ≤ d) : 0 < d * m - 12 * α / 25 := by have hm0 : 0 ≤ m := by linarith have hd0 : 0 ≤ d - 17 / 50 := by linarith nlinarith [mul_nonneg hd0 hm0] -private lemma rational_slope {m α d : ℝ} (hm : 61 ≤ m) (hα17 : α ≤ 17) +private lemma rational_slope {m α d : ℝ} (hm : 55 ≤ m) (hα17 : α ≤ 17) (hd : 17 / 50 ≤ d) : HasDerivAt (fun x => tailRational x α d) (tailRational m α d * (3 / m + 2 / (m - 2 * α) - 1 / (m + 3) - @@ -299,9 +366,9 @@ private lemma rational_slope {m α d : ℝ} (hm : 61 ≤ m) (hα17 : α ≤ 17) · dsimp [tailRational] ring -private lemma rational_slope_neg {m α d : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) +private lemma rational_slope_neg {m α d : ℝ} (hm : 55 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) (hd : 17 / 50 ≤ d) (hd1 : d ≤ 21 / 25) - (hdα : 12 ≤ α → d ≤ 2 / 5) : + (hdα : 10 ≤ α → d ≤ 39 / 100) : 3 / m + 2 / (m - 2 * α) - 1 / (m + 3) - 1 / (m + 5) - 4 * d / (d * m - 12 * α / 25) < 0 := by have hm0 : 0 < m := by linarith @@ -324,8 +391,8 @@ private lemma rational_slope_neg {m α d : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (by positivity) private lemma tailRational_antitone {α d : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) - (hd : 17 / 50 ≤ d) (hd1 : d ≤ 21 / 25) (hdα : 12 ≤ α → d ≤ 2 / 5) : - AntitoneOn (fun m => tailRational m α d) (Set.Ici 61) := by + (hd : 17 / 50 ≤ d) (hd1 : d ≤ 21 / 25) (hdα : 10 ≤ α → d ≤ 39 / 100) : + AntitoneOn (fun m => tailRational m α d) (Set.Ici 55) := by apply tail_antitone (fun m hm => rational_slope hm hα17 hd) intro m hm have hm0 : 0 ≤ m := by linarith @@ -334,7 +401,7 @@ private lemma tailRational_antitone {α d : ℝ} (hα : 0 ≤ α) (hα17 : α exact mul_nonpos_of_nonneg_of_nonpos (by unfold tailRational; positivity) (rational_slope_neg hm hα hα17 hd hd1 hdα).le -private lemma distillT0_eq_rational {m α : ℝ} (hm : 61 ≤ m) +private lemma distillT0_eq_rational {m α : ℝ} (hm : 55 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : distillT0 m α = (24 * (3 / 5) ^ 4 * distillRatio α) * tailRational m α (21 / 25 - 3 / 5 * cubicPolarEnvelope α) := by @@ -344,7 +411,7 @@ private lemma distillT0_eq_rational {m α : ℝ} (hm : 61 ≤ m) have hm3 : m + 3 ≠ 0 := by linarith have hm5 : m + 5 ≠ 0 := by linarith have hn : 1 - distillNode m α ≠ 0 := by - have := distillNode_lt_four_fifths hm hα hα17 + have := distillNode_lt_one (by linarith : 0 < m) hα (by linarith : α ≤ m / 2) linarith have hc : (21 / 25 - 3 / 5 * cubicPolarEnvelope α) * m - 12 * α / 25 ≠ 0 := by apply (tail_den_pos hm hα17 _).ne' @@ -361,17 +428,17 @@ private lemma distillT0_eq_rational {m α : ℝ} (hm : 61 ≤ m) ring /-- Real-degree antitonicity of the regularized rational component, including alpha zero. -/ -lemma distillT0_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : - AntitoneOn (fun m => distillT0 m α) (Set.Ici 61) := by +lemma distillT0_antitone_55 {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : + AntitoneOn (fun m => distillT0 m α) (Set.Ici 55) := by have he := cubicPolarEnvelope_nonneg hα have he1 := cubicPolarEnvelope_le_five_sixths hα hα17 have hd : 17 / 50 ≤ 21 / 25 - 3 / 5 * cubicPolarEnvelope α := by linarith have hd1 : 21 / 25 - 3 / 5 * cubicPolarEnvelope α ≤ 21 / 25 := by linarith - have hdα : 12 ≤ α → 21 / 25 - 3 / 5 * cubicPolarEnvelope α ≤ 2 / 5 := by - intro h12 - have he12 := cubicPolarEnvelope_mono (by norm_num : (0 : ℝ) ≤ 12) h12 - have hval : cubicPolarEnvelope 12 = 1468 / 1875 := by norm_num [cubicPolarEnvelope] - rw [hval] at he12 + have hdα : 10 ≤ α → 21 / 25 - 3 / 5 * cubicPolarEnvelope α ≤ 39 / 100 := by + intro h10 + have he10 := cubicPolarEnvelope_mono (by norm_num : (0 : ℝ) ≤ 10) h10 + have hval : cubicPolarEnvelope 10 = 4970 / 6591 := by norm_num [cubicPolarEnvelope] + rw [hval] at he10 linarith intro m hm n hn hmn change distillT0 n α ≤ distillT0 m α @@ -379,6 +446,10 @@ lemma distillT0_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : exact mul_le_mul_of_nonneg_left (tailRational_antitone hα hα17 hd hd1 hdα hm hn hmn) (mul_nonneg (by norm_num) (distillRatio_nonneg hα)) +lemma distillT0_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : + AntitoneOn (fun m => distillT0 m α) (Set.Ici 61) := + (distillT0_antitone_55 hα hα17).mono (Set.Ici_subset_Ici.mpr (by norm_num)) + /-- The earlier pointwise reduction holds on the full closed alpha interval. -/ lemma distillComponents_le_61 {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α ≤ diff --git a/Sendov/LargeDegree/DistillationTailBound.lean b/Sendov/LargeDegree/DistillationTailBound.lean index aa86f91..5f2e6b3 100644 --- a/Sendov/LargeDegree/DistillationTailBound.lean +++ b/Sendov/LargeDegree/DistillationTailBound.lean @@ -1,12 +1,14 @@ import Sendov.Common.DistillationMajorant import Sendov.LargeDegree.DistillationTail +import Sendov.DistillationFinite.Rows53_55 import Sendov.DistillationFinite.Rows61_61 /-! -# The proved infinite tail +# The proved bounded interval and infinite tail The existing critical-point row at `m = 61` supplies the earlier `<199/200` tail, starting at polynomial degree 62. No finite base or monotonicity is assumed. +The original row 55 separately closes the real interval `55 <= m <= 61`. The underlying mathematical route is Senjian An's *Proof Distillation for Sendov's Conjecture*, revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, Sections 7--8 (CC BY 4.0, https://creativecommons.org/licenses/by/4.0/). @@ -14,6 +16,44 @@ Conjecture*, revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, Sections 7--8 namespace Sendov +/-- A real-degree interval, not a finite case split. The original row 55 supplies +the three base budgets internally; bounded growth is allowed for both powers. -/ +theorem distillComponents_interval_55_61 {m α : ℝ} (hm : m ∈ Set.Icc 55 61) + (hα : 0 ≤ α) (h17 : α ≤ 17) : + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := by + have hm5 : 5 ≤ m := by have := hm.1; linarith + have hE := distillEBudget_antitone_on (K := 55) (by norm_num) + (by simp) hm.1 hm.1 + have h0 := (distillT0_antitone_55 hα h17 (by simp) hm.1 hm.1).trans + (CriticalRow55.component0 α hα h17) + have hnode : distillNode 55 α ≤ (979 / 1000) ^ 10 := + (distillNode_mono (by norm_num) hα h17).trans + (by norm_num [distillNode, cubicPolarEnvelope]) + have h1 := distillKappa_rpow_interval (K := 55) (U := 61) + (ε := 331 / 37800) 10 (by norm_num) hm (by norm_num) (by norm_num) + (by norm_num) hα h17 (distillNode_pos (by norm_num) hα).le + (by norm_num : (0 : ℝ) < 979 / 1000) hnode + have hpow := Real.rpow_le_rpow (distillNode_pos (by linarith) hα).le + (distillNode_antitone_degree_on (K := 55) (by norm_num) hα + (by simp) hm.1 hm.1) (by linarith : 0 ≤ (m - 3) / 2) + have h1' := (mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_left hpow (distillKappa_nonneg hm5 hα)) + (by norm_num : (0 : ℝ) ≤ 1 - 331 / 37800 * (61 - 55))).trans h1 + have h1'' : distillT1 m α * (1 - 331 / 37800 * (61 - 55)) ≤ 91 / 1000 := by + apply le_trans _ (CriticalRow55.component1 α hα h17) + simpa only [distillT1, mul_assoc] using + mul_le_mul_of_nonneg_left h1' (by norm_num : (0 : ℝ) ≤ 259 / 3125) + have h2 := distillKappa_rpow_interval (K := 55) (U := 61) + (ε := 95 / 4158) 4 (by norm_num) hm (by norm_num) (by norm_num) + (by norm_num) hα h17 (cubicPolarEnvelope_nonneg hα) + (by norm_num : (0 : ℝ) < 21 / 22) (cubicPolarEnvelope_le_decay_base hα h17) + have h2' : distillT2 m α * (1 - 95 / 4158 * (61 - 55)) ≤ 33 / 100 := by + apply le_trans _ (CriticalRow55.component2 α hα h17) + simpa only [distillT2, mul_assoc] using + mul_le_mul_of_nonneg_left h2 (by norm_num : (0 : ℝ) ≤ 421 / 3125) + norm_num [distillEBudget] at hE ⊢ + linarith + /-- The existing finite row closes the earlier tail on the full closed alpha domain, including zero. No stronger row certificate at m=61 is required. -/ theorem distillComponents_lt_199_200 {m α : ℝ} (hm : 61 ≤ m) diff --git a/data/README.md b/data/README.md index 3b7fd2d..57d8051 100644 --- a/data/README.md +++ b/data/README.md @@ -1,7 +1,7 @@ # Exact mathematical table `paper_certificate_table.json` is the unchanged ordered subset of records -`m = 5,...,61` (57 records) from Senjian An's mathematical certificate table, +`m = 5,...,55` and `m=61` (52 records) from Senjian An's mathematical certificate table, *Proof Distillation for Sendov's Conjecture*, [SJanPerth/Sendov-Proof-Distillation](https://github.com/SJanPerth/Sendov-Proof-Distillation/blob/e8ae601491ec171ab4f7f8456113dd6a047aa85d/verification/paper_certificate_table.json), fixed revision **e8ae601491ec171ab4f7f8456113dd6a047aa85d**. @@ -10,8 +10,10 @@ The mathematical paper/table is attributed under [Creative Commons Attribution 4.0 International](https://creativecommons.org/licenses/by/4.0/); `LICENSE-PAPER.txt` retains the source's notice and legal-code link. No table values, retained row order, component IDs/order or budgets were changed. Records -62 through 81 were removed because the proved real-parameter tail now starts -at 61 and uses the original row-61 budget. This is a selected subset, not a +56 through 60 are covered by the proved real interval `55 ≤ m ≤ 61`, which +uses the original row-55 component budgets. Records 62 through 81 were removed +because the proved real-parameter tail starts at 61 and uses the original row-61 +budget. This is a selected subset, not a verbatim copy of the complete donor table. The project generates its own Lean certificate source; the table itself is not a formal proof. diff --git a/data/paper_certificate_table.json b/data/paper_certificate_table.json index aa0b06c..da526fc 100644 --- a/data/paper_certificate_table.json +++ b/data/paper_certificate_table.json @@ -1886,191 +1886,6 @@ ], "total": "30677/33000" }, - { - "m": 56, - "e": "25/96", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 245, - "sq": "6500950886507080314903330816000000000000000000000000/109077275790632816102301759708160835137523397863154721", - "sign_lo": "615383911344", - "sign_hi": "615383911344" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 83, - "sq": "229475183867012584380320481060051683813147494124867430966928875124106670122273346824528165582632309432148941414187703618348687491902212053318010585317316672007504207435887378717114836257432838413577269984067398281739455087464157579158795033398592529500376068982360898240919314444422147170117071931455757913532032242084491173508354958711030593597195384241/33350587111153081730291536833890673373855342382046560889787200129777585356800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-34898806757040", - "sign_hi": "-34898806757040" - }, - { - "index": 2, - "k": "66", - "lo": "33/2", - "hi": "67/4", - "u": 334, - "sq": "1023809637158695041287391891012858719018755247615852431798056713781171630669057956120432089884497271185856035108066902488605538404317352403117693615105076076040275246507552489185463380790457168032374428414797103953621527051880644835098871887785397527723635714861784976733209059919073682067586484653021970277918678026000086914241651292627101463653201011910057330892654482343668428941721988567/9212479294322018209732352558501960526960320154138321240717742942308235805258569240131702137532541496613307633746676952233651611024686216966732317228236584397665098199588528893216506751340994917128824153629140269684844054905589578631110475293370716416862263226119735620891175168551565346219308617030432777878625082745197397281733000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-3082887/2", - "sign_hi": "3759931/64" - } - ], - "total": "11069/12000" - }, - { - "m": 57, - "e": "89/342", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 241, - "sq": "18933060602415252041535324160000000000000000000000/326397279356000564240138335136244306492159398708241", - "sign_lo": "701379421377", - "sign_hi": "701379421377" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 76, - "sq": "241063939835339153718168664891791782028017978322876566796857900058267549677343941937629910075482283350735735660132959397674227215833971993177606929045022806820204181020762751710335560783797280446018215697558724604104791683810367839683609468747778870758518332686120928313153737314828231063944346473871634624703226115589258691801120227734823591481271176243886913577475411232518418952094010361/41849111184888226294830139378296772977403279401084519786407496761715079260578763865719453777133081460736000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-39405892070544", - "sign_hi": "-39405892070544" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 319, - "sq": "3944321443812641076228995391274653519777841054489922914829180399887307223301883716251449475960649193288006736754786682626911455133610751495434774220095167468433340442897679047173871084190447486168737869770321069879881739167866938071281478031706096376876585402118197818939799419907506317229375872457405545770001/38829277342286595270690095226128505630945697310322132335112807251962899726336000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-389872", - "sign_hi": "-389872" - } - ], - "total": "19157/21375" - }, - { - "m": 58, - "e": "181/696", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 238, - "sq": "187659156390323047152343842816000000000000000000000000/3327549251564828360424785067213737594822366401910034601", - "sign_lo": "787269310384", - "sign_hi": "787269310384" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 70, - "sq": "137726103743815937536065488465333695958681456063438133269784629990671362593988983922457720701625195719460691948176496437847375307646313155689002318150134181471449167291672830848984352667925014974868743726009069308475209852208591618280678715045929588498917947464260734759244325093453966321160599308195260509975694594293033901788185948657660128765124546916872994139572391485354911424106176614945230156335747/28819433961133959862483916253080076114072216217750687427024145596113392597733627912639129825290116138256919062118400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-44095310841776", - "sign_hi": "-44095310841776" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 322, - "sq": "85570290888240194998697911409905619553999470413284614314415689793940334415916433686774123956097978960089886618480581368291795202616046461457391814064117146110280946297027919751560545059212076817957746032641854488420482479940856591422396025431924785800790939552004050566496543133164572371785620996852095076028343/827235787519630012720605899255461274836710287254727653936693934288126607360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-2593352", - "sign_hi": "-2593352" - } - ], - "total": "15487/17400" - }, - { - "m": 59, - "e": "46/177", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 235, - "sq": "15182037537841674495248400000000000000000000000000000000/277125241898152397995822344336074685413819376482210503201", - "sign_lo": "873053578365", - "sign_hi": "873053578365" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 63, - "sq": "1672928870687096755250386949594607029176325671889970390202599125078806937621678065083525197353959216158516132268107115435785065050919351938427230784115353614960964530876968053222919291491011331745402608350979464980738877335776628328753692334743685770282781825978113069832251800023031595804589481017439089610196359641633384306616160069493073453489823066297547275979431275518074571686394203930912224961007592771347158073132721/425496676549827027669106369224484509171017013327583779192091489350976869418236047435221474234661228542785946543605925670878637241250349056000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-48969409884870", - "sign_hi": "-48969409884870" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 324, - "sq": "11401203075690201628893656569962720576046543800614995501835319937037876099826098132313358241133384539903008282649146403716670360981544234204114850300775011093144310759653719927573494491238962706294900399303284256915792011244286674506152018651511671087953725306716912291677650032741820392487907193019841352517907041/109056998766219172483401321108702991818383955421271693105192615210107896784182312960000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-4863630", - "sign_hi": "-4863630" - } - ], - "total": "78047/88500" - }, - { - "m": 60, - "e": "187/720", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 231, - "sq": "114277564107089510400000000000000000000/2148716008870371333169059618290011950721", - "sign_lo": "958732225320", - "sign_hi": "958732225320" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 57, - "sq": "1666550813942302733778014347861012562393367509906353239490025644811063160956733115100187705017804607609437782221347930430010801282199035764613773646467453250387475796416023028314746831282648468825274545361293760183763920657853040893908786004799600085609409710673008534194340634475762798107761715502248279743054184888133780250754740757127/519229685853482762853049632922009600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-54030536013960", - "sign_hi": "-54030536013960" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 324, - "sq": "998469240815300617365331540351445495113194004298528067830471005833440693785712496538941689894195656543157766132798021149707412462006574447358431720545692526992993490572854428143463465919023115463132701763432741458004438456662288006771960766614366520311507759156825300953074054720216330521069882572529599384365637171537211640807/9516249174156585361055200024926323977257720901813064286326416796917631039412633600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-7200706", - "sign_hi": "-7200706" - } - ], - "total": "15691/18000" - }, { "m": 61, "e": "95/366", diff --git a/docs/design.md b/docs/design.md index 6951357..0a29a07 100644 --- a/docs/design.md +++ b/docs/design.md @@ -34,8 +34,8 @@ The two-chord integral theorem gives raw cubic scalar obstruction ≤ E_budget(m) + T0(m,α) + T1(m,α) + T2(m,α). ``` -For `5 ≤ m ≤ 60`, fixed rational budgets and critical brackets are checked for -every integer parameter; the same existing row-61 certificate supplies the tail +For `5 ≤ m ≤ 54`, fixed rational budgets and critical brackets are checked for +every integer parameter; row 55 supplies a bounded real interval and row 61 the tail base. The complete critical expressions are tied to the actual derivatives of `T0`, `T1`, and `T2`. Their polynomial signs are certified on entire outer intervals, while the middle interval uses monotone factors at @@ -51,17 +51,31 @@ For all real `m ≥ 61`, proved parameter antitonicity reduces the four-componen bound to the existing finite `m=61` certificate. `DistillationTailBound` discharges that base with its already-certified `<199/200` budget; no base or monotonicity premise is left to the final caller. The rational component uses the actual -envelope-dependent denominator, with a split at `α=12`, rather than the old +envelope-dependent denominator, with a split at `α=10`, rather than the old independent worst-case bounds that required 81. The exponential components use `η ≤ (21/22)^4`, hence `log η / 2 ≤ 2 log(21/22) ≤ -1/11`. This dominates `1/60 + 2/27`, the kappa slope bound at 61, without assuming a logarithmic estimate or derivative sign. Zero bases are handled separately. +For `55 ≤ m ≤ 61`, the rational component is already antitone. The parameterized +lemma `distillKappa_rpow_interval` bounds finite growth instead of asserting +antitonicity: if the logarithmic slope is at most `ε`, then +`f(m) (1 - ε (U-K)) ≤ f(K)` on `[K,U]`, provided the weight is positive. +It proves this by differentiating `f(m) (1 - ε (m-K))`; no exponential +comparison or derivative fact is left to the final caller. The node cap +`node(55,α) ≤ (979/1000)^10` gives `ε1=331/37800`, while the envelope cap gives +`ε2=95/4158`. Together with the original row-55 budgets `248,91,330` divided by +1000, the exact total is `58135011269/58896123000 < 199/200`. +The theorem covers real degrees and the entire closed alpha interval, without +a finite case split or new Bernstein certificates. The original correlation +`α ≤ min(m/2,17)` remains in the finite interface; for this interval it follows +from `m ≥ 55` and `α ≤ 17`. + The natural-number split `m < 61` versus `61 ≤ m` has no gap. The finite aggregate proves exactly 5 through 60, and both it and the tail import the final group `Rows61_61`; row 61 is emitted only once. The generator and validator share -an explicit 5-through-61 range, paired with the real tail theorem. They reject -missing61, extra62, duplicated/reordered rows and mismatched components rather +an explicit retained range `5..55,61`, paired with both real theorems. They reject +missing55, missing61, reintroduced56, extra62, duplicated/reordered rows and mismatched components rather than inferring a smaller cutoff from truncated data. Rows 62 through 81 and all old row-81-only/two-thirds interfaces have been retired. @@ -91,9 +105,11 @@ Acceptance distinguishes: The earlier-tail consumer test checks actual proof-value edges from both final theorems through the geometric reduction and the tail to row 61. Its recursive -project-value audit requires exactly cases 5 through 60 in the finite aggregate -and all 57 cases, including each of their three components and strict budgets, -in each final theorem. Retired cases and tail interfaces must be absent from +project-value audit requires rows 5 through 54 with their strict budgets and all +three row-55 components in the finite aggregate. Each final theorem additionally +consumes row 61 and its strict budget. The row-55 aggregate budget theorem is not +needed: the interval uses the three individual budgets with different growth weights. +Retired rows 56 through 60, 62 through 81 and tail interfaces must be absent from both the imported environment and the actual value closure. Dependency checks do not equate a module import with proof consumption. diff --git a/docs/getting-started.md b/docs/getting-started.md index 0ea06e1..8f9b39f 100644 --- a/docs/getting-started.md +++ b/docs/getting-started.md @@ -55,8 +55,9 @@ diff -u Sendov/Common/DistillationFinite.lean "$out/generated/Sendov/Common/Dist python3 -m unittest discover -s tests ``` -The output contains all 57 retained records (`m = 5..61`) in eight groups. -The finite aggregate consumes `m = 5..60`; the tail shares row 61 in the final +The output contains all 52 retained records (`m = 5..55,61`) in eight groups. +The finite aggregate covers `m = 5..60` using 50 direct cases and the real +interval 55–61 based on row 55; the tail shares row 61 in the final `Rows61_61` group. Use a fresh output root; generation must not replace a nonempty directory. See [`scripts/GENERATORS.md`](../scripts/GENERATORS.md) for the retained global `sinh` generator and its SymPy dependency. diff --git a/scripts/GENERATORS.md b/scripts/GENERATORS.md index 26f15c8..8cb7151 100644 --- a/scripts/GENERATORS.md +++ b/scripts/GENERATORS.md @@ -12,9 +12,11 @@ python3 -B -m unittest discover -s tests -v ``` The finite output directory must be new or empty. The generator emits all -`m = 5,...,61`, components `0,1,2`, with the unchanged selected table records. -Rows are grouped in batches of eight, ending in `Rows61_61`. The finite -aggregate covers 5–60; the real tail starts at 61 and uses the original row-61 +`m = 5,...,55,61`, components `0,1,2`, with the unchanged selected table records. +Rows are grouped in contiguous batches of at most eight, ending in `Rows53_55` +and `Rows61_61`; a group never spans a gap in retained degrees. The finite +aggregate covers 5–60 using rows 5–54 and the real interval theorem 55–61, +whose base is the original row 55. The real tail starts at 61 and uses the original row-61 `<199/200` budget from that same group. The output contains exactly these eight row modules and `Sendov/Common/DistillationFinite.lean`. No second per-row source tree is published. `bundle_rows.py` is the source-packaging helper, not a @@ -28,7 +30,7 @@ bracket, sign, squared-envelope and budget checks apply. Editing that input changes a proposed certificate, not the proof trust base. Keep the shipped table unchanged to reproduce the selected source. `distillation_data.py` is the explicit range authority, paired with `distillComponents_lt_199_200`; truncated inputs -cannot select a different cutoff. In particular, missing61, extra62, duplicate +cannot select a different cutoff. In particular, missing55, missing61, reintroduced56, extra62, duplicate or reordered rows, and duplicate/reordered/mismatched components are rejected. All data validation and exact row rendering finish before staging. The complete diff --git a/scripts/axioms.lean b/scripts/axioms.lean index b55f893..11d7794 100644 --- a/scripts/axioms.lean +++ b/scripts/axioms.lean @@ -46,3 +46,6 @@ end SendovAudit #sendov_axioms Sendov.distillScalar_lt_199_200 #sendov_axioms Sendov.distillScalar_lt_one #sendov_axioms Sendov.polar_origin_incompatible +#sendov_axioms Sendov.distillKappa_rpow_interval +#sendov_axioms Sendov.distillT0_antitone_55 +#sendov_axioms Sendov.distillComponents_interval_55_61 diff --git a/scripts/bundle_rows.py b/scripts/bundle_rows.py index ab68e4c..4b68081 100644 --- a/scripts/bundle_rows.py +++ b/scripts/bundle_rows.py @@ -26,13 +26,17 @@ def bundle(source, output, size=8): rows_dir = source / 'Sendov/DistillationFinite' expected = {f'Row{m}.lean' for m in ROWS} if {p.name for p in rows_dir.glob('Row*.lean')} != expected: - raise ValueError('rows must be exactly Row5 through Row61') + raise ValueError('rows must be exactly Row5 through Row55, then Row61') rows = {m: split_row((rows_dir / f'Row{m}.lean').read_text()) for m in ROWS} aggregate = (source / 'Sendov/Common/DistillationFinite.lean').read_text() row_imports = [line for line in aggregate.splitlines() if line.startswith(f'import {PREFIX}Row')] if row_imports != [f'import {PREFIX}Row{m}' for m in ROWS]: raise ValueError('aggregate must import each row exactly once in original order') - groups = [list(ROWS[start:start + size]) for start in range(0, len(ROWS), size)] + groups = [] + for m in ROWS: + if not groups or len(groups[-1]) == size or m != groups[-1][-1] + 1: + groups.append([]) + groups[-1].append(m) rendered, manifest = {}, [] for group in groups: name = f'Rows{group[0]}_{group[-1]}' diff --git a/scripts/distillation_data.py b/scripts/distillation_data.py index 0e6c332..2a54a27 100644 --- a/scripts/distillation_data.py +++ b/scripts/distillation_data.py @@ -10,11 +10,12 @@ import json from pathlib import Path -# Paired with distillComponents_lt_199_200: real m >= 61 uses the row-61 base. +# Paired with the proved interval 55 <= m <= 61 and the real tail m >= 61. # Never derive an allowed lower tail threshold from the supplied table. TAIL_START = 61 -ROWS = tuple(range(5, TAIL_START + 1)) -FINITE_ROWS = ROWS[:-1] +INTERVAL_START = 55 +ROWS = (*range(5, INTERVAL_START + 1), TAIL_START) +FINITE_ROWS = tuple(range(5, TAIL_START)) def require(condition, message): @@ -71,11 +72,11 @@ def candidate_squared(m, j, lo, hi): def load_table(path, coefficients): rows = json.loads(Path(path).read_text(encoding='utf-8'), object_pairs_hook=object_pairs, parse_constant=reject_constant) - require(type(rows) is list and len(rows) == len(ROWS), 'exactly 57 rows required') + require(type(rows) is list and len(rows) == len(ROWS), 'exactly 52 rows required') for m, row in zip(ROWS, rows): fields(row, 'm e components total', f'row {m}') require(type(row['m']) is int and row['m'] == m, - 'rows must be m=5..61 exactly once in order') + 'rows must be m=5..55,61 exactly once in order') e = rational(row['e']) require(e == F(1, 4) + F(7, 12*m), f'E budget mismatch at {m}') parts = row['components'] diff --git a/scripts/gen_distillation.py b/scripts/gen_distillation.py index 277f11a..ba48581 100644 --- a/scripts/gen_distillation.py +++ b/scripts/gen_distillation.py @@ -13,7 +13,7 @@ import os import tempfile from bundle_rows import bundle -from distillation_data import FINITE_ROWS, ROWS, load_table +from distillation_data import FINITE_ROWS, INTERVAL_START, ROWS, load_table from fractions import Fraction as F from math import comb, gcd, lcm from pathlib import Path @@ -125,16 +125,19 @@ def row_source(row): s+=f' {m-3} (by norm_num) (by norm_num)\n' s+=' (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num)\n' s+=f' sign_{j}_left sign_{j}_right ?_ ⟨hα, hd⟩\n' - s+=' norm_num [distillKappa, distillRatio, distillNode, cubicPolarEnvelope]\n\n' + s+=' norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope]\n\n' s+=f'end CriticalRow{m}\n\n' total=rat(row['total']) + budgets=[rat(F(c['u'],1000)) for c in row['components']] s+=f'''theorem distillFinite_{m} (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ {rat(d)}) : distillEBudget {m} + distillT0 {m} α + distillT1 {m} α + distillT2 {m} α ≤ {total} := by have h0 := CriticalRow{m}.component0 α hα hd have h1 := CriticalRow{m}.component1 α hα hd have h2 := CriticalRow{m}.component2 α hα hd - norm_num [distillEBudget] at * - linarith + calc + _ ≤ distillEBudget {m} + {budgets[0]} + {budgets[1]} + {budgets[2]} := + add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 + _ = {total} := by norm_num only [distillEBudget] theorem distillFiniteBound_{m} : ({total} : ℝ) < 199 / 200 := by norm_num @@ -144,6 +147,7 @@ def row_source(row): def aggregate_source(): s=''.join(f'import Sendov.DistillationFinite.Row{m}\n' for m in ROWS) + s+='import Sendov.LargeDegree.DistillationTailBound\n' s+=f''' /-! Exact finite-domain critical-bracket closure. Fixed original paper budgets; see DistillationCriticalFinite for attribution. No sampled truth or global T grid. -/ @@ -152,9 +156,13 @@ def aggregate_source(): theorem distillFinite_components {{m : ℕ}} (hm : 5 ≤ m) (hm60 : m ≤ {FINITE_ROWS[-1]}) {{α : ℝ}} (hα : 0 ≤ α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := by + by_cases hinterval : {INTERVAL_START} ≤ m + · exact distillComponents_interval_55_61 + ⟨by exact_mod_cast hinterval, by exact_mod_cast (show m ≤ 61 by omega)⟩ hα h17 + have hm54 : m ≤ {INTERVAL_START - 1} := by omega interval_cases m ''' - for m in FINITE_ROWS: + for m in range(5, INTERVAL_START): bound = 'h17' if F(m, 2) >= 17 else '(by linarith)' s+=f' · exact (distillFinite_{m} α hα {bound}).trans_lt distillFiniteBound_{m}\n' s+=f''' diff --git a/tests/BoundaryConsumer.lean b/tests/BoundaryConsumer.lean index f81bf4e..678284b 100644 --- a/tests/BoundaryConsumer.lean +++ b/tests/BoundaryConsumer.lean @@ -36,6 +36,21 @@ theorem closed_tail {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (h17 : α ≤ Sendov.distillT1 m α + Sendov.distillT2 m α < 199 / 200 := Sendov.distillComponents_lt_199_200 hm hα h17 +theorem closed_interval {m α : ℝ} (hm : m ∈ Set.Icc 55 61) + (hα : 0 ≤ α) (h17 : α ≤ 17) : + Sendov.distillEBudget m + Sendov.distillT0 m α + + Sendov.distillT1 m α + Sendov.distillT2 m α < 199 / 200 := + Sendov.distillComponents_interval_55_61 hm hα h17 + +theorem interval_boundary : + Sendov.scalarObstruction 55 0 (Sendov.cubicPolarEnvelope 0) = 1 / 110 ∧ + Sendov.distillEBudget 55 + Sendov.distillT0 55 0 + + Sendov.distillT1 55 0 + Sendov.distillT2 55 0 < 199 / 200 := by + constructor + · convert raw_zero 55 using 1 + norm_num + · exact closed_interval (by norm_num) le_rfl (by norm_num) + end MathPolishBoundary open Lean Elab Command in @@ -44,7 +59,8 @@ run_cmd do for (consumer, target) in #[ (`MathPolishBoundary.raw_zero, `Sendov.scalarObstruction_zero), (`MathPolishBoundary.tail_zero, `Sendov.distillT2_zero), - (`MathPolishBoundary.closed_tail, `Sendov.distillComponents_lt_199_200)] do + (`MathPolishBoundary.closed_tail, `Sendov.distillComponents_lt_199_200), + (`MathPolishBoundary.closed_interval, `Sendov.distillComponents_interval_55_61)] do let some info := env.find? consumer | throwError "missing consumer {consumer}" let some value := info.value? (allowOpaque := true) | throwError "missing proof value" unless value.getUsedConstants.contains target do diff --git a/tests/EarlierTail.lean b/tests/EarlierTail.lean index ae0db3e..8d0ac98 100644 --- a/tests/EarlierTail.lean +++ b/tests/EarlierTail.lean @@ -73,6 +73,11 @@ open Lean Elab Command in run_cmd do let env := (← getEnv).setExporting false for (consumer, targets) in #[ + (`Sendov.distillFinite_components, #[`Sendov.distillComponents_interval_55_61]), + (`Sendov.distillComponents_interval_55_61, + #[`Sendov.distillKappa_rpow_interval, `Sendov.distillT0_antitone_55, + `Sendov.CriticalRow55.component0, `Sendov.CriticalRow55.component1, + `Sendov.CriticalRow55.component2]), (`Sendov.distillComponents_lt_199_200, #[`Sendov.distillComponents_le_61, `Sendov.distillFinite_61, `Sendov.distillFiniteBound_61]), @@ -93,7 +98,8 @@ run_cmd do unless value.getUsedConstants.contains target do throwError "not an actual proof consumer: {consumer} -> {target}" logInfo m!"EARLIER_TAIL_CONSUMER {consumer} -> {target}" - for target in #[`Sendov.distillComponents_lt_199_200, `Sendov.distillScalar_lt_199_200, + for target in #[`Sendov.distillComponents_interval_55_61, + `Sendov.distillComponents_lt_199_200, `Sendov.distillScalar_lt_199_200, `Sendov.distillScalar_lt_one, `SendovConjecture.sendov, `SendovConjecture.phelps_rodriguez] do let axioms ← withEnv env <| Lean.collectAxioms target @@ -133,19 +139,19 @@ run_cmd do for m in [5:82] do for stem in ["distillFinite_", "distillFiniteBound_"] do let name := Name.str `Sendov s!"{stem}{m}" - unless visited.contains name == (m ≤ upper) do + unless visited.contains name == (m ≤ 54 || (m == 61 && upper == 61)) do throwError "wrong actual case closure: {root}, {name}" - if 62 ≤ m && env.contains name then + if (56 ≤ m && m ≤ 60 || 62 ≤ m) && env.contains name then throwError "retired case still imported: {name}" for j in [0:3] do let name := Name.str (Name.str `Sendov s!"CriticalRow{m}") s!"component{j}" - unless visited.contains name == (m ≤ upper) do + unless visited.contains name == (m ≤ 55 || (m == 61 && upper == 61)) do throwError "wrong actual component closure: {root}, {name}" - if 62 ≤ m && env.contains name then + if (56 ≤ m && m ≤ 60 || 62 ≤ m) && env.contains name then throwError "retired component still imported: {name}" for name in visited do let text := name.toString if retired.contains name || (text.splitOn "two_thirds").length > 1 || (text.splitOn "_le_81").length > 1 then throwError "retired tail in actual value closure: {root}, {name}" - logInfo m!"K61_VALUE_CLOSURE {root}: 5..{upper}, three components, no retired names" + logInfo m!"INTERVAL_VALUE_CLOSURE {root}: cases5..54, base55, tail61 iff final; no retired rows" diff --git a/tests/Localbudgets.lean b/tests/Localbudgets.lean new file mode 100644 index 0000000..af24417 --- /dev/null +++ b/tests/Localbudgets.lean @@ -0,0 +1,154 @@ +import Sendov.Common.DistillationFinite +import Sendov.LargeDegree.DistillationTailBound + +namespace Localbudgets + +open Sendov + +-- The m=60 formulas below are regression examples, not retained row consumers. +-- Raw central obligations cover the zero flank, internal brackets and the +-- point bracket at 17, with both integer and half-integer real exponents. +example : + distillKappa 5 (1 / 2) * (96 * (3 / 5) ^ 4 / + ((5 - 1) * (5 + 1) * (5 + 3) * (5 + 5) * (1 - distillNode 5 (3 / 4)) ^ 4)) ≤ + 101 / 500 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +example : + ((259 / 3125) * distillKappa 5 0) ^ 2 * (distillNode 5 (1 / 4)) ^ 2 ≤ + (191 / 1000 : ℝ) ^ 2 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +example : + ((421 / 3125) * distillKappa 5 (1 / 2)) ^ 2 * (cubicPolarEnvelope (3 / 4)) ^ 2 ≤ + (37 / 250 : ℝ) ^ 2 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +example : + ((259 / 3125) * distillKappa 6 (1 / 2)) ^ 2 * (distillNode 6 (3 / 4)) ^ 3 ≤ + (171 / 1000 : ℝ) ^ 2 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +example : + ((421 / 3125) * distillKappa 6 (3 / 4)) ^ 2 * (cubicPolarEnvelope 1) ^ 3 ≤ + (133 / 1000 : ℝ) ^ 2 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +example : + distillKappa 61 17 * (96 * (3 / 5) ^ 4 / + ((61 - 1) * (61 + 1) * (61 + 3) * (61 + 5) * (1 - distillNode 61 17) ^ 4)) ≤ + 57 / 250 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +example : + ((259 / 3125) * distillKappa 60 17) ^ 2 * (distillNode 60 17) ^ 57 ≤ + (57 / 1000 : ℝ) ^ 2 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +example : + ((421 / 3125) * distillKappa 60 17) ^ 2 * (cubicPolarEnvelope 17) ^ 57 ≤ + (81 / 250 : ℝ) ^ 2 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +example : + ((259 / 3125) * distillKappa 61 17) ^ 2 * (distillNode 61 17) ^ 58 ≤ + (13 / 250 : ℝ) ^ 2 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +example : + ((421 / 3125) * distillKappa 61 17) ^ 2 * (cubicPolarEnvelope 17) ^ 58 ≤ + (81 / 250 : ℝ) ^ 2 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +-- These closed numerical negations require no assumed sign identity or bound. +-- Each also checks that the emitted arithmetic tactic rejects the false goal. +theorem wrong_unsquared_budget : ¬ ( + distillKappa 5 (1 / 2) * (96 * (3 / 5) ^ 4 / + ((5 - 1) * (5 + 1) * (5 + 3) * (5 + 5) * (1 - distillNode 5 (3 / 4)) ^ 4)) ≤ + 201 / 1000) := by + fail_if_success + have h : + distillKappa 5 (1 / 2) * (96 * (3 / 5) ^ 4 / + ((5 - 1) * (5 + 1) * (5 + 3) * (5 + 5) * + (1 - distillNode 5 (3 / 4)) ^ 4)) ≤ 201 / 1000 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +theorem wrong_zero_flank_budget : ¬ ( + ((259 / 3125) * distillKappa 5 0) ^ 2 * (distillNode 5 (1 / 4)) ^ 2 ≤ + (19 / 100 : ℝ) ^ 2) := by + fail_if_success + have h : + ((259 / 3125) * distillKappa 5 0) ^ 2 * (distillNode 5 (1 / 4)) ^ 2 ≤ + (19 / 100 : ℝ) ^ 2 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +theorem wrong_scale : ¬ ( + ((518 / 3125) * distillKappa 6 (1 / 2)) ^ 2 * (distillNode 6 (3 / 4)) ^ 3 ≤ + (171 / 1000 : ℝ) ^ 2) := by + fail_if_success + have h : + ((518 / 3125) * distillKappa 6 (1 / 2)) ^ 2 * (distillNode 6 (3 / 4)) ^ 3 ≤ + (171 / 1000 : ℝ) ^ 2 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +theorem wrong_internal_exponent : ¬ ( + ((259 / 3125) * distillKappa 6 (1 / 2)) ^ 2 * (distillNode 6 (3 / 4)) ^ 2 ≤ + (171 / 1000 : ℝ) ^ 2) := by + fail_if_success + have h : + ((259 / 3125) * distillKappa 6 (1 / 2)) ^ 2 * (distillNode 6 (3 / 4)) ^ 2 ≤ + (171 / 1000 : ℝ) ^ 2 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +theorem wrong_endpoint_exponent : ¬ ( + ((421 / 3125) * distillKappa 60 17) ^ 2 * (cubicPolarEnvelope 17) ^ 56 ≤ + (81 / 250 : ℝ) ^ 2) := by + fail_if_success + have h : + ((421 / 3125) * distillKappa 60 17) ^ 2 * (cubicPolarEnvelope 17) ^ 56 ≤ + (81 / 250 : ℝ) ^ 2 := by + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] + +theorem wrong_row_total : + ¬ (distillEBudget 5 + 101 / 500 + 191 / 1000 + 37 / 250 ≤ 272 / 300) := by + norm_num only [distillEBudget] + +theorem wrong_rpow_exponent : ¬ (((6 : ℝ) - 3) / 2 = (2 : ℝ) / 2) := by norm_num + +example (n : ℕ) : ((0 : ℝ) ^ ((n : ℝ) / 2)) ^ 2 = (0 : ℝ) ^ n := + distillRpow_half_sq le_rfl n + +example : (2 : ℝ) * (1 / 4 : ℝ) ^ (((6 : ℝ) - 3) / 2) ≤ 1 / 4 := by + exact distillMulRpow_le_of_sq 3 (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +example : (2 : ℝ) * (0 : ℝ) ^ (((6 : ℝ) - 3) / 2) ≤ 0 := by + exact distillMulRpow_le_of_sq 3 le_rfl le_rfl (by norm_num) (by norm_num) + +example : distillT1 5 0 ≤ 191 / 1000 := + CriticalRow5.component1 0 le_rfl (by norm_num) + +example (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : + distillT0 61 α ≤ 57 / 250 ∧ distillT1 61 α ≤ 13 / 250 ∧ + distillT2 61 α ≤ 81 / 250 := + ⟨CriticalRow61.component0 α hα hd, CriticalRow61.component1 α hα hd, + CriticalRow61.component2 α hα hd⟩ + +example : distillEBudget 61 + distillT0 61 17 + distillT1 61 17 + distillT2 61 17 < + 199 / 200 := + (distillFinite_61 17 (by norm_num) le_rfl).trans_lt distillFiniteBound_61 + +example {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) {α : ℝ} (hα : 0 ≤ α) + (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := + distillFinite_components hm hm60 hα hαm h17 + +example {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (h17 : α ≤ 17) : + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := + distillComponents_lt_199_200 hm hα h17 + +end Localbudgets diff --git a/tests/Localranges.lean b/tests/Localranges.lean new file mode 100644 index 0000000..3ec7306 --- /dev/null +++ b/tests/Localranges.lean @@ -0,0 +1,54 @@ +import Sendov.Common.DistillationBounds + +open Sendov + +example {m : ℝ} (hm : m ∈ Set.Icc 55 61) : + distillEBudget m + distillT0 m 0 + distillT1 m 0 + distillT2 m 0 < 199 / 200 := + distillComponents_interval_55_61 hm le_rfl (by norm_num) + +example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : + distillEBudget 55 + distillT0 55 α + distillT1 55 α + distillT2 55 α < 199 / 200 := + distillComponents_interval_55_61 (by norm_num) hα h17 + +example : + distillEBudget (111 / 2) + distillT0 (111 / 2) 17 + + distillT1 (111 / 2) 17 + distillT2 (111 / 2) 17 < 199 / 200 := + distillComponents_interval_55_61 (by norm_num) (by norm_num) le_rfl + +example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : + distillEBudget 61 + distillT0 61 α + distillT1 61 α + distillT2 61 α < 199 / 200 := + distillComponents_interval_55_61 (by norm_num) hα h17 + +example {m : ℕ} (hm : 56 ≤ m) (h60 : m ≤ 60) {α : ℝ} + (hα : 0 ≤ α) (h17 : α ≤ 17) : + distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := by + exact distillFinite_components (by omega) h60 hα + (by + have hmR : (56 : ℝ) ≤ m := by exact_mod_cast hm + linarith) h17 + +example {n : ℕ} (hn : 6 ≤ n) {α : ℝ} (hα : 0 < α) (h17 : α ≤ 17) + (hhalf : 2 * α ≤ M n) : + scalarObstruction (M n) α (cubicPolarEnvelope α) < 1 := + distillScalar_lt_one hn hα h17 hhalf + +example : scalarObstruction 5 (5 / 2) (cubicPolarEnvelope (5 / 2)) < 199 / 200 := by + exact distillFinite_scalar (m := 5) (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) + +example {m : ℝ} (hm : m ∈ Set.Icc 55 61) : + (distillKappa m 0 * (0 : ℝ) ^ ((m - 3) / 2)) * + (1 - 95 / 4158 * (61 - 55)) ≤ + distillKappa 55 0 * (0 : ℝ) ^ (((55 : ℝ) - 3) / 2) := + distillKappa_rpow_interval (ε := 95 / 4158) 4 (by norm_num) hm (by norm_num) (by norm_num) + (by norm_num) le_rfl (by norm_num) le_rfl + (by norm_num : (0 : ℝ) < 21 / 22) (by norm_num) + +example : ¬ (54 : ℝ) ∈ Set.Icc 55 61 := by norm_num +example : ¬ (123 / 2 : ℝ) ∈ Set.Icc 55 61 := by norm_num +example : ¬ (18 : ℝ) ≤ 17 := by norm_num + +example : (1 / 54 + 2 / 21 : ℝ) > 1 / 11 := by norm_num +example : (43 / 165 + 31 / 125 + + (91 / 1000) / (1 - 331 / 37800 * 7) + + (33 / 100) / (1 - 95 / 4158 * 7) : ℝ) > 199 / 200 := by norm_num diff --git a/tests/expected.json b/tests/expected.json index 607b8a3..d56ff96 100644 --- a/tests/expected.json +++ b/tests/expected.json @@ -1,16 +1,16 @@ { "distillation": { - "Sendov/Common/DistillationFinite.lean": "08ecbb1e3d2d571718579467ac752a4a4b944973c02a1fa355eec785360e0ab6", - "Sendov/DistillationFinite/Rows13_20.lean": "d4797d14dc0932db445dd421d8117b84b3748ea98160b105fa296af07a7de0b7", - "Sendov/DistillationFinite/Rows21_28.lean": "c8eae11289b2d45e244ee083da84418babdc395af0ee05454cc711b085e1d318", - "Sendov/DistillationFinite/Rows29_36.lean": "60ef832981cf7f3c6056d079e0abcfc663a3a4f53523b690f3cf21f82132517b", - "Sendov/DistillationFinite/Rows37_44.lean": "cacca609ff5a960d97220629eea75c087c2f7971395d0280b1a770ad1eeffa84", - "Sendov/DistillationFinite/Rows45_52.lean": "21ef52d413d69addc9916ebab6830f75c18a213e82d91ba32b702a0874383c25", - "Sendov/DistillationFinite/Rows53_60.lean": "4e09662cc6311402ac606523821bb139f89fb877a782c438484136e824744217", - "Sendov/DistillationFinite/Rows5_12.lean": "6c2058e9eb2c6b9f73daa869e699640492cfd8f1df5412ebf1fe467bdecdbfc5", - "Sendov/DistillationFinite/Rows61_61.lean": "12914a847c6360f43e32fe9ecdfbc2ca5a098388cef6f41a973cf34dca8bc08d" + "Sendov/Common/DistillationFinite.lean": "51879329cdb23b7dc2e4d94d94eb5f974c17bff183ab56addb2fdebeae463fb7", + "Sendov/DistillationFinite/Rows13_20.lean": "7211b2822f8f262eae422406ce57c48c8f9e566a0961fcdc3fad2812e7fedad4", + "Sendov/DistillationFinite/Rows21_28.lean": "16cc1f9657beb98a7bdb2b46a423d4b66e97ab154899335b0e8680873c36a00e", + "Sendov/DistillationFinite/Rows29_36.lean": "339320274f3012e878e90f27338a8e1a9bee8240368ab2281d12b7afc11c4fde", + "Sendov/DistillationFinite/Rows37_44.lean": "653824c8891543bf6a684048e9a9672accc87c19bc52f55e8dbfa9b9d8579114", + "Sendov/DistillationFinite/Rows45_52.lean": "c41366a1bc680c09367945b56eb00f791620c583f1c9c827d0ddd1dfdd33b0f2", + "Sendov/DistillationFinite/Rows53_55.lean": "428b635c53f831d4ec2e7a875d58523846302ca89f3eefeaccae87ee28ed6a59", + "Sendov/DistillationFinite/Rows5_12.lean": "7c70b26f98e65cffed59178b9ac6d91c683e10a47ec9369f58df4b25d15c7602", + "Sendov/DistillationFinite/Rows61_61.lean": "3a2916ff4e15b4cf31fb4e87d16b611d499f3a8ce1399a0ddb0195406b3f9f2c" }, - "table_sha256": "e29363bce9ae130a080e1b02ccbbfddbb5e63a31a769900ab08d389c519cd528", + "table_sha256": "d20fef86d64459e54c2e335d9a425451b2f87822acbf6a5dd09ce2d633731183", "sinh": { "sha256": "d04df2219415aa8e4f838c9c1b246b35af087e4ba41d4c449f95fe0f436c4acb", "bytes": 15024 diff --git a/tests/test_axiom_audit.py b/tests/test_axiom_audit.py index e73cc1b..6ad1762 100644 --- a/tests/test_axiom_audit.py +++ b/tests/test_axiom_audit.py @@ -26,15 +26,18 @@ 'Sendov.distillScalar_lt_199_200', 'Sendov.distillScalar_lt_one', 'Sendov.polar_origin_incompatible', + 'Sendov.distillKappa_rpow_interval', + 'Sendov.distillT0_antitone_55', + 'Sendov.distillComponents_interval_55_61', ] MODULES = { 'Sendov.DistillationFinite.Rows61_61': TARGETS[4:6], 'Sendov.Common.DistillationFinite': TARGETS[2:4], - 'Sendov.LargeDegree.DistillationTail': TARGETS[6:8], - 'Sendov.LargeDegree.DistillationTailBound': TARGETS[8:10], + 'Sendov.LargeDegree.DistillationTail': TARGETS[6:8] + TARGETS[12:14], + 'Sendov.LargeDegree.DistillationTailBound': TARGETS[8:10] + TARGETS[14:15], 'Sendov.Common.DistillationBounds': TARGETS[10:11], - 'Sendov.Reduction.Main': TARGETS[11:], + 'Sendov.Reduction.Main': TARGETS[11:12], 'Solution': TARGETS[:2], } diff --git a/tests/test_bundle_rows.py b/tests/test_bundle_rows.py index b271c5d..92d84db 100644 --- a/tests/test_bundle_rows.py +++ b/tests/test_bundle_rows.py @@ -16,19 +16,20 @@ def fixture(self, root): rows = source / 'Sendov/DistillationFinite' rows.mkdir(parents=True) (source / 'Sendov/Common').mkdir() - for m in range(5, 62): + for m in [*range(5, 56), 61]: (rows / f'Row{m}.lean').write_text( 'import Mathlib.Data.Nat.Basic\n\n' f'namespace FixtureRow{m}\ntheorem value : (1 : Nat) = 1 := rfl\nend FixtureRow{m}\n') (source / 'Sendov/Common/DistillationFinite.lean').write_text(''.join( - f'import Sendov.DistillationFinite.Row{m}\n' for m in range(5, 62)) + '\n-- aggregate body\n') + f'import Sendov.DistillationFinite.Row{m}\n' for m in [*range(5, 56), 61]) + + '\n-- aggregate body\n') return source def test_all_rows_once_in_original_order_and_bodies_preserved(self): with tempfile.TemporaryDirectory() as temporary: root = Path(temporary); source = self.fixture(root) result = bundle_rows.bundle(source, root / 'out', size=8) - self.assertEqual([m for group in result['groups'] for m in group['rows']], list(range(5, 62))) + self.assertEqual([m for group in result['groups'] for m in group['rows']], [*range(5, 56), 61]) for group in result['groups']: text = (root / 'out' / group['path']).read_text() for m in group['rows']: @@ -36,6 +37,7 @@ def test_all_rows_once_in_original_order_and_bodies_preserved(self): body = ''.join(x for x in original.splitlines(keepends=True) if not x.startswith('import ')) self.assertIn(body, text) self.assertEqual(result['groups'][-1]['module'], 'Sendov.DistillationFinite.Rows61_61') + self.assertEqual(result['groups'][-2]['module'], 'Sendov.DistillationFinite.Rows53_55') self.assertFalse((root / 'out/Sendov/DistillationFinite/Row61.lean').exists()) self.assertFalse((root / 'out/Sendov/DistillationFinite/Row46.lean').exists()) aggregate = (root / 'out/Sendov/Common/DistillationFinite.lean').read_text() @@ -59,6 +61,15 @@ def test_extra_row62_fails_before_output(self): bundle_rows.bundle(source, root / 'out') self.assertFalse((root / 'out').exists()) + def test_retired_row56_fails_before_output(self): + with tempfile.TemporaryDirectory() as temporary: + root = Path(temporary); source = self.fixture(root) + (source / 'Sendov/DistillationFinite/Row56.lean').write_text( + 'import Mathlib.Data.Nat.Basic\n') + with self.assertRaisesRegex(ValueError, 'rows'): + bundle_rows.bundle(source, root / 'out') + self.assertFalse((root / 'out').exists()) + def test_duplicate_or_omitted_aggregate_import_is_not_repaired(self): with tempfile.TemporaryDirectory() as temporary: root = Path(temporary); source = self.fixture(root) diff --git a/tests/test_generator_core.py b/tests/test_generator_core.py index 0ad54d8..223e595 100644 --- a/tests/test_generator_core.py +++ b/tests/test_generator_core.py @@ -15,15 +15,17 @@ class ExactCoreTests(unittest.TestCase): - def test_k61_exact_allowed_domain_and_components(self): + def test_interval_and_tail_exact_base_domain_and_components(self): selected = [r for r in json.loads(g.TABLE.read_text()) if 5 <= r['m'] <= 61] - self.assertEqual([r['m'] for r in selected], list(range(5, 62))) + self.assertEqual([r['m'] for r in selected], [*range(5, 56), 61]) with tempfile.TemporaryDirectory() as temporary: table = Path(temporary) / 'table.json' table.write_text(json.dumps(selected)) self.assertEqual(load_table(table, g.coefficients), selected) mutations = { 'missing61': lambda r: r.pop(), + 'missing55': lambda r: r.pop(-2), + 'retired56': lambda r: r.__setitem__(-2, dict(r[-2], m=56)), 'extra62': lambda r: r.append(dict(r[-1], m=62)), 'duplicate': lambda r: r.__setitem__(1, r[0]), 'reordered': lambda r: r.reverse(), @@ -41,11 +43,12 @@ def test_k61_exact_allowed_domain_and_components(self): with self.assertRaises(ValueError): load_table(table, g.coefficients) - def test_k61_generator_covers_56_finite_cases_and_one_shared_base(self): + def test_generator_covers_50_cases_six_degree_interval_and_tail(self): with tempfile.TemporaryDirectory() as temporary: output = Path(temporary) / 'output' result = g.generate(output) - self.assertEqual(result['rows'], list(range(5, 62))) + self.assertEqual(result['rows'], [*range(5, 56), 61]) + self.assertEqual(result['groups'][-2]['rows'], [53, 54, 55]) self.assertEqual(result['groups'][-1]['rows'], [61]) self.assertEqual(len(result['groups']), 8) self.assertTrue((output / 'Sendov/DistillationFinite/Rows61_61.lean').is_file()) @@ -54,10 +57,12 @@ def test_k61_generator_covers_56_finite_cases_and_one_shared_base(self): cases = [f' · exact (distillFinite_{m} α hα (by linarith)).trans_lt ' f'distillFiniteBound_{m}' for m in range(5, 34)] cases += [f' · exact (distillFinite_{m} α hα h17).trans_lt ' - f'distillFiniteBound_{m}' for m in range(34, 61)] + f'distillFiniteBound_{m}' for m in range(34, 55)] self.assertEqual([line for line in aggregate.splitlines() if line.startswith(' · exact (distillFinite_')], cases) self.assertIn('(hm60 : m ≤ 60)', aggregate) + self.assertIn('by_cases hinterval : 55 ≤ m', aggregate) + self.assertIn('exact distillComponents_interval_55_61', aggregate) for path in output.rglob('*.lean'): self.assertNotIn('two_thirds', path.read_text()) self.assertNotIn('distillFiniteTailBase', path.read_text()) @@ -103,7 +108,30 @@ def test_every_flank_keeps_the_complete_original_identity(self): self.assertEqual(text.count(' ring1\n'), 1) self.assertNotIn('norm_num only', text) self.assertNotIn('bernstein_ring', text) - self.assertEqual((identities, empty), (307, 35)) + self.assertEqual((identities, empty), (291, 21)) + + def test_interval_growth_budget_is_exact_and_has_strict_slack(self): + # Independent numerical contract, not values read from generated Lean. + row = next(r for r in json.loads(g.TABLE.read_text()) if r['m'] == 55) + self.assertEqual([c['u'] for c in row['components']], [248, 91, 330]) + slope = F(1, 54) + F(2, 21) + self.assertEqual(slope - 5 * (1 - F(979, 1000)), F(331, 37800)) + self.assertEqual(slope - F(1, 11), F(95, 4158)) + u = F(17, 20) + eta = u - u**3 / 30 + node = F(4, 25) + F(3, 5)*eta + F(204, 1375) + self.assertLessEqual(node, F(979, 1000)**10) + self.assertLessEqual(eta, F(21, 22)**4) + w1, w2 = 1 - F(331, 37800)*6, 1 - F(95, 4158)*6 + self.assertGreater(min(w1, w2), 0) + total = F(43, 165) + F(31, 125) + F(91, 1000)/w1 + F(33, 100)/w2 + self.assertEqual(total, F(58135011269, 58896123000)) + self.assertLess(total, F(199, 200)) + # Removing growth or extending the same interval to 62 is not licensed. + self.assertGreater(slope, F(1, 11)) + wider = F(43, 165) + F(31, 125) + F(91, 1000)/(1-F(331,37800)*7) + ( + F(33,100)/(1-F(95,4158)*7)) + self.assertGreater(wider, F(199, 200)) def test_empty_polynomial_and_bad_interval_are_rejected(self): with self.assertRaisesRegex(ValueError, 'empty'): @@ -113,6 +141,42 @@ def test_empty_polynomial_and_bad_interval_are_rejected(self): with self.assertRaisesRegex(ValueError, 'component'): g.coefficients(5, 3) + def test_all_central_budgets_keep_raw_factors_and_correlated_exponents(self): + count = 0 + for row in json.loads(g.TABLE.read_text()): + m = row['m'] + source = g.row_source(row) + self.assertEqual(source.count( + 'norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope]'), 3) + self.assertNotIn('norm_num [distillEBudget] at *', source) + self.assertIn('add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2', source) + self.assertIn(f"_ = {g.rat(row['total'])} := by norm_num only [distillEBudget]", + source) + budgets = [g.rat(F(c['u'], 1000)) for c in row['components']] + self.assertIn(f"_ ≤ distillEBudget {m} + " + ' + '.join(budgets), source) + for c in row['components']: + j, lo, hi = c['index'], F(c['lo']), F(c['hi']) + with self.subTest(m=m, component=j): + # Reconstruct the raw formulas, including lo=0, rather than + # calling the table validator's cancelled-ratio evaluator. + u, v = lo / (lo + 3), hi / (hi + 3) + ratio = (1-u) * (1-u**2/30) / 3 + kappa = F(m*m-1, 4*m) * ratio * (m-2*lo)**2 + envelope = v-v**3/30 + node = F(4, 25) + F(3, 5)*envelope + F(12, 25*m)*hi + if j == 0: + square = (kappa * 96*F(3, 5)**4 / + ((m-1)*(m+1)*(m+3)*(m+5)*(1-node)**4))**2 + else: + square = (F((259, 421)[j-1], 3125)*kappa)**2 * ( + node if j == 1 else envelope)**(m-3) + component = source.split(f'theorem component{j} ')[1].split('\n\n')[0] + self.assertIn(f' {m-3} (by norm_num) (by norm_num)', component) + self.assertEqual(square, F(c['sq'])) + self.assertLess(square, F(c['u'], 1000)**2) + count += 1 + self.assertEqual(count, 156) + def test_all_actual_sign_certificates_by_coefficient_reconstruction(self): # Expand the Bernstein basis back into powers, independently of the # renderer's change-of-basis implementation. No sampled evaluations. diff --git a/tests/test_generators.py b/tests/test_generators.py index 2a897d2..059052c 100644 --- a/tests/test_generators.py +++ b/tests/test_generators.py @@ -39,7 +39,7 @@ class GeneratorTests(unittest.TestCase): def test_retained_table_matches_pinned_original_subset(self): table = ROOT / 'data/paper_certificate_table.json' self.assertEqual(digest(table), EXPECTED['table_sha256']) - self.assertEqual([r['m'] for r in json.loads(table.read_text())], list(range(5, 62))) + self.assertEqual([r['m'] for r in json.loads(table.read_text())], [*range(5, 56), 61]) def setUp(self): self.temp = tempfile.TemporaryDirectory() @@ -68,7 +68,10 @@ def assert_distillation(self, output): actual = {str(p.relative_to(output)): digest(p) for p in output.rglob('*') if p.is_file()} self.assertEqual(actual, EXPECTED['distillation']) aggregate = (output / 'Sendov/Common/DistillationFinite.lean').read_text() - self.assertEqual(aggregate.count(' · exact (distillFinite_'), 56) + self.assertEqual(aggregate.count(' · exact (distillFinite_'), 50) + self.assertIn('exact distillComponents_interval_55_61', aggregate) + self.assertTrue((output / 'Sendov/DistillationFinite/Rows53_55.lean').is_file()) + self.assertFalse((output / 'Sendov/DistillationFinite/Rows53_60.lean').exists()) self.assertTrue((output / 'Sendov/DistillationFinite/Rows61_61.lean').is_file()) self.assertFalse((output / 'Sendov/DistillationFinite/Row61.lean').exists()) self.assertFalse((output / 'Sendov/DistillationFinite/Row5.lean').exists()) @@ -99,6 +102,8 @@ def test_bad_data_is_rejected_before_any_publication(self): original = json.loads((self.repo / 'data/paper_certificate_table.json').read_text()) mutations = { 'missing61': lambda r: r.pop(), + 'missing55': lambda r: r.pop(-2), + 'retired56': lambda r: r.__setitem__(-2, dict(r[-2], m=56)), 'extra62': lambda r: r.append(dict(r[-1], m=62)), 'duplicate row': lambda r: r.__setitem__(1, r[0]), 'row order': lambda r: r.reverse(), From b8713480a2caf7964bf2f91cc22a381d6d4ece3e Mon Sep 17 00:00:00 2001 From: Methode Date: Sun, 13 Sep 2026 10:22:28 -0700 Subject: [PATCH 11/24] refactor(sendov): prove the full scalar domain without degree certificates --- README.md | 55 +- Sendov/Common/DistillationBounds.lean | 38 +- Sendov/Common/DistillationCorrelatedPeak.lean | 393 ++++ Sendov/Common/DistillationCritical.lean | 491 ----- Sendov/Common/DistillationCriticalFinite.lean | 130 -- Sendov/Common/DistillationFactors.lean | 20 - Sendov/Common/DistillationFinite.lean | 81 - Sendov/Common/DistillationMajorant.lean | 30 - Sendov/Common/DistillationMiddleAlpha.lean | 152 ++ .../Common/DistillationMiddleEstimates.lean | 141 ++ Sendov/Common/DistillationPeakAlgebra.lean | 250 +++ Sendov/Common/DistillationPeakClosure.lean | 27 + Sendov/Common/DistillationPeakFirst.lean | 201 ++ Sendov/Common/DistillationPeakRational.lean | 157 ++ Sendov/Common/DistillationPeakRest.lean | 407 ++++ Sendov/Common/DistillationRegularity.lean | 129 ++ Sendov/Common/DistillationTotalBound.lean | 237 ++ Sendov/DistillationFinite/Rows13_20.lean | 952 -------- Sendov/DistillationFinite/Rows21_28.lean | 952 -------- Sendov/DistillationFinite/Rows29_36.lean | 953 -------- Sendov/DistillationFinite/Rows37_44.lean | 951 -------- Sendov/DistillationFinite/Rows45_52.lean | 866 -------- Sendov/DistillationFinite/Rows53_55.lean | 311 --- Sendov/DistillationFinite/Rows5_12.lean | 941 -------- Sendov/DistillationFinite/Rows61_61.lean | 98 - Sendov/LargeDegree/DistillationTail.lean | 463 ---- Sendov/LargeDegree/DistillationTailBound.lean | 73 - Sendov/Reduction/CubicScalar.lean | 2 +- Sendov/Reduction/Main.lean | 2 +- data/README.md | 32 +- data/paper_certificate_table.json | 1926 ----------------- docs/design.md | 225 +- docs/getting-started.md | 40 +- formalization.yaml | 53 +- lakefile.toml | 1 + scripts/GENERATORS.md | 95 +- scripts/LICENSE-DISTILLATION-MIT.txt | 21 - scripts/axioms.lean | 29 +- scripts/bundle_rows.py | 75 - scripts/distillation_data.py | 117 - scripts/gen_distillation.py | 225 -- tests/BoundaryConsumer.lean | 66 +- tests/EarlierTail.lean | 157 -- tests/LocalMiddleAlpha.lean | 150 ++ tests/LocalPeakClosure.lean | 150 ++ tests/LocalTotalBound.lean | 83 + tests/Localbudgets.lean | 154 -- tests/Localcertificates.lean | 155 +- tests/Localcommon.lean | 44 +- tests/Localgenerators.lean | 19 - tests/Localhotspots.lean | 56 +- tests/Localmathematics.lean | 59 - tests/Localranges.lean | 54 - tests/NoFiniteRows.lean | 93 + tests/expected.json | 12 - tests/test_alpha_certificates.py | 102 + tests/test_axiom_audit.py | 41 +- tests/test_bundle_rows.py | 83 - tests/test_generator_core.py | 275 +-- tests/test_generators.py | 165 +- 60 files changed, 3048 insertions(+), 11212 deletions(-) create mode 100644 Sendov/Common/DistillationCorrelatedPeak.lean delete mode 100644 Sendov/Common/DistillationCritical.lean delete mode 100644 Sendov/Common/DistillationCriticalFinite.lean delete mode 100644 Sendov/Common/DistillationFinite.lean delete mode 100644 Sendov/Common/DistillationMajorant.lean create mode 100644 Sendov/Common/DistillationMiddleAlpha.lean create mode 100644 Sendov/Common/DistillationMiddleEstimates.lean create mode 100644 Sendov/Common/DistillationPeakAlgebra.lean create mode 100644 Sendov/Common/DistillationPeakClosure.lean create mode 100644 Sendov/Common/DistillationPeakFirst.lean create mode 100644 Sendov/Common/DistillationPeakRational.lean create mode 100644 Sendov/Common/DistillationPeakRest.lean create mode 100644 Sendov/Common/DistillationRegularity.lean create mode 100644 Sendov/Common/DistillationTotalBound.lean delete mode 100644 Sendov/DistillationFinite/Rows13_20.lean delete mode 100644 Sendov/DistillationFinite/Rows21_28.lean delete mode 100644 Sendov/DistillationFinite/Rows29_36.lean delete mode 100644 Sendov/DistillationFinite/Rows37_44.lean delete mode 100644 Sendov/DistillationFinite/Rows45_52.lean delete mode 100644 Sendov/DistillationFinite/Rows53_55.lean delete mode 100644 Sendov/DistillationFinite/Rows5_12.lean delete mode 100644 Sendov/DistillationFinite/Rows61_61.lean delete mode 100644 Sendov/LargeDegree/DistillationTail.lean delete mode 100644 Sendov/LargeDegree/DistillationTailBound.lean delete mode 100644 data/paper_certificate_table.json delete mode 100644 scripts/LICENSE-DISTILLATION-MIT.txt delete mode 100644 scripts/bundle_rows.py delete mode 100644 scripts/distillation_data.py delete mode 100644 scripts/gen_distillation.py delete mode 100644 tests/EarlierTail.lean create mode 100644 tests/LocalMiddleAlpha.lean create mode 100644 tests/LocalPeakClosure.lean create mode 100644 tests/LocalTotalBound.lean delete mode 100644 tests/Localbudgets.lean delete mode 100644 tests/Localmathematics.lean delete mode 100644 tests/Localranges.lean create mode 100644 tests/NoFiniteRows.lean create mode 100644 tests/test_alpha_certificates.py delete mode 100644 tests/test_bundle_rows.py diff --git a/README.md b/README.md index 84a723f..d7d4cdd 100644 --- a/README.md +++ b/README.md @@ -18,9 +18,8 @@ hypothesis in either final theorem. The polynomial identities, analytic reduction, low-degree argument and boundary classification start from Terence Tao's formalization.[1] The scalar endgame -here is a Lean implementation of Senjian An's rational-envelope and -low-degree critical-polynomial method, not an import of its Python checks as -trusted facts.[2] +uses Senjian An's rational envelope and two-chord estimate, followed by +full-degree-ray alpha estimates proved in Lean, not trusted Python checks.[2] | Part | Active source | |---|---| @@ -29,32 +28,26 @@ trusted facts.[2] | Interior degrees `2 ≤ n ≤ 5` | [`LowDegree`](Sendov/Analytic/LowDegree.lean), [`Interior`](Sendov/Interior.lean) | | Original polar/origin hypotheses → scalar domain and lower bound | [`CubicScalar`](Sendov/Reduction/CubicScalar.lean) | | Strong hyperbolic bound and cubic polar envelope | [`DistillationHyperbolic`](Sendov/Common/DistillationHyperbolic.lean), [`CubicPolar`](Sendov/Reduction/CubicPolar.lean) | -| Two-chord integral estimate and regularized factors | [`TwoChord`](Sendov/Common/TwoChord.lean), [`DistillationMajorant`](Sendov/Common/DistillationMajorant.lean) | -| Finite critical-point certificates | [`DistillationFinite`](Sendov/Common/DistillationFinite.lean), [`generated modules`](Sendov/DistillationFinite) | -| Real-parameter tail using the actual base certificate | [`DistillationTailBound`](Sendov/LargeDegree/DistillationTailBound.lean) | +| Two-chord integral estimate and regularized factors | [`TwoChord`](Sendov/Common/TwoChord.lean), [`DistillationFactors`](Sendov/Common/DistillationFactors.lean) | +| Small alpha, `0 < alpha <= 7/5` | [`DistillationTotalBound`](Sendov/Common/DistillationTotalBound.lean) | +| Middle alpha, `7/5 <= alpha <= 2` | [`DistillationMiddleAlpha`](Sendov/Common/DistillationMiddleAlpha.lean) | +| Large alpha, `2 <= alpha <= 17` | [`DistillationPeakClosure`](Sendov/Common/DistillationPeakClosure.lean) | | Complete contradiction | [`DistillationBounds`](Sendov/Common/DistillationBounds.lean), [`Reduction/Main`](Sendov/Reduction/Main.lean) | -The convention is **`m = n - 1`**. The final degree split now uses the finite -proof for `5 ≤ m ≤ 60` (through `n=61`), then the real-parameter tail for -`m ≥ 61` (from `n=62`). The latter reuses the existing row-61 certificate -to prove a bound of `<199/200`, which is sufficient for the scalar `<1`. -Exactly 52 unchanged certificate records, `5 ≤ m ≤ 55` and `m=61`, are retained. -The finite aggregate uses 50 individual cases for `5 ≤ m ≤ 54` and a single -real interval theorem for `55 ≤ m ≤ 61`, with the original row-55 budgets -constructed internally. The tail still consumes row 61 from `Rows61_61`. -Rows 56–60, 62–81 and the old `<2/3` tail interfaces are retired. -There is no separate duplicate row-61 module or second certificate representation. -The earlier tail uses the rational fourth-power envelope cap `(21/22)^4` -to retain stronger logarithmic decay. The rational component is antitone already -from 55, using an alpha split at 10. On the bounded interval, the two exponential -components may grow: linear weights bound that growth, giving the exact total -`58135011269/58896123000 < 199/200`. No new Bernstein certificates are introduced. - -Each finite case uses the complete critical polynomials of degrees **7, 7, 4**. -Exact Bernstein identities prove derivative signs on the full outer intervals; -a mixed-endpoint estimate covers the central bracket. The proof does not assume -that a numerical root finder found all critical points. Closed endpoints and -empty outer intervals are handled explicitly. +The convention is **`m = n - 1`**. `distillScalar_lt_one_real` proves the +original raw scalar bound `<1` for **every real `m >= 5`, +`0 < alpha <= 17`, `2*alpha <= m`**, including noninteger degrees and the +legal `m=2*alpha` endpoint. The natural `n >= 6` wrapper has its original type. +There is no finite-degree certificate, numerical degree base, interval patch +or later tail cutoff. No claim is made that 5 is globally minimal. + +The three alpha regimes are mathematical estimates on entire degree rays. +Large alpha uses three complete polynomial identities of degrees **53, 47, 47**, +with 150 ordered coefficients and 71 low-degree homogeneous factor coefficients. +All scales, factors and identities are checked by Lean's kernel. These are +fixed alpha certificates, not degree rows; their full source and data cost is +included in the implementation, not hidden behind three theorem names. +The raw value at `alpha=0` remains `1/(2*m)`, separately from regularization. The old `R`-based finite/large-degree certificate system and its specialized generators are retired, not shipped as a second compatibility route. General @@ -81,15 +74,15 @@ is not reported as all of them. See [`docs/getting-started.md`](docs/getting-started.md) for verification and [`scripts/GENERATORS.md`](scripts/GENERATORS.md) for reproducible generation. -The finite generator emits the entire selected table in one command to a fresh output -root. Python prepares exact data; Lean verifies the complete identities and -inequalities. A successful generator run is **not** a completed proof check. +The alpha identities are self-contained Lean source and need no generator. +The existing global `sinh` generator remains reproducible. A successful +generator run is **not** a completed proof check. ## Provenance and scope This is a local adaptation, not a claim that upstream maintainers reviewed or endorsed these changes. The repository keeps the original Apache-2.0 code -license. The distilled mathematics and certificate table are attributed to +license. The retained distilled mathematics is attributed to Senjian An's fixed source version; the source paper is CC BY 4.0.[2] The retained generator entry points incorporate applicable portability fixes; obsolete batch-specific tools are not retained merely to preserve a PR surface.[4] diff --git a/Sendov/Common/DistillationBounds.lean b/Sendov/Common/DistillationBounds.lean index 9f59396..2e60151 100644 --- a/Sendov/Common/DistillationBounds.lean +++ b/Sendov/Common/DistillationBounds.lean @@ -1,30 +1,30 @@ -import Sendov.Common.DistillationFinite -import Sendov.LargeDegree.DistillationTailBound +import Sendov.Common.DistillationMiddleAlpha +import Sendov.Common.DistillationPeakClosure /-! -# The complete scalar upper bound +# The complete scalar bound without finite degree certificates -The original degree is `n`; the scalar parameter is `m = n - 1`. -The scalar consumer uses finite rows for `5 ≤ m ≤ 54`, the real interval -`55 ≤ m ≤ 61` based on row 55, and the real-degree tail based on row 61. -Exactly the 52 original records 5 through 55 and 61 are retained. +Both alpha regions hold for every legal real degree m >= 5. The shared endpoint +alpha = 2 joins them without a degree split or a numerical base row. -/ namespace Sendov -/-- The cubic scalar obstruction is strictly below one on the full domain -produced by the geometric reduction. No numerical or tail premise remains. -/ +/-- The entire original scalar domain, with no finite-degree or tail premise. -/ +theorem distillScalar_lt_one_real {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (h17 : α ≤ 17) (hhalf : 2 * α ≤ m) : + scalarObstruction m α (cubicPolarEnvelope α) < 1 := by + by_cases hlow : α ≤ 2 + · exact distillScalar_lt_one_alpha_le_two hm hα hlow hhalf + · exact distillScalar_lt_one_peak_strip hm (by linarith) h17 hhalf + +/-- The original geometric-reduction interface retains its literal contract. -/ theorem distillScalar_lt_one {n : ℕ} (hn : 6 ≤ n) {α : ℝ} (hα : 0 < α) (h17 : α ≤ 17) (hhalf : 2 * α ≤ M n) : scalarObstruction (M n) α (cubicPolarEnvelope α) < 1 := by - have hn1 : 1 ≤ n := by omega - have hM : ((n - 1 : ℕ) : ℝ) = M n := by - rw [Nat.cast_sub hn1] - simp [M] - have hm : 5 ≤ n - 1 := by omega - rw [← hM] at hhalf ⊢ - by_cases hfinite : n - 1 < 61 - · exact (distillFinite_scalar hm (by omega) hα (by linarith) h17).trans (by norm_num) - · have hlarge : (61 : ℝ) ≤ (n - 1 : ℕ) := by exact_mod_cast (show 61 ≤ n - 1 by omega) - exact (distillScalar_lt_199_200 hlarge hα h17).trans (by norm_num) + have hm : 5 ≤ M n := by + have hnR : (6 : ℝ) ≤ n := by exact_mod_cast hn + unfold M + linarith + exact distillScalar_lt_one_real hm hα h17 hhalf end Sendov diff --git a/Sendov/Common/DistillationCorrelatedPeak.lean b/Sendov/Common/DistillationCorrelatedPeak.lean new file mode 100644 index 0000000..f81dedd --- /dev/null +++ b/Sendov/Common/DistillationCorrelatedPeak.lean @@ -0,0 +1,393 @@ +import Sendov.Common.DistillationTotalBound + +/-! +# Same-alpha degree peaks + +The shift is `m - 2 * alpha`, not `m - 34`. All bounds below cover the +entire legal real-degree ray. No finite row or old tail theorem is imported. +-/ + +namespace Sendov + +lemma log_le_pade {x : ℝ} (hx : 0 < x) (hx1 : x ≤ 1) : + Real.log x ≤ -2 * ((1 - x) / (1 + x)) := by + let f := fun y : ℝ => Real.log y - 2 * (y - 1) / (y + 1) + have hd (y : ℝ) (hy : 0 < y) : + HasDerivAt f ((y - 1) ^ 2 / (y * (y + 1) ^ 2)) y := by + have h := (Real.hasDerivAt_log hy.ne').sub + ((((hasDerivAt_id' y).sub_const 1).const_mul 2).div + ((hasDerivAt_id' y).add_const 1) (by linarith)) + apply h.congr_deriv + field_simp + ring + have hmono : MonotoneOn f (Set.Ioi 0) := by + refine monotoneOn_of_hasDerivWithinAt_nonneg (convex_Ioi 0) + (fun y hy => (hd y hy).continuousAt.continuousWithinAt) + (fun y hy => (hd y (interior_subset hy)).hasDerivWithinAt) ?_ + intro y hy + have hy0 : 0 < y := interior_subset hy + exact div_nonneg (sq_nonneg _) (by positivity) + have h := hmono hx (by norm_num : (1 : ℝ) ∈ Set.Ioi 0) hx1 + dsimp [f] at h + norm_num at h + have hid : 2 * (x - 1) / (x + 1) = -2 * ((1 - x) / (1 + x)) := by ring + linarith + +private lemma pow_mul_exp_peak {t c : ℝ} (ht : 0 ≤ t) (hc : 0 < c) + (n : ℕ) (hn : 0 < n) : + t ^ n * Real.exp (-c * t) ≤ + ((n : ℝ) / c) ^ n * Real.exp (-(n : ℝ)) := by + have hn0 : (0 : ℝ) < n := Nat.cast_pos.mpr hn + have h := pow_le_pow_left₀ + (mul_nonneg (div_nonneg (mul_nonneg hc.le ht) hn0.le) (Real.exp_nonneg _)) + (Real.mul_exp_neg_le_exp_neg_one (c * t / n)) n + rw [mul_pow, ← Real.exp_nat_mul, ← Real.exp_nat_mul] at h + have he : (n : ℝ) * -(c * t / n) = -c * t := by field_simp + rw [he] at h + have hmul := mul_le_mul_of_nonneg_left h (pow_nonneg (div_nonneg hn0.le hc.le) n) + have hid : ((n : ℝ) / c) ^ n * ((c * t / n) ^ n * Real.exp (-c * t)) = + t ^ n * Real.exp (-c * t) := by + rw [← mul_assoc, ← mul_pow] + congr 2 + field_simp + simpa only [hid, mul_neg, mul_one] using hmul + +noncomputable def distillExpPeak (α c : ℝ) : ℝ := + Real.exp (-c * (2 * α - 3)) * + (27 * Real.exp (-3) / c ^ 3 + 8 * α * Real.exp (-2) / c ^ 2) + +/-- The two polynomial terms peak separately, but at the same alpha. -/ +lemma distill_degree_exp_le_peak {m α c : ℝ} (hα : 0 ≤ α) + (hαm : 2 * α ≤ m) (hc : 0 < c) : + m * (m - 2 * α) ^ 2 * Real.exp (-c * (m - 3)) ≤ + distillExpPeak α c := by + let t := m - 2 * α + have ht : 0 ≤ t := sub_nonneg.mpr hαm + have h2 := pow_mul_exp_peak ht hc 2 (by norm_num) + have h3 := pow_mul_exp_peak ht hc 3 (by norm_num) + have hsum := add_le_add h3 (mul_le_mul_of_nonneg_left h2 (by positivity : 0 ≤ 2 * α)) + have hexp : Real.exp (-c * (m - 3)) = + Real.exp (-c * (2 * α - 3)) * Real.exp (-c * t) := by + rw [← Real.exp_add] + congr 1 + dsimp [t] + ring + rw [hexp] + unfold distillExpPeak + have hid : m * (m - 2 * α) ^ 2 * + (Real.exp (-c * (2 * α - 3)) * Real.exp (-c * t)) = + Real.exp (-c * (2 * α - 3)) * + (t ^ 3 * Real.exp (-c * t) + 2 * α * (t ^ 2 * Real.exp (-c * t))) := by + dsimp [t] + ring + rw [hid] + apply mul_le_mul_of_nonneg_left _ (Real.exp_nonneg _) + convert hsum using 1 + norm_num + ring + +noncomputable def distillPeak2 (α : ℝ) : ℝ := + (421 / 12500) * distillRatio α * + distillExpPeak α (-Real.log (cubicPolarEnvelope α) / 2) + +lemma distillKappa_le_shifted_cubic {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : + distillKappa m α ≤ distillRatio α / 4 * (m * (m - 2 * α) ^ 2) := by + have hbase : (m ^ 2 - 1) / (4 * m) ≤ m / 4 := by + apply (div_le_iff₀ (by positivity : 0 < 4 * m)).mpr + nlinarith + have h := mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_right hbase (distillRatio_nonneg hα)) (sq_nonneg (m - 2 * α)) + exact h.trans_eq (by ring) + +/-- An explicit uniform degree bound; no optimizer or assumed maximum occurs. -/ +theorem distillT2_le_peak {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) + (hαm : 2 * α ≤ m) : distillT2 m α ≤ distillPeak2 α := by + have hm0 : 0 < m := by linarith + have he := cubicPolarEnvelope_pos hα + have hc : 0 < -Real.log (cubicPolarEnvelope α) / 2 := + div_pos (neg_pos.mpr (Real.log_neg he (cubicPolarEnvelope_lt_one hα.le))) (by norm_num) + have hK := distillKappa_le_shifted_cubic hm0 hα.le + have hpow : cubicPolarEnvelope α ^ ((m - 3) / 2) = + Real.exp (-(-Real.log (cubicPolarEnvelope α) / 2) * (m - 3)) := by + rw [Real.rpow_def_of_pos he] + congr 1 + ring + have hpeak := distill_degree_exp_le_peak hα.le hαm hc + rw [distillT2, hpow] + calc + _ ≤ (421 / 3125) * (distillRatio α / 4 * (m * (m - 2 * α) ^ 2)) * + Real.exp (-(-Real.log (cubicPolarEnvelope α) / 2) * (m - 3)) := + mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_left hK (by norm_num)) (Real.exp_nonneg _) + _ = (421 / 12500) * distillRatio α * + (m * (m - 2 * α) ^ 2 * + Real.exp (-(-Real.log (cubicPolarEnvelope α) / 2) * (m - 3))) := by ring + _ ≤ distillPeak2 α := mul_le_mul_of_nonneg_left hpeak + (mul_nonneg (by norm_num) (distillRatio_nonneg hα.le)) + +noncomputable def distillPeakNode (α : ℝ) : ℝ := + 8 / 25 + 3 / 5 * cubicPolarEnvelope α + +noncomputable def distillPeakRate1 (α : ℝ) : ℝ := + (1 - distillPeakNode α) / (1 + distillPeakNode α) + + (2 / 25) * (α - 1) / (α * distillPeakNode α) + +noncomputable def distillPeakBoost1 (α : ℝ) : ℝ := + (6 / 25) * (α - 1) ^ 2 / (α * distillPeakNode α) + +noncomputable def distillPeak1 (α : ℝ) : ℝ := + (259 / 12500) * distillRatio α * Real.exp (distillPeakBoost1 α) * + distillExpPeak α (distillPeakRate1 α) + +lemma distillPeakNode_pos {α : ℝ} (hα : 0 ≤ α) : 0 < distillPeakNode α := by + have := cubicPolarEnvelope_nonneg hα + unfold distillPeakNode + linarith + +lemma distillPeakNode_lt_one {α : ℝ} (hα : 0 ≤ α) : distillPeakNode α < 1 := by + have := cubicPolarEnvelope_lt_one hα + unfold distillPeakNode + linarith + +lemma distillPeakRate1_pos {α : ℝ} (hα : 1 ≤ α) : 0 < distillPeakRate1 α := by + have hb := distillPeakNode_pos (by linarith : 0 ≤ α) + have hb1 := distillPeakNode_lt_one (by linarith : 0 ≤ α) + have hfirst : 0 < (1 - distillPeakNode α) / (1 + distillPeakNode α) := + div_pos (by linarith) (by linarith) + have hsecond : 0 ≤ (2 / 25 : ℝ) * (α - 1) / (α * distillPeakNode α) := + div_nonneg (mul_nonneg (by norm_num) (by linarith)) (by positivity) + exact add_pos_of_pos_of_nonneg hfirst hsecond + +/-- The reciprocal correction is a nonnegative square, not a discarded term. -/ +lemma distillNode_rpow_le_exp {m α : ℝ} (hm : 5 ≤ m) (hα : 1 ≤ α) : + distillNode m α ^ ((m - 3) / 2) ≤ + Real.exp (-distillPeakRate1 α * (m - 3) + distillPeakBoost1 α) := by + have hα0 : 0 < α := by linarith + have hm0 : 0 < m := by linarith + have hb := distillPeakNode_pos hα0.le + have hb1 := distillPeakNode_lt_one hα0.le + have hn := distillNode_pos hm0 hα0.le + have hlog := Real.log_le_sub_one_of_pos (div_pos hn hb) + rw [Real.log_div hn.ne' hb.ne'] at hlog + have hpade := log_le_pade hb hb1.le + have hlogbound : Real.log (distillNode m α) ≤ + -2 * ((1 - distillPeakNode α) / (1 + distillPeakNode α)) + + (distillNode m α - distillPeakNode α) / distillPeakNode α := by + have hid : (distillNode m α - distillPeakNode α) / distillPeakNode α = + distillNode m α / distillPeakNode α - 1 := by field_simp + linarith + have hmul := mul_le_mul_of_nonneg_right hlogbound (by linarith : 0 ≤ (m - 3) / 2) + have hgap : + -distillPeakRate1 α * (m - 3) + distillPeakBoost1 α - + (-2 * ((1 - distillPeakNode α) / (1 + distillPeakNode α)) + + (distillNode m α - distillPeakNode α) / distillPeakNode α) * ((m - 3) / 2) = + (2 / 25) * (m - 3 * α) ^ 2 / (α * distillPeakNode α * m) := by + unfold distillPeakRate1 distillPeakBoost1 + have hnode : distillNode m α = distillPeakNode α - 4 / 25 + 12 * α / (25 * m) := by + unfold distillNode distillPeakNode + ring + rw [hnode] + have hbplus : 1 + distillPeakNode α ≠ 0 := by positivity + field_simp + ring + have hnonneg : 0 ≤ (2 / 25 : ℝ) * (m - 3 * α) ^ 2 / + (α * distillPeakNode α * m) := by positivity + rw [Real.rpow_def_of_pos hn] + exact Real.exp_le_exp.mpr (by linarith) + +theorem distillT1_le_peak {m α : ℝ} (hm : 5 ≤ m) (hα : 1 ≤ α) + (hαm : 2 * α ≤ m) : distillT1 m α ≤ distillPeak1 α := by + have hα0 : 0 ≤ α := by linarith + have hm0 : 0 < m := by linarith + have hK := distillKappa_le_shifted_cubic hm0 hα0 + have hpow := distillNode_rpow_le_exp hm hα + have hp := mul_le_mul hK hpow + (Real.rpow_nonneg (distillNode_pos hm0 hα0).le _) (by + have := distillRatio_nonneg hα0 + positivity) + have hpeak := distill_degree_exp_le_peak hα0 hαm (distillPeakRate1_pos hα) + have h := mul_le_mul_of_nonneg_left hp (by norm_num : (0 : ℝ) ≤ 259 / 3125) + have hscaled := mul_le_mul_of_nonneg_left hpeak + (by have := distillRatio_nonneg hα0 + positivity : 0 ≤ (259 / 12500) * distillRatio α * Real.exp (distillPeakBoost1 α)) + rw [Real.exp_add] at h + unfold distillT1 distillPeak1 + nlinarith only [h, hscaled] + +noncomputable def distillPeakRate2 (α : ℝ) : ℝ := + (1 - cubicPolarEnvelope α) / (1 + cubicPolarEnvelope α) + +lemma distillPeakRate2_pos {α : ℝ} (hα : 0 ≤ α) : 0 < distillPeakRate2 α := + div_pos (sub_pos.mpr (cubicPolarEnvelope_lt_one hα)) + (by have := cubicPolarEnvelope_nonneg hα; positivity) + +private lemma quartic_peak {z l : ℝ} (hz : 0 ≤ z) (hz1 : z ≤ 1) + (hl : 0 ≤ l) (hl1 : l ≤ 1) : + z ^ 2 * (1 - z) * (1 - l * z) ≤ (1 - l) * (4 / 27) + l / 16 := by + have h3 : z ^ 2 * (1 - z) ≤ 4 / 27 := by + have h := mul_nonneg (sq_nonneg (z - 2 / 3)) (by linarith : 0 ≤ z + 1 / 3) + nlinarith + have h4 : z ^ 2 * (1 - z) ^ 2 ≤ 1 / 16 := by + have hp : 0 ≤ z * (1 - z) := mul_nonneg hz (by linarith) + have hq : z * (1 - z) ≤ 1 / 4 := by nlinarith [sq_nonneg (z - 1 / 2)] + have hs := pow_le_pow_left₀ hp hq 2 + nlinarith only [hs] + have h := add_le_add + (mul_le_mul_of_nonneg_left h3 (by linarith : 0 ≤ 1 - l)) + (mul_le_mul_of_nonneg_left h4 hl) + nlinarith only [h] + +noncomputable def distillPeakD (α : ℝ) : ℝ := + 21 / 25 - 3 / 5 * cubicPolarEnvelope α + +noncomputable def distillPeak0 (α : ℝ) : ℝ := + (972 / 625) * distillRatio α * (4 * distillPeakD α / 27 - 37 / 1800) / + (α * distillPeakD α ^ 3 * (distillPeakD α - 6 / 25) ^ 2) + +lemma distillPeakD_gt {α : ℝ} (hα : 0 ≤ α) : 6 / 25 < distillPeakD α := by + have := cubicPolarEnvelope_lt_one hα + unfold distillPeakD + linarith + +/-- A quartic peak bound after compactifying the entire degree ray. -/ +theorem distillT0_le_peak {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) + (hαm : 2 * α ≤ m) : distillT0 m α ≤ distillPeak0 α := by + have hm0 : 0 < m := by linarith + have hm1 : m - 1 ≠ 0 := by linarith + have hnode := distillNode_lt_one hm0 hα.le (by linarith) + let d := distillPeakD α + have hd : 6 / 25 < d := distillPeakD_gt hα.le + have hd0 : 0 < d := by linarith + let l := (6 / 25) / d + have hl : 0 ≤ l := by dsimp [l]; positivity + have hl1 : l < 1 := (div_lt_one hd0).mpr hd + let q := m - 2 * α * l + have hq : 0 < q := by + have h := mul_pos hα (sub_pos.mpr hl1) + dsimp [q] + nlinarith + let z := (m - 2 * α) / q + have hz : 0 ≤ z := div_nonneg (by linarith) hq.le + have hz1 : z ≤ 1 := by + apply (div_le_one hq).mpr + dsimp [q] + nlinarith + let A := 24 * (3 / 5 : ℝ) ^ 4 * distillRatio α * + m * (m - 2 * α) ^ 2 / (d * m - 12 * α / 25) ^ 4 + have hdenid : d * m - 12 * α / 25 = d * q := by + dsimp [q, l] + field_simp + ring + have hden : 0 < d * m - 12 * α / 25 := by + rw [hdenid] + positivity + have hA : 0 ≤ A := by + have := distillRatio_nonneg hα.le + dsimp [A] + positivity + have hT : distillT0 m α = A * (m ^ 2 / ((m + 3) * (m + 5))) := by + have hnodeid : 1 - distillNode m α = (d * m - 12 * α / 25) / m := by + dsimp [d, distillPeakD, distillNode] + field_simp + ring + unfold distillT0 distillKappa + rw [hnodeid] + dsimp [A] + field_simp + ring + have hTA : distillT0 m α ≤ A := by + rw [hT] + apply mul_le_of_le_one_right hA + apply (div_le_one (by positivity : 0 < (m + 3) * (m + 5))).mpr + nlinarith + let C := 24 * (3 / 5 : ℝ) ^ 4 * distillRatio α / + (2 * α * d ^ 4 * (1 - l) ^ 2) + have hC : 0 ≤ C := by + have := distillRatio_nonneg hα.le + dsimp [C] + positivity + have hAz : A = C * (z ^ 2 * (1 - z) * (1 - l * z)) := by + have hlne : 1 - l ≠ 0 := by linarith + dsimp [A, C, z] + rw [hdenid] + field_simp [hq.ne', hlne, hα.ne', hd0.ne'] + dsimp [q] + ring + have hcap : C * ((1 - l) * (4 / 27) + l / 16) = distillPeak0 α := by + dsimp [C, l, distillPeak0] + change _ = (972 / 625) * distillRatio α * (4 * d / 27 - 37 / 1800) / + (α * d ^ 3 * (d - 6 / 25) ^ 2) + have hsub : d - 6 / 25 ≠ 0 := by linarith + field_simp + ring + rw [hAz] at hTA + exact hTA.trans ((mul_le_mul_of_nonneg_left (quartic_peak hz hz1 hl hl1.le) hC).trans_eq hcap) + +noncomputable def distillElementary (m α : ℝ) : ℝ := + distillRatio α / (2 * (1 - cubicPolarEnvelope α)) + distillRatio α / 4 + + (1 / 2 + distillRatio α / 4) / m + +lemma distillElementary_antitone_degree {m k α : ℝ} (hk : 0 < k) + (hkm : k ≤ m) (hα : 0 ≤ α) : + distillElementary m α ≤ distillElementary k α := by + unfold distillElementary + have hnum : 0 ≤ 1 / 2 + distillRatio α / 4 := by + have := distillRatio_nonneg hα + positivity + exact add_le_add le_rfl (div_le_div_of_nonneg_left hnum hk hkm) + +/-- Keep the actual elementary term before choosing any component peak estimates. -/ +theorem distillScalar_le_elementary_components {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α ≤ m) : + scalarObstruction m α (cubicPolarEnvelope α) ≤ + distillElementary m α + distillT0 m α + distillT1 m α + distillT2 m α := by + have h := distillScalar_le_total_sub_loss hm hα hαm + have hE : distillEBudget m - distillElementaryLoss m α = distillElementary m α := by + have hid := distillScalar_eq_loss_integral (by linarith : 0 < m) hα + unfold scalarObstruction at hid + rw [← distillKappa_eq hα] at hid + unfold distillElementary + rw [distillRatio_eq hα] + have he := (sub_pos.mpr (cubicPolarEnvelope_lt_one hα.le)).ne' + have hm0 : m ≠ 0 := by linarith + have halg : + cubicPolarEnvelope α / (2 * α * (1 - cubicPolarEnvelope α)) + + cubicPolarEnvelope α / (4 * α) + 1 / (2 * m) + + cubicPolarEnvelope α / (4 * α * m) = + cubicPolarEnvelope α / α / (2 * (1 - cubicPolarEnvelope α)) + + cubicPolarEnvelope α / α / 4 + (1 / 2 + cubicPolarEnvelope α / α / 4) / m := by + field_simp + ring + linarith + unfold distillTotal at h + linarith only [h, hE] + +/-- Actual elementary E is bounded on the same legal degree domain. -/ +theorem distillScalar_le_correlated_peak2 {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α ≤ m) : + scalarObstruction m α (cubicPolarEnvelope α) ≤ + distillElementary (max 5 (2 * α)) α + + distillT0 m α + distillT1 m α + distillPeak2 α := by + have h := distillScalar_le_elementary_components hm hα hαm + have hEbound := distillElementary_antitone_degree + (lt_of_lt_of_le (by norm_num : (0 : ℝ) < 5) (le_max_left 5 (2 * α))) + (max_le hm hαm) hα.le + have h2 := distillT2_le_peak hm hα hαm + linarith + +noncomputable def distillCorrelatedPeak (α : ℝ) : ℝ := + distillElementary (max 5 (2 * α)) α + + distillPeak0 α + distillPeak1 α + distillPeak2 α + +/-- All three degree bounds retain the same original alpha. -/ +theorem distillScalar_le_correlated_peak {m α : ℝ} (hm : 5 ≤ m) + (hα : 1 ≤ α) (hαm : 2 * α ≤ m) : + scalarObstruction m α (cubicPolarEnvelope α) ≤ distillCorrelatedPeak α := by + have hα0 : 0 < α := by linarith + have h := distillScalar_le_correlated_peak2 hm hα0 hαm + have h0 := distillT0_le_peak hm hα0 hαm + have h1 := distillT1_le_peak hm hα hαm + unfold distillCorrelatedPeak + linarith + +end Sendov diff --git a/Sendov/Common/DistillationCritical.lean b/Sendov/Common/DistillationCritical.lean deleted file mode 100644 index ade090c..0000000 --- a/Sendov/Common/DistillationCritical.lean +++ /dev/null @@ -1,491 +0,0 @@ -import Sendov.Common.DistillationFactors - -/-! -# Critical polynomials and derivatives of the distillation components - -Adaptation of Senjian An, *Proof Distillation for Sendov's Conjecture*, -revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, Appendix B and (5.2)--(5.4). -Paper: CC BY 4.0, https://creativecommons.org/licenses/by/4.0/ . -The three definitions use exactly the descending coefficient order of -`verification/verify_paper.py`. They are not the old Sendov R or T1. --/ - -namespace Sendov - -noncomputable def distillCritical0 (m α : ℝ) : ℝ := - -4176 * α ^ 7 + 2 * (1363 * m - 36072) * α ^ 6 + - (-377 * m ^ 2 + 22092 * m - 514512) * α ^ 5 + - 12 * (103 * m ^ 2 - 1323 * m - 161676) * α ^ 4 + - 1134 * (49 * m ^ 2 - 566 * m - 3600) * α ^ 3 + - 486 * (665 * m ^ 2 - 4752 * m - 9360) * α ^ 2 + - 972 * (743 * m ^ 2 - 3330 * m - 2160) * α + 43740 * m * (13 * m - 36) - -noncomputable def distillCritical1 (m α : ℝ) : ℝ := - 1392 * (m - 1) * α ^ 7 - 4 * (174 * m ^ 2 - 8279 * m + 4392) * α ^ 6 - - 2 * (2914 * m ^ 2 - 158961 * m + 34992) * α ^ 5 - - 3 * (783 * m ^ 3 - m ^ 2 - 538848 * m + 6048) * α ^ 4 - - 216 * (140 * m ^ 3 - 609 * m ^ 2 - 21974 * m - 2610) * α ^ 3 - - 216 * (660 * m ^ 3 - 2164 * m ^ 2 - 37581 * m - 6480) * α ^ 2 - - 648 * (450 * m ^ 3 - 934 * m ^ 2 - 11655 * m - 1620) * α - - 14580 * m * (15 * m ^ 2 - 17 * m - 204) - -noncomputable def distillCritical2 (m α : ℝ) : ℝ := - 116 * α ^ 4 + 2 * (110 * m + 453) * α ^ 3 - - 3 * (27 * m ^ 2 - 565 * m - 720) * α ^ 2 - - 540 * (m ^ 2 - 7 * m - 3) * α - 810 * m * (m - 3) - -noncomputable def distillN (α : ℝ) : ℝ := 29 * α ^ 2 + 180 * α + 270 - -noncomputable def distillB (m α : ℝ) : ℝ := - 24 * α ^ 4 + (37 * m + 216) * α ^ 3 + (252 * m + 648) * α ^ 2 + - (486 * m + 648) * α + 216 * m - -noncomputable def distillD (m α : ℝ) : ℝ := 50 * m * (α + 3) ^ 3 - distillB m α - -noncomputable def distillK (m α : ℝ) : ℝ := - (α + 3) * (m - 2 * α) * (58 * α + 180) - - (3 * (m - 2 * α) + 4 * (α + 3)) * distillN α - -noncomputable def distillRp (m α : ℝ) : ℝ := - (α + 3) * (96 * α ^ 3 + 3 * (37 * m + 216) * α ^ 2 + - 2 * (252 * m + 648) * α + (486 * m + 648)) - 3 * distillB m α - -noncomputable def distillL (α : ℝ) : ℝ := 81 * α ^ 2 + 540 * α + 810 - -lemma distillCritical0_eq (m α : ℝ) : - distillCritical0 m α = distillK m α * distillD m α + - 4 * (m - 2 * α) * distillN α * distillRp m α := by - unfold distillCritical0 distillK distillD distillN distillRp distillB - ring - -lemma distillCritical1_eq (m α : ℝ) : - distillCritical1 m α = -2 * distillK m α * distillB m α - - (m - 3) * (m - 2 * α) * distillN α * distillRp m α := by - unfold distillCritical1 distillK distillN distillRp distillB - ring - -lemma distillCritical2_eq (m α : ℝ) : - distillCritical2 m α = -2 * α * distillK m α - - (m - 3) * (m - 2 * α) * distillL α := by - unfold distillCritical2 distillK distillN distillL - ring - -lemma distillRatio_compact {α : ℝ} (hα : 0 ≤ α) : - distillRatio α = distillN α / (30 * (α + 3) ^ 3) := by - have ht : α + 3 ≠ 0 := by linarith - unfold distillRatio distillN - field_simp [ht] - ring - -lemma cubicPolarEnvelope_compact {α : ℝ} (hα : 0 ≤ α) : - cubicPolarEnvelope α = α * distillN α / (30 * (α + 3) ^ 3) := by - have ht : α + 3 ≠ 0 := by linarith - unfold cubicPolarEnvelope distillN - field_simp [ht] - ring - -lemma distillNode_compact {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : - distillNode m α = distillB m α / (50 * m * (α + 3) ^ 3) := by - rw [distillNode, cubicPolarEnvelope_compact hα] - have ht : α + 3 ≠ 0 := by linarith - unfold distillB distillN - field_simp [ht, hm.ne'] - ring - -lemma distillD_eq {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : - distillD m α = 50 * m * (α + 3) ^ 3 * (1 - distillNode m α) := by - rw [distillNode_compact hm hα, distillD] - rw [mul_one_sub, mul_div_cancel₀ _ (by positivity)] - -lemma distillN_pos {α : ℝ} (hα : 0 ≤ α) : 0 < distillN α := by - unfold distillN - positivity - -lemma distillB_pos {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : - 0 < distillB m α := by - unfold distillB - positivity - -lemma distillD_pos {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) (hαm : α ≤ m / 2) : - 0 < distillD m α := by - rw [distillD_eq hm hα] - have := distillNode_lt_one hm hα hαm - have : 0 < α + 3 := by linarith - positivity - -lemma distillRatio_pos {α : ℝ} (hα : 0 ≤ α) : 0 < distillRatio α := by - rw [distillRatio_compact hα] - exact div_pos (distillN_pos hα) (by positivity) - -lemma cubicPolarEnvelope_pos {α : ℝ} (hα : 0 < α) : 0 < cubicPolarEnvelope α := by - rw [cubicPolarEnvelope_compact hα.le] - exact div_pos (mul_pos hα (distillN_pos hα.le)) (by positivity) - -lemma distillKappa_pos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 ≤ α) (hαm : 2 * α < m) : - 0 < distillKappa m α := by - have hs : 0 < m ^ 2 - 1 := by nlinarith - have hq : 0 < m - 2 * α := by linarith - have hr := distillRatio_pos hα - unfold distillKappa - positivity - -lemma distillT0_pos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 ≤ α) (hαm : 2 * α < m) : - 0 < distillT0 m α := by - have hk := distillKappa_pos hm hα hαm - have hb := distillNode_lt_one (by linarith : 0 < m) hα (by linarith) - have hm1 : 0 < m - 1 := by linarith - unfold distillT0 - positivity - -lemma distillT1_pos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 ≤ α) (hαm : 2 * α < m) : - 0 < distillT1 m α := by - have hk := distillKappa_pos hm hα hαm - have hb := distillNode_pos (by linarith : 0 < m) hα - unfold distillT1 - positivity - -lemma distillT2_pos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : - 0 < distillT2 m α := by - have hk := distillKappa_pos hm hα.le hαm - have he := cubicPolarEnvelope_pos hα - unfold distillT2 - positivity - -lemma distillRatio_continuousOn : ContinuousOn distillRatio (Set.Ici 0) := by - unfold distillRatio - have hd : ∀ α ∈ Set.Ici (0 : ℝ), α + 3 ≠ 0 := by - intro α hα - have : 0 ≤ α := hα - linarith - have hu : ContinuousOn (fun α : ℝ ↦ α / (α + 3)) (Set.Ici 0) := - continuousOn_id.div (continuousOn_id.add continuousOn_const) hd - fun_prop - -lemma cubicPolarEnvelope_continuousOn : ContinuousOn cubicPolarEnvelope (Set.Ici 0) := by - unfold cubicPolarEnvelope - have hd : ∀ α ∈ Set.Ici (0 : ℝ), α + 3 ≠ 0 := by - intro α hα - have : 0 ≤ α := hα - linarith - have hu : ContinuousOn (fun α : ℝ ↦ α / (α + 3)) (Set.Ici 0) := - continuousOn_id.div (continuousOn_id.add continuousOn_const) hd - fun_prop - -lemma distillKappa_continuousOn (m : ℝ) : - ContinuousOn (distillKappa m) (Set.Ici 0) := by - unfold distillKappa - exact (continuousOn_const.mul distillRatio_continuousOn).mul (by fun_prop) - -lemma distillNode_continuousOn (m : ℝ) : ContinuousOn (distillNode m) (Set.Ici 0) := by - unfold distillNode - exact (continuousOn_const.add - (continuousOn_const.mul cubicPolarEnvelope_continuousOn)).add (by fun_prop) - -lemma distillT0_continuousOn {m : ℝ} (hm : 5 ≤ m) : - ContinuousOn (distillT0 m) (Set.Icc 0 (m / 2)) := by - have hk := (distillKappa_continuousOn m).mono (Set.Icc_subset_Ici_self (a := m / 2)) - have hb := (distillNode_continuousOn m).mono (Set.Icc_subset_Ici_self (a := m / 2)) - unfold distillT0 - apply hk.mul - apply continuousOn_const.div - · exact continuousOn_const.mul ((continuousOn_const.sub hb).pow 4) - · intro α hα - have hm1 : 0 < m - 1 := by linarith - have hn := distillNode_lt_one (by linarith : 0 < m) hα.1 hα.2 - positivity - -lemma distillT1_continuousOn {m : ℝ} (hm : 5 ≤ m) : - ContinuousOn (distillT1 m) (Set.Icc 0 (m / 2)) := by - have hk := (distillKappa_continuousOn m).mono (Set.Icc_subset_Ici_self (a := m / 2)) - have hb := (distillNode_continuousOn m).mono (Set.Icc_subset_Ici_self (a := m / 2)) - unfold distillT1 - exact (continuousOn_const.mul hk).mul (hb.rpow_const (fun _ _ ↦ Or.inr (by linarith))) - -lemma distillT2_continuousOn {m : ℝ} (hm : 5 ≤ m) : - ContinuousOn (distillT2 m) (Set.Icc 0 (m / 2)) := by - have hk := (distillKappa_continuousOn m).mono (Set.Icc_subset_Ici_self (a := m / 2)) - have he := cubicPolarEnvelope_continuousOn.mono (Set.Icc_subset_Ici_self (a := m / 2)) - unfold distillT2 - exact (continuousOn_const.mul hk).mul (he.rpow_const (fun _ _ ↦ Or.inr (by linarith))) - -/- The derivative calculation is factored through small logarithmic-slope -identities. No expanded degree-seven polynomial enters rational simplification. -/ -private lemma hasDerivAt_distillU {α : ℝ} (hα : 0 ≤ α) : - HasDerivAt (fun x : ℝ ↦ x / (x + 3)) (3 / (α + 3) ^ 2) α := by - have ht : α + 3 ≠ 0 := by linarith - convert! (hasDerivAt_id α).div ((hasDerivAt_id α).add_const 3) ht using 1 - simp only [id_eq] - ring - -lemma hasDerivAt_distillRatio {α : ℝ} (hα : 0 ≤ α) : - HasDerivAt distillRatio - (distillRatio α * ((58 * α + 180) / distillN α - 3 / (α + 3))) α := by - have hu := hasDerivAt_distillU hα - have ht : α + 3 ≠ 0 := by linarith - have hn := (distillN_pos hα).ne' - convert! ((hu.const_sub 1).mul ((hu.pow 2 |>.div_const 30).const_sub 1)).div_const 3 - using 1 - · rw [distillRatio_compact hα] - norm_num only [Pi.pow_apply, Nat.reduceSub, Nat.cast_ofNat, pow_one, mul_one] - field_simp [ht, hn] - unfold distillN - ring - -lemma hasDerivAt_cubicPolarEnvelope {α : ℝ} (hα : 0 ≤ α) : - HasDerivAt cubicPolarEnvelope (distillL α / (30 * (α + 3) ^ 4)) α := by - have hu := hasDerivAt_distillU hα - have ht : α + 3 ≠ 0 := by linarith - convert! hu.sub ((hu.pow 3).div_const 30) using 1 - · unfold distillL - norm_num only [Nat.reduceSub, Nat.cast_ofNat] - field_simp [ht] - ring - -lemma hasDerivAt_distillNode {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : - HasDerivAt (distillNode m) (distillRp m α / (50 * m * (α + 3) ^ 4)) α := by - have he := hasDerivAt_cubicPolarEnvelope hα - have ht : α + 3 ≠ 0 := by linarith - convert! ((he.const_mul (3 / 5)).const_add (4 / 25)).add - (((hasDerivAt_id α).const_mul 12).div_const (25 * m)) using 1 - · field_simp [ht, hm.ne'] - unfold distillRp distillB distillL - ring - -lemma hasDerivAt_distillKappa {m α : ℝ} (hα : 0 ≤ α) (hαm : 2 * α < m) : - HasDerivAt (distillKappa m) - (distillKappa m α * (distillK m α / ((α + 3) * (m - 2 * α) * distillN α))) α := by - have hr := hasDerivAt_distillRatio hα - have ht : α + 3 ≠ 0 := by linarith - have hq : m - 2 * α ≠ 0 := by linarith - have hn := (distillN_pos hα).ne' - convert! (hr.const_mul ((m ^ 2 - 1) / (4 * m))).mul - ((((hasDerivAt_id α).const_mul 2).const_sub m).pow 2) using 1 - · unfold distillKappa distillK - norm_num only [Pi.pow_apply, id_eq, Nat.reduceSub, Nat.cast_ofNat, pow_one, mul_one] - field_simp [ht, hq, hn] - ring - -private lemma hasDerivAt_mul_slope {f g : ℝ → ℝ} {α u v : ℝ} - (hf : HasDerivAt f (f α * u) α) (hg : HasDerivAt g (g α * v) α) : - HasDerivAt (fun x ↦ f x * g x) (f α * g α * (u + v)) α := by - convert! hf.mul hg using 1 - ring - -private lemma hasDerivAt_rpow_slope {f : ℝ → ℝ} {α u p : ℝ} - (hf : HasDerivAt f (f α * u) α) (hpos : 0 < f α) : - HasDerivAt (fun x ↦ f x ^ p) (f α ^ p * (p * u)) α := by - convert! hf.rpow_const (Or.inl hpos.ne') using 1 - rw [Real.rpow_sub hpos, Real.rpow_one] - field_simp - -private lemma hasDerivAt_distillNode_slope {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : - HasDerivAt (distillNode m) - (distillNode m α * (distillRp m α / ((α + 3) * distillB m α))) α := by - convert! hasDerivAt_distillNode hm hα using 1 - rw [distillNode_compact hm hα] - have ht : α + 3 ≠ 0 := by linarith - have hb := (distillB_pos hm hα).ne' - field_simp [ht, hb, hm.ne'] - -private lemma hasDerivAt_cubicPolarEnvelope_slope {α : ℝ} (hα : 0 < α) : - HasDerivAt cubicPolarEnvelope - (cubicPolarEnvelope α * (distillL α / (α * (α + 3) * distillN α))) α := by - convert! hasDerivAt_cubicPolarEnvelope hα.le using 1 - rw [cubicPolarEnvelope_compact hα.le] - have ht : α + 3 ≠ 0 := by linarith - have hn := (distillN_pos hα.le).ne' - field_simp [ht, hn, hα.ne'] - -lemma hasDerivAt_distillT1 {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : - HasDerivAt (distillT1 m) - (distillT1 m α * (-distillCritical1 m α / - (2 * (α + 3) * (m - 2 * α) * distillN α * distillB m α))) α := by - have hm0 : 0 < m := by linarith - have hk := hasDerivAt_distillKappa hα.le hαm - have hb := hasDerivAt_rpow_slope (p := (m - 3) / 2) - (hasDerivAt_distillNode_slope hm0 hα.le) (distillNode_pos hm0 hα.le) - have hs : distillK m α / ((α + 3) * (m - 2 * α) * distillN α) + - (m - 3) / 2 * (distillRp m α / ((α + 3) * distillB m α)) = - -distillCritical1 m α / - (2 * (α + 3) * (m - 2 * α) * distillN α * distillB m α) := by - rw [distillCritical1_eq] - have ht : α + 3 ≠ 0 := by linarith - have hq : m - 2 * α ≠ 0 := by linarith - have hn := (distillN_pos hα.le).ne' - have hB := (distillB_pos hm0 hα.le).ne' - generalize hq' : m - 2 * α = q at hq ⊢ - field_simp [ht, hq, hn, hB] - ring - have hd := (hasDerivAt_mul_slope hk hb).const_mul (259 / 3125) - rw [hs] at hd - unfold distillT1 - simpa only [mul_assoc] using hd - -lemma hasDerivAt_distillT2 {m α : ℝ} (_hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : - HasDerivAt (distillT2 m) - (distillT2 m α * (-distillCritical2 m α / - (2 * α * (α + 3) * (m - 2 * α) * distillN α))) α := by - have hk := hasDerivAt_distillKappa hα.le hαm - have he := hasDerivAt_rpow_slope (p := (m - 3) / 2) - (hasDerivAt_cubicPolarEnvelope_slope hα) (cubicPolarEnvelope_pos hα) - have hs : distillK m α / ((α + 3) * (m - 2 * α) * distillN α) + - (m - 3) / 2 * (distillL α / (α * (α + 3) * distillN α)) = - -distillCritical2 m α / - (2 * α * (α + 3) * (m - 2 * α) * distillN α) := by - rw [distillCritical2_eq] - have ht : α + 3 ≠ 0 := by linarith - have hq : m - 2 * α ≠ 0 := by linarith - have hn := (distillN_pos hα.le).ne' - generalize hq' : m - 2 * α = q at hq ⊢ - field_simp [ht, hq, hn, hα.ne'] - ring - have hd := (hasDerivAt_mul_slope hk he).const_mul (421 / 3125) - rw [hs] at hd - unfold distillT2 - simpa only [mul_assoc] using hd - -private lemma hasDerivAt_reciprocal_quartic {f : ℝ → ℝ} {α d A C : ℝ} - (hf : HasDerivAt f d α) (hC : C ≠ 0) (hb : 1 - f α ≠ 0) : - HasDerivAt (fun x ↦ A / (C * (1 - f x) ^ 4)) - ((A / (C * (1 - f α) ^ 4)) * (4 * d / (1 - f α))) α := by - convert! (hasDerivAt_const α A).div (((hf.const_sub 1).pow 4).const_mul C) - (mul_ne_zero hC (pow_ne_zero 4 hb)) using 1 - norm_num only [Pi.pow_apply, Nat.reduceSub, Nat.cast_ofNat] - field_simp [hC, hb] - ring - -lemma hasDerivAt_distillT0 {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : - HasDerivAt (distillT0 m) - (distillT0 m α * (distillCritical0 m α / - ((α + 3) * (m - 2 * α) * distillN α * distillD m α))) α := by - have hm0 : 0 < m := by linarith - have ht : α + 3 ≠ 0 := by linarith - have hq : m - 2 * α ≠ 0 := by linarith - have hn := (distillN_pos hα.le).ne' - have hD := (distillD_pos hm0 hα.le (by linarith)).ne' - have hb : 1 - distillNode m α ≠ 0 := - (sub_pos.mpr (distillNode_lt_one hm0 hα.le (by linarith))).ne' - have hC : (m - 1) * (m + 1) * (m + 3) * (m + 5) ≠ 0 := by - have hm1 : 0 < m - 1 := by linarith - positivity - have hfrac := hasDerivAt_reciprocal_quartic (A := 96 * (3 / 5) ^ 4) - (hasDerivAt_distillNode hm0 hα.le) hC hb - have hs₀ : 4 * (distillRp m α / (50 * m * (α + 3) ^ 4)) / - (1 - distillNode m α) = 4 * distillRp m α / ((α + 3) * distillD m α) := by - rw [distillD_eq hm0 hα.le] - field_simp [ht, hb, hm0.ne'] - rw [hs₀] at hfrac - have hs : distillK m α / ((α + 3) * (m - 2 * α) * distillN α) + - 4 * distillRp m α / ((α + 3) * distillD m α) = - distillCritical0 m α / ((α + 3) * (m - 2 * α) * distillN α * distillD m α) := by - rw [distillCritical0_eq] - generalize hq' : m - 2 * α = q at hq ⊢ - field_simp [ht, hq, hn, hD] - have hd := hasDerivAt_mul_slope (hasDerivAt_distillKappa hα.le hαm) hfrac - rw [hs] at hd - exact hd - -lemma distillT0_denom_pos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : - 0 < (α + 3) * (m - 2 * α) * distillN α * distillD m α := by - have hq : 0 < m - 2 * α := by linarith - have hn := distillN_pos hα.le - have hd := distillD_pos (by linarith : 0 < m) hα.le (by linarith) - positivity - -lemma distillT1_denom_pos {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : - 0 < 2 * (α + 3) * (m - 2 * α) * distillN α * distillB m α := by - have hq : 0 < m - 2 * α := by linarith - have hn := distillN_pos hα.le - have hb := distillB_pos (by linarith : 0 < m) hα.le - positivity - -lemma distillT2_denom_pos {m α : ℝ} (_hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : - 0 < 2 * α * (α + 3) * (m - 2 * α) * distillN α := by - have hq : 0 < m - 2 * α := by linarith - have hn := distillN_pos hα.le - positivity - -lemma distillT0_deriv_nonneg_iff {m α : ℝ} (hm : 5 ≤ m) - (hα : 0 < α) (hαm : 2 * α < m) : - 0 ≤ deriv (distillT0 m) α ↔ 0 ≤ distillCritical0 m α := by - rw [(hasDerivAt_distillT0 hm hα hαm).deriv] - have ht := distillT0_pos hm hα.le hαm - have hd := distillT0_denom_pos hm hα hαm - rw [mul_nonneg_iff_of_pos_left ht, le_div_iff₀ hd, zero_mul] - -lemma distillT0_deriv_nonneg {m α : ℝ} (hm : 5 ≤ m) - (hα : 0 < α) (hαm : 2 * α < m) (hp : 0 ≤ distillCritical0 m α) : - 0 ≤ deriv (distillT0 m) α := - (distillT0_deriv_nonneg_iff hm hα hαm).mpr hp - -lemma distillT0_deriv_nonpos_iff {m α : ℝ} (hm : 5 ≤ m) - (hα : 0 < α) (hαm : 2 * α < m) : - deriv (distillT0 m) α ≤ 0 ↔ distillCritical0 m α ≤ 0 := by - rw [(hasDerivAt_distillT0 hm hα hαm).deriv] - have ht := distillT0_pos hm hα.le hαm - have hd := distillT0_denom_pos hm hα hαm - nth_rw 1 [← mul_zero (distillT0 m α)] - rw [mul_le_mul_iff_right₀ ht, div_le_iff₀ hd, zero_mul] - -lemma distillT0_deriv_nonpos {m α : ℝ} (hm : 5 ≤ m) - (hα : 0 < α) (hαm : 2 * α < m) (hp : distillCritical0 m α ≤ 0) : - deriv (distillT0 m) α ≤ 0 := - (distillT0_deriv_nonpos_iff hm hα hαm).mpr hp - -lemma distillT1_deriv_nonneg_iff {m α : ℝ} (hm : 5 ≤ m) - (hα : 0 < α) (hαm : 2 * α < m) : - 0 ≤ deriv (distillT1 m) α ↔ distillCritical1 m α ≤ 0 := by - rw [(hasDerivAt_distillT1 hm hα hαm).deriv] - have ht := distillT1_pos hm hα.le hαm - have hd := distillT1_denom_pos hm hα hαm - rw [mul_nonneg_iff_of_pos_left ht, le_div_iff₀ hd, zero_mul] - exact neg_nonneg - -lemma distillT1_deriv_nonneg {m α : ℝ} (hm : 5 ≤ m) - (hα : 0 < α) (hαm : 2 * α < m) (hp : distillCritical1 m α ≤ 0) : - 0 ≤ deriv (distillT1 m) α := - (distillT1_deriv_nonneg_iff hm hα hαm).mpr hp - -lemma distillT1_deriv_nonpos_iff {m α : ℝ} (hm : 5 ≤ m) - (hα : 0 < α) (hαm : 2 * α < m) : - deriv (distillT1 m) α ≤ 0 ↔ 0 ≤ distillCritical1 m α := by - rw [(hasDerivAt_distillT1 hm hα hαm).deriv] - have ht := distillT1_pos hm hα.le hαm - have hd := distillT1_denom_pos hm hα hαm - nth_rw 1 [← mul_zero (distillT1 m α)] - rw [mul_le_mul_iff_right₀ ht, div_le_iff₀ hd, zero_mul, neg_nonpos] - -lemma distillT1_deriv_nonpos {m α : ℝ} (hm : 5 ≤ m) - (hα : 0 < α) (hαm : 2 * α < m) (hp : 0 ≤ distillCritical1 m α) : - deriv (distillT1 m) α ≤ 0 := - (distillT1_deriv_nonpos_iff hm hα hαm).mpr hp - -lemma distillT2_deriv_nonneg_iff {m α : ℝ} (hm : 5 ≤ m) - (hα : 0 < α) (hαm : 2 * α < m) : - 0 ≤ deriv (distillT2 m) α ↔ distillCritical2 m α ≤ 0 := by - rw [(hasDerivAt_distillT2 hm hα hαm).deriv] - have ht := distillT2_pos hm hα hαm - have hd := distillT2_denom_pos hm hα hαm - rw [mul_nonneg_iff_of_pos_left ht, le_div_iff₀ hd, zero_mul] - exact neg_nonneg - -lemma distillT2_deriv_nonneg {m α : ℝ} (hm : 5 ≤ m) - (hα : 0 < α) (hαm : 2 * α < m) (hp : distillCritical2 m α ≤ 0) : - 0 ≤ deriv (distillT2 m) α := - (distillT2_deriv_nonneg_iff hm hα hαm).mpr hp - -lemma distillT2_deriv_nonpos_iff {m α : ℝ} (hm : 5 ≤ m) - (hα : 0 < α) (hαm : 2 * α < m) : - deriv (distillT2 m) α ≤ 0 ↔ 0 ≤ distillCritical2 m α := by - rw [(hasDerivAt_distillT2 hm hα hαm).deriv] - have ht := distillT2_pos hm hα hαm - have hd := distillT2_denom_pos hm hα hαm - nth_rw 1 [← mul_zero (distillT2 m α)] - rw [mul_le_mul_iff_right₀ ht, div_le_iff₀ hd, zero_mul, neg_nonpos] - -lemma distillT2_deriv_nonpos {m α : ℝ} (hm : 5 ≤ m) - (hα : 0 < α) (hαm : 2 * α < m) (hp : 0 ≤ distillCritical2 m α) : - deriv (distillT2 m) α ≤ 0 := - (distillT2_deriv_nonpos_iff hm hα hαm).mpr hp - -end Sendov diff --git a/Sendov/Common/DistillationCriticalFinite.lean b/Sendov/Common/DistillationCriticalFinite.lean deleted file mode 100644 index a7df625..0000000 --- a/Sendov/Common/DistillationCriticalFinite.lean +++ /dev/null @@ -1,130 +0,0 @@ -import Sendov.Common.DistillationCritical -import Sendov.Common.DistillationMajorant -import Sendov.Common.BernsteinCert -import Sendov.Common.BernsteinRing -import Mathlib.Analysis.Calculus.Deriv.MeanValue - -/-! -# Finite critical-bracket bounds - -Critical polynomials and fixed budgets from Senjian An, *Proof Distillation for -Sendov's Conjecture*, e8ae601491ec171ab4f7f8456113dd6a047aa85d (paper CC BY 4.0). -New Lean proofs, Apache-2.0 as the baseline. The interval outside the bracket is -controlled analytically; only the bracket uses the mixed factor estimate. --/ -namespace Sendov - -/-- Two monotone flanks and a bounded central bracket cover the exact closed domain. -Degenerate flanks are allowed: their derivative hypotheses have empty open domains. -/ -lemma distillPeak_le {f : ℝ → ℝ} {d l r b x : ℝ} - (hl : 0 ≤ l) (hlr : l ≤ r) (hr : r ≤ d) - (hc : ContinuousOn f (Set.Icc 0 d)) - (hd : ∀ x ∈ Set.Ioo 0 d, DifferentiableAt ℝ f x) - (hp : ∀ x ∈ Set.Ioo 0 l, 0 ≤ deriv f x) - (hn : ∀ x ∈ Set.Ioo r d, deriv f x ≤ 0) - (hb : ∀ x ∈ Set.Icc l r, f x ≤ b) (hx : x ∈ Set.Icc 0 d) : f x ≤ b := by - have hld : l ≤ d := hlr.trans hr - have hr0 : 0 ≤ r := hl.trans hlr - have hleft : MonotoneOn f (Set.Icc 0 l) := by - apply monotoneOn_of_deriv_nonneg (convex_Icc _ _) - (hc.mono (Set.Icc_subset_Icc le_rfl hld)) - · rw [interior_Icc] - intro y hy - exact (hd y ⟨hy.1, hy.2.trans_le hld⟩).differentiableWithinAt - · simpa only [interior_Icc] using hp - have hright : AntitoneOn f (Set.Icc r d) := by - apply antitoneOn_of_deriv_nonpos (convex_Icc _ _) - (hc.mono (Set.Icc_subset_Icc hr0 le_rfl)) - · rw [interior_Icc] - intro y hy - exact (hd y ⟨hr0.trans_lt hy.1, hy.2⟩).differentiableWithinAt - · simpa only [interior_Icc] using hn - by_cases hxl : x ≤ l - · exact (hleft ⟨hx.1, hxl⟩ ⟨hl, le_rfl⟩ hxl).trans (hb l ⟨le_rfl, hlr⟩) - by_cases hxr : x ≤ r - · exact hb x ⟨le_of_not_ge hxl, hxr⟩ - · have hrx : r ≤ x := le_of_not_ge hxr - exact (hright ⟨le_rfl, hr⟩ ⟨hrx, hx.2⟩ hrx).trans (hb r ⟨hlr, le_rfl⟩) - -/-- Squaring half-integer powers is exact, also at zero. -/ -lemma distillRpow_half_sq {b : ℝ} (hb : 0 ≤ b) (n : ℕ) : - (b ^ ((n : ℝ) / 2)) ^ 2 = b ^ n := by - rw [← Real.rpow_natCast, ← Real.rpow_mul hb] - norm_num - -lemma distillMulRpow_le_of_sq {a b c m : ℝ} (n : ℕ) - (hb : 0 ≤ b) (hc : 0 ≤ c) (hn : (m - 3) / 2 = (n : ℝ) / 2) - (hsq : a ^ 2 * b ^ n ≤ c ^ 2) : a * b ^ ((m - 3) / 2) ≤ c := by - have hid : (a * b ^ ((m - 3) / 2)) ^ 2 = a ^ 2 * b ^ n := by - rw [mul_pow, hn, distillRpow_half_sq hb] - exact le_of_sq_le_sq (by rwa [hid]) hc - -/-- Component 0: exact flanks from the critical derivative API and one mixed bracket. -/ -lemma distillT0_le_of_critical {m d l r b α : ℝ} - (hm : 5 ≤ m) (hl : 0 ≤ l) (hlr : l ≤ r) (hr : r ≤ d) (hdm : d ≤ m / 2) - (hp : ∀ x ∈ Set.Ioo 0 l, 0 ≤ distillCritical0 m x) - (hq : ∀ x ∈ Set.Ioo r d, 0 ≤ -distillCritical0 m x) - (hb : distillKappa m l * (96 * (3 / 5) ^ 4 / - ((m - 1) * (m + 1) * (m + 3) * (m + 5) * (1 - distillNode m r) ^ 4)) ≤ b) - (hα : α ∈ Set.Icc 0 d) : distillT0 m α ≤ b := by - apply distillPeak_le hl hlr hr - ((distillT0_continuousOn hm).mono (Set.Icc_subset_Icc le_rfl hdm)) - (fun x hx ↦ (hasDerivAt_distillT0 hm hx.1 (by have := hx.2; linarith)).differentiableAt) - ?_ ?_ ?_ hα - · intro x hx - apply distillT0_deriv_nonneg hm hx.1 (by have := hx.2; linarith) - exact hp x hx - · intro x hx - apply distillT0_deriv_nonpos hm (by have := hx.1; linarith) - (by have := hx.2; linarith) - exact neg_nonneg.mp (hq x hx) - · intro x hx - exact (distillT0_mixed hm hl hx.1 hx.2 (hr.trans hdm)).trans hb - -/-- Component 1: exact flanks from the critical derivative API and one mixed bracket. -/ -lemma distillT1_le_of_critical {m d l r b α : ℝ} - (n : ℕ) (hb0 : 0 ≤ b) (hn : (m - 3) / 2 = (n : ℝ) / 2) - (hm : 5 ≤ m) (hl : 0 ≤ l) (hlr : l ≤ r) (hr : r ≤ d) (hdm : d ≤ m / 2) - (hp : ∀ x ∈ Set.Ioo 0 l, 0 ≤ -distillCritical1 m x) - (hq : ∀ x ∈ Set.Ioo r d, 0 ≤ distillCritical1 m x) - (hb : ((259 / 3125) * distillKappa m l) ^ 2 * (distillNode m r) ^ n ≤ b ^ 2) - (hα : α ∈ Set.Icc 0 d) : distillT1 m α ≤ b := by - apply distillPeak_le hl hlr hr - ((distillT1_continuousOn hm).mono (Set.Icc_subset_Icc le_rfl hdm)) - (fun x hx ↦ (hasDerivAt_distillT1 hm hx.1 (by have := hx.2; linarith)).differentiableAt) - ?_ ?_ ?_ hα - · intro x hx - apply distillT1_deriv_nonneg hm hx.1 (by have := hx.2; linarith) - exact neg_nonneg.mp (hp x hx) - · intro x hx - apply distillT1_deriv_nonpos hm (by have := hx.1; linarith) - (by have := hx.2; linarith) - exact hq x hx - · intro x hx - apply (distillT1_mixed hm hl hx.1 hx.2 (hr.trans hdm)).trans - exact distillMulRpow_le_of_sq n (distillNode_pos (by linarith) (hl.trans hlr)).le hb0 hn hb - -/-- Component 2: exact flanks from the critical derivative API and one mixed bracket. -/ -lemma distillT2_le_of_critical {m d l r b α : ℝ} - (n : ℕ) (hb0 : 0 ≤ b) (hn : (m - 3) / 2 = (n : ℝ) / 2) - (hm : 5 ≤ m) (hl : 0 ≤ l) (hlr : l ≤ r) (hr : r ≤ d) (hdm : d ≤ m / 2) - (hp : ∀ x ∈ Set.Ioo 0 l, 0 ≤ -distillCritical2 m x) - (hq : ∀ x ∈ Set.Ioo r d, 0 ≤ distillCritical2 m x) - (hb : ((421 / 3125) * distillKappa m l) ^ 2 * (cubicPolarEnvelope r) ^ n ≤ b ^ 2) - (hα : α ∈ Set.Icc 0 d) : distillT2 m α ≤ b := by - apply distillPeak_le hl hlr hr - ((distillT2_continuousOn hm).mono (Set.Icc_subset_Icc le_rfl hdm)) - (fun x hx ↦ (hasDerivAt_distillT2 hm hx.1 (by have := hx.2; linarith)).differentiableAt) - ?_ ?_ ?_ hα - · intro x hx - apply distillT2_deriv_nonneg hm hx.1 (by have := hx.2; linarith) - exact neg_nonneg.mp (hp x hx) - · intro x hx - apply distillT2_deriv_nonpos hm (by have := hx.1; linarith) - (by have := hx.2; linarith) - exact hq x hx - · intro x hx - apply (distillT2_mixed hm hl hx.1 hx.2 (hr.trans hdm)).trans - exact distillMulRpow_le_of_sq n (cubicPolarEnvelope_nonneg (hl.trans hlr)) hb0 hn hb - -end Sendov diff --git a/Sendov/Common/DistillationFactors.lean b/Sendov/Common/DistillationFactors.lean index c8b593f..f67094a 100644 --- a/Sendov/Common/DistillationFactors.lean +++ b/Sendov/Common/DistillationFactors.lean @@ -198,24 +198,4 @@ lemma distillT2_mixed {m l α r : ℝ} (hm : 5 ≤ m) (hl : 0 ≤ l) (by norm_num)) hb (Real.rpow_nonneg (cubicPolarEnvelope_nonneg hα0) _) (mul_nonneg (by norm_num) (distillKappa_nonneg hm hl)) -/-- Algebraic assembly for a separately proved two-chord integral bound. -No integral estimate or polar implication is asserted by this interface. -/ -lemma distillScalar_le_components {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) - (hJ : (∫ t in (0 : ℝ)..1, - t ^ 3 * polarKernel m α (cubicPolarEnvelope α) t ^ ((m - 3) / 2)) ≤ - 96 * (3 / 5) ^ 4 / - ((m - 1) * (m + 1) * (m + 3) * (m + 5) * (1 - distillNode m α) ^ 4) + - (259 / 3125) * distillNode m α ^ ((m - 3) / 2) + - (421 / 3125) * cubicPolarEnvelope α ^ ((m - 3) / 2)) : - scalarObstruction m α (cubicPolarEnvelope α) ≤ - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α := by - have hE := distillElementary_le_budget (by linarith : 0 < m) hα - have hK := mul_le_mul_of_nonneg_left hJ (distillKappa_nonneg hm hα.le) - unfold scalarObstruction - rw [← distillKappa_eq hα] - unfold distillT0 distillT1 distillT2 - calc - _ ≤ distillEBudget m + distillKappa m α * _ := add_le_add hE hK - _ = _ := by ring - end Sendov diff --git a/Sendov/Common/DistillationFinite.lean b/Sendov/Common/DistillationFinite.lean deleted file mode 100644 index d0870ff..0000000 --- a/Sendov/Common/DistillationFinite.lean +++ /dev/null @@ -1,81 +0,0 @@ -import Sendov.DistillationFinite.Rows5_12 -import Sendov.DistillationFinite.Rows13_20 -import Sendov.DistillationFinite.Rows21_28 -import Sendov.DistillationFinite.Rows29_36 -import Sendov.DistillationFinite.Rows37_44 -import Sendov.DistillationFinite.Rows45_52 -import Sendov.DistillationFinite.Rows53_55 -import Sendov.DistillationFinite.Rows61_61 -import Sendov.LargeDegree.DistillationTailBound - -/-! Exact finite-domain critical-bracket closure. Fixed original paper budgets; -see DistillationCriticalFinite for attribution. No sampled truth or global T grid. -/ -namespace Sendov - -theorem distillFinite_components {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) - {α : ℝ} (hα : 0 ≤ α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := by - by_cases hinterval : 55 ≤ m - · exact distillComponents_interval_55_61 - ⟨by exact_mod_cast hinterval, by exact_mod_cast (show m ≤ 61 by omega)⟩ hα h17 - have hm54 : m ≤ 54 := by omega - interval_cases m - · exact (distillFinite_5 α hα (by linarith)).trans_lt distillFiniteBound_5 - · exact (distillFinite_6 α hα (by linarith)).trans_lt distillFiniteBound_6 - · exact (distillFinite_7 α hα (by linarith)).trans_lt distillFiniteBound_7 - · exact (distillFinite_8 α hα (by linarith)).trans_lt distillFiniteBound_8 - · exact (distillFinite_9 α hα (by linarith)).trans_lt distillFiniteBound_9 - · exact (distillFinite_10 α hα (by linarith)).trans_lt distillFiniteBound_10 - · exact (distillFinite_11 α hα (by linarith)).trans_lt distillFiniteBound_11 - · exact (distillFinite_12 α hα (by linarith)).trans_lt distillFiniteBound_12 - · exact (distillFinite_13 α hα (by linarith)).trans_lt distillFiniteBound_13 - · exact (distillFinite_14 α hα (by linarith)).trans_lt distillFiniteBound_14 - · exact (distillFinite_15 α hα (by linarith)).trans_lt distillFiniteBound_15 - · exact (distillFinite_16 α hα (by linarith)).trans_lt distillFiniteBound_16 - · exact (distillFinite_17 α hα (by linarith)).trans_lt distillFiniteBound_17 - · exact (distillFinite_18 α hα (by linarith)).trans_lt distillFiniteBound_18 - · exact (distillFinite_19 α hα (by linarith)).trans_lt distillFiniteBound_19 - · exact (distillFinite_20 α hα (by linarith)).trans_lt distillFiniteBound_20 - · exact (distillFinite_21 α hα (by linarith)).trans_lt distillFiniteBound_21 - · exact (distillFinite_22 α hα (by linarith)).trans_lt distillFiniteBound_22 - · exact (distillFinite_23 α hα (by linarith)).trans_lt distillFiniteBound_23 - · exact (distillFinite_24 α hα (by linarith)).trans_lt distillFiniteBound_24 - · exact (distillFinite_25 α hα (by linarith)).trans_lt distillFiniteBound_25 - · exact (distillFinite_26 α hα (by linarith)).trans_lt distillFiniteBound_26 - · exact (distillFinite_27 α hα (by linarith)).trans_lt distillFiniteBound_27 - · exact (distillFinite_28 α hα (by linarith)).trans_lt distillFiniteBound_28 - · exact (distillFinite_29 α hα (by linarith)).trans_lt distillFiniteBound_29 - · exact (distillFinite_30 α hα (by linarith)).trans_lt distillFiniteBound_30 - · exact (distillFinite_31 α hα (by linarith)).trans_lt distillFiniteBound_31 - · exact (distillFinite_32 α hα (by linarith)).trans_lt distillFiniteBound_32 - · exact (distillFinite_33 α hα (by linarith)).trans_lt distillFiniteBound_33 - · exact (distillFinite_34 α hα h17).trans_lt distillFiniteBound_34 - · exact (distillFinite_35 α hα h17).trans_lt distillFiniteBound_35 - · exact (distillFinite_36 α hα h17).trans_lt distillFiniteBound_36 - · exact (distillFinite_37 α hα h17).trans_lt distillFiniteBound_37 - · exact (distillFinite_38 α hα h17).trans_lt distillFiniteBound_38 - · exact (distillFinite_39 α hα h17).trans_lt distillFiniteBound_39 - · exact (distillFinite_40 α hα h17).trans_lt distillFiniteBound_40 - · exact (distillFinite_41 α hα h17).trans_lt distillFiniteBound_41 - · exact (distillFinite_42 α hα h17).trans_lt distillFiniteBound_42 - · exact (distillFinite_43 α hα h17).trans_lt distillFiniteBound_43 - · exact (distillFinite_44 α hα h17).trans_lt distillFiniteBound_44 - · exact (distillFinite_45 α hα h17).trans_lt distillFiniteBound_45 - · exact (distillFinite_46 α hα h17).trans_lt distillFiniteBound_46 - · exact (distillFinite_47 α hα h17).trans_lt distillFiniteBound_47 - · exact (distillFinite_48 α hα h17).trans_lt distillFiniteBound_48 - · exact (distillFinite_49 α hα h17).trans_lt distillFiniteBound_49 - · exact (distillFinite_50 α hα h17).trans_lt distillFiniteBound_50 - · exact (distillFinite_51 α hα h17).trans_lt distillFiniteBound_51 - · exact (distillFinite_52 α hα h17).trans_lt distillFiniteBound_52 - · exact (distillFinite_53 α hα h17).trans_lt distillFiniteBound_53 - · exact (distillFinite_54 α hα h17).trans_lt distillFiniteBound_54 - -theorem distillFinite_scalar {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) - {α : ℝ} (hα : 0 < α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : - scalarObstruction m α (cubicPolarEnvelope α) < 199 / 200 := by - have hmR : (5 : ℝ) ≤ m := by exact_mod_cast hm - exact (distillScalar_le_majorant hmR hα (by linarith)).trans_lt - (distillFinite_components hm hm60 hα.le hαm h17) - -end Sendov diff --git a/Sendov/Common/DistillationMajorant.lean b/Sendov/Common/DistillationMajorant.lean deleted file mode 100644 index 1a73379..0000000 --- a/Sendov/Common/DistillationMajorant.lean +++ /dev/null @@ -1,30 +0,0 @@ -import Sendov.Common.DistillationFactors -import Sendov.Common.TwoChord - -/-! -# The proved scalar majorant - -This joins the two-chord integral estimate to the regularized factors from -Senjian An's *Proof Distillation for Sendov's Conjecture*, revision -`e8ae601491ec171ab4f7f8456113dd6a047aa85d`, Section 4. -Mathematical source: https://github.com/SJanPerth/Sendov-Proof-Distillation -(CC BY 4.0; https://creativecommons.org/licenses/by/4.0/). -This is a new Lean formulation. The integral bound is proved, not an assumption. -The remaining finite and tail component bounds are separate theorems. --/ - -namespace Sendov - -/-- The complete two-chord upper bound for the cubic scalar obstruction. -Positive alpha is intentional: the raw scalar definition at zero is not its -continuous extension. No extra integrability or geometric feasibility is needed. -/ -theorem distillScalar_le_majorant {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) - (hαm : 2 * α ≤ m) : - scalarObstruction m α (cubicPolarEnvelope α) ≤ - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α := by - apply distillScalar_le_components hm hα - simpa only [distillNode_eq] using - integral_polarKernel_two_chord hm hα.le hαm - (cubicPolarEnvelope_nonneg hα.le) (cubicPolarEnvelope_lt_one hα.le) - -end Sendov diff --git a/Sendov/Common/DistillationMiddleAlpha.lean b/Sendov/Common/DistillationMiddleAlpha.lean new file mode 100644 index 0000000..cba7412 --- /dev/null +++ b/Sendov/Common/DistillationMiddleAlpha.lean @@ -0,0 +1,152 @@ +import Sendov.Common.DistillationMiddleEstimates + +/-! +# The closed middle-alpha strip, without finite degree bases + +The only split is in alpha, at `17/10`. On each side a positive sextic in +`m-5` bounds T0 on the entire real-degree ray, retaining its actual denominator. +T1 and T2 use mixed-alpha exponential peaks, also on the entire ray. +-/ + +namespace Sendov + +lemma distillElementary_le_middle {m α : ℝ} (hm : 5 ≤ m) (hα : 7 / 5 ≤ α) : + distillElementary m α ≤ 221 / 660 := by + have hα0 : 0 < α := by linarith + have hr : distillRatio α ≤ 5 / 22 := by + have h := distillRatio_antitone (by norm_num : (0 : ℝ) ≤ 7 / 5) hα + have hcap : distillRatio (7 / 5) ≤ 5 / 22 := by norm_num [distillRatio] + exact h.trans hcap + have he := cubicPolarEnvelope_lt_one hα0.le + have hlinear := (le_div_iff₀ (by linarith : 0 < α + 3)).mp + (cubicPolarEnvelope_le_linear hα0.le) + have hid : distillRatio α * α = cubicPolarEnvelope α := + (eq_div_iff hα0.ne').mp (distillRatio_eq hα0) + have hfirst : distillRatio α / (2 * (1 - cubicPolarEnvelope α)) ≤ 1 / 6 := by + apply (div_le_iff₀ (by positivity : 0 < 2 * (1 - cubicPolarEnvelope α))).mpr + nlinarith + have h := distillElementary_antitone_degree (by norm_num : (0 : ℝ) < 5) hm hα0.le + unfold distillElementary at h ⊢ + nlinarith only [h, hfirst, hr] + +private lemma middle_T0_lower_polynomial {m : ℝ} (hm : 5 ≤ m) : + 24 * (3 / 5 : ℝ) ^ 4 * (5 / 22) * m ^ 3 * (m - 2 * (7 / 5)) ^ 2 < + (13 / 50) * ((m + 3) * (m + 5) * ((31 / 50) * m - 12 * (17 / 10) / 25) ^ 4) := by + have hx : 0 ≤ m - 5 := by linarith + have hid : + 2148437500000 * + ((13 / 50) * ((m + 3) * (m + 5) * ((31 / 50) * m - 12 * (17 / 10) / 25) ^ 4) - + 24 * (3 / 5) ^ 4 * (5 / 22) * m ^ 3 * (m - 2 * (7 / 5)) ^ 2) = + 82539689375 * (m - 5) ^ 6 + 1183226670250 * (m - 5) ^ 5 + + 5752975708450 * (m - 5) ^ 4 + 13287198225360 * (m - 5) ^ 3 + + 48679218659063 * (m - 5) ^ 2 + 207466884835694 * (m - 5) + + 297259523310640 := by ring + have hpos : 0 < + 82539689375 * (m - 5) ^ 6 + 1183226670250 * (m - 5) ^ 5 + + 5752975708450 * (m - 5) ^ 4 + 13287198225360 * (m - 5) ^ 3 + + 48679218659063 * (m - 5) ^ 2 + 207466884835694 * (m - 5) + + 297259523310640 := by positivity + rw [← hid] at hpos + linarith only [hpos] + +private lemma middle_T0_upper_polynomial {m : ℝ} (hm : 5 ≤ m) : + 24 * (3 / 5 : ℝ) ^ 4 * (10 / 47) * m ^ 3 * (m - 2 * (17 / 10)) ^ 2 < + (13 / 50) * ((m + 3) * (m + 5) * ((3 / 5) * m - 12 * 2 / 25) ^ 4) := by + have hx : 0 ≤ m - 5 := by linarith + have hid : + 917968750 * + ((13 / 50) * ((m + 3) * (m + 5) * ((3 / 5) * m - 12 * 2 / 25) ^ 4) - + 24 * (3 / 5) ^ 4 * (10 / 47) * m ^ 3 * (m - 2 * (17 / 10)) ^ 2) = + 30931875 * (m - 5) ^ 6 + 369947250 * (m - 5) ^ 5 + + 1135607850 * (m - 5) ^ 4 + 856992960 * (m - 5) ^ 3 + + 18236567691 * (m - 5) ^ 2 + 103802533398 * (m - 5) + 136283024880 := by ring + have hpos : 0 < + 30931875 * (m - 5) ^ 6 + 369947250 * (m - 5) ^ 5 + + 1135607850 * (m - 5) ^ 4 + 856992960 * (m - 5) ^ 3 + + 18236567691 * (m - 5) ^ 2 + 103802533398 * (m - 5) + 136283024880 := by positivity + rw [← hid] at hpos + linarith only [hpos] + +lemma distillT0_le_middle {m α : ℝ} (hm : 5 ≤ m) + (hα : 7 / 5 ≤ α) (hα2 : α ≤ 2) : distillT0 m α ≤ 13 / 50 := by + have hm0 : 0 < m := by linarith + by_cases hsplit : α ≤ 17 / 10 + · have hd : 0 < (31 / 50 : ℝ) * m - 12 * (17 / 10) / 25 := by linarith + have h := distillT0_le_mixed_rational hm (by norm_num : (0 : ℝ) ≤ 7 / 5) + hα hsplit (by linarith : 2 * (17 / 10 : ℝ) ≤ m) + (by norm_num [distillRatio] : distillRatio (7 / 5) ≤ 5 / 22) + (by norm_num [distillPeakD, cubicPolarEnvelope] : (31 / 50 : ℝ) ≤ distillPeakD (17 / 10)) + hd + apply h.trans (le_of_lt _) + apply (div_lt_iff₀ (by positivity : + 0 < (m + 3) * (m + 5) * ((31 / 50) * m - 12 * (17 / 10) / 25) ^ 4)).mpr + exact middle_T0_lower_polynomial hm + · have hd : 0 < (3 / 5 : ℝ) * m - 12 * 2 / 25 := by linarith + have h := distillT0_le_mixed_rational hm (by norm_num : (0 : ℝ) ≤ 17 / 10) + (by linarith : (17 / 10 : ℝ) ≤ α) hα2 (by linarith : 2 * (2 : ℝ) ≤ m) + (by norm_num [distillRatio] : distillRatio (17 / 10) ≤ 10 / 47) + (by norm_num [distillPeakD, cubicPolarEnvelope] : (3 / 5 : ℝ) ≤ distillPeakD 2) + hd + apply h.trans (le_of_lt _) + apply (div_lt_iff₀ (by positivity : + 0 < (m + 3) * (m + 5) * ((3 / 5) * m - 12 * 2 / 25) ^ 4)).mpr + exact middle_T0_upper_polynomial hm + +lemma distillT1_le_middle {m α : ℝ} (hm : 5 ≤ m) + (hα : 7 / 5 ≤ α) (hα2 : α ≤ 2) : distillT1 m α ≤ 7 / 30 := by + by_cases hsplit : α ≤ 17 / 10 + · have h := distillT1_le_mixed_peak hm (by norm_num : (0 : ℝ) ≤ 7 / 5) + (by norm_num : (1 : ℝ) ≤ 17 / 10) hα hsplit (by linarith) + have hlin := distill_mixed_peak1_le_linear (by norm_num : (0 : ℝ) ≤ 7 / 5) + (by norm_num : (1 : ℝ) ≤ 17 / 10) + (by norm_num [distillPeakRate1, distillPeakBoost1, distillPeakNode, cubicPolarEnvelope]) + refine (h.trans hlin).trans ?_ + norm_num [distillLinearExpPeak, distillRatio, distillPeakRate1, + distillPeakBoost1, distillPeakNode, cubicPolarEnvelope] + · have h := distillT1_le_mixed_peak hm (by norm_num : (0 : ℝ) ≤ 17 / 10) + (by norm_num : (1 : ℝ) ≤ 2) (by linarith : (17 / 10 : ℝ) ≤ α) hα2 (by linarith) + have hlin := distill_mixed_peak1_le_linear (by norm_num : (0 : ℝ) ≤ 17 / 10) + (by norm_num : (1 : ℝ) ≤ 2) + (by norm_num [distillPeakRate1, distillPeakBoost1, distillPeakNode, cubicPolarEnvelope]) + refine (h.trans hlin).trans ?_ + norm_num [distillLinearExpPeak, distillRatio, distillPeakRate1, + distillPeakBoost1, distillPeakNode, cubicPolarEnvelope] + +lemma distillT2_le_middle {m α : ℝ} (hm : 5 ≤ m) + (hα : 7 / 5 ≤ α) (hα2 : α ≤ 2) : distillT2 m α ≤ 1 / 6 := by + by_cases hsplit : α ≤ 17 / 10 + · have h := distillT2_le_mixed_peak hm (by norm_num : (0 : ℝ) ≤ 7 / 5) + (by norm_num : (0 : ℝ) < 17 / 10) hα hsplit (by linarith) + have hlin := distill_mixed_peak2_le_linear (by norm_num : (0 : ℝ) ≤ 7 / 5) + (by norm_num : (0 : ℝ) ≤ 17 / 10) + (by norm_num [distillPeakRate2, cubicPolarEnvelope]) + refine (h.trans hlin).trans ?_ + norm_num [distillLinearExpPeak, distillRatio, distillPeakRate2, cubicPolarEnvelope] + · have h := distillT2_le_mixed_peak hm (by norm_num : (0 : ℝ) ≤ 17 / 10) + (by norm_num : (0 : ℝ) < 2) (by linarith : (17 / 10 : ℝ) ≤ α) hα2 (by linarith) + have hlin := distill_mixed_peak2_le_linear (by norm_num : (0 : ℝ) ≤ 17 / 10) + (by norm_num : (0 : ℝ) ≤ 2) + (by norm_num [distillPeakRate2, cubicPolarEnvelope]) + refine (h.trans hlin).trans ?_ + norm_num [distillLinearExpPeak, distillRatio, distillPeakRate2, cubicPolarEnvelope] + +/-- Both alpha endpoints and all real degrees are included; there is no finite base. -/ +theorem distillScalar_lt_one_middle_alpha {m α : ℝ} (hm : 5 ≤ m) + (hα : 7 / 5 ≤ α) (hα2 : α ≤ 2) (hαm : 2 * α ≤ m) : + scalarObstruction m α (cubicPolarEnvelope α) < 1 := by + have h := distillScalar_le_elementary_components hm (by linarith : 0 < α) hαm + have hE := distillElementary_le_middle hm hα + have h0 := distillT0_le_middle hm hα hα2 + have h1 := distillT1_le_middle hm hα hα2 + have h2 := distillT2_le_middle hm hα hα2 + linarith only [h, hE, h0, h1, h2] + +/-- The inherited small-alpha argument and the new strip cover all `0 t ^ 3 * (1 - c * t) ^ ((m - 3) / 2)) := + (by fun_prop : Continuous fun t : ℝ => t ^ 3).mul + ((continuous_rpow_const hs.le).comp (by fun_prop)) + have hfirst : + (∫ t in (0 : ℝ)..1, + t ^ 3 * polarKernel m α (cubicPolarEnvelope α) t ^ ((m - 3) / 2)) ≤ + ∫ t in (0 : ℝ)..1, t ^ 3 * (1 - c * t) ^ ((m - 3) / 2) := by + refine intervalIntegral.integral_mono_on (by norm_num) + ((continuous_cube_mul_polarKernel_rpow _ _ _ hs.le).intervalIntegrable _ _) + (hcont.intervalIntegrable _ _) ?_ + intro t ht + apply mul_le_mul_of_nonneg_left _ (pow_nonneg ht.1 3) + apply Real.rpow_le_rpow (polarKernel_nonneg hm0.le hα + (cubicPolarEnvelope_nonneg hα) ht) _ hs.le + have he := mul_le_mul_of_nonneg_right (cubicPolarEnvelope_le_linear hα) ht.1 + have hq : 2 * α / m ≤ 1 := (div_le_one hm0).mpr hαm + have htprod : 0 ≤ t * (1 - t) := mul_nonneg ht.1 (sub_nonneg.mpr ht.2) + have hqt := mul_le_mul_of_nonneg_right hq htprod + have hid : α / (α + 3) + c = 1 := by dsimp [c]; field_simp + unfold polarKernel + nlinarith + have hrest : 0 ≤ ∫ t in (1 : ℝ)..1 / c, + t ^ 3 * (1 - c * t) ^ ((m - 3) / 2) := by + refine intervalIntegral.integral_nonneg hstop ?_ + intro t ht + have hct := (le_div_iff₀ hc).mp ht.2 + exact mul_nonneg (pow_nonneg (by linarith [ht.1]) 3) + (Real.rpow_nonneg (by nlinarith) _) + have hadd := intervalIntegral.integral_add_adjacent_intervals (μ := volume) + (hcont.intervalIntegrable 0 1) (hcont.intervalIntegrable 1 (1 / c)) + rw [integral_chord_pow hs hc] at hadd + have heq : 6 / (c ^ 4 * (((m - 3) / 2 + 1) * ((m - 3) / 2 + 2) * + ((m - 3) / 2 + 3) * ((m - 3) / 2 + 4))) = + 96 * (α + 3) ^ 4 / + (81 * ((m - 1) * (m + 1) * (m + 3) * (m + 5))) := by + have hp : ((m - 3) / 2 + 1) * ((m - 3) / 2 + 2) * + ((m - 3) / 2 + 3) * ((m - 3) / 2 + 4) = + ((m - 1) * (m + 1) * (m + 3) * (m + 5)) / 16 := by ring + rw [hp] + dsimp [c] + have hm1 : 0 < m - 1 := by linarith + field_simp + ring + rw [heq] at hadd + linarith + +/-- The shared `(m^2-1)` cancels before bounding the degree and alpha losses. -/ +theorem distillScalar_le_chordTotal {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hαm : 2 * α ≤ m) : + scalarObstruction m α (cubicPolarEnvelope α) ≤ distillChordTotal m α := by + have hm0 : 0 < m := by linarith + have hm1 : 0 < m - 1 := by linarith + have hr : distillRatio α ≤ 1 / (α + 3) := by + rw [distillRatio_eq hα] + apply (div_le_iff₀ hα).mpr + simpa only [div_eq_mul_inv, one_mul, mul_comm] using cubicPolarEnvelope_le_linear hα.le + have hmc : 0 ≤ (m ^ 2 - 1) / (4 * m) := + div_nonneg (by nlinarith) (by positivity) + have hK : distillKappa m α ≤ + (m ^ 2 - 1) / (4 * m) * (1 / (α + 3)) * (m - 2 * α) ^ 2 := by + unfold distillKappa + exact mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left hr hmc) (sq_nonneg _) + have hJ := integral_linear_envelope_chord hm hα.le hαm + have hI0 : 0 ≤ ∫ t in (0 : ℝ)..1, + t ^ 3 * polarKernel m α (cubicPolarEnvelope α) t ^ ((m - 3) / 2) := by + refine intervalIntegral.integral_nonneg (by norm_num) ?_ + intro t ht + exact mul_nonneg (pow_nonneg ht.1 3) + (Real.rpow_nonneg (polarKernel_nonneg hm0.le hα.le + (cubicPolarEnvelope_nonneg hα.le) ht) _) + have hKI := mul_le_mul hK hJ hI0 + (mul_nonneg (mul_nonneg hmc (by positivity)) (sq_nonneg _)) + have hid : + ((m ^ 2 - 1) / (4 * m) * (1 / (α + 3)) * (m - 2 * α) ^ 2) * + (96 * (α + 3) ^ 4 / (81 * ((m - 1) * (m + 1) * (m + 3) * (m + 5)))) = + (8 / 27) * (α + 3) ^ 3 * (m - 2 * α) ^ 2 / (m * (m + 3) * (m + 5)) := by + field_simp + ring + rw [hid] at hKI + have hE := distillElementary_le_budget hm0 hα + unfold scalarObstruction distillChordTotal + rw [← distillKappa_eq hα] + exact add_le_add hE hKI + +private lemma chord_total_polynomial_pos {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 ≤ α) (hα1 : α ≤ 7 / 5) : + 0 < (81 * m - 63) * (m + 3) * (m + 5) - + 32 * (α + 3) ^ 3 * (m - 2 * α) ^ 2 := by + have hx : 0 ≤ m - 5 := sub_nonneg.mpr hm + have hr : 0 ≤ 7 - 5 * α := by linarith + let x := m - 5 + let p0 := 81 * x ^ 3 + 936 * x ^ 2 + 3996 * x + 5760 + let p1 := 2025 * x ^ 3 + 17352 * x ^ 2 + 63612 * x + 113760 + let p2 := 20250 * x ^ 3 + 98928 * x ^ 2 + 301464 * x + 1159776 + let p3 := 101250 * x ^ 3 + 40144 * x ^ 2 + 260536 * x + 8048512 + let p4 := 3125 * (x + 2) * (9 * x - 32) ^ 2 + + 26590 * x ^ 2 + 21388 * x + 24752608 + let p5 := 3125 * (x + 3) * (9 * x - 66) ^ 2 + + 59725 * (x - 4) ^ 2 + 9340 * x + 2477844 + have hx0 : 0 ≤ x := hx + have hp0 : 0 < p0 := by dsimp [p0]; positivity + have hp1 : 0 < p1 := by dsimp [p1]; positivity + have hp2 : 0 < p2 := by dsimp [p2]; positivity + have hp3 : 0 < p3 := by dsimp [p3]; positivity + have hp4 : 0 < p4 := by dsimp [p4]; positivity + have hp5 : 0 < p5 := by dsimp [p5]; positivity + -- Only alpha uses a degree-five interval identity; m is unbounded. + have hid : 7 ^ 5 * ((81 * m - 63) * (m + 3) * (m + 5) - + 32 * (α + 3) ^ 3 * (m - 2 * α) ^ 2) = + p0 * (7 - 5 * α) ^ 5 + p1 * α * (7 - 5 * α) ^ 4 + + p2 * α ^ 2 * (7 - 5 * α) ^ 3 + p3 * α ^ 3 * (7 - 5 * α) ^ 2 + + p4 * α ^ 4 * (7 - 5 * α) + p5 * α ^ 5 := by + dsimp [p0, p1, p2, p3, p4, p5, x] + ring + have hpos : 0 < p0 * (7 - 5 * α) ^ 5 + p1 * α * (7 - 5 * α) ^ 4 + + p2 * α ^ 2 * (7 - 5 * α) ^ 3 + p3 * α ^ 3 * (7 - 5 * α) ^ 2 + + p4 * α ^ 4 * (7 - 5 * α) + p5 * α ^ 5 := by + rcases eq_or_lt_of_le hα with heq | hpos + · rw [← heq] + positivity + · positivity + rw [← hid] at hpos + exact pos_of_mul_pos_right hpos (by norm_num) + +theorem distillChordTotal_lt_one {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 ≤ α) (hα1 : α ≤ 7 / 5) : distillChordTotal m α < 1 := by + have hm0 : 0 < m := by linarith + have hden : 0 < 108 * m * (m + 3) * (m + 5) := by positivity + have hid : 1 - distillChordTotal m α = + ((81 * m - 63) * (m + 3) * (m + 5) - + 32 * (α + 3) ^ 3 * (m - 2 * α) ^ 2) / + (108 * m * (m + 3) * (m + 5)) := by + unfold distillChordTotal distillEBudget + field_simp + ring + have hpos := div_pos (chord_total_polynomial_pos hm hα hα1) hden + rw [← hid] at hpos + linarith + +/-- A genuine continuous tail on the small-alpha strip, not a full-domain tail. -/ +theorem distillScalar_lt_one_small_alpha {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hα1 : α ≤ 7 / 5) : + scalarObstruction m α (cubicPolarEnvelope α) < 1 := + (distillScalar_le_chordTotal hm hα (by linarith)).trans_lt + (distillChordTotal_lt_one hm hα.le hα1) + +end Sendov diff --git a/Sendov/DistillationFinite/Rows13_20.lean b/Sendov/DistillationFinite/Rows13_20.lean deleted file mode 100644 index ee407d7..0000000 --- a/Sendov/DistillationFinite/Rows13_20.lean +++ /dev/null @@ -1,952 +0,0 @@ -import Sendov.Common.DistillationCriticalFinite -import Sendov.Common.BernsteinList - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow13 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 4)) : - 0 ≤ distillCritical0 13 x := by - refine (BernsteinCert.coeffs_pos - [95312609280, 986159038464, 4182255286272, 9323494875648, 11586221773824, 7716434879920, - 2252158751992, 69702872952] - (lo := 0) (hi := (13 / 4)) (s := 4826809) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 2) (13 / 2)) : - 0 ≤ -distillCritical0 13 x := by - refine (BernsteinCert.coeffs_pos - [1189709612, 37772699081, 260361665772, 828361550449, 1449618070732, 1449000260187, - 780713914268, 176894977259] - (lo := (7 / 2)) (hi := (13 / 2)) (s := 34992) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : - distillT0 13 α ≤ (239 / 1000) := by - apply distillT0_le_of_critical (l := (13 / 4)) (r := (7 / 2)) (d := (13 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 3) : - 0 ≤ -distillCritical1 13 x := by - refine (BernsteinCert.coeffs_pos - [1645800, 16941952, 71804080, 160487408, 199865978, 132068736, 36713934, 381360] - (lo := 0) (hi := 3) (s := 9) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 4) (13 / 2)) : - 0 ≤ distillCritical1 13 x := by - refine (BernsteinCert.coeffs_pos - [936862162992, 22850723657552, 153778667321056, 494270967533056, 882182150561280, - 901351912066304, 495897196957184, 114401900763136] - (lo := (13 / 4)) (hi := (13 / 2)) (s := 4826809) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : - distillT1 13 α ≤ (77 / 500) := by - apply distillT1_le_of_critical (l := 3) (r := (13 / 4)) (d := (13 / 2)) - 10 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 3) : - 0 ≤ -distillCritical2 13 x := by - refine (BernsteinCert.coeffs_pos - [3900, 20100, 33398, 18330, 784] - (lo := 0) (hi := 3) (s := 3) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 4) (13 / 2)) : - 0 ≤ distillCritical2 13 x := by - refine (BernsteinCert.coeffs_pos - [320316, 11716616, 44579760, 58856160, 25927552] - (lo := (13 / 4)) (hi := (13 / 2)) (s := 2197) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : - distillT2 13 α ≤ (129 / 1000) := by - apply distillT2_le_of_critical (l := 3) (r := (13 / 4)) (d := (13 / 2)) - 10 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow13 - -theorem distillFinite_13 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (13 / 2)) : - distillEBudget 13 + distillT0 13 α + distillT1 13 α + distillT2 13 α ≤ (15929 / 19500) := by - have h0 := CriticalRow13.component0 α hα hd - have h1 := CriticalRow13.component1 α hα hd - have h2 := CriticalRow13.component2 α hα hd - calc - _ ≤ distillEBudget 13 + (239 / 1000) + (77 / 500) + (129 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (15929 / 19500) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_13 : ((15929 / 19500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow14 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (7 / 2)) : - 0 ≤ distillCritical0 14 x := by - refine (BernsteinCert.coeffs_pos - [1634826240, 17468504064, 76407535872, 175522049280, 224895192000, 155251799056, - 48093576856, 2297476344] - (lo := 0) (hi := (7 / 2)) (s := 117649) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 4) 7) : - 0 ≤ -distillCritical0 14 x := by - refine (BernsteinCert.coeffs_pos - [31505747040, 3139887834864, 24475073676480, 82219170216960, 148918433249280, - 152794802917376, 84167676051456, 19458984509440] - (lo := (15 / 4)) (hi := 7) (s := 4826809) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : - distillT0 14 α ≤ (243 / 1000) := by - apply distillT0_le_of_critical (l := (7 / 2)) (r := (15 / 4)) (d := 7) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 4)) : - 0 ≤ -distillCritical1 14 x := by - refine (BernsteinCert.coeffs_pos - [8354066595840, 89082275364864, 390991396847616, 905593677189120, 1172159626377984, - 812792326493504, 246560391834720, 9461705445040] - (lo := 0) (hi := (13 / 4)) (s := 62748517) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 2) 7) : - 0 ≤ distillCritical1 14 x := by - refine (BernsteinCert.coeffs_pos - [8263120944, 371817286832, 2817201946960, 9576838303744, 17712993405312, 18584497896704, - 10449732005120, 2457165967360] - (lo := (7 / 2)) (hi := 7) (s := 117649) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : - distillT1 14 α ≤ (31 / 200) := by - apply distillT1_le_of_critical (l := (13 / 4)) (r := (7 / 2)) (d := 7) - 11 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 4)) : - 0 ≤ -distillCritical2 14 x := by - refine (BernsteinCert.coeffs_pos - [31933440, 170415360, 292567584, 166593880, 9195140] - (lo := 0) (hi := (13 / 4)) (s := 28561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 2) 7) : - 0 ≤ distillCritical2 14 x := by - refine (BernsteinCert.coeffs_pos - [15288, 1542572, 6226992, 8437200, 3777280] - (lo := (7 / 2)) (hi := 7) (s := 343) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : - distillT2 14 α ≤ (33 / 250) := by - apply distillT2_le_of_critical (l := (13 / 4)) (r := (7 / 2)) (d := 7) - 11 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow14 - -theorem distillFinite_14 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 7) : - distillEBudget 14 + distillT0 14 α + distillT1 14 α + distillT2 14 α ≤ (493 / 600) := by - have h0 := CriticalRow14.component0 α hα hd - have h1 := CriticalRow14.component1 α hα hd - have h2 := CriticalRow14.component2 α hα hd - calc - _ ≤ distillEBudget 14 + (243 / 1000) + (31 / 200) + (33 / 250) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (493 / 600) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_14 : ((493 / 600) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow15 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 4) : - 0 ≤ distillCritical0 15 x := by - refine (BernsteinCert.coeffs_pos - [26079975, 294403005, 1352845395, 3241657665, 4291827957, 3017029239, 912832401, - 13390923] - (lo := 0) (hi := 4) (s := 4096) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 4) (15 / 2)) : - 0 ≤ -distillCritical0 15 x := by - refine (BernsteinCert.coeffs_pos - [3075661352184, 81246089189976, 538497355541328, 1681320236398848, 2907450237404160, - 2881036943671680, 1541466330819840, 347148353664000] - (lo := (17 / 4)) (hi := (15 / 2)) (s := 62748517) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : - distillT0 15 α ≤ (31 / 125) := by - apply distillT0_le_of_critical (l := 4) (r := (17 / 4)) (d := (15 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 4)) : - 0 ≤ -distillCritical1 15 x := by - refine (BernsteinCert.coeffs_pos - [191102976, 2162130944, 10024951808, 24392509440, 32908441600, 23448196576, 6982601904, - 43361328] - (lo := 0) (hi := (15 / 4)) (s := 3125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 4 (15 / 2)) : - 0 ≤ distillCritical1 15 x := by - refine (BernsteinCert.coeffs_pos - [29636069376, 736116675072, 4943373389568, 15801867967104, 28021669675200, - 28437914681640, 15539857707960, 3560930262000] - (lo := 4) (hi := (15 / 2)) (s := 117649) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : - distillT1 15 α ≤ (39 / 250) := by - apply distillT1_le_of_critical (l := (15 / 4)) (r := 4) (d := (15 / 2)) - 12 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 4)) : - 0 ≤ -distillCritical2 15 x := by - refine (BernsteinCert.coeffs_pos - [18432, 103680, 183808, 102264, 804] - (lo := 0) (hi := (15 / 4)) (s := 25) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 4 (15 / 2)) : - 0 ≤ distillCritical2 15 x := by - refine (BernsteinCert.coeffs_pos - [114560, 2404512, 8513280, 10865340, 4681800] - (lo := 4) (hi := (15 / 2)) (s := 343) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : - distillT2 15 α ≤ (17 / 125) := by - apply distillT2_le_of_critical (l := (15 / 4)) (r := 4) (d := (15 / 2)) - 12 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow15 - -theorem distillFinite_15 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (15 / 2)) : - distillEBudget 15 + distillT0 15 α + distillT1 15 α + distillT2 15 α ≤ (373 / 450) := by - have h0 := CriticalRow15.component0 α hα hd - have h1 := CriticalRow15.component1 α hα hd - have h2 := CriticalRow15.component2 α hα hd - calc - _ ≤ distillEBudget 15 + (31 / 125) + (39 / 250) + (17 / 125) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (373 / 450) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_15 : ((373 / 450) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow16 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 4)) : - 0 ≤ distillCritical0 16 x := by - refine (BernsteinCert.coeffs_pos - [1972182712320, 22926687731712, 108347544207360, 266704058474496, 362811134954496, - 263349024912128, 84343618952256, 2781135409648] - (lo := 0) (hi := (17 / 4)) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 2) 8) : - 0 ≤ -distillCritical0 16 x := by - refine (BernsteinCert.coeffs_pos - [13422546288, 665907316704, 4906210792896, 16098896403072, 28751483518464, - 29204927704064, 15959087198208, 3663911747584] - (lo := (9 / 2)) (hi := 8) (s := 823543) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : - distillT0 16 α ≤ (251 / 1000) := by - apply distillT0_le_of_critical (l := (17 / 4)) (r := (9 / 2)) (d := 8) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 4) : - 0 ≤ -distillCritical1 16 x := by - refine (BernsteinCert.coeffs_pos - [6130890, 71590149, 342415404, 859646871, 1199203626, 890581747, 285996160, 9254673] - (lo := 0) (hi := 4) (s := 128) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 4) 8) : - 0 ≤ distillCritical1 16 x := by - refine (BernsteinCert.coeffs_pos - [15134656784656, 713207139336832, 5389882680124416, 18206806631106560, - 33433144747765760, 34819713077477376, 19434630765740032, 4536633546244096] - (lo := (17 / 4)) (hi := 8) (s := 170859375) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : - distillT1 16 α ≤ (157 / 1000) := by - apply distillT1_le_of_critical (l := 4) (r := (17 / 4)) (d := 8) - 13 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 4) : - 0 ≤ -distillCritical2 16 x := by - refine (BernsteinCert.coeffs_pos - [10530, 61155, 111741, 64433, 1461] - (lo := 0) (hi := 4) (s := 16) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 4) 8) : - 0 ≤ distillCritical2 16 x := by - refine (BernsteinCert.coeffs_pos - [10204444, 301877416, 1123574784, 1468708096, 642678784] - (lo := (17 / 4)) (hi := 8) (s := 50625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : - distillT2 16 α ≤ (7 / 50) := by - apply distillT2_le_of_critical (l := 4) (r := (17 / 4)) (d := 8) - 13 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow16 - -theorem distillFinite_16 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 8) : - distillEBudget 16 + distillT0 16 α + distillT1 16 α + distillT2 16 α ≤ (20027 / 24000) := by - have h0 := CriticalRow16.component0 α hα hd - have h1 := CriticalRow16.component1 α hα hd - have h2 := CriticalRow16.component2 α hα hd - calc - _ ≤ distillEBudget 16 + (251 / 1000) + (157 / 1000) + (7 / 50) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (20027 / 24000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_16 : ((20027 / 24000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow17 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (19 / 4)) : - 0 ≤ distillCritical0 17 x := by - refine (BernsteinCert.coeffs_pos - [2253820723200, 27574101098496, 136446721136640, 349375546750464, 490179912370176, - 362651147992720, 114843490435896, 390340442168] - (lo := 0) (hi := (19 / 4)) (s := 893871739) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 5 (17 / 2)) : - 0 ≤ -distillCritical0 17 x := by - refine (BernsteinCert.coeffs_pos - [50391315840, 1210326217408, 7831599144320, 24159770489792, 41457331418328, - 40848782192260, 21756336775348, 4880218869944] - (lo := 5) (hi := (17 / 2)) (s := 823543) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : - distillT0 17 α ≤ (32 / 125) := by - apply distillT0_le_of_critical (l := (19 / 4)) (r := 5) (d := (17 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 2)) : - 0 ≤ -distillCritical1 17 x := by - refine (BernsteinCert.coeffs_pos - [167203840, 2061905408, 10374514944, 27264937856, 39554095696, 30217779960, 9659524024, - 64588688] - (lo := 0) (hi := (9 / 2)) (s := 6561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 4) (17 / 2)) : - 0 ≤ distillCritical1 17 x := by - refine (BernsteinCert.coeffs_pos - [49818019422896, 1316111243212112, 8920425494468256, 28532184143080960, - 50483737628892160, 51058649636572416, 27790063192013312, 6340904691931136] - (lo := (19 / 4)) (hi := (17 / 2)) (s := 170859375) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : - distillT1 17 α ≤ (157 / 1000) := by - apply distillT1_le_of_critical (l := (9 / 2)) (r := (19 / 4)) (d := (17 / 2)) - 14 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 4)) : - 0 ≤ -distillCritical2 17 x := by - refine (BernsteinCert.coeffs_pos - [2903040, 17383680, 32674848, 19440040, 675924] - (lo := 0) (hi := (17 / 4)) (s := 4913) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 2) (17 / 2)) : - 0 ≤ distillCritical2 17 x := by - refine (BernsteinCert.coeffs_pos - [51111, 2623968, 10265430, 13725352, 6092171] - (lo := (9 / 2)) (hi := (17 / 2)) (s := 512) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : - distillT2 17 α ≤ (29 / 200) := by - apply distillT2_le_of_critical (l := (17 / 4)) (r := (9 / 2)) (d := (17 / 2)) - 14 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow17 - -theorem distillFinite_17 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (17 / 2)) : - distillEBudget 17 + distillT0 17 α + distillT1 17 α + distillT2 17 α ≤ (21479 / 25500) := by - have h0 := CriticalRow17.component0 α hα hd - have h1 := CriticalRow17.component1 α hα hd - have h2 := CriticalRow17.component2 α hα hd - calc - _ ≤ distillEBudget 17 + (32 / 125) + (157 / 1000) + (29 / 200) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (21479 / 25500) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_17 : ((21479 / 25500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow18 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 5) : - 0 ≤ distillCritical0 18 x := by - refine (BernsteinCert.coeffs_pos - [31177872, 391875408, 1989487656, 5219727480, 7502139000, 5710155372, 1906260228, - 42056496] - (lo := 0) (hi := 5) (s := 15625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 4) 9) : - 0 ≤ -distillCritical0 18 x := by - refine (BernsteinCert.coeffs_pos - [1926607008, 73720166256, 524548632768, 1694855393280, 2998373345280, 3024924807168, - 1643920736256, 375595204608] - (lo := (21 / 4)) (hi := 9) (s := 78125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : - distillT0 18 α ≤ (259 / 1000) := by - apply distillT0_le_of_critical (l := 5) (r := (21 / 4)) (d := 9) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (19 / 4)) : - 0 ≤ -distillCritical1 18 x := by - refine (BernsteinCert.coeffs_pos - [18704203776000, 237355485954048, 1228172209569792, 3319004068098048, 4958468754534144, - 3926425884542784, 1339372424410272, 40779572863632] - (lo := 0) (hi := (19 / 4)) (s := 893871739) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 5 9) : - 0 ≤ distillCritical1 18 x := by - refine (BernsteinCert.coeffs_pos - [92712615, 5246215902, 40156857081, 135740625552, 248599719945, 257891522598, - 143292810807, 33287968332] - (lo := 5) (hi := 9) (s := 1024) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : - distillT1 18 α ≤ (79 / 500) := by - apply distillT1_le_of_critical (l := (19 / 4)) (r := 5) (d := 9) - 15 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 2)) : - 0 ≤ -distillCritical2 18 x := by - refine (BernsteinCert.coeffs_pos - [4800, 29600, 57144, 34956, 1568] - (lo := 0) (hi := (9 / 2)) (s := 9) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 4) 9) : - 0 ≤ distillCritical2 18 x := by - refine (BernsteinCert.coeffs_pos - [1705388, 371129784, 1526114304, 2084600448, 937598976] - (lo := (19 / 4)) (hi := 9) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : - distillT2 18 α ≤ (3 / 20) := by - apply distillT2_le_of_critical (l := (9 / 2)) (r := (19 / 4)) (d := 9) - 15 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow18 - -theorem distillFinite_18 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 9) : - distillEBudget 18 + distillT0 18 α + distillT1 18 α + distillT2 18 α ≤ (11467 / 13500) := by - have h0 := CriticalRow18.component0 α hα hd - have h1 := CriticalRow18.component1 α hα hd - have h2 := CriticalRow18.component2 α hα hd - calc - _ ≤ distillEBudget 18 + (259 / 1000) + (79 / 500) + (3 / 20) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (11467 / 13500) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_18 : ((11467 / 13500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow19 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 4)) : - 0 ≤ distillCritical0 19 x := by - refine (BernsteinCert.coeffs_pos - [11823022080, 152534925312, 793746229248, 2131410839040, 3133102819840, 2446484008528, - 854290278968, 31580537144] - (lo := 0) (hi := (21 / 4)) (s := 7411887) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 2) (19 / 2)) : - 0 ≤ -distillCritical0 19 x := by - refine (BernsteinCert.coeffs_pos - [815511069, 158277314263, 1265345417225, 4295494687115, 7836312414375, 8090637953749, - 4483415908339, 1042574009225] - (lo := (11 / 2)) (hi := (19 / 2)) (s := 262144) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : - distillT0 19 α ≤ (131 / 500) := by - apply distillT0_le_of_critical (l := (21 / 4)) (r := (11 / 2)) (d := (19 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 4)) : - 0 ≤ -distillCritical1 19 x := by - refine (BernsteinCert.coeffs_pos - [91296890880, 1218553348096, 6608431685632, 18634236508160, 28881217019648, - 23521701222432, 8058000683376, 78742960176] - (lo := 0) (hi := (21 / 4)) (s := 7411887) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 2) (19 / 2)) : - 0 ≤ distillCritical1 19 x := by - refine (BernsteinCert.coeffs_pos - [39694891881, 1174877186107, 8120323321637, 26120350376351, 46267736011851, - 46754263641793, 25399921798375, 5781468959525] - (lo := (11 / 2)) (hi := (19 / 2)) (s := 131072) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : - distillT1 19 α ≤ (159 / 1000) := by - apply distillT1_le_of_critical (l := (21 / 4)) (r := (11 / 2)) (d := (19 / 2)) - 16 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 5) : - 0 ≤ -distillCritical2 19 x := by - refine (BernsteinCert.coeffs_pos - [49248, 318492, 634368, 383102, 3478] - (lo := 0) (hi := 5) (s := 125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 4) (19 / 2)) : - 0 ≤ distillCritical2 19 x := by - refine (BernsteinCert.coeffs_pos - [20787084, 540100584, 1978380336, 2567429600, 1118051200] - (lo := (21 / 4)) (hi := (19 / 2)) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : - distillT2 19 α ≤ (77 / 500) := by - apply distillT2_le_of_critical (l := 5) (r := (21 / 4)) (d := (19 / 2)) - 16 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow19 - -theorem distillFinite_19 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (19 / 2)) : - distillEBudget 19 + distillT0 19 α + distillT1 19 α + distillT2 19 α ≤ (1951 / 2280) := by - have h0 := CriticalRow19.component0 α hα hd - have h1 := CriticalRow19.component1 α hα hd - have h2 := CriticalRow19.component2 α hα hd - calc - _ ≤ distillEBudget 19 + (131 / 500) + (159 / 1000) + (77 / 500) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (1951 / 2280) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_19 : ((1951 / 2280) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow20 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 4)) : - 0 ≤ distillCritical0 20 x := by - refine (BernsteinCert.coeffs_pos - [3210529996800, 43392000983040, 235474379735040, 655390796451840, 990711683438592, - 788061705056000, 275622004818080, 3955544430960] - (lo := 0) (hi := (23 / 4)) (s := 3404825447) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 6 10) : - 0 ≤ -distillCritical0 20 x := by - refine (BernsteinCert.coeffs_pos - [8003691, 269774631, 1879076907, 6011913663, 10570468665, 10616391005, 5748621105, - 1309160125] - (lo := 6) (hi := 10) (s := 256) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : - distillT0 20 α ≤ (53 / 200) := by - apply distillT0_le_of_critical (l := (23 / 4)) (r := 6) (d := 10) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (11 / 2)) : - 0 ≤ -distillCritical1 20 x := by - refine (BernsteinCert.coeffs_pos - [18513100800, 253662658560, 1411196636160, 4080619848960, 6491826102912, 5455808074592, - 1977015589344, 61606601776] - (lo := 0) (hi := (11 / 2)) (s := 1771561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 4) 10) : - 0 ≤ distillCritical1 20 x := by - refine (BernsteinCert.coeffs_pos - [27976374343920, 2430543418874560, 19114144481148800, 65035103129729024, - 119222947355381760, 123523222279290880, 68472870743572480, 15859922763776000] - (lo := (23 / 4)) (hi := 10) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : - distillT1 20 α ≤ (159 / 1000) := by - apply distillT1_le_of_critical (l := (11 / 2)) (r := (23 / 4)) (d := 10) - 17 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 4)) : - 0 ≤ -distillCritical2 20 x := by - refine (BernsteinCert.coeffs_pos - [2611200, 17352960, 35435200, 21976488, 447500] - (lo := 0) (hi := (21 / 4)) (s := 7203) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 2) 10) : - 0 ≤ distillCritical2 20 x := by - refine (BernsteinCert.coeffs_pos - [975328, 37035532, 141627840, 187507360, 82700800] - (lo := (11 / 2)) (hi := 10) (s := 6561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : - distillT2 20 α ≤ (4 / 25) := by - apply distillT2_le_of_critical (l := (21 / 4)) (r := (11 / 2)) (d := 10) - 17 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow20 - -theorem distillFinite_20 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 10) : - distillEBudget 20 + distillT0 20 α + distillT1 20 α + distillT2 20 α ≤ (5179 / 6000) := by - have h0 := CriticalRow20.component0 α hα hd - have h1 := CriticalRow20.component1 α hα hd - have h2 := CriticalRow20.component2 α hα hd - calc - _ ≤ distillEBudget 20 + (53 / 200) + (159 / 1000) + (4 / 25) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (5179 / 6000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_20 : ((5179 / 6000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end diff --git a/Sendov/DistillationFinite/Rows21_28.lean b/Sendov/DistillationFinite/Rows21_28.lean deleted file mode 100644 index 158365e..0000000 --- a/Sendov/DistillationFinite/Rows21_28.lean +++ /dev/null @@ -1,952 +0,0 @@ -import Sendov.Common.DistillationCriticalFinite -import Sendov.Common.BernsteinList - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow21 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 6) : - 0 ≤ distillCritical0 21 x := by - refine (BernsteinCert.coeffs_pos - [24885, 344577, 1913103, 5439279, 8390587, 6828303, 2490257, 73041] - (lo := 0) (hi := 6) (s := 32) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 4) (21 / 2)) : - 0 ≤ -distillCritical0 21 x := by - refine (BernsteinCert.coeffs_pos - [3083660642280, 283158061418568, 2194144323169680, 7355419192733184, 13318328773327104, - 13676740567926912, 7545890856409344, 1747843365768192] - (lo := (25 / 4)) (hi := (21 / 2)) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : - distillT0 21 α ≤ (67 / 250) := by - apply distillT0_le_of_critical (l := 6) (r := (25 / 4)) (d := (21 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 6) : - 0 ≤ -distillCritical1 21 x := by - refine (BernsteinCert.coeffs_pos - [105945, 1521433, 8842533, 26602997, 43805279, 37832655, 13846627, 197859] - (lo := 0) (hi := 6) (s := 16) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 4) (21 / 2)) : - 0 ≤ distillCritical1 21 x := by - refine (BernsteinCert.coeffs_pos - [113758150270320, 4082926086718224, 29077158265650144, 94484104230311424, - 168014508486308352, 169982024485001472, 92325810395635200, 20993604324489216] - (lo := (25 / 4)) (hi := (21 / 2)) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : - distillT1 21 α ≤ (4 / 25) := by - apply distillT1_le_of_critical (l := 6) (r := (25 / 4)) (d := (21 / 2)) - 18 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (11 / 2)) : - 0 ≤ -distillCritical2 21 x := by - refine (BernsteinCert.coeffs_pos - [4898880, 33423840, 69893784, 44401356, 1334176] - (lo := 0) (hi := (11 / 2)) (s := 14641) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 4) (21 / 2)) : - 0 ≤ distillCritical2 21 x := by - refine (BernsteinCert.coeffs_pos - [8924540, 646825560, 2582180784, 3484393632, 1555231104] - (lo := (23 / 4)) (hi := (21 / 2)) (s := 130321) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : - distillT2 21 α ≤ (33 / 200) := by - apply distillT2_le_of_critical (l := (11 / 2)) (r := (23 / 4)) (d := (21 / 2)) - 18 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow21 - -theorem distillFinite_21 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (21 / 2)) : - distillEBudget 21 + distillT0 21 α + distillT1 21 α + distillT2 21 α ≤ (7837 / 9000) := by - have h0 := CriticalRow21.component0 α hα hd - have h1 := CriticalRow21.component1 α hα hd - have h2 := CriticalRow21.component2 α hα hd - calc - _ ≤ distillEBudget 21 + (67 / 250) + (4 / 25) + (33 / 200) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (7837 / 9000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_21 : ((7837 / 9000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow22 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 2)) : - 0 ≤ distillCritical0 22 x := by - refine (BernsteinCert.coeffs_pos - [30792960000, 445377927168, 2572183662336, 7563508192512, 11975591323968, 9920238748240, - 3646030987656, 33436259048] - (lo := 0) (hi := (13 / 2)) (s := 62748517) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 4) 11) : - 0 ≤ -distillCritical0 22 x := by - refine (BernsteinCert.coeffs_pos - [14767914854880, 467537063626224, 3217749780157632, 10235741853238272, - 17931176975505408, 17960411366723584, 9703583421087744, 2205301382316032] - (lo := (27 / 4)) (hi := 11) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : - distillT0 22 α ≤ (271 / 1000) := by - apply distillT0_le_of_critical (l := (13 / 2)) (r := (27 / 4)) (d := 11) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 4)) : - 0 ≤ -distillCritical1 22 x := by - refine (BernsteinCert.coeffs_pos - [7023225470976, 103328513851392, 614788765433856, 1892504223682560, 3190211005935360, - 2832819482168896, 1088817206404192, 36504389791536] - (lo := 0) (hi := (25 / 4)) (s := 1220703125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 2) 11) : - 0 ≤ distillCritical1 22 x := by - refine (BernsteinCert.coeffs_pos - [69911613200, 31099175440592, 255054315681168, 878129789212672, 1616258257694080, - 1676061209948928, 928512234606848, 214744360742912] - (lo := (13 / 2)) (hi := 11) (s := 4782969) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : - distillT1 22 α ≤ (4 / 25) := by - apply distillT1_le_of_critical (l := (25 / 4)) (r := (13 / 2)) (d := 11) - 19 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 4)) : - 0 ≤ -distillCritical2 22 x := by - refine (BernsteinCert.coeffs_pos - [86676480, 606631680, 1297754016, 842672584, 32412212] - (lo := 0) (hi := (23 / 4)) (s := 279841) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 6 11) : - 0 ≤ distillCritical2 22 x := by - refine (BernsteinCert.coeffs_pos - [2268, 2744892, 11439318, 15719282, 7095088] - (lo := 6) (hi := 11) (s := 625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : - distillT2 22 α ≤ (17 / 100) := by - apply distillT2_le_of_critical (l := (23 / 4)) (r := 6) (d := 11) - 19 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow22 - -theorem distillFinite_22 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 11) : - distillEBudget 22 + distillT0 22 α + distillT1 22 α + distillT2 22 α ≤ (14479 / 16500) := by - have h0 := CriticalRow22.component0 α hα hd - have h1 := CriticalRow22.component1 α hα hd - have h2 := CriticalRow22.component2 α hα hd - calc - _ ≤ distillEBudget 22 + (271 / 1000) + (4 / 25) + (17 / 100) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (14479 / 16500) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_22 : ((14479 / 16500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow23 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 4)) : - 0 ≤ distillCritical0 23 x := by - refine (BernsteinCert.coeffs_pos - [1982136320, 29323280384, 172988123136, 518772464128, 836616640000, 707264918448, - 270200563544, 6453121496] - (lo := 0) (hi := (27 / 4)) (s := 4782969) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 7 (23 / 2)) : - 0 ≤ -distillCritical0 23 x := by - refine (BernsteinCert.coeffs_pos - [51396902528, 3634851593024, 27652415110656, 91979940230464, 165754342766344, - 169621380354876, 93314280169484, 21556236449192] - (lo := 7) (hi := (23 / 2)) (s := 4782969) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : - distillT0 23 α ≤ (273 / 1000) := by - apply distillT0_le_of_critical (l := (27 / 4)) (r := 7) (d := (23 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 4)) : - 0 ≤ -distillCritical1 23 x := by - refine (BernsteinCert.coeffs_pos - [55318937600, 850379964416, 5270920028160, 16838754555904, 29316774613504, - 26723143323168, 10412319412112, 203634219920] - (lo := 0) (hi := (27 / 4)) (s := 14348907) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 7 (23 / 2)) : - 0 ≤ distillCritical1 23 x := by - refine (BernsteinCert.coeffs_pos - [995128529152, 50666535851392, 376094514533376, 1239774891757376, 2218546071663440, - 2250988264845624, 1223993114037784, 278345609952016] - (lo := 7) (hi := (23 / 2)) (s := 4782969) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : - distillT1 23 α ≤ (161 / 1000) := by - apply distillT1_le_of_critical (l := (27 / 4)) (r := 7) (d := (23 / 2)) - 20 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 4)) : - 0 ≤ -distillCritical2 23 x := by - refine (BernsteinCert.coeffs_pos - [3815424, 27876096, 61417344, 39553096, 383924] - (lo := 0) (hi := (25 / 4)) (s := 15625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 2) (23 / 2)) : - 0 ≤ distillCritical2 23 x := by - refine (BernsteinCert.coeffs_pos - [239472, 7601533, 28569717, 37538223, 16475567] - (lo := (13 / 2)) (hi := (23 / 2)) (s := 1250) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : - distillT2 23 α ≤ (7 / 40) := by - apply distillT2_le_of_critical (l := (25 / 4)) (r := (13 / 2)) (d := (23 / 2)) - 20 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow23 - -theorem distillFinite_23 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (23 / 2)) : - distillEBudget 23 + distillT0 23 α + distillT1 23 α + distillT2 23 α ≤ (61021 / 69000) := by - have h0 := CriticalRow23.component0 α hα hd - have h1 := CriticalRow23.component1 α hα hd - have h2 := CriticalRow23.component2 α hα hd - calc - _ ≤ distillEBudget 23 + (273 / 1000) + (161 / 1000) + (7 / 40) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (61021 / 69000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_23 : ((61021 / 69000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow24 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 4)) : - 0 ≤ distillCritical0 24 x := by - refine (BernsteinCert.coeffs_pos - [4746997923840, 73164538773504, 447965465444352, 1386669848739840, 2291328567198720, - 1969726633871616, 762089030190336, 4533555905904] - (lo := 0) (hi := (29 / 4)) (s := 17249876309) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 2) 12) : - 0 ≤ -distillCritical0 24 x := by - refine (BernsteinCert.coeffs_pos - [84982480, 2628270592, 17997003840, 57099267200, 99853936640, 99883987968, 53902778368, - 12236308480] - (lo := (15 / 2)) (hi := 12) (s := 2187) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : - distillT0 24 α ≤ (11 / 40) := by - apply distillT0_le_of_critical (l := (29 / 4)) (r := (15 / 2)) (d := 12) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 4)) : - 0 ≤ -distillCritical1 24 x := by - refine (BernsteinCert.coeffs_pos - [46025240739840, 737939268698112, 4757440347832320, 15751231124705280, - 28292882244470784, 26463699854085888, 10476559012793856, 67764558438576] - (lo := 0) (hi := (29 / 4)) (s := 17249876309) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 2) 12) : - 0 ≤ distillCritical1 24 x := by - refine (BernsteinCert.coeffs_pos - [127355280, 3996095744, 27497476416, 87364258560, 152491243264, 151703445504, - 81098987520, 18159042560] - (lo := (15 / 2)) (hi := 12) (s := 243) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : - distillT1 24 α ≤ (161 / 1000) := by - apply distillT1_le_of_critical (l := (29 / 4)) (r := (15 / 2)) (d := 12) - 21 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (13 / 2)) : - 0 ≤ -distillCritical2 24 x := by - refine (BernsteinCert.coeffs_pos - [6531840, 48872160, 110005056, 72339708, 1361896] - (lo := 0) (hi := (13 / 2)) (s := 28561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 4) 12) : - 0 ≤ distillCritical2 24 x := by - refine (BernsteinCert.coeffs_pos - [268524, 12988152, 50695424, 67761920, 30064640] - (lo := (27 / 4)) (hi := 12) (s := 2401) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : - distillT2 24 α ≤ (9 / 50) := by - apply distillT2_le_of_critical (l := (13 / 2)) (r := (27 / 4)) (d := 12) - 21 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow24 - -theorem distillFinite_24 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 12) : - distillEBudget 24 + distillT0 24 α + distillT1 24 α + distillT2 24 α ≤ (32051 / 36000) := by - have h0 := CriticalRow24.component0 α hα hd - have h1 := CriticalRow24.component1 α hα hd - have h2 := CriticalRow24.component2 α hα hd - calc - _ ≤ distillEBudget 24 + (11 / 40) + (161 / 1000) + (9 / 50) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (32051 / 36000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_24 : ((32051 / 36000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow25 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 2)) : - 0 ≤ distillCritical0 25 x := by - refine (BernsteinCert.coeffs_pos - [6658560, 104818944, 654663744, 2063864160, 3467847680, 3035622620, 1217166364, - 24580624] - (lo := 0) (hi := (15 / 2)) (s := 28125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 4) (25 / 2)) : - 0 ≤ -distillCritical0 25 x := by - refine (BernsteinCert.coeffs_pos - [11384777913672, 727247908624744, 5482364668675376, 18160873161033728, - 32640788624409600, 33335006304645760, 18306494249163520, 4221637754240000] - (lo := (31 / 4)) (hi := (25 / 2)) (s := 893871739) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : - distillT0 25 α ≤ (277 / 1000) := by - apply distillT0_le_of_critical (l := (15 / 2)) (r := (31 / 4)) (d := (25 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 2)) : - 0 ≤ -distillCritical1 25 x := by - refine (BernsteinCert.coeffs_pos - [67169280, 1100406272, 7243465472, 24471594880, 44862645040, 42979698360, 17765271432, - 447251712] - (lo := 0) (hi := (15 / 2)) (s := 28125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 4) (25 / 2)) : - 0 ≤ distillCritical1 25 x := by - refine (BernsteinCert.coeffs_pos - [80779279690416, 9690244766280272, 76014640230507808, 255281173869243904, - 460715608679823360, 469477527539559680, 255847429110325760, 58239373592320000] - (lo := (31 / 4)) (hi := (25 / 2)) (s := 893871739) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : - distillT1 25 α ≤ (161 / 1000) := by - apply distillT1_le_of_critical (l := (15 / 2)) (r := (31 / 4)) (d := (25 / 2)) - 22 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 4)) : - 0 ≤ -distillCritical2 25 x := by - refine (BernsteinCert.coeffs_pos - [1408000, 10781440, 24773280, 16607608, 446692] - (lo := 0) (hi := (27 / 4)) (s := 6561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 7 (25 / 2)) : - 0 ≤ distillCritical2 25 x := by - refine (BernsteinCert.coeffs_pos - [675264, 70830128, 287108160, 390125940, 174871000] - (lo := 7) (hi := (25 / 2)) (s := 14641) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : - distillT2 25 α ≤ (93 / 500) := by - apply distillT2_le_of_critical (l := (27 / 4)) (r := 7) (d := (25 / 2)) - 22 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow25 - -theorem distillFinite_25 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (25 / 2)) : - distillEBudget 25 + distillT0 25 α + distillT1 25 α + distillT2 25 α ≤ (673 / 750) := by - have h0 := CriticalRow25.component0 α hα hd - have h1 := CriticalRow25.component1 α hα hd - have h2 := CriticalRow25.component2 α hα hd - calc - _ ≤ distillEBudget 25 + (277 / 1000) + (161 / 1000) + (93 / 500) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (673 / 750) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_25 : ((673 / 750) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow26 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 8) : - 0 ≤ distillCritical0 26 x := by - refine (BernsteinCert.coeffs_pos - [21465405, 351232443, 2272145985, 7380885159, 12686998359, 11280128177, 4598433899, - 19441197] - (lo := 0) (hi := 8) (s := 131072) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 4) 13) : - 0 ≤ -distillCritical0 26 x := by - refine (BernsteinCert.coeffs_pos - [35732324880864, 1111011969593232, 7610471820871488, 24143164934547456, - 42212599768676352, 42215407934861312, 22774884449009664, 5167836332818432] - (lo := (33 / 4)) (hi := 13) (s := 893871739) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : - distillT0 26 α ≤ (279 / 1000) := by - apply distillT0_le_of_critical (l := 8) (r := (33 / 4)) (d := 13) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 8) : - 0 ≤ -distillCritical1 26 x := by - refine (BernsteinCert.coeffs_pos - [224936595, 3833861949, 26188308639, 91501746849, 172741990137, 169597494487, - 71352632725, 1013459211] - (lo := 0) (hi := 8) (s := 131072) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 4) 13) : - 0 ≤ distillCritical1 26 x := by - refine (BernsteinCert.coeffs_pos - [324416503328400, 14750115770725920, 106891472433082176, 346391522019348480, - 610649595233212416, 610945977391734784, 327730049946697728, 73539025671028736] - (lo := (33 / 4)) (hi := 13) (s := 893871739) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : - distillT1 26 α ≤ (81 / 500) := by - apply distillT1_le_of_critical (l := 8) (r := (33 / 4)) (d := 13) - 23 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 4)) : - 0 ≤ -distillCritical2 26 x := by - refine (BernsteinCert.coeffs_pos - [124001280, 988104960, 2335033056, 1555350296, 2376324] - (lo := 0) (hi := (29 / 4)) (s := 707281) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (15 / 2) 13) : - 0 ≤ distillCritical2 26 x := by - refine (BernsteinCert.coeffs_pos - [3357720, 94466340, 350231856, 457397744, 199972864] - (lo := (15 / 2)) (hi := 13) (s := 14641) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : - distillT2 26 α ≤ (191 / 1000) := by - apply distillT2_le_of_critical (l := (29 / 4)) (r := (15 / 2)) (d := 13) - 23 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow26 - -theorem distillFinite_26 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 13) : - distillEBudget 26 + distillT0 26 α + distillT1 26 α + distillT2 26 α ≤ (35273 / 39000) := by - have h0 := CriticalRow26.component0 α hα hd - have h1 := CriticalRow26.component1 α hα hd - have h2 := CriticalRow26.component2 α hα hd - calc - _ ≤ distillEBudget 26 + (279 / 1000) + (81 / 500) + (191 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (35273 / 39000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_26 : ((35273 / 39000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow27 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (33 / 4)) : - 0 ≤ distillCritical0 27 x := by - refine (BernsteinCert.coeffs_pos - [2786918400, 46516617216, 306593777664, 1013088923136, 1768271491584, 1597776150672, - 673159819896, 12051890424] - (lo := 0) (hi := (33 / 4)) (s := 19487171) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (17 / 2) (27 / 2)) : - 0 ≤ -distillCritical0 27 x := by - refine (BernsteinCert.coeffs_pos - [16869196368, 1064646906651, 8010422479728, 26503241824755, 47589705911880, - 48561168058353, 26645623846776, 6138784644993] - (lo := (17 / 2)) (hi := (27 / 2)) (s := 1250000) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : - distillT0 27 α ≤ (7 / 25) := by - apply distillT0_le_of_critical (l := (33 / 4)) (r := (17 / 2)) (d := (27 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 2)) : - 0 ≤ -distillCritical1 27 x := by - refine (BernsteinCert.coeffs_pos - [517590466560, 9164734004736, 64877844748032, 234166178994048, 454805616687840, - 457372160416728, 196146018321624, 793019555328] - (lo := 0) (hi := (17 / 2)) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (35 / 4) (27 / 2)) : - 0 ≤ distillCritical1 27 x := by - refine (BernsteinCert.coeffs_pos - [697464484134000, 21680354555329392, 147540088389767904, 463553223820494336, - 800156563044226560, 787234858010355456, 416198987466259968, 92157018004187136] - (lo := (35 / 4)) (hi := (27 / 2)) (s := 893871739) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : - distillT1 27 α ≤ (81 / 500) := by - apply distillT1_le_of_critical (l := (17 / 2)) (r := (35 / 4)) (d := (27 / 2)) - 24 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (15 / 2)) : - 0 ≤ -distillCritical2 27 x := by - refine (BernsteinCert.coeffs_pos - [20736, 168864, 406896, 276044, 2776] - (lo := 0) (hi := (15 / 2)) (s := 125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 4) (27 / 2)) : - 0 ≤ distillCritical2 27 x := by - refine (BernsteinCert.coeffs_pos - [42192956, 1621851288, 6219278064, 8249965344, 3642807168] - (lo := (31 / 4)) (hi := (27 / 2)) (s := 279841) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : - distillT2 27 α ≤ (49 / 250) := by - apply distillT2_le_of_critical (l := (15 / 2)) (r := (31 / 4)) (d := (27 / 2)) - 24 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow27 - -theorem distillFinite_27 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (27 / 2)) : - distillEBudget 27 + distillT0 27 α + distillT1 27 α + distillT2 27 α ≤ (36839 / 40500) := by - have h0 := CriticalRow27.component0 α hα hd - have h1 := CriticalRow27.component1 α hα hd - have h2 := CriticalRow27.component2 α hα hd - calc - _ ≤ distillEBudget 27 + (7 / 25) + (81 / 500) + (49 / 250) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (36839 / 40500) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_27 : ((36839 / 40500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow28 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (35 / 4)) : - 0 ≤ distillCritical0 28 x := by - refine (BernsteinCert.coeffs_pos - [188045328384, 3255662149632, 22185558540288, 75419892633600, 134471191326720, - 123265812193024, 52966489937952, 193320907088] - (lo := 0) (hi := (35 / 4)) (s := 1838265625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 9 14) : - 0 ≤ -distillCritical0 28 x := by - refine (BernsteinCert.coeffs_pos - [3085052184, 98833401288, 680357243664, 2162577493440, 3785116471440, 3787832416864, - 2044289592288, 463931297984] - (lo := 9) (hi := 14) (s := 78125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : - distillT0 28 α ≤ (141 / 500) := by - apply distillT0_le_of_critical (l := (35 / 4)) (r := 9) (d := 14) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (35 / 4)) : - 0 ≤ -distillCritical1 28 x := by - refine (BernsteinCert.coeffs_pos - [2117420974080, 38227241336832, 275727892119552, 1013321618657280, 2003778711229440, - 2057395616543360, 916168403232192, 19758575767792] - (lo := 0) (hi := (35 / 4)) (s := 1838265625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 9 14) : - 0 ≤ distillCritical1 28 x := by - refine (BernsteinCert.coeffs_pos - [10785881592, 1250744333184, 9687079540872, 32143744732320, 57333275573520, - 57748023276032, 31107450384384, 6999015288832] - (lo := 9) (hi := 14) (s := 78125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : - distillT1 28 α ≤ (81 / 500) := by - apply distillT1_le_of_critical (l := (35 / 4)) (r := 9) (d := 14) - 25 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (31 / 4)) : - 0 ≤ -distillCritical2 28 x := by - refine (BernsteinCert.coeffs_pos - [145152000, 1207353600, 2964629184, 2045792744, 36236724] - (lo := 0) (hi := (31 / 4)) (s := 923521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 8 14) : - 0 ≤ distillCritical2 28 x := by - refine (BernsteinCert.coeffs_pos - [13769, 847223, 3360153, 4524719, 2016812] - (lo := 8) (hi := 14) (s := 162) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : - distillT2 28 α ≤ (101 / 500) := by - apply distillT2_le_of_critical (l := (31 / 4)) (r := 8) (d := 14) - 25 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow28 - -theorem distillFinite_28 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 14) : - distillEBudget 28 + distillT0 28 α + distillT1 28 α + distillT2 28 α ≤ (5501 / 6000) := by - have h0 := CriticalRow28.component0 α hα hd - have h1 := CriticalRow28.component1 α hα hd - have h2 := CriticalRow28.component2 α hα hd - calc - _ ≤ distillEBudget 28 + (141 / 500) + (81 / 500) + (101 / 500) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (5501 / 6000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_28 : ((5501 / 6000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end diff --git a/Sendov/DistillationFinite/Rows29_36.lean b/Sendov/DistillationFinite/Rows29_36.lean deleted file mode 100644 index 413e522..0000000 --- a/Sendov/DistillationFinite/Rows29_36.lean +++ /dev/null @@ -1,953 +0,0 @@ -import Sendov.Common.DistillationCriticalFinite -import Sendov.Common.BernsteinList - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow29 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 9) : - 0 ≤ distillCritical0 29 x := by - refine (BernsteinCert.coeffs_pos - [197780, 3488992, 24198318, 83590720, 151154120, 140565393, 62268338, 1040539] - (lo := 0) (hi := 9) (s := 2187) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (37 / 4) (29 / 2)) : - 0 ≤ -distillCritical0 29 x := by - refine (BernsteinCert.coeffs_pos - [3365009093848, 225248328637816, 1701585339576240, 5636574293296640, 10125674930489600, - 10333620443687808, 5669434720615168, 1305691412116480] - (lo := (37 / 4)) (hi := (29 / 2)) (s := 257298363) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : - distillT0 29 α ≤ (283 / 1000) := by - apply distillT0_le_of_critical (l := 9) (r := (37 / 4)) (d := (29 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (37 / 4)) : - 0 ≤ -distillCritical1 29 x := by - refine (BernsteinCert.coeffs_pos - [82561740963840, 1545252498210816, 11528781702340608, 43691654914836480, - 88744704573081984, 93213389812990880, 42340381608252144, 546067555464592] - (lo := 0) (hi := (37 / 4)) (s := 94931877133) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 2) (29 / 2)) : - 0 ≤ distillCritical1 29 x := by - refine (BernsteinCert.coeffs_pos - [59461268712, 2904147866329, 21016658198312, 67640225648945, 118241015368320, - 117227207292427, 62291372501104, 13841798528747] - (lo := (19 / 2)) (hi := (29 / 2)) (s := 125000) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : - distillT1 29 α ≤ (81 / 500) := by - apply distillT1_le_of_critical (l := (37 / 4)) (r := (19 / 2)) (d := (29 / 2)) - 26 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 8) : - 0 ≤ -distillCritical2 29 x := by - refine (BernsteinCert.coeffs_pos - [152685, 1296540, 3242406, 2273324, 55989] - (lo := 0) (hi := 8) (s := 1024) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 4) (29 / 2)) : - 0 ≤ distillCritical2 29 x := by - refine (BernsteinCert.coeffs_pos - [2306556, 370203624, 1518559536, 2074659424, 933059456] - (lo := (33 / 4)) (hi := (29 / 2)) (s := 78125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : - distillT2 29 α ≤ (207 / 1000) := by - apply distillT2_le_of_critical (l := 8) (r := (33 / 4)) (d := (29 / 2)) - 26 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow29 - -theorem distillFinite_29 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (29 / 2)) : - distillEBudget 29 + distillT0 29 α + distillT1 29 α + distillT2 29 α ≤ (10028 / 10875) := by - have h0 := CriticalRow29.component0 α hα hd - have h1 := CriticalRow29.component1 α hα hd - have h2 := CriticalRow29.component2 α hα hd - calc - _ ≤ distillEBudget 29 + (283 / 1000) + (81 / 500) + (207 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (10028 / 10875) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_29 : ((10028 / 10875) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow30 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (19 / 2)) : - 0 ≤ distillCritical0 30 x := by - refine (BernsteinCert.coeffs_pos - [59458406400, 1085950126080, 7774295811840, 27590328241920, 50896812815424, - 47958547091760, 21722649776040, 85582967880] - (lo := 0) (hi := (19 / 2)) (s := 893871739) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (39 / 4) 15) : - 0 ≤ -distillCritical0 30 x := by - refine (BernsteinCert.coeffs_pos - [30938144928, 1046274794768, 7267036504896, 23185203672064, 40666332743680, - 40751676026880, 22014264688640, 4998856704000] - (lo := (39 / 4)) (hi := 15) (s := 823543) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : - distillT0 30 α ≤ (71 / 250) := by - apply distillT0_le_of_critical (l := (19 / 2)) (r := (39 / 4)) (d := 15) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (39 / 4)) : - 0 ≤ -distillCritical1 30 x := by - refine (BernsteinCert.coeffs_pos - [41897164800, 811945492480, 6259018383360, 24436949258240, 50941706289408, - 54707108281152, 25370825388576, 124412060016] - (lo := 0) (hi := (39 / 4)) (s := 62748517) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 10 15) : - 0 ≤ distillCritical1 30 x := by - refine (BernsteinCert.coeffs_pos - [3037223088, 102525926208, 701995390560, 2199334347360, 3774932441820, 3688383688128, - 1935210028068, 425057271840] - (lo := 10) (hi := 15) (s := 3125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : - distillT1 30 α ≤ (81 / 500) := by - apply distillT1_le_of_critical (l := (39 / 4)) (r := 10) (d := 15) - 27 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (17 / 2)) : - 0 ≤ -distillCritical2 30 x := by - refine (BernsteinCert.coeffs_pos - [10497600, 92443680, 237338280, 165581964, 501328] - (lo := 0) (hi := (17 / 2)) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (35 / 4) 15) : - 0 ≤ distillCritical2 30 x := by - refine (BernsteinCert.coeffs_pos - [2902028, 95820792, 362222208, 477505152, 210014208] - (lo := (35 / 4)) (hi := 15) (s := 15625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : - distillT2 30 α ≤ (53 / 250) := by - apply distillT2_le_of_critical (l := (17 / 2)) (r := (35 / 4)) (d := 15) - 27 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow30 - -theorem distillFinite_30 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 15) : - distillEBudget 30 + distillT0 30 α + distillT1 30 α + distillT2 30 α ≤ (8347 / 9000) := by - have h0 := CriticalRow30.component0 α hα hd - have h1 := CriticalRow30.component1 α hα hd - have h2 := CriticalRow30.component2 α hα hd - calc - _ ≤ distillEBudget 30 + (71 / 250) + (81 / 500) + (53 / 250) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (8347 / 9000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_30 : ((8347 / 9000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow31 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (39 / 4)) : - 0 ≤ distillCritical0 31 x := by - refine (BernsteinCert.coeffs_pos - [33552138240, 623766847488, 4540664236032, 16359631151616, 30574635908608, - 29180498720752, 13596057413528, 222672713624] - (lo := 0) (hi := (39 / 4)) (s := 564736653) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 10 (31 / 2)) : - 0 ≤ -distillCritical0 31 x := by - refine (BernsteinCert.coeffs_pos - [225435578880, 17266180879616, 131637595733440, 437468013861088, 787146933908688, - 804045361730924, 441344960087348, 101656747262824] - (lo := 10) (hi := (31 / 2)) (s := 19487171) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : - distillT0 31 α ≤ (57 / 200) := by - apply distillT0_le_of_critical (l := (39 / 4)) (r := 10) (d := (31 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 10) : - 0 ≤ -distillCritical1 31 x := by - refine (BernsteinCert.coeffs_pos - [77311179, 1524959784, 11957184495, 47451971880, 100514528985, 109921626124, - 52678060789, 1108527660] - (lo := 0) (hi := 10) (s := 125000) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (41 / 4) (31 / 2)) : - 0 ≤ distillCritical1 31 x := by - refine (BernsteinCert.coeffs_pos - [175051664695024, 38828586873419056, 303923780105488032, 1005941384272358912, - 1783658361378919424, 1783473051877208832, 953008433951074816, 212597817534662656] - (lo := (41 / 4)) (hi := (31 / 2)) (s := 1801088541) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : - distillT1 31 α ≤ (161 / 1000) := by - apply distillT1_le_of_critical (l := 10) (r := (41 / 4)) (d := (31 / 2)) - 28 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (35 / 4)) : - 0 ≤ -distillCritical2 31 x := by - refine (BernsteinCert.coeffs_pos - [5142528, 46179072, 120638208, 85451912, 876748] - (lo := 0) (hi := (35 / 4)) (s := 42875) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 9 (31 / 2)) : - 0 ≤ distillCritical2 31 x := by - refine (BernsteinCert.coeffs_pos - [3439584, 159263280, 620637528, 829540940, 368040184] - (lo := 9) (hi := (31 / 2)) (s := 28561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : - distillT2 31 α ≤ (109 / 500) := by - apply distillT2_le_of_critical (l := (35 / 4)) (r := 9) (d := (31 / 2)) - 28 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow31 - -theorem distillFinite_31 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (31 / 2)) : - distillEBudget 31 + distillT0 31 α + distillT1 31 α + distillT2 31 α ≤ (10844 / 11625) := by - have h0 := CriticalRow31.component0 α hα hd - have h1 := CriticalRow31.component1 α hα hd - have h2 := CriticalRow31.component2 α hα hd - calc - _ ≤ distillEBudget 31 + (57 / 200) + (161 / 1000) + (109 / 500) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (10844 / 11625) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_31 : ((10844 / 11625) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow32 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (41 / 4)) : - 0 ≤ distillCritical0 32 x := by - refine (BernsteinCert.coeffs_pos - [8714295705600, 167446784507904, 1256310382952448, 4644359403872256, 8844419150920704, - 8542597473847040, 4078182123919808, 19928443544304] - (lo := 0) (hi := (41 / 4)) (s := 194754273881) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 2) 16) : - 0 ≤ -distillCritical0 32 x := by - refine (BernsteinCert.coeffs_pos - [60907600080, 2234356822368, 15716019034944, 50406603295104, 88678358294016, - 89041249092608, 48167533867008, 10948007624704] - (lo := (21 / 2)) (hi := 16) (s := 1771561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : - distillT0 32 α ≤ (143 / 500) := by - apply distillT0_le_of_critical (l := (41 / 4)) (r := (21 / 2)) (d := 16) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 2)) : - 0 ≤ -distillCritical1 32 x := by - refine (BernsteinCert.coeffs_pos - [3591045120, 73215256576, 592203874304, 2417611393792, 5248741992704, 5861748113536, - 2868300956864, 40425357264] - (lo := 0) (hi := (21 / 2)) (s := 7411887) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (43 / 4) 16) : - 0 ≤ distillCritical1 32 x := by - refine (BernsteinCert.coeffs_pos - [849882632166704, 54409221776846720, 400426286009455104, 1290051097497143296, - 2247293886519808000, 2216049022292066304, 1170022511241199616, 258160945409294336] - (lo := (43 / 4)) (hi := 16) (s := 1801088541) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : - distillT1 32 α ≤ (161 / 1000) := by - apply distillT1_le_of_critical (l := (21 / 2)) (r := (43 / 4)) (d := 16) - 29 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 9) : - 0 ≤ -distillCritical2 32 x := by - refine (BernsteinCert.coeffs_pos - [9280, 84940, 225684, 162154, 2734] - (lo := 0) (hi := 9) (s := 81) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (37 / 4) 16) : - 0 ≤ distillCritical2 32 x := by - refine (BernsteinCert.coeffs_pos - [34367932, 2704293256, 10863601152, 14715316480, 6583287808] - (lo := (37 / 4)) (hi := 16) (s := 531441) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : - distillT2 32 α ≤ (223 / 1000) := by - apply distillT2_le_of_critical (l := 9) (r := (37 / 4)) (d := 16) - 29 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow32 - -theorem distillFinite_32 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 16) : - distillEBudget 32 + distillT0 32 α + distillT1 32 α + distillT2 32 α ≤ (9007 / 9600) := by - have h0 := CriticalRow32.component0 α hα hd - have h1 := CriticalRow32.component1 α hα hd - have h2 := CriticalRow32.component2 α hα hd - calc - _ ≤ distillEBudget 32 + (143 / 500) + (161 / 1000) + (223 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (9007 / 9600) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_32 : ((9007 / 9600) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow33 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 2)) : - 0 ≤ distillCritical0 33 x := by - refine (BernsteinCert.coeffs_pos - [33200640, 648791808, 4945453632, 18545582496, 35746242560, 34920812276, 17115504588, - 286099272] - (lo := 0) (hi := (21 / 2)) (s := 823543) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (43 / 4) (33 / 2)) : - 0 ≤ -distillCritical0 33 x := by - refine (BernsteinCert.coeffs_pos - [30858499404744, 3012677290638312, 23291304021084528, 77793108841608192, - 140340539631739392, 143579388903355008, 78888657534803712, 18180403202497536] - (lo := (43 / 4)) (hi := (33 / 2)) (s := 3404825447) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : - distillT0 33 α ≤ (143 / 500) := by - apply distillT0_le_of_critical (l := (21 / 2)) (r := (43 / 4)) (d := (33 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 11) : - 0 ≤ -distillCritical1 33 x := by - refine (BernsteinCert.coeffs_pos - [681031800, 14337073872, 119514421728, 501493086432, 1115107545366, 1271095479756, - 635419722018, 4884667668] - (lo := 0) (hi := 11) (s := 1771561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (45 / 4) (33 / 2)) : - 0 ≤ distillCritical1 33 x := by - refine (BernsteinCert.coeffs_pos - [118768488240, 4869217031312, 34046637330016, 107078840929792, 183532073576960, - 178659588595968, 93274775496192, 20369848891392] - (lo := (45 / 4)) (hi := (33 / 2)) (s := 117649) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : - distillT1 33 α ≤ (161 / 1000) := by - apply distillT1_le_of_critical (l := 11) (r := (45 / 4)) (d := (33 / 2)) - 30 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (37 / 4)) : - 0 ≤ -distillCritical2 33 x := by - refine (BernsteinCert.coeffs_pos - [205286400, 1914451200, 5171252256, 3765766920, 86276788] - (lo := 0) (hi := (37 / 4)) (s := 1874161) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (19 / 2) (33 / 2)) : - 0 ≤ distillCritical2 33 x := by - refine (BernsteinCert.coeffs_pos - [11518, 3195873, 13234545, 18159795, 8189181] - (lo := (19 / 2)) (hi := (33 / 2)) (s := 686) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : - distillT2 33 α ≤ (57 / 250) := by - apply distillT2_le_of_critical (l := (37 / 4)) (r := (19 / 2)) (d := (33 / 2)) - 30 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow33 - -theorem distillFinite_33 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (33 / 2)) : - distillEBudget 33 + distillT0 33 α + distillT1 33 α + distillT2 33 α ≤ (3733 / 3960) := by - have h0 := CriticalRow33.component0 α hα hd - have h1 := CriticalRow33.component1 α hα hd - have h2 := CriticalRow33.component2 α hα hd - calc - _ ≤ distillEBudget 33 + (143 / 500) + (161 / 1000) + (57 / 250) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (3733 / 3960) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_33 : ((3733 / 3960) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow34 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 11) : - 0 ≤ distillCritical0 34 x := by - refine (BernsteinCert.coeffs_pos - [603786960, 12176310096, 95533266888, 367170391800, 720353694360, 711325560884, - 357824486244, 2264545576] - (lo := 0) (hi := 11) (s := 19487171) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (45 / 4) 17) : - 0 ≤ -distillCritical0 34 x := by - refine (BernsteinCert.coeffs_pos - [102465371939040, 4219948061984592, 30165632845323840, 97398834911723520, - 171999965329520640, 173136495778705408, 93825271458643968, 21352274804080640] - (lo := (45 / 4)) (hi := 17) (s := 3404825447) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 34 α ≤ (287 / 1000) := by - apply distillT0_le_of_critical (l := 11) (r := (45 / 4)) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 2)) : - 0 ≤ -distillCritical1 34 x := by - refine (BernsteinCert.coeffs_pos - [1050640865280, 22815734455296, 195838903153152, 843980797313280, 1920753970887648, - 2233555576819312, 1141171228981456, 2058573566256] - (lo := 0) (hi := (23 / 2)) (s := 3404825447) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (47 / 4) 17) : - 0 ≤ distillCritical1 34 x := by - refine (BernsteinCert.coeffs_pos - [451252001951824, 14318358312915808, 95869081404545088, 295061851586269184, - 498237870725494784, 479214806220152832, 247569442817720320, 53544450087976960] - (lo := (47 / 4)) (hi := 17) (s := 257298363) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 34 α ≤ (161 / 1000) := by - apply distillT1_le_of_critical (l := (23 / 2)) (r := (47 / 4)) (d := 17) - 31 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (39 / 4)) : - 0 ≤ -distillCritical2 34 x := by - refine (BernsteinCert.coeffs_pos - [8094720, 78055680, 216105248, 156726168, 642652] - (lo := 0) (hi := (39 / 4)) (s := 85683) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 10 17) : - 0 ≤ distillCritical2 34 x := by - refine (BernsteinCert.coeffs_pos - [52380, 2018300, 7751958, 10296810, 4550560] - (lo := 10) (hi := 17) (s := 343) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 34 α ≤ (233 / 1000) := by - apply distillT2_le_of_critical (l := (39 / 4)) (r := 10) (d := 17) - 31 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow34 - -theorem distillFinite_34 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 34 + distillT0 34 α + distillT1 34 α + distillT2 34 α ≤ (12089 / 12750) := by - have h0 := CriticalRow34.component0 α hα hd - have h1 := CriticalRow34.component1 α hα hd - have h2 := CriticalRow34.component2 α hα hd - calc - _ ≤ distillEBudget 34 + (287 / 1000) + (161 / 1000) + (233 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (12089 / 12750) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_34 : ((12089 / 12750) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow35 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (45 / 4)) : - 0 ≤ distillCritical0 35 x := by - refine (BernsteinCert.coeffs_pos - [192217088, 3938992128, 31374428160, 122230658560, 242518571520, 241899403728, - 124716114488, 2191926840] - (lo := 0) (hi := (45 / 4)) (s := 6834375) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 2) 17) : - 0 ≤ -distillCritical0 35 x := by - refine (BernsteinCert.coeffs_pos - [202982156024, 28797496722988, 221414020533916, 727378963157592, 1286334745696064, - 1287738857803520, 691391983685440, 155509792813440] - (lo := (23 / 2)) (hi := 17) (s := 19487171) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 35 α ≤ (287 / 1000) := by - apply distillT0_le_of_critical (l := (45 / 4)) (r := (23 / 2)) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (47 / 4)) : - 0 ≤ -distillCritical1 35 x := by - refine (BernsteinCert.coeffs_pos - [146948633395200, 3241672841134080, 28249095164682240, 123510663437875200, - 285029609881825536, 336599500923801376, 176872630443951952, 2968987875771408] - (lo := 0) (hi := (47 / 4)) (s := 506623120463) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 12 17) : - 0 ≤ distillCritical1 35 x := by - refine (BernsteinCert.coeffs_pos - [8095655808, 1022209280136, 7596239778648, 24103580710680, 41072429520180, - 39499970454118, 20305688774836, 4357432784538] - (lo := 12) (hi := 17) (s := 15625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 35 α ≤ (4 / 25) := by - apply distillT1_le_of_critical (l := (47 / 4)) (r := 12) (d := 17) - 32 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 10) : - 0 ≤ -distillCritical2 35 x := by - refine (BernsteinCert.coeffs_pos - [4536, 44523, 125223, 91991, 955] - (lo := 0) (hi := 10) (s := 50) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (41 / 4) 17) : - 0 ≤ distillCritical2 35 x := by - refine (BernsteinCert.coeffs_pos - [22885540, 1192238344, 4605871776, 6077243008, 2661273088] - (lo := (41 / 4)) (hi := 17) (s := 177147) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 35 α ≤ (239 / 1000) := by - apply distillT2_le_of_critical (l := 10) (r := (41 / 4)) (d := 17) - 32 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow35 - -theorem distillFinite_35 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 35 + distillT0 35 α + distillT1 35 α + distillT2 35 α ≤ (1429 / 1500) := by - have h0 := CriticalRow35.component0 α hα hd - have h1 := CriticalRow35.component1 α hα hd - have h2 := CriticalRow35.component2 α hα hd - calc - _ ≤ distillEBudget 35 + (287 / 1000) + (4 / 25) + (239 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (1429 / 1500) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_35 : ((1429 / 1500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow36 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (47 / 4)) : - 0 ≤ distillCritical0 36 x := by - refine (BernsteinCert.coeffs_pos - [11145125560320, 235364240719872, 1927236725637120, 7687182510084096, 15509440540624896, - 15618680920597248, 8276449656193056, 67386225560688] - (lo := 0) (hi := (47 / 4)) (s := 506623120463) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 12 17) : - 0 ≤ -distillCritical0 36 x := by - refine (BernsteinCert.coeffs_pos - [6959488896, 289632493152, 1995867444096, 6182251432560, 10450523460960, 10052662448016, - 5197576434552, 1126706704776] - (lo := 12) (hi := 17) (s := 78125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 36 α ≤ (287 / 1000) := by - apply distillT0_le_of_critical (l := (47 / 4)) (r := 12) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (49 / 4)) : - 0 ≤ -distillCritical1 36 x := by - refine (BernsteinCert.coeffs_pos - [160159582126080, 3639464830697472, 32615119255928832, 146284385698418688, - 345138974429469696, 415358711642044800, 222986021776233408, 2574684763393776] - (lo := 0) (hi := (49 / 4)) (s := 678223072849) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 2) 17) : - 0 ≤ distillCritical1 36 x := by - refine (BernsteinCert.coeffs_pos - [5164473663280, 268005353881984, 1838845193667744, 5567231374132544, 9132551871822080, - 8485589792050176, 4221711237506560, 877523932011520] - (lo := (25 / 2)) (hi := 17) (s := 1594323) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 36 α ≤ (4 / 25) := by - apply distillT1_le_of_critical (l := (49 / 4)) (r := (25 / 2)) (d := 17) - 33 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (41 / 4)) : - 0 ≤ -distillCritical2 36 x := by - refine (BernsteinCert.coeffs_pos - [246343680, 2460430080, 7027373376, 5225644248, 84568996] - (lo := 0) (hi := (41 / 4)) (s := 2825761) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (21 / 2) 17) : - 0 ≤ distillCritical2 36 x := by - refine (BernsteinCert.coeffs_pos - [2470824, 219597372, 855526104, 1122332400, 487245920] - (lo := (21 / 2)) (hi := 17) (s := 28561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 36 α ≤ (61 / 250) := by - apply distillT2_le_of_critical (l := (41 / 4)) (r := (21 / 2)) (d := 17) - 33 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow36 - -theorem distillFinite_36 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 36 + distillT0 36 α + distillT1 36 α + distillT2 36 α ≤ (51689 / 54000) := by - have h0 := CriticalRow36.component0 α hα hd - have h1 := CriticalRow36.component1 α hα hd - have h2 := CriticalRow36.component2 α hα hd - calc - _ ≤ distillEBudget 36 + (287 / 1000) + (4 / 25) + (61 / 250) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (51689 / 54000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_36 : ((51689 / 54000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end diff --git a/Sendov/DistillationFinite/Rows37_44.lean b/Sendov/DistillationFinite/Rows37_44.lean deleted file mode 100644 index 0419e39..0000000 --- a/Sendov/DistillationFinite/Rows37_44.lean +++ /dev/null @@ -1,951 +0,0 @@ -import Sendov.Common.DistillationCriticalFinite -import Sendov.Common.BernsteinList - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow37 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 12) : - 0 ≤ distillCritical0 37 x := by - refine (BernsteinCert.coeffs_pos - [740925, 15888039, 131983281, 533286819, 1087320151, 1104726613, 599087099, 11285921] - (lo := 0) (hi := 12) (s := 36864) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (49 / 4) 17) : - 0 ≤ -distillCritical0 37 x := by - refine (BernsteinCert.coeffs_pos - [9003700352232, 3968335648531624, 29919083496350480, 94859866319116736, - 161117899442540544, 154495564621041664, 79290449457934336, 17016402316869632] - (lo := (49 / 4)) (hi := 17) (s := 893871739) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 37 α ≤ (287 / 1000) := by - apply distillT0_le_of_critical (l := 12) (r := (49 / 4)) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (51 / 4)) : - 0 ≤ -distillCritical1 37 x := by - refine (BernsteinCert.coeffs_pos - [716610600960, 16760323211264, 154339513262080, 709644967258112, 1710765993932416, - 2097080117760800, 1150458225450064, 7728910782960] - (lo := 0) (hi := (51 / 4)) (s := 3693048057) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 13 17) : - 0 ≤ distillCritical1 37 x := by - refine (BernsteinCert.coeffs_pos - [57904457889, 1903795669685, 12084404188825, 34904838577957, 55124204786619, - 49498253087975, 23843598650891, 4803430007359] - (lo := 13) (hi := 17) (s := 4096) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 37 α ≤ (159 / 1000) := by - apply distillT1_le_of_critical (l := (51 / 4)) (r := 13) (d := 17) - 34 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (21 / 2)) : - 0 ≤ -distillCritical2 37 x := by - refine (BernsteinCert.coeffs_pos - [603840, 6134880, 17787848, 13380860, 288504] - (lo := 0) (hi := (21 / 2)) (s := 7203) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (43 / 4) 17) : - 0 ≤ distillCritical2 37 x := by - refine (BernsteinCert.coeffs_pos - [6234588, 3425706152, 13501220928, 17627386752, 7590949888] - (lo := (43 / 4)) (hi := 17) (s := 390625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 37 α ≤ (249 / 1000) := by - apply distillT2_le_of_critical (l := (21 / 2)) (r := (43 / 4)) (d := 17) - 34 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow37 - -theorem distillFinite_37 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 37 + distillT0 37 α + distillT1 37 α + distillT2 37 α ≤ (21329 / 22200) := by - have h0 := CriticalRow37.component0 α hα hd - have h1 := CriticalRow37.component1 α hα hd - have h2 := CriticalRow37.component2 α hα hd - calc - _ ≤ distillEBudget 37 + (287 / 1000) + (159 / 1000) + (249 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (21329 / 22200) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_37 : ((21329 / 22200) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow38 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 2)) : - 0 ≤ distillCritical0 38 x := by - refine (BernsteinCert.coeffs_pos - [19488024576, 430097651712, 3668847250176, 15163093935360, 31409640413760, - 32182520121296, 17959131355112, 183739085256] - (lo := 0) (hi := (25 / 2)) (s := 1220703125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (51 / 4) 17) : - 0 ≤ -distillCritical0 38 x := by - refine (BernsteinCert.coeffs_pos - [114877510043616, 5092222392625392, 34064628442319808, 101611248598144512, - 164910742970529792, 152014316782931968, 75200397754089472, 15574572477579264] - (lo := (51 / 4)) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 38 α ≤ (287 / 1000) := by - apply distillT0_le_of_critical (l := (25 / 2)) (r := (51 / 4)) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (53 / 4)) : - 0 ≤ -distillCritical1 38 x := by - refine (BernsteinCert.coeffs_pos - [188900514201600, 4543602466553856, 42962852889280512, 202377940809191424, - 498220275127204608, 621777168188123200, 348623477048922592, 794471569575984] - (lo := 0) (hi := (53 / 4)) (s := 1174711139837) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 2) 17) : - 0 ≤ distillCritical1 38 x := by - refine (BernsteinCert.coeffs_pos - [48542894482896, 1166796017363088, 6856519171796784, 18880824351187008, - 28695963607721088, 24900374693969152, 11615736665854720, 2268809693094912] - (lo := (27 / 2)) (hi := 17) (s := 823543) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 38 α ≤ (159 / 1000) := by - apply distillT1_le_of_critical (l := (53 / 4)) (r := (27 / 2)) (d := 17) - 35 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 11) : - 0 ≤ -distillCritical2 38 x := by - refine (BernsteinCert.coeffs_pos - [1077300, 11288700, 33499974, 25110002, 123072] - (lo := 0) (hi := 11) (s := 14641) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (45 / 4) 17) : - 0 ≤ distillCritical2 38 x := by - refine (BernsteinCert.coeffs_pos - [117215100, 4017080520, 14313914304, 17750452096, 7368864768] - (lo := (45 / 4)) (hi := 17) (s := 279841) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 38 α ≤ (127 / 500) := by - apply distillT2_le_of_critical (l := 11) (r := (45 / 4)) (d := 17) - 35 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow38 - -theorem distillFinite_38 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 38 + distillT0 38 α + distillT1 38 α + distillT2 38 α ≤ (2201 / 2280) := by - have h0 := CriticalRow38.component0 α hα hd - have h1 := CriticalRow38.component1 α hα hd - have h2 := CriticalRow38.component2 α hα hd - calc - _ ≤ distillEBudget 38 + (287 / 1000) + (159 / 1000) + (127 / 500) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (2201 / 2280) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_38 : ((2201 / 2280) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow39 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 13) : - 0 ≤ distillCritical0 39 x := by - refine (BernsteinCert.coeffs_pos - [61804620, 1402759296, 12279055842, 51879916800, 109128666960, 112689040779, - 64787473914, 128530077] - (lo := 0) (hi := 13) (s := 4826809) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (53 / 4) 17) : - 0 ≤ -distillCritical0 39 x := by - refine (BernsteinCert.coeffs_pos - [17108813084168, 426903230928200, 2561530252353072, 7192600531282240, 11151744305551360, - 9881122686885888, 4712493719736320, 942298208878592] - (lo := (53 / 4)) (hi := 17) (s := 11390625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 39 α ≤ (287 / 1000) := by - apply distillT0_le_of_critical (l := 13) (r := (53 / 4)) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 2)) : - 0 ≤ -distillCritical1 39 x := by - refine (BernsteinCert.coeffs_pos - [243476480, 5939730944, 56934562560, 271685184640, 677116090048, 856291631496, - 491805745592, 7850018192] - (lo := 0) (hi := (27 / 2)) (s := 1594323) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (55 / 4) 17) : - 0 ≤ distillCritical1 39 x := by - refine (BernsteinCert.coeffs_pos - [776220767172720, 108950263196626416, 741131633020891104, 2142620140767822720, - 3321211317865522176, 2902649874544336896, 1354858682660904960, 263760894951260160] - (lo := (55 / 4)) (hi := 17) (s := 62748517) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 39 α ≤ (79 / 500) := by - apply distillT1_le_of_critical (l := (27 / 2)) (r := (55 / 4)) (d := 17) - 36 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (45 / 4)) : - 0 ≤ -distillCritical2 39 x := by - refine (BernsteinCert.coeffs_pos - [79872, 850688, 2561152, 1941128, 20292] - (lo := 0) (hi := (45 / 4)) (s := 1125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (23 / 2) 17) : - 0 ≤ distillCritical2 39 x := by - refine (BernsteinCert.coeffs_pos - [5150264, 243542764, 876085176, 1081599280, 445604960] - (lo := (23 / 2)) (hi := 17) (s := 14641) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 39 α ≤ (259 / 1000) := by - apply distillT2_le_of_critical (l := (45 / 4)) (r := (23 / 2)) (d := 17) - 36 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow39 - -theorem distillFinite_39 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 39 + distillT0 39 α + distillT1 39 α + distillT2 39 α ≤ (14171 / 14625) := by - have h0 := CriticalRow39.component0 α hα hd - have h1 := CriticalRow39.component1 α hα hd - have h2 := CriticalRow39.component2 α hα hd - calc - _ ≤ distillEBudget 39 + (287 / 1000) + (79 / 500) + (259 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (14171 / 14625) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_39 : ((14171 / 14625) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow40 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (53 / 4)) : - 0 ≤ distillCritical0 40 x := by - refine (BernsteinCert.coeffs_pos - [13874076057600, 319404418007040, 2833672340275200, 12117221835079680, - 25732901382730752, 26766447825685760, 15725130190623360, 196910190955120] - (lo := 0) (hi := (53 / 4)) (s := 1174711139837) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 2) 17) : - 0 ≤ -distillCritical0 40 x := by - refine (BernsteinCert.coeffs_pos - [759374723952, 40137614276256, 263351883650688, 760145428070784, 1188521909766912, - 1052983947921920, 499818697728000, 99188314716160] - (lo := (27 / 2)) (hi := 17) (s := 823543) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 40 α ≤ (287 / 1000) := by - apply distillT0_le_of_critical (l := (53 / 4)) (r := (27 / 2)) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 14) : - 0 ≤ -distillCritical1 40 x := by - refine (BernsteinCert.coeffs_pos - [210644550, 5278767165, 51901770060, 253490323905, 644580351366, 829141605607, - 486430906248, 5795970779] - (lo := 0) (hi := 14) (s := 1647086) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (57 / 4) 17) : - 0 ≤ distillCritical1 40 x := by - refine (BernsteinCert.coeffs_pos - [2950782573731472, 127688744399884992, 791843921285225472, 2177788679780401152, - 3249058594728886272, 2746165907629015040, 1242607876766760960, 234818901464842240] - (lo := (57 / 4)) (hi := 17) (s := 19487171) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 40 α ≤ (79 / 500) := by - apply distillT1_le_of_critical (l := 14) (r := (57 / 4)) (d := 17) - 37 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (23 / 2)) : - 0 ≤ -distillCritical2 40 x := by - refine (BernsteinCert.coeffs_pos - [19180800, 207580320, 633854400, 485505236, 7588800] - (lo := 0) (hi := (23 / 2)) (s := 279841) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (47 / 4) 17) : - 0 ≤ distillCritical2 40 x := by - refine (BernsteinCert.coeffs_pos - [42828748, 3746490232, 13653815136, 16800987520, 6873393664] - (lo := (47 / 4)) (hi := 17) (s := 194481) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 40 α ≤ (33 / 125) := by - apply distillT2_le_of_critical (l := (23 / 2)) (r := (47 / 4)) (d := 17) - 37 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow40 - -theorem distillFinite_40 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 40 + distillT0 40 α + distillT1 40 α + distillT2 40 α ≤ (11683 / 12000) := by - have h0 := CriticalRow40.component0 α hα hd - have h1 := CriticalRow40.component1 α hα hd - have h2 := CriticalRow40.component2 α hα hd - calc - _ ≤ distillEBudget 40 + (287 / 1000) + (79 / 500) + (33 / 125) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (11683 / 12000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_40 : ((11683 / 12000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow41 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (55 / 4)) : - 0 ≤ distillCritical0 41 x := by - refine (BernsteinCert.coeffs_pos - [2920579006464, 69068704333824, 628174873589760, 2743795180500480, 5912462599618560, - 6191155412608784, 3750607427647704, 18608274669400] - (lo := 0) (hi := (55 / 4)) (s := 304487046875) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 14 17) : - 0 ≤ -distillCritical0 41 x := by - refine (BernsteinCert.coeffs_pos - [5357567964, 131396060728, 761367606246, 2058344771400, 3068265007634, 2611112787531, - 1194934814268, 229074420757] - (lo := 14) (hi := 17) (s := 729) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 41 α ≤ (287 / 1000) := by - apply distillT0_le_of_critical (l := (55 / 4)) (r := 14) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 2)) : - 0 ≤ -distillCritical1 41 x := by - refine (BernsteinCert.coeffs_pos - [1860406133760, 47858605843968, 482363396206848, 2409898941272448, 6249119240223120, - 8172874298354392, 4897806317994360, 40044402202160] - (lo := 0) (hi := (29 / 2)) (s := 17249876309) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (59 / 4) 17) : - 0 ≤ distillCritical1 41 x := by - refine (BernsteinCert.coeffs_pos - [1954946700115088, 49133046896914928, 276734364062525664, 721491122377495552, - 1033831048206699520, 844034084905684992, 369985543123558400, 67847736684707840] - (lo := (59 / 4)) (hi := 17) (s := 1594323) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 41 α ≤ (157 / 1000) := by - apply distillT1_le_of_critical (l := (29 / 2)) (r := (59 / 4)) (d := 17) - 38 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 12) : - 0 ≤ -distillCritical2 41 x := by - refine (BernsteinCert.coeffs_pos - [11685, 130200, 406498, 310320, 65] - (lo := 0) (hi := 12) (s := 192) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (49 / 4) 17) : - 0 ≤ distillCritical2 41 x := by - refine (BernsteinCert.coeffs_pos - [183148396, 4368408504, 14343986304, 16743616640, 6600007680] - (lo := (49 / 4)) (hi := 17) (s := 130321) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 41 α ≤ (269 / 1000) := by - apply distillT2_le_of_critical (l := 12) (r := (49 / 4)) (d := 17) - 38 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow41 - -theorem distillFinite_41 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 41 + distillT0 41 α + distillT1 41 α + distillT2 41 α ≤ (120199 / 123000) := by - have h0 := CriticalRow41.component0 α hα hd - have h1 := CriticalRow41.component1 α hα hd - have h2 := CriticalRow41.component2 α hα hd - calc - _ ≤ distillEBudget 41 + (287 / 1000) + (157 / 1000) + (269 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (120199 / 123000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_41 : ((120199 / 123000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow42 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 14) : - 0 ≤ distillCritical0 42 x := by - refine (BernsteinCert.coeffs_pos - [8365275, 200545713, 1847584161, 8163494847, 17749943613, 18703640295, 11565197031, - 172991433] - (lo := 0) (hi := 14) (s := 941192) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (57 / 4) 17) : - 0 ≤ -distillCritical0 42 x := by - refine (BernsteinCert.coeffs_pos - [50358143685600, 4722866446785552, 30972864974370624, 87161941383312384, - 131906545727993856, 112728368793415680, 51507884468355072, 9824558069317632] - (lo := (57 / 4)) (hi := 17) (s := 19487171) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 42 α ≤ (143 / 500) := by - apply distillT0_le_of_critical (l := 14) (r := (57 / 4)) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 15) : - 0 ≤ -distillCritical1 42 x := by - refine (BernsteinCert.coeffs_pos - [1430352, 37746592, 389757280, 1990818240, 5262008180, 6994043912, 4281391932, 20229000] - (lo := 0) (hi := 15) (s := 15625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (61 / 4) 17) : - 0 ≤ distillCritical1 42 x := by - refine (BernsteinCert.coeffs_pos - [9674856523168080, 167584454000488224, 851148203633082432, 2090872947977124864, - 2866264359788132352, 2254521947252908032, 955787252801224704, 169895370516332544] - (lo := (61 / 4)) (hi := 17) (s := 823543) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 42 α ≤ (39 / 250) := by - apply distillT1_le_of_critical (l := 15) (r := (61 / 4)) (d := 17) - 39 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (49 / 4)) : - 0 ≤ -distillCritical2 42 x := by - refine (BernsteinCert.coeffs_pos - [48522240, 548985600, 1737425952, 1339888776, 7395196] - (lo := 0) (hi := (49 / 4)) (s := 823543) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (25 / 2) 17) : - 0 ≤ distillCritical2 42 x := by - refine (BernsteinCert.coeffs_pos - [8875520, 260981420, 865671024, 1007149136, 394345088] - (lo := (25 / 2)) (hi := 17) (s := 6561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 42 α ≤ (137 / 500) := by - apply distillT2_le_of_critical (l := (49 / 4)) (r := (25 / 2)) (d := 17) - 39 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow42 - -theorem distillFinite_42 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 42 + distillT0 42 α + distillT1 42 α + distillT2 42 α ≤ (8819 / 9000) := by - have h0 := CriticalRow42.component0 α hα hd - have h1 := CriticalRow42.component1 α hα hd - have h2 := CriticalRow42.component2 α hα hd - calc - _ ≤ distillEBudget 42 + (143 / 500) + (39 / 250) + (137 / 500) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (8819 / 9000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_42 : ((8819 / 9000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow43 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 2)) : - 0 ≤ distillCritical0 43 x := by - refine (BernsteinCert.coeffs_pos - [125909614080, 3097543037184, 29228204244672, 131813967943008, 290608670169024, - 307939956026780, 196494775761212, 1570609315632] - (lo := 0) (hi := (29 / 2)) (s := 17249876309) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (59 / 4) 17) : - 0 ≤ -distillCritical0 43 x := by - refine (BernsteinCert.coeffs_pos - [241329033437528, 5977566888915992, 33652596827420592, 87893907910468288, - 126297911863822336, 103475167039537152, 45546164845039616, 8391380704477184] - (lo := (59 / 4)) (hi := 17) (s := 4782969) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 43 α ≤ (143 / 500) := by - apply distillT0_le_of_critical (l := (29 / 2)) (r := (59 / 4)) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (31 / 2)) : - 0 ≤ -distillCritical1 43 x := by - refine (BernsteinCert.coeffs_pos - [2150654976000, 58185480135168, 615153183194880, 3210790512868992, 8646426735703392, - 11674976608160744, 7299985660815096, 11266162138960] - (lo := 0) (hi := (31 / 2)) (s := 27512614111) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (63 / 4) 17) : - 0 ≤ distillCritical1 43 x := by - refine (BernsteinCert.coeffs_pos - [14560310642175216, 187570090492658352, 848671241110913376, 1943669075490092160, - 2530096609046799360, 1907218885214683136, 778966818478743552, 133836932648697856] - (lo := (63 / 4)) (hi := 17) (s := 78125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 43 α ≤ (39 / 250) := by - apply distillT1_le_of_critical (l := (31 / 2)) (r := (63 / 4)) (d := 17) - 40 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (25 / 2)) : - 0 ≤ -distillCritical2 43 x := by - refine (BernsteinCert.coeffs_pos - [891648, 10240992, 32845488, 25577092, 268448] - (lo := 0) (hi := (25 / 2)) (s := 15625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (51 / 4) 17) : - 0 ≤ distillCritical2 43 x := by - refine (BernsteinCert.coeffs_pos - [95475996, 3947635080, 13281114720, 15421202048, 6001934848] - (lo := (51 / 4)) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 43 α ≤ (279 / 1000) := by - apply distillT2_le_of_critical (l := (25 / 2)) (r := (51 / 4)) (d := 17) - 40 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow43 - -theorem distillFinite_43 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 43 + distillT0 43 α + distillT1 43 α + distillT2 43 α ≤ (127009 / 129000) := by - have h0 := CriticalRow43.component0 α hα hd - have h1 := CriticalRow43.component1 α hα hd - have h2 := CriticalRow43.component2 α hα hd - calc - _ ≤ distillEBudget 43 + (143 / 500) + (39 / 250) + (279 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (127009 / 129000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_43 : ((127009 / 129000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow44 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 15) : - 0 ≤ distillCritical0 44 x := by - refine (BernsteinCert.coeffs_pos - [849024, 21420384, 206902080, 951954480, 2127248960, 2265354544, 1492973864, 1994520] - (lo := 0) (hi := 15) (s := 140625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (61 / 4) 17) : - 0 ≤ -distillCritical0 44 x := by - refine (BernsteinCert.coeffs_pos - [489004352844208, 7398831200662496, 36110453925835520, 87131692244405760, - 118340961495285760, 92628275178299392, 39178309244813312, 6959933834526720] - (lo := (61 / 4)) (hi := 17) (s := 823543) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 44 α ≤ (143 / 500) := by - apply distillT0_le_of_critical (l := 15) (r := (61 / 4)) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (63 / 4)) : - 0 ≤ -distillCritical1 44 x := by - refine (BernsteinCert.coeffs_pos - [404970536960, 11094654713856, 118722588278784, 626807954698240, 1706103540857856, - 2329365558662016, 1486183128987200, 20728193456400] - (lo := 0) (hi := (63 / 4)) (s := 5403265623) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 16 17) : - 0 ≤ distillCritical1 44 x := by - refine (BernsteinCert.coeffs_pos - [95942262656, 5037386289088, 29415669774880, 75016752584016, 103309075583888, - 80437735436936, 33489634275760, 5818447647000] - (lo := 16) (hi := 17) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 44 α ≤ (31 / 200) := by - apply distillT1_le_of_critical (l := (63 / 4)) (r := 16) (d := 17) - 41 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (51 / 4)) : - 0 ≤ -distillCritical2 44 x := by - refine (BernsteinCert.coeffs_pos - [13854720, 161498880, 524792128, 412470424, 6257148] - (lo := 0) (hi := (51 / 4)) (s := 250563) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 13 17) : - 0 ≤ distillCritical2 44 x := by - refine (BernsteinCert.coeffs_pos - [84467, 7191936, 24672222, 28638280, 11088375] - (lo := 13) (hi := 17) (s := 128) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 44 α ≤ (283 / 1000) := by - apply distillT2_le_of_critical (l := (51 / 4)) (r := 13) (d := 17) - 41 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow44 - -theorem distillFinite_44 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 44 + distillT0 44 α + distillT1 44 α + distillT2 44 α ≤ (65159 / 66000) := by - have h0 := CriticalRow44.component0 α hα hd - have h1 := CriticalRow44.component1 α hα hd - have h2 := CriticalRow44.component2 α hα hd - calc - _ ≤ distillEBudget 44 + (143 / 500) + (31 / 200) + (283 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (65159 / 66000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_44 : ((65159 / 66000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end diff --git a/Sendov/DistillationFinite/Rows45_52.lean b/Sendov/DistillationFinite/Rows45_52.lean deleted file mode 100644 index 9467f0d..0000000 --- a/Sendov/DistillationFinite/Rows45_52.lean +++ /dev/null @@ -1,866 +0,0 @@ -import Sendov.Common.DistillationCriticalFinite -import Sendov.Common.BernsteinList - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow45 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (61 / 4)) : - 0 ≤ distillCritical0 45 x := by - refine (BernsteinCert.coeffs_pos - [290237644800, 7416646778880, 72509269063680, 337237878366720, 759830715528192, - 813132325666224, 546342180873336, 6036468966648] - (lo := 0) (hi := (61 / 4)) (s := 51520374361) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 2) 17) : - 0 ≤ -distillCritical0 45 x := by - refine (BernsteinCert.coeffs_pos - [50773565824, 1370369396604, 7596016567764, 19286176403624, 26824077330624, - 21226642719360, 9012499380160, 1600178663040] - (lo := (31 / 2)) (hi := 17) (s := 81) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 45 α ≤ (57 / 200) := by - apply distillT0_le_of_critical (l := (61 / 4)) (r := (31 / 2)) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (65 / 4)) : - 0 ≤ -distillCritical1 45 x := by - refine (BernsteinCert.coeffs_pos - [972618596352, 27292873162752, 298783919185920, 1610716128675840, 4463609951479680, - 6186323178993312, 4028997769033392, 44180834863440] - (lo := 0) (hi := (65 / 4)) (s := 15083778125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 2) 17) : - 0 ≤ distillCritical1 45 x := by - refine (BernsteinCert.coeffs_pos - [43680994075152, 639217250353944, 2962724704861608, 6756753144769056, 8655355325189952, - 6381837711308160, 2540535059687040, 424487977443840] - (lo := (33 / 2)) (hi := 17) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 45 α ≤ (77 / 500) := by - apply distillT1_le_of_critical (l := (65 / 4)) (r := (33 / 2)) (d := 17) - 42 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (53 / 4)) : - 0 ≤ -distillCritical2 45 x := by - refine (BernsteinCert.coeffs_pos - [391910400, 4694319360, 15578252640, 12206129352, 14989876] - (lo := 0) (hi := (53 / 4)) (s := 7890481) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (27 / 2) 17) : - 0 ≤ distillCritical2 45 x := by - refine (BernsteinCert.coeffs_pos - [13856832, 269184060, 818275392, 896135952, 333466304] - (lo := (27 / 2)) (hi := 17) (s := 2401) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 45 α ≤ (36 / 125) := by - apply distillT2_le_of_critical (l := (53 / 4)) (r := (27 / 2)) (d := 17) - 42 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow45 - -theorem distillFinite_45 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 45 + distillT0 45 α + distillT1 45 α + distillT2 45 α ≤ (26729 / 27000) := by - have h0 := CriticalRow45.component0 α hα hd - have h1 := CriticalRow45.component1 α hα hd - have h2 := CriticalRow45.component2 α hα hd - calc - _ ≤ distillEBudget 45 + (57 / 200) + (77 / 500) + (36 / 125) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (26729 / 27000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_45 : ((26729 / 27000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow46 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (63 / 4)) : - 0 ≤ distillCritical0 46 x := by - refine (BernsteinCert.coeffs_pos - [8471183360, 221793746944, 2217872498688, 10516706271232, 24002114307584, - 25786587097152, 17905381361840, 87406488928] - (lo := 0) (hi := (63 / 4)) (s := 1801088541) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 16 17) : - 0 ≤ -distillCritical0 46 x := by - refine (BernsteinCert.coeffs_pos - [27745483632, 363311005264, 1644423464696, 3749437851896, 4849062858456, 3627803822260, - 1469701213876, 250380345416] - (lo := 16) (hi := 17) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 46 α ≤ (71 / 250) := by - apply distillT0_le_of_critical (l := (63 / 4)) (r := 16) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (67 / 4)) : - 0 ≤ -distillCritical1 46 x := by - refine (BernsteinCert.coeffs_pos - [337937903124480, 9707731313688576, 108665645425606656, 597885756027826176, - 1686200738344827648, 2371417002819163328, 1576375325028149600, 12926181583597584] - (lo := 0) (hi := (67 / 4)) (s := 6060711605323) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 46 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 46 α ≤ (153 / 1000) := by - apply distillT1_le_of_critical (l := (67 / 4)) (r := 17) (d := 17) - 43 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (27 / 2)) : - 0 ≤ -distillCritical2 46 x := by - refine (BernsteinCert.coeffs_pos - [316480, 3844960, 12921576, 10215556, 61384] - (lo := 0) (hi := (27 / 2)) (s := 6561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (55 / 4) 17) : - 0 ≤ distillCritical2 46 x := by - refine (BernsteinCert.coeffs_pos - [167510220, 3983957720, 12285681216, 13442494080, 4976573440] - (lo := (55 / 4)) (hi := 17) (s := 28561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 46 α ≤ (73 / 250) := by - apply distillT2_le_of_critical (l := (27 / 2)) (r := (55 / 4)) (d := 17) - 43 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow46 - -theorem distillFinite_46 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 46 + distillT0 46 α + distillT1 46 α + distillT2 46 α ≤ (34213 / 34500) := by - have h0 := CriticalRow46.component0 α hα hd - have h1 := CriticalRow46.component1 α hα hd - have h2 := CriticalRow46.component2 α hα hd - calc - _ ≤ distillEBudget 46 + (71 / 250) + (153 / 1000) + (73 / 250) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (34213 / 34500) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_46 : ((34213 / 34500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow47 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 16) : - 0 ≤ distillCritical0 47 x := by - refine (BernsteinCert.coeffs_pos - [295518375, 7833043521, 79245659475, 379695923109, 873366376341, 942092902915, - 666360453681, 9399522263] - (lo := 0) (hi := 16) (s := 67108864) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (65 / 4) 17) : - 0 ≤ -distillCritical0 47 x := by - refine (BernsteinCert.coeffs_pos - [15397621242280, 818716375621736, 4739759707551024, 11971051892787776, - 16322765186136064, 12582209027776512, 5186046842884096, 891992064671744] - (lo := (65 / 4)) (hi := 17) (s := 729) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 47 α ≤ (283 / 1000) := by - apply distillT0_le_of_critical (l := 16) (r := (65 / 4)) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 47 x := by - refine (BernsteinCert.coeffs_pos - [22018774320, 640022273064, 7246161961272, 40299639569208, 114791086917888, - 163061805712510, 110369826011992, 2152820201154] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 47 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 47 α ≤ (69 / 500) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 44 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (55 / 4)) : - 0 ≤ -distillCritical2 47 x := by - refine (BernsteinCert.coeffs_pos - [7796736, 96056064, 326839296, 260620744, 2741276] - (lo := 0) (hi := (55 / 4)) (s := 166375) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 14 17) : - 0 ≤ distillCritical2 47 x := by - refine (BernsteinCert.coeffs_pos - [139232, 4710300, 14830440, 16246586, 5990346] - (lo := 14) (hi := 17) (s := 27) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 47 α ≤ (297 / 1000) := by - apply distillT2_le_of_critical (l := (55 / 4)) (r := 14) (d := 17) - 44 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow47 - -theorem distillFinite_47 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 47 + distillT0 47 α + distillT1 47 α + distillT2 47 α ≤ (69119 / 70500) := by - have h0 := CriticalRow47.component0 α hα hd - have h1 := CriticalRow47.component1 α hα hd - have h2 := CriticalRow47.component2 α hα hd - calc - _ ≤ distillEBudget 47 + (283 / 1000) + (69 / 500) + (297 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (69119 / 70500) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_47 : ((69119 / 70500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow48 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (33 / 2)) : - 0 ≤ distillCritical0 48 x := by - refine (BernsteinCert.coeffs_pos - [72253440, 1960587264, 20272389120, 98967977472, 230462447744, 249313304256, - 182338790368, 1525585584] - (lo := 0) (hi := (33 / 2)) (s := 19487171) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (67 / 4) 17) : - 0 ≤ -distillCritical0 48 x := by - refine (BernsteinCert.coeffs_pos - [354897485095728, 3321802657734528, 12535233892807680, 25272279824701440, - 29751451415629824, 20598821852184576, 7802772844707840, 1251451303624704] - (lo := (67 / 4)) (hi := 17) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 48 α ≤ (283 / 1000) := by - apply distillT0_le_of_critical (l := (33 / 2)) (r := (67 / 4)) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 48 x := by - refine (BernsteinCert.coeffs_pos - [23472633600, 682648733664, 7735092314688, 43076728701936, 123004760598432, - 175655443877280, 120622004139648, 5124511031136] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 48 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 48 α ≤ (17 / 125) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 45 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 14) : - 0 ≤ -distillCritical2 48 x := by - refine (BernsteinCert.coeffs_pos - [218700, 2731725, 9409023, 7564833, 111803] - (lo := 0) (hi := 14) (s := 4802) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (57 / 4) 17) : - 0 ≤ distillCritical2 48 x := by - refine (BernsteinCert.coeffs_pos - [39639132, 3205489032, 10401612768, 11441562240, 4207497728] - (lo := (57 / 4)) (hi := 17) (s := 14641) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 48 α ≤ (301 / 1000) := by - apply distillT2_le_of_critical (l := 14) (r := (57 / 4)) (d := 17) - 45 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow48 - -theorem distillFinite_48 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 48 + distillT0 48 α + distillT1 48 α + distillT2 48 α ≤ (14143 / 14400) := by - have h0 := CriticalRow48.component0 α hα hd - have h1 := CriticalRow48.component1 α hα hd - have h2 := CriticalRow48.component2 α hα hd - calc - _ ≤ distillEBudget 48 + (283 / 1000) + (17 / 125) + (301 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (14143 / 14400) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_48 : ((14143 / 14400) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow49 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 49 x := by - refine (BernsteinCert.coeffs_pos - [1288099260, 35762656032, 377764755210, 1878357794400, 4426800113640, 4799762567483, - 3632062300638, 10457952385] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 49 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 49 α ≤ (261 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 49 x := by - refine (BernsteinCert.coeffs_pos - [24988982760, 727119719136, 8245372912704, 45976583685600, 131587201045986, - 188822483951056, 131343227181150, 8257413991640] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 49 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 49 α ≤ (131 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 46 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (29 / 2)) : - 0 ≤ -distillCritical2 49 x := by - refine (BernsteinCert.coeffs_pos - [29211840, 374297760, 1315193064, 1054320500, 2168760] - (lo := 0) (hi := (29 / 2)) (s := 707281) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (59 / 4) 17) : - 0 ≤ distillCritical2 49 x := by - refine (BernsteinCert.coeffs_pos - [262554076, 3805372264, 10565597184, 10819327360, 3797309440] - (lo := (59 / 4)) (hi := 17) (s := 6561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 49 α ≤ (153 / 500) := by - apply distillT2_le_of_critical (l := (29 / 2)) (r := (59 / 4)) (d := 17) - 46 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow49 - -theorem distillFinite_49 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 49 + distillT0 49 α + distillT1 49 α + distillT2 49 α ≤ (10079 / 10500) := by - have h0 := CriticalRow49.component0 α hα hd - have h1 := CriticalRow49.component1 α hα hd - have h2 := CriticalRow49.component2 α hα hd - calc - _ ≤ distillEBudget 49 + (261 / 1000) + (131 / 1000) + (153 / 500) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (10079 / 10500) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_49 : ((10079 / 10500) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow50 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 50 x := by - refine (BernsteinCert.coeffs_pos - [1342818000, 37306118160, 394455786120, 1964449373400, 4642104191448, 5052406955660, - 3827026759700, 97192809600] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 50 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 50 α ≤ (13 / 50) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 50 x := by - refine (BernsteinCert.coeffs_pos - [26569134000, 773474158080, 8777456969760, 49001824005120, 140546263845804, - 202574751551680, 142542015870100, 11553875896800] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 50 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 50 α ≤ (63 / 500) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 47 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (59 / 4)) : - 0 ≤ -distillCritical2 50 x := by - refine (BernsteinCert.coeffs_pos - [487296000, 6327002880, 22495133280, 18177472424, 116432148] - (lo := 0) (hi := (59 / 4)) (s := 12117361) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 15 17) : - 0 ≤ distillCritical2 50 x := by - refine (BernsteinCert.coeffs_pos - [188325, 3241035, 9169935, 9407797, 3291036] - (lo := 15) (hi := 17) (s := 4) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 50 α ≤ (31 / 100) := by - apply distillT2_le_of_critical (l := (59 / 4)) (r := 15) (d := 17) - 47 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow50 - -theorem distillFinite_50 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 50 + distillT0 50 α + distillT1 50 α + distillT2 50 α ≤ (2873 / 3000) := by - have h0 := CriticalRow50.component0 α hα hd - have h1 := CriticalRow50.component1 α hα hd - have h2 := CriticalRow50.component2 α hα hd - calc - _ ≤ distillEBudget 50 + (13 / 50) + (63 / 500) + (31 / 100) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (2873 / 3000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_50 : ((2873 / 3000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow51 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 51 x := by - refine (BernsteinCert.coeffs_pos - [82274940, 2287182096, 24206166522, 120731122728, 286011625536, 312360961923, - 236690749410, 10813061517] - (lo := 0) (hi := 17) (s := 24137569) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 51 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 51 α ≤ (129 / 500) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 51 x := by - refine (BernsteinCert.coeffs_pos - [1659670560, 48338292888, 548929276488, 3067945243848, 8817047328420, 12760239546882, - 9072170055300, 883308444750] - (lo := 0) (hi := 17) (s := 24137569) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 51 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 51 α ≤ (3 / 25) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 48 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 15) : - 0 ≤ -distillCritical2 51 x := by - refine (BernsteinCert.coeffs_pos - [4896, 64404, 231656, 188634, 1986] - (lo := 0) (hi := 15) (s := 125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (61 / 4) 17) : - 0 ≤ distillCritical2 51 x := by - refine (BernsteinCert.coeffs_pos - [115683404, 2779929784, 8111817696, 8372924800, 2925632000] - (lo := (61 / 4)) (hi := 17) (s := 2401) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 51 α ≤ (157 / 500) := by - apply distillT2_le_of_critical (l := 15) (r := (61 / 4)) (d := 17) - 48 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow51 - -theorem distillFinite_51 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 51 + distillT0 51 α + distillT1 51 α + distillT2 51 α ≤ (36469 / 38250) := by - have h0 := CriticalRow51.component0 α hα hd - have h1 := CriticalRow51.component1 α hα hd - have h2 := CriticalRow51.component2 α hα hd - calc - _ ≤ distillEBudget 51 + (129 / 500) + (3 / 25) + (157 / 500) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (36469 / 38250) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_51 : ((36469 / 38250) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow52 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 52 x := by - refine (BernsteinCert.coeffs_pos - [1455667200, 40490588448, 428911889472, 2142296933328, 5087080441632, 5572950758576, - 4222210241448, 270345660952] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 52 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 52 α ≤ (32 / 125) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 52 x := by - refine (BernsteinCert.coeffs_pos - [29926091520, 871989110784, 9908848318752, 55438938591408, 159625678843248, - 231882271804840, 166406373124752, 18646863797624] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 52 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 52 α ≤ (113 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 49 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (61 / 4)) : - 0 ≤ -distillCritical2 52 x := by - refine (BernsteinCert.coeffs_pos - [528353280, 7040183040, 25614141504, 21011917304, 303488004] - (lo := 0) (hi := (61 / 4)) (s := 13845841) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (31 / 2) 17) : - 0 ≤ distillCritical2 52 x := by - refine (BernsteinCert.coeffs_pos - [1919632, 136650532, 420486648, 439755280, 154008928] - (lo := (31 / 2)) (hi := 17) (s := 81) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 52 α ≤ (159 / 500) := by - apply distillT2_le_of_critical (l := (61 / 4)) (r := (31 / 2)) (d := 17) - 49 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow52 - -theorem distillFinite_52 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 52 + distillT0 52 α + distillT1 52 α + distillT2 52 α ≤ (73961 / 78000) := by - have h0 := CriticalRow52.component0 α hα hd - have h1 := CriticalRow52.component1 α hα hd - have h2 := CriticalRow52.component2 α hα hd - calc - _ ≤ distillEBudget 52 + (32 / 125) + (113 / 1000) + (159 / 500) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (73961 / 78000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_52 : ((73961 / 78000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end diff --git a/Sendov/DistillationFinite/Rows53_55.lean b/Sendov/DistillationFinite/Rows53_55.lean deleted file mode 100644 index 72f5c0a..0000000 --- a/Sendov/DistillationFinite/Rows53_55.lean +++ /dev/null @@ -1,311 +0,0 @@ -import Sendov.Common.DistillationCriticalFinite -import Sendov.Common.BernsteinList - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow53 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 53 x := by - refine (BernsteinCert.coeffs_pos - [1513797660, 42131596608, 446676961914, 2234052914256, 5316752614008, 5840850173315, - 4422429264134, 356763655089] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 53 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 53 α ≤ (127 / 500) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 53 x := by - refine (BernsteinCert.coeffs_pos - [31705522200, 924227481744, 10509062039568, 58856051828016, 169761742211382, - 247461175693060, 179088983157658, 22448083421556] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 53 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 53 α ≤ (21 / 200) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 50 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (63 / 4)) : - 0 ≤ -distillCritical2 53 x := by - refine (BernsteinCert.coeffs_pos - [6784000, 92588800, 343321056, 280846744, 770692] - (lo := 0) (hi := (63 / 4)) (s := 194481) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 16 17) : - 0 ≤ distillCritical2 53 x := by - refine (BernsteinCert.coeffs_pos - [1190908, 10662876, 25488990, 23772974, 7756068] - (lo := 16) (hi := 17) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 53 α ≤ (161 / 500) := by - apply distillT2_le_of_critical (l := (63 / 4)) (r := 16) (d := 17) - 50 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow53 - -theorem distillFinite_53 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 53 + distillT0 53 α + distillT1 53 α + distillT2 53 α ≤ (149779 / 159000) := by - have h0 := CriticalRow53.component0 α hα hd - have h1 := CriticalRow53.component1 α hα hd - have h2 := CriticalRow53.component2 α hα hd - calc - _ ≤ distillEBudget 53 + (127 / 500) + (21 / 200) + (161 / 500) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (149779 / 159000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_53 : ((149779 / 159000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow54 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 54 x := by - refine (BernsteinCert.coeffs_pos - [1573065360, 43805120112, 464800048200, 2327697029160, 5551214151240, 6113834596908, - 4624399808028, 443076028200] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 54 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 54 α ≤ (251 / 1000) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 54 x := by - refine (BernsteinCert.coeffs_pos - [33554003760, 978505020576, 11132892077184, 62409028340160, 180305850272796, - 263672609579496, 192283241772420, 26422249246680] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 54 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 54 α ≤ (49 / 500) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 51 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 16) : - 0 ≤ -distillCritical2 54 x := by - refine (BernsteinCert.coeffs_pos - [557685, 7706340, 28893294, 23805444, 160261] - (lo := 0) (hi := 16) (s := 16384) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (65 / 4) 17) : - 0 ≤ distillCritical2 54 x := by - refine (BernsteinCert.coeffs_pos - [216994460, 2042940200, 4922556096, 4586464640, 1489863680] - (lo := (65 / 4)) (hi := 17) (s := 81) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 54 α ≤ (163 / 500) := by - apply distillT2_le_of_critical (l := 16) (r := (65 / 4)) (d := 17) - 51 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow54 - -theorem distillFinite_54 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 54 + distillT0 54 α + distillT1 54 α + distillT2 54 α ≤ (379 / 405) := by - have h0 := CriticalRow54.component0 α hα hd - have h1 := CriticalRow54.component1 α hα hd - have h2 := CriticalRow54.component2 α hα hd - calc - _ ≤ distillEBudget 54 + (251 / 1000) + (49 / 500) + (163 / 500) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (379 / 405) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_54 : ((379 / 405) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow55 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 55 x := by - refine (BernsteinCert.coeffs_pos - [1633470300, 45511158960, 483281148330, 2423229278040, 5790465053328, 6391904029355, - 4828121873130, 529282780285] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 55 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 55 α ≤ (31 / 125) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 55 x := by - refine (BernsteinCert.coeffs_pos - [35472848400, 1034860655880, 11780791646040, 66100487612760, 191265858612744, - 280528399081990, 205997669702640, 30571708087130] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 55 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 55 α ≤ (91 / 1000) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 52 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (65 / 4)) : - 0 ≤ -distillCritical2 55 x := by - refine (BernsteinCert.coeffs_pos - [1824768, 25526016, 96754560, 80269864, 845252] - (lo := 0) (hi := (65 / 4)) (s := 54925) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (33 / 2) 17) : - 0 ≤ distillCritical2 55 x := by - refine (BernsteinCert.coeffs_pos - [7531920, 80886852, 200203608, 187915664, 61067104] - (lo := (33 / 2)) (hi := 17) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 55 α ≤ (33 / 100) := by - apply distillT2_le_of_critical (l := (65 / 4)) (r := (33 / 2)) (d := 17) - 52 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow55 - -theorem distillFinite_55 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 55 + distillT0 55 α + distillT1 55 α + distillT2 55 α ≤ (30677 / 33000) := by - have h0 := CriticalRow55.component0 α hα hd - have h1 := CriticalRow55.component1 α hα hd - have h2 := CriticalRow55.component2 α hα hd - calc - _ ≤ distillEBudget 55 + (31 / 125) + (91 / 1000) + (33 / 100) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (30677 / 33000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_55 : ((30677 / 33000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end diff --git a/Sendov/DistillationFinite/Rows5_12.lean b/Sendov/DistillationFinite/Rows5_12.lean deleted file mode 100644 index 8df588f..0000000 --- a/Sendov/DistillationFinite/Rows5_12.lean +++ /dev/null @@ -1,941 +0,0 @@ -import Sendov.Common.DistillationCriticalFinite -import Sendov.Common.BernsteinList - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow5 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (1 / 2)) : - 0 ≤ distillCritical0 5 x := by - refine (BernsteinCert.coeffs_pos - [811814400, 5668081920, 16703858880, 26817130080, 25162157184, 13647499564, 3883427188, - 428541912] - (lo := 0) (hi := (1 / 2)) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 4) (5 / 2)) : - 0 ≤ -distillCritical0 5 x := by - refine (BernsteinCert.coeffs_pos - [3667054680, 133443712440, 939063315600, 3006831250944, 5267101731840, 5254197895040, - 2819499598080, 635350144000] - (lo := (3 / 4)) (hi := (5 / 2)) (s := 117649) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : - distillT0 5 α ≤ (101 / 500) := by - apply distillT0_le_of_critical (l := (1 / 2)) (r := (3 / 4)) (d := (5 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 0) : - 0 ≤ -distillCritical1 5 x := by - exact False.elim (lt_irrefl 0 (hx.1.trans hx.2)) - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (1 / 4) (5 / 2)) : - 0 ≤ distillCritical1 5 x := by - refine (BernsteinCert.coeffs_pos - [12259473776, 1574964910352, 13907088807648, 52400775960064, 105639358896640, - 119707352275200, 72226624540160, 18128870144000] - (lo := (1 / 4)) (hi := (5 / 2)) (s := 4782969) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : - distillT1 5 α ≤ (191 / 1000) := by - apply distillT1_le_of_critical (l := 0) (r := (1 / 4)) (d := (5 / 2)) - 2 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (1 / 2)) : - 0 ≤ -distillCritical2 5 x := by - refine (BernsteinCert.coeffs_pos - [129600, 462240, 574680, 277028, 34872] - (lo := 0) (hi := (1 / 2)) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 4) (5 / 2)) : - 0 ≤ distillCritical2 5 x := by - refine (BernsteinCert.coeffs_pos - [105732, 1927944, 6663120, 8426720, 3625600] - (lo := (3 / 4)) (hi := (5 / 2)) (s := 343) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : - distillT2 5 α ≤ (37 / 250) := by - apply distillT2_le_of_critical (l := (1 / 2)) (r := (3 / 4)) (d := (5 / 2)) - 2 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow5 - -theorem distillFinite_5 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (5 / 2)) : - distillEBudget 5 + distillT0 5 α + distillT1 5 α + distillT2 5 α ≤ (2723 / 3000) := by - have h0 := CriticalRow5.component0 α hα hd - have h1 := CriticalRow5.component1 α hα hd - have h2 := CriticalRow5.component2 α hα hd - calc - _ ≤ distillEBudget 5 + (101 / 500) + (191 / 1000) + (37 / 250) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (2723 / 3000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_5 : ((2723 / 3000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow6 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 1) : - 0 ≤ distillCritical0 6 x := by - refine (BernsteinCert.coeffs_pos - [11022480, 81636336, 251574984, 413183592, 381933576, 188980524, 39624636, 351048] - (lo := 0) (hi := 1) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 4) 3) : - 0 ≤ -distillCritical0 6 x := by - refine (BernsteinCert.coeffs_pos - [27728275200, 447127232784, 2514208985280, 7143254756352, 11535924344832, - 10802251984896, 5493577531392, 1179296464896] - (lo := (5 / 4)) (hi := 3) (s := 117649) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : - distillT0 6 α ≤ (207 / 1000) := by - apply distillT0_le_of_critical (l := 1) (r := (5 / 4)) (d := 3) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (1 / 2)) : - 0 ≤ -distillCritical1 6 x := by - refine (BernsteinCert.coeffs_pos - [2620200960, 18010708992, 51883587072, 80528401152, 71711489376, 35657006256, - 8597748720, 616902768] - (lo := 0) (hi := (1 / 2)) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 4) 3) : - 0 ≤ distillCritical1 6 x := by - refine (BernsteinCert.coeffs_pos - [15436880, 339621280, 2286850752, 7499530240, 13737961472, 14430855168, 8162164736, - 1934098432] - (lo := (3 / 4)) (hi := 3) (s := 243) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : - distillT1 6 α ≤ (171 / 1000) := by - apply distillT1_le_of_critical (l := (1 / 2)) (r := (3 / 4)) (d := 3) - 3 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 4)) : - 0 ≤ -distillCritical2 6 x := by - refine (BernsteinCert.coeffs_pos - [46080, 172800, 225184, 113320, 14740] - (lo := 0) (hi := (3 / 4)) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 1 3) : - 0 ≤ distillCritical2 6 x := by - refine (BernsteinCert.coeffs_pos - [509, 17451, 66087, 87237, 38556] - (lo := 1) (hi := 3) (s := 4) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : - distillT2 6 α ≤ (133 / 1000) := by - apply distillT2_le_of_critical (l := (3 / 4)) (r := 1) (d := 3) - 3 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow6 - -theorem distillFinite_6 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 3) : - distillEBudget 6 + distillT0 6 α + distillT1 6 α + distillT2 6 α ≤ (1931 / 2250) := by - have h0 := CriticalRow6.component0 α hα hd - have h1 := CriticalRow6.component1 α hα hd - have h2 := CriticalRow6.component2 α hα hd - calc - _ ≤ distillEBudget 6 + (207 / 1000) + (171 / 1000) + (133 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (1931 / 2250) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_6 : ((1931 / 2250) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow7 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 4)) : - 0 ≤ distillCritical0 7 x := by - refine (BernsteinCert.coeffs_pos - [55180984320, 429810499584, 1395082082304, 2422130895360, 2386652858880, 1285853794480, - 316795014504, 15850500584] - (lo := 0) (hi := (5 / 4)) (s := 15625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 2) (7 / 2)) : - 0 ≤ -distillCritical0 7 x := by - refine (BernsteinCert.coeffs_pos - [185130279, 3942712503, 24603999183, 74279629287, 125273982333, 121470457501, - 63677088141, 14055953093] - (lo := (3 / 2)) (hi := (7 / 2)) (s := 2048) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : - distillT0 7 α ≤ (211 / 1000) := by - apply distillT0_le_of_critical (l := (5 / 4)) (r := (3 / 2)) (d := (7 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 4)) : - 0 ≤ -distillCritical1 7 x := by - refine (BernsteinCert.coeffs_pos - [2835087360, 20677230592, 63304278016, 104741586944, 100016290304, 53990586720, - 14592870576, 1339046832] - (lo := 0) (hi := (3 / 4)) (s := 9) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 1 (7 / 2)) : - 0 ≤ distillCritical1 7 x := by - refine (BernsteinCert.coeffs_pos - [2066664192, 75283502464, 573374903552, 1998803827520, 3808983147120, 4121099547832, - 2388281187064, 578171524112] - (lo := 1) (hi := (7 / 2)) (s := 78125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : - distillT1 7 α ≤ (41 / 250) := by - apply distillT1_le_of_critical (l := (3 / 4)) (r := 1) (d := (7 / 2)) - 4 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 1) : - 0 ≤ -distillCritical2 7 x := by - refine (BernsteinCert.coeffs_pos - [22680, 89100, 121164, 63302, 8442] - (lo := 0) (hi := 1) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 4) (7 / 2)) : - 0 ≤ distillCritical2 7 x := by - refine (BernsteinCert.coeffs_pos - [30220, 22660840, 94130736, 129223648, 58484608] - (lo := (5 / 4)) (hi := (7 / 2)) (s := 6561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : - distillT2 7 α ≤ (31 / 250) := by - apply distillT2_le_of_critical (l := 1) (r := (5 / 4)) (d := (7 / 2)) - 4 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow7 - -theorem distillFinite_7 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (7 / 2)) : - distillEBudget 7 + distillT0 7 α + distillT1 7 α + distillT2 7 α ≤ (2497 / 3000) := by - have h0 := CriticalRow7.component0 α hα hd - have h1 := CriticalRow7.component1 α hα hd - have h2 := CriticalRow7.component2 α hα hd - calc - _ ≤ distillEBudget 7 + (211 / 1000) + (41 / 250) + (31 / 250) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (2497 / 3000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_7 : ((2497 / 3000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow8 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 2)) : - 0 ≤ distillCritical0 8 x := by - refine (BernsteinCert.coeffs_pos - [12533760, 102137856, 346844160, 630770688, 653415296, 373756864, 100918592, 7008816] - (lo := 0) (hi := (3 / 2)) (s := 9) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 4) 4) : - 0 ≤ -distillCritical0 8 x := by - refine (BernsteinCert.coeffs_pos - [131996352688, 4881726753664, 34523100938496, 110994170240000, 195224673419264, - 195581035905024, 105431361912832, 23874173403136] - (lo := (7 / 4)) (hi := 4) (s := 4782969) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : - distillT0 8 α ≤ (43 / 200) := by - apply distillT0_le_of_critical (l := (3 / 2)) (r := (7 / 4)) (d := 4) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 4)) : - 0 ≤ -distillCritical1 8 x := by - refine (BernsteinCert.coeffs_pos - [236967690240, 1859867246592, 6063769976832, 10513297428480, 10225272023040, - 5291040062720, 1138498333952, 151036272] - (lo := 0) (hi := (5 / 4)) (s := 15625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (3 / 2) 4) : - 0 ≤ distillCritical1 8 x := by - refine (BernsteinCert.coeffs_pos - [11560412016, 226336332672, 1443916812096, 4557986760960, 8092194965760, 8270382964736, - 4563174377472, 1056901758976] - (lo := (3 / 2)) (hi := 4) (s := 78125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : - distillT1 8 α ≤ (157 / 1000) := by - apply distillT1_le_of_critical (l := (5 / 4)) (r := (3 / 2)) (d := 4) - 5 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 2)) : - 0 ≤ -distillCritical2 8 x := by - refine (BernsteinCert.coeffs_pos - [19200, 79200, 108352, 50572, 1872] - (lo := 0) (hi := (3 / 2)) (s := 3) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 4) 4) : - 0 ≤ distillCritical2 8 x := by - refine (BernsteinCert.coeffs_pos - [2692492, 45996184, 156390144, 195703552, 83378176] - (lo := (7 / 4)) (hi := 4) (s := 6561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : - distillT2 8 α ≤ (3 / 25) := by - apply distillT2_le_of_critical (l := (3 / 2)) (r := (7 / 4)) (d := 4) - 5 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow8 - -theorem distillFinite_8 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 4) : - distillEBudget 8 + distillT0 8 α + distillT1 8 α + distillT2 8 α ≤ (9779 / 12000) := by - have h0 := CriticalRow8.component0 α hα hd - have h1 := CriticalRow8.component1 α hα hd - have h2 := CriticalRow8.component2 α hα hd - calc - _ ≤ distillEBudget 8 + (43 / 200) + (157 / 1000) + (3 / 25) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (9779 / 12000) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_8 : ((9779 / 12000) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow9 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 2) : - 0 ≤ distillCritical0 9 x := by - refine (BernsteinCert.coeffs_pos - [7971615, 69435063, 250050645, 477017505, 509326785, 289489977, 68863707, 136575] - (lo := 0) (hi := 2) (s := 32) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 4) (9 / 2)) : - 0 ≤ -distillCritical0 9 x := by - refine (BernsteinCert.coeffs_pos - [11570504, 209153320, 1234367760, 3614356480, 5971193600, 5699726976, 2949468416, - 643701760] - (lo := (9 / 4)) (hi := (9 / 2)) (s := 81) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : - distillT0 9 α ≤ (11 / 50) := by - apply distillT0_le_of_critical (l := 2) (r := (9 / 4)) (d := (9 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (3 / 2)) : - 0 ≤ -distillCritical1 9 x := by - refine (BernsteinCert.coeffs_pos - [6589440, 54425088, 187067136, 343290240, 356562864, 201589656, 51591048, 2494368] - (lo := 0) (hi := (3 / 2)) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (7 / 4) (9 / 2)) : - 0 ≤ distillCritical1 9 x := by - refine (BernsteinCert.coeffs_pos - [1374449339568, 38263679796816, 271470993332256, 906577981337088, 1671400180482048, - 1758235947404544, 993743949795840, 235128973547520] - (lo := (7 / 4)) (hi := (9 / 2)) (s := 19487171) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : - distillT1 9 α ≤ (39 / 250) := by - apply distillT1_le_of_critical (l := (3 / 2)) (r := (7 / 4)) (d := (9 / 2)) - 6 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (7 / 4)) : - 0 ≤ -distillCritical2 9 x := by - refine (BernsteinCert.coeffs_pos - [11197440, 48418560, 69561504, 34697496, 2078596] - (lo := 0) (hi := (7 / 4)) (s := 2401) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 2 (9 / 2)) : - 0 ≤ distillCritical2 9 x := by - refine (BernsteinCert.coeffs_pos - [26944, 697056, 2548584, 3304476, 1440504] - (lo := 2) (hi := (9 / 2)) (s := 125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : - distillT2 9 α ≤ (3 / 25) := by - apply distillT2_le_of_critical (l := (7 / 4)) (r := 2) (d := (9 / 2)) - 6 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow9 - -theorem distillFinite_9 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (9 / 2)) : - distillEBudget 9 + distillT0 9 α + distillT1 9 α + distillT2 9 α ≤ (5473 / 6750) := by - have h0 := CriticalRow9.component0 α hα hd - have h1 := CriticalRow9.component1 α hα hd - have h2 := CriticalRow9.component2 α hα hd - calc - _ ≤ distillEBudget 9 + (11 / 50) + (39 / 250) + (3 / 25) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (5473 / 6750) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_9 : ((5473 / 6750) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow10 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 4)) : - 0 ≤ distillCritical0 10 x := by - refine (BernsteinCert.coeffs_pos - [308019200, 2792488960, 10463846400, 20790661120, 23214035456, 13974554304, 3705586832, - 124650592] - (lo := 0) (hi := (9 / 4)) (s := 2187) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 2) 5) : - 0 ≤ -distillCritical0 10 x := by - refine (BernsteinCert.coeffs_pos - [182040744, 4514878184, 29445832240, 91088481280, 156343349760, 153833492864, - 81724139264, 18271559680] - (lo := (5 / 2)) (hi := 5) (s := 3125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : - distillT0 10 α ≤ (9 / 40) := by - apply distillT0_le_of_critical (l := (9 / 4)) (r := (5 / 2)) (d := 5) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (7 / 4)) : - 0 ≤ -distillCritical1 10 x := by - refine (BernsteinCert.coeffs_pos - [2689774387200, 23258320404480, 83729139056640, 161196037632000, 176396717043456, - 106236383011136, 30027750193952, 2142322286928] - (lo := 0) (hi := (7 / 4)) (s := 823543) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 2 5) : - 0 ≤ distillCritical1 10 x := by - refine (BernsteinCert.coeffs_pos - [40230640, 2861489920, 23278100160, 82664174816, 158331459260, 171293951280, - 99052779220, 23910352000] - (lo := 2) (hi := 5) (s := 2187) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : - distillT1 10 α ≤ (31 / 200) := by - apply distillT1_le_of_critical (l := (7 / 4)) (r := 2) (d := 5) - 7 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 2) : - 0 ≤ -distillCritical2 10 x := by - refine (BernsteinCert.coeffs_pos - [14175, 63990, 95910, 50338, 3779] - (lo := 0) (hi := 2) (s := 4) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (9 / 4) 5) : - 0 ≤ distillCritical2 10 x := by - refine (BernsteinCert.coeffs_pos - [1173852, 66240936, 260405760, 348878720, 155238400] - (lo := (9 / 4)) (hi := 5) (s := 14641) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : - distillT2 10 α ≤ (121 / 1000) := by - apply distillT2_le_of_critical (l := 2) (r := (9 / 4)) (d := 5) - 7 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow10 - -theorem distillFinite_10 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5) : - distillEBudget 10 + distillT0 10 α + distillT1 10 α + distillT2 10 α ≤ (607 / 750) := by - have h0 := CriticalRow10.component0 α hα hd - have h1 := CriticalRow10.component1 α hα hd - have h2 := CriticalRow10.component2 α hα hd - calc - _ ≤ distillEBudget 10 + (9 / 40) + (31 / 200) + (121 / 1000) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (607 / 750) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_10 : ((607 / 750) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow11 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 2)) : - 0 ≤ distillCritical0 11 x := by - refine (BernsteinCert.coeffs_pos - [1317938688, 12405208320, 48218991552, 99377007840, 115329236160, 72721372108, - 20810300940, 1107629072] - (lo := 0) (hi := (5 / 2)) (s := 15625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 4) (11 / 2)) : - 0 ≤ -distillCritical0 11 x := by - refine (BernsteinCert.coeffs_pos - [29860506888, 1465779690856, 10785194353424, 35335858883840, 62967110431488, - 63771092294272, 34722916282624, 7939748744192] - (lo := (11 / 4)) (hi := (11 / 2)) (s := 1771561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : - distillT0 11 α ≤ (229 / 1000) := by - apply distillT0_le_of_critical (l := (5 / 2)) (r := (11 / 4)) (d := (11 / 2)) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (9 / 4)) : - 0 ≤ -distillCritical1 11 x := by - refine (BernsteinCert.coeffs_pos - [5132779520, 47598501888, 182637846528, 371577997312, 423824972544, 258668567520, - 67881102032, 1540304784] - (lo := 0) (hi := (9 / 4)) (s := 6561) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (5 / 2) (11 / 2)) : - 0 ≤ distillCritical1 11 x := by - refine (BernsteinCert.coeffs_pos - [2269541230, 57025527163, 390064523178, 1270709939423, 2295683591354, 2372211292089, - 1319106854830, 307421296237] - (lo := (5 / 2)) (hi := (11 / 2)) (s := 17496) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : - distillT1 11 α ≤ (77 / 500) := by - apply distillT1_le_of_critical (l := (9 / 4)) (r := (5 / 2)) (d := (11 / 2)) - 8 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 2)) : - 0 ≤ -distillCritical2 11 x := by - refine (BernsteinCert.coeffs_pos - [228096, 1089504, 1679856, 837284, 4336] - (lo := 0) (hi := (5 / 2)) (s := 125) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 4) (11 / 2)) : - 0 ≤ distillCritical2 11 x := by - refine (BernsteinCert.coeffs_pos - [625044, 10403560, 35152848, 43822560, 18602624] - (lo := (11 / 4)) (hi := (11 / 2)) (s := 1331) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : - distillT2 11 α ≤ (61 / 500) := by - apply distillT2_le_of_critical (l := (5 / 2)) (r := (11 / 4)) (d := (11 / 2)) - 8 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow11 - -theorem distillFinite_11 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ (11 / 2)) : - distillEBudget 11 + distillT0 11 α + distillT1 11 α + distillT2 11 α ≤ (5333 / 6600) := by - have h0 := CriticalRow11.component0 α hα hd - have h1 := CriticalRow11.component1 α hα hd - have h2 := CriticalRow11.component2 α hα hd - calc - _ ≤ distillEBudget 11 + (229 / 1000) + (77 / 500) + (61 / 500) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (5333 / 6600) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_11 : ((5333 / 6600) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow12 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 3) : - 0 ≤ distillCritical0 12 x := by - refine (BernsteinCert.coeffs_pos - [28800, 288096, 1182528, 2552496, 3066304, 1958832, 529928, 3960] - (lo := 0) (hi := 3) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo (13 / 4) 6) : - 0 ≤ -distillCritical0 12 x := by - refine (BernsteinCert.coeffs_pos - [1664241508272, 35159330460576, 219174632642304, 662380928815104, 1119724972978176, - 1089345607925760, 573425787469824, 127185145823232] - (lo := (13 / 4)) (hi := 6) (s := 19487171) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : - distillT0 12 α ≤ (47 / 200) := by - apply distillT0_le_of_critical (l := 3) (r := (13 / 4)) (d := 6) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (5 / 2)) : - 0 ≤ -distillCritical1 12 x := by - refine (BernsteinCert.coeffs_pos - [7847165952, 75733512192, 302446586880, 641197866240, 765023287680, 493871716512, - 142955512032, 7230207600] - (lo := 0) (hi := (5 / 2)) (s := 15625) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo (11 / 4) 6) : - 0 ≤ distillCritical1 12 x := by - refine (BernsteinCert.coeffs_pos - [2764968101040, 136428974431296, 1056344227288704, 3646711898413056, 6834600949616640, - 7257719142088704, 4127070189256704, 980881124622336] - (lo := (11 / 4)) (hi := 6) (s := 62748517) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : - distillT1 12 α ≤ (31 / 200) := by - apply distillT1_le_of_critical (l := (5 / 2)) (r := (11 / 4)) (d := 6) - 9 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 (11 / 4)) : - 0 ≤ -distillCritical2 12 x := by - refine (BernsteinCert.coeffs_pos - [22394880, 111248640, 178398144, 93750984, 2508244] - (lo := 0) (hi := (11 / 4)) (s := 14641) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 3 6) : - 0 ≤ distillCritical2 12 x := by - refine (BernsteinCert.coeffs_pos - [282, 6406, 22972, 29500, 12768] - (lo := 3) (hi := 6) (s := 1) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : - distillT2 12 α ≤ (1 / 8) := by - apply distillT2_le_of_critical (l := (11 / 4)) (r := 3) (d := 6) - 9 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow12 - -theorem distillFinite_12 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 6) : - distillEBudget 12 + distillT0 12 α + distillT1 12 α + distillT2 12 α ≤ (2929 / 3600) := by - have h0 := CriticalRow12.component0 α hα hd - have h1 := CriticalRow12.component1 α hα hd - have h2 := CriticalRow12.component2 α hα hd - calc - _ ≤ distillEBudget 12 + (47 / 200) + (31 / 200) + (1 / 8) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (2929 / 3600) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_12 : ((2929 / 3600) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end diff --git a/Sendov/DistillationFinite/Rows61_61.lean b/Sendov/DistillationFinite/Rows61_61.lean deleted file mode 100644 index 7c372a3..0000000 --- a/Sendov/DistillationFinite/Rows61_61.lean +++ /dev/null @@ -1,98 +0,0 @@ -import Sendov.Common.DistillationCriticalFinite -import Sendov.Common.BernsteinList - -section - -/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions. -Generated by scripts/gen_distillation.py. See the shared helper for provenance. -/ - -namespace Sendov -namespace CriticalRow61 - -private lemma sign_0_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ distillCritical0 61 x := by - refine (BernsteinCert.coeffs_pos - [2019781980, 56430214272, 601686039834, 3036073584816, 7326547127832, 8167105809971, - 6087236209110, 1044305251249] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical0 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_0_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ -distillCritical0 61 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component0 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 61 α ≤ (57 / 250) := by - apply distillT0_le_of_critical (l := 17) (r := 17) (d := 17) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_0_left sign_0_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_1_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical1 61 x := by - refine (BernsteinCert.coeffs_pos - [48537024120, 1418814495216, 16199029223856, 91304072373456, 266199727275870, - 395856838633324, 299684953990290, 59281036043180] - (lo := 0) (hi := 17) (s := 410338673) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical1 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_1_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical1 61 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component1 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 61 α ≤ (13 / 250) := by - apply distillT1_le_of_critical (l := 17) (r := 17) (d := 17) - 58 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_1_left sign_1_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -private lemma sign_2_left (x : ℝ) (hx : x ∈ Set.Ioo 0 17) : - 0 ≤ -distillCritical2 61 x := by - refine (BernsteinCert.coeffs_pos - [2865780, 41674500, 164428314, 144912610, 9604580] - (lo := 0) (hi := 17) (s := 83521) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical2 - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -private lemma sign_2_right (x : ℝ) (hx : x ∈ Set.Ioo 17 17) : - 0 ≤ distillCritical2 61 x := by - exact False.elim (lt_irrefl 17 (hx.1.trans hx.2)) - -theorem component2 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT2 61 α ≤ (81 / 250) := by - apply distillT2_le_of_critical (l := 17) (r := 17) (d := 17) - 58 (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num) - sign_2_left sign_2_right ?_ ⟨hα, hd⟩ - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -end CriticalRow61 - -theorem distillFinite_61 (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillEBudget 61 + distillT0 61 α + distillT1 61 α + distillT2 61 α ≤ (19754 / 22875) := by - have h0 := CriticalRow61.component0 α hα hd - have h1 := CriticalRow61.component1 α hα hd - have h2 := CriticalRow61.component2 α hα hd - calc - _ ≤ distillEBudget 61 + (57 / 250) + (13 / 250) + (81 / 250) := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = (19754 / 22875) := by norm_num only [distillEBudget] - -theorem distillFiniteBound_61 : ((19754 / 22875) : ℝ) < 199 / 200 := by norm_num - -end Sendov - -end diff --git a/Sendov/LargeDegree/DistillationTail.lean b/Sendov/LargeDegree/DistillationTail.lean deleted file mode 100644 index b4fd4e2..0000000 --- a/Sendov/LargeDegree/DistillationTail.lean +++ /dev/null @@ -1,463 +0,0 @@ -import Sendov.Common.DistillationFactors - -/-! -# Real-degree monotonicity and bounded growth of distillation components - -New Lean adaptation of Senjian An, *Proof Distillation for Sendov's Conjecture*, -revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, lines 898--950. -Paper: CC BY 4.0, https://creativecommons.org/licenses/by/4.0/ . -The m=61 reduction uses the actual dependence of the rational denominator -on alpha and the stronger decay from `cubicPolarEnvelope 17 <= (21/22)^4`. -The rational component is antitone already from 55; a finite-interval growth -lemma retains exponential decay even when a power component is not antitone. -Finite base certificates remain separate. No raw scalar value at alpha zero -is identified with a continuous extension. --/ - -namespace Sendov - -private lemma slope_mul {f g : ℝ → ℝ} {x u v : ℝ} - (hf : HasDerivAt f (f x * u) x) (hg : HasDerivAt g (g x * v) x) : - HasDerivAt (fun y => f y * g y) ((f x * g x) * (u + v)) x := by - convert! hf.mul hg using 1 - ring - -private lemma slope_div {f g : ℝ → ℝ} {x u v : ℝ} - (hf : HasDerivAt f (f x * u) x) (hg : HasDerivAt g (g x * v) x) - (hg0 : g x ≠ 0) : - HasDerivAt (fun y => f y / g y) ((f x / g x) * (u - v)) x := by - convert! hf.div hg hg0 using 1 - field_simp - -private lemma slope_pow {f : ℝ → ℝ} {x u : ℝ} (n : ℕ) - (hf : HasDerivAt f (f x * u) x) : - HasDerivAt (fun y => f y ^ n) (f x ^ n * (n * u)) x := by - convert! hf.pow n using 1 - cases n with - | zero => simp - | succ n => simp only [Nat.add_sub_cancel, pow_succ, Nat.cast_add, Nat.cast_one]; ring - -private lemma slope_linear (x c : ℝ) (h : x + c ≠ 0) : - HasDerivAt (fun y : ℝ => y + c) ((x + c) * (1 / (x + c))) x := by - convert! (hasDerivAt_id' x).add_const c using 1 - exact mul_one_div_cancel h - -private lemma tail_antitone {f f' : ℝ → ℝ} {K : ℝ} - (hf : ∀ x : ℝ, K ≤ x → HasDerivAt f (f' x) x) - (hn : ∀ x : ℝ, K ≤ x → f' x ≤ 0) : AntitoneOn f (Set.Ici K) := by - exact antitoneOn_of_hasDerivWithinAt_nonpos (convex_Ici _) - (fun x hx => (hf x hx).continuousAt.continuousWithinAt) - (fun x hx => (hf x (interior_subset hx)).hasDerivWithinAt) - (fun x hx => hn x (interior_subset hx)) - -lemma distillEBudget_antitone_on {K : ℝ} (hK : 0 < K) : - AntitoneOn distillEBudget (Set.Ici K) := by - intro m hm n _ hmn - change K ≤ m at hm - dsimp only [distillEBudget] - apply add_le_add le_rfl - exact div_le_div_of_nonneg_left (by norm_num) - (by linarith : 0 < 12 * m) (by linarith) - -lemma distillEBudget_antitone : AntitoneOn distillEBudget (Set.Ici 61) := - distillEBudget_antitone_on (by norm_num) - -lemma cubicPolarEnvelope_le_five_sixths {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : - cubicPolarEnvelope α ≤ 5 / 6 := by - calc - cubicPolarEnvelope α ≤ cubicPolarEnvelope 17 := cubicPolarEnvelope_mono hα hα17 - _ ≤ 5 / 6 := by norm_num [cubicPolarEnvelope] - -lemma cubicPolarEnvelope_le_decay_base {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : - cubicPolarEnvelope α ≤ (21 / 22) ^ 4 := - (cubicPolarEnvelope_mono hα hα17).trans (by norm_num [cubicPolarEnvelope]) - -lemma distillNode_antitone_degree_on {K α : ℝ} (hK : 0 < K) (hα : 0 ≤ α) : - AntitoneOn (fun m => distillNode m α) (Set.Ici K) := by - intro m hm n _ hmn - change K ≤ m at hm - dsimp only [distillNode] - apply add_le_add le_rfl - exact div_le_div_of_nonneg_left (by positivity : 0 ≤ 12 * α) - (by linarith : 0 < 25 * m) (by linarith) - -lemma distillNode_antitone_degree {α : ℝ} (hα : 0 ≤ α) : - AntitoneOn (fun m => distillNode m α) (Set.Ici 61) := - distillNode_antitone_degree_on (by norm_num) hα - -lemma distillNode_lt_four_fifths {m α : ℝ} (hm : 61 ≤ m) - (hα : 0 ≤ α) (hα17 : α ≤ 17) : distillNode m α < 4 / 5 := by - have he := cubicPolarEnvelope_le_five_sixths hα hα17 - have ht : 12 * α / (25 * m) ≤ 204 / 1525 := by - apply (div_le_iff₀ (by linarith : 0 < 25 * m)).mpr - linarith - unfold distillNode - linarith only [he, ht] - -private lemma kappa_slope {m α : ℝ} (hm : 34 < m) (hα17 : α ≤ 17) : - HasDerivAt (fun x => distillKappa x α) - (distillKappa m α * (1 / (m - 1) + 1 / (m + 1) - 1 / m + - 2 / (m - 2 * α))) m := by - have hm0 : m ≠ 0 := by linarith - have hm1 : m - 1 ≠ 0 := by linarith - have hmp1 : m + 1 ≠ 0 := by linarith - have hma : m - 2 * α ≠ 0 := by linarith - have h1 := slope_linear m (-1) (by linarith) - have h2 := slope_linear m 1 hmp1 - have h3 := slope_linear m 0 (by simpa using hm0) - have h4 := slope_pow 2 (slope_linear m (-2 * α) (by linarith)) - have hc := hasDerivAt_const m (distillRatio α / 4) - have hc' : HasDerivAt (fun _ : ℝ => distillRatio α / 4) - (distillRatio α / 4 * 0) m := by simpa using hc - convert! slope_mul (slope_mul (slope_div (slope_mul h1 h2) h3 - (by simpa using hm0)) hc') h4 using 1 - · funext x - dsimp [distillKappa] - ring - · dsimp [distillKappa] - ring - -private lemma kappa_slope_le {K m α : ℝ} (hK : 34 < K) (hm : K ≤ m) - (hα17 : α ≤ 17) : - 1 / (m - 1) + 1 / (m + 1) - 1 / m + 2 / (m - 2 * α) ≤ - 1 / (K - 1) + 2 / (K - 34) := by - have h1 : 1 / (m - 1) ≤ 1 / (K - 1) := - div_le_div_of_nonneg_left (by norm_num) (by linarith) (by linarith) - have h2 : 1 / (m + 1) ≤ 1 / m := - div_le_div_of_nonneg_left (by norm_num) (by linarith) (by linarith) - have h3 : 2 / (m - 2 * α) ≤ 2 / (K - 34) := - div_le_div_of_nonneg_left (by norm_num) (by linarith) (by linarith) - linarith only [h1, h2, h3] - -/-- On a bounded degree interval, a small positive logarithmic slope consumes -only a linear budget. Unlike an infinite antitone tail, this permits growth. -/ -lemma distillKappa_rpow_interval {K U m α z q ε : ℝ} (n : ℕ) - (hK : 34 < K) (hm : m ∈ Set.Icc K U) (hε : 0 ≤ ε) - (hroom : ε * (U - K) < 1) - (hdecay : 1 / (K - 1) + 2 / (K - 34) ≤ n * (1 - q) / 2 + ε) - (hα : 0 ≤ α) (hα17 : α ≤ 17) (hz : 0 ≤ z) (hq : 0 < q) - (hzq : z ≤ q ^ n) : - (distillKappa m α * z ^ ((m - 3) / 2)) * (1 - ε * (U - K)) ≤ - distillKappa K α * z ^ ((K - 3) / 2) := by - rcases hz.eq_or_lt with rfl | hz - · have hm' : (m - 3) / 2 ≠ 0 := by have := hm.1; linarith - have hK' : (K - 3) / 2 ≠ 0 := by linarith - simp [Real.zero_rpow hm', Real.zero_rpow hK'] - let f := fun t => distillKappa t α * z ^ ((t - 3) / 2) - let w := fun t => 1 - ε * (t - K) - have hf0 (t : ℝ) (ht : K ≤ t) : 0 ≤ f t := - mul_nonneg (distillKappa_nonneg (by linarith) hα) (Real.rpow_nonneg hz.le _) - have hw (t : ℝ) (ht : t ≤ U) : 0 ≤ w t := by - have := mul_le_mul_of_nonneg_left (sub_le_sub_right ht K) hε - dsimp [w] - linarith - have hlog : Real.log z / 2 ≤ -(n * (1 - q) / 2) := by - have hl := Real.log_le_log hz hzq - rw [Real.log_pow] at hl - have hqlog := mul_le_mul_of_nonneg_left (Real.log_le_sub_one_of_pos hq) - (Nat.cast_nonneg n : (0 : ℝ) ≤ n) - linarith - let s := fun t => 1 / (t - 1) + 1 / (t + 1) - 1 / t + - 2 / (t - 2 * α) + Real.log z / 2 - have hs (t : ℝ) (ht : K ≤ t) : s t ≤ ε := by - have := kappa_slope_le hK ht hα17 - dsimp [s] - linarith - have hd (t : ℝ) (ht : K ≤ t) : - HasDerivAt (fun t => f t * w t) (f t * (s t * w t - ε)) t := by - have hp : HasDerivAt (fun t : ℝ => z ^ ((t - 3) / 2)) - (z ^ ((t - 3) / 2) * (Real.log z / 2)) t := by - convert! (hasDerivAt_const t z).rpow - (((hasDerivAt_id' t).sub_const 3).div_const 2) hz using 1 - ring - have hf := slope_mul (kappa_slope (hK.trans_le ht) hα17) hp - have hw' := (((hasDerivAt_id' t).sub_const K).const_mul ε).const_sub 1 - convert! hf.mul hw' using 1 - dsimp [f, w, s] - ring - have hanti : AntitoneOn (fun t => f t * w t) (Set.Icc K U) := by - apply antitoneOn_of_hasDerivWithinAt_nonpos (convex_Icc _ _) - (fun t ht => (hd t ht.1).continuousAt.continuousWithinAt) - (fun t ht => (hd t (interior_subset ht).1).hasDerivWithinAt) - intro t ht - have ht' : t ∈ Set.Icc K U := interior_subset ht - apply mul_nonpos_of_nonneg_of_nonpos (hf0 t ht'.1) - have hsw := mul_le_mul_of_nonneg_right (hs t ht'.1) (hw t ht'.2) - have hprod : 0 ≤ ε * (ε * (t - K)) := by - exact mul_nonneg hε (mul_nonneg hε (sub_nonneg.mpr ht'.1)) - dsimp [w] at * - nlinarith - have hstep := hanti ⟨le_rfl, hm.1.trans hm.2⟩ hm hm.1 - have hweight : 1 - ε * (U - K) ≤ w m := by - dsimp [w] - have := mul_le_mul_of_nonneg_left (sub_le_sub_right hm.2 K) hε - linarith - exact (mul_le_mul_of_nonneg_left hweight (hf0 m hm.1)).trans - (by simpa [w, f] using hstep) - -/-- A rational power cap retains stronger logarithmic decay without a log estimate -or a derivative sign as a caller premise. Since `K > 34`, the positive left side -of `hdecay` already forces `n > 0` and `q < 1`; no extra premises are needed. -/ -lemma distillKappa_rpow_antitone_of_pow {K α z q : ℝ} (n : ℕ) (hK : 34 < K) - (hdecay : 1 / (K - 1) + 2 / (K - 34) ≤ n * (1 - q) / 2) - (hα : 0 ≤ α) (hα17 : α ≤ 17) - (hz : 0 ≤ z) (hq : 0 < q) (hz1 : z ≤ q ^ n) : - AntitoneOn (fun m => distillKappa m α * z ^ ((m - 3) / 2)) (Set.Ici K) := by - rcases hz.eq_or_lt with rfl | hz - · intro m hm n hn _ - have hm' : (m - 3) / 2 ≠ 0 := by change K ≤ m at hm; linarith - have hn' : (n - 3) / 2 ≠ 0 := by change K ≤ n at hn; linarith - simp only [Real.zero_rpow hm', Real.zero_rpow hn', mul_zero, le_refl] - have hp (m : ℝ) : HasDerivAt (fun x : ℝ => z ^ ((x - 3) / 2)) - (z ^ ((m - 3) / 2) * (Real.log z / 2)) m := by - convert! (hasDerivAt_const m z).rpow - (((hasDerivAt_id' m).sub_const 3).div_const 2) hz using 1 - ring - apply tail_antitone (fun m hm => slope_mul (kappa_slope (hK.trans_le hm) hα17) (hp m)) - intro m hm - apply mul_nonpos_of_nonneg_of_nonpos - · exact mul_nonneg (distillKappa_nonneg (by linarith) hα) (Real.rpow_nonneg hz.le _) - · have hk := kappa_slope_le hK hm hα17 - have hl := Real.log_le_log hz hz1 - rw [Real.log_pow] at hl - have hqlog := mul_le_mul_of_nonneg_left (Real.log_le_sub_one_of_pos hq) - (Nat.cast_nonneg n : (0 : ℝ) ≤ n) - linarith - -/-- The original sufficient condition remains a special case. -/ -lemma distillKappa_rpow_antitone_on {K α z : ℝ} (hK : 34 < K) - (hdecay : 1 / (K - 1) + 2 / (K - 34) ≤ 1 / 12) - (hα : 0 ≤ α) (hα17 : α ≤ 17) - (hz : 0 ≤ z) (hz1 : z ≤ 5 / 6) : - AntitoneOn (fun m => distillKappa m α * z ^ ((m - 3) / 2)) (Set.Ici K) := - distillKappa_rpow_antitone_of_pow 1 hK (by norm_num at *; exact hdecay) - hα hα17 hz (by norm_num : (0 : ℝ) < 5 / 6) (by simpa using hz1) - -private lemma kappa_rpow_antitone {α z : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) - (hz : 0 ≤ z) (hz1 : z ≤ (21 / 22) ^ 4) : - AntitoneOn (fun m => distillKappa m α * z ^ ((m - 3) / 2)) (Set.Ici 61) := - distillKappa_rpow_antitone_of_pow 4 (by norm_num) (by norm_num) - hα hα17 hz (by norm_num : (0 : ℝ) < 21 / 22) hz1 - -/-- Real-degree antitonicity; the node itself also decreases with the degree. -/ -lemma distillT1_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : - AntitoneOn (fun m => distillT1 m α) (Set.Ici 61) := by - intro m hm n hn hmn - have hm' : 61 ≤ m := hm - have hn' : 61 ≤ n := hn - have hz := distillNode_pos (by linarith : 0 < m) hα - have hz1 : distillNode m α ≤ (21 / 22) ^ 4 := - (distillNode_lt_four_fifths hm' hα hα17).le.trans (by norm_num) - have hpow := Real.rpow_le_rpow (distillNode_pos (by linarith : 0 < n) hα).le - (distillNode_antitone_degree hα hm hn hmn) (by linarith : 0 ≤ (n - 3) / 2) - have hstep := (mul_le_mul_of_nonneg_left hpow - (distillKappa_nonneg (by linarith) hα)).trans - (kappa_rpow_antitone hα hα17 hz.le hz1 hm hn hmn) - have := mul_le_mul_of_nonneg_left hstep (by norm_num : (0 : ℝ) ≤ 259 / 3125) - simpa only [distillT1, mul_assoc] using this - -/-- The zero-alpha case is included by the zero-base real-power case. -/ -lemma distillT2_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : - AntitoneOn (fun m => distillT2 m α) (Set.Ici 61) := by - intro m hm n hn hmn - have hstep := kappa_rpow_antitone hα hα17 (cubicPolarEnvelope_nonneg hα) - (cubicPolarEnvelope_le_decay_base hα hα17) hm hn hmn - have := mul_le_mul_of_nonneg_left hstep (by norm_num : (0 : ℝ) ≤ 421 / 3125) - simpa only [distillT2, mul_assoc] using this - -lemma distillT2_zero {m : ℝ} (hm : 61 ≤ m) : distillT2 m 0 = 0 := by - have hs : (m - 3) / 2 ≠ 0 := by linarith - simp [distillT2, cubicPolarEnvelope, Real.zero_rpow hs] - -private def tailP (m α : ℝ) : ℝ := - 7 * m ^ 4 - 30 * α * m ^ 3 - (8 * α ^ 2 + 96 * α + 105) * m ^ 2 + - (90 * α - 128 * α ^ 2) * m - 360 * α ^ 2 - -private lemma tailP_pos {m α : ℝ} (hm : 55 ≤ m) (hα : 0 ≤ α) (hα10 : α ≤ 10) : - 0 < tailP m α := by - have hm0 : 0 ≤ m := by linarith - have hx : 0 ≤ m - 55 := by linarith - have hgap : 0 ≤ 10 - α := by linarith - have hid : tailP m α = - 7 * (m - 55) ^ 4 + 1240 * (m - 55) ^ 3 + 75685 * (m - 55) ^ 2 + - 1718950 * (m - 55) + 7809750 + - (10 - α) * (α * (8 * m ^ 2 + 128 * m + 360) + - 30 * m ^ 3 + 176 * m ^ 2 + 1190 * m + 3600) := by - dsimp [tailP] - ring - rw [hid] - positivity - -private noncomputable def tailQ (m α d : ℝ) : ℝ := - d * tailP m α / 7 + (21 / 25 - d) * (4 * α / 7) * - ((3 * m - 2 * α) * m ^ 2 + 32 * (m - α) * m + (75 * m - 90 * α)) - -private lemma tailQ_cap_pos {m α : ℝ} (hm : 55 ≤ m) (hα : 0 ≤ α) - (hα17 : α ≤ 17) : 0 < tailQ m α (39 / 100) := by - have hm0 : 0 ≤ m := by linarith - have hx : 0 ≤ m - 55 := by linarith - have hgap : 0 ≤ 17 - α := by linarith - have hid : tailQ m α (39 / 100) = - (39 / 100) * (m - 55) ^ 4 + (141 / 2) * (m - 55) ^ 3 + - (431967 / 100) * (m - 55) ^ 2 + (4544763 / 50) * (m - 55) + - 160893 / 2 + - (17 - α) * (3 / 50) * (16 * α * m ^ 2 + 256 * α * m + 720 * α + - 15 * m ^ 3 + 224 * m ^ 2 + 3947 * m + 12240) := by - dsimp [tailQ, tailP] - ring - rw [hid] - positivity - -private lemma tailQ_pos {m α d : ℝ} (hm : 55 ≤ m) (hα : 0 ≤ α) - (hα17 : α ≤ 17) (hd : 0 < d) (hd1 : d ≤ 21 / 25) - (hdα : 10 ≤ α → d ≤ 39 / 100) : 0 < tailQ m α d := by - have hm0 : 0 ≤ m := by linarith - have h1 : 0 ≤ 3 * m - 2 * α := by linarith - have h2 : 0 ≤ m - α := by linarith - have h3 : 0 ≤ 75 * m - 90 * α := by linarith - have h4 : 0 ≤ 21 / 25 - d := by linarith - by_cases hα10 : α ≤ 10 - · unfold tailQ - exact add_pos_of_pos_of_nonneg (div_pos (mul_pos hd (tailP_pos hm hα hα10)) - (by norm_num)) (by positivity) - · have hd2 : 0 ≤ 39 / 100 - d := sub_nonneg.mpr (hdα (by linarith)) - have hid : tailQ m α d = d * (100 / 39 * tailQ m α (39 / 100)) + - (39 / 100 - d) * (16 * α / 13) * - ((3 * m - 2 * α) * m ^ 2 + 32 * (m - α) * m + (75 * m - 90 * α)) := by - dsimp [tailQ, tailP] - ring - rw [hid] - exact add_pos_of_pos_of_nonneg - (mul_pos hd (mul_pos (by norm_num) (tailQ_cap_pos hm hα hα17))) (by positivity) - -private noncomputable def tailRational (m α d : ℝ) : ℝ := - m ^ 3 * (m - 2 * α) ^ 2 / ((m + 3) * (m + 5) * (d * m - 12 * α / 25) ^ 4) - -private lemma tail_den_pos {m α d : ℝ} (hm : 55 ≤ m) (hα17 : α ≤ 17) - (hd : 17 / 50 ≤ d) : 0 < d * m - 12 * α / 25 := by - have hm0 : 0 ≤ m := by linarith - have hd0 : 0 ≤ d - 17 / 50 := by linarith - nlinarith [mul_nonneg hd0 hm0] - -private lemma rational_slope {m α d : ℝ} (hm : 55 ≤ m) (hα17 : α ≤ 17) - (hd : 17 / 50 ≤ d) : - HasDerivAt (fun x => tailRational x α d) - (tailRational m α d * (3 / m + 2 / (m - 2 * α) - 1 / (m + 3) - - 1 / (m + 5) - 4 * d / (d * m - 12 * α / 25))) m := by - have hm0 : m ≠ 0 := by linarith - have hma : m - 2 * α ≠ 0 := by linarith - have hm3 : m + 3 ≠ 0 := by linarith - have hm5 : m + 5 ≠ 0 := by linarith - have hc : d * m - 12 * α / 25 ≠ 0 := (tail_den_pos hm hα17 hd).ne' - have h1 := slope_pow 3 (slope_linear m 0 (by simpa using hm0)) - have h2 := slope_pow 2 (slope_linear m (-2 * α) (by linarith)) - have h3 := slope_linear m 3 hm3 - have h5 := slope_linear m 5 hm5 - have hd' : HasDerivAt (fun x : ℝ => d * x - 12 * α / 25) - ((d * m - 12 * α / 25) * (d / (d * m - 12 * α / 25))) m := by - convert! ((hasDerivAt_id' m).const_mul d).sub_const (12 * α / 25) using 1 - simp [← mul_div_assoc, hc] - have hden := slope_mul (slope_mul h3 h5) (slope_pow 4 hd') - convert! slope_div (slope_mul h1 h2) hden - (mul_ne_zero (mul_ne_zero hm3 hm5) (pow_ne_zero 4 hc)) using 1 - · funext x - dsimp [tailRational] - ring - · dsimp [tailRational] - ring - -private lemma rational_slope_neg {m α d : ℝ} (hm : 55 ≤ m) (hα : 0 ≤ α) - (hα17 : α ≤ 17) (hd : 17 / 50 ≤ d) (hd1 : d ≤ 21 / 25) - (hdα : 10 ≤ α → d ≤ 39 / 100) : - 3 / m + 2 / (m - 2 * α) - 1 / (m + 3) - 1 / (m + 5) - - 4 * d / (d * m - 12 * α / 25) < 0 := by - have hm0 : 0 < m := by linarith - have hma : 0 < m - 2 * α := by linarith - have hm3 : 0 < m + 3 := by linarith - have hm5 : 0 < m + 5 := by linarith - have hc := tail_den_pos hm hα17 hd - have hid : 3 / m + 2 / (m - 2 * α) - 1 / (m + 3) - 1 / (m + 5) - - 4 * d / (d * m - 12 * α / 25) = - -tailQ m α d / (m * (m - 2 * α) * (m + 3) * (m + 5) * - (d * m - 12 * α / 25)) := by - generalize hdef : d * m - 12 * α / 25 = c at * - field_simp - rw [← hdef] - dsimp [tailQ, tailP] - ring - rw [hid] - exact div_neg_of_neg_of_pos - (neg_neg_of_pos (tailQ_pos hm hα hα17 (by linarith) hd1 hdα)) - (by positivity) - -private lemma tailRational_antitone {α d : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) - (hd : 17 / 50 ≤ d) (hd1 : d ≤ 21 / 25) (hdα : 10 ≤ α → d ≤ 39 / 100) : - AntitoneOn (fun m => tailRational m α d) (Set.Ici 55) := by - apply tail_antitone (fun m hm => rational_slope hm hα17 hd) - intro m hm - have hm0 : 0 ≤ m := by linarith - have hm3 : 0 ≤ m + 3 := by linarith - have hm5 : 0 ≤ m + 5 := by linarith - exact mul_nonpos_of_nonneg_of_nonpos (by unfold tailRational; positivity) - (rational_slope_neg hm hα hα17 hd hd1 hdα).le - -private lemma distillT0_eq_rational {m α : ℝ} (hm : 55 ≤ m) - (hα : 0 ≤ α) (hα17 : α ≤ 17) : - distillT0 m α = (24 * (3 / 5) ^ 4 * distillRatio α) * - tailRational m α (21 / 25 - 3 / 5 * cubicPolarEnvelope α) := by - have hm0 : m ≠ 0 := by linarith - have hm1 : m - 1 ≠ 0 := by linarith - have hmp1 : m + 1 ≠ 0 := by linarith - have hm3 : m + 3 ≠ 0 := by linarith - have hm5 : m + 5 ≠ 0 := by linarith - have hn : 1 - distillNode m α ≠ 0 := by - have := distillNode_lt_one (by linarith : 0 < m) hα (by linarith : α ≤ m / 2) - linarith - have hc : (21 / 25 - 3 / 5 * cubicPolarEnvelope α) * m - 12 * α / 25 ≠ 0 := by - apply (tail_den_pos hm hα17 _).ne' - have := cubicPolarEnvelope_le_five_sixths hα hα17 - linarith - unfold distillT0 distillKappa tailRational - have hnode : 1 - distillNode m α = - ((21 / 25 - 3 / 5 * cubicPolarEnvelope α) * m - 12 * α / 25) / m := by - unfold distillNode - field_simp - ring - rw [hnode] - field_simp - ring - -/-- Real-degree antitonicity of the regularized rational component, including alpha zero. -/ -lemma distillT0_antitone_55 {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : - AntitoneOn (fun m => distillT0 m α) (Set.Ici 55) := by - have he := cubicPolarEnvelope_nonneg hα - have he1 := cubicPolarEnvelope_le_five_sixths hα hα17 - have hd : 17 / 50 ≤ 21 / 25 - 3 / 5 * cubicPolarEnvelope α := by linarith - have hd1 : 21 / 25 - 3 / 5 * cubicPolarEnvelope α ≤ 21 / 25 := by linarith - have hdα : 10 ≤ α → 21 / 25 - 3 / 5 * cubicPolarEnvelope α ≤ 39 / 100 := by - intro h10 - have he10 := cubicPolarEnvelope_mono (by norm_num : (0 : ℝ) ≤ 10) h10 - have hval : cubicPolarEnvelope 10 = 4970 / 6591 := by norm_num [cubicPolarEnvelope] - rw [hval] at he10 - linarith - intro m hm n hn hmn - change distillT0 n α ≤ distillT0 m α - rw [distillT0_eq_rational hn hα hα17, distillT0_eq_rational hm hα hα17] - exact mul_le_mul_of_nonneg_left (tailRational_antitone hα hα17 hd hd1 hdα hm hn hmn) - (mul_nonneg (by norm_num) (distillRatio_nonneg hα)) - -lemma distillT0_antitone {α : ℝ} (hα : 0 ≤ α) (hα17 : α ≤ 17) : - AntitoneOn (fun m => distillT0 m α) (Set.Ici 61) := - (distillT0_antitone_55 hα hα17).mono (Set.Ici_subset_Ici.mpr (by norm_num)) - -/-- The earlier pointwise reduction holds on the full closed alpha interval. -/ -lemma distillComponents_le_61 {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (hα17 : α ≤ 17) : - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α ≤ - distillEBudget 61 + distillT0 61 α + distillT1 61 α + distillT2 61 α := by - exact add_le_add (add_le_add (add_le_add - (distillEBudget_antitone (by simp) hm hm) - (distillT0_antitone hα hα17 (by simp) hm hm)) - (distillT1_antitone hα hα17 (by simp) hm hm)) - (distillT2_antitone hα hα17 (by simp) hm hm) - -end Sendov diff --git a/Sendov/LargeDegree/DistillationTailBound.lean b/Sendov/LargeDegree/DistillationTailBound.lean deleted file mode 100644 index 5f2e6b3..0000000 --- a/Sendov/LargeDegree/DistillationTailBound.lean +++ /dev/null @@ -1,73 +0,0 @@ -import Sendov.Common.DistillationMajorant -import Sendov.LargeDegree.DistillationTail -import Sendov.DistillationFinite.Rows53_55 -import Sendov.DistillationFinite.Rows61_61 - -/-! -# The proved bounded interval and infinite tail - -The existing critical-point row at `m = 61` supplies the earlier `<199/200` -tail, starting at polynomial degree 62. No finite base or monotonicity is assumed. -The original row 55 separately closes the real interval `55 <= m <= 61`. -The underlying mathematical route is Senjian An's *Proof Distillation for Sendov's -Conjecture*, revision e8ae601491ec171ab4f7f8456113dd6a047aa85d, Sections 7--8 -(CC BY 4.0, https://creativecommons.org/licenses/by/4.0/). --/ - -namespace Sendov - -/-- A real-degree interval, not a finite case split. The original row 55 supplies -the three base budgets internally; bounded growth is allowed for both powers. -/ -theorem distillComponents_interval_55_61 {m α : ℝ} (hm : m ∈ Set.Icc 55 61) - (hα : 0 ≤ α) (h17 : α ≤ 17) : - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := by - have hm5 : 5 ≤ m := by have := hm.1; linarith - have hE := distillEBudget_antitone_on (K := 55) (by norm_num) - (by simp) hm.1 hm.1 - have h0 := (distillT0_antitone_55 hα h17 (by simp) hm.1 hm.1).trans - (CriticalRow55.component0 α hα h17) - have hnode : distillNode 55 α ≤ (979 / 1000) ^ 10 := - (distillNode_mono (by norm_num) hα h17).trans - (by norm_num [distillNode, cubicPolarEnvelope]) - have h1 := distillKappa_rpow_interval (K := 55) (U := 61) - (ε := 331 / 37800) 10 (by norm_num) hm (by norm_num) (by norm_num) - (by norm_num) hα h17 (distillNode_pos (by norm_num) hα).le - (by norm_num : (0 : ℝ) < 979 / 1000) hnode - have hpow := Real.rpow_le_rpow (distillNode_pos (by linarith) hα).le - (distillNode_antitone_degree_on (K := 55) (by norm_num) hα - (by simp) hm.1 hm.1) (by linarith : 0 ≤ (m - 3) / 2) - have h1' := (mul_le_mul_of_nonneg_right - (mul_le_mul_of_nonneg_left hpow (distillKappa_nonneg hm5 hα)) - (by norm_num : (0 : ℝ) ≤ 1 - 331 / 37800 * (61 - 55))).trans h1 - have h1'' : distillT1 m α * (1 - 331 / 37800 * (61 - 55)) ≤ 91 / 1000 := by - apply le_trans _ (CriticalRow55.component1 α hα h17) - simpa only [distillT1, mul_assoc] using - mul_le_mul_of_nonneg_left h1' (by norm_num : (0 : ℝ) ≤ 259 / 3125) - have h2 := distillKappa_rpow_interval (K := 55) (U := 61) - (ε := 95 / 4158) 4 (by norm_num) hm (by norm_num) (by norm_num) - (by norm_num) hα h17 (cubicPolarEnvelope_nonneg hα) - (by norm_num : (0 : ℝ) < 21 / 22) (cubicPolarEnvelope_le_decay_base hα h17) - have h2' : distillT2 m α * (1 - 95 / 4158 * (61 - 55)) ≤ 33 / 100 := by - apply le_trans _ (CriticalRow55.component2 α hα h17) - simpa only [distillT2, mul_assoc] using - mul_le_mul_of_nonneg_left h2 (by norm_num : (0 : ℝ) ≤ 421 / 3125) - norm_num [distillEBudget] at hE ⊢ - linarith - -/-- The existing finite row closes the earlier tail on the full closed alpha -domain, including zero. No stronger row certificate at m=61 is required. -/ -theorem distillComponents_lt_199_200 {m α : ℝ} (hm : 61 ≤ m) - (hα : 0 ≤ α) (h17 : α ≤ 17) : - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := - (distillComponents_le_61 hm hα h17).trans_lt - ((distillFinite_61 α hα h17).trans_lt distillFiniteBound_61) - -/-- Earlier raw scalar tail. Positive alpha is intentional; all of `α ≤ 17` -is covered, and `2 * α ≤ m` follows from the degree threshold. -/ -theorem distillScalar_lt_199_200 {m α : ℝ} (hm : 61 ≤ m) - (hα : 0 < α) (h17 : α ≤ 17) : - scalarObstruction m α (cubicPolarEnvelope α) < 199 / 200 := by - exact (distillScalar_le_majorant (by linarith) hα (by linarith)).trans_lt - (distillComponents_lt_199_200 hm hα.le h17) - -end Sendov diff --git a/Sendov/Reduction/CubicScalar.lean b/Sendov/Reduction/CubicScalar.lean index 0b31d80..96c66d8 100644 --- a/Sendov/Reduction/CubicScalar.lean +++ b/Sendov/Reduction/CubicScalar.lean @@ -17,7 +17,7 @@ certificate, tail bound, or old `R` enlargement is used here. namespace Sendov -/-- The four facts required by the cubic finite/tail endgame, all derived from +/-- The four facts required by the cubic scalar contradiction, all derived from raw geometric inputs. The final conjunction is a lower bound, not a premise. -/ theorem cubicScalar_constraints_of_polar_origin {n : ℕ} (hn : 6 ≤ n) {a x α : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx : x ^ 2 ≤ 1) diff --git a/Sendov/Reduction/Main.lean b/Sendov/Reduction/Main.lean index ec107a8..6013702 100644 --- a/Sendov/Reduction/Main.lean +++ b/Sendov/Reduction/Main.lean @@ -10,7 +10,7 @@ import Sendov.Common.DistillationBounds # Polar/origin incompatibility through the cubic scalar obstruction For `n ≥ 6`, the original geometric hypotheses produce the scalar domain and -`1 ≤ H`. The complete finite/tail bound proves `H < 1` on that same domain. +`1 ≤ H`. The uniform real-degree bound proves `H < 1` on that same domain. Degrees two through five are handled directly by the low-degree analytic argument in `Interior`; no old `R` certificate route is needed. -/ diff --git a/data/README.md b/data/README.md index 57d8051..d66bf3d 100644 --- a/data/README.md +++ b/data/README.md @@ -1,23 +1,15 @@ -# Exact mathematical table +# Mathematical attribution -`paper_certificate_table.json` is the unchanged ordered subset of records -`m = 5,...,55` and `m=61` (52 records) from Senjian An's mathematical certificate table, -*Proof Distillation for Sendov's Conjecture*, -[SJanPerth/Sendov-Proof-Distillation](https://github.com/SJanPerth/Sendov-Proof-Distillation/blob/e8ae601491ec171ab4f7f8456113dd6a047aa85d/verification/paper_certificate_table.json), -fixed revision **e8ae601491ec171ab4f7f8456113dd6a047aa85d**. +No finite-degree certificate table is retained. The full real `m >= 5` route +uses analytic degree-ray bounds and fixed alpha polynomial identities in Lean. +Their coefficients are contained in the proof source, not an external table. -The mathematical paper/table is attributed under -[Creative Commons Attribution 4.0 International](https://creativecommons.org/licenses/by/4.0/); -`LICENSE-PAPER.txt` retains the source's notice and legal-code link. No table -values, retained row order, component IDs/order or budgets were changed. Records -56 through 60 are covered by the proved real interval `55 ≤ m ≤ 61`, which -uses the original row-55 component budgets. Records 62 through 81 were removed -because the proved real-parameter tail starts at 61 and uses the original row-61 -budget. This is a selected subset, not a -verbatim copy of the complete donor table. The project generates -its own Lean certificate source; the table itself is not a formal proof. +The retained cubic-envelope and two-chord mathematics adapts Senjian An's +*Proof Distillation for Sendov's Conjecture*, fixed revision +`e8ae601491ec171ab4f7f8456113dd6a047aa85d`: +https://github.com/SJanPerth/Sendov-Proof-Distillation/tree/e8ae601491ec171ab4f7f8456113dd6a047aa85d -The upstream verification **code** has a separate MIT license. The small rational -checks adapted in `scripts/distillation_data.py` retain its notice in -`scripts/LICENSE-DISTILLATION-MIT.txt`; this does not relicense the mathematical -table as MIT or imply adoption of an upstream formal proof. +`LICENSE-PAPER.txt` retains the source's CC BY 4.0 notice and legal-code link +for that mathematical attribution. The retired table and MIT verification-code +adaptation are not part of the new route. No upstream Python result is trusted +as a formal premise. diff --git a/data/paper_certificate_table.json b/data/paper_certificate_table.json deleted file mode 100644 index da526fc..0000000 --- a/data/paper_certificate_table.json +++ /dev/null @@ -1,1926 +0,0 @@ -[ - { - "m": 5, - "e": "11/30", - "components": [ - { - "index": 0, - "k": "2", - "lo": "1/2", - "hi": "3/4", - "u": 202, - "sq": "345663626000976562500000000000000/8532694281700697952441690868675249", - "sign_lo": "53567739/16", - "sign_hi": "-3208672845/2048" - }, - { - "index": 1, - "k": "0", - "lo": "0", - "hi": "1/4", - "u": 191, - "sq": "1071869163584569/29460504150390625", - "sign_lo": "-6269400", - "sign_hi": "766217111/1024" - }, - { - "index": 2, - "k": "2", - "lo": "1/2", - "hi": "3/4", - "u": 148, - "sq": "1121025015543257344/51519870758056640625", - "sign_lo": "-4359/2", - "sign_hi": "185031/64" - } - ], - "total": "2723/3000" - }, - { - "m": 6, - "e": "25/72", - "components": [ - { - "index": 0, - "k": "4", - "lo": "1", - "hi": "5/4", - "u": 207, - "sq": "10952359114935356720621750831675535140625/256807730774197088470206908996036412826624", - "sign_lo": "351048", - "sign_hi": "-758195025/64" - }, - { - "index": 1, - "k": "2", - "lo": "1/2", - "hi": "3/4", - "u": 171, - "sq": "5460665625610299/186920166015625000", - "sign_lo": "-38556423/8", - "sign_hi": "18990256815/1024" - }, - { - "index": 2, - "k": "3", - "lo": "3/4", - "hi": "1", - "u": 133, - "sq": "535464208891258298351/30720000000000000000000", - "sign_lo": "-298485/64", - "sign_hi": "2036" - } - ], - "total": "1931/2250" - }, - { - "m": 7, - "e": "1/3", - "components": [ - { - "index": 0, - "k": "5", - "lo": "5/4", - "hi": "3/2", - "u": 211, - "sq": "2811248271174366670825003329000000/63645499797462270227236485163847641", - "sign_lo": "9906562865/2048", - "sign_hi": "-185130279/16" - }, - { - "index": 1, - "k": "3", - "lo": "3/4", - "hi": "1", - "u": 164, - "sq": "1182743499424270247438801761/44100000000000000000000000000", - "sign_lo": "-20336773761/1024", - "sign_hi": "16145814" - }, - { - "index": 2, - "k": "4", - "lo": "1", - "hi": "5/4", - "u": 124, - "sq": "7416843437532623565289/483250188447852963840000", - "sign_lo": "-8442", - "sign_hi": "7555/64" - } - ], - "total": "2497/3000" - }, - { - "m": 8, - "e": "31/96", - "components": [ - { - "index": 0, - "k": "6", - "lo": "3/2", - "hi": "7/4", - "u": 215, - "sq": "148679430010467133298528786361621248632422400/3245952473515737982582781571806215372528951009", - "sign_lo": "106446393/8", - "sign_hi": "-8249772043/1024" - }, - { - "index": 1, - "k": "5", - "lo": "5/4", - "hi": "3/2", - "u": 157, - "sq": "377798596060495643265896750563477/15393232568314800000000000000000000", - "sign_lo": "-47198835/1024", - "sign_hi": "722525751/8" - }, - { - "index": 2, - "k": "6", - "lo": "3/2", - "hi": "7/4", - "u": 120, - "sq": "1538332665048978711275164426348211243/107571644398449235770918120000000000000", - "sign_lo": "-3159", - "sign_hi": "673123/64" - } - ], - "total": "9779/12000" - }, - { - "m": 9, - "e": "17/54", - "components": [ - { - "index": 0, - "k": "8", - "lo": "2", - "hi": "9/4", - "u": 220, - "sq": "139256190123085451332946176/2879809196797970285606555625", - "sign_lo": "546300", - "sign_hi": "-85403336337/2048" - }, - { - "index": 1, - "k": "6", - "lo": "3/2", - "hi": "7/4", - "u": 156, - "sq": "259159966184709869271004669152262950565331236/10686733714922552340096995507147312164306640625", - "sign_lo": "-170474463/4", - "sign_hi": "85903083723/1024" - }, - { - "index": 2, - "k": "7", - "lo": "7/4", - "hi": "2", - "u": 120, - "sq": "207943802139808519297719599609100544/14553143435926758684217929840087890625", - "sign_lo": "-519649/64", - "sign_hi": "8420" - } - ], - "total": "5473/6750" - }, - { - "m": 10, - "e": "37/120", - "components": [ - { - "index": 0, - "k": "9", - "lo": "9/4", - "hi": "5/2", - "u": 225, - "sq": "638293762541221093747816508114878880793600/12670638520251952131767561075962441202170201", - "sign_lo": "8519088897/512", - "sign_hi": "-568877325/16" - }, - { - "index": 1, - "k": "7", - "lo": "7/4", - "hi": "2", - "u": 155, - "sq": "39992206538790281750679741636522271281933/1671405449599205894628539681434631347656250", - "sign_lo": "-133895142933/1024", - "sign_hi": "40230640" - }, - { - "index": 2, - "k": "8", - "lo": "2", - "hi": "9/4", - "u": 121, - "sq": "30906246597347521204992829131708683421/2130683380444656398773193359375000000000", - "sign_lo": "-15116", - "sign_hi": "293463/64" - } - ], - "total": "607/750" - }, - { - "m": 11, - "e": "10/33", - "components": [ - { - "index": 0, - "k": "10", - "lo": "5/2", - "hi": "11/4", - "u": 229, - "sq": "270768145496851065976525637069732661192732900000000/5177630465344514816982506442433463167085530332106561", - "sign_lo": "346134085/8", - "sign_hi": "-41058196971/2048" - }, - { - "index": 1, - "k": "9", - "lo": "9/4", - "hi": "5/2", - "u": 154, - "sq": "25774045985593821375784246813470784975644433299961/1091596293147393410814963821091079711914062500000000", - "sign_lo": "-70180136721/1024", - "sign_hi": "1134770615/4" - }, - { - "index": 2, - "k": "10", - "lo": "5/2", - "hi": "11/4", - "u": 122, - "sq": "348705329536581989784912196711706323531582681/23742866139963781811525528755118604125976562500", - "sign_lo": "-1355", - "sign_hi": "1718871/64" - } - ], - "total": "5333/6600" - }, - { - "m": 12, - "e": "43/144", - "components": [ - { - "index": 0, - "k": "12", - "lo": "3", - "hi": "13/4", - "u": 235, - "sq": "26520865503698587417602539062500000000000000/482937844037254032100813776438682760806167409", - "sign_lo": "8660520", - "sign_hi": "-104015094267/1024" - }, - { - "index": 1, - "k": "10", - "lo": "5/2", - "hi": "11/4", - "u": 155, - "sq": "411535779455274768541650617194746668735655004975500313559771202653723/17323966715860733046200189982926496865335217500000000000000000000000000", - "sign_lo": "-2259439875/8", - "sign_hi": "172810506315/1024" - }, - { - "index": 2, - "k": "11", - "lo": "11/4", - "hi": "3", - "u": 125, - "sq": "122867860045464447609172630296457108866071/7919417137625252757504000000000000000000000", - "sign_lo": "-627061/64", - "sign_hi": "22842" - } - ], - "total": "2929/3600" - }, - { - "m": 13, - "e": "23/78", - "components": [ - { - "index": 0, - "k": "13", - "lo": "13/4", - "hi": "7/2", - "u": 239, - "sq": "10261487887363197834397469708157314007876/180296818648617353571477195328372072515625", - "sign_lo": "113267168547/2048", - "sign_hi": "-297427403/4" - }, - { - "index": 1, - "k": "12", - "lo": "3", - "hi": "13/4", - "u": 154, - "sq": "47722121814946760439811585176997743252260096594885332831227409002912841/2013026738709048149567060193021461600437760353088378906250000000000000000", - "sign_lo": "-92670480", - "sign_hi": "761200507431/1024" - }, - { - "index": 2, - "k": "12", - "lo": "3", - "hi": "13/4", - "u": 129, - "sq": "1181636795712106490656347650026063752159653585930396453711994929329/72023685843483620239169340493390336632728576660156250000000000000000", - "sign_lo": "-21168", - "sign_hi": "1041027/64" - } - ], - "total": "15929/19500" - }, - { - "m": 14, - "e": "7/24", - "components": [ - { - "index": 0, - "k": "14", - "lo": "7/2", - "hi": "15/4", - "u": 243, - "sq": "931732224047070511883660857541107339543622250000/15862443193197619493545506747144366925912619792641", - "sign_lo": "2010291801/16", - "sign_hi": "-12799209735/512" - }, - { - "index": 1, - "k": "13", - "lo": "13/4", - "hi": "7/2", - "u": 155, - "sq": "79883777618938672988321459316635177291889759782334208714149/3326166344477469187983121936213831738281250000000000000000000", - "sign_lo": "-591356590315/1024", - "sign_hi": "3615115413/8" - }, - { - "index": 2, - "k": "13", - "lo": "13/4", - "hi": "7/2", - "u": 132, - "sq": "126263305167394487826714216164913584397734348393124438290290547/7274325795372225114119087674499650011621093750000000000000000000", - "sign_lo": "-2298785/64", - "sign_hi": "13377/2" - } - ], - "total": "493/600" - }, - { - "m": 15, - "e": "13/45", - "components": [ - { - "index": 0, - "k": "16", - "lo": "4", - "hi": "17/4", - "u": 248, - "sq": "1488686634960976081550752780906145604133102500000000/24313124653786598685031896305554638743513954608688689", - "sign_lo": "53563692", - "sign_hi": "-384457669023/2048" - }, - { - "index": 1, - "k": "15", - "lo": "15/4", - "hi": "4", - "u": 156, - "sq": "723628356583696612772046448569698988880188312544077829283774464/30027213873897670110512823465045181592358858324587345123291015625", - "sign_lo": "-148173788025/1024", - "sign_hi": "1620722544" - }, - { - "index": 2, - "k": "15", - "lo": "15/4", - "hi": "4", - "u": 136, - "sq": "239942485521070994273626724216712223654146656620773376/13118557098965952137780652519381551398403263092041015625", - "sign_lo": "-407025/64", - "sign_hi": "50120" - } - ], - "total": "373/450" - }, - { - "m": 16, - "e": "55/192", - "components": [ - { - "index": 0, - "k": "17", - "lo": "17/4", - "hi": "9/2", - "u": 251, - "sq": "69735547485351562500000000000000000000/1107217223258472848854432556722827015361", - "sign_lo": "173820963103/1024", - "sign_hi": "-838909143/8" - }, - { - "index": 1, - "k": "16", - "lo": "4", - "hi": "17/4", - "u": 157, - "sq": "4153997784454318279837186805891153972139343015158471013410672833565845618192715067026221799941941759/169978506385079270493866310292814815088202965911994095784615542784000000000000000000000000000000000000", - "sign_lo": "-1184598144", - "sign_hi": "945916049041/1024" - }, - { - "index": 2, - "k": "16", - "lo": "4", - "hi": "17/4", - "u": 140, - "sq": "3293508622136713077980764008714648832693819105614030545555296840000180446441312133/168189265038967838695718824928581512577499101841730360221693738964843750000000000000", - "sign_lo": "-23376", - "sign_hi": "2551111/64" - } - ], - "total": "20027/24000" - }, - { - "m": 17, - "e": "29/102", - "components": [ - { - "index": 0, - "k": "19", - "lo": "19/4", - "hi": "5", - "u": 256, - "sq": "1227418617048630041167291089738524299729305600000000/18833511118948245571727665746196710518858636630828761", - "sign_lo": "48792555271/2048", - "sign_hi": "-393682155" - }, - { - "index": 1, - "k": "18", - "lo": "9/2", - "hi": "19/4", - "u": 157, - "sq": "73736936957566663364256745556643340794306184105186345168861458303146169487768007871808806413301247135143844562064/2999121654371641135853732569012436541634551848808823256327480371209142526521921672753023813129402697086334228515625", - "sign_lo": "-2942822097/8", - "sign_hi": "3113626213931/1024" - }, - { - "index": 2, - "k": "17", - "lo": "17/4", - "hi": "9/2", - "u": 145, - "sq": "4315063392497142436911899130565804971665271512643549297681/206370795799437622974892292404547333717346191406250000000000", - "sign_lo": "-2872677/64", - "sign_hi": "51111/2" - } - ], - "total": "21479/25500" - }, - { - "m": 18, - "e": "61/216", - "components": [ - { - "index": 0, - "k": "20", - "lo": "5", - "hi": "21/4", - "u": 259, - "sq": "4973995727176222495038879678800390625/74464108572646067850349626880398704656", - "sign_lo": "210282480", - "sign_hi": "-131671547703/512" - }, - { - "index": 1, - "k": "19", - "lo": "19/4", - "hi": "5", - "u": 158, - "sq": "19190711389019402801011458678792094731777275286268609806543261150599360073586921690381026373633/771251477700149520595490077300249406132439714782773248000000000000000000000000000000000000000000", - "sign_lo": "-2548723303977/1024", - "sign_hi": "1483401840" - }, - { - "index": 2, - "k": "18", - "lo": "9/2", - "hi": "19/4", - "u": 150, - "sq": "112008335495215130632874007087522219844601184687769942914361777982260447893360054218524021394736574751/5029126802898557611612698554139953040078290766852570995127775350650308440673828125000000000000000000000", - "sign_lo": "-71442", - "sign_hi": "426347/64" - } - ], - "total": "11467/13500" - }, - { - "m": 19, - "e": "16/57", - "components": [ - { - "index": 0, - "k": "21", - "lo": "21/4", - "hi": "11/2", - "u": 262, - "sq": "346357880916537048190021331124574544367187897516340250000/5078023369287431876477195468132354433627561616518782694721", - "sign_lo": "959258815749/2048", - "sign_hi": "-815511069/16" - }, - { - "index": 1, - "k": "21", - "lo": "21/4", - "hi": "11/2", - "u": 159, - "sq": "95034881763670320507506158189213513439172260397959272626850665660254735038139303264249784026259553722174941807568721/3792220498905088292313488954182468544591454362020924749149666528114065925373022280946373939514160156250000000000000000", - "sign_lo": "-1195908707673/1024", - "sign_hi": "39694891881/8" - }, - { - "index": 2, - "k": "20", - "lo": "5", - "hi": "21/4", - "u": 154, - "sq": "618700387502477191416126025360269406473680599217185635438494523846969282565979761/26144694679481366637798962847343377941175634965267324404736000000000000000000000000", - "sign_lo": "-17390", - "sign_hi": "5196771/64" - } - ], - "total": "1951/2280" - }, - { - "m": 20, - "e": "67/240", - "components": [ - { - "index": 0, - "k": "23", - "lo": "23/4", - "hi": "6", - "u": 265, - "sq": "5076176541391545719082859685025/72349808205694038357981429164161", - "sign_lo": "247221526935/1024", - "sign_hi": "-512236224" - }, - { - "index": 1, - "k": "22", - "lo": "11/2", - "hi": "23/4", - "u": 159, - "sq": "22195005908908006339127692644804714630090350442953587921865410098990403005009567792562428564045583934439495668727639540938970969/878196407337946788064260689643400167403577936724168306881210810388438403606414794921875000000000000000000000000000000000000000000", - "sign_lo": "-42354538721/8", - "sign_hi": "1748523396495/1024" - }, - { - "index": 2, - "k": "21", - "lo": "21/4", - "hi": "11/2", - "u": 160, - "sq": "10403283810191443915559584605203635677969611777768568218831548176682782494341615572638694551580577591/411224373198171286400060795987542531917850536898561290278346413099495506875000000000000000000000000000", - "sign_lo": "-3020625/64", - "sign_hi": "60958" - } - ], - "total": "5179/6000" - }, - { - "m": 21, - "e": "5/18", - "components": [ - { - "index": 0, - "k": "24", - "lo": "6", - "hi": "25/4", - "u": 268, - "sq": "7304961283546767847721430101718554257587095413401000000/102309671589518332589788177932976932173729961153558998569", - "sign_lo": "638962668", - "sign_hi": "-385457580285/2048" - }, - { - "index": 1, - "k": "24", - "lo": "6", - "hi": "25/4", - "u": 160, - "sq": "27735140698634445999393613038498325941432595096804879312799932494814048721203031127142555057721086150327096896234888978602108010249/1089327385337662774149348214789726350491137189234788047210424189531766488878775416236263467692593112587928771972656250000000000000000", - "sign_lo": "-3461741064", - "sign_hi": "7109884391895/1024" - }, - { - "index": 2, - "k": "22", - "lo": "11/2", - "hi": "23/4", - "u": 165, - "sq": "58555689253557068612259677896717177086686929453358646656895931374900790300865234912103907954910569341023737538576053688449/2172059205993341570405504972999185496287418150860524588510169711067844013074878972702208557166159152984619140625000000000000", - "sign_lo": "-83386", - "sign_hi": "2231135/64" - } - ], - "total": "7837/9000" - }, - { - "m": 22, - "e": "73/264", - "components": [ - { - "index": 0, - "k": "26", - "lo": "13/2", - "hi": "27/4", - "u": 271, - "sq": "393454895918196430471192730428579251637827600/5384472071354360808523478203580776932968239801", - "sign_lo": "4179532381/16", - "sign_hi": "-461497339215/512" - }, - { - "index": 1, - "k": "25", - "lo": "25/4", - "hi": "13/2", - "u": 160, - "sq": "10047365346100772517391627724639559774486716442239011108372472012122353867991997421358801785796556029191320990933672475192679482983778677/392974369789993708634431152590661429831899432359539117433112991766797673358340343461847437931580066680908203125000000000000000000000000000", - "sign_lo": "-11407621809855/1024", - "sign_hi": "4369475825/8" - }, - { - "index": 2, - "k": "23", - "lo": "23/4", - "hi": "6", - "u": 170, - "sq": "5681354213451082801613189599979880809040483152777672847878144/198337973047283602051368353775432446927879936993122100830078125", - "sign_lo": "-8103053/64", - "sign_hi": "2268" - } - ], - "total": "14479/16500" - }, - { - "m": 23, - "e": "19/69", - "components": [ - { - "index": 0, - "k": "27", - "lo": "27/4", - "hi": "7", - "u": 273, - "sq": "350054734693932971249121000000000000000000000000000000/4722466635015948035229880083532699571588888670499548049", - "sign_lo": "1764122088969/2048", - "sign_hi": "-401538301" - }, - { - "index": 1, - "k": "27", - "lo": "27/4", - "hi": "7", - "u": 161, - "sq": "65684021456017756328036188304904438836212679239799244235513010349843899755715529699739663901462798057620586088174750051620079382080009649/2550660482371861186937215972044429020606912672519683837890625000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-9278084145105/1024", - "sign_hi": "7774441634" - }, - { - "index": 2, - "k": "25", - "lo": "25/4", - "hi": "13/2", - "u": 175, - "sq": "23033360560313453277223271333016158477095229050914940317854183255792077665588508111285078667371825603535851714318576675681/757638788858751152137917914617278011502956291659641778268973440604364018511788115594053364157002197265625000000000000000000", - "sign_lo": "-2399525/64", - "sign_hi": "119736" - } - ], - "total": "61021/69000" - }, - { - "m": 24, - "e": "79/288", - "components": [ - { - "index": 0, - "k": "29", - "lo": "29/4", - "hi": "15/2", - "u": 275, - "sq": "15717303175066366312563294944175114496000000/208073051338066793077461358015741558767840121", - "sign_lo": "283347244119/1024", - "sign_hi": "-11616042735/8" - }, - { - "index": 1, - "k": "29", - "lo": "29/4", - "hi": "15/2", - "u": 161, - "sq": "698438622788453988425611353017360318169128715679399585578588016509743581360368300342319485884268912675014731563/27027356106463959056827727077560926298937562837165051611298699200000000000000000000000000000000000000000000000000", - "sign_lo": "-4235284902411/1024", - "sign_hi": "156670873515/8" - }, - { - "index": 2, - "k": "26", - "lo": "13/2", - "hi": "27/4", - "u": 180, - "sq": "9173422663553561659683130401057886390494294088968510363375137307126292760010926946406092298026963103946103/283800262209165852164507468934633734070788960217948026251113025341469150510142800000000000000000000000000000", - "sign_lo": "-170237/2", - "sign_hi": "5437611/64" - } - ], - "total": "32051/36000" - }, - { - "m": 25, - "e": "41/150", - "components": [ - { - "index": 0, - "k": "30", - "lo": "15/2", - "hi": "31/4", - "u": 277, - "sq": "105493009408241734632805695831765149666830449228515625000000000000/1380809103998266352997784608793875271373387284168892436264379454881", - "sign_lo": "9332955675/8", - "sign_hi": "-1423097239209/2048" - }, - { - "index": 1, - "k": "30", - "lo": "15/2", - "hi": "31/4", - "u": 161, - "sq": "1864531586952572261123760254002667296740112246052447864827391642340089551251144117264571717166181926052395012920854617276108589934062139064588485639131125639298584830125259381711904449/71950381657623463405052637224215112818828358538809672400386480980020289934944769036527659635536991928309331470138655025326001690808702671020569141546729952096939086914062500000000000000", - "sign_lo": "-21226985550", - "sign_hi": "5048704980651/1024" - }, - { - "index": 2, - "k": "27", - "lo": "27/4", - "hi": "7", - "u": 186, - "sq": "410172098148017170348031110894125763430224324644641211922230280019560109668936624040592687739545222505201801/11970924228286743164062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-9045513/64", - "sign_hi": "42204" - } - ], - "total": "673/750" - }, - { - "m": 26, - "e": "85/312", - "components": [ - { - "index": 0, - "k": "32", - "lo": "8", - "hi": "33/4", - "u": 279, - "sq": "4237044877656546923879493600279092788696289062500000000/54618988497115964036963584074927591663586263586670282641", - "sign_lo": "311059152", - "sign_hi": "-1116635152527/512" - }, - { - "index": 1, - "k": "32", - "lo": "8", - "hi": "33/4", - "u": 162, - "sq": "503819501028181779671595767438229500763155039131183227548864390434185170498945506834793805591265394311520191778013673688628612087763814059895422976/19375458632013934263921727237315602288460383367659279175975830914362739678204401464138076330915678883719146900765917251874270732514560222625732421875", - "sign_lo": "-16215347376", - "sign_hi": "20276031458025/1024" - }, - { - "index": 2, - "k": "29", - "lo": "29/4", - "hi": "15/2", - "u": 191, - "sq": "1484043684853453719884639961052865577815165164432061982826090892571835873082550048828125/41076015699246255913604274009604466963470140920615660207335904712177553691385470908366848", - "sign_lo": "-594081/64", - "sign_hi": "419715/2" - } - ], - "total": "35273/39000" - }, - { - "m": 27, - "e": "22/81", - "components": [ - { - "index": 0, - "k": "33", - "lo": "33/4", - "hi": "17/2", - "u": 280, - "sq": "26928447704834089062917481960104992265677099977321/344150050786083658683945628656384871176909339372025", - "sign_lo": "3294685544661/2048", - "sign_hi": "-1054324773" - }, - { - "index": 1, - "k": "34", - "lo": "17/2", - "hi": "35/4", - "u": 162, - "sq": "1804597005659090593692217482268641094136039729940835812383387161120498889296471800510657650888060508926772049880917312153105870157607059840310226205387093493442999452279711486788388064229057081632681/69352674944889878900011219452947626206682139742397172561829113517251025951662208404830791678201227605222313795495374612652304051932637120826450040049140999690280295908451080322265625000000000000000000", - "sign_lo": "-6195465276", - "sign_hi": "43591530258375/1024" - }, - { - "index": 2, - "k": "30", - "lo": "15/2", - "hi": "31/4", - "u": 196, - "sq": "306035795552009759312793869131934895304890421761675986275766697182407747116741712949436238080250100421814493597748321609348961212792476624439520246645860515329/7994043921043534055899091839501825802566845383909247874535065940053779592597988130174199731945718096143469679070463272951345632517328262329101562500000000000000", - "sign_lo": "-140535/2", - "sign_hi": "10548239/64" - } - ], - "total": "36839/40500" - }, - { - "m": 28, - "e": "13/48", - "components": [ - { - "index": 0, - "k": "35", - "lo": "35/4", - "hi": "9", - "u": 282, - "sq": "12110178061777046843369463585177600000000/152893581783201068017886371454064665785369", - "sign_lo": "422889484255/1024", - "sign_hi": "-3085052184" - }, - { - "index": 1, - "k": "35", - "lo": "35/4", - "hi": "9", - "u": 162, - "sq": "6663809171648796916337726545655491770443952524117906746183083398822709369593316525666885421028664610285469983554293831730339/256091666279147404638317254099691479090050375367835730314994384896000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-43221884492045/1024", - "sign_hi": "10785881592" - }, - { - "index": 2, - "k": "31", - "lo": "31/4", - "hi": "8", - "u": 202, - "sq": "633627232488424933654711591966650712917552690547446925620269274533635455117905148692718119799929319741074499398795264/15665295631900096198195953532373330109933209643339271955859045625093234093401718833286061374642643518745899200439453125", - "sign_lo": "-9059181/64", - "sign_hi": "110152" - } - ], - "total": "5501/6000" - }, - { - "m": 29, - "e": "47/174", - "components": [ - { - "index": 0, - "k": "36", - "lo": "9", - "hi": "37/4", - "u": 283, - "sq": "807707317262331019057967518917952217129032977058764582488795765625/10135162407748791626573960157186366097829246376741654098343219564544", - "sign_lo": "2275658793", - "sign_hi": "-2944382957117/2048" - }, - { - "index": 1, - "k": "37", - "lo": "37/4", - "hi": "19/2", - "u": 162, - "sq": "88183664478754631624013699724614020803357421859633634229172437714526567537983497975333771448614395455409657394889268687577853970989078229316479336084809541103009793858147239057908357279536818604920111809/3386701606299295215410985984328573999262196659406237110823755491220734962145767430518554199678666563133962091759059726652573129535268392584917984677872482279781252145767211914062500000000000000000000000000", - "sign_lo": "-34129222216537/1024", - "sign_hi": "37163292945" - }, - { - "index": 2, - "k": "32", - "lo": "8", - "hi": "33/4", - "u": 207, - "sq": "1208755783069986065409597899702551898364111117244676024058855469465772844383662601339983760440035852885819943121738658052659380457118360081/28360042470273430719221853142194632367000200701714782069299646070692621905619257294262069990509189665317535400390625000000000000000000000000", - "sign_lo": "-223956", - "sign_hi": "2883195/64" - } - ], - "total": "10028/10875" - }, - { - "m": 30, - "e": "97/360", - "components": [ - { - "index": 0, - "k": "38", - "lo": "19/2", - "hi": "39/4", - "u": 284, - "sq": "367353879381645389717887769262383252764944/4565661172260621337749024022758610200324025", - "sign_lo": "10697870985/16", - "sign_hi": "-2114428842423/512" - }, - { - "index": 1, - "k": "39", - "lo": "39/4", - "hi": "10", - "u": 162, - "sq": "360607699442052098417745093006223581739870369318723834423485464951797444856460318927400937951353114782017589114783191247916032144754124391972864/13869645470288764541313790565940290822056613529691088563686888129516810714191422256670951798145448289234678285186674884243984706699848175048828125", - "sign_lo": "-17005573453437/1024", - "sign_hi": "75930577200" - }, - { - "index": 2, - "k": "34", - "lo": "17/2", - "hi": "35/4", - "u": 212, - "sq": "96803363148650413439627725543865364934713044547827718853607262334640642454302530238098549476126645215822073697497479769350682830095924377114853939514621991072998046875/2162928992706138785221157924131871070087496966278661400797172712782791897051187407195969571512612965562982813727660902837742858158897055454162490541676108143668905377792", - "sign_lo": "-31333", - "sign_hi": "18137675/64" - } - ], - "total": "8347/9000" - }, - { - "m": 31, - "e": "25/93", - "components": [ - { - "index": 0, - "k": "39", - "lo": "39/4", - "hi": "10", - "u": 285, - "sq": "1370012501802155212072073608337573970561600710102015625/16961604807195104800847088606056723478949272415622376964", - "sign_lo": "6763683676329/2048", - "sign_hi": "-1761215460" - }, - { - "index": 1, - "k": "40", - "lo": "10", - "hi": "41/4", - "u": 161, - "sq": "55998102243494337652748694649011912128393149890530372486016716477193847585917608266268875665784027987056044091073845541502601501634406691436166684481948694997290314620180744815875435274929466098744440471891909618178665163420047058162805921/2161245252447042298973635372719011068998247548409457161987116088895522778517805675578851276777902193012803740287656906878179559441843337050863999143087417362762486089876537806402972168881706807042064610868692398071289062500000000000000000000", - "sign_lo": "-88682212800", - "sign_hi": "10940729043439/1024" - }, - { - "index": 2, - "k": "35", - "lo": "35/4", - "hi": "9", - "u": 218, - "sq": "11145318280788936864651132207230709038652778735541738706572075211924368985579583420900792475721/236553766550457946147512890282332069479311071163881457975296000000000000000000000000000000000000", - "sign_lo": "-7671545/64", - "sign_hi": "214974" - } - ], - "total": "10844/11625" - }, - { - "m": 32, - "e": "103/384", - "components": [ - { - "index": 0, - "k": "41", - "lo": "41/4", - "hi": "21/2", - "u": 286, - "sq": "41899219043964738475118657497129288079225640714240000/514959170417627120050112213996069837235391786225277809", - "sign_lo": "1245527721519/1024", - "sign_hi": "-41873975055/8" - }, - { - "index": 1, - "k": "42", - "lo": "21/2", - "hi": "43/4", - "u": 161, - "sq": "11152981218565371204051090368815249042780164584368480982721191099476492415864305684169887243229806602002617270903064152370153502114952565605579633040420017568282083611238597400652294792975523970142665880496940930164520089435089225712136195769345223/431087127942047774616680827233953277989930476631680464138424829292607279383085277002920954360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-613960113447/8", - "sign_hi": "53117664510419/1024" - }, - { - "index": 2, - "k": "36", - "lo": "9", - "hi": "37/4", - "u": 223, - "sq": "645558869609974248821201750239132809557355670579600913102783826392471283446131742013051000686972655754461728957876426868257697179379952472342286912651097384391434705571008658479819190558068474124226353/13047975641125999848982109164478791828140746860541542420598075875734308502314037904810960615355819031094271976819308698695147961012136466143001512803758126230323200000000000000000000000000000000000000000", - "sign_lo": "-221454", - "sign_hi": "8591983/64" - } - ], - "total": "9007/9600" - }, - { - "m": 33, - "e": "53/198", - "components": [ - { - "index": 0, - "k": "42", - "lo": "21/2", - "hi": "43/4", - "u": 286, - "sq": "28166826911416374936093505473693847656250000000000000000/345560027157622368121115804292644142489454181815039821321", - "sign_lo": "78212388483/16", - "sign_hi": "-3857312425593/2048" - }, - { - "index": 1, - "k": "44", - "lo": "11", - "hi": "45/4", - "u": 161, - "sq": "2013157485321119240703053530699773925085616614711197288945673337149531498302969808661625694820512254955404354184217054816316177570289680982242805642717571353411661128253906919202147897625133781778734322939529/78061453081796836909426525232446110386274785681730248216446521734613416773689811475494105275981636736004372698945316022540666102897376118820970552669905373477376997470855712890625000000000000000000000000000000", - "sign_lo": "-53731344348", - "sign_hi": "113639174154135/1024" - }, - { - "index": 2, - "k": "37", - "lo": "37/4", - "hi": "19/2", - "u": 228, - "sq": "260368545548813136237315115037622506258666749092722386614036948442210969188213320188636551504721240315595083192175465029091273222838069613020566123464981911779760619788471594082849/5023066055020658988359057736501507647149297998948417287126044476921976334347814026603849495690241026850457708966706839304183773720069439150393009185791015625000000000000000000000000", - "sign_lo": "-21569197/64", - "sign_hi": "40313" - } - ], - "total": "3733/3960" - }, - { - "m": 34, - "e": "109/408", - "components": [ - { - "index": 0, - "k": "44", - "lo": "11", - "hi": "45/4", - "u": 287, - "sq": "52211950991856029871407639829784041989554952250000/637133476632117529934660843719900945735712972317321", - "sign_lo": "2264545576", - "sign_hi": "-3202042873095/512" - }, - { - "index": 1, - "k": "46", - "lo": "23/2", - "hi": "47/4", - "u": 161, - "sq": "14091929269576974592237457527795653043026800298336846032706926435768832596539623520468805552616055462137758253456381800131103941547628084268042177704251124011900352095374850978081447935163008322450281539448683027731425537521390485699449595005589042180808437875361/548986821167722541315071792349867620527177844134800550755473758466947632737913113988661294035893372350420394421721751287548819514027153524493779725947494448689911684148314498634668465230368873575472691309971359988474463864616126329565304331481456756591796875000000", - "sign_lo": "-128660847891/8", - "sign_hi": "197422750853923/1024" - }, - { - "index": 2, - "k": "39", - "lo": "39/4", - "hi": "10", - "u": 233, - "sq": "83020569466720643349747721507976544065651636287368010213723862132822150039128198000628881657678462542481508000000000000000000000/1532232046432634854765227903352662914157339933914936455063351968484653192680279842529814796825213810835144522488898491883537047479", - "sign_lo": "-4337901/64", - "sign_hi": "366660" - } - ], - "total": "12089/12750" - }, - { - "m": 35, - "e": "4/15", - "components": [ - { - "index": 0, - "k": "45", - "lo": "45/4", - "hi": "23/2", - "u": 287, - "sq": "73700277720319733247931930080920379224436471713319396972656250000/899416323463051567165807476395654787879107028378494194659104428321", - "sign_lo": "14980449997125/2048", - "sign_hi": "-25372769503/16" - }, - { - "index": 1, - "k": "47", - "lo": "47/4", - "hi": "12", - "u": 160, - "sq": "1013288626246128660845689156433862435905809311206700891938930565095032533169094920322890252286883894289633626537082102676021700982091916866069595306470670336/39703978292674329281824415354028800284556452313679066532060504947853562585601899521213767406004229551512990176732041149032514937289306544698774814605712890625", - "sign_lo": "-185561742235713/1024", - "sign_hi": "40478279040" - }, - { - "index": 2, - "k": "40", - "lo": "10", - "hi": "41/4", - "u": 239, - "sq": "4774332678129393127948710356223343133951863168123962658336513391625653645340758931418012481126832387708125242170859649824695441150247694177967854599532326467272702828122503422694517749842783186861357154602327708401/84204664098266510734917724142403523431126845972388108760484085155516023366715050565437702676278313355431013955477853464508561921547881680784001697309573851278310133205082358711025390625000000000000000000000000000000", - "sign_lo": "-191000", - "sign_hi": "17164155/64" - } - ], - "total": "1429/1500" - }, - { - "m": 36, - "e": "115/432", - "components": [ - { - "index": 0, - "k": "47", - "lo": "47/4", - "hi": "12", - "u": 287, - "sq": "3801372382804402150213718414306640625/46221808608953758727469870915254699961", - "sign_lo": "4211639097543/1024", - "sign_hi": "-6959488896" - }, - { - "index": 1, - "k": "49", - "lo": "49/4", - "hi": "25/2", - "u": 160, - "sq": "3172803384636863355335502208863626528150693327608579503232198118569110249761676347436554791855488054158025609553058816474638071340829211202468027495569738526493300435998791643721787970299874151236373449073910431585838940271433486167/124892373709018480459001628622162920432576750295102968514709928463762497339003856156260377886662360555060506583378167161404671506001155562774737259417763221884472697362624704121191647823718717802421451779082417488098144531250000000000", - "sign_lo": "-160917797712111/1024", - "sign_hi": "968338811865/8" - }, - { - "index": 2, - "k": "41", - "lo": "41/4", - "hi": "21/2", - "u": 244, - "sq": "1569460100262200674694024079674702495467049598137772529909056874800654725667648899395838639067545926940413497160541116188247042782165749758329126738726224134776095507/26508953673075994378658378978560051374569737362372811485154425229912238915023894542652063587337170491350469570077305160908270000000000000000000000000000000000000000000", - "sign_lo": "-21142249/64", - "sign_hi": "308853/2" - } - ], - "total": "51689/54000" - }, - { - "m": 37, - "e": "59/222", - "components": [ - { - "index": 0, - "k": "48", - "lo": "12", - "hi": "49/4", - "u": 287, - "sq": "360493065727462756141648957307039554002742806310097322563519736384/4391078756503303783239787417440926274538703255382638901056643805225", - "sign_lo": "10969915212", - "sign_hi": "-1125462544029/2048" - }, - { - "index": 1, - "k": "51", - "lo": "51/4", - "hi": "13", - "u": 159, - "sq": "8653932218621805638726826478279685672703989078103908985950990349722339186267718551102968636225434842055204457353113971727520997478179759353222772421908215504653259816946293395505946638390799834538295429767898167507051443058249549933054260334063041/342638955126068320654041787909613341429698085801083791299134569458086885567394288207931587199967085206496339463130808895527264750877686113648128838032885479855622612582400000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-117382832516205/1024", - "sign_hi": "231617831556" - }, - { - "index": 2, - "k": "42", - "lo": "21/2", - "hi": "43/4", - "u": 249, - "sq": "22926810587846563904330079034750659504085270519056104737074687900055984089647468903039995488012071215504774128740898472976918699907430075622579013537304459576970196152739231149090630407826627829197015040705468432641743222690614660665381689/371599930188540179013917620592985372647314966093381226633408575820651772980639497362811912126409832541245532928072845853429340475859744038132352499462472164793344236053299319974069442676367636124723503598943352699279785156250000000000000000", - "sign_lo": "-973701/2", - "sign_hi": "1558647/64" - } - ], - "total": "21329/22200" - }, - { - "m": 38, - "e": "121/456", - "components": [ - { - "index": 0, - "k": "50", - "lo": "25/2", - "hi": "51/4", - "u": 287, - "sq": "3321596956380208888364845490732538132971479152511256250000/40372218128115972521845589209862189302399048646023720641049", - "sign_lo": "114836928285/16", - "sign_hi": "-3589922188863/512" - }, - { - "index": 1, - "k": "53", - "lo": "53/4", - "hi": "27/2", - "u": 159, - "sq": "930906834211384684835210736815225593653941393508969317065488163808781502568272795420251170126719702681716497646468190561592614177316191601887222763432152843391570418354027834449955794089840718953250885307379002680626172254190531140333/37114086979841206001380078366602496689591215177135007814277183065763722820197227258265203901188375866819438430036755994315292168480840366616522763245695328628849267715850146487355232238769531250000000000000000000000000000000000000000000", - "sign_lo": "-49654473098499/1024", - "sign_hi": "3033930905181/8" - }, - { - "index": 2, - "k": "44", - "lo": "11", - "hi": "45/4", - "u": 254, - "sq": "36999321434330625321503294898085720802012309828033233428462610993313674280112392858448175806079858493899929514014406715009818000423908233642578125/576268868943196848463091494654410346107016663099972291312617363615009593078572863617581746514261849457936301455673402275996928526448048681661759488", - "sign_lo": "-123072", - "sign_hi": "29303775/64" - } - ], - "total": "2201/2280" - }, - { - "m": 39, - "e": "31/117", - "components": [ - { - "index": 0, - "k": "52", - "lo": "13", - "hi": "53/4", - "u": 287, - "sq": "98361860325639846873188923578733542002737522125244140625/1194562690258813942840560865032522450223903417563852570624", - "sign_lo": "1670891001", - "sign_hi": "-32079024532815/2048" - }, - { - "index": 1, - "k": "54", - "lo": "27/2", - "hi": "55/4", - "u": 158, - "sq": "18806864657293553276518615039395257771975569833606810631292710048998250058421317150425144135986575312010050370433935926037990353402064726224140692795862874791478563641894305334889873707599004808835926435875752924826249458372655618355405022978129194030435577812222336588747068826119248577114381218806152609/756430501508222896124896939606748743379137643694828177119857721991321880437208355777277443255536847024255075424775706256563410194242663709816821813355979822456875333815332066276867806489298512399232752141129601764974692171417043128375543785714418820731452797190286219120025634765625000000000000000000000000", - "sign_lo": "-3218998084857/8", - "sign_hi": "48513797948295/1024" - }, - { - "index": 2, - "k": "45", - "lo": "45/4", - "hi": "23/2", - "u": 259, - "sq": "1874559116069106350577523378378983839080903810242036127107503705911173173750689038638469197091517048474616934304737371073423922400089015991095217225270042283178737269833013546435732986335536170213912692661981469403337238209/28051112812464294929100472064640500036095282823033026118665137623962303625560778202510527780735255497015027595024193272707854110084726803872355737241375523764983299927630149288446774316406250000000000000000000000000000000000", - "sign_lo": "-18491085/64", - "sign_hi": "643783/2" - } - ], - "total": "14171/14625" - }, - { - "m": 40, - "e": "127/480", - "components": [ - { - "index": 0, - "k": "53", - "lo": "53/4", - "hi": "27/2", - "u": 287, - "sq": "10165399005188922146132916256224431967037440000/123857955920143931888993140173300078563795728081", - "sign_lo": "12306886934695/1024", - "sign_hi": "-47460920247/8" - }, - { - "index": 1, - "k": "56", - "lo": "14", - "hi": "57/4", - "u": 158, - "sq": "206403357454822958098854563408621409297243206333973169528652719680792789055275238756459542049240883043877636321740836778980445333048248745396604742183559103468949377042962141490159134141008601706544295777830677850997835646081634518832283162499642987652709827688429107848909331537/8358404375211205321868793514387031789569017877674808813027291255124622099267917626866665745404765047947171949377187334781209347925795517666031334443925527623608398437500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-370942129856", - "sign_hi": "184423910858217/1024" - }, - { - "index": 2, - "k": "46", - "lo": "23/2", - "hi": "47/4", - "u": 264, - "sq": "42643097513680415451942270034789787371707072752000165248416489362246061994767011196382608693944792842315449654849923008565425201249699821442131223768857603663672264584771340897451859377847245716992255896870062650877702007495663053181378725339979363925140305355772172558043/614225329043894937607556876459910795877420041634846948331898379379112347052672585729397914098628618684427435337002902706286107740349108698984849023194630037229138078135558677993541789467893319588700098340772987575247657916062500000000000000000000000000000000000000000000000", - "sign_lo": "-474300", - "sign_hi": "10707187/64" - } - ], - "total": "11683/12000" - }, - { - "m": 41, - "e": "65/246", - "components": [ - { - "index": 0, - "k": "55", - "lo": "55/4", - "hi": "14", - "u": 287, - "sq": "1522408189531421776995276323473933667783727982659845675469140625/18555710627948082750768927612714808973871938469195036177190101124", - "sign_lo": "11630171668375/2048", - "sign_hi": "-16072703892" - }, - { - "index": 1, - "k": "58", - "lo": "29/2", - "hi": "59/4", - "u": 157, - "sq": "583784744452280255283866043343829430847409156541752160844110187983396539427406101359305953419410766691956204232578648827276752717316495140352166375317553953401268757910005155926929761165526483968570070132927820187990886842246312090909749265075977612339311377353797931871653359002055841459975872689413688376210077011486832763655381098897285471710281/23824422870679708130108718033732889678101203819285732587553173645875041268314798688880033216060423118399597969090724806404277893659351668491709544858762958708687781370896608233871133948500425862090254395840530091461163040745872562966415179711350160700976964074686330641030518547355491337791377759458555374294519424438476562500000000000000000000000000", - "sign_lo": "-2502775137635/8", - "sign_hi": "366552506271579/1024" - }, - { - "index": 2, - "k": "48", - "lo": "12", - "hi": "49/4", - "u": 269, - "sq": "472260386639649989781481146174579459180847224576343588402087912950146697880968071269212392388927148724581391693708357351464541802697743439270515920390225695014787195664588475734844849190790685375613216773788537288990416354475584124904876767166301206307770480429598769743681/6567788821475945465084096356008850251021431059497748323230768044530119062371883389728678596900477892812541306320758452999103996953540998355620740428129502672376098700245622422713616225373750422299338090884582548609985043243523597717285156250000000000000000000000000000000000", - "sign_lo": "-7020", - "sign_hi": "45787099/64" - } - ], - "total": "120199/123000" - }, - { - "m": 42, - "e": "19/72", - "components": [ - { - "index": 0, - "k": "56", - "lo": "14", - "hi": "57/4", - "u": 286, - "sq": "3506936358422527939629138238793091070897320505902240000/42943272869450096386833857349523957549601391893343032641", - "sign_lo": "19375040496", - "sign_hi": "-1573691990175/512" - }, - { - "index": 1, - "k": "60", - "lo": "15", - "hi": "61/4", - "u": 156, - "sq": "477999393506156990968406198057368729192269396673720502610374798521809053400740101261232652896386033703616602324610672900957268217580948199192445848068122136390777050805563528787455061166577561174554930965544809376817789641218508703853875105921202219496196464948738168564560057046064124761993181186110273155690921984/19675628501092962982239046297698260737121918465928277712003388139945346618342572245567361991454451397674564562270561661616120921482851811284450218984774078082193387159272164103374460753304577446023412977788738844905586760743880430668345336751363180755762487565700969609225139643482460627410546294413506984710693359375", - "sign_lo": "-221204115000", - "sign_hi": "604678532698005/1024" - }, - { - "index": 2, - "k": "49", - "lo": "49/4", - "hi": "25/2", - "u": 274, - "sq": "547934952128228586241730634630961379529321397665946357802218220588846896260256303150779838909190070703977718881624414245445759263824766837718504636437857117114735224416087914036700701192472706679836846888065338134765625/7343801640019264919102790491340740522466306923772264377483575398504110701998238762661497913020340125684829790237072623741740551807249854041081104410260643860110865524289377229657033279242523236385421088286999325102309376", - "sign_lo": "-12941593/64", - "sign_hi": "554720" - } - ], - "total": "8819/9000" - }, - { - "m": 43, - "e": "34/129", - "components": [ - { - "index": 0, - "k": "58", - "lo": "29/2", - "hi": "59/4", - "u": 286, - "sq": "409623834162785169913845110065844167327273038357470693971071819438336/5022745790327246703171471587315304860390978137165146919011572331824641", - "sign_lo": "98163082227/8", - "sign_hi": "-30166129179691/2048" - }, - { - "index": 1, - "k": "62", - "lo": "31/2", - "hi": "63/4", - "u": 156, - "sq": "223283810647691987441513829537269868865932938550247806885378729242278003780319903577666569129448846989140999547726067279096841399996906670460204179966784051244490548221424574438774649193930409199101675588358948372134349087581328273920685101005209277637871068048884084600230083561899516212118170881125192684331378481/9277337158566813803581243692197298941728212544236245862904325889149081000039946879417891519759414691836148277086981582825551108512732578618532930139592624992499885400824759778880425705613474492363027623283009666105774570146353543838764022121307940837997563221506425179541110992431640625000000000000000000000000000000", - "sign_lo": "-704135133685/8", - "sign_hi": "910019415135951/1024" - }, - { - "index": 2, - "k": "50", - "lo": "25/2", - "hi": "51/4", - "u": 279, - "sq": "3394158388447380975957978090721318808313812491428451244454611452452189554935232598779925131593297961948751178946661181391809162349284299936239929532188914679016227132399970769648109115930341841774310034975742063948590657006208641/43916384886161413932922750183897595235007772439504353909495065097870988581809183414105853347417640785664402480606816901627536285856374216642165667369848256918632761366385790186595985902404785156250000000000000000000000000000000000", - "sign_lo": "-419450", - "sign_hi": "23868999/64" - } - ], - "total": "127009/129000" - }, - { - "m": 44, - "e": "139/528", - "components": [ - { - "index": 0, - "k": "60", - "lo": "15", - "hi": "61/4", - "u": 286, - "sq": "264758333272256448541517789982876401864552729719626521094400000000/3254011474367032379178879447015868972737162834626773051755741887329", - "sign_lo": "2423341800", - "sign_hi": "-30562772052763/1024" - }, - { - "index": 1, - "k": "63", - "lo": "63/4", - "hi": "16", - "u": 155, - "sq": "76996894114391539093443520988160073607151971917989162166006260888943540379024315226983827967766186919529486817423994658121175699923746621638609115934225786120428476277617728561508006438949375132963556646992409408076252886276154945582399488/3235404740489583882667863027390012131351990784930099996763981641073602537705139855712606303456009487588314570208077003950933117234669335018687510511200760647250688489239204384590054245708687487046511335464504810488506336696445941925048828125", - "sign_lo": "-944428314357225/1024", - "sign_hi": "95942262656" - }, - { - "index": 2, - "k": "51", - "lo": "51/4", - "hi": "13", - "u": 283, - "sq": "3288070488300019407131515649897279793763851859727669385545123557179879322333601586035802807999304029919085082770018860984585451608347675650427315253501418287976688227068720994858346650023699657721871163318177939228875216083/41137908589540522089271408366948688062406844378882055943200810054535540163416101471736543789604212550644973068112101213267448872977622513462922107583273933183610570923835392000000000000000000000000000000000000000000000000000", - "sign_lo": "-42235749/64", - "sign_hi": "168934" - } - ], - "total": "65159/66000" - }, - { - "m": 45, - "e": "71/270", - "components": [ - { - "index": 0, - "k": "61", - "lo": "61/4", - "hi": "31/2", - "u": 285, - "sq": "68951601382420087432559202520943488650647073034016564965326562500/852408236699517927845209883901697264314432031250178387612020330449", - "sign_lo": "46028075870691/2048", - "sign_hi": "-10710049041" - }, - { - "index": 1, - "k": "65", - "lo": "65/4", - "hi": "33/2", - "u": 154, - "sq": "1849572338432898993359588216522365235706583650958895483252816151064471902616145475151201546384665049579538248983175402694571193972998775263334674039334213744153031050803547450527351119950537095212410572988993137273921030050520496737567489612790628809/78437011999712947095668433687533497894083501785050442958645069760273639221320466388467780409398820900588088974792844375568628341481805596653112486147776829876603968947669509592657277607941068708896636962890625000000000000000000000000000000000000000000", - "sign_lo": "-897423208163625/1024", - "sign_hi": "2730062129697/8" - }, - { - "index": 2, - "k": "53", - "lo": "53/4", - "hi": "27/2", - "u": 288, - "sq": "10676128204480959199819226010296252426779223329457874304191669663600046856606147649109671088362314100932913796632191040163067635708059696056598873143807850785206382784251323220266394481/129447314888176912062408466308736047480771643192195675820873012075936566414879644810728377693416130640959351951903169103521518501377105712890625000000000000000000000000000000000000000000", - "sign_lo": "-3747469/64", - "sign_hi": "866052" - } - ], - "total": "26729/27000" - }, - { - "m": 46, - "e": "145/552", - "components": [ - { - "index": 0, - "k": "63", - "lo": "63/4", - "hi": "16", - "u": 284, - "sq": "192762188060479913871564512376667727576072308017172644/2390480392089430846641333875165779317968999768047515625", - "sign_lo": "5973687227673/512", - "sign_hi": "-27745483632" - }, - { - "index": 1, - "k": "67", - "lo": "67/4", - "hi": "17", - "u": 153, - "sq": "5327678452603282871870861124238933765061819291966344105457333700475097719702532525752275753431008569906394641066375824880837369984703198449040323364426300087914480586911451341567533358128424083380540448709552498367610327532932047859997864613844503733101301602754395486831073479407399076972364168545322219643575108241/228178525629763606469562765865788017250903919157735699185913185688572096192692165732923257782146170880000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-807886348974849/1024", - "sign_hi": "660005312440" - }, - { - "index": 2, - "k": "54", - "lo": "27/2", - "hi": "55/4", - "u": 292, - "sq": "33881370441598725707726788782264012059500289582282986196537446842001526215277840208842806769481269820896524355405420203271141078917687459390290079785816771840048185409864652487472598516577280696288471093394432178515360793343423383665429203179836326627992093563079833984375/397691630697079175146122065833280202888493456302541040358019382760028726905311159159707864936500494764999512905589529334787629405695604839933141073492273569290548231753267824845755738776707475165600549199245083606790808423193868674951947673903957368385261897441980939501568", - "sign_lo": "-621513/2", - "sign_hi": "41877555/64" - } - ], - "total": "34213/34500" - }, - { - "m": 47, - "e": "37/141", - "components": [ - { - "index": 0, - "k": "64", - "lo": "16", - "hi": "65/4", - "u": 283, - "sq": "1208643499290733093373353210580348238504367095730126650624400526702724000000/15093543042703080644459120772267374392847971257013587713069095815803932902529", - "sign_lo": "37598089052", - "sign_hi": "-5774107965855/2048" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 138, - "sq": "4743487926628950605021700798348055777725434117788395367110257324449922931522924698765788277470768949886858283100009935198088681185544469145242536817619393486412484281905121557921399401055230832361785418909548068533076643600913436667228806906316792522084474082298227813998041083895965904609604739759193101411081449086356713103057969314729/249368232372990197774835590554404196320598264335835382752222842588054918487050882992731111435282677760000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-2152820201154", - "sign_hi": "-2152820201154" - }, - { - "index": 2, - "k": "55", - "lo": "55/4", - "hi": "14", - "u": 297, - "sq": "31116301469945849052731028268715753749870670257500600656322662557441449100683229642234163136297397888359073022375558543917527719168099429796263277402542945317416271622266596048499828842149600273291143332384137322606559278957145882624/354105422236656039353014321644743222515671112532079776483147440832607908900159245373108597297418469054895749840532472420186686284485156336425416728432935798972859828394858433190785119363362137539008589470768129103817045688629150390625", - "sign_lo": "-37692545/64", - "sign_hi": "417696" - } - ], - "total": "69119/70500" - }, - { - "m": 48, - "e": "151/576", - "components": [ - { - "index": 0, - "k": "66", - "lo": "33/2", - "hi": "67/4", - "u": 283, - "sq": "697044244289816667721268939263374854891502326028435345270374400/8738188288910343515497728685879910974215425843463908527875901489", - "sign_lo": "208528479513/8", - "sign_hi": "-22181092818483/1024" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 136, - "sq": "29252522156813354410293113011452809090062784173526434663506425665625419703985583355696257931261351028577665357660528979798952484940935889586874948161296111065307771260698416287489166245011983444234105191115080717148340015554700433225489756540088643309989416363380741521063/1604370290913852836269264994304000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-5124511031136", - "sign_hi": "-5124511031136" - }, - { - "index": 2, - "k": "56", - "lo": "14", - "hi": "57/4", - "u": 301, - "sq": "22256243155145652331992790594759864710247007668799102430373182592878435331118153456731014599495844148125346498557670412072879224291525076566767415742220400979278778840695126600570511546234067870580859384936003694564778842050943292843358987795796119353480792048656911/245908131138662974861075133458178140361860248011559898170364468966498505156465528267309129801258638794568084916041612574737451407807798579455305520307858983825203693595537643656853817701341535303692969577892352034931250000000000000000000000000000000000000000000000000", - "sign_lo": "-894424", - "sign_hi": "9909783/64" - } - ], - "total": "14143/14400" - }, - { - "m": 49, - "e": "11/42", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 261, - "sq": "226731525329919064081858560000000000000000000000000000/3350697821824282405808785553334973299280614906081607849", - "sign_lo": "10457952385", - "sign_hi": "10457952385" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 131, - "sq": "242175254484148440737987704325505081944797202632009559072685614813309516487770137871777414478888538563724826578733454007901621754257210236436809601505736222396252821552285759491630368985612310535528209963432479373990120430239420430947729247134642177160007178637880527759336891926089118314169126693079967580805258990424208131542712880577806921/14175004682950160276315848742688955600056433618261241600616530904540462300837426197462193135419995979776000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-8257413991640", - "sign_hi": "-8257413991640" - }, - { - "index": 2, - "k": "58", - "lo": "29/2", - "hi": "59/4", - "u": 306, - "sq": "14632288527747070725599662686499313086768730951685384040246870835171740213968569708637390769893545261425939157238397267938586943332911529185914418624317583006729206381939864225211178237679980197504481702776659940208696525223463398746058951657555985236398256445577526941399214241671213185146162728023903516978545230728486969489/157220779219787866427813155940336572657100695970259158984404261501249275350650954641661364860008564859831507848090018871222807633741408932218525290141243209638092292207050988145291272503447826580663187288138922397031447094639142401929229025769023392607733641076839215973596354538202285766601562500000000000000000000000000000000", - "sign_lo": "-271095/2", - "sign_hi": "65638519/64" - } - ], - "total": "10079/10500" - }, - { - "m": 50, - "e": "157/600", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 260, - "sq": "15829886789258636370640896000000000000000000/235636318223011240671712443943271264232153649", - "sign_lo": "97192809600", - "sign_hi": "97192809600" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 126, - "sq": "118569841129892748392490697577324327674803862739746714538562887785977725219970474720035634254648152912401843653468745537657756246440721280994026101015494439987819693465370307103274628335905523339528661120276619921939357023196558200920929156269665031534979256883302362384480399047/7555786372591432341913600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-11553875896800", - "sign_hi": "-11553875896800" - }, - { - "index": 2, - "k": "59", - "lo": "59/4", - "hi": "15", - "u": 310, - "sq": "615721409782928072474580502723987421268310866040440101829489368809130925890536382806658542460080064017459711475779602312781716467272563925944268703460693359375/6430209604048836086311103358776314070481685506201260548015229089106732521990253765931808879481901322397211457818529284706430809315266123561405594675258291388416", - "sign_lo": "-29108037/64", - "sign_hi": "753300" - } - ], - "total": "2873/3000" - }, - { - "m": 51, - "e": "40/153", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 258, - "sq": "183430610944000000000000000000000000/2764024563172579597072581051857294689", - "sign_lo": "183822045789", - "sign_hi": "183822045789" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 120, - "sq": "28049467964031454430399990775851745736812531074942041403497874202513850976209934065055139694234022902991737277224911637150958211236408741966821007367594031698109241801707842593032527654636498348909561447419060385921195337648032421816426424627180891833968106707287835036266952342081/1980704062856608439838598758400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-15016243560750", - "sign_hi": "-15016243560750" - }, - { - "index": 2, - "k": "60", - "lo": "15", - "hi": "61/4", - "u": 314, - "sq": "309828951632981422674192541706351291995572740823514133955143105471248521547797996937179811393122512866308319060051314049376720903805806901985195841486067044752844818918583060900914394846901905737882064598468268938808684298850442920871903585827362039073331728166366177377260320710912699521810411623940130896261446200496736342100659105227508635525438729/3149052958892764994778884837673609990030799493598678424230384430164701995965949291822289417379663636028757550701376375998671618763105773052341554950520445970448774254377947023429729116201771055495885194812115975452518679393617958794986215090947577328597445360978571646268238951100134377752599849729000000000000000000000000000000000000000000000000000000", - "sign_lo": "-804330", - "sign_hi": "28920851/64" - } - ], - "total": "36469/38250" - }, - { - "m": 52, - "e": "163/624", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 256, - "sq": "2124836554605108205587781386240000000000000000000000/32541433007931753756140467933867899649129216985421121", - "sign_lo": "270345660952", - "sign_hi": "270345660952" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 113, - "sq": "258051760218371391247841103729595048234377253883014919132669002507557819014214663909411181200384055089646474914601358075931455701433269726505940094353312685327678970784888098846152308397191322179656055617309697362904558656649117647605533234614298365508584293014251648305038451882838695406630650909128386275423750788735592034668491405460252402938531/20514009047371655285369941669651631583095957006727880129128971843502408876825869339852800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-18646863797624", - "sign_hi": "-18646863797624" - }, - { - "index": 2, - "k": "61", - "lo": "61/4", - "hi": "31/2", - "u": 318, - "sq": "518249494524407614145175981883162270580340631625143512432436856999584795558683749373188949299647225564536542018228855586278834266943590283335061051860554047420456198150536920215591849622803615062780818987920819315679032870245012077904645533186965362274457105967216784582194273723648887084794709880255216686403617678688734097979/5132852603594514499454144366095098346149327843341827364752063297465784946015682775213112912552160110401919470856086005395800861017351708173194439198595643329375951964239284467983683397414829177109555570511904724425919077567879523767504106776796217743705537167397387997500000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-75872001/64", - "sign_hi": "119977" - } - ], - "total": "73961/78000" - }, - { - "m": 53, - "e": "83/318", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 254, - "sq": "3476253760848225116499091193856000000000000000000000000/54282369687160592158110376013801193391599202888438407721", - "sign_lo": "356763655089", - "sign_hi": "356763655089" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 105, - "sq": "1002772932988752026908568576000650489256528145928765103648052072090319313795425064479649044771300281369460841243289887745843655819118111746306239956425906899368621852006892627758545625378405430121672605907476719752892513965958091691223347751620156493271234533077719072889510603827365462854539165861696451683445316247533069534533943464033569100268051719197726014100583197176394871068969/91025864375173611224680792127325439482441009587532512931023483058727922787807931133567823519342342972982933226719805440000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-22448083421556", - "sign_hi": "-22448083421556" - }, - { - "index": 2, - "k": "63", - "lo": "63/4", - "hi": "16", - "u": 322, - "sq": "8869029747634942785133248777345236641452028906084010543588219363109988677701019158069552748485628681176150701294467549923483763471159132150606086936229468444431805313303776542371541309853834705348980676664556019173768797617603009994171444191465103797333154685060644864/85693902311671922895943008891983173815904214019082273360495860907767538525488084499496003506564947630668116523342564724330158909092300974985332605887971723345805781209219229693155816485491806638785417115322401740303131997076994431916663330639494233764708042144775390625", - "sign_lo": "-15606513/64", - "sign_hi": "1190908" - } - ], - "total": "149779/159000" - }, - { - "m": 54, - "e": "169/648", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 251, - "sq": "3961940278027569321738240000000000000000000000000000/63243281254700073070644585624999629577531295004196481", - "sign_lo": "443076028200", - "sign_hi": "443076028200" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 98, - "sq": "1469717661167112088172025741638458809703138667454691479150808881829496229587289669061475438587938371074104304715608690248708322884433050152313840105129791735473112038474869026442299863307396973150808140770855454238987085009359965891610407771916737092429148457267510196675254672724459647338519195992630688521268390224183647295130315148172302348259263/154311245596222747736413854341664624979591195838870048838987426168609746828390301696000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-26422249246680", - "sign_hi": "-26422249246680" - }, - { - "index": 2, - "k": "64", - "lo": "16", - "hi": "65/4", - "u": 326, - "sq": "1540713499816691451450168760794815958548803324287307248866666376820739955947143408631346535613597057455246411205338911726882253965602116613903041802096935423717831951594561390237150711480272860699294978623944875353088922864228621922387934122931587625711784873469538280999634500917548779610406227727626385467374348081648349761962890625/14520790003925058683367279910693817968566063270753146295534456297865184605021529204697029481442530985645359216486647626304859856567949289045037866716525085939933462662690401958816783217115272033742450813246407314824384487276142321147941493765629874923284469296965620965990733106837958807678263974227195449346588464038454621575470645248", - "sign_lo": "-641044", - "sign_hi": "54248615/64" - } - ], - "total": "379/405" - }, - { - "m": 55, - "e": "43/165", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 248, - "sq": "14448031664094307067203525017600000000000000000000/236253291542505615720637955928526274661604422809641", - "sign_lo": "529282780285", - "sign_hi": "529282780285" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 91, - "sq": "277064168731605384328225627427251810587309067978737075076737777574424556744117840951282836334323691249058208430235211079120104695779490858287781647597507890065686307426422252100826329480077492679199124976403089143904449180768056270296594859832605494481785576504364776728765992105743594425237950781530688777363756788838261097849462910818264667086449002304303715689/34042746510276992396790454843552497556762937527859049242031008205499123537852959293440000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-30571708087130", - "sign_hi": "-30571708087130" - }, - { - "index": 2, - "k": "65", - "lo": "65/4", - "hi": "33/2", - "u": 330, - "sq": "768674250846312209883312565088717611221331600247515798191973781037932729868931974393983968356660460534687332434868467063011848464709335013614306297746577871360507350993399397467781635917242496121918322601363284578762977683651123771799155672012435721/7074784114767971108871824476511743376736146390290222958783650635066801403470453840372575214326394260419941039284643057207454431735603172642448919190015697093739065595255893520177201045395738516601562500000000000000000000000000000000000000000000000000", - "sign_lo": "-68676725/64", - "sign_hi": "470745" - } - ], - "total": "30677/33000" - }, - { - "m": 61, - "e": "95/366", - "components": [ - { - "index": 0, - "k": "B", - "lo": "17", - "hi": "17", - "u": 228, - "sq": "2803170496946934733907313263616000000000000000000000000/54319097954293509509886404129047312387176990686778996121", - "sign_lo": "1044305251249", - "sign_hi": "1044305251249" - }, - { - "index": 1, - "k": "B", - "lo": "17", - "hi": "17", - "u": 52, - "sq": "1779700891521289675727033856487613154386274283986867643728801812001935525275324079199220653195005722340277021836779133849792760073355329971637330364710096833818586865253990804885079115141616619333624748305555064325051831907050704551871074514651298384048172133684733156670130547826361489389654480321251422458563715115682391469713371085280576865519924218178669631225440203453724660983485457779188682728472234649763975498424755181163635543007749249/684147296318722016513825845747416635822083767747123024248784467192098299784463565636959965400081783934874474739453022928803838647708675997696000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-59281036043180", - "sign_hi": "-59281036043180" - }, - { - "index": 2, - "k": "B", - "lo": "17", - "hi": "17", - "u": 324, - "sq": "516373418510123557656385511038316889842519892780084733381203585843123882806691577500340845723832336663718250396279737333962557390923867043484579154257798184447308782596596452264388886254097134344006127760774582823842705806729283561082418840700609119078947674982614312577566631333114619840397876605625979459585621102679783609/4935562433715216654270098662253626916583399624186903184949292221537223023001600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "sign_lo": "-9604580", - "sign_hi": "-9604580" - } - ], - "total": "19754/22875" - } -] diff --git a/docs/design.md b/docs/design.md index 0a29a07..90b2fdd 100644 --- a/docs/design.md +++ b/docs/design.md @@ -1,122 +1,135 @@ # Proof design -The active endgame implements the rational-envelope/critical-point method of -Senjian An on top of the existing polynomial and analytic reduction.[1][2] -It is a replacement for the old scalar certificate route, not an extra premise -added to the final statements. +The polynomial, analytic, low-degree and boundary arguments retain the original +meaning.[1] The scalar reduction uses Senjian An's rational envelope and +two-chord estimate.[2] Its upper bound now uses full-degree-ray estimates: +there are no finite degree certificates or later tail cutoff. -## Reduction contract +## Exact reduction contract -For interior degree `n ≥ 6`, put `m = M n = n - 1`. The theorem -`cubicScalar_constraints_of_polar_origin` derives all four facts from the -original geometric hypotheses: +For interior degree `n >= 6`, put `m = M n = n - 1`. +`cubicScalar_constraints_of_polar_origin` derives, from the original geometric +hypotheses, `0 < alpha`, `2*alpha <= M n`, `alpha <= 17`, and +`1 <= scalarObstruction (M n) alpha (cubicPolarEnvelope alpha)`. +These are conclusions of the reduction, not additional conjecture hypotheses. +The original weak polar integral premise remains `1 <= I`. -1. `0 < α`; -2. `2 * α ≤ M n`; -3. `α ≤ 17`; -4. `1 ≤ scalarObstruction (M n) α (cubicPolarEnvelope α)`. +`distillScalar_lt_one_real` proves `<1` for every real `m >= 5`, +`0 < alpha <= 17`, `2*alpha <= m`. It splits at alpha 2, not at any degree. +The original `distillScalar_lt_one` natural `n >= 6` signature is unchanged. +`polar_origin_incompatible` combines these bounds. Degrees 2 through 5 still +use the existing elementary integral proof; boundary equality classification +is separate. Neither final headline theorem is weakened or strengthened. +No minimality claim about the scalar starting value 5 is made. -The range and the scalar lower bound are conclusions, not inputs smuggled into -Sendov's conjecture. The original weak polar integral bound remains weak: -its left side is `1 ≤ I`, not an assumed stronger inequality. +## Small alpha -`distillScalar_lt_one` proves a strict upper bound on exactly this domain. -`polar_origin_incompatible` combines the lower and upper bounds. The interior -proof covers degrees two through five with the already-proved elementary -integral argument; the unit-circle case and its equality classification stay -in the separate boundary proof. +For `0 < alpha <= 7/5`, `DistillationTotalBound` uses the full chord: -## Scalar upper bound +```text +C(m,alpha) = E_budget(m) + + (8/27) (alpha+3)^3 (m-2alpha)^2 / (m(m+3)(m+5)). +``` + +Degree factors cancel before estimation. A degree-five alpha identity with six +polynomial coefficients in `m-5` proves `C<1` on the entire unbounded strip; +the last two coefficients use explicit nonnegative-square decompositions. +There is no degree subdivision. The method does not extend automatically: +`C(25/2,17/12)=1+141383/711868500` and +`C(13,10/7)=1+426061/212373252`. These refute an enlarged chord majorant, +not the original scalar inequality. + +## Faithful elementary term and middle alpha -The two-chord integral theorem gives +For positive alpha, with `u=alpha/(alpha+3)` and `eta=u-u^3/30`, ```text -raw cubic scalar obstruction ≤ E_budget(m) + T0(m,α) + T1(m,α) + T2(m,α). +L = u^2/(180(1-eta)) + u(30+u-u^2)(1+1/m)/360 +H = E_budget - L + kappa*J. ``` -For `5 ≤ m ≤ 54`, fixed rational budgets and critical brackets are checked for -every integer parameter; row 55 supplies a bounded real interval and row 61 the tail -base. The complete critical expressions are tied to the -actual derivatives of `T0`, `T1`, and `T2`. Their polynomial signs are certified -on entire outer intervals, while the middle interval uses monotone factors at -opposite endpoints. This establishes the bound without trusting a sampled -maximum or requiring a separate root-isolation oracle. - -The coefficient-list frontend constructs the existing Bernstein addition tree. -Scale positivity, interval membership, both endpoint supports and the complete -polynomial equality remain explicit Lean obligations. The Python coefficient -calculation is not in the trusted base. - -For all real `m ≥ 61`, proved parameter antitonicity reduces the four-component -bound to the existing finite `m=61` certificate. `DistillationTailBound` discharges -that base with its already-certified `<199/200` budget; no base or monotonicity -premise is left to the final caller. The rational component uses the actual -envelope-dependent denominator, with a split at `α=10`, rather than the old -independent worst-case bounds that required 81. The exponential components use -`η ≤ (21/22)^4`, hence `log η / 2 ≤ 2 log(21/22) ≤ -1/11`. -This dominates `1/60 + 2/27`, the kappa slope bound at 61, without assuming -a logarithmic estimate or derivative sign. Zero bases are handled separately. - -For `55 ≤ m ≤ 61`, the rational component is already antitone. The parameterized -lemma `distillKappa_rpow_interval` bounds finite growth instead of asserting -antitonicity: if the logarithmic slope is at most `ε`, then -`f(m) (1 - ε (U-K)) ≤ f(K)` on `[K,U]`, provided the weight is positive. -It proves this by differentiating `f(m) (1 - ε (m-K))`; no exponential -comparison or derivative fact is left to the final caller. The node cap -`node(55,α) ≤ (979/1000)^10` gives `ε1=331/37800`, while the envelope cap gives -`ε2=95/4158`. Together with the original row-55 budgets `248,91,330` divided by -1000, the exact total is `58135011269/58896123000 < 199/200`. -The theorem covers real degrees and the entire closed alpha interval, without -a finite case split or new Bernstein certificates. The original correlation -`α ≤ min(m/2,17)` remains in the finite interface; for this interval it follows -from `m ≥ 55` and `α ≤ 17`. - -The natural-number split `m < 61` versus `61 ≤ m` has no gap. The finite -aggregate proves exactly 5 through 60, and both it and the tail import the final -group `Rows61_61`; row 61 is emitted only once. The generator and validator share -an explicit retained range `5..55,61`, paired with both real theorems. They reject -missing55, missing61, reintroduced56, extra62, duplicated/reordered rows and mismatched components rather -than inferring a smaller cutoff from truncated data. Rows 62 through 81 and all -old row-81-only/two-thirds interfaces have been retired. - -## Endpoints and definitions - -The regularized components are continuous at `α=0` and their closed-interval -certificates include that endpoint. The raw scalar definition is **not** silently -replaced by a continuous extension there. The geometric reduction supplies -`α>0` where the raw scalar comparison is used. - -The old specialized `c`, `Q`, `R` definitions and their moment/packed/batch -certificates are absent from the active source. `M`, `A`, `QQ`, the actual -coordinate identity `mul_eq_c`, the linear and cubic integral lemmas and the -global weak hyperbolic estimate remain because real consumers still need them. -A name containing `c` or a file containing `Tail` is not, by itself, a reason -to delete useful mathematics. - -## Verification boundary - -Acceptance distinguishes: - -- exact source generation and input coverage; -- Lean elaboration with the pinned project options; -- independent kernel replay over the pinned imported environment; -- original final-theorem type preservation; -- actual value and type/value dependency checks for both final theorems. - -The earlier-tail consumer test checks actual proof-value edges from both final -theorems through the geometric reduction and the tail to row 61. Its recursive -project-value audit requires rows 5 through 54 with their strict budgets and all -three row-55 components in the finite aggregate. Each final theorem additionally -consumes row 61 and its strict budget. The row-55 aggregate budget theorem is not -needed: the interval uses the three individual budgets with different growth weights. -Retired rows 56 through 60, 62 through 81 and tail interfaces must be absent from -both the imported environment and the actual value closure. Dependency checks -do not equate a module import with proof consumption. - -Readability is the first selection criterion, measured compilation cost second, -and line count third. Source counts include the shared certificate frontend; -generator, template and input-table costs are reported separately rather than -hidden by moving text out of Lean files. +The exact loss bridge is actually consumed by +`distillScalar_le_elementary_components`. The unused total derivative and the +unused strict loss-positivity research lemma are retired, not the bridge. +`distillTotal`, `distillElementaryLoss`, the original raw scalar, and all +retained factor definitions keep their meanings. + +For `7/5 <= alpha <= 2`, `DistillationMiddleEstimates` and +`DistillationMiddleAlpha` split alpha at `17/10`. The rational T0 estimate +retains `(m+3)(m+5)` and uses two positive sextics in `m-5` on the whole ray. +Mixed-alpha exponential estimates bound T1 and T2 on the same ray. +The component budgets are `221/660`, `13/50`, `7/30`, `1/6`. +All constants are discharged internally, with no assumed maximizer or bound. + +## Large alpha + +For `2 <= alpha <= 17`, `DistillationCorrelatedPeak` shifts by `m-2*alpha`, +not `m-34`, and bounds the full legal degree ray analytically. +`DistillationPeakRational` converts the exponential estimates to rational ones. +`DistillationPeakAlgebra`, `PeakFirst`, `PeakRest`, and `PeakClosure` close the +alpha inequality. The only additional split is alpha `5/2`, where +`max 5 (2*alpha)` changes formula. + +The first peak uses an affine budget `(431-3*alpha)/2500` and a fourth-order +Taylor denominator; the second retains the sixth-order denominator. Three +full identities of degrees 53, 47, 47 contain respectively 54, 48, 48 ordered +integer coefficients, plus 71 coefficients in the smaller homogeneous factors. +The positive scales are `15^53`, `1`, and `29^47`. The complete identities, +factor ordering and scale obligations are explicit. They are not sampled +equalities or finite degree data. + +The four large-alpha closure modules occupy 885 lines, including all 150 large +and 71 small factor coefficients, before counting the upstream same-alpha, +rational, middle, small-alpha and common-certificate helpers. The existing +`BernsteinList`, `BernsteinCert`, and `BernsteinRing` remain necessary. +No new generator is needed: the Lean identities are self-contained. +The stricter historical `<199/200` convenience is not imposed: the new +rational peak at alpha 17 lies between `199/200` and 1. + +## Retirement boundary and endpoints + +All degree rows, finite aggregates, critical-polynomial derivative machinery, +old degree-tail/interval modules, and their table/generator/bundler are retired. +The old compound scalar wrapper discarded elementary loss and has no remaining +consumer; it is replaced by the faithful elementary-component bridge. +`DistillationRegularity` preserves common compact forms, positivity and +continuity from the former critical module without retaining its row machinery. +The endpoint-only alpha-17 research theorem is superseded by the uniform strip. + +The raw scalar at alpha zero is exactly `1/(2*m)`, not the continuous extension. +The positive-alpha theorem stays positive. `BoundaryConsumer` separately covers +raw zero, regularized T2 zero for every real `m>=5`, and legal `m=2*alpha`. +`NoFiniteRows` covers generic natural degrees, noninteger degrees, alpha +`7/5`, `2`, `17`, and the endpoint ray. Existing low-degree statements remain +unchanged. The raw scalar itself need not be antitone in degree: +`LocalTotalBound` retains the exact `H(5,1)= 5`, `0 < alpha <= 17`, +`2*alpha <= m`; there is no numerical degree base or finite tail cutoff. +`NoFiniteRows` checks complete recursive proof-value closures, requiring actual +small/middle/large-alpha consumption in all four roots. The Python suite +contains real Lean negative coefficient/scale/interval controls and the complete +independent auditor fixture matrix. Run compilers serially. +See [`scripts/GENERATORS.md`](../scripts/GENERATORS.md) for the retained global +`sinh` generator and its SymPy dependency. If certificate data or generated proofs change, verify the complete affected import cone, its kernel checks and final consumers. Do not count previously @@ -72,7 +76,9 @@ compiled objects from a different source projection as a successful new build. - A Lean success means that particular source/module elaborated. - A kernel success means the named module replayed over its imports. - Full completion also requires both unchanged final contracts and their real - proof dependencies, including every finite case and the infinite tail. + proof dependencies, including all three full-degree-ray alpha estimates. -The active branch does not include the retired packed/moment/`R` certificate -system as a compatibility fallback. +Lake enumerates every `Sendov` source module explicitly through its root glob, +including useful common mathematics outside the final theorem import cone. +Retired degree-row objects and sidecars must not be available as a fallback; +never delete dependency-package caches when retiring project artifacts. diff --git a/formalization.yaml b/formalization.yaml index 82a5256..60c5b06 100644 --- a/formalization.yaml +++ b/formalization.yaml @@ -4,10 +4,10 @@ project: name: Sendov's conjecture and the Phelps-Rodriguez conjecture description: 'Local Lean development of both complete conjectures, retaining the original polynomial, analytic and boundary arguments and replacing the old scalar endgame by a proved cubic polar envelope - and exact critical-point certificates. Degrees 2 through 5 use the elementary analytic proof. - For n >= 6, m = n - 1: the finite range 5 <= m <= 63 is fully certified, and the real-parameter - tail for m >= 64 uses the actual m=64 base. Exactly 60 unchanged records, m=5 through 64, - remain. Final statements are unchanged; no numerical bound is assumed.' + and full-degree-ray alpha estimates. Degrees 2 through 5 use the unchanged elementary analytic proof. + For every real m >= 5, 0 < alpha <= 17, 2*alpha <= m, the original scalar is strictly below one. + The natural n >= 6 wrapper and final statements are unchanged. No finite degree certificates, + numerical degree bases or old interval/tail cutoff remain; no bound is assumed.' authors: - Terence Tao license: Apache-2.0 @@ -52,12 +52,12 @@ status: literature_dependencies: [] fidelity: divergences: The original final theorem types and polynomial semantics are unchanged. The local - variant uses Senjian An's stronger rational polar envelope and 7/7/4-degree critical-polynomial - bounds in place of the old R/packed/moment route. All analytic bridges, derivative signs, interval - endpoints, finite budgets and the infinite tail are proved in Lean. The raw scalar at alpha zero + variant uses Senjian An's stronger rational polar envelope and two-chord estimate, followed by + small, middle and large alpha bounds on full real-degree rays. Fixed alpha identities of degrees + 53, 47 and 47 have complete kernel-checked coefficients and factors. The raw scalar at alpha zero is not silently redefined by regularization. The degree-five case now uses the existing elementary - low-degree theorem. Obsolete intermediate interfaces are retired, not maintained as a second proof - system. + low-degree theorem, unchanged in this stage. Obsolete intermediate interfaces are retired, not + maintained as a second proof system. No claim that m=5 is globally minimal is made. sources: - title: A digestion of the proof of Sendov's conjecture authors: @@ -140,7 +140,7 @@ sources: id: https://zbmath.org/7681950 relationship: background note: The earlier high-degree result. Its use of analytic continuation is what the digested argument - replaces by an explicit finite check, which is why this development can be fully formalized. + replaces by explicit scalar estimates. This variant closes the scalar domain without degree rows. - title: Sendov conjecture proof (ProofAtlas manuscript) authors: - Lech Mazur @@ -158,9 +158,9 @@ sources: type: other id: https://github.com/SJanPerth/Sendov-Proof-Distillation/tree/e8ae601491ec171ab4f7f8456113dd6a047aa85d relationship: adapts - note: Cubic rational envelope, two-chord estimate, complete low-degree critical expressions, original - finite budgets and real-parameter tail. The source paper is CC BY 4.0. Python verification is - not a trusted premise; the adapted method is proved in Lean. + note: Source of the retained cubic rational envelope and two-chord estimate. The source paper is + CC BY 4.0. Its finite degree certificates and degree tail are superseded by the full-ray alpha + estimates; no Python verification is a trusted premise. related_formalizations: - id: https://www.proofatlas.ai/formalizations/sendov-conjecture/ relationship: builds-on @@ -182,15 +182,15 @@ automation: adaptation. This is not an assertion of new upstream-maintainer or human peer review. - method: other framework: Python exact arithmetic - role: scripts/gen_distillation.py generates every selected finite case and the aggregate into - a fresh output root. scripts/gen_sinh.py reproduces the retained global hyperbolic proof source. - Generator output is rechecked by Lean; compiler and kernel acceptance are separate. + role: scripts/gen_sinh.py reproduces the retained global hyperbolic proof source. The alpha + identities are self-contained Lean source and require no generator. Python tests exercise + full-identity mutations and audit failures; compiler and kernel acceptance are separate. review: status: self-assessed - notes: The K64 pruning candidate has local exact-source compilation, kernel replay, original-contract - and actual proof-value dependency probes. Parent independent review and final whole-library gates - remain pending. These are not claims of independent human mathematical review or endorsement by - the upstream authors. + notes: The no-degree-row full-real-m5 candidate is subject to exact-source compilation, kernel replay, + original compiled-contract comparison and full unpruned proof-value audits. Parent review of the + final exact tree, promotion and paired milestone measurements remain separate pending gates. + This is not a claim of human peer review or upstream-author endorsement. known_gaps: [] limitations: - The two deliberate placeholders in Challenge.lean are specifications, not imported proof premises. @@ -218,13 +218,8 @@ alignment: module: Sendov.Reduction.CubicScalar status: proved note: Derives all scalar-domain conditions and the lower bound from the original geometric inputs. - - source: Complete finite critical-point certificate range - lean: Sendov.distillFinite_scalar - module: Sendov.Common.DistillationFinite + - source: Complete original scalar domain on real degree rays + lean: Sendov.distillScalar_lt_one_real + module: Sendov.Common.DistillationBounds status: proved - note: All integer m from 5 through 63; entire alpha domain, not samples. - - source: Real-parameter infinite tail - lean: Sendov.distillScalar_lt_199_200 - module: Sendov.LargeDegree.DistillationTailBound - status: proved - note: All real m >= 64 and positive alpha <= 17; the actual m=64 base is discharged. + note: Every real m >= 5, 0 < alpha <= 17, 2*alpha <= m; no degree base or finite row. diff --git a/lakefile.toml b/lakefile.toml index b3fee13..c824046 100644 --- a/lakefile.toml +++ b/lakefile.toml @@ -16,6 +16,7 @@ scope = "leanprover-community" [[lean_lib]] name = "Sendov" +globs = ["Sendov", "Sendov.+"] [[lean_lib]] name = "Challenge" diff --git a/scripts/GENERATORS.md b/scripts/GENERATORS.md index 8cb7151..3a198a1 100644 --- a/scripts/GENERATORS.md +++ b/scripts/GENERATORS.md @@ -1,76 +1,47 @@ -# Active proof generators +# Retained generation support -Use Python 3.10+; only `gen_sinh.py` needs SymPy (tested with 1.13.1). -`gen_distillation.py`, its exact-data validator and bundler use only the standard -library. Run these commands from the repository root: +The alpha-53/47/47 certificates are self-contained Lean identities in +`DistillationPeakFirst.lean` and `DistillationPeakRest.lean`. +Their 150 ordered coefficients, 71 smaller factor coefficients, positive +scales and complete symbolic identities are checked by the kernel. They +do not need a separate generator or degree table. + +The only retained generator is the useful global `sinh` proof generator. +Use Python 3.10+ with SymPy (tested with 1.13.1): ```sh -python3 -m pip install 'sympy==1.13.1' # if not already installed python3 -B scripts/gen_sinh.py --output /tmp/sendov-Sinh.lean -python3 -B scripts/gen_distillation.py --output /tmp/sendov-distillation-new -python3 -B -m unittest discover -s tests -v +diff -u Sendov/Common/Sinh.lean /tmp/sendov-Sinh.lean +python3 -B -m unittest discover -s tests ``` -The finite output directory must be new or empty. The generator emits all -`m = 5,...,55,61`, components `0,1,2`, with the unchanged selected table records. -Rows are grouped in contiguous batches of at most eight, ending in `Rows53_55` -and `Rows61_61`; a group never spans a gap in retained degrees. The finite -aggregate covers 5–60 using rows 5–54 and the real interval theorem 55–61, -whose base is the original row 55. The real tail starts at 61 and uses the original row-61 -`<199/200` budget from that same group. The output contains exactly these -eight row modules and `Sendov/Common/DistillationFinite.lean`. No second per-row -source tree is published. `bundle_rows.py` is the source-packaging helper, not a -certificate checker or an alternative proof route. - -`--output` is required for distillation; there is no subset/mutation CLI or -workspace restriction. Paths can be absolute or relative to the caller's cwd. -`--table /path/to/table.json` explicitly overrides the default project-local -`data/paper_certificate_table.json`; the same exact schema, ordered coverage, -bracket, sign, squared-envelope and budget checks apply. Editing that input -changes a proposed certificate, not the proof trust base. Keep the shipped table -unchanged to reproduce the selected source. `distillation_data.py` is the explicit -range authority, paired with `distillComponents_lt_199_200`; truncated inputs -cannot select a different cutoff. In particular, missing55, missing61, reintroduced56, extra62, duplicate -or reordered rows, and duplicate/reordered/mismatched components are rejected. - -All data validation and exact row rendering finish before staging. The complete -grouped snapshot is then staged beside the target and committed by one directory -rename. Nonempty targets, regular files and symlinks are rejected; handled -render/write/rename failures leave prior target contents intact and clean private -staging. This is an atomic publication guarantee on a local filesystem with a -trusted parent directory, **not** a power-loss durability guarantee or protection -against malicious concurrent same-user namespace changes. Interrupted runs may -leave private `.distillation-*` staging; no partially published Lean tree is used. - -Sinh's optional default is `Sendov/Common/Sinh.lean` relative to the script's -repository, not the caller's cwd. Its existing atomic single-file writer replaces -that file only after complete rendering. Imports perform no generation; `-B` -suppresses Python's own bytecode cache writes. Explicit outputs are recommended. +Without `--output`, Sinh writes `Sendov/Common/Sinh.lean` relative to its own +repository, not the caller's cwd. Its atomic single-file writer replaces the +target only after complete rendering, preserving existing content on handled +write/rename errors. Imports perform no generation; `-B` suppresses bytecode. +This is not a power-loss durability or hostile-concurrency guarantee. -**Python生成≠Lean验收** — exact Python checks and byte-identical regeneration are -not Lean elaboration or kernel replay. After integrating the generated modules -into the selected proof and building it with the pinned project toolchain, run: +The degree-row table, validator, renderer, bundler, and tests exclusively +exercising those retired interfaces are removed. The remaining suite retains +Sinh relocation/digest/publication guarantees, the independent axiom auditor, +and actual full-alpha-identity mutation tests. Python generation is not Lean +acceptance: ```sh -lake env lean scripts/axioms.lean +lake build +lake env lean tests/NoFiniteRows.lean sh scripts/audit.sh ``` -The two public conjectures and the finite/tail seams are queried, not retired -route names. The shell audit fails if the Lean query itself fails. Full Lean -build/kernel replay and the two headline type contracts remain separate gates. +Original headline types and independent exact-module kernel replay are +separate obligations, as described in `docs/getting-started.md`. -## Attribution and licenses +## Attribution -- Sinh, its analytic tail and the retained proof templates derive from Terence - Tao's Sendov development (Apache-2.0); original notices are preserved. -- Mathematical table/route: Senjian An, *Proof Distillation for Sendov's - Conjecture*, [fixed revision e8ae601491ec171ab4f7f8456113dd6a047aa85d](https://github.com/SJanPerth/Sendov-Proof-Distillation/tree/e8ae601491ec171ab4f7f8456113dd6a047aa85d). - Retained records are an unchanged ordered subset, not the full donor table; - see `../data/README.md` for CC BY 4.0 attribution. -- The rational envelope checks in `distillation_data.py` adapt that revision's - explicitly MIT-licensed `verification/verify_paper.py`; the original Senjian An - copyright/permission notice is retained in `LICENSE-DISTILLATION-MIT.txt`. - This is licensed adaptation, not copying code from an unlicensed donor. -- New renderer, schema/CLI integration, bundling and test changes are Apache-2.0; - see the project `LICENSE` and the retained `LICENSE-APACHE-2.0.txt` copy. +Sinh, its analytic tail and proof templates derive from Terence Tao's +development under Apache-2.0. The original notices and license copy remain. +The rational-envelope/two-chord mathematics is adapted from Senjian An, +*Proof Distillation for Sendov's Conjecture*, fixed revision +`e8ae601491ec171ab4f7f8456113dd6a047aa85d`, under CC BY 4.0. +The mathematical notice remains in `data/LICENSE-PAPER.txt`; no degree +table or separately MIT-licensed verification code remains in this tree. diff --git a/scripts/LICENSE-DISTILLATION-MIT.txt b/scripts/LICENSE-DISTILLATION-MIT.txt deleted file mode 100644 index 9862d99..0000000 --- a/scripts/LICENSE-DISTILLATION-MIT.txt +++ /dev/null @@ -1,21 +0,0 @@ -MIT License - -Copyright (c) 2026 Senjian An - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. diff --git a/scripts/axioms.lean b/scripts/axioms.lean index 11d7794..ddfaafe 100644 --- a/scripts/axioms.lean +++ b/scripts/axioms.lean @@ -1,12 +1,10 @@ import Lean import Solution -import Sendov.Common.DistillationFinite -import Sendov.LargeDegree.DistillationTailBound /-! Run after building the selected proof with `lake env lean scripts/axioms.lean`. This separate audit checks the two exact public conjecture statements and their -active finite/tail seams, not retired intermediate names. +active full-domain alpha estimates, not retired degree-certificate interfaces. Only `propext`, `Classical.choice` and `Quot.sound` are permitted. In particular, `sorryAx` and `Lean.ofReduceBool` are not permitted. These assertions do not @@ -36,16 +34,19 @@ end SendovAudit #sendov_axioms SendovConjecture.sendov #sendov_axioms SendovConjecture.phelps_rodriguez -#sendov_axioms Sendov.distillFinite_components -#sendov_axioms Sendov.distillFinite_scalar -#sendov_axioms Sendov.distillFinite_61 -#sendov_axioms Sendov.distillFiniteBound_61 -#sendov_axioms Sendov.distillComponents_le_61 -#sendov_axioms Sendov.distillT2_zero -#sendov_axioms Sendov.distillComponents_lt_199_200 -#sendov_axioms Sendov.distillScalar_lt_199_200 +#sendov_axioms Sendov.distillScalar_lt_one_real #sendov_axioms Sendov.distillScalar_lt_one #sendov_axioms Sendov.polar_origin_incompatible -#sendov_axioms Sendov.distillKappa_rpow_interval -#sendov_axioms Sendov.distillT0_antitone_55 -#sendov_axioms Sendov.distillComponents_interval_55_61 +#sendov_axioms Sendov.scalarObstruction_zero +#sendov_axioms Sendov.distillScalar_lt_one_small_alpha +#sendov_axioms Sendov.distillScalar_lt_one_middle_alpha +#sendov_axioms Sendov.distillScalar_lt_one_alpha_le_two +#sendov_axioms Sendov.distillScalar_lt_one_peak_strip +#sendov_axioms Sendov.distillScalar_le_total_sub_loss +#sendov_axioms Sendov.distillChordTotal_lt_one +#sendov_axioms Sendov.distillScalar_le_elementary_components +#sendov_axioms Sendov.distillScalar_le_rationalPeak +#sendov_axioms Sendov.distillRationalPeak_lt_one +#sendov_axioms Sendov.PeakClosure.gap1_identity +#sendov_axioms Sendov.PeakClosure.LowHomogeneous.gapH_identity +#sendov_axioms Sendov.PeakClosure.HighHomogeneous.gapH_identity diff --git a/scripts/bundle_rows.py b/scripts/bundle_rows.py deleted file mode 100644 index 4b68081..0000000 --- a/scripts/bundle_rows.py +++ /dev/null @@ -1,75 +0,0 @@ -"""Bundle this generator's self-contained RowN modules, preserving each body. - -This is source packaging, not a certificate checker or a general Lean parser. -The last group includes the row-61 base shared with the infinite tail. -""" -from pathlib import Path -import argparse -import json -from distillation_data import ROWS - -PREFIX = 'Sendov.DistillationFinite.' - - -def split_row(text): - lines = text.splitlines(keepends=True) - imports = [line.rstrip('\r\n') for line in lines if line.startswith('import ')] - if not imports or any(PREFIX in line for line in imports): - raise ValueError('rows must import shared helpers, not one another') - return imports, ''.join(line for line in lines if not line.startswith('import ')) - - -def bundle(source, output, size=8): - source, output = Path(source), Path(output) - if not isinstance(size, int) or size < 1: - raise ValueError('positive rows-per-module required') - rows_dir = source / 'Sendov/DistillationFinite' - expected = {f'Row{m}.lean' for m in ROWS} - if {p.name for p in rows_dir.glob('Row*.lean')} != expected: - raise ValueError('rows must be exactly Row5 through Row55, then Row61') - rows = {m: split_row((rows_dir / f'Row{m}.lean').read_text()) for m in ROWS} - aggregate = (source / 'Sendov/Common/DistillationFinite.lean').read_text() - row_imports = [line for line in aggregate.splitlines() if line.startswith(f'import {PREFIX}Row')] - if row_imports != [f'import {PREFIX}Row{m}' for m in ROWS]: - raise ValueError('aggregate must import each row exactly once in original order') - groups = [] - for m in ROWS: - if not groups or len(groups[-1]) == size or m != groups[-1][-1] + 1: - groups.append([]) - groups[-1].append(m) - rendered, manifest = {}, [] - for group in groups: - name = f'Rows{group[0]}_{group[-1]}' - path = f'Sendov/DistillationFinite/{name}.lean' - imports = list(dict.fromkeys(line for m in group for line in rows[m][0])) - text = '\n'.join(imports) + '\n\n' - text += '\n'.join('section\n' + rows[m][1] + '\nend\n' for m in group) - rendered[path] = text - manifest.append({'module': PREFIX + name, 'path': path, 'rows': group}) - replacements = ''.join(f"import {group['module']}\n" for group in manifest) - new_aggregate, inserted = [], False - for line in aggregate.splitlines(keepends=True): - if line.startswith(f'import {PREFIX}Row'): - if not inserted: - new_aggregate.append(replacements); inserted = True - else: - new_aggregate.append(line) - rendered['Sendov/Common/DistillationFinite.lean'] = ''.join(new_aggregate) - # Complete validation/render first, and never overwrite an existing projection. - output.mkdir(parents=True, exist_ok=False) - for path, text in rendered.items(): - target = output / path; target.parent.mkdir(parents=True, exist_ok=True) - target.write_text(text) - return {'groups': manifest, 'candidate_paths': sorted(rendered), 'rows': list(ROWS), - 'source_lines': sum(len(text.splitlines()) for text in rendered.values()), - 'source_bytes': sum(len(text.encode()) for text in rendered.values()), - 'scope': 'Source bodies preserved; complete compiler/kernel acceptance still required.'} - - -if __name__ == '__main__': - parser = argparse.ArgumentParser(description=__doc__) - parser.add_argument('--source', required=True, type=Path) - parser.add_argument('--output', required=True, type=Path) - parser.add_argument('--rows-per-module', type=int, default=8) - args = parser.parse_args() - print(json.dumps(bundle(args.source, args.output, args.rows_per_module), indent=2)) diff --git a/scripts/distillation_data.py b/scripts/distillation_data.py deleted file mode 100644 index 2a54a27..0000000 --- a/scripts/distillation_data.py +++ /dev/null @@ -1,117 +0,0 @@ -"""Exact input validation for the selected finite certificate renderer. - -The rational envelope checks adapt Senjian An's MIT-licensed verify_paper.py, -SJanPerth/Sendov-Proof-Distillation, e8ae601491ec171ab4f7f8456113dd6a047aa85d. -Copyright (c) 2026 Senjian An; see LICENSE-DISTILLATION-MIT.txt. -Schema/coverage validation and integration changes: Apache-2.0. -No sampled arithmetic and no Python assertions authorize generation. -""" -from fractions import Fraction as F -import json -from pathlib import Path - -# Paired with the proved interval 55 <= m <= 61 and the real tail m >= 61. -# Never derive an allowed lower tail threshold from the supplied table. -TAIL_START = 61 -INTERVAL_START = 55 -ROWS = (*range(5, INTERVAL_START + 1), TAIL_START) -FINITE_ROWS = tuple(range(5, TAIL_START)) - - -def require(condition, message): - if not condition: - raise ValueError(message) - - -def object_pairs(pairs): - result = {} - for key, value in pairs: - require(key not in result, f'duplicate JSON key: {key}') - result[key] = value - return result - - -def reject_constant(value): - raise ValueError(f'non-finite JSON constant: {value}') - - -def fields(obj, keys, context): - require(type(obj) is dict and set(obj) == set(keys.split()), - f'{context}: wrong object fields') - - -def rational(value): - require(type(value) is str, 'rational must be a string') - try: - result = F(value) - except (ValueError, ZeroDivisionError) as error: - raise ValueError(f'invalid rational: {value}') from error - require(str(result) == value, f'noncanonical rational: {value}') - return result - - -def eta(a): - u = a / (a + 3) - return u - u**3 / 30 - - -def candidate_squared(m, j, lo, hi): - """The paper's exact squared bracket envelope, not a floating root check.""" - ratio = F(1, 3) if lo == 0 else eta(lo) / lo - kappa = F(m*m - 1, 4*m) * ratio * (m - 2*lo)**2 - node = F(4, 25) + F(3, 5)*eta(hi) + F(12, 25*m)*hi - require(0 < node < 1, 'invalid chord node') - if j == 0: - chord = 96*F(3, 5)**4 / ((m-1)*(m+1)*(m+3)*(m+5)) - return (kappa*chord / (1-node)**4)**2 - if j == 1: - return (F(259, 3125)*kappa)**2 * node**(m-3) - return (F(421, 3125)*kappa)**2 * eta(hi)**(m-3) - - -def load_table(path, coefficients): - rows = json.loads(Path(path).read_text(encoding='utf-8'), - object_pairs_hook=object_pairs, parse_constant=reject_constant) - require(type(rows) is list and len(rows) == len(ROWS), 'exactly 52 rows required') - for m, row in zip(ROWS, rows): - fields(row, 'm e components total', f'row {m}') - require(type(row['m']) is int and row['m'] == m, - 'rows must be m=5..55,61 exactly once in order') - e = rational(row['e']) - require(e == F(1, 4) + F(7, 12*m), f'E budget mismatch at {m}') - parts = row['components'] - require(type(parts) is list and len(parts) == 3, 'exactly three components required') - total = e - for j, part in enumerate(parts): - fields(part, 'index k lo hi u sq sign_lo sign_hi', f'{m}, component {j}') - require(type(part['index']) is int and part['index'] == j, - 'components must be 0..2 exactly once in order') - require(type(part['u']) is int and part['u'] > 0, 'positive integer budget required') - require(type(part['k']) is str, 'bracket classification must be a string') - lo, hi = rational(part['lo']), rational(part['hi']) - require(0 <= lo <= hi <= min(F(17), F(m, 2)), 'bracket outside domain') - boundary = m >= (49, 47, 57)[j] - if boundary: - require(part['k'] == 'B' and lo == hi == 17, 'boundary classification mismatch') - else: - k = rational(part['k']) - require(k.denominator == 1 and lo == k/4 and hi == (k+1)/4, - 'quarter bracket mismatch') - p = coefficients(m, j) - left = sum(c * lo**i for i, c in enumerate(p)) - right = sum(c * hi**i for i, c in enumerate(p)) - require(left == rational(part['sign_lo']) and right == rational(part['sign_hi']), - 'stored sign-value mismatch') - if boundary: - require(left > 0 if j == 0 else left < 0, 'boundary sign mismatch') - else: - require((left > 0 and right < 0) if j == 0 else (left < 0 and right > 0), - 'isolating sign mismatch') - square = candidate_squared(m, j, lo, hi) - require(square == rational(part['sq']), 'stored squared envelope mismatch') - budget = F(part['u'], 1000) - require(square < budget**2, 'component budget does not bound envelope') - total += budget - require(total == rational(row['total']), 'total budget mismatch') - require(total < F(199, 200), 'finite bound failed') - return rows diff --git a/scripts/gen_distillation.py b/scripts/gen_distillation.py deleted file mode 100644 index ba48581..0000000 --- a/scripts/gen_distillation.py +++ /dev/null @@ -1,225 +0,0 @@ -#!/usr/bin/env python3 -"""Suggest small exact critical-polynomial certificates; Lean checks every identity. - -No Python truth enters Lean. Output needs subsequent strict pinned-Lean compilation. -Mathematical data: Senjian An, SJanPerth/Sendov-Proof-Distillation, -e8ae601491ec171ab4f7f8456113dd6a047aa85d, paper CC BY 4.0 / upstream code MIT. -New generator and Lean template: Apache-2.0 as the Sendov baseline. -Explicit fresh/empty output directory required; no production default. -""" -import argparse -import json -import textwrap -import os -import tempfile -from bundle_rows import bundle -from distillation_data import FINITE_ROWS, INTERVAL_START, ROWS, load_table -from fractions import Fraction as F -from math import comb, gcd, lcm -from pathlib import Path - -TABLE = Path(__file__).resolve().parents[1] / 'data/paper_certificate_table.json' - -def coefficients(m, j): - """Ascending powers, independently checked against the actual Lean definitions.""" - if j == 0: - return [43740*m*(13*m-36), 972*(743*m*m-3330*m-2160), - 486*(665*m*m-4752*m-9360), 1134*(49*m*m-566*m-3600), - 12*(103*m*m-1323*m-161676), -377*m*m+22092*m-514512, - 2*(1363*m-36072), -4176] - if j == 1: - return [-14580*m*(15*m*m-17*m-204), -648*(450*m**3-934*m*m-11655*m-1620), - -216*(660*m**3-2164*m*m-37581*m-6480), - -216*(140*m**3-609*m*m-21974*m-2610), - -3*(783*m**3-m*m-538848*m+6048), - -2*(2914*m*m-158961*m+34992), -4*(174*m*m-8279*m+4392), 1392*(m-1)] - if j == 2: - return [-810*m*(m-3), -540*(m*m-7*m-3), -3*(27*m*m-565*m-720), - 2*(110*m+453), 116] - raise ValueError('component must be 0, 1 or 2') - -def certificate(p, a, b): - """scale*p(x) = sum cs[i]*(x-a)^i*(b-x)^(n-i), exact rationals.""" - if not p: - raise ValueError('empty polynomial data') - if not a < b: - raise ValueError('nonempty interval required') - n = len(p)-1 - h = b-a - q = [sum(F(p[i])*comb(i,k)*a**(i-k)*h**k for i in range(k,n+1)) for k in range(n+1)] - cs = [sum(q[k]*F(comb(j,k),comb(n,k)) for k in range(j+1))*comb(n,j)/h**n for j in range(n+1)] - scale = lcm(*(c.denominator for c in cs)) - ns = [int(c*scale) for c in cs] - common = gcd(scale, gcd(*ns)) if len(ns)>1 else gcd(scale, ns[0]) - return scale//common, [c//common for c in ns] - -def sign_cover(p, a, b): - """One certificate for the entire flank; fail rather than grow a subdivision.""" - scale, cs = certificate(p,a,b) - if min(cs) >= 0 and cs[0] > 0 and cs[-1] > 0: - return [(a,b,scale,cs)] - raise ValueError(f'no single strictly positive certificate on [{a},{b}]') - -def validate_cover(intervals, a, b): - if not intervals or intervals[0][0] != a or intervals[-1][1] != b: - raise ValueError('missing sign region at boundary') - cursor = a - for lo,hi in intervals: - if lo != cursor or not lo < hi: - raise ValueError('sign coverage has gap, overlap or reversal') - cursor = hi - -def rat(x): - x = F(x) - return str(x.numerator) if x.denominator == 1 else f'({x.numerator} / {x.denominator})' - -def signed(j,m,side): - positive = (j == 0) == (side == 'left') - return ('' if positive else '-')+f'distillCritical{j} {m} x' - -def sign_source(m,j,side,a,b): - name=f'sign_{j}_{side}' - target=signed(j,m,side) - if a == b: - return f'''private lemma {name} (x : ℝ) (hx : x ∈ Set.Ioo {rat(a)} {rat(b)}) : - 0 ≤ {target} := by - exact False.elim (lt_irrefl {rat(a)} (hx.1.trans hx.2)) - -''', 0 - p=coefficients(m,j) - if target.startswith('-'): - p=[-c for c in p] - cells=sign_cover(p,a,b) - validate_cover([(v[0],v[1]) for v in cells],a,b) - [(lo,hi,scale,cs)]=cells - data=textwrap.fill('['+', '.join(map(str,cs))+']', width=92, - initial_indent=' ', subsequent_indent=' ') - return f'''private lemma {name} (x : ℝ) (hx : x ∈ Set.Ioo {rat(a)} {rat(b)}) : - 0 ≤ {target} := by - refine (BernsteinCert.coeffs_pos -{data} - (lo := {rat(lo)}) (hi := {rat(hi)}) (s := {scale}) - (by norm_num) (by norm_num) ⟨hx.1.le, hx.2.le⟩ (by decide) (by decide) ?_).le - unfold distillCritical{j} - simp only [BernsteinCert.coeffTree_eval_cons, BernsteinCert.coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - -''', 1 - -def row_source(row): - m=row['m']; d=min(F(17),F(m,2)) - s='import Sendov.Common.DistillationCriticalFinite\nimport Sendov.Common.BernsteinList\n\n' - s+='/-! Fixed paper budgets; low-degree sign certificates, not whole-domain T subdivisions.\nGenerated by scripts/gen_distillation.py. See the shared helper for provenance. -/\n\n' - s+=f'namespace Sendov\nnamespace CriticalRow{m}\n\n' - for c in row['components']: - j=c['index']; lo=F(c['lo']); hi=F(c['hi']); u=F(c['u'],1000) - for side,a,b in [('left',F(0),lo),('right',hi,d)]: - source, _ = sign_source(m,j,side,a,b) - s += source - s+=f'''theorem component{j} (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ {rat(d)}) : - distillT{j} {m} α ≤ {rat(u)} := by - apply distillT{j}_le_of_critical (l := {rat(lo)}) (r := {rat(hi)}) (d := {rat(d)}) -''' - if j: - s+=f' {m-3} (by norm_num) (by norm_num)\n' - s+=' (by norm_num) (by norm_num) (by norm_num) (by norm_num) (by norm_num)\n' - s+=f' sign_{j}_left sign_{j}_right ?_ ⟨hα, hd⟩\n' - s+=' norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope]\n\n' - s+=f'end CriticalRow{m}\n\n' - total=rat(row['total']) - budgets=[rat(F(c['u'],1000)) for c in row['components']] - s+=f'''theorem distillFinite_{m} (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ {rat(d)}) : - distillEBudget {m} + distillT0 {m} α + distillT1 {m} α + distillT2 {m} α ≤ {total} := by - have h0 := CriticalRow{m}.component0 α hα hd - have h1 := CriticalRow{m}.component1 α hα hd - have h2 := CriticalRow{m}.component2 α hα hd - calc - _ ≤ distillEBudget {m} + {budgets[0]} + {budgets[1]} + {budgets[2]} := - add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2 - _ = {total} := by norm_num only [distillEBudget] - -theorem distillFiniteBound_{m} : ({total} : ℝ) < 199 / 200 := by norm_num - -''' - s+='end Sendov\n' - return s - -def aggregate_source(): - s=''.join(f'import Sendov.DistillationFinite.Row{m}\n' for m in ROWS) - s+='import Sendov.LargeDegree.DistillationTailBound\n' - s+=f''' -/-! Exact finite-domain critical-bracket closure. Fixed original paper budgets; -see DistillationCriticalFinite for attribution. No sampled truth or global T grid. -/ -namespace Sendov - -theorem distillFinite_components {{m : ℕ}} (hm : 5 ≤ m) (hm60 : m ≤ {FINITE_ROWS[-1]}) - {{α : ℝ}} (hα : 0 ≤ α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := by - by_cases hinterval : {INTERVAL_START} ≤ m - · exact distillComponents_interval_55_61 - ⟨by exact_mod_cast hinterval, by exact_mod_cast (show m ≤ 61 by omega)⟩ hα h17 - have hm54 : m ≤ {INTERVAL_START - 1} := by omega - interval_cases m -''' - for m in range(5, INTERVAL_START): - bound = 'h17' if F(m, 2) >= 17 else '(by linarith)' - s+=f' · exact (distillFinite_{m} α hα {bound}).trans_lt distillFiniteBound_{m}\n' - s+=f''' -theorem distillFinite_scalar {{m : ℕ}} (hm : 5 ≤ m) (hm60 : m ≤ {FINITE_ROWS[-1]}) - {{α : ℝ}} (hα : 0 < α) (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : - scalarObstruction m α (cubicPolarEnvelope α) < 199 / 200 := by - have hmR : (5 : ℝ) ≤ m := by exact_mod_cast hm - exact (distillScalar_le_majorant hmR hα (by linarith)).trans_lt - (distillFinite_components hm hm60 hα.le hαm h17) - -end Sendov -''' - return s - - -def require_empty_output(output): - if output.is_symlink() or (output.exists() and - (not output.is_dir() or any(output.iterdir()))): - raise ValueError('output must be a new or empty directory (not a symlink)') - - -def generate(output, table=TABLE): - output = Path(output).absolute() - require_empty_output(output) - rows = load_table(table, coefficients) - rendered = {f'Sendov/DistillationFinite/Row{r["m"]}.lean': row_source(r) - for r in rows} - rendered['Sendov/Common/DistillationFinite.lean'] = aggregate_source() - # All exact calculations and row rendering precede staging. Only the grouped - # snapshot is published; individual rows are temporary packaging inputs. - output.parent.mkdir(parents=True, exist_ok=True) - with tempfile.TemporaryDirectory(prefix='.distillation-', dir=output.parent) as temporary: - work = Path(temporary) - raw = work / 'rows' - for rel, text in rendered.items(): - target = raw / rel - target.parent.mkdir(parents=True, exist_ok=True) - target.write_text(text, encoding='utf-8', newline='\n') - result = bundle(raw, work / 'grouped', size=8) - require_empty_output(output) - os.replace(work / 'grouped', output) - return result - - -def main(): - parser = argparse.ArgumentParser(description=__doc__) - parser.add_argument('--output', type=Path, required=True, - help='new or empty output directory; never the project source tree') - parser.add_argument('--table', type=Path, default=TABLE, - help='exact table JSON (default: project data/paper_certificate_table.json)') - args = parser.parse_args() - try: - result = generate(args.output, args.table) - except (ValueError, OSError) as error: - parser.exit(1, f'error: {error}\n') - print(json.dumps(result, indent=2)) - - -if __name__ == '__main__': - main() diff --git a/tests/BoundaryConsumer.lean b/tests/BoundaryConsumer.lean index 678284b..cec63bb 100644 --- a/tests/BoundaryConsumer.lean +++ b/tests/BoundaryConsumer.lean @@ -1,55 +1,24 @@ -import Lean -import Sendov.Common.DistillationCritical -import Sendov.LargeDegree.DistillationTailBound +import Sendov.Common.DistillationBounds namespace MathPolishBoundary +open Sendov -/-- The totalized raw obstruction retains its actual zero-endpoint value. -/ theorem raw_zero (m : ℝ) : - Sendov.scalarObstruction m 0 (Sendov.cubicPolarEnvelope 0) = 1 / (2 * m) := - Sendov.scalarObstruction_zero m + scalarObstruction m 0 (cubicPolarEnvelope 0) = 1 / (2 * m) := + scalarObstruction_zero m -/-- The tail component vanishes at the closed left endpoint. -/ -theorem tail_zero {m : ℝ} (hm : 61 ≤ m) : Sendov.distillT2 m 0 = 0 := - Sendov.distillT2_zero hm +theorem component_zero {m : ℝ} (hm : 5 ≤ m) : distillT2 m 0 = 0 := by + have hexp : (m - 3) / 2 ≠ 0 := by linarith + simp [distillT2, cubicPolarEnvelope, Real.zero_rpow hexp] -/-- Both boundary identities are consumed together at the real tail threshold. -/ -theorem threshold_boundary : - Sendov.scalarObstruction 61 0 (Sendov.cubicPolarEnvelope 0) = 1 / 122 ∧ - Sendov.distillT2 61 0 = 0 := by - constructor - · convert raw_zero 61 using 1 - norm_num - · exact tail_zero (by norm_num) - -/-- The former threshold remains covered by the stronger tail interface. -/ -theorem former_threshold_boundary : - Sendov.scalarObstruction 64 0 (Sendov.cubicPolarEnvelope 0) = 1 / 128 ∧ - Sendov.distillT2 64 0 = 0 := by - constructor - · convert raw_zero 64 using 1 - norm_num - · exact tail_zero (by norm_num) - -theorem closed_tail {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (h17 : α ≤ 17) : - Sendov.distillEBudget m + Sendov.distillT0 m α + - Sendov.distillT1 m α + Sendov.distillT2 m α < 199 / 200 := - Sendov.distillComponents_lt_199_200 hm hα h17 - -theorem closed_interval {m α : ℝ} (hm : m ∈ Set.Icc 55 61) - (hα : 0 ≤ α) (h17 : α ≤ 17) : - Sendov.distillEBudget m + Sendov.distillT0 m α + - Sendov.distillT1 m α + Sendov.distillT2 m α < 199 / 200 := - Sendov.distillComponents_interval_55_61 hm hα h17 +theorem legal_right_endpoint {α : ℝ} (hα : 5 / 2 ≤ α) (h17 : α ≤ 17) : + scalarObstruction (2 * α) α (cubicPolarEnvelope α) < 1 := + distillScalar_lt_one_real (by linarith) (by linarith) h17 le_rfl -theorem interval_boundary : - Sendov.scalarObstruction 55 0 (Sendov.cubicPolarEnvelope 0) = 1 / 110 ∧ - Sendov.distillEBudget 55 + Sendov.distillT0 55 0 + - Sendov.distillT1 55 0 + Sendov.distillT2 55 0 < 199 / 200 := by +example : scalarObstruction 5 0 (cubicPolarEnvelope 0) = 1 / 10 ∧ distillT2 5 0 = 0 := by constructor - · convert raw_zero 55 using 1 - norm_num - · exact closed_interval (by norm_num) le_rfl (by norm_num) + · norm_num [raw_zero] + · exact component_zero le_rfl end MathPolishBoundary @@ -58,16 +27,9 @@ run_cmd do let env := (← getEnv).setExporting false for (consumer, target) in #[ (`MathPolishBoundary.raw_zero, `Sendov.scalarObstruction_zero), - (`MathPolishBoundary.tail_zero, `Sendov.distillT2_zero), - (`MathPolishBoundary.closed_tail, `Sendov.distillComponents_lt_199_200), - (`MathPolishBoundary.closed_interval, `Sendov.distillComponents_interval_55_61)] do + (`MathPolishBoundary.legal_right_endpoint, `Sendov.distillScalar_lt_one_real)] do let some info := env.find? consumer | throwError "missing consumer {consumer}" let some value := info.value? (allowOpaque := true) | throwError "missing proof value" unless value.getUsedConstants.contains target do throwError "not a real value consumer: {consumer} -> {target}" logInfo m!"BOUNDARY_VALUE_CONSUMER {consumer} -> {target}" - for target in #[`Sendov.distillComponents_le_of_mixed, `Sendov.distillL_eq, - `Sendov.distillT0_nonneg, `Sendov.distillT1_nonneg, `Sendov.distillT2_nonneg, - `Sendov.QQ_zero, `Sendov.QQ_le_one] do - if env.contains target then throwError "retired declaration remains: {target}" - logInfo "BOUNDARY_PASS: actual zero identities consumed; seven retired declarations absent" diff --git a/tests/EarlierTail.lean b/tests/EarlierTail.lean deleted file mode 100644 index 8d0ac98..0000000 --- a/tests/EarlierTail.lean +++ /dev/null @@ -1,157 +0,0 @@ -import Lean -import Solution - -open Sendov - -namespace EarlierTailTest - -example {m : ℕ} (hm : 5 ≤ m) : (5 ≤ m ∧ m ≤ 60) ∨ 61 ≤ m := by omega - -example {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) : - distillEBudget m + distillT0 m 0 + distillT1 m 0 + distillT2 m 0 < 199 / 200 := - distillFinite_components hm hm60 (by norm_num) (by positivity) (by norm_num) - -example {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (h17 : α ≤ 17) : - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := - distillComponents_lt_199_200 hm hα h17 - -example {m α : ℝ} (hm : 61 ≤ m) (hα : 0 < α) (h17 : α ≤ 17) : - scalarObstruction m α (cubicPolarEnvelope α) < 1 := - (distillScalar_lt_199_200 hm hα h17).trans (by norm_num) - -example : - distillEBudget 61 + distillT0 61 0 + distillT1 61 0 + distillT2 61 0 < 199 / 200 := - distillComponents_lt_199_200 (by norm_num) (by norm_num) (by norm_num) - -example : - scalarObstruction 61 0 (cubicPolarEnvelope 0) = 1 / 122 := by - rw [scalarObstruction_zero] - norm_num - -example : - distillEBudget (123 / 2) + distillT0 (123 / 2) 17 + - distillT1 (123 / 2) 17 + distillT2 (123 / 2) 17 < 199 / 200 := - distillComponents_lt_199_200 (by norm_num) (by norm_num) (by norm_num) - -example {n : ℕ} (hn : 6 ≤ n) {α : ℝ} - (hα : 0 < α) (h17 : α ≤ 17) (hhalf : 2 * α ≤ M n) : - scalarObstruction (M n) α (cubicPolarEnvelope α) < 1 := - distillScalar_lt_one hn hα h17 hhalf - -example : scalarObstruction (M 6) (5 / 2) (cubicPolarEnvelope (5 / 2)) < 1 := - distillScalar_lt_one (by norm_num) (by norm_num) (by norm_num) (by norm_num [M]) - -example : scalarObstruction (M 61) 17 (cubicPolarEnvelope 17) < 1 := - distillScalar_lt_one (by norm_num) (by norm_num) (by norm_num) (by norm_num [M]) - -example : scalarObstruction (M 62) 17 (cubicPolarEnvelope 17) < 1 := - distillScalar_lt_one (by norm_num) (by norm_num) (by norm_num) (by norm_num [M]) - -example : scalarObstruction (M 64) 17 (cubicPolarEnvelope 17) < 1 := - distillScalar_lt_one (by norm_num) (by norm_num) (by norm_num) (by norm_num [M]) - -example : scalarObstruction (M 65) 17 (cubicPolarEnvelope 17) < 1 := - distillScalar_lt_one (by norm_num) (by norm_num) (by norm_num) (by norm_num [M]) - -open Polynomial in -example {p : ℂ[X]} (hdeg : 2 ≤ p.natDegree) - (hzeroes : ∀ w : ℂ, p.eval w = 0 → ‖w‖ ≤ 1) {a : ℂ} (hpa : p.eval a = 0) : - ∃ ζ : ℂ, (derivative p).eval ζ = 0 ∧ ‖ζ - a‖ ≤ 1 := - SendovConjecture.sendov hdeg hzeroes hpa - -open Polynomial in -example {p : ℂ[X]} (hdeg : 2 ≤ p.natDegree) - (hzeroes : ∀ w : ℂ, p.eval w = 0 → ‖w‖ ≤ 1) {a : ℂ} (hpa : p.eval a = 0) : - (∃ ζ : ℂ, (derivative p).eval ζ = 0 ∧ ‖ζ - a‖ < 1) ∨ - (‖a‖ = 1 ∧ ∃ c : ℂ, c ≠ 0 ∧ - p = C c * (X ^ p.natDegree - C (a ^ p.natDegree))) := - SendovConjecture.phelps_rodriguez hdeg hzeroes hpa - -end EarlierTailTest - -open Lean Elab Command in -run_cmd do - let env := (← getEnv).setExporting false - for (consumer, targets) in #[ - (`Sendov.distillFinite_components, #[`Sendov.distillComponents_interval_55_61]), - (`Sendov.distillComponents_interval_55_61, - #[`Sendov.distillKappa_rpow_interval, `Sendov.distillT0_antitone_55, - `Sendov.CriticalRow55.component0, `Sendov.CriticalRow55.component1, - `Sendov.CriticalRow55.component2]), - (`Sendov.distillComponents_lt_199_200, - #[`Sendov.distillComponents_le_61, `Sendov.distillFinite_61, - `Sendov.distillFiniteBound_61]), - (`Sendov.distillScalar_lt_199_200, - #[`Sendov.distillScalar_le_majorant, `Sendov.distillComponents_lt_199_200]), - (`Sendov.distillScalar_lt_one, - #[`Sendov.distillFinite_scalar, `Sendov.distillScalar_lt_199_200]), - (`Sendov.polar_origin_incompatible, #[`Sendov.distillScalar_lt_one]), - (`Sendov.sendov_interior, #[`Sendov.polar_origin_incompatible]), - (`Sendov.sendov_interior_real, #[`Sendov.sendov_interior]), - (`Sendov.phelps_rodriguez, #[`Sendov.sendov_interior_real]), - (`Sendov.sendov, #[`Sendov.phelps_rodriguez]), - (`SendovConjecture.sendov, #[`Sendov.sendov]), - (`SendovConjecture.phelps_rodriguez, #[`Sendov.phelps_rodriguez])] do - let some info := env.find? consumer | throwError "missing declaration {consumer}" - let some value := info.value? (allowOpaque := true) | throwError "missing proof {consumer}" - for target in targets do - unless value.getUsedConstants.contains target do - throwError "not an actual proof consumer: {consumer} -> {target}" - logInfo m!"EARLIER_TAIL_CONSUMER {consumer} -> {target}" - for target in #[`Sendov.distillComponents_interval_55_61, - `Sendov.distillComponents_lt_199_200, `Sendov.distillScalar_lt_199_200, - `Sendov.distillScalar_lt_one, `SendovConjecture.sendov, - `SendovConjecture.phelps_rodriguez] do - let axioms ← withEnv env <| Lean.collectAxioms target - unless axioms.all (#[``propext, ``Classical.choice, ``Quot.sound].contains) do - throwError "unexpected axiom in {target}: {axioms}" - logInfo m!"EARLIER_TAIL_AXIOMS {target}: {axioms}" - -open Lean Elab Command in -run_cmd do - let env := (← getEnv).setExporting false - let retired := #[ - `Sendov.distillFiniteTailBase, `Sendov.distillComponents_lt_two_thirds, - `Sendov.distillScalar_lt_two_thirds, `Sendov.distillComponents_lt_two_thirds_of_base, - `Sendov.distillEBudget_le_81, `Sendov.distillT0_le_81, `Sendov.distillT1_le_81, - `Sendov.distillT2_le_81, `Sendov.distillComponents_le_81, `Sendov.distillTail_polynomial_pos, - `Sendov.distillComponents_le_64] - for name in retired do - if env.contains name then throwError "retired declaration still imported: {name}" - -- Only project values can reference project cases: earlier imported libraries - -- cannot depend on declarations introduced later by Sendov. - for (root, upper) in #[(`Sendov.distillFinite_components, 60), - (`SendovConjecture.sendov, 61), (`SendovConjecture.phelps_rodriguez, 61)] do - let mut pending := [root] - let mut visited : Std.HashSet Name := {} - while !pending.isEmpty do - let name := pending.head! - pending := pending.tail! - unless visited.contains name do - visited := visited.insert name - let some info := env.find? name | throwError "missing closure declaration {name}" - if let some value := info.value? (allowOpaque := true) then - for used in value.getUsedConstants do - let text := used.toString - if text.startsWith "Sendov." || text.startsWith "SendovConjecture." || - text.startsWith "_private.Sendov." then - pending := used :: pending - for m in [5:82] do - for stem in ["distillFinite_", "distillFiniteBound_"] do - let name := Name.str `Sendov s!"{stem}{m}" - unless visited.contains name == (m ≤ 54 || (m == 61 && upper == 61)) do - throwError "wrong actual case closure: {root}, {name}" - if (56 ≤ m && m ≤ 60 || 62 ≤ m) && env.contains name then - throwError "retired case still imported: {name}" - for j in [0:3] do - let name := Name.str (Name.str `Sendov s!"CriticalRow{m}") s!"component{j}" - unless visited.contains name == (m ≤ 55 || (m == 61 && upper == 61)) do - throwError "wrong actual component closure: {root}, {name}" - if (56 ≤ m && m ≤ 60 || 62 ≤ m) && env.contains name then - throwError "retired component still imported: {name}" - for name in visited do - let text := name.toString - if retired.contains name || (text.splitOn "two_thirds").length > 1 || - (text.splitOn "_le_81").length > 1 then - throwError "retired tail in actual value closure: {root}, {name}" - logInfo m!"INTERVAL_VALUE_CLOSURE {root}: cases5..54, base55, tail61 iff final; no retired rows" diff --git a/tests/LocalMiddleAlpha.lean b/tests/LocalMiddleAlpha.lean new file mode 100644 index 0000000..2669fb8 --- /dev/null +++ b/tests/LocalMiddleAlpha.lean @@ -0,0 +1,150 @@ +import Sendov.Common.DistillationMiddleAlpha +import Solution + +namespace LocalMiddleAlpha + +open Sendov + +theorem closed_real_strip {m α : ℝ} (hm : 5 ≤ m) + (hα : 7 / 5 ≤ α) (hα2 : α ≤ 2) (hhalf : 2 * α ≤ m) : + scalarObstruction m α (cubicPolarEnvelope α) < 1 := + distillScalar_lt_one_middle_alpha hm hα hα2 hhalf + +theorem lower_endpoint_ray {m : ℝ} (hm : 5 ≤ m) : + scalarObstruction m (7 / 5) (cubicPolarEnvelope (7 / 5)) < 1 := + closed_real_strip hm (by norm_num) (by norm_num) (by linarith) + +theorem upper_endpoint_ray {m : ℝ} (hm : 5 ≤ m) : + scalarObstruction m 2 (cubicPolarEnvelope 2) < 1 := + closed_real_strip hm (by norm_num) (by norm_num) (by linarith) + +theorem split_endpoint_ray {m : ℝ} (hm : 5 ≤ m) : + scalarObstruction m (17 / 10) (cubicPolarEnvelope (17 / 10)) < 1 := + closed_real_strip hm (by norm_num) (by norm_num) (by linarith) + +theorem original_natural_degree {n : ℕ} (hn : 6 ≤ n) {α : ℝ} + (hα : 7 / 5 ≤ α) (hα2 : α ≤ 2) (hhalf : 2 * α ≤ M n) : + scalarObstruction (M n) α (cubicPolarEnvelope α) < 1 := by + apply closed_real_strip _ hα hα2 hhalf + have hnreal : (6 : ℝ) ≤ n := by exact_mod_cast hn + unfold M + linarith + +theorem noninteger_degree_lower : + scalarObstruction (11 / 2) (3 / 2) (cubicPolarEnvelope (3 / 2)) < 1 := + closed_real_strip (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +theorem noninteger_degree_upper : + scalarObstruction (201 / 20) (19 / 10) (cubicPolarEnvelope (19 / 10)) < 1 := + closed_real_strip (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +theorem degree_five_lower : + scalarObstruction 5 (7 / 5) (cubicPolarEnvelope (7 / 5)) < 1 := + lower_endpoint_ray (by norm_num) + +theorem degree_five_upper : scalarObstruction 5 2 (cubicPolarEnvelope 2) < 1 := + upper_endpoint_ray (by norm_num) + +theorem inherited_join {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hα2 : α ≤ 2) : + scalarObstruction m α (cubicPolarEnvelope α) < 1 := + distillScalar_lt_one_alpha_le_two hm hα hα2 (by linarith) + +theorem old_whole_chord_counterexample : + distillChordTotal 13 (10 / 7) = 1 + 426061 / 212373252 := by + norm_num [distillChordTotal, distillEBudget] + +theorem original_at_whole_chord_counterexample : + scalarObstruction 13 (10 / 7) (cubicPolarEnvelope (10 / 7)) < 1 := + closed_real_strip (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +theorem old_rational_peak_lower_obstruction : 1 < distillRationalPeak (7 / 5) := by + norm_num [distillRationalPeak, distillElementary, distillPeak0, distillPeakD, + distillRatio, cubicPolarEnvelope, distillRationalExpPeak, distillTaylor6, + distillPeakRate1, distillPeakRate2, distillPeakShift1, distillPeakBoost1, distillPeakNode] + +theorem old_rational_peak_upper_obstruction : 1 < distillRationalPeak (19 / 10) := by + norm_num [distillRationalPeak, distillElementary, distillPeak0, distillPeakD, + distillRatio, cubicPolarEnvelope, distillRationalExpPeak, distillTaylor6, + distillPeakRate1, distillPeakRate2, distillPeakShift1, distillPeakBoost1, distillPeakNode] + +theorem raw_zero_unchanged (m : ℝ) : + scalarObstruction m 0 (cubicPolarEnvelope 0) = 1 / (2 * m) := + scalarObstruction_zero m + +theorem final_consumer_at_six : + scalarObstruction (M 6) (19 / 10) (cubicPolarEnvelope (19 / 10)) < 1 := + distillScalar_lt_one (by norm_num) (by norm_num) (by norm_num) (by norm_num [M]) + +theorem retained_old_domain_at_six : + scalarObstruction (M 6) (5 / 2) (cubicPolarEnvelope (5 / 2)) < 1 := + distillScalar_lt_one (by norm_num) (by norm_num) (by norm_num) (by norm_num [M]) + +end LocalMiddleAlpha + +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + for (consumer, targets) in #[ + (`Sendov.distillScalar_lt_one_middle_alpha, + #[`Sendov.distillScalar_le_elementary_components, `Sendov.distillElementary_le_middle, + `Sendov.distillT0_le_middle, `Sendov.distillT1_le_middle, `Sendov.distillT2_le_middle]), + (`Sendov.distillT0_le_middle, #[`Sendov.distillT0_le_mixed_rational]), + (`Sendov.distillT1_le_middle, + #[`Sendov.distillT1_le_mixed_peak, `Sendov.distill_mixed_peak1_le_linear]), + (`Sendov.distillT2_le_middle, + #[`Sendov.distillT2_le_mixed_peak, `Sendov.distill_mixed_peak2_le_linear]), + (`Sendov.distillScalar_le_correlated_peak2, + #[`Sendov.distillScalar_le_elementary_components]), + (`Sendov.distillScalar_lt_one_alpha_le_two, + #[`Sendov.distillScalar_lt_one_middle_alpha, `Sendov.distillScalar_lt_one_small_alpha]), + (`Sendov.distillScalar_lt_one_real, + #[`Sendov.distillScalar_lt_one_alpha_le_two, `Sendov.distillScalar_lt_one_peak_strip]), + (`Sendov.distillScalar_lt_one, #[`Sendov.distillScalar_lt_one_real]), + (`Sendov.polar_origin_incompatible, #[`Sendov.distillScalar_lt_one]), + (`Sendov.sendov_interior, #[`Sendov.polar_origin_incompatible]), + (`Sendov.sendov_interior_real, #[`Sendov.sendov_interior]), + (`Sendov.phelps_rodriguez, #[`Sendov.sendov_interior_real]), + (`Sendov.sendov, #[`Sendov.phelps_rodriguez]), + (`SendovConjecture.sendov, #[`Sendov.sendov]), + (`SendovConjecture.phelps_rodriguez, #[`Sendov.phelps_rodriguez])] do + let some info := env.find? consumer | throwError "missing declaration {consumer}" + let some value := info.value? (allowOpaque := true) | throwError "missing proof {consumer}" + for target in targets do + unless value.getUsedConstants.contains target do + throwError "not an actual consumer: {consumer} -> {target}" + logInfo m!"MIDDLE_ALPHA_CONSUMER {consumer} -> {target}" + for root in #[`Sendov.distillScalar_lt_one_middle_alpha, + `Sendov.distillScalar_lt_one_alpha_le_two, `LocalMiddleAlpha.original_natural_degree] do + let mut pending := [root] + let mut visited : Std.HashSet Name := {} + while !pending.isEmpty do + let name := pending.head! + pending := pending.tail! + unless visited.contains name do + visited := visited.insert name + let some info := env.find? name | throwError "missing closure declaration {name}" + if let some value := info.value? (allowOpaque := true) then + for used in value.getUsedConstants do + pending := used :: pending + for name in visited do + let text := name.toString + for forbidden in #["CriticalRow", "distillFinite", "DistillationFinite", + "DistillationTail", "interval_55_61", "_le_61", "_antitone_55", + "distillScalar_le_rationalPeak", "distillT0_le_peak"] do + if (text.splitOn forbidden).length > 1 then + throwError "forbidden proof-value dependency: {root} -> {name}" + let axioms ← withEnv env <| Lean.collectAxioms root + unless axioms.all (#[``propext, ``Classical.choice, ``Quot.sound].contains) do + throwError "unexpected axioms for {root}: {axioms}" + logInfo m!"MIDDLE_ALPHA_FULL_VALUE_CLOSURE {root}: {visited.size} declarations" + logInfo m!"No namespace pruning; no rows, old interval/tail, or discarded-factor T0 peak" + logInfo m!"MIDDLE_ALPHA_AXIOMS {root}: {axioms}" + for root in #[`LocalMiddleAlpha.noninteger_degree_upper, + `LocalMiddleAlpha.old_whole_chord_counterexample, + `LocalMiddleAlpha.old_rational_peak_lower_obstruction, + `LocalMiddleAlpha.old_rational_peak_upper_obstruction, + `SendovConjecture.sendov, `SendovConjecture.phelps_rodriguez] do + let axioms ← withEnv env <| Lean.collectAxioms root + unless axioms.all (#[``propext, ``Classical.choice, ``Quot.sound].contains) do + throwError "unexpected axioms for {root}: {axioms}" + logInfo m!"MIDDLE_ALPHA_REGRESSION_AXIOMS {root}: {axioms}" diff --git a/tests/LocalPeakClosure.lean b/tests/LocalPeakClosure.lean new file mode 100644 index 0000000..530e253 --- /dev/null +++ b/tests/LocalPeakClosure.lean @@ -0,0 +1,150 @@ +import Sendov.Common.DistillationPeakClosure +import Solution + +namespace LocalPeakClosure + +open Sendov + +theorem uniform_alpha {α : ℝ} (hα : 2 ≤ α) (h17 : α ≤ 17) : + distillRationalPeak α < 1 := + distillRationalPeak_lt_one hα h17 + +theorem original_real_ray {m α : ℝ} (hm : 5 ≤ m) (hα : 2 ≤ α) + (h17 : α ≤ 17) (hhalf : 2 * α ≤ m) : + scalarObstruction m α (cubicPolarEnvelope α) < 1 := + distillScalar_lt_one_peak_strip hm hα h17 hhalf + +example : scalarObstruction 5 2 (cubicPolarEnvelope 2) < 1 := + original_real_ray (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +example : scalarObstruction 5 (5 / 2) (cubicPolarEnvelope (5 / 2)) < 1 := + original_real_ray (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +example : scalarObstruction 34 17 (cubicPolarEnvelope 17) < 1 := + original_real_ray (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +example : scalarObstruction (137 / 4) 17 (cubicPolarEnvelope 17) < 1 := + original_real_ray (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +example : ¬ 2 * (17 : ℝ) ≤ 5 := by norm_num + +theorem strict_margin_needed : 199 / 200 < distillRationalPeak 17 := by + norm_num [distillRationalPeak, distillElementary, distillPeak0, distillPeakD, + distillRatio, cubicPolarEnvelope, distillRationalExpPeak, distillTaylor6, + distillPeakRate1, distillPeakRate2, distillPeakShift1, distillPeakBoost1, distillPeakNode] + +theorem lower_interval_obstruction : 1 < distillRationalPeak (19 / 10) := by + norm_num [distillRationalPeak, distillElementary, distillPeak0, distillPeakD, + distillRatio, cubicPolarEnvelope, distillRationalExpPeak, distillTaylor6, + distillPeakRate1, distillPeakRate2, distillPeakShift1, distillPeakBoost1, distillPeakNode] + +theorem upper_interval_obstruction : 1 < distillRationalPeak 18 := by + norm_num [distillRationalPeak, distillElementary, distillPeak0, distillPeakD, + distillRatio, cubicPolarEnvelope, distillRationalExpPeak, distillTaylor6, + distillPeakRate1, distillPeakRate2, distillPeakShift1, distillPeakBoost1, distillPeakNode] + +noncomputable def thirdOrderCandidate (α : ℝ) : ℝ := + distillElementary (max 5 (2 * α)) α + distillPeak0 α + + (259 / 12500) * distillRatio α * + ((27 * (249 / 5000) / distillPeakRate1 α ^ 3 + + 8 * α * (677 / 5000) / distillPeakRate1 α ^ 2) / + (1 + distillPeakShift1 α + distillPeakShift1 α ^ 2 / 2 + + distillPeakShift1 α ^ 3 / 6)) + + (421 / 12500) * distillRatio α * + distillRationalExpPeak α (distillPeakRate2 α) (distillPeakRate2 α * (2 * α - 3)) + +/-- Dropping one more Taylor term breaks this particular majorant at the endpoint. -/ +theorem third_order_obstruction : 1 < thirdOrderCandidate 17 := by + norm_num [thirdOrderCandidate, distillElementary, distillPeak0, distillPeakD, + distillRatio, cubicPolarEnvelope, distillRationalExpPeak, distillTaylor6, + distillPeakRate1, distillPeakRate2, distillPeakShift1, distillPeakBoost1, distillPeakNode] + +theorem raw_zero_unchanged : scalarObstruction 5 0 (cubicPolarEnvelope 0) = 1 / 10 := by + norm_num [scalarObstruction_zero] + +open Polynomial in +example {p : ℂ[X]} (hdeg : 2 ≤ p.natDegree) + (hzeroes : ∀ w : ℂ, p.eval w = 0 → ‖w‖ ≤ 1) {a : ℂ} (hpa : p.eval a = 0) : + ∃ ζ : ℂ, (derivative p).eval ζ = 0 ∧ ‖ζ - a‖ ≤ 1 := + SendovConjecture.sendov hdeg hzeroes hpa + +open Polynomial in +example {p : ℂ[X]} (hdeg : 2 ≤ p.natDegree) + (hzeroes : ∀ w : ℂ, p.eval w = 0 → ‖w‖ ≤ 1) {a : ℂ} (hpa : p.eval a = 0) : + (∃ ζ : ℂ, (derivative p).eval ζ = 0 ∧ ‖ζ - a‖ < 1) ∨ + (‖a‖ = 1 ∧ ∃ c : ℂ, c ≠ 0 ∧ + p = C c * (X ^ p.natDegree - C (a ^ p.natDegree))) := + SendovConjecture.phelps_rodriguez hdeg hzeroes hpa + +end LocalPeakClosure + +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + for (consumer, targets) in #[ + (`Sendov.PeakClosure.gap1_pos, #[`Sendov.PeakClosure.gap1_identity]), + (`Sendov.PeakClosure.gapLow_pos, #[`Sendov.PeakClosure.LowHomogeneous.positive]), + (`Sendov.PeakClosure.LowHomogeneous.positive, + #[`Sendov.PeakClosure.LowHomogeneous.identity]), + (`Sendov.PeakClosure.LowHomogeneous.identity, + #[`Sendov.PeakClosure.LowHomogeneous.gapH_eval, + `Sendov.PeakClosure.LowHomogeneous.gapH_identity]), + (`Sendov.PeakClosure.gapHigh_pos, #[`Sendov.PeakClosure.HighHomogeneous.positive]), + (`Sendov.PeakClosure.HighHomogeneous.positive, + #[`Sendov.PeakClosure.HighHomogeneous.identity]), + (`Sendov.PeakClosure.HighHomogeneous.identity, + #[`Sendov.PeakClosure.HighHomogeneous.gapH_eval, + `Sendov.PeakClosure.HighHomogeneous.gapH_identity]), + (`Sendov.PeakClosure.peak1_lt_budget, + #[`Sendov.PeakClosure.gap1_pos, `Sendov.PeakClosure.peak1_le_four]), + (`Sendov.PeakClosure.rest_lt_budget, + #[`Sendov.PeakClosure.gapLow_pos, `Sendov.PeakClosure.gapHigh_pos, + `Sendov.PeakClosure.gapLow_eq, `Sendov.PeakClosure.gapHigh_eq, + `Sendov.PeakClosure.peak2_eq]), + (`Sendov.distillRationalPeak_lt_one, + #[`Sendov.PeakClosure.peak1_lt_budget, `Sendov.PeakClosure.rest_lt_budget]), + (`Sendov.distillScalar_lt_one_peak_strip, + #[`Sendov.distillScalar_le_rationalPeak, `Sendov.distillRationalPeak_lt_one]), + (`Sendov.distillScalar_lt_one_real, + #[`Sendov.distillScalar_lt_one_peak_strip, `Sendov.distillScalar_lt_one_alpha_le_two]), + (`Sendov.distillScalar_lt_one, #[`Sendov.distillScalar_lt_one_real]), + (`Sendov.polar_origin_incompatible, #[`Sendov.distillScalar_lt_one]), + (`Sendov.sendov_interior, #[`Sendov.polar_origin_incompatible]), + (`Sendov.sendov_interior_real, #[`Sendov.sendov_interior]), + (`Sendov.phelps_rodriguez, #[`Sendov.sendov_interior_real]), + (`Sendov.sendov, #[`Sendov.phelps_rodriguez]), + (`SendovConjecture.sendov, #[`Sendov.sendov]), + (`SendovConjecture.phelps_rodriguez, #[`Sendov.phelps_rodriguez])] do + let some info := env.find? consumer | throwError "missing declaration {consumer}" + let some value := info.value? (allowOpaque := true) | throwError "missing proof {consumer}" + for target in targets do + unless value.getUsedConstants.contains target do + throwError "not an actual value consumer: {consumer} -> {target}" + logInfo m!"PEAK_CLOSURE_CONSUMER {consumer} -> {target}" + for root in #[`Sendov.distillRationalPeak_lt_one, `Sendov.distillScalar_lt_one_peak_strip] do + let mut pending := [root] + let mut visited : Std.HashSet Name := {} + while !pending.isEmpty do + let name := pending.head! + pending := pending.tail! + unless visited.contains name do + visited := visited.insert name + let some info := env.find? name | throwError "missing closure declaration {name}" + if let some value := info.value? (allowOpaque := true) then + for used in value.getUsedConstants do + pending := used :: pending + for name in visited do + let text := name.toString + for forbidden in #["CriticalRow", "distillFinite", "DistillationTail", + "interval_55_61", "_le_61", "_le_51", "_antitone_55"] do + if (text.splitOn forbidden).length > 1 then + throwError "old row/tail in new value closure: {root} -> {name}" + logInfo m!"PEAK_CLOSURE_NO_ROWS_OR_OLD_TAIL {root}; full constants {visited.size}" + for target in #[`Sendov.distillRationalPeak_lt_one, `Sendov.distillScalar_lt_one_peak_strip, + `LocalPeakClosure.strict_margin_needed, `LocalPeakClosure.lower_interval_obstruction, + `LocalPeakClosure.upper_interval_obstruction, `LocalPeakClosure.third_order_obstruction, + `SendovConjecture.sendov, `SendovConjecture.phelps_rodriguez] do + let axioms ← withEnv env <| Lean.collectAxioms target + unless axioms.all (#[``propext, ``Classical.choice, ``Quot.sound].contains) do + throwError "unexpected axiom in {target}: {axioms}" + logInfo m!"PEAK_CLOSURE_AXIOMS {target}: {axioms}" diff --git a/tests/LocalTotalBound.lean b/tests/LocalTotalBound.lean new file mode 100644 index 0000000..2597a71 --- /dev/null +++ b/tests/LocalTotalBound.lean @@ -0,0 +1,83 @@ +import Sendov.Common.DistillationTotalBound + +namespace LocalTotalBound +open Sendov MeasureTheory + +theorem small_alpha_real_ray {m α : ℝ} (hm : 5 ≤ m) + (hα : 0 < α) (hα1 : α ≤ 7 / 5) : + scalarObstruction m α (cubicPolarEnvelope α) < 1 := + distillScalar_lt_one_small_alpha hm hα hα1 + +theorem whole_chord_real_frontier : + distillChordTotal (25 / 2) (17 / 12) = 1 + 141383 / 711868500 := by + norm_num [distillChordTotal, distillEBudget] + +theorem whole_chord_integer_frontier : + distillChordTotal 13 (10 / 7) = 1 + 426061 / 212373252 := by + norm_num [distillChordTotal, distillEBudget] + +private lemma integral_quadratic (A b : ℝ) : + (∫ t in (0 : ℝ)..1, t ^ 3 * (1 - b * t + A * t ^ 2)) = + 1 / 4 - b / 5 + A / 6 := by + have hid : (fun t : ℝ => t ^ 3 * (1 - b * t + A * t ^ 2)) = + fun t => t ^ 3 - b * t ^ 4 + A * t ^ 5 := by funext t; ring + rw [hid] + simp (disch := exact Continuous.intervalIntegrable (by fun_prop) _ _) only + [intervalIntegral.integral_add, intervalIntegral.integral_sub, + intervalIntegral.integral_const_mul, integral_pow] + norm_num + ring + +private lemma integral_quadratic_sq (A b : ℝ) : + (∫ t in (0 : ℝ)..1, t ^ 3 * (1 - b * t + A * t ^ 2) ^ 2) = + 1 / 4 - 2 * b / 5 + (b ^ 2 + 2 * A) / 6 - 2 * A * b / 7 + A ^ 2 / 8 := by + have hid : (fun t : ℝ => t ^ 3 * (1 - b * t + A * t ^ 2) ^ 2) = + fun t => t ^ 3 - (2 * b) * t ^ 4 + (b ^ 2 + 2 * A) * t ^ 5 - + (2 * A * b) * t ^ 6 + A ^ 2 * t ^ 7 := by funext t; ring + rw [hid] + simp (disch := exact Continuous.intervalIntegrable (by fun_prop) _ _) only + [intervalIntegral.integral_add, intervalIntegral.integral_sub, + intervalIntegral.integral_const_mul, integral_pow] + norm_num + ring + +theorem raw_five_at_one : + scalarObstruction 5 1 (cubicPolarEnvelope 1) = 4104463139 / 7377920000 := by + have hQ (t : ℝ) : polarKernel 5 1 (cubicPolarEnvelope 1) t = + 1 - (2593 / 1920) * t + (3 / 5) * t ^ 2 := by + norm_num [polarKernel, cubicPolarEnvelope] + ring + simp only [scalarObstruction, show ((5 : ℝ) - 3) / 2 = 1 by norm_num, + Real.rpow_one, hQ, integral_quadratic] + norm_num [cubicPolarEnvelope] + +theorem raw_seven_at_one : + scalarObstruction 7 1 (cubicPolarEnvelope 1) = 280207725981353 / 489767341916160 := by + have hQ (t : ℝ) : polarKernel 7 1 (cubicPolarEnvelope 1) t = + 1 - (19687 / 13440) * t + (5 / 7) * t ^ 2 := by + norm_num [polarKernel, cubicPolarEnvelope] + ring + simp only [scalarObstruction, show ((7 : ℝ) - 3) / 2 = (2 : ℕ) by norm_num, + Real.rpow_natCast, hQ, integral_quadratic_sq] + norm_num [cubicPolarEnvelope] + +theorem raw_increases_5_7 : + scalarObstruction 5 1 (cubicPolarEnvelope 1) < + scalarObstruction 7 1 (cubicPolarEnvelope 1) := by + rw [raw_five_at_one, raw_seven_at_one] + norm_num + +theorem no_raw_antitone_start_le_5 {K : ℝ} (hK : K ≤ 5) : + ¬ AntitoneOn (fun m : ℝ => scalarObstruction m 1 (cubicPolarEnvelope 1)) + (Set.Ici K) := by + intro h + exact (not_le_of_gt raw_increases_5_7) + (h hK (hK.trans (by norm_num)) (by norm_num)) + +theorem raw_zero_not_regularized : + scalarObstruction 5 0 (cubicPolarEnvelope 0) = 1 / 10 ∧ + distillEBudget 5 - distillElementaryLoss 5 0 = 11 / 30 := by + rw [scalarObstruction_zero] + norm_num [distillEBudget, distillElementaryLoss, cubicPolarEnvelope] + +end LocalTotalBound diff --git a/tests/Localbudgets.lean b/tests/Localbudgets.lean deleted file mode 100644 index af24417..0000000 --- a/tests/Localbudgets.lean +++ /dev/null @@ -1,154 +0,0 @@ -import Sendov.Common.DistillationFinite -import Sendov.LargeDegree.DistillationTailBound - -namespace Localbudgets - -open Sendov - --- The m=60 formulas below are regression examples, not retained row consumers. --- Raw central obligations cover the zero flank, internal brackets and the --- point bracket at 17, with both integer and half-integer real exponents. -example : - distillKappa 5 (1 / 2) * (96 * (3 / 5) ^ 4 / - ((5 - 1) * (5 + 1) * (5 + 3) * (5 + 5) * (1 - distillNode 5 (3 / 4)) ^ 4)) ≤ - 101 / 500 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -example : - ((259 / 3125) * distillKappa 5 0) ^ 2 * (distillNode 5 (1 / 4)) ^ 2 ≤ - (191 / 1000 : ℝ) ^ 2 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -example : - ((421 / 3125) * distillKappa 5 (1 / 2)) ^ 2 * (cubicPolarEnvelope (3 / 4)) ^ 2 ≤ - (37 / 250 : ℝ) ^ 2 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -example : - ((259 / 3125) * distillKappa 6 (1 / 2)) ^ 2 * (distillNode 6 (3 / 4)) ^ 3 ≤ - (171 / 1000 : ℝ) ^ 2 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -example : - ((421 / 3125) * distillKappa 6 (3 / 4)) ^ 2 * (cubicPolarEnvelope 1) ^ 3 ≤ - (133 / 1000 : ℝ) ^ 2 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -example : - distillKappa 61 17 * (96 * (3 / 5) ^ 4 / - ((61 - 1) * (61 + 1) * (61 + 3) * (61 + 5) * (1 - distillNode 61 17) ^ 4)) ≤ - 57 / 250 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -example : - ((259 / 3125) * distillKappa 60 17) ^ 2 * (distillNode 60 17) ^ 57 ≤ - (57 / 1000 : ℝ) ^ 2 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -example : - ((421 / 3125) * distillKappa 60 17) ^ 2 * (cubicPolarEnvelope 17) ^ 57 ≤ - (81 / 250 : ℝ) ^ 2 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -example : - ((259 / 3125) * distillKappa 61 17) ^ 2 * (distillNode 61 17) ^ 58 ≤ - (13 / 250 : ℝ) ^ 2 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -example : - ((421 / 3125) * distillKappa 61 17) ^ 2 * (cubicPolarEnvelope 17) ^ 58 ≤ - (81 / 250 : ℝ) ^ 2 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - --- These closed numerical negations require no assumed sign identity or bound. --- Each also checks that the emitted arithmetic tactic rejects the false goal. -theorem wrong_unsquared_budget : ¬ ( - distillKappa 5 (1 / 2) * (96 * (3 / 5) ^ 4 / - ((5 - 1) * (5 + 1) * (5 + 3) * (5 + 5) * (1 - distillNode 5 (3 / 4)) ^ 4)) ≤ - 201 / 1000) := by - fail_if_success - have h : - distillKappa 5 (1 / 2) * (96 * (3 / 5) ^ 4 / - ((5 - 1) * (5 + 1) * (5 + 3) * (5 + 5) * - (1 - distillNode 5 (3 / 4)) ^ 4)) ≤ 201 / 1000 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -theorem wrong_zero_flank_budget : ¬ ( - ((259 / 3125) * distillKappa 5 0) ^ 2 * (distillNode 5 (1 / 4)) ^ 2 ≤ - (19 / 100 : ℝ) ^ 2) := by - fail_if_success - have h : - ((259 / 3125) * distillKappa 5 0) ^ 2 * (distillNode 5 (1 / 4)) ^ 2 ≤ - (19 / 100 : ℝ) ^ 2 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -theorem wrong_scale : ¬ ( - ((518 / 3125) * distillKappa 6 (1 / 2)) ^ 2 * (distillNode 6 (3 / 4)) ^ 3 ≤ - (171 / 1000 : ℝ) ^ 2) := by - fail_if_success - have h : - ((518 / 3125) * distillKappa 6 (1 / 2)) ^ 2 * (distillNode 6 (3 / 4)) ^ 3 ≤ - (171 / 1000 : ℝ) ^ 2 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -theorem wrong_internal_exponent : ¬ ( - ((259 / 3125) * distillKappa 6 (1 / 2)) ^ 2 * (distillNode 6 (3 / 4)) ^ 2 ≤ - (171 / 1000 : ℝ) ^ 2) := by - fail_if_success - have h : - ((259 / 3125) * distillKappa 6 (1 / 2)) ^ 2 * (distillNode 6 (3 / 4)) ^ 2 ≤ - (171 / 1000 : ℝ) ^ 2 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -theorem wrong_endpoint_exponent : ¬ ( - ((421 / 3125) * distillKappa 60 17) ^ 2 * (cubicPolarEnvelope 17) ^ 56 ≤ - (81 / 250 : ℝ) ^ 2) := by - fail_if_success - have h : - ((421 / 3125) * distillKappa 60 17) ^ 2 * (cubicPolarEnvelope 17) ^ 56 ≤ - (81 / 250 : ℝ) ^ 2 := by - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope] - -theorem wrong_row_total : - ¬ (distillEBudget 5 + 101 / 500 + 191 / 1000 + 37 / 250 ≤ 272 / 300) := by - norm_num only [distillEBudget] - -theorem wrong_rpow_exponent : ¬ (((6 : ℝ) - 3) / 2 = (2 : ℝ) / 2) := by norm_num - -example (n : ℕ) : ((0 : ℝ) ^ ((n : ℝ) / 2)) ^ 2 = (0 : ℝ) ^ n := - distillRpow_half_sq le_rfl n - -example : (2 : ℝ) * (1 / 4 : ℝ) ^ (((6 : ℝ) - 3) / 2) ≤ 1 / 4 := by - exact distillMulRpow_le_of_sq 3 (by norm_num) (by norm_num) (by norm_num) (by norm_num) - -example : (2 : ℝ) * (0 : ℝ) ^ (((6 : ℝ) - 3) / 2) ≤ 0 := by - exact distillMulRpow_le_of_sq 3 le_rfl le_rfl (by norm_num) (by norm_num) - -example : distillT1 5 0 ≤ 191 / 1000 := - CriticalRow5.component1 0 le_rfl (by norm_num) - -example (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 61 α ≤ 57 / 250 ∧ distillT1 61 α ≤ 13 / 250 ∧ - distillT2 61 α ≤ 81 / 250 := - ⟨CriticalRow61.component0 α hα hd, CriticalRow61.component1 α hα hd, - CriticalRow61.component2 α hα hd⟩ - -example : distillEBudget 61 + distillT0 61 17 + distillT1 61 17 + distillT2 61 17 < - 199 / 200 := - (distillFinite_61 17 (by norm_num) le_rfl).trans_lt distillFiniteBound_61 - -example {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) {α : ℝ} (hα : 0 ≤ α) - (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := - distillFinite_components hm hm60 hα hαm h17 - -example {m α : ℝ} (hm : 61 ≤ m) (hα : 0 ≤ α) (h17 : α ≤ 17) : - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := - distillComponents_lt_199_200 hm hα h17 - -end Localbudgets diff --git a/tests/Localcertificates.lean b/tests/Localcertificates.lean index e0f9121..92e7afa 100644 --- a/tests/Localcertificates.lean +++ b/tests/Localcertificates.lean @@ -1,9 +1,7 @@ import Sendov.Common.BernsteinList -import Sendov.Common.DistillationFinite namespace Localcertificates - -open BernsteinCert Sendov +open BernsteinCert example (cs : List ℕ) (i : ℕ) (x y : ℝ) : (coeffTree cs i).eval x y = x ^ i * (coeffTree cs 0).eval x y := @@ -21,7 +19,8 @@ example (x y : ℝ) : (coeffTree [7] 0).eval x y = 7 := by simp only [coeffTree_eval_cons, coeffTree_eval_nil, List.length_nil, Nat.cast_ofNat] ring1 -example (x y : ℝ) : (coeffTree [2, 0, 3] 0).eval x y = 2 * y ^ 2 + 3 * x ^ 2 := by +theorem full_identity (x : ℝ) : + 2 * (1 - x) ^ 2 + 3 * x ^ 2 = (coeffTree [2, 0, 3] 0).eval x (1 - x) := by simp only [coeffTree_eval_cons, coeffTree_eval_nil, List.length_cons, List.length_nil, Nat.cast_ofNat] ring1 @@ -36,130 +35,44 @@ example : (coeffTree [] 0).edge true = false ∧ example : (coeffTree [0, 1] 0).edge true = false ∧ (coeffTree [1, 0] 0).edge false = false := by decide -example (x : ℝ) (hx : x ∈ Set.Icc 0 1) : 0 < x ^ 2 + (1 - x) ^ 2 := by - refine coeffs_pos [1, 0, 1] (lo := 0) (hi := 1) (s := 1) - (by norm_num) (by norm_num) hx (by decide) (by decide) ?_ - simp only [coeffTree_eval_cons, coeffTree_eval_nil, - List.length_cons, List.length_nil] - ring1 +example (x : ℝ) (hx : x ∈ Set.Icc 0 1) : 0 < 2 * (1 - x) ^ 2 + 3 * x ^ 2 := + coeffs_pos [2, 0, 3] (lo := 0) (hi := 1) (s := 1) + (by norm_num) (by norm_num) hx (by decide) (by decide) + (by simpa using full_identity x) -theorem critical0_identity (x : ℝ) : - 117649 * -distillCritical0 5 x = - (coeffTree [3667054680, 133443712440, 939063315600, 3006831250944, - 5267101731840, 5254197895040, 2819499598080, 635350144000] 0).eval - (x - 3 / 4) (5 / 2 - x) := by - unfold distillCritical0 - simp only [coeffTree_eval_cons, coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 +-- Each negation concerns the full identity with the same inputs on both sides. +-- The interior coefficient mutation even preserves both endpoint values. +example : ¬ (∀ x : ℝ, 2 * (1 - x) ^ 2 + 3 * x ^ 2 = + (coeffTree [2, 1, 3] 0).eval x (1 - x)) := by + intro h + have hq := h (1 / 2) + norm_num [coeffTree_eval_cons, coeffTree_eval_nil] at hq -theorem critical1_identity (x : ℝ) : - 4782969 * distillCritical1 5 x = - (coeffTree [12259473776, 1574964910352, 13907088807648, 52400775960064, - 105639358896640, 119707352275200, 72226624540160, 18128870144000] 0).eval - (x - 1 / 4) (5 / 2 - x) := by - unfold distillCritical1 - simp only [coeffTree_eval_cons, coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 +example : ¬ (∀ x : ℝ, 2 * (2 * (1 - x) ^ 2 + 3 * x ^ 2) = + (coeffTree [2, 0, 3] 0).eval x (1 - x)) := by + intro h + have hq := h 0 + norm_num [coeffTree_eval_cons, coeffTree_eval_nil] at hq -theorem critical2_identity (x : ℝ) : - -distillCritical2 5 x = - (coeffTree [129600, 462240, 574680, 277028, 34872] 0).eval (x - 0) (1 / 2 - x) := by - unfold distillCritical2 - simp only [coeffTree_eval_cons, coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 +example : ¬ (∀ x : ℝ, 2 * (1 - x) ^ 2 + 3 * x ^ 2 = + (coeffTree [3, 0, 2] 0).eval x (1 - x)) := by + intro h + have hq := h 0 + norm_num [coeffTree_eval_cons, coeffTree_eval_nil] at hq + +example : ¬ (∀ x : ℝ, 2 * (1 - x) ^ 2 + 3 * x ^ 2 = + (coeffTree [2, 0] 0).eval x (1 - x)) := by + intro h + have hq := h 1 + norm_num [coeffTree_eval_cons, coeffTree_eval_nil] at hq -example (x : ℝ) (hx : x ∈ Set.Icc 0 (1 / 2)) : 0 < -distillCritical2 5 x := by - exact coeffs_pos [129600, 462240, 574680, 277028, 34872] - (lo := 0) (hi := 1 / 2) (s := 1) (by norm_num) (by norm_num) - hx (by decide) (by decide) (by simpa only [one_mul] using critical2_identity x) - --- A changed interior coefficient preserves both endpoint values and supports. --- The complete identity must still fail, not merely a frontend shape check. -example (x : ℝ) : x = x := by - fail_if_success - have h : -distillCritical2 5 x = - (coeffTree [129600, 462240, 574681, 277028, 34872] 0).eval - (x - 0) (1 / 2 - x) := by - unfold distillCritical2 - simp only [coeffTree_eval_cons, coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - rfl - -example : (coeffTree [129600, 462240, 574681, 277028, 34872] 0).edge true = true ∧ - (coeffTree [129600, 462240, 574681, 277028, 34872] 0).edge false = true := by decide - -example : ¬ (∀ x : ℝ, -distillCritical2 5 x = - (coeffTree [129600, 462240, 574681, 277028, 34872] 0).eval (x - 0) (1 / 2 - x)) := by +example : ¬ (∀ x : ℝ, 2 * (1 - x) ^ 2 + 3 * x ^ 2 = + (coeffTree [2, 0, 3] 0).eval x (2 - x)) := by intro h - have hq := h (1 / 4) - norm_num [distillCritical2, coeffTree, Cert.eval] at hq - -example (x : ℝ) : x = x := by - fail_if_success - have h : 2 * -distillCritical2 5 x = - (coeffTree [129600, 462240, 574680, 277028, 34872] 0).eval - (x - 0) (1 / 2 - x) := by - unfold distillCritical2 - simp only [coeffTree_eval_cons, coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - fail_if_success - have h : -distillCritical2 5 x = - (coeffTree [34872, 277028, 574680, 462240, 129600] 0).eval - (x - 0) (1 / 2 - x) := by - unfold distillCritical2 - simp only [coeffTree_eval_cons, coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - fail_if_success - have h : -distillCritical2 5 x = - (coeffTree [129600, 462240, 574680, 277028] 0).eval (x - 0) (1 / 2 - x) := by - unfold distillCritical2 - simp only [coeffTree_eval_cons, coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - fail_if_success - have h : -distillCritical2 5 x = - (coeffTree [129600, 462240, 574680, 277028, 34872] 0).eval (x - 0) (3 / 4 - x) := by - unfold distillCritical2 - simp only [coeffTree_eval_cons, coeffTree_eval_nil, - List.length_cons, List.length_nil, Nat.cast_ofNat] - ring1 - rfl + have hq := h 0 + norm_num [coeffTree_eval_cons, coeffTree_eval_nil] at hq example (x y : ℝ) : (x + y) ^ 2 = y ^ 2 + 2 * x * y + x ^ 2 := by bernstein_ring x y -example (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 5 / 2) : - distillT1 5 α ≤ 191 / 1000 := - CriticalRow5.component1 α hα hd - -example (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT1 46 α ≤ 153 / 1000 := - CriticalRow46.component1 α hα hd - -example (α : ℝ) (hα : 0 ≤ α) (hd : α ≤ 17) : - distillT0 61 α ≤ 57 / 250 ∧ distillT1 61 α ≤ 13 / 250 ∧ - distillT2 61 α ≤ 81 / 250 := - ⟨CriticalRow61.component0 α hα hd, CriticalRow61.component1 α hα hd, - CriticalRow61.component2 α hα hd⟩ - -example {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) {α : ℝ} (hα : 0 ≤ α) - (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := - distillFinite_components hm hm60 hα hαm h17 - -example {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) {α : ℝ} (hα : 0 < α) - (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : - scalarObstruction m α (cubicPolarEnvelope α) < 199 / 200 := - distillFinite_scalar hm hm60 hα hαm h17 - -example : distillEBudget 61 + distillT0 61 17 + distillT1 61 17 + distillT2 61 17 < - 199 / 200 := - (distillFinite_61 17 (by norm_num) le_rfl).trans_lt distillFiniteBound_61 - end Localcertificates diff --git a/tests/Localcommon.lean b/tests/Localcommon.lean index 556d5fc..8d75461 100644 --- a/tests/Localcommon.lean +++ b/tests/Localcommon.lean @@ -1,4 +1,3 @@ -import Sendov.Common.DistillationCriticalFinite import Sendov.Common.DistillationHyperbolic import Sendov.Common.DistillationBounds @@ -46,42 +45,20 @@ example {m : ℝ} (hm : 5 ≤ m) : ContinuousWithinAt (distillT2 m) (Set.Icc 0 (m / 2)) (m / 2) := distillT2_continuousOn hm (m / 2) ⟨by linarith, le_rfl⟩ -example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : - deriv (distillT0 m) α ≤ 0 ↔ distillCritical0 m α ≤ 0 := - distillT0_deriv_nonpos_iff hm hα hαm - -example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : - deriv (distillT1 m) α ≤ 0 ↔ 0 ≤ distillCritical1 m α := - distillT1_deriv_nonpos_iff hm hα hαm - -example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : - deriv (distillT2 m) α ≤ 0 ↔ 0 ≤ distillCritical2 m α := - distillT2_deriv_nonpos_iff hm hα hαm - -- Neither square recovery nor the zero-base case requires a nonnegative coefficient. example {a c : ℝ} (hc : 0 ≤ c) (hsq : a ^ 2 ≤ c ^ 2) : a * (0 : ℝ) ^ (((3 : ℝ) - 3) / 2) ≤ c := by - apply distillMulRpow_le_of_sq 0 (by norm_num) hc (by norm_num) - simpa only [pow_zero, mul_one] using hsq + norm_num only [sub_self, zero_div, Real.rpow_zero, mul_one] + exact le_of_sq_le_sq hsq hc example {a c : ℝ} (hc : 0 ≤ c) : a * (0 : ℝ) ^ (((4 : ℝ) - 3) / 2) ≤ c := by - apply distillMulRpow_le_of_sq 1 (by norm_num) hc (by norm_num) - simpa only [pow_one, mul_zero] using sq_nonneg c - -example {f : ℝ → ℝ} {b : ℝ} (hc : ContinuousOn f (Set.Icc 0 0)) - (hb : f 0 ≤ b) : f 0 ≤ b := by - apply distillPeak_le (l := 0) (r := 0) (d := 0) le_rfl le_rfl le_rfl hc - · simp - · simp - · simp - · simpa using hb - · exact ⟨le_rfl, le_rfl⟩ + simpa only [Real.zero_rpow (by norm_num : ((4 : ℝ) - 3) / 2 ≠ 0), mul_zero] using hc example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α ≤ m) : scalarObstruction m α (cubicPolarEnvelope α) ≤ - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α := - distillScalar_le_majorant hm hα hαm + distillElementary m α + distillT0 m α + distillT1 m α + distillT2 m α := + distillScalar_le_elementary_components hm hα hαm example : Filter.Tendsto (fun z => Real.sinh z / z) (nhdsWithin 0 {(0 : ℝ)}ᶜ) (nhds 1) := by @@ -95,17 +72,6 @@ example : Real.log (Real.sinh 10 / 10) ≤ (7 / 8 : ℝ) * (Real.sqrt (9 + (8 / 7 : ℝ) * 10 ^ 2) - 3) := DistillationHyperbolic.log_sinh_div_le (by norm_num) le_rfl -example {m : ℝ} (hm : 61 ≤ m) : distillT2 m 0 = 0 := distillT2_zero hm - -example {m : ℝ} (hm : 61 ≤ m) : - distillEBudget m + distillT0 m 0 + distillT1 m 0 + distillT2 m 0 ≤ - distillEBudget 61 + distillT0 61 0 + distillT1 61 0 + distillT2 61 0 := - distillComponents_le_61 hm le_rfl (by norm_num) - -example {m : ℝ} (hm : 61 ≤ m) : - scalarObstruction m 17 (cubicPolarEnvelope 17) < 199 / 200 := - distillScalar_lt_199_200 hm (by norm_num) le_rfl - example {n : ℕ} (hn : 6 ≤ n) {α : ℝ} (hα : 0 < α) (h17 : α ≤ 17) (hhalf : 2 * α ≤ M n) : scalarObstruction (M n) α (cubicPolarEnvelope α) < 1 := diff --git a/tests/Localgenerators.lean b/tests/Localgenerators.lean index 4208386..ae2baf3 100644 --- a/tests/Localgenerators.lean +++ b/tests/Localgenerators.lean @@ -1,5 +1,4 @@ import Sendov.Common.BernsteinList -import Sendov.Common.DistillationFinite import Sendov.Common.Sinh namespace Localgenerators @@ -60,24 +59,6 @@ example (x y : ℝ) : y - x = -1 * x + y := by fail_if_success bernstein_ring x y ring -example {m : ℕ} (hm : 5 ≤ m) (hm60 : m ≤ 60) {α : ℝ} (hα : 0 ≤ α) - (hαm : α ≤ (m : ℝ) / 2) (h17 : α ≤ 17) : - Sendov.distillEBudget m + Sendov.distillT0 m α + Sendov.distillT1 m α + - Sendov.distillT2 m α < 199 / 200 := - Sendov.distillFinite_components hm hm60 hα hαm h17 - -example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : - Sendov.distillT0 61 α ≤ 57 / 250 := - Sendov.CriticalRow61.component0 α hα h17 - -example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : - Sendov.distillT1 61 α ≤ 13 / 250 := - Sendov.CriticalRow61.component1 α hα h17 - -example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : - Sendov.distillT2 61 α ≤ 81 / 250 := - Sendov.CriticalRow61.component2 α hα h17 - example : Real.sinh 0 ≤ 0 * Real.exp (Real.sqrt (0 ^ 2 + 9) - 3) := Sendov.sinh_le_mul_exp le_rfl diff --git a/tests/Localhotspots.lean b/tests/Localhotspots.lean index 347a54b..4cedc84 100644 --- a/tests/Localhotspots.lean +++ b/tests/Localhotspots.lean @@ -1,5 +1,5 @@ import Sendov.Reduction.CubicScalar -import Sendov.Common.DistillationCriticalFinite +import Sendov.Common.DistillationRegularity open Sendov Real @@ -37,22 +37,6 @@ example {Q p : ℝ} (hQ : 0 < Q) (hp : 1 ≤ p) : (0 + Q) ^ p ≤ (0 : ℝ) ^ p + p * Q * (0 + Q) ^ (p - 1) := rpow_add_le_of_one_le le_rfl (by simpa using hQ) hp --- All three identities are symbolic polynomial equalities, not evaluations. -example (m α : ℝ) : - distillCritical0 m α = distillK m α * distillD m α + - 4 * (m - 2 * α) * distillN α * distillRp m α := - distillCritical0_eq m α - -example (m α : ℝ) : - distillCritical1 m α = -2 * distillK m α * distillB m α - - (m - 3) * (m - 2 * α) * distillN α * distillRp m α := - distillCritical1_eq m α - -example (m α : ℝ) : - distillCritical2 m α = -2 * α * distillK m α - - (m - 3) * (m - 2 * α) * distillL α := - distillCritical2_eq m α - example (α : ℝ) : distillN α = 29 * α ^ 2 + 180 * α + 270 := rfl example (x : ℝ) : @@ -63,44 +47,6 @@ example (x : ℝ) : DistillationHyperbolic.D x = 55 * x ^ 8 + 25740 * x ^ 6 + 2837835 * x ^ 4 + 91891800 * x ^ 2 + 654729075 := rfl -example {m : ℝ} (hm : 0 < m) : - distillD m 0 = 50 * m * (0 + 3) ^ 3 * (1 - distillNode m 0) := - distillD_eq hm le_rfl - -example {m α : ℝ} (hm : 0 < m) (hα : 0 ≤ α) : - distillD m α = 50 * m * (α + 3) ^ 3 * (1 - distillNode m α) := - distillD_eq hm hα - -example {m : ℝ} (hm : 0 < m) : - HasDerivAt (distillKappa m) - (distillKappa m 0 * (distillK m 0 / ((0 + 3) * (m - 2 * 0) * distillN 0))) 0 := - hasDerivAt_distillKappa le_rfl (by simpa using hm) - -example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : - HasDerivAt (distillT0 m) - (distillT0 m α * (distillCritical0 m α / - ((α + 3) * (m - 2 * α) * distillN α * distillD m α))) α := - hasDerivAt_distillT0 hm hα hαm - -example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : - HasDerivAt (distillT1 m) - (distillT1 m α * (-distillCritical1 m α / - (2 * (α + 3) * (m - 2 * α) * distillN α * distillB m α))) α := - hasDerivAt_distillT1 hm hα hαm - -example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : - HasDerivAt (distillT2 m) - (distillT2 m α * (-distillCritical2 m α / - (2 * α * (α + 3) * (m - 2 * α) * distillN α))) α := - hasDerivAt_distillT2 hm hα hαm - -example {m α : ℝ} (hm : 5 ≤ m) (hα : 0 < α) (hαm : 2 * α < m) : - (deriv (distillT0 m) α ≤ 0 ↔ distillCritical0 m α ≤ 0) ∧ - (deriv (distillT1 m) α ≤ 0 ↔ 0 ≤ distillCritical1 m α) ∧ - (deriv (distillT2 m) α ≤ 0 ↔ 0 ≤ distillCritical2 m α) := - ⟨distillT0_deriv_nonpos_iff hm hα hαm, distillT1_deriv_nonpos_iff hm hα hαm, - distillT2_deriv_nonpos_iff hm hα hαm⟩ - example {m : ℝ} (hm : 5 ≤ m) : ContinuousWithinAt (distillT0 m) (Set.Icc 0 (m / 2)) 0 := distillT0_continuousOn hm 0 ⟨le_rfl, by linarith⟩ diff --git a/tests/Localmathematics.lean b/tests/Localmathematics.lean deleted file mode 100644 index fb3285b..0000000 --- a/tests/Localmathematics.lean +++ /dev/null @@ -1,59 +0,0 @@ -import Sendov.LargeDegree.DistillationTail - -namespace MathematicsFeasibility -open Sendov - -theorem decay_base : cubicPolarEnvelope 17 ≤ (21 / 22 : ℝ) ^ 4 := by - norm_num [cubicPolarEnvelope] - -theorem log_decay {z : ℝ} (hz : 0 < z) (hcap : z ≤ (21 / 22 : ℝ) ^ 4) : - Real.log z / 2 ≤ -(1 / 11) := by - have hlog := Real.log_le_log hz hcap - rw [Real.log_pow] at hlog - have hlinear := Real.log_le_sub_one_of_pos (by norm_num : (0 : ℝ) < 21 / 22) - norm_num only [Nat.cast_ofNat] at hlog - linarith - -theorem start61 : (1 / (61 - 1) + 2 / (61 - 34) : ℝ) ≤ 1 / 11 := by - norm_num - -theorem start60_not_this_certificate : - ¬ (1 / (60 - 1) + 2 / (60 - 34) : ℝ) ≤ 1 / 11 := by norm_num - -example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : - AntitoneOn (fun m : ℝ => distillKappa m α * (5 / 6 : ℝ) ^ ((m - 3) / 2)) - (Set.Ici 64) := - distillKappa_rpow_antitone_on (by norm_num) (by norm_num) - hα h17 (by norm_num) le_rfl - -example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : - AntitoneOn (fun m : ℝ => distillKappa m α * (0 : ℝ) ^ ((m - 3) / 2)) - (Set.Ici 61) := - distillKappa_rpow_antitone_of_pow 4 (by norm_num) (by norm_num) - hα h17 le_rfl (by norm_num : (0 : ℝ) < 21 / 22) (by norm_num) - -theorem zero34 : distillT2 34 17 = 0 := by - norm_num [distillT2, distillKappa] - -theorem positive35 : 0 < distillT2 35 17 := by - have hk : 0 < distillKappa 35 17 := by norm_num [distillKappa, distillRatio] - have he : 0 < cubicPolarEnvelope 17 := by norm_num [cubicPolarEnvelope] - exact mul_pos (mul_pos (by norm_num) hk) (Real.rpow_pos_of_pos he _) - -theorem increase59_61 : distillT2 59 17 < distillT2 61 17 := by - norm_num [distillT2, distillKappa, distillRatio, cubicPolarEnvelope, - show ((59 : ℝ) - 3) / 2 = (28 : ℕ) by norm_num, - show ((61 : ℝ) - 3) / 2 = (29 : ℕ) by norm_num, Real.rpow_natCast] - -theorem no_antitone_start_le_59 {K : ℝ} (hK : K ≤ 59) : - ¬ AntitoneOn (fun m : ℝ => distillT2 m 17) (Set.Ici K) := by - intro h - exact (not_le_of_gt increase59_61) - (h hK (hK.trans (by norm_num)) (by norm_num)) - -example : 2 * (17 : ℝ) ≤ 34 ∧ 2 * (17 : ℝ) ≤ 35 ∧ - 2 * (17 : ℝ) ≤ 59 ∧ 2 * (17 : ℝ) ≤ 61 := by norm_num - -#print axioms no_antitone_start_le_59 -#print axioms log_decay -end MathematicsFeasibility diff --git a/tests/Localranges.lean b/tests/Localranges.lean deleted file mode 100644 index 3ec7306..0000000 --- a/tests/Localranges.lean +++ /dev/null @@ -1,54 +0,0 @@ -import Sendov.Common.DistillationBounds - -open Sendov - -example {m : ℝ} (hm : m ∈ Set.Icc 55 61) : - distillEBudget m + distillT0 m 0 + distillT1 m 0 + distillT2 m 0 < 199 / 200 := - distillComponents_interval_55_61 hm le_rfl (by norm_num) - -example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : - distillEBudget 55 + distillT0 55 α + distillT1 55 α + distillT2 55 α < 199 / 200 := - distillComponents_interval_55_61 (by norm_num) hα h17 - -example : - distillEBudget (111 / 2) + distillT0 (111 / 2) 17 + - distillT1 (111 / 2) 17 + distillT2 (111 / 2) 17 < 199 / 200 := - distillComponents_interval_55_61 (by norm_num) (by norm_num) le_rfl - -example {α : ℝ} (hα : 0 ≤ α) (h17 : α ≤ 17) : - distillEBudget 61 + distillT0 61 α + distillT1 61 α + distillT2 61 α < 199 / 200 := - distillComponents_interval_55_61 (by norm_num) hα h17 - -example {m : ℕ} (hm : 56 ≤ m) (h60 : m ≤ 60) {α : ℝ} - (hα : 0 ≤ α) (h17 : α ≤ 17) : - distillEBudget m + distillT0 m α + distillT1 m α + distillT2 m α < 199 / 200 := by - exact distillFinite_components (by omega) h60 hα - (by - have hmR : (56 : ℝ) ≤ m := by exact_mod_cast hm - linarith) h17 - -example {n : ℕ} (hn : 6 ≤ n) {α : ℝ} (hα : 0 < α) (h17 : α ≤ 17) - (hhalf : 2 * α ≤ M n) : - scalarObstruction (M n) α (cubicPolarEnvelope α) < 1 := - distillScalar_lt_one hn hα h17 hhalf - -example : scalarObstruction 5 (5 / 2) (cubicPolarEnvelope (5 / 2)) < 199 / 200 := by - exact distillFinite_scalar (m := 5) (by norm_num) (by norm_num) - (by norm_num) (by norm_num) (by norm_num) - -example {m : ℝ} (hm : m ∈ Set.Icc 55 61) : - (distillKappa m 0 * (0 : ℝ) ^ ((m - 3) / 2)) * - (1 - 95 / 4158 * (61 - 55)) ≤ - distillKappa 55 0 * (0 : ℝ) ^ (((55 : ℝ) - 3) / 2) := - distillKappa_rpow_interval (ε := 95 / 4158) 4 (by norm_num) hm (by norm_num) (by norm_num) - (by norm_num) le_rfl (by norm_num) le_rfl - (by norm_num : (0 : ℝ) < 21 / 22) (by norm_num) - -example : ¬ (54 : ℝ) ∈ Set.Icc 55 61 := by norm_num -example : ¬ (123 / 2 : ℝ) ∈ Set.Icc 55 61 := by norm_num -example : ¬ (18 : ℝ) ≤ 17 := by norm_num - -example : (1 / 54 + 2 / 21 : ℝ) > 1 / 11 := by norm_num -example : (43 / 165 + 31 / 125 + - (91 / 1000) / (1 - 331 / 37800 * 7) + - (33 / 100) / (1 - 95 / 4158 * 7) : ℝ) > 199 / 200 := by norm_num diff --git a/tests/NoFiniteRows.lean b/tests/NoFiniteRows.lean new file mode 100644 index 0000000..263f748 --- /dev/null +++ b/tests/NoFiniteRows.lean @@ -0,0 +1,93 @@ +import Solution + +/-! Full proof-value traversal: imported and private constants are not pruned. -/ +open Sendov + +example {n : ℕ} (hn : 6 ≤ n) {α : ℝ} (hα : 0 < α) + (h17 : α ≤ 17) (hhalf : 2 * α ≤ M n) : + scalarObstruction (M n) α (cubicPolarEnvelope α) < 1 := + distillScalar_lt_one hn hα h17 hhalf + +example {m : ℝ} (hm : 5 ≤ m) : + scalarObstruction m (7 / 5) (cubicPolarEnvelope (7 / 5)) < 1 := + distillScalar_lt_one_real hm (by norm_num) (by norm_num) (by linarith) + +example {m : ℝ} (hm : 5 ≤ m) : + scalarObstruction m 2 (cubicPolarEnvelope 2) < 1 := + distillScalar_lt_one_real hm (by norm_num) (by norm_num) (by linarith) + +example {m : ℝ} (hm : 34 ≤ m) : + scalarObstruction m 17 (cubicPolarEnvelope 17) < 1 := + distillScalar_lt_one_real (by linarith) (by norm_num) (by norm_num) (by linarith) + +example {α : ℝ} (hα : 5 / 2 ≤ α) (h17 : α ≤ 17) : + scalarObstruction (2 * α) α (cubicPolarEnvelope α) < 1 := + distillScalar_lt_one_real (by linarith) (by linarith) h17 le_rfl + +example : scalarObstruction (11 / 2) (19 / 10) (cubicPolarEnvelope (19 / 10)) < 1 := + distillScalar_lt_one_real (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +example (m : ℝ) : scalarObstruction m 0 (cubicPolarEnvelope 0) = 1 / (2 * m) := + scalarObstruction_zero m + +example : ¬ 2 * (17 : ℝ) ≤ 5 := by norm_num + +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + let retiredModule := fun (name : Name) => + let text := name.toString + text.startsWith "Sendov.DistillationFinite." || + text.startsWith "Sendov.LargeDegree." || + #["Sendov.Common.DistillationCritical", "Sendov.Common.DistillationCriticalFinite", + "Sendov.Common.DistillationFinite", "Sendov.Common.DistillationMajorant"].contains text + for name in env.header.moduleNames do + if retiredModule name then throwError "retired imported module: {name}" + for root in #[`Sendov.distillScalar_lt_one_real, `Sendov.distillScalar_lt_one, + `SendovConjecture.sendov, `SendovConjecture.phelps_rodriguez] do + let mut pending := [root] + let mut visited : Std.HashSet Name := {} + while !pending.isEmpty do + let name := pending.head! + pending := pending.tail! + unless visited.contains name do + visited := visited.insert name + let some info := env.find? name | throwError "missing closure declaration {name}" + if let some value := info.value? (allowOpaque := true) then + for used in value.getUsedConstants do + pending := used :: pending + for name in visited do + if let some idx := env.getModuleIdxFor? name then + let owner := env.header.moduleNames[idx.toNat]! + if retiredModule owner then + throwError "retired proof-value owner: {root} -> {name} in {owner}" + let text := name.toString + for forbidden in #["CriticalRow", "distillFinite", "DistillationFinite", + "DistillationCritical", "distillCritical", "DistillationTail", + "interval_55_61", "_le_61", "_antitone_55", "distillComponents_lt_199_200", + "distillScalar_lt_199_200", "distillKappa_rpow_interval", + "distillKappa_rpow_antitone", "distillT0_le_of_critical", + "distillT1_le_of_critical", "distillT2_le_of_critical", + "distillScalar_le_components", "distillScalar_le_majorant", + "hasDerivAt_distillTotal", "distillScalar_lt_one_alpha_seventeen", + "distillFiniteTailBase", "distillComponents_le_64", "_le_81", + "distillScalar_lt_two_thirds", "distillComponents_lt_two_thirds"] do + if (text.splitOn forbidden).length > 1 then + throwError "retired proof-value dependency: {root} -> {name}" + for target in #[`Sendov.distillScalar_lt_one_small_alpha, + `Sendov.distillScalar_lt_one_middle_alpha, `Sendov.distillScalar_lt_one_peak_strip, + `Sendov.distillScalar_le_total_sub_loss, + `Sendov.distillScalar_le_elementary_components, + `Sendov.PeakClosure.gap1_identity, + `Sendov.PeakClosure.LowHomogeneous.gapH_identity, + `Sendov.PeakClosure.HighHomogeneous.gapH_identity] do + unless visited.contains target do + throwError "missing positive proof consumption: {root} -> {target}" + logInfo m!"NO_ROWS_POSITIVE {root} -> {target}" + let axioms ← withEnv env <| Lean.collectAxioms root + unless axioms.all (#[``propext, ``Classical.choice, ``Quot.sound].contains) do + throwError "unexpected axioms for {root}: {axioms}" + logInfo m!"NO_ROWS_CLOSURE {root}: {visited.size}; axioms {axioms}" + logInfo m!"NO_ROWS_PROJECT_VALUES {root}: {(visited.toArray.filter fun n => + n.toString.startsWith "Sendov." || n.toString.startsWith "_private.Sendov.").map + Name.toString}" diff --git a/tests/expected.json b/tests/expected.json index d56ff96..dcd290d 100644 --- a/tests/expected.json +++ b/tests/expected.json @@ -1,16 +1,4 @@ { - "distillation": { - "Sendov/Common/DistillationFinite.lean": "51879329cdb23b7dc2e4d94d94eb5f974c17bff183ab56addb2fdebeae463fb7", - "Sendov/DistillationFinite/Rows13_20.lean": "7211b2822f8f262eae422406ce57c48c8f9e566a0961fcdc3fad2812e7fedad4", - "Sendov/DistillationFinite/Rows21_28.lean": "16cc1f9657beb98a7bdb2b46a423d4b66e97ab154899335b0e8680873c36a00e", - "Sendov/DistillationFinite/Rows29_36.lean": "339320274f3012e878e90f27338a8e1a9bee8240368ab2281d12b7afc11c4fde", - "Sendov/DistillationFinite/Rows37_44.lean": "653824c8891543bf6a684048e9a9672accc87c19bc52f55e8dbfa9b9d8579114", - "Sendov/DistillationFinite/Rows45_52.lean": "c41366a1bc680c09367945b56eb00f791620c583f1c9c827d0ddd1dfdd33b0f2", - "Sendov/DistillationFinite/Rows53_55.lean": "428b635c53f831d4ec2e7a875d58523846302ca89f3eefeaccae87ee28ed6a59", - "Sendov/DistillationFinite/Rows5_12.lean": "7c70b26f98e65cffed59178b9ac6d91c683e10a47ec9369f58df4b25d15c7602", - "Sendov/DistillationFinite/Rows61_61.lean": "3a2916ff4e15b4cf31fb4e87d16b611d499f3a8ce1399a0ddb0195406b3f9f2c" - }, - "table_sha256": "d20fef86d64459e54c2e335d9a425451b2f87822acbf6a5dd09ce2d633731183", "sinh": { "sha256": "d04df2219415aa8e4f838c9c1b246b35af087e4ba41d4c449f95fe0f436c4acb", "bytes": 15024 diff --git a/tests/test_alpha_certificates.py b/tests/test_alpha_certificates.py new file mode 100644 index 0000000..10930c7 --- /dev/null +++ b/tests/test_alpha_certificates.py @@ -0,0 +1,102 @@ +"""Reject mutations of the complete retained identities, using the real Lean frontend.""" +import json +import hashlib +import os +from pathlib import Path +import re +import subprocess +import tempfile +import unittest + +ROOT = Path(__file__).resolve().parents[1] +COMMON = ROOT / 'Sendov/Common' + + +def certificate_prefix(file, namespace, coefficient_name, identity): + text = (COMMON / file).read_text() + start = text.index(f'namespace {namespace}\n') + end = text.index('\n\n', text.index('\n ring1', text.index(identity, start))) + prefix = text[:end] + # Retain the entire polynomial identity, factor definitions and coefficient list. + opened = [] + for line in prefix.splitlines(): + if line.startswith('namespace '): + opened.append(line.removeprefix('namespace ')) + elif line.startswith('end '): + assert opened.pop() == line.removeprefix('end ') + prefix += '\n\n' + ''.join(f'end {name}\n' for name in reversed(opened)) + pattern = rf'private def {coefficient_name} : List \u2115 := \[(.*?)\]' + matches = list(re.finditer(pattern, prefix, re.S)) + match = next(m for m in matches if m.start() > start) + return prefix, match + + +class AlphaCertificateTests(unittest.TestCase): + def lean(self, source, label): + with tempfile.TemporaryDirectory(prefix='alpha-identity-', dir=ROOT / '.lake') as tmp: + path = Path(tmp) / 'Identity.lean' + path.write_text(source) + result = subprocess.run( + ['lake', 'env', 'lean', '-DwarningAsError=true', str(path)], + cwd=ROOT, text=True, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, + timeout=180) + if destination := os.environ.get('SENDOV_ALPHA_LOG_DIR'): + log = Path(destination) + log.mkdir(parents=True, exist_ok=True) + (log / (label + '.log')).write_text(result.stdout) + (log / (label + '.lean')).write_text(source) + (log / (label + '.json')).write_text(json.dumps({ + 'exit_code': result.returncode, + 'source_sha256': hashlib.sha256(source.encode()).hexdigest(), + })) + return result + + def assert_identity_rejected(self, source, label): + result = self.lean(source, label) + self.assertNotEqual(result.returncode, 0, result.stdout) + errors = [line for line in result.stdout.splitlines() if ': error:' in line] + self.assertEqual(len(errors), 1, result.stdout) + self.assertIn('error: ring failed, ring expressions not equal', errors[0]) + for unexpected in ['unknown identifier', 'Unknown identifier', 'failed to synthesize', + 'maximum recursion depth', 'maximum number of heartbeats', + 'declaration uses', 'error: linter', 'unknown module']: + self.assertNotIn(unexpected, result.stdout) + + def test_all_three_full_identities_reject_interior_coefficient_mutation(self): + for label, file, namespace, name, identity, length in [ + ('first', 'DistillationPeakFirst.lean', 'Sendov.PeakClosure', + 'gap1Coefficients', 'private lemma gap1H_identity', 54), + ('low', 'DistillationPeakRest.lean', 'LowHomogeneous', + 'coefficients', 'lemma gapH_identity', 48), + ('high', 'DistillationPeakRest.lean', 'HighHomogeneous', + 'coefficients', 'lemma gapH_identity', 48), + ]: + with self.subTest(certificate=label): + source, match = certificate_prefix(file, namespace, name, identity) + good = self.lean(source, label + '-control') + self.assertEqual(good.returncode, 0, good.stdout) + entries = list(re.finditer(r'0x[0-9a-fA-F]+|\d+', match.group(1))) + self.assertEqual(len(entries), length) + selected = entries[length // 2] + before = match.start(1) + selected.start() + after = match.start(1) + selected.end() + value = int(selected.group(), 16 if selected.group().startswith('0x') else 10) + replacement = hex(value + 1) if selected.group().startswith('0x') else str(value + 1) + mutant = source[:before] + replacement + source[after:] + self.assert_identity_rejected(mutant, label + '-wrong-coefficient') + + def test_complete_factor_identity_rejects_wrong_scale_and_interval(self): + text = (COMMON / 'DistillationPeakFirst.lean').read_text() + end = text.index('\n\n', text.index('\n ring1', text.index('private lemma SH_eval'))) + source = text[:end] + '\n\nend Sendov.PeakClosure\n' + control = self.lean(source, 'factor-control') + self.assertEqual(control.returncode, 0, control.stdout) + self.assertIn('(15 : \u211d) ^ 1', source) + self.assert_identity_rejected(source.replace('(15 : \u211d) ^ 1', '(16 : \u211d) ^ 1'), + 'factor-wrong-scale') + self.assert_identity_rejected(source.replace('((17) - a)', '((18) - a)'), + 'factor-wrong-interval') + + +if __name__ == '__main__': + unittest.main() diff --git a/tests/test_axiom_audit.py b/tests/test_axiom_audit.py index 6ad1762..703e720 100644 --- a/tests/test_axiom_audit.py +++ b/tests/test_axiom_audit.py @@ -16,28 +16,35 @@ TARGETS = [ 'SendovConjecture.sendov', 'SendovConjecture.phelps_rodriguez', - 'Sendov.distillFinite_components', - 'Sendov.distillFinite_scalar', - 'Sendov.distillFinite_61', - 'Sendov.distillFiniteBound_61', - 'Sendov.distillComponents_le_61', - 'Sendov.distillT2_zero', - 'Sendov.distillComponents_lt_199_200', - 'Sendov.distillScalar_lt_199_200', + 'Sendov.distillScalar_lt_one_real', 'Sendov.distillScalar_lt_one', 'Sendov.polar_origin_incompatible', - 'Sendov.distillKappa_rpow_interval', - 'Sendov.distillT0_antitone_55', - 'Sendov.distillComponents_interval_55_61', + 'Sendov.scalarObstruction_zero', + 'Sendov.distillScalar_lt_one_small_alpha', + 'Sendov.distillScalar_lt_one_middle_alpha', + 'Sendov.distillScalar_lt_one_alpha_le_two', + 'Sendov.distillScalar_lt_one_peak_strip', + 'Sendov.distillScalar_le_total_sub_loss', + 'Sendov.distillChordTotal_lt_one', + 'Sendov.distillScalar_le_elementary_components', + 'Sendov.distillScalar_le_rationalPeak', + 'Sendov.distillRationalPeak_lt_one', + 'Sendov.PeakClosure.gap1_identity', + 'Sendov.PeakClosure.LowHomogeneous.gapH_identity', + 'Sendov.PeakClosure.HighHomogeneous.gapH_identity', ] MODULES = { - 'Sendov.DistillationFinite.Rows61_61': TARGETS[4:6], - 'Sendov.Common.DistillationFinite': TARGETS[2:4], - 'Sendov.LargeDegree.DistillationTail': TARGETS[6:8] + TARGETS[12:14], - 'Sendov.LargeDegree.DistillationTailBound': TARGETS[8:10] + TARGETS[14:15], - 'Sendov.Common.DistillationBounds': TARGETS[10:11], - 'Sendov.Reduction.Main': TARGETS[11:12], + 'Sendov.Common.DistillationFactors': TARGETS[5:6], + 'Sendov.Common.DistillationTotalBound': TARGETS[6:7] + TARGETS[10:12], + 'Sendov.Common.DistillationCorrelatedPeak': TARGETS[12:13], + 'Sendov.Common.DistillationPeakRational': TARGETS[13:14], + 'Sendov.Common.DistillationMiddleAlpha': TARGETS[7:9], + 'Sendov.Common.DistillationPeakFirst': TARGETS[15:16], + 'Sendov.Common.DistillationPeakRest': TARGETS[16:18], + 'Sendov.Common.DistillationPeakClosure': TARGETS[9:10] + TARGETS[14:15], + 'Sendov.Common.DistillationBounds': TARGETS[2:4], + 'Sendov.Reduction.Main': TARGETS[4:5], 'Solution': TARGETS[:2], } diff --git a/tests/test_bundle_rows.py b/tests/test_bundle_rows.py deleted file mode 100644 index 92d84db..0000000 --- a/tests/test_bundle_rows.py +++ /dev/null @@ -1,83 +0,0 @@ -from pathlib import Path -import importlib.util -import sys -import tempfile -import unittest - -ROOT = Path(__file__).resolve().parents[1] / 'scripts' -sys.path.insert(0, str(ROOT)) -spec = importlib.util.spec_from_file_location('bundle_rows', ROOT / 'bundle_rows.py') -bundle_rows = importlib.util.module_from_spec(spec) -spec.loader.exec_module(bundle_rows) - -class Bundling(unittest.TestCase): - def fixture(self, root): - source = root / 'input' - rows = source / 'Sendov/DistillationFinite' - rows.mkdir(parents=True) - (source / 'Sendov/Common').mkdir() - for m in [*range(5, 56), 61]: - (rows / f'Row{m}.lean').write_text( - 'import Mathlib.Data.Nat.Basic\n\n' - f'namespace FixtureRow{m}\ntheorem value : (1 : Nat) = 1 := rfl\nend FixtureRow{m}\n') - (source / 'Sendov/Common/DistillationFinite.lean').write_text(''.join( - f'import Sendov.DistillationFinite.Row{m}\n' for m in [*range(5, 56), 61]) + - '\n-- aggregate body\n') - return source - - def test_all_rows_once_in_original_order_and_bodies_preserved(self): - with tempfile.TemporaryDirectory() as temporary: - root = Path(temporary); source = self.fixture(root) - result = bundle_rows.bundle(source, root / 'out', size=8) - self.assertEqual([m for group in result['groups'] for m in group['rows']], [*range(5, 56), 61]) - for group in result['groups']: - text = (root / 'out' / group['path']).read_text() - for m in group['rows']: - original = (source / f'Sendov/DistillationFinite/Row{m}.lean').read_text() - body = ''.join(x for x in original.splitlines(keepends=True) if not x.startswith('import ')) - self.assertIn(body, text) - self.assertEqual(result['groups'][-1]['module'], 'Sendov.DistillationFinite.Rows61_61') - self.assertEqual(result['groups'][-2]['module'], 'Sendov.DistillationFinite.Rows53_55') - self.assertFalse((root / 'out/Sendov/DistillationFinite/Row61.lean').exists()) - self.assertFalse((root / 'out/Sendov/DistillationFinite/Row46.lean').exists()) - aggregate = (root / 'out/Sendov/Common/DistillationFinite.lean').read_text() - self.assertNotIn('import Sendov.DistillationFinite.Row46\n', aggregate) - self.assertTrue(aggregate.endswith('\n-- aggregate body\n')) - - def test_missing_row_fails_before_output(self): - with tempfile.TemporaryDirectory() as temporary: - root = Path(temporary); source = self.fixture(root) - (source / 'Sendov/DistillationFinite/Row61.lean').unlink() - with self.assertRaisesRegex(ValueError, 'rows'): - bundle_rows.bundle(source, root / 'out') - self.assertFalse((root / 'out').exists()) - - def test_extra_row62_fails_before_output(self): - with tempfile.TemporaryDirectory() as temporary: - root = Path(temporary); source = self.fixture(root) - (source / 'Sendov/DistillationFinite/Row62.lean').write_text( - 'import Mathlib.Data.Nat.Basic\n') - with self.assertRaisesRegex(ValueError, 'rows'): - bundle_rows.bundle(source, root / 'out') - self.assertFalse((root / 'out').exists()) - - def test_retired_row56_fails_before_output(self): - with tempfile.TemporaryDirectory() as temporary: - root = Path(temporary); source = self.fixture(root) - (source / 'Sendov/DistillationFinite/Row56.lean').write_text( - 'import Mathlib.Data.Nat.Basic\n') - with self.assertRaisesRegex(ValueError, 'rows'): - bundle_rows.bundle(source, root / 'out') - self.assertFalse((root / 'out').exists()) - - def test_duplicate_or_omitted_aggregate_import_is_not_repaired(self): - with tempfile.TemporaryDirectory() as temporary: - root = Path(temporary); source = self.fixture(root) - aggregate = source / 'Sendov/Common/DistillationFinite.lean' - aggregate.write_text(aggregate.read_text().replace('Row6\n', 'Row5\n')) - with self.assertRaisesRegex(ValueError, 'aggregate'): - bundle_rows.bundle(source, root / 'out') - self.assertFalse((root / 'out').exists()) - -if __name__ == '__main__': - unittest.main() diff --git a/tests/test_generator_core.py b/tests/test_generator_core.py index 223e595..c9124f9 100644 --- a/tests/test_generator_core.py +++ b/tests/test_generator_core.py @@ -1,7 +1,4 @@ -"""Exact-core regressions and publication I/O fault injection (never mocked math).""" -from fractions import Fraction as F -import json -from math import comb +"""Publication guarantees for the retained single-file sinh generator.""" from pathlib import Path import sys import tempfile @@ -9,272 +6,16 @@ from unittest.mock import patch sys.path.insert(0, str(Path(__file__).resolve().parents[1] / 'scripts')) -import gen_distillation as g -from distillation_data import load_table import generator_output -class ExactCoreTests(unittest.TestCase): - def test_interval_and_tail_exact_base_domain_and_components(self): - selected = [r for r in json.loads(g.TABLE.read_text()) if 5 <= r['m'] <= 61] - self.assertEqual([r['m'] for r in selected], [*range(5, 56), 61]) - with tempfile.TemporaryDirectory() as temporary: - table = Path(temporary) / 'table.json' - table.write_text(json.dumps(selected)) - self.assertEqual(load_table(table, g.coefficients), selected) - mutations = { - 'missing61': lambda r: r.pop(), - 'missing55': lambda r: r.pop(-2), - 'retired56': lambda r: r.__setitem__(-2, dict(r[-2], m=56)), - 'extra62': lambda r: r.append(dict(r[-1], m=62)), - 'duplicate': lambda r: r.__setitem__(1, r[0]), - 'reordered': lambda r: r.reverse(), - 'duplicate component': lambda r: r[0]['components'].__setitem__( - 1, r[0]['components'][0]), - 'reordered components': lambda r: r[0]['components'].reverse(), - 'mismatched components': lambda r: r[0].__setitem__( - 'components', r[1]['components']), - } - for name, mutate in mutations.items(): - with self.subTest(mutation=name): - rows = json.loads(json.dumps(selected)) - mutate(rows) - table.write_text(json.dumps(rows)) - with self.assertRaises(ValueError): - load_table(table, g.coefficients) - - def test_generator_covers_50_cases_six_degree_interval_and_tail(self): - with tempfile.TemporaryDirectory() as temporary: - output = Path(temporary) / 'output' - result = g.generate(output) - self.assertEqual(result['rows'], [*range(5, 56), 61]) - self.assertEqual(result['groups'][-2]['rows'], [53, 54, 55]) - self.assertEqual(result['groups'][-1]['rows'], [61]) - self.assertEqual(len(result['groups']), 8) - self.assertTrue((output / 'Sendov/DistillationFinite/Rows61_61.lean').is_file()) - self.assertFalse((output / 'Sendov/DistillationFinite/Row61.lean').exists()) - aggregate = (output / 'Sendov/Common/DistillationFinite.lean').read_text() - cases = [f' · exact (distillFinite_{m} α hα (by linarith)).trans_lt ' - f'distillFiniteBound_{m}' for m in range(5, 34)] - cases += [f' · exact (distillFinite_{m} α hα h17).trans_lt ' - f'distillFiniteBound_{m}' for m in range(34, 55)] - self.assertEqual([line for line in aggregate.splitlines() - if line.startswith(' · exact (distillFinite_')], cases) - self.assertIn('(hm60 : m ≤ 60)', aggregate) - self.assertIn('by_cases hinterval : 55 ≤ m', aggregate) - self.assertIn('exact distillComponents_interval_55_61', aggregate) - for path in output.rglob('*.lean'): - self.assertNotIn('two_thirds', path.read_text()) - self.assertNotIn('distillFiniteTailBase', path.read_text()) - - def test_real_pilot_uses_raw_coefficient_list(self): - row = next(r for r in json.loads(g.TABLE.read_text()) if r['m'] == 46) - text = g.row_source(row) - self.assertIn('BernsteinCert.coeffs_pos', text) - self.assertNotIn('have hid', text) - self.assertNotIn('sign_0_left_0', text) - - def test_every_flank_keeps_the_complete_original_identity(self): - identities = empty = 0 - for row in g.load_table(g.TABLE, g.coefficients): - m = row['m'] - for component in row['components']: - j = component['index'] - for side, a, b in [('left', F(0), F(component['lo'])), - ('right', F(component['hi']), min(F(17), F(m, 2)))]: - with self.subTest(m=m, component=j, side=side): - text, count = g.sign_source(m, j, side, a, b) - self.assertIn(f'0 ≤ {g.signed(j, m, side)}', text) - if a == b: - empty += 1 - self.assertEqual(count, 0) - self.assertIn('False.elim', text) - self.assertNotIn('coeffs_pos', text) - continue - identities += 1 - self.assertEqual(count, 1) - p = g.coefficients(m, j) - if (j == 0) != (side == 'left'): - p = [-c for c in p] - scale, cs = g.certificate(p, a, b) - compact = ''.join(text.split()) - self.assertIn('BernsteinCert.coeffs_pos[' + - ','.join(map(str, cs)) + ']', compact) - self.assertIn(f'(lo:={g.rat(a)})(hi:={g.rat(b)})(s:={scale})' - .replace(' ', ''), compact) - self.assertIn(f'unfold distillCritical{j}', text) - self.assertIn('simp only [BernsteinCert.coeffTree_eval_cons,', text) - self.assertIn('BernsteinCert.coeffTree_eval_nil', text) - self.assertEqual(text.count(' ring1\n'), 1) - self.assertNotIn('norm_num only', text) - self.assertNotIn('bernstein_ring', text) - self.assertEqual((identities, empty), (291, 21)) - - def test_interval_growth_budget_is_exact_and_has_strict_slack(self): - # Independent numerical contract, not values read from generated Lean. - row = next(r for r in json.loads(g.TABLE.read_text()) if r['m'] == 55) - self.assertEqual([c['u'] for c in row['components']], [248, 91, 330]) - slope = F(1, 54) + F(2, 21) - self.assertEqual(slope - 5 * (1 - F(979, 1000)), F(331, 37800)) - self.assertEqual(slope - F(1, 11), F(95, 4158)) - u = F(17, 20) - eta = u - u**3 / 30 - node = F(4, 25) + F(3, 5)*eta + F(204, 1375) - self.assertLessEqual(node, F(979, 1000)**10) - self.assertLessEqual(eta, F(21, 22)**4) - w1, w2 = 1 - F(331, 37800)*6, 1 - F(95, 4158)*6 - self.assertGreater(min(w1, w2), 0) - total = F(43, 165) + F(31, 125) + F(91, 1000)/w1 + F(33, 100)/w2 - self.assertEqual(total, F(58135011269, 58896123000)) - self.assertLess(total, F(199, 200)) - # Removing growth or extending the same interval to 62 is not licensed. - self.assertGreater(slope, F(1, 11)) - wider = F(43, 165) + F(31, 125) + F(91, 1000)/(1-F(331,37800)*7) + ( - F(33,100)/(1-F(95,4158)*7)) - self.assertGreater(wider, F(199, 200)) - - def test_empty_polynomial_and_bad_interval_are_rejected(self): - with self.assertRaisesRegex(ValueError, 'empty'): - g.certificate([], F(0), F(1)) - with self.assertRaisesRegex(ValueError, 'interval'): - g.certificate([1], F(1), F(0)) - with self.assertRaisesRegex(ValueError, 'component'): - g.coefficients(5, 3) - - def test_all_central_budgets_keep_raw_factors_and_correlated_exponents(self): - count = 0 - for row in json.loads(g.TABLE.read_text()): - m = row['m'] - source = g.row_source(row) - self.assertEqual(source.count( - 'norm_num only [distillKappa, distillRatio, distillNode, cubicPolarEnvelope]'), 3) - self.assertNotIn('norm_num [distillEBudget] at *', source) - self.assertIn('add_le_add (add_le_add (add_le_add le_rfl h0) h1) h2', source) - self.assertIn(f"_ = {g.rat(row['total'])} := by norm_num only [distillEBudget]", - source) - budgets = [g.rat(F(c['u'], 1000)) for c in row['components']] - self.assertIn(f"_ ≤ distillEBudget {m} + " + ' + '.join(budgets), source) - for c in row['components']: - j, lo, hi = c['index'], F(c['lo']), F(c['hi']) - with self.subTest(m=m, component=j): - # Reconstruct the raw formulas, including lo=0, rather than - # calling the table validator's cancelled-ratio evaluator. - u, v = lo / (lo + 3), hi / (hi + 3) - ratio = (1-u) * (1-u**2/30) / 3 - kappa = F(m*m-1, 4*m) * ratio * (m-2*lo)**2 - envelope = v-v**3/30 - node = F(4, 25) + F(3, 5)*envelope + F(12, 25*m)*hi - if j == 0: - square = (kappa * 96*F(3, 5)**4 / - ((m-1)*(m+1)*(m+3)*(m+5)*(1-node)**4))**2 - else: - square = (F((259, 421)[j-1], 3125)*kappa)**2 * ( - node if j == 1 else envelope)**(m-3) - component = source.split(f'theorem component{j} ')[1].split('\n\n')[0] - self.assertIn(f' {m-3} (by norm_num) (by norm_num)', component) - self.assertEqual(square, F(c['sq'])) - self.assertLess(square, F(c['u'], 1000)**2) - count += 1 - self.assertEqual(count, 156) - - def test_all_actual_sign_certificates_by_coefficient_reconstruction(self): - # Expand the Bernstein basis back into powers, independently of the - # renderer's change-of-basis implementation. No sampled evaluations. - rows = json.loads(g.TABLE.read_text()) - for row in rows: - m = row['m'] - for component in row['components']: - j = component['index'] - for side, a, b in [('left', F(0), F(component['lo'])), - ('right', F(component['hi']), min(F(17), F(m, 2)))]: - if a == b: - continue # empty flank has an explicit False.elim proof - with self.subTest(m=m, component=j, side=side): - p = g.coefficients(m, j) - if (j == 0) != (side == 'left'): - p = [-c for c in p] - [(lo, hi, scale, cs)] = g.sign_cover(p, a, b) - n = len(p) - 1 - reconstructed = [F(0)] * len(p) - for i, coefficient in enumerate(cs): - for u in range(i + 1): - for v in range(n - i + 1): - reconstructed[u+v] += (coefficient * comb(i, u) - * (-lo)**(i-u) * comb(n-i, v) * hi**(n-i-v) * (-1)**v) - self.assertEqual(reconstructed, [scale*c for c in p]) - self.assertGreaterEqual(min(cs), 0) - self.assertGreater(cs[0], 0) - self.assertGreater(cs[-1], 0) - - def test_sign_cover_gap_overlap_and_negative_polynomial_are_rejected(self): - for intervals in ([], [(F(0), F(1)), (F(2), F(3))], - [(F(0), F(2)), (F(1), F(3))]): - with self.assertRaises(ValueError): - g.validate_cover(intervals, F(0), F(3)) - with self.assertRaises(ValueError): - g.sign_cover([-1], F(0), F(1)) - - class PublicationTests(unittest.TestCase): - def test_staging_write_failure_leaves_empty_target_and_cleans_staging(self): - with tempfile.TemporaryDirectory() as temporary: - parent = Path(temporary) - output = parent / 'output' - output.mkdir() - before = output.stat().st_ino - actual_write = Path.write_text - calls = 0 - - def fail_seventh(path, *args, **kwargs): - nonlocal calls - calls += 1 - if calls == 7: - raise OSError('injected seventh staging write failure') - return actual_write(path, *args, **kwargs) - - with patch.object(Path, 'write_text', fail_seventh): - with self.assertRaisesRegex(OSError, 'seventh'): - g.generate(output) - self.assertEqual(output.stat().st_ino, before) - self.assertEqual(list(output.iterdir()), []) - self.assertEqual(list(parent.iterdir()), [output]) - - def test_publish_failure_preserves_empty_target(self): - with tempfile.TemporaryDirectory() as temporary: - parent = Path(temporary) - output = parent / 'output' - output.mkdir() - before = output.stat().st_ino - with patch.object(g.os, 'replace', side_effect=OSError('injected publish failure')): - with self.assertRaisesRegex(OSError, 'publish'): - g.generate(output) - self.assertEqual(output.stat().st_ino, before) - self.assertEqual(list(output.iterdir()), []) - self.assertEqual(list(parent.iterdir()), [output]) - - def test_real_rename_refuses_late_nonempty_target(self): - with tempfile.TemporaryDirectory() as temporary: - parent = Path(temporary) - output = parent / 'output' - actual_replace = g.os.replace - - def competing_output(source, target): - target.mkdir() - (target / 'sentinel').write_bytes(b'competing output') - return actual_replace(source, target) - - with patch.object(g.os, 'replace', competing_output): - with self.assertRaises(OSError): - g.generate(output) - self.assertEqual((output / 'sentinel').read_bytes(), b'competing output') - self.assertEqual(list(parent.iterdir()), [output]) - def test_writer_success_replaces_target_and_cleans_staging(self): with tempfile.TemporaryDirectory() as temporary: output = Path(temporary) / 'file.lean' output.write_bytes(b'old') - generator_output.write_lean(output, 'new α\n') - self.assertEqual(output.read_bytes(), 'new α\n'.encode()) + generator_output.write_lean(output, 'new \u03b1\n') + self.assertEqual(output.read_bytes(), 'new \u03b1\n'.encode()) self.assertEqual(list(Path(temporary).iterdir()), [output]) def test_writer_rejected_source_preserves_previous_file(self): @@ -286,6 +27,16 @@ def test_writer_rejected_source_preserves_previous_file(self): self.assertEqual(output.read_bytes(), b'old') self.assertEqual(list(Path(temporary).iterdir()), [output]) + def test_publish_failure_preserves_previous_file_and_cleans_staging(self): + with tempfile.TemporaryDirectory() as temporary: + output = Path(temporary) / 'file.lean' + output.write_bytes(b'old') + with patch.object(generator_output.os, 'replace', side_effect=OSError('publish')): + with self.assertRaisesRegex(OSError, 'publish'): + generator_output.write_lean(output, 'new\n') + self.assertEqual(output.read_bytes(), b'old') + self.assertEqual(list(Path(temporary).iterdir()), [output]) + if __name__ == '__main__': unittest.main() diff --git a/tests/test_generators.py b/tests/test_generators.py index 059052c..54d0d55 100644 --- a/tests/test_generators.py +++ b/tests/test_generators.py @@ -1,9 +1,4 @@ -"""Portable active-route generator tests. Run with unittest, using Python with SymPy. - -The digest fixture pins the selected mathematical source. It is shipped here; -no workspace report or external fixture is read. -These are Python regressions, not Lean acceptance tests. -""" +"""Portable sinh regeneration and audit command-failure regressions.""" import hashlib import json import os @@ -36,175 +31,43 @@ def inventory(root): class GeneratorTests(unittest.TestCase): - def test_retained_table_matches_pinned_original_subset(self): - table = ROOT / 'data/paper_certificate_table.json' - self.assertEqual(digest(table), EXPECTED['table_sha256']) - self.assertEqual([r['m'] for r in json.loads(table.read_text())], [*range(5, 56), 61]) - def setUp(self): self.temp = tempfile.TemporaryDirectory() self.addCleanup(self.temp.cleanup) self.work = Path(self.temp.name) self.repo = self.work / 'relocated-source' self.repo.mkdir() - for directory in ('scripts', 'data'): - if (ROOT / directory).exists(): - shutil.copytree(ROOT / directory, self.repo / directory, - ignore=shutil.ignore_patterns('__pycache__')) - (self.repo / 'scripts').mkdir(exist_ok=True) + shutil.copytree(ROOT / 'scripts', self.repo / 'scripts', + ignore=shutil.ignore_patterns('__pycache__')) self.elsewhere = self.work / 'unrelated' self.elsewhere.mkdir() - def cli(self, script, *args, cwd=None, optimized=False): - return subprocess.run([sys.executable, '-B', *(['-O'] if optimized else []), - str(self.repo / 'scripts' / script), *map(str, args)], - cwd=cwd or self.elsewhere, capture_output=True, text=True, + def cli(self, *args, cwd=None): + return subprocess.run([sys.executable, '-B', str(self.repo / 'scripts/gen_sinh.py'), + *map(str, args)], cwd=cwd or self.elsewhere, + capture_output=True, text=True, env={**os.environ, 'PYTHONDONTWRITEBYTECODE': '1'}, timeout=120) def assert_success(self, result): self.assertEqual(result.returncode, 0, result.stdout + result.stderr) - def assert_distillation(self, output): - actual = {str(p.relative_to(output)): digest(p) for p in output.rglob('*') if p.is_file()} - self.assertEqual(actual, EXPECTED['distillation']) - aggregate = (output / 'Sendov/Common/DistillationFinite.lean').read_text() - self.assertEqual(aggregate.count(' · exact (distillFinite_'), 50) - self.assertIn('exact distillComponents_interval_55_61', aggregate) - self.assertTrue((output / 'Sendov/DistillationFinite/Rows53_55.lean').is_file()) - self.assertFalse((output / 'Sendov/DistillationFinite/Rows53_60.lean').exists()) - self.assertTrue((output / 'Sendov/DistillationFinite/Rows61_61.lean').is_file()) - self.assertFalse((output / 'Sendov/DistillationFinite/Row61.lean').exists()) - self.assertFalse((output / 'Sendov/DistillationFinite/Row5.lean').exists()) - - def test_complete_cli_regeneration_from_all_cwds(self): - for i, cwd in enumerate((self.repo, self.repo / 'scripts', self.elsewhere)): - with self.subTest(cwd=cwd): - output = self.work / f'generated-{i}' - if i == 1: - output.mkdir() # explicitly empty targets are accepted too - result = self.cli('gen_distillation.py', '--output', output, cwd=cwd) - self.assert_success(result) - self.assert_distillation(output) - def test_sinh_explicit_and_default_outputs_from_all_cwds(self): for i, cwd in enumerate((self.repo, self.repo / 'scripts', self.elsewhere)): with self.subTest(cwd=cwd): output = self.work / f'Sinh-{i}.lean' - self.assert_success(self.cli('gen_sinh.py', '--output', output, cwd=cwd)) + self.assert_success(self.cli('--output', output, cwd=cwd)) self.assertEqual(digest(output), EXPECTED['sinh']['sha256']) self.assertEqual(output.stat().st_size, EXPECTED['sinh']['bytes']) - self.assert_success(self.cli('gen_sinh.py', cwd=cwd)) + self.assert_success(self.cli(cwd=cwd)) self.assertEqual(output.read_bytes(), (self.repo / 'Sendov/Common/Sinh.lean').read_bytes()) - - def test_bad_data_is_rejected_before_any_publication(self): - original = json.loads((self.repo / 'data/paper_certificate_table.json').read_text()) - mutations = { - 'missing61': lambda r: r.pop(), - 'missing55': lambda r: r.pop(-2), - 'retired56': lambda r: r.__setitem__(-2, dict(r[-2], m=56)), - 'extra62': lambda r: r.append(dict(r[-1], m=62)), - 'duplicate row': lambda r: r.__setitem__(1, r[0]), - 'row order': lambda r: r.reverse(), - 'missing component': lambda r: r[0]['components'].pop(), - 'component order': lambda r: r[0]['components'].reverse(), - 'duplicate component': lambda r: r[0]['components'].__setitem__( - 1, r[0]['components'][0]), - 'mismatched components': lambda r: r[0].__setitem__( - 'components', r[1]['components']), - 'boolean index': lambda r: r[0]['components'][0].__setitem__('index', False), - 'boolean degree': lambda r: r[0].__setitem__('m', True), - 'float degree': lambda r: r[0].__setitem__('m', 5.0), - 'false metadata': lambda r: r[0].__setitem__('e', '1/2'), - 'bad rational': lambda r: r[0].__setitem__('total', '1/0'), - 'changed total': lambda r: r[0].__setitem__('total', '1'), - 'changed square': lambda r: r[0]['components'][0].__setitem__('sq', '0'), - 'changed sign': lambda r: r[0]['components'][0].__setitem__('sign_lo', '0'), - 'bad budget': lambda r: r[0]['components'][0].__setitem__('u', 0), - 'bad bracket': lambda r: r[0]['components'][0].__setitem__('hi', '1/4'), - 'bad classification': lambda r: r[0]['components'][0].__setitem__('k', 'B'), - 'unknown field': lambda r: r[0].__setitem__('unused', 1), - 'missing field': lambda r: r[0]['components'][0].pop('sq'), - 'wrong container': lambda r: r[0].__setitem__('components', {}), - } - for name, mutation in mutations.items(): - with self.subTest(mutation=name): - rows = json.loads(json.dumps(original)) - mutation(rows) - table = self.work / 'bad.json' - table.write_text(json.dumps(rows)) - output = self.work / ('invalid-' + name.replace(' ', '-')) - output.mkdir(exist_ok=True) - before = inventory(self.work) - result = self.cli('gen_distillation.py', '--table', table, '--output', output, - optimized=True) - self.assertNotEqual(result.returncode, 0, name) - self.assertNotIn('Traceback', result.stderr) - self.assertEqual(inventory(self.work), before) - self.assertEqual(list(output.iterdir()), []) - - def test_invalid_json_and_missing_inputs_do_not_create_output(self): - for text in ('{', '{"a":1,"a":2}', '[NaN]', '[Infinity]'): - with self.subTest(text=text): - table = self.work / 'bad.json' - table.write_text(text) - output = self.work / 'never-created' - result = self.cli('gen_distillation.py', '--table', table, '--output', output) - self.assertNotEqual(result.returncode, 0) - self.assertNotIn('Traceback', result.stderr) - self.assertFalse(output.exists()) - missing = self.cli('gen_distillation.py', '--table', self.work / 'missing.json', - '--output', self.work / 'never-created') - self.assertNotEqual(missing.returncode, 0) - self.assertFalse((self.work / 'never-created').exists()) - - - def test_output_argument_is_required_and_subset_options_are_removed(self): - before = inventory(self.work) - for args in ((), ('--rows', '5'), ('--mutation', 'budget')): - result = self.cli('gen_distillation.py', *args) - self.assertNotEqual(result.returncode, 0) - self.assertIn('--output', result.stderr) - self.assertEqual(inventory(self.work), before) - - def test_nonempty_file_and_symlink_targets_are_preserved(self): - directory = self.work / 'old' - directory.mkdir() - (directory / 'sentinel').write_bytes(b'original\x00bytes') - regular = self.work / 'regular' - regular.write_bytes(b'old-file') - link = self.work / 'link' - link.symlink_to(directory, target_is_directory=True) - for output in (directory, regular, link): - with self.subTest(output=output): - before = inventory(self.work) - result = self.cli('gen_distillation.py', '--output', output) - self.assertNotEqual(result.returncode, 0) - self.assertIn('new or empty directory', result.stderr) - self.assertEqual(inventory(self.work), before) - self.assertTrue(link.is_symlink()) - - def test_missing_default_table_or_helper_has_no_output(self): - for rel in ('data/paper_certificate_table.json', 'scripts/bundle_rows.py'): - with self.subTest(missing=rel): - path = self.repo / rel - saved = path.read_bytes() - path.unlink() - before = inventory(self.work) - result = self.cli('gen_distillation.py', '--output', self.work / 'out') - self.assertNotEqual(result.returncode, 0) - self.assertEqual(inventory(self.work), before) - self.assertFalse((self.work / 'out').exists()) - path.write_bytes(saved) - def test_imports_have_no_generation_side_effects(self): for cwd in (self.repo, self.repo / 'scripts', self.elsewhere): with self.subTest(cwd=cwd): before = inventory(self.work) program = ('import sys; sys.path.insert(0, ' + repr(str(self.repo / 'scripts')) - + '); import gen_sinh, gen_distillation, generator_output, ' - 'bundle_rows, distillation_data') + + '); import gen_sinh, generator_output') result = subprocess.run([sys.executable, '-B', '-c', program], cwd=cwd, capture_output=True, text=True, timeout=30) self.assert_success(result) @@ -217,7 +80,7 @@ def test_sinh_missing_tail_preserves_existing_target(self): output.write_bytes(b'old theorem source\n') (self.repo / 'scripts/sinh_tail.lean.txt').unlink() before = inventory(self.work) - result = self.cli('gen_sinh.py', '--output', output) + result = self.cli('--output', output) self.assertNotEqual(result.returncode, 0) self.assertEqual(inventory(self.work), before) @@ -226,15 +89,12 @@ def test_sinh_actual_replace_failure_preserves_target(self): output.mkdir() (output / 'sentinel').write_bytes(b'old theorem source\n') before = inventory(self.work) - result = self.cli('gen_sinh.py', '--output', output) + result = self.cli('--output', output) self.assertNotEqual(result.returncode, 0) self.assertEqual(inventory(self.work), before) self.assertEqual(set(self.work.glob('.Sinh.lean.*.tmp')), set()) - def test_audit_propagates_lean_command_failure(self): - # A deliberately failing executable models a missing/broken Lean command, - # not a proof result. The shell audit must not turn its failure into PASS. (self.repo / 'Sendov').mkdir() (self.repo / 'Solution.lean').write_text('-- no proof in this I/O fixture\n') (self.repo / 'Challenge.lean').write_text('sorry\nsorry\n') @@ -247,6 +107,7 @@ def test_audit_propagates_lean_command_failure(self): cwd=self.elsewhere, capture_output=True, text=True, env={**os.environ, 'PATH': str(bin_dir) + os.pathsep + os.environ['PATH']}) self.assertNotEqual(result.returncode, 0, result.stdout + result.stderr) + self.assertIn('Lean axiom query failed', result.stdout) if __name__ == '__main__': From c7f25171a07b916a678b0df1dbd32ee55eb5e4df Mon Sep 17 00:00:00 2001 From: Methode Date: Sun, 13 Sep 2026 11:58:22 -0700 Subject: [PATCH 12/24] refactor(sendov): decouple peak certificates and simplify scalar proofs --- Sendov/Common/DistillationCorrelatedPeak.lean | 12 ++--- Sendov/Common/DistillationMiddleAlpha.lean | 21 +++----- Sendov/Common/DistillationPeakAlgebra.lean | 12 ++--- Sendov/Common/DistillationPeakClosure.lean | 1 + Sendov/Common/DistillationPeakFirst.lean | 2 - Sendov/Common/DistillationPeakRest.lean | 3 +- Sendov/Common/DistillationTotalBound.lean | 50 ++++++++----------- tests/PeakBudgetIndependence.lean | 26 ++++++++++ 8 files changed, 67 insertions(+), 60 deletions(-) create mode 100644 tests/PeakBudgetIndependence.lean diff --git a/Sendov/Common/DistillationCorrelatedPeak.lean b/Sendov/Common/DistillationCorrelatedPeak.lean index f81dedd..620a6e7 100644 --- a/Sendov/Common/DistillationCorrelatedPeak.lean +++ b/Sendov/Common/DistillationCorrelatedPeak.lean @@ -346,19 +346,13 @@ theorem distillScalar_le_elementary_components {m α : ℝ} (hm : 5 ≤ m) have hid := distillScalar_eq_loss_integral (by linarith : 0 < m) hα unfold scalarObstruction at hid rw [← distillKappa_eq hα] at hid + rw [← add_right_cancel hid] unfold distillElementary rw [distillRatio_eq hα] have he := (sub_pos.mpr (cubicPolarEnvelope_lt_one hα.le)).ne' have hm0 : m ≠ 0 := by linarith - have halg : - cubicPolarEnvelope α / (2 * α * (1 - cubicPolarEnvelope α)) + - cubicPolarEnvelope α / (4 * α) + 1 / (2 * m) + - cubicPolarEnvelope α / (4 * α * m) = - cubicPolarEnvelope α / α / (2 * (1 - cubicPolarEnvelope α)) + - cubicPolarEnvelope α / α / 4 + (1 / 2 + cubicPolarEnvelope α / α / 4) / m := by - field_simp - ring - linarith + field_simp + ring unfold distillTotal at h linarith only [h, hE] diff --git a/Sendov/Common/DistillationMiddleAlpha.lean b/Sendov/Common/DistillationMiddleAlpha.lean index cba7412..b33252c 100644 --- a/Sendov/Common/DistillationMiddleAlpha.lean +++ b/Sendov/Common/DistillationMiddleAlpha.lean @@ -41,13 +41,10 @@ private lemma middle_T0_lower_polynomial {m : ℝ} (hm : 5 ≤ m) : 5752975708450 * (m - 5) ^ 4 + 13287198225360 * (m - 5) ^ 3 + 48679218659063 * (m - 5) ^ 2 + 207466884835694 * (m - 5) + 297259523310640 := by ring - have hpos : 0 < - 82539689375 * (m - 5) ^ 6 + 1183226670250 * (m - 5) ^ 5 + - 5752975708450 * (m - 5) ^ 4 + 13287198225360 * (m - 5) ^ 3 + - 48679218659063 * (m - 5) ^ 2 + 207466884835694 * (m - 5) + - 297259523310640 := by positivity - rw [← hid] at hpos - linarith only [hpos] + apply sub_pos.mp + apply pos_of_mul_pos_right (a := (2148437500000 : ℝ)) _ (by norm_num) + rw [hid] + positivity private lemma middle_T0_upper_polynomial {m : ℝ} (hm : 5 ≤ m) : 24 * (3 / 5 : ℝ) ^ 4 * (10 / 47) * m ^ 3 * (m - 2 * (17 / 10)) ^ 2 < @@ -60,12 +57,10 @@ private lemma middle_T0_upper_polynomial {m : ℝ} (hm : 5 ≤ m) : 30931875 * (m - 5) ^ 6 + 369947250 * (m - 5) ^ 5 + 1135607850 * (m - 5) ^ 4 + 856992960 * (m - 5) ^ 3 + 18236567691 * (m - 5) ^ 2 + 103802533398 * (m - 5) + 136283024880 := by ring - have hpos : 0 < - 30931875 * (m - 5) ^ 6 + 369947250 * (m - 5) ^ 5 + - 1135607850 * (m - 5) ^ 4 + 856992960 * (m - 5) ^ 3 + - 18236567691 * (m - 5) ^ 2 + 103802533398 * (m - 5) + 136283024880 := by positivity - rw [← hid] at hpos - linarith only [hpos] + apply sub_pos.mp + apply pos_of_mul_pos_right (a := (917968750 : ℝ)) _ (by norm_num) + rw [hid] + positivity lemma distillT0_le_middle {m α : ℝ} (hm : 5 ≤ m) (hα : 7 / 5 ≤ α) (hα2 : α ≤ 2) : distillT0 m α ≤ 13 / 50 := by diff --git a/Sendov/Common/DistillationPeakAlgebra.lean b/Sendov/Common/DistillationPeakAlgebra.lean index 0146c78..4e654cd 100644 --- a/Sendov/Common/DistillationPeakAlgebra.lean +++ b/Sendov/Common/DistillationPeakAlgebra.lean @@ -14,6 +14,9 @@ nonnegative Taylor terms. namespace Sendov.PeakClosure +/-- Shared affine budget; neither complementary certificate depends on the other. -/ +noncomputable def budget1 (a : ℝ) : ℝ := (431 - 3 * a) / 2500 + def S (a : ℝ) : ℝ := a + 3 def N (a : ℝ) : ℝ := 29 * a ^ 2 + 180 * a + 270 def P (a : ℝ) : ℝ := 5 * a ^ 3 + 36 * a ^ 2 + 78 * a + 48 @@ -39,7 +42,7 @@ noncomputable def taylor4 (x : ℝ) : ℝ := 1 + x + x ^ 2 / 2 + x ^ 3 / 6 + x ^ 4 / 24 lemma S_pos {a : ℝ} (ha : 0 ≤ a) : 0 < S a := by unfold S; positivity -lemma N_pos {a : ℝ} (ha : 0 ≤ a) : 0 < N a := by unfold N; positivity +lemma N_pos {a : ℝ} (ha : 0 ≤ a) : 0 < N a := distillN_pos ha lemma P_pos {a : ℝ} (ha : 0 ≤ a) : 0 < P a := by unfold P; positivity lemma W_pos {a : ℝ} (ha : 0 ≤ a) : 0 < W a := by unfold W; positivity lemma V_pos {a : ℝ} (ha : 0 ≤ a) : 0 < V a := by @@ -49,11 +52,8 @@ lemma F_pos {a : ℝ} (ha : 0 ≤ a) : 0 < F a := by unfold F; positivity lemma G_pos {a : ℝ} (ha : 0 ≤ a) : 0 < G a := by unfold G; positivity lemma D_pos {a : ℝ} (ha : 0 ≤ a) : 0 < D a := by unfold D; positivity -lemma ratio_eq {a : ℝ} (ha : 0 ≤ a) : distillRatio a = N a / (30 * S a ^ 3) := by - have hs := (S_pos ha).ne' - unfold distillRatio N S at * - field_simp - ring +lemma ratio_eq {a : ℝ} (ha : 0 ≤ a) : distillRatio a = N a / (30 * S a ^ 3) := + distillRatio_compact ha lemma envelope_gap_eq {a : ℝ} (ha : 0 ≤ a) : 1 - cubicPolarEnvelope a = F a / (30 * S a ^ 3) := by diff --git a/Sendov/Common/DistillationPeakClosure.lean b/Sendov/Common/DistillationPeakClosure.lean index 799caae..ad2cc3c 100644 --- a/Sendov/Common/DistillationPeakClosure.lean +++ b/Sendov/Common/DistillationPeakClosure.lean @@ -1,3 +1,4 @@ +import Sendov.Common.DistillationPeakFirst import Sendov.Common.DistillationPeakRest /-! diff --git a/Sendov/Common/DistillationPeakFirst.lean b/Sendov/Common/DistillationPeakFirst.lean index a5a7f7f..cee6955 100644 --- a/Sendov/Common/DistillationPeakFirst.lean +++ b/Sendov/Common/DistillationPeakFirst.lean @@ -12,8 +12,6 @@ Long literals use hexadecimal only where decimal would exceed the line limit. namespace Sendov.PeakClosure -noncomputable def budget1 (a : ℝ) : ℝ := (431 - 3 * a) / 2500 - def gap1 (a : ℝ) : ℝ := 31250 * (431 - 3 * a) * S a ^ 3 * C a ^ 3 * t4 (X a) (V a) - numerator1 a diff --git a/Sendov/Common/DistillationPeakRest.lean b/Sendov/Common/DistillationPeakRest.lean index 004a875..ab7b7ae 100644 --- a/Sendov/Common/DistillationPeakRest.lean +++ b/Sendov/Common/DistillationPeakRest.lean @@ -1,4 +1,5 @@ -import Sendov.Common.DistillationPeakFirst +import Sendov.Common.DistillationPeakAlgebra +import Sendov.Common.BernsteinList /-! # Joint elementary, zeroth and second peak budget diff --git a/Sendov/Common/DistillationTotalBound.lean b/Sendov/Common/DistillationTotalBound.lean index bca34f5..03acaf7 100644 --- a/Sendov/Common/DistillationTotalBound.lean +++ b/Sendov/Common/DistillationTotalBound.lean @@ -35,27 +35,22 @@ lemma distillScalar_eq_loss_integral {m α : ℝ} (hm : 0 < m) (hα : 0 < α) : cubicPolarEnvelope α / (4 * α) + 1 / (2 * m) + cubicPolarEnvelope α / (4 * α * m) = distillEBudget m - distillElementaryLoss m α := by - have hrat : - cubicPolarEnvelope α / (2 * α * (1 - cubicPolarEnvelope α)) + - cubicPolarEnvelope α / (4 * α) + 1 / (2 * m) + - cubicPolarEnvelope α / (4 * α * m) = - distillRatio α / (2 * (1 - cubicPolarEnvelope α)) + - distillRatio α / 4 + 1 / (2 * m) + distillRatio α / (4 * m) := by - rw [distillRatio_eq hα] + trans distillRatio α / (2 * (1 - cubicPolarEnvelope α)) + + distillRatio α / 4 + 1 / (2 * m) + distillRatio α / (4 * m) + · rw [distillRatio_eq hα] field_simp [hα.ne', hm.ne', he] - rw [hrat] - simp only [distillElementaryLoss, distillEBudget] - have hr : distillRatio α = - (1 - α / (α + 3)) * (1 - (α / (α + 3)) ^ 2 / 30) / 3 := rfl - rw [hr] - generalize hu : α / (α + 3) = u - have heq : cubicPolarEnvelope α = u - u ^ 3 / 30 := by - simp only [cubicPolarEnvelope, hu] - rw [heq] at he ⊢ - generalize hd : 1 - (u - u ^ 3 / 30) = d at he ⊢ - field_simp [hm.ne', he] - rw [← hd] - ring + · simp only [distillElementaryLoss, distillEBudget] + have hr : distillRatio α = + (1 - α / (α + 3)) * (1 - (α / (α + 3)) ^ 2 / 30) / 3 := rfl + rw [hr] + generalize hu : α / (α + 3) = u + have heq : cubicPolarEnvelope α = u - u ^ 3 / 30 := by + simp only [cubicPolarEnvelope, hu] + rw [heq] at he ⊢ + generalize hd : 1 - (u - u ^ 3 / 30) = d at he ⊢ + field_simp [hm.ne', he] + rw [← hd] + ring unfold scalarObstruction rw [← distillKappa_eq hα, hE] @@ -202,15 +197,12 @@ private lemma chord_total_polynomial_pos {m α : ℝ} (hm : 5 ≤ m) p4 * α ^ 4 * (7 - 5 * α) + p5 * α ^ 5 := by dsimp [p0, p1, p2, p3, p4, p5, x] ring - have hpos : 0 < p0 * (7 - 5 * α) ^ 5 + p1 * α * (7 - 5 * α) ^ 4 + - p2 * α ^ 2 * (7 - 5 * α) ^ 3 + p3 * α ^ 3 * (7 - 5 * α) ^ 2 + - p4 * α ^ 4 * (7 - 5 * α) + p5 * α ^ 5 := by - rcases eq_or_lt_of_le hα with heq | hpos - · rw [← heq] - positivity - · positivity - rw [← hid] at hpos - exact pos_of_mul_pos_right hpos (by norm_num) + apply pos_of_mul_pos_right (a := (7 : ℝ) ^ 5) _ (by norm_num) + rw [hid] + rcases eq_or_lt_of_le hα with heq | hpos + · rw [← heq] + positivity + · positivity theorem distillChordTotal_lt_one {m α : ℝ} (hm : 5 ≤ m) (hα : 0 ≤ α) (hα1 : α ≤ 7 / 5) : distillChordTotal m α < 1 := by diff --git a/tests/PeakBudgetIndependence.lean b/tests/PeakBudgetIndependence.lean new file mode 100644 index 0000000..d0c4db0 --- /dev/null +++ b/tests/PeakBudgetIndependence.lean @@ -0,0 +1,26 @@ +import Sendov.Common.DistillationPeakRest + +/-! The complementary budget must not import the first peak's heavy certificate. -/ +open Sendov Sendov.PeakClosure + +example (a : ℝ) : budget1 a = (431 - 3 * a) / 2500 := rfl + +example {a : ℝ} (ha : 2 ≤ a) (h17 : a ≤ 17) : + distillElementary (max 5 (2 * a)) a + distillPeak0 a + + (421 / 12500) * distillRatio a * + distillRationalExpPeak a (distillPeakRate2 a) (distillPeakRate2 a * (2 * a - 3)) < + 1 - budget1 a := + rest_lt_budget ha h17 + +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + if env.header.moduleNames.contains `Sendov.Common.DistillationPeakFirst then + throwError "complementary budget still imports the first peak certificate" + if env.contains `Sendov.PeakClosure.peak1_lt_budget then + throwError "first peak certificate leaked into the complementary budget environment" + let some idx := env.getModuleIdxFor? `Sendov.PeakClosure.budget1 | + throwError "missing shared budget owner" + unless env.header.moduleNames[idx.toNat]! == `Sendov.Common.DistillationPeakAlgebra do + throwError "shared budget is not owned by the common algebra module" + logInfo "PEAK_BUDGET_INDEPENDENT: original budget and rest type, without First" From 0a4e966c41e1287f92d305d3bad8e70c8c295dde Mon Sep 17 00:00:00 2001 From: subfish-zhou <91206366+subfish-zhou@users.noreply.github.com> Date: Mon, 14 Sep 2026 00:47:42 -0700 Subject: [PATCH 13/24] docs: provide degree-uniform endgame review material --- docs/degree-uniform/CERTIFICATES.json | 375 ++++++++++++++++++ docs/degree-uniform/CERTIFICATE_REPLAY.json | 36 ++ docs/degree-uniform/MATHEMATICAL_NOTE.md | 222 +++++++++++ docs/degree-uniform/README.md | 37 ++ .../degree-uniform/check_note_certificates.py | 123 ++++++ scripts/LICENSE-APACHE-2.0.txt | 1 - 6 files changed, 793 insertions(+), 1 deletion(-) create mode 100644 docs/degree-uniform/CERTIFICATES.json create mode 100644 docs/degree-uniform/CERTIFICATE_REPLAY.json create mode 100644 docs/degree-uniform/MATHEMATICAL_NOTE.md create mode 100644 docs/degree-uniform/README.md create mode 100644 docs/degree-uniform/check_note_certificates.py diff --git a/docs/degree-uniform/CERTIFICATES.json b/docs/degree-uniform/CERTIFICATES.json new file mode 100644 index 0000000..b581463 --- /dev/null +++ b/docs/degree-uniform/CERTIFICATES.json @@ -0,0 +1,375 @@ +{ + "status": "draft data transcription, not a new proof check", + "source_commit": "c7f25171a07b916a678b0df1dbd32ee55eb5e4df", + "source_files": [ + "Sendov/Common/DistillationPeakFirst.lean", + "Sendov/Common/DistillationPeakRest.lean" + ], + "number_encoding": "decimal integer strings; parse with arbitrary precision, never floating point", + "coefficient_order": "index i multiplies (alpha-L)^i*(U-alpha)^(degree-i), no binomial factor", + "identity": "scale * gap(alpha) = sum of ordered homogeneous terms", + "certificates": [ + { + "gap": "gap1", + "lower": "2", + "upper": "17", + "degree": 53, + "scale": "215197256322241735579900134833764013819745741784572601318359375", + "coefficients": [ + "1558580488523084412600253872550252452338816063293210054623232", + "2455069633966568256667519520083198076602336938691753642186244096", + "493029306711767388606145292157677489370460911802469256105501392896", + "50724256729771167482795499945892756644506857955316256864941985759232", + "3441557966572480478994656957776412355159241869588885785000049305190400", + "171890348001171022850673904285358273450653637012816031580730494433361920", + "6721078802933683137360270917297705052329564170190433957402763382981263360", + "213973631070578722992265293230183404958221297703198231874745746517226946560", + "5698870849868393843200886331376228078472090001759838510685333071027946782720", + "129512969981146440664091151106905152700392770111041540922013733951712098713600", + "2549460243024360470732197297050374170003452514531468345974054033740349370531840", + "43982571569418319918413011996115420376617775943168116380394348153192886605905920", + "671228919799732373527234139748182212891953758102911679630607912980889415376158720", + "9130911014662955884179890485098190323866054543552493672239369568072261117680599040", + "111409030749968073486133115492071007566930687896896420607321075334386651576510054400", + "1225569258978050449562587762869917727995965089256689591590253545070927595548196413440", + "12207989426097209951203549797476089652999156191133541608801091337259123535154904657920", + "110512875106250969133867520580187353837944672680560842331220442782843603562615499141120", + "911934680861816623945451593940815915077447615504582308154287402807869819625310170122240", + "6877024145864856265879699084865930330389845887709488927066843734673544707655503210393600", + "47494208278955290424608903412367225907096301198045239464432524451086250120311198952325120", + "300910628039314638913200373332271026878476506889867102603668637078764311307824359600501760", + "1751452569493864940136054572797031255572539651418416188051926780016086438701981023890946560", + "9375569721232362310143337509934214140336439751570668575953732428512527949236393454755192320", + "46194189101971498251405412284821209630535026562051471644615192482416353449202575746141190400", + "209606348676782197308309730164590873815576532360870359780608857674536778419271266997084504064", + "876145444867309053180136547655520910627356149096579117653902842128812780886557625191456254592", + "3373831520295550908188380845593121077064438676262985102485142880081093971355959528602508347392", + "11966341706100679985368960798342767079030813079950703151217182707270387309033011564598004836864", + "39075071909368118495056025821271113143041722051021530005292825637641761847683615301002820990400", + "117392365059877380602470769826467375675170430350268853406128215966348218721830256361063082608320", + "324168168228872587836173803041799894163868605647328882493175570192423895723384374765256051282560", + "821790671924781814893429337183114826152813494982412790642644390298058920238675340801603556625760", + "1909653987756711056060552821991090994938164370371422501833854949913885213319716252595305168829120", + "4060263070768094908170920869501034933638383113665954123960291978446396684740743106512693057493600", + "7881512014461833034343795010156389136210047932303860216973824848327695515314792881745919903344240", + "13931525427452440859581885157536777540893073783924008650484568462559331471667083828520112312243120", + "22356516067802159520556040666436443302514796071691536276947343549011942540720695198719842879295920", + "32455153761860066200672837336577490069369895695023963214967781931835826900280109148645344948296440", + "42445620445573791900240734928974045462300205965329681047548040464919968292318979584136134061554400", + "49766536910804654206683348969024892146775702882176101862176092706070362965866568183629226229821040", + "52012950225118954356427722918642628751370675276561341415603661413207176194250518906923556481313220", + "48130212944563759445629583642157257401899362086637380348501835444739718996467536604512342707136420", + "39116673349325112091802641080399428388213894356929911317381280351356865783811244510832767246329840", + "27653576769556359882862826158868321050331373823472639346129118602929137080362040184392279798769850", + "16807527360820256451493425234389022855539250543066866853949319915075046945885743894074349692746220", + "8657325866815982652908326618101927200720223604445642407929446693393796169807221627603957535977560", + "3712197663531047496056923925013109019188268413944479728968908793440184469279251846259339877506735", + "1295471123418004451756012996343554766434973541627088913093308608653657015508766495099421151009670", + "357351262476241989006760571578951949320557188488682687873483153736409013544317660960801458937275", + "74947704240350077547865961680316253997029590471797469179091668493590259139233893317719628272832", + "11310916285951207571597311293040437183978534427639783873058768800461349718018042161571165539621", + "1119945403927140499357285848846002779212874226709730436154973515192085181255791771970171867996", + "57388450901061302909204174813760581334851746914146380031048577074728690631838468514554260257" + ], + "low_degree_homogenizations": { + "SH": { + "degree": 1, + "scale": "15", + "coefficients": [ + "5", + "20" + ] + }, + "NH": { + "degree": 2, + "scale": "225", + "coefficients": [ + "746", + "5932", + "11711" + ] + }, + "PH": { + "degree": 3, + "scale": "3375", + "coefficients": [ + "388", + "5394", + "24474", + "36343" + ] + }, + "WH": { + "degree": 3, + "scale": "3375", + "coefficients": [ + "9742", + "123546", + "520266", + "727087" + ] + }, + "CH": { + "degree": 7, + "scale": "170859375", + "coefficients": [ + "24132872", + "814421384", + "11345681292", + "85126993720", + "373029172870", + "957053482512", + "1332925738034", + "777699749327" + ] + }, + "XH": { + "degree": 7, + "scale": "170859375", + "coefficients": [ + "4759936", + "326665252", + "6025627956", + "51603922010", + "237247357010", + "597611142156", + "761351011627", + "367047183361" + ] + } + } + }, + { + "gap": "gapLow", + "lower": "2", + "upper": "5/2", + "degree": 47, + "scale": "1", + "coefficients": [ + "28687231504364325032601869723445872447324983311445964958222241497088", + "1582470884517134842005578612798484747555273639928136326122746727628800", + "42477829560992384110457357641481089857017906878222887289408281531908096", + "739991578476397822350133939211373380355778117354268774703542562566701056", + "9413056885932049870437637478252909243026309772882846488332131468700549120", + "93259940190499531365813802273382087026148329770609094431054491175094321152", + "749539208821165482212556144974311598775954155184881940423498769820729475072", + "5025372953230470851603705598134768560851621417453752029150285206160750411776", + "28684166640670678720610795626886932213461246102393460985085922710453881929728", + "141544969138884429935199086884156019328301955943379069193957333728179313967104", + "611124284151271312951680838948273121743113432252944266568872236811165498343424", + "2330742211495422210000371809035441859034996959347844184354516459847036157558784", + "7913118499797015740820645764620857398698511393389031236153638377710097056923648", + "24068259216899798379936780097112061908794032084695043266207876399632757651668992", + "65927147281600083878921306654440298932116167269213663699969656108563848362983424", + "163343579680054264119016704303494996095477788761035850187562927529953345174241280", + "367399152474887375258818525464220139846670110057649222598139207215170501017075712", + "752467859247056995005469226570004271805252877364236588967368830685456973072171008", + "1406826797146415829777186918022572530531674453024353094076907086287186041021399040", + "2405959481954287992874670889022213600437904499583786002855449434275520321222082560", + "3770060987352898880800496304527756880079991851711283552530241676376910606379253760", + "5419763555231114745387210724756725643299658804399850355843612224285665928203468800", + "7154813405295885141357741777609942561035753064005586741861237951689744842122854400", + "8679203016865827929555737960166472908771393043255280752648083208088018031424307200", + "9677688796304807537487224868595559320860485875723491095168351701590420335099904000", + "9919560979140861407140764221408805965530862362201975948826830116308272117972992000", + "9344007104242418535060402014428743351940565228821383000965233647273311295504384000", + "8084522500401051069413653872882556660981281341114489775913986947660535667097600000", + "6419201881448217165480050637481674686619500186383036996160079087352699677573120000", + "4671904617346067820478084781558798986878505898618824791272607705180349836820480000", + "3111844057281932459124149980408328558999479112769005716989570734786471254425600000", + "1893235729991851904124545466179602166252040127507429990399742458557930828595200000", + "1049572191719473385576995180348682865783662511689356966436931752106906289766400000", + "528658776562341975608520513624753559156398321757735009396005846763394307072000000", + "241083845995078020324569217631158852444003062607738421599393810014024053248000000", + "99118250239934318950638058737191121765552404630525003992731219602567597568000000", + "36552543805101490210009236757568708960228515464282651981395671477024749440000000", + "12016463630234911404315522706739364181578208779840803401088451340248756720000000", + "3495034251891797117533347510852352645931861409668474362881041778889108960000000", + "891014717301182519594129731897207490989285870737328430887812389171836200000000", + "196776904713778175247836913887350781998096992539491612454184666225621600000000", + "37081511583502455897700811627099733565496914219000961361725918870410575000000", + "5844457308382822406737113797001111478146048246405193318972811272136250000000", + "749465611683340016524487419973964294090193344954173279767878731087250000000", + "75108892506493962283330837008673969319966623994864334005032500279000000000", + "5517771459967244556976623417418409705597878753861436193715382705000000000", + "264262424414129340280092119033185949135450991396339212985779130000000000", + "6191237285816150279084488283919823436327247079696528432958912500000000" + ], + "low_degree_homogenizations": { + "SH": { + "degree": 1, + "scale": "1", + "coefficients": [ + "10", + "11" + ] + }, + "NH": { + "degree": 2, + "scale": "1", + "coefficients": [ + "2984", + "6560", + "3605" + ] + }, + "FH": { + "degree": 3, + "scale": "1", + "coefficients": [ + "18064", + "57840", + "61680", + "21905" + ] + }, + "GH": { + "degree": 3, + "scale": "1", + "coefficients": [ + "41936", + "140160", + "156120", + "57955" + ] + }, + "DH": { + "degree": 3, + "scale": "1", + "coefficients": [ + "30064", + "97440", + "105240", + "37877" + ] + }, + "JH": { + "degree": 3, + "scale": "1", + "coefficients": [ + "370024", + "1192740", + "1280910", + "458291" + ] + } + } + }, + { + "gap": "gapHigh", + "lower": "5/2", + "upper": "17", + "degree": 47, + "scale": "540388254896363906423085056139791027545489078221423373035998591883509", + "coefficients": [ + "74294847429793803349013859407037881235926964956358341195506950000000000", + "14468208523937467153670902052811485558859630976644137123669912260000000000", + "1309708807098842653716700406222379534304225015994802129176540772660000000000", + "74576457150190025865884332417107464369000959506932847067298507871628000000000", + "3030009977994709507138115055555654561058159449596267705652585055169167000000000", + "94164843289451615331819486290514185117021666479379122457933828894412865000000000", + "2338896013483961737783309734508401854205591013417248627312817349583556984900000000", + "47851339751446162416440976260342841871497987003987991767961397439404805959200000000", + "824172647663660612853666662698174188106257796449610304950444419780873663948400000000", + "12148548122904954743774949073833696799998311384788259957721744326406135934618120000000", + "155220161070734422173392420798761486753974195177357558906127723174067036401905440000000", + "1736492319202497447856104544825467294091336616840954077643834057986773684210885280000000", + "17148467155199067861106782667584716076083624695486481181619446020262917450330713856000000", + "150478921147515391939367188838979676759198636841351498715082418779485919641451070336000000", + "1179716947516088028938178044676109848067198859264191898097937905939586165117452706304000000", + "8299843940765309666079249593351913658220338946458170469628423963609898491257495982796800000", + "52595464470677421110964717678212998990487783069914630531976855981621412766058717718118400000", + "301108036953314661533878180546489045715314383381276266715033302046829649770108860224307200000", + "1561191043554546394894831604065622283283013701261834176737775314116271878622481590076047360000", + "7345126477852844153535053183494006142839812725944103816616514838775134137294792831004835840000", + "31405920692587923869560141299255663052006867115293353748018032733107602779309161509342412800000", + "122174247252137338423424184466740441178369774769421184580852965561074798116900936021802221568000", + "432743799025503115732562964633985223784045267819034144030689266406542291836751005018597883904000", + "1396179901678688396473077267553594013803717935119447429076095841565179553789373711127913955328000", + "4103383300986526671756940763275957122571892222756644139370778632638265008538595830468096452198400", + "10982986950215774269554935648030476496069689595361118830360905350856041888858772589999700102348800", + "26755911675546507158393277754174443079485864224700029280216144326267532457186215708987139660185600", + "59269985649518891077055987690024926108099485616350104384557568331603919441795887712766787500113920", + "119235273428577481387066382624551619802559796967880077109069196996619567611899586362822390364241920", + "217471117363885706930402347326571855470640955636439021543198995859652060732052551897615969843937280", + "358851383219381795770762401322294059714686625545807934587835397057784011927468353093064709579472896", + "534354226961847219271512037646585909139645962031545191062854967040561656261166065628180659342147584", + "715811727106001977448118503852493319157378363299230815481784783108603523022902663802089560006983680", + "859423952677989012967568725937235594865708050885313602090460304263247098099204937259452081339629568", + "920705622403083735359827475695323896714398542820354391273921454550427514407396187935453939429801984", + "875426662871979573116149222239043128444182772209303451981643343160218437496252652571143239458881536", + "734024597813249560690419097556102843536965717287687730725715831949221938129637069717920162332540928", + "538517523632934686114823446622036797817293875615244828062202955068508417223473516919224045244776448", + "342386081591850465255306799547928459571024440543761503555195645557409312692476095033336121973014528", + "186400966646479125404068521136416237088517385064884250990203416465845968457889413298524725314584576", + "85574390760496889550851875954125949440527503785197586226761553964876980849251130757158056547581952", + "32468665866671016726697384944178906025811355127148582330722789477938737667290553880919964452388864", + "9905505812346642430126763905473616778299059082764042895658810776895200152623518098341831485947904", + "2335483524013682009486555702969323863106304356746996403966503203744467899141059608764254456381440", + "400035968070281456751345267763303102569227468621478166327252049991642260838856670811513507807232", + "44597015820241923456502849694219222777844645075973913680518013650821256503457016749840853368832", + "2519500525180673896491860843808907330553020264601599548769406599846561391488288736450571141120", + "19286492509041959506496627214548384489747573868937787217081427690416394743856453359077687296" + ], + "low_degree_homogenizations": { + "SH": { + "degree": 1, + "scale": "29", + "coefficients": [ + "11", + "40" + ] + }, + "NH": { + "degree": 2, + "scale": "841", + "coefficients": [ + "3605", + "26060", + "46844" + ] + }, + "FH": { + "degree": 3, + "scale": "24389", + "coefficients": [ + "21905", + "182730", + "463740", + "327304" + ] + }, + "GH": { + "degree": 3, + "scale": "24389", + "coefficients": [ + "57955", + "688470", + "2704260", + "3512696" + ] + }, + "DH": { + "degree": 3, + "scale": "24389", + "coefficients": [ + "37877", + "356970", + "1097340", + "1095304" + ] + }, + "JH": { + "degree": 3, + "scale": "24389", + "coefficients": [ + "458291", + "4099800", + "11696640", + "10420864" + ] + } + } + } + ] +} diff --git a/docs/degree-uniform/CERTIFICATE_REPLAY.json b/docs/degree-uniform/CERTIFICATE_REPLAY.json new file mode 100644 index 0000000..5a11d0d --- /dev/null +++ b/docs/degree-uniform/CERTIFICATE_REPLAY.json @@ -0,0 +1,36 @@ +{ + "status": "PASS", + "sympy_version": "1.13.1", + "identities": [ + { + "gap": "gap1", + "degree": 53, + "identity": true, + "coefficients": 54, + "factor_identities": 6, + "factor_coefficients": 29 + }, + { + "gap": "gapLow", + "degree": 47, + "identity": true, + "coefficients": 48, + "factor_identities": 6, + "factor_coefficients": 21 + }, + { + "gap": "gapHigh", + "degree": 47, + "identity": true, + "coefficients": 48, + "factor_identities": 6, + "factor_coefficients": 21 + } + ], + "interior_coefficient_mutants_rejected": [ + "gap1", + "gapLow", + "gapHigh" + ], + "scope": "Exact rational polynomial identities from displayed note formulas and JSON; not an analytic proof or Lean replay." +} diff --git a/docs/degree-uniform/MATHEMATICAL_NOTE.md b/docs/degree-uniform/MATHEMATICAL_NOTE.md new file mode 100644 index 0000000..8596ba8 --- /dev/null +++ b/docs/degree-uniform/MATHEMATICAL_NOTE.md @@ -0,0 +1,222 @@ +# A degree-uniform scalar endgame for Sendov's conjecture + +**Mathematical review note — not a standalone paper.** + +**Local contribution: subfish-zhou (GitHub).** Original mathematical sources and authorship are credited below. + +This note explains the scalar replacement in the mathematical source snapshot `c7f25171a07b916a678b0df1dbd32ee55eb5e4df`, relative to the fixed `teorth/sendov` base `1ddea92d89f951a0a7cbbffa6c267cf7e6640b1d`.[3] It is a reading guide, not a new standalone proof of the conjecture. Analytic lemmas not proved below are explicit inputs from the cited literature or named Lean results. The exact-arithmetic specification in §5 is self-contained with the adjacent `CERTIFICATES.json`; its scope is the three large-alpha identities, not all analytic implications. + +## 1. The scalar theorem and its limits + +For real parameters put + +\[ +u=\frac{\alpha}{\alpha+3},\qquad e(\alpha)=u-\frac{u^3}{30},\qquad +\beta_m(t;\alpha,\eta)=(1-t)^2+\eta t+\frac{2\alpha}{m}t(1-t), +\] +\[ +\begin{aligned} +H_m(\alpha;\eta)={}&\frac{\eta}{2\alpha(1-\eta)}+\frac{\eta}{4\alpha} ++\frac1{2m}+\frac{\eta}{4\alpha m}\\ +&+\frac{\eta(m^2-1)(m-2\alpha)^2}{4\alpha m} +\int_0^1t^3\beta_m(t;\alpha,\eta)^{(m-3)/2}\,dt. +\end{aligned} +\] + +**Existing Lean result, in mathematical notation:** + +\[ +\boxed{m\in\mathbb R,\ m\ge5,\quad0<\alpha\le17,\quad2\alpha\le m +\quad\Longrightarrow\quad H_m(\alpha;e(\alpha))<1.} +\] + +This is `Sendov.distillScalar_lt_one_real` in `Common/DistillationBounds.lean`. All source paths in this note omit the prefix `Sendov/` and refer to that mathematical source snapshot. The kernel and envelope definitions are in `Common/DistillationKernel.lean` and `Common/DistillationEnvelope.lean`. + +The domain includes `2*alpha = m`; the integral prefactor then vanishes and is never cancelled as a nonzero quantity. No extra hypothesis from Tao's old linear-envelope tail is imposed. This is not interpolation between integer-degree rows. Nor does it assert that `H` is monotone in `m`, that its maximum has been found, that `5` is the smallest admissible real threshold, or that An's `<199/200` margin survives.[2] + +**Zero is different.** Under Lean's totalized division, the raw expression at `alpha=eta=0` is `1/(2*m)` (`scalarObstruction_zero`). An's continuous extension along `eta=e(alpha)` has value + +\[ +\frac14+\frac7{12m}+\frac1{2(m-2)}. +\] + +These are distinct definitions at zero.[2] The boxed result is a positive-alpha theorem; it makes no raw continuity claim. + +## 2. What is inherited, and how the result is consumed + +The geometric convention is **`m=n-1`**, with `n` the polynomial degree. In the normalized interior reduction, `alpha=m(1-a^2)/2`, where `a` is the real distinguished root, and `eta=beta(1)`. Tao's Lemma 6 and Propositions 10–11 supply the identity/reduction framework and `alpha<=17`; his Remark 8 records earlier sources of the identities.[1] An's §§2–4 give the scalar reformulation, its eta monotonicity, the cubic envelope and the two-chord majorization.[2] + +The local `cubicScalar_constraints_of_polar_origin` derives `0=1`, which explains this proof's `m>=5` range without proving a minimality result. For the exact retained loss, + +\[ +E_m=\frac14+\frac7{12m}-L_m,\qquad +L_m=\frac{u^2}{180(1-e)}+ +\frac{u(30+u-u^2)}{360}\left(1+\frac1m\right). +\] + +This identity reorganizes existing rational expressions; the useful change is not discarding the loss before the final estimates. + +| Region | Closure and explicit proof input | +|---|---| +| `0=81`; the new theorem covers the entire real range from `5`, including the nonintegers below `81` not supplied by his finite integer table.[2] + +## 4. Why keep the same alpha? + +With `t=m-2*alpha>=0`, `m(m-2alpha)^2=t^3+2alpha*t^2`. For `c>0`, the standard exponential peak inequality gives + +\[ +m(m-2\alpha)^2e^{-c(m-3)} +\le e^{-c(2\alpha-3)} +\left(\frac{27e^{-3}}{c^3}+\frac{8\alpha e^{-2}}{c^2}\right). +\] + +This is `distill_degree_exp_le_peak`. The two terms peak separately; “same-alpha” does not assert a common optimizing degree. + +For `T0`, let `d=21/25-3e/5`, `ell=(6/25)/d` and `z=(m-2alpha)/(m-2alpha*ell)`. The proof supplies the needed denominator and range facts and uses + +\[ +0\le z\le1,\qquad z^2(1-z)(1-\ell z) +\le(1-\ell)\frac4{27}+\frac{\ell}{16}. +\] + +For `T1`, put `B=8/25+3e/5`, + +\[ +c_1=\frac{1-B}{1+B}+\frac{2(\alpha-1)}{25\alpha B},\qquad +v_1=\frac{6(\alpha-1)^2}{25\alpha B}. +\] + +The proof of `distillNode_rpow_le_exp` bounds `q^s` by `exp(-c1*(m-3)+v1)`. Its algebraic remainder after the logarithmic bound is exactly + +\[ +\frac{2(m-3\alpha)^2}{25\alpha Bm}\ge0. +\] + +The reciprocal correction has not been silently discarded. The elementary term is bounded at the **actual** degree floor `max(5,2alpha)`. Rationalization uses `exp(-2)<=677/5000`, `exp(-3)<=249/5000` and positive Taylor denominators. First-peak algebra deliberately drops nonnegative fifth/sixth Taylor terms, using a fourth-order denominator; the second peak keeps sixth order. This is a controlled relaxation, not pointwise superiority of every new bound. + +The missing range, logarithmic and integral arguments are supplied by the named Lean results, not by the following numerical certificate specification. + +## 5. Self-contained specification for the fixed identities + +This section and `CERTIFICATES.json` specify an exact check without a numerical optimizer, root isolator, Lean parser or certificate search. All arithmetic is over arbitrary-precision integers/rationals. The JSON is a decimal transcription of the candidate's complete lists; strings must **not** be converted through floating point. + +For this section only write `a=alpha` (not the geometric root of §2), and define these polynomials: + +```text +S = a+3 +N = 29*a^2+180*a+270 +P = 5*a^3+36*a^2+78*a+48 +W = 95*a^3+774*a^2+2052*a+1782 +V = 9*P*W +C = 605*a^7+13426*a^6+113310*a^5+470394*a^4 + +1001268*a^3+969084*a^2+174960*a-192456 +X = 70*a^7+7769*a^6+85302*a^5+334746*a^4 + +393390*a^3-616248*a^2-1758348*a-997272 +F = a^3+90*a^2+540*a+810 +G = 59*a^3+450*a^2+1080*a+810 +D = 13*a^3+198*a^2+864*a+1134 +J = 97*a^3+2169*a^2+10827*a+15147 + +t4(x,v) = 24*v^4+24*x*v^3+12*x^2*v^2+4*x^3*v+x^4 +t6(x,v) = 720*v^6+720*x*v^5+360*x^2*v^4+120*x^3*v^3 + +30*x^4*v^2+6*x^5*v+x^6 + +A1 = 259*N*a^3*V^6*(6723*V+5416*C) +B1 = 78125000*S^3*C^3*t4(X,V) +A2 = 1263*N*G^8*(6723*G+5416*a*F) +B2 = 7812500*S^3*F^3*t6((2*a-3)*F,G) +Q = a*S^3*F^3*D^3*t6((2*a-3)*F,G) +b = (431-3*a)/2500 +E(v) = N/(2*F)+N/(120*S^3)+(1/2+N/(120*S^3))/v +Z0 = 3000*S^9*N*J/(a*F^2*D^3) +``` + +Here `A1/B1` is the relaxed rational first-peak bound and `A2/B2` the rational second-peak bound; `Z0` is the zeroth-peak bound. This correspondence is an input from `PeakAlgebra.peak1_le_four`, `peak2_eq`, `peak0_eq`, and `elementary_eq`. + +Construct the three polynomials by **exact rational cancellation**: + +```text +gap1 = b*B1-A1 +gapLow = 7812500*Q*(1-b-E(5)-Z0-A2/B2) +gapHigh = 93750000*Q*(1-b-E(2*a)-Z0-A2/B2) +``` + +Require cancellation to leave a polynomial, not a sampled rational function. Equivalently, multiply denominators and check polynomial identities before cancellation. These are the budget-gap equalities `gap1_eq`, `gapLow_eq`, `gapHigh_eq`; their multipliers are part of the specification, not optional normalizations. + +| JSON gap | Closed interval `[L,U]` | Degree `d` | Positive scale `s` | Ordered coefficient count | Lean identity | +|---|---|---:|---:|---:|---| +| `gap1` | `[2,17]` | 53 | `15^53` | 54 | `PeakClosure.gap1_identity` | +| `gapLow` | `[2,5/2]` | 47 | `1` | 48 | `PeakClosure.LowHomogeneous.identity` | +| `gapHigh` | `[5/2,17]` | 47 | `29^47` | 48 | `PeakClosure.HighHomogeneous.identity` | + +For each record, index `i=0,...,d` means exactly + +\[ +\boxed{s\,\mathrm{gap}(a)= +\sum_{i=0}^d c_i(a-L)^i(U-a)^{d-i}.} +\] + +There is **no additional binomial coefficient**. The lowest index is the `y^d` term, not the `x^d` term. The JSON also includes all 71 low-degree factor coefficients: First has 29, Low and High each have 21. The factor named `SH`, for example, means the homogeneous representation of `S`, and likewise `NH,PH,WH,CH,XH,FH,GH,DH,JH` where present. For factor degree `k`, check its listed `scale*f(a)` against the same ordered sum on that record's interval. `VH=9*PH*WH` is derived, not another stored coefficient list. + +**Acceptance procedure:** + +1. Require the exact three records, exact interval/degree/scale metadata above, and list lengths `54/48/48`. Check the 71 factor entries and their identities if checking the factored implementation as well as the target identities. +2. Independently construct all factors, rational budget differences, and resulting polynomials from the displayed formulas. Expand both sides of each boxed identity using exact polynomial addition, multiplication and nonnegative integer powers. Compare **every coefficient**, allowing only trailing zero padding; require degrees at most the specified `d`. +3. Require `s>0`, `L=0` for every entry, and `c_0>0`, `c_d>0`. The supplied lists in fact have every coefficient positive. At an interior point both interval coordinates are positive; at either endpoint the appropriate axis coefficient is positive. This proves strict gap positivity on the whole closed interval. +4. Justify denominator signs separately before returning to rational inequalities. On `[2,17]`, `a,S,N,P,W,V,F,G,D` are positive; `C,X>0` are the sign lemmas `C_pos`, `X_pos` in `PeakAlgebra` (their positive homogeneous representations also permit an interval check here). Hence `B1,B2,Q>0`; `t4,t6` have positive constant terms in a positive second argument and nonnegative first argument. Therefore `gap1>0` proves `A1/B10` or `gapHigh>0` proves the complementary bound with the correct degree floor. +5. Combine those budget inequalities only **after** invoking the analytic peak majorizations of §§3–4. Passing the finite identity check alone is not a proof of the integral inequality or the geometric reduction. + +Checking positive entries without the full polynomial identity, evaluating at a mesh, checking only endpoints, using approximate coefficients, or truncating the vectors must be rejected. A useful implementation should also reject a changed interior coefficient, scale, interval, order or truncation; those are controls, not replacement proof obligations. + +The initial transcription pass checked signs, counts and scales. A subsequent parent-side replay with `check_note_certificates.py` independently constructed the polynomials from the displayed formulas and checked all three complete identities, all 18 listed factor identities, and rejection of one changed interior coefficient in each large identity, using exact rational arithmetic with SymPy 1.13.1. The results are in `CERTIFICATE_REPLAY.json`. This is a new non-Lean algebraic check, not a new proof of the analytic majorizations; formal acceptance remains the R12/R13 evidence summarized in the pull-request description. The three lists contain integers of up to 98, 82 and 99 decimal digits, respectively. A uniform degree organization need not be a simpler hand calculation. + +To replay this check in the documented SymPy environment, from `docs/degree-uniform`: + +```sh +python check_note_certificates.py +``` + +## 6. Review boundary + +Read `Reduction/CubicScalar` and `Common/DistillationBounds` first; follow the small/middle branch files, then `CorrelatedPeak -> PeakRational -> PeakAlgebra -> PeakFirst/PeakRest -> PeakClosure`. General certificate logic lives in `BernsteinList`, `BernsteinCert`, `BernsteinRing`. The complete source carries the proofs and the data; this short note intentionally does not repeat the original paper or hide unshown lemmas behind a claim of independent sufficiency. + +An's table has 77 integer-degree rows and critical equations of degrees 7/7/4; the local retired intermediate table had 52 degree records; this endgame has three high-degree alpha identities.[2] These are different units. The claim is a whole-real-degree scalar assembly with fixed certificates, not an optimal, certificate-free, universally more hand-checkable proof. + +No Lean build, benchmark or project test suite was rerun for this documentation pass; CI status is reported separately on the pull request. The original final contracts and reported trust base are described in the PR body, together with portable commands and the exact limitations of earlier verification. A publication-ready standalone exposition, literature-priority assessment and independent complete analytic review remain outside this draft's claims. The additional exact certificate replay is limited to the finite polynomial identities specified above. + +## Sources + +[1] https://terrytao.wordpress.com/2026/08/12/a-digestion-of-the-proof-of-sendovs-conjecture +[2] https://github.com/SJanPerth/Sendov-Proof-Distillation/blob/e8ae601491ec171ab4f7f8456113dd6a047aa85d/paper/Proof_Distillation_for_Sendovs_Conjecture.pdf +[3] https://github.com/teorth/sendov/tree/1ddea92d89f951a0a7cbbffa6c267cf7e6640b1d +[4] https://github.com/pickhardt/sendov-explicit-threshold diff --git a/docs/degree-uniform/README.md b/docs/degree-uniform/README.md new file mode 100644 index 0000000..22baa24 --- /dev/null +++ b/docs/degree-uniform/README.md @@ -0,0 +1,37 @@ +# Degree-uniform endgame: review material + +Local contribution: **subfish-zhou (GitHub)**. Original authorship and mathematical +attributions are retained in the note and repository notices. + +- [Mathematical review note](MATHEMATICAL_NOTE.md): scalar theorem, inherited inputs, + the degree-ray argument and the limits of this exposition. +- [Exact coefficient data](CERTIFICATES.json): three complete identities of degrees + 53/47/47 and their low-degree homogeneous factors. +- [Replay script](check_note_certificates.py) and [local result](CERTIFICATE_REPLAY.json). + +The note describes mathematical source commit +`c7f25171a07b916a678b0df1dbd32ee55eb5e4df`. These accompanying documents do not change +that proof. The later 9/9/18 experiment is not included. + +With Python and SymPy 1.13.1 available, run from the repository root: + +```sh +python docs/degree-uniform/check_note_certificates.py +``` + +The script reads the adjacent note and data, reconstructs the complete rational +polynomial identities, and rejects three internal-coefficient mutations. It writes +`CERTIFICATE_REPLAY.json` beside itself. This is supplementary exact-arithmetic +verification, not a replacement for the analytic lemmas, Lean's kernel, or the +repository's documented proof audit. + +**Intermediate API migration:** `Sendov.polar_origin_incompatible` now requires +`6 <= n`, rather than upstream's `5 <= n`. The final conjecture statements are +unchanged; degree five uses the existing polynomial low-degree argument in +`Interior`. The former standalone scalar interface is not preserved at degree five. +The old `R`/FiniteRange/LargeDegree route is retired, not retained as a second proof. + +Tao's original production history remains accessible in the fixed upstream tree: +[README and provenance](https://github.com/teorth/sendov/tree/1ddea92d89f951a0a7cbbffa6c267cf7e6640b1d), +[original making-of document](https://github.com/teorth/sendov/blob/1ddea92d89f951a0a7cbbffa6c267cf7e6640b1d/docs/making-of.md). +The new local development does not replace attribution of that original work. diff --git a/docs/degree-uniform/check_note_certificates.py b/docs/degree-uniform/check_note_certificates.py new file mode 100644 index 0000000..808d341 --- /dev/null +++ b/docs/degree-uniform/check_note_certificates.py @@ -0,0 +1,123 @@ +"""Exact replay of the note's displayed formulas and coefficient data. +Requires SymPy; does not read Lean or prove the analytic majorizations. +""" +import ast +import copy +import json +import re +from pathlib import Path +import sympy as s + +ROOT = Path(__file__).resolve().parent +a = s.Symbol('a') +values = {'a': a} +functions = {} + + +def expression(node, env): + if isinstance(node, ast.Constant) and type(node.value) is int: + return s.Integer(node.value) + if isinstance(node, ast.Name): + return env[node.id] + if isinstance(node, ast.UnaryOp) and isinstance(node.op, (ast.UAdd, ast.USub)): + v = expression(node.operand, env) + return v if isinstance(node.op, ast.UAdd) else -v + if isinstance(node, ast.BinOp): + x, y = expression(node.left, env), expression(node.right, env) + if isinstance(node.op, ast.Add): return x + y + if isinstance(node.op, ast.Sub): return x - y + if isinstance(node.op, ast.Mult): return x * y + if isinstance(node.op, ast.Div): return x / y + if isinstance(node.op, ast.Pow): + assert y.is_Integer and 0 <= y <= 60 + return x ** y + if isinstance(node, ast.Call) and isinstance(node.func, ast.Name) and not node.keywords: + names, body = functions[node.func.id] + assert len(names) == len(node.args) + local = dict(values) + local.update(zip(names, [expression(v, env) for v in node.args])) + return expression(body, local) + raise ValueError(f'Unsupported formula syntax: {ast.dump(node)}') + + +note = (ROOT / 'MATHEMATICAL_NOTE.md').read_text() +blocks = re.findall(r'```text\n(.*?)```', note, re.S) +assert len(blocks) == 2 +statements = [] +for block in blocks: + for line in block.splitlines(): + if not line.strip(): continue + if line.startswith(' '): + statements[-1] += ' ' + line.strip() + else: + statements.append(line) +for statement in statements: + left, right = statement.split('=', 1) + left = left.strip() + tree = ast.parse(right.strip().replace('^', '**'), mode='eval').body + function = re.fullmatch(r'(\w+)\(([^)]*)\)', left) + if function: + functions[function[1]] = ([x.strip() for x in function[2].split(',')], tree) + else: + assert left not in values + values[left] = expression(tree, values) + + +def exact_identity(poly, coefficients, degree, lower, upper, scale): + assert len(coefficients) == degree + 1 + lhs = s.Poly(scale * poly, a, domain=s.QQ) + x, y = s.Poly(a - lower, a), s.Poly(upper - a, a) + rhs = sum((s.Integer(c) * x**i * y**(degree-i) + for i, c in enumerate(coefficients)), s.Poly(0, a)) + return (lhs - rhs).is_zero + + +def check(data): + expected = [('gap1', 2, 17, 53, 15**53), + ('gapLow', 2, s.Rational(5, 2), 47, 1), + ('gapHigh', s.Rational(5, 2), 17, 47, 29**47)] + assert len(data['certificates']) == len(expected) + rows = [] + for record, (name, lo, hi, degree, scale) in zip(data['certificates'], expected): + assert (record['gap'], s.Rational(record['lower']), s.Rational(record['upper']), + record['degree'], int(record['scale'])) == (name, lo, hi, degree, scale) + coefficients = [int(c) for c in record['coefficients']] + assert all(c > 0 for c in coefficients) + poly = s.Poly(s.cancel(values[name]), a, domain=s.QQ) + assert exact_identity(poly.as_expr(), coefficients, degree, lo, hi, scale), name + factors = record['low_degree_homogenizations'] + for factor, item in factors.items(): + assert factor.endswith('H') + assert exact_identity(values[factor[:-1]], item['coefficients'], + item['degree'], lo, hi, int(item['scale'])), factor + rows.append({'gap': name, 'degree': degree, 'identity': True, + 'coefficients': len(coefficients), 'factor_identities': len(factors), + 'factor_coefficients': sum(len(x['coefficients']) for x in factors.values())}) + return rows + + +def main(): + data = json.loads((ROOT / 'CERTIFICATES.json').read_text()) + rows = check(data) + rejected = [] + for i, record in enumerate(data['certificates']): + mutant = copy.deepcopy(data) + j = record['degree'] // 2 + mutant['certificates'][i]['coefficients'][j] = str(int(record['coefficients'][j]) + 1) + try: + check(mutant) + except AssertionError: + rejected.append(record['gap']) + else: + raise AssertionError('Interior-coefficient mutation was accepted') + assert sum(x['coefficients'] for x in rows) == 150 + assert sum(x['factor_coefficients'] for x in rows) == 71 + result = {'status': 'PASS', 'sympy_version': s.__version__, 'identities': rows, + 'interior_coefficient_mutants_rejected': rejected, + 'scope': 'Exact rational polynomial identities from displayed note formulas and JSON; not an analytic proof or Lean replay.'} + (ROOT / 'CERTIFICATE_REPLAY.json').write_text(json.dumps(result, indent=2) + '\n') + print(json.dumps(result, indent=2)) + + +if __name__ == '__main__': + main() diff --git a/scripts/LICENSE-APACHE-2.0.txt b/scripts/LICENSE-APACHE-2.0.txt index 44c57c5..10b7627 100644 --- a/scripts/LICENSE-APACHE-2.0.txt +++ b/scripts/LICENSE-APACHE-2.0.txt @@ -199,4 +199,3 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. - From ed1a7c2ede87323fd8ce7293722963a0fe32dad9 Mon Sep 17 00:00:00 2001 From: Methode Date: Mon, 14 Sep 2026 12:18:21 -0700 Subject: [PATCH 14/24] Formalize parameter-preserving middle and bulk budget algebra --- Sendov/Analytic/PaperBulkAlgebra.lean | 90 +++++++++++++++++++++++++++ docs/paper-formalization/STATUS.md | 68 ++++++++++++++++++++ tests/PaperBulkAlgebra.lean | 16 +++++ 3 files changed, 174 insertions(+) create mode 100644 Sendov/Analytic/PaperBulkAlgebra.lean create mode 100644 docs/paper-formalization/STATUS.md create mode 100644 tests/PaperBulkAlgebra.lean diff --git a/Sendov/Analytic/PaperBulkAlgebra.lean b/Sendov/Analytic/PaperBulkAlgebra.lean new file mode 100644 index 0000000..02f4210 --- /dev/null +++ b/Sendov/Analytic/PaperBulkAlgebra.lean @@ -0,0 +1,90 @@ +import Mathlib.Tactic.FieldSimp +import Mathlib.Tactic.Linarith +import Mathlib.Tactic.Positivity +import Mathlib.Tactic.Ring +import Mathlib.Data.Real.Basic + +/-! +# Parameter-preserving bulk budget + +The algebraic middle-region argument of first-origin-uniform/round5, §4. +These lemmas close the scalar budget from the stated integral estimate; +they do not assert that estimate or claim the complete uniform D theorem. +-/ + +namespace Sendov.PaperBulk + +/-- The middle-region cubic has an explicit positive decomposition. -/ +theorem middle_cubic_pos {a : ℝ} (ha : 1 / 3 ≤ a) (hb : a ≤ 4 / 5) : + 0 < 256 * a ^ 2 * (1 - a) - 24 * a ^ 2 - 16 := by + have h₁ : 0 ≤ (a - 1 / 3) * (536 / 225) := by positivity + have h₂ : 0 ≤ (a - 1 / 3) * (4 / 5 - a) * (256 * a + 872 / 15) := by + positivity + have hid : 256 * a ^ 2 * (1 - a) - 24 * a ^ 2 - 16 = + 8 / 27 + (a - 1 / 3) * (536 / 225) + + (a - 1 / 3) * (4 / 5 - a) * (256 * a + 872 / 15) := by ring + rw [hid] + linarith + +/-- All real m ≥ 256 satisfy the retained-a budget on the middle interval. -/ +theorem middle_budget {m a : ℝ} (hm : 256 ≤ m) + (ha : 1 / 3 ≤ a) (hb : a ≤ 4 / 5) : + 16 / (m * a ^ 2) + 24 / m < 1 - a := by + have hm0 : 0 < m := by linarith + have ha0 : 0 < a := by linarith + have hh : 0 ≤ 1 - a := by linarith + have hc := middle_cubic_pos ha hb + have hmul : 0 ≤ (m - 256) * a ^ 2 * (1 - a) := by positivity + have hp : 16 + 24 * a ^ 2 < (1 - a) * (m * a ^ 2) := by nlinarith + have hd : 0 < m * a ^ 2 := by positivity + calc + 16 / (m * a ^ 2) + 24 / m = (16 + 24 * a ^ 2) / (m * a ^ 2) := by + field_simp + _ < 1 - a := (div_lt_iff₀ hd).2 hp + +/-- A consumer of the analytic estimate, with strictness unchanged. -/ +theorem direct_budget_middle {m a T : ℝ} (hm : 256 ≤ m) + (ha : 1 / 3 ≤ a) (hb : a ≤ 4 / 5) + (hT : T < 16 / (m * a ^ 2) + 24 / m) : + T < 1 - m * a / (m + 1) := by + have hm0 : 0 < m + 1 := by linarith + have ha0 : 0 < a := by linarith + have hp : 0 < a / (m + 1) := div_pos ha0 hm0 + have he : 1 - m * a / (m + 1) = 1 - a + a / (m + 1) := by + field_simp + ring + rw [he] + have ht := hT.trans (middle_budget hm ha hb) + linarith + +/-- The same retained-a estimate closes the large-a, large-ray region. -/ +theorem large_ray_budget {m a : ℝ} (hm : 0 < m) (ha : 4 / 5 ≤ a) + (hscale : 49 ≤ m * (1 - a)) : + 16 / (m * a ^ 2) + 24 / m ≤ 1 - a := by + have ha0 : 0 < a := by linarith + have ha2 : (4 / 5 : ℝ) ^ 2 ≤ a ^ 2 := by nlinarith + have hd : 0 < m * a ^ 2 := by positivity + have hfirst : 16 / (m * a ^ 2) ≤ 25 / m := by + apply (div_le_iff₀ hd).2 + have he : 25 / m * (m * a ^ 2) = 25 * a ^ 2 := by field_simp + rw [he] + nlinarith + have hlast : 49 / m ≤ 1 - a := (div_le_iff₀ hm).2 (by nlinarith [hscale]) + calc + 16 / (m * a ^ 2) + 24 / m ≤ 25 / m + 24 / m := by linarith + _ = 49 / m := by ring + _ ≤ 1 - a := hlast + +/-- Small-a closure of the global two-thirds bound. -/ +theorem direct_budget_small {m a T : ℝ} (hm : 0 ≤ m) + (ha : 0 < a) (hb : a ≤ 1 / 3) (hT : T < 2 / 3) : + T < 1 - m * a / (m + 1) := by + have hd : 0 < m + 1 := by linarith + have he : 1 - m * a / (m + 1) = 1 - a + a / (m + 1) := by + field_simp + ring + have hp := div_pos ha hd + rw [he] + linarith + +end Sendov.PaperBulk diff --git a/docs/paper-formalization/STATUS.md b/docs/paper-formalization/STATUS.md new file mode 100644 index 0000000..4187ac6 --- /dev/null +++ b/docs/paper-formalization/STATUS.md @@ -0,0 +1,68 @@ +# Paper formalization acceptance ledger + +Baseline: `0a4e966c41e1287f92d305d3bad8e70c8c295dde`. +Integration branch: `formalize/paper-results-20260914`. +Status: **IN PROGRESS**, not complete and not a uniform D proof. + +## Acceptance units + +- Existing boundary average-square rigidity: re-integrate refined production + source and verify Solution/Conjecture consumers. Worker `existing`. +- Existing first-origin m=5,6: integrate production namespace and verify + complete polar/first-origin contradiction, not only scalar lemmas. Worker `existing`. +- Existing real-split collinear reciprocal/moment results: integrate and verify; + complex affine transport and general equality classification remain distinct + unfinished mathematics, not previously completed formalizations. Worker `existing`. +- Raw polar geometry and stronger `b ≤ α/(3+α) ≤ λ/(3+λ)`: worker `polar`. +- Finite Taylor integral budget (T): worker `taylor`. +- Latest near-endpoint rational algebra: worker `near`; full near-endpoint + result additionally needs Taylor, parameter conversions and integer endpoint + decay. Do not count algebra alone as raw-polar D. +- Latest near-endpoint `m≥7, m(1-a)≤2/5`, gap `>(1-a)/1000`: pending assembly. +- Old narrower near-endpoint **stronger margins**: pending preservation. + Round3 `λ≤1/10` gap `>h/5`; round5 `λ≤1/5` gap `>h/80`. + Weaker old cutoffs can be corollaries; stronger margins cannot be discarded. +- Two-endpoint quadratic integral estimates, polar endpoint/log lower bounds, + sharp Laplace estimate (S), finite-ray quantitative tails: pending. +- Round5 full `m≥256` all-a theorem: pending the above analytic inputs and + finite-ray comparisons. The all-a theorem is NOT currently formalized. +- Round4 stronger bound `T<3/5` for m≥512: preserve separately; does not follow + merely from the weaker round5 bound `T<2/3`. +- Curvature-corrected polar secant and rational sufficient gate F_sec: pending. + Universal positivity of F_sec was never proved and is not an acceptance claim. +- Finite centered expansion including H terms, coefficient estimate from finite + Fourier/AM-GM, C-budget: pending. Universal C-near was never proved. +- Exact full-polar mean-half counterexample: pending Lean translation; it is + NOT a D or Sendov counterexample. +- Rational diagnostic certificates: keep distinct from universal proofs; + scoped certified intervals are eligible theorems, floating grids are not. + +## Accepted first independent module + +`Sendov/Analytic/PaperBulkAlgebra.lean` contains: + +- `Sendov.PaperBulk.middle_cubic_pos`: an explicit positive decomposition, + avoiding differentiation/concavity infrastructure for the middle interval. +- `middle_budget`: for real m≥256 and 1/3≤a≤4/5, + `16/(m*a²)+24/m < 1-a`. +- `direct_budget_middle`: converts the explicitly hypothesized analytic bound + on T to D. This is an honest consumer, not a proof of its analytic premise. +- `large_ray_budget`: for m>0, a≥4/5 and m(1-a)≥49, + `16/(m*a²)+24/m ≤ 1-a`. +- `direct_budget_small`: consumes T<2/3 for 0 Date: Mon, 14 Sep 2026 12:33:47 -0700 Subject: [PATCH 15/24] Integrate checked research proofs and actual polar Taylor inputs --- Sendov.lean | 1 + Sendov/Analytic/FirstOriginAlgebra.lean | 122 ++ Sendov/Analytic/FirstOriginBounds.lean | 166 ++ Sendov/Analytic/FirstOriginSmall.lean | 158 ++ Sendov/Analytic/PaperNearAlgebra.lean | 218 +++ Sendov/Analytic/PaperPolar.lean | 189 ++ Sendov/Analytic/PaperTaylor.lean | 305 ++++ Sendov/Boundary.lean | 118 +- Sendov/Collinear/Balance.lean | 72 + Sendov/Collinear/Diameter.lean | 70 + Sendov/Collinear/Gate.lean | 161 ++ Sendov/Collinear/Mass.lean | 104 ++ Sendov/Collinear/Moment.lean | 52 + Sendov/Interior.lean | 9 +- docs/paper-formalization/STATUS.md | 16 + docs/paper-formalization/checkpoint1.json | 9 + .../paper-formalization/imported-sources.json | 114 ++ tests/BoundaryAudit.lean | 44 + tests/BoundaryContracts.lean | 17 + tests/BoundaryProbe.lean | 141 ++ tests/BoundaryWiring.lean | 22 + tests/CollinearAcceptance.lean | 82 + tests/CollinearRound2Tests.lean | 102 ++ tests/CollinearTests.lean | 46 + tests/FirstOriginAudit.lean | 62 + tests/FirstOriginWiring.lean | 32 + tests/Localanalytic.lean | 9 +- tests/PaperNearAlgebra.lean | 36 + tests/PaperPolar.lean | 46 + tests/PaperTaylor.lean | 21 + .../parent-integrated01-receipts.json | 1582 +++++++++++++++++ tests/verify_existing_integration.py | 63 + 32 files changed, 4117 insertions(+), 72 deletions(-) create mode 100644 Sendov/Analytic/FirstOriginAlgebra.lean create mode 100644 Sendov/Analytic/FirstOriginBounds.lean create mode 100644 Sendov/Analytic/FirstOriginSmall.lean create mode 100644 Sendov/Analytic/PaperNearAlgebra.lean create mode 100644 Sendov/Analytic/PaperPolar.lean create mode 100644 Sendov/Analytic/PaperTaylor.lean create mode 100644 Sendov/Collinear/Balance.lean create mode 100644 Sendov/Collinear/Diameter.lean create mode 100644 Sendov/Collinear/Gate.lean create mode 100644 Sendov/Collinear/Mass.lean create mode 100644 Sendov/Collinear/Moment.lean create mode 100644 docs/paper-formalization/checkpoint1.json create mode 100644 docs/paper-formalization/imported-sources.json create mode 100644 tests/BoundaryAudit.lean create mode 100644 tests/BoundaryContracts.lean create mode 100644 tests/BoundaryProbe.lean create mode 100644 tests/BoundaryWiring.lean create mode 100644 tests/CollinearAcceptance.lean create mode 100644 tests/CollinearRound2Tests.lean create mode 100644 tests/CollinearTests.lean create mode 100644 tests/FirstOriginAudit.lean create mode 100644 tests/FirstOriginWiring.lean create mode 100644 tests/PaperNearAlgebra.lean create mode 100644 tests/PaperPolar.lean create mode 100644 tests/PaperTaylor.lean create mode 100644 tests/integration-existing/parent-integrated01-receipts.json create mode 100644 tests/verify_existing_integration.py diff --git a/Sendov.lean b/Sendov.lean index e9215f0..23d37c0 100644 --- a/Sendov.lean +++ b/Sendov.lean @@ -1 +1,2 @@ import Sendov.Conjecture +import Sendov.Collinear.Moment diff --git a/Sendov/Analytic/FirstOriginAlgebra.lean b/Sendov/Analytic/FirstOriginAlgebra.lean new file mode 100644 index 0000000..d916c32 --- /dev/null +++ b/Sendov/Analytic/FirstOriginAlgebra.lean @@ -0,0 +1,122 @@ +import Sendov.Analytic.Origin + +/-! Finite polynomial integrals and positive decompositions for degrees five and six. +No sampling, general Bernstein framework, or endpoint strictness assumptions. -/ + +namespace Sendov.FirstOriginSmall + +noncomputable def B (a t : ℝ) : ℝ := 1 - a * (1 + a) * t + a ^ 2 * t ^ 2 +noncomputable def Q (a : ℝ) : ℝ := + 120 + 170 * a + 102 * a ^ 2 - 29 * a ^ 3 - 117 * a ^ 4 - 93 * a ^ 5 - 61 * a ^ 6 + 13 * a ^ 7 + 25 * a ^ 8 + 9 * a ^ 9 + a ^ 10 + +lemma integral_quadratic_cube (c d e : ℝ) : + (∫ t in (0 : ℝ)..1, (c + d * t + e * t ^ 2) ^ 3) = + c ^ 3 + 3 * c ^ 2 * d / 2 + (3 * c ^ 2 * e + 3 * c * d ^ 2) / 3 + (6 * c * d * e + d ^ 3) / 4 + (3 * c * e ^ 2 + 3 * d ^ 2 * e) / 5 + 3 * d * e ^ 2 / 6 + e ^ 3 / 7 := by + have hex : (fun t : ℝ => (c + d * t + e * t ^ 2) ^ 3) = + (fun t => c ^ 3 + (3 * c ^ 2 * d) * t ^ 1 + (3 * c ^ 2 * e + 3 * c * d ^ 2) * t ^ 2 + (6 * c * d * e + d ^ 3) * t ^ 3 + (3 * c * e ^ 2 + 3 * d ^ 2 * e) * t ^ 4 + (3 * d * e ^ 2) * t ^ 5 + e ^ 3 * t ^ 6) := by + funext t; ring + rw [hex] + simp (disch := exact Continuous.intervalIntegrable (by fun_prop) _ _) + only [intervalIntegral.integral_add, intervalIntegral.integral_const_mul, + intervalIntegral.integral_const, integral_pow, integral_id] + norm_num + <;> ring + +lemma integral_t_quadratic_sq (c d e : ℝ) : + (∫ t in (0 : ℝ)..1, t * (c + d * t + e * t ^ 2) ^ 2) = + c ^ 2 / 2 + 2 * c * d / 3 + (2 * c * e + d ^ 2) / 4 + 2 * d * e / 5 + e ^ 2 / 6 := by + have hex : (fun t : ℝ => t * (c + d * t + e * t ^ 2) ^ 2) = + (fun t => c ^ 2 * t ^ 1 + (2 * c * d) * t ^ 2 + (2 * c * e + d ^ 2) * t ^ 3 + (2 * d * e) * t ^ 4 + e ^ 2 * t ^ 5) := by + funext t; ring + rw [hex] + simp (disch := exact Continuous.intervalIntegrable (by fun_prop) _ _) + only [intervalIntegral.integral_add, intervalIntegral.integral_const_mul, integral_pow, integral_id] + norm_num + <;> ring + +lemma integral_t_linear_fifth (a : ℝ) : + (∫ t in (0 : ℝ)..1, t * (1 - a * t) ^ 5) = + 1 / 2 - 5 * a / 3 + 5 * a ^ 2 / 2 - 2 * a ^ 3 + 5 * a ^ 4 / 6 - a ^ 5 / 7 := by + have hex : (fun t : ℝ => t * (1 - a * t) ^ 5) = + (fun t => t + (-5 * a) * t ^ 2 + (10 * a ^ 2) * t ^ 3 + (-10 * a ^ 3) * t ^ 4 + (5 * a ^ 4) * t ^ 5 + (-a ^ 5) * t ^ 6) := by + funext t; ring + rw [hex] + simp (disch := exact Continuous.intervalIntegrable (by fun_prop) _ _) + only [intervalIntegral.integral_add, intervalIntegral.integral_const_mul, integral_pow, integral_id] + norm_num + <;> ring + +lemma integral_sq_linear_cube (a : ℝ) : + (∫ t in (0 : ℝ)..1, t ^ 2 * (1 - a * t) ^ 3) = 1 / 3 - 3 * a / 4 + 3 * a ^ 2 / 5 - a ^ 3 / 6 := by + have hex : (fun t : ℝ => t ^ 2 * (1 - a * t) ^ 3) = + (fun t => t ^ 2 + (-3 * a) * t ^ 3 + (3 * a ^ 2) * t ^ 4 + (-a ^ 3) * t ^ 5) := by + funext t; ring + rw [hex] + simp (disch := exact Continuous.intervalIntegrable (by fun_prop) _ _) + only [intervalIntegral.integral_add, intervalIntegral.integral_const_mul, integral_pow] + norm_num + <;> ring + +lemma polar_cube_integral (a : ℝ) : + 1 - (∫ t in (0 : ℝ)..1, Ppolar a ((1 + a) / 2) t ^ (3 : ℕ)) = (1 - a) ^ 2 * Q a / 140 := by + have hp : (fun t => Ppolar a ((1 + a) / 2) t) = + (fun t => a ^ 2 + (a * (1 - a ^ 2) * (1 + a)) * t + (1 - a ^ 2) ^ 2 * t ^ 2) := by + funext t; unfold Ppolar; ring + simp_rw [hp] + rw [integral_quadratic_cube] + unfold Q + ring + +lemma Q_lower {a : ℝ} (ha0 : 0 ≤ a) (ha1 : a ≤ 1) : 92 ≤ Q a := by + have h3 : a ^ 3 ≤ a ^ 2 := pow_le_pow_of_le_one ha0 ha1 (by omega : 2 ≤ 3) + have h4 : a ^ 4 ≤ a ^ 2 := pow_le_pow_of_le_one ha0 ha1 (by omega : 2 ≤ 4) + have h5 : a ^ 5 ≤ a ^ 2 := pow_le_pow_of_le_one ha0 ha1 (by omega : 2 ≤ 5) + have h6 : a ^ 6 ≤ a ^ 2 := pow_le_pow_of_le_one ha0 ha1 (by omega : 2 ≤ 6) + have h2 : a ^ 2 ≤ a := by nlinarith + unfold Q + nlinarith [pow_nonneg ha0 7, pow_nonneg ha0 8, pow_nonneg ha0 9, pow_nonneg ha0 10] + +lemma polar_cube_lt_one {a : ℝ} (ha0 : 0 < a) (ha1 : a < 1) : + (∫ t in (0 : ℝ)..1, Ppolar a ((1 + a) / 2) t ^ (3 : ℕ)) < 1 := by + have hQ := Q_lower ha0.le ha1.le + have h := polar_cube_integral a + have hg : 0 < (1 - a) ^ 2 * Q a := mul_pos (sq_pos_of_pos (by linarith)) (by linarith) + linarith + +lemma fifth_sixth_majorant {y : ℝ} (hy : 0 ≤ y) : 6 * y ^ 5 ≤ 1 + 5 * y ^ 6 := by + have hid : 1 + 5 * y ^ 6 - 6 * y ^ 5 = (y - 1) ^ 2 * (5 * y ^ 4 + 4 * y ^ 3 + 3 * y ^ 2 + 2 * y + 1) := by ring + have hp : 0 ≤ (y - 1) ^ 2 * (5 * y ^ 4 + 4 * y ^ 3 + 3 * y ^ 2 + 2 * y + 1) := by positivity + linarith + +lemma five_halves_majorant {u w : ℝ} (hu : 0 ≤ u) (huw : u ≤ w) (hw : w ≤ 1) : + w ^ 5 ≤ u ^ 5 + (5 / 2 : ℝ) * u ^ 3 * (w ^ 2 - u ^ 2) + (15 / 8 : ℝ) * (w ^ 2 - u ^ 2) ^ 2 := by + have hid : u ^ 5 + (5 / 2 : ℝ) * u ^ 3 * (w ^ 2 - u ^ 2) + (15 / 8 : ℝ) * (w ^ 2 - u ^ 2) ^ 2 - w ^ 5 = + (15 / 8 : ℝ) * (1 - w) * (w ^ 2 - u ^ 2) ^ 2 + (w - u) ^ 3 * (5 * u ^ 2 + (35 / 8 : ℝ) * u * (w - u) + (7 / 8 : ℝ) * (w - u) ^ 2) := by ring + have hd : 0 ≤ w - u := sub_nonneg.mpr huw + have hp : 0 ≤ (15 / 8 : ℝ) * (1 - w) * (w ^ 2 - u ^ 2) ^ 2 + (w - u) ^ 3 * (5 * u ^ 2 + (35 / 8 : ℝ) * u * (w - u) + (7 / 8 : ℝ) * (w - u) ^ 2) := by + have : 0 ≤ 1 - w := sub_nonneg.mpr hw + positivity + linarith + +lemma upper_five_gap {a : ℝ} (ha0 : 0 < a) (ha1 : a < 1) : + (1 - a) ^ 2 + 5 * a ^ 2 * (∫ t in (0 : ℝ)..1, t * (B a t) ^ 2) < 1 - 5 * a / 6 := by + have he : (fun t => B a t) = (fun t => 1 + (-a * (1 + a)) * t + a ^ 2 * t ^ 2) := by + funext t; unfold B; ring + simp_rw [he] + rw [integral_t_quadratic_sq] + have hh : 0 < 1 - a := by linarith + have hp : 0 < a * (1 - a) * (14 * (1 - a) ^ 4 + 28 * a * (1 - a) ^ 3 + 12 * a ^ 2 * (1 - a) ^ 2 + 3 * a ^ 3 * (1 - a) + 6 * a ^ 4) / 12 := by positivity + have hid : 1 - 5 * a / 6 - ((1 - a) ^ 2 + 5 * a ^ 2 * (1 ^ 2 / 2 + 2 * 1 * (-a * (1 + a)) / 3 + (2 * 1 * a ^ 2 + (-a * (1 + a)) ^ 2) / 4 + 2 * (-a * (1 + a)) * a ^ 2 / 5 + (a ^ 2) ^ 2 / 6)) = + a * (1 - a) * (14 * (1 - a) ^ 4 + 28 * a * (1 - a) ^ 3 + 12 * a ^ 2 * (1 - a) ^ 2 + 3 * a ^ 3 * (1 - a) + 6 * a ^ 4) / 12 := by ring + linarith + +lemma upper_six_gap {a : ℝ} (ha0 : 0 < a) (ha1 : a < 1) : + (1 - a) ^ 3 + 6 * a ^ 2 * ((∫ t in (0 : ℝ)..1, t * (1 - a * t) ^ 5) + (5 / 2 : ℝ) * a * (1 - a) * (∫ t in (0 : ℝ)..1, t ^ 2 * (1 - a * t) ^ 3) + (15 / 32 : ℝ) * a ^ 2 * (1 - a) ^ 2) < 1 - 6 * a / 7 := by + rw [integral_t_linear_fifth, integral_sq_linear_cube] + have hh : 0 < 1 - a := by linarith + have hp : 0 < a * (1 - a) * (240 * (1 - a) ^ 5 + 768 * a * (1 - a) ^ 4 + 912 * a ^ 2 * (1 - a) ^ 3 + 593 * a ^ 3 * (1 - a) ^ 2 + 93 * a ^ 4 * (1 - a) + 68 * a ^ 5) / 112 := by positivity + have hid : 1 - 6 * a / 7 - ((1 - a) ^ 3 + 6 * a ^ 2 * ((1 / 2 - 5 * a / 3 + 5 * a ^ 2 / 2 - 2 * a ^ 3 + 5 * a ^ 4 / 6 - a ^ 5 / 7) + (5 / 2 : ℝ) * a * (1 - a) * (1 / 3 - 3 * a / 4 + 3 * a ^ 2 / 5 - a ^ 3 / 6) + (15 / 32 : ℝ) * a ^ 2 * (1 - a) ^ 2)) = + a * (1 - a) * (240 * (1 - a) ^ 5 + 768 * a * (1 - a) ^ 4 + 912 * a ^ 2 * (1 - a) ^ 3 + 593 * a ^ 3 * (1 - a) ^ 2 + 93 * a ^ 4 * (1 - a) + 68 * a ^ 5) / 112 := by ring + linarith + +end Sendov.FirstOriginSmall diff --git a/Sendov/Analytic/FirstOriginBounds.lean b/Sendov/Analytic/FirstOriginBounds.lean new file mode 100644 index 0000000..39563a6 --- /dev/null +++ b/Sendov/Analytic/FirstOriginBounds.lean @@ -0,0 +1,166 @@ +import Sendov.Analytic.FirstOriginAlgebra + +/-! The raw polar mean bound and the complete T budgets on 0 < a < 1. +The five/six split is intentional; no extrapolation to larger degrees. -/ + +namespace Sendov.FirstOriginSmall + +lemma sqrt_pow_eq_rpow {z : ℝ} (hz : 0 ≤ z) (k : ℕ) : + (Real.sqrt z) ^ k = z ^ ((k : ℝ) / 2) := by + rw [Real.sqrt_eq_rpow, ← Real.rpow_natCast, ← Real.rpow_mul hz] + congr 1 + ring + +lemma Ppolar_nonneg_small {a x t : ℝ} (ha : 0 ≤ a) (ha1 : a ≤ 1) + (hx : -1 ≤ x) (ht : 0 ≤ t) : 0 ≤ Ppolar a x t := by + have hd : 0 ≤ 1 - a ^ 2 := by nlinarith + have hid : Ppolar a x t = (a - (1 - a ^ 2) * t) ^ 2 + 2 * a * (1 - a ^ 2) * t * (x + 1) := by + unfold Ppolar; ring + rw [hid] + have : 0 ≤ x + 1 := by linarith + positivity + +lemma Ppolar_le_half {a x t : ℝ} (ha : 0 ≤ a) (ha1 : a ≤ 1) + (hx : x ≤ (1 + a) / 2) (ht : 0 ≤ t) : Ppolar a x t ≤ Ppolar a ((1 + a) / 2) t := by + have hd : 0 ≤ 1 - a ^ 2 := by nlinarith + have hh : 0 ≤ (1 + a) / 2 - x := sub_nonneg.mpr hx + have hp := mul_nonneg (mul_nonneg (mul_nonneg (by positivity : 0 ≤ 2 * a) hd) ht) hh + unfold Ppolar + nlinarith only [hp] + +lemma polar_mean_gt_half_add_one {n : ℕ} (hn : n = 6 ∨ n = 7) {a x : ℝ} + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) + (hpolar : 1 ≤ ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) : + (1 + a) / 2 < x := by + by_contra hx + have hx : x ≤ (1 + a) / 2 := le_of_not_gt hx + have hcube := polar_cube_lt_one ha0 ha1 + have hcp : Continuous (fun t => Ppolar a ((1 + a) / 2) t ^ (3 : ℕ)) := by + exact (continuous_Ppolar _ _).pow 3 + rcases hn with rfl | rfl + · norm_num at hpolar + have hcont : Continuous (fun t => Ppolar a x t ^ (5 / 2 : ℝ)) := + (continuous_rpow_const (by norm_num : (0 : ℝ) ≤ 5 / 2)).comp (continuous_Ppolar a x) + have hi := intervalIntegral.integral_mono_on (μ := MeasureTheory.volume) (by norm_num : (0 : ℝ) ≤ 1) + (hcont.intervalIntegrable 0 1) + ((continuous_const.add (continuous_const.mul hcp)).intervalIntegrable 0 1) + (show ∀ t ∈ Set.Icc (0 : ℝ) 1, + Ppolar a x t ^ (5 / 2 : ℝ) ≤ (1 / 6 : ℝ) + (5 / 6 : ℝ) * Ppolar a ((1 + a) / 2) t ^ (3 : ℕ) from by + intro t ht + have hp0 := Ppolar_nonneg_small ha0.le ha1.le hx0 ht.1 + have hp1 := Ppolar_le_half ha0.le ha1.le hx ht.1 + have hz : 0 ≤ Ppolar a ((1 + a) / 2) t := hp0.trans hp1 + have hm := Real.rpow_le_rpow hp0 hp1 (by norm_num : (0 : ℝ) ≤ 5 / 2) + have hf := fifth_sixth_majorant (Real.sqrt_nonneg (Ppolar a ((1 + a) / 2) t)) + rw [sqrt_pow_eq_rpow hz 5, sqrt_pow_eq_rpow hz 6] at hf + norm_num [Real.rpow_natCast] at hf + linarith) + dsimp only [Pi.add_apply, Pi.mul_apply, Pi.pow_apply] at hi + simp (disch := exact Continuous.intervalIntegrable (by fun_prop) _ _) + only [intervalIntegral.integral_add, intervalIntegral.integral_const_mul, + intervalIntegral.integral_const] at hi + norm_num at hi + linarith + · norm_num [Real.rpow_natCast] at hpolar + have hi := intervalIntegral.integral_mono_on (μ := MeasureTheory.volume) (by norm_num : (0 : ℝ) ≤ 1) + (((continuous_Ppolar a x).pow 3).intervalIntegrable 0 1) + (hcp.intervalIntegrable 0 1) (show ∀ t ∈ Set.Icc (0 : ℝ) 1, + Ppolar a x t ^ (3 : ℕ) ≤ Ppolar a ((1 + a) / 2) t ^ (3 : ℕ) from by + intro t ht + exact pow_le_pow_left₀ (Ppolar_nonneg_small ha0.le ha1.le hx0 ht.1) + (Ppolar_le_half ha0.le ha1.le hx ht.1) 3) + dsimp only [Pi.pow_apply] at hi + linarith + +lemma beta_B_bounds {a x t : ℝ} (ha0 : 0 ≤ a) (ha1 : a ≤ 1) + (hx : (1 + a) / 2 ≤ x) (hx1 : x ≤ 1) (ht0 : 0 ≤ t) (ht1 : t ≤ 1) : + 0 ≤ QQ (a * x) (a ^ 2) t ∧ QQ (a * x) (a ^ 2) t ≤ B a t ∧ + (1 - a * t) ^ 2 ≤ B a t ∧ B a t ≤ 1 ∧ 0 ≤ 1 - a * t := by + have hat : a * t ≤ 1 := (mul_le_mul_of_nonneg_left ht1 ha0).trans (by simpa using ha1) + have hq : QQ (a * x) (a ^ 2) t = (1 - a * t) ^ 2 + 2 * a * t * (1 - x) := by unfold QQ; ring + have hb : B a t = (1 - a * t) ^ 2 + a * (1 - a) * t := by unfold B; ring + have hdiff : B a t - QQ (a * x) (a ^ 2) t = 2 * a * t * (x - (1 + a) / 2) := by + unfold B QQ; ring + have hupper : 1 - B a t = a * t * (1 + a - a * t) := by unfold B; ring + have hp : 0 ≤ a * (1 - a) * t := by positivity + have hp2 : 0 ≤ 2 * a * t * (1 - x) := by positivity + have hp3 : 0 ≤ 2 * a * t * (x - (1 + a) / 2) := by positivity + have hp4 : 0 ≤ a * t * (1 + a - a * t) := by + have : 0 ≤ 1 + a - a * t := by linarith + positivity + constructor + · rw [hq]; positivity + constructor + · linarith + constructor + · linarith + constructor <;> linarith + +lemma B_five_halves {a t : ℝ} (ha0 : 0 ≤ a) (ha1 : a ≤ 1) + (ht0 : 0 ≤ t) (ht1 : t ≤ 1) : + B a t ^ (5 / 2 : ℝ) ≤ (1 - a * t) ^ 5 + (5 / 2 : ℝ) * a * (1 - a) * t * (1 - a * t) ^ 3 + (15 / 8 : ℝ) * a ^ 2 * (1 - a) ^ 2 * t ^ 2 := by + obtain ⟨_, _, hu2, hb1, hu⟩ := beta_B_bounds ha0 ha1 (le_refl ((1 + a) / 2)) + (by linarith : (1 + a) / 2 ≤ 1) ht0 ht1 + have hb0 : 0 ≤ B a t := (sq_nonneg _).trans hu2 + have hsq := Real.sq_sqrt hb0 + have huw : 1 - a * t ≤ Real.sqrt (B a t) := by + nlinarith [Real.sqrt_nonneg (B a t)] + have hw1 : Real.sqrt (B a t) ≤ 1 := by + nlinarith [Real.sqrt_nonneg (B a t)] + have h := five_halves_majorant hu huw hw1 + rw [sqrt_pow_eq_rpow hb0 5, hsq] at h + have he : B a t - (1 - a * t) ^ 2 = a * (1 - a) * t := by unfold B; ring + rw [he] at h + convert h using 1 <;> ring + +lemma direct_budget_five {a x : ℝ} (ha0 : 0 < a) (ha1 : a < 1) + (hx : (1 + a) / 2 ≤ x) (hx1 : x ≤ 1) : + QQ (a * x) (a ^ 2) 1 ^ (5 / 2 : ℝ) + 5 * a ^ 2 * (∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (2 : ℕ)) < 1 - 5 * a / 6 := by + have hend := beta_B_bounds ha0.le ha1.le hx hx1 (by norm_num : (0 : ℝ) ≤ 1) le_rfl + have heB : B a 1 = 1 - a := by unfold B; ring + have he := Real.rpow_le_rpow hend.1 hend.2.1 (by norm_num : (0 : ℝ) ≤ 5 / 2) + rw [heB] at he + have he2 := Real.rpow_le_rpow_of_exponent_ge (by linarith : 0 < 1 - a) + (by linarith : 1 - a ≤ 1) (by norm_num : (2 : ℝ) ≤ 5 / 2) + norm_num [Real.rpow_natCast] at he2 + have hi : (∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (2 : ℕ)) ≤ + ∫ t in (0 : ℝ)..1, t * (B a t) ^ 2 := by + apply intervalIntegral.integral_mono_on (by norm_num) + (Continuous.intervalIntegrable (by unfold QQ; fun_prop) _ _) + (Continuous.intervalIntegrable (by unfold B; fun_prop) _ _) + intro t ht + have hb := beta_B_bounds ha0.le ha1.le hx hx1 ht.1 ht.2 + exact mul_le_mul_of_nonneg_left (pow_le_pow_left₀ hb.1 hb.2.1 2) ht.1 + have hmul := mul_le_mul_of_nonneg_left hi (by positivity : 0 ≤ 5 * a ^ 2) + have hg := upper_five_gap ha0 ha1 + linarith + +lemma direct_budget_six {a x : ℝ} (ha0 : 0 < a) (ha1 : a < 1) + (hx : (1 + a) / 2 ≤ x) (hx1 : x ≤ 1) : + QQ (a * x) (a ^ 2) 1 ^ (3 : ℕ) + 6 * a ^ 2 * (∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (5 / 2 : ℝ)) < 1 - 6 * a / 7 := by + have hend := beta_B_bounds ha0.le ha1.le hx hx1 (by norm_num : (0 : ℝ) ≤ 1) le_rfl + have heB : B a 1 = 1 - a := by unfold B; ring + have he := pow_le_pow_left₀ hend.1 hend.2.1 3 + rw [heB] at he + have hi : (∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (5 / 2 : ℝ)) ≤ + ∫ t in (0 : ℝ)..1, (t * (1 - a * t) ^ 5 + ((5 / 2 : ℝ) * a * (1 - a)) * (t ^ 2 * (1 - a * t) ^ 3) + ((15 / 8 : ℝ) * a ^ 2 * (1 - a) ^ 2) * t ^ 3) := by + apply intervalIntegral.integral_mono_on (by norm_num) + (by simpa only [pow_one] using + (continuous_pow_mul_QQ (a * x) (a ^ 2) 1 (by norm_num : (0 : ℝ) ≤ 5 / 2)).intervalIntegrable 0 1) + (Continuous.intervalIntegrable (by fun_prop) _ _) + intro t ht + have hb := beta_B_bounds ha0.le ha1.le hx hx1 ht.1 ht.2 + have hp := (Real.rpow_le_rpow hb.1 hb.2.1 (by norm_num : (0 : ℝ) ≤ 5 / 2)).trans + (B_five_halves ha0.le ha1.le ht.1 ht.2) + have hm := mul_le_mul_of_nonneg_left hp ht.1 + calc + _ ≤ t * ((1 - a * t) ^ 5 + (5 / 2 : ℝ) * a * (1 - a) * t * (1 - a * t) ^ 3 + (15 / 8 : ℝ) * a ^ 2 * (1 - a) ^ 2 * t ^ 2) := hm + _ = _ := by ring + simp (disch := exact Continuous.intervalIntegrable (by fun_prop) _ _) + only [intervalIntegral.integral_add, intervalIntegral.integral_const_mul, integral_pow] at hi + norm_num at hi + have hmul := mul_le_mul_of_nonneg_left hi (by positivity : 0 ≤ 6 * a ^ 2) + have hg := upper_six_gap ha0 ha1 + nlinarith only [he, hmul, hg] + +end Sendov.FirstOriginSmall diff --git a/Sendov/Analytic/FirstOriginSmall.lean b/Sendov/Analytic/FirstOriginSmall.lean new file mode 100644 index 0000000..f7170c9 --- /dev/null +++ b/Sendov/Analytic/FirstOriginSmall.lean @@ -0,0 +1,158 @@ +import Sendov.Analytic.FirstOriginBounds + +/-! Actual Fprod and first-origin consumers for n = 6 or n = 7. +All root norm hypotheses are closed (at most one). -/ + +namespace Sendov.FirstOriginSmall + +lemma norm_sum_le_card (q : Multiset ℂ) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) : + ‖q.sum‖ ≤ (q.card : ℝ) := by + refine (norm_multiset_sum_le q).trans ?_ + simpa using Multiset.sum_map_le_sum_map (fun v : ℂ => ‖v‖) (fun _ => (1 : ℝ)) hq1 + +lemma norm_Fprod_le {n : ℕ} (hn : 2 ≤ n) {a x t : ℝ} {q : Multiset ℂ} + (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x) + (hb : 0 ≤ QQ (a * x) (a ^ 2) t) : + ‖Fprod a q t‖ ≤ QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 1) / 2) := by + have hc : (q.card : ℝ) = (n : ℝ) - 1 := by + rw [hqcard, Nat.cast_sub (by omega : 1 ≤ n)]; norm_num + have hnR : (2 : ℝ) ≤ n := by exact_mod_cast hn + have hcpos : (0 : ℝ) < q.card := by rw [hc]; linarith + let f : ℂ → ℝ := fun v => ‖1 - (a : ℂ) * (t : ℂ) * v‖ + have hsum := sum_norm_sq_one_sub_le hqcard hq1 (by omega) hx (t := t) (a := a) + have ham := Multiset.prod_le_mean_pow (q.map (fun v => (f v) ^ 2)) (by + intro y hy + obtain ⟨v, _, rfl⟩ := Multiset.mem_map.mp hy + exact sq_nonneg _) + rw [Multiset.card_map, prod_map_sq] at ham + have hmean : (q.map (fun v => (f v) ^ 2)).sum / (q.card : ℝ) ≤ QQ (a * x) (a ^ 2) t := by + rw [div_le_iff₀ hcpos, hc] + simpa only [f, mul_comm] using hsum + have hmean0 : 0 ≤ (q.map (fun v => (f v) ^ 2)).sum / (q.card : ℝ) := by + apply div_nonneg _ hcpos.le + apply Multiset.sum_nonneg + intro y hy + obtain ⟨v, _, rfl⟩ := Multiset.mem_map.mp hy + exact sq_nonneg _ + have hprod := ham.trans (pow_le_pow_left₀ hmean0 hmean q.card) + have heq : (QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 1) / 2)) ^ 2 = QQ (a * x) (a ^ 2) t ^ q.card := by + rw [← Real.rpow_natCast _ 2, ← Real.rpow_mul hb, ← Real.rpow_natCast _ q.card, hc] + congr 1 + norm_num + have hf : ‖Fprod a q t‖ = (q.map f).prod := norm_prod_map q _ + rw [hf] + apply (sq_le_sq₀ (prod_map_norm_nonneg q _) (Real.rpow_nonneg hb _)).mp + rw [heq] + exact hprod + +lemma norm_integral_Fprod_le_of_first_origin {n : ℕ} (hn : 0 < n) + {a : ℝ} {q z : Multiset ℂ} + (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) (hz1 : ∀ v ∈ z, ‖v‖ ≤ 1) + (hfirst : (n : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t) = + (-1) ^ (n - 1) * q.prod * z.prod) : + ‖∫ t in (0 : ℝ)..1, Fprod a q t‖ ≤ 1 / (n : ℝ) := by + have hnR : (0 : ℝ) < n := by exact_mod_cast hn + have hpq : ‖q.prod‖ ≤ 1 := by + rw [norm_multiset_prod] + exact prod_norm_le_one q hq1 + have hpz : ‖z.prod‖ ≤ 1 := by + rw [norm_multiset_prod] + exact prod_norm_le_one z hz1 + have hnorm := congrArg norm hfirst + simp only [norm_mul, norm_pow, norm_neg, norm_one, one_pow, one_mul, Complex.norm_natCast] at hnorm + rw [le_div_iff₀ hnR] + have hp := mul_le_mul hpq hpz (norm_nonneg _) (by norm_num : (0 : ℝ) ≤ 1) + nlinarith only [hnorm, hp] + +lemma first_origin_polar_six_seven_core + {n : ℕ} (hn : n = 6 ∨ n = 7) {a : ℝ} + (ha0 : 0 < a) (ha1 : a < 1) {q : Multiset ℂ} + (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hstar : 1 ≤ ∫ t in (0 : ℝ)..1, + (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) + (hfirst_bound : ‖∫ t in (0 : ℝ)..1, Sendov.Fprod a q t‖ ≤ 1 / (n : ℝ)) : + False := by + have hn2 : 2 ≤ n := by omega + have hnR : (2 : ℝ) ≤ n := by exact_mod_cast hn2 + have hm0 : 0 < (n : ℝ) - 1 := by linarith + have hmC : (n : ℂ) - 1 ≠ 0 := by + exact_mod_cast (ne_of_gt hm0) + have hc : (q.card : ℝ) = (n : ℝ) - 1 := by + rw [hqcard, Nat.cast_sub (by omega : 1 ≤ n)]; norm_num + let μ : ℂ := q.sum / ((n : ℂ) - 1) + have hsum : q.sum = ((n : ℂ) - 1) * ((μ.re : ℂ) + (μ.im : ℂ) * Complex.I) := by + rw [Complex.re_add_im] + dsimp [μ] + field_simp + have hnc : ‖(n : ℂ) - 1‖ = (n : ℝ) - 1 := by + have he : (n : ℂ) - 1 = (((n : ℝ) - 1 : ℝ) : ℂ) := by push_cast; rfl + rw [he, Complex.norm_real, Real.norm_eq_abs, abs_of_pos hm0] + have hqsum := norm_sum_le_card q hq1 + rw [hc] at hqsum + have hμ : ‖μ‖ ≤ 1 := by + dsimp [μ] + rw [norm_div, hnc, div_le_iff₀ hm0] + simpa using hqsum + have hx0 : -1 ≤ μ.re := by + have h := Complex.abs_re_le_norm μ + exact (abs_le.mp (h.trans hμ)).1 + have hx1 : μ.re ≤ 1 := (Complex.re_le_norm μ).trans hμ + have hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * μ.re := by + have hre : (q.map (fun v => v.re)).sum = q.sum.re := + (map_multiset_sum Complex.reAddGroupHom q).symm + rw [hre, hsum] + simp + have hpolar := one_le_integral_Ppolar hn2 hqcard hq1 hx hstar + have hxhalf := polar_mean_gt_half_add_one hn ha0 ha1 hx0 hpolar + have hq0 : q ≠ 0 := by + intro h + simp [h] at hqcard + omega + have ht := one_le_tri hn2 hqcard hq0 hq1 ha0.le hx hsum + have hβ := (beta_B_bounds ha0.le ha1.le hxhalf.le hx1 + (by norm_num : (0 : ℝ) ≤ 1) le_rfl).1 + have hf := norm_Fprod_le hn2 hqcard hq1 hx hβ + have hcoef : ((n : ℂ) - 1) * (a : ℂ) * ((μ.re : ℂ) + (μ.im : ℂ) * Complex.I) = (a : ℂ) * q.sum := by + rw [hsum]; ring + rw [hcoef] at ht + have hi : ‖(a : ℂ) * q.sum * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ ≤ + a * ((n : ℝ) - 1) / (n : ℝ) := by + rw [norm_mul, norm_mul, Complex.norm_real, Real.norm_eq_abs, abs_of_pos ha0] + have hmul := mul_le_mul (mul_le_mul_of_nonneg_left hqsum ha0.le) hfirst_bound + (norm_nonneg _) (by positivity : 0 ≤ a * ((n : ℝ) - 1)) + simpa only [mul_one_div] using hmul + have htri := norm_add_le (Fprod a q 1) ((a : ℂ) * q.sum * (∫ t in (0 : ℝ)..1, Fprod a q t)) + rcases hn with rfl | rfl + · have hb := direct_budget_five ha0 ha1 hxhalf.le hx1 + norm_num [Real.rpow_natCast] at ht hf hi htri + linarith + · have hb := direct_budget_six ha0 ha1 hxhalf.le hx1 + norm_num [Real.rpow_natCast] at ht hf hi htri + linarith + +theorem first_origin_polar_six_seven + {n : ℕ} (hn : n = 6 ∨ n = 7) {a : ℝ} + (ha0 : 0 < a) (ha1 : a < 1) {q : Multiset ℂ} + (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hstar : 1 ≤ ∫ t in (0 : ℝ)..1, + (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) + (hfirst_bound : ‖∫ t in (0 : ℝ)..1, Sendov.Fprod a q t‖ ≤ 1 / (n : ℝ)) : + False := by + exact first_origin_polar_six_seven_core hn ha0 ha1 hqcard hq1 hstar hfirst_bound + +theorem norm_integral_Fprod_le_of_factorization + {n : ℕ} (hn : 0 < n) {a : ℝ} (ha0 : a ≠ 0) + {c : ℂ} (hc0 : c ≠ 0) {p : Polynomial ℂ} {q z : Multiset ℂ} + (hzcard : z.card = n - 1) (hq0 : ∀ v ∈ q, v ≠ 0) + (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) (hz1 : ∀ v ∈ z, ‖v‖ ≤ 1) + (hpa : p.eval (a : ℂ) = 0) + (hpz : p = Polynomial.C c * ((Polynomial.X - Polynomial.C (a : ℂ)) * (z.map (fun w => Polynomial.X - Polynomial.C w)).prod)) + (hpq : Polynomial.derivative p = Polynomial.C ((n : ℂ) * c) * ((q.map (fun v => (a : ℂ) - v⁻¹)).map + (fun w => Polynomial.X - Polynomial.C w)).prod) : + ‖∫ t in (0 : ℝ)..1, Fprod a q t‖ ≤ 1 / (n : ℝ) := by + apply norm_integral_Fprod_le_of_first_origin hn hq1 hz1 + exact first_origin_identity hc0 (Complex.ofReal_ne_zero.mpr ha0) hzcard hq0 hpa hpz hpq + + +end Sendov.FirstOriginSmall diff --git a/Sendov/Analytic/PaperNearAlgebra.lean b/Sendov/Analytic/PaperNearAlgebra.lean new file mode 100644 index 0000000..0a78f85 --- /dev/null +++ b/Sendov/Analytic/PaperNearAlgebra.lean @@ -0,0 +1,218 @@ +import Mathlib.Tactic.FieldSimp +import Mathlib.Tactic.Positivity +import Mathlib.Tactic.Linarith +import Mathlib.Data.Real.Basic +import Mathlib.Tactic.Ring + +/-! Rational algebra for round7, §§3 and 5. No polar or Taylor estimate is +asserted here: those are separate analytic inputs to the paper's gap argument. -/ +namespace Sendov.PaperNear + +noncomputable def A (τ : ℝ) : ℝ := 1 - 2 * τ / 5 +noncomputable def C (τ : ℝ) : ℝ := 1 - 2 * τ +noncomputable def L (τ : ℝ) : ℝ := 1 + τ +noncomputable def H (τ : ℝ) : ℝ := 1 + 3 * τ +noncomputable def D (τ : ℝ) : ℝ := A τ * C τ * L τ * H τ +noncomputable def F (τ : ℝ) : ℝ := + A τ * C τ * H τ - (5 / 17 : ℝ) * L τ * H τ - + (2312 / 3375 : ℝ) * A τ * C τ - D τ / 80 +noncomputable def G (τ : ℝ) : ℝ := + 1 / L τ - 5 / (17 * A τ * C τ) - + (2312 / 3375 : ℝ) / (L τ * H τ) - 1 / 80 + +/-- The exact degree-four Bernstein certificate, with the paper's numerators. -/ +theorem quartic_bernstein (u : ℝ) : + F (u / 7) = (551821830 * (1-u)^4 + + 3025830066 * 4 * u * (1-u)^3 + + 3755012933 * 6 * u^2 * (1-u)^2 + + 2857448181 * 4 * u^3 * (1-u) + 450387360 * u^4) / 66123540000 := by + unfold F D A C L H + ring + +/-- A uniform lower bound, not merely positivity at sampled points. -/ +theorem quartic_lower (τ : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) : + (450387360 / 66123540000 : ℝ) ≤ F τ := by + have hu : 0 ≤ 7 * τ := by positivity + have hv : 0 ≤ 1 - 7 * τ := by linarith + have h0 : 0 ≤ (1 - 7 * τ)^4 := by positivity + have h1 : 0 ≤ (7 * τ) * (1 - 7 * τ)^3 := by positivity + have h2 : 0 ≤ (7 * τ)^2 * (1 - 7 * τ)^2 := by positivity + have h3 : 0 ≤ (7 * τ)^3 * (1 - 7 * τ) := by positivity + have hid : F τ - 450387360 / 66123540000 = + (101434470 * (1-7*τ)^4 + 10301770824 * (7*τ) * (1-7*τ)^3 + + 19827753438 * (7*τ)^2 * (1-7*τ)^2 + + 9628243284 * (7*τ)^3 * (1-7*τ)) / 66123540000 := by + unfold F D A C L H + ring + have hp : 0 ≤ (101434470 * (1-7*τ)^4 + + 10301770824 * (7*τ) * (1-7*τ)^3 + + 19827753438 * (7*τ)^2 * (1-7*τ)^2 + + 9628243284 * (7*τ)^3 * (1-7*τ)) / (66123540000 : ℝ) := by + positivity + linarith + +theorem denominator_bounds (τ : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) : + 0 < D τ ∧ D τ ≤ 80 / 49 := by + have ha : 0 < A τ := by unfold A; linarith + have hc : 0 < C τ := by unfold C; linarith + have hl : 0 < L τ := by unfold L; linarith + have hh : 0 < H τ := by unfold H; linarith + have ha1 : A τ ≤ 1 := by unfold A; linarith + have hc1 : C τ ≤ 1 := by unfold C; linarith + have hl8 : L τ ≤ 8 / 7 := by unfold L; linarith + have hh10 : H τ ≤ 10 / 7 := by unfold H; linarith + have hac : A τ * C τ ≤ 1 := by nlinarith + have hlh : L τ * H τ ≤ 80 / 49 := by nlinarith + constructor + · unfold D; positivity + · unfold D + nlinarith [mul_pos ha hc, mul_pos hl hh, + mul_nonneg (sub_nonneg.mpr hac) (mul_nonneg hl.le hh.le)] + +theorem denominator_mul_G (τ : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) : + D τ * G τ = F τ := by + have ha : A τ ≠ 0 := by unfold A; linarith + have hc : C τ ≠ 0 := by unfold C; linarith + have hl : L τ ≠ 0 := by unfold L; linarith + have hh : H τ ≠ 0 := by unfold H; linarith + unfold G F D + field_simp + +/-- The paper's conservative positive margin, uniformly on the closed interval. -/ +theorem G_lower (τ : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) : + (312769 / 91838250 : ℝ) ≤ G τ := by + obtain ⟨hd, hd2⟩ := denominator_bounds τ hτ hτ7 + have hf := quartic_lower τ hτ hτ7 + have he := denominator_mul_G τ hτ hτ7 + have hg : 0 ≤ G τ := by nlinarith + nlinarith [mul_nonneg (show 0 ≤ 2 - D τ by linarith) hg] + +theorem G_gt_one_thousandth (τ : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) : + (1 / 1000 : ℝ) < G τ := by + have := G_lower τ hτ hτ7 + norm_num at * + linarith + +noncomputable def P (τ ℓ : ℝ) : ℝ := (1 - ℓ * τ) * (1 - 2 * τ) * (3 + ℓ) +noncomputable def Q (τ : ℝ) : ℝ := (1 + τ) * (1 + 3 * τ) +noncomputable def f (τ ℓ : ℝ) : ℝ := 1 / P τ ℓ +noncomputable def g (τ ℓ : ℝ) : ℝ := (4 / 27 : ℝ) * ℓ * (3 + ℓ)^2 / Q τ + +/-- Uniform denominator separation for the first rational error term. -/ +theorem P_lower (τ ℓ : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) + (hℓ : 0 ≤ ℓ) (hℓ2 : ℓ ≤ 2 / 5) : (99 / 49 : ℝ) ≤ P τ ℓ := by + have hlt : ℓ * τ ≤ 2 / 35 := by nlinarith + have ha : 33 / 35 ≤ 1 - ℓ * τ := by linarith + have hc : 5 / 7 ≤ 1 - 2 * τ := by linarith + have hac : (33 / 35 : ℝ) * (5 / 7) ≤ (1 - ℓ * τ) * (1 - 2 * τ) := + mul_le_mul ha hc (by norm_num) (by linarith) + have hab : 0 ≤ (1 - ℓ * τ) * (1 - 2 * τ) := by positivity + have hp := mul_le_mul_of_nonneg_left (show (3 : ℝ) ≤ 3 + ℓ by linarith) hab + unfold P + nlinarith + +theorem Q_bounds (τ : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) : + 0 < Q τ ∧ Q τ ≤ 80 / 49 := by + unfold Q + constructor + · positivity + · nlinarith [sq_nonneg (τ - 1/7)] + +/-- A finite-difference version of the paper's lower derivative bound for f. +It avoids differentiability hypotheses and includes the closed endpoints. -/ +theorem f_difference_lower (τ x y : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) + (hx : 0 ≤ x) (hxy : x ≤ y) (hy : y ≤ 2 / 5) : + -(y-x) / 4 ≤ f τ y - f τ x := by + have hy0 : 0 ≤ y := le_trans hx hxy + have hx2 : x ≤ 2 / 5 := le_trans hxy hy + have hpx := P_lower τ x hτ hτ7 hx hx2 + have hpy := P_lower τ y hτ hτ7 hy0 hy + have hpx0 : P τ x ≠ 0 := by linarith + have hpy0 : P τ y ≠ 0 := by linarith + have hprod : 4 ≤ P τ x * P τ y := by nlinarith + have htx : τ * x ≤ 2 / 35 := by nlinarith + have hty : τ * y ≤ 2 / 35 := by nlinarith + have hs0 : 0 ≤ 1 - 3*τ - τ*(x+y) := by nlinarith + have hs1 : 1 - 3*τ - τ*(x+y) ≤ 1 := by nlinarith [mul_nonneg hτ (add_nonneg hx hy0)] + have hc0 : 0 ≤ 1 - 2*τ := by linarith + have hc1 : 1 - 2*τ ≤ 1 := by linarith + have hcs : (1 - 2*τ) * (1 - 3*τ - τ*(x+y)) ≤ 1 := by nlinarith + have hmul := mul_le_mul_of_nonneg_left hcs (sub_nonneg.mpr hxy) + have hdiff : P τ y - P τ x ≤ y-x := by + unfold P + nlinarith only [hmul] + have hid : (P τ x * P τ y) * (f τ y - f τ x) = P τ x - P τ y := by + unfold f + field_simp + by_cases hsign : 0 ≤ f τ y - f τ x + · linarith + · have hn : 0 ≤ -(f τ y - f τ x) := by linarith + have := mul_le_mul_of_nonneg_right hprod hn + nlinarith + +/-- A finite-difference version of ∂ℓ g ≥ 49/60. -/ +theorem g_difference_lower (τ x y : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) + (hx : 0 ≤ x) (hxy : x ≤ y) : + (49 / 60 : ℝ) * (y-x) ≤ g τ y - g τ x := by + have hy : 0 ≤ y := le_trans hx hxy + obtain ⟨hq0, hq⟩ := Q_bounds τ hτ hτ7 + have hqn : Q τ ≠ 0 := ne_of_gt hq0 + have hid : Q τ * (g τ y - g τ x) = + (4 / 27 : ℝ) * (y-x) * (9 + 6*(x+y) + x^2 + x*y + y^2) := by + unfold g + field_simp + ring + have hp : 0 ≤ (y-x) * (6*(x+y) + x^2 + x*y + y^2) := by positivity + have hb : (4 / 3 : ℝ) * (y-x) ≤ Q τ * (g τ y - g τ x) := by + nlinarith only [hid, hp] + have hg0 : 0 ≤ g τ y - g τ x := by nlinarith + have hm := mul_le_mul_of_nonneg_right hq hg0 + nlinarith + +/-- Quantitative strict increase in ℓ on the entire near-endpoint rectangle. -/ +theorem fg_difference_lower (τ x y : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) + (hx : 0 ≤ x) (hxy : x ≤ y) (hy : y ≤ 2 / 5) : + (17 / 30 : ℝ) * (y-x) ≤ (f τ y + g τ y) - (f τ x + g τ x) := by + have hf := f_difference_lower τ x y hτ hτ7 hx hxy hy + have hg := g_difference_lower τ x y hτ hτ7 hx hxy + linarith + +theorem fg_strictMonoOn (τ : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) : + StrictMonoOn (fun ℓ => f τ ℓ + g τ ℓ) (Set.Icc 0 (2 / 5)) := by + intro x hx y hy hxy + have := fg_difference_lower τ x y hτ hτ7 hx.1 hxy.le hy.2 + linarith + +theorem fg_le_endpoint (τ ℓ : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) + (hℓ : 0 ≤ ℓ) (hℓ2 : ℓ ≤ 2 / 5) : + f τ ℓ + g τ ℓ ≤ f τ (2 / 5) + g τ (2 / 5) := by + have := fg_difference_lower τ ℓ (2/5) hτ hτ7 hℓ hℓ2 le_rfl + linarith + +/-- Strict positivity of the cleared quartic throughout the interval. -/ +theorem quartic_pos (τ : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) : 0 < F τ := by + have := quartic_lower τ hτ hτ7 + linarith + +/-- Identifies the quartic consumer with the sum of the two endpoint errors. -/ +theorem G_eq_endpoint (τ : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) : + G τ = 1 / (1+τ) - (f τ (2/5) + g τ (2/5)) - 1/80 := by + have ha : 1 - 2 * τ / 5 ≠ 0 := by linarith + have hc : 1 - 2 * τ ≠ 0 := by linarith + have hl : 1 + τ ≠ 0 := by linarith + have hh : 1 + 3 * τ ≠ 0 := by linarith + have ha' : 1 - (2 / 5 : ℝ) * τ ≠ 0 := by linarith + unfold G f g P Q A C L H + field_simp + ring + +/-- The full rational near-endpoint remainder, before analytic inputs are supplied. -/ +theorem rational_remainder_gt (τ ℓ : ℝ) (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) + (hℓ : 0 ≤ ℓ) (hℓ2 : ℓ ≤ 2 / 5) : + (1 / 1000 : ℝ) < 1 / (1+τ) - (f τ ℓ + g τ ℓ) - 1/80 := by + have hm := fg_le_endpoint τ ℓ hτ hτ7 hℓ hℓ2 + have hg := G_gt_one_thousandth τ hτ hτ7 + rw [G_eq_endpoint τ hτ hτ7] at hg + linarith + +end Sendov.PaperNear diff --git a/Sendov/Analytic/PaperPolar.lean b/Sendov/Analytic/PaperPolar.lean new file mode 100644 index 0000000..e3afdd8 --- /dev/null +++ b/Sendov/Analytic/PaperPolar.lean @@ -0,0 +1,189 @@ +import Sendov.Reduction.BetaBound + +/-! +# Raw polar input for the paper-level D problem + +The degree parameter here is `m = n - 1`. The only analytic hypothesis is +`RawPolar m a x`; in particular neither the rational endpoint bound nor an +upper bound on alpha is assumed. We expose the actual pointwise exponential +majorant and its integral comparison before applying `Sendov.beta_le`. +-/ + +namespace Sendov.PaperPolar + +open MeasureTheory + +noncomputable def beta (a x t : ℝ) : ℝ := 1 - 2 * a * x * t + a ^ 2 * t ^ 2 +noncomputable def b (a x : ℝ) : ℝ := 1 - 2 * a * x + a ^ 2 +noncomputable def c (a x : ℝ) : ℝ := 1 - b a x +noncomputable def d (a x : ℝ) : ℝ := 2 * a * (1 - x) +noncomputable def alpha (m : ℕ) (a : ℝ) : ℝ := (m : ℝ) * (1 - a ^ 2) / 2 +noncomputable def lambda (m : ℕ) (a : ℝ) : ℝ := (m : ℝ) * (1 - a) + +/-- The raw integral, with exactly the polynomial in the paper. -/ +def RawPolar (m : ℕ) (a x : ℝ) : Prop := + 1 ≤ ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2) + +lemma raw_kernel_eq (a x t : ℝ) : + a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2 = + Sendov.Ppolar a x t := by + unfold Sendov.Ppolar + ring + +lemma rawPolar_iff (m : ℕ) (a x : ℝ) : + RawPolar m a x ↔ + 1 ≤ ∫ t in (0 : ℝ)..1, Sendov.Ppolar a x t ^ ((m : ℝ) / 2) := by + simp only [RawPolar, raw_kernel_eq] + +lemma beta_one (a x : ℝ) : beta a x 1 = b a x := by simp [beta, b] + +lemma b_eq_QQ (a x : ℝ) : b a x = Sendov.QQ (a * x) (a ^ 2) 1 := by + simp only [b, Sendov.QQ] + ring + +lemma x_sq_le_one {x : ℝ} (hx0 : -1 ≤ x) (hx1 : x ≤ 1) : x ^ 2 ≤ 1 := by + nlinarith + +lemma alpha_pos {m : ℕ} {a : ℝ} (hm : 0 < m) (ha0 : 0 < a) (ha1 : a < 1) : + 0 < alpha m a := by + have hm' : (0 : ℝ) < m := by exact_mod_cast hm + have hdelta : 0 < 1 - a ^ 2 := by nlinarith + unfold alpha + positivity + +lemma lambda_pos {m : ℕ} {a : ℝ} (hm : 0 < m) (ha1 : a < 1) : + 0 < lambda m a := by + have hm' : (0 : ℝ) < m := by exact_mod_cast hm + unfold lambda + positivity + +lemma alpha_le_lambda (m : ℕ) (a : ℝ) : alpha m a ≤ lambda m a := by + have h := mul_nonneg (Nat.cast_nonneg (α := ℝ) m) (sq_nonneg (1 - a)) + unfold alpha lambda + nlinarith only [h] + +/-- The quadratic is below its affine endpoint chord, then below an exponential. +This does not require any polar integral hypothesis. -/ +lemma rpow_le_exp {m : ℕ} {a x t : ℝ} (hm : 0 < m) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (ht0 : 0 ≤ t) (ht1 : t ≤ 1) : + Sendov.Ppolar a x t ^ ((m : ℝ) / 2) ≤ + Real.exp (alpha m a * (-1 + (2 - b a x) * t)) := by + have hn : 2 ≤ m + 1 := by omega + have he : ((m + 1 : ℕ) : ℝ) - 1 = (m : ℝ) := by push_cast; ring + have hα : alpha m a = Sendov.M (m + 1) * (1 - a ^ 2) / 2 := by + simp only [alpha, Sendov.M, he] + simpa only [he, b_eq_QQ] using + (Sendov.Ppolar_rpow_le hn (x_sq_le_one hx0 hx1) hα ht0 ht1) + +/-- Actual domination of the raw integral, not a new assumption on its value. -/ +theorem integral_le_exp {m : ℕ} {a x : ℝ} (hm : 0 < m) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) : + (∫ t in (0 : ℝ)..1, Sendov.Ppolar a x t ^ ((m : ℝ) / 2)) ≤ + ∫ t in (0 : ℝ)..1, Real.exp (alpha m a * (-1 + (2 - b a x) * t)) := by + have he : 0 ≤ (m : ℝ) / 2 := by positivity + refine intervalIntegral.integral_mono_on (by norm_num) + (((continuous_rpow_const he).comp (Sendov.continuous_Ppolar a x)).intervalIntegrable _ _) + ((by fun_prop : Continuous fun t : ℝ => + Real.exp (alpha m a * (-1 + (2 - b a x) * t))).intervalIntegrable _ _) ?_ + intro t ht + exact rpow_le_exp hm hx0 hx1 ht.1 ht.2 + +/-- The exponential polar inequality is a consequence of raw polar. -/ +theorem one_le_integral_exp {m : ℕ} {a x : ℝ} (hm : 0 < m) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hraw : RawPolar m a x) : + 1 ≤ ∫ t in (0 : ℝ)..1, Real.exp (alpha m a * (-1 + (2 - b a x) * t)) := + ((rawPolar_iff m a x).mp hraw).trans (integral_le_exp hm hx0 hx1) + +lemma b_eq_sq_add_d (a x : ℝ) : b a x = (1 - a) ^ 2 + d a x := by + unfold b d + ring + +lemma d_nonneg {a x : ℝ} (ha0 : 0 ≤ a) (hx1 : x ≤ 1) : 0 ≤ d a x := by + unfold d + positivity + +lemma d_le_b (a x : ℝ) : d a x ≤ b a x := by + rw [b_eq_sq_add_d] + nlinarith only [sq_nonneg (1 - a)] + +lemma b_pos {a x : ℝ} (ha0 : 0 ≤ a) (ha1 : a < 1) (hx1 : x ≤ 1) : + 0 < b a x := by + rw [b_eq_sq_add_d] + have hd := d_nonneg ha0 hx1 + have hh : 0 < (1 - a) ^ 2 := sq_pos_of_pos (by linarith) + linarith + +lemma rational_mono {u v : ℝ} (hu : 0 ≤ u) (huv : u ≤ v) : + u / (3 + u) ≤ v / (3 + v) := by + have hv : 0 ≤ v := hu.trans huv + apply (div_le_div_iff₀ (by positivity : 0 < 3 + u) (by positivity : 0 < 3 + v)).2 + nlinarith + +/-- The stronger rational endpoint bound, with no upper bound on alpha. -/ +theorem b_le_alpha {m : ℕ} {a x : ℝ} (hm : 0 < m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) : b a x ≤ alpha m a / (3 + alpha m a) := + Sendov.beta_le (alpha_pos hm ha0 ha1) (b_pos ha0.le ha1 hx1).le + (one_le_integral_exp hm hx0 hx1 hraw) + +/-- Paper degree range: raw polar gives both rational endpoint bounds. -/ +theorem endpoint_bounds {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) : + b a x ≤ alpha m a / (3 + alpha m a) ∧ + alpha m a / (3 + alpha m a) ≤ lambda m a / (3 + lambda m a) := by + have hm0 : 0 < m := by omega + exact ⟨b_le_alpha hm0 ha0 ha1 hx0 hx1 hraw, + rational_mono (alpha_pos hm0 ha0 ha1).le (alpha_le_lambda m a)⟩ + +lemma b_lt_one {m : ℕ} {a x : ℝ} (hm : 0 < m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) : b a x < 1 := by + have hα := alpha_pos hm ha0 ha1 + refine (b_le_alpha hm ha0 ha1 hx0 hx1 hraw).trans_lt ?_ + apply (div_lt_one (by positivity : 0 < 3 + alpha m a)).2 + linarith + +/-- The easy raw-polar geometry required by D. -/ +theorem geometry {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) : a / 2 < x ∧ 0 < c a x := by + have hb := b_lt_one (by omega : 0 < m) ha0 ha1 hx0 hx1 hraw + constructor + · unfold b at hb + nlinarith + · unfold c + linarith + +/-- Quantitative positivity of the chord slope. -/ +theorem c_lower_bound {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) : 3 / (3 + lambda m a) ≤ c a x := by + have hbounds := endpoint_bounds hm ha0 ha1 hx0 hx1 hraw + have hb := hbounds.1.trans hbounds.2 + have hl := lambda_pos (by omega : 0 < m) ha1 + have hid : 3 / (3 + lambda m a) = 1 - lambda m a / (3 + lambda m a) := by + field_simp + ring + rw [hid, c] + linarith + +/-- The quadratic beta lies below the chord joining 1 to b. -/ +lemma beta_le_chord {a x t : ℝ} (ht0 : 0 ≤ t) (ht1 : t ≤ 1) : + beta a x t ≤ 1 - c a x * t := by + have h := mul_nonneg (sq_nonneg a) (mul_nonneg ht0 (sub_nonneg.mpr ht1)) + unfold beta c b + nlinarith only [h] + +/-- Positivity of beta on the integration interval. -/ +lemma beta_pos {a x t : ℝ} (ha0 : 0 ≤ a) (ha1 : a < 1) + (hx1 : x ≤ 1) (ht0 : 0 ≤ t) (ht1 : t ≤ 1) : 0 < beta a x t := by + have hat : a * t < 1 := (mul_le_mul_of_nonneg_left ht1 ha0).trans_lt (by simpa using ha1) + have hs : 0 < (1 - a * t) ^ 2 := sq_pos_of_pos (by linarith) + have h := mul_nonneg (mul_nonneg ha0 ht0) (sub_nonneg.mpr hx1) + unfold beta + nlinarith only [hs, h] + +end Sendov.PaperPolar diff --git a/Sendov/Analytic/PaperTaylor.lean b/Sendov/Analytic/PaperTaylor.lean new file mode 100644 index 0000000..d982ee5 --- /dev/null +++ b/Sendov/Analytic/PaperTaylor.lean @@ -0,0 +1,305 @@ +import Sendov.Common.Chord +import Mathlib.Analysis.SpecialFunctions.Pow.Deriv +import Mathlib.Analysis.Calculus.Deriv.MeanValue + +/-! +# Finite Taylor budget for the actual origin integral + +Source: first-origin-uniform/REPORT.md §4.2 (R3), inherited unchanged in +round3/REPORT.md §1 and round4/REPORT.md. The analytic bound requires only +`7 ≤ m`, `0 < a < 1`, `x ≤ 1`, and `0 < c = a(2x-a)`. +In particular raw polar, the lower bound `-1 ≤ x`, integrality of `m`, and +any smallness assumption on `m(1-a)` are not needed for the Taylor estimate. +-/ + +namespace Sendov.PaperTaylor + +open MeasureTheory + +noncomputable def beta (a x t : ℝ) : ℝ := 1 - 2 * a * x * t + a ^ 2 * t ^ 2 +noncomputable def defect (a x : ℝ) : ℝ := 2 * a * (1 - x) +noncomputable def chord (a x : ℝ) : ℝ := a * (2 * x - a) +noncomputable def budget (m a x : ℝ) : ℝ := + beta a x 1 ^ (m / 2) + m * a ^ 2 * + ∫ t in (0 : ℝ)..1, t * beta a x t ^ ((m - 1) / 2) + +lemma beta_decomposition (a x t : ℝ) : + beta a x t = (1 - a * t) ^ 2 + defect a x * t := by + unfold beta defect + ring + +lemma defect_nonneg {a x : ℝ} (ha : 0 ≤ a) (hx : x ≤ 1) : + 0 ≤ defect a x := mul_nonneg (by positivity) (sub_nonneg.mpr hx) + +lemma beta_pos {a x t : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx : x ≤ 1) + (ht : t ∈ Set.Icc (0 : ℝ) 1) : 0 < beta a x t := by + have hat : a * t < 1 := lt_of_le_of_lt (mul_le_of_le_one_right ha.le ht.2) ha1 + rw [beta_decomposition] + exact add_pos_of_pos_of_nonneg (sq_pos_of_pos (by linarith)) + (mul_nonneg (defect_nonneg ha.le hx) ht.1) + +lemma beta_le_chord {a x t : ℝ} (ht : t ∈ Set.Icc (0 : ℝ) 1) : + beta a x t ≤ 1 - chord a x * t := by + have h := mul_nonneg (sq_nonneg a) (mul_nonneg ht.1 (sub_nonneg.mpr ht.2)) + unfold beta chord + nlinarith + +lemma chord_lt_one {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx : x ≤ 1) : + chord a x < 1 := by + have h := beta_pos ha ha1 hx (t := 1) (by norm_num) + unfold beta chord at * + nlinarith + +/-- A genuine finite second-order Taylor majorant, proved by two derivative comparisons. +The lower endpoint is positive, as it is for `(1-at)^2` with `a<1`. -/ +lemma rpow_taylor_le {p v w : ℝ} (hp : 2 ≤ p) (hv : 0 < v) (hvw : v ≤ w) : + w ^ p ≤ v ^ p + p * (w - v) * v ^ (p - 1) + + (p * (p - 1) / 2) * (w - v) ^ 2 * w ^ (p - 2) := by + let K := p * (p - 1) * w ^ (p - 2) + let g := fun z : ℝ => p * z ^ (p - 1) - p * v ^ (p - 1) - K * (z - v) + have hg : ∀ z ∈ Set.Icc v w, HasDerivAt g + (p * (p - 1) * z ^ (p - 2) - K) z := by + intro z hz + have hz0 : z ≠ 0 := ne_of_gt (lt_of_lt_of_le hv hz.1) + convert! (((Real.hasDerivAt_rpow_const (p := p - 1) (Or.inl hz0)).const_mul p).sub_const + (p * v ^ (p - 1))).sub + (((hasDerivAt_id z).sub_const v).const_mul K) using 1 + ring_nf + have hgmono : AntitoneOn g (Set.Icc v w) := by + apply antitoneOn_of_hasDerivWithinAt_nonpos (convex_Icc _ _) + · exact fun z hz => (hg z hz).continuousAt.continuousWithinAt + · intro z hz + exact (hg z (interior_subset hz)).hasDerivWithinAt + · intro z hz + have hz' := interior_subset hz + have hpow := Real.rpow_le_rpow (by linarith [hz'.1] : 0 ≤ z) hz'.2 + (by linarith : 0 ≤ p - 2) + dsimp [K] + nlinarith [mul_le_mul_of_nonneg_left hpow + (show 0 ≤ p * (p - 1) by nlinarith)] + have hgnonpos : ∀ z ∈ Set.Icc v w, g z ≤ 0 := by + intro z hz + have h := hgmono (Set.left_mem_Icc.mpr hvw) hz hz.1 + simpa [g] using h + let f := fun z : ℝ => z ^ p - v ^ p - p * (z - v) * v ^ (p - 1) - + K / 2 * (z - v) ^ 2 + have hf : ∀ z ∈ Set.Icc v w, HasDerivAt f (g z) z := by + intro z hz + have hz0 : z ≠ 0 := ne_of_gt (lt_of_lt_of_le hv hz.1) + convert! (((Real.hasDerivAt_rpow_const (p := p) (Or.inl hz0)).sub_const (v ^ p)).sub + ((((hasDerivAt_id z).sub_const v).const_mul p).mul_const (v ^ (p - 1)))).sub + ((((hasDerivAt_id z).sub_const v).pow 2).const_mul (K / 2)) using 1 + dsimp [g] + ring_nf + have hfmono : AntitoneOn f (Set.Icc v w) := by + apply antitoneOn_of_hasDerivWithinAt_nonpos (convex_Icc _ _) + · exact fun z hz => (hf z hz).continuousAt.continuousWithinAt + · exact fun z hz => (hf z (interior_subset hz)).hasDerivWithinAt + · exact fun z hz => hgnonpos z (interior_subset hz) + have h := hfmono (Set.left_mem_Icc.mpr hvw) (Set.right_mem_Icc.mpr hvw) hvw + dsimp [f, K] at h + nlinarith + +/-- The missing quadratic Beta moment, with a real exponent. -/ +lemma integral_sq_mul_rpow {s : ℝ} (hs : 0 < s) : + (∫ t in (0 : ℝ)..1, t ^ 2 * (1 - t) ^ s) = + 2 / ((s + 1) * (s + 2) * (s + 3)) := by + have hrefl : (∫ t in (0 : ℝ)..1, t ^ 2 * (1 - t) ^ s) = + ∫ t in (0 : ℝ)..1, (1 - t) ^ 2 * t ^ s := by + simpa using (intervalIntegral.integral_comp_sub_left (a := (0 : ℝ)) (b := 1) + (fun t : ℝ => (1 - t) ^ 2 * t ^ s) 1) + have heq : ∀ t ∈ Set.uIcc (0 : ℝ) 1, + (1 - t) ^ 2 * t ^ s = t ^ s - 2 * t ^ (s + (1 : ℕ)) + t ^ (s + (2 : ℕ)) := by + intro t ht + rw [Set.uIcc_of_le (by norm_num : (0 : ℝ) ≤ 1)] at ht + rw [Real.rpow_add_natCast' ht.1 (by positivity : s + (1 : ℕ) ≠ 0), + Real.rpow_add_natCast' ht.1 (by positivity : s + (2 : ℕ) ≠ 0)] + ring + have hi : ∀ n : ℕ, IntervalIntegrable (fun t : ℝ => t ^ (s + n)) volume 0 1 := by + intro n + exact intervalIntegral.intervalIntegrable_rpow' (by linarith [Nat.cast_nonneg (α := ℝ) n]) + have hi0 : IntervalIntegrable (fun t : ℝ => t ^ s) volume 0 1 := + intervalIntegral.intervalIntegrable_rpow' (by linarith) + rw [hrefl, intervalIntegral.integral_congr heq, + intervalIntegral.integral_add (hi0.sub ((hi 1).const_mul 2)) (hi 2), + intervalIntegral.integral_sub hi0 ((hi 1).const_mul 2), + intervalIntegral.integral_const_mul, + integral_rpow_zero_one (by linarith), integral_rpow_zero_one (by push_cast; linarith), + integral_rpow_zero_one (by push_cast; linarith)] + push_cast + field_simp + ring + +lemma integral_chord_sq {s c : ℝ} (hs : 0 < s) (hc : 0 < c) : + (∫ t in (0 : ℝ)..1 / c, t ^ 2 * (1 - c * t) ^ s) = + 2 / (c ^ 3 * ((s + 1) * (s + 2) * (s + 3))) := by + have h := intervalIntegral.integral_comp_mul_left (a := (0 : ℝ)) (b := 1 / c) + (fun y : ℝ => (y / c) ^ 2 * (1 - y) ^ s) hc.ne' + simp only [mul_div_cancel_left₀ _ hc.ne', mul_one_div_cancel hc.ne', mul_zero, + div_pow, div_mul_eq_mul_div, intervalIntegral.integral_div, integral_sq_mul_rpow hs, + smul_eq_mul] at h + rw [h] + field_simp + +/-- Extension to the zero of a nonnegative chord, for any natural weight. -/ +lemma integral_chord_extend {s c : ℝ} (hs : 0 ≤ s) (hc : 0 < c) (hc1 : c ≤ 1) + (k : ℕ) : + (∫ t in (0 : ℝ)..1, t ^ k * (1 - c * t) ^ s) ≤ + ∫ t in (0 : ℝ)..1 / c, t ^ k * (1 - c * t) ^ s := by + have hend : (1 : ℝ) ≤ 1 / c := (le_div_iff₀ hc).mpr (by simpa using hc1) + have hcont : Continuous (fun t : ℝ => t ^ k * (1 - c * t) ^ s) := + (continuous_pow k).mul ((continuous_rpow_const hs).comp (by fun_prop)) + have hrest : 0 ≤ ∫ t in (1 : ℝ)..1 / c, t ^ k * (1 - c * t) ^ s := by + refine intervalIntegral.integral_nonneg hend ?_ + intro t ht + have ht' := (le_div_iff₀ hc).mp ht.2 + exact mul_nonneg (pow_nonneg (by linarith [ht.1]) k) + (Real.rpow_nonneg (by nlinarith) s) + have hadd := intervalIntegral.integral_add_adjacent_intervals (μ := volume) + (hcont.intervalIntegrable 0 1) (hcont.intervalIntegrable 1 (1 / c)) + linarith + +lemma sq_rpow {u : ℝ} (hu : 0 ≤ u) (s : ℝ) : (u ^ 2) ^ s = u ^ (2 * s) := by + rw [← Real.rpow_natCast u 2, ← Real.rpow_mul hu] + norm_num + +/-- Pointwise Taylor bound with the actual quadratic and its actual secant. -/ +lemma beta_rpow_taylor {m a x t : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : x ≤ 1) (ht : t ∈ Set.Icc (0 : ℝ) 1) : + t * beta a x t ^ ((m - 1) / 2) ≤ + t * (1 - a * t) ^ (m - 1) + + ((m - 1) / 2 * defect a x) * (t ^ 2 * (1 - a * t) ^ (m - 3)) + + ((m - 1) * (m - 3) / 8 * defect a x ^ 2) * + (t ^ 3 * (1 - chord a x * t) ^ ((m - 5) / 2)) := by + have hd := defect_nonneg ha.le hx + have hu : 0 < 1 - a * t := by + have := mul_le_of_le_one_right ha.le ht.2 + linarith + have hβ := beta_pos ha ha1 hx ht + have hvw : (1 - a * t) ^ 2 ≤ beta a x t := by + rw [beta_decomposition] + exact le_add_of_nonneg_right (mul_nonneg hd ht.1) + have h := rpow_taylor_le (by linarith : 2 ≤ (m - 1) / 2) + (sq_pos_of_pos hu) hvw + have hdiff : beta a x t - (1 - a * t) ^ 2 = defect a x * t := by + rw [beta_decomposition] + ring + rw [hdiff, sq_rpow hu.le, sq_rpow hu.le, + show 2 * ((m - 1) / 2) = m - 1 by ring, + show 2 * ((m - 1) / 2 - 1) = m - 3 by ring, + show (m - 1) / 2 - 2 = (m - 5) / 2 by ring] at h + have hpow := Real.rpow_le_rpow hβ.le (beta_le_chord ht) + (by linarith : 0 ≤ (m - 5) / 2) + have hcoef : 0 ≤ (m - 1) / 2 * ((m - 1) / 2 - 1) / 2 * (defect a x * t) ^ 2 := by + apply mul_nonneg _ (sq_nonneg _) + apply div_nonneg _ (by norm_num) + exact mul_nonneg (by linarith) (by linarith) + have h2 := mul_le_mul_of_nonneg_left hpow hcoef + have h3 := mul_le_mul_of_nonneg_left (h.trans (add_le_add le_rfl h2)) ht.1 + convert! h3 using 1 + ring + +/-- Integrating the pointwise Taylor majorant. All integrability is proved here. -/ +lemma integral_beta_taylor {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : x ≤ 1) : + (∫ t in (0 : ℝ)..1, t * beta a x t ^ ((m - 1) / 2)) ≤ + (∫ t in (0 : ℝ)..1, t * (1 - a * t) ^ (m - 1)) + + ((m - 1) / 2 * defect a x) * + (∫ t in (0 : ℝ)..1, t ^ 2 * (1 - a * t) ^ (m - 3)) + + ((m - 1) * (m - 3) / 8 * defect a x ^ 2) * + (∫ t in (0 : ℝ)..1, t ^ 3 * (1 - chord a x * t) ^ ((m - 5) / 2)) := by + have hcont : ∀ (k : ℕ) (c s : ℝ), 0 ≤ s → + Continuous (fun t : ℝ => t ^ k * (1 - c * t) ^ s) := by + intro k c s hs + exact (continuous_pow k).mul ((continuous_rpow_const hs).comp (by fun_prop)) + have hi0 : IntervalIntegrable (fun t : ℝ => t * (1 - a * t) ^ (m - 1)) volume 0 1 := by + simpa using (hcont 1 a (m - 1) (by linarith)).intervalIntegrable 0 1 + have hi1 := ((hcont 2 a (m - 3) (by linarith)).intervalIntegrable 0 1 (μ := volume)).const_mul + ((m - 1) / 2 * defect a x) + have hi2 := ((hcont 3 (chord a x) ((m - 5) / 2) (by linarith)).intervalIntegrable 0 1 + (μ := volume)).const_mul ((m - 1) * (m - 3) / 8 * defect a x ^ 2) + rw [← intervalIntegral.integral_const_mul, ← intervalIntegral.integral_const_mul, + ← intervalIntegral.integral_add hi0 hi1, + ← intervalIntegral.integral_add (hi0.add hi1) hi2] + apply intervalIntegral.integral_mono_on (by norm_num) _ ((hi0.add hi1).add hi2) + · intro t ht + exact beta_rpow_taylor hm ha ha1 hx ht + · have hβ : Continuous (fun t : ℝ => t * beta a x t ^ ((m - 1) / 2)) := + continuous_id.mul ((continuous_rpow_const (by linarith : 0 ≤ (m - 1) / 2)).comp + (by unfold beta; fun_prop)) + exact hβ.intervalIntegrable 0 1 + +/-- **(T)**, for the actual integral, not an assumed scalar budget. +It holds even for real `m ≥ 7`; raw polar is only needed elsewhere to supply `c > 0`. +Each nonnegative linear majorant is extended only as far as its zero. -/ +theorem budget_le {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : x ≤ 1) (hc : 0 < chord a x) : + budget m a x ≤ 1 / (m + 1) + beta a x 1 ^ (m / 2) + + defect a x / (a * (m - 2)) + + 12 * m * a ^ 2 * defect a x ^ 2 / (chord a x ^ 4 * (m + 1) * (m + 3)) := by + have hm0 : 0 < m := by linarith + have hm1 : 0 < m - 1 := by linarith + have hm2 : 0 < m - 2 := by linarith + have hm3 : 0 < m - 3 := by linarith + have hmp1 : 0 < m + 1 := by linarith + have hmp3 : 0 < m + 3 := by linarith + have hd := defect_nonneg ha.le hx + have hc1 := (chord_lt_one ha ha1 hx).le + have h0 := integral_chord_extend (s := m - 1) (by linarith) ha ha1.le 1 + simp only [pow_one] at h0 + rw [integral_chord_lin hm1 ha] at h0 + have h1 := integral_chord_extend (s := m - 3) (by linarith) ha ha1.le 2 + rw [integral_chord_sq hm3 ha] at h1 + have h2 := integral_chord_extend (s := (m - 5) / 2) (by linarith) hc hc1 3 + rw [integral_chord_pow (by linarith) hc] at h2 + have hcoef1 : 0 ≤ (m - 1) / 2 * defect a x := mul_nonneg (by linarith) hd + have hcoef2 : 0 ≤ (m - 1) * (m - 3) / 8 * defect a x ^ 2 := by positivity + have hsum := (integral_beta_taylor hm ha ha1 hx).trans + (add_le_add (add_le_add h0 (mul_le_mul_of_nonneg_left h1 hcoef1)) + (mul_le_mul_of_nonneg_left h2 hcoef2)) + have htotal := mul_le_mul_of_nonneg_left hsum (show 0 ≤ m * a ^ 2 by positivity) + have heq : m * a ^ 2 * + (1 / (a ^ 2 * ((m - 1 + 1) * (m - 1 + 2))) + + ((m - 1) / 2 * defect a x) * + (2 / (a ^ 3 * ((m - 3 + 1) * (m - 3 + 2) * (m - 3 + 3)))) + + ((m - 1) * (m - 3) / 8 * defect a x ^ 2) * + (6 / (chord a x ^ 4 * (((m - 5) / 2 + 1) * ((m - 5) / 2 + 2) * + ((m - 5) / 2 + 3) * ((m - 5) / 2 + 4))))) = + 1 / (m + 1) + defect a x / (a * (m - 2)) + + 12 * m * a ^ 2 * defect a x ^ 2 / (chord a x ^ 4 * (m + 1) * (m + 3)) := by + have he1 : m - 1 + 1 = m := by ring + have he2 : m - 1 + 2 = m + 1 := by ring + have he3 : m - 3 + 1 = m - 2 := by ring + have he4 : m - 3 + 2 = m - 1 := by ring + have he5 : m - 3 + 3 = m := by ring + have he6 : ((m - 5) / 2 + 1) * ((m - 5) / 2 + 2) * + ((m - 5) / 2 + 3) * ((m - 5) / 2 + 4) = + (m - 3) * (m - 1) * (m + 1) * (m + 3) / 16 := by ring + rw [he1, he2, he3, he4, he5, he6] + field_simp [ha.ne', hc.ne', hm0.ne', hm1.ne', hm2.ne', hm3.ne', hmp1.ne', hmp3.ne'] + ring + rw [heq] at htotal + unfold budget + linarith + +lemma chord_eq_one_sub_beta (a x : ℝ) : chord a x = 1 - beta a x 1 := by + unfold chord beta + ring + +lemma defect_eq_beta_sub_sq (a x : ℝ) : defect a x = beta a x 1 - (1 - a) ^ 2 := by + unfold defect beta + ring + +/-- The paper's exact `b,c,d` notation, with `T` expanded as an integral. -/ +theorem finite_taylor_budget {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : x ≤ 1) (hc : 0 < 1 - beta a x 1) : + let b := beta a x 1 + let c := 1 - b + let d := 2 * a * (1 - x) + b ^ (m / 2) + m * a ^ 2 * (∫ t in (0 : ℝ)..1, t * beta a x t ^ ((m - 1) / 2)) ≤ + 1 / (m + 1) + b ^ (m / 2) + d / (a * (m - 2)) + + 12 * m * a ^ 2 * d ^ 2 / (c ^ 4 * (m + 1) * (m + 3)) := by + have h := budget_le hm ha ha1 hx (by simpa [chord_eq_one_sub_beta] using hc) + simpa only [budget, defect, chord_eq_one_sub_beta] using h + +end Sendov.PaperTaylor diff --git a/Sendov/Boundary.lean b/Sendov/Boundary.lean index b7dbee4..2650f7b 100644 --- a/Sendov/Boundary.lean +++ b/Sendov/Boundary.lean @@ -23,10 +23,11 @@ The polar identity is useless here: at `a = 1` the reflected point `1/a` coincid `∑ⱼ qⱼ = 2 ∑ⱼ 1/(1 - zⱼ)`, `qⱼ = 1/(1 - wⱼ)`. -Both sides are then sandwiched. On the left `Re qⱼ ≤ ‖qⱼ‖ ≤ 1`, so the real part is at most -`n-1`; on the right `Re 1/(1-z) ≥ 1/2` for `‖z‖ ≤ 1`, because -`Re 1/(1-z) - 1/2 = (1-‖z‖²)/(2‖1-z‖²)`, so the real part is at least `n-1`. Equality forces -`Re qⱼ = 1` for every `j`, hence `qⱼ = 1`, hence every critical point is `0`, hence +The right side has real part at least `n-1`: `Re 1/(1-z) ≥ 1/2` for `‖z‖ ≤ 1`, because +`Re 1/(1-z) - 1/2 = (1-‖z‖²)/(2‖1-z‖²)`. On the left `‖qⱼ‖ ≤ 1` gives +`∑ⱼ ‖qⱼ‖² ≤ n-1`. The squared-distance identity now gives +`0 ≤ ∑ⱼ ‖qⱼ - 1‖² = ∑ⱼ ‖qⱼ‖² - 2 Re ∑ⱼ qⱼ + (n-1) ≤ 0`. +Every summand vanishes, hence every `qⱼ = 1`, hence every critical point is `0`, hence `p' = n c Xⁿ⁻¹` and `p = c(Xⁿ - 1)`. The repeated-root case is handled before any division: if `1` is a multiple zero then `p'(1) = 0` @@ -86,32 +87,31 @@ lemma half_le_re_inv_one_sub {z : ℂ} (hz : ‖z‖ ≤ 1) (hz1 : z ≠ 1) : simp only [Complex.sub_re, Complex.sub_im, Complex.one_re, Complex.one_im] nlinarith [hsq] -/-- A point of the closed unit disk with real part `1` is `1`. -/ -lemma eq_one_of_re_eq_one_of_norm_le_one {v : ℂ} (hre : v.re = 1) (hv : ‖v‖ ≤ 1) : v = 1 := by - have him : v.im = 0 := by - have hsq := pow_le_one₀ (norm_nonneg v) hv (n := 2) - rw [Complex.sq_norm, Complex.normSq_apply] at hsq - nlinarith only [hsq, hre, sq_nonneg v.im] - apply Complex.ext <;> simp [hre, him] - -/-- A multiset of nonnegative reals summing to zero is all zeroes. -/ -lemma eq_zero_of_sum_eq_zero {s : Multiset ℝ} (hs : ∀ x ∈ s, 0 ≤ x) (h : s.sum = 0) : - ∀ x ∈ s, x = 0 := by - exact Multiset.all_zero_of_le_zero_le_of_sum_eq_zero hs h - -lemma sum_le_card_mul (c : ℝ) : ∀ (s : Multiset ℝ), (∀ x ∈ s, x ≤ c) → - s.sum ≤ (s.card : ℝ) * c := by - intro s h - simpa only [nsmul_eq_mul] using Multiset.sum_le_card_nsmul s c h - -lemma card_mul_le_sum (c : ℝ) : ∀ (s : Multiset ℝ), (∀ x ∈ s, c ≤ x) → - (s.card : ℝ) * c ≤ s.sum := by - intro s h - simpa only [nsmul_eq_mul] using Multiset.card_nsmul_le_sum h - -lemma sum_map_one_sub_re (s : Multiset ℂ) : - (s.map (fun v => 1 - v.re)).sum = (s.card : ℝ) - (s.map (fun v => v.re)).sum := by - simp [Multiset.sum_map_sub, Multiset.map_const', Multiset.sum_replicate] +/-- The sum of squared distances to `1`, with multiplicities (also for the empty multiset). -/ +lemma sum_norm_sub_one_sq (s : Multiset ℂ) : + (s.map (fun v => ‖v - 1‖ ^ 2)).sum = + (s.map (fun v => ‖v‖ ^ 2)).sum - 2 * s.sum.re + s.card := by + simp_rw [Complex.sq_norm, Complex.normSq_sub, Complex.normSq_one, map_one, mul_one] + rw [Multiset.sum_map_sub, Multiset.sum_map_add, Multiset.sum_map_mul_left, sum_map_re] + simp only [Multiset.map_const', Multiset.sum_replicate, nsmul_eq_mul, mul_one] + ring + +/-- Average second moment at most `1` and average real part at least `1` force every point + to be `1`. No pointwise disk bound or nonempty hypothesis is needed. -/ +lemma all_eq_one_of_sum_norm_sq_le_card {s : Multiset ℂ} + (hsecond : (s.map (fun v => ‖v‖ ^ 2)).sum ≤ (s.card : ℝ)) + (hfirst : (s.card : ℝ) ≤ s.sum.re) : ∀ v ∈ s, v = 1 := by + have hzero : (s.map (fun v => ‖v - 1‖ ^ 2)).sum = 0 := by + apply le_antisymm + · rw [sum_norm_sub_one_sq] + linarith only [hsecond, hfirst] + · exact Multiset.sum_nonneg (by simp only [Multiset.mem_map]; rintro _ ⟨v, _, rfl⟩; positivity) + intro v hv + have hvzero := Multiset.all_zero_of_le_zero_le_of_sum_eq_zero + (s := s.map (fun v => ‖v - 1‖ ^ 2)) + (by simp only [Multiset.mem_map]; rintro _ ⟨u, _, rfl⟩; positivity) + hzero _ (Multiset.mem_map_of_mem _ hv) + exact sub_eq_zero.mp (norm_eq_zero.mp (sq_eq_zero_iff.mp hvzero)) /-! ### The boundary reciprocal identity -/ @@ -131,48 +131,27 @@ theorem boundary_reciprocal {n : ℕ} {Zs Qi : Multiset ℂ} (hn0 : (n : ℂ) linear_combination (-2 * (Zs.map (fun u => u⁻¹)).sum) * hI + 2 * h1 + hII - (n : ℂ) * h2 exact (mul_left_cancel₀ (mul_ne_zero hn0 hQ0) h).symm -/-! ### The sandwich -/ +/-! ### Average second-moment rigidity -/ -/-- Both sides of `(BR)` are pinned: the left has real part at most `N`, the right at least `N`, -so every `qⱼ` has real part `1` and hence, lying in the closed unit disk, equals `1`. -/ -theorem all_q_eq_one {N : ℕ} {qs zs : Multiset ℂ} +/-- The boundary identity gives average real part at least `1`; an average second-moment +bound then forces all `qⱼ = 1`. This is weaker than assuming each `qⱼ` is in the unit disk. -/ +theorem all_q_eq_one_of_sum_norm_sq_le {N : ℕ} {qs zs : Multiset ℂ} (hqcard : qs.card = N) (hzcard : zs.card = N) - (hq1 : ∀ v ∈ qs, ‖v‖ ≤ 1) (hz1 : ∀ w ∈ zs, ‖w‖ ≤ 1) (hzne : ∀ w ∈ zs, w ≠ 1) + (hqsecond : (qs.map (fun v => ‖v‖ ^ 2)).sum ≤ (N : ℝ)) + (hz1 : ∀ w ∈ zs, ‖w‖ ≤ 1) (hzne : ∀ w ∈ zs, w ≠ 1) (hBR : qs.sum = 2 * (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum) : ∀ v ∈ qs, v = 1 := by - have hupper : (qs.map (fun v => v.re)).sum ≤ (N : ℝ) := by - have h := sum_le_card_mul 1 (qs.map (fun v => v.re)) (by - intro r hr - obtain ⟨v, hv, rfl⟩ := Multiset.mem_map.1 hr - exact (Complex.re_le_norm v).trans (hq1 v hv)) - rwa [Multiset.card_map, hqcard, mul_one] at h - have hlower : (N : ℝ) ≤ (qs.map (fun v => v.re)).sum := by - have h := card_mul_le_sum (1 / 2) (zs.map (fun w => (((1 : ℂ) - w)⁻¹).re)) (by + apply all_eq_one_of_sum_norm_sq_le_card (hqcard ▸ hqsecond) + have h := Multiset.card_nsmul_le_sum (s := zs.map (fun w => (((1 : ℂ) - w)⁻¹).re)) + (a := (1 : ℝ) / 2) (by intro r hr obtain ⟨w, hw, rfl⟩ := Multiset.mem_map.1 hr exact half_le_re_inv_one_sub (hz1 w hw) (hzne w hw)) - rw [Multiset.card_map, hzcard] at h - have hmapre : (zs.map (fun w => (((1 : ℂ) - w)⁻¹).re)).sum - = (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum.re := by - rw [← sum_map_re, Multiset.map_map] - rfl - have hre : (qs.map (fun v => v.re)).sum - = 2 * (zs.map (fun w => (((1 : ℂ) - w)⁻¹).re)).sum := by - rw [sum_map_re, hBR, hmapre, Complex.mul_re] - simp - rw [hre] - linarith - have heq : (qs.map (fun v => 1 - v.re)).sum = 0 := by - rw [sum_map_one_sub_re, hqcard] - linarith - intro v hv - refine eq_one_of_re_eq_one_of_norm_le_one ?_ (hq1 v hv) - have hzero := eq_zero_of_sum_eq_zero (s := qs.map (fun v => 1 - v.re)) (by - intro r hr - obtain ⟨u, hu, rfl⟩ := Multiset.mem_map.1 hr - have := (Complex.re_le_norm u).trans (hq1 u hu) - linarith) heq (1 - v.re) (Multiset.mem_map_of_mem _ hv) - linarith + rw [Multiset.card_map, hzcard, nsmul_eq_mul] at h + rw [hqcard, hBR, Complex.mul_re, Complex.re_ofNat, Complex.im_ofNat, + zero_mul, sub_zero, ← sum_map_re, Multiset.map_map] + simp only [Function.comp_def] + linarith only [h] /-! ### Rubinstein's theorem at `a = 1` -/ @@ -270,8 +249,15 @@ theorem rubinstein_one {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegree rw [Multiset.map_map] rfl rw [hQiinv, hZsinv] at hBRraw + -- Pointwise unit-disk bounds imply the average second-moment bound. + have hqsecond : (q.map (fun v => ‖v‖ ^ 2)).sum ≤ ((n - 1 : ℕ) : ℝ) := by + have h := Multiset.sum_le_card_nsmul (q.map (fun v => ‖v‖ ^ 2)) (1 : ℝ) (by + intro r hr + obtain ⟨v, hv, rfl⟩ := Multiset.mem_map.1 hr + exact pow_le_one₀ (norm_nonneg v) (hq1 v hv)) + simpa only [Multiset.card_map, hqcard, nsmul_eq_mul, mul_one] using h -- every `qⱼ` is `1`, so every critical point is `0` - have hqone := all_q_eq_one hqcard hzcard hq1 hz1 hzne hBRraw + have hqone := all_q_eq_one_of_sum_norm_sq_le hqcard hzcard hqsecond hz1 hzne hBRraw have hderivX : derivative p = C ((n : ℂ) * p.leadingCoeff) * X ^ (n - 1) := by rw [hpq] congr 1 diff --git a/Sendov/Collinear/Balance.lean b/Sendov/Collinear/Balance.lean new file mode 100644 index 0000000..678b146 --- /dev/null +++ b/Sendov/Collinear/Balance.lean @@ -0,0 +1,72 @@ +import Sendov.Collinear.Mass + +open Polynomial +namespace Collinear + +/-- Logarithmic derivative balance at a simple marked root. -/ +theorem reciprocal_balance (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree) + (a : ℝ) (ha : a ∈ p.roots) (hd : p.derivative.eval a ≠ 0) : + (p.derivative.roots.map (fun x => 1 / (a - x))).sum = + 2 * (p.roots.map (fun x => 1 / (a - x))).sum := by + classical + have hp : p ≠ 0 := ne_zero_of_mem_roots ha + let g := p /ₘ (X - C a) + have hfac : (X - C a) * g = p := mul_divByMonic_eq_iff_isRoot.mpr + ((mem_roots hp).mp ha) + have hg : g ≠ 0 := by intro h; simp [h] at hfac; exact hp hfac.symm + have hgs : g.Splits := hs.of_dvd hp ⟨X - C a, by rw [mul_comm]; exact hfac.symm⟩ + have hder : p.derivative = g + (X - C a) * g.derivative := by + rw [← hfac, derivative_mul]; simp + have heval : p.derivative.eval a = g.eval a := by rw [hder]; simp + have heval2 : p.derivative.derivative.eval a = 2 * g.derivative.eval a := by + rw [hder, derivative_add, derivative_mul]; simp; ring + have hroots : p.roots = {a} + g.roots := by + rw [← hfac, roots_mul (mul_ne_zero (X_sub_C_ne_zero a) hg), roots_X_sub_C] + rw [← (derivative_root_budget p hs hn).1.eval_derivative_div_eval_of_ne_zero hd, + heval2, heval, mul_div_assoc, + hgs.eval_derivative_div_eval_of_ne_zero (heval ▸ hd)] + rw [hroots] + simp only [Multiset.map_add, Multiset.map_singleton, Multiset.sum_add, + Multiset.sum_singleton, sub_self, div_zero, zero_add] + +/-- Strict-side decomposition; occurrences at the mark contribute zero. -/ +theorem reciprocal_decomposition (s : Multiset ℝ) (a : ℝ) : + (s.map (fun x => 1 / (a - x))).sum = + ((s.filter (· < a)).map (fun x => 1 / (a - x))).sum - + ((s.filter (a < ·)).map (fun x => 1 / (x - a))).sum ∧ + (s.map (fun x => 1 / |a - x|)).sum = + ((s.filter (· < a)).map (fun x => 1 / (a - x))).sum + + ((s.filter (a < ·)).map (fun x => 1 / (x - a))).sum := by + classical + induction s using Multiset.induction_on with + | empty => simp + | @cons x s ih => + simp only [Multiset.map_cons, Multiset.sum_cons, Multiset.filter_cons] + rcases lt_trichotomy x a with h | rfl | h + · simp only [h, not_lt.mpr h.le, ite_true, ite_false, zero_add, + Multiset.map_add, Multiset.sum_add, Multiset.map_singleton, Multiset.sum_singleton, + abs_of_pos (sub_pos.mpr h), ih.1, ih.2] + constructor <;> ring + · simpa only [lt_self_iff_false, ite_false, sub_self, abs_zero, div_zero, zero_add] + using ih + · have he : 1 / (a - x) = -(1 / (x - a)) := by rw [← neg_sub x a, div_neg] + simp only [h, not_lt.mpr h.le, ite_true, ite_false, zero_add, + Multiset.map_add, Multiset.sum_add, Multiset.map_singleton, Multiset.sum_singleton, + abs_of_neg (sub_neg.mpr h), neg_sub, he, ih.1, ih.2] + constructor <;> ring + +/-- Signed balance plus interlacing controls each side by half the total mass. -/ +theorem two_sided_mass (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree) + (a : ℝ) (ha : a ∈ p.roots) (hd : p.derivative.eval a ≠ 0) : + 2 * ((p.roots.filter (· < a)).map (fun x => 1 / (a - x))).sum ≤ + (p.derivative.roots.map (fun x => 1 / |a - x|)).sum ∧ + 2 * ((p.roots.filter (a < ·)).map (fun x => 1 / (x - a))).sum ≤ + (p.derivative.roots.map (fun x => 1 / |a - x|)).sum := by + obtain ⟨hl, hr⟩ := signed_reciprocal_domination p hs hn a ha + have hb := reciprocal_balance p hs hn a ha hd + rw [(reciprocal_decomposition p.roots a).1, + (reciprocal_decomposition p.derivative.roots a).1] at hb + rw [(reciprocal_decomposition p.derivative.roots a).2] + constructor <;> linarith + +end Collinear diff --git a/Sendov/Collinear/Diameter.lean b/Sendov/Collinear/Diameter.lean new file mode 100644 index 0000000..9201a1b --- /dev/null +++ b/Sendov/Collinear/Diameter.lean @@ -0,0 +1,70 @@ +import Sendov.Collinear.Balance + +open Polynomial +namespace Collinear + +/-- No division by a side length: this also covers empty endpoint sides. -/ +private theorem count_le_side_mass (s : Multiset ℝ) (A B a : ℝ) + (hb : ∀ x ∈ s, x ∈ Set.Icc A B) (hne : a ∉ s) : + (s.card : ℝ) ≤ + (a - A) * ((s.filter (· < a)).map (fun x => 1 / (a - x))).sum + + (B - a) * ((s.filter (a < ·)).map (fun x => 1 / (x - a))).sum := by + classical + induction s using Multiset.induction_on with + | empty => simp + | @cons x s ih => + have hxs := hb x (Multiset.mem_cons_self x s) + have hxa : x ≠ a := by intro h; subst x; exact hne (Multiset.mem_cons_self a s) + have hi := ih (fun y hy => hb y (Multiset.mem_cons_of_mem hy)) + (fun h => hne (Multiset.mem_cons_of_mem h)) + simp only [Multiset.card_cons, Nat.cast_add, Nat.cast_one, Multiset.filter_cons] + rcases lt_or_gt_of_ne hxa with h | h + · have ht : 1 ≤ (a - A) * (1 / (a - x)) := by + rw [mul_one_div, le_div_iff₀ (sub_pos.mpr h)]; linarith [hxs.1] + simp only [h, not_lt.mpr h.le, ite_true, ite_false, zero_add, + Multiset.map_add, Multiset.sum_add, Multiset.map_singleton, Multiset.sum_singleton] + nlinarith + · have ht : 1 ≤ (B - a) * (1 / (x - a)) := by + rw [mul_one_div, le_div_iff₀ (sub_pos.mpr h)]; linarith [hxs.2] + simp only [h, not_lt.mpr h.le, ite_true, ite_false, zero_add, + Multiset.map_add, Multiset.sum_add, Multiset.map_singleton, Multiset.sum_singleton] + nlinarith + +/-- The real-root diameter bound with the multiple-root branch explicit. -/ +theorem diameter_reciprocal (p : ℝ[X]) (hs : p.Splits) (hn : 2 ≤ p.natDegree) + (A B : ℝ) (hAB : A < B) (hroots : ∀ x ∈ p.roots, x ∈ Set.Icc A B) + (a : ℝ) (ha : a ∈ p.roots) : + p.derivative.eval a = 0 ∨ + (p.natDegree - 1 : ℝ) * (2 / (B - A)) ≤ + (p.derivative.roots.map (fun x => 1 / |a - x|)).sum := by + classical + by_cases hd : p.derivative.eval a = 0 + · exact Or.inl hd + right + have hp := ne_zero_of_mem_roots ha + have hm : p.rootMultiplicity a = 1 := by + have hpos := (rootMultiplicity_pos hp).mpr ((mem_roots hp).mp ha) + have hnot : ¬1 < p.rootMultiplicity a := by + intro h; exact hd ((one_lt_rootMultiplicity_iff_isRoot hp).mp h).2 + omega + have hne : a ∉ p.roots.erase a := by + rw [← Multiset.count_eq_zero, Multiset.count_erase_self, count_roots, hm] + have hc := count_le_side_mass (p.roots.erase a) A B a + (fun x hx => hroots x (Multiset.mem_of_mem_erase hx)) hne + have hcard : ((p.roots.erase a).card : ℝ) = p.natDegree - 1 := by + have h := Multiset.card_erase_add_one ha + rw [hs.natDegree_eq_card_roots] at ⊢ + have hh : ((p.roots.erase a).card : ℝ) + 1 = p.roots.card := by exact_mod_cast h + linarith + have hside : + p.roots.filter (· < a) = (p.roots.erase a).filter (· < a) ∧ + p.roots.filter (a < ·) = (p.roots.erase a).filter (a < ·) := by + constructor <;> (conv_lhs => rw [← Multiset.cons_erase ha]) <;> simp + rw [hcard, ← hside.1, ← hside.2] at hc + obtain ⟨hl, hr⟩ := two_sided_mass p hs (by omega) a ha hd + have hL := mul_le_mul_of_nonneg_left hl (sub_nonneg.mpr (hroots a ha).1) + have hR := mul_le_mul_of_nonneg_left hr (sub_nonneg.mpr (hroots a ha).2) + rw [← mul_div_assoc, div_le_iff₀ (sub_pos.mpr hAB)] + nlinarith + +end Collinear diff --git a/Sendov/Collinear/Gate.lean b/Sendov/Collinear/Gate.lean new file mode 100644 index 0000000..d3023b0 --- /dev/null +++ b/Sendov/Collinear/Gate.lean @@ -0,0 +1,161 @@ +import Mathlib.Analysis.Calculus.LocalExtr.Polynomial +import Mathlib.Algebra.Polynomial.Splits + +open Polynomial + +namespace Collinear + +/-- Rolle's lower bounds exhaust the derivative degree. The old roots lose one +copy each; all remaining derivative roots are simple, and there are exactly one +fewer of them than distinct original roots. -/ +theorem derivative_root_budget (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree) : + p.derivative.Splits ∧ + p.derivative.roots = (p.roots - p.roots.dedup) + + (p.derivative.roots.toFinset \ p.roots.toFinset).val ∧ + (p.derivative.roots.toFinset \ p.roots.toFinset).card + 1 = + p.roots.toFinset.card := by + classical + let u := p.derivative.roots.toFinset \ p.roots.toFinset + let m := (p.roots - p.roots.dedup) + u.val + have hle : m ≤ p.derivative.roots := by + apply Multiset.le_iff_count.mpr + intro a + by_cases ha : a ∈ p.roots + · have hau : a ∉ u := by simp [u, ha] + simp only [m, Multiset.count_add, Multiset.count_sub, + Multiset.count_dedup, ha, ↓reduceIte] + have huz : u.val.count a = 0 := Multiset.count_eq_zero.mpr hau + rw [huz, add_zero, count_roots, count_roots] + exact rootMultiplicity_sub_one_le_derivative_rootMultiplicity p a + · have haz := Multiset.count_eq_zero.mpr ha + simp only [m, Multiset.count_add, Multiset.count_sub, haz, + Nat.zero_sub, zero_add] + exact Multiset.le_iff_count.mp + (le_trans (Finset.val_le_iff.mpr (Finset.sdiff_subset (s := p.derivative.roots.toFinset) + (t := p.roots.toFinset))) (Multiset.dedup_le _)) a + have hcardp : p.roots.card = p.natDegree := hs.natDegree_eq_card_roots.symm + have hcount := p.card_roots_le_derivative + have hupper := p.derivative.card_roots' + rw [p.natDegree_derivative] at hupper + have hcardd : p.derivative.roots.card = p.natDegree - 1 := by omega + have hsplit : p.derivative.Splits := + splits_iff_card_roots.mpr (by simpa [p.natDegree_derivative] using hcardd) + have hdistinct := p.card_roots_toFinset_le_card_roots_derivative_sdiff_roots_succ + have hdedup : p.roots.dedup.card = p.roots.toFinset.card := rfl + have hsmall : p.roots.toFinset.card ≤ p.roots.card := by + simpa [hdedup] using Multiset.card_le_card (Multiset.dedup_le p.roots) + have hmcard : m.card = p.natDegree - p.roots.toFinset.card + u.card := by + simp only [m, Multiset.card_add, Multiset.card_sub (Multiset.dedup_le _), + hcardp, hdedup, Finset.card_def] + have heq : m = p.derivative.roots := + Multiset.eq_of_le_of_card_le hle (by dsimp [u] at hmcard; omega) + have hnew : u.card + 1 = p.roots.toFinset.card := by + have := congrArg Multiset.card heq + omega + exact ⟨hsplit, heq.symm, hnew⟩ + +/-- A saturated finite interlacing has no dispensable point. Erasing a point +would violate mathlib's interlaced cardinality bound. -/ +private theorem essential_gap (s t : Finset ℝ) (hcard : t.card + 1 = s.card) + (hrolle : ∀ a ∈ s, ∀ b ∈ s, a < b → + (∀ x ∈ s, x ∉ Set.Ioo a b) → ∃ w ∈ t, a < w ∧ w < b) + (z : ℝ) (hz : z ∈ t) : + ∃ a ∈ s, ∃ b ∈ s, a < z ∧ z < b ∧ + (∀ x ∈ s, x ∉ Set.Ioo a b) ∧ + (∀ w ∈ t, w ∈ Set.Ioo a b → w = z) := by + classical + have hfail : ¬ (∀ a ∈ s, ∀ b ∈ s, a < b → + (∀ x ∈ s, x ∉ Set.Ioo a b) → ∃ w ∈ t.erase z, a < w ∧ w < b) := by + intro h + have hc := Finset.card_le_of_interleaved h + rw [Finset.card_erase_of_mem hz] at hc + have hp := Finset.card_pos.mpr ⟨z, hz⟩ + omega + push Not at hfail + obtain ⟨a, ha, b, hb, hab, hgap, hnone⟩ := hfail + have hunique : ∀ w ∈ t, w ∈ Set.Ioo a b → w = z := by + intro w hw hwi + by_contra hwz + exact (hnone w (Finset.mem_erase.mpr ⟨hwz, hw⟩) hwi.1).not_gt hwi.2 + obtain ⟨w, hw, haw, hwb⟩ := hrolle a ha b hb hab hgap + have hwz := hunique w hw ⟨haw, hwb⟩ + exact ⟨a, ha, b, hb, hwz ▸ haw, hwz ▸ hwb, hgap, hunique⟩ + +private theorem rolle_new (p : ℝ[X]) (hp : p ≠ 0) (hd : p.derivative ≠ 0) + (a : ℝ) (ha : a ∈ p.roots.toFinset) + (b : ℝ) (hb : b ∈ p.roots.toFinset) (hab : a < b) + (hgap : ∀ x ∈ p.roots.toFinset, x ∉ Set.Ioo a b) : + ∃ w ∈ p.derivative.roots.toFinset \ p.roots.toFinset, a < w ∧ w < b := by + rw [Multiset.mem_toFinset, mem_roots hp] at ha hb + obtain ⟨w, hwi, hw⟩ := exists_deriv_eq_zero hab p.continuousOn (ha.trans hb.symm) + refine ⟨w, Finset.mem_sdiff.mpr ⟨?_, ?_⟩, hwi⟩ + · rwa [Multiset.mem_toFinset, mem_roots hd, IsRoot, ← p.deriv] + · exact fun h => hgap w h hwi + +/-- Every derivative root not inherited from an old multiple root is simple +and is the unique derivative root in one adjacent open root gap. -/ +theorem new_critical_point_gap (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree) + (z : ℝ) (hz : z ∈ p.derivative.roots) (hzp : z ∉ p.roots) : + p.derivative.rootMultiplicity z = 1 ∧ + ∃ a ∈ p.roots, ∃ b ∈ p.roots, + a < z ∧ z < b ∧ + (∀ x ∈ p.roots, x ∉ Set.Ioo a b) ∧ + (∀ w ∈ p.derivative.roots, w ∈ Set.Ioo a b → w = z) := by + classical + obtain ⟨_, heq, hcard⟩ := derivative_root_budget p hs hn + have hzt : z ∈ p.derivative.roots.toFinset \ p.roots.toFinset := by + simp [hz, hzp] + have hmult : p.derivative.rootMultiplicity z = 1 := by + rw [← count_roots, heq] + simp [Multiset.count_add, Multiset.count_sub, hz, hzp] + have hp : p ≠ 0 := by intro h; simp [h] at hn + have hd : p.derivative ≠ 0 := by + intro h + have := eq_C_of_derivative_eq_zero h + rw [this] at hn + simp at hn + obtain ⟨a, ha, b, hb, haz, hzb, hgap, huniq⟩ := + essential_gap _ _ hcard (rolle_new p hp hd) z hzt + refine ⟨hmult, a, Multiset.mem_toFinset.mp ha, b, Multiset.mem_toFinset.mp hb, + haz, hzb, ?_, ?_⟩ + · intro x hx + exact hgap x (Multiset.mem_toFinset.mpr hx) + · intro w hw hwi + apply huniq w _ hwi + exact Finset.mem_sdiff.mpr ⟨Multiset.mem_toFinset.mpr hw, + fun h => hgap w h hwi⟩ + +/-- Every adjacent distinct-root gap contains exactly one derivative root; +that root is simple. No squarefreeness hypothesis is imposed on `p`. -/ +theorem adjacent_gap_unique (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree) + (a : ℝ) (ha : a ∈ p.roots) (b : ℝ) (hb : b ∈ p.roots) + (hab : a < b) (hgap : ∀ x ∈ p.roots, x ∉ Set.Ioo a b) : + ∃! z : ℝ, z ∈ p.derivative.roots ∧ z ∈ Set.Ioo a b ∧ + p.derivative.rootMultiplicity z = 1 := by + classical + have hp : p ≠ 0 := by intro h; simp [h] at hn + have hd : p.derivative ≠ 0 := by + intro h + have := eq_C_of_derivative_eq_zero h + rw [this] at hn + simp at hn + obtain ⟨z, hz, haz, hzb⟩ := rolle_new p hp hd a + (Multiset.mem_toFinset.mpr ha) b (Multiset.mem_toFinset.mpr hb) hab + (fun x hx => hgap x (Multiset.mem_toFinset.mp hx)) + obtain ⟨hzd, hzp⟩ := Finset.mem_sdiff.mp hz + have hzroot := Multiset.mem_toFinset.mp hzd + obtain ⟨hmult, c, hc, d, hdroot, hcz, hzd', hgap', huniq⟩ := + new_critical_point_gap p hs hn z hzroot + (fun h => hzp (Multiset.mem_toFinset.mpr h)) + have hac : a = c := le_antisymm + (le_of_not_gt (fun h => hgap' a ha ⟨h, haz.trans hzd'⟩)) + (le_of_not_gt (fun h => hgap c hc ⟨h, hcz.trans hzb⟩)) + have hbd : b = d := le_antisymm + (le_of_not_gt (fun h => hgap d hdroot ⟨haz.trans hzd', h⟩)) + (le_of_not_gt (fun h => hgap' b hb ⟨hcz.trans hzb, h⟩)) + refine ⟨z, ⟨hzroot, ⟨haz, hzb⟩, hmult⟩, ?_⟩ + intro w hw + apply huniq w hw.1 + simpa [← hac, ← hbd] using hw.2.1 + +end Collinear diff --git a/Sendov/Collinear/Mass.lean b/Sendov/Collinear/Mass.lean new file mode 100644 index 0000000..a4588a1 --- /dev/null +++ b/Sendov/Collinear/Mass.lean @@ -0,0 +1,104 @@ +import Sendov.Collinear.Gate + +open Polynomial +open scoped BigOperators + +namespace Collinear + +/-- Monotone nonnegative mass transfers along finite root gaps. Multiplicities +are handled by cancelling the common `s - s.dedup` part, not by discarding them. -/ +private theorem weighted_left {α : Type*} [LinearOrder α] + (s t : Multiset α) (u : Finset α) + (ht : t = (s - s.dedup) + u.val) + (hgap : ∀ x ∈ s, ∀ y ∈ s, x < y → + (∀ v ∈ s, v ∉ Set.Ioo x y) → ∃ w ∈ u, x < w ∧ w < y) + (a : α) (ha : a ∈ s) (f : α → ℝ) + (hf : ∀ x y, x ≤ y → y < a → f x ≤ f y) + (hpos : ∀ y, y < a → 0 ≤ f y) : + ((s.filter (· < a)).map f).sum ≤ ((t.filter (· < a)).map f).sum := by + classical + let l := s.toFinset.filter (· < a) + let r := u.filter (· < a) + have hex : ∀ x, ∃ y, x ∈ l → + y ∈ r ∧ x < y ∧ (∀ v ∈ s, x < v → y < v) := by + intro x + by_cases hx : x ∈ l + · obtain ⟨hxs, hxa⟩ := Finset.mem_filter.mp hx + obtain ⟨b, hb, hxb, hleast⟩ := Finset.exists_next_right + (s := s.toFinset) ⟨a, Multiset.mem_toFinset.mpr ha, hxa⟩ + obtain ⟨w, hw, hxw, hwb⟩ := hgap x (Multiset.mem_toFinset.mp hxs) + b (Multiset.mem_toFinset.mp hb) hxb (by + intro v hv hvi + exact hvi.2.not_ge (hleast v (Multiset.mem_toFinset.mpr hv) hvi.1)) + refine ⟨w, fun _ => ⟨Finset.mem_filter.mpr ⟨hw, ?_⟩, hxw, ?_⟩⟩ + · exact hwb.trans_le (hleast a (Multiset.mem_toFinset.mpr ha) hxa) + · intro v hv hxv + exact hwb.trans_le (hleast v (Multiset.mem_toFinset.mpr hv) hxv) + · exact ⟨a, fun h => (hx h).elim⟩ + choose g hg using hex + have hginj : Set.InjOn g (↑l : Set α) := by + intro x hx y hy heq + rcases lt_trichotomy x y with hxy | hxy | hyx + · have hlt := (hg x hx).2.2 y + (Multiset.mem_toFinset.mp (Finset.mem_filter.mp hy).1) hxy + exact False.elim ((hlt.trans (hg y hy).2.1).ne heq) + · exact hxy + · have hlt := (hg y hy).2.2 x + (Multiset.mem_toFinset.mp (Finset.mem_filter.mp hx).1) hyx + exact False.elim ((hlt.trans (hg x hx).2.1).ne heq.symm) + have hsum : ∑ x ∈ l, f x ≤ ∑ y ∈ r, f y := calc + _ ≤ ∑ x ∈ l, f (g x) := Finset.sum_le_sum (fun x hx => + hf x (g x) (hg x hx).2.1.le (Finset.mem_filter.mp (hg x hx).1).2) + _ = ∑ y ∈ l.image g, f y := (Finset.sum_image hginj).symm + _ ≤ ∑ y ∈ r, f y := Finset.sum_le_sum_of_subset_of_nonneg + (Finset.image_subset_iff.mpr (fun x hx => (hg x hx).1)) + (fun y hy _ => hpos y (Finset.mem_filter.mp hy).2) + have hsdec : s = (s - s.dedup) + s.dedup := + (tsub_add_cancel_of_le (Multiset.dedup_le s)).symm + have hs_sum := congrArg (fun m : Multiset α => ((m.filter (· < a)).map f).sum) hsdec + have ht_sum := congrArg (fun m : Multiset α => ((m.filter (· < a)).map f).sum) ht + simp only [Multiset.filter_add, Multiset.map_add, Multiset.sum_add] at hs_sum ht_sum + rw [hs_sum, ht_sum] + exact add_le_add (le_refl _) hsum + +/-- The two signed-side inequalities in Zhang's Proposition 3.1. They hold +with all occurrences counted, even before imposing simplicity of `a` (the +strict filters omit occurrences equal to `a`). -/ +theorem signed_reciprocal_domination (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree) + (a : ℝ) (ha : a ∈ p.roots) : + (((p.roots.filter (· < a)).map (fun x => 1 / (a - x))).sum ≤ + ((p.derivative.roots.filter (· < a)).map (fun y => 1 / (a - y))).sum) ∧ + (((p.roots.filter (a < ·)).map (fun x => 1 / (x - a))).sum ≤ + ((p.derivative.roots.filter (a < ·)).map (fun y => 1 / (y - a))).sum) := by + classical + obtain ⟨_, ht, _⟩ := derivative_root_budget p hs hn + have hgap : ∀ x ∈ p.roots, ∀ y ∈ p.roots, x < y → + (∀ v ∈ p.roots, v ∉ Set.Ioo x y) → + ∃ w ∈ p.derivative.roots.toFinset \ p.roots.toFinset, x < w ∧ w < y := by + intro x hx y hy hxy hg + obtain ⟨w, hw, _⟩ := adjacent_gap_unique p hs hn x hx y hy hxy hg + exact ⟨w, Finset.mem_sdiff.mpr ⟨Multiset.mem_toFinset.mpr hw.1, + fun h => hg w (Multiset.mem_toFinset.mp h) hw.2.1⟩, hw.2.1⟩ + constructor + · apply weighted_left p.roots p.derivative.roots _ ht hgap a ha (fun x => 1 / (a - x)) + · intro x y hxy hya + exact one_div_le_one_div_of_le (sub_pos.mpr hya) (sub_le_sub_left hxy a) + · intro y hya + exact le_of_lt (one_div_pos.mpr (sub_pos.mpr hya)) + · refine weighted_left (α := OrderDual ℝ) + (show Multiset (OrderDual ℝ) from p.roots) + (show Multiset (OrderDual ℝ) from p.derivative.roots) + (show Finset (OrderDual ℝ) from + p.derivative.roots.toFinset \ p.roots.toFinset) ?_ + (fun x hx y hy hyx hg => ?_) (OrderDual.toDual a) ha + (fun x => 1 / (OrderDual.ofDual x - a)) ?_ ?_ + · exact ht + · obtain ⟨w, hw, hyw, hwx⟩ := hgap y hy x hx hyx + (fun v hv hvi => hg v hv ⟨hvi.2, hvi.1⟩) + exact ⟨w, hw, hwx, hyw⟩ + · intro x y hyx hay + exact one_div_le_one_div_of_le (sub_pos.mpr hay) (sub_le_sub_right hyx a) + · intro y hay + exact le_of_lt (one_div_pos.mpr (sub_pos.mpr hay)) + +end Collinear diff --git a/Sendov/Collinear/Moment.lean b/Sendov/Collinear/Moment.lean new file mode 100644 index 0000000..71906f9 --- /dev/null +++ b/Sendov/Collinear/Moment.lean @@ -0,0 +1,52 @@ +import Sendov.Collinear.Diameter +import Mathlib.Analysis.MeanInequalitiesPow + +open Polynomial +open scoped BigOperators +namespace Collinear + +/-- Uniform Jensen weights on occurrence indices, not on distinct values. -/ +private theorem multiset_moment_bound (s : Multiset ℝ) (hs : 0 < s.card) + (f : ℝ → ℝ) (hf : ∀ x ∈ s, 0 ≤ f x) (c : ℝ) (hc : 0 ≤ c) + (hmean : (s.card : ℝ) * c ≤ (s.map f).sum) (r : ℝ) (hr : 1 ≤ r) : + (s.card : ℝ) * c ^ r ≤ (s.map (fun x => f x ^ r)).sum := by + classical + have hcard : (0 : ℝ) < s.card := by exact_mod_cast hs + have hj := Real.rpow_arith_mean_le_arith_mean_rpow + (Finset.univ : Finset (Fin s.toList.length)) (fun _ => (s.card : ℝ)⁻¹) + (fun i => f s.toList[i.val]) (fun _ _ => inv_nonneg.mpr hcard.le) + (by simp [Multiset.length_toList, hcard.ne']) + (fun i _ => hf _ (Multiset.mem_toList.mp (List.getElem_mem i.isLt))) hr + simp only [← Finset.mul_sum, Fin.sum_univ_fun_getElem, Multiset.sum_map_toList] at hj + rw [Fin.sum_univ_fun_getElem s.toList (fun x => f x ^ r), Multiset.sum_map_toList] at hj + have hm : c ≤ (s.card : ℝ)⁻¹ * (s.map f).sum := by + rw [← div_eq_inv_mul, le_div_iff₀ hcard] + simpa [mul_comm] using hmean + have hp := (Real.rpow_le_rpow hc hm (by linarith)).trans hj + have h := mul_le_mul_of_nonneg_left hp hcard.le + simpa only [← mul_assoc, mul_inv_cancel₀ hcard.ne', one_mul] using h + +/-- All real exponents at least one, full derivative multiplicities. The left +branch is essential: the real inverse at zero is not an infinite moment. -/ +theorem diameter_moment (p : ℝ[X]) (hs : p.Splits) (hn : 2 ≤ p.natDegree) + (A B : ℝ) (hAB : A < B) (hroots : ∀ x ∈ p.roots, x ∈ Set.Icc A B) + (a : ℝ) (ha : a ∈ p.roots) (r : ℝ) (hr : 1 ≤ r) : + p.derivative.eval a = 0 ∨ + (p.natDegree - 1 : ℝ) * (2 / (B - A)) ^ r ≤ + (p.derivative.roots.map (fun x => |a - x| ^ (-r))).sum := by + rcases diameter_reciprocal p hs hn A B hAB hroots a ha with hd | hmass + · exact Or.inl hd + right + have hcount : p.derivative.roots.card = p.natDegree - 1 := by + rw [← (derivative_root_budget p hs (by omega)).1.natDegree_eq_card_roots, + natDegree_derivative] + have hcard : (p.derivative.roots.card : ℝ) = p.natDegree - 1 := by + rw [hcount, Nat.cast_sub (by omega), Nat.cast_one] + have hpos : 0 < p.derivative.roots.card := by rw [hcount]; omega + have h := multiset_moment_bound p.derivative.roots hpos (fun x => 1 / |a - x|) + (fun x _ => one_div_nonneg.mpr (abs_nonneg _)) (2 / (B - A)) (by positivity) + (by rwa [hcard]) r hr + simpa only [hcard, one_div, Real.inv_rpow (abs_nonneg _), + Real.rpow_neg (abs_nonneg _)] using h + +end Collinear diff --git a/Sendov/Interior.lean b/Sendov/Interior.lean index 1aeae62..beffd65 100644 --- a/Sendov/Interior.lean +++ b/Sendov/Interior.lean @@ -6,6 +6,7 @@ Authors: Terence Tao import Sendov.Analytic.OriginExact import Sendov.Analytic.Polar import Sendov.Analytic.LowDegree +import Sendov.Analytic.FirstOriginSmall import Sendov.Analytic.Jsum import Sendov.Counterexample.Factor import Sendov.Reduction.Main @@ -25,7 +26,9 @@ disk, and `Sendov.exists_root_multiset` writes `p` over the other zeroes `zⱼ`. From `(⋆)` the argument branches on the degree. -* For `n ≥ 6`, AM–GM relaxes `(⋆)` to the raw polar inequality `(1Q)`, the centroid identity and +* For `n = 6` or `n = 7`, the first-origin factorization bound and `(⋆)` feed + `Sendov.FirstOriginSmall.first_origin_polar_six_seven`, without the second-origin channel. +* For `n ≥ 8`, AM–GM relaxes `(⋆)` to the raw polar inequality `(1Q)`, the centroid identity and the two origin identities give `(origin-exact)`, and `Sendov.polar_origin_incompatible` says the two cannot hold together. * For `n ≤ 5`, `Sendov.low_degree_contradiction` shows `(⋆)` is already contradictory on its own, @@ -94,6 +97,10 @@ theorem sendov_interior {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegre -- the branch: low degree needs nothing further rcases (by omega : n ≤ 5 ∨ 6 ≤ n) with hn5 | hn6 · exact low_degree_contradiction hn hn5 ha0 ha1 hqcard hq1 hstar + by_cases hn67 : n = 6 ∨ n = 7 + · exact FirstOriginSmall.first_origin_polar_six_seven hn67 ha0 ha1 hqcard hq1 hstar + (FirstOriginSmall.norm_integral_Fprod_le_of_factorization (by omega) (ne_of_gt ha0) + hc0 hzcard hq0 hq1 hz1 hpa hpz hpq') have hn5 : 5 ≤ n := by omega -- `x + iy` is the centroid of the `qⱼ` obtain ⟨x, y, hxy⟩ : ∃ x y : ℝ, q.sum = ((n : ℂ) - 1) * ((x : ℂ) + (y : ℂ) * I) := by diff --git a/docs/paper-formalization/STATUS.md b/docs/paper-formalization/STATUS.md index 4187ac6..9d6fc03 100644 --- a/docs/paper-formalization/STATUS.md +++ b/docs/paper-formalization/STATUS.md @@ -4,6 +4,22 @@ Baseline: `0a4e966c41e1287f92d305d3bad8e70c8c295dde`. Integration branch: `formalize/paper-results-20260914`. Status: **IN PROGRESS**, not complete and not a uniform D proof. +## Checkpoint 1 — integrated and freshly rechecked + +Boundary rigidity and first-origin n=6/n=7 are now actual consumers of both +public Solution theorem proofs. The real-collinear moment theorem is exported +independently; it is not a proof dependency of the general complex theorem. +`PaperPolar`, `PaperTaylor`, and `PaperNearAlgebra` are now integrated, with +actual raw-integral domination, actual integral Taylor budget, and the full +rational near-endpoint rectangle respectively. Parent replay passed 60 gates +(34 elaborations, 26 independent kernel checks); the prior bulk module gates +are separate. Ten boundary/final theorem contracts match baseline exactly. +Near-endpoint D still requires endpoint decay and parameter assembly. + +The initial task allocation below is retained as the acceptance inventory; +worker assignments marked there refer to the completed first dispatch, not +claims that all enclosing targets are finished. + ## Acceptance units - Existing boundary average-square rigidity: re-integrate refined production diff --git a/docs/paper-formalization/checkpoint1.json b/docs/paper-formalization/checkpoint1.json new file mode 100644 index 0000000..9e3cc12 --- /dev/null +++ b/docs/paper-formalization/checkpoint1.json @@ -0,0 +1,9 @@ +{ + "status": "partial_kernel_verified", + "gates": 60, + "compile_gates": 34, + "kernel_gates": 26, + "seconds": 318.20658225315856, + "exact_boundary_final_contracts": 10, + "complete_D": false +} \ No newline at end of file diff --git a/docs/paper-formalization/imported-sources.json b/docs/paper-formalization/imported-sources.json new file mode 100644 index 0000000..6ce424a --- /dev/null +++ b/docs/paper-formalization/imported-sources.json @@ -0,0 +1,114 @@ +[ + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-near/Sendov/Analytic/PaperNearAlgebra.lean", + "target": "Sendov/Analytic/PaperNearAlgebra.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-near/tests/PaperNearAlgebra.lean", + "target": "tests/PaperNearAlgebra.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-taylor/Sendov/Analytic/PaperTaylor.lean", + "target": "Sendov/Analytic/PaperTaylor.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-taylor/tests/PaperTaylor.lean", + "target": "tests/PaperTaylor.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-polar/Sendov/Analytic/PaperPolar.lean", + "target": "Sendov/Analytic/PaperPolar.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-polar/Sendov/Tests/PaperPolar.lean", + "target": "tests/PaperPolar.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/Sendov.lean", + "target": "Sendov.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/Sendov/Analytic/FirstOriginAlgebra.lean", + "target": "Sendov/Analytic/FirstOriginAlgebra.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/Sendov/Analytic/FirstOriginBounds.lean", + "target": "Sendov/Analytic/FirstOriginBounds.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/Sendov/Analytic/FirstOriginSmall.lean", + "target": "Sendov/Analytic/FirstOriginSmall.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/Sendov/Boundary.lean", + "target": "Sendov/Boundary.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/Sendov/Collinear/Balance.lean", + "target": "Sendov/Collinear/Balance.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/Sendov/Collinear/Diameter.lean", + "target": "Sendov/Collinear/Diameter.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/Sendov/Collinear/Gate.lean", + "target": "Sendov/Collinear/Gate.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/Sendov/Collinear/Mass.lean", + "target": "Sendov/Collinear/Mass.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/Sendov/Collinear/Moment.lean", + "target": "Sendov/Collinear/Moment.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/Sendov/Interior.lean", + "target": "Sendov/Interior.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/tests/BoundaryAudit.lean", + "target": "tests/BoundaryAudit.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/tests/BoundaryContracts.lean", + "target": "tests/BoundaryContracts.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/tests/BoundaryProbe.lean", + "target": "tests/BoundaryProbe.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/tests/BoundaryWiring.lean", + "target": "tests/BoundaryWiring.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/tests/CollinearAcceptance.lean", + "target": "tests/CollinearAcceptance.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/tests/CollinearRound2Tests.lean", + "target": "tests/CollinearRound2Tests.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/tests/CollinearTests.lean", + "target": "tests/CollinearTests.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/tests/FirstOriginAudit.lean", + "target": "tests/FirstOriginAudit.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/tests/FirstOriginWiring.lean", + "target": "tests/FirstOriginWiring.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/tests/Localanalytic.lean", + "target": "tests/Localanalytic.lean" + }, + { + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-existing/tests/verify_existing_integration.py", + "target": "tests/verify_existing_integration.py" + } +] \ No newline at end of file diff --git a/tests/BoundaryAudit.lean b/tests/BoundaryAudit.lean new file mode 100644 index 0000000..499bc0a --- /dev/null +++ b/tests/BoundaryAudit.lean @@ -0,0 +1,44 @@ +import scripts.axioms + +#sendov_axioms Sendov.sum_norm_sub_one_sq +#sendov_axioms Sendov.all_eq_one_of_sum_norm_sq_le_card +#sendov_axioms Sendov.all_q_eq_one_of_sum_norm_sq_le +#sendov_axioms Sendov.rubinstein_one +#sendov_axioms Sendov.sendov_boundary_one + +-- Follow actual proof values, including opaque and private declarations, using +-- the repository's tests/NoFiniteRows.lean traversal pattern. A type reference +-- alone is deliberately not accepted as evidence of consumption. +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + let targets := #[`Sendov.rubinstein_one, + `Sendov.all_q_eq_one_of_sum_norm_sq_le, `Sendov.all_eq_one_of_sum_norm_sq_le_card, + `Sendov.sum_norm_sub_one_sq] + for name in targets do + unless (env.find? name).isSome do throwError "missing boundary target {name}" + for root in #[`SendovConjecture.sendov, `SendovConjecture.phelps_rodriguez] do + let mut pending := [root] + let mut visited : Std.HashSet Name := {} + while !pending.isEmpty do + let name := pending.head! + pending := pending.tail! + unless visited.contains name do + visited := visited.insert name + let some info := env.find? name | throwError "missing closure declaration {name}" + if let some value := info.value? (allowOpaque := true) then + for used in value.getUsedConstants do + pending := used :: pending + for target in targets do + unless visited.contains target do + throwError "missing actual boundary consumption: {root} -> {target}" + logInfo m!"BOUNDARY_VALUE {root} -> {target}" + if visited.contains `Sendov.all_q_eq_one then + throwError "retired pointwise wrapper consumed by {root}" + logInfo m!"BOUNDARY_NO_RETIRED_VALUE {root}" + logInfo m!"BOUNDARY_CLOSURE {root}: {visited.size}" + for retired in #[`Sendov.all_q_eq_one, `Sendov.eq_one_of_re_eq_one_of_norm_le_one, + `Sendov.eq_zero_of_sum_eq_zero, `Sendov.sum_le_card_mul, + `Sendov.card_mul_le_sum, `Sendov.sum_map_one_sub_re] do + if (env.find? retired).isSome then throwError "retired boundary helper remains: {retired}" + logInfo "BOUNDARY_RETIRED_ABSENT" diff --git a/tests/BoundaryContracts.lean b/tests/BoundaryContracts.lean new file mode 100644 index 0000000..a7ece07 --- /dev/null +++ b/tests/BoundaryContracts.lean @@ -0,0 +1,17 @@ +import Solution + +-- Exact elaborated public contracts: run against both frozen baseline objects +-- and freshly compiled candidate objects, then compare complete JSON records. +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + for name in #[`Sendov.eval_prod_at, `Sendov.eval_deriv_prod_at, + `Sendov.half_le_re_inv_one_sub, `Sendov.boundary_reciprocal, + `Sendov.rubinstein_one, `Sendov.sendov_boundary_one, + `Sendov.phelps_rodriguez, `Sendov.sendov, + `SendovConjecture.phelps_rodriguez, `SendovConjecture.sendov] do + let some info := env.find? name | throwError "missing contract {name}" + logInfo m!"BOUNDARY_CONTRACT {(Json.mkObj [ + ("name", toJson name.toString), + ("levels", toJson (repr info.levelParams).pretty), + ("type", toJson (repr info.type).pretty)]).compress}" diff --git a/tests/BoundaryProbe.lean b/tests/BoundaryProbe.lean new file mode 100644 index 0000000..c5c1246 --- /dev/null +++ b/tests/BoundaryProbe.lean @@ -0,0 +1,141 @@ +import Sendov.Boundary + +open Sendov + +-- This first consumer was compiled RED before the new declaration existed. +example (s : Multiset ℂ) + (hsecond : (s.map (fun v => ‖v‖ ^ 2)).sum ≤ (s.card : ℝ)) + (hfirst : (s.card : ℝ) ≤ s.sum.re) : ∀ v ∈ s, v = 1 := by + exact all_eq_one_of_sum_norm_sq_le_card hsecond hfirst + +-- The single average boundary interface is consumed, not re-proved here. +example {N : ℕ} {qs zs : Multiset ℂ} + (hqcard : qs.card = N) (hzcard : zs.card = N) + (hqsecond : (qs.map (fun v => ‖v‖ ^ 2)).sum ≤ (N : ℝ)) + (hz1 : ∀ w ∈ zs, ‖w‖ ≤ 1) (hzne : ∀ w ∈ zs, w ≠ 1) + (hBR : qs.sum = 2 * (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum) : + ∀ v ∈ qs, v = 1 := + all_q_eq_one_of_sum_norm_sq_le hqcard hzcard hqsecond hz1 hzne hBR + +example {N : ℕ} {qs zs : Multiset ℂ} + (hqcard : qs.card = N) (hzcard : zs.card = N) + (hq1 : ∀ v ∈ qs, ‖v‖ ≤ 1) (hz1 : ∀ w ∈ zs, ‖w‖ ≤ 1) + (hzne : ∀ w ∈ zs, w ≠ 1) + (hBR : qs.sum = 2 * (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum) : + ∀ v ∈ qs, v = 1 := by + -- Migrated pointwise consumer: form the second moment at the call site. + apply all_q_eq_one_of_sum_norm_sq_le hqcard hzcard ?_ hz1 hzne hBR + have h := Multiset.sum_le_card_nsmul (qs.map (fun v => ‖v‖ ^ 2)) (1 : ℝ) (by + intro r hr + obtain ⟨v, hv, rfl⟩ := Multiset.mem_map.1 hr + exact pow_le_one₀ (norm_nonneg v) (hq1 v hv)) + simpa only [Multiset.card_map, hqcard, nsmul_eq_mul, mul_one] using h + +-- Empty, singleton, and repeated points: no division by card or deduplication. +example : ∀ v ∈ (0 : Multiset ℂ), v = 1 := + all_eq_one_of_sum_norm_sq_le_card (by simp) (by simp) + +example : ∀ v ∈ ({1} : Multiset ℂ), v = 1 := + all_eq_one_of_sum_norm_sq_le_card (by simp) (by simp) + +example (k : ℕ) : ∀ v ∈ Multiset.replicate k (1 : ℂ), v = 1 := + all_eq_one_of_sum_norm_sq_le_card (by simp) (by simp) + +example : ∀ v ∈ ({1, 1} : Multiset ℂ), v = 1 := + all_q_eq_one_of_sum_norm_sq_le (N := 2) (zs := {-1, -1}) + (by simp) (by simp) (by norm_num) (by simp) (by norm_num) + (by norm_num) + +example : ∀ v ∈ (0 : Multiset ℂ), v = 1 := + all_q_eq_one_of_sum_norm_sq_le (N := 0) (zs := 0) + rfl rfl (by simp) (by simp) (by simp) (by simp) + +example (s : Multiset ℂ) : + (s.map (fun v => ‖v - 1‖ ^ 2)).sum = + (s.map (fun v => ‖v‖ ^ 2)).sum - 2 * s.sum.re + s.card := + sum_norm_sub_one_sq s + +example : (({Complex.I, Complex.I} : Multiset ℂ).map (fun v => ‖v - 1‖ ^ 2)).sum = 4 := by + rw [sum_norm_sub_one_sq] + norm_num + +-- The aggregate second-moment assumption alone is genuinely weaker than the pointwise one. +example : ∃ s : Multiset ℂ, + (s.map (fun v => ‖v‖ ^ 2)).sum ≤ (s.card : ℝ) ∧ ¬ (∀ v ∈ s, ‖v‖ ≤ 1) := by + refine ⟨{(6 / 5 : ℂ), 0}, ?_, ?_⟩ <;> norm_num + +-- Real counterexamples to dropping either generic hypothesis (no inconsistent assumptions). +example : ∃ s : Multiset ℂ, + (s.map (fun v => ‖v‖ ^ 2)).sum ≤ (s.card : ℝ) ∧ ¬ (∀ v ∈ s, v = 1) := by + exact ⟨{0}, by norm_num, by norm_num⟩ + +example : ∃ s : Multiset ℂ, + (s.card : ℝ) ≤ s.sum.re ∧ ¬ (∀ v ∈ s, v = 1) := by + exact ⟨{2}, by norm_num, by norm_num⟩ + +-- Even equality of the first moment does not control the imaginary part. +example : ∃ s : Multiset ℂ, + (s.card : ℝ) = s.sum.re ∧ ¬ (∀ v ∈ s, v = 1) := by + refine ⟨{1 + Complex.I}, by norm_num, ?_⟩ + simp only [Multiset.mem_singleton, forall_eq, add_eq_left, Complex.I_ne_zero, not_false_eq_true] + +-- Every retained premise of the boundary helper has a consistent omission witness. +-- Without second moment: q={2}, z={0}; all remaining boundary premises hold. +example : ∃ qs zs : Multiset ℂ, + qs.card = 1 ∧ zs.card = 1 ∧ + (∀ w ∈ zs, ‖w‖ ≤ 1) ∧ (∀ w ∈ zs, w ≠ 1) ∧ + qs.sum = 2 * (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum ∧ + ¬ (∀ v ∈ qs, v = 1) := by + refine ⟨{2}, {0}, ?_⟩ + norm_num + +-- Without z != 1, totalized inverse at zero makes BR hold with q=0. +example : ∃ qs zs : Multiset ℂ, + qs.card = 1 ∧ zs.card = 1 ∧ + (qs.map (fun v => ‖v‖ ^ 2)).sum ≤ (1 : ℝ) ∧ (∀ w ∈ zs, ‖w‖ ≤ 1) ∧ + qs.sum = 2 * (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum ∧ + ¬ (∀ v ∈ qs, v = 1) := by + refine ⟨{0}, {1}, ?_⟩ + norm_num + +-- Without the z disk bound: q=-1, z=3. +example : ∃ qs zs : Multiset ℂ, + qs.card = 1 ∧ zs.card = 1 ∧ + (qs.map (fun v => ‖v‖ ^ 2)).sum ≤ (1 : ℝ) ∧ (∀ w ∈ zs, w ≠ 1) ∧ + qs.sum = 2 * (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum ∧ + ¬ (∀ v ∈ qs, v = 1) := by + refine ⟨{-1}, {3}, ?_⟩ + norm_num + +-- Without BR: q=0, z=-1. +example : ∃ qs zs : Multiset ℂ, + qs.card = 1 ∧ zs.card = 1 ∧ + (qs.map (fun v => ‖v‖ ^ 2)).sum ≤ (1 : ℝ) ∧ + (∀ w ∈ zs, ‖w‖ ≤ 1) ∧ (∀ w ∈ zs, w ≠ 1) ∧ ¬ (∀ v ∈ qs, v = 1) := by + refine ⟨{0}, {-1}, ?_⟩ + norm_num + +-- Without matching z cardinality: N=1, q={0}, z=empty. +example : ∃ qs zs : Multiset ℂ, + qs.card = 1 ∧ (qs.map (fun v => ‖v‖ ^ 2)).sum ≤ (1 : ℝ) ∧ + (∀ w ∈ zs, ‖w‖ ≤ 1) ∧ (∀ w ∈ zs, w ≠ 1) ∧ + qs.sum = 2 * (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum ∧ + ¬ (∀ v ∈ qs, v = 1) := by + refine ⟨{0}, 0, ?_⟩ + norm_num + +-- Direct polynomial consumer of the rewired strict-or-extremal theorem. +example {n : ℕ} (hn : 2 ≤ n) {p : Polynomial ℂ} (hdeg : p.natDegree = n) + (hroots : ∀ w ∈ p.roots, ‖w‖ ≤ 1) (hp1 : p.eval 1 = 0) : + (∃ ζ : ℂ, (Polynomial.derivative p).eval ζ = 0 ∧ ‖ζ - 1‖ < 1) + ∨ p = Polynomial.C p.leadingCoeff * (Polynomial.X ^ n - 1) := + rubinstein_one hn hdeg hroots hp1 + +-- Without matching q cardinality: N=0, q={0}, z=empty. +example : ∃ qs zs : Multiset ℂ, + zs.card = 0 ∧ (qs.map (fun v => ‖v‖ ^ 2)).sum ≤ (0 : ℝ) ∧ + (∀ w ∈ zs, ‖w‖ ≤ 1) ∧ (∀ w ∈ zs, w ≠ 1) ∧ + qs.sum = 2 * (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum ∧ + ¬ (∀ v ∈ qs, v = 1) := by + refine ⟨{0}, 0, ?_⟩ + norm_num diff --git a/tests/BoundaryWiring.lean b/tests/BoundaryWiring.lean new file mode 100644 index 0000000..b808b27 --- /dev/null +++ b/tests/BoundaryWiring.lean @@ -0,0 +1,22 @@ +import Sendov.Boundary + +-- This environment contract must fail against v1 before retirement/rewiring. +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + if (env.find? `Sendov.all_q_eq_one).isSome then + throwError "retired pointwise wrapper remains: Sendov.all_q_eq_one" + logInfo "BOUNDARY_POINTWISE_RETIRED" + +-- Direct proof-value use, not merely a transitive path through the old adapter. +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + let some info := env.find? `Sendov.rubinstein_one | throwError "missing rubinstein_one" + let some value := info.value? (allowOpaque := true) | throwError "missing proof value" + let used := value.getUsedConstants + unless used.contains `Sendov.all_q_eq_one_of_sum_norm_sq_le do + throwError "rubinstein_one does not directly consume average boundary rigidity" + if used.contains `Sendov.all_q_eq_one then + throwError "rubinstein_one still directly consumes the retired wrapper" + logInfo "BOUNDARY_DIRECT_AVERAGE_CONSUMER" diff --git a/tests/CollinearAcceptance.lean b/tests/CollinearAcceptance.lean new file mode 100644 index 0000000..66faf47 --- /dev/null +++ b/tests/CollinearAcceptance.lean @@ -0,0 +1,82 @@ +import Sendov.Collinear.Moment + +open Polynomial +open scoped BigOperators +namespace Collinear + +-- Acceptance contract: arbitrary degree, with all algebraic multiplicities retained. +example (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree) : + p.derivative.Splits ∧ + p.derivative.roots = (p.roots - p.roots.dedup) + + (p.derivative.roots.toFinset \ p.roots.toFinset).val ∧ + (p.derivative.roots.toFinset \ p.roots.toFinset).card + 1 = + p.roots.toFinset.card := by + exact derivative_root_budget p hs hn + +-- Second vertical acceptance: every new critical point owns an adjacent gap, +-- and it is the unique critical point there. The multiplicity is also certified. +example (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree) + (z : ℝ) (hz : z ∈ p.derivative.roots) (hzp : z ∉ p.roots) : + p.derivative.rootMultiplicity z = 1 ∧ + ∃ a ∈ p.roots, ∃ b ∈ p.roots, + a < z ∧ z < b ∧ + (∀ x ∈ p.roots, x ∉ Set.Ioo a b) ∧ + (∀ w ∈ p.derivative.roots, w ∈ Set.Ioo a b → w = z) := by + exact new_critical_point_gap p hs hn z hz hzp + +-- Third vertical acceptance: not merely every new root has a gap, but every +-- adjacent gap has exactly one simple critical point. +example (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree) + (a : ℝ) (ha : a ∈ p.roots) (b : ℝ) (hb : b ∈ p.roots) + (hab : a < b) (hgap : ∀ x ∈ p.roots, x ∉ Set.Ioo a b) : + ∃! z : ℝ, z ∈ p.derivative.roots ∧ z ∈ Set.Ioo a b ∧ + p.derivative.rootMultiplicity z = 1 := by + exact adjacent_gap_unique p hs hn a ha b hb hab hgap + +-- Degree-uniform signed-side acceptance; repetitions are Multiset occurrences. +example (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree) + (a : ℝ) (ha : a ∈ p.roots) : + (((p.roots.filter (· < a)).map (fun x => 1 / (a - x))).sum ≤ + ((p.derivative.roots.filter (· < a)).map (fun y => 1 / (a - y))).sum) ∧ + (((p.roots.filter (a < ·)).map (fun x => 1 / (x - a))).sum ≤ + ((p.derivative.roots.filter (a < ·)).map (fun y => 1 / (y - a))).sum) := by + exact signed_reciprocal_domination p hs hn a ha + +#print axioms reciprocal_balance +#print axioms two_sided_mass + +example (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree) + (a : ℝ) (ha : a ∈ p.roots) (hd : p.derivative.eval a ≠ 0) : + ((p.derivative.roots.map (fun x => 1 / (a - x))).sum) = + 2 * ((p.roots.map (fun x => 1 / (a - x))).sum) := by + exact reciprocal_balance p hs hn a ha hd + +example (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree) + (a : ℝ) (ha : a ∈ p.roots) (hd : p.derivative.eval a ≠ 0) : + 2 * ((p.roots.filter (· < a)).map (fun x => 1 / (a - x))).sum ≤ + (p.derivative.roots.map (fun x => 1 / |a - x|)).sum ∧ + 2 * ((p.roots.filter (a < ·)).map (fun x => 1 / (x - a))).sum ≤ + (p.derivative.roots.map (fun x => 1 / |a - x|)).sum := by + exact two_sided_mass p hs hn a ha hd + +#print axioms diameter_reciprocal + +example (p : ℝ[X]) (hs : p.Splits) (hn : 2 ≤ p.natDegree) + (A B : ℝ) (hAB : A < B) (hroots : ∀ x ∈ p.roots, x ∈ Set.Icc A B) + (a : ℝ) (ha : a ∈ p.roots) : + p.derivative.eval a = 0 ∨ + (p.natDegree - 1 : ℝ) * (2 / (B - A)) ≤ + (p.derivative.roots.map (fun x => 1 / |a - x|)).sum := by + exact diameter_reciprocal p hs hn A B hAB hroots a ha + +#print axioms diameter_moment + +example (p : ℝ[X]) (hs : p.Splits) (hn : 2 ≤ p.natDegree) + (A B : ℝ) (hAB : A < B) (hroots : ∀ x ∈ p.roots, x ∈ Set.Icc A B) + (a : ℝ) (ha : a ∈ p.roots) (r : ℝ) (hr : 1 ≤ r) : + p.derivative.eval a = 0 ∨ + (p.natDegree - 1 : ℝ) * (2 / (B - A)) ^ r ≤ + (p.derivative.roots.map (fun x => |a - x| ^ (-r))).sum := by + exact diameter_moment p hs hn A B hAB hroots a ha r hr + +end Collinear diff --git a/tests/CollinearRound2Tests.lean b/tests/CollinearRound2Tests.lean new file mode 100644 index 0000000..4efdd95 --- /dev/null +++ b/tests/CollinearRound2Tests.lean @@ -0,0 +1,102 @@ +import Sendov.Collinear.Moment +import tests.CollinearTests + +open Polynomial +namespace Collinear.Round2Tests + +-- Simplicity only at the marked root; all other roots can have arbitrary multiplicity. +example (p : ℝ[X]) (hs : p.Splits) (hn : 2 ≤ p.natDegree) + (a : ℝ) (ha : a ∈ p.roots) (hm : p.rootMultiplicity a = 1) : + ((p.derivative.roots.filter (· < a)).map (fun x => 1 / (a - x))).sum - + ((p.derivative.roots.filter (a < ·)).map (fun x => 1 / (x - a))).sum = + 2 * (((p.roots.filter (· < a)).map (fun x => 1 / (a - x))).sum - + ((p.roots.filter (a < ·)).map (fun x => 1 / (x - a))).sum) := by + have hd : p.derivative.eval a ≠ 0 := by + intro h + have := (one_lt_rootMultiplicity_iff_isRoot (ne_zero_of_mem_roots ha)).mpr + ⟨(mem_roots (ne_zero_of_mem_roots ha)).mp ha, h⟩ + omega + have hb := reciprocal_balance p hs (by omega) a ha hd + rwa [(reciprocal_decomposition p.roots a).1, + (reciprocal_decomposition p.derivative.roots a).1] at hb + +-- Endpoint consumers do not require strict interior membership or positive side lengths. +example (p : ℝ[X]) (hs : p.Splits) (hn : 2 ≤ p.natDegree) + (A B : ℝ) (hAB : A < B) (hb : ∀ x ∈ p.roots, x ∈ Set.Icc A B) + (ha : A ∈ p.roots) (hd : p.derivative.eval A ≠ 0) (r : ℝ) (hr : 1 ≤ r) : + p.roots.filter (· < A) = 0 ∧ + (p.natDegree - 1 : ℝ) * (2 / (B - A)) ^ r ≤ + (p.derivative.roots.map (fun x => |A - x| ^ (-r))).sum := by + refine ⟨?_, (diameter_moment p hs hn A B hAB hb A ha r hr).resolve_left hd⟩ + exact Multiset.filter_eq_nil.mpr (fun x hx => not_lt.mpr (hb x hx).1) + +example (p : ℝ[X]) (hs : p.Splits) (hn : 2 ≤ p.natDegree) + (A B : ℝ) (hAB : A < B) (hb : ∀ x ∈ p.roots, x ∈ Set.Icc A B) + (ha : B ∈ p.roots) (hd : p.derivative.eval B ≠ 0) (r : ℝ) (hr : 1 ≤ r) : + p.roots.filter (B < ·) = 0 ∧ + (p.natDegree - 1 : ℝ) * (2 / (B - A)) ^ r ≤ + (p.derivative.roots.map (fun x => |B - x| ^ (-r))).sum := by + refine ⟨?_, (diameter_moment p hs hn A B hAB hb B ha r hr).resolve_left hd⟩ + exact Multiset.filter_eq_nil.mpr (fun x hx => not_lt.mpr (hb x hx).2) + +-- The singular branch is genuinely available for arbitrary multiple roots. +example (p : ℝ[X]) (hn : 2 ≤ p.natDegree) (a : ℝ) + (hm : 1 < p.rootMultiplicity a) : p.derivative.eval a = 0 := by + have hp : p ≠ 0 := by intro h; simp [h] at hn + exact ((one_lt_rootMultiplicity_iff_isRoot hp).mp hm).2 + +-- The finite branch never relies on a zero derivative-root distance. +example (p : ℝ[X]) (a : ℝ) (hd : p.derivative.eval a ≠ 0) + (w : ℝ) (hw : w ∈ p.derivative.roots) : 0 < |a - w| := by + apply abs_pos.mpr + intro h + have he := (mem_roots (ne_zero_of_mem_roots hw)).mp hw + exact hd ((sub_eq_zero.mp h) ▸ he) + +-- Exact occurrence count, not number of distinct roots and not n. +example (p : ℝ[X]) (hs : p.Splits) (hn : 2 ≤ p.natDegree) : + p.derivative.roots.card = p.natDegree - 1 := by + rw [← (derivative_root_budget p hs (by omega)).1.natDegree_eq_card_roots, + natDegree_derivative] + +-- Full final interface, including r=1, with no squarefree premise. +example (p : ℝ[X]) (hs : p.Splits) (hn : 2 ≤ p.natDegree) + (A B : ℝ) (hAB : A < B) (hb : ∀ x ∈ p.roots, x ∈ Set.Icc A B) + (a : ℝ) (ha : a ∈ p.roots) : + p.derivative.eval a = 0 ∨ + (p.natDegree - 1 : ℝ) * (2 / (B - A)) ≤ + (p.derivative.roots.map (fun x => |a - x| ^ (-1 : ℝ))).sum := by + simpa only [Real.rpow_one] using diameter_moment p hs hn A B hAB hb a ha 1 le_rfl + +-- Dropping the disjunction is false, even for a fully split quadratic in a +-- positive-length interval. This is a symbolic family, not numeric sampling. +example (a : ℝ) : + let p : ℝ[X] := (X - C a) ^ 2 + p.Splits ∧ p.natDegree = 2 ∧ a - 1 < a + 1 ∧ + (∀ x ∈ p.roots, x ∈ Set.Icc (a - 1) (a + 1)) ∧ + a ∈ p.roots ∧ + ¬((p.natDegree - 1 : ℝ) * (2 / ((a + 1) - (a - 1))) ≤ + (p.derivative.roots.map (fun x => 1 / |a - x|)).sum) := by + dsimp only + have hd : ((X - C a) ^ 2).derivative = C 2 * (X - C a) := by simp [derivative_pow] + have hroot : (((X - C a) ^ 2 : ℝ[X]).derivative).roots = {a} := by + rw [hd, roots_C_mul _ (by norm_num), roots_X_sub_C] + have hdeg : ((X - C a) ^ 2 : ℝ[X]).natDegree = 2 := by simp + refine ⟨(Splits.X_sub_C a).pow _, hdeg, by linarith, ?_, ?_, ?_⟩ + · intro x hx + have he : x = a := by + simpa [sub_eq_zero] using (mem_roots (pow_ne_zero 2 (X_sub_C_ne_zero a))).mp hx + subst x + constructor <;> linarith + · rw [mem_roots (pow_ne_zero 2 (X_sub_C_ne_zero a))] + simp + · rw [hroot, hdeg] + norm_num + +#print axioms Collinear.reciprocal_balance +#print axioms Collinear.reciprocal_decomposition +#print axioms Collinear.two_sided_mass +#print axioms Collinear.diameter_reciprocal +#print axioms Collinear.diameter_moment + +end Collinear.Round2Tests diff --git a/tests/CollinearTests.lean b/tests/CollinearTests.lean new file mode 100644 index 0000000..d3097e0 --- /dev/null +++ b/tests/CollinearTests.lean @@ -0,0 +1,46 @@ +import Sendov.Collinear.Mass + +open Polynomial + +namespace Collinear.Tests + +-- The public gate is not restricted to a fixed degree or squarefree polynomial. +example (p : ℝ[X]) (hs : p.Splits) (hn : 2 ≤ p.natDegree) : + p.derivative.Splits ∧ + p.derivative.roots = (p.roots - p.roots.dedup) + + (p.derivative.roots.toFinset \ p.roots.toFinset).val ∧ + (p.derivative.roots.toFinset \ p.roots.toFinset).card + 1 = + p.roots.toFinset.card := + Collinear.derivative_root_budget p hs (by omega) + +-- Nontrivial universal consumer: both signed sides, arbitrary distinguished root. +example (p : ℝ[X]) (hs : p.Splits) (hn : 2 ≤ p.natDegree) + (a : ℝ) (ha : a ∈ p.roots) : + (((p.roots.filter (· < a)).map (fun x => 1 / (a - x))).sum ≤ + ((p.derivative.roots.filter (· < a)).map (fun y => 1 / (a - y))).sum) ∧ + (((p.roots.filter (a < ·)).map (fun x => 1 / (x - a))).sum ≤ + ((p.derivative.roots.filter (a < ·)).map (fun y => 1 / (y - a))).sum) := + Collinear.signed_reciprocal_domination p hs (by omega) a ha + +-- Multiple-root branch must be routed away from finite reciprocal moments. +-- This is a general regression, not a fixed example with coincident roots. +example (p : ℝ[X]) (hn : 2 ≤ p.natDegree) (a : ℝ) + (hm : 1 < p.rootMultiplicity a) : p.derivative.IsRoot a := by + have hp : p ≠ 0 := by intro h; simp [h] at hn + exact ((one_lt_rootMultiplicity_iff_isRoot hp).mp hm).2 + +-- At a simple original root the derivative denominator really is nonzero. +example (p : ℝ[X]) (hn : 2 ≤ p.natDegree) (a : ℝ) + (hm : p.rootMultiplicity a = 1) : ¬p.derivative.IsRoot a := by + have hp : p ≠ 0 := by intro h; simp [h] at hn + intro hd + have ha : p.IsRoot a := (rootMultiplicity_pos hp).mp (by omega) + have := (one_lt_rootMultiplicity_iff_isRoot hp).mpr ⟨ha, hd⟩ + omega + +#print axioms Collinear.derivative_root_budget +#print axioms Collinear.new_critical_point_gap +#print axioms Collinear.adjacent_gap_unique +#print axioms Collinear.signed_reciprocal_domination + +end Collinear.Tests diff --git a/tests/FirstOriginAudit.lean b/tests/FirstOriginAudit.lean new file mode 100644 index 0000000..aa6d6cf --- /dev/null +++ b/tests/FirstOriginAudit.lean @@ -0,0 +1,62 @@ +import Sendov.Analytic.FirstOriginSmall + +/-! Metadata-only audit adapted from the frozen tests/NoFiniteRows.lean traversal. +Every reachable proof value is followed, including private and imported constants. +This module contributes no mathematical assumptions. -/ + +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + for (root, required) in #[ + (`Sendov.FirstOriginSmall.first_origin_polar_six_seven, + #[`Sendov.one_le_tri, `Sendov.one_le_integral_Ppolar, + `Sendov.FirstOriginSmall.polar_mean_gt_half_add_one, + `Sendov.FirstOriginSmall.direct_budget_five, + `Sendov.FirstOriginSmall.direct_budget_six, + `Sendov.FirstOriginSmall.five_halves_majorant, + `Sendov.FirstOriginSmall.fifth_sixth_majorant, + `Sendov.FirstOriginSmall.integral_quadratic_cube, + `Sendov.FirstOriginSmall.norm_Fprod_le]), + (`Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_factorization, + #[`Sendov.first_origin_identity, + `Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_first_origin])] do + let mut pending := [root] + let mut visited : Std.HashSet Name := {} + while !pending.isEmpty do + let name := pending.head! + pending := pending.tail! + unless visited.contains name do + visited := visited.insert name + let some info := env.find? name | throwError "missing closure declaration {name}" + if let some value := info.value? (allowOpaque := true) then + for used in value.getUsedConstants do + pending := used :: pending + for name in visited do + let text := name.toString + for forbidden in #["centroid_identity", "second_origin_identity", "origin_exact", + "alpha_le_seventeen", "OriginExact", "Jsum", "scalarObstruction", + "distillScalar", "Distillation", "polar_origin_incompatible", "Worigin", + "sorryAx", "native_decide"] do + if (text.splitOn forbidden).length > 1 then + throwError "forbidden proof-value dependency: {root} -> {name}" + if let some idx := env.getModuleIdxFor? name then + let owner := env.header.moduleNames[idx.toNat]!.toString + for forbidden in #["OriginExact", "Jsum", "Distillation", "LargeDegree", + "Reduction.Contradiction", "Reduction.Scalar", "Interior"] do + if (owner.splitOn forbidden).length > 1 then + throwError "forbidden proof-value owner: {root} -> {name} in {owner}" + for target in required do + unless visited.contains target do + throwError "missing positive proof consumption: {root} -> {target}" + logInfo m!"FIRST_ORIGIN_POSITIVE {root} -> {target}" + let axioms ← withEnv env <| Lean.collectAxioms root + unless axioms.all (#[``propext, ``Classical.choice, ``Quot.sound].contains) do + throwError "unexpected axioms for {root}: {axioms}" + logInfo m!"FIRST_ORIGIN_CLOSURE {root}: {visited.size}; axioms {axioms}" + logInfo m!"FIRST_ORIGIN_PROJECT_VALUES {root}: {(visited.toArray.filter fun n => + n.toString.startsWith "Sendov." || n.toString.startsWith "_private.Sendov.").map + Name.toString}" + +#print axioms Sendov.FirstOriginSmall.first_origin_polar_six_seven +#print axioms Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_first_origin +#print axioms Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_factorization diff --git a/tests/FirstOriginWiring.lean b/tests/FirstOriginWiring.lean new file mode 100644 index 0000000..2f4f4b9 --- /dev/null +++ b/tests/FirstOriginWiring.lean @@ -0,0 +1,32 @@ +import Solution + +-- The small-degree route must be a real proof consumer, not an unused import. +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + let some info := env.find? `Sendov.sendov_interior | throwError "missing interior theorem" + let some value := info.value? (allowOpaque := true) | throwError "missing interior proof" + for target in #[`Sendov.FirstOriginSmall.first_origin_polar_six_seven, + `Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_factorization] do + unless value.getUsedConstants.contains target do + throwError "interior does not directly consume {target}" + logInfo m!"FIRST_ORIGIN_INTERIOR_DIRECT {target}" + for root in #[`SendovConjecture.sendov, `SendovConjecture.phelps_rodriguez] do + let mut pending := [root] + let mut visited : Std.HashSet Name := {} + while !pending.isEmpty do + let name := pending.head! + pending := pending.tail! + unless visited.contains name do + visited := visited.insert name + let some ci := env.find? name | throwError "missing closure declaration {name}" + if let some v := ci.value? (allowOpaque := true) then + for used in v.getUsedConstants do pending := used :: pending + for target in #[`Sendov.FirstOriginSmall.first_origin_polar_six_seven, + `Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_factorization] do + unless visited.contains target do + throwError "missing final-root consumption {root} -> {target}" + logInfo m!"FIRST_ORIGIN_SOLUTION_VALUE {root} -> {target}" + if visited.contains `Collinear.diameter_moment then + throwError "real-collinear theorem unexpectedly consumed by complex Solution" + logInfo m!"COLLINEAR_NOT_IN_SOLUTION_VALUE {root}" diff --git a/tests/Localanalytic.lean b/tests/Localanalytic.lean index 1895ef8..a6abe43 100644 --- a/tests/Localanalytic.lean +++ b/tests/Localanalytic.lean @@ -32,11 +32,10 @@ example {w : ℂ} (hw : ‖w‖ ≤ 1) : abs_of_nonneg (sub_nonneg.2 (pow_le_one₀ (norm_nonneg w) hw))] example {v : ℂ} (hre : v.re = 1) (hv : ‖v‖ ≤ 1) : v = 1 := by - have him : v.im = 0 := by - have hsq := pow_le_one₀ (norm_nonneg v) hv (n := 2) - rw [Complex.sq_norm, Complex.normSq_apply] at hsq - nlinarith only [hsq, hre, sq_nonneg v.im] - apply Complex.ext <;> simp [hre, him] + -- Migrate the existing scalar boundary consumer to the refined moment API. + exact all_eq_one_of_sum_norm_sq_le_card (s := {v}) + (by simpa using pow_le_one₀ (norm_nonneg v) hv (n := 2)) + (by simp [hre]) v (by simp) example (g f : ℂ → ℂ) : ∀ (s : Multiset ℂ), (∀ v ∈ s, ‖g v‖ ≤ 1) → ‖sumEraseProdC s g f‖ ≤ sumEraseProdMap s (fun v => ‖f v‖) := by diff --git a/tests/PaperNearAlgebra.lean b/tests/PaperNearAlgebra.lean new file mode 100644 index 0000000..6bd1b4c --- /dev/null +++ b/tests/PaperNearAlgebra.lean @@ -0,0 +1,36 @@ +import Sendov.Analytic.PaperNearAlgebra + +open Sendov.PaperNear + +-- Generic API checks, including the paper's strictly positive input domain. +example (τ ℓ : ℝ) (hτ : 0 < τ) (hτ7 : τ ≤ 1 / 7) + (hℓ : 0 < ℓ) (hℓ2 : ℓ ≤ 2 / 5) : + (1 / 1000 : ℝ) < 1 / (1 + τ) - (f τ ℓ + g τ ℓ) - 1 / 80 := + rational_remainder_gt τ ℓ hτ.le hτ7 hℓ.le hℓ2 + +example (τ : ℝ) (hτ : 0 < τ) (hτ7 : τ ≤ 1 / 7) : + StrictMonoOn (fun ℓ => f τ ℓ + g τ ℓ) (Set.Icc 0 (2 / 5)) := + fg_strictMonoOn τ hτ.le hτ7 + +example : (1 / 1000 : ℝ) < G (1 / 7) := + G_gt_one_thousandth (1 / 7) (by norm_num) le_rfl + +example : (1 / 1000 : ℝ) < G 0 := + G_gt_one_thousandth 0 le_rfl (by norm_num) + +#print axioms Sendov.PaperNear.quartic_bernstein +#print axioms Sendov.PaperNear.quartic_lower +#print axioms Sendov.PaperNear.denominator_bounds +#print axioms Sendov.PaperNear.denominator_mul_G +#print axioms Sendov.PaperNear.G_lower +#print axioms Sendov.PaperNear.G_gt_one_thousandth +#print axioms Sendov.PaperNear.P_lower +#print axioms Sendov.PaperNear.Q_bounds +#print axioms Sendov.PaperNear.f_difference_lower +#print axioms Sendov.PaperNear.g_difference_lower +#print axioms Sendov.PaperNear.fg_difference_lower +#print axioms Sendov.PaperNear.fg_strictMonoOn +#print axioms Sendov.PaperNear.fg_le_endpoint +#print axioms Sendov.PaperNear.quartic_pos +#print axioms Sendov.PaperNear.G_eq_endpoint +#print axioms Sendov.PaperNear.rational_remainder_gt diff --git a/tests/PaperPolar.lean b/tests/PaperPolar.lean new file mode 100644 index 0000000..5b30c71 --- /dev/null +++ b/tests/PaperPolar.lean @@ -0,0 +1,46 @@ +import Sendov.Analytic.PaperPolar + +/-! Direct-import regression: the hypothesis is the literal raw integral, +not the exponential inequality or the rational endpoint bound. -/ +namespace Sendov.PaperPolar.Tests + +open MeasureTheory + +theorem literal_raw_consequences {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : 1 ≤ ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2)) : + (1 - 2 * a * x + a ^ 2 ≤ + ((m : ℝ) * (1 - a ^ 2) / 2) / (3 + (m : ℝ) * (1 - a ^ 2) / 2)) ∧ + (((m : ℝ) * (1 - a ^ 2) / 2) / (3 + (m : ℝ) * (1 - a ^ 2) / 2) ≤ + ((m : ℝ) * (1 - a)) / (3 + (m : ℝ) * (1 - a))) ∧ + a / 2 < x ∧ 0 < 1 - (1 - 2 * a * x + a ^ 2) := by + have he := endpoint_bounds hm ha0 ha1 hx0 hx1 hraw + have hg := geometry hm ha0 ha1 hx0 hx1 hraw + exact ⟨he.1, he.2, hg.1, hg.2⟩ + +theorem literal_integral_domination {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) : + (∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2)) ≤ + ∫ t in (0 : ℝ)..1, + Real.exp (((m : ℝ) * (1 - a ^ 2) / 2) * + (-1 + (2 - (1 - 2 * a * x + a ^ 2)) * t)) := by + simpa only [raw_kernel_eq, alpha, b] using + (integral_le_exp (by omega : 0 < m) (a := a) hx0 hx1) + +#print axioms Sendov.PaperPolar.rpow_le_exp +#print axioms Sendov.PaperPolar.integral_le_exp +#print axioms Sendov.PaperPolar.one_le_integral_exp +#print axioms Sendov.PaperPolar.b_le_alpha +#print axioms Sendov.PaperPolar.endpoint_bounds +#print axioms Sendov.PaperPolar.geometry +#print axioms Sendov.PaperPolar.c_lower_bound +#print axioms Sendov.PaperPolar.beta_le_chord +#print axioms Sendov.PaperPolar.beta_pos +#print axioms literal_raw_consequences +#print axioms literal_integral_domination + +end Sendov.PaperPolar.Tests diff --git a/tests/PaperTaylor.lean b/tests/PaperTaylor.lean new file mode 100644 index 0000000..6b68179 --- /dev/null +++ b/tests/PaperTaylor.lean @@ -0,0 +1,21 @@ +import Sendov.Analytic.PaperTaylor + +open MeasureTheory Sendov.PaperTaylor + +-- Check the exact requested inequality with a natural degree and expanded quadratic. +example (m : ℕ) (a x : ℝ) (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : x ≤ 1) (hc : 0 < 1 - (1 - 2 * a * x + a ^ 2)) : + let b := 1 - 2 * a * x + a ^ 2 + let c := 1 - b + let d := 2 * a * (1 - x) + b ^ ((m : ℝ) / 2) + (m : ℝ) * a ^ 2 * + (∫ t in (0 : ℝ)..1, t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) ≤ + 1 / ((m : ℝ) + 1) + b ^ ((m : ℝ) / 2) + d / (a * ((m : ℝ) - 2)) + + 12 * (m : ℝ) * a ^ 2 * d ^ 2 / (c ^ 4 * ((m : ℝ) + 1) * ((m : ℝ) + 3)) := by + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + simpa [beta] using finite_taylor_budget hm' ha ha1 hx (by simpa [beta] using hc) + +#print axioms Sendov.PaperTaylor.rpow_taylor_le +#print axioms Sendov.PaperTaylor.integral_beta_taylor +#print axioms Sendov.PaperTaylor.budget_le +#print axioms Sendov.PaperTaylor.finite_taylor_budget diff --git a/tests/integration-existing/parent-integrated01-receipts.json b/tests/integration-existing/parent-integrated01-receipts.json new file mode 100644 index 0000000..9fffa9b --- /dev/null +++ b/tests/integration-existing/parent-integrated01-receipts.json @@ -0,0 +1,1582 @@ +[ + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Sendov/Boundary.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Boundary.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Boundary.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Sendov/Boundary.json" + ], + "exit_code": 0, + "seconds": 4.637327351025306, + "module": "Sendov.Boundary", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Boundary", + "--tag", + "parent-integrated01" + ], + "source_sha256": "204d914bfeec14999b4b3b86d9070af17bc0f096462e52f28ff738b7e4f81705", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Boundary.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "Sendov.Boundary" + ], + "exit_code": 0, + "seconds": 4.592854195041582, + "module": "Sendov.Boundary", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Boundary", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "204d914bfeec14999b4b3b86d9070af17bc0f096462e52f28ff738b7e4f81705", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Boundary-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/BoundaryProbe.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/BoundaryProbe.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/BoundaryProbe.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/BoundaryProbe.json" + ], + "exit_code": 0, + "seconds": 4.16514456900768, + "module": "tests.BoundaryProbe", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.BoundaryProbe", + "--tag", + "parent-integrated01" + ], + "source_sha256": "9c1e09608d0a7d262aef189c78a2a7df0ecd018e99b56550c653ce1fa066e833", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.BoundaryProbe.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "tests.BoundaryProbe" + ], + "exit_code": 0, + "seconds": 4.423945305054076, + "module": "tests.BoundaryProbe", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.BoundaryProbe", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "9c1e09608d0a7d262aef189c78a2a7df0ecd018e99b56550c653ce1fa066e833", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.BoundaryProbe-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Sendov/Analytic/FirstOriginAlgebra.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Analytic/FirstOriginAlgebra.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Analytic/FirstOriginAlgebra.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Sendov/Analytic/FirstOriginAlgebra.json" + ], + "exit_code": 0, + "seconds": 6.099887011980172, + "module": "Sendov.Analytic.FirstOriginAlgebra", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Analytic.FirstOriginAlgebra", + "--tag", + "parent-integrated01" + ], + "source_sha256": "c18e2d5d0207cb386dca31949eef8b4240958e53a17c2819f653c40f7575d75b", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Analytic.FirstOriginAlgebra.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "Sendov.Analytic.FirstOriginAlgebra" + ], + "exit_code": 0, + "seconds": 5.073037578025833, + "module": "Sendov.Analytic.FirstOriginAlgebra", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Analytic.FirstOriginAlgebra", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "c18e2d5d0207cb386dca31949eef8b4240958e53a17c2819f653c40f7575d75b", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Analytic.FirstOriginAlgebra-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Sendov/Analytic/FirstOriginBounds.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Analytic/FirstOriginBounds.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Analytic/FirstOriginBounds.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Sendov/Analytic/FirstOriginBounds.json" + ], + "exit_code": 0, + "seconds": 4.867831470037345, + "module": "Sendov.Analytic.FirstOriginBounds", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Analytic.FirstOriginBounds", + "--tag", + "parent-integrated01" + ], + "source_sha256": "931ee26dd1b7458f24a337eb4177d5ff2a9211d5e67a89ffe96cde98c0baebf7", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Analytic.FirstOriginBounds.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "Sendov.Analytic.FirstOriginBounds" + ], + "exit_code": 0, + "seconds": 4.668646619014908, + "module": "Sendov.Analytic.FirstOriginBounds", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Analytic.FirstOriginBounds", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "931ee26dd1b7458f24a337eb4177d5ff2a9211d5e67a89ffe96cde98c0baebf7", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Analytic.FirstOriginBounds-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Sendov/Analytic/FirstOriginSmall.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Analytic/FirstOriginSmall.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Analytic/FirstOriginSmall.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Sendov/Analytic/FirstOriginSmall.json" + ], + "exit_code": 0, + "seconds": 5.272365131997503, + "module": "Sendov.Analytic.FirstOriginSmall", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Analytic.FirstOriginSmall", + "--tag", + "parent-integrated01" + ], + "source_sha256": "69cd012979351d0bb4b1e92acb1ea9d1d3ce5e3700250a6b05f80a6167578075", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Analytic.FirstOriginSmall.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "Sendov.Analytic.FirstOriginSmall" + ], + "exit_code": 0, + "seconds": 4.606699668976944, + "module": "Sendov.Analytic.FirstOriginSmall", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Analytic.FirstOriginSmall", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "69cd012979351d0bb4b1e92acb1ea9d1d3ce5e3700250a6b05f80a6167578075", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Analytic.FirstOriginSmall-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Sendov/Interior.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Interior.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Interior.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Sendov/Interior.json" + ], + "exit_code": 0, + "seconds": 3.60037838795688, + "module": "Sendov.Interior", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Interior", + "--tag", + "parent-integrated01" + ], + "source_sha256": "ccf36572e0dcbd817df29bf62f4245a3d274b466d958015e543ba3c6098ea345", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Interior.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "Sendov.Interior" + ], + "exit_code": 0, + "seconds": 4.495678294042591, + "module": "Sendov.Interior", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Interior", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "ccf36572e0dcbd817df29bf62f4245a3d274b466d958015e543ba3c6098ea345", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Interior-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Sendov/Conjecture.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Conjecture.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Conjecture.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Sendov/Conjecture.json" + ], + "exit_code": 0, + "seconds": 3.571729419985786, + "module": "Sendov.Conjecture", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Conjecture", + "--tag", + "parent-integrated01" + ], + "source_sha256": "260df47ae05aee1735d8f24451f53bf7d25f55c4ecf6eb5a583860cfde4d42c8", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Conjecture.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "Sendov.Conjecture" + ], + "exit_code": 0, + "seconds": 4.385996114986483, + "module": "Sendov.Conjecture", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Conjecture", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "260df47ae05aee1735d8f24451f53bf7d25f55c4ecf6eb5a583860cfde4d42c8", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Conjecture-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Solution.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Solution.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Solution.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Solution.json" + ], + "exit_code": 0, + "seconds": 2.819178839039523, + "module": "Solution", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Solution", + "--tag", + "parent-integrated01" + ], + "source_sha256": "bea235d32a6e29f078e72348671e40d7cdec39fc00667e00d5819b7cdfa30ce6", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Solution.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "Solution" + ], + "exit_code": 0, + "seconds": 4.591696546995081, + "module": "Solution", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Solution", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "bea235d32a6e29f078e72348671e40d7cdec39fc00667e00d5819b7cdfa30ce6", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Solution-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Sendov/Collinear/Gate.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Collinear/Gate.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Collinear/Gate.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Sendov/Collinear/Gate.json" + ], + "exit_code": 0, + "seconds": 2.9448194350115955, + "module": "Sendov.Collinear.Gate", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Collinear.Gate", + "--tag", + "parent-integrated01" + ], + "source_sha256": "f4e77cf2ad3b20ac4761da256a4ae2b8ecdea45fd091d212ecd3640ef364e63f", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Collinear.Gate.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "Sendov.Collinear.Gate" + ], + "exit_code": 0, + "seconds": 4.238855689007323, + "module": "Sendov.Collinear.Gate", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Collinear.Gate", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "f4e77cf2ad3b20ac4761da256a4ae2b8ecdea45fd091d212ecd3640ef364e63f", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Collinear.Gate-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Sendov/Collinear/Mass.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Collinear/Mass.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Collinear/Mass.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Sendov/Collinear/Mass.json" + ], + "exit_code": 0, + "seconds": 2.9159342409693636, + "module": "Sendov.Collinear.Mass", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Collinear.Mass", + "--tag", + "parent-integrated01" + ], + "source_sha256": "8bfc6af8f0be863382eb16b0020413ba604aa1ed7ed7bfe929cda45b154c21e8", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Collinear.Mass.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "Sendov.Collinear.Mass" + ], + "exit_code": 0, + "seconds": 4.127788801037241, + "module": "Sendov.Collinear.Mass", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Collinear.Mass", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "8bfc6af8f0be863382eb16b0020413ba604aa1ed7ed7bfe929cda45b154c21e8", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Collinear.Mass-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Sendov/Collinear/Balance.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Collinear/Balance.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Collinear/Balance.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Sendov/Collinear/Balance.json" + ], + "exit_code": 0, + "seconds": 2.8124370709992945, + "module": "Sendov.Collinear.Balance", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Collinear.Balance", + "--tag", + "parent-integrated01" + ], + "source_sha256": "5a552794875eedebc032168861169d2cdddc038baaaeea66745826d164211e99", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Collinear.Balance.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "Sendov.Collinear.Balance" + ], + "exit_code": 0, + "seconds": 4.413372524024453, + "module": "Sendov.Collinear.Balance", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Collinear.Balance", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "5a552794875eedebc032168861169d2cdddc038baaaeea66745826d164211e99", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Collinear.Balance-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Sendov/Collinear/Diameter.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Collinear/Diameter.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Collinear/Diameter.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Sendov/Collinear/Diameter.json" + ], + "exit_code": 0, + "seconds": 3.646286108996719, + "module": "Sendov.Collinear.Diameter", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Collinear.Diameter", + "--tag", + "parent-integrated01" + ], + "source_sha256": "aeb12605fe0b815917e96829c21d71c600c32522e10b759c32bb2065273de38f", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Collinear.Diameter.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "Sendov.Collinear.Diameter" + ], + "exit_code": 0, + "seconds": 4.167032600031234, + "module": "Sendov.Collinear.Diameter", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Collinear.Diameter", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "aeb12605fe0b815917e96829c21d71c600c32522e10b759c32bb2065273de38f", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Collinear.Diameter-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Sendov/Collinear/Moment.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Collinear/Moment.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Collinear/Moment.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Sendov/Collinear/Moment.json" + ], + "exit_code": 0, + "seconds": 3.034026184992399, + "module": "Sendov.Collinear.Moment", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Collinear.Moment", + "--tag", + "parent-integrated01" + ], + "source_sha256": "0f1612f32a7a37307d71627ab865ca8f5d93ba7345dd96e11c04269dd09b81d8", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Collinear.Moment.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "Sendov.Collinear.Moment" + ], + "exit_code": 0, + "seconds": 4.233618247963022, + "module": "Sendov.Collinear.Moment", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Collinear.Moment", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "0f1612f32a7a37307d71627ab865ca8f5d93ba7345dd96e11c04269dd09b81d8", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.Collinear.Moment-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/CollinearTests.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/CollinearTests.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/CollinearTests.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/CollinearTests.json" + ], + "exit_code": 0, + "seconds": 2.3706941939890385, + "module": "tests.CollinearTests", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.CollinearTests", + "--tag", + "parent-integrated01" + ], + "source_sha256": "d1061c6a54d5595f17f6e9db3718a4129fa877ff99fbd684f5461ae05020bdbe", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.CollinearTests.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "tests.CollinearTests" + ], + "exit_code": 0, + "seconds": 4.147964646981563, + "module": "tests.CollinearTests", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.CollinearTests", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "d1061c6a54d5595f17f6e9db3718a4129fa877ff99fbd684f5461ae05020bdbe", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.CollinearTests-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/CollinearRound2Tests.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/CollinearRound2Tests.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/CollinearRound2Tests.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/CollinearRound2Tests.json" + ], + "exit_code": 0, + "seconds": 3.408390793018043, + "module": "tests.CollinearRound2Tests", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.CollinearRound2Tests", + "--tag", + "parent-integrated01" + ], + "source_sha256": "b441c8c5bc06f2caf0862aa633edde72dc1dbe8593f7981267c5587dbfb5e0a6", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.CollinearRound2Tests.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "tests.CollinearRound2Tests" + ], + "exit_code": 0, + "seconds": 4.205070880008861, + "module": "tests.CollinearRound2Tests", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.CollinearRound2Tests", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "b441c8c5bc06f2caf0862aa633edde72dc1dbe8593f7981267c5587dbfb5e0a6", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.CollinearRound2Tests-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/CollinearAcceptance.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/CollinearAcceptance.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/CollinearAcceptance.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/CollinearAcceptance.json" + ], + "exit_code": 0, + "seconds": 2.7177694919519126, + "module": "tests.CollinearAcceptance", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.CollinearAcceptance", + "--tag", + "parent-integrated01" + ], + "source_sha256": "b90596c3c8371337ac6a67330c891ec1a6aaa090b04cf8fcaa6d4fff680138e5", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.CollinearAcceptance.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "tests.CollinearAcceptance" + ], + "exit_code": 0, + "seconds": 4.13122546102386, + "module": "tests.CollinearAcceptance", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.CollinearAcceptance", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "b90596c3c8371337ac6a67330c891ec1a6aaa090b04cf8fcaa6d4fff680138e5", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.CollinearAcceptance-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Sendov.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Sendov.json" + ], + "exit_code": 0, + "seconds": 2.677756931982003, + "module": "Sendov", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov", + "--tag", + "parent-integrated01" + ], + "source_sha256": "3f52679314022a1d2540c053568830f545d298c618a45649252068f71db8d1fc", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-Sendov.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/Localanalytic.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/Localanalytic.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/Localanalytic.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/Localanalytic.json" + ], + "exit_code": 0, + "seconds": 5.377116655989084, + "module": "tests.Localanalytic", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.Localanalytic", + "--tag", + "parent-integrated01" + ], + "source_sha256": "7ae5a379504b056acb1e927ef16870856de5464410daf70ba5eaea85fcc8c6e2", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.Localanalytic.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "tests.Localanalytic" + ], + "exit_code": 0, + "seconds": 4.367686050012708, + "module": "tests.Localanalytic", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.Localanalytic", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "7ae5a379504b056acb1e927ef16870856de5464410daf70ba5eaea85fcc8c6e2", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.Localanalytic-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/Localreduction.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/Localreduction.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/Localreduction.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/Localreduction.json" + ], + "exit_code": 0, + "seconds": 3.361300297023263, + "module": "tests.Localreduction", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.Localreduction", + "--tag", + "parent-integrated01" + ], + "source_sha256": "af193d148f7a7c00aecbf6fb58493507e5af9e16cd2adea20f625369f69e6d07", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.Localreduction.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "tests.Localreduction" + ], + "exit_code": 0, + "seconds": 4.514493878989015, + "module": "tests.Localreduction", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.Localreduction", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "af193d148f7a7c00aecbf6fb58493507e5af9e16cd2adea20f625369f69e6d07", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.Localreduction-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/LocalMiddleAlpha.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/LocalMiddleAlpha.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/LocalMiddleAlpha.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/LocalMiddleAlpha.json" + ], + "exit_code": 0, + "seconds": 13.137169818975963, + "module": "tests.LocalMiddleAlpha", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.LocalMiddleAlpha", + "--tag", + "parent-integrated01" + ], + "source_sha256": "0a8902c7e29f0b9fd495e38ca404faaf718ef8a3af6d82df09b3d7a09325393d", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.LocalMiddleAlpha.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "tests.LocalMiddleAlpha" + ], + "exit_code": 0, + "seconds": 4.614542532013729, + "module": "tests.LocalMiddleAlpha", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.LocalMiddleAlpha", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "0a8902c7e29f0b9fd495e38ca404faaf718ef8a3af6d82df09b3d7a09325393d", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.LocalMiddleAlpha-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/LocalPeakClosure.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/LocalPeakClosure.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/LocalPeakClosure.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/LocalPeakClosure.json" + ], + "exit_code": 0, + "seconds": 8.895943243987858, + "module": "tests.LocalPeakClosure", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.LocalPeakClosure", + "--tag", + "parent-integrated01" + ], + "source_sha256": "a8b635b06dc9d39254cc0622adbea9a882bf5eb08c7699ab68f692e9bd784545", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.LocalPeakClosure.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "tests.LocalPeakClosure" + ], + "exit_code": 0, + "seconds": 4.6097695890348405, + "module": "tests.LocalPeakClosure", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.LocalPeakClosure", + "--tag", + "parent-integrated01", + "--kernel" + ], + "source_sha256": "a8b635b06dc9d39254cc0622adbea9a882bf5eb08c7699ab68f692e9bd784545", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.LocalPeakClosure-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/scripts/axioms.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/scripts/axioms.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/scripts/axioms.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/scripts/axioms.json" + ], + "exit_code": 0, + "seconds": 3.1431618679780513, + "module": "scripts.axioms", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "scripts.axioms", + "--tag", + "parent-integrated01" + ], + "source_sha256": "e7ef1a7af7b8b729b0b13a4907ea7979961fda7e79cc6811abafcc29254da656", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-scripts.axioms.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/BoundaryWiring.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/BoundaryWiring.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/BoundaryWiring.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/BoundaryWiring.json" + ], + "exit_code": 0, + "seconds": 2.7240611810120754, + "module": "tests.BoundaryWiring", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.BoundaryWiring", + "--tag", + "parent-integrated01" + ], + "source_sha256": "53e968a6ec87036cd736ddbf676ea335a0ec901d48a70f4794f46afd262b3d8c", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.BoundaryWiring.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/BoundaryAudit.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/BoundaryAudit.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/BoundaryAudit.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/BoundaryAudit.json" + ], + "exit_code": 0, + "seconds": 15.690171732974704, + "module": "tests.BoundaryAudit", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.BoundaryAudit", + "--tag", + "parent-integrated01" + ], + "source_sha256": "12e81365f9aa32d22f0f6a51fb93297e8fd325f6bf7aad59f87ffe4ae82cf716", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.BoundaryAudit.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/BoundaryContracts.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/BoundaryContracts.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/BoundaryContracts.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/BoundaryContracts.json" + ], + "exit_code": 0, + "seconds": 2.7515192850260064, + "module": "tests.BoundaryContracts", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.BoundaryContracts", + "--tag", + "parent-integrated01" + ], + "source_sha256": "21dc87df827c30896a43e88baf149da2aeee9f7d11d7316c976ee4bfe0a61019", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.BoundaryContracts.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/FirstOriginAudit.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/FirstOriginAudit.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/FirstOriginAudit.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/FirstOriginAudit.json" + ], + "exit_code": 0, + "seconds": 24.132082740950864, + "module": "tests.FirstOriginAudit", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.FirstOriginAudit", + "--tag", + "parent-integrated01" + ], + "source_sha256": "eda08ee06deff1b01ccebfdcab74c70392c50694fcb84b0c37729cb5a7bacada", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.FirstOriginAudit.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/FirstOriginWiring.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/FirstOriginWiring.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/FirstOriginWiring.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/FirstOriginWiring.json" + ], + "exit_code": 0, + "seconds": 10.814981314004399, + "module": "tests.FirstOriginWiring", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.FirstOriginWiring", + "--tag", + "parent-integrated01" + ], + "source_sha256": "982bb1786d15875e8d3211e836ca3d7951cc082204fd5ca6a72908340ab87f13", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.FirstOriginWiring.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/NoFiniteRows.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/NoFiniteRows.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/NoFiniteRows.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/NoFiniteRows.json" + ], + "exit_code": 0, + "seconds": 27.442488458007574, + "module": "tests.NoFiniteRows", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.NoFiniteRows", + "--tag", + "parent-integrated01" + ], + "source_sha256": "355b9b39563f38d85a248b95249175893edd47a1e23ac41c9d9fb62a7599ff62", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/parent-integrated01-tests.NoFiniteRows.log", + "source_unchanged": true + } +] diff --git a/tests/verify_existing_integration.py b/tests/verify_existing_integration.py new file mode 100644 index 0000000..fb0b2da --- /dev/null +++ b/tests/verify_existing_integration.py @@ -0,0 +1,63 @@ +"""Serial exact-source replay in the private tree; no Lake build or cache writes.""" +import argparse +import hashlib +import json +from pathlib import Path +import subprocess +import sys + +TREE = Path(__file__).resolve().parents[1] +CHECK = Path('/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py') +PROOFS = [ + 'Sendov.Boundary', 'tests.BoundaryProbe', + 'Sendov.Analytic.FirstOriginAlgebra', 'Sendov.Analytic.FirstOriginBounds', + 'Sendov.Analytic.FirstOriginSmall', 'Sendov.Interior', 'Sendov.Conjecture', 'Solution', + 'Sendov.Collinear.Gate', 'Sendov.Collinear.Mass', 'Sendov.Collinear.Balance', + 'Sendov.Collinear.Diameter', 'Sendov.Collinear.Moment', + 'tests.CollinearTests', 'tests.CollinearRound2Tests', 'tests.CollinearAcceptance', + 'tests.Localanalytic', 'tests.Localreduction', 'tests.LocalMiddleAlpha', + 'tests.LocalPeakClosure', +] +AUDITS = ['scripts.axioms', 'tests.BoundaryWiring', 'tests.BoundaryAudit', + 'tests.BoundaryContracts', 'tests.FirstOriginAudit', 'tests.FirstOriginWiring', + 'tests.NoFiniteRows'] + + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--tag', required=True) + parser.add_argument('modules', nargs='*') + args = parser.parse_args() + logs = TREE / '.lake/paper/logs' + evidence = TREE / 'tests/integration-existing' + evidence.mkdir(parents=True, exist_ok=True) + receipts = [] + modules = args.modules or PROOFS[:16] + ['Sendov'] + PROOFS[16:] + AUDITS + for module in modules: + source = TREE / Path(*module.split('.')).with_suffix('.lean') + before = hashlib.sha256(source.read_bytes()).hexdigest() + if module in PROOFS: + assert not list(source.with_suffix('').glob('**/*.lean')), module + for kernel in ([False, True] if module in PROOFS else [False]): + stem = args.tag + '-' + module + ('-kernel' if kernel else '') + assert not (logs / (stem + '.json')).exists(), 'use a fresh tag' + command = [sys.executable, str(CHECK), str(TREE), module, '--tag', args.tag] + if kernel: + command.append('--kernel') + result = subprocess.run(command, cwd=TREE, text=True, capture_output=True) + record = json.loads((logs / (stem + '.json')).read_text()) + assert record['exit_code'] == result.returncode + record.update(wrapper_command=command, source_sha256=before, + log=str(logs / (stem + '.log'))) + record['source_unchanged'] = hashlib.sha256(source.read_bytes()).hexdigest() == before + receipts.append(record) + (evidence / (args.tag + '-receipts.json')).write_text(json.dumps(receipts, indent=2) + '\n') + print(f"{module} {'kernel' if kernel else 'compile'}: exit {result.returncode} ({record['seconds']:.2f}s)", flush=True) + if result.returncode or not record['source_unchanged']: + print(result.stdout + result.stderr) + raise SystemExit(result.returncode or 1) + print(f'PASS: {len(receipts)} gates; detailed actual commands in {evidence / (args.tag + "-receipts.json")}') + + +if __name__ == '__main__': + main() From b7f5d9690cf6053f80c265531104857cc677dc7a Mon Sep 17 00:00:00 2001 From: Methode Date: Mon, 14 Sep 2026 12:35:41 -0700 Subject: [PATCH 16/24] Prove uniform finite-ray algebra from a shared base comparison --- Sendov/Analytic/PaperRayAlgebra.lean | 72 ++++++++++++++++++++++++++++ tests/PaperRayAlgebra.lean | 15 ++++++ 2 files changed, 87 insertions(+) create mode 100644 Sendov/Analytic/PaperRayAlgebra.lean create mode 100644 tests/PaperRayAlgebra.lean diff --git a/Sendov/Analytic/PaperRayAlgebra.lean b/Sendov/Analytic/PaperRayAlgebra.lean new file mode 100644 index 0000000..87d3735 --- /dev/null +++ b/Sendov/Analytic/PaperRayAlgebra.lean @@ -0,0 +1,72 @@ +import Mathlib.Tactic.FieldSimp +import Mathlib.Tactic.Linarith +import Mathlib.Tactic.Positivity +import Mathlib.Tactic.Ring +import Mathlib.Data.Real.Basic + +/-! Uniform finite-ray comparisons from round5 §5.4. These compare the +analytic upper and lower bounds; the analytic bounds themselves are separate. +A single monotonic comparison carries each base inequality to every real m≥256. -/ +namespace Sendov.PaperRay + +/-- A generic base-to-ray comparison, preserving every parameter. -/ +theorem compare_from_base {M m C E K z : ℝ} (hM : 0 < M) (hm : M ≤ m) + (hE : 0 ≤ E) (hK : 0 ≤ K) (hC : 0 ≤ C - E / M) + (hbase : 1 + K / M + z < M / (M + 1) * (C - E / M)) : + 1 + K / m + z < m / (m + 1) * (C - E / m) := by + have hm0 : 0 < m := lt_of_lt_of_le hM hm + have hM1 : 0 < M + 1 := by linarith + have hm1 : 0 < m + 1 := by linarith + have hfrac : M / (M + 1) ≤ m / (m + 1) := by + apply (div_le_div_iff₀ hM1 hm1).2 + nlinarith + have hEdiv : E / m ≤ E / M := by + apply (div_le_div_iff₀ hm0 hM).2 + nlinarith + have hKdiv : K / m ≤ K / M := by + apply (div_le_div_iff₀ hm0 hM).2 + nlinarith + have hleft : 0 ≤ M / (M + 1) := by positivity + have hright : 0 ≤ m / (m + 1) := by positivity + have hprod : M / (M + 1) * (C - E / M) ≤ m / (m + 1) * (C - E / m) := by + nlinarith [mul_nonneg (sub_nonneg.mpr hfrac) hC, + mul_nonneg hright (sub_nonneg.mpr hEdiv)] + linarith + +/-- The ray 1/5 ≤ lambda ≤ 1. -/ +theorem ray_one {m : ℝ} (hm : 256 ≤ m) : + 1 + 18 / m < m / (m + 1) * (1 + (24 / 49 - 8 / m) / 5) := by + have h := compare_from_base (M := 256) (C := 1 + 24 / 245) + (E := 8 / 5) (K := 18) (z := 0) (by norm_num) hm + (by norm_num) (by norm_num) (by norm_num) (by norm_num) + convert h using 1 <;> ring + +/-- The ray 1 ≤ lambda ≤ 5. -/ +theorem ray_two {m : ℝ} (hm : 256 ≤ m) : + 1 + 33 / m < m / (m + 1) * (1 + 6 / 25 - 24 / m) := by + simpa using compare_from_base (M := 256) (C := 1 + 6 / 25) + (E := 24) (K := 33) (z := 0) (by norm_num) hm + (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +/-- The ray 5 ≤ lambda ≤ 10. -/ +theorem ray_three {m : ℝ} (hm : 256 ≤ m) : + 1 + 33 / m < m / (m + 1) * (6 * (7 / 12) ^ 2) := by + simpa using compare_from_base (M := 256) (C := 6 * (7 / 12) ^ 2) + (E := 0) (K := 33) (z := 0) (by norm_num) hm + (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +/-- The ray 10 ≤ lambda ≤ 25. -/ +theorem ray_four {m : ℝ} (hm : 256 ≤ m) : + 1 + 51 / m + 1 / 4 < m / (m + 1) * (11 * (231 / 512) ^ 2) := by + simpa using compare_from_base (M := 256) (C := 11 * (231 / 512) ^ 2) + (E := 0) (K := 51) (z := 1 / 4) (by norm_num) hm + (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +/-- The ray 25 ≤ lambda ≤ 49. -/ +theorem ray_five {m : ℝ} (hm : 256 ≤ m) : + 1 + 62 / m + 2 < m / (m + 1) * (26 * (207 / 512) ^ 2) := by + simpa using compare_from_base (M := 256) (C := 26 * (207 / 512) ^ 2) + (E := 0) (K := 62) (z := 2) (by norm_num) hm + (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +end Sendov.PaperRay diff --git a/tests/PaperRayAlgebra.lean b/tests/PaperRayAlgebra.lean new file mode 100644 index 0000000..ae66a8c --- /dev/null +++ b/tests/PaperRayAlgebra.lean @@ -0,0 +1,15 @@ +import Sendov.Analytic.PaperRayAlgebra + +open Sendov.PaperRay + +example {m : ℝ} (hm : 256 ≤ m) : + 1 + 18 / m < m / (m + 1) * (1 + (24 / 49 - 8 / m) / 5) := ray_one hm +example {m : ℝ} (hm : 256 ≤ m) : + 1 + 62 / m + 2 < m / (m + 1) * (26 * (207 / 512) ^ 2) := ray_five hm + +#print axioms compare_from_base +#print axioms ray_one +#print axioms ray_two +#print axioms ray_three +#print axioms ray_four +#print axioms ray_five From 120dd03161ab7311bd49a409156bb425cdce60d8 Mon Sep 17 00:00:00 2001 From: Methode Date: Mon, 14 Sep 2026 12:47:06 -0700 Subject: [PATCH 17/24] Close raw-polar near-endpoint D and formalize integral and centered tools --- Sendov/Analytic/PaperCentered.lean | 362 +++++++++++++++++++ Sendov/Analytic/PaperCoefficient.lean | 261 ++++++++++++++ Sendov/Analytic/PaperLaplace.lean | 292 +++++++++++++++ Sendov/Analytic/PaperNear.lean | 191 ++++++++++ Sendov/Analytic/PaperSecant.lean | 390 +++++++++++++++++++++ Sendov/Analytic/PaperTwoEnd.lean | 380 ++++++++++++++++++++ docs/paper-formalization/checkpoint2.json | 11 + docs/paper-formalization/round2-files.json | 14 + tests/PaperCentered.lean | 83 +++++ tests/PaperCoefficientTests.lean | 80 +++++ tests/PaperLaplace.lean | 78 +++++ tests/PaperNear.lean | 41 +++ tests/PaperSecantTests.lean | 109 ++++++ tests/PaperTwoEndTests.lean | 89 +++++ 14 files changed, 2381 insertions(+) create mode 100644 Sendov/Analytic/PaperCentered.lean create mode 100644 Sendov/Analytic/PaperCoefficient.lean create mode 100644 Sendov/Analytic/PaperLaplace.lean create mode 100644 Sendov/Analytic/PaperNear.lean create mode 100644 Sendov/Analytic/PaperSecant.lean create mode 100644 Sendov/Analytic/PaperTwoEnd.lean create mode 100644 docs/paper-formalization/checkpoint2.json create mode 100644 docs/paper-formalization/round2-files.json create mode 100644 tests/PaperCentered.lean create mode 100644 tests/PaperCoefficientTests.lean create mode 100644 tests/PaperLaplace.lean create mode 100644 tests/PaperNear.lean create mode 100644 tests/PaperSecantTests.lean create mode 100644 tests/PaperTwoEndTests.lean diff --git a/Sendov/Analytic/PaperCentered.lean b/Sendov/Analytic/PaperCentered.lean new file mode 100644 index 0000000..75c413b --- /dev/null +++ b/Sendov/Analytic/PaperCentered.lean @@ -0,0 +1,362 @@ +import Sendov.Counterexample.Identities +import Mathlib.RingTheory.Polynomial.Vieta + +/-! # Finite centered expansion +All endpoints are finite complex polynomials; no reality or positivity of the mean is used. +-/ +noncomputable section +open scoped BigOperators +open Polynomial +namespace Sendov.PaperCentered + +/-- The finite endpoint sum in the paper. -/ +def B (m k : ℕ) (z : ℂ) : ℂ := + ∑ j ∈ Finset.range (k + 1), (m + 1).choose j * z ^ j * (1 - z) ^ (m + 1 - j) + +/-- The complementary endpoint, retained at every degree. -/ +def H (m k : ℕ) (z : ℂ) : ℂ := 1 - B m k z + +@[simp] theorem B_zero (m : ℕ) (z : ℂ) : B m 0 z = (1 - z) ^ (m + 1) := by + simp [B] + +theorem H_succ (m k : ℕ) (z : ℂ) : + H m (k + 1) z = H m k z - + (m + 1).choose (k + 1) * z ^ (k + 1) * (1 - z) ^ (m - k) := by + simp only [H, B, Finset.sum_range_succ] + rw [show m + 1 - (k + 1) = m - k by omega] + ring + +/-- Homogeneous Vieta identity, including repeated values and zero scaling. -/ +theorem prod_affine (r : Multiset ℂ) (x y : ℂ) : + (r.map (fun v => x + y * v)).prod = + ∑ k ∈ Finset.range (r.card + 1), y ^ k * r.esymm k * x ^ (r.card - k) := by + have h := congrArg (Polynomial.eval x) + (Multiset.prod_X_add_C_eq_sum_esymm (r.map (fun v => y * v))) + have hs (k : ℕ) : (r.map (fun v => y * v)).esymm k = y ^ k * r.esymm k := by + exact (Multiset.pow_smul_esymm y k r).symm + simpa only [eval_multiset_prod, Multiset.map_map, Function.comp_def, eval_add, + eval_X, eval_C, eval_finsetSum, eval_mul, eval_pow, Multiset.card_map, hs] using h + +/-- The actual centered product expansion, before integration. -/ +theorem centered_product (q : Multiset ℂ) (a μ : ℂ) (t : ℝ) : + (q.map (fun v => 1 - a * t * v)).prod = + ∑ k ∈ Finset.range (q.card + 1), (-a) ^ k * + (q.map (fun v => v - μ)).esymm k * (t : ℂ) ^ k * + (1 - a * μ * t) ^ (q.card - k) := by + have h := prod_affine (q.map (fun v => v - μ)) (1 - a * μ * t) (-a * t) + simp only [Multiset.map_map, Function.comp_def, Multiset.card_map, mul_pow] at h + convert h using 1 + · congr 2; ext v; ring + · apply Finset.sum_congr rfl + intro k hk + ring + +@[simp] theorem esymm_zero (r : Multiset ℂ) : r.esymm 0 = 1 := by + simp [Multiset.esymm] + +@[simp] theorem esymm_one (r : Multiset ℂ) : r.esymm 1 = r.sum := by + simp [Multiset.esymm, Multiset.powersetCard_one] + +/-- Elementary symmetric recursion, without distinctness assumptions. -/ +theorem esymm_cons (v : ℂ) (r : Multiset ℂ) (k : ℕ) : + (v ::ₘ r).esymm (k + 1) = r.esymm (k + 1) + v * r.esymm k := by + simp only [Multiset.esymm, Multiset.powersetCard_cons, Multiset.map_add, + Multiset.sum_add, Multiset.map_map, Function.comp_def, Multiset.prod_cons] + rw [Multiset.sum_map_mul_left] + +/-- Degree two Newton identity proved directly from the multiset recursion. -/ +theorem two_mul_esymm_two (r : Multiset ℂ) : + 2 * r.esymm 2 = r.sum ^ 2 - (r.map (fun v => v ^ 2)).sum := by + induction r using Multiset.induction_on with + | empty => simp [Multiset.esymm, show 2 = 1 + 1 from rfl, Multiset.powersetCard_zero_right] + | cons v r ih => + rw [show 2 = 1 + 1 from rfl, esymm_cons, esymm_one] + simp only [Multiset.sum_cons, Multiset.map_cons] + linear_combination ih + +/-- Centering really kills the linear coefficient. -/ +theorem centered_sum (q : Multiset ℂ) (μ : ℂ) (hμ : q.sum = q.card * μ) : + (q.map (fun v => v - μ)).sum = 0 := by + have hc : (q.map (fun _ => μ)).sum = (q.card : ℂ) * μ := by + induction q using Multiset.induction_on with + | empty => simp + | cons v q ih => simp [Nat.cast_add, add_mul]; ring + simp only [Multiset.sum_map_sub, Multiset.map_id', hc, hμ, sub_self] + +/-- Differentiating the finite endpoint sum telescopes exactly. -/ +theorem hasDerivAt_H (m k : ℕ) (hk : k ≤ m) (z : ℂ) : + HasDerivAt (H m k) ((m + 1) * (m.choose k : ℂ) * z ^ k * (1 - z) ^ (m - k)) z := by + induction k with + | zero => + have he : H m 0 = fun w => 1 - (1 - w) ^ (m + 1) := by + funext w; simp [H] + rw [he] + simpa using + (((hasDerivAt_id z).const_sub 1).pow (m + 1)).const_sub 1 + | succ k ih => + have hk' : k ≤ m := by omega + have hmk : m - k = (m - (k + 1)) + 1 := by omega + have hc₁ : ((m + 1 : ℕ) : ℂ) * m.choose k = + ((m + 1).choose (k + 1) : ℂ) * (k + 1) := by + exact_mod_cast Nat.add_one_mul_choose_eq m k + have hc₂ : (m.choose (k + 1) : ℂ) * (m + 1) = + ((m + 1).choose (k + 1) : ℂ) * (m - k) := by + have h := Nat.choose_mul_succ_eq m (k + 1) + rw [show m + 1 - (k + 1) = m - k by omega] at h + exact_mod_cast h + have hd := (ih hk').sub + ((((hasDerivAt_id z).pow (k + 1)).const_mul + ((m + 1).choose (k + 1) : ℂ)).mul + (((hasDerivAt_id z).const_sub 1).pow (m - k))) + have he : H m (k + 1) = fun w => H m k w - + (m + 1).choose (k + 1) * w ^ (k + 1) * (1 - w) ^ (m - k) := + funext (H_succ m k) + rw [he] + convert hd using 1 <;> try rfl + simp only [Pi.pow_apply, id_eq, Nat.cast_add, Nat.cast_one, + Nat.add_sub_cancel, mul_one, mul_neg, hmk, pow_succ] + have hc₃ : ((m - (k + 1) : ℕ) : ℂ) + 1 = (m : ℂ) - k := by + simpa only [Nat.cast_add, Nat.cast_one, Nat.cast_sub hk'] using + congrArg (Nat.cast : ℕ → ℂ) hmk.symm + rw [hc₃] + push_cast at hc₁ + linear_combination -(z ^ k * (1 - z) ^ (m - (k + 1)) * (1 - z)) * hc₁ + + (z ^ k * z * (1 - z) ^ (m - (k + 1))) * hc₂ + +@[simp] theorem H_at_zero (m k : ℕ) : H m k 0 = 0 := by + rw [H, B, Finset.sum_eq_single 0] + · simp + · intro j hj hj0 + simp [zero_pow hj0] + · simp + +/-- Integer incomplete-beta identity, division-free and valid for every complex z, +including z=0 and the top index k=m. -/ +theorem finite_beta (m k : ℕ) (hk : k ≤ m) (z : ℂ) : + ((m + 1) * (m.choose k : ℂ) * z ^ (k + 1)) * + (∫ t in (0 : ℝ)..1, (t : ℂ) ^ k * (1 - z * t) ^ (m - k)) = H m k z := by + have hd (t : ℝ) : HasDerivAt (fun t : ℝ => H m k (z * t)) + (((m + 1) * (m.choose k : ℂ) * z ^ (k + 1)) * + ((t : ℂ) ^ k * (1 - z * t) ^ (m - k))) t := by + have ht : HasDerivAt (fun t : ℝ => z * (t : ℂ)) z t := by + simpa using (Complex.ofRealCLM.hasDerivAt (x := t)).const_mul z + convert (hasDerivAt_H m k hk (z * t)).scomp t ht using 1 <;> try rfl + simp only [smul_eq_mul, mul_pow, pow_succ] + ring + have hi : IntervalIntegrable (fun t : ℝ => + ((m + 1) * (m.choose k : ℂ) * z ^ (k + 1)) * + ((t : ℂ) ^ k * (1 - z * t) ^ (m - k))) MeasureTheory.volume 0 1 := by + apply Continuous.intervalIntegrable + fun_prop + have h := intervalIntegral.integral_eq_sub_of_hasDerivAt (fun t _ => hd t) hi + simpa [intervalIntegral.integral_const_mul] using h + +/-- Normalized elementary coefficient (the sign is part of the coefficient). -/ +def coeff (r : Multiset ℂ) (μ : ℂ) (k : ℕ) : ℂ := + (-1) ^ k * r.esymm k / ((r.card.choose k : ℂ) * μ ^ k) + +/-- Exact finite centered beta expansion. Centering need not equal the mean for this +identity; the mean condition is used only to remove degree one below. -/ +theorem centered_integral (q : Multiset ℂ) (a μ : ℂ) (hμ : μ ≠ 0) : + (q.card + 1) * (a * μ) * + (∫ t in (0 : ℝ)..1, (q.map (fun v => 1 - a * t * v)).prod) = + ∑ k ∈ Finset.range (q.card + 1), + coeff (q.map (fun v => v - μ)) μ k * H q.card k (a * μ) := by + let r := q.map (fun v => v - μ) + have he : (fun t : ℝ => (q.map (fun v => 1 - a * t * v)).prod) = + fun t : ℝ => ∑ k ∈ Finset.range (q.card + 1), + ((-a) ^ k * r.esymm k) * ((t : ℂ) ^ k * (1 - a * μ * t) ^ (q.card - k)) := by + funext t + rw [centered_product q a μ t] + apply Finset.sum_congr rfl + intro k hk + dsimp [r] + ring + rw [he, intervalIntegral.integral_finsetSum] + · rw [Finset.mul_sum] + apply Finset.sum_congr rfl + intro k hk + have hk' : k ≤ q.card := Nat.lt_succ_iff.mp (Finset.mem_range.mp hk) + have hc : (q.card.choose k : ℂ) ≠ 0 := by exact_mod_cast Nat.choose_ne_zero hk' + rw [intervalIntegral.integral_const_mul, ← finite_beta q.card k hk' (a * μ)] + dsimp [coeff, r] + rw [Multiset.card_map] + rw [show -a = (-1 : ℂ) * a by ring] + simp only [mul_pow, pow_succ] + field_simp + · intro k hk + apply Continuous.intervalIntegrable + fun_prop + +/-- The top endpoint is not dropped: H at k=m is exactly z^(m+1). -/ +theorem H_top (m : ℕ) (z : ℂ) : H m m z = z ^ (m + 1) := by + have hs := add_pow z (1 - z) (m + 1) + rw [Finset.sum_range_succ] at hs + simp only [Nat.choose_self, Nat.sub_self, pow_zero, Nat.cast_one, mul_one] at hs + have hb : B m m z = ∑ i ∈ Finset.range (m + 1), + z ^ i * (1 - z) ^ (m + 1 - i) * ((m + 1).choose i : ℂ) := by + apply Finset.sum_congr rfl + intro i hi + ring + rw [H, hb] + have he : z + (1 - z) = 1 := by ring + rw [he, one_pow] at hs + linear_combination hs + +/-- The centered second moment, without complex conjugation. -/ +def kappa (r : Multiset ℂ) : ℂ := (r.map (fun v => v ^ 2)).sum / r.card + +/-- The exact second-order correction. -/ +def correction (r : Multiset ℂ) (μ : ℂ) : ℂ := + kappa r / (((r.card : ℂ) - 1) * μ ^ 2) + +@[simp] theorem coeff_zero (r : Multiset ℂ) (μ : ℂ) : coeff r μ 0 = 1 := by + simp [coeff] + +theorem coeff_one (r : Multiset ℂ) (μ : ℂ) (hr : r.sum = 0) : coeff r μ 1 = 0 := by + simp [coeff, hr] + +/-- The second-order coefficient is computed, not postulated. -/ +theorem coeff_two (r : Multiset ℂ) (μ : ℂ) (hm : 2 ≤ r.card) + (hr : r.sum = 0) (hμ : μ ≠ 0) : coeff r μ 2 = -correction r μ := by + have hc : (r.card.choose 2 : ℂ) ≠ 0 := by exact_mod_cast Nat.choose_ne_zero hm + have hm₀ : (r.card : ℂ) ≠ 0 := by exact_mod_cast (by omega : r.card ≠ 0) + have hm₁ : (r.card : ℂ) - 1 ≠ 0 := by + have h : (r.card : ℂ) ≠ 1 := by exact_mod_cast (by omega : r.card ≠ 1) + exact sub_ne_zero.mpr h + have hc₂ : 2 * (r.card.choose 2 : ℂ) = (r.card : ℂ) * ((r.card : ℂ) - 1) := by + have h₂ := Nat.add_one_mul_choose_eq (r.card - 1) 1 + rw [show r.card - 1 + 1 = r.card by omega] at h₂ + norm_num only [Nat.choose_one_right, Nat.reduceAdd] at h₂ + have h₃ : (r.card : ℂ) * ((r.card : ℂ) - 1) = (r.card.choose 2 : ℂ) * 2 := by + simpa only [Nat.cast_mul, Nat.cast_sub (by omega : 1 ≤ r.card), Nat.cast_one, + Nat.cast_ofNat] using congrArg (Nat.cast : ℕ → ℂ) h₂ + linear_combination h₃.symm + have he := two_mul_esymm_two r + rw [hr, zero_pow (by decide : 2 ≠ 0), zero_sub] at he + dsimp [coeff, correction, kappa] + norm_num + field_simp + linear_combination (r.card.choose 2 : ℂ) * he - r.esymm 2 * hc₂ + +/-- Every degree from 3 through m is retained. -/ +def tail (r : Multiset ℂ) (μ z : ℂ) : ℂ := + ∑ k ∈ Finset.Ico 3 (r.card + 1), coeff r μ k * H r.card k z + +/-- Finite epsilon, with both low-degree endpoint corrections and all higher H terms. -/ +def epsilon (r : Multiset ℂ) (μ z : ℂ) : ℂ := + -(1 - z) ^ (r.card + 1) + correction r μ * B r.card 2 z + tail r μ z + +/-- The paper's exact second-order identity, for any complex nonzero mean. -/ +theorem second_order (q : Multiset ℂ) (a μ : ℂ) (hm : 2 ≤ q.card) + (hmean : q.sum = q.card * μ) (hμ : μ ≠ 0) : + (q.card + 1) * (a * μ) * + (∫ t in (0 : ℝ)..1, (q.map (fun v => 1 - a * t * v)).prod) = + 1 - correction (q.map (fun v => v - μ)) μ + + epsilon (q.map (fun v => v - μ)) μ (a * μ) := by + let r := q.map (fun v => v - μ) + have hrc : r.card = q.card := Multiset.card_map _ _ + have hrs : r.sum = 0 := centered_sum q μ hmean + rw [centered_integral q a μ hμ] + have hs := Finset.sum_range_add_sum_Ico + (fun k => coeff r μ k * H q.card k (a * μ)) (by omega : 3 ≤ q.card + 1) + rw [← hs] + rw [show 3 = 2 + 1 from rfl, Finset.sum_range_succ, + show 2 = 1 + 1 from rfl, Finset.sum_range_succ, Finset.sum_range_succ] + simp only [Finset.sum_range_zero, coeff_zero, one_mul, coeff_one r μ hrs, zero_mul, + zero_add, add_zero] + rw [coeff_two r μ (by omega) hrs hμ] + dsimp [epsilon, tail] + rw [hrc] + simp only [H, B_zero] + ring + +/-- The mean squared norm of the centered family. -/ +def variance (r : Multiset ℂ) : ℝ := (r.map (fun v => ‖v‖ ^ 2)).sum / r.card + +/-- The paper's Γ, in real arithmetic. -/ +def Gamma (r : Multiset ℂ) (μ : ℂ) : ℝ := + variance r / (((r.card : ℝ) - 1) * ‖μ‖ ^ 2) + +theorem norm_kappa_le_variance (r : Multiset ℂ) : ‖kappa r‖ ≤ variance r := by + have hs : ‖(r.map (fun v => v ^ 2)).sum‖ ≤ (r.map (fun v => ‖v‖ ^ 2)).sum := by + induction r using Multiset.induction_on with + | empty => simp + | cons v r ih => + simp only [Multiset.map_cons, Multiset.sum_cons] + exact (norm_add_le _ _).trans (by simpa [norm_pow] using add_le_add_left ih (‖v ^ 2‖)) + simpa [kappa, variance, norm_div] using + div_le_div_of_nonneg_right hs (Nat.cast_nonneg r.card) + +theorem norm_correction_le_Gamma (r : Multiset ℂ) (μ : ℂ) (hm : 2 ≤ r.card) : + ‖correction r μ‖ ≤ Gamma r μ := by + have hmR : (2 : ℝ) ≤ r.card := by exact_mod_cast hm + have he : (r.card : ℂ) - 1 = (((r.card : ℝ) - 1 : ℝ) : ℂ) := by push_cast; rfl + have hn : ‖(r.card : ℂ) - 1‖ = (r.card : ℝ) - 1 := by + rw [he, Complex.norm_real, Real.norm_eq_abs, abs_of_nonneg (by linarith)] + simp only [correction, Gamma, norm_div, norm_mul, norm_pow, hn] + exact div_le_div_of_nonneg_right (norm_kappa_le_variance r) + (mul_nonneg (by linarith) (sq_nonneg _)) + +/-- The actual coefficient modulus, ready for an independent Fourier upper bound. -/ +theorem norm_coeff (r : Multiset ℂ) (μ : ℂ) (k : ℕ) : + ‖coeff r μ k‖ = ‖r.esymm k‖ / ((r.card.choose k : ℝ) * ‖μ‖ ^ k) := by + simp [coeff, norm_pow] + +/-- The finite triangle budget, using the actual elementary symmetric coefficients. +No endpoint H is replaced by 1. -/ +def Efin (r : Multiset ℂ) (μ z : ℂ) : ℝ := + ‖1 - z‖ ^ (r.card + 1) + Gamma r μ * ‖B r.card 2 z‖ + + ∑ k ∈ Finset.Ico 3 (r.card + 1), + (‖r.esymm k‖ / ((r.card.choose k : ℝ) * ‖μ‖ ^ k)) * ‖H r.card k z‖ + +theorem norm_epsilon_le (r : Multiset ℂ) (μ z : ℂ) (hm : 2 ≤ r.card) : + ‖epsilon r μ z‖ ≤ Efin r μ z := by + have ht : ‖tail r μ z‖ ≤ ∑ k ∈ Finset.Ico 3 (r.card + 1), + (‖r.esymm k‖ / ((r.card.choose k : ℝ) * ‖μ‖ ^ k)) * ‖H r.card k z‖ := by + simpa only [tail, norm_mul, norm_coeff] using + norm_sum_le (Finset.Ico 3 (r.card + 1)) (fun k => coeff r μ k * H r.card k z) + have hc := mul_le_mul_of_nonneg_right (norm_correction_le_Gamma r μ hm) + (norm_nonneg (B r.card 2 z)) + calc + ‖epsilon r μ z‖ ≤ ‖-(1 - z) ^ (r.card + 1) + correction r μ * B r.card 2 z‖ + + ‖tail r μ z‖ := norm_add_le _ _ + _ ≤ (‖-(1 - z) ^ (r.card + 1)‖ + ‖correction r μ * B r.card 2 z‖) + + ‖tail r μ z‖ := add_le_add (norm_add_le _ _) le_rfl + _ ≤ Efin r μ z := by + simp only [norm_neg, norm_pow, norm_mul, Efin] + linarith + +/-- C-budget: the strict finite budget forces the normalized first-origin integral +outside the closed unit disk. The expansion is proved above, not a hypothesis. -/ +theorem C_budget (q : Multiset ℂ) (a : ℝ) (μ : ℂ) (hm : 2 ≤ q.card) + (ha : 0 ≤ a) (hmean : q.sum = q.card * μ) (hμ : μ ≠ 0) + (hbudget : Efin (q.map (fun v => v - μ)) μ (a * μ) + + Gamma (q.map (fun v => v - μ)) μ < 1 - a * ‖μ‖) : + 1 < ‖(q.card + 1 : ℂ) * + (∫ t in (0 : ℝ)..1, (q.map (fun v => 1 - (a : ℂ) * t * v)).prod)‖ := by + let r := q.map (fun v => v - μ) + let J : ℂ := (q.card + 1 : ℂ) * + (∫ t in (0 : ℝ)..1, (q.map (fun v => 1 - (a : ℂ) * t * v)).prod) + have hm' : 2 ≤ r.card := by simpa [r] using hm + have he := second_order q (a : ℂ) μ hm hmean hμ + have hident : (1 : ℂ) = (a * μ) * J + correction r μ - epsilon r μ (a * μ) := by + dsimp [J, r] + linear_combination -he + have hn : (1 : ℝ) ≤ ‖(a * μ) * J‖ + ‖correction r μ‖ + ‖epsilon r μ (a * μ)‖ := by + calc (1 : ℝ) = ‖(1 : ℂ)‖ := by simp + _ = ‖(a * μ) * J + correction r μ - epsilon r μ (a * μ)‖ := congrArg norm hident + _ ≤ ‖(a * μ) * J + correction r μ‖ + ‖epsilon r μ (a * μ)‖ := norm_sub_le _ _ + _ ≤ _ := add_le_add (norm_add_le _ _) le_rfl + have ha' : ‖(a : ℂ)‖ = a := by simp [Real.norm_eq_abs, abs_of_nonneg ha] + simp only [norm_mul, ha'] at hn + have hc := norm_correction_le_Gamma r μ hm' + have heps := norm_epsilon_le r μ (a * μ) hm' + change 1 < ‖J‖ + by_contra h + have hJ : ‖J‖ ≤ 1 := le_of_not_gt h + have hmul := mul_le_mul_of_nonneg_left hJ (mul_nonneg ha (norm_nonneg μ)) + change Efin r μ (a * μ) + Gamma r μ < 1 - a * ‖μ‖ at hbudget + nlinarith + +end Sendov.PaperCentered diff --git a/Sendov/Analytic/PaperCoefficient.lean b/Sendov/Analytic/PaperCoefficient.lean new file mode 100644 index 0000000..10efaef --- /dev/null +++ b/Sendov/Analytic/PaperCoefficient.lean @@ -0,0 +1,261 @@ +import Mathlib.MeasureTheory.Integral.CircleIntegral +import Mathlib.RingTheory.Polynomial.Vieta +import Mathlib.Topology.Algebra.Polynomial +import Sendov.Analytic.Maclaurin + +/-! +# Centered coefficient estimates + +Exact Cauchy circle coefficient extraction and AM–GM, independently of centered +integral expansions. The multiset formulation permits repetitions and imposes no +pointwise root bound. The optimized theorem covers zero variance separately, and +the radius estimate is valid for every real radius (including zero and negatives). + +The cached mathlib polynomial Parseval module is unavailable here; this proof uses +only the already available exact circle integrals of integer powers, not samples. +-/ + +open scoped BigOperators +open Polynomial Complex +open scoped Real + +namespace Sendov.PaperCoefficient + +private lemma circleIntegrable_eval_mul_zpow (p : ℂ[X]) (n : ℤ) : + CircleIntegrable (fun z ↦ p.eval z * z ^ n) 0 1 := by + have h : CircleIntegrable (fun z : ℂ ↦ z ^ n) 0 1 := by + simpa using (circleIntegrable_sub_zpow_iff (c := 0) (w := 0) (R := 1) (n := n)).2 + (Or.inr (Or.inr (by simp))) + exact h.fun_continuousOn_mul p.continuous.continuousOn + +/-- Exact Cauchy coefficient extraction on the unit circle. -/ +theorem circleIntegral_coeff (p : ℂ[X]) (k : ℕ) : + (∮ z in C(0, 1), p.eval z * z ^ (-(k : ℤ) - 1)) = + p.coeff k * (2 * π * I) := by + induction p using Polynomial.induction_on' with + | add p q hp hq => + simp only [eval_add, add_mul, coeff_add] + rw [circleIntegral.integral_add (circleIntegrable_eval_mul_zpow p _) + (circleIntegrable_eval_mul_zpow q _), hp, hq] + | monomial n a => + have hi : (∮ z in C(0, 1), (monomial n a).eval z * z ^ (-(k : ℤ) - 1)) = + a * ∮ z in C(0, 1), z ^ ((n : ℤ) - k - 1) := by + rw [← circleIntegral.integral_const_mul] + apply circleIntegral.integral_congr (by norm_num) + intro z hz + have hz0 : z ≠ 0 := by intro h; simp [h] at hz + simp only [eval_monomial] + rw [mul_assoc, ← zpow_natCast, ← zpow_add₀ hz0] + congr 2; omega + rw [hi] + by_cases hnk : n = k + · subst n + simp only [sub_self, zero_sub, zpow_neg_one, coeff_monomial, ↓reduceIte] + simpa using congrArg (a * ·) + (circleIntegral.integral_sub_center_inv (0 : ℂ) (R := 1) (by norm_num)) + · have hn : (n : ℤ) - k - 1 ≠ -1 := by omega + have hzero := circleIntegral.integral_sub_zpow_of_ne hn (0 : ℂ) 0 1 + simp only [sub_zero] at hzero + simp [hzero, coeff_monomial, hnk] + +/-- Cauchy's coefficient bound from a uniform bound on the unit circle. -/ +theorem norm_coeff_le_of_circle (p : ℂ[X]) (k : ℕ) (B : ℝ) + (hB : ∀ z : ℂ, ‖z‖ = 1 → ‖p.eval z‖ ≤ B) : + ‖p.coeff k‖ ≤ B := by + have h := circleIntegral.norm_two_pi_i_inv_smul_integral_le_of_norm_le_const + (f := fun z ↦ p.eval z * z ^ (-(k : ℤ) - 1)) (c := 0) (R := 1) + (C := B) (by norm_num) (by + intro z hz + have hz1 : ‖z‖ = 1 := by simpa [Metric.mem_sphere, dist_zero_right] using hz + simpa [norm_mul, norm_zpow, hz1] using hB z hz1) + rw [circleIntegral_coeff] at h + have hpi : (2 * π * I : ℂ) ≠ 0 := by simp [Real.pi_ne_zero] + have heq : (2 * π * I : ℂ)⁻¹ • (p.coeff k * (2 * π * I)) = p.coeff k := by + rw [smul_eq_mul, mul_comm (p.coeff k), inv_mul_cancel_left₀ hpi] + rw [heq, one_mul] at h + exact h + +/-- Squared Cauchy bound, with no positivity assumption hidden in the interface. -/ +theorem norm_coeff_sq_le_of_circle (p : ℂ[X]) (k : ℕ) (B : ℝ) + (hB : ∀ z : ℂ, ‖z‖ = 1 → ‖p.eval z‖ ^ 2 ≤ B) : + ‖p.coeff k‖ ^ 2 ≤ B := by + have hB0 : 0 ≤ B := (sq_nonneg _).trans (hB 1 (by simp)) + have h := norm_coeff_le_of_circle p k (Real.sqrt B) (fun z hz ↦ + (Real.le_sqrt (norm_nonneg _) hB0).2 (hB z hz)) + exact (sq_le_sq₀ (norm_nonneg _) (Real.sqrt_nonneg _)).2 h |>.trans_eq + (Real.sq_sqrt hB0) + +/-- The variance parameter for a centered multiset. -/ +noncomputable def variance (r : Multiset ℂ) : ℝ := + (r.map (fun z ↦ ‖z‖ ^ 2)).sum / r.card + +/-- AM–GM gives the sharp top-degree product bound, including the empty family. -/ +theorem norm_prod_sq_le_variance_pow (r : Multiset ℂ) : + ‖r.prod‖ ^ 2 ≤ variance r ^ r.card := by + have h := Sendov.Multiset.prod_le_mean_pow (r.map (fun z ↦ ‖z‖ ^ 2)) (by + intro x hx + obtain ⟨z, _, rfl⟩ := Multiset.mem_map.mp hx + exact sq_nonneg _) + have hn : (r.map norm).prod = ‖r.prod‖ := by + clear h + induction r using Multiset.induction_on with + | empty => simp + | cons a r ih => simp [ih] + simpa [variance, Multiset.prod_map_pow, hn] using h + +/-- The cross term in the mean square is exactly the sum of the roots. -/ +theorem sum_norm_add_sq (r : Multiset ℂ) (z : ℂ) : + (r.map (fun w ↦ ‖z + w‖ ^ 2)).sum = + r.card * ‖z‖ ^ 2 + (r.map (fun w ↦ ‖w‖ ^ 2)).sum + + 2 * (z * (starRingEnd ℂ) r.sum).re := by + simp only [← Complex.normSq_eq_norm_sq] + induction r using Multiset.induction_on with + | empty => simp + | cons a r ih => + simp only [Multiset.map_cons, Multiset.sum_cons, Multiset.card_cons, + Nat.cast_add, Nat.cast_one, ih] + rw [Complex.normSq_add, map_add, mul_add, add_re] + ring + +/-- The centered AM–GM circle bound; no individual bound on the roots is used. -/ +theorem norm_prod_add_sq_le (r : Multiset ℂ) (hr : r.sum = 0) + (z : ℂ) (hz : ‖z‖ = 1) : + ‖(r.map (fun w ↦ z + w)).prod‖ ^ 2 ≤ (1 + variance r) ^ r.card := by + by_cases hcard : r.card = 0 + · have hr0 := Multiset.card_eq_zero.mp hcard + subst r + simp + have hc : (r.card : ℝ) ≠ 0 := by exact_mod_cast hcard + have h := norm_prod_sq_le_variance_pow (r.map (fun w ↦ z + w)) + have hv : variance (r.map (fun w ↦ z + w)) = 1 + variance r := by + unfold variance + simp only [Multiset.map_map, Multiset.card_map, Function.comp_def] + rw [sum_norm_add_sq, hr, hz] + simp only [one_pow, mul_one, map_zero, mul_zero, zero_re, add_zero] + rw [add_div, div_self hc] + simpa only [hv, Multiset.card_map] using h + +/-- All elementary symmetric coefficients obey the centered unit-circle bound. -/ +theorem norm_esymm_sq_le (r : Multiset ℂ) (hr : r.sum = 0) + (k : ℕ) (hk : k ≤ r.card) : + ‖r.esymm k‖ ^ 2 ≤ (1 + variance r) ^ r.card := by + let p : ℂ[X] := (r.map (fun w ↦ X + C w)).prod + have hp : p.coeff (r.card - k) = r.esymm k := by + dsimp [p] + rw [Multiset.prod_X_add_C_coeff r (Nat.sub_le _ _), Nat.sub_sub_self hk] + rw [← hp] + apply norm_coeff_sq_le_of_circle + intro z hz + have heval : p.eval z = (r.map (fun w ↦ z + w)).prod := by + dsimp [p] + change (evalRingHom z) (r.map (fun w ↦ X + C w)).prod = _ + rw [map_multiset_prod] + simp [Multiset.map_map] + rw [heval] + exact norm_prod_add_sq_le r hr z hz + +/-- Scaling of variance, valid also when the scalar or the family is zero. -/ +theorem variance_map_mul (r : Multiset ℂ) (a : ℂ) : + variance (r.map (a * ·)) = ‖a‖ ^ 2 * variance r := by + simp only [variance, Multiset.map_map, Multiset.card_map, Function.comp_def, norm_mul, + mul_pow, Multiset.sum_map_mul_left] + ring + +/-- The radius-parametrized coefficient estimate from REPORT §3.2. -/ +theorem norm_esymm_sq_mul_pow_le (r : Multiset ℂ) (hr : r.sum = 0) + (k : ℕ) (hk : k ≤ r.card) (R : ℝ) : + ‖r.esymm k‖ ^ 2 * R ^ (2 * k) ≤ (1 + R ^ 2 * variance r) ^ r.card := by + have hs : (r.map ((R : ℂ) * ·)).sum = 0 := by + rw [Multiset.sum_map_mul_left] + simp [hr] + have h := norm_esymm_sq_le (r.map ((R : ℂ) * ·)) hs k (by simpa using hk) + have he := Multiset.pow_smul_esymm (R : ℂ) k r + simp only [smul_eq_mul] at he + rw [← he, variance_map_mul] at h + simp only [norm_mul, norm_pow, Multiset.card_map, + Complex.norm_real, Real.norm_eq_abs, mul_pow, sq_abs] at h + have habs : (|R| ^ k) ^ 2 = R ^ (2 * k) := by + calc + _ = (|R| ^ 2) ^ k := by rw [← pow_mul, ← pow_mul, Nat.mul_comm k 2] + _ = _ := by rw [sq_abs, ← pow_mul] + simpa only [habs, mul_comm] using h + +/-- Variance is always nonnegative. -/ +theorem variance_nonneg (r : Multiset ℂ) : 0 ≤ variance r := by + apply div_nonneg _ (Nat.cast_nonneg _) + exact Multiset.sum_nonneg (by + intro x hx + obtain ⟨z, _, rfl⟩ := Multiset.mem_map.mp hx + exact sq_nonneg _) + +/-- Vanishing variance makes every positive-degree elementary coefficient vanish. -/ +theorem esymm_eq_zero_of_variance_eq_zero (r : Multiset ℂ) + (hv : variance r = 0) (k : ℕ) (hk : 0 < k) : r.esymm k = 0 := by + have hall : ∀ z ∈ r, z = 0 := by + intro z hz + have hc : r.card ≠ 0 := by + intro hc + simp [Multiset.card_eq_zero.mp hc] at hz + have hs : (r.map (fun z ↦ ‖z‖ ^ 2)).sum = 0 := by + exact (div_eq_zero_iff.mp hv).resolve_right (by exact_mod_cast hc) + have hle := Multiset.single_le_sum (s := r.map (fun z ↦ ‖z‖ ^ 2)) + (by intro x hx; obtain ⟨w, _, rfl⟩ := Multiset.mem_map.mp hx; exact sq_nonneg _) + (‖z‖ ^ 2) (Multiset.mem_map.mpr ⟨z, hz, rfl⟩) + rw [hs] at hle + have hn : ‖z‖ = 0 := by nlinarith [sq_nonneg ‖z‖] + exact norm_eq_zero.mp hn + have hm : r.map ((0 : ℂ) • ·) = r := by + calc + _ = r.map id := Multiset.map_congr rfl (fun z hz ↦ by simp [hall z hz]) + _ = r := Multiset.map_id r + have he := Multiset.pow_smul_esymm (0 : ℂ) k r + rw [hm] at he + simpa [zero_pow hk.ne'] using he.symm + +/-- Scalar optimization of the radius-parametrized inequality. -/ +theorem optimized_scalar_bound {E v : ℝ} {m k : ℕ} + (hv : 0 < v) (hk : 0 < k) (hkm : k < m) + (h : ∀ t : ℝ, 0 ≤ t → E * t ^ k ≤ (1 + t * v) ^ m) : + E ≤ (m : ℝ) ^ m / ((k : ℝ) ^ k * ((m - k : ℕ) : ℝ) ^ (m - k)) * v ^ k := by + let d : ℝ := (m - k : ℕ) + have hd : 0 < d := by dsimp [d]; exact_mod_cast Nat.sub_pos_of_lt hkm + have hkR : 0 < (k : ℝ) := by exact_mod_cast hk + have hmR : (m : ℝ) = (k : ℝ) + d := by + dsimp [d] + exact_mod_cast (Nat.add_sub_of_le hkm.le).symm + have ht : 0 < (k : ℝ) / (d * v) := div_pos hkR (mul_pos hd hv) + have hh := h ((k : ℝ) / (d * v)) ht.le + have hbase : 1 + (k : ℝ) / (d * v) * v = (m : ℝ) / d := by + rw [hmR] + field_simp + ring + rw [hbase] at hh + have he := (le_div_iff₀ (pow_pos ht k)).mpr hh + apply he.trans_eq + change ((m : ℝ) / d) ^ m / ((k : ℝ) / (d * v)) ^ k = + (m : ℝ) ^ m / ((k : ℝ) ^ k * d ^ (m - k)) * v ^ k + have hdp : d ^ m = d ^ k * d ^ (m - k) := by + rw [← pow_add, Nat.add_sub_of_le hkm.le] + rw [div_pow, hdp, div_pow, mul_pow] + field_simp + +/-- The optimized finite-degree bound of REPORT §3.2, including zero variance. -/ +theorem norm_esymm_sq_le_optimized (r : Multiset ℂ) (hr : r.sum = 0) + (k : ℕ) (hk : 0 < k) (hkm : k < r.card) : + ‖r.esymm k‖ ^ 2 ≤ + (r.card : ℝ) ^ r.card / + ((k : ℝ) ^ k * ((r.card - k : ℕ) : ℝ) ^ (r.card - k)) * variance r ^ k := by + rcases (variance_nonneg r).eq_or_lt with hv | hv + · rw [esymm_eq_zero_of_variance_eq_zero r hv.symm k hk, ← hv] + simp [zero_pow hk.ne'] + · apply optimized_scalar_bound hv hk hkm + intro t ht + have h := norm_esymm_sq_mul_pow_le r hr k hkm.le (Real.sqrt t) + simpa only [pow_mul, Real.sq_sqrt ht] using h + +/-- The top-degree coefficient has the sharper product bound, without centeredness. -/ +theorem norm_esymm_card_sq_le (r : Multiset ℂ) : + ‖r.esymm r.card‖ ^ 2 ≤ variance r ^ r.card := by + simpa [Multiset.esymm] using norm_prod_sq_le_variance_pow r + +end Sendov.PaperCoefficient diff --git a/Sendov/Analytic/PaperLaplace.lean b/Sendov/Analytic/PaperLaplace.lean new file mode 100644 index 0000000..436d5d4 --- /dev/null +++ b/Sendov/Analytic/PaperLaplace.lean @@ -0,0 +1,292 @@ +import Sendov.Analytic.PaperTaylor +import Sendov.Analytic.PaperPolar +import Mathlib.Analysis.SpecialFunctions.ExpDeriv + +/-! +# Sharp Laplace bound for the actual Taylor budget + +Source: round4/REPORT.md §5.2 and round5/REPORT.md §5.3. +The split point is `x / (2*a)` and all integrals below are actual interval integrals. +-/ + +namespace Sendov.PaperLaplace + +open MeasureTheory PaperTaylor + +/-- The first-order exponential remainder, valid without a sign restriction. -/ +lemma exp_le_one_add_mul_exp (v : ℝ) : + Real.exp v ≤ 1 + v * Real.exp v := by + have h := mul_le_mul_of_nonneg_right (Real.add_one_le_exp (-v)) (Real.exp_pos v).le + rw [← Real.exp_add] at h + simp only [neg_add_cancel, Real.exp_zero] at h + nlinarith + +/-- A reusable exponential Taylor comparison with a controlled quadratic error. -/ +lemma rpow_le_exp_taylor {b p u v : ℝ} (hb : 0 < b) (hp : 0 ≤ p) + (hv : 0 ≤ v) (hlog : p * (b - 1) ≤ -u + v) (hvu : v ≤ u / 4) : + b ^ p ≤ Real.exp (-u) + v * Real.exp (-(3 / 4 : ℝ) * u) := by + have hlog' := mul_le_mul_of_nonneg_left (Real.log_le_sub_one_of_pos hb) hp + have hpow : b ^ p ≤ Real.exp (-u + v) := by + rw [Real.rpow_def_of_pos hb] + apply Real.exp_le_exp.mpr + nlinarith + have hexp := mul_le_mul_of_nonneg_left (exp_le_one_add_mul_exp v) + (Real.exp_pos (-u)).le + have hrem := mul_le_mul_of_nonneg_left + (Real.exp_le_exp.mpr (show -u + v ≤ -(3 / 4 : ℝ) * u by linarith)) hv + rw [Real.exp_add] at hpow hrem + nlinarith + +lemma split_mem {a x : ℝ} (ha : 0 < a) (hx : 0 < x) (hxa : x < 2 * a) : + x / (2 * a) ∈ Set.Ioo (0 : ℝ) 1 := by + exact ⟨div_pos hx (by positivity), (div_lt_one (by positivity)).mpr hxa⟩ + +lemma beta_split {a : ℝ} (ha : a ≠ 0) (x : ℝ) : + beta a x (x / (2 * a)) = 1 - 3 * x ^ 2 / 4 := by + unfold beta + field_simp + ring + +/-- The paper's pointwise two-exponential majorant on the left interval. -/ +lemma beta_rpow_le_exp {m a x t : ℝ} (hm : 1 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : x ≤ 1) (hxa : x < 2 * a) (ht : t ∈ Set.Icc (0 : ℝ) (x / (2 * a))) : + beta a x t ^ ((m - 1) / 2) ≤ + Real.exp (-((m - 1) * a * x) * t) + + ((m - 1) / 2 * a ^ 2 * t ^ 2) * + Real.exp (-(3 / 4 : ℝ) * ((m - 1) * a * x) * t) := by + have ht1 : t ≤ 1 := ht.2.trans ((div_lt_one (by positivity)).mpr hxa).le + have ht0 := ht.1 + have hm0 : 0 ≤ m - 1 := sub_nonneg.mpr hm + have hat : 2 * a * t ≤ x := by + have h := (le_div_iff₀ (show 0 < 2 * a by positivity)).mp ht.2 + nlinarith + have hvu : (m - 1) / 2 * a ^ 2 * t ^ 2 ≤ ((m - 1) * a * x * t) / 4 := by + have h := mul_nonneg (show 0 ≤ (m - 1) * a * t by positivity) (sub_nonneg.mpr hat) + nlinarith only [h] + have h := rpow_le_exp_taylor (beta_pos ha ha1 hx ⟨ht.1, ht1⟩) + (by positivity : 0 ≤ (m - 1) / 2) + (by positivity : 0 ≤ (m - 1) / 2 * a ^ 2 * t ^ 2) + (show (m - 1) / 2 * (beta a x t - 1) ≤ + -((m - 1) * a * x * t) + (m - 1) / 2 * a ^ 2 * t ^ 2 by unfold beta; ring_nf; exact le_rfl) + hvu + simpa only [neg_mul, mul_assoc] using h + +/-- Exact first exponential moment, including the finite endpoint remainder. -/ +lemma integral_mul_exp {s : ℝ} (hs : s ≠ 0) (z : ℝ) : + (∫ t in (0 : ℝ)..z, t * Real.exp (-s * t)) = + 1 / s ^ 2 - (z / s + 1 / s ^ 2) * Real.exp (-s * z) := by + have hd : ∀ t : ℝ, HasDerivAt + (fun t : ℝ => -(t / s + 1 / s ^ 2) * Real.exp (-s * t)) + (t * Real.exp (-s * t)) t := by + intro t + convert! ((((hasDerivAt_id t).div_const s).add_const (1 / s ^ 2)).neg.mul + (((hasDerivAt_id t).const_mul (-s)).exp)) using 1 + dsimp + field_simp + ring + have h := intervalIntegral.integral_eq_sub_of_hasDerivAt (fun t _ => hd t) + ((by fun_prop : Continuous (fun t : ℝ => t * Real.exp (-s * t))).intervalIntegrable 0 z) + convert! h using 1 + simp + ring + +/-- Exact cubic exponential moment. -/ +lemma integral_cube_mul_exp {s : ℝ} (hs : s ≠ 0) (z : ℝ) : + (∫ t in (0 : ℝ)..z, t ^ 3 * Real.exp (-s * t)) = + 6 / s ^ 4 - (z ^ 3 / s + 3 * z ^ 2 / s ^ 2 + 6 * z / s ^ 3 + 6 / s ^ 4) * + Real.exp (-s * z) := by + have hd : ∀ t : ℝ, HasDerivAt + (fun t : ℝ => -(t ^ 3 / s + 3 * t ^ 2 / s ^ 2 + 6 * t / s ^ 3 + 6 / s ^ 4) * + Real.exp (-s * t)) (t ^ 3 * Real.exp (-s * t)) t := by + intro t + convert! ((((((hasDerivAt_id t).pow 3).div_const s).add + ((((hasDerivAt_id t).pow 2).const_mul 3).div_const (s ^ 2))).add + (((hasDerivAt_id t).const_mul 6).div_const (s ^ 3))).add_const (6 / s ^ 4)).neg.mul + (((hasDerivAt_id t).const_mul (-s)).exp) using 1 + dsimp + field_simp + ring + have h := intervalIntegral.integral_eq_sub_of_hasDerivAt (fun t _ => hd t) + ((by fun_prop : Continuous (fun t : ℝ => t ^ 3 * Real.exp (-s * t))).intervalIntegrable 0 z) + convert! h using 1 + simp + ring + +lemma integral_mul_exp_le {s z : ℝ} (hs : 0 < s) (hz : 0 ≤ z) : + (∫ t in (0 : ℝ)..z, t * Real.exp (-s * t)) ≤ 1 / s ^ 2 := by + rw [integral_mul_exp hs.ne'] + have : 0 ≤ (z / s + 1 / s ^ 2) * Real.exp (-s * z) := by positivity + linarith + +lemma integral_cube_mul_exp_le {s z : ℝ} (hs : 0 < s) (hz : 0 ≤ z) : + (∫ t in (0 : ℝ)..z, t ^ 3 * Real.exp (-s * t)) ≤ 6 / s ^ 4 := by + rw [integral_cube_mul_exp hs.ne'] + have : 0 ≤ (z ^ 3 / s + 3 * z ^ 2 / s ^ 2 + 6 * z / s ^ 3 + 6 / s ^ 4) * + Real.exp (-s * z) := by positivity + linarith + +/-- Continuity supplies every integrability obligation for the actual kernel. -/ +lemma continuous_weighted_beta (a x p : ℝ) (hp : 0 ≤ p) : + Continuous (fun t : ℝ => t * beta a x t ^ p) := + continuous_id.mul ((continuous_rpow_const hp).comp (by unfold beta; fun_prop)) + +/-- Convexity of the quadratic, expressed as an explicit secant certificate. -/ +lemma beta_le_of_endpoints {a x z t r : ℝ} (hz : z < 1) + (ht : t ∈ Set.Icc z 1) (hzr : beta a x z ≤ r) (h1r : beta a x 1 ≤ r) : + beta a x t ≤ r := by + have h0 := mul_nonneg (sub_nonneg.mpr ht.2) (sub_nonneg.mpr hzr) + have h1 := mul_nonneg (sub_nonneg.mpr ht.1) (sub_nonneg.mpr h1r) + have h2 := mul_nonneg (mul_nonneg (mul_nonneg (sq_nonneg a) + (sub_nonneg.mpr ht.1)) (sub_nonneg.mpr ht.2)) (sub_nonneg.mpr hz.le) + by_contra h + have h3 := mul_pos (sub_pos.mpr hz) (sub_pos.mpr (lt_of_not_ge h)) + unfold beta at * + nlinarith only [h0, h1, h2, h3] + +/-- Actual left integral, with the two exponential moments explicitly evaluated. -/ +lemma integral_left_le {m a x : ℝ} (hm : 1 < m) (ha : 0 < a) (ha1 : a < 1) + (hx0 : 0 < x) (hx : x ≤ 1) (hxa : x < 2 * a) : + (∫ t in (0 : ℝ)..(x / (2 * a)), t * beta a x t ^ ((m - 1) / 2)) ≤ + 1 / ((m - 1) ^ 2 * a ^ 2 * x ^ 2) + + (256 / 27 : ℝ) / ((m - 1) ^ 3 * a ^ 2 * x ^ 4) := by + let s := (m - 1) * a * x + let c := (m - 1) / 2 * a ^ 2 + let z := x / (2 * a) + have hm0 : 0 < m - 1 := sub_pos.mpr hm + have hs : 0 < s := by dsimp [s]; positivity + have hc : 0 ≤ c := by dsimp [c]; positivity + have hz : 0 ≤ z := (split_mem ha hx0 hxa).1.le + have hf : IntervalIntegrable (fun t : ℝ => t * Real.exp (-s * t)) volume 0 z := + (by fun_prop : Continuous (fun t : ℝ => t * Real.exp (-s * t))).intervalIntegrable _ _ + have hg : IntervalIntegrable (fun t : ℝ => t ^ 3 * Real.exp (-(3 / 4 : ℝ) * s * t)) + volume 0 z := + (by fun_prop : Continuous + (fun t : ℝ => t ^ 3 * Real.exp (-(3 / 4 : ℝ) * s * t))).intervalIntegrable _ _ + have h := intervalIntegral.integral_mono_on hz + ((continuous_weighted_beta a x ((m - 1) / 2) (by positivity)).intervalIntegrable 0 z) + (hf.add (hg.const_mul c)) (show ∀ t ∈ Set.Icc (0 : ℝ) z, + t * beta a x t ^ ((m - 1) / 2) ≤ + t * Real.exp (-s * t) + c * (t ^ 3 * Real.exp (-(3 / 4 : ℝ) * s * t)) from by + intro t ht + have h := mul_le_mul_of_nonneg_left (beta_rpow_le_exp hm.le ha ha1 hx hxa ht) ht.1 + convert! h using 1 + dsimp [s, c] + ring) + rw [intervalIntegral.integral_add hf (hg.const_mul c), intervalIntegral.integral_const_mul] at h + have hfirst := integral_mul_exp_le hs hz + have hthird := integral_cube_mul_exp_le (show 0 < (3 / 4 : ℝ) * s by positivity) hz + have hthird' : (∫ t in (0 : ℝ)..z, t ^ 3 * Real.exp (-(3 / 4 : ℝ) * s * t)) ≤ + 6 / ((3 / 4 : ℝ) * s) ^ 4 := by simpa only [neg_mul] using hthird + have hbound := h.trans (add_le_add hfirst (mul_le_mul_of_nonneg_left hthird' hc)) + convert! hbound using 1 + dsimp [s, c] + field_simp + ring + +/-- Actual right integral: convexity controls the kernel by the two endpoints. -/ +lemma integral_right_le {m a x r : ℝ} (hm : 1 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx0 : 0 < x) (hx : x ≤ 1) (hxa : x < 2 * a) + (hr0 : 1 - 3 * x ^ 2 / 4 ≤ r) (hr1 : beta a x 1 ≤ r) : + (∫ t in (x / (2 * a))..(1 : ℝ), t * beta a x t ^ ((m - 1) / 2)) ≤ + r ^ ((m - 1) / 2) / 2 := by + let z := x / (2 * a) + have hz := split_mem ha hx0 hxa + have hp : 0 ≤ (m - 1) / 2 := by linarith + have hr : 0 < r := (beta_pos ha ha1 hx (t := 1) (by norm_num)).trans_le hr1 + have hzr : beta a x z ≤ r := by simpa only [z, beta_split ha.ne'] using hr0 + have h := intervalIntegral.integral_mono_on (μ := volume) hz.2.le + ((continuous_weighted_beta a x ((m - 1) / 2) hp).intervalIntegrable z 1) + ((continuous_id.mul_const (r ^ ((m - 1) / 2))).intervalIntegrable z 1) + (show ∀ t ∈ Set.Icc z (1 : ℝ), t * beta a x t ^ ((m - 1) / 2) ≤ + t * r ^ ((m - 1) / 2) from by + intro t ht + have ht0 : 0 ≤ t := hz.1.le.trans ht.1 + exact mul_le_mul_of_nonneg_left + (Real.rpow_le_rpow (beta_pos ha ha1 hx ⟨ht0, ht.2⟩).le + (beta_le_of_endpoints hz.2 ht hzr hr1) hp) ht0) + rw [intervalIntegral.integral_mul_const] at h + simp only [id_eq, integral_id, one_pow] at h + have hpow := Real.rpow_nonneg hr.le ((m - 1) / 2) + have hrest := mul_nonneg (sq_nonneg z) hpow + nlinarith + +/-- **(S)** for `PaperTaylor.budget`, including its endpoint term and actual integral. + +The analytic statement holds for every real `m > 1`. Raw polar is not needed here: +it is used by the paper to supply the geometric and endpoint hypotheses. +No exponential or integral estimate is assumed. -/ +theorem budget_le_of_beta_le_one {m a x r : ℝ} (hm : 1 < m) (ha : 0 < a) (ha1 : a < 1) + (hx0 : 0 < x) (hx1 : x ≤ 1) (hxa : x < 2 * a) + (hr0 : 1 - 3 * x ^ 2 / 4 ≤ r) (hrb : beta a x 1 ≤ r) (hb1 : beta a x 1 ≤ 1) : + m * x ^ 2 * PaperTaylor.budget m a x ≤ + m ^ 2 / (m - 1) ^ 2 + (256 / 27 : ℝ) * m ^ 2 / ((m - 1) ^ 3 * x ^ 2) + + (m ^ 2 / 2 + m) * r ^ ((m - 1) / 2) := by + let L := 1 / ((m - 1) ^ 2 * a ^ 2 * x ^ 2) + + (256 / 27 : ℝ) / ((m - 1) ^ 3 * a ^ 2 * x ^ 4) + let R := r ^ ((m - 1) / 2) + have hm0 : 0 < m := by linarith + have hm1 : 0 < m - 1 := sub_pos.mpr hm + have hp : 0 ≤ (m - 1) / 2 := by positivity + have hb : 0 < beta a x 1 := beta_pos ha ha1 hx1 (by norm_num) + have hR : 0 ≤ R := Real.rpow_nonneg (hb.le.trans hrb) _ + have hleft := integral_left_le hm ha ha1 hx0 hx1 hxa + have hright := integral_right_le hm.le ha ha1 hx0 hx1 hxa hr0 hrb + have hi : (∫ t in (0 : ℝ)..1, t * beta a x t ^ ((m - 1) / 2)) ≤ L + R / 2 := by + rw [← intervalIntegral.integral_add_adjacent_intervals + ((continuous_weighted_beta a x ((m - 1) / 2) hp).intervalIntegrable + (0 : ℝ) (x / (2 * a))) + ((continuous_weighted_beta a x ((m - 1) / 2) hp).intervalIntegrable + (x / (2 * a)) (1 : ℝ))] + exact add_le_add hleft hright + have hend : beta a x 1 ^ (m / 2) ≤ R := + (Real.rpow_le_rpow_of_exponent_ge hb hb1 (by linarith)).trans + (Real.rpow_le_rpow hb.le hrb hp) + have hbudget : PaperTaylor.budget m a x ≤ R + m * a ^ 2 * (L + R / 2) := by + unfold PaperTaylor.budget + exact add_le_add hend (mul_le_mul_of_nonneg_left hi (by positivity)) + have hscaled := mul_le_mul_of_nonneg_left hbudget (show 0 ≤ m * x ^ 2 by positivity) + have heq : m * x ^ 2 * (R + m * a ^ 2 * (L + R / 2)) = + m ^ 2 / (m - 1) ^ 2 + (256 / 27 : ℝ) * m ^ 2 / ((m - 1) ^ 3 * x ^ 2) + + (m * x ^ 2 + m ^ 2 * a ^ 2 * x ^ 2 / 2) * R := by + dsimp [L] + field_simp + ring + rw [heq] at hscaled + have hx2 : x ^ 2 ≤ 1 := by nlinarith + have ha2 : a ^ 2 ≤ 1 := by nlinarith + have hax2 : a ^ 2 * x ^ 2 ≤ 1 := by + nlinarith [mul_le_mul_of_nonneg_left hx2 (sq_nonneg a)] + have hcoef : m * x ^ 2 + m ^ 2 * a ^ 2 * x ^ 2 / 2 ≤ m ^ 2 / 2 + m := by + nlinarith only [mul_le_mul_of_nonneg_left hx2 hm0.le, + mul_le_mul_of_nonneg_left hax2 (sq_nonneg m)] + exact hscaled.trans (add_le_add le_rfl (mul_le_mul_of_nonneg_right hcoef hR)) + +/-- Convenient radius form of **(S)**. The endpoint positivity also proves `0 < r`. -/ +theorem budget_le {m a x r : ℝ} (hm : 1 < m) (ha : 0 < a) (ha1 : a < 1) + (hx0 : 0 < x) (hx1 : x ≤ 1) (hxa : x < 2 * a) + (hr0 : 1 - 3 * x ^ 2 / 4 ≤ r) (hrb : beta a x 1 ≤ r) (hr1 : r ≤ 1) : + m * x ^ 2 * PaperTaylor.budget m a x ≤ + m ^ 2 / (m - 1) ^ 2 + (256 / 27 : ℝ) * m ^ 2 / ((m - 1) ^ 3 * x ^ 2) + + (m ^ 2 / 2 + m) * r ^ ((m - 1) / 2) := + budget_le_of_beta_le_one hm ha ha1 hx0 hx1 hxa hr0 hrb (hrb.trans hr1) + +/-- Paper interface: raw polar supplies positivity of `x` and `beta(1) < 1`. +The hypothesis `1/2 < a` ensures the paper's split lies strictly before 1. +Only the two stated endpoint bounds on `r` remain; `r ≤ 1` is not required. -/ +theorem sharp_laplace {m : ℕ} {a x r : ℝ} (hm : 7 ≤ m) + (ha : 1 / 2 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) + (hr0 : 1 - 3 * x ^ 2 / 4 ≤ r) (hrb : PaperPolar.b a x ≤ r) : + (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x ≤ + (m : ℝ) ^ 2 / (m - 1) ^ 2 + + (256 / 27 : ℝ) * m ^ 2 / ((m - 1) ^ 3 * x ^ 2) + + ((m : ℝ) ^ 2 / 2 + m) * r ^ (((m : ℝ) - 1) / 2) := by + have ha0 : 0 < a := by linarith + have hgeom := PaperPolar.geometry hm ha0 ha1 hx0 hx1 hraw + have hb := PaperPolar.b_lt_one (by omega : 0 < m) ha0 ha1 hx0 hx1 hraw + have heq : beta a x 1 = PaperPolar.b a x := by simp [beta, PaperPolar.b] + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + exact budget_le_of_beta_le_one (by linarith) ha0 ha1 (by linarith [hgeom.1]) + hx1 (by linarith) hr0 (by simpa only [heq] using hrb) (by simpa only [heq] using hb.le) + +end Sendov.PaperLaplace diff --git a/Sendov/Analytic/PaperNear.lean b/Sendov/Analytic/PaperNear.lean new file mode 100644 index 0000000..8e258a0 --- /dev/null +++ b/Sendov/Analytic/PaperNear.lean @@ -0,0 +1,191 @@ +import Sendov.Analytic.PaperPolar +import Sendov.Analytic.PaperTaylor +import Sendov.Analytic.PaperNearAlgebra + +/-! +# Near-endpoint closure of the actual paper D budget + +The integer endpoint estimate has one geometric base case, at `m = 7`. +All scalar parameters and both Taylor errors are derived from raw polar. +-/ + +namespace Sendov.PaperNearClosure + +lemma half_power_le : (2 / 17 : ℝ) ^ (1 / 2 : ℝ) ≤ 7 / 20 := by + have hs : ((2 / 17 : ℝ) ^ (1 / 2 : ℝ)) ^ 2 = 2 / 17 := by + rw [← Real.rpow_natCast _ 2, ← Real.rpow_mul (by norm_num : (0 : ℝ) ≤ 2 / 17)] + norm_num + nlinarith [Real.rpow_nonneg (by norm_num : (0 : ℝ) ≤ 2 / 17) (1 / 2 : ℝ)] + +/-- One base case followed by a uniform geometric step, not a degree table. -/ +lemma geometric_endpoint {m : ℕ} (hm : 7 ≤ m) : + (m : ℝ) / 3 * (2 / 17 : ℝ) ^ (((m : ℝ) - 2) / 2) ≤ 49 / 4335 := by + induction m, hm using Nat.le_induction with + | base => + norm_num only [Nat.cast_ofNat] + rw [show (5 : ℝ) / 2 = 2 + 1 / 2 by norm_num, + Real.rpow_add (by norm_num : (0 : ℝ) < 2 / 17)] + norm_num [Real.rpow_two] + nlinarith [half_power_le] + | succ k hk ih => + have hk' : (7 : ℝ) ≤ k := by exact_mod_cast hk + have hp : 0 ≤ (2 / 17 : ℝ) ^ (((k : ℝ) - 2) / 2) := + Real.rpow_nonneg (by norm_num) _ + have he : (((k + 1 : ℕ) : ℝ) - 2) / 2 = ((k : ℝ) - 2) / 2 + 1 / 2 := by + push_cast + ring + rw [he, Real.rpow_add (by norm_num : (0 : ℝ) < 2 / 17)] + have hs := mul_le_mul_of_nonneg_left half_power_le + (show 0 ≤ (((k + 1 : ℕ) : ℝ) / 3) * (2 / 17 : ℝ) ^ (((k : ℝ) - 2) / 2) + by positivity) + have hc : (((k + 1 : ℕ) : ℝ) / 3) * (7 / 20) ≤ (k : ℝ) / 3 := by + push_cast + linarith + have ht := mul_le_mul_of_nonneg_right hc hp + nlinarith only [hs, ht, ih] + +/-- The actual endpoint term is uniformly less than one eightieth of `1-a`. -/ +theorem endpoint_term_lt {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 2 / 5) : + PaperPolar.b a x ^ ((m : ℝ) / 2) / (1 - a) < 1 / 80 := by + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + have hh : 0 < 1 - a := by linarith + have hl := PaperPolar.lambda_pos (by omega : 0 < m) ha1 + have hb0 := PaperPolar.b_pos ha0.le ha1 hx1 + have hb := (PaperPolar.endpoint_bounds hm ha0 ha1 hx0 hx1 hraw).1.trans + (PaperPolar.endpoint_bounds hm ha0 ha1 hx0 hx1 hraw).2 + have hl2 : PaperPolar.lambda m a ≤ 2 / 5 := hnear + have hb2 : PaperPolar.b a x ≤ 2 / 17 := by + have ht := PaperPolar.rational_mono hl.le hl2 + norm_num at ht + exact hb.trans ht + have hb3 : PaperPolar.b a x ≤ (m : ℝ) * (1 - a) / 3 := by + have hs : 0 < 3 + PaperPolar.lambda m a := by positivity + have ht : PaperPolar.lambda m a / (3 + PaperPolar.lambda m a) ≤ + PaperPolar.lambda m a / 3 := by + apply div_le_div_of_nonneg_left hl.le (by norm_num) + linarith + exact hb.trans ht + have hpow := Real.rpow_le_rpow hb0.le hb2 (by linarith : 0 ≤ ((m : ℝ) - 2) / 2) + have hsplit : PaperPolar.b a x ^ ((m : ℝ) / 2) = + PaperPolar.b a x * PaperPolar.b a x ^ (((m : ℝ) - 2) / 2) := by + rw [show (m : ℝ) / 2 = 1 + ((m : ℝ) - 2) / 2 by ring, + Real.rpow_add hb0, Real.rpow_one] + have hmul := mul_le_mul hb3 hpow + (Real.rpow_nonneg hb0.le _) (by positivity : 0 ≤ (m : ℝ) * (1 - a) / 3) + rw [← hsplit] at hmul + apply (div_lt_iff₀ hh).2 + have hg := mul_le_mul_of_nonneg_right (geometric_endpoint hm) hh.le + have hc : (49 / 4335 : ℝ) * (1 - a) < (1 / 80 : ℝ) * (1 - a) := by + exact mul_lt_mul_of_pos_right (by norm_num) hh + nlinarith only [hmul, hg, hc] + +/-- Exact conversion of the first Taylor error to the correlated parameter `f`. -/ +lemma first_error_le {m a d : ℝ} (hm : 7 ≤ m) (ha0 : 0 < a) (ha1 : a < 1) + (hd : d ≤ m * (1 - a) / (3 + m * (1 - a))) : + d / (a * (m - 2)) ≤ (1 - a) * PaperNear.f (1 / m) (m * (1 - a)) := by + have hm0 : 0 < m := by linarith + have hm2 : 0 < m - 2 := by linarith + have hs : 0 < 3 + m * (1 - a) := by positivity + have he1 : 1 - m * (1 - a) * (1 / m) = a := by field_simp; ring + have he2 : 1 - 2 * (1 / m) = (m - 2) / m := by field_simp + calc + d / (a * (m - 2)) ≤ (m * (1 - a) / (3 + m * (1 - a))) / (a * (m - 2)) := + div_le_div_of_nonneg_right hd (by positivity) + _ = (1 - a) * PaperNear.f (1 / m) (m * (1 - a)) := by + unfold PaperNear.f PaperNear.P + rw [he1, he2] + field_simp + +/-- Exact conversion of the second Taylor error; `a² ≤ 1` is proved, not assumed. -/ +lemma second_error_le {m a d c : ℝ} (hm : 7 ≤ m) (ha0 : 0 < a) (ha1 : a < 1) + (hd0 : 0 ≤ d) (hd : d ≤ m * (1 - a) / (3 + m * (1 - a))) + (hc : 3 / (3 + m * (1 - a)) ≤ c) : + 12 * m * a ^ 2 * d ^ 2 / (c ^ 4 * (m + 1) * (m + 3)) ≤ + (1 - a) * PaperNear.g (1 / m) (m * (1 - a)) := by + have hm0 : 0 < m := by linarith + have hp1 : 0 < m + 1 := by linarith + have hp3 : 0 < m + 3 := by linarith + have hs : 0 < 3 + m * (1 - a) := by positivity + have hc0 : 0 < 3 / (3 + m * (1 - a)) := by positivity + have ha2 : a ^ 2 ≤ 1 := by nlinarith + have hd2 : d ^ 2 ≤ (m * (1 - a) / (3 + m * (1 - a))) ^ 2 := + pow_le_pow_left₀ hd0 hd 2 + have hnum : 12 * m * a ^ 2 * d ^ 2 ≤ + 12 * m * (m * (1 - a) / (3 + m * (1 - a))) ^ 2 := by + have ht : a ^ 2 * d ^ 2 ≤ (m * (1 - a) / (3 + m * (1 - a))) ^ 2 := by + calc + a ^ 2 * d ^ 2 ≤ 1 * d ^ 2 := mul_le_mul_of_nonneg_right ha2 (sq_nonneg d) + _ ≤ (m * (1 - a) / (3 + m * (1 - a))) ^ 2 := by simpa using hd2 + nlinarith only [mul_le_mul_of_nonneg_left ht (show 0 ≤ 12 * m by positivity)] + have hden : (3 / (3 + m * (1 - a))) ^ 4 * (m + 1) * (m + 3) ≤ + c ^ 4 * (m + 1) * (m + 3) := by + exact mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_right (pow_le_pow_left₀ hc0.le hc 4) hp1.le) hp3.le + calc + _ ≤ (12 * m * (m * (1 - a) / (3 + m * (1 - a))) ^ 2) / + ((3 / (3 + m * (1 - a))) ^ 4 * (m + 1) * (m + 3)) := by + exact div_le_div₀ (by positivity) hnum (by positivity) hden + _ = (1 - a) * PaperNear.g (1 / m) (m * (1 - a)) := by + unfold PaperNear.g PaperNear.Q + field_simp + ring + +/-- Both actual Taylor errors satisfy the correlated rational bounds. -/ +theorem parameter_errors {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) : + PaperTaylor.defect a x / (a * ((m : ℝ) - 2)) ≤ + (1 - a) * PaperNear.f (1 / (m : ℝ)) (PaperPolar.lambda m a) ∧ + 12 * (m : ℝ) * a ^ 2 * PaperTaylor.defect a x ^ 2 / + (PaperTaylor.chord a x ^ 4 * ((m : ℝ) + 1) * ((m : ℝ) + 3)) ≤ + (1 - a) * PaperNear.g (1 / (m : ℝ)) (PaperPolar.lambda m a) := by + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + have hb := (PaperPolar.endpoint_bounds hm ha0 ha1 hx0 hx1 hraw).1.trans + (PaperPolar.endpoint_bounds hm ha0 ha1 hx0 hx1 hraw).2 + have hd : PaperTaylor.defect a x ≤ (m : ℝ) * (1 - a) / (3 + (m : ℝ) * (1 - a)) := + (PaperPolar.d_le_b a x).trans hb + have hc : 3 / (3 + (m : ℝ) * (1 - a)) ≤ PaperTaylor.chord a x := by + convert PaperPolar.c_lower_bound hm ha0 ha1 hx0 hx1 hraw using 1 + · rfl + · unfold PaperTaylor.chord PaperPolar.c PaperPolar.b + ring + exact ⟨first_error_le hm' ha0 ha1 hd, + second_error_le hm' ha0 ha1 (PaperTaylor.defect_nonneg ha0.le hx1) hd hc⟩ + +/-- The near-endpoint D theorem for the actual integral budget and raw polar input. -/ +theorem near_endpoint_D {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 2 / 5) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x > + (1 - a) / 1000 := by + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + have hm0 : (0 : ℝ) < m := by linarith + have hp1 : (0 : ℝ) < (m : ℝ) + 1 := by positivity + have hh : 0 < 1 - a := by linarith + have ht0 : (0 : ℝ) ≤ 1 / (m : ℝ) := by positivity + have ht7 : 1 / (m : ℝ) ≤ (1 / 7 : ℝ) := by + exact one_div_le_one_div_of_le (by norm_num) hm' + have hl := PaperPolar.lambda_pos (by omega : 0 < m) ha1 + have hc : 0 < PaperTaylor.chord a x := by + have h := (PaperPolar.geometry hm ha0 ha1 hx0 hx1 hraw).2 + convert h using 1 + unfold PaperTaylor.chord PaperPolar.c PaperPolar.b + ring + have hbudget := PaperTaylor.budget_le hm' ha0 ha1 hx1 hc + have herr := parameter_errors hm ha0 ha1 hx0 hx1 hraw + have hend := (div_lt_iff₀ hh).mp (endpoint_term_lt hm ha0 ha1 hx0 hx1 hraw hnear) + have he : PaperTaylor.beta a x 1 = PaperPolar.b a x := by + simp [PaperTaylor.beta, PaperPolar.b] + rw [he] at hbudget + have hr := mul_lt_mul_of_pos_left + (PaperNear.rational_remainder_gt (1 / (m : ℝ)) (PaperPolar.lambda m a) + ht0 ht7 hl.le hnear) hh + have hbase : 1 - (m : ℝ) * a / ((m : ℝ) + 1) - 1 / ((m : ℝ) + 1) = + (1 - a) * (1 / (1 + 1 / (m : ℝ))) := by + field_simp + ring + nlinarith only [hbudget, herr.1, herr.2, hend, hr, hbase] + +end Sendov.PaperNearClosure diff --git a/Sendov/Analytic/PaperSecant.lean b/Sendov/Analytic/PaperSecant.lean new file mode 100644 index 0000000..d5a1481 --- /dev/null +++ b/Sendov/Analytic/PaperSecant.lean @@ -0,0 +1,390 @@ +import Sendov.Analytic.PaperPolar +import Sendov.Analytic.PaperTaylor +import Mathlib.Analysis.Convex.SpecificFunctions.Basic + +/-! +# Curvature-corrected finite polar secant + +Source: first-origin-uniform/round6/REPORT.md §§2–3. All endpoint formulas +use natural powers, including odd degrees. The gate below is sufficient; +no universal positivity claim is made. +-/ +namespace Sendov.PaperSecant +open MeasureTheory + +noncomputable def R (m : ℕ) (a x : ℝ) : ℝ := + ∫ t in (0 : ℝ)..1, Ppolar a x t ^ ((m : ℝ) / 2) +noncomputable def U1 (m : ℕ) (a : ℝ) : ℝ := + ((a + (1 - a ^ 2)) ^ (m + 1) - a ^ (m + 1)) / (((m : ℝ) + 1) * (1 - a ^ 2)) +noncomputable def U0 (m : ℕ) (a : ℝ) : ℝ := + 2 * (1 - a ^ (m + 2)) / (((m : ℝ) + 2) * (1 - a ^ 2)) +noncomputable def V0 (m : ℕ) (a : ℝ) : ℝ := + U0 m a - (m : ℝ) / 12 * a ^ (m - 2) * (1 - a ^ 2) ^ 2 +noncomputable def S (m : ℕ) (a : ℝ) : ℝ := + a / 2 + (1 - a / 2) * (1 - V0 m a) / (U1 m a - V0 m a) +noncomputable def B (m : ℕ) (a : ℝ) : ℝ := 1 - (m : ℝ) * a / ((m : ℝ) + 1) +noncomputable def Wsec (m : ℕ) (a : ℝ) : ℝ := + 1 / ((m : ℝ) + 1) + (PaperTaylor.beta a (S m a) 1) ^ (m / 2) + + PaperTaylor.defect a (S m a) / (a * ((m : ℝ) - 2)) + + 12 * (m : ℝ) * a ^ 2 * PaperTaylor.defect a (S m a) ^ 2 / + (PaperTaylor.chord a (S m a) ^ 4 * ((m : ℝ) + 1) * ((m : ℝ) + 3)) +noncomputable def Fsec (m : ℕ) (a : ℝ) : ℝ := B m a - Wsec m a + +lemma delta_pos {a : ℝ} (ha : 0 < a) (ha1 : a < 1) : 0 < 1 - a ^ 2 := by + nlinarith + +lemma integrable_R (m : ℕ) (a x : ℝ) : + IntervalIntegrable (fun t => Ppolar a x t ^ ((m : ℝ) / 2)) volume 0 1 := + ((continuous_rpow_const (by positivity : 0 ≤ (m : ℝ) / 2)).comp + (continuous_Ppolar a x)).intervalIntegrable _ _ + +/-- Exact finite upper endpoint, not an exponential replacement. -/ +theorem R_one {m : ℕ} {a : ℝ} (ha : 0 < a) (ha1 : a < 1) : R m a 1 = U1 m a := by + have hd := delta_pos ha ha1 + have heq : ∀ t ∈ Set.uIcc (0 : ℝ) 1, + Ppolar a 1 t ^ ((m : ℝ) / 2) = (a + (1 - a ^ 2) * t) ^ m := by + intro t ht + rw [Set.uIcc_of_le (by norm_num : (0 : ℝ) ≤ 1)] at ht + have hid : Ppolar a 1 t = (a + (1 - a ^ 2) * t) ^ 2 := by unfold Ppolar; ring + rw [hid, PaperTaylor.sq_rpow (add_nonneg ha.le (mul_nonneg hd.le ht.1)), + show 2 * ((m : ℝ) / 2) = m by ring, + Real.rpow_natCast] + unfold R U1 + rw [intervalIntegral.integral_congr heq, + intervalIntegral.integral_comp_add_mul (fun y : ℝ => y ^ m) hd.ne', integral_pow] + simp only [mul_zero, add_zero, mul_one, smul_eq_mul] + rw [mul_comm ((m : ℝ) + 1), ← div_div] + ring + +/-- Exact integral of the chord at `x = a/2`. -/ +theorem integral_chord {m : ℕ} {a : ℝ} (ha : 0 < a) (ha1 : a < 1) : + (∫ t in (0 : ℝ)..1, (a ^ 2 + (1 - a ^ 2) * t) ^ ((m : ℝ) / 2)) = U0 m a := by + have hd := delta_pos ha ha1 + rw [intervalIntegral.integral_comp_add_mul (fun y : ℝ => y ^ ((m : ℝ) / 2)) hd.ne', + integral_rpow (Or.inl (by have := Nat.cast_nonneg (α := ℝ) m; linarith : -1 < (m : ℝ) / 2))] + simp only [mul_zero, add_zero, mul_one, smul_eq_mul] + rw [show a ^ 2 + (1 - a ^ 2) = 1 by ring, Real.one_rpow, + PaperTaylor.sq_rpow ha.le, show 2 * ((m : ℝ) / 2 + 1) = ((m + 2 : ℕ) : ℝ) by push_cast; ring, + Real.rpow_natCast] + unfold U0 + field_simp + +/-- A derivative lower bound valid uniformly above a positive base. -/ +lemma rpow_sub_lower {p q v w : ℝ} (hp : 1 ≤ p) (hq : 0 < q) + (hqv : q ≤ v) (hvw : v ≤ w) : + p * q ^ (p - 1) * (w - v) ≤ w ^ p - v ^ p := by + let f := fun z : ℝ => z ^ p - p * q ^ (p - 1) * z + have hf : ∀ z ∈ Set.Icc v w, HasDerivAt f + (p * z ^ (p - 1) - p * q ^ (p - 1)) z := by + intro z hz + convert! (Real.hasDerivAt_rpow_const (p := p) + (Or.inl (ne_of_gt (by linarith [hz.1] : 0 < z)))).sub + ((hasDerivAt_id z).const_mul (p * q ^ (p - 1))) using 1 + simp + have hmono : MonotoneOn f (Set.Icc v w) := by + apply monotoneOn_of_hasDerivWithinAt_nonneg (convex_Icc _ _) + · exact fun z hz => (hf z hz).continuousAt.continuousWithinAt + · exact fun z hz => (hf z (interior_subset hz)).hasDerivWithinAt + · intro z hz + have hz' := interior_subset hz + have hpow := Real.rpow_le_rpow hq.le (hqv.trans hz'.1) (by linarith : 0 ≤ p - 1) + exact sub_nonneg.mpr (mul_le_mul_of_nonneg_left hpow (by linarith)) + have h := hmono (Set.left_mem_Icc.mpr hvw) (Set.right_mem_Icc.mpr hvw) hvw + dsimp [f] at h + nlinarith + +lemma kernel_half (a t : ℝ) : + Ppolar a (a / 2) t = (a ^ 2 + (1 - a ^ 2) * t) - (1 - a ^ 2) ^ 2 * t * (1 - t) := by + unfold Ppolar + ring + +lemma kernel_half_ge {a t : ℝ} (ha : 0 < a) (ha1 : a < 1) (ht : 0 ≤ t) : + a ^ 2 ≤ Ppolar a (a / 2) t := by + have hd := delta_pos ha ha1 + have h : 0 ≤ a ^ 2 * t * (1 - a ^ 2) + t ^ 2 * (1 - a ^ 2) ^ 2 := by positivity + unfold Ppolar + nlinarith + +/-- The actual pointwise curvature subtraction from the chord. -/ +theorem curvature_pointwise {m : ℕ} {a t : ℝ} (hm : 2 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (ht : t ∈ Set.Icc (0 : ℝ) 1) : + Ppolar a (a / 2) t ^ ((m : ℝ) / 2) ≤ + (a ^ 2 + (1 - a ^ 2) * t) ^ ((m : ℝ) / 2) - + ((m : ℝ) / 2 * a ^ (m - 2) * (1 - a ^ 2) ^ 2) * (t * (1 - t)) := by + have hm' : (2 : ℝ) ≤ m := by exact_mod_cast hm + have hq := kernel_half_ge ha ha1 ht.1 + have hgap : 0 ≤ (1 - a ^ 2) ^ 2 * t * (1 - t) := + mul_nonneg (mul_nonneg (sq_nonneg _) ht.1) (sub_nonneg.mpr ht.2) + have hvw : Ppolar a (a / 2) t ≤ a ^ 2 + (1 - a ^ 2) * t := by rw [kernel_half]; linarith + have h := rpow_sub_lower (by linarith : 1 ≤ (m : ℝ) / 2) (sq_pos_of_pos ha) hq hvw + rw [PaperTaylor.sq_rpow ha.le, + show 2 * ((m : ℝ) / 2 - 1) = ((m - 2 : ℕ) : ℝ) by rw [Nat.cast_sub hm]; push_cast; ring, + Real.rpow_natCast, kernel_half] at h + rw [kernel_half] + nlinarith + +lemma integral_bubble : (∫ t in (0 : ℝ)..1, t * (1 - t)) = 1 / 6 := by + have hid : (fun t : ℝ => t * (1 - t)) = fun t => t ^ 1 - t ^ 2 := by funext t; ring + rw [hid, intervalIntegral.integral_sub ((continuous_pow 1).intervalIntegrable _ _) + ((continuous_pow 2).intervalIntegrable _ _), integral_pow, integral_pow] + norm_num + +/-- Integrated curvature correction with explicit finite coefficient. -/ +theorem R_half_le_V0 {m : ℕ} {a : ℝ} (hm : 2 ≤ m) (ha : 0 < a) (ha1 : a < 1) : + R m a (a / 2) ≤ V0 m a := by + have hi : IntervalIntegrable + (fun t : ℝ => (a ^ 2 + (1 - a ^ 2) * t) ^ ((m : ℝ) / 2)) volume 0 1 := + ((continuous_rpow_const (by positivity : 0 ≤ (m : ℝ) / 2)).comp + (by fun_prop)).intervalIntegrable _ _ + have hb : IntervalIntegrable (fun t : ℝ => t * (1 - t)) volume 0 1 := + (by fun_prop : Continuous _).intervalIntegrable _ _ + have h := intervalIntegral.integral_mono_on (by norm_num : (0 : ℝ) ≤ 1) + (integrable_R m a (a / 2)) (hi.sub (hb.const_mul _)) + (fun t ht => curvature_pointwise hm ha ha1 ht) + rw [intervalIntegral.integral_sub hi (hb.const_mul _), intervalIntegral.integral_const_mul, + integral_chord ha ha1, integral_bubble] at h + unfold R V0 + convert h using 1 + ring + +/-- The chord integral is already strictly below one. -/ +theorem U0_lt_one {m : ℕ} {a : ℝ} (hm : 2 ≤ m) (ha : 0 < a) (ha1 : a < 1) : U0 m a < 1 := by + have hd := delta_pos ha ha1 + have hm' : (2 : ℝ) ≤ m := by exact_mod_cast hm + have hc : Continuous (fun t : ℝ => a ^ 2 + (1 - a ^ 2) * t) := by fun_prop + have h := intervalIntegral.integral_mono_on (by norm_num : (0 : ℝ) ≤ 1) + (((continuous_rpow_const (by positivity : 0 ≤ (m : ℝ) / 2)).comp hc).intervalIntegrable 0 1) + (hc.intervalIntegrable 0 1 (μ := volume)) (fun t ht => Real.rpow_le_self_of_le_one + (add_nonneg (sq_nonneg _) (mul_nonneg hd.le ht.1)) + (by nlinarith [mul_nonneg hd.le (sub_nonneg.mpr ht.2)] : a ^ 2 + (1 - a ^ 2) * t ≤ 1) + (by linarith : 1 ≤ (m : ℝ) / 2)) + simp only [Function.comp_apply] at h + rw [integral_chord ha ha1] at h + have he : (∫ t in (0 : ℝ)..1, a ^ 2 + (1 - a ^ 2) * t) = (1 + a ^ 2) / 2 := by + have hi : IntervalIntegrable (fun t : ℝ => (1 - a ^ 2) * t) volume 0 1 := + (by fun_prop : Continuous (fun t : ℝ => (1 - a ^ 2) * t)).intervalIntegrable _ _ + rw [intervalIntegral.integral_add (intervalIntegrable_const (c := a ^ 2)) hi, + intervalIntegral.integral_const, intervalIntegral.integral_const_mul, integral_id] + norm_num + ring + rw [he] at h + nlinarith + +lemma V0_lt_one {m : ℕ} {a : ℝ} (hm : 2 ≤ m) (ha : 0 < a) (ha1 : a < 1) : V0 m a < 1 := by + have h := U0_lt_one hm ha ha1 + have hsub : 0 ≤ (m : ℝ) / 12 * a ^ (m - 2) * (1 - a ^ 2) ^ 2 := by positivity + unfold V0 + linarith + +/-- Positive lower endpoint, hence the corrected upper endpoint is positive too. -/ +lemma R_half_pos {m : ℕ} {a : ℝ} (ha : 0 < a) (ha1 : a < 1) : 0 < R m a (a / 2) := by + have h := intervalIntegral.integral_mono_on (by norm_num : (0 : ℝ) ≤ 1) + (intervalIntegrable_const (c := (a ^ 2) ^ ((m : ℝ) / 2))) + (integrable_R m a (a / 2)) (fun t ht => Real.rpow_le_rpow (sq_nonneg a) + (kernel_half_ge ha ha1 ht.1) (by positivity : 0 ≤ (m : ℝ) / 2)) + simp only [intervalIntegral.integral_const, sub_zero, smul_eq_mul, one_mul] at h + exact (Real.rpow_pos_of_pos (sq_pos_of_pos ha) _).trans_le h + +lemma V0_pos {m : ℕ} {a : ℝ} (hm : 2 ≤ m) (ha : 0 < a) (ha1 : a < 1) : 0 < V0 m a := + (R_half_pos ha ha1).trans_le (R_half_le_V0 hm ha ha1) + +/-- Monotonicity of the actual raw integral on its full feasible interval. -/ +theorem R_mono {m : ℕ} {a x y : ℝ} (ha : 0 < a) (ha1 : a < 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hxy : x ≤ y) : R m a x ≤ R m a y := by + have hd := delta_pos ha ha1 + refine intervalIntegral.integral_mono_on (by norm_num) (integrable_R m a x) + (integrable_R m a y) ?_ + intro t ht + apply Real.rpow_le_rpow (Ppolar_nonneg (PaperPolar.x_sq_le_one hx0 hx1) a t) _ (by positivity) + have h := mul_nonneg (mul_nonneg (mul_nonneg (by positivity : 0 ≤ 2 * a) ht.1) hd.le) + (sub_nonneg.mpr hxy) + unfold Ppolar + nlinarith + +/-- `U1 < 1` excludes every raw-polar feasible mean. -/ +theorem one_le_U1 {m : ℕ} {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hraw : PaperPolar.RawPolar m a x) : 1 ≤ U1 m a := by + have h := ((PaperPolar.rawPolar_iff m a x).mp hraw).trans (R_mono ha ha1 hx0 hx1 hx1) + rwa [R_one ha ha1] at h + +/-- Convexity is proved pointwise from the affine kernel and integrated. -/ +theorem R_secant {m : ℕ} {a θ : ℝ} (hm : 2 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hθ0 : 0 ≤ θ) (hθ1 : θ ≤ 1) : + R m a ((1 - θ) * (a / 2) + θ * 1) ≤ (1 - θ) * V0 m a + θ * U1 m a := by + have hm' : (2 : ℝ) ≤ m := by exact_mod_cast hm + have hp : 1 ≤ (m : ℝ) / 2 := by linarith + have hpoint : ∀ t ∈ Set.Icc (0 : ℝ) 1, + Ppolar a ((1 - θ) * (a / 2) + θ * 1) t ^ ((m : ℝ) / 2) ≤ + (1 - θ) * Ppolar a (a / 2) t ^ ((m : ℝ) / 2) + θ * Ppolar a 1 t ^ ((m : ℝ) / 2) := by + intro t ht + have h0 : 0 ≤ Ppolar a (a / 2) t := (sq_nonneg a).trans (kernel_half_ge ha ha1 ht.1) + have h1 : 0 ≤ Ppolar a 1 t := Ppolar_nonneg (by norm_num) a t + have h := (convexOn_rpow hp).2 h0 h1 (sub_nonneg.mpr hθ1) hθ0 (by ring : 1 - θ + θ = 1) + simp only [smul_eq_mul] at h + have hid : Ppolar a ((1 - θ) * (a / 2) + θ * 1) t = + (1 - θ) * Ppolar a (a / 2) t + θ * Ppolar a 1 t := by unfold Ppolar; ring + rwa [hid] + have h := intervalIntegral.integral_mono_on (by norm_num : (0 : ℝ) ≤ 1) + (integrable_R m a _) (((integrable_R m a (a / 2)).const_mul (1 - θ)).add + ((integrable_R m a 1).const_mul θ)) hpoint + rw [intervalIntegral.integral_add ((integrable_R m a (a / 2)).const_mul (1 - θ)) + ((integrable_R m a 1).const_mul θ), intervalIntegral.integral_const_mul, + intervalIntegral.integral_const_mul] at h + change R m a _ ≤ (1 - θ) * R m a (a / 2) + θ * R m a 1 at h + rw [R_one ha ha1] at h + exact h.trans (add_le_add + (mul_le_mul_of_nonneg_left (R_half_le_V0 hm ha ha1) (sub_nonneg.mpr hθ1)) le_rfl) + +/-- All denominators in the secant are strictly positive. -/ +lemma secant_den_pos {m : ℕ} {a : ℝ} (hm : 2 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hu : 1 ≤ U1 m a) : 0 < U1 m a - V0 m a := by + have hv := V0_lt_one hm ha ha1 + linarith + +lemma S_bounds {m : ℕ} {a : ℝ} (hm : 2 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hu : 1 ≤ U1 m a) : a / 2 < S m a ∧ S m a ≤ 1 := by + have hv := V0_lt_one hm ha ha1 + have hd := secant_den_pos hm ha ha1 hu + have hleft : 0 < (1 - a / 2) * (1 - V0 m a) / (U1 m a - V0 m a) := by + apply div_pos _ hd + exact mul_pos (by linarith) (by linarith) + have hright : (1 - a / 2) * (1 - V0 m a) / (U1 m a - V0 m a) ≤ 1 - a / 2 := by + apply (div_le_iff₀ hd).2 + nlinarith [mul_nonneg (show 0 ≤ 1 - a / 2 by linarith) (sub_nonneg.mpr hu)] + unfold S + constructor <;> linarith + +lemma V0_le_U0 (m : ℕ) {a : ℝ} (ha : 0 ≤ a) : V0 m a ≤ U0 m a := by + have h : 0 ≤ (m : ℝ) / 12 * a ^ (m - 2) * (1 - a ^ 2) ^ 2 := by positivity + unfold V0 + linarith + +/-- Retaining curvature can only improve the plain endpoint secant. -/ +theorem plain_secant_le_S {m : ℕ} {a : ℝ} (hm : 2 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hu : 1 ≤ U1 m a) : + a / 2 + (1 - a / 2) * (1 - U0 m a) / (U1 m a - U0 m a) ≤ S m a := by + have hvu := V0_le_U0 m ha.le + have hu0 := U0_lt_one hm ha ha1 + have hd0 : 0 < U1 m a - U0 m a := by linarith + have hdv := secant_den_pos hm ha ha1 hu + have hf : (1 - U0 m a) / (U1 m a - U0 m a) ≤ + (1 - V0 m a) / (U1 m a - V0 m a) := by + apply (div_le_div_iff₀ hd0 hdv).2 + nlinarith [mul_nonneg (sub_nonneg.mpr hu) (sub_nonneg.mpr hvu)] + have h := mul_le_mul_of_nonneg_left hf (show 0 ≤ 1 - a / 2 by linarith) + unfold S + simp only [mul_div_assoc] + exact add_le_add le_rfl h + +/-- Positivity of both Taylor-gate denominators follows from the finite secant. -/ +lemma gate_denominators_pos {m : ℕ} {a : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hu : 1 ≤ U1 m a) : + 0 < a * ((m : ℝ) - 2) ∧ + 0 < PaperTaylor.chord a (S m a) ^ 4 * ((m : ℝ) + 1) * ((m : ℝ) + 3) := by + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + have hs := (S_bounds (by omega : 2 ≤ m) ha ha1 hu).1 + have hc : 0 < PaperTaylor.chord a (S m a) := by + unfold PaperTaylor.chord + exact mul_pos ha (by linarith) + constructor + · exact mul_pos ha (by linarith) + · positivity + +/-- The curvature-corrected analytic lower bound follows from raw polar alone. -/ +theorem raw_implies_secant {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hraw : PaperPolar.RawPolar m a x) : S m a ≤ x := by + have hx := (PaperPolar.geometry hm ha ha1 hx0 hx1 hraw).1 + have hu := one_le_U1 ha ha1 hx0 hx1 hraw + have hd := secant_den_pos (by omega : 2 ≤ m) ha ha1 hu + have he : 0 < 1 - a / 2 := by linarith + let θ := (x - a / 2) / (1 - a / 2) + have hθ0 : 0 ≤ θ := div_nonneg (by linarith) he.le + have hθ1 : θ ≤ 1 := (div_le_one he).2 (by linarith) + have hid : (1 - θ) * (a / 2) + θ * 1 = x := by + dsimp [θ] + field_simp [show 2 - a ≠ 0 by linarith] + ring + have h := R_secant (by omega : 2 ≤ m) ha ha1 hθ0 hθ1 + rw [hid] at h + have hr : 1 ≤ R m a x := (PaperPolar.rawPolar_iff m a x).mp hraw + have hnum : 1 - V0 m a ≤ θ * (U1 m a - V0 m a) := by nlinarith + have hratio : (1 - V0 m a) / (U1 m a - V0 m a) ≤ θ := (div_le_iff₀ hd).2 hnum + have hmul := mul_le_mul_of_nonneg_left hratio he.le + have hid2 : (1 - a / 2) * θ = x - a / 2 := by + dsimp [θ] + exact mul_div_cancel₀ _ he.ne' + rw [hid2] at hmul + unfold S + rw [mul_div_assoc] + linarith + +/-- The alternative finite endpoint form in the report. -/ +lemma S_eq_one_sub {m : ℕ} {a : ℝ} (hd : U1 m a - V0 m a ≠ 0) : + S m a = 1 - (1 - a / 2) * (U1 m a - 1) / (U1 m a - V0 m a) := by + unfold S + field_simp + ring + +/-- The actual origin budget is antitone in the mean; no budget surrogate is assumed. -/ +theorem budget_antitone {m a x y : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hxy : x ≤ y) (hy : y ≤ 1) : PaperTaylor.budget m a y ≤ PaperTaylor.budget m a x := by + have hx : x ≤ 1 := hxy.trans hy + have hβ : ∀ t ∈ Set.Icc (0 : ℝ) 1, PaperTaylor.beta a y t ≤ PaperTaylor.beta a x t := by + intro t ht + have h := mul_nonneg (mul_nonneg (show 0 ≤ 2 * a by positivity) ht.1) (sub_nonneg.mpr hxy) + unfold PaperTaylor.beta + nlinarith + have he := Real.rpow_le_rpow (PaperTaylor.beta_pos ha ha1 hy (t := 1) (by norm_num)).le + (hβ 1 (by norm_num)) (by linarith : 0 ≤ m / 2) + have hc : ∀ z : ℝ, Continuous (fun t : ℝ => t * PaperTaylor.beta a z t ^ ((m - 1) / 2)) := by + intro z + exact continuous_id.mul ((continuous_rpow_const (by linarith : 0 ≤ (m - 1) / 2)).comp + (by unfold PaperTaylor.beta; fun_prop)) + have hi := intervalIntegral.integral_mono_on (by norm_num : (0 : ℝ) ≤ 1) + ((hc y).intervalIntegrable 0 1 (μ := volume)) ((hc x).intervalIntegrable 0 1) (fun t ht => + mul_le_mul_of_nonneg_left (Real.rpow_le_rpow (PaperTaylor.beta_pos ha ha1 hy ht).le + (hβ t ht) (by linarith : 0 ≤ (m - 1) / 2)) ht.1) + have hmul := mul_le_mul_of_nonneg_left hi (show 0 ≤ m * a ^ 2 by positivity) + unfold PaperTaylor.budget + linarith + +/-- Odd degrees are rounded down in the exponent, never evaluated by a rational square root. -/ +lemma endpoint_pow_le {m : ℕ} {b : ℝ} (hb : 0 < b) (hb1 : b ≤ 1) : + b ^ ((m : ℝ) / 2) ≤ b ^ (m / 2) := by + rw [← Real.rpow_natCast] + apply Real.rpow_le_rpow_of_exponent_ge hb hb1 + have hn : m / 2 * 2 ≤ m := Nat.div_mul_le_self m 2 + have hn' : ((m / 2 : ℕ) : ℝ) * 2 ≤ m := by exact_mod_cast hn + linarith + +/-- The rational gate majorizes the actual origin budget at the secant. -/ +theorem budget_S_le_Wsec {m : ℕ} {a : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hu : 1 ≤ U1 m a) : PaperTaylor.budget m a (S m a) ≤ Wsec m a := by + have hs := S_bounds (by omega : 2 ≤ m) ha ha1 hu + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + have hc : 0 < PaperTaylor.chord a (S m a) := by + unfold PaperTaylor.chord + exact mul_pos ha (by linarith [hs.1]) + have hb := PaperTaylor.beta_pos ha ha1 hs.2 (t := 1) (by norm_num) + have hb1 : PaperTaylor.beta a (S m a) 1 ≤ 1 := by + rw [PaperTaylor.chord_eq_one_sub_beta] at hc + linarith + have ht := PaperTaylor.budget_le hm' ha ha1 hs.2 hc + have hp := endpoint_pow_le (m := m) hb hb1 + unfold Wsec + linarith + +/-- `Fsec > 0` is a sufficient condition for D for every raw-polar feasible mean. +There is no hypothesis assuming an integral secant, and no assertion that this +finite rational function is positive everywhere. -/ +theorem gate_implies_D {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hraw : PaperPolar.RawPolar m a x) + (hgate : 0 < Fsec m a) : PaperTaylor.budget m a x < B m a := by + have hu := one_le_U1 ha ha1 hx0 hx1 hraw + have hs := raw_implies_secant hm ha ha1 hx0 hx1 hraw + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + have ht := (budget_antitone hm' ha ha1 hs hx1).trans (budget_S_le_Wsec hm ha ha1 hu) + unfold Fsec at hgate + linarith + +end Sendov.PaperSecant diff --git a/Sendov/Analytic/PaperTwoEnd.lean b/Sendov/Analytic/PaperTwoEnd.lean new file mode 100644 index 0000000..80e4a5f --- /dev/null +++ b/Sendov/Analytic/PaperTwoEnd.lean @@ -0,0 +1,380 @@ +import Sendov.Analytic.PaperTaylor + +/-! +# Scale-adapted two-endpoint bounds for the actual origin integral + +The exponent is always `(m - 1) / 2`, including in the middle-interval +exponential bound. Parameters are real; no integrality assumption is needed. +Source: first-origin-uniform/round4/REPORT.md §2 and round5/REPORT.md §3. +-/ + +namespace Sendov.PaperTwoEnd + +open MeasureTheory + +noncomputable def Q (x u : ℝ) : ℝ := 1 - 2 * x * u + u ^ 2 +noncomputable def endpoint (m a x : ℝ) : ℝ := Q x a ^ (m / 2) +noncomputable def total (m a x : ℝ) : ℝ := + endpoint m a x + m * ∫ u in (0 : ℝ)..a, u * Q x u ^ ((m - 1) / 2) + +lemma Q_beta (a x t : ℝ) : Q x (a * t) = PaperTaylor.beta a x t := by + unfold Q PaperTaylor.beta + ring + +/-- Actual affine substitution `u = a*t`, including the Jacobian and weight. -/ +theorem total_eq_budget {m a x : ℝ} (ha : 0 < a) : + total m a x = PaperTaylor.budget m a x := by + have h := intervalIntegral.integral_comp_mul_left (a := (0 : ℝ)) (b := 1) + (fun u : ℝ => u * Q x u ^ ((m - 1) / 2)) ha.ne' + simp only [mul_zero, mul_one, smul_eq_mul] at h + have heq : (fun t : ℝ => a * t * Q x (a * t) ^ ((m - 1) / 2)) = + (fun t : ℝ => a * (t * PaperTaylor.beta a x t ^ ((m - 1) / 2))) := by + funext t + rw [Q_beta] + ring + rw [heq, intervalIntegral.integral_const_mul] at h + have h' : (∫ u in (0 : ℝ)..a, u * Q x u ^ ((m - 1) / 2)) = + a ^ 2 * ∫ t in (0 : ℝ)..1, t * PaperTaylor.beta a x t ^ ((m - 1) / 2) := by + calc + _ = a * (a⁻¹ * ∫ u in (0 : ℝ)..a, u * Q x u ^ ((m - 1) / 2)) := by + rw [← mul_assoc, mul_inv_cancel₀ ha.ne', one_mul] + _ = _ := by rw [← h]; ring + unfold total endpoint PaperTaylor.budget + rw [h', ← Q_beta] + simp only [mul_one] + ring + +lemma Q_nonneg {x : ℝ} (hx0 : 0 ≤ x) (hx1 : x ≤ 1) (u : ℝ) : 0 ≤ Q x u := by + have hx2 : x ^ 2 ≤ 1 := by nlinarith + unfold Q + nlinarith [sq_nonneg (u - x)] + +lemma Q_pos {a x u : ℝ} (ha1 : a < 1) (hx1 : x ≤ 1) + (hu : u ∈ Set.Icc (0 : ℝ) a) : 0 < Q x u := by + have : 0 ≤ 2 * u * (1 - x) := mul_nonneg (mul_nonneg (by norm_num) hu.1) + (sub_nonneg.mpr hx1) + unfold Q + nlinarith [sq_pos_of_pos (show 0 < 1 - u by linarith [hu.2])] + +lemma continuous_weight {p : ℝ} (hp : 0 ≤ p) (x : ℝ) : + Continuous (fun u : ℝ => u * Q x u ^ p) := + continuous_id.mul ((continuous_rpow_const hp).comp (by unfold Q; fun_prop)) + +/-- The left quadratic is dominated by a linear chord, extended only to its zero. -/ +lemma integral_left_le {p x s : ℝ} (hp : 0 < p) (hx : 0 < x) (hx1 : x ≤ 1) + (hs : 0 ≤ s) (hsx : s ≤ x) : + (∫ u in (0 : ℝ)..s, u * Q x u ^ p) ≤ + 1 / (x ^ 2 * ((p + 1) * (p + 2))) := by + have hc : Continuous (fun u : ℝ => u * (1 - x * u) ^ p) := + continuous_id.mul ((continuous_rpow_const hp.le).comp (by fun_prop)) + have hsz : s ≤ 1 / x := by + apply (le_div_iff₀ hx).mpr + nlinarith [mul_le_mul_of_nonneg_right hsx hx.le] + have hle : (∫ u in (0 : ℝ)..s, u * Q x u ^ p) ≤ + ∫ u in (0 : ℝ)..s, u * (1 - x * u) ^ p := by + apply intervalIntegral.integral_mono_on hs ((continuous_weight hp.le x).intervalIntegrable _ _) + (hc.intervalIntegrable _ _) + intro u hu + apply mul_le_mul_of_nonneg_left _ hu.1 + apply Real.rpow_le_rpow (Q_nonneg hx.le hx1 u) _ hp.le + have := mul_nonneg hu.1 (show 0 ≤ x - u by linarith [hu.2]) + unfold Q + nlinarith + have hrest : 0 ≤ ∫ u in s..1 / x, u * (1 - x * u) ^ p := by + apply intervalIntegral.integral_nonneg hsz + intro u hu + have := (le_div_iff₀ hx).mp hu.2 + exact mul_nonneg (by linarith [hu.1]) (Real.rpow_nonneg (by nlinarith) _) + have hadd := intervalIntegral.integral_add_adjacent_intervals (μ := volume) + (hc.intervalIntegrable 0 s) (hc.intervalIntegrable s (1 / x)) + rw [integral_chord_lin hp hx] at hadd + linarith + +/-- The sharp rational left bound, before the strict `4/(m*x²)` simplification. -/ +theorem left_le {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (hx : 0 < x) (hx1 : x ≤ 1) : + m * (∫ u in (0 : ℝ)..min a x, u * Q x u ^ ((m - 1) / 2)) ≤ + 4 * m / ((m + 1) * (m + 3) * x ^ 2) := by + have h := mul_le_mul_of_nonneg_left + (integral_left_le (p := (m - 1) / 2) (by linarith) hx hx1 + (le_min ha.le hx.le) (min_le_right a x)) (show 0 ≤ m by linarith) + have heq : 4 * m / ((m + 1) * (m + 3) * x ^ 2) = + m * (1 / (x ^ 2 * (((m - 1) / 2 + 1) * ((m - 1) / 2 + 2)))) := by + rw [show ((m - 1) / 2 + 1) * ((m - 1) / 2 + 2) = (m + 1) * (m + 3) / 4 by ring] + field_simp + rw [heq] + exact h + +theorem left_lt {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (hx : 0 < x) (hx1 : x ≤ 1) : + m * (∫ u in (0 : ℝ)..min a x, u * Q x u ^ ((m - 1) / 2)) < + 4 / (m * x ^ 2) := by + apply (left_le hm ha hx hx1).trans_lt + have hm0 : 0 < m := by linarith + apply (div_lt_div_iff₀ (by positivity) (by positivity)).mpr + nlinarith [sq_pos_of_pos hx, mul_pos (sq_pos_of_pos hx) (show 0 < 4 * m + 3 by linarith)] + +/-- If the vertex is outside the integration interval there is no right tail. -/ +theorem total_lt_left_endpoint {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) + (hx : 0 < x) (hx1 : x ≤ 1) (hax : a ≤ x) : + total m a x < 4 / (m * x ^ 2) + endpoint m a x := by + have h := left_lt hm ha hx hx1 + rw [min_eq_left hax] at h + unfold total + linarith + +/-- Exact split at the quadratic's vertex. -/ +lemma total_split {m a x : ℝ} (hm : 7 ≤ m) : + total m a x = endpoint m a x + + m * (∫ u in (0 : ℝ)..x, u * Q x u ^ ((m - 1) / 2)) + + m * (∫ u in x..a, u * Q x u ^ ((m - 1) / 2)) := by + have hc := continuous_weight (x := x) (show 0 ≤ (m - 1) / 2 by linarith) + have h := intervalIntegral.integral_add_adjacent_intervals (μ := volume) + (hc.intervalIntegrable 0 x) (hc.intervalIntegrable x a) + unfold total + rw [← h] + ring + +/-- On the right side of the vertex the quadratic is bounded by its right endpoint. -/ +lemma Q_le_endpoint {a x u : ℝ} (hxa : x ≤ a) (hu : u ∈ Set.Icc x a) : + Q x u ≤ Q x a := by + have := mul_nonneg (sub_nonneg.mpr hu.2) (show 0 ≤ a + u - 2 * x by linarith [hu.1]) + unfold Q + nlinarith + +lemma integral_right_le_endpoint {p a x : ℝ} (hp : 0 ≤ p) (hx : 0 ≤ x) + (hx1 : x ≤ 1) (hxa : x ≤ a) : + (∫ u in x..a, u * Q x u ^ p) ≤ Q x a ^ p * ((a ^ 2 - x ^ 2) / 2) := by + have hle : (∫ u in x..a, u * Q x u ^ p) ≤ ∫ u in x..a, Q x a ^ p * u := by + apply intervalIntegral.integral_mono_on hxa ((continuous_weight hp x).intervalIntegrable _ _) + ((by fun_prop : Continuous (fun u : ℝ => Q x a ^ p * u)).intervalIntegrable _ _) + intro u hu + rw [mul_comm (Q x a ^ p) u] + exact mul_le_mul_of_nonneg_left + (Real.rpow_le_rpow (Q_nonneg hx hx1 u) (Q_le_endpoint hxa hu) hp) + (show 0 ≤ u by linarith [hu.1]) + rw [intervalIntegral.integral_const_mul, integral_id] at hle + exact hle + +lemma endpoint_le_power {m a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx1 : x ≤ 1) + (hc : 0 < PaperTaylor.chord a x) : endpoint m a x ≤ Q x a ^ ((m - 1) / 2) := by + apply Real.rpow_le_rpow_of_exponent_ge (Q_pos ha1 hx1 ⟨ha.le, le_rfl⟩) + · unfold PaperTaylor.chord at hc + unfold Q + nlinarith + · linarith + +/-- Unrelaxed exponent: this statement also applies at `m = 7,8`. -/ +theorem total_lt_middle {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : 0 < x) (hx1 : x ≤ 1) (hxa : x < a) (hax : a < 3 * x / 2) : + total m a x < 4 / (m * x ^ 2) + + (1 + 5 * m * x ^ 2 / 8) * Real.exp (-3 * (m - 1) * x ^ 2 / 8) := by + have hp : 0 ≤ (m - 1) / 2 := by linarith + have hm0 : 0 ≤ m := by linarith + have hb : 0 < Q x a := Q_pos ha1 hx1 ⟨ha.le, le_rfl⟩ + have hbnd : Q x a ≤ 1 - 3 * x ^ 2 / 4 := by + have := mul_nonneg (show 0 ≤ a - x by linarith) (show 0 ≤ 3 * x / 2 - a by linarith) + have := sq_nonneg (a - x) + unfold Q + nlinarith [sq_nonneg x] + have hc : 0 < PaperTaylor.chord a x := by + unfold PaperTaylor.chord + apply mul_pos ha + linarith + have hexp : Q x a ^ ((m - 1) / 2) ≤ Real.exp (-3 * (m - 1) * x ^ 2 / 8) := by + rw [Real.rpow_def_of_pos hb] + apply Real.exp_le_exp.mpr + have hlog := Real.log_le_sub_one_of_pos hb + have := mul_le_mul_of_nonneg_right (hlog.trans (by linarith : Q x a - 1 ≤ -3 * x ^ 2 / 4)) hp + nlinarith + have hmass : (a ^ 2 - x ^ 2) / 2 ≤ 5 * x ^ 2 / 8 := by + nlinarith [mul_nonneg (show 0 ≤ 3 * x / 2 - a by linarith) + (show 0 ≤ 3 * x / 2 + a by positivity)] + have hr := integral_right_le_endpoint hp hx.le hx1 hxa.le + have hr' : m * (∫ u in x..a, u * Q x u ^ ((m - 1) / 2)) ≤ + (5 * m * x ^ 2 / 8) * Real.exp (-3 * (m - 1) * x ^ 2 / 8) := by + have h1 := mul_le_mul_of_nonneg_right hexp (show 0 ≤ (a ^ 2 - x ^ 2) / 2 by + nlinarith [mul_nonneg (sub_nonneg.mpr hxa.le) (show 0 ≤ a + x by positivity)]) + have h2 := mul_le_mul_of_nonneg_left hmass (Real.exp_pos (-3 * (m - 1) * x ^ 2 / 8)).le + have h3 := mul_le_mul_of_nonneg_left (hr.trans (h1.trans h2)) hm0 + calc + _ ≤ m * (Real.exp (-3 * (m - 1) * x ^ 2 / 8) * (5 * x ^ 2 / 8)) := h3 + _ = _ := by ring + have he := (endpoint_le_power ha ha1 hx1 hc).trans hexp + have hl := left_lt hm ha hx hx1 + rw [min_eq_right hxa.le] at hl + rw [total_split hm] + nlinarith + +/-- The weighted half of the right-tail integral, evaluated by a genuine primitive. -/ +lemma integral_right_weight {p a x : ℝ} (hp : 0 ≤ p) : + (∫ u in x..a, (u - x) * Q x u ^ p) = + (Q x a ^ (p + 1) - Q x x ^ (p + 1)) / (2 * (p + 1)) := by + have hp1 : p + 1 ≠ 0 := by linarith + have hd : ∀ u : ℝ, HasDerivAt (fun u : ℝ => Q x u ^ (p + 1) / (2 * (p + 1))) + ((u - x) * Q x u ^ p) u := by + intro u + have hq : HasDerivAt (fun u : ℝ => Q x u) (2 * (u - x)) u := by + unfold Q + convert! ((hasDerivAt_const u 1).sub ((hasDerivAt_id u).const_mul (2 * x))).add + ((hasDerivAt_id u).pow 2) using 1 + simp only [id_eq] + ring + have h := (hq.rpow_const (p := p + 1) (Or.inr (by linarith))).div_const (2 * (p + 1)) + convert! h using 1 + rw [show p + 1 - 1 = p by ring] + field_simp + have hc : Continuous (fun u : ℝ => (u - x) * Q x u ^ p) := + (continuous_id.sub continuous_const).mul + ((continuous_rpow_const hp).comp (by unfold Q; fun_prop)) + have h := intervalIntegral.integral_eq_sub_of_hasDerivAt (fun u _ => hd u) + (hc.intervalIntegrable x a) + rw [h] + ring + +/-- Exact affine-power integral used for the secant majorant on the right. -/ +lemma integral_affine_power {p v l : ℝ} (hp : 0 ≤ p) (hl : 0 < l) : + (∫ w in (0 : ℝ)..l, (v + l * w) ^ p) = + ((v + l ^ 2) ^ (p + 1) - v ^ (p + 1)) / (l * (p + 1)) := by + have hp1 : p + 1 ≠ 0 := by linarith + have hd : ∀ w : ℝ, HasDerivAt (fun w : ℝ => (v + l * w) ^ (p + 1) / (l * (p + 1))) + ((v + l * w) ^ p) w := by + intro w + have h := (((hasDerivAt_id w).const_mul l).const_add v).rpow_const + (p := p + 1) (Or.inr (by linarith)) + convert! h.div_const (l * (p + 1)) using 1 + rw [show p + 1 - 1 = p by ring] + simp only [id_eq, mul_one] + field_simp + have hc : Continuous (fun w : ℝ => (v + l * w) ^ p) := + (continuous_rpow_const hp).comp (by fun_prop) + have h := intervalIntegral.integral_eq_sub_of_hasDerivAt (fun w _ => hd w) + (hc.intervalIntegrable 0 l) + rw [h] + simp only [mul_zero, add_zero, ← pow_two] + ring + +/-- The unweighted half of the right tail is controlled by its rising secant. -/ +lemma integral_right_unweighted {p a x : ℝ} (hp : 0 ≤ p) (hx : 0 ≤ x) + (hx1 : x ≤ 1) (hxa : x < a) : + (∫ u in x..a, Q x u ^ p) ≤ + (Q x a ^ (p + 1) - Q x x ^ (p + 1)) / ((a - x) * (p + 1)) := by + have hshift := intervalIntegral.integral_comp_add_left (a := (0 : ℝ)) (b := a - x) + (fun u : ℝ => Q x u ^ p) x + simp only [add_zero, add_sub_cancel] at hshift + rw [← hshift] + have hq : (fun w : ℝ => Q x (x + w) ^ p) = (fun w : ℝ => (1 - x ^ 2 + w ^ 2) ^ p) := by + funext w + congr 1 + unfold Q + ring + rw [hq] + have hcq : Continuous (fun w : ℝ => (1 - x ^ 2 + w ^ 2) ^ p) := + (continuous_rpow_const hp).comp (by fun_prop) + have hcl : Continuous (fun w : ℝ => (1 - x ^ 2 + (a - x) * w) ^ p) := + (continuous_rpow_const hp).comp (by fun_prop) + have hle : (∫ w in (0 : ℝ)..a - x, (1 - x ^ 2 + w ^ 2) ^ p) ≤ + ∫ w in (0 : ℝ)..a - x, (1 - x ^ 2 + (a - x) * w) ^ p := by + apply intervalIntegral.integral_mono_on (sub_nonneg.mpr hxa.le) + (hcq.intervalIntegrable _ _) (hcl.intervalIntegrable _ _) + intro w hw + apply Real.rpow_le_rpow _ _ hp + · nlinarith [sq_nonneg w] + · nlinarith [mul_nonneg hw.1 (sub_nonneg.mpr hw.2)] + rw [integral_affine_power hp (sub_pos.mpr hxa)] at hle + have hqa : 1 - x ^ 2 + (a - x) ^ 2 = Q x a := by unfold Q; ring + have hqx : 1 - x ^ 2 = Q x x := by unfold Q; ring + rw [hqa, hqx] at hle + rw [hqx] + exact hle + +/-- Scale-adapted right-tail estimate: the weight and offset cost at most `E` and `4E`. +Both terms are actual integrals, not assumed error budgets. -/ +lemma right_le_five_endpoint {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : 0 < x) (hx1 : x ≤ 1) (hc : 0 < PaperTaylor.chord a x) + (hsep : 3 * x / 2 ≤ a) : + m * (∫ u in x..a, u * Q x u ^ ((m - 1) / 2)) ≤ 5 * endpoint m a x := by + let p := (m - 1) / 2 + let D := Q x a ^ (p + 1) - Q x x ^ (p + 1) + have hp : 0 ≤ p := by dsimp [p]; linarith + have hp1 : 0 < p + 1 := by linarith + have hm0 : 0 ≤ m := by linarith + have hxa : x < a := by linarith + have hl : 0 < a - x := sub_pos.mpr hxa + have hb : 0 < Q x a := Q_pos ha1 hx1 ⟨ha.le, le_rfl⟩ + have hb1 : Q x a ≤ 1 := by unfold PaperTaylor.chord at hc; unfold Q; nlinarith + have hE : 0 ≤ endpoint m a x := Real.rpow_nonneg hb.le _ + have hD : D ≤ endpoint m a x := by + have hv := Real.rpow_nonneg (Q_nonneg hx.le hx1 x) (p + 1) + have hbE : Q x a ^ (p + 1) ≤ endpoint m a x := + Real.rpow_le_rpow_of_exponent_ge hb hb1 (by dsimp [p]; linarith) + dsimp [D] + linarith + have hw : m * (∫ u in x..a, (u - x) * Q x u ^ p) ≤ endpoint m a x := by + rw [integral_right_weight hp, ← mul_div_assoc] + apply (div_le_iff₀ (show 0 < 2 * (p + 1) by positivity)).mpr + have h := mul_le_mul_of_nonneg_left hD hm0 + change m * D ≤ endpoint m a x * (2 * (p + 1)) + dsimp [p] at * + nlinarith + have hc4 : m * x ≤ 4 * ((a - x) * (p + 1)) := by + have h := mul_nonneg (show 0 ≤ 2 * (a - x) - x by linarith) (show 0 ≤ m + 1 by linarith) + dsimp [p] + nlinarith + have hu : m * x * (∫ u in x..a, Q x u ^ p) ≤ 4 * endpoint m a x := by + have h := mul_le_mul_of_nonneg_left (integral_right_unweighted hp hx.le hx1 hxa) + (show 0 ≤ m * x by positivity) + apply h.trans + rw [← mul_div_assoc] + apply (div_le_iff₀ (mul_pos hl hp1)).mpr + have h1 := mul_le_mul_of_nonneg_left hD (show 0 ≤ m * x by positivity) + have h2 := mul_le_mul_of_nonneg_right hc4 hE + change m * x * D ≤ 4 * endpoint m a x * ((a - x) * (p + 1)) + nlinarith + have hcq : Continuous (fun u : ℝ => Q x u ^ p) := + (continuous_rpow_const hp).comp (by unfold Q; fun_prop) + have hiw : IntervalIntegrable (fun u : ℝ => (u - x) * Q x u ^ p) volume x a := + ((continuous_id.sub continuous_const).mul hcq).intervalIntegrable x a + have hiu := (hcq.intervalIntegrable x a (μ := volume)).const_mul x + have hsplit : (∫ u in x..a, u * Q x u ^ p) = + (∫ u in x..a, (u - x) * Q x u ^ p) + x * ∫ u in x..a, Q x u ^ p := by + rw [← intervalIntegral.integral_const_mul, ← intervalIntegral.integral_add hiw hiu] + apply intervalIntegral.integral_congr + intro u _ + ring + change m * (∫ u in x..a, u * Q x u ^ p) ≤ _ + rw [hsplit] + nlinarith + +/-- The separated two-endpoint estimate, including the boundary `a = 3*x/2`. -/ +theorem total_lt_separated {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : 0 < x) (hx1 : x ≤ 1) (hc : 0 < PaperTaylor.chord a x) + (hsep : a ≤ x ∨ 3 * x / 2 ≤ a) : + total m a x < 4 / (m * x ^ 2) + 6 * endpoint m a x := by + rcases hsep with hax | hax + · have h := total_lt_left_endpoint hm ha hx hx1 hax + have hE : 0 ≤ endpoint m a x := Real.rpow_nonneg (Q_nonneg hx.le hx1 a) _ + linarith + · have hxa : x ≤ a := by linarith + have hr := right_le_five_endpoint hm ha ha1 hx hx1 hc hax + have hl := left_lt hm ha hx hx1 + rw [min_eq_right hxa] at hl + rw [total_split hm] + linarith + +/-- Separated estimate directly on the original `t`-coordinate budget. -/ +theorem budget_lt_separated {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : 0 < x) (hx1 : x ≤ 1) (hc : 0 < PaperTaylor.chord a x) + (hsep : a ≤ x ∨ 3 * x / 2 ≤ a) : + PaperTaylor.budget m a x < 4 / (m * x ^ 2) + + 6 * PaperTaylor.beta a x 1 ^ (m / 2) := by + rw [← total_eq_budget ha] + simpa only [endpoint, ← Q_beta, mul_one] using total_lt_separated hm ha ha1 hx hx1 hc hsep + +/-- Middle estimate directly on the original budget, with the unrelaxed exponent. -/ +theorem budget_lt_middle {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : 0 < x) (hx1 : x ≤ 1) (hxa : x < a) (hax : a < 3 * x / 2) : + PaperTaylor.budget m a x < 4 / (m * x ^ 2) + + (1 + 5 * m * x ^ 2 / 8) * Real.exp (-3 * (m - 1) * x ^ 2 / 8) := by + rw [← total_eq_budget ha] + exact total_lt_middle hm ha ha1 hx hx1 hxa hax + +end Sendov.PaperTwoEnd diff --git a/docs/paper-formalization/checkpoint2.json b/docs/paper-formalization/checkpoint2.json new file mode 100644 index 0000000..f36f487 --- /dev/null +++ b/docs/paper-formalization/checkpoint2.json @@ -0,0 +1,11 @@ +{ + "status": "partial_kernel_verified", + "gates": 24, + "seconds": 120.83266002003802, + "near_endpoint_D": true, + "all_a_m256_D": false, + "secant_gate": true, + "centered_actual_coefficients": true, + "optimized_coefficient_bound": true, + "centered_coefficient_assembly": false +} \ No newline at end of file diff --git a/docs/paper-formalization/round2-files.json b/docs/paper-formalization/round2-files.json new file mode 100644 index 0000000..62991a0 --- /dev/null +++ b/docs/paper-formalization/round2-files.json @@ -0,0 +1,14 @@ +[ + "Sendov/Analytic/PaperNear.lean", + "tests/PaperNear.lean", + "Sendov/Analytic/PaperTwoEnd.lean", + "tests/PaperTwoEndTests.lean", + "Sendov/Analytic/PaperLaplace.lean", + "tests/PaperLaplace.lean", + "Sendov/Analytic/PaperSecant.lean", + "tests/PaperSecantTests.lean", + "Sendov/Analytic/PaperCentered.lean", + "tests/PaperCentered.lean", + "Sendov/Analytic/PaperCoefficient.lean", + "tests/PaperCoefficientTests.lean" +] \ No newline at end of file diff --git a/tests/PaperCentered.lean b/tests/PaperCentered.lean new file mode 100644 index 0000000..c8ea6d5 --- /dev/null +++ b/tests/PaperCentered.lean @@ -0,0 +1,83 @@ +import Sendov.Analytic.PaperCentered + +/-! Regression contracts: complex endpoints, top degree, repeated roots, degree two, +and the actual finite (not assumed) expansion. -/ +noncomputable section +open scoped BigOperators +open Sendov.PaperCentered + +-- Zero scaling is covered by the division-free beta theorem. +example (m k : ℕ) (hk : k ≤ m) : + ((m + 1) * (m.choose k : ℂ) * (0 : ℂ) ^ (k + 1)) * + (∫ t in (0 : ℝ)..1, (t : ℂ) ^ k * (1 - (0 : ℂ) * t) ^ (m - k)) = + H m k 0 := finite_beta m k hk 0 + +-- Nonreal endpoints are not treated as probabilities. +example (m k : ℕ) (hk : k ≤ m) : + ((m + 1) * (m.choose k : ℂ) * Complex.I ^ (k + 1)) * + (∫ t in (0 : ℝ)..1, (t : ℂ) ^ k * (1 - Complex.I * t) ^ (m - k)) = + H m k Complex.I := finite_beta m k hk Complex.I + +-- The top-degree H factor really remains present. +example (m : ℕ) (z : ℂ) : + ((m + 1 : ℂ) * z ^ (m + 1)) * + (∫ t in (0 : ℝ)..1, (t : ℂ) ^ m) = z ^ (m + 1) := by + simpa [H_top] using finite_beta m m le_rfl z + +-- Public contract with no normalized-coefficient notation hiding the denominator. +example (q : Multiset ℂ) (a μ : ℂ) (hμ : μ ≠ 0) : + (q.card + 1) * (a * μ) * + (∫ t in (0 : ℝ)..1, (q.map (fun v => 1 - a * t * v)).prod) = + ∑ k ∈ Finset.range (q.card + 1), + ((-1) ^ k * (q.map (fun v => v - μ)).esymm k / + ((q.card.choose k : ℂ) * μ ^ k)) * H q.card k (a * μ) := by + simpa [coeff] using centered_integral q a μ hμ + +-- Multisets retain multiplicities: no distinctness assumptions are needed. +example (x y u : ℂ) : + ((u ::ₘ u ::ₘ (0 : Multiset ℂ)).map (fun v => x + y * v)).prod = + ∑ k ∈ Finset.range 3, y ^ k * (u ::ₘ u ::ₘ (0 : Multiset ℂ)).esymm k * x ^ (2 - k) := by + simpa using prod_affine (u ::ₘ u ::ₘ (0 : Multiset ℂ)) x y + +-- The minimum degree has an empty high-degree tail, not an omitted H_2 endpoint. +example (u v μ z : ℂ) : tail (u ::ₘ {v}) μ z = 0 := by + simp [tail] + +example (z : ℂ) : B 2 2 z = (1 - z) ^ 3 + 3 * z * (1 - z) ^ 2 + + 3 * z ^ 2 * (1 - z) := by + norm_num [B, Finset.sum_range_succ, Nat.choose] + +-- Explicit nonreal mean and nonzero second correction. +example (a : ℂ) : + (3 : ℂ) * (a * Complex.I) * + (∫ t in (0 : ℝ)..1, + (((Complex.I + 1) ::ₘ {Complex.I - 1}).map + (fun v => 1 - a * t * v)).prod) = + 1 - correction ((((Complex.I + 1) ::ₘ {Complex.I - 1}).map + (fun v => v - Complex.I))) Complex.I + + epsilon ((((Complex.I + 1) ::ₘ {Complex.I - 1}).map + (fun v => v - Complex.I))) Complex.I (a * Complex.I) := by + convert second_order ((Complex.I + 1) ::ₘ {Complex.I - 1}) a Complex.I + (by simp) (by simp; ring) Complex.I_ne_zero using 1 + norm_num + +example : correction ((1 : ℂ) ::ₘ {-1}) Complex.I = -1 := by + norm_num [correction, kappa, Complex.I_sq] + +-- End-to-end consumption: the finite budget is discharged, not supplied as an axiom. +example : 1 < ‖(3 : ℂ) * (∫ t in (0 : ℝ)..1, + (((1 : ℂ) ::ₘ {1}).map (fun v => 1 - (1 / 2 : ℂ) * t * v)).prod)‖ := by + have hb : Efin ((((1 : ℂ) ::ₘ {1}).map (fun v => v - 1))) 1 (1 / 2) + + Gamma ((((1 : ℂ) ::ₘ {1}).map (fun v => v - 1))) 1 < + 1 - (1 / 2 : ℝ) * ‖(1 : ℂ)‖ := by + norm_num [Efin, Gamma, variance] + convert C_budget ((1 : ℂ) ::ₘ {1}) (1 / 2) 1 (by simp) (by norm_num) + (by norm_num) one_ne_zero (by simpa using hb) using 1 + norm_num + +-- Independent audit roots for the general, not numerical, results. +#print axioms Sendov.PaperCentered.finite_beta +#print axioms Sendov.PaperCentered.centered_integral +#print axioms Sendov.PaperCentered.second_order +#print axioms Sendov.PaperCentered.norm_epsilon_le +#print axioms Sendov.PaperCentered.C_budget diff --git a/tests/PaperCoefficientTests.lean b/tests/PaperCoefficientTests.lean new file mode 100644 index 0000000..d0e80c3 --- /dev/null +++ b/tests/PaperCoefficientTests.lean @@ -0,0 +1,80 @@ +import Sendov.Analytic.PaperCoefficient + +/-! +Interface and edge-case regressions for the general centered coefficient theorem. +These are tests of the already proved arbitrary-family theorem, not substitutes +for it. The final declarations print the exact transitive axiom dependencies. +-/ + +open scoped BigOperators +open Sendov.PaperCoefficient + +namespace Sendov.PaperCoefficientTests + +-- The paper interface: arbitrary cardinality and an explicitly supplied mean square. +example (m k : ℕ) (r : Multiset ℂ) (hm : r.card = m) (hr : r.sum = 0) + (v R : ℝ) (hv : v = (r.map (fun z ↦ ‖z‖ ^ 2)).sum / m) (hk : k ≤ m) : + ‖r.esymm k‖ ^ 2 * R ^ (2 * k) ≤ (1 + R ^ 2 * v) ^ m := by + have h := norm_esymm_sq_mul_pow_le r hr k (by omega) R + simpa [variance, hm, hv] using h + +example (m k : ℕ) (r : Multiset ℂ) (hm : r.card = m) (hr : r.sum = 0) + (v : ℝ) (hv : v = (r.map (fun z ↦ ‖z‖ ^ 2)).sum / m) + (hk : 0 < k) (hkm : k < m) : + ‖r.esymm k‖ ^ 2 ≤ + (m : ℝ) ^ m / ((k : ℝ) ^ k * ((m - k : ℕ) : ℝ) ^ (m - k)) * v ^ k := by + have h := norm_esymm_sq_le_optimized r hr k hk (by omega) + simpa [variance, hm, hv] using h + +-- No centeredness is needed for the sharp top coefficient / product bound. +example (r : Multiset ℂ) : ‖r.esymm r.card‖ ^ 2 ≤ variance r ^ r.card := + norm_esymm_card_sq_le r + +-- Empty family, zero radius, negative radius, and zero variance are legal inputs. +example : ‖(0 : Multiset ℂ).esymm 0‖ ^ 2 * (0 : ℝ) ^ (2 * 0) ≤ + (1 + (0 : ℝ) ^ 2 * variance 0) ^ (0 : Multiset ℂ).card := + norm_esymm_sq_mul_pow_le 0 (by simp) 0 (by simp) 0 + +example (r : Multiset ℂ) (hr : r.sum = 0) (k : ℕ) (hk : k ≤ r.card) : + ‖r.esymm k‖ ^ 2 * (-3 : ℝ) ^ (2 * k) ≤ (1 + 9 * variance r) ^ r.card := by + convert norm_esymm_sq_mul_pow_le r hr k hk (-3) using 1; norm_num + +example (r : Multiset ℂ) (hv : variance r = 0) (k : ℕ) (hk : 0 < k) : + r.esymm k = 0 := esymm_eq_zero_of_variance_eq_zero r hv k hk + +-- A genuinely complex arbitrary centered family; no assumption ‖z‖ ≤ 1. +example (z : ℂ) (R : ℝ) : + ‖(z ::ₘ {-z}).esymm 1‖ ^ 2 * R ^ 2 ≤ + (1 + R ^ 2 * variance (z ::ₘ {-z})) ^ 2 := by + simpa using norm_esymm_sq_mul_pow_le (z ::ₘ {-z}) (by simp) 1 (by simp) R + +-- The complex finite-function formulation also feeds the theorem directly. +example {m : ℕ} (r : Fin m → ℂ) (hr : ∑ i, r i = 0) + (k : ℕ) (hk : 0 < k) (hkm : k < m) : + let s := (Finset.univ : Finset (Fin m)).val.map r + ‖s.esymm k‖ ^ 2 ≤ + (m : ℝ) ^ m / ((k : ℝ) ^ k * ((m - k : ℕ) : ℝ) ^ (m - k)) * + ((∑ i, ‖r i‖ ^ 2) / m) ^ k := by + dsimp + have hs : ((Finset.univ : Finset (Fin m)).val.map r).sum = 0 := by + simpa [List.sum_ofFn] using hr + have h := norm_esymm_sq_le_optimized ((Finset.univ : Finset (Fin m)).val.map r) hs k hk + (by simpa using hkm) + simpa [variance, Multiset.map_map, List.sum_ofFn, Function.comp_def] using h + +end Sendov.PaperCoefficientTests + +#print axioms Sendov.PaperCoefficient.circleIntegral_coeff +#print axioms Sendov.PaperCoefficient.norm_coeff_le_of_circle +#print axioms Sendov.PaperCoefficient.norm_coeff_sq_le_of_circle +#print axioms Sendov.PaperCoefficient.norm_prod_sq_le_variance_pow +#print axioms Sendov.PaperCoefficient.sum_norm_add_sq +#print axioms Sendov.PaperCoefficient.norm_prod_add_sq_le +#print axioms Sendov.PaperCoefficient.norm_esymm_sq_le +#print axioms Sendov.PaperCoefficient.variance_map_mul +#print axioms Sendov.PaperCoefficient.norm_esymm_sq_mul_pow_le +#print axioms Sendov.PaperCoefficient.variance_nonneg +#print axioms Sendov.PaperCoefficient.esymm_eq_zero_of_variance_eq_zero +#print axioms Sendov.PaperCoefficient.optimized_scalar_bound +#print axioms Sendov.PaperCoefficient.norm_esymm_sq_le_optimized +#print axioms Sendov.PaperCoefficient.norm_esymm_card_sq_le diff --git a/tests/PaperLaplace.lean b/tests/PaperLaplace.lean new file mode 100644 index 0000000..eb6857e --- /dev/null +++ b/tests/PaperLaplace.lean @@ -0,0 +1,78 @@ +import Sendov.Analytic.PaperLaplace + +open MeasureTheory Sendov.PaperTaylor Sendov.PaperLaplace + +-- Exact finite-endpoint moments (not an assumed improper-integral evaluation). +example : (∫ t in (0 : ℝ)..1, t * Real.exp (-2 * t)) = + 1 / 4 - 3 / 4 * Real.exp (-2) := by + have h := integral_mul_exp (s := 2) (by norm_num) 1 + norm_num at h ⊢ + exact h + +example : (∫ t in (0 : ℝ)..1, t ^ 3 * Real.exp (-t)) = + 6 - 16 * Real.exp (-1) := by + have h := integral_cube_mul_exp (s := 1) (by norm_num) 1 + norm_num at h ⊢ + exact h + +example {s z : ℝ} (hs : 0 < s) (hz : 0 ≤ z) : + (∫ t in (0 : ℝ)..z, t ^ 3 * Real.exp (-s * t)) ≤ 6 / s ^ 4 := + integral_cube_mul_exp_le hs hz + +-- The actual split identity at x=1, with its strict interval membership. +example : (1 : ℝ) / (2 * (3 / 4)) ∈ Set.Ioo (0 : ℝ) 1 := + split_mem (by norm_num) (by norm_num) (by norm_num) + +example : beta (3 / 4) 1 (1 / (2 * (3 / 4))) = 1 / 4 := by + rw [beta_split (by norm_num : (3 / 4 : ℝ) ≠ 0)] + norm_num + +-- Real, nonintegral degree: the analytic theorem does not need degree integrality. +example : (3 / 2 : ℝ) * (1 : ℝ) ^ 2 * budget (3 / 2) (3 / 4) 1 ≤ + (3 / 2 : ℝ) ^ 2 / (3 / 2 - 1) ^ 2 + + (256 / 27 : ℝ) * (3 / 2) ^ 2 / ((3 / 2 - 1) ^ 3 * (1 : ℝ) ^ 2) + + ((3 / 2 : ℝ) ^ 2 / 2 + 3 / 2) * (1 / 4 : ℝ) ^ (((3 / 2 : ℝ) - 1) / 2) := by + apply Sendov.PaperLaplace.budget_le <;> norm_num [beta] + +-- The headline conclusion contains precisely the original endpoint plus integral. +example {m a x r : ℝ} (hm : 1 < m) (ha : 0 < a) (ha1 : a < 1) + (hx0 : 0 < x) (hx1 : x ≤ 1) (hxa : x < 2 * a) + (hr0 : 1 - 3 * x ^ 2 / 4 ≤ r) (hrb : beta a x 1 ≤ r) (hr1 : r ≤ 1) : + m * x ^ 2 * (beta a x 1 ^ (m / 2) + m * a ^ 2 * + ∫ t in (0 : ℝ)..1, t * beta a x t ^ ((m - 1) / 2)) ≤ + m ^ 2 / (m - 1) ^ 2 + (256 / 27 : ℝ) * m ^ 2 / ((m - 1) ^ 3 * x ^ 2) + + (m ^ 2 / 2 + m) * r ^ ((m - 1) / 2) := + Sendov.PaperLaplace.budget_le hm ha ha1 hx0 hx1 hxa hr0 hrb hr1 + +-- Round4 geometry: no assumed integral/exponential comparison and no r ≤ 1 input. +example {m : ℕ} {a x r : ℝ} (hm : 512 ≤ m) + (ha : 7 / 8 ≤ a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : Sendov.PaperPolar.RawPolar m a x) + (hr0 : 1 - 3 * x ^ 2 / 4 ≤ r) (hrb : Sendov.PaperPolar.b a x ≤ r) : + (m : ℝ) * x ^ 2 * budget m a x ≤ + (m : ℝ) ^ 2 / (m - 1) ^ 2 + + (256 / 27 : ℝ) * m ^ 2 / ((m - 1) ^ 3 * x ^ 2) + + ((m : ℝ) ^ 2 / 2 + m) * r ^ (((m : ℝ) - 1) / 2) := + sharp_laplace (by omega) (by linarith) ha1 hx0 hx1 hraw hr0 hrb + +-- Round5 geometry uses the same theorem, not a downward extrapolation of m ≥ 512. +example {m : ℕ} {a x r : ℝ} (hm : 256 ≤ m) + (ha : 4 / 5 ≤ a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : Sendov.PaperPolar.RawPolar m a x) + (hr0 : 1 - 3 * x ^ 2 / 4 ≤ r) (hrb : Sendov.PaperPolar.b a x ≤ r) : + (m : ℝ) * x ^ 2 * budget m a x ≤ + (m : ℝ) ^ 2 / (m - 1) ^ 2 + + (256 / 27 : ℝ) * m ^ 2 / ((m - 1) ^ 3 * x ^ 2) + + ((m : ℝ) ^ 2 / 2 + m) * r ^ (((m : ℝ) - 1) / 2) := + sharp_laplace (by omega) (by linarith) ha1 hx0 hx1 hraw hr0 hrb + +#print axioms Sendov.PaperLaplace.exp_le_one_add_mul_exp +#print axioms Sendov.PaperLaplace.rpow_le_exp_taylor +#print axioms Sendov.PaperLaplace.beta_rpow_le_exp +#print axioms Sendov.PaperLaplace.integral_mul_exp +#print axioms Sendov.PaperLaplace.integral_cube_mul_exp +#print axioms Sendov.PaperLaplace.integral_left_le +#print axioms Sendov.PaperLaplace.integral_right_le +#print axioms Sendov.PaperLaplace.budget_le_of_beta_le_one +#print axioms Sendov.PaperLaplace.budget_le +#print axioms Sendov.PaperLaplace.sharp_laplace diff --git a/tests/PaperNear.lean b/tests/PaperNear.lean new file mode 100644 index 0000000..311fe75 --- /dev/null +++ b/tests/PaperNear.lean @@ -0,0 +1,41 @@ +import Sendov.Analytic.PaperNear + +open MeasureTheory + +namespace Sendov.PaperNearAcceptance + +/-- Acceptance at the public API, with no endpoint or error assumptions. -/ +theorem exact_signature (m : ℕ) (a x : ℝ) (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 2 / 5) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x > + (1 - a) / 1000 := + PaperNearClosure.near_endpoint_D hm ha0 ha1 hx0 hx1 hraw hnear + +/-- Both integrals expanded: this is the actual D conclusion, not a scalar wrapper. -/ +theorem expanded_integrals (m : ℕ) (a x : ℝ) (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : 1 ≤ ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2)) + (hnear : (m : ℝ) * (1 - a) ≤ 2 / 5) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + (m : ℝ) * a ^ 2 * + ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) > + (1 - a) / 1000 := by + change PaperPolar.RawPolar m a x at hraw + simpa only [PaperTaylor.budget, PaperTaylor.beta, mul_one, one_pow] using + PaperNearClosure.near_endpoint_D hm ha0 ha1 hx0 hx1 hraw hnear + +#print axioms PaperNearClosure.half_power_le +#print axioms PaperNearClosure.geometric_endpoint +#print axioms PaperNearClosure.endpoint_term_lt +#print axioms PaperNearClosure.first_error_le +#print axioms PaperNearClosure.second_error_le +#print axioms PaperNearClosure.parameter_errors +#print axioms PaperNearClosure.near_endpoint_D +#print axioms exact_signature +#print axioms expanded_integrals + +end Sendov.PaperNearAcceptance diff --git a/tests/PaperSecantTests.lean b/tests/PaperSecantTests.lean new file mode 100644 index 0000000..645c339 --- /dev/null +++ b/tests/PaperSecantTests.lean @@ -0,0 +1,109 @@ +import Sendov.Analytic.PaperSecant + +/-! Regression tests for round6 §§2–3. Numerical tests are kernel-checked +rational arithmetic, not floating-point checks or claims of universal positivity. -/ +namespace Sendov.PaperSecant.Tests +open MeasureTheory + +-- Odd and even degrees use the same exact finite endpoint theorem. +example {a : ℝ} (ha : 0 < a) (ha1 : a < 1) : + R 7 a 1 = ((a + (1 - a ^ 2)) ^ 8 - a ^ 8) / (8 * (1 - a ^ 2)) := by + have h := R_one (m := 7) ha ha1 + norm_num [U1] at h ⊢ + exact h + +example {a : ℝ} (ha : 0 < a) (ha1 : a < 1) : + (∫ t in (0 : ℝ)..1, (a ^ 2 + (1 - a ^ 2) * t) ^ ((7 : ℝ) / 2)) = + 2 * (1 - a ^ 9) / (9 * (1 - a ^ 2)) := by + have h := integral_chord (m := 7) ha ha1 + norm_num [U0] at h ⊢ + exact h + +example {a : ℝ} (ha : 0 < a) (ha1 : a < 1) : + R 8 a (a / 2) ≤ U0 8 a - (8 : ℝ) / 12 * a ^ 6 * (1 - a ^ 2) ^ 2 := by + simpa [V0] using (R_half_le_V0 (m := 8) (by norm_num) ha ha1) + +example {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : PaperPolar.RawPolar m a x) : + 0 < V0 m a ∧ V0 m a < 1 ∧ 1 ≤ U1 m a ∧ a / 2 < S m a ∧ S m a ≤ x := by + have hu := one_le_U1 ha ha1 hx0 hx1 hr + exact ⟨V0_pos (by omega) ha ha1, V0_lt_one (by omega) ha ha1, hu, + (S_bounds (by omega) ha ha1 hu).1, raw_implies_secant hm ha ha1 hx0 hx1 hr⟩ + +example {m : ℕ} {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hu : U1 m a < 1) : ¬ PaperPolar.RawPolar m a x := by + intro hr + exact (not_le_of_gt hu) (one_le_U1 ha ha1 hx0 hx1 hr) + +-- Direct universal interface, with the actual origin integral exposed. +example {m : ℕ} {a : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hg : 0 < Fsec m a) : ∀ x : ℝ, -1 ≤ x → x ≤ 1 → PaperPolar.RawPolar m a x → + PaperTaylor.beta a x 1 ^ ((m : ℝ) / 2) + (m : ℝ) * a ^ 2 * + (∫ t in (0 : ℝ)..1, t * PaperTaylor.beta a x t ^ (((m : ℝ) - 1) / 2)) < + 1 - (m : ℝ) * a / ((m : ℝ) + 1) := by + intro x hx0 hx1 hr + exact gate_implies_D hm ha ha1 hx0 hx1 hr hg + +-- Report §3.1: three positive diagnostics and the failure retained verbatim. +theorem gate_7_four_fifths : 0 < Fsec 7 (4 / 5) := by + norm_num [Fsec, B, Wsec, S, V0, U0, U1, PaperTaylor.beta, + PaperTaylor.defect, PaperTaylor.chord] + +theorem gate_8_nine_tenths : 0 < Fsec 8 (9 / 10) := by + norm_num [Fsec, B, Wsec, S, V0, U0, U1, PaperTaylor.beta, + PaperTaylor.defect, PaperTaylor.chord] + +theorem gate_10_nine_tenths : 0 < Fsec 10 (9 / 10) := by + norm_num [Fsec, B, Wsec, S, V0, U0, U1, PaperTaylor.beta, + PaperTaylor.defect, PaperTaylor.chord] + +theorem gate_16_nine_tenths_negative : Fsec 16 (9 / 10) < 0 := by + norm_num [Fsec, B, Wsec, S, V0, U0, U1, PaperTaylor.beta, + PaperTaylor.defect, PaperTaylor.chord] + +-- The rejected linear simplification must not creep into the secant API. +theorem linear_simplification_fails : + S 10 (49 / 50) - (1 - (10 - 4 : ℝ) * (1 - 49 / 50) / 6) = + -(580765093537365039347573397 : ℝ) / 317624371446602655376674688925300 := by + norm_num [S, V0, U0, U1] + +-- A negative gate is compatible with raw feasibility, not a counterexample to D. +theorem raw_feasible_at_negative_gate : PaperPolar.RawPolar 16 (9 / 10) 1 := by + rw [PaperPolar.rawPolar_iff] + change 1 ≤ R 16 (9 / 10) 1 + rw [R_one (by norm_num) (by norm_num)] + norm_num [U1] + +-- The odd-degree positive diagnostic closes D for every feasible mean. +example {x : ℝ} (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : PaperPolar.RawPolar 7 (4 / 5) x) : + PaperTaylor.budget 7 (4 / 5) x < B 7 (4 / 5) := by + exact gate_implies_D (by norm_num) (by norm_num) (by norm_num) + hx0 hx1 hr gate_7_four_fifths + +#print axioms R_one +#print axioms integral_chord +#print axioms curvature_pointwise +#print axioms R_half_le_V0 +#print axioms V0_pos +#print axioms V0_le_U0 +#print axioms V0_lt_one +#print axioms U0_lt_one +#print axioms R_mono +#print axioms one_le_U1 +#print axioms R_secant +#print axioms S_bounds +#print axioms S_eq_one_sub +#print axioms plain_secant_le_S +#print axioms gate_denominators_pos +#print axioms raw_implies_secant +#print axioms budget_antitone +#print axioms endpoint_pow_le +#print axioms budget_S_le_Wsec +#print axioms gate_implies_D +#print axioms gate_7_four_fifths +#print axioms gate_8_nine_tenths +#print axioms gate_10_nine_tenths +#print axioms gate_16_nine_tenths_negative + +end Sendov.PaperSecant.Tests diff --git a/tests/PaperTwoEndTests.lean b/tests/PaperTwoEndTests.lean new file mode 100644 index 0000000..e0cd370 --- /dev/null +++ b/tests/PaperTwoEndTests.lean @@ -0,0 +1,89 @@ +import Sendov.Analytic.PaperTwoEnd + +/-! Regression tests for the actual two-endpoint integral estimates. -/ +namespace Sendov.PaperTwoEnd.Tests + +open MeasureTheory + +-- The interface is valid for real m, not only odd integers. +theorem real_degree_left : + (15 / 2 : ℝ) * (∫ u in (0 : ℝ)..min (1 / 2) (3 / 4), + u * Q (3 / 4) u ^ (((15 / 2 : ℝ) - 1) / 2)) < + 4 / ((15 / 2 : ℝ) * (3 / 4) ^ 2) := by + exact left_lt (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +-- Equality at the vertex belongs to the left/separated branch. +theorem vertex_boundary : + PaperTaylor.budget 7 (1 / 2) (1 / 2) < 4 / ((7 : ℝ) * (1 / 2) ^ 2) + + 6 * PaperTaylor.beta (1 / 2) (1 / 2) 1 ^ ((7 : ℝ) / 2) := by + apply budget_lt_separated (by norm_num) (by norm_num) (by norm_num) + (by norm_num) (by norm_num) + · norm_num [PaperTaylor.chord] + · exact Or.inl le_rfl + +-- Equality at 3*x/2 belongs to the separated branch; no gap at the seam. +theorem separated_boundary : + PaperTaylor.budget 256 (3 / 4) (1 / 2) < 4 / ((256 : ℝ) * (1 / 2) ^ 2) + + 6 * PaperTaylor.beta (3 / 4) (1 / 2) 1 ^ ((256 : ℝ) / 2) := by + apply budget_lt_separated (by norm_num) (by norm_num) (by norm_num) + (by norm_num) (by norm_num) + · norm_num [PaperTaylor.chord] + · right; norm_num + +-- m=7 retains the original exponent rather than silently replacing it by -m*x²/3. +theorem middle_seven : + PaperTaylor.budget 7 (5 / 8) (1 / 2) < 4 / ((7 : ℝ) * (1 / 2) ^ 2) + + (1 + 5 * (7 : ℝ) * (1 / 2) ^ 2 / 8) * + Real.exp (-3 * ((7 : ℝ) - 1) * (1 / 2) ^ 2 / 8) := by + exact budget_lt_middle (by norm_num) (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +-- m=8 exercises a nonintegral real exponent. +theorem middle_eight : + PaperTaylor.budget 8 (5 / 8) (1 / 2) < 4 / ((8 : ℝ) * (1 / 2) ^ 2) + + (1 + 5 * (8 : ℝ) * (1 / 2) ^ 2 / 8) * + Real.exp (-3 * ((8 : ℝ) - 1) * (1 / 2) ^ 2 / 8) := by + exact budget_lt_middle (by norm_num) (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +-- Closed x-boundary and the vanishing quadratic minimum cause no singular derivative. +theorem closed_x_boundary : + total 7 (1 / 2) 1 < 4 / ((7 : ℝ) * 1 ^ 2) + endpoint 7 (1 / 2) 1 := by + exact total_lt_left_endpoint (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) + +theorem zero_minimum_primitive : + (∫ u in (1 : ℝ)..(3 / 2), (u - 1) * Q 1 u ^ (7 / 2 : ℝ)) = + (Q 1 (3 / 2) ^ ((7 / 2 : ℝ) + 1) - Q 1 1 ^ ((7 / 2 : ℝ) + 1)) / + (2 * ((7 / 2 : ℝ) + 1)) := by + exact integral_right_weight (by norm_num) + +-- The change of variables includes both powers of a, not just the Jacobian. +theorem affine_link (m : ℝ) : total m (2 / 3) (3 / 4) = + PaperTaylor.budget m (2 / 3) (3 / 4) := total_eq_budget (by norm_num) + +-- Geometry-only coverage is exhaustive, with no assumed integral estimates. +theorem exhaustive (m a x : ℝ) (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : 0 < x) (hx1 : x ≤ 1) (hc : 0 < PaperTaylor.chord a x) : + (PaperTaylor.budget m a x < 4 / (m * x ^ 2) + + 6 * PaperTaylor.beta a x 1 ^ (m / 2)) ∨ + (PaperTaylor.budget m a x < 4 / (m * x ^ 2) + + (1 + 5 * m * x ^ 2 / 8) * Real.exp (-3 * (m - 1) * x ^ 2 / 8)) := by + by_cases hleft : a ≤ x + · exact Or.inl (budget_lt_separated hm ha ha1 hx hx1 hc (Or.inl hleft)) + by_cases hright : 3 * x / 2 ≤ a + · exact Or.inl (budget_lt_separated hm ha ha1 hx hx1 hc (Or.inr hright)) + exact Or.inr (budget_lt_middle hm ha ha1 hx hx1 (lt_of_not_ge hleft) (lt_of_not_ge hright)) + +#print axioms Sendov.PaperTwoEnd.total_eq_budget +#print axioms Sendov.PaperTwoEnd.left_le +#print axioms Sendov.PaperTwoEnd.left_lt +#print axioms Sendov.PaperTwoEnd.integral_right_weight +#print axioms Sendov.PaperTwoEnd.integral_affine_power +#print axioms Sendov.PaperTwoEnd.integral_right_unweighted +#print axioms Sendov.PaperTwoEnd.right_le_five_endpoint +#print axioms Sendov.PaperTwoEnd.budget_lt_separated +#print axioms Sendov.PaperTwoEnd.budget_lt_middle +#print axioms Sendov.PaperTwoEnd.Tests.exhaustive + +end Sendov.PaperTwoEnd.Tests From 916075ac174e0e7dd6380a6fa0a713d54f07caf6 Mon Sep 17 00:00:00 2001 From: Methode Date: Mon, 14 Sep 2026 12:52:18 -0700 Subject: [PATCH 18/24] Wire uniform near-endpoint first-origin proof into both public conclusions --- Sendov/Analytic/FirstOriginBudget.lean | 77 +++++ Sendov/Interior.lean | 11 +- docs/paper-formalization/STATUS.md | 22 ++ tests/FirstOriginBudget.lean | 26 ++ tests/FirstOriginWiring.lean | 4 +- .../near-wiring-final-receipts.json | 272 ++++++++++++++++++ 6 files changed, 410 insertions(+), 2 deletions(-) create mode 100644 Sendov/Analytic/FirstOriginBudget.lean create mode 100644 tests/FirstOriginBudget.lean create mode 100644 tests/integration-existing/near-wiring-final-receipts.json diff --git a/Sendov/Analytic/FirstOriginBudget.lean b/Sendov/Analytic/FirstOriginBudget.lean new file mode 100644 index 0000000..4be1bf6 --- /dev/null +++ b/Sendov/Analytic/FirstOriginBudget.lean @@ -0,0 +1,77 @@ +import Sendov.Analytic.FirstOriginSmall +import Sendov.Analytic.PaperNear + +/-! Generic first-origin consumers of the scalar D estimates. +No second-origin or polynomial centroid identity is used in these proofs. -/ +namespace Sendov.FirstOriginBudget + +lemma beta_eq_QQ (a x t : ℝ) : PaperTaylor.beta a x t = QQ (a * x) (a ^ 2) t := by + unfold PaperTaylor.beta QQ + ring + +/-- First-origin forces the opposite of D, in the closed pointwise disk domain. -/ +theorem lower_budget {n : ℕ} (hn : 2 ≤ n) {a x y : ℝ} {q : Multiset ℂ} + (ha : 0 < a) (ha1 : a < 1) (hx1 : x ≤ 1) + (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x) + (hsum : q.sum = ((n : ℂ) - 1) * ((x : ℂ) + (y : ℂ) * Complex.I)) + (hfirst : ‖∫ t in (0 : ℝ)..1, Fprod a q t‖ ≤ 1 / (n : ℝ)) : + 1 ≤ PaperTaylor.budget ((n : ℝ) - 1) a x + a * ((n : ℝ) - 1) / (n : ℝ) := by + have hnR : (2 : ℝ) ≤ n := by exact_mod_cast hn + have hm0 : 0 ≤ (n : ℝ) - 1 := by linarith + have hc : (q.card : ℝ) = (n : ℝ) - 1 := by + rw [hqcard, Nat.cast_sub (by omega : 1 ≤ n)] + norm_num + have hq0 : q ≠ 0 := by + intro h + simp [h] at hqcard + omega + have hsumle := FirstOriginSmall.norm_sum_le_card q hq1 + rw [hc] at hsumle + have ht := one_le_tri hn hqcard hq0 hq1 ha.le hx hsum + have hβ : 0 ≤ QQ (a * x) (a ^ 2) 1 := by + rw [← beta_eq_QQ] + exact (PaperTaylor.beta_pos ha ha1 hx1 (by norm_num)).le + have hf := FirstOriginSmall.norm_Fprod_le hn hqcard hq1 hx hβ + have hcoef : ((n : ℂ) - 1) * (a : ℂ) * ((x : ℂ) + (y : ℂ) * Complex.I) = + (a : ℂ) * q.sum := by rw [hsum]; ring + rw [hcoef] at ht + have hi : ‖(a : ℂ) * q.sum * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ ≤ + a * ((n : ℝ) - 1) / (n : ℝ) := by + rw [norm_mul, norm_mul, Complex.norm_real, Real.norm_eq_abs, abs_of_pos ha] + have hmul := mul_le_mul (mul_le_mul_of_nonneg_left hsumle ha.le) hfirst + (norm_nonneg _) (by positivity : 0 ≤ a * ((n : ℝ) - 1)) + simpa only [mul_one_div] using hmul + have htri := norm_add_le (Fprod a q 1) + ((a : ℂ) * q.sum * (∫ t in (0 : ℝ)..1, Fprod a q t)) + have hexp : (n : ℝ) - 1 - 1 = (n : ℝ) - 2 := by ring + simp only [PaperTaylor.budget, beta_eq_QQ, hexp] + nlinarith only [ht, hf, hi, htri] + +/-- The near-endpoint raw-polar theorem is consumed without an analytic assumption. -/ +theorem near_contradiction {n : ℕ} (hn : 8 ≤ n) {a x y : ℝ} {q : Multiset ℂ} + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x) + (hsum : q.sum = ((n : ℂ) - 1) * ((x : ℂ) + (y : ℂ) * Complex.I)) + (hraw : 1 ≤ ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) + (hnear : ((n : ℝ) - 1) * (1 - a) ≤ 2 / 5) + (hfirst : ‖∫ t in (0 : ℝ)..1, Fprod a q t‖ ≤ 1 / (n : ℝ)) : False := by + have hm : 7 ≤ n - 1 := by omega + have hcast : ((n - 1 : ℕ) : ℝ) = (n : ℝ) - 1 := by + rw [Nat.cast_sub (by omega : 1 ≤ n)] + norm_num + have hr : PaperPolar.RawPolar (n - 1) a x := by + rw [PaperPolar.rawPolar_iff, hcast] + exact hraw + have hd := PaperNearClosure.near_endpoint_D hm ha ha1 hx0 hx1 hr + (by simpa only [hcast] using hnear) + have hl := lower_budget (by omega) ha ha1 hx1 hqcard hq1 hx hsum hfirst + rw [hcast] at hd + have he : (n : ℝ) - 1 + 1 = n := by ring + rw [he] at hd + have hh : 0 < (1 - a) / 1000 := by positivity + rw [mul_comm a ((n : ℝ) - 1)] at hl + linarith + +end Sendov.FirstOriginBudget diff --git a/Sendov/Interior.lean b/Sendov/Interior.lean index beffd65..4c19de0 100644 --- a/Sendov/Interior.lean +++ b/Sendov/Interior.lean @@ -7,6 +7,7 @@ import Sendov.Analytic.OriginExact import Sendov.Analytic.Polar import Sendov.Analytic.LowDegree import Sendov.Analytic.FirstOriginSmall +import Sendov.Analytic.FirstOriginBudget import Sendov.Analytic.Jsum import Sendov.Counterexample.Factor import Sendov.Reduction.Main @@ -108,7 +109,15 @@ theorem sendov_interior {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegre rw [Complex.re_add_im, mul_div_cancel₀ _ hne] obtain ⟨hxre, hx2⟩ := xy_bounds hn hqcard hq1 hxy have hpolar := one_le_integral_Ppolar hn (a := a) (x := x) hqcard hq1 hxre hstar - -- the origin channel + -- The uniform near-endpoint region uses only the first-origin channel. + by_cases hnear : ((n : ℝ) - 1) * (1 - a) ≤ 2 / 5 + · have hxSq : x ^ 2 ≤ 1 := (le_add_of_nonneg_right (sq_nonneg y)).trans hx2 + exact FirstOriginBudget.near_contradiction (by omega) ha0 ha1 + (by nlinarith [sq_nonneg (x + 1)]) (by nlinarith [sq_nonneg (x - 1)]) + hqcard hq1 hxre hxy hpolar hnear + (FirstOriginSmall.norm_integral_Fprod_le_of_factorization (by omega) (ne_of_gt ha0) + hc0 hzcard hq0 hq1 hz1 hpa hpz hpq') + -- the remaining origin channel have hcent := centroid_identity (c := p.leadingCoeff) (a := ((a : ℝ) : ℂ)) (n := n) (z := z) (q := q) (p := p) hn hc0 hzcard hqcard hpz hpq' have hfirst := first_origin_identity (c := p.leadingCoeff) (a := ((a : ℝ) : ℂ)) (n := n) diff --git a/docs/paper-formalization/STATUS.md b/docs/paper-formalization/STATUS.md index 9d6fc03..384f806 100644 --- a/docs/paper-formalization/STATUS.md +++ b/docs/paper-formalization/STATUS.md @@ -4,6 +4,28 @@ Baseline: `0a4e966c41e1287f92d305d3bad8e70c8c295dde`. Integration branch: `formalize/paper-results-20260914`. Status: **IN PROGRESS**, not complete and not a uniform D proof. +## Checkpoint 2 — actual near-endpoint D, now wired into Solution + +`PaperNearClosure.near_endpoint_D` proves the actual raw-polar integral +implication for every natural m≥7 and m(1-a)≤2/5, with strict gap >h/1000. +The two-endpoint integral bounds, sharp Laplace estimate, curvature secant +and its sufficient D gate, finite complex centered expansion, and optimized +coefficient bounds have also been integrated and freshly checked (24 gates). +The centered actual-coefficient budget and independent optimized coefficient +bound still need their common majorant interface; this is in the next batch. + +`FirstOriginBudget.lower_budget` connects the scalar integral to actual Fprod. +`Interior` now branches into the new near-endpoint contradiction before +constructing the polynomial centroid and second-origin identities. Both +public Solution proof-value closures contain `near_endpoint_D`; the standalone +near contradiction's closure excludes all old centroid/second-origin/endgame +entries. Exact final sources passed the `near-wiring-clean` gates. The original +remaining-domain proof is retained; no all-a m≥256 Lean claim is made yet. + +Next dispatched items: global polar endpoint/log bounds, quantitative tails, +ray geometry, centered majorant assembly, older stronger near margins, exact +full-complex-polar diagnostic, and independent semantic review of checkpoint2. + ## Checkpoint 1 — integrated and freshly rechecked Boundary rigidity and first-origin n=6/n=7 are now actual consumers of both diff --git a/tests/FirstOriginBudget.lean b/tests/FirstOriginBudget.lean new file mode 100644 index 0000000..d91b426 --- /dev/null +++ b/tests/FirstOriginBudget.lean @@ -0,0 +1,26 @@ +import Sendov.Analytic.FirstOriginBudget + +#print axioms Sendov.FirstOriginBudget.lower_budget +#print axioms Sendov.FirstOriginBudget.near_contradiction + +-- Verify proof-value independence, not merely an import or a theorem name. +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + for root in #[`Sendov.FirstOriginBudget.near_contradiction, + `Sendov.FirstOriginSmall.first_origin_polar_six_seven] do + let mut pending := [root] + let mut seen : Std.HashSet Name := {} + while !pending.isEmpty do + let name := pending.head! + pending := pending.tail! + unless seen.contains name do + seen := seen.insert name + let some ci := env.find? name | throwError "missing declaration {name}" + if let some value := ci.value? (allowOpaque := true) then + for used in value.getUsedConstants do pending := used :: pending + for forbidden in #[`Sendov.second_origin_identity, `Sendov.centroid_identity, + `Sendov.origin_exact, `Sendov.polar_origin_incompatible] do + if seen.contains forbidden then + throwError "unexpected old-channel dependency {root} -> {forbidden}" + logInfo m!"FIRST_ORIGIN_ONLY {root}" diff --git a/tests/FirstOriginWiring.lean b/tests/FirstOriginWiring.lean index 2f4f4b9..d3fc3e7 100644 --- a/tests/FirstOriginWiring.lean +++ b/tests/FirstOriginWiring.lean @@ -23,7 +23,9 @@ run_cmd do if let some v := ci.value? (allowOpaque := true) then for used in v.getUsedConstants do pending := used :: pending for target in #[`Sendov.FirstOriginSmall.first_origin_polar_six_seven, - `Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_factorization] do + `Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_factorization, + `Sendov.FirstOriginBudget.near_contradiction, + `Sendov.PaperNearClosure.near_endpoint_D] do unless visited.contains target do throwError "missing final-root consumption {root} -> {target}" logInfo m!"FIRST_ORIGIN_SOLUTION_VALUE {root} -> {target}" diff --git a/tests/integration-existing/near-wiring-final-receipts.json b/tests/integration-existing/near-wiring-final-receipts.json new file mode 100644 index 0000000..564a37d --- /dev/null +++ b/tests/integration-existing/near-wiring-final-receipts.json @@ -0,0 +1,272 @@ +[ + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Sendov/Conjecture.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Conjecture.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov/Conjecture.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Sendov/Conjecture.json" + ], + "exit_code": 0, + "seconds": 3.60258825001074, + "module": "Sendov.Conjecture", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Conjecture", + "--tag", + "near-wiring-final" + ], + "source_sha256": "260df47ae05aee1735d8f24451f53bf7d25f55c4ecf6eb5a583860cfde4d42c8", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/near-wiring-final-Sendov.Conjecture.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "Sendov.Conjecture" + ], + "exit_code": 0, + "seconds": 4.505168583011255, + "module": "Sendov.Conjecture", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov.Conjecture", + "--tag", + "near-wiring-final", + "--kernel" + ], + "source_sha256": "260df47ae05aee1735d8f24451f53bf7d25f55c4ecf6eb5a583860cfde4d42c8", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/near-wiring-final-Sendov.Conjecture-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Solution.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Solution.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Solution.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Solution.json" + ], + "exit_code": 0, + "seconds": 2.8251066589728, + "module": "Solution", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Solution", + "--tag", + "near-wiring-final" + ], + "source_sha256": "bea235d32a6e29f078e72348671e40d7cdec39fc00667e00d5819b7cdfa30ce6", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/near-wiring-final-Solution.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/leanchecker", + "Solution" + ], + "exit_code": 0, + "seconds": 4.549807851959486, + "module": "Solution", + "kernel": true, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Solution", + "--tag", + "near-wiring-final", + "--kernel" + ], + "source_sha256": "bea235d32a6e29f078e72348671e40d7cdec39fc00667e00d5819b7cdfa30ce6", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/near-wiring-final-Solution-kernel.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/Sendov.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/Sendov.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/Sendov.json" + ], + "exit_code": 0, + "seconds": 2.700117100030184, + "module": "Sendov", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "Sendov", + "--tag", + "near-wiring-final" + ], + "source_sha256": "3f52679314022a1d2540c053568830f545d298c618a45649252068f71db8d1fc", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/near-wiring-final-Sendov.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/FirstOriginWiring.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/FirstOriginWiring.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/FirstOriginWiring.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/FirstOriginWiring.json" + ], + "exit_code": 0, + "seconds": 11.51174083497608, + "module": "tests.FirstOriginWiring", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.FirstOriginWiring", + "--tag", + "near-wiring-final" + ], + "source_sha256": "0c2e5c0f9b10f8d74b6832f3caab0b3fdf8dbae42fda4a6dcccfd301787af6a1", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/near-wiring-final-tests.FirstOriginWiring.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/scripts/axioms.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/scripts/axioms.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/scripts/axioms.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/scripts/axioms.json" + ], + "exit_code": 0, + "seconds": 3.17235064599663, + "module": "scripts.axioms", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "scripts.axioms", + "--tag", + "near-wiring-final" + ], + "source_sha256": "e7ef1a7af7b8b729b0b13a4907ea7979961fda7e79cc6811abafcc29254da656", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/near-wiring-final-scripts.axioms.log", + "source_unchanged": true + }, + { + "command": [ + "/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/bin/lean", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/tests/BoundaryContracts.lean", + "-o", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/BoundaryContracts.olean", + "-i", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects/tests/BoundaryContracts.ilean", + "--setup", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/setups/tests/BoundaryContracts.json" + ], + "exit_code": 0, + "seconds": 2.7350074279820547, + "module": "tests.BoundaryContracts", + "kernel": false, + "lean_path": "/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Cli/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/batteries/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/Qq/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/aesop/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/proofwidgets/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/importGraph/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/LeanSearchClient/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/plausible/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-research-20260914/.lake/packages/mathlib/.lake/build/lib/lean:/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/objects:/home/v-zhouziyu/.elan/toolchains/leanprover--lean4---v4.34.0-rc1/lib/lean", + "options": { + "weak.linter.mathlibStandardSet": true, + "relaxedAutoImplicit": false, + "pp.unicode.fun": true, + "maxSynthPendingDepth": 3, + "autoImplicit": false + }, + "wrapper_command": [ + "/home/v-zhouziyu/.hermes/hermes-agent/venv/bin/python3", + "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/check.py", + "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "tests.BoundaryContracts", + "--tag", + "near-wiring-final" + ], + "source_sha256": "21dc87df827c30896a43e88baf149da2aeee9f7d11d7316c976ee4bfe0a61019", + "log": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914/.lake/paper/logs/near-wiring-final-tests.BoundaryContracts.log", + "source_unchanged": true + } +] From a5f0c11401e0294eb4f4022970a4a429b48885e9 Mon Sep 17 00:00:00 2001 From: Methode Date: Mon, 14 Sep 2026 12:58:30 -0700 Subject: [PATCH 19/24] Verify global polar and ray bounds plus full centered majorant budget --- Sendov/Analytic/PaperCenteredBound.lean | 143 ++++++++ Sendov/Analytic/PaperGlobalPolar.lean | 229 +++++++++++++ Sendov/Analytic/PaperNearMargins.lean | 147 ++++++++ Sendov/Analytic/PaperRayGeometry.lean | 373 +++++++++++++++++++++ Sendov/Analytic/PaperTail.lean | 237 +++++++++++++ docs/paper-formalization/checkpoint3.json | 12 + docs/paper-formalization/round3-files.json | 14 + tests/PaperCenteredBoundTests.lean | 108 ++++++ tests/PaperGlobalPolarTests.lean | 101 ++++++ tests/PaperNearMargins.lean | 137 ++++++++ tests/PaperPolarCounterexample.lean | 161 +++++++++ tests/PaperRayGeometry.lean | 123 +++++++ tests/PaperSecantNeighborhoods.lean | 219 ++++++++++++ tests/PaperTailTests.lean | 63 ++++ 14 files changed, 2067 insertions(+) create mode 100644 Sendov/Analytic/PaperCenteredBound.lean create mode 100644 Sendov/Analytic/PaperGlobalPolar.lean create mode 100644 Sendov/Analytic/PaperNearMargins.lean create mode 100644 Sendov/Analytic/PaperRayGeometry.lean create mode 100644 Sendov/Analytic/PaperTail.lean create mode 100644 docs/paper-formalization/checkpoint3.json create mode 100644 docs/paper-formalization/round3-files.json create mode 100644 tests/PaperCenteredBoundTests.lean create mode 100644 tests/PaperGlobalPolarTests.lean create mode 100644 tests/PaperNearMargins.lean create mode 100644 tests/PaperPolarCounterexample.lean create mode 100644 tests/PaperRayGeometry.lean create mode 100644 tests/PaperSecantNeighborhoods.lean create mode 100644 tests/PaperTailTests.lean diff --git a/Sendov/Analytic/PaperCenteredBound.lean b/Sendov/Analytic/PaperCenteredBound.lean new file mode 100644 index 0000000..5615181 --- /dev/null +++ b/Sendov/Analytic/PaperCenteredBound.lean @@ -0,0 +1,143 @@ +import Sendov.Analytic.PaperCentered +import Sendov.Analytic.PaperCoefficient + +/-! +# The paper's square-root centered finite budget + +Assembles the optimized coefficient estimate and the exact centered expansion. +The variance is always that of the actual centered multiset. Every complex +endpoint H is retained, including the top degree. This is a sufficient-budget +implication, not a claim that the budget is positive on any geometric domain. +-/ + +noncomputable section +open scoped BigOperators +namespace Sendov.PaperCenteredBound +open PaperCentered + +/-- The two component modules use definitionally identical actual variances. -/ +theorem variance_eq (r : Multiset ℂ) : + PaperCoefficient.variance r = PaperCentered.variance r := rfl + +/-- REPORT §3.2, with an explicit top-degree branch. Only positive degrees +through m are used; outside that range the value is zero (except m=k=0). -/ +def C (m k : ℕ) (v : ℝ) : ℝ := + if k = m then Real.sqrt (v ^ m) + else if 0 < k ∧ k < m then + Real.sqrt ((m : ℝ) ^ m / ((k : ℝ) ^ k * ((m - k : ℕ) : ℝ) ^ (m - k)) * v ^ k) + else 0 + +@[simp] theorem C_top (m : ℕ) (v : ℝ) : C m m v = Real.sqrt (v ^ m) := by + simp [C] + +theorem C_interior (m k : ℕ) (v : ℝ) (hk : 0 < k) (hkm : k < m) : + C m k v = Real.sqrt + ((m : ℝ) ^ m / ((k : ℝ) ^ k * ((m - k : ℕ) : ℝ) ^ (m - k)) * v ^ k) := by + simp [C, hkm.ne, hk, hkm] + +theorem C_nonneg (m k : ℕ) (v : ℝ) : 0 ≤ C m k v := by + unfold C + split_ifs <;> positivity + +/-- Zero variance is covered without choosing a singular optimizing radius. -/ +@[simp] theorem C_zero_variance (m k : ℕ) (hk : 0 < k) : C m k 0 = 0 := by + by_cases hkm : k = m + · subst m + simp [C, zero_pow hk.ne'] + · simp [C, hkm, zero_pow hk.ne'] + +/-- The exact paper square-root bound, including k=m and zero variance. -/ +theorem norm_esymm_le_C (r : Multiset ℂ) (hr : r.sum = 0) + (k : ℕ) (hk : 0 < k) (hkm : k ≤ r.card) : + ‖r.esymm k‖ ≤ C r.card k (variance r) := by + by_cases htop : k = r.card + · subst k + rw [C_top] + have h := PaperCoefficient.norm_esymm_card_sq_le r + rw [variance_eq] at h + exact (Real.le_sqrt (norm_nonneg _) ((sq_nonneg _).trans h)).2 h + · rw [C_interior _ _ _ hk (lt_of_le_of_ne hkm htop)] + have h := PaperCoefficient.norm_esymm_sq_le_optimized r hr k hk + (lt_of_le_of_ne hkm htop) + rw [variance_eq] at h + exact (Real.le_sqrt (norm_nonneg _) ((sq_nonneg _).trans h)).2 h + +/-- Normalized actual coefficient interface. No real-mean assumption is made; +the inequality even holds at zero mean under Lean's total division convention. -/ +theorem norm_coeff_le_C (r : Multiset ℂ) (hr : r.sum = 0) + (μ : ℂ) (k : ℕ) (hk : 0 < k) (hkm : k ≤ r.card) : + ‖coeff r μ k‖ ≤ C r.card k (variance r) / ((r.card.choose k : ℝ) * ‖μ‖ ^ k) := by + rw [norm_coeff] + exact div_le_div_of_nonneg_right (norm_esymm_le_C r hr k hk hkm) (by positivity) + +/-- The coefficient interface on the actual deviations from a complex mean. -/ +theorem norm_centered_coeff_le_C (q : Multiset ℂ) (μ : ℂ) + (hmean : q.sum = q.card * μ) (k : ℕ) (hk : 0 < k) (hkm : k ≤ q.card) : + ‖coeff (q.map (fun v => v - μ)) μ k‖ ≤ + C q.card k (variance (q.map (fun v => v - μ))) / + ((q.card.choose k : ℝ) * ‖μ‖ ^ k) := by + simpa only [Multiset.card_map] using + norm_coeff_le_C (q.map (fun v => v - μ)) (centered_sum q μ hmean) μ k hk + (by simpa only [Multiset.card_map] using hkm) + +/-- REPORT §3.3 E_fin: the exact square-root majorant, not the actual-coefficient +triangle bound. All finite endpoints remain inside complex norms. -/ +def majorant_Efin (r : Multiset ℂ) (μ z : ℂ) : ℝ := + ‖1 - z‖ ^ (r.card + 1) + Gamma r μ * ‖B r.card 2 z‖ + + ∑ k ∈ Finset.Ico 3 (r.card + 1), + (C r.card k (variance r) / ((r.card.choose k : ℝ) * ‖μ‖ ^ k)) * ‖H r.card k z‖ + +/-- Comparison with the accepted actual-coefficient finite budget. -/ +theorem Efin_le_majorant_Efin (r : Multiset ℂ) (hr : r.sum = 0) (μ z : ℂ) : + Efin r μ z ≤ majorant_Efin r μ z := by + unfold Efin majorant_Efin + apply add_le_add le_rfl + apply Finset.sum_le_sum + intro k hk + obtain ⟨hk₀, hk₁⟩ := Finset.mem_Ico.mp hk + apply mul_le_mul_of_nonneg_right _ (norm_nonneg _) + exact div_le_div_of_nonneg_right (norm_esymm_le_C r hr k (by omega) (by omega)) + (by positivity) + +/-- The actual finite epsilon obeys the paper's square-root majorant. -/ +theorem norm_epsilon_le_majorant_Efin (r : Multiset ℂ) (hr : r.sum = 0) + (μ z : ℂ) (hm : 2 ≤ r.card) : + ‖epsilon r μ z‖ ≤ majorant_Efin r μ z := + (norm_epsilon_le r μ z hm).trans (Efin_le_majorant_Efin r hr μ z) + +/-- C-budget with the actual centered variance, valid for any nonzero complex +mean. The strict scalar budget is an explicit hypothesis, never a conclusion. -/ +theorem C_budget (q : Multiset ℂ) (a : ℝ) (μ : ℂ) (hm : 2 ≤ q.card) + (ha : 0 ≤ a) (hmean : q.sum = q.card * μ) (hμ : μ ≠ 0) + (hbudget : majorant_Efin (q.map (fun v => v - μ)) μ (a * μ) + + Gamma (q.map (fun v => v - μ)) μ < 1 - a * ‖μ‖) : + 1 < ‖(q.card + 1 : ℂ) * + (∫ t in (0 : ℝ)..1, (q.map (fun v => 1 - (a : ℂ) * t * v)).prod)‖ := by + apply PaperCentered.C_budget q a μ hm ha hmean hμ + exact lt_of_le_of_lt + (add_le_add (Efin_le_majorant_Efin _ (centered_sum q μ hmean) μ (a * μ)) le_rfl) + hbudget + +/-- At the top endpoint the apparent inverse power of the mean cancels exactly. +The scale a can itself be complex; no positivity interpretation of H is used. -/ +theorem majorant_top_suppression (r : Multiset ℂ) (a μ : ℂ) (hμ : μ ≠ 0) : + (C r.card r.card (variance r) / ((r.card.choose r.card : ℝ) * ‖μ‖ ^ r.card)) * + ‖H r.card r.card (a * μ)‖ = + Real.sqrt (variance r ^ r.card) * ‖a‖ ^ (r.card + 1) * ‖μ‖ := by + have hn : ‖μ‖ ≠ 0 := norm_ne_zero_iff.mpr hμ + rw [C_top, H_top, norm_pow, norm_mul, mul_pow, Nat.choose_self] + simp only [Nat.cast_one, one_mul] + rw [pow_succ ‖μ‖] + field_simp + +/-- The same cancellation for the signed actual top coefficient. -/ +theorem coeff_top_suppression (r : Multiset ℂ) (a μ : ℂ) (hμ : μ ≠ 0) : + coeff r μ r.card * H r.card r.card (a * μ) = + (-1) ^ r.card * r.prod * a ^ (r.card + 1) * μ := by + rw [coeff, H_top, Nat.choose_self] + simp only [Nat.cast_one, one_mul] + have he : r.esymm r.card = r.prod := by simp [Multiset.esymm] + rw [he, mul_pow, pow_succ μ] + field_simp + +end Sendov.PaperCenteredBound diff --git a/Sendov/Analytic/PaperGlobalPolar.lean b/Sendov/Analytic/PaperGlobalPolar.lean new file mode 100644 index 0000000..4579b32 --- /dev/null +++ b/Sendov/Analytic/PaperGlobalPolar.lean @@ -0,0 +1,229 @@ +import Sendov.Analytic.PaperSecant +import Mathlib.Analysis.Complex.ExponentialBounds + +/-! +# Global raw-polar endpoint estimates + +Retain both endpoints of the affine polar chord. With `N = (m+2)/2` +and `δ = 1-a²`, its exact integral supplies the logarithmic bound when +`N*δ ≥ 2`. In the complementary region the already proved rational +bound gives `c > 3/5`. Both branches yield `log N / N ≤ c`. +-/ +namespace Sendov.PaperGlobalPolar + +open MeasureTheory PaperPolar + +/-- The quadratic lies below its affine endpoint chord. -/ +lemma polar_le_chord {a x t : ℝ} (ht : t ∈ Set.Icc (0 : ℝ) 1) : + Ppolar a x t ≤ a ^ 2 + (1 - a ^ 2) * (1 + c a x) * t := by + have h := mul_nonneg (sq_nonneg (1 - a ^ 2)) + (mul_nonneg ht.1 (sub_nonneg.mpr ht.2)) + unfold Ppolar c b + nlinarith only [h] + +/-- Exact finite chord integral, with neither endpoint discarded. -/ +theorem integral_chord {m : ℕ} {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) + (hc : 0 < c a x) : + (∫ t in (0 : ℝ)..1, + (a ^ 2 + (1 - a ^ 2) * (1 + c a x) * t) ^ ((m : ℝ) / 2)) = + ((1 + (1 - a ^ 2) * c a x) ^ (((m : ℝ) + 2) / 2) - + (a ^ 2) ^ (((m : ℝ) + 2) / 2)) / + ((((m : ℝ) + 2) / 2) * (1 - a ^ 2) * (1 + c a x)) := by + have hd := PaperSecant.delta_pos ha ha1 + have hs : 0 < (1 - a ^ 2) * (1 + c a x) := mul_pos hd (by linarith) + rw [intervalIntegral.integral_comp_add_mul (fun y : ℝ => y ^ ((m : ℝ) / 2)) hs.ne', + integral_rpow (Or.inl (by have := Nat.cast_nonneg (α := ℝ) m; linarith : -1 < (m : ℝ) / 2))] + simp only [mul_zero, add_zero, mul_one, smul_eq_mul] + rw [show a ^ 2 + (1 - a ^ 2) * (1 + c a x) = 1 + (1 - a ^ 2) * c a x by ring, + show (m : ℝ) / 2 + 1 = ((m : ℝ) + 2) / 2 by ring] + field_simp + +/-- The raw integral is bounded by the exact finite chord integral. -/ +theorem raw_integral_le_chord {m : ℕ} {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hc : 0 < c a x) : + (∫ t in (0 : ℝ)..1, Ppolar a x t ^ ((m : ℝ) / 2)) ≤ + ((1 + (1 - a ^ 2) * c a x) ^ (((m : ℝ) + 2) / 2) - + (a ^ 2) ^ (((m : ℝ) + 2) / 2)) / + ((((m : ℝ) + 2) / 2) * (1 - a ^ 2) * (1 + c a x)) := by + rw [← integral_chord ha ha1 hc] + refine intervalIntegral.integral_mono_on (by norm_num) (PaperSecant.integrable_R m a x) + (((continuous_rpow_const (by positivity : 0 ≤ (m : ℝ) / 2)).comp + (by fun_prop)).intervalIntegrable _ _) ?_ + intro t ht + exact Real.rpow_le_rpow (Ppolar_nonneg (x_sq_le_one hx0 hx1) a t) + (polar_le_chord ht) (by positivity) + +/-- Taking logarithms of the exact chord bound. -/ +theorem log_mul_delta_le {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + Real.log ((((m : ℝ) + 2) / 2) * (1 - a ^ 2)) ≤ + ((((m : ℝ) + 2) / 2) * (1 - a ^ 2)) * c a x := by + have hc := (geometry hm ha ha1 hx0 hx1 hr).2 + have hd := PaperSecant.delta_pos ha ha1 + have hN : 0 < ((m : ℝ) + 2) / 2 := by positivity + have hD : 0 < (((m : ℝ) + 2) / 2) * (1 - a ^ 2) := mul_pos hN hd + have hden : 0 < (((m : ℝ) + 2) / 2) * (1 - a ^ 2) * (1 + c a x) := + mul_pos hD (by linarith) + have h := ((rawPolar_iff m a x).mp hr).trans (raw_integral_le_chord ha ha1 hx0 hx1 hc) + have hpow := (le_div_iff₀ hden).mp h + have hnonneg := Real.rpow_nonneg (sq_nonneg a) (((m : ℝ) + 2) / 2) + have hlower : (((m : ℝ) + 2) / 2) * (1 - a ^ 2) ≤ + (1 + (1 - a ^ 2) * c a x) ^ (((m : ℝ) + 2) / 2) := by + nlinarith [mul_nonneg hD.le hc.le] + have hp : 0 < 1 + (1 - a ^ 2) * c a x := by positivity + have hlog := Real.log_le_log hD hlower + rw [Real.log_rpow hp] at hlog + have hu := Real.log_le_sub_one_of_pos hp + have hmul := mul_le_mul_of_nonneg_left hu hN.le + nlinarith + +/-- The tangent bound at four and `log 2 > 1/2` control the lower endpoint. -/ +lemma log_le_mul_log_two {N : ℝ} (hN : 4 ≤ N) : + Real.log N ≤ N / 2 * Real.log 2 := by + have hN0 : 0 < N := by linarith + have h := Real.log_le_sub_one_of_pos (div_pos hN0 (by norm_num : (0 : ℝ) < 4)) + rw [Real.log_div hN0.ne' (by norm_num), + show Real.log 4 = 2 * Real.log 2 by + rw [show (4 : ℝ) = 2 ^ 2 by norm_num, Real.log_pow]; norm_num] at h + have h2 := Real.log_two_gt_d9 + nlinarith [mul_nonneg (by linarith : 0 ≤ N - 4) (by linarith : 0 ≤ Real.log 2 - 1 / 2)] + +/-- On `[2,N]`, concavity puts `log t` above `t * log N / N`. -/ +lemma log_chord_lower {N t : ℝ} (hN : 4 ≤ N) (ht : 2 ≤ t) (htN : t ≤ N) : + t * (Real.log N / N) ≤ Real.log t := by + have hN0 : 0 < N := by linarith + have hden : 0 < N - 2 := by linarith + let u := (N - t) / (N - 2) + let v := (t - 2) / (N - 2) + have hu : 0 ≤ u := div_nonneg (sub_nonneg.mpr htN) hden.le + have hv : 0 ≤ v := div_nonneg (by linarith) hden.le + have huv : u + v = 1 := by dsimp [u, v]; field_simp; ring + have htuv : u * 2 + v * N = t := by dsimp [u, v]; field_simp; ring + have hconc := strictConcaveOn_log_Ioi.concaveOn.2 + (show (0 : ℝ) < 2 by norm_num) hN0 hu hv huv + simp only [smul_eq_mul, htuv] at hconc + have hend : 2 * Real.log N / N ≤ Real.log 2 := by + apply (div_le_iff₀ hN0).2 + nlinarith [log_le_mul_log_two hN] + calc + t * (Real.log N / N) = u * (2 * Real.log N / N) + v * Real.log N := by + dsimp [u, v] + field_simp + ring + _ ≤ u * Real.log 2 + v * Real.log N := + add_le_add (mul_le_mul_of_nonneg_left hend hu) le_rfl + _ ≤ Real.log t := hconc + +/-- The logarithmic endpoint comparison holds uniformly in delta. -/ +lemma log_mul_div_delta {N δ : ℝ} (hN : 4 ≤ N) (hδ : 0 < δ) + (hδ1 : δ ≤ 1) (hlarge : 2 ≤ N * δ) : + Real.log N ≤ Real.log (N * δ) / δ := by + apply (le_div_iff₀ hδ).2 + have h := log_chord_lower hN hlarge + (mul_le_of_le_one_right (by linarith : 0 ≤ N) hδ1) + have hN0 : N ≠ 0 := by linarith + have heq : N * δ * (Real.log N / N) = Real.log N * δ := by + field_simp + rwa [heq] at h + +/-- A small, genuine logarithmic numerical certificate, not a hypothesis. -/ +lemma log_129_gt : (24 : ℝ) / 5 < Real.log 129 := by + have h := Real.log_two_gt_d9 + have he : Real.log 128 = 7 * Real.log 2 := by + rw [show (128 : ℝ) = 2 ^ 7 by norm_num, Real.log_pow] + norm_num + have hmono : Real.log 128 ≤ Real.log 129 := Real.log_le_log (by norm_num) (by norm_num) + rw [he] at hmono + linarith + +/-- A convenient uniform upper bound on `log N / N`. -/ +lemma log_div_le_half {N : ℝ} (hN : 4 ≤ N) : Real.log N / N ≤ 1 / 2 := by + have hN0 : 0 < N := by linarith + apply (div_le_iff₀ hN0).2 + have h := log_le_mul_log_two hN + have h2 := Real.log_le_sub_one_of_pos (by norm_num : (0 : ℝ) < 2) + nlinarith [mul_nonneg hN0.le (by linarith : 0 ≤ 1 - Real.log 2)] + +/-- The small-delta branch uses the stronger rational polar estimate. -/ +theorem three_fifths_lt_c {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hsmall : (((m : ℝ) + 2) / 2) * (1 - a ^ 2) < 2) : + (3 : ℝ) / 5 < c a x := by + have hd := PaperSecant.delta_pos ha ha1 + have hα := PaperPolar.alpha_pos (by omega : 0 < m) ha ha1 + have hα2 : alpha m a < 2 := by unfold alpha; nlinarith + have hb := b_le_alpha (by omega : 0 < m) ha ha1 hx0 hx1 hr + have hfrac : alpha m a / (3 + alpha m a) < (2 : ℝ) / 5 := by + apply (div_lt_iff₀ (by linarith : 0 < 3 + alpha m a)).2 + linarith + unfold c + linarith + +/-- A global logarithmic bound derived solely from raw polar. -/ +theorem log_degree_le_c {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + Real.log (((m : ℝ) + 2) / 2) / (((m : ℝ) + 2) / 2) ≤ c a x := by + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + have hN : 4 ≤ ((m : ℝ) + 2) / 2 := by linarith + have hN0 : 0 < ((m : ℝ) + 2) / 2 := by positivity + have hd := PaperSecant.delta_pos ha ha1 + by_cases hlarge : 2 ≤ (((m : ℝ) + 2) / 2) * (1 - a ^ 2) + · have hlog := log_mul_div_delta hN hd (by nlinarith [sq_nonneg a]) hlarge + have hraw := log_mul_delta_le hm ha ha1 hx0 hx1 hr + have hlog' := (le_div_iff₀ hd).mp hlog + apply (div_le_iff₀ hN0).2 + nlinarith + · have hc := three_fifths_lt_c hm ha ha1 hx0 hx1 hr (lt_of_not_ge hlarge) + exact (log_div_le_half hN).trans (by linarith) + +/-- Elementary endpoint suppression from the logarithmic bound. -/ +lemma rpow_endpoint {N B : ℝ} (hN : 4 ≤ N) (hB : 0 < B) + (hc : Real.log N / N ≤ 1 - B) : B ^ (N - 1) ≤ 2 / N := by + have hN0 : 0 < N := by linarith + have hlogB : Real.log B ≤ -(Real.log N / N) := by + have h := Real.log_le_sub_one_of_pos hB + linarith + have hpow := mul_le_mul_of_nonneg_left hlogB (by linarith : 0 ≤ N - 1) + have hexp : -(N - 1) * (Real.log N / N) = Real.log N / N - Real.log N := by + field_simp + ring + have htwo : Real.log N / N ≤ Real.log 2 := + (log_div_le_half hN).trans (by linarith [Real.log_two_gt_d9]) + apply (Real.log_le_log_iff (Real.rpow_pos_of_pos hB _) (div_pos (by norm_num) hN0)).mp + rw [Real.log_rpow hB, Real.log_div (by norm_num) hN0.ne'] + nlinarith + +/-- The global endpoint estimate, for all real `a` in `(0,1)` and all degrees `m ≥ 7`. -/ +theorem endpoint_le {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : b a x ^ ((m : ℝ) / 2) ≤ 4 / ((m : ℝ) + 2) := by + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + have h := rpow_endpoint (N := ((m : ℝ) + 2) / 2) (by linarith) + (b_pos ha.le ha1 hx1) (log_degree_le_c hm ha ha1 hx0 hx1 hr) + rw [show ((m : ℝ) + 2) / 2 - 1 = (m : ℝ) / 2 by ring] at h + calc + b a x ^ ((m : ℝ) / 2) ≤ 2 / (((m : ℝ) + 2) / 2) := h + _ = 4 / ((m : ℝ) + 2) := by field_simp; norm_num + +/-- The second global endpoint estimate, with a strict degree-256 base. -/ +theorem degree_mul_sq_gt {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : (19 : ℝ) / 2 < (m : ℝ) * x ^ 2 := by + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast hm + have hN : (129 : ℝ) ≤ ((m : ℝ) + 2) / 2 := by linarith + have hN0 : 0 < ((m : ℝ) + 2) / 2 := by positivity + have hlog : (24 : ℝ) / 5 < Real.log (((m : ℝ) + 2) / 2) := + log_129_gt.trans_le (Real.log_le_log (by norm_num) hN) + have hc := (div_le_iff₀ hN0).mp (log_degree_le_c (by omega) ha ha1 hx0 hx1 hr) + have hcx : c a x ≤ x ^ 2 := by unfold c b; nlinarith [sq_nonneg (x - a)] + have hmul := mul_le_mul_of_nonneg_right hcx hN0.le + have hx : 0 ≤ x ^ 2 := sq_nonneg x + have hpositive : 0 < c a x := (geometry (by omega) ha ha1 hx0 hx1 hr).2 + have hscaled : (24 : ℝ) / 5 < (((m : ℝ) + 2) / 2) * x ^ 2 := by nlinarith + have hfactor : (m : ℝ) + 2 ≤ (129 : ℝ) / 128 * m := by linarith + have hlast := mul_le_mul_of_nonneg_right hfactor hx + nlinarith + +end Sendov.PaperGlobalPolar diff --git a/Sendov/Analytic/PaperNearMargins.lean b/Sendov/Analytic/PaperNearMargins.lean new file mode 100644 index 0000000..f897fdb --- /dev/null +++ b/Sendov/Analytic/PaperNearMargins.lean @@ -0,0 +1,147 @@ +import Sendov.Analytic.PaperNear + +/-! +# Historical near-endpoint margins for the actual integral budget + +Preserves first-origin-uniform/REPORT.md §4.2, round3 §2 and round5 §2: +`λ ≤ 1/50` gives `h/3`, `λ ≤ 1/10` gives `h/5`, and `λ ≤ 1/5` +gives `h/80`. The earlier legacy_RESULT.md `λ ≤ 1/100`, `h/3` result +is included as a corollary. These are not consequences of the weaker +`λ ≤ 2/5`, `h/1000` conclusion. + +The stronger raw-polar parameter errors and the geometric endpoint bound +from `PaperNear` suffice. First move the correlated sum `f+g` to the +chosen cutoff; then elementary denominator bounds leave rational slack. +-/ + +namespace Sendov.PaperNearMargins + +/-- Bound the first error at a fixed cutoff, uniformly in the degree. -/ +lemma f_le_cutoff_bound {τ k : ℝ} (_hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) + (hk : 0 ≤ k) (hk2 : k ≤ 2 / 5) : + PaperNear.f τ k ≤ 1 / ((1 - k / 7) * (5 / 7) * (3 + k)) := by + have ha : 0 < 1 - k / 7 := by linarith + have hc : 0 < 1 - 2 * τ := by linarith + have hb : 1 - k / 7 ≤ 1 - k * τ := by nlinarith + have hd : (5 / 7 : ℝ) ≤ 1 - 2 * τ := by linarith + have hp := mul_le_mul hb hd (by norm_num : (0 : ℝ) ≤ 5 / 7) (by linarith) + have hden := mul_le_mul_of_nonneg_right hp (by linarith : 0 ≤ 3 + k) + unfold PaperNear.f PaperNear.P + exact one_div_le_one_div_of_le (by positivity) hden + +/-- Bound the second error at a fixed cutoff using `Q ≥ 1`. -/ +lemma g_le_cutoff_bound {τ k : ℝ} (hτ : 0 ≤ τ) (hk : 0 ≤ k) : + PaperNear.g τ k ≤ (4 / 27 : ℝ) * k * (3 + k) ^ 2 := by + have hq : (1 : ℝ) ≤ PaperNear.Q τ := by + unfold PaperNear.Q + nlinarith [sq_nonneg τ] + unfold PaperNear.g + apply (div_le_iff₀ (by linarith : 0 < PaperNear.Q τ)).2 + simpa only [mul_one] using mul_le_mul_of_nonneg_left hq + (show 0 ≤ (4 / 27 : ℝ) * k * (3 + k) ^ 2 by positivity) + +/-- A reusable scalar certificate. The last hypothesis is just rational +arithmetic at the selected cutoff, not an assumption on the actual budget. -/ +theorem rational_remainder_gt {τ ℓ k r : ℝ} + (hτ : 0 ≤ τ) (hτ7 : τ ≤ 1 / 7) (hℓ : 0 ≤ ℓ) (hℓk : ℓ ≤ k) + (hk2 : k ≤ 2 / 5) + (hcert : r < 7 / 8 - 1 / ((1 - k / 7) * (5 / 7) * (3 + k)) - + (4 / 27 : ℝ) * k * (3 + k) ^ 2 - 1 / 80) : + r < 1 / (1 + τ) - (PaperNear.f τ ℓ + PaperNear.g τ ℓ) - 1 / 80 := by + have hk : 0 ≤ k := hℓ.trans hℓk + have hfg := PaperNear.fg_difference_lower τ ℓ k hτ hτ7 hℓ hℓk hk2 + have hf := f_le_cutoff_bound hτ hτ7 hk hk2 + have hg := g_le_cutoff_bound hτ hk + have hbase : (7 / 8 : ℝ) ≤ 1 / (1 + τ) := by + apply (le_div_iff₀ (by positivity : 0 < 1 + τ)).2 + linarith + linarith + +/-- Transfer any certified rational remainder to the actual raw-polar budget. +No Taylor error, chord positivity, or endpoint estimate is assumed. -/ +theorem margin_of_rational {m : ℕ} {a x r : ℝ} (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 2 / 5) + (hr : r < 1 / (1 + 1 / (m : ℝ)) - + (PaperNear.f (1 / (m : ℝ)) (PaperPolar.lambda m a) + + PaperNear.g (1 / (m : ℝ)) (PaperPolar.lambda m a)) - 1 / 80) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x > + (1 - a) * r := by + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + have hm0 : (0 : ℝ) < m := by linarith + have hp1 : (0 : ℝ) < (m : ℝ) + 1 := by positivity + have hh : 0 < 1 - a := by linarith + have hc : 0 < PaperTaylor.chord a x := by + have h := (PaperPolar.geometry hm ha0 ha1 hx0 hx1 hraw).2 + convert h using 1 + unfold PaperTaylor.chord PaperPolar.c PaperPolar.b + ring + have hbudget := PaperTaylor.budget_le hm' ha0 ha1 hx1 hc + have herr := PaperNearClosure.parameter_errors hm ha0 ha1 hx0 hx1 hraw + have hend := (div_lt_iff₀ hh).mp + (PaperNearClosure.endpoint_term_lt hm ha0 ha1 hx0 hx1 hraw hnear) + have he : PaperTaylor.beta a x 1 = PaperPolar.b a x := by + simp [PaperTaylor.beta, PaperPolar.b] + rw [he] at hbudget + have hrem := mul_lt_mul_of_pos_left hr hh + have hbase : 1 - (m : ℝ) * a / ((m : ℝ) + 1) - 1 / ((m : ℝ) + 1) = + (1 - a) * (1 / (1 + 1 / (m : ℝ))) := by + field_simp + ring + nlinarith only [hbudget, herr.1, herr.2, hend, hrem, hbase] + +/-- Raw-polar closure from an explicit rational cutoff certificate. -/ +theorem margin_of_cutoff {m : ℕ} {a x k r : ℝ} (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ k) + (hk2 : k ≤ 2 / 5) + (hcert : r < 7 / 8 - 1 / ((1 - k / 7) * (5 / 7) * (3 + k)) - + (4 / 27 : ℝ) * k * (3 + k) ^ 2 - 1 / 80) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x > + (1 - a) * r := by + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + have ht7 : 1 / (m : ℝ) ≤ (1 / 7 : ℝ) := + one_div_le_one_div_of_le (by norm_num) hm' + exact margin_of_rational hm ha0 ha1 hx0 hx1 hraw (hnear.trans hk2) + (rational_remainder_gt (by positivity) ht7 + (PaperPolar.lambda_pos (by omega : 0 < m) ha1).le hnear hk2 hcert) + +/-- Original uniform thin layer: retain the strict `h/3` margin. -/ +theorem near_endpoint_one_fiftieth {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 1 / 50) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x > + (1 - a) / 3 := by + simpa only [div_eq_mul_inv, one_mul] using + margin_of_cutoff (r := 1 / 3) hm ha0 ha1 hx0 hx1 hraw hnear + (by norm_num) (by norm_num) + +/-- Round3: retain the strict `h/5` margin on the larger thin layer. -/ +theorem near_endpoint_one_tenth {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 1 / 10) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x > + (1 - a) / 5 := by + simpa only [div_eq_mul_inv, one_mul] using + margin_of_cutoff (r := 1 / 5) hm ha0 ha1 hx0 hx1 hraw hnear + (by norm_num) (by norm_num) + +/-- Round5: retain the strict `h/80` margin. -/ +theorem near_endpoint_one_fifth {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 1 / 5) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x > + (1 - a) / 80 := by + simpa only [div_eq_mul_inv, one_mul] using + margin_of_cutoff (r := 1 / 80) hm ha0 ha1 hx0 hx1 hraw hnear + (by norm_num) (by norm_num) + +/-- The precise earlier legacy_RESULT margin, inherited without weakening. -/ +theorem near_endpoint_one_hundredth {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 1 / 100) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x > + (1 - a) / 3 := + near_endpoint_one_fiftieth hm ha0 ha1 hx0 hx1 hraw (by linarith) + +end Sendov.PaperNearMargins diff --git a/Sendov/Analytic/PaperRayGeometry.lean b/Sendov/Analytic/PaperRayGeometry.lean new file mode 100644 index 0000000..630798c --- /dev/null +++ b/Sendov/Analytic/PaperRayGeometry.lean @@ -0,0 +1,373 @@ +import Sendov.Analytic.PaperPolar +import Sendov.Analytic.PaperRayAlgebra +import Mathlib.Analysis.Convex.SpecificFunctions.Basic +import Mathlib.Analysis.Complex.ExponentialBounds + +/-! +# Finite-ray geometry and the actual budget, from raw polar + +All geometric conclusions below consume the raw integral, not assumed endpoint +ceilings. The rational polar bound suffices through lambda=25. The ceiling +23/25 uses convexity of the exponential chord and a fixed endpoint at 49. +The first budget interval is deliberately [2/5,1], not the paper's [1/5,1]: +`PaperNearClosure.near_endpoint_D` covers the omitted near-endpoint region. +No upper-tail estimate is asserted in this module. +-/ +namespace Sendov.PaperRayGeometry + +open MeasureTheory PaperPolar + +/-- The true available budget B (not the origin expression T). -/ +noncomputable def B (m : ℕ) (a : ℝ) : ℝ := 1 - (m : ℝ) * a / ((m : ℝ) + 1) + +lemma scaled_budget_eq (m : ℕ) (a x : ℝ) : + (m : ℝ) * x ^ 2 * B m a = + (m : ℝ) / ((m : ℝ) + 1) * ((lambda m a + 1) * x ^ 2) := by + unfold B lambda + have hd : (m : ℝ) + 1 ≠ 0 := by positivity + field_simp + ring + +lemma a_lower {m : ℕ} {a L : ℝ} (hm : 256 ≤ m) (ha1 : a < 1) + (hl : lambda m a ≤ L) : 1 - L / 256 ≤ a := by + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast hm + have hh := mul_nonneg (sub_nonneg.mpr hm') (show 0 ≤ 1 - a by linarith) + unfold lambda at hl + nlinarith + +lemma b_le_lambda {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) : b a x ≤ lambda m a / (3 + lambda m a) := by + obtain ⟨h₁, h₂⟩ := endpoint_bounds hm ha0 ha1 hx0 hx1 hraw + exact h₁.trans h₂ + +/-- The exact conversion loses only b/(2a), not an unweighted 2h. -/ +lemma x_lower_of_b {a x q : ℝ} (ha : 0 < a) (hb : b a x ≤ q) : + 1 - q / (2 * a) ≤ x := by + have hden : 0 < 2 * a := by positivity + have hh : q / (2 * a) * (2 * a) = q := div_mul_cancel₀ _ hden.ne' + unfold b at hb + nlinarith [sq_nonneg (1 - a)] + +lemma x_lower_constant {a x A q : ℝ} (hA : 0 < A) (ha : A ≤ a) + (hq : 0 ≤ q) (hb : b a x ≤ q) : 1 - q / (2 * A) ≤ x := by + have ha0 : 0 < a := hA.trans_le ha + have hx := x_lower_of_b ha0 hb + have hdiv : q / (2 * a) ≤ q / (2 * A) := by + apply (div_le_div_iff₀ (by positivity) (by positivity)).2 + nlinarith + linarith + +variable {m : ℕ} {a x : ℝ} + +/-- All m>=256, lambda<=10: both endpoint and vertex geometry. -/ +theorem geometry_ten (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl : lambda m a ≤ 10) : + b a x < 4 / 5 ∧ 7 / 12 < x := by + have hlpos := lambda_pos (by omega : 0 < m) ha1 + have hb := (b_le_lambda (by omega) ha0 ha1 hx0 hx1 hraw).trans + (rational_mono hlpos.le hl) + norm_num at hb + have ha := a_lower hm ha1 hl + norm_num at ha + have hx := x_lower_constant (by norm_num : (0 : ℝ) < 123 / 128) ha + (by norm_num : (0 : ℝ) ≤ 10 / 13) hb + constructor <;> norm_num at * <;> linarith + +theorem geometry_one (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl : lambda m a ≤ 1) : 5 / 6 < x := by + have hlpos := lambda_pos (by omega : 0 < m) ha1 + have hb := (b_le_lambda (by omega) ha0 ha1 hx0 hx1 hraw).trans + (rational_mono hlpos.le hl) + norm_num at hb + have ha := a_lower hm ha1 hl + norm_num at ha + have hx := x_lower_constant (by norm_num : (0 : ℝ) < 255 / 256) ha + (by norm_num : (0 : ℝ) ≤ 1 / 4) hb + norm_num at hx + linarith + +theorem geometry_twentyfive (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl : lambda m a ≤ 25) : + b a x < 9 / 10 ∧ 231 / 512 < x := by + have hlpos := lambda_pos (by omega : 0 < m) ha1 + have hb := (b_le_lambda (by omega) ha0 ha1 hx0 hx1 hraw).trans + (rational_mono hlpos.le hl) + have ha := a_lower hm ha1 hl + have hx := (geometry (by omega) ha0 ha1 hx0 hx1 hraw).1 + constructor <;> norm_num at * <;> linarith + +/-- Convexity in the ray parameter, integrated on the full interval. +The strictly positive alpha rules out the equality at the zero endpoint. -/ +lemma integral_exp_lt_one_of_fixed {α L q : ℝ} (hα : 0 < α) (hαL : α ≤ L) + (hfixed : (∫ t in (0 : ℝ)..1, Real.exp (L * (-1 + (2 - q) * t))) < 1) : + (∫ t in (0 : ℝ)..1, Real.exp (α * (-1 + (2 - q) * t))) < 1 := by + have hL : 0 < L := hα.trans_le hαL + have hw : 0 < α / L := div_pos hα hL + have hw1 : α / L ≤ 1 := (div_le_one hL).2 hαL + have hpt (t : ℝ) : Real.exp (α * (-1 + (2 - q) * t)) ≤ + (1 - α / L) + α / L * Real.exp (L * (-1 + (2 - q) * t)) := by + have hc := convexOn_exp.2 (Set.mem_univ (0 : ℝ)) + (Set.mem_univ (L * (-1 + (2 - q) * t))) + (show 0 ≤ 1 - α / L by linarith) hw.le (by ring : 1 - α / L + α / L = 1) + simp only [smul_eq_mul, mul_zero, zero_add, Real.exp_zero, mul_one] at hc + rw [← mul_assoc, div_mul_cancel₀ _ hL.ne'] at hc + exact hc + have hi := intervalIntegral.integral_mono_on (μ := volume) (a := (0 : ℝ)) (b := 1) (by norm_num) + ((by fun_prop : Continuous fun t : ℝ => + Real.exp (α * (-1 + (2 - q) * t))).intervalIntegrable _ _) + ((by fun_prop : Continuous fun t : ℝ => + (1 - α / L) + α / L * Real.exp (L * (-1 + (2 - q) * t))).intervalIntegrable _ _) + (fun t _ => hpt t) + rw [intervalIntegral.integral_add + (intervalIntegrable_const : IntervalIntegrable (fun _ : ℝ => 1 - α / L) volume 0 1) + ((by fun_prop : Continuous fun t : ℝ => + α / L * Real.exp (L * (-1 + (2 - q) * t))).intervalIntegrable _ _), + intervalIntegral.integral_const_mul] at hi + simp only [intervalIntegral.integral_const, sub_zero, smul_eq_mul, one_mul] at hi + have hstrict := mul_pos hw (sub_pos.mpr hfixed) + nlinarith + +/-- A reusable fixed-endpoint obstruction to raw polar. -/ +lemma b_lt_of_fixed (hm : 0 < m) (ha0 : 0 < a) (ha1 : a < 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hraw : RawPolar m a x) + {L q : ℝ} (hL : lambda m a ≤ L) + (hfixed : (∫ t in (0 : ℝ)..1, Real.exp (L * (-1 + (2 - q) * t))) < 1) : + b a x < q := by + by_contra hn + have hq : q ≤ b a x := le_of_not_gt hn + have hα := PaperPolar.alpha_pos hm ha0 ha1 + have hi := one_le_integral_exp hm hx0 hx1 hraw + have hmono := intervalIntegral.integral_mono_on + (μ := volume) (a := (0 : ℝ)) (b := 1) (by norm_num) + ((by fun_prop : Continuous fun t : ℝ => + Real.exp (alpha m a * (-1 + (2 - b a x) * t))).intervalIntegrable _ _) + ((by fun_prop : Continuous fun t : ℝ => + Real.exp (alpha m a * (-1 + (2 - q) * t))).intervalIntegrable _ _) (fun t ht => by + apply Real.exp_le_exp.mpr + nlinarith [mul_nonneg (mul_nonneg hα.le ht.1) (sub_nonneg.mpr hq)]) + exact (not_lt_of_ge (hi.trans hmono)) + (integral_exp_lt_one_of_fixed hα ((alpha_le_lambda m a).trans hL) hfixed) + +lemma exp_fixed_49 : Real.exp (98 / 25 : ℝ) < 1323 / 25 := by + have he : Real.exp (1 : ℝ) < 11 / 4 := Real.exp_one_lt_d9.trans (by norm_num) + have hp : Real.exp (98 / 25 : ℝ) ^ 25 < (1323 / 25 : ℝ) ^ 25 := by + calc + Real.exp (98 / 25 : ℝ) ^ 25 = Real.exp (1 : ℝ) ^ 98 := by + rw [← Real.exp_nat_mul, ← Real.exp_nat_mul] + norm_num + _ ≤ (11 / 4 : ℝ) ^ 98 := pow_le_pow_left₀ (Real.exp_nonneg _) he.le _ + _ < (1323 / 25 : ℝ) ^ 25 := by norm_num + exact (pow_lt_pow_iff_left₀ (Real.exp_nonneg _) (by norm_num) + (by norm_num : (25 : ℕ) ≠ 0)).mp hp + +lemma fixed_49_integral_lt_one : + (∫ t in (0 : ℝ)..1, Real.exp (49 * (-1 + (2 - 23 / 25) * t))) < 1 := by + rw [Sendov.integral_exp_eq' (by norm_num : (0 : ℝ) < 49) + (by norm_num : (23 / 25 : ℝ) < 2)] + norm_num + have he := exp_fixed_49 + have hp := Real.exp_pos (-49 : ℝ) + linarith + +theorem geometry_fortynine (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl : lambda m a ≤ 49) : + b a x < 23 / 25 ∧ 207 / 512 < x := by + refine ⟨b_lt_of_fixed (by omega) ha0 ha1 hx0 hx1 hraw hl fixed_49_integral_lt_one, ?_⟩ + have ha := a_lower hm ha1 hl + have hx := (geometry (by omega) ha0 ha1 hx0 hx1 hraw).1 + norm_num at ha + linarith + +/-- Scaling a lower bound for (lambda+1)x² gives a lower bound for the true B. -/ +lemma scaled_budget_lower {C : ℝ} (hp : C ≤ (lambda m a + 1) * x ^ 2) : + (m : ℝ) / ((m : ℝ) + 1) * C ≤ (m : ℝ) * x ^ 2 * B m a := by + rw [scaled_budget_eq] + exact mul_le_mul_of_nonneg_left hp (by positivity) + +lemma scaled_budget_lower_of_x {l s : ℝ} (hl : l ≤ lambda m a) (hl0 : 0 ≤ l + 1) + (hs : 0 ≤ s) (hx : s ≤ x) : + (m : ℝ) / ((m : ℝ) + 1) * ((l + 1) * s ^ 2) ≤ + (m : ℝ) * x ^ 2 * B m a := by + apply scaled_budget_lower + have hx2 : s ^ 2 ≤ x ^ 2 := by nlinarith + have h₁ := mul_nonneg (sq_nonneg x) (sub_nonneg.mpr hl) + have h₂ := mul_nonneg hl0 (sub_nonneg.mpr hx2) + nlinarith + +/-- A rational replacement for the sinh-root budget argument, on the altered +region [2/5,1]. Its uniform product lower bound is 11/10. -/ +lemma product_lower_one (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl0 : 2 / 5 ≤ lambda m a) (hl1 : lambda m a ≤ 1) : + 11 / 10 ≤ (lambda m a + 1) * x ^ 2 := by + have hlpos : 0 ≤ lambda m a := by linarith + have hb := b_le_lambda (by omega) ha0 ha1 hx0 hx1 hraw + have hrat : lambda m a / (3 + lambda m a) ≤ lambda m a / 3 := by + apply (div_le_div_iff₀ (by positivity) (by norm_num)).2 + nlinarith [sq_nonneg (lambda m a)] + have ha := a_lower hm ha1 hl1 + norm_num at ha + have hx := x_lower_constant (by norm_num : (0 : ℝ) < 255 / 256) ha + (show 0 ≤ lambda m a / 3 by positivity) (hb.trans hrat) + have hxlin : 1 - 128 / 765 * lambda m a ≤ x := by + convert hx using 1 + ring + have hx2 : 1 - 256 / 765 * lambda m a ≤ x ^ 2 := by + nlinarith [sq_nonneg (x - 1)] + have hmul := mul_nonneg (show 0 ≤ lambda m a + 1 by positivity) + (sub_nonneg.mpr hx2) + have hquad := mul_nonneg hlpos (sub_nonneg.mpr hl1) + nlinarith + +/-- Actual lower budget on [2/5,1]; this intentionally does not claim [1/5,1]. -/ +theorem budget_lower_one (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl0 : 2 / 5 ≤ lambda m a) (hl1 : lambda m a ≤ 1) : + 1 + 18 / (m : ℝ) < (m : ℝ) * x ^ 2 * B m a := by + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast hm + have hc := PaperRay.compare_from_base (M := 256) (C := 11 / 10) (E := 0) + (K := 18) (z := 0) (by norm_num) hm' (by norm_num) (by norm_num) + (by norm_num) (by norm_num) + simp only [zero_div, sub_zero, add_zero] at hc + exact hc.trans_le (scaled_budget_lower + (product_lower_one hm ha0 ha1 hx0 hx1 hraw hl0 hl1)) + +/-- The rational endpoint bound gives a product >=6/5 on [1,5]. +The split at 2 uses constant rational lower bounds for x, not a grid in m. -/ +lemma product_lower_five (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl0 : 1 ≤ lambda m a) (hl1 : lambda m a ≤ 5) : + 6 / 5 ≤ (lambda m a + 1) * x ^ 2 := by + have hlpos : 0 ≤ lambda m a := by linarith + have hb := b_le_lambda (by omega) ha0 ha1 hx0 hx1 hraw + have ha := a_lower hm ha1 hl1 + norm_num at ha + by_cases hl2 : lambda m a ≤ 2 + · have hb2 := hb.trans (rational_mono hlpos hl2) + norm_num at hb2 + have hx := x_lower_constant (by norm_num : (0 : ℝ) < 251 / 256) ha + (by norm_num : (0 : ℝ) ≤ 2 / 5) hb2 + have hxs : 79 / 100 ≤ x := by norm_num at hx; linarith + have hx2 : (79 / 100 : ℝ) ^ 2 ≤ x ^ 2 := by nlinarith + have hmul := mul_nonneg (sq_nonneg x) (show 0 ≤ lambda m a - 1 by linarith) + nlinarith + · have hb5 := hb.trans (rational_mono hlpos hl1) + norm_num at hb5 + have hx := x_lower_constant (by norm_num : (0 : ℝ) < 251 / 256) ha + (by norm_num : (0 : ℝ) ≤ 5 / 8) hb5 + have hxs : 17 / 25 ≤ x := by norm_num at hx; linarith + have hx2 : (17 / 25 : ℝ) ^ 2 ≤ x ^ 2 := by nlinarith + have hmul := mul_nonneg (sq_nonneg x) (show 0 ≤ lambda m a - 2 by linarith) + nlinarith + +theorem budget_lower_five (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl0 : 1 ≤ lambda m a) (hl1 : lambda m a ≤ 5) : + 1 + 33 / (m : ℝ) < (m : ℝ) * x ^ 2 * B m a := by + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast hm + have hc := PaperRay.compare_from_base (M := 256) (C := 6 / 5) (E := 0) + (K := 33) (z := 0) (by norm_num) hm' (by norm_num) (by norm_num) + (by norm_num) (by norm_num) + simp only [zero_div, sub_zero, add_zero] at hc + exact hc.trans_le (scaled_budget_lower + (product_lower_five hm ha0 ha1 hx0 hx1 hraw hl0 hl1)) + +/-- The whole middle ray, including both seams 1 and 10. -/ +theorem budget_lower_ten (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl0 : 1 ≤ lambda m a) (hl1 : lambda m a ≤ 10) : + 1 + 33 / (m : ℝ) < (m : ℝ) * x ^ 2 * B m a := by + by_cases hl5 : lambda m a ≤ 5 + · exact budget_lower_five hm ha0 ha1 hx0 hx1 hraw hl0 hl5 + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast hm + have hx := (geometry_ten hm ha0 ha1 hx0 hx1 hraw hl1).2 + refine (PaperRay.ray_three hm').trans_le ?_ + simpa only [show (5 : ℝ) + 1 = 6 by norm_num] using + scaled_budget_lower_of_x (by linarith : 5 ≤ lambda m a) (by norm_num) + (by norm_num : (0 : ℝ) ≤ 7 / 12) hx.le + +theorem budget_lower_twentyfive (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl0 : 10 ≤ lambda m a) (hl1 : lambda m a ≤ 25) : + 1 + 51 / (m : ℝ) + 1 / 4 < (m : ℝ) * x ^ 2 * B m a := by + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast hm + have hx := (geometry_twentyfive hm ha0 ha1 hx0 hx1 hraw hl1).2 + refine (PaperRay.ray_four hm').trans_le ?_ + simpa only [show (10 : ℝ) + 1 = 11 by norm_num] using + scaled_budget_lower_of_x hl0 (by norm_num) + (by norm_num : (0 : ℝ) ≤ 231 / 512) hx.le + +theorem budget_lower_fortynine (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl0 : 25 ≤ lambda m a) (hl1 : lambda m a ≤ 49) : + 1 + 62 / (m : ℝ) + 2 < (m : ℝ) * x ^ 2 * B m a := by + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast hm + have hx := (geometry_fortynine hm ha0 ha1 hx0 hx1 hraw hl1).2 + refine (PaperRay.ray_five hm').trans_le ?_ + simpa only [show (25 : ℝ) + 1 = 26 by norm_num] using + scaled_budget_lower_of_x hl0 (by norm_num) + (by norm_num : (0 : ℝ) ≤ 207 / 512) hx.le + +/-- The actual Laplace splitting point is inside the integration interval. -/ +theorem halfpoint_mem (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl : lambda m a ≤ 49) : + x / (2 * a) ∈ Set.Ioo (0 : ℝ) 1 := by + have ha := a_lower hm ha1 hl + have hx := (geometry (by omega) ha0 ha1 hx0 hx1 hraw).1 + constructor + · exact div_pos (by linarith) (by positivity) + · apply (div_lt_one (by positivity : 0 < 2 * a)).2 + linarith + +lemma beta_halfpoint (ha0 : 0 < a) : + beta a x (x / (2 * a)) = 1 - 3 * x ^ 2 / 4 := by + unfold beta + field_simp + ring + +/-- Both endpoints needed for the Laplace remainder; no integral bound is assumed. -/ +theorem laplace_endpoints_ten (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl : lambda m a ≤ 10) : + b a x < 4 / 5 ∧ beta a x (x / (2 * a)) < 4 / 5 := by + obtain ⟨hb, hx⟩ := geometry_ten hm ha0 ha1 hx0 hx1 hraw hl + refine ⟨hb, ?_⟩ + rw [beta_halfpoint ha0] + have hx2 : (7 / 12 : ℝ) ^ 2 < x ^ 2 := by nlinarith + nlinarith + +/-- Both endpoints needed for the Laplace remainder; no integral bound is assumed. -/ +theorem laplace_endpoints_twentyfive (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl : lambda m a ≤ 25) : + b a x < 9 / 10 ∧ beta a x (x / (2 * a)) < 9 / 10 := by + obtain ⟨hb, hx⟩ := geometry_twentyfive hm ha0 ha1 hx0 hx1 hraw hl + refine ⟨hb, ?_⟩ + rw [beta_halfpoint ha0] + have hx2 : (231 / 512 : ℝ) ^ 2 < x ^ 2 := by nlinarith + nlinarith + +/-- Both endpoints needed for the Laplace remainder; no integral bound is assumed. -/ +theorem laplace_endpoints_fortynine (hm : 256 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : RawPolar m a x) (hl : lambda m a ≤ 49) : + b a x < 23 / 25 ∧ beta a x (x / (2 * a)) < 23 / 25 := by + obtain ⟨hb, hx⟩ := geometry_fortynine hm ha0 ha1 hx0 hx1 hraw hl + refine ⟨hb, ?_⟩ + rw [beta_halfpoint ha0] + have hx2 : (207 / 512 : ℝ) ^ 2 < x ^ 2 := by nlinarith + nlinarith + +/-- Cancellation interface for any separately proved upper bound on T. -/ +lemma lt_B_of_scaled_lt {T : ℝ} (hm : 0 < m) (hx : 0 < x) + (h : (m : ℝ) * x ^ 2 * T < (m : ℝ) * x ^ 2 * B m a) : T < B m a := by + have hm' : (0 : ℝ) < m := by exact_mod_cast hm + exact (mul_lt_mul_iff_right₀ (show 0 < (m : ℝ) * x ^ 2 by positivity)).mp h + +end Sendov.PaperRayGeometry diff --git a/Sendov/Analytic/PaperTail.lean b/Sendov/Analytic/PaperTail.lean new file mode 100644 index 0000000..5adc927 --- /dev/null +++ b/Sendov/Analytic/PaperTail.lean @@ -0,0 +1,237 @@ +import Sendov.Analytic.PaperLaplace +import Mathlib.Analysis.Calculus.Deriv.MeanValue + +/-! Uniform real-degree tails and quantitative consequences of sharp Laplace. +All numerical certificates are fixed rational Taylor comparisons; there is no degree table. -/ +namespace Sendov.PaperTail + +/-- A polynomial times a decaying exponential is decreasing past its critical point. -/ +lemma power_exp_antitone {c M d : ℝ} {n : ℕ} (hn : 1 ≤ n) + (hM : 0 < M) (hc : 0 ≤ c) (hcrit : (n : ℝ) ≤ c * M) : + AntitoneOn (fun t : ℝ => t ^ n * Real.exp (-c * (t - d))) (Set.Ici M) := by + have hd (t : ℝ) : HasDerivAt (fun t : ℝ => t ^ n * Real.exp (-c * (t - d))) + (((n : ℝ) * t ^ (n - 1) - c * t ^ n) * Real.exp (-c * (t - d))) t := by + convert! ((hasDerivAt_pow n t).mul + ((((hasDerivAt_id t).sub_const d).const_mul (-c)).exp)) using 1 + dsimp + ring + apply antitoneOn_of_deriv_nonpos (convex_Ici M) (by fun_prop) + · intro t ht + exact (hd t).differentiableAt.differentiableWithinAt + · intro t ht + rw [(hd t).deriv] + have htM : M ≤ t := (interior_subset ht) + have ht0 : 0 ≤ t := hM.le.trans htM + have hct : (n : ℝ) ≤ c * t := hcrit.trans (mul_le_mul_of_nonneg_left htM hc) + have heq : t ^ n = t ^ (n - 1) * t := by + rw [← pow_succ]; congr 1; omega + apply mul_nonpos_of_nonpos_of_nonneg _ (Real.exp_pos _).le + rw [heq] + nlinarith only [mul_nonneg (pow_nonneg ht0 (n - 1)) (sub_nonneg.mpr hct)] + +lemma rpow_le_exp {r m : ℝ} (hr : 0 < r) (hm : 1 ≤ m) : + r ^ ((m - 1) / 2) ≤ Real.exp (-((1 - r) / 2) * (m - 1)) := by + rw [Real.rpow_def_of_pos hr] + apply Real.exp_le_exp.mpr + have h := mul_le_mul_of_nonneg_right (Real.log_le_sub_one_of_pos hr) + (show 0 ≤ (m - 1) / 2 by linarith) + nlinarith + +/-- Generic fixed-endpoint tail certificate. -/ +lemma tail_certificate {m r C : ℝ} {n : ℕ} (hm : 256 ≤ m) (hr : 0 < r) + (hn : 1 ≤ n) (hr1 : r ≤ 1) (hcrit : (n : ℝ) ≤ (1 - r) / 2 * 256) + (hbase : (129 / 256 : ℝ) * 256 ^ n < C * Real.exp ((1 - r) / 2 * 255)) : + (129 / 256 : ℝ) * m ^ n * r ^ ((m - 1) / 2) < C := by + have hm0 : 0 ≤ m := by linarith + have hmono := power_exp_antitone (d := 1) hn (by norm_num : (0 : ℝ) < 256) + (show 0 ≤ (1 - r) / 2 by linarith) hcrit + (show (256 : ℝ) ∈ Set.Ici 256 by simp) hm hm + have hpow := mul_le_mul_of_nonneg_left (rpow_le_exp hr (by linarith : 1 ≤ m)) + (show 0 ≤ (129 / 256 : ℝ) * m ^ n by positivity) + have hbound : (129 / 256 : ℝ) * m ^ n * r ^ ((m - 1) / 2) ≤ + (129 / 256 : ℝ) * 256 ^ n * Real.exp (-((1 - r) / 2) * 255) := by + have h := mul_le_mul_of_nonneg_left hmono (by norm_num : (0 : ℝ) ≤ 129 / 256) + dsimp at h + nlinarith only [hpow, h] + apply hbound.trans_lt + rw [show -((1 - r) / 2) * 255 = -((1 - r) / 2 * 255) by ring, Real.exp_neg] + exact (div_lt_iff₀ (Real.exp_pos _)).mpr hbase |>.trans_eq (by ring) + +/-- The radius `4/5` tail, uniformly in a real degree. -/ +theorem tail_four_fifths {m : ℝ} (hm : 256 ≤ m) : + (m ^ 2 / 2 + m) * (4 / 5 : ℝ) ^ ((m - 1) / 2) < 1 / m := by + have he : (129 / 256 : ℝ) * 256 ^ (3 : ℕ) < Real.exp ((1 - 4 / 5) / 2 * 255) := by + have h := Real.sum_le_exp_of_nonneg (by norm_num : (0 : ℝ) ≤ (1 - 4 / 5) / 2 * 255) 16 + norm_num [Finset.sum_range_succ, Nat.factorial_succ] at h ⊢ + linarith + have h := tail_certificate (n := 3) (C := 1) hm (by norm_num : (0 : ℝ) < 4 / 5) + (by norm_num) (by norm_num) (by norm_num) (by simpa using he) + have hp := Real.rpow_nonneg (by norm_num : (0 : ℝ) ≤ 4 / 5) ((m - 1) / 2) + have hm0 : 0 < m := by linarith + apply (lt_div_iff₀ hm0).mpr + have hc : (m ^ 2 / 2 + m) * m ≤ (129 / 256 : ℝ) * m ^ 3 := by + nlinarith only [mul_nonneg (sq_nonneg m) (show 0 ≤ m - 256 by linarith)] + nlinarith only [mul_le_mul_of_nonneg_right hc hp, h] + +theorem tail_nine_tenths {m : ℝ} (hm : 256 ≤ m) : + (m ^ 2 / 2 + m) * (9 / 10 : ℝ) ^ ((m - 1) / 2) < 1 / 4 := by + have he : (129 / 256 : ℝ) * 256 ^ (2 : ℕ) < + (1 / 4 : ℝ) * Real.exp ((1 - 9 / 10) / 2 * 255) := by + have h := Real.sum_le_exp_of_nonneg (by norm_num : (0 : ℝ) ≤ (1 - 9 / 10) / 2 * 255) 16 + norm_num [Finset.sum_range_succ, Nat.factorial_succ] at h ⊢ + linarith + have h := tail_certificate (n := 2) hm (by norm_num : (0 : ℝ) < 9 / 10) + (by norm_num) (by norm_num) (by norm_num) he + have hc : m ^ 2 / 2 + m ≤ (129 / 256 : ℝ) * m ^ 2 := by + nlinarith only [mul_nonneg (show 0 ≤ m by linarith) (show 0 ≤ m - 256 by linarith)] + exact (mul_le_mul_of_nonneg_right hc (Real.rpow_nonneg (by norm_num) _)).trans_lt h + +theorem tail_twenty_three_twenty_fifths {m : ℝ} (hm : 256 ≤ m) : + (m ^ 2 / 2 + m) * (23 / 25 : ℝ) ^ ((m - 1) / 2) < 2 := by + have he : (129 / 256 : ℝ) * 256 ^ (2 : ℕ) < + (2 : ℝ) * Real.exp ((1 - 23 / 25) / 2 * 255) := by + have h := Real.sum_le_exp_of_nonneg (by norm_num : (0 : ℝ) ≤ (1 - 23 / 25) / 2 * 255) 16 + norm_num [Finset.sum_range_succ, Nat.factorial_succ] at h ⊢ + linarith + have h := tail_certificate (n := 2) hm (by norm_num : (0 : ℝ) < 23 / 25) + (by norm_num) (by norm_num) (by norm_num) he + have hc : m ^ 2 / 2 + m ≤ (129 / 256 : ℝ) * m ^ 2 := by + nlinarith only [mul_nonneg (show 0 ≤ m by linarith) (show 0 ≤ m - 256 by linarith)] + exact (mul_le_mul_of_nonneg_right hc (Real.rpow_nonneg (by norm_num) _)).trans_lt h + +/-- The middle-region correction is decreasing on the entire required range. -/ +theorem middle_antitone : AntitoneOn + (fun k : ℝ => (1 + 5 * k / 8) * Real.exp (-(11 / 30 : ℝ) * k)) + (Set.Ici (19 / 2)) := by + have hd (k : ℝ) : HasDerivAt + (fun k : ℝ => (1 + 5 * k / 8) * Real.exp (-(11 / 30 : ℝ) * k)) + ((5 / 8 - (11 / 30 : ℝ) * (1 + 5 * k / 8)) * Real.exp (-(11 / 30 : ℝ) * k)) k := by + convert! (((((hasDerivAt_id k).const_mul 5).div_const 8).const_add 1).mul + (((hasDerivAt_id k).const_mul (-(11 / 30 : ℝ))).exp)) using 1 + dsimp + ring + apply antitoneOn_of_deriv_nonpos (convex_Ici _) (by fun_prop) + · intro k hk; exact (hd k).differentiableAt.differentiableWithinAt + · intro k hk + rw [(hd k).deriv] + have hk' : 19 / 2 ≤ k := interior_subset hk + exact mul_nonpos_of_nonpos_of_nonneg (by linarith) (Real.exp_pos _).le + +/-- Real-degree middle-region tail, retaining its quadratic coefficient. -/ +theorem middle_tail {m : ℝ} (hm : 256 ≤ m) : + m * (1 + 5 * m / 162) * Real.exp (-22 * m / 1215) < 24 := by + have h1 := power_exp_antitone (n := 1) (c := 22 / 1215) (d := 0) + (by norm_num) (by norm_num : (0 : ℝ) < 256) (by norm_num) (by norm_num) + (show (256 : ℝ) ∈ Set.Ici 256 by simp) hm hm + have h2 := power_exp_antitone (n := 2) (c := 22 / 1215) (d := 0) + (by norm_num) (by norm_num : (0 : ℝ) < 256) (by norm_num) (by norm_num) + (show (256 : ℝ) ∈ Set.Ici 256 by simp) hm hm + have he : (256 : ℝ) * (1 + 5 * 256 / 162) < 24 * Real.exp (22 * 256 / 1215) := by + have h := Real.sum_le_exp_of_nonneg (by norm_num : (0 : ℝ) ≤ 22 * 256 / 1215) 16 + norm_num [Finset.sum_range_succ, Nat.factorial_succ] at h ⊢ + linarith + have hbase : (256 : ℝ) * (1 + 5 * 256 / 162) * Real.exp (-22 * 256 / 1215) < 24 := by + rw [show (-22 * 256 / 1215 : ℝ) = -(22 * 256 / 1215) by ring, Real.exp_neg, ← div_eq_mul_inv] + exact (div_lt_iff₀ (Real.exp_pos _)).mpr he + dsimp at h1 h2 + simp only [sub_zero, pow_one] at h1 h2 + have heq (t : ℝ) : -(22 / 1215 : ℝ) * t = -22 * t / 1215 := by ring + simp only [heq] at h1 h2 + nlinarith only [h1, h2, hbase] + +/-- Uniform rational control of the leading sharp-Laplace term. -/ +lemma laplace_square {m : ℝ} (hm : 256 ≤ m) : + m ^ 2 / (m - 1) ^ 2 ≤ 1 + 3 / m := by + have hm0 : 0 < m := by linarith + have hm1 : 0 < m - 1 := by linarith + apply (div_le_iff₀ (sq_pos_of_pos hm1)).mpr + apply (le_div_iff₀ hm0).mp + field_simp + simp only [npowRec] at * + nlinarith only [sq_nonneg (m - 3), hm] + +lemma laplace_cube {m : ℝ} (hm : 256 ≤ m) : + m ^ 3 / (m - 1) ^ 3 ≤ (253 / 250 : ℝ) := by + have hm1 : 0 < m - 1 := by linarith + have hratio : m / (m - 1) ≤ (256 / 255 : ℝ) := by + apply (div_le_iff₀ hm1).mpr + linarith + have h := pow_le_pow_left₀ (by positivity : 0 ≤ m / (m - 1)) hratio 3 + rw [div_pow] at h + exact h.trans (by norm_num) + +/-- The non-tail part of sharp Laplace, with a reusable lower bound on `x`. -/ +lemma laplace_main_lt {m x q K : ℝ} (hm : 256 ≤ m) (hq : 0 < q) (hx : q ≤ x) + (hK : 3 + (256 / 27 : ℝ) * (253 / 250) / q ^ 2 < K) : + m ^ 2 / (m - 1) ^ 2 + (256 / 27 : ℝ) * m ^ 2 / ((m - 1) ^ 3 * x ^ 2) < + 1 + K / m := by + have hm0 : 0 < m := by linarith + have hx0 : 0 < x := hq.trans_le hx + have hm1 : 0 < m - 1 := by linarith + have hsq : q ^ 2 ≤ x ^ 2 := by nlinarith + have hc : (256 / 27 : ℝ) * m ^ 2 / ((m - 1) ^ 3 * x ^ 2) ≤ + ((256 / 27 : ℝ) * (253 / 250) / q ^ 2) / m := by + calc + _ = (256 / 27 : ℝ) * (m ^ 3 / (m - 1) ^ 3) / x ^ 2 / m := by field_simp + _ ≤ (256 / 27 : ℝ) * (253 / 250) / x ^ 2 / m := by + exact div_le_div_of_nonneg_right (div_le_div_of_nonneg_right + (mul_le_mul_of_nonneg_left (laplace_cube hm) (by norm_num)) (sq_nonneg x)) hm0.le + _ ≤ _ := by gcongr + have h := add_le_add (laplace_square hm) hc + have hK' := (div_lt_div_iff_of_pos_right hm0).mpr hK + rw [add_div] at hK' + linarith only [h, hK'] + +/-- First quantitative region; endpoint assumptions refer to the actual kernel. -/ +theorem budget_region_one {m a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx : 5 / 6 < x) (hx1 : x ≤ 1) (hxa : x < 2 * a) + (hb : PaperTaylor.beta a x 1 ≤ 4 / 5) : + m * x ^ 2 * PaperTaylor.budget m a x < 1 + 18 / m := by + have hx0 : 0 < x := by linarith + have hsplit : 1 - 3 * x ^ 2 / 4 ≤ (4 / 5 : ℝ) := by nlinarith + have h := PaperLaplace.budget_le (by linarith : 1 < m) ha ha1 hx0 hx1 hxa hsplit hb (by norm_num) + have hmain := laplace_main_lt (K := 17) hm (by norm_num : (0 : ℝ) < 5 / 6) hx.le (by norm_num) + have ht := tail_four_fifths hm + have hs := h.trans_lt (add_lt_add hmain ht) + simp only [div_eq_mul_inv] at hs ⊢ + linarith only [hs] + +/-- Second quantitative region. -/ +theorem budget_region_two {m a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx : 7 / 12 < x) (hx1 : x ≤ 1) (hxa : x < 2 * a) + (hb : PaperTaylor.beta a x 1 ≤ 4 / 5) : + m * x ^ 2 * PaperTaylor.budget m a x < 1 + 33 / m := by + have hx0 : 0 < x := by linarith + have hsplit : 1 - 3 * x ^ 2 / 4 ≤ (4 / 5 : ℝ) := by nlinarith + have h := PaperLaplace.budget_le (by linarith : 1 < m) ha ha1 hx0 hx1 hxa hsplit hb (by norm_num) + have hmain := laplace_main_lt (K := 32) hm (by norm_num : (0 : ℝ) < 7 / 12) hx.le (by norm_num) + have ht := tail_four_fifths hm + have hs := h.trans_lt (add_lt_add hmain ht) + simp only [div_eq_mul_inv] at hs ⊢ + linarith only [hs] + +/-- Third quantitative region. -/ +theorem budget_region_three {m a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx : 231 / 512 < x) (hx1 : x ≤ 1) (hxa : x < 2 * a) + (hb : PaperTaylor.beta a x 1 ≤ 9 / 10) : + m * x ^ 2 * PaperTaylor.budget m a x < 1 + 51 / m + 1 / 4 := by + have hx0 : 0 < x := by linarith + have hsplit : 1 - 3 * x ^ 2 / 4 ≤ (9 / 10 : ℝ) := by nlinarith + have h := PaperLaplace.budget_le (by linarith : 1 < m) ha ha1 hx0 hx1 hxa hsplit hb (by norm_num) + have hmain := laplace_main_lt (K := 51) hm (by norm_num : (0 : ℝ) < 231 / 512) hx.le (by norm_num) + have ht := tail_nine_tenths hm + linarith + +/-- Fourth quantitative region. -/ +theorem budget_region_four {m a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx : 207 / 512 < x) (hx1 : x ≤ 1) (hxa : x < 2 * a) + (hb : PaperTaylor.beta a x 1 ≤ 23 / 25) : + m * x ^ 2 * PaperTaylor.budget m a x < 1 + 62 / m + 2 := by + have hx0 : 0 < x := by linarith + have hsplit : 1 - 3 * x ^ 2 / 4 ≤ (23 / 25 : ℝ) := by nlinarith + have h := PaperLaplace.budget_le (by linarith : 1 < m) ha ha1 hx0 hx1 hxa hsplit hb (by norm_num) + have hmain := laplace_main_lt (K := 62) hm (by norm_num : (0 : ℝ) < 207 / 512) hx.le (by norm_num) + have ht := tail_twenty_three_twenty_fifths hm + linarith + +end Sendov.PaperTail diff --git a/docs/paper-formalization/checkpoint3.json b/docs/paper-formalization/checkpoint3.json new file mode 100644 index 0000000..248b4e7 --- /dev/null +++ b/docs/paper-formalization/checkpoint3.json @@ -0,0 +1,12 @@ +{ + "status": "partial_kernel_verified", + "gates": 24, + "seconds": 117.01536821923219, + "global_polar_bounds": true, + "finite_ray_bounds": true, + "centered_majorant_C_budget": true, + "historical_near_margins": true, + "full_complex_mean_half_counterexample": true, + "secant_diagnostic_intervals": true, + "all_a_m256_D": false +} \ No newline at end of file diff --git a/docs/paper-formalization/round3-files.json b/docs/paper-formalization/round3-files.json new file mode 100644 index 0000000..41f6651 --- /dev/null +++ b/docs/paper-formalization/round3-files.json @@ -0,0 +1,14 @@ +[ + "Sendov/Analytic/PaperGlobalPolar.lean", + "tests/PaperGlobalPolarTests.lean", + "Sendov/Analytic/PaperTail.lean", + "tests/PaperTailTests.lean", + "Sendov/Analytic/PaperRayGeometry.lean", + "tests/PaperRayGeometry.lean", + "Sendov/Analytic/PaperCenteredBound.lean", + "tests/PaperCenteredBoundTests.lean", + "Sendov/Analytic/PaperNearMargins.lean", + "tests/PaperNearMargins.lean", + "tests/PaperPolarCounterexample.lean", + "tests/PaperSecantNeighborhoods.lean" +] \ No newline at end of file diff --git a/tests/PaperCenteredBoundTests.lean b/tests/PaperCenteredBoundTests.lean new file mode 100644 index 0000000..e20457b --- /dev/null +++ b/tests/PaperCenteredBoundTests.lean @@ -0,0 +1,108 @@ +import Sendov.Analytic.PaperCenteredBound + +/-! Edge cases and exact public interfaces; no sampled data substitutes for a theorem. -/ +noncomputable section +open scoped BigOperators +open Sendov.PaperCentered Sendov.PaperCenteredBound +namespace Sendov.PaperCenteredBoundTests + +-- The two actual mean-square definitions are identified, not independently assumed. +example (r : Multiset ℂ) : Sendov.PaperCoefficient.variance r = + (r.map (fun z => ‖z‖ ^ 2)).sum / r.card := rfl +example (r : Multiset ℂ) : Sendov.PaperCoefficient.variance r = variance r := + variance_eq r + +-- Piecewise formula: interior, top degree, and zero variance including m=k>0. +example (m k : ℕ) (v : ℝ) (hk : 0 < k) (hkm : k < m) : + C m k v = Real.sqrt + ((m : ℝ) ^ m / ((k : ℝ) ^ k * ((m - k : ℕ) : ℝ) ^ (m - k)) * v ^ k) := + C_interior m k v hk hkm +example (m : ℕ) (v : ℝ) : C m m v = Real.sqrt (v ^ m) := C_top m v +example (m k : ℕ) (hk : 0 < k) : C m k 0 = 0 := C_zero_variance m k hk +example : C 0 0 0 = 1 := by simp + +-- Top degree uses sqrt(v^m), not a singular interior radius. +example (r : Multiset ℂ) (hr : r.sum = 0) (hm : 0 < r.card) : + ‖r.esymm r.card‖ ≤ Real.sqrt (variance r ^ r.card) := by + simpa using norm_esymm_le_C r hr r.card hm le_rfl + +-- Actual zero variance kills both interior and top positive coefficients. +example (r : Multiset ℂ) (hr : r.sum = 0) (hv : variance r = 0) + (μ : ℂ) (k : ℕ) (hk : 0 < k) (hkm : k ≤ r.card) : coeff r μ k = 0 := by + have h := norm_coeff_le_C r hr μ k hk hkm + rw [hv, C_zero_variance _ _ hk, zero_div] at h + exact norm_eq_zero.mp (le_antisymm h (norm_nonneg _)) + +-- Explicit coefficient interface with actual deviations and actual mean square. +example (q : Multiset ℂ) (μ : ℂ) (hmean : q.sum = q.card * μ) + (k : ℕ) (hk : 0 < k) (hkm : k ≤ q.card) : + ‖coeff (q.map (fun z => z - μ)) μ k‖ ≤ + C q.card k (((q.map (fun z => ‖z - μ‖ ^ 2)).sum) / q.card) / + ((q.card.choose k : ℝ) * ‖μ‖ ^ k) := by + simpa [variance, Multiset.map_map, Function.comp_def] using + norm_centered_coeff_le_C q μ hmean k hk hkm + +-- All H endpoints: zero scale and the exact top endpoint for arbitrary complex scale. +example (m k : ℕ) : H m k 0 = 0 := H_at_zero m k +example (m : ℕ) (z : ℂ) : H m m z = z ^ (m + 1) := H_top m z +example (m : ℕ) (z : ℂ) : H m 0 z = 1 - (1 - z) ^ (m + 1) := by simp [H] + +-- m=2 has no tail; m=3 retains exactly the top endpoint, not a replacement by 1. +example (r : Multiset ℂ) (hm : r.card = 2) (μ z : ℂ) : + majorant_Efin r μ z = ‖1 - z‖ ^ 3 + Gamma r μ * ‖B 2 2 z‖ := by + simp [majorant_Efin, hm] +example (r : Multiset ℂ) (hm : r.card = 3) (μ z : ℂ) : + majorant_Efin r μ z = ‖1 - z‖ ^ 4 + Gamma r μ * ‖B 3 2 z‖ + + Real.sqrt (variance r ^ 3) / ‖μ‖ ^ 3 * ‖z ^ 4‖ := by + norm_num [majorant_Efin, hm, Finset.sum_Ico_succ_top, H_top, norm_pow] + +-- A genuinely nonreal mean, with a nontrivial arbitrary complex family. +def q3 (z : ℂ) : Multiset ℂ := (Complex.I + z) ::ₘ (Complex.I - z) ::ₘ {Complex.I} +lemma q3_mean (z : ℂ) : (q3 z).sum = (q3 z).card * Complex.I := by + simp [q3] + ring +example : Complex.I.im ≠ 0 := by simp +example (z : ℂ) : + ‖coeff ((q3 z).map (fun w => w - Complex.I)) Complex.I 2‖ ≤ + C 3 2 (variance ((q3 z).map (fun w => w - Complex.I))) / 3 := by + simpa [q3] using norm_centered_coeff_le_C (q3 z) Complex.I (q3_mean z) 2 + (by decide) (by simp [q3]) +example (z : ℂ) : + ‖coeff ((q3 z).map (fun w => w - Complex.I)) Complex.I 3‖ ≤ + Real.sqrt (variance ((q3 z).map (fun w => w - Complex.I)) ^ 3) := by + simpa [q3] using norm_centered_coeff_le_C (q3 z) Complex.I (q3_mean z) 3 + (by decide) (by simp [q3]) + +-- Nonreal mean is accepted by the epsilon and integral-budget interfaces too. +example (z a : ℂ) : + ‖epsilon ((q3 z).map (fun w => w - Complex.I)) Complex.I (a * Complex.I)‖ ≤ + majorant_Efin ((q3 z).map (fun w => w - Complex.I)) Complex.I (a * Complex.I) := + norm_epsilon_le_majorant_Efin _ (centered_sum _ _ (q3_mean z)) _ _ (by simp [q3]) +example (z : ℂ) (a : ℝ) (ha : 0 ≤ a) + (hb : majorant_Efin ((q3 z).map (fun w => w - Complex.I)) Complex.I (a * Complex.I) + + Gamma ((q3 z).map (fun w => w - Complex.I)) Complex.I < 1 - a * ‖Complex.I‖) : + 1 < ‖((q3 z).card + 1 : ℂ) * + (∫ t in (0 : ℝ)..1, ((q3 z).map (fun w => 1 - (a : ℂ) * t * w)).prod)‖ := + Sendov.PaperCenteredBound.C_budget (q3 z) a Complex.I (by simp [q3]) ha + (q3_mean z) Complex.I_ne_zero hb + +-- Exact top endpoint suppression on both majorant and signed coefficients. +example (r : Multiset ℂ) (a μ : ℂ) (hμ : μ ≠ 0) : + C r.card r.card (variance r) / ((r.card.choose r.card : ℝ) * ‖μ‖ ^ r.card) * + ‖H r.card r.card (a * μ)‖ = + Real.sqrt (variance r ^ r.card) * ‖a‖ ^ (r.card + 1) * ‖μ‖ := + majorant_top_suppression r a μ hμ +example (r : Multiset ℂ) (a : ℂ) : + coeff r Complex.I r.card * H r.card r.card (a * Complex.I) = + (-1) ^ r.card * r.prod * a ^ (r.card + 1) * Complex.I := + coeff_top_suppression r a Complex.I Complex.I_ne_zero + +end Sendov.PaperCenteredBoundTests + +#print axioms Sendov.PaperCenteredBound.norm_esymm_le_C +#print axioms Sendov.PaperCenteredBound.norm_coeff_le_C +#print axioms Sendov.PaperCenteredBound.norm_centered_coeff_le_C +#print axioms Sendov.PaperCenteredBound.norm_epsilon_le_majorant_Efin +#print axioms Sendov.PaperCenteredBound.C_budget +#print axioms Sendov.PaperCenteredBound.majorant_top_suppression +#print axioms Sendov.PaperCenteredBound.coeff_top_suppression diff --git a/tests/PaperGlobalPolarTests.lean b/tests/PaperGlobalPolarTests.lean new file mode 100644 index 0000000..08e2df1 --- /dev/null +++ b/tests/PaperGlobalPolarTests.lean @@ -0,0 +1,101 @@ +import Sendov.Analytic.PaperGlobalPolar + +/-! Global polar regressions: exact public hypotheses, both sides of the delta +split, odd/even exponents, the strict degree base, and a proof-dependency audit. -/ +namespace Sendov.PaperGlobalPolar.Tests +open MeasureTheory PaperPolar + +-- The public estimate consumes raw polar only, not a logarithmic/chord assumption. +example {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : 1 ≤ ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2)) : + (1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) ≤ 4 / ((m : ℝ) + 2) := + endpoint_le hm ha ha1 hx0 hx1 hr + +example {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : (m : ℝ) * x ^ 2 > 19 / 2 := + degree_mul_sq_gt hm ha ha1 hx0 hx1 hr + +-- Minimum odd degree: do not silently round the real exponent to a natural power. +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 7 a x) : b a x ^ ((7 : ℝ) / 2) ≤ 4 / 9 := by + have h := endpoint_le (by norm_num : 7 ≤ 7) ha ha1 hx0 hx1 hr + norm_num at h ⊢ + exact h + +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 8 a x) : b a x ^ (4 : ℕ) ≤ 2 / 5 := by + have h := endpoint_le (by norm_num : 7 ≤ 8) ha ha1 hx0 hx1 hr + norm_num [Real.rpow_natCast] at h ⊢ + exact h + +-- Exact lower split boundary belongs to the large-delta branch. +example : Real.log ((9 : ℝ) / 2) ≤ Real.log (((9 : ℝ) / 2) * (4 / 9)) / (4 / 9) := + log_mul_div_delta (by norm_num) (by norm_num) (by norm_num) (by norm_num) + +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 7 a x) (hs : (9 : ℝ) / 2 * (1 - a ^ 2) < 2) : + (3 : ℝ) / 5 < c a x := by + exact three_fifths_lt_c (by norm_num) ha ha1 hx0 hx1 hr (by norm_num at *; exact hs) + +-- The strict target holds at the stated base, not merely above it. +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 256 a x) : (19 : ℝ) / 2 < 256 * x ^ 2 := by + simpa using degree_mul_sq_gt (by norm_num : 256 ≤ 256) ha ha1 hx0 hx1 hr + +example : (24 : ℝ) / 5 < Real.log 129 := log_129_gt + +-- Nonvacuity: an actual finite raw-polar instance, not an assumed scalar estimate. +theorem raw_feasible : RawPolar 16 (9 / 10) 1 := by + rw [rawPolar_iff] + change 1 ≤ PaperSecant.R 16 (9 / 10) 1 + rw [PaperSecant.R_one (by norm_num) (by norm_num)] + norm_num [PaperSecant.U1] + +example : b (9 / 10) 1 ^ ((16 : ℝ) / 2) ≤ 4 / 18 := by + have h := endpoint_le (by norm_num : 7 ≤ 16) (by norm_num) (by norm_num) + (by norm_num) (by norm_num) raw_feasible + norm_num at h ⊢ + exact h + +#print axioms integral_chord +#print axioms raw_integral_le_chord +#print axioms log_mul_delta_le +#print axioms log_mul_div_delta +#print axioms log_129_gt +#print axioms three_fifths_lt_c +#print axioms log_degree_le_c +#print axioms endpoint_le +#print axioms degree_mul_sq_gt +#print axioms raw_feasible + +-- Both headline proofs must actually reach the finite chord, both branches, +-- and the established logarithmic certificate in their proof-value closure. +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + for root in #[`Sendov.PaperGlobalPolar.endpoint_le, `Sendov.PaperGlobalPolar.degree_mul_sq_gt] do + let mut pending := [root] + let mut visited : Std.HashSet Name := {} + while !pending.isEmpty do + let name := pending.head! + pending := pending.tail! + unless visited.contains name do + visited := visited.insert name + let some ci := env.find? name | throwError "missing declaration {name}" + if let some value := ci.value? (allowOpaque := true) then + for used in value.getUsedConstants do pending := used :: pending + for target in #[`Sendov.PaperGlobalPolar.integral_chord, + `Sendov.PaperGlobalPolar.raw_integral_le_chord, + `Sendov.PaperGlobalPolar.log_mul_div_delta, + `Sendov.PaperGlobalPolar.three_fifths_lt_c, + `Sendov.PaperPolar.b_le_alpha, `Real.log_two_gt_d9] do + unless visited.contains target do + throwError "headline proof does not consume {root} -> {target}" + if visited.contains `sorryAx then throwError "unexpected sorry dependency" + logInfo m!"GLOBAL_POLAR_PROOF_CLOSURE_OK {root}" + +end Sendov.PaperGlobalPolar.Tests diff --git a/tests/PaperNearMargins.lean b/tests/PaperNearMargins.lean new file mode 100644 index 0000000..7ee77cc --- /dev/null +++ b/tests/PaperNearMargins.lean @@ -0,0 +1,137 @@ +import Sendov.Analytic.PaperNearMargins + +open MeasureTheory + +namespace Sendov.PaperNearMarginsAcceptance + +/-- Literal raw-polar signature and historical strict margin. -/ +theorem exact_one_fiftieth (m : ℕ) (a x : ℝ) (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 1 / 50) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x > + (1 - a) / 3 := by + -- The larger-domain, weaker-margin theorem cannot discharge this goal. + fail_if_success + exact PaperNearClosure.near_endpoint_D hm ha0 ha1 hx0 hx1 hraw (by linarith) + exact PaperNearMargins.near_endpoint_one_fiftieth hm ha0 ha1 hx0 hx1 hraw hnear + +/-- Expand both raw polar and T: no abstract scalar surrogate is accepted. -/ +theorem expanded_one_fiftieth (m : ℕ) (a x : ℝ) (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : 1 ≤ ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2)) + (hnear : (m : ℝ) * (1 - a) ≤ 1 / 50) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + (m : ℝ) * a ^ 2 * + ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) > + (1 - a) / 3 := by + change PaperPolar.RawPolar m a x at hraw + simpa only [PaperTaylor.budget, PaperTaylor.beta, mul_one, one_pow] using + PaperNearMargins.near_endpoint_one_fiftieth hm ha0 ha1 hx0 hx1 hraw hnear + +#print axioms PaperNearMargins.near_endpoint_one_fiftieth +#print axioms exact_one_fiftieth +#print axioms expanded_one_fiftieth + +/-- Literal raw-polar signature and historical strict margin. -/ +theorem exact_one_tenth (m : ℕ) (a x : ℝ) (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 1 / 10) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x > + (1 - a) / 5 := by + -- The larger-domain, weaker-margin theorem cannot discharge this goal. + fail_if_success + exact PaperNearClosure.near_endpoint_D hm ha0 ha1 hx0 hx1 hraw (by linarith) + exact PaperNearMargins.near_endpoint_one_tenth hm ha0 ha1 hx0 hx1 hraw hnear + +/-- Expand both raw polar and T: no abstract scalar surrogate is accepted. -/ +theorem expanded_one_tenth (m : ℕ) (a x : ℝ) (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : 1 ≤ ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2)) + (hnear : (m : ℝ) * (1 - a) ≤ 1 / 10) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + (m : ℝ) * a ^ 2 * + ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) > + (1 - a) / 5 := by + change PaperPolar.RawPolar m a x at hraw + simpa only [PaperTaylor.budget, PaperTaylor.beta, mul_one, one_pow] using + PaperNearMargins.near_endpoint_one_tenth hm ha0 ha1 hx0 hx1 hraw hnear + +#print axioms PaperNearMargins.near_endpoint_one_tenth +#print axioms exact_one_tenth +#print axioms expanded_one_tenth + +/-- Literal raw-polar signature and historical strict margin. -/ +theorem exact_one_fifth (m : ℕ) (a x : ℝ) (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 1 / 5) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x > + (1 - a) / 80 := by + -- The larger-domain, weaker-margin theorem cannot discharge this goal. + fail_if_success + exact PaperNearClosure.near_endpoint_D hm ha0 ha1 hx0 hx1 hraw (by linarith) + exact PaperNearMargins.near_endpoint_one_fifth hm ha0 ha1 hx0 hx1 hraw hnear + +/-- Expand both raw polar and T: no abstract scalar surrogate is accepted. -/ +theorem expanded_one_fifth (m : ℕ) (a x : ℝ) (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : 1 ≤ ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2)) + (hnear : (m : ℝ) * (1 - a) ≤ 1 / 5) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + (m : ℝ) * a ^ 2 * + ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) > + (1 - a) / 80 := by + change PaperPolar.RawPolar m a x at hraw + simpa only [PaperTaylor.budget, PaperTaylor.beta, mul_one, one_pow] using + PaperNearMargins.near_endpoint_one_fifth hm ha0 ha1 hx0 hx1 hraw hnear + +#print axioms PaperNearMargins.near_endpoint_one_fifth +#print axioms exact_one_fifth +#print axioms expanded_one_fifth + +/-- Literal raw-polar signature and historical strict margin. -/ +theorem exact_one_hundredth (m : ℕ) (a x : ℝ) (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 1 / 100) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x > + (1 - a) / 3 := by + -- The larger-domain, weaker-margin theorem cannot discharge this goal. + fail_if_success + exact PaperNearClosure.near_endpoint_D hm ha0 ha1 hx0 hx1 hraw (by linarith) + exact PaperNearMargins.near_endpoint_one_hundredth hm ha0 ha1 hx0 hx1 hraw hnear + +/-- Expand both raw polar and T: no abstract scalar surrogate is accepted. -/ +theorem expanded_one_hundredth (m : ℕ) (a x : ℝ) (hm : 7 ≤ m) + (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : 1 ≤ ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2)) + (hnear : (m : ℝ) * (1 - a) ≤ 1 / 100) : + 1 - (m : ℝ) * a / ((m : ℝ) + 1) - + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + (m : ℝ) * a ^ 2 * + ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) > + (1 - a) / 3 := by + change PaperPolar.RawPolar m a x at hraw + simpa only [PaperTaylor.budget, PaperTaylor.beta, mul_one, one_pow] using + PaperNearMargins.near_endpoint_one_hundredth hm ha0 ha1 hx0 hx1 hraw hnear + +#print axioms PaperNearMargins.near_endpoint_one_hundredth +#print axioms exact_one_hundredth +#print axioms expanded_one_hundredth + +#print axioms PaperNearMargins.f_le_cutoff_bound +#print axioms PaperNearMargins.g_le_cutoff_bound +#print axioms PaperNearMargins.rational_remainder_gt +#print axioms PaperNearMargins.margin_of_rational +#print axioms PaperNearMargins.margin_of_cutoff + +end Sendov.PaperNearMarginsAcceptance diff --git a/tests/PaperPolarCounterexample.lean b/tests/PaperPolarCounterexample.lean new file mode 100644 index 0000000..5aa353d --- /dev/null +++ b/tests/PaperPolarCounterexample.lean @@ -0,0 +1,161 @@ +import Sendov.Analytic.PaperPolar +import Mathlib.Analysis.SpecialFunctions.Integrals.Basic + +/-! +# Full complex-polar diagnostic against the all-degree mean-half claim + +Four conjugate unit-circle pairs, not just a relaxed scalar witness. +This refutes only `pointwise + full polar ⇒ mean > (1+a)/2` for all degrees. +No first-origin identity is assumed. This is not a D or Sendov counterexample. +-/ +namespace Sendov.PaperPolar.Counterexample +open MeasureTheory +open scoped BigOperators + +noncomputable def a : ℝ := 99 / 100 +noncomputable def x : ℝ := 497 / 500 +noncomputable def y : ℝ := Real.sqrt (1 - x ^ 2) +noncomputable def plus : ℂ := ⟨x, y⟩ +noncomputable def minus : ℂ := ⟨x, -y⟩ +/-- Alternating signs give exactly four conjugate pairs. -/ +noncomputable def q (j : Fin 8) : ℂ := if j.val % 2 = 0 then plus else minus +noncomputable def value : ℝ := + 9844160902221705118371486810769458499 / + 9843750000000000000000000000000000000 + +lemma y_sq : y ^ 2 = 1 - x ^ 2 := by + exact Real.sq_sqrt (by norm_num [x]) + +lemma norm_plus : ‖plus‖ = 1 := by + have h : ‖plus‖ ^ 2 = 1 := by + rw [Complex.sq_norm, Complex.normSq_apply] + change x * x + y * y = 1 + nlinarith [y_sq] + nlinarith [norm_nonneg plus] + +lemma norm_minus : ‖minus‖ = 1 := by + have h : ‖minus‖ ^ 2 = 1 := by + rw [Complex.sq_norm, Complex.normSq_apply] + change x * x + (-y) * (-y) = 1 + nlinarith [y_sq] + nlinarith [norm_nonneg minus] + +theorem norm_q (j : Fin 8) : ‖q j‖ = 1 := by + unfold q + split <;> first | exact norm_plus | exact norm_minus + +theorem mean_q : (∑ j : Fin 8, q j) / 8 = (x : ℂ) := by + norm_num [q, Fin.sum_univ_succ] + apply Complex.ext <;> simp [plus, minus] + ring + +lemma pair_product (s r : ℝ) : + ((s : ℂ) + r * plus) * (s + r * minus) = + ((s ^ 2 + 2 * s * r * x + r ^ 2 : ℝ) : ℂ) := by + apply Complex.ext <;> + simp only [plus, minus, pow_two, Complex.mul_re, Complex.mul_im, Complex.add_re, + Complex.add_im, Complex.ofReal_re, Complex.ofReal_im, Complex.ofReal_add, + Complex.ofReal_mul, Complex.ofReal_ofNat, Complex.re_ofNat, Complex.im_ofNat, + zero_mul, mul_zero, sub_zero, add_zero, zero_add] + · have h := congrArg (fun z : ℝ => r ^ 2 * z) y_sq + nlinarith only [h] + · ring + +theorem product_eq (t : ℝ) : + (∏ j : Fin 8, ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * q j)) = + (((a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + + (1 - a ^ 2) ^ 2 * t ^ 2) ^ 4 : ℝ) : ℂ) := by + have hp := pair_product a ((1 - a ^ 2) * t) + norm_num [q, Fin.prod_univ_succ] + calc + _ = (((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * plus) * + ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * minus)) ^ 4 := by push_cast; ring + _ = _ := by rw [hp]; push_cast; ring + +/-- Nine coefficients of a fourth power of a quadratic. -/ +noncomputable def fourthCoeffs (A B C : ℝ) : Fin 9 → ℝ := + ![A ^ 4, 4 * A ^ 3 * B, 6 * A ^ 2 * B ^ 2 + 4 * A ^ 3 * C, + 4 * A * B ^ 3 + 12 * A ^ 2 * B * C, + B ^ 4 + 12 * A * B ^ 2 * C + 6 * A ^ 2 * C ^ 2, + 4 * B ^ 3 * C + 12 * A * B * C ^ 2, + 6 * B ^ 2 * C ^ 2 + 4 * A * C ^ 3, 4 * B * C ^ 3, C ^ 4] + +lemma fourth_expansion (A B C t : ℝ) : + (A + B * t + C * t ^ 2) ^ 4 = + ∑ k : Fin 9, fourthCoeffs A B C k * t ^ k.val := by + simp [fourthCoeffs, Fin.sum_univ_succ] + ring + +lemma integral_fourth (A B C : ℝ) : + (∫ t in (0 : ℝ)..1, (A + B * t + C * t ^ 2) ^ 4) = + ∑ k : Fin 9, fourthCoeffs A B C k / (k.val + 1) := by + simp_rw [fourth_expansion] + rw [intervalIntegral.integral_finsetSum] + · apply Finset.sum_congr rfl + intro k hk + rw [intervalIntegral.integral_const_mul, integral_pow] + simp + ring + · intro k hk + exact ((continuous_const.mul (continuous_pow k.val))).intervalIntegrable _ _ + +theorem integral_real : + (∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ 4) = + value := by + rw [integral_fourth] + norm_num [fourthCoeffs, Fin.sum_univ_succ, a, x, value] + +/-- Evaluation of the literal complex product integral (not the raw relaxation). -/ +theorem integral_complex : + (∫ t in (0 : ℝ)..1, + ∏ j : Fin 8, ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * q j)) = (value : ℂ) := by + simp_rw [product_eq] + rw [intervalIntegral.integral_ofReal, integral_real] + +theorem value_gt_one : 1 < value := by norm_num [value] + +theorem full_polar : + 1 < ‖∫ t in (0 : ℝ)..1, + ∏ j : Fin 8, ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * q j)‖ := by + rw [integral_complex, Complex.norm_real, Real.norm_eq_abs, + abs_of_pos (lt_trans (by norm_num) value_gt_one)] + exact value_gt_one + +theorem mean_lt_half : ((∑ j : Fin 8, q j) / 8).re < (1 + a) / 2 := by + rw [mean_q] + norm_num [a, x] + +/-- The two means are exactly `0.994` and `0.995`. -/ +theorem exact_means : ((∑ j : Fin 8, q j) / 8).re = 497 / 500 ∧ + (1 + a) / 2 = 199 / 200 := by + rw [mean_q] + norm_num [a, x] + +/-- The scalar relaxation also holds, but is not used to prove full polar. -/ +theorem raw_polar : RawPolar 8 a x := by + unfold RawPolar + norm_num only [Nat.cast_ofNat, show (8 : ℝ) / 2 = (4 : ℝ) by norm_num, + Real.rpow_ofNat] + rw [integral_real] + exact value_gt_one.le + +/-- The exact counterexample to the proposed all-degree implication. -/ +theorem not_universal_mean_half : + ¬ (∀ (m : ℕ) (a : ℝ) (q : Fin m → ℂ), 7 ≤ m → 0 < a → a < 1 → + (∀ j, ‖q j‖ ≤ 1) → + 1 ≤ ‖∫ t in (0 : ℝ)..1, + ∏ j : Fin m, ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * q j)‖ → + (1 + a) / 2 < ((∑ j : Fin m, q j) / (m : ℂ)).re) := by + intro h + have hh := h 8 a q (by norm_num) (by norm_num [a]) (by norm_num [a]) + (fun j => (norm_q j).le) full_polar.le + exact (not_lt_of_ge mean_lt_half.le) hh + +#print axioms norm_q +#print axioms mean_q +#print axioms integral_complex +#print axioms full_polar +#print axioms not_universal_mean_half + +end Sendov.PaperPolar.Counterexample diff --git a/tests/PaperRayGeometry.lean b/tests/PaperRayGeometry.lean new file mode 100644 index 0000000..f67b6b9 --- /dev/null +++ b/tests/PaperRayGeometry.lean @@ -0,0 +1,123 @@ +import Sendov.Analytic.PaperRayGeometry + +/-! Tests consume only raw polar and domain hypotheses. Every finite-ray seam +is checked at the base degree, and the continuous interval coverage is explicit. +The lambda=1/5 test concerns geometry only: the first budget is [2/5,1]. -/ +namespace Sendov.PaperRayGeometry.Tests + +open PaperPolar + +variable {x : ℝ} (hx0 : -1 ≤ x) (hx1 : x ≤ 1) +include hx0 hx1 + +-- The original paper's lower endpoint still has the requested geometry. +theorem geometry_at_one_fifth (hraw : RawPolar 256 (1279 / 1280) x) : 5 / 6 < x := by + exact geometry_one (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hraw + (by norm_num [lambda]) + +-- The altered lower seam is closed, in agreement with the near-D overlap. +theorem budget_at_two_fifths (hraw : RawPolar 256 (639 / 640) x) : + 1 + 18 / (256 : ℝ) < (256 : ℝ) * x ^ 2 * B 256 (639 / 640) := by + exact budget_lower_one (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hraw + (by norm_num [lambda]) (by norm_num [lambda]) + +-- Both adjacent budget interfaces include lambda=1. +theorem budget_at_one (hraw : RawPolar 256 (255 / 256) x) : + (1 + 18 / (256 : ℝ) < (256 : ℝ) * x ^ 2 * B 256 (255 / 256)) ∧ + (1 + 33 / (256 : ℝ) < (256 : ℝ) * x ^ 2 * B 256 (255 / 256)) := by + constructor + · exact budget_lower_one (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hraw + (by norm_num [lambda]) (by norm_num [lambda]) + · exact budget_lower_ten (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hraw + (by norm_num [lambda]) (by norm_num [lambda]) + +-- The internal rational-product split is also closed at 2. +theorem product_at_two (hraw : RawPolar 256 (127 / 128) x) : + 6 / 5 ≤ (lambda 256 (127 / 128) + 1) * x ^ 2 := by + exact product_lower_five (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hraw + (by norm_num [lambda]) (by norm_num [lambda]) + +theorem budget_at_five (hraw : RawPolar 256 (251 / 256) x) : + 1 + 33 / (256 : ℝ) < (256 : ℝ) * x ^ 2 * B 256 (251 / 256) := by + exact budget_lower_five (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hraw + (by norm_num [lambda]) (by norm_num [lambda]) + +theorem budgets_at_ten (hraw : RawPolar 256 (123 / 128) x) : + (1 + 33 / (256 : ℝ) < (256 : ℝ) * x ^ 2 * B 256 (123 / 128)) ∧ + (1 + 51 / (256 : ℝ) + 1 / 4 < (256 : ℝ) * x ^ 2 * B 256 (123 / 128)) := by + constructor + · exact budget_lower_ten (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hraw + (by norm_num [lambda]) (by norm_num [lambda]) + · exact budget_lower_twentyfive (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hraw + (by norm_num [lambda]) (by norm_num [lambda]) + +theorem budgets_at_twentyfive (hraw : RawPolar 256 (231 / 256) x) : + (1 + 51 / (256 : ℝ) + 1 / 4 < (256 : ℝ) * x ^ 2 * B 256 (231 / 256)) ∧ + (1 + 62 / (256 : ℝ) + 2 < (256 : ℝ) * x ^ 2 * B 256 (231 / 256)) := by + constructor + · exact budget_lower_twentyfive (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hraw + (by norm_num [lambda]) (by norm_num [lambda]) + · exact budget_lower_fortynine (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hraw + (by norm_num [lambda]) (by norm_num [lambda]) + +theorem endpoint_at_fortynine (hraw : RawPolar 256 (207 / 256) x) : + b (207 / 256) x < 23 / 25 ∧ + beta (207 / 256) x (x / (2 * (207 / 256))) < 23 / 25 := by + exact laplace_endpoints_fortynine (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hraw + (by norm_num [lambda]) + +theorem budget_at_fortynine (hraw : RawPolar 256 (207 / 256) x) : + 1 + 62 / (256 : ℝ) + 2 < (256 : ℝ) * x ^ 2 * B 256 (207 / 256) := by + exact budget_lower_fortynine (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hraw + (by norm_num [lambda]) (by norm_num [lambda]) + +-- Odd degree uses a genuinely nonintegral raw exponent; no parity assumption. +theorem odd_degree (hraw : RawPolar 257 (208 / 257) x) : + b (208 / 257) x < 23 / 25 ∧ + 1 + 62 / (257 : ℝ) + 2 < (257 : ℝ) * x ^ 2 * B 257 (208 / 257) := by + constructor + · exact (geometry_fortynine (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hraw + (by norm_num [lambda])).1 + · exact budget_lower_fortynine (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hraw + (by norm_num [lambda]) (by norm_num [lambda]) + +-- This is a continuous four-region cover, not a finite check of sample lambdas. +theorem exhaustive {m : ℕ} {a : ℝ} (hm : 256 ≤ m) (ha0 : 0 < a) (ha1 : a < 1) + (hraw : RawPolar m a x) (hl0 : 2 / 5 ≤ lambda m a) (hl1 : lambda m a ≤ 49) : + (lambda m a ≤ 1 ∧ 5 / 6 < x ∧ + 1 + 18 / (m : ℝ) < (m : ℝ) * x ^ 2 * B m a) ∨ + (1 ≤ lambda m a ∧ lambda m a ≤ 10 ∧ b a x < 4 / 5 ∧ 7 / 12 < x ∧ + 1 + 33 / (m : ℝ) < (m : ℝ) * x ^ 2 * B m a) ∨ + (10 ≤ lambda m a ∧ lambda m a ≤ 25 ∧ b a x < 9 / 10 ∧ + 1 + 51 / (m : ℝ) + 1 / 4 < (m : ℝ) * x ^ 2 * B m a) ∨ + (25 ≤ lambda m a ∧ b a x < 23 / 25 ∧ + 1 + 62 / (m : ℝ) + 2 < (m : ℝ) * x ^ 2 * B m a) := by + by_cases h1 : lambda m a ≤ 1 + · exact Or.inl ⟨h1, geometry_one hm ha0 ha1 hx0 hx1 hraw h1, + budget_lower_one hm ha0 ha1 hx0 hx1 hraw hl0 h1⟩ + right + by_cases h10 : lambda m a ≤ 10 + · obtain ⟨hb, hx⟩ := geometry_ten hm ha0 ha1 hx0 hx1 hraw h10 + exact Or.inl ⟨by linarith, h10, hb, hx, + budget_lower_ten hm ha0 ha1 hx0 hx1 hraw (by linarith) h10⟩ + right + by_cases h25 : lambda m a ≤ 25 + · exact Or.inl ⟨by linarith, h25, (geometry_twentyfive hm ha0 ha1 hx0 hx1 hraw h25).1, + budget_lower_twentyfive hm ha0 ha1 hx0 hx1 hraw (by linarith) h25⟩ + exact Or.inr ⟨by linarith, (geometry_fortynine hm ha0 ha1 hx0 hx1 hraw hl1).1, + budget_lower_fortynine hm ha0 ha1 hx0 hx1 hraw (by linarith) hl1⟩ + +#print axioms Sendov.PaperRayGeometry.geometry_one +#print axioms Sendov.PaperRayGeometry.geometry_ten +#print axioms Sendov.PaperRayGeometry.geometry_twentyfive +#print axioms Sendov.PaperRayGeometry.integral_exp_lt_one_of_fixed +#print axioms Sendov.PaperRayGeometry.exp_fixed_49 +#print axioms Sendov.PaperRayGeometry.geometry_fortynine +#print axioms Sendov.PaperRayGeometry.budget_lower_one +#print axioms Sendov.PaperRayGeometry.budget_lower_ten +#print axioms Sendov.PaperRayGeometry.budget_lower_twentyfive +#print axioms Sendov.PaperRayGeometry.budget_lower_fortynine +#print axioms Sendov.PaperRayGeometry.laplace_endpoints_fortynine +#print axioms Sendov.PaperRayGeometry.Tests.exhaustive + +end Sendov.PaperRayGeometry.Tests diff --git a/tests/PaperSecantNeighborhoods.lean b/tests/PaperSecantNeighborhoods.lean new file mode 100644 index 0000000..715f50e --- /dev/null +++ b/tests/PaperSecantNeighborhoods.lean @@ -0,0 +1,219 @@ +import Sendov.Analytic.PaperSecant + +/-! +# Two continuous finite secant diagnostic neighborhoods + +All bounds below are rational interval bounds on the whole closed interval, +not evaluations at sample points. These are only two local diagnostics; +no all-degree or all-parameter positivity of the secant gate is asserted. +-/ +namespace Sendov.PaperSecant.Neighborhoods + +/-- A closed rational enclosure, with endpoints kept as real numbers. -/ +def Bounds (z l u : ℝ) : Prop := l ≤ z ∧ z ≤ u + +namespace Bounds +variable {z w l u L U l' u' : ℝ} + +lemma widen (h : Bounds z l u) (hl : l' ≤ l) (hu : u ≤ u') : Bounds z l' u' := + ⟨hl.trans h.1, h.2.trans hu⟩ + +lemma const (z : ℝ) : Bounds z z z := ⟨le_rfl, le_rfl⟩ + +lemma add (hz : Bounds z l u) (hw : Bounds w L U) : Bounds (z + w) (l + L) (u + U) := + ⟨add_le_add hz.1 hw.1, add_le_add hz.2 hw.2⟩ + +lemma sub (hz : Bounds z l u) (hw : Bounds w L U) : Bounds (z - w) (l - U) (u - L) := + ⟨sub_le_sub hz.1 hw.2, sub_le_sub hz.2 hw.1⟩ + +lemma mul (hz : Bounds z l u) (hw : Bounds w L U) (hl : 0 ≤ l) (hL : 0 ≤ L) : + Bounds (z * w) (l * L) (u * U) := by + exact ⟨mul_le_mul hz.1 hw.1 hL (hl.trans hz.1), + mul_le_mul hz.2 hw.2 (hL.trans hw.1) (hl.trans (hz.1.trans hz.2))⟩ + +lemma div (hz : Bounds z l u) (hw : Bounds w L U) (hl : 0 ≤ l) (hL : 0 < L) : + Bounds (z / w) (l / U) (u / L) := by + have hw0 : 0 < w := hL.trans_le hw.1 + have hU : 0 < U := hw0.trans_le hw.2 + constructor + · exact (div_le_div_iff₀ hU hw0).2 + (mul_le_mul hz.1 hw.2 hw0.le (hl.trans hz.1)) + · exact (div_le_div_iff₀ hw0 hL).2 + (mul_le_mul hz.2 hw.1 hL.le (hl.trans (hz.1.trans hz.2))) + +lemma pow (hz : Bounds z l u) (hl : 0 ≤ l) (n : ℕ) : + Bounds (z ^ n) (l ^ n) (u ^ n) := + ⟨pow_le_pow_left₀ hl hz.1 n, pow_le_pow_left₀ (hl.trans hz.1) hz.2 n⟩ + +end Bounds + + +/-- Uniform rational positivity on the report's degree-7 closed neighborhood. -/ +theorem gate_7_lower {a : ℝ} (ha : Bounds a (7999 / 10000) (8001 / 10000)) : + (21011 : ℝ) / 200000 ≤ Fsec 7 a := by + let a2 : ℝ := a ^ 2 + have ha2 : Bounds a2 (3999 / 6250) (6401601 / 10000000) := + (ha.pow (by norm_num) 2).widen (by norm_num) (by norm_num) + let delta : ℝ := (1 - a2) + have hdelta : Bounds delta (3598399 / 10000000) (2251 / 6250) := + ((Bounds.const (1 : ℝ)).sub ha2).widen (by norm_num) (by norm_num) + let top : ℝ := (a + delta) + have htop : Bounds top (11597399 / 10000000) (58013 / 50000) := + (ha.add hdelta).widen (by norm_num) (by norm_num) + let u1 : ℝ := ((top ^ 8 - a ^ 8) / (8 * delta)) + have hu1 : Bounds u1 (10775067 / 10000000) (2706667 / 2500000) := + (((htop.pow (by norm_num) 8).sub (ha.pow (by norm_num) 8)).div ((Bounds.const (8 : ℝ)).mul + hdelta (by norm_num) (by norm_num)) (by norm_num) (by norm_num)).widen (by norm_num) (by + norm_num) + let u0 : ℝ := ((2 * (1 - a ^ 9)) / (9 * delta)) + have hu0 : Bounds u0 (1335257 / 2500000) (1069529 / 2000000) := + (((Bounds.const (2 : ℝ)).mul ((Bounds.const (1 : ℝ)).sub (ha.pow (by norm_num) 9)) (by + norm_num) (by norm_num)).div ((Bounds.const (9 : ℝ)).mul hdelta (by norm_num) (by norm_num)) + (by norm_num) (by norm_num)).widen (by norm_num) (by norm_num) + let v0 : ℝ := (u0 - (((7 / 12) * a ^ 5) * delta ^ 2)) + have hv0 : Bounds v0 (2546463 / 5000000) (2550147 / 5000000) := + (hu0.sub (((Bounds.const ((7 / 12) : ℝ)).mul (ha.pow (by norm_num) 5) (by norm_num) (by + norm_num)).mul (hdelta.pow (by norm_num) 2) (by norm_num) (by norm_num))).widen (by + norm_num) (by norm_num) + let s : ℝ := ((a / 2) + (((1 - (a / 2)) * (1 - v0)) / (u1 - v0))) + have hs : Bounds s (4563153 / 5000000) (2297309 / 2500000) := + ((ha.div (Bounds.const (2 : ℝ)) (by norm_num) (by norm_num)).add ((((Bounds.const (1 : ℝ)).sub + (ha.div (Bounds.const (2 : ℝ)) (by norm_num) (by norm_num))).mul ((Bounds.const (1 : ℝ)).sub + hv0) (by norm_num) (by norm_num)).div (hu1.sub hv0) (by norm_num) (by norm_num))).widen (by + norm_num) (by norm_num) + let c : ℝ := (a * ((2 * s) - a)) + have hc : Bounds c (1025033 / 1250000) (1038077 / 1250000) := + (ha.mul (((Bounds.const (2 : ℝ)).mul hs (by norm_num) (by norm_num)).sub ha) (by norm_num) (by + norm_num)).widen (by norm_num) (by norm_num) + let b : ℝ := ((1 - ((2 * a) * s)) + a2) + have hb : Bounds b (211723 / 1250000) (1801337 / 10000000) := + (((Bounds.const (1 : ℝ)).sub (((Bounds.const (2 : ℝ)).mul ha (by norm_num) (by norm_num)).mul + hs (by norm_num) (by norm_num))).add ha2).widen (by norm_num) (by norm_num) + let d : ℝ := ((2 * a) * (1 - s)) + have hd : Bounds d (64853 / 500000) (699043 / 5000000) := + (((Bounds.const (2 : ℝ)).mul ha (by norm_num) (by norm_num)).mul ((Bounds.const (1 : ℝ)).sub + hs) (by norm_num) (by norm_num)).widen (by norm_num) (by norm_num) + let budget : ℝ := (1 - ((7 * a) / 8)) + have hbudget : Bounds budget (23993 / 80000) (24007 / 80000) := + ((Bounds.const (1 : ℝ)).sub (((Bounds.const (7 : ℝ)).mul ha (by norm_num) (by norm_num)).div + (Bounds.const (8 : ℝ)) (by norm_num) (by norm_num))).widen (by norm_num) (by norm_num) + let w : ℝ := ((((1 / 8) + b ^ 3) + (d / (a * 5))) + (((84 * a2) * d ^ 2) / ((c ^ 4 * 8) * 10))) + have hw : Bounds w (58139 / 312500) (77943 / 400000) := + ((((Bounds.const ((1 / 8) : ℝ)).add (hb.pow (by norm_num) 3)).add (hd.div (ha.mul + (Bounds.const (5 : ℝ)) (by norm_num) (by norm_num)) (by norm_num) (by norm_num))).add + ((((Bounds.const (84 : ℝ)).mul ha2 (by norm_num) (by norm_num)).mul (hd.pow (by norm_num) 2) + (by norm_num) (by norm_num)).div (((hc.pow (by norm_num) 4).mul (Bounds.const (8 : ℝ)) (by + norm_num) (by norm_num)).mul (Bounds.const (10 : ℝ)) (by norm_num) (by norm_num)) (by + norm_num) (by norm_num))).widen (by norm_num) (by norm_num) + let f : ℝ := (budget - w) + have hf : Bounds f (21011 / 200000) (1140427 / 10000000) := + (hbudget.sub hw).widen (by norm_num) (by norm_num) + have hid : f = Fsec 7 a := by + dsimp [f, w, budget, d, b, c, s, v0, u0, u1, top, delta, a2] + norm_num [Fsec, B, Wsec, S, V0, U0, U1, PaperTaylor.beta, + PaperTaylor.defect, PaperTaylor.chord] + rw [← hid] + exact hf.1 + +/-- Uniform rational positivity on the report's degree-10 closed neighborhood. -/ +theorem gate_10_lower {a : ℝ} (ha : Bounds a (899999 / 1000000) (900001 / 1000000)) : + (155747 : ℝ) / 10000000 ≤ Fsec 10 a := by + let a2 : ℝ := a ^ 2 + have ha2 : Bounds a2 (4049991 / 5000000) (8100019 / 10000000) := + (ha.pow (by norm_num) 2).widen (by norm_num) (by norm_num) + let delta : ℝ := (1 - a2) + have hdelta : Bounds delta (1899981 / 10000000) (950009 / 5000000) := + ((Bounds.const (1 : ℝ)).sub ha2).widen (by norm_num) (by norm_num) + let top : ℝ := (a + delta) + have htop : Bounds top (10899971 / 10000000) (2725007 / 2500000) := + (ha.add hdelta).widen (by norm_num) (by norm_num) + let u1 : ℝ := ((top ^ 11 - a ^ 11) / (11 * delta)) + have hu1 : Bounds u1 (10844569 / 10000000) (1355691 / 1250000) := + (((htop.pow (by norm_num) 11).sub (ha.pow (by norm_num) 11)).div ((Bounds.const (11 : ℝ)).mul + hdelta (by norm_num) (by norm_num)) (by norm_num) (by norm_num)).widen (by norm_num) (by + norm_num) + let u0 : ℝ := ((2 * (1 - a ^ 12)) / (12 * delta)) + have hu0 : Bounds u0 (1258877 / 2000000) (3147287 / 5000000) := + (((Bounds.const (2 : ℝ)).mul ((Bounds.const (1 : ℝ)).sub (ha.pow (by norm_num) 12)) (by + norm_num) (by norm_num)).div ((Bounds.const (12 : ℝ)).mul hdelta (by norm_num) (by + norm_num)) (by norm_num) (by norm_num)).widen (by norm_num) (by norm_num) + let v0 : ℝ := (u0 - (((5 / 6) * a ^ 8) * delta ^ 2)) + have hv0 : Bounds v0 (3082441 / 5000000) (6165079 / 10000000) := + (hu0.sub (((Bounds.const ((5 / 6) : ℝ)).mul (ha.pow (by norm_num) 8) (by norm_num) (by + norm_num)).mul (hdelta.pow (by norm_num) 2) (by norm_num) (by norm_num))).widen (by + norm_num) (by norm_num) + let s : ℝ := ((a / 2) + (((1 - (a / 2)) * (1 - v0)) / (u1 - v0))) + have hs : Bounds s (450311 / 500000) (281487 / 312500) := + ((ha.div (Bounds.const (2 : ℝ)) (by norm_num) (by norm_num)).add ((((Bounds.const (1 : ℝ)).sub + (ha.div (Bounds.const (2 : ℝ)) (by norm_num) (by norm_num))).mul ((Bounds.const (1 : ℝ)).sub + hv0) (by norm_num) (by norm_num)).div (hu1.sub hv0) (by norm_num) (by norm_num))).widen (by + norm_num) (by norm_num) + let c : ℝ := (a * ((2 * s) - a)) + have hc : Bounds c (8111177 / 10000000) (811367 / 1000000) := + (ha.mul (((Bounds.const (2 : ℝ)).mul hs (by norm_num) (by norm_num)).sub ha) (by norm_num) (by + norm_num)).widen (by norm_num) (by norm_num) + let b : ℝ := ((1 - ((2 * a) * s)) + a2) + have hb : Bounds b (235789 / 1250000) (944421 / 5000000) := + (((Bounds.const (1 : ℝ)).sub (((Bounds.const (2 : ℝ)).mul ha (by norm_num) (by norm_num)).mul + hs (by norm_num) (by norm_num))).add ha2).widen (by norm_num) (by norm_num) + let d : ℝ := ((2 * a) * (1 - s)) + have hd : Bounds d (893173 / 5000000) (894403 / 5000000) := + (((Bounds.const (2 : ℝ)).mul ha (by norm_num) (by norm_num)).mul ((Bounds.const (1 : ℝ)).sub + hs) (by norm_num) (by norm_num)).widen (by norm_num) (by norm_num) + let budget : ℝ := (1 - ((10 * a) / 11)) + have hbudget : Bounds budget (454543 / 2500000) (1818191 / 10000000) := + ((Bounds.const (1 : ℝ)).sub (((Bounds.const (10 : ℝ)).mul ha (by norm_num) (by norm_num)).div + (Bounds.const (11 : ℝ)) (by norm_num) (by norm_num))).widen (by norm_num) (by norm_num) + let w : ℝ := ((((1 / 11) + b ^ 5) + (d / (a * 8))) + (((120 * a2) * d ^ 2) / ((c ^ 4 * 11) * + 13))) + have hw : Bounds w (1660067 / 10000000) (66497 / 400000) := + ((((Bounds.const ((1 / 11) : ℝ)).add (hb.pow (by norm_num) 5)).add (hd.div (ha.mul + (Bounds.const (8 : ℝ)) (by norm_num) (by norm_num)) (by norm_num) (by norm_num))).add + ((((Bounds.const (120 : ℝ)).mul ha2 (by norm_num) (by norm_num)).mul (hd.pow (by norm_num) + 2) (by norm_num) (by norm_num)).div (((hc.pow (by norm_num) 4).mul (Bounds.const (11 : ℝ)) + (by norm_num) (by norm_num)).mul (Bounds.const (13 : ℝ)) (by norm_num) (by norm_num)) (by + norm_num) (by norm_num))).widen (by norm_num) (by norm_num) + let f : ℝ := (budget - w) + have hf : Bounds f (155747 / 10000000) (39531 / 2500000) := + (hbudget.sub hw).widen (by norm_num) (by norm_num) + have hid : f = Fsec 10 a := by + dsimp [f, w, budget, d, b, c, s, v0, u0, u1, top, delta, a2] + norm_num [Fsec, B, Wsec, S, V0, U0, U1, PaperTaylor.beta, + PaperTaylor.defect, PaperTaylor.chord] + rw [← hid] + exact hf.1 + +/-- Positivity at every real parameter in this interval, including its endpoints. -/ +theorem gate_7_interval {a : ℝ} (ha : a ∈ Set.Icc (7999 / 10000) (8001 / 10000)) : + 0 < Fsec 7 a := + lt_of_lt_of_le (by norm_num : (0 : ℝ) < 21011 / 200000) (gate_7_lower ha) + +/-- D holds uniformly for every raw-polar feasible mean in this neighborhood. -/ +theorem D_7_interval {a x : ℝ} (ha : a ∈ Set.Icc (7999 / 10000) (8001 / 10000)) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : PaperPolar.RawPolar 7 a x) : + PaperTaylor.budget 7 a x < B 7 a := by + have ha0 : 0 < a := by have := ha.1; linarith + have ha1 : a < 1 := by have := ha.2; linarith + exact gate_implies_D (by norm_num) ha0 ha1 hx0 hx1 hr (gate_7_interval ha) + +/-- Positivity at every real parameter in this interval, including its endpoints. -/ +theorem gate_10_interval {a : ℝ} (ha : a ∈ Set.Icc (899999 / 1000000) (900001 / 1000000)) : + 0 < Fsec 10 a := + lt_of_lt_of_le (by norm_num : (0 : ℝ) < 155747 / 10000000) (gate_10_lower ha) + +/-- D holds uniformly for every raw-polar feasible mean in this neighborhood. -/ +theorem D_10_interval {a x : ℝ} (ha : a ∈ Set.Icc (899999 / 1000000) (900001 / 1000000)) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : PaperPolar.RawPolar 10 a x) : + PaperTaylor.budget 10 a x < B 10 a := by + have ha0 : 0 < a := by have := ha.1; linarith + have ha1 : a < 1 := by have := ha.2; linarith + exact gate_implies_D (by norm_num) ha0 ha1 hx0 hx1 hr (gate_10_interval ha) + +#print axioms gate_7_lower +#print axioms gate_10_lower +#print axioms gate_7_interval +#print axioms gate_10_interval +#print axioms D_7_interval +#print axioms D_10_interval + +end Sendov.PaperSecant.Neighborhoods diff --git a/tests/PaperTailTests.lean b/tests/PaperTailTests.lean new file mode 100644 index 0000000..1b1c21e --- /dev/null +++ b/tests/PaperTailTests.lean @@ -0,0 +1,63 @@ +import Sendov.Analytic.PaperTail + +open Sendov + +-- Real-degree contracts (not merely a natural-degree table). +example {m : ℝ} (hm : 256 ≤ m) : + (m ^ 2 / 2 + m) * (4 / 5 : ℝ) ^ ((m - 1) / 2) < 1 / m := + PaperTail.tail_four_fifths hm + +example {m : ℝ} (hm : 256 ≤ m) : + (m ^ 2 / 2 + m) * (9 / 10 : ℝ) ^ ((m - 1) / 2) < 1 / 4 := + PaperTail.tail_nine_tenths hm + +example {m : ℝ} (hm : 256 ≤ m) : + (m ^ 2 / 2 + m) * (23 / 25 : ℝ) ^ ((m - 1) / 2) < 2 := + PaperTail.tail_twenty_three_twenty_fifths hm + +example {m : ℝ} (hm : 256 ≤ m) : + m * (1 + 5 * m / 162) * Real.exp (-22 * m / 1215) < 24 := + PaperTail.middle_tail hm + +example {k l : ℝ} (hk : 19 / 2 ≤ k) (hkl : k ≤ l) : + (1 + 5 * l / 8) * Real.exp (-(11 / 30 : ℝ) * l) ≤ + (1 + 5 * k / 8) * Real.exp (-(11 / 30 : ℝ) * k) := + PaperTail.middle_antitone hk (hk.trans hkl) hkl + +-- The exact cutoff and a nonintegral degree are covered. +example : ((256 : ℝ) ^ 2 / 2 + 256) * (9 / 10 : ℝ) ^ (((256 : ℝ) - 1) / 2) < 1 / 4 := + PaperTail.tail_nine_tenths (m := 256) (by norm_num) + +example : ((513 / 2 : ℝ) ^ 2 / 2 + 513 / 2) * (23 / 25 : ℝ) ^ (((513 / 2 : ℝ) - 1) / 2) < 2 := + PaperTail.tail_twenty_three_twenty_fifths (m := 513 / 2) (by norm_num) + +section ActualBudget +variable {m a x : ℝ} (hm : 256 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx1 : x ≤ 1) (hxa : x < 2 * a) + +example (hx : 5 / 6 < x) (hb : PaperTaylor.beta a x 1 ≤ 4 / 5) : + m * x ^ 2 * PaperTaylor.budget m a x < 1 + 18 / m := + PaperTail.budget_region_one hm ha ha1 hx hx1 hxa hb + +example (hx : 7 / 12 < x) (hb : PaperTaylor.beta a x 1 ≤ 4 / 5) : + m * x ^ 2 * PaperTaylor.budget m a x < 1 + 33 / m := + PaperTail.budget_region_two hm ha ha1 hx hx1 hxa hb + +example (hx : 231 / 512 < x) (hb : PaperTaylor.beta a x 1 ≤ 9 / 10) : + m * x ^ 2 * PaperTaylor.budget m a x < 1 + 51 / m + 1 / 4 := + PaperTail.budget_region_three hm ha ha1 hx hx1 hxa hb + +example (hx : 207 / 512 < x) (hb : PaperTaylor.beta a x 1 ≤ 23 / 25) : + m * x ^ 2 * PaperTaylor.budget m a x < 1 + 62 / m + 2 := + PaperTail.budget_region_four hm ha ha1 hx hx1 hxa hb +end ActualBudget + +#print axioms PaperTail.tail_four_fifths +#print axioms PaperTail.tail_nine_tenths +#print axioms PaperTail.tail_twenty_three_twenty_fifths +#print axioms PaperTail.middle_tail +#print axioms PaperTail.middle_antitone +#print axioms PaperTail.budget_region_one +#print axioms PaperTail.budget_region_two +#print axioms PaperTail.budget_region_three +#print axioms PaperTail.budget_region_four From 1108d11ee7e6c1d231d41c91607745e0330dcbc2 Mon Sep 17 00:00:00 2001 From: Methode Date: Mon, 14 Sep 2026 13:13:47 -0700 Subject: [PATCH 20/24] Integrate full m256 uniform D and wire large degrees to first-origin --- Sendov/Analytic/FirstOriginBudget.lean | 24 ++ Sendov/Analytic/FirstOriginMargins.lean | 284 +++++++++++++ Sendov/Analytic/PaperHistoricalBounds.lean | 443 +++++++++++++++++++++ Sendov/Analytic/PaperUniform.lean | 188 +++++++++ Sendov/Interior.lean | 16 +- docs/paper-formalization/checkpoint4.json | 8 + docs/paper-formalization/round4-files.json | 8 + tests/FirstOriginBudget.lean | 2 + tests/FirstOriginMargins.lean | 140 +++++++ tests/FirstOriginWiring.lean | 4 +- tests/PaperHistoricalBoundsTests.lean | 143 +++++++ tests/PaperUniform.lean | 100 +++++ 12 files changed, 1356 insertions(+), 4 deletions(-) create mode 100644 Sendov/Analytic/FirstOriginMargins.lean create mode 100644 Sendov/Analytic/PaperHistoricalBounds.lean create mode 100644 Sendov/Analytic/PaperUniform.lean create mode 100644 docs/paper-formalization/checkpoint4.json create mode 100644 docs/paper-formalization/round4-files.json create mode 100644 tests/FirstOriginMargins.lean create mode 100644 tests/PaperHistoricalBoundsTests.lean create mode 100644 tests/PaperUniform.lean diff --git a/Sendov/Analytic/FirstOriginBudget.lean b/Sendov/Analytic/FirstOriginBudget.lean index 4be1bf6..aed9631 100644 --- a/Sendov/Analytic/FirstOriginBudget.lean +++ b/Sendov/Analytic/FirstOriginBudget.lean @@ -1,5 +1,6 @@ import Sendov.Analytic.FirstOriginSmall import Sendov.Analytic.PaperNear +import Sendov.Analytic.PaperUniform /-! Generic first-origin consumers of the scalar D estimates. No second-origin or polynomial centroid identity is used in these proofs. -/ @@ -74,4 +75,27 @@ theorem near_contradiction {n : ℕ} (hn : 8 ≤ n) {a x y : ℝ} {q : Multiset rw [mul_comm a ((n : ℝ) - 1)] at hl linarith +/-- All degrees n≥257 close using only polar and the first-origin bound. -/ +theorem uniform_contradiction {n : ℕ} (hn : 257 ≤ n) {a x y : ℝ} {q : Multiset ℂ} + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x) + (hsum : q.sum = ((n : ℂ) - 1) * ((x : ℂ) + (y : ℂ) * Complex.I)) + (hraw : 1 ≤ ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) + (hfirst : ‖∫ t in (0 : ℝ)..1, Fprod a q t‖ ≤ 1 / (n : ℝ)) : False := by + have hm : 256 ≤ n - 1 := by omega + have hcast : ((n - 1 : ℕ) : ℝ) = (n : ℝ) - 1 := by + rw [Nat.cast_sub (by omega : 1 ≤ n)] + norm_num + have hr : PaperPolar.RawPolar (n - 1) a x := by + rw [PaperPolar.rawPolar_iff, hcast] + exact hraw + have hd := PaperUniform.uniform_D hm ha ha1 hx0 hx1 hr + have hl := lower_budget (by omega) ha ha1 hx1 hqcard hq1 hx hsum hfirst + rw [hcast] at hd + have he : (n : ℝ) - 1 + 1 = n := by ring + rw [he] at hd + rw [mul_comm a ((n : ℝ) - 1)] at hl + linarith + end Sendov.FirstOriginBudget diff --git a/Sendov/Analytic/FirstOriginMargins.lean b/Sendov/Analytic/FirstOriginMargins.lean new file mode 100644 index 0000000..c0c6955 --- /dev/null +++ b/Sendov/Analytic/FirstOriginMargins.lean @@ -0,0 +1,284 @@ +import Sendov.Analytic.FirstOriginSmall + +/-! +# Quantitative first-origin margins for m = 5, 6 + +The hypotheses concern only the pointwise closed disk and the polar integral. +In particular, no first-origin factorization or upper bound on the integral is +assumed. The conclusion is a direct lower bound on its norm, not a contradiction. +The polynomial constants and the actual (not surrogate) T budgets are exposed. +-/ +namespace Sendov.FirstOriginMargins + +open FirstOriginSmall + +noncomputable def A5 (a : ℝ) : ℝ := + 7 / 6 - (7 / 3) * a + a ^ 2 + (7 / 12) * a ^ 3 + (1 / 12) * a ^ 4 + +noncomputable def A6 (a : ℝ) : ℝ := + 15 / 7 - (27 / 7) * a + (15 / 7) * a ^ 2 + (65 / 112) * a ^ 3 - + (229 / 112) * a ^ 4 + (23 / 14) * a ^ 5 + +/-- Explicit nonnegative Bernstein remainder after subtracting 1/16. -/ +lemma A5_remainder (a : ℝ) : + A5 a - 1 / 16 = (53 / 48) * (1 - a) ^ 4 + (25 / 12) * a * (1 - a) ^ 3 + + (5 / 8) * a ^ 2 * (1 - a) ^ 2 + (7 / 16) * a ^ 4 := by + unfold A5 + ring + +/-- Explicit nonnegative Bernstein remainder after subtracting 93/560. -/ +lemma A6_remainder (a : ℝ) : + A6 a - 93 / 560 = (1107 / 560) * (1 - a) ^ 5 + + (675 / 112) * a * (1 - a) ^ 4 + (363 / 56) * a ^ 2 * (1 - a) ^ 3 + + (407 / 112) * a ^ 3 * (1 - a) ^ 2 + (247 / 560) * a ^ 5 := by + unfold A6 + ring + +lemma A5_lower {a : ℝ} (ha0 : 0 ≤ a) (ha1 : a ≤ 1) : 1 / 16 ≤ A5 a := by + have hh : 0 ≤ 1 - a := sub_nonneg.mpr ha1 + have hp : 0 ≤ A5 a - 1 / 16 := by rw [A5_remainder]; positivity + linarith + +lemma A6_lower {a : ℝ} (ha0 : 0 ≤ a) (ha1 : a ≤ 1) : 93 / 560 ≤ A6 a := by + have hh : 0 ≤ 1 - a := sub_nonneg.mpr ha1 + have hp : 0 ≤ A6 a - 93 / 560 := by rw [A6_remainder]; positivity + linarith + +lemma upper_five_gap_identity (a : ℝ) : + 1 - 5 * a / 6 - ((1 - a) ^ 2 + + 5 * a ^ 2 * (∫ t in (0 : ℝ)..1, t * B a t ^ 2)) = a * (1 - a) * A5 a := by + have he : (fun t => B a t) = + (fun t => 1 + (-a * (1 + a)) * t + a ^ 2 * t ^ 2) := by + funext t; unfold B; ring + simp_rw [he] + rw [integral_t_quadratic_sq] + unfold A5 + ring + +lemma upper_six_gap_identity (a : ℝ) : + 1 - 6 * a / 7 - ((1 - a) ^ 3 + 6 * a ^ 2 * + ((∫ t in (0 : ℝ)..1, t * (1 - a * t) ^ 5) + + (5 / 2 : ℝ) * a * (1 - a) * + (∫ t in (0 : ℝ)..1, t ^ 2 * (1 - a * t) ^ 3) + + (15 / 32 : ℝ) * a ^ 2 * (1 - a) ^ 2)) = a * (1 - a) * A6 a := by + rw [integral_t_linear_fifth, integral_sq_linear_cube] + unfold A6 + ring + +/-- The actual direct budget, with real exponents and the original QQ integrand. -/ +noncomputable def T (m a x : ℝ) : ℝ := + QQ (a * x) (a ^ 2) 1 ^ (m / 2) + + m * a ^ 2 * (∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ ((m - 1) / 2)) + +lemma T_five_gap {a x : ℝ} (ha0 : 0 < a) (ha1 : a < 1) + (hx : (1 + a) / 2 ≤ x) (hx1 : x ≤ 1) : + T 5 a x ≤ 1 - 5 * a / 6 - a * (1 - a) / 16 := by + have hend := beta_B_bounds ha0.le ha1.le hx hx1 (by norm_num : (0 : ℝ) ≤ 1) le_rfl + have heB : B a 1 = 1 - a := by unfold B; ring + have he := Real.rpow_le_rpow hend.1 hend.2.1 (by norm_num : (0 : ℝ) ≤ 5 / 2) + rw [heB] at he + have he2 := Real.rpow_le_rpow_of_exponent_ge (by linarith : 0 < 1 - a) + (by linarith : 1 - a ≤ 1) (by norm_num : (2 : ℝ) ≤ 5 / 2) + norm_num [Real.rpow_natCast] at he2 + have hi : (∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (2 : ℕ)) ≤ + ∫ t in (0 : ℝ)..1, t * (B a t) ^ 2 := by + apply intervalIntegral.integral_mono_on (by norm_num) + (Continuous.intervalIntegrable (by unfold QQ; fun_prop) _ _) + (Continuous.intervalIntegrable (by unfold B; fun_prop) _ _) + intro t ht + have hb := beta_B_bounds ha0.le ha1.le hx hx1 ht.1 ht.2 + exact mul_le_mul_of_nonneg_left (pow_le_pow_left₀ hb.1 hb.2.1 2) ht.1 + have hmul := mul_le_mul_of_nonneg_left hi (by positivity : 0 ≤ 5 * a ^ 2) + have hg := upper_five_gap_identity a + have hl := mul_le_mul_of_nonneg_left (A5_lower ha0.le ha1.le) + (by positivity : 0 ≤ a * (1 - a)) + norm_num [T, Real.rpow_natCast] + linarith + +lemma T_six_gap {a x : ℝ} (ha0 : 0 < a) (ha1 : a < 1) + (hx : (1 + a) / 2 ≤ x) (hx1 : x ≤ 1) : + T 6 a x ≤ 1 - 6 * a / 7 - (93 / 560) * a * (1 - a) := by + have hend := beta_B_bounds ha0.le ha1.le hx hx1 (by norm_num : (0 : ℝ) ≤ 1) le_rfl + have heB : B a 1 = 1 - a := by unfold B; ring + have he := pow_le_pow_left₀ hend.1 hend.2.1 3 + rw [heB] at he + have hi : (∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (5 / 2 : ℝ)) ≤ + ∫ t in (0 : ℝ)..1, (t * (1 - a * t) ^ 5 + + ((5 / 2 : ℝ) * a * (1 - a)) * (t ^ 2 * (1 - a * t) ^ 3) + + ((15 / 8 : ℝ) * a ^ 2 * (1 - a) ^ 2) * t ^ 3) := by + apply intervalIntegral.integral_mono_on (by norm_num) + (by simpa only [pow_one] using + (continuous_pow_mul_QQ (a * x) (a ^ 2) 1 + (by norm_num : (0 : ℝ) ≤ 5 / 2)).intervalIntegrable 0 1) + (Continuous.intervalIntegrable (by fun_prop) _ _) + intro t ht + have hb := beta_B_bounds ha0.le ha1.le hx hx1 ht.1 ht.2 + have hp := (Real.rpow_le_rpow hb.1 hb.2.1 (by norm_num : (0 : ℝ) ≤ 5 / 2)).trans + (B_five_halves ha0.le ha1.le ht.1 ht.2) + have hm := mul_le_mul_of_nonneg_left hp ht.1 + calc + _ ≤ t * ((1 - a * t) ^ 5 + (5 / 2 : ℝ) * a * (1 - a) * t * + (1 - a * t) ^ 3 + (15 / 8 : ℝ) * a ^ 2 * (1 - a) ^ 2 * t ^ 2) := hm + _ = _ := by ring + simp (disch := exact Continuous.intervalIntegrable (by fun_prop) _ _) + only [intervalIntegral.integral_add, intervalIntegral.integral_const_mul, integral_pow] at hi + norm_num at hi + have hmul := mul_le_mul_of_nonneg_left hi (by positivity : 0 ≤ 6 * a ^ 2) + have hg := upper_six_gap_identity a + have hl := mul_le_mul_of_nonneg_left (A6_lower ha0.le ha1.le) + (by positivity : 0 ≤ a * (1 - a)) + norm_num [T, Real.rpow_natCast] + nlinarith only [he, hmul, hg, hl] + +/-- General lower budget retaining the actual norm of J, without assuming it ≤ 1. +The explicit beta nonnegativity hypothesis permits reuse beyond the small degrees. -/ +theorem lower_budget_norm {n : ℕ} (hn : 2 ≤ n) {a x y : ℝ} {q : Multiset ℂ} + (ha : 0 ≤ a) + (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x) + (hsum : q.sum = ((n : ℂ) - 1) * ((x : ℂ) + (y : ℂ) * Complex.I)) + (hβ : 0 ≤ QQ (a * x) (a ^ 2) 1) : + 1 ≤ T ((n : ℝ) - 1) a x + a * ((n : ℝ) - 1) / (n : ℝ) * + ‖(n : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ := by + have hnR : (2 : ℝ) ≤ n := by exact_mod_cast hn + have hn0 : (n : ℝ) ≠ 0 := by linarith + have hc : (q.card : ℝ) = (n : ℝ) - 1 := by + rw [hqcard, Nat.cast_sub (by omega : 1 ≤ n)]; norm_num + have hq0 : q ≠ 0 := by + intro h + simp [h] at hqcard + omega + have hsumle := norm_sum_le_card q hq1 + rw [hc] at hsumle + have ht := one_le_tri hn hqcard hq0 hq1 ha hx hsum + have hf := norm_Fprod_le hn hqcard hq1 hx hβ + have hcoef : ((n : ℂ) - 1) * (a : ℂ) * ((x : ℂ) + (y : ℂ) * Complex.I) = + (a : ℂ) * q.sum := by rw [hsum]; ring + rw [hcoef] at ht + have hi : ‖(a : ℂ) * q.sum * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ ≤ + a * ((n : ℝ) - 1) / (n : ℝ) * + ‖(n : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ := by + simp only [norm_mul, Complex.norm_real, Real.norm_eq_abs, abs_of_nonneg ha, + Complex.norm_natCast] + have hm := mul_le_mul_of_nonneg_right (mul_le_mul_of_nonneg_left hsumle ha) + (norm_nonneg (∫ t in (0 : ℝ)..1, Fprod a q t)) + have he : a * ((n : ℝ) - 1) / (n : ℝ) * + ((n : ℝ) * ‖∫ t in (0 : ℝ)..1, Fprod a q t‖) = + a * ((n : ℝ) - 1) * ‖∫ t in (0 : ℝ)..1, Fprod a q t‖ := by + field_simp + rw [he] + exact hm + have htri := norm_add_le (Fprod a q 1) + ((a : ℂ) * q.sum * (∫ t in (0 : ℝ)..1, Fprod a q t)) + have hexp : (n : ℝ) - 1 - 1 = (n : ℝ) - 2 := by ring + simp only [T, hexp] + nlinarith only [ht, hf, hi, htri] + +/-- Solved form of the general norm budget. No polar or first-origin upper bound +is needed; those hypotheses are not hidden in the beta nonnegativity proof. -/ +theorem norm_J_lower {n : ℕ} (hn : 2 ≤ n) {a x y : ℝ} {q : Multiset ℂ} + (ha : 0 < a) (hx1 : x ≤ 1) + (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x) + (hsum : q.sum = ((n : ℂ) - 1) * ((x : ℂ) + (y : ℂ) * Complex.I)) : + ((1 - T ((n : ℝ) - 1) a x) * (n : ℝ)) / (a * ((n : ℝ) - 1)) ≤ + ‖(n : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ := by + have hnR : (2 : ℝ) ≤ n := by exact_mod_cast hn + have hn0 : (n : ℝ) ≠ 0 := by linarith + have hm0 : 0 < (n : ℝ) - 1 := by linarith + have hβ : 0 ≤ QQ (a * x) (a ^ 2) 1 := by + have he : QQ (a * x) (a ^ 2) 1 = (1 - a) ^ 2 + 2 * a * (1 - x) := by + unfold QQ; ring + rw [he] + have : 0 ≤ 1 - x := sub_nonneg.mpr hx1 + positivity + have hl := lower_budget_norm hn ha.le hqcard hq1 hx hsum hβ + have hs : 1 - T ((n : ℝ) - 1) a x ≤ a * ((n : ℝ) - 1) / (n : ℝ) * + ‖(n : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ := by linarith + have hmul := mul_le_mul_of_nonneg_right hs (by linarith : (0 : ℝ) ≤ n) + have he : a * ((n : ℝ) - 1) / (n : ℝ) * + ‖(n : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ * (n : ℝ) = + ‖(n : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ * (a * ((n : ℝ) - 1)) := by + field_simp + rw [he] at hmul + exact (div_le_iff₀ (mul_pos ha hm0)).mpr hmul + +/-- The finite mean coordinates, proved solely from the pointwise closed disk. -/ +lemma mean_coordinates {n : ℕ} (hn : 2 ≤ n) {q : Multiset ℂ} + (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) : + ∃ x y : ℝ, -1 ≤ x ∧ x ≤ 1 ∧ + (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x ∧ + q.sum = ((n : ℂ) - 1) * ((x : ℂ) + (y : ℂ) * Complex.I) := by + have hnR : (2 : ℝ) ≤ n := by exact_mod_cast hn + have hm0 : 0 < (n : ℝ) - 1 := by linarith + have hmC : (n : ℂ) - 1 ≠ 0 := by exact_mod_cast (ne_of_gt hm0) + have hc : (q.card : ℝ) = (n : ℝ) - 1 := by + rw [hqcard, Nat.cast_sub (by omega : 1 ≤ n)]; norm_num + let μ : ℂ := q.sum / ((n : ℂ) - 1) + have hsum : q.sum = ((n : ℂ) - 1) * ((μ.re : ℂ) + (μ.im : ℂ) * Complex.I) := by + rw [Complex.re_add_im] + dsimp [μ] + field_simp + have hnc : ‖(n : ℂ) - 1‖ = (n : ℝ) - 1 := by + have he : (n : ℂ) - 1 = (((n : ℝ) - 1 : ℝ) : ℂ) := by push_cast; rfl + rw [he, Complex.norm_real, Real.norm_eq_abs, abs_of_pos hm0] + have hqsum := norm_sum_le_card q hq1 + rw [hc] at hqsum + have hμ : ‖μ‖ ≤ 1 := by + dsimp [μ] + rw [norm_div, hnc, div_le_iff₀ hm0] + simpa using hqsum + have hx0 : -1 ≤ μ.re := by + have h := Complex.abs_re_le_norm μ + exact (abs_le.mp (h.trans hμ)).1 + have hx1 : μ.re ≤ 1 := (Complex.re_le_norm μ).trans hμ + have hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * μ.re := by + have hre : (q.map (fun v => v.re)).sum = q.sum.re := + (map_multiset_sum Complex.reAddGroupHom q).symm + rw [hre, hsum] + simp + exact ⟨μ.re, μ.im, hx0, hx1, hx, hsum⟩ + +/-- n = 6: a quantitative lower norm bound from pointwise disk plus polar alone. -/ +theorem norm_J_six {a : ℝ} (ha0 : 0 < a) (ha1 : a < 1) {q : Multiset ℂ} + (hqcard : q.card = 6 - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hstar : 1 ≤ ∫ t in (0 : ℝ)..1, + (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) : + 1 + (3 / 40 : ℝ) * (1 - a) ≤ + ‖(6 : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ := by + obtain ⟨x, y, hx0, hx1, hx, hsum⟩ := mean_coordinates (by norm_num : 2 ≤ 6) hqcard hq1 + have hpolar := one_le_integral_Ppolar (by norm_num : 2 ≤ 6) hqcard hq1 hx hstar + have hxhalf := polar_mean_gt_half_add_one (Or.inl rfl : 6 = 6 ∨ 6 = 7) ha0 ha1 hx0 hpolar + have hβ := (beta_B_bounds ha0.le ha1.le hxhalf.le hx1 + (by norm_num : (0 : ℝ) ≤ 1) le_rfl).1 + have hl := lower_budget_norm (by norm_num : 2 ≤ 6) ha0.le hqcard hq1 hx hsum hβ + have hg := T_five_gap ha0 ha1 hxhalf.le hx1 + norm_num at hl + have hm : a * (1 + (3 / 40 : ℝ) * (1 - a)) ≤ + a * ‖(6 : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ := by + norm_num + nlinarith only [hl, hg] + exact (mul_le_mul_iff_right₀ ha0).mp hm + +/-- n = 7: a quantitative lower norm bound from pointwise disk plus polar alone. -/ +theorem norm_J_seven {a : ℝ} (ha0 : 0 < a) (ha1 : a < 1) {q : Multiset ℂ} + (hqcard : q.card = 7 - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hstar : 1 ≤ ∫ t in (0 : ℝ)..1, + (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) : + 1 + (31 / 160 : ℝ) * (1 - a) ≤ + ‖(7 : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ := by + obtain ⟨x, y, hx0, hx1, hx, hsum⟩ := mean_coordinates (by norm_num : 2 ≤ 7) hqcard hq1 + have hpolar := one_le_integral_Ppolar (by norm_num : 2 ≤ 7) hqcard hq1 hx hstar + have hxhalf := polar_mean_gt_half_add_one (Or.inr rfl : 7 = 6 ∨ 7 = 7) ha0 ha1 hx0 hpolar + have hβ := (beta_B_bounds ha0.le ha1.le hxhalf.le hx1 + (by norm_num : (0 : ℝ) ≤ 1) le_rfl).1 + have hl := lower_budget_norm (by norm_num : 2 ≤ 7) ha0.le hqcard hq1 hx hsum hβ + have hg := T_six_gap ha0 ha1 hxhalf.le hx1 + norm_num at hl + have hm : a * (1 + (31 / 160 : ℝ) * (1 - a)) ≤ + a * ‖(7 : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ := by + norm_num + nlinarith only [hl, hg] + exact (mul_le_mul_iff_right₀ ha0).mp hm + +end Sendov.FirstOriginMargins diff --git a/Sendov/Analytic/PaperHistoricalBounds.lean b/Sendov/Analytic/PaperHistoricalBounds.lean new file mode 100644 index 0000000..734f40a --- /dev/null +++ b/Sendov/Analytic/PaperHistoricalBounds.lean @@ -0,0 +1,443 @@ +import Sendov.Analytic.PaperGlobalPolar +import Sendov.Analytic.PaperTwoEnd +import Sendov.Analytic.PaperTail + +/-! +# Retained historical bounds on the actual origin integral + +Round 4, §§3–4: these are quantitative bounds on `T`, not merely the later +weaker domain conclusion `T < B`. They are independent of `PaperUniform`. +The logarithmic certificate uses `log 256 = 8 log 2`; the tail certificates +are finite rational Taylor lower bounds, checked by the kernel. +-/ +namespace Sendov.PaperHistoricalBounds + +open PaperPolar + +lemma log_257_gt : (27 : ℝ) / 5 < Real.log 257 := by + have h := Real.log_two_gt_d9 + have he : Real.log 256 = 8 * Real.log 2 := by + rw [show (256 : ℝ) = 2 ^ 8 by norm_num, Real.log_pow] + norm_num + have hmono : Real.log 256 ≤ Real.log 257 := Real.log_le_log (by norm_num) (by norm_num) + rw [he] at hmono + linarith + +/-- Historical scale bound, strictly stronger than the degree-256 scale bound. -/ +theorem degree_mul_sq_gt {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : (32 : ℝ) / 3 < (m : ℝ) * x ^ 2 := by + have hm' : (512 : ℝ) ≤ m := by exact_mod_cast hm + have hN : (257 : ℝ) ≤ ((m : ℝ) + 2) / 2 := by linarith + have hN0 : 0 < ((m : ℝ) + 2) / 2 := by positivity + have hlog : (27 : ℝ) / 5 < Real.log (((m : ℝ) + 2) / 2) := + log_257_gt.trans_le (Real.log_le_log (by norm_num) hN) + have hc := (div_le_iff₀ hN0).mp + (PaperGlobalPolar.log_degree_le_c (by omega) ha ha1 hx0 hx1 hr) + have hcx : c a x ≤ x ^ 2 := by unfold c b; nlinarith [sq_nonneg (x - a)] + have hmul := mul_le_mul_of_nonneg_right hcx hN0.le + have hscaled : (27 : ℝ) / 5 < (((m : ℝ) + 2) / 2) * x ^ 2 := by nlinarith + have hfactor : (m : ℝ) + 2 ≤ (257 : ℝ) / 256 * m := by linarith + have hlast := mul_le_mul_of_nonneg_right hfactor (sq_nonneg x) + nlinarith + +/-- The original, weaker exponent `exp(-k/3)` is valid for every real `m ≥ 9`. -/ +theorem budget_lt_middle {m a x : ℝ} (hm : 9 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : 0 < x) (hx1 : x ≤ 1) (hxa : x < a) (hax : a < 3 * x / 2) : + PaperTaylor.budget m a x < 4 / (m * x ^ 2) + + (1 + 5 * m * x ^ 2 / 8) * Real.exp (-(m * x ^ 2) / 3) := by + apply (PaperTwoEnd.budget_lt_middle (by linarith) ha ha1 hx hx1 hxa hax).trans_le + apply add_le_add_right + apply mul_le_mul_of_nonneg_left _ (by positivity) + apply Real.exp_le_exp.mpr + nlinarith only [mul_nonneg (show 0 ≤ m - 9 by linarith) (sq_nonneg x)] + +/-- Monotonicity for the historical correction, without stronger later exponents. -/ +lemma middle_antitone : AntitoneOn + (fun k : ℝ => (1 + 5 * k / 8) * Real.exp (-k / 3)) (Set.Ici 3) := by + have hd (k : ℝ) : HasDerivAt + (fun k : ℝ => (1 + 5 * k / 8) * Real.exp (-k / 3)) + ((5 / 8 - (1 + 5 * k / 8) / 3) * Real.exp (-k / 3)) k := by + convert! (((((hasDerivAt_id k).const_mul 5).div_const 8).const_add 1).mul + (((hasDerivAt_id k).neg.div_const 3).exp)) using 1 + dsimp + ring + apply antitoneOn_of_deriv_nonpos (convex_Ici _) (by fun_prop) + · intro k hk; exact (hd k).differentiableAt.differentiableWithinAt + · intro k hk + rw [(hd k).deriv] + have hk' : 3 ≤ k := interior_subset hk + exact mul_nonpos_of_nonpos_of_nonneg (by linarith) (Real.exp_pos _).le + +lemma middle_base : (1 + 5 * ((32 : ℝ) / 3) / 8) * Real.exp (-(32 / 3) / 3) < 9 / 40 := by + have he : (920 : ℝ) / 27 < Real.exp (32 / 9) := by + have h := Real.sum_le_exp_of_nonneg (by norm_num : (0 : ℝ) ≤ 32 / 9) 16 + norm_num [Finset.sum_range_succ, Nat.factorial_succ] at h ⊢ + linarith + rw [show (-(32 / 3) / 3 : ℝ) = -(32 / 9) by ring, Real.exp_neg, ← div_eq_mul_inv] + apply (div_lt_iff₀ (Real.exp_pos _)).mpr + linarith + +lemma chord_eq (a x : ℝ) : PaperTaylor.chord a x = c a x := by + unfold PaperTaylor.chord c b + ring + +lemma beta_one_eq (a x : ℝ) : PaperTaylor.beta a x 1 = b a x := by + unfold PaperTaylor.beta b + ring + +/-- The actual `t`-coordinate integral is less than `3/5`, for every `m ≥ 512`. -/ +theorem budget_lt_three_fifths {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : PaperTaylor.budget m a x < 3 / 5 := by + have hm' : (512 : ℝ) ≤ m := by exact_mod_cast hm + have hg := geometry (by omega : 7 ≤ m) ha ha1 hx0 hx1 hr + have hx : 0 < x := by linarith [hg.1] + have hc : 0 < PaperTaylor.chord a x := by rw [chord_eq]; exact hg.2 + have hk := degree_mul_sq_gt hm ha ha1 hx0 hx1 hr + have hleft : 4 / ((m : ℝ) * x ^ 2) < 3 / 8 := by + apply (div_lt_iff₀ (by positivity)).mpr + linarith + by_cases hsep : a ≤ x ∨ 3 * x / 2 ≤ a + · have h := PaperTwoEnd.budget_lt_separated (m := (m : ℝ)) (by linarith) ha ha1 hx hx1 hc hsep + have he := PaperGlobalPolar.endpoint_le (by omega) ha ha1 hx0 hx1 hr + rw [beta_one_eq] at h + have he' : 4 / ((m : ℝ) + 2) ≤ 4 / 514 := by + apply (div_le_div_iff₀ (by positivity) (by norm_num)).mpr + linarith + linarith + · push Not at hsep + have h := budget_lt_middle (m := (m : ℝ)) (by linarith) ha ha1 hx hx1 hsep.1 hsep.2 + have hmono := middle_antitone (by norm_num : (32 / 3 : ℝ) ∈ Set.Ici 3) + (show (m : ℝ) * x ^ 2 ∈ Set.Ici 3 by apply Set.mem_Ici.mpr; linarith) hk.le + dsimp at hmono + nlinarith only [h, hleft, hmono, middle_base] + +/-- Independent real-degree tail certificate for the retained-`a` bulk bound. -/ +lemma middle_tail {m : ℝ} (hm : 512 ≤ m) : + m * (1 + m / 40) * Real.exp (-m / 75) < 24 := by + have h1 := PaperTail.power_exp_antitone (n := 1) (c := 1 / 75) (d := 0) + (by norm_num) (by norm_num : (0 : ℝ) < 512) (by norm_num) (by norm_num) + (show (512 : ℝ) ∈ Set.Ici 512 by simp) hm hm + have h2 := PaperTail.power_exp_antitone (n := 2) (c := 1 / 75) (d := 0) + (by norm_num) (by norm_num : (0 : ℝ) < 512) (by norm_num) (by norm_num) + (show (512 : ℝ) ∈ Set.Ici 512 by simp) hm hm + have he : (512 : ℝ) * (1 + 512 / 40) < 24 * Real.exp (512 / 75) := by + have h := Real.sum_le_exp_of_nonneg (by norm_num : (0 : ℝ) ≤ 512 / 75) 16 + norm_num [Finset.sum_range_succ, Nat.factorial_succ] at h ⊢ + linarith + have hb : (512 : ℝ) * (1 + 512 / 40) * Real.exp (-512 / 75) < 24 := by + rw [show (-512 / 75 : ℝ) = -(512 / 75) by ring, Real.exp_neg, ← div_eq_mul_inv] + exact (div_lt_iff₀ (Real.exp_pos _)).mpr he + dsimp at h1 h2 + simp only [sub_zero, pow_one] at h1 h2 + have heq (t : ℝ) : -(1 / 75 : ℝ) * t = -t / 75 := by ring + simp only [heq] at h1 h2 + nlinarith only [h1, h2, hb] + +/-- Retaining `a`: the real integral satisfies `T < 40/(m*a²)` on the historical bulk domain. -/ +theorem budget_lt_forty {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (ha2 : 2 / 5 ≤ a) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar m a x) : + PaperTaylor.budget m a x < 40 / ((m : ℝ) * a ^ 2) := by + have hm' : (512 : ℝ) ≤ m := by exact_mod_cast hm + have hm0 : 0 < (m : ℝ) := by positivity + have hg := geometry (by omega : 7 ≤ m) ha ha1 hx0 hx1 hr + have hx : 0 < x := by linarith [hg.1] + have hc : 0 < PaperTaylor.chord a x := by rw [chord_eq]; exact hg.2 + have hsq : a ^ 2 / 4 < x ^ 2 := by nlinarith [hg.1] + have hx25 : 1 / 25 ≤ x ^ 2 := by nlinarith + have hk : (m : ℝ) / 25 ≤ (m : ℝ) * x ^ 2 := by nlinarith [mul_le_mul_of_nonneg_left hx25 hm0.le] + have hleft : 4 / ((m : ℝ) * x ^ 2) < 16 / ((m : ℝ) * a ^ 2) := by + apply (div_lt_div_iff₀ (by positivity) (by positivity)).mpr + nlinarith only [mul_pos hm0 (sub_pos.mpr hsq)] + have htotal : PaperTaylor.budget m a x < 4 / ((m : ℝ) * x ^ 2) + 24 / m := by + by_cases hsep : a ≤ x ∨ 3 * x / 2 ≤ a + · have h := PaperTwoEnd.budget_lt_separated (m := (m : ℝ)) (by linarith) ha ha1 hx hx1 hc hsep + have he := PaperGlobalPolar.endpoint_le (by omega) ha ha1 hx0 hx1 hr + rw [beta_one_eq] at h + have he' : 4 / ((m : ℝ) + 2) ≤ 4 / m := by + apply (div_le_div_iff₀ (by positivity) hm0).mpr + linarith + have he24 : 6 * (4 / (m : ℝ)) = 24 / m := by ring + linarith + · push Not at hsep + have h := budget_lt_middle (m := (m : ℝ)) (by linarith) ha ha1 hx hx1 hsep.1 hsep.2 + have hmono := middle_antitone + (show (m : ℝ) / 25 ∈ Set.Ici 3 by apply Set.mem_Ici.mpr; linarith) + (show (m : ℝ) * x ^ 2 ∈ Set.Ici 3 by apply Set.mem_Ici.mpr; linarith) hk + dsimp at hmono + have heq : (1 + 5 * ((m : ℝ) / 25) / 8) * Real.exp (-((m : ℝ) / 25) / 3) = + (1 + (m : ℝ) / 40) * Real.exp (-(m : ℝ) / 75) := by + congr 1 + · ring + · congr 1 + ring + rw [heq] at hmono + have ht := (lt_div_iff₀ hm0).mpr (show + (1 + (m : ℝ) / 40) * Real.exp (-(m : ℝ) / 75) * m < 24 by + nlinarith only [middle_tail hm']) + nlinarith only [h, hmono, ht] + have hrest : 24 / (m : ℝ) ≤ 24 / ((m : ℝ) * a ^ 2) := by + apply (div_le_div_iff₀ hm0 (by positivity)).mpr + nlinarith only [mul_nonneg hm0.le (show 0 ≤ 1 - a ^ 2 by nlinarith)] + have heq : 16 / ((m : ℝ) * a ^ 2) + 24 / ((m : ℝ) * a ^ 2) = + 40 / ((m : ℝ) * a ^ 2) := by ring + linarith + +/-- A general chord majorant, integrated to its zero (never the growing quadratic). -/ +lemma integral_chord_le {p a x s : ℝ} (hp : 0 < p) (ha : 0 < a) + (hx : 0 ≤ x) (hx1 : x ≤ 1) (hs : 0 < s) (hsa : s ≤ 2 * x - a) : + (∫ u in (0 : ℝ)..a, u * PaperTwoEnd.Q x u ^ p) ≤ + 1 / (s ^ 2 * ((p + 1) * (p + 2))) := by + have hc : Continuous (fun u : ℝ => u * (1 - s * u) ^ p) := + continuous_id.mul ((continuous_rpow_const hp.le).comp (by fun_prop)) + have hzero : a ≤ 1 / s := by + apply (le_div_iff₀ hs).mpr + have hq := PaperTwoEnd.Q_nonneg hx hx1 a + unfold PaperTwoEnd.Q at hq + nlinarith [mul_le_mul_of_nonneg_right hsa ha.le] + have hle : (∫ u in (0 : ℝ)..a, u * PaperTwoEnd.Q x u ^ p) ≤ + ∫ u in (0 : ℝ)..a, u * (1 - s * u) ^ p := by + apply intervalIntegral.integral_mono_on ha.le + ((PaperTwoEnd.continuous_weight hp.le x).intervalIntegrable _ _) + (hc.intervalIntegrable _ _) + intro u hu + apply mul_le_mul_of_nonneg_left _ hu.1 + apply Real.rpow_le_rpow (PaperTwoEnd.Q_nonneg hx hx1 u) _ hp.le + unfold PaperTwoEnd.Q + nlinarith only [mul_nonneg hu.1 (show 0 ≤ 2 * x - s - u by linarith [hu.2])] + have hrest : 0 ≤ ∫ u in a..1 / s, u * (1 - s * u) ^ p := by + apply intervalIntegral.integral_nonneg hzero + intro u hu + have hz := (le_div_iff₀ hs).mp hu.2 + exact mul_nonneg (ha.le.trans hu.1) (Real.rpow_nonneg (by linarith) _) + have hadd := intervalIntegral.integral_add_adjacent_intervals (μ := MeasureTheory.volume) + (hc.intervalIntegrable 0 a) (hc.intervalIntegrable a (1 / s)) + rw [integral_chord_lin hp hs] at hadd + linarith + +/-- Exact rational contribution of the chord, with a retained slope parameter. -/ +lemma total_le_chord {m a x s : ℝ} (hm : 7 ≤ m) (ha : 0 < a) + (hx : 0 < x) (hx1 : x ≤ 1) (hs : 0 < s) (hsa : s ≤ 2 * x - a) : + PaperTwoEnd.total m a x ≤ + 4 * m / ((m + 1) * (m + 3) * s ^ 2) + PaperTwoEnd.endpoint m a x := by + have h := mul_le_mul_of_nonneg_left + (integral_chord_le (p := (m - 1) / 2) (by linarith) ha hx.le hx1 hs hsa) + (show 0 ≤ m by linarith) + have heq : m * (1 / (s ^ 2 * (((m - 1) / 2 + 1) * ((m - 1) / 2 + 2)))) = + 4 * m / ((m + 1) * (m + 3) * s ^ 2) := by + rw [show ((m - 1) / 2 + 1) * ((m - 1) / 2 + 2) = (m + 1) * (m + 3) / 4 by ring] + field_simp + rw [heq] at h + unfold PaperTwoEnd.total + linarith + +/-- The same sharp rising-secant integral at the historical split `a ≥ 7*x/5`. -/ +lemma right_le_six_endpoint {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : 0 < x) (hx1 : x ≤ 1) (hc : 0 < PaperTaylor.chord a x) + (hsep : 7 * x / 5 ≤ a) : + m * (∫ u in x..a, u * PaperTwoEnd.Q x u ^ ((m - 1) / 2)) ≤ + 6 * PaperTwoEnd.endpoint m a x := by + let p := (m - 1) / 2 + let D := PaperTwoEnd.Q x a ^ (p + 1) - PaperTwoEnd.Q x x ^ (p + 1) + have hp : 0 ≤ p := by dsimp [p]; linarith + have hp1 : 0 < p + 1 := by linarith + have hm0 : 0 ≤ m := by linarith + have hxa : x < a := by linarith + have hl : 0 < a - x := sub_pos.mpr hxa + have hb := PaperTwoEnd.Q_pos ha1 hx1 ⟨ha.le, le_rfl⟩ + have hb1 : PaperTwoEnd.Q x a ≤ 1 := by + unfold PaperTaylor.chord at hc + unfold PaperTwoEnd.Q + nlinarith + have hE : 0 ≤ PaperTwoEnd.endpoint m a x := Real.rpow_nonneg hb.le _ + have hD : D ≤ PaperTwoEnd.endpoint m a x := by + have hv := Real.rpow_nonneg (PaperTwoEnd.Q_nonneg hx.le hx1 x) (p + 1) + have hbE : PaperTwoEnd.Q x a ^ (p + 1) ≤ PaperTwoEnd.endpoint m a x := + Real.rpow_le_rpow_of_exponent_ge hb hb1 (by dsimp [p]; linarith) + dsimp [D] + linarith + have hw : m * (∫ u in x..a, (u - x) * PaperTwoEnd.Q x u ^ p) ≤ + PaperTwoEnd.endpoint m a x := by + rw [PaperTwoEnd.integral_right_weight hp, ← mul_div_assoc] + apply (div_le_iff₀ (show 0 < 2 * (p + 1) by positivity)).mpr + have h := mul_le_mul_of_nonneg_left hD hm0 + change m * D ≤ PaperTwoEnd.endpoint m a x * (2 * (p + 1)) + dsimp [p] at * + nlinarith + have hc5 : m * x ≤ 5 * ((a - x) * (p + 1)) := by + have h := mul_nonneg (show 0 ≤ 5 * (a - x) - 2 * x by linarith) + (show 0 ≤ m + 1 by linarith) + dsimp [p] + nlinarith + have hu : m * x * (∫ u in x..a, PaperTwoEnd.Q x u ^ p) ≤ + 5 * PaperTwoEnd.endpoint m a x := by + have h := mul_le_mul_of_nonneg_left (PaperTwoEnd.integral_right_unweighted hp hx.le hx1 hxa) + (show 0 ≤ m * x by positivity) + apply h.trans + rw [← mul_div_assoc] + apply (div_le_iff₀ (mul_pos hl hp1)).mpr + have h1 := mul_le_mul_of_nonneg_left hD (show 0 ≤ m * x by positivity) + have h2 := mul_le_mul_of_nonneg_right hc5 hE + change m * x * D ≤ 5 * PaperTwoEnd.endpoint m a x * ((a - x) * (p + 1)) + nlinarith + have hcq : Continuous (fun u : ℝ => PaperTwoEnd.Q x u ^ p) := + (continuous_rpow_const hp).comp (by unfold PaperTwoEnd.Q; fun_prop) + have hiw : IntervalIntegrable (fun u : ℝ => (u - x) * PaperTwoEnd.Q x u ^ p) + MeasureTheory.volume x a := + ((continuous_id.sub continuous_const).mul hcq).intervalIntegrable x a + have hiu := (hcq.intervalIntegrable x a (μ := MeasureTheory.volume)).const_mul x + have hsplit : (∫ u in x..a, u * PaperTwoEnd.Q x u ^ p) = + (∫ u in x..a, (u - x) * PaperTwoEnd.Q x u ^ p) + + x * ∫ u in x..a, PaperTwoEnd.Q x u ^ p := by + rw [← intervalIntegral.integral_const_mul, ← intervalIntegral.integral_add hiw hiu] + apply intervalIntegral.integral_congr + intro u _ + ring + change m * (∫ u in x..a, u * PaperTwoEnd.Q x u ^ p) ≤ _ + rw [hsplit] + nlinarith + +/-- Historical A5 on the actual integral, before endpoint suppression. -/ +theorem total_le_A5 {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : 0 < x) (hx1 : x ≤ 1) (hc : 0 < PaperTaylor.chord a x) : + PaperTwoEnd.total m a x ≤ 100 * m / (9 * (m + 1) * (m + 3) * x ^ 2) + + 29 * PaperTwoEnd.endpoint m a x := by + have hm0 : 0 < m := by linarith + have hE : 0 ≤ PaperTwoEnd.endpoint m a x := + Real.rpow_nonneg (PaperTwoEnd.Q_nonneg hx.le hx1 a) _ + by_cases hsep : 7 * x / 5 ≤ a + · have hr := right_le_six_endpoint hm ha ha1 hx hx1 hc hsep + have hl := PaperTwoEnd.left_le hm ha hx hx1 + rw [min_eq_right (by linarith : x ≤ a)] at hl + have hcoeff : 4 * m / ((m + 1) * (m + 3) * x ^ 2) ≤ + 100 * m / (9 * (m + 1) * (m + 3) * x ^ 2) := by + apply (div_le_div_iff₀ (by positivity) (by positivity)).mpr + nlinarith only [mul_nonneg hm0.le (mul_nonneg + (mul_nonneg (show 0 ≤ m + 1 by linarith) (show 0 ≤ m + 3 by linarith)) (sq_nonneg x))] + rw [PaperTwoEnd.total_split hm] + linarith + · have h := total_le_chord hm ha hx hx1 (show 0 < 3 * x / 5 by positivity) + (show 3 * x / 5 ≤ 2 * x - a by linarith) + have heq : 4 * m / ((m + 1) * (m + 3) * (3 * x / 5) ^ 2) = + 100 * m / (9 * (m + 1) * (m + 3) * x ^ 2) := by field_simp; ring + rw [heq] at h + linarith + +/-- Historical A5b, retaining its exact rational degree factor. -/ +theorem total_le_A5b {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) + (hx : 0 < x) (hx1 : x ≤ 1) (hc : 0 < PaperTaylor.chord a x) : + PaperTwoEnd.total m a x ≤ 16 * m / ((m + 1) * (m + 3) * x ^ 2) + + 13 * PaperTwoEnd.endpoint m a x := by + have hm0 : 0 < m := by linarith + have hE : 0 ≤ PaperTwoEnd.endpoint m a x := + Real.rpow_nonneg (PaperTwoEnd.Q_nonneg hx.le hx1 a) _ + by_cases hsep : 3 * x / 2 ≤ a + · have hr := PaperTwoEnd.right_le_five_endpoint hm ha ha1 hx hx1 hc hsep + have hl := PaperTwoEnd.left_le hm ha hx hx1 + rw [min_eq_right (by linarith : x ≤ a)] at hl + have hcoeff : 4 * m / ((m + 1) * (m + 3) * x ^ 2) ≤ + 16 * m / ((m + 1) * (m + 3) * x ^ 2) := by + apply div_le_div_of_nonneg_right (by linarith) (by positivity) + rw [PaperTwoEnd.total_split hm] + linarith + · have h := total_le_chord hm ha hx hx1 (show 0 < x / 2 by positivity) + (show x / 2 ≤ 2 * x - a by linarith) + have heq : 4 * m / ((m + 1) * (m + 3) * (x / 2) ^ 2) = + 16 * m / ((m + 1) * (m + 3) * x ^ 2) := by field_simp; ring + rw [heq] at h + linarith + +/-- A5 with raw polar, all degrees `m ≥ 7`, on the actual `t`-coordinate integral. -/ +theorem budget_le_A5 {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : PaperTaylor.budget m a x ≤ + 100 * m / (9 * ((m : ℝ) + 1) * (m + 3) * x ^ 2) + 116 / ((m : ℝ) + 2) := by + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + have hg := geometry hm ha ha1 hx0 hx1 hr + have hx : 0 < x := by linarith [hg.1] + have hc : 0 < PaperTaylor.chord a x := by rw [chord_eq]; exact hg.2 + have h := total_le_A5 hm' ha ha1 hx hx1 hc + have he := PaperGlobalPolar.endpoint_le hm ha ha1 hx0 hx1 hr + rw [PaperTwoEnd.total_eq_budget ha] at h + have hendpoint : PaperTwoEnd.endpoint m a x = b a x ^ ((m : ℝ) / 2) := by + unfold PaperTwoEnd.endpoint PaperTwoEnd.Q b + congr 1 + ring + rw [hendpoint] at h + have heq : 29 * (4 / ((m : ℝ) + 2)) = 116 / ((m : ℝ) + 2) := by ring + linarith + +/-- A5b with raw polar, including the odd degree `7` and even degree `8`. -/ +theorem budget_le_A5b {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : PaperTaylor.budget m a x ≤ + 16 * m / (((m : ℝ) + 1) * (m + 3) * x ^ 2) + 52 / ((m : ℝ) + 2) := by + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + have hg := geometry hm ha ha1 hx0 hx1 hr + have hx : 0 < x := by linarith [hg.1] + have hc : 0 < PaperTaylor.chord a x := by rw [chord_eq]; exact hg.2 + have h := total_le_A5b hm' ha ha1 hx hx1 hc + have he := PaperGlobalPolar.endpoint_le hm ha ha1 hx0 hx1 hr + rw [PaperTwoEnd.total_eq_budget ha] at h + have hendpoint : PaperTwoEnd.endpoint m a x = b a x ^ ((m : ℝ) / 2) := by + unfold PaperTwoEnd.endpoint PaperTwoEnd.Q b + congr 1 + ring + rw [hendpoint] at h + have heq : 13 * (4 / ((m : ℝ) + 2)) = 52 / ((m : ℝ) + 2) := by ring + linarith + +/-- The historical bulk constant, with no degree-512 or lower-radius assumption. -/ +theorem budget_lt_bulk116 {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : PaperTaylor.budget m a x < 116 / ((m : ℝ) * a ^ 2) := by + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + have hm0 : 0 < (m : ℝ) := by linarith + have hg := geometry hm ha ha1 hx0 hx1 hr + have hx : 0 < x := by linarith [hg.1] + have hsq : a ^ 2 < 4 * x ^ 2 := by nlinarith [hg.1] + have h := budget_le_A5b hm ha ha1 hx0 hx1 hr + have hleft : 16 * m / (((m : ℝ) + 1) * (m + 3) * x ^ 2) < 16 / ((m : ℝ) * x ^ 2) := by + apply (div_lt_div_iff₀ (by positivity) (by positivity)).mpr + nlinarith only [mul_pos (sq_pos_of_pos hx) (show 0 < 4 * (m : ℝ) + 3 by linarith)] + have hleft' : 16 / ((m : ℝ) * x ^ 2) < 64 / ((m : ℝ) * a ^ 2) := by + apply (div_lt_div_iff₀ (by positivity) (by positivity)).mpr + nlinarith only [mul_pos hm0 (sub_pos.mpr hsq)] + have htail : 52 / ((m : ℝ) + 2) ≤ 52 / ((m : ℝ) * a ^ 2) := by + apply (div_le_div_iff₀ (by positivity) (by positivity)).mpr + nlinarith only [mul_nonneg hm0.le (show 0 ≤ 1 - a ^ 2 by nlinarith)] + have heq : 64 / ((m : ℝ) * a ^ 2) + 52 / ((m : ℝ) * a ^ 2) = + 116 / ((m : ℝ) * a ^ 2) := by ring + linarith + +/-- The old bulk cutoff follows from a stronger `T` estimate, not from a uniform D theorem. -/ +theorem budget_lt_one_sub_of_bulk116 {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hbulk : 116 ≤ (m : ℝ) * a ^ 2 * (1 - a)) : + PaperTaylor.budget m a x < 1 - a := by + have hm0 : 0 < (m : ℝ) := by exact_mod_cast (show 0 < m by omega) + apply (budget_lt_bulk116 hm ha ha1 hx0 hx1 hr).trans_le + apply (div_le_iff₀ (by positivity)).mpr + nlinarith only [hbulk] + +/-- The historical improved bulk cutoff retains the strict margin to `1-a`. -/ +theorem budget_lt_one_sub_of_bulk40 {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (ha2 : 2 / 5 ≤ a) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar m a x) + (hbulk : 40 ≤ (m : ℝ) * a ^ 2 * (1 - a)) : + PaperTaylor.budget m a x < 1 - a := by + have hm0 : 0 < (m : ℝ) := by exact_mod_cast (show 0 < m by omega) + apply (budget_lt_forty hm ha ha1 ha2 hx0 hx1 hr).trans_le + apply (div_le_iff₀ (by positivity)).mpr + nlinarith only [hbulk] + +/-- All small radii are closed with the stronger historical bound, independently of D. -/ +theorem budget_lt_one_sub_of_small {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (ha2 : a ≤ 2 / 5) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar m a x) : + PaperTaylor.budget m a x < 1 - a := + (budget_lt_three_fifths hm ha ha1 hx0 hx1 hr).trans_le (by linarith) + +end Sendov.PaperHistoricalBounds diff --git a/Sendov/Analytic/PaperUniform.lean b/Sendov/Analytic/PaperUniform.lean new file mode 100644 index 0000000..6ec6744 --- /dev/null +++ b/Sendov/Analytic/PaperUniform.lean @@ -0,0 +1,188 @@ +import Sendov.Analytic.PaperGlobalPolar +import Sendov.Analytic.PaperTwoEnd +import Sendov.Analytic.PaperTail +import Sendov.Analytic.PaperRayGeometry +import Sendov.Analytic.PaperNear +import Sendov.Analytic.PaperBulkAlgebra + +/-! # Uniform D for all natural degrees at least 256 + +The two-endpoint integral bounds give both a global two-thirds bound and a +retained-radius bound. The remaining continuous rays use sharp Laplace and +raw-polar geometry. No analytic estimate is assumed by the public theorem. +-/ +namespace Sendov.PaperUniform + +open PaperPolar + +lemma beta_one (a x : ℝ) : PaperTaylor.beta a x 1 = b a x := by + simp only [PaperTaylor.beta, b, mul_one, one_pow] + +lemma chord_eq (a x : ℝ) : PaperTaylor.chord a x = c a x := by + unfold PaperTaylor.chord c b + ring + +/-- A single rational Taylor certificate, independent of the degree. -/ +lemma exp_seventeen_fifths : (29 : ℝ) < Real.exp (17 / 5 : ℝ) := by + have h := Real.sum_le_exp_of_nonneg (by norm_num : (0 : ℝ) ≤ 17 / 5) 16 + norm_num [Finset.sum_range_succ, Nat.factorial_succ] at h + linarith + +lemma middle_relax {m x : ℝ} (hm : 256 ≤ m) : + (1 + 5 * m * x ^ 2 / 8) * Real.exp (-3 * (m - 1) * x ^ 2 / 8) ≤ + (1 + 5 * (m * x ^ 2) / 8) * Real.exp (-(11 / 30 : ℝ) * (m * x ^ 2)) := by + have hm0 : 0 ≤ m := by linarith + rw [mul_assoc 5 m (x ^ 2)] + apply mul_le_mul_of_nonneg_left _ (by positivity) + apply Real.exp_le_exp.mpr + nlinarith only [mul_nonneg (show 0 ≤ m - 45 by linarith) (sq_nonneg x)] + +variable {m : ℕ} {a x : ℝ} + +/-- The actual integral budget is globally less than two thirds. -/ +theorem budget_lt_two_thirds (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : PaperTaylor.budget (m : ℝ) a x < 2 / 3 := by + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast hm + have hm7 : (7 : ℝ) ≤ m := by linarith + obtain ⟨hax, hc⟩ := geometry (by omega : 7 ≤ m) ha ha1 hx0 hx1 hr + have hx : 0 < x := by linarith + have hk := PaperGlobalPolar.degree_mul_sq_gt hm ha ha1 hx0 hx1 hr + have he := PaperGlobalPolar.endpoint_le (by omega) ha ha1 hx0 hx1 hr + rw [← beta_one] at he + have hleft : 4 / ((m : ℝ) * x ^ 2) < 8 / 19 := by + apply (div_lt_iff₀ (by positivity : 0 < (m : ℝ) * x ^ 2)).mpr + linarith + by_cases hs : a ≤ x ∨ 3 * x / 2 ≤ a + · have ht := PaperTwoEnd.budget_lt_separated hm7 ha ha1 hx hx1 + (by rw [chord_eq]; exact hc) hs + have he' : 4 / ((m : ℝ) + 2) ≤ 4 / 258 := by + apply (div_le_div_iff₀ (by positivity) (by norm_num)).mpr + linarith + linarith + · push Not at hs + have ht := (PaperTwoEnd.budget_lt_middle hm7 ha ha1 hx hx1 hs.1 hs.2).trans_le + (add_le_add le_rfl (middle_relax (x := x) hm')) + have hf := PaperTail.middle_antitone + (show (19 / 2 : ℝ) ∈ Set.Ici (19 / 2) by simp) hk.le hk.le + have hexp : Real.exp (-(11 / 30 : ℝ) * (19 / 2)) ≤ Real.exp (-(17 / 5 : ℝ)) := + Real.exp_le_exp.mpr (by norm_num) + have hinv : Real.exp (-(17 / 5 : ℝ)) < 1 / 29 := by + rw [Real.exp_neg, ← one_div] + exact one_div_lt_one_div_of_lt (by norm_num) exp_seventeen_fifths + have hf' := mul_le_mul_of_nonneg_left (hexp.trans hinv.le) + (by norm_num : (0 : ℝ) ≤ 1 + 5 * (19 / 2) / 8) + dsimp at hf + linarith + +/-- Retaining a in the left endpoint term is essential at degree 256. -/ +theorem budget_lt_retained (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (ha3 : 1 / 3 ≤ a) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar m a x) : + PaperTaylor.budget (m : ℝ) a x < 16 / ((m : ℝ) * a ^ 2) + 24 / (m : ℝ) := by + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast hm + have hm0 : (0 : ℝ) < m := by linarith + have hm7 : (7 : ℝ) ≤ m := by linarith + obtain ⟨hax, hc⟩ := geometry (by omega : 7 ≤ m) ha ha1 hx0 hx1 hr + have hx : 0 < x := by linarith + have hleft : 4 / ((m : ℝ) * x ^ 2) < 16 / ((m : ℝ) * a ^ 2) := by + apply (div_lt_div_iff₀ (by positivity) (by positivity)).mpr + have hs : a ^ 2 < 4 * x ^ 2 := by nlinarith + nlinarith only [mul_pos hm0 (sub_pos.mpr hs)] + by_cases hs : a ≤ x ∨ 3 * x / 2 ≤ a + · have ht := PaperTwoEnd.budget_lt_separated hm7 ha ha1 hx hx1 + (by rw [chord_eq]; exact hc) hs + have he := PaperGlobalPolar.endpoint_le (by omega) ha ha1 hx0 hx1 hr + rw [← beta_one] at he + have he' : 4 / ((m : ℝ) + 2) ≤ 4 / (m : ℝ) := by + apply (div_le_div_iff₀ (by positivity) hm0).mpr + linarith + simp only [div_eq_mul_inv] at he he' ht hleft ⊢ + linarith + · push Not at hs + have ht := (PaperTwoEnd.budget_lt_middle hm7 ha ha1 hx hx1 hs.1 hs.2).trans_le + (add_le_add le_rfl (middle_relax (x := x) hm')) + have hx2 : (4 / 81 : ℝ) ≤ x ^ 2 := by nlinarith + have hk : (4 : ℝ) * m / 81 ≤ (m : ℝ) * x ^ 2 := by + nlinarith only [mul_le_mul_of_nonneg_left hx2 hm0.le] + have hbase : (19 / 2 : ℝ) ≤ 4 * m / 81 := by linarith + have hf := PaperTail.middle_antitone hbase (hbase.trans hk) hk + have htail := PaperTail.middle_tail hm' + have heq : (1 + 5 * ((4 : ℝ) * m / 81) / 8) * + Real.exp (-(11 / 30 : ℝ) * (4 * m / 81)) = + (1 + 5 * (m : ℝ) / 162) * Real.exp (-22 * m / 1215) := by + rw [show -(11 / 30 : ℝ) * (4 * m / 81) = -22 * m / 1215 by ring] + congr 1 + ring + dsimp at hf + rw [heq] at hf + have hf' : (1 + 5 * ((m : ℝ) * x ^ 2) / 8) * + Real.exp (-(11 / 30 : ℝ) * ((m : ℝ) * x ^ 2)) < 24 / (m : ℝ) := by + apply (lt_div_iff₀ hm0).mpr + have hh := mul_le_mul_of_nonneg_left hf hm0.le + nlinarith only [hh, htail] + linarith + +/-- Closure of the four finite continuous rays, including all seams. -/ +theorem finite_rays_D (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hl0 : 2 / 5 ≤ lambda m a) (hl1 : lambda m a ≤ 49) : + PaperTaylor.budget (m : ℝ) a x < 1 - (m : ℝ) * a / ((m : ℝ) + 1) := by + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast hm + have hx : 0 < x := by + have := (geometry (by omega : 7 ≤ m) ha ha1 hx0 hx1 hr).1 + linarith + have hxa : x < 2 * a := + (div_lt_one (by positivity : 0 < 2 * a)).mp + (PaperRayGeometry.halfpoint_mem hm ha ha1 hx0 hx1 hr hl1).2 + apply PaperRayGeometry.lt_B_of_scaled_lt (by omega : 0 < m) hx + by_cases hl : lambda m a ≤ 1 + · have hg := PaperRayGeometry.geometry_one hm ha ha1 hx0 hx1 hr hl + have hb := (PaperRayGeometry.geometry_ten hm ha ha1 hx0 hx1 hr (by linarith)).1 + rw [← beta_one] at hb + exact (PaperTail.budget_region_one hm' ha ha1 hg hx1 hxa hb.le).trans + (PaperRayGeometry.budget_lower_one hm ha ha1 hx0 hx1 hr hl0 hl) + by_cases hl10 : lambda m a ≤ 10 + · obtain ⟨hb, hg⟩ := PaperRayGeometry.geometry_ten hm ha ha1 hx0 hx1 hr hl10 + rw [← beta_one] at hb + exact (PaperTail.budget_region_two hm' ha ha1 hg hx1 hxa hb.le).trans + (PaperRayGeometry.budget_lower_ten hm ha ha1 hx0 hx1 hr (by linarith) hl10) + by_cases hl25 : lambda m a ≤ 25 + · obtain ⟨hb, hg⟩ := PaperRayGeometry.geometry_twentyfive hm ha ha1 hx0 hx1 hr hl25 + rw [← beta_one] at hb + exact (PaperTail.budget_region_three hm' ha ha1 hg hx1 hxa hb.le).trans + (PaperRayGeometry.budget_lower_twentyfive hm ha ha1 hx0 hx1 hr (by linarith) hl25) + · obtain ⟨hb, hg⟩ := PaperRayGeometry.geometry_fortynine hm ha ha1 hx0 hx1 hr hl1 + rw [← beta_one] at hb + exact (PaperTail.budget_region_four hm' ha ha1 hg hx1 hxa hb.le).trans + (PaperRayGeometry.budget_lower_fortynine hm ha ha1 hx0 hx1 hr (by linarith) hl1) + +/-- All a, with only the raw polar integral and the stated domain assumptions. -/ +theorem uniform_D (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + PaperTaylor.budget (m : ℝ) a x < 1 - (m : ℝ) * a / ((m : ℝ) + 1) := by + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast hm + have hm0 : (0 : ℝ) < m := by linarith + by_cases ha3 : a ≤ 1 / 3 + · exact PaperBulk.direct_budget_small hm0.le ha ha3 + (budget_lt_two_thirds hm ha ha1 hx0 hx1 hr) + have ht := budget_lt_retained hm ha ha1 (by linarith) hx0 hx1 hr + by_cases ha4 : a ≤ 4 / 5 + · exact PaperBulk.direct_budget_middle hm' (by linarith) ha4 ht + by_cases hl49 : 49 ≤ lambda m a + · have hbulk := PaperBulk.large_ray_budget hm0 (by linarith : 4 / 5 ≤ a) hl49 + have hgap : 1 - a < 1 - (m : ℝ) * a / ((m : ℝ) + 1) := by + have heq : 1 - (m : ℝ) * a / ((m : ℝ) + 1) = + 1 - a + a / ((m : ℝ) + 1) := by field_simp; ring + rw [heq] + have := div_pos ha (show (0 : ℝ) < m + 1 by positivity) + linarith + exact (ht.trans_le hbulk).trans hgap + by_cases hlnear : lambda m a ≤ 2 / 5 + · have hn := PaperNearClosure.near_endpoint_D (by omega) ha ha1 hx0 hx1 hr hlnear + have hp : 0 < (1 - a) / 1000 := by positivity + linarith + · exact finite_rays_D hm ha ha1 hx0 hx1 hr (by linarith) (by linarith) + +end Sendov.PaperUniform diff --git a/Sendov/Interior.lean b/Sendov/Interior.lean index 4c19de0..ce28aad 100644 --- a/Sendov/Interior.lean +++ b/Sendov/Interior.lean @@ -29,9 +29,11 @@ From `(⋆)` the argument branches on the degree. * For `n = 6` or `n = 7`, the first-origin factorization bound and `(⋆)` feed `Sendov.FirstOriginSmall.first_origin_polar_six_seven`, without the second-origin channel. -* For `n ≥ 8`, AM–GM relaxes `(⋆)` to the raw polar inequality `(1Q)`, the centroid identity and - the two origin identities give `(origin-exact)`, and `Sendov.polar_origin_incompatible` says - the two cannot hold together. +* For `n ≥ 257`, raw polar and first-origin alone close the entire interval `0 < a < 1`. +* For `8 ≤ n ≤ 256` with `(n-1)(1-a) ≤ 2/5`, the uniform near-endpoint budget + also closes with first-origin alone. +* In the remaining finite-degree region, the centroid identity and the two origin identities + give `(origin-exact)`, and `Sendov.polar_origin_incompatible` closes the contradiction. * For `n ≤ 5`, `Sendov.low_degree_contradiction` shows `(⋆)` is already contradictory on its own, with no recourse to the origin channel. Degree five belongs only to this low-degree branch. @@ -109,6 +111,14 @@ theorem sendov_interior {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegre rw [Complex.re_add_im, mul_div_cancel₀ _ hne] obtain ⟨hxre, hx2⟩ := xy_bounds hn hqcard hq1 hxy have hpolar := one_le_integral_Ppolar hn (a := a) (x := x) hqcard hq1 hxre hstar + -- All sufficiently large degrees use only the first-origin channel. + by_cases hlarge : 257 ≤ n + · have hxSq : x ^ 2 ≤ 1 := (le_add_of_nonneg_right (sq_nonneg y)).trans hx2 + exact FirstOriginBudget.uniform_contradiction hlarge ha0 ha1 + (by nlinarith [sq_nonneg (x + 1)]) (by nlinarith [sq_nonneg (x - 1)]) + hqcard hq1 hxre hxy hpolar + (FirstOriginSmall.norm_integral_Fprod_le_of_factorization (by omega) (ne_of_gt ha0) + hc0 hzcard hq0 hq1 hz1 hpa hpz hpq') -- The uniform near-endpoint region uses only the first-origin channel. by_cases hnear : ((n : ℝ) - 1) * (1 - a) ≤ 2 / 5 · have hxSq : x ^ 2 ≤ 1 := (le_add_of_nonneg_right (sq_nonneg y)).trans hx2 diff --git a/docs/paper-formalization/checkpoint4.json b/docs/paper-formalization/checkpoint4.json new file mode 100644 index 0000000..8e5a308 --- /dev/null +++ b/docs/paper-formalization/checkpoint4.json @@ -0,0 +1,8 @@ +{ + "all_a_m256_D": true, + "n_ge_257_Solution_uses_first_origin_only_branch": true, + "historical_stronger_bounds": true, + "quantitative_J_gaps_m5_m6": true, + "gates": 12, + "all_paper_obligations_complete": false +} \ No newline at end of file diff --git a/docs/paper-formalization/round4-files.json b/docs/paper-formalization/round4-files.json new file mode 100644 index 0000000..1b3306c --- /dev/null +++ b/docs/paper-formalization/round4-files.json @@ -0,0 +1,8 @@ +[ + "Sendov/Analytic/PaperUniform.lean", + "tests/PaperUniform.lean", + "Sendov/Analytic/PaperHistoricalBounds.lean", + "tests/PaperHistoricalBoundsTests.lean", + "Sendov/Analytic/FirstOriginMargins.lean", + "tests/FirstOriginMargins.lean" +] \ No newline at end of file diff --git a/tests/FirstOriginBudget.lean b/tests/FirstOriginBudget.lean index d91b426..fa794d8 100644 --- a/tests/FirstOriginBudget.lean +++ b/tests/FirstOriginBudget.lean @@ -2,12 +2,14 @@ import Sendov.Analytic.FirstOriginBudget #print axioms Sendov.FirstOriginBudget.lower_budget #print axioms Sendov.FirstOriginBudget.near_contradiction +#print axioms Sendov.FirstOriginBudget.uniform_contradiction -- Verify proof-value independence, not merely an import or a theorem name. open Lean Elab Command in run_cmd do let env := (← getEnv).setExporting false for root in #[`Sendov.FirstOriginBudget.near_contradiction, + `Sendov.FirstOriginBudget.uniform_contradiction, `Sendov.FirstOriginSmall.first_origin_polar_six_seven] do let mut pending := [root] let mut seen : Std.HashSet Name := {} diff --git a/tests/FirstOriginMargins.lean b/tests/FirstOriginMargins.lean new file mode 100644 index 0000000..f6a87f9 --- /dev/null +++ b/tests/FirstOriginMargins.lean @@ -0,0 +1,140 @@ +import Sendov.Analytic.FirstOriginMargins + +/-! Expanded-signature regression tests: no named predicate conceals an assumption. +The norm is of the entire complex multiple of the actual product integral. +No first-origin identity, no polynomial data, and no upper bound on this norm. +-/ +namespace Sendov.FirstOriginMargins.Tests + +/-- Full expanded six-degree statement, including the definition of Fprod. -/ +theorem six_expanded + (a : ℝ) (q : Multiset ℂ) + (ha0 : 0 < a) (ha1 : a < 1) + (hqcard : q.card = 5) + (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hstar : 1 ≤ ∫ t in (0 : ℝ)..1, + (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) : + 1 + (3 / 40 : ℝ) * (1 - a) ≤ + ‖(6 : ℂ) * (∫ t in (0 : ℝ)..1, + (q.map (fun v => 1 - (a : ℂ) * (t : ℂ) * v)).prod)‖ := by + exact norm_J_six ha0 ha1 hqcard hq1 hstar + +/-- Full expanded seven-degree statement, including the definition of Fprod. -/ +theorem seven_expanded + (a : ℝ) (q : Multiset ℂ) + (ha0 : 0 < a) (ha1 : a < 1) + (hqcard : q.card = 6) + (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hstar : 1 ≤ ∫ t in (0 : ℝ)..1, + (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) : + 1 + (31 / 160 : ℝ) * (1 - a) ≤ + ‖(7 : ℂ) * (∫ t in (0 : ℝ)..1, + (q.map (fun v => 1 - (a : ℂ) * (t : ℂ) * v)).prod)‖ := by + exact norm_J_seven ha0 ha1 hqcard hq1 hstar + +-- The scalar inequalities also retain the actual integral, rather than U5 or U6. +example {a x : ℝ} (ha0 : 0 < a) (ha1 : a < 1) + (hx : (1 + a) / 2 ≤ x) (hx1 : x ≤ 1) : + QQ (a * x) (a ^ 2) 1 ^ (5 / 2 : ℝ) + 5 * a ^ 2 * + (∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (2 : ℕ)) ≤ + 1 - 5 * a / 6 - a * (1 - a) / 16 := by + have h := T_five_gap ha0 ha1 hx hx1 + norm_num [T, Real.rpow_natCast] at h + exact h + +example {a x : ℝ} (ha0 : 0 < a) (ha1 : a < 1) + (hx : (1 + a) / 2 ≤ x) (hx1 : x ≤ 1) : + QQ (a * x) (a ^ 2) 1 ^ (3 : ℕ) + 6 * a ^ 2 * + (∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (5 / 2 : ℝ)) ≤ + 1 - 6 * a / 7 - (93 / 560) * a * (1 - a) := by + have h := T_six_gap ha0 ha1 hx hx1 + norm_num [T, Real.rpow_natCast] at h + exact h + +-- Endpoint values are valid for the polynomial certificates (unlike final a-domain). +example : 1 / 16 ≤ A5 0 := A5_lower (by norm_num) (by norm_num) +example : 1 / 16 ≤ A5 1 := A5_lower (by norm_num) (by norm_num) +example : 93 / 560 ≤ A6 0 := A6_lower (by norm_num) (by norm_num) +example : 93 / 560 ≤ A6 1 := A6_lower (by norm_num) (by norm_num) + +end Sendov.FirstOriginMargins.Tests + +#check @Sendov.FirstOriginMargins.Tests.six_expanded +#check @Sendov.FirstOriginMargins.Tests.seven_expanded +#check @Sendov.FirstOriginMargins.norm_J_lower + +#print axioms Sendov.FirstOriginMargins.A5_lower +#print axioms Sendov.FirstOriginMargins.A6_lower +#print axioms Sendov.FirstOriginMargins.T_five_gap +#print axioms Sendov.FirstOriginMargins.T_six_gap +#print axioms Sendov.FirstOriginMargins.lower_budget_norm +#print axioms Sendov.FirstOriginMargins.norm_J_lower +#print axioms Sendov.FirstOriginMargins.norm_J_six +#print axioms Sendov.FirstOriginMargins.norm_J_seven + +/-! Traverse all reachable proof values, including imported/private ones. Verify +positive use of the quantitative certificates and prohibit the old contradiction +and first-origin-bound consumers. Standard logical axioms are the only allowlist. +-/ +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + for (root, required) in #[ + (`Sendov.FirstOriginMargins.norm_J_six, + #[`Sendov.FirstOriginMargins.A5_remainder, + `Sendov.FirstOriginMargins.A5_lower, + `Sendov.FirstOriginMargins.upper_five_gap_identity, + `Sendov.FirstOriginMargins.T_five_gap, + `Sendov.FirstOriginMargins.lower_budget_norm, + `Sendov.FirstOriginSmall.polar_mean_gt_half_add_one, + `Sendov.one_le_integral_Ppolar, `Sendov.one_le_tri, + `Sendov.FirstOriginSmall.norm_Fprod_le]), + (`Sendov.FirstOriginMargins.norm_J_seven, + #[`Sendov.FirstOriginMargins.A6_remainder, + `Sendov.FirstOriginMargins.A6_lower, + `Sendov.FirstOriginMargins.upper_six_gap_identity, + `Sendov.FirstOriginMargins.T_six_gap, + `Sendov.FirstOriginMargins.lower_budget_norm, + `Sendov.FirstOriginSmall.five_halves_majorant, + `Sendov.FirstOriginSmall.polar_mean_gt_half_add_one, + `Sendov.one_le_integral_Ppolar, `Sendov.one_le_tri, + `Sendov.FirstOriginSmall.norm_Fprod_le]), + (`Sendov.FirstOriginMargins.norm_J_lower, + #[`Sendov.FirstOriginMargins.lower_budget_norm, + `Sendov.one_le_tri, `Sendov.FirstOriginSmall.norm_Fprod_le])] do + let mut pending := [root] + let mut visited : Std.HashSet Name := {} + while !pending.isEmpty do + let name := pending.head! + pending := pending.tail! + unless visited.contains name do + visited := visited.insert name + let some info := env.find? name | throwError "missing closure declaration {name}" + if let some value := info.value? (allowOpaque := true) then + for used in value.getUsedConstants do pending := used :: pending + for name in visited do + let text := name.toString + for forbidden in #["centroid_identity", "second_origin_identity", "first_origin_identity", + "origin_exact", "alpha_le_seventeen", "OriginExact", "Jsum", + "scalarObstruction", "distillScalar", "Distillation", "polar_origin_incompatible", + "Worigin", "sorryAx", "native_decide", "first_origin_polar_six_seven", + "norm_integral_Fprod_le_of_first_origin", "norm_integral_Fprod_le_of_factorization", + "FirstOriginBudget.lower_budget", "near_contradiction", "direct_budget_five", + "direct_budget_six", "Sendov.FirstOriginSmall.upper_five_gap", + "Sendov.FirstOriginSmall.upper_six_gap"] do + if (text.splitOn forbidden).length > 1 then + throwError "forbidden margin proof dependency: {root} -> {name}" + if let some idx := env.getModuleIdxFor? name then + let owner := env.header.moduleNames[idx.toNat]!.toString + for forbidden in #["OriginExact", "Jsum", "Distillation", "LargeDegree", + "Reduction.Contradiction", "Reduction.Scalar", "Interior"] do + if (owner.splitOn forbidden).length > 1 then + throwError "forbidden margin proof owner: {root} -> {name} in {owner}" + for target in required do + unless visited.contains target do + throwError "missing positive quantitative consumption: {root} -> {target}" + logInfo m!"MARGIN_POSITIVE {root} -> {target}" + let axioms ← withEnv env <| Lean.collectAxioms root + unless axioms.all (#[``propext, ``Classical.choice, ``Quot.sound].contains) do + throwError "unexpected axioms for {root}: {axioms}" + logInfo m!"MARGIN_CLOSURE {root}: {visited.size}; axioms {axioms}" diff --git a/tests/FirstOriginWiring.lean b/tests/FirstOriginWiring.lean index d3fc3e7..03bb7ff 100644 --- a/tests/FirstOriginWiring.lean +++ b/tests/FirstOriginWiring.lean @@ -25,7 +25,9 @@ run_cmd do for target in #[`Sendov.FirstOriginSmall.first_origin_polar_six_seven, `Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_factorization, `Sendov.FirstOriginBudget.near_contradiction, - `Sendov.PaperNearClosure.near_endpoint_D] do + `Sendov.PaperNearClosure.near_endpoint_D, + `Sendov.FirstOriginBudget.uniform_contradiction, + `Sendov.PaperUniform.uniform_D] do unless visited.contains target do throwError "missing final-root consumption {root} -> {target}" logInfo m!"FIRST_ORIGIN_SOLUTION_VALUE {root} -> {target}" diff --git a/tests/PaperHistoricalBoundsTests.lean b/tests/PaperHistoricalBoundsTests.lean new file mode 100644 index 0000000..d8f9317 --- /dev/null +++ b/tests/PaperHistoricalBoundsTests.lean @@ -0,0 +1,143 @@ +import Sendov.Analytic.PaperHistoricalBounds + +/-! Regressions for actual historical integral bounds, independently of uniform D. -/ +namespace Sendov.PaperHistoricalBounds.Tests +open MeasureTheory PaperPolar + +-- Fully expanded input and output: no assumed scalar approximation of the integral. +example {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : 1 ≤ ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2)) : + (1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + m * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2) < 3 / 5 := by + simpa [PaperTaylor.budget, PaperTaylor.beta] using + budget_lt_three_fifths hm ha ha1 hx0 hx1 hr + +example {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (ha2 : 2 / 5 ≤ a) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar m a x) : + PaperTwoEnd.total m a x < 40 / ((m : ℝ) * a ^ 2) := by + rw [PaperTwoEnd.total_eq_budget ha] + exact budget_lt_forty hm ha ha1 ha2 hx0 hx1 hr + +-- Exact base and adjacent odd degree, with the actual half-integer exponents. +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 512 a x) : PaperTaylor.budget 512 a x < 3 / 5 := + budget_lt_three_fifths (by norm_num) ha ha1 hx0 hx1 hr + +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 513 a x) : PaperTaylor.budget 513 a x < 3 / 5 := + budget_lt_three_fifths (by norm_num) ha ha1 hx0 hx1 hr + +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 512 a x) : (32 : ℝ) / 3 < 512 * x ^ 2 := by + simpa using degree_mul_sq_gt (by norm_num) ha ha1 hx0 hx1 hr + +-- Original exponential relaxation starts at 9, not 7 or 8. +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx : 0 < x) (hx1 : x ≤ 1) + (hxa : x < a) (hax : a < 3 * x / 2) : + PaperTaylor.budget 9 a x < 4 / (9 * x ^ 2) + + (1 + 5 * 9 * x ^ 2 / 8) * Real.exp (-(9 * x ^ 2) / 3) := + budget_lt_middle (by norm_num) ha ha1 hx hx1 hxa hax + +-- Historical A5 and A5b really apply at 7 and 8; no degree-512 restriction. +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 7 a x) : PaperTaylor.budget 7 a x ≤ + 100 * 7 / (9 * (7 + 1) * (7 + 3) * x ^ 2) + 116 / 9 := by + convert budget_le_A5 (by norm_num) ha ha1 hx0 hx1 hr using 1 <;> norm_num + +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 8 a x) : PaperTaylor.budget 8 a x ≤ + 16 * 8 / ((8 + 1) * (8 + 3) * x ^ 2) + 52 / 10 := by + convert budget_le_A5b (by norm_num) ha ha1 hx0 hx1 hr using 1 <;> norm_num + +example {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hbulk : 116 ≤ (m : ℝ) * a ^ 2 * (1 - a)) : + PaperTaylor.budget m a x < 1 - a := + budget_lt_one_sub_of_bulk116 hm ha ha1 hx0 hx1 hr hbulk + +-- Exact nonvacuous base, radius boundary, and closed disk boundary x = 1. +theorem raw_feasible : RawPolar 512 (2 / 5) 1 := by + rw [rawPolar_iff] + change 1 ≤ PaperSecant.R 512 (2 / 5) 1 + rw [PaperSecant.R_one (by norm_num) (by norm_num)] + norm_num [PaperSecant.U1] + have h1 := pow_le_pow_right₀ (by norm_num : (1 : ℝ) ≤ 31 / 25) (by norm_num : 32 ≤ 513) + have h2 := pow_le_pow_left₀ (by norm_num : (0 : ℝ) ≤ 2 / 5) (by norm_num : (2 / 5 : ℝ) ≤ 1) 513 + have hlarge : (900 : ℝ) ≤ (31 / 25) ^ (513 : ℕ) := + (by norm_num : (900 : ℝ) ≤ (31 / 25) ^ (32 : ℕ)).trans h1 + have hsmall : (2 / 5 : ℝ) ^ (513 : ℕ) ≤ 1 := by simpa only [one_pow] using h2 + apply (le_div_iff₀ (by norm_num : (0 : ℝ) < 10773 / 25)).mpr + exact (by norm_num : (1 : ℝ) * (10773 / 25) ≤ 900 - 1).trans (sub_le_sub hlarge hsmall) + +example : PaperTaylor.budget 512 (2 / 5) 1 < 3 / 5 := + budget_lt_three_fifths (by norm_num) (by norm_num) (by norm_num) + (by norm_num) (by norm_num) raw_feasible + +example : PaperTaylor.budget 512 (2 / 5) 1 < 40 / (512 * (2 / 5) ^ 2) := + budget_lt_forty (by norm_num) (by norm_num) (by norm_num) (by norm_num) + (by norm_num) (by norm_num) raw_feasible + +example : (27 : ℝ) / 5 < Real.log 257 := log_257_gt +example : (512 : ℝ) * (1 + 512 / 40) * Real.exp (-512 / 75) < 24 := middle_tail (by norm_num) + +#print axioms budget_lt_three_fifths +#print axioms budget_lt_forty +#print axioms budget_le_A5 +#print axioms budget_le_A5b +#print axioms budget_lt_bulk116 +#print axioms budget_lt_one_sub_of_bulk116 +#print axioms budget_lt_one_sub_of_bulk40 +#print axioms budget_lt_one_sub_of_small +#print axioms raw_feasible + +-- Audit proof VALUES, not merely theorem signatures or imported names. +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + let roots := #[ + (`Sendov.PaperHistoricalBounds.budget_lt_three_fifths, + #[`Sendov.PaperHistoricalBounds.log_257_gt, + `Sendov.PaperHistoricalBounds.degree_mul_sq_gt, + `Sendov.PaperHistoricalBounds.middle_base, + `Sendov.PaperHistoricalBounds.budget_lt_middle, + `Sendov.PaperTwoEnd.budget_lt_separated]), + (`Sendov.PaperHistoricalBounds.budget_lt_forty, + #[`Sendov.PaperHistoricalBounds.middle_tail, + `Sendov.PaperTail.power_exp_antitone, + `Sendov.PaperHistoricalBounds.budget_lt_middle, + `Sendov.PaperTwoEnd.budget_lt_separated]), + (`Sendov.PaperHistoricalBounds.budget_le_A5, + #[`Sendov.PaperHistoricalBounds.integral_chord_le, + `Sendov.PaperTwoEnd.integral_right_weight, + `Sendov.PaperTwoEnd.integral_right_unweighted]), + (`Sendov.PaperHistoricalBounds.budget_lt_bulk116, + #[`Sendov.PaperHistoricalBounds.budget_le_A5b, + `Sendov.PaperHistoricalBounds.integral_chord_le, + `Sendov.PaperTwoEnd.integral_right_weight])] + for (root, required) in roots do + let mut pending := [root] + let mut visited : Std.HashSet Name := {} + while !pending.isEmpty do + let name := pending.head! + pending := pending.tail! + unless visited.contains name do + visited := visited.insert name + let some ci := env.find? name | throwError "missing declaration {name}" + if let some value := ci.value? (allowOpaque := true) then + for used in value.getUsedConstants do pending := used :: pending + for target in required ++ #[`Sendov.PaperGlobalPolar.endpoint_le, + `Sendov.PaperTwoEnd.total_eq_budget] do + unless visited.contains target do + throwError "historical proof missing required dependency {root} -> {target}" + if visited.contains `sorryAx then throwError "unexpected proof hole" + for name in visited.toList do + if (`Sendov.PaperUniform).isPrefixOf name then + throwError "historical stronger bound incorrectly depends on uniform D: {name}" + logInfo m!"HISTORICAL_BOUND_PROOF_CLOSURE_OK {root}" + +end Sendov.PaperHistoricalBounds.Tests diff --git a/tests/PaperUniform.lean b/tests/PaperUniform.lean new file mode 100644 index 0000000..0cd1101 --- /dev/null +++ b/tests/PaperUniform.lean @@ -0,0 +1,100 @@ +import Sendov.Analytic.PaperUniform + +open MeasureTheory + +namespace Sendov.PaperUniformAcceptance + +/-- Exact public signature: no endpoint, tail, geometry or finite-table premises. -/ +theorem exact_signature (m : ℕ) (a x : ℝ) (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : PaperPolar.RawPolar m a x) : + PaperTaylor.budget (m : ℝ) a x < 1 - (m : ℝ) * a / ((m : ℝ) + 1) := + PaperUniform.uniform_D hm ha ha1 hx0 hx1 hr + +/-- Both integrals expanded, retaining the actual unrelaxed exponent. -/ +theorem expanded_integrals (m : ℕ) (a x : ℝ) (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : 1 ≤ ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2)) : + (1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + (m : ℝ) * a ^ 2 * + (∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < + 1 - (m : ℝ) * a / ((m : ℝ) + 1) := by + change PaperPolar.RawPolar m a x at hr + simpa only [PaperTaylor.budget, PaperTaylor.beta, mul_one, one_pow] using + PaperUniform.uniform_D hm ha ha1 hx0 hx1 hr + +/-- The cutoff itself, not just degrees strictly above it. -/ +example (a x : ℝ) (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : PaperPolar.RawPolar 256 a x) : + PaperTaylor.budget 256 a x < 1 - 256 * a / 257 := by + have h := PaperUniform.uniform_D (by norm_num : 256 ≤ 256) ha ha1 hx0 hx1 hr + norm_num at h + exact h + +example (m : ℕ) (a x : ℝ) (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : PaperPolar.RawPolar m a x) : PaperTaylor.budget (m : ℝ) a x < 2 / 3 := + PaperUniform.budget_lt_two_thirds hm ha ha1 hx0 hx1 hr + +example (m : ℕ) (a x : ℝ) (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (ha3 : 1 / 3 ≤ a) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : PaperPolar.RawPolar m a x) : + PaperTaylor.budget (m : ℝ) a x < 16 / ((m : ℝ) * a ^ 2) + 24 / (m : ℝ) := + PaperUniform.budget_lt_retained hm ha ha1 ha3 hx0 hx1 hr + +#check @PaperUniform.uniform_D +#print axioms PaperUniform.exp_seventeen_fifths +#print axioms PaperUniform.budget_lt_two_thirds +#print axioms PaperUniform.budget_lt_retained +#print axioms PaperUniform.finite_rays_D +#print axioms PaperUniform.uniform_D +#print axioms exact_signature +#print axioms expanded_integrals + +-- Audit proof values, not merely the import list or declaration types. +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + let mut pending := [`Sendov.PaperUniformAcceptance.expanded_integrals] + let mut visited : Std.HashSet Name := {} + while !pending.isEmpty do + let name := pending.head! + pending := pending.tail! + unless visited.contains name do + visited := visited.insert name + let some ci := env.find? name | throwError "missing closure declaration {name}" + if let .axiomInfo _ := ci then + unless #[`propext, `Classical.choice, `Quot.sound].contains name do + throwError "nonstandard axiom in uniform D: {name}" + if let some v := ci.value? (allowOpaque := true) then + for used in v.getUsedConstants do pending := used :: pending + for target in #[`Sendov.PaperUniform.uniform_D, + `Sendov.PaperUniform.budget_lt_two_thirds, + `Sendov.PaperUniform.budget_lt_retained, + `Sendov.PaperGlobalPolar.endpoint_le, + `Sendov.PaperGlobalPolar.degree_mul_sq_gt, + `Sendov.PaperUniform.exp_seventeen_fifths, + `Sendov.PaperTwoEnd.budget_lt_separated, + `Sendov.PaperTwoEnd.budget_lt_middle, + `Sendov.PaperTail.middle_antitone, + `Sendov.PaperTail.middle_tail, + `Sendov.PaperBulk.middle_budget, + `Sendov.PaperBulk.large_ray_budget, + `Sendov.PaperNearClosure.near_endpoint_D, + `Sendov.PaperTail.budget_region_one, + `Sendov.PaperTail.budget_region_two, + `Sendov.PaperTail.budget_region_three, + `Sendov.PaperTail.budget_region_four, + `Sendov.PaperRayGeometry.budget_lower_one, + `Sendov.PaperRayGeometry.budget_lower_ten, + `Sendov.PaperRayGeometry.budget_lower_twentyfive, + `Sendov.PaperRayGeometry.budget_lower_fortynine, + `Sendov.PaperRayGeometry.halfpoint_mem] do + unless visited.contains target do + throwError "missing uniform D proof-value dependency {target}" + logInfo m!"UNIFORM_D_VALUE {target}" + logInfo "UNIFORM_D_AXIOMS_ONLY propext Classical.choice Quot.sound" + +end Sendov.PaperUniformAcceptance From 429d65679619ac1ae99373ce43d15788d1bc2e02 Mon Sep 17 00:00:00 2001 From: Methode Date: Mon, 14 Sep 2026 13:43:19 -0700 Subject: [PATCH 21/24] Complete retained rates and exact diagnostic proofs with reproducible generators --- Sendov/Analytic/PaperCenteredCertificate.lean | 141 ++ Sendov/Analytic/PaperConjugate.lean | 193 ++ Sendov/Analytic/PaperConsequences.lean | 279 +++ Sendov/Analytic/PaperLegacyExact.lean | 77 + Sendov/Analytic/PaperLegacyHelpers.lean | 150 ++ Sendov/Analytic/PaperLegacyHundred.lean | 25 + Sendov/Analytic/PaperRateDetails.lean | 145 ++ Sendov/Analytic/PaperWideRays.lean | 210 ++ docs/paper-formalization/checkpoint5.json | 8 + .../paper-formalization/generator-replay.json | 5 + docs/paper-formalization/modules.json | 181 ++ docs/paper-formalization/round5-files.json | 127 + scripts/check_paper.py | 53 + scripts/generate_centered_hundred.py | 92 + scripts/verify_paper_results.py | 67 + tests/CONJUGATE_BUDGETS.md | 87 + tests/PaperCenteredHundred.lean | 2106 +++++++++++++++++ tests/PaperConjugateBudgets.lean | 100 + tests/PaperConjugateDI03.lean | 126 + tests/PaperConjugateDI04.lean | 150 ++ tests/PaperConjugateDI05.lean | 294 +++ tests/PaperConjugateDI06.lean | 1254 ++++++++++ tests/PaperConjugateDI07.lean | 1254 ++++++++++ tests/PaperConsequencesTests.lean | 102 + tests/PaperLegacyCertificates.lean | 232 ++ tests/PaperPolarDomainWitnesses.lean | 332 +++ tests/PaperRateDetailsTests.lean | 165 ++ tests/PaperWideRaysTests.lean | 93 + tests/conjugate-data.json | 47 + tests/data/di02-witnesses.json | 694 ++++++ tests/generate_conjugate_budgets.py | 95 + 31 files changed, 8884 insertions(+) create mode 100644 Sendov/Analytic/PaperCenteredCertificate.lean create mode 100644 Sendov/Analytic/PaperConjugate.lean create mode 100644 Sendov/Analytic/PaperConsequences.lean create mode 100644 Sendov/Analytic/PaperLegacyExact.lean create mode 100644 Sendov/Analytic/PaperLegacyHelpers.lean create mode 100644 Sendov/Analytic/PaperLegacyHundred.lean create mode 100644 Sendov/Analytic/PaperRateDetails.lean create mode 100644 Sendov/Analytic/PaperWideRays.lean create mode 100644 docs/paper-formalization/checkpoint5.json create mode 100644 docs/paper-formalization/generator-replay.json create mode 100644 docs/paper-formalization/modules.json create mode 100644 docs/paper-formalization/round5-files.json create mode 100644 scripts/check_paper.py create mode 100644 scripts/generate_centered_hundred.py create mode 100644 scripts/verify_paper_results.py create mode 100644 tests/CONJUGATE_BUDGETS.md create mode 100644 tests/PaperCenteredHundred.lean create mode 100644 tests/PaperConjugateBudgets.lean create mode 100644 tests/PaperConjugateDI03.lean create mode 100644 tests/PaperConjugateDI04.lean create mode 100644 tests/PaperConjugateDI05.lean create mode 100644 tests/PaperConjugateDI06.lean create mode 100644 tests/PaperConjugateDI07.lean create mode 100644 tests/PaperConsequencesTests.lean create mode 100644 tests/PaperLegacyCertificates.lean create mode 100644 tests/PaperPolarDomainWitnesses.lean create mode 100644 tests/PaperRateDetailsTests.lean create mode 100644 tests/PaperWideRaysTests.lean create mode 100644 tests/conjugate-data.json create mode 100644 tests/data/di02-witnesses.json create mode 100644 tests/generate_conjugate_budgets.py diff --git a/Sendov/Analytic/PaperCenteredCertificate.lean b/Sendov/Analytic/PaperCenteredCertificate.lean new file mode 100644 index 0000000..5faeb82 --- /dev/null +++ b/Sendov/Analytic/PaperCenteredCertificate.lean @@ -0,0 +1,141 @@ +import Sendov.Analytic.PaperCenteredBound +import Mathlib.Algebra.Polynomial.Expand +import Mathlib.Analysis.SpecialFunctions.Integrals.Basic + +/-! +# Exact finite certificate bridge + +Rational witnesses may be generated externally, but this module consumes only +kernel-checked inequalities bound to the actual centered multiset. It does not +assume an error estimate or replace either error definition by a scalar proxy. +-/ +noncomputable section +open scoped BigOperators +namespace Sendov.PaperCenteredCertificate +open PaperCentered PaperCenteredBound + +/-- Real binomial endpoint, useful for exact rational replay. -/ +def realB (m k : ℕ) (z : ℝ) : ℝ := + ∑ j ∈ Finset.range (k + 1), (m + 1).choose j * z ^ j * (1 - z) ^ (m + 1 - j) + +lemma B_ofReal (m k : ℕ) (z : ℝ) : B m k (z : ℂ) = (realB m k z : ℂ) := by + simp [B, realB] + +lemma realB_nonneg (m k : ℕ) (z : ℝ) (hz : 0 ≤ z) (hz1 : z ≤ 1) : + 0 ≤ realB m k z := by + apply Finset.sum_nonneg + intro j hj + exact mul_nonneg (mul_nonneg (Nat.cast_nonneg _) (pow_nonneg hz _)) + (pow_nonneg (sub_nonneg.mpr hz1) _) + +lemma realB_le_one (m k : ℕ) (z : ℝ) (hk : k ≤ m) + (hz : 0 ≤ z) (hz1 : z ≤ 1) : realB m k z ≤ 1 := by + have hsum : (∑ j ∈ Finset.range (m + 1 + 1), + ((m + 1).choose j : ℝ) * z ^ j * (1 - z) ^ (m + 1 - j)) = 1 := by + have h := add_pow z (1 - z) (m + 1) + rw [show z + (1 - z) = 1 by ring, one_pow] at h + calc + _ = ∑ j ∈ Finset.range (m + 1 + 1), + z ^ j * (1 - z) ^ (m + 1 - j) * ((m + 1).choose j : ℝ) := by + apply Finset.sum_congr rfl + intro j hj + ring + _ = 1 := h.symm + unfold realB + apply le_trans (b := ∑ j ∈ Finset.range (m + 1 + 1), + ((m + 1).choose j : ℝ) * z ^ j * (1 - z) ^ (m + 1 - j)) _ hsum.le + apply Finset.sum_le_sum_of_subset_of_nonneg + · exact Finset.range_mono (by omega) + · intro j hj hj' + exact mul_nonneg (mul_nonneg (Nat.cast_nonneg _) (pow_nonneg hz _)) + (pow_nonneg (sub_nonneg.mpr hz1) _) + +/-- All endpoints, including the top endpoint, have norm at most one when the +scale really is in the real unit interval. No such claim is made for complex scales. -/ +theorem norm_H_ofReal_le_one (m k : ℕ) (z : ℝ) (hk : k ≤ m) + (hz : 0 ≤ z) (hz1 : z ≤ 1) : ‖H m k (z : ℂ)‖ ≤ 1 := by + rw [H, B_ofReal, ← Complex.ofReal_one, ← Complex.ofReal_sub, + Complex.norm_real, Real.norm_eq_abs, abs_of_nonneg + (sub_nonneg.mpr (realB_le_one m k z hk hz hz1))] + linarith [realB_nonneg m k z hz hz1] + +/-- A square witness checks a normalized square-root coefficient without trusting +an external square-root implementation. The top-degree branch is explicit. -/ +theorem normalized_C_le (m k : ℕ) (v u b : ℝ) + (hk : 0 < k) (hkm : k ≤ m) (hu : 0 < u) (hb : 0 ≤ b) + (hsq : (if k = m then v ^ m else + (m : ℝ) ^ m / ((k : ℝ) ^ k * ((m - k : ℕ) : ℝ) ^ (m - k)) * v ^ k) ≤ + (b * ((m.choose k : ℝ) * u ^ k)) ^ 2) : + C m k v / ((m.choose k : ℝ) * u ^ k) ≤ b := by + have hd : 0 < (m.choose k : ℝ) * u ^ k := + mul_pos (by exact_mod_cast Nat.choose_pos hkm) (pow_pos hu _) + apply (div_le_iff₀ hd).2 + have he : C m k v = Real.sqrt (if k = m then v ^ m else + (m : ℝ) ^ m / ((k : ℝ) ^ k * ((m - k : ℕ) : ℝ) ^ (m - k)) * v ^ k) := by + by_cases h : k = m + · simp [h] + · simp [C, h, hk, lt_of_le_of_ne hkm h] + rw [he] + exact (Real.sqrt_le_left (mul_nonneg hb hd.le)).2 hsq + +/-- Finite per-degree normalized bounds assemble into the actual majorant. -/ +theorem majorant_le (r : Multiset ℂ) (μ z : ℂ) (p : ℝ) (b : ℕ → ℝ) + (hp : ‖1 - z‖ ^ (r.card + 1) + Gamma r μ * ‖B r.card 2 z‖ ≤ p) + (hH : ∀ k ∈ Finset.Ico 3 (r.card + 1), ‖H r.card k z‖ ≤ 1) + (hb : ∀ k ∈ Finset.Ico 3 (r.card + 1), + C r.card k (variance r) / ((r.card.choose k : ℝ) * ‖μ‖ ^ k) ≤ b k) : + majorant_Efin r μ z ≤ p + ∑ k ∈ Finset.Ico 3 (r.card + 1), b k := by + apply add_le_add hp + apply Finset.sum_le_sum + intro k hk + calc + _ ≤ C r.card k (variance r) / ((r.card.choose k : ℝ) * ‖μ‖ ^ k) := + mul_le_of_le_one_right (div_nonneg (C_nonneg _ _ _) (by positivity)) (hH k hk) + _ ≤ b k := hb k hk + +/-- Independent actual-coefficient certificate path, not the generic C majorant. -/ +theorem actual_le (r : Multiset ℂ) (μ z : ℂ) (p : ℝ) (b : ℕ → ℝ) + (hp : ‖1 - z‖ ^ (r.card + 1) + Gamma r μ * ‖B r.card 2 z‖ ≤ p) + (hH : ∀ k ∈ Finset.Ico 3 (r.card + 1), ‖H r.card k z‖ ≤ 1) + (hb : ∀ k ∈ Finset.Ico 3 (r.card + 1), + ‖r.esymm k‖ / ((r.card.choose k : ℝ) * ‖μ‖ ^ k) ≤ b k) : + Efin r μ z ≤ p + ∑ k ∈ Finset.Ico 3 (r.card + 1), b k := by + apply add_le_add hp + apply Finset.sum_le_sum + intro k hk + calc + _ ≤ ‖r.esymm k‖ / ((r.card.choose k : ℝ) * ‖μ‖ ^ k) := + mul_le_of_le_one_right (by positivity) (hH k hk) + _ ≤ b k := hb k hk + +/-- Exact elementary coefficients of two equally repeated opposite deviations. +The formula uses Vieta and polynomial dilation, not enumeration of subsets. -/ +theorem esymm_opposite_replicate (n k : ℕ) (d : ℂ) (hk : k ≤ 2 * n) : + (Multiset.replicate n (-d) + Multiset.replicate n d).esymm k = + if 2 ∣ (2 * n - k) then + (-d ^ 2) ^ (n - (2 * n - k) / 2) * (n.choose ((2 * n - k) / 2) : ℂ) + else 0 := by + let r := Multiset.replicate n (-d) + Multiset.replicate n d + have hc : r.card = 2 * n := by simp [r]; omega + have hp : (r.map (fun w => Polynomial.X + Polynomial.C w)).prod = + Polynomial.expand ℂ 2 ((Polynomial.X + Polynomial.C (-d ^ 2)) ^ n) := by + simp only [r, Multiset.map_add, Multiset.map_replicate, Multiset.prod_add, + Multiset.prod_replicate, map_pow, map_add, Polynomial.expand_X, + Polynomial.expand_C, ← mul_pow] + congr 1 + simp only [map_neg, map_pow] + ring + have hv := Multiset.prod_X_add_C_coeff r (k := 2 * n - k) (by omega) + rw [hc, Nat.sub_sub_self hk, hp, Polynomial.coeff_expand (by decide : 0 < 2)] at hv + simpa only [Polynomial.coeff_X_add_C_pow] using hv.symm + +/-- A reusable exact lower rectangle for a real integrand. -/ +theorem lower_rectangle (f : ℝ → ℝ) (s t b : ℝ) (hst : s ≤ t) + (hf : IntervalIntegrable f MeasureTheory.volume s t) + (hb : ∀ x ∈ Set.Icc s t, b ≤ f x) : + (t - s) * b ≤ ∫ x in s..t, f x := by + have h := intervalIntegral.integral_mono_on hst + (intervalIntegrable_const (c := b)) hf hb + simpa only [intervalIntegral.integral_const, smul_eq_mul] using h + +end Sendov.PaperCenteredCertificate diff --git a/Sendov/Analytic/PaperConjugate.lean b/Sendov/Analytic/PaperConjugate.lean new file mode 100644 index 0000000..632d0e5 --- /dev/null +++ b/Sendov/Analytic/PaperConjugate.lean @@ -0,0 +1,193 @@ +import Sendov.Analytic.PaperCenteredBound +import Mathlib.Analysis.SpecialFunctions.Integrals.Basic +import Mathlib.Tactic.NormNum.NatFactorial + +noncomputable section +open scoped BigOperators +namespace Sendov.PaperConjugate +open PaperCentered PaperCenteredBound + +def y (x : ℝ) : ℝ := Real.sqrt (1 - x ^ 2) +def plus (x : ℝ) : ℂ := ⟨x, y x⟩ +def minus (x : ℝ) : ℂ := ⟨x, -y x⟩ +/-- Exactly n copies of each conjugate; multiplicities are retained. -/ +def family (n : ℕ) (x : ℝ) : Multiset ℂ := + Multiset.replicate n (plus x) + Multiset.replicate n (minus x) + +@[simp] theorem card_family (n : ℕ) (x : ℝ) : (family n x).card = 2*n := by + simp [family]; omega + +theorem y_sq (x : ℝ) (hx : x ^ 2 ≤ 1) : y x ^ 2 = 1 - x ^ 2 := + Real.sq_sqrt (sub_nonneg.mpr hx) + +theorem norm_plus (x : ℝ) (hx : x ^ 2 ≤ 1) : ‖plus x‖ = 1 := by + have h : ‖plus x‖ ^ 2 = 1 := by + rw [Complex.sq_norm, Complex.normSq_apply] + change x*x + y x*y x = 1 + nlinarith [y_sq x hx] + nlinarith [norm_nonneg (plus x)] + +theorem norm_minus (x : ℝ) (hx : x ^ 2 ≤ 1) : ‖minus x‖ = 1 := by + have h : ‖minus x‖ ^ 2 = 1 := by + rw [Complex.sq_norm, Complex.normSq_apply] + change x*x + (-y x)*(-y x) = 1 + nlinarith [y_sq x hx] + nlinarith [norm_nonneg (minus x)] + +theorem norm_family (n : ℕ) (x : ℝ) (hx : x ^ 2 ≤ 1) : + ∀ q ∈ family n x, ‖q‖ = 1 := by + intro q hq + simp only [family, Multiset.mem_add, Multiset.mem_replicate] at hq + rcases hq with ⟨_, rfl⟩ | ⟨_, rfl⟩ + · exact norm_plus x hx + · exact norm_minus x hx + +theorem sum_family (n : ℕ) (x : ℝ) : (family n x).sum = (2*n : ℕ) * (x : ℂ) := by + simp only [family, Multiset.sum_add, Multiset.sum_replicate, nsmul_eq_mul] + apply Complex.ext <;> simp [plus, minus] <;> ring + +theorem mean_family (n : ℕ) (hn : 0 < n) (x : ℝ) : + (family n x).sum / (family n x).card = (x : ℂ) := by + rw [sum_family, card_family] + have h : ((2*n : ℕ) : ℂ) ≠ 0 := by exact_mod_cast (by omega : 2*n ≠ 0) + exact mul_div_cancel_left₀ _ h + +theorem variance_family (n : ℕ) (hn : 0 < n) (x : ℝ) (hx : x ^ 2 ≤ 1) : + variance ((family n x).map (fun q => q - (x : ℂ))) = 1 - x ^ 2 := by + have hp : ‖plus x - (x : ℂ)‖ ^ 2 = 1 - x ^ 2 := by + rw [Complex.sq_norm, Complex.normSq_apply] + simpa [plus, pow_two] using y_sq x hx + have hm : ‖minus x - (x : ℂ)‖ ^ 2 = 1 - x ^ 2 := by + rw [Complex.sq_norm, Complex.normSq_apply] + simpa [minus, pow_two] using y_sq x hx + simp only [variance, Multiset.map_map, Multiset.card_map, card_family, + family, Multiset.map_add, Multiset.map_replicate, Multiset.sum_add, + Multiset.sum_replicate, nsmul_eq_mul, Function.comp_apply, hp, hm, + Multiset.card_add, Multiset.card_replicate] + have h : (n : ℝ) ≠ 0 := by exact_mod_cast hn.ne' + push_cast + field_simp + <;> ring + +theorem pair_product (x : ℝ) (hx : x ^ 2 ≤ 1) (s r : ℝ) : + ((s : ℂ) + r * plus x) * (s + r * minus x) = + ((s^2 + 2*s*r*x + r^2 : ℝ) : ℂ) := by + apply Complex.ext <;> + simp only [plus, minus, pow_two, Complex.mul_re, Complex.mul_im, Complex.add_re, + Complex.add_im, Complex.ofReal_re, Complex.ofReal_im, Complex.ofReal_add, + Complex.ofReal_mul, Complex.ofReal_ofNat, Complex.re_ofNat, Complex.im_ofNat, + zero_mul, mul_zero, sub_zero, add_zero, zero_add] + · have h := congrArg (fun z : ℝ => r^2*z) (y_sq x hx) + nlinarith only [h] + · ring + +theorem polar_product (n : ℕ) (x a t : ℝ) (hx : x^2 ≤ 1) : + ((family n x).map (fun q => (a : ℂ) + ((1-a^2)*t : ℝ)*q)).prod = + (((a^2 + 2*a*(1-a^2)*x*t + (1-a^2)^2*t^2)^n : ℝ) : ℂ) := by + simp only [family, Multiset.map_add, Multiset.map_replicate, + Multiset.prod_add, Multiset.prod_replicate, ← mul_pow] + rw [pair_product x hx] + push_cast + ring + +def K (n : ℕ) (a x : ℝ) : ℂ := + ∫ t in (0 : ℝ)..1, ((family n x).map + (fun q => (a : ℂ) + ((1-a^2)*t : ℝ)*q)).prod + +def J (n : ℕ) (a x : ℝ) : ℂ := + ((family n x).card+1 : ℂ) * (∫ t in (0 : ℝ)..1, + ((family n x).map (fun q => 1 - (a : ℂ)*t*q)).prod) + +theorem K_eq (n : ℕ) (a x : ℝ) (hx : x^2 ≤ 1) : + K n a x = ((∫ t in (0 : ℝ)..1, + (a^2 + 2*a*(1-a^2)*x*t + (1-a^2)^2*t^2)^n : ℝ) : ℂ) := by + unfold K + simp_rw [polar_product n x a _ hx] + exact intervalIntegral.integral_ofReal + +/-- Finite polynomial integration; certificates supply the exact expansion. -/ +theorem integral_coeffs (d : ℕ) (c : Fin d → ℝ) (f : ℝ → ℝ) + (he : ∀ t, f t = ∑ k : Fin d, c k * t^k.val) : + (∫ t in (0 : ℝ)..1, f t) = ∑ k : Fin d, c k / (k.val+1) := by + simp_rw [he] + rw [intervalIntegral.integral_finsetSum] + · apply Finset.sum_congr rfl + intro k hk + rw [intervalIntegral.integral_const_mul, integral_pow] + simp + ring + · intro k hk + exact (continuous_const.mul (continuous_pow k.val)).intervalIntegrable _ _ + +/-- Real endpoint polynomials, still the exact B and H from the paper. -/ +def BR (m k : ℕ) (z : ℝ) : ℝ := + ∑ j ∈ Finset.range (k+1), ((m+1).choose j : ℝ)*z^j*(1-z)^(m+1-j) + +theorem B_ofReal (m k : ℕ) (z : ℝ) : B m k (z : ℂ) = (BR m k z : ℂ) := by + simp [B, BR] + +theorem norm_H_ofReal (m k : ℕ) (z : ℝ) : ‖H m k (z : ℂ)‖ = |1-BR m k z| := by + rw [H, B_ofReal, ← Complex.ofReal_one, ← Complex.ofReal_sub, + Complex.norm_real, Real.norm_eq_abs] + +def scalarBudget (m : ℕ) (a x : ℝ) : ℝ := + |1-a*x|^(m+1) + (1-x^2)/(((m : ℝ)-1)*x^2)*|BR m 2 (a*x)| + + ∑ k ∈ Finset.Ico 3 (m+1), + C m k (1-x^2) / ((m.choose k : ℝ)*x^k)*|1-BR m k (a*x)| + +theorem budget_eq (n : ℕ) (hn : 0 < n) (a x : ℝ) (hx0 : 0 ≤ x) (hx : x^2 ≤ 1) : + majorant_Efin ((family n x).map (fun q => q-(x : ℂ))) (x : ℂ) ((a : ℂ)*x) = + scalarBudget (2*n) a x := by + unfold majorant_Efin Gamma scalarBudget + rw [variance_family n hn x hx] + simp only [Multiset.card_map, card_family, ← Complex.ofReal_mul, + ← Complex.ofReal_one, ← Complex.ofReal_sub, Complex.norm_real, Real.norm_eq_abs, + abs_of_nonneg hx0, B_ofReal, norm_H_ofReal] + +theorem BR_succ (m k : ℕ) (z : ℝ) : BR m (k+1) z = BR m k z + + ((m+1).choose (k+1) : ℝ)*z^(k+1)*(1-z)^(m+1-(k+1)) := by + simp [BR, Finset.sum_range_succ] + +/-- Squared rational certificates bound the literal square root times H. +No H endpoint is discarded, even at degree m. -/ +theorem sqrt_term_le (s d h b : ℝ) (hs : 0 ≤ s) (hd : 0 < d) (hb : 0 ≤ b) + (hcert : s*h^2 ≤ (b*d)^2) : Real.sqrt s / d * |h| ≤ b := by + have hsq := Real.sq_sqrt hs + have ha : |h|^2 = h^2 := sq_abs h + have hmul : (Real.sqrt s * |h|)^2 ≤ (b*d)^2 := by + rw [mul_pow, hsq, ha] + exact hcert + have hle : Real.sqrt s * |h| ≤ b*d := by + nlinarith [mul_nonneg (Real.sqrt_nonneg s) (abs_nonneg h), mul_nonneg hb hd.le] + rw [div_mul_eq_mul_div] + exact (div_le_iff₀ hd).2 hle + +def term (m k : ℕ) (x z : ℝ) : ℝ := + C m k (1-x^2) / ((m.choose k : ℝ)*x^k)*|1-BR m k z| + +theorem scalarBudget_le (m : ℕ) (hm : 4 ≤ m) (a x b c : ℝ) + (h3 : term m 3 x (a*x) ≤ b) + (hrest : ∀ k ∈ Finset.Ico 4 (m+1), term m k x (a*x) ≤ c) : + scalarBudget m a x ≤ |1-a*x|^(m+1) + + (1-x^2)/(((m : ℝ)-1)*x^2)*|BR m 2 (a*x)| + b + (m-3 : ℕ)*c := by + unfold scalarBudget + change _ + ∑ k ∈ Finset.Ico 3 (m+1), term m k x (a*x) ≤ _ + rw [Finset.sum_eq_sum_Ico_succ_bot (show 3 < m+1 by omega)] + have hh := Finset.sum_le_sum hrest + simp only [Finset.sum_const, Nat.card_Ico, nsmul_eq_mul] at hh + have heq : m+1-4 = m-3 := by omega + rw [heq] at hh + linarith + +theorem budget_implies_J (n : ℕ) (hn : 0 < n) (a x : ℝ) (ha : 0 ≤ a) + (hx0 : 0 < x) (hx : x^2 ≤ 1) + (hb : scalarBudget (2*n) a x + (1-x^2)/(((2*n : ℕ) : ℝ)-1)/x^2 < 1-a*x) : + 1 < ‖J n a x‖ := by + apply PaperCenteredBound.C_budget (family n x) a (x : ℂ) + (by simp; omega) ha (by rw [sum_family, card_family]) + (by exact_mod_cast hx0.ne') + rw [budget_eq n hn a x hx0.le hx] + simpa [Gamma, variance_family n hn x hx, Complex.norm_real, Real.norm_eq_abs, + abs_of_pos hx0, div_mul_eq_div_div] using hb + +end Sendov.PaperConjugate diff --git a/Sendov/Analytic/PaperConsequences.lean b/Sendov/Analytic/PaperConsequences.lean new file mode 100644 index 0000000..3fb1b50 --- /dev/null +++ b/Sendov/Analytic/PaperConsequences.lean @@ -0,0 +1,279 @@ +import Sendov.Analytic.PaperSecant +import Sendov.Analytic.PaperCenteredBound +import Sendov.Analytic.PaperUniform +import Sendov.Counterexample.Identities + +/-! +# Finite and limiting-model consequences + +AS03 concerns fixed natural degree only. EX03 retains the additional root-distance +product hypothesis and the actual polynomial factorizations. EX01/02 retain the +unproved finite-majorant hypothesis. AS05 is a theorem about the exponential +model, not an assertion of convergence to it. Historical cutoffs are restrictions +of the proved degree-256 theorem. +-/ + +noncomputable section +open scoped BigOperators +open Polynomial Filter +namespace Sendov.PaperConsequences + +/-- AS03: the exact finite endpoint has its stated value at zero. -/ +theorem U1_zero (m : ℕ) : PaperSecant.U1 m 0 = 1 / ((m : ℝ) + 1) := by + simp [PaperSecant.U1] + +/-- AS03: two-sided continuity gives, in particular, the fixed-degree right limit. -/ +theorem tendsto_U1_zero (m : ℕ) : + Tendsto (PaperSecant.U1 m) (nhds 0) (nhds (1 / ((m : ℝ) + 1))) := by + have hc : ContinuousAt (PaperSecant.U1 m) 0 := by + unfold PaperSecant.U1 + apply ContinuousAt.div <;> first | fun_prop | positivity + simpa only [U1_zero] using hc.tendsto + +/-- The paper's one-sided limit, with fixed m (not uniform in degree). -/ +theorem tendsto_U1_zero_right (m : ℕ) : + Tendsto (PaperSecant.U1 m) (nhdsWithin 0 (Set.Ioi 0)) + (nhds (1 / ((m : ℝ) + 1))) := + (tendsto_U1_zero m).mono_left nhdsWithin_le_nhds + +theorem U1_limit_lt_one {m : ℕ} (hm : 1 ≤ m) : 1 / ((m : ℝ) + 1) < 1 := by + have hm0 : (0 : ℝ) < m := by exact_mod_cast (show 0 < m by omega) + exact (div_lt_one (by positivity)).mpr (by linarith) + +/-- AS03: one epsilon excludes all real means simultaneously, at fixed degree. -/ +theorem exists_small_radius_not_rawPolar {m : ℕ} (hm : 1 ≤ m) : + ∃ ε > (0 : ℝ), ∀ a : ℝ, 0 < a → a < ε → + ∀ x : ℝ, -1 ≤ x → x ≤ 1 → ¬ PaperPolar.RawPolar m a x := by + have he : ∀ᶠ a in nhds (0 : ℝ), PaperSecant.U1 m a < 1 := + (tendsto_U1_zero m).eventually (gt_mem_nhds (U1_limit_lt_one hm)) + obtain ⟨ε, hε, he⟩ := Metric.eventually_nhds_iff.mp he + refine ⟨min ε 1, lt_min hε (by norm_num), ?_⟩ + intro a ha haε x hx0 hx1 hr + have ha1 : a < 1 := haε.trans_le (min_le_right _ _) + have hdist : dist a 0 < ε := by + simpa [Real.dist_eq, abs_of_pos ha] using haε.trans_le (min_le_left ε 1) + exact (not_lt_of_ge (PaperSecant.one_le_U1 ha ha1 hx0 hx1 hr)) (he hdist) + +private lemma prod_norm (q : Multiset ℂ) : (q.map norm).prod = ‖q.prod‖ := by + induction q using Multiset.induction_on with + | empty => simp + | cons v q ih => simp [ih] + +private lemma prod_norm_rpow (q : Multiset ℂ) (r : ℝ) : + (q.map (fun v => ‖v‖ ^ r)).prod = ‖q.prod‖ ^ r := by + induction q using Multiset.induction_on with + | empty => simp + | cons v q ih => simp [ih, Real.mul_rpow (norm_nonneg v) (norm_nonneg q.prod)] + +/-- The AM–GM step, for every positive real moment (repeated roots allowed). -/ +theorem moment_ge_card_of_one_le_norm_prod (q : Multiset ℂ) {r : ℝ} + (hr : 0 < r) (hp : 1 ≤ ‖q.prod‖) : + (q.card : ℝ) ≤ (q.map (fun v => ‖v‖ ^ r)).sum := by + by_cases hcard : q.card = 0 + · have hq := Multiset.card_eq_zero.mp hcard + subst q + simp + have hc : (0 : ℝ) < q.card := by exact_mod_cast (Nat.pos_of_ne_zero hcard) + have h := Sendov.Multiset.prod_le_mean_pow (q.map (fun v => ‖v‖ ^ r)) (by + intro v hv + obtain ⟨w, _, rfl⟩ := Multiset.mem_map.mp hv + exact Real.rpow_nonneg (norm_nonneg _) _) + rw [prod_norm_rpow, Multiset.card_map] at h + have hp' : 1 ≤ ‖q.prod‖ ^ r := by + simpa using Real.rpow_le_rpow (by norm_num : (0 : ℝ) ≤ 1) hp hr.le + have hs : 0 ≤ (q.map (fun v => ‖v‖ ^ r)).sum := by + apply Multiset.sum_nonneg + intro v hv + obtain ⟨w, _, rfl⟩ := Multiset.mem_map.mp hv + exact Real.rpow_nonneg (norm_nonneg _) _ + have hmean : 1 ≤ (q.map (fun v => ‖v‖ ^ r)).sum / q.card := by + by_contra hn + have hh := pow_lt_one₀ (div_nonneg hs hc.le) (lt_of_not_ge hn) hcard + exact (not_lt_of_ge (hp'.trans h)) hh + simpa only [one_mul] using (le_div_iff₀ hc).mp hmean + +/-- EX03: p'(a) evaluated through the actual root and inverse-critical-root +factorizations. The positive root-distance product is deduced, not assumed. -/ +theorem root_distance_product_identity {m : ℕ} {p : ℂ[X]} {c a : ℂ} + {q z : Multiset ℂ} (hc : c ≠ 0) (hq : ∀ v ∈ q, v ≠ 0) + (hpz : p = C c * ((X - C a) * (z.map (fun w => X - C w)).prod)) + (hpq : derivative p = C (((m + 1 : ℕ) : ℂ) * c) * + ((q.map (fun v => a - v⁻¹)).map (fun w => X - C w)).prod) : + 0 < (z.map (fun w => ‖a - w‖)).prod ∧ + (q.map norm).prod = ((m : ℝ) + 1) / (z.map (fun w => ‖a - w‖)).prod := by + have hid := congrArg norm (Sendov.prod_sub_mul_prod hc hq hpz hpq) + have hz : (z.map (fun w => ‖a - w‖)).prod = ‖(z.map (fun w => a - w)).prod‖ := by + simpa only [Multiset.map_map, Function.comp_def] using prod_norm (z.map (fun w => a - w)) + have hncast : ‖(m : ℂ) + 1‖ = (m : ℝ) + 1 := by + simpa only [Nat.cast_add, Nat.cast_one] using Complex.norm_natCast (m + 1) + simp only [norm_mul, Nat.cast_add, Nat.cast_one, hncast] at hid + have hpos : 0 < ‖(z.map (fun w => a - w)).prod‖ := by + have hn := norm_nonneg (z.map (fun w => a - w)).prod + have hm : (0 : ℝ) < m + 1 := by positivity + by_contra h + have hz0 : ‖(z.map (fun w => a - w)).prod‖ = 0 := le_antisymm (le_of_not_gt h) hn + rw [hz0, mul_zero] at hid + linarith + refine ⟨hz.symm ▸ hpos, ?_⟩ + rw [prod_norm, hz, eq_div_iff hpos.ne'] + exact hid + +/-- EX03: the extra root-product region forces every positive real moment. +No pointwise unit-disk hypothesis is needed for this separate obstruction. -/ +theorem moment_ge_degree_of_root_distance_product {m : ℕ} {p : ℂ[X]} {c a : ℂ} + {q z : Multiset ℂ} (_hm : 1 ≤ m) (hqcard : q.card = m) + (_hzcard : z.card = m) (hc : c ≠ 0) (hq : ∀ v ∈ q, v ≠ 0) + (hpz : p = C c * ((X - C a) * (z.map (fun w => X - C w)).prod)) + (hpq : derivative p = C (((m + 1 : ℕ) : ℂ) * c) * + ((q.map (fun v => a - v⁻¹)).map (fun w => X - C w)).prod) + (hprod : (z.map (fun w => ‖a - w‖)).prod ≤ (m : ℝ) + 1) + {r : ℝ} (hr : 0 < r) : (m : ℝ) ≤ (q.map (fun v => ‖v‖ ^ r)).sum := by + obtain ⟨hpos, hid⟩ := root_distance_product_identity hc hq hpz hpq + have hp : 1 ≤ ‖q.prod‖ := by + rw [← prod_norm, hid] + exact (le_div_iff₀ hpos).mpr (by simpa using hprod) + simpa only [hqcard] using moment_ge_card_of_one_le_norm_prod q hr hp + +/-- The actual centered variance, not an independent scalar surrogate. -/ +theorem centered_variance_le (q : Multiset ℂ) (μ : ℂ) (hm : 0 < q.card) + (hmean : q.sum = q.card * μ) (hq : ∀ v ∈ q, ‖v‖ ≤ 1) : + PaperCentered.variance (q.map (fun v => v - μ)) ≤ 1 - ‖μ‖ ^ 2 ∧ ‖μ‖ ≤ 1 := by + have hc : (0 : ℝ) < q.card := by exact_mod_cast hm + have hs := PaperCoefficient.sum_norm_add_sq (q.map (fun v => v - μ)) μ + rw [PaperCentered.centered_sum q μ hmean] at hs + have hmap : (q.map (fun v => v - μ)).map (fun w => ‖μ + w‖ ^ 2) = + q.map (fun v => ‖v‖ ^ 2) := by + simp only [Multiset.map_map, Function.comp_def] + congr 1 + funext v + congr 2 + ring + rw [hmap] at hs + simp only [Multiset.card_map, map_zero, mul_zero, Complex.zero_re, add_zero] at hs + have hsum : (q.map (fun v => ‖v‖ ^ 2)).sum ≤ (q.card : ℝ) := by + simpa using Multiset.sum_map_le_sum_map (fun v : ℂ => ‖v‖ ^ 2) (fun _ => (1 : ℝ)) + (fun v hv => pow_le_one₀ (norm_nonneg v) (hq v hv)) + have hv0 : 0 ≤ ((q.map (fun v => v - μ)).map (fun v => ‖v‖ ^ 2)).sum := by + apply Multiset.sum_nonneg + intro v hv + obtain ⟨w, _, rfl⟩ := Multiset.mem_map.mp hv + exact sq_nonneg _ + have hv : PaperCentered.variance (q.map (fun v => v - μ)) ≤ 1 - ‖μ‖ ^ 2 := by + unfold PaperCentered.variance + rw [Multiset.card_map, div_le_iff₀ hc] + nlinarith only [hs, hsum] + refine ⟨hv, ?_⟩ + have hsq : ‖μ‖ ^ 2 ≤ 1 := by nlinarith only [hs, hsum, hv0, hc] + nlinarith only [hsq, norm_nonneg μ] + +/-- Raw polar and the actual real part make the complex mean nonzero. -/ +theorem mean_ne_zero_of_rawPolar {m : ℕ} {a x : ℝ} {μ : ℂ} + (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hx : μ.re = x) (hr : PaperPolar.RawPolar m a x) : μ ≠ 0 := by + have hg := (PaperPolar.geometry hm ha ha1 hx0 hx1 hr).1 + intro hz + simp only [hz, Complex.zero_re] at hx + linarith + +/-- EX01: the factor-three bound on the actual variance-to-mean-square ratio. -/ +theorem variance_ratio_le_alpha (q : Multiset ℂ) {μ : ℂ} {a x : ℝ} + (hm : 7 ≤ q.card) (ha : 0 < a) (ha1 : a < 1) + (hmean : q.sum = q.card * μ) (hq : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hx : μ.re = x) + (hr : PaperPolar.RawPolar q.card a x) : + PaperCentered.variance (q.map (fun v => v - μ)) / ‖μ‖ ^ 2 ≤ + PaperPolar.alpha q.card a / 3 := by + have hμ := mean_ne_zero_of_rawPolar hm ha ha1 hx0 hx1 hx hr + have hs : 0 < ‖μ‖ ^ 2 := sq_pos_of_pos (norm_pos_iff.mpr hμ) + have hv := (centered_variance_le q μ (by omega) hmean hq).1 + have hb := PaperPolar.b_le_alpha (by omega : 0 < q.card) ha ha1 hx0 hx1 hr + have hα := PaperPolar.alpha_pos (by omega : 0 < q.card) ha ha1 + have hprod := (le_div_iff₀ (by positivity : 0 < 3 + PaperPolar.alpha q.card a)).mp hb + have hnorm : 1 - PaperPolar.b a x ≤ ‖μ‖ ^ 2 := by + have hh := Complex.sq_norm_sub_sq_re μ + rw [hx] at hh + unfold PaperPolar.b + nlinarith only [hh, sq_nonneg (μ.im), sq_nonneg (x - a)] + have hh := mul_le_mul_of_nonneg_left hnorm (show 0 ≤ 3 + PaperPolar.alpha q.card a by positivity) + apply (div_le_iff₀ hs).mpr + nlinarith only [hv, hprod, hh] + +/-- EX01: the finite centered correction is strictly less than 7h/18, h=1-a. -/ +theorem Gamma_lt_seven_eighteenths (q : Multiset ℂ) {μ : ℂ} {a x : ℝ} + (hm : 7 ≤ q.card) (ha : 0 < a) (ha1 : a < 1) + (hmean : q.sum = q.card * μ) (hq : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hx : μ.re = x) + (hr : PaperPolar.RawPolar q.card a x) : + PaperCentered.Gamma (q.map (fun v => v - μ)) μ < 7 * (1 - a) / 18 := by + have hm' : (7 : ℝ) ≤ q.card := by exact_mod_cast hm + have hd : 0 < (q.card : ℝ) - 1 := by linarith + have hv := variance_ratio_le_alpha q hm ha ha1 hmean hq hx0 hx1 hx hr + have hg : PaperCentered.Gamma (q.map (fun v => v - μ)) μ ≤ + PaperPolar.alpha q.card a / (3 * ((q.card : ℝ) - 1)) := by + unfold PaperCentered.Gamma + rw [Multiset.card_map, mul_comm ((q.card : ℝ) - 1), ← div_div] + exact (div_le_div_of_nonneg_right hv hd.le).trans_eq (div_div _ _ _) + apply hg.trans_lt + apply (div_lt_iff₀ (by positivity : 0 < 3 * ((q.card : ℝ) - 1))).mpr + unfold PaperPolar.alpha + have hstrict : (q.card : ℝ) * (1 - a ^ 2) < 2 * q.card * (1 - a) := by + nlinarith only [mul_pos (show (0 : ℝ) < q.card by linarith) (sq_pos_of_pos (sub_pos.mpr ha1))] + have hscale := mul_nonneg (show 0 ≤ (q.card : ℝ) - 7 by linarith) (sub_pos.mpr ha1).le + nlinarith only [hstrict, hscale] + +/-- EX02: conditional closure. The finite square-root majorant estimate remains +an explicit hypothesis, so this does not assert a global centered-budget theorem. -/ +theorem norm_J_gt_one_of_majorant_half (q : Multiset ℂ) {μ : ℂ} {a x : ℝ} + (hm : 7 ≤ q.card) (ha : 0 < a) (ha1 : a < 1) + (hmean : q.sum = q.card * μ) (hq : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hx : μ.re = x) + (hr : PaperPolar.RawPolar q.card a x) + (hfin : PaperCenteredBound.majorant_Efin (q.map (fun v => v - μ)) μ (a * μ) ≤ + (1 - a) / 2) : + 1 < ‖(q.card + 1 : ℂ) * + (∫ t in (0 : ℝ)..1, (q.map (fun v => 1 - (a : ℂ) * t * v)).prod)‖ := by + have hg := Gamma_lt_seven_eighteenths q hm ha ha1 hmean hq hx0 hx1 hx hr + have hn := (centered_variance_le q μ (by omega) hmean hq).2 + apply PaperCenteredBound.C_budget q a μ (by omega) ha.le hmean + (mean_ne_zero_of_rawPolar hm ha ha1 hx0 hx1 hx hr) + have hh := mul_le_mul_of_nonneg_left hn ha.le + nlinarith only [hg, hfin, hh, ha1] + +/-- AS05: the entire feasible exponential-model family has positive budget. +This is not a finite-degree convergence claim. The endpoint x=1 is included. -/ +theorem limiting_exponential_model {ℓ x : ℝ} (hℓ : 0 < ℓ) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hG : 1 ≤ ∫ t in (0 : ℝ)..1, Real.exp (ℓ * (2 * x * t - 1))) : + 1 / 2 < x ∧ 1 - x ≤ ℓ * x ^ 2 / 6 ∧ + (1 - x) * (5 - x) ≤ (1 + ℓ) * x ^ 2 - 1 ∧ + 0 < (1 + ℓ) * x ^ 2 - 1 := by + have hG' : 1 ≤ ∫ t in (0 : ℝ)..1, + Real.exp (ℓ * (-1 + (2 - 2 * (1 - x)) * t)) := by + convert hG using 1 + congr 1 + funext t + congr 1 + ring + have hb := Sendov.beta_le hℓ (by linarith : 0 ≤ 2 * (1 - x)) hG' + have hb' := (le_div_iff₀ (by positivity : 0 < 3 + ℓ)).mp hb + have hhalf : 1 / 2 < x := by nlinarith only [hb', hℓ] + have hsq := mul_nonneg hℓ.le (sq_nonneg (1 - x)) + have hmodel : 1 - x ≤ ℓ * x ^ 2 / 6 := by nlinarith only [hb', hsq] + have hbudget : (1 - x) * (5 - x) ≤ (1 + ℓ) * x ^ 2 - 1 := by + nlinarith only [hmodel] + refine ⟨hhalf, hmodel, hbudget, ?_⟩ + rcases hx1.eq_or_lt with he | he + · subst x + nlinarith only [hℓ] + · have hp := mul_pos (sub_pos.mpr he) (show 0 < 5 - x by linarith) + linarith only [hp, hbudget] + +/-- UN: every old all-a cutoff is an explicit restriction of uniform D. +In particular M=512,10000,100000,1000000 are covered with identical assumptions. -/ +theorem old_all_a_cutoff {M m : ℕ} {a x : ℝ} (hM : 256 ≤ M) (hm : M ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : PaperPolar.RawPolar m a x) : + PaperTaylor.budget (m : ℝ) a x < 1 - (m : ℝ) * a / ((m : ℝ) + 1) := + PaperUniform.uniform_D (hM.trans hm) ha ha1 hx0 hx1 hr + +end Sendov.PaperConsequences diff --git a/Sendov/Analytic/PaperLegacyExact.lean b/Sendov/Analytic/PaperLegacyExact.lean new file mode 100644 index 0000000..c7c84b1 --- /dev/null +++ b/Sendov/Analytic/PaperLegacyExact.lean @@ -0,0 +1,77 @@ +import Sendov.Analytic.PaperLegacyHelpers + +/-! Exact rational polar evaluations, retaining the original certificate values. +The coefficients are only proof witnesses: Lean checks the polynomial identities +and performs the actual interval integrals. -/ +namespace Sendov.PaperLegacy +open MeasureTheory +open scoped BigOperators +set_option maxRecDepth 4096 +set_option linter.style.longLine false + +noncomputable def rejectedValue : ℝ := (21484374999999997335218629130671942625580595921317281107599410652807517809930638152511891758297318219940306524303963658262024409195338388735195202696322122987717532298125821810500213171812932277952301854268159 / 21484375000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) +private noncomputable def rejectedCoeffs : Fin 11 → ℝ := + ![976562490234375043945312382812500205078124753906250205078124882812500043945312490234375000976562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 19531249552669026715464577249306416701978311703864739848288905306799591259003664699407384262078183462857949218750000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 175781244229423197139243642246291875915240261256588770149425547209847217583986898501207995202542091532074227775690781082656250000000000000000000000000000000000000000000000000000000000000000000, 937499962711431241295991798411903968924932074308504202041591985488186711968570691816017830356060066295607212774177608391717279902807364375000000000000000000000000000000000000000000000, 3281249856470725215965603408883241546477687642532728230279700312438262491550174373957944013664223819976348092399432586880362527583489353725025273933801250000000000000000000000, 7874999647739313137103475501120615593423415505689905342901785350291718420293237499889285065389735527007437001077168822132349410207161036809037673161167157481192300407, 13124999439007900306151563801436505063064834117796567069993875993358161863449795575610770338147038699889748164989019427988358546199637555857422773933801250000, 14999999433382898720001666490402347404098825498172417772696908360642673474310351721754854263997277644718560796512923217530487822402807364375000000000, 11249999664433083584898344607858275988131137403065956441794005215699668909881894975681449120321938754621835791279753281082656250000000000000, 4999999905483270436092013997774146398701233709505087067885122765193417608389944666109940900934214589712857949218750000000000000000, 999999995000000011249999985000000013124999992125000003281249999062500000175781249980468750000976562500000000000000000000] +-- Kernel-checked expansion of the exact rational coefficient witness. +set_option maxHeartbeats 4000000 in +lemma rejected_integral : R 5 (999999999 / 1000000000) (499999993298327 / 500000000000000) = rejectedValue := by + unfold R + rw [integral_coefficients 11 (fun k => rejectedCoeffs k / 976562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) _ (by + intro t + simp [P, rejectedCoeffs, Fin.sum_univ_succ] + ring)] + norm_num [rejectedCoeffs, Fin.sum_univ_succ, rejectedValue] + +noncomputable def lowerValue : ℝ := (300781249999999999999999991979166680302083362609374907158854146614583722558593182545138795220487626343747271838544554200518729714844852479166248774739695585937479689670141111111111 / 300781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) +private noncomputable def lowerCoeffs : Fin 11 → ℝ := + ![999999990000000044999999880000000209999999748000000209999999880000000044999999990000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 19999999790000000999999997150000005399999992860000006719999995500000002099999999350000000119999999990000000000000000000000000000000000000000000000000000000000000000000000000, 179999998060000009564999971480000057259999918480000084349999936120000035119999986340000003564999999440000000040000000000000000000000000000000000000000000000000000000, 959999989600000051919999841800000328319999509840000541599999551600000278079999872480000041999999990600000001279999999920000000000000000000000000000000000000, 3359999964160000177039999462800001119649998302580001932469998319720001122389999426420000220809999937920000012039999998560000000080000000000000000000, 8063999917120000395199998839520002348759996525460003886799996645020002259159998809100000489407999845380000036479999993920000000639999999968, 13439999870080000581599998400320003023479995841160004298049996606520002058139999045600000333009999915280000014839999998400000000080, 15359999864320000551679998632320002306879997204640002502799998324360000838399999690560000081839999985320000001599999999920, 11519999910400000317439999322880000968159999022720000713999999619600000146684999960070000007284999999200000000040, 5119999966720000097279999831040000193919999845440000087359999964960000009779999998190000000199999999990, 1023999994880000011519999984640000013439999991936000003359999999040000000179999999980000000001] +-- Kernel-checked expansion of the exact rational coefficient witness. +set_option maxHeartbeats 4000000 in +lemma lower_integral : R 5 (999999999 / 1000000000) (999999999 / 1000000000) = lowerValue := by + unfold R + rw [integral_coefficients 11 (fun k => lowerCoeffs k / 1000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) _ (by + intro t + simp [P, lowerCoeffs, Fin.sum_univ_succ] + ring)] + norm_num [lowerCoeffs, Fin.sum_univ_succ, lowerValue] + +noncomputable def upperValue : ℝ := (481250000000000000000000468416667249941661820800250678954209818746582015341119357762285008107528488304159940324353574007262488216096783189067490161962713862765485621136939178374143223285192061918203408478780933333359 / 481250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) +private noncomputable def upperCoeffs : Fin 11 → ℝ := + ![3124999968750000140624999625000000656249999212500000656249999625000000140624999968750000003125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 62499999343750009374999931718750269999999340187501070999998804687500925312499510468750169124999965593750003125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 562499993937500129890623910875009703937442520250203413593292500375689259749284807313014111140373098250080325124984975000001250000000000000000000000000000000000000000000000000000000000000000000000000, 2999999967500000862249992355625094400999334355754625179976511361325294581343693089218626118539173608265717666436088874768855074996742500000250000000000000000000000000000000000000000000000000, 10499999888000003353249969921250436098902987095591868213790273325169627427784818296272701738714100665172319382008374239479745442248759902190014999649000000025000000000000000000000000, 25199999741000008234999927873501116739866693492143892683241242362897652510657664206988656388250725568942608335835530336322606699636005059531679654232990100800999984950000001, 41999999594000013017499892601001640248363561803731443930795933598969707891394518982940491272036877563238840460499123452817210638219729902867014999599000000025000000, 47999999576000012923999903726001311608992014664557422120992380914289511593929703121643287742414128492046792317355153574782385074995742500000250000000000000, 35999999720000007391999953084000463825497814546005444631241724411258285658384954475221430847764760922500181725124977475000001250000000000000000000, 15999999896000001903999990672000022205999968317000029672999980990500008430562497444343750506874999940593750003125000000000000000000000000, 3199999984000000035999999952000000041999999974800000010499999997000000000562499999937500000003125000000000000000000000000000000] +-- Kernel-checked expansion of the exact rational coefficient witness. +set_option maxHeartbeats 4000000 in +lemma upper_integral : R 5 (999999999 / 1000000000) (9999999990000001 / 10000000000000000) = upperValue := by + unfold R + rw [integral_coefficients 11 (fun k => upperCoeffs k / 3125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) _ (by + intro t + simp [P, upperCoeffs, Fin.sum_univ_succ] + ring)] + norm_num [upperCoeffs, Fin.sum_univ_succ, upperValue] + +noncomputable def legacyValue : ℝ := (4812500000000000000000000016041667053270832333937499072791679301083303621187491236972452837735445936250789684438375523306165816662255646054499495954894600939643764087516503820343977280168916684346885750721029374900505000006237 / 4812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) +private noncomputable def legacyCoeffs : Fin 11 → ℝ := + ![31249999687500001406249996250000006562499992125000006562499996250000001406249999687500000031250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 624999993437500033124999893125000244687499585625000524999999505000000341249999833437500054374999989375000000937500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 5624999939375000328906248808750003191874993380000010837187485943750014327499988728125006658906247162500000818749999857500000011250000000000000000000000000000000000000000000000000000000000000000000000000000000, 29999999675000001832499992911250020812499951318750093016249853248750191258749795738750175946249880610000061806249976642500006029999999055000000067500000000000000000000000000000000000000000000000000000, 104999998880000006372499974692500077469062307755625398032186801133751048665936154755626465294061163352501000392499402175000275473749906550000021802499996895000000202500000000000000000000000000, 251999997410000014449999943185000173418749567765625906423748369850002547089371512150629204627495543068754116695621745155002147254998855040000474944999853975000031049999995950000000243, 419999995940000021534999919290000234523749445596251095244060665053752623024371806487503280770309702042501936768748941977500440773749866050000027809999996490000000202500000000, 479999995760000020599999929660000184049999614865000657302499080081251050752499033566250701508749607955000163718749950902500009944999998785000000067500000000000000000, 359999997200000011839999965400000075374999873460000165112499833792500127223906177232187530415156241012500001774999999790000000011250000000000000000000000000, 159999998960000003519999992080000012539999985810000011549999993235000002825624999178437500158124999981875000000937500000000000000000000000000000000, 31999999840000000359999999520000000419999999748000000104999999970000000005624999999375000000031250000000000000000000000000000000000000000] +-- Kernel-checked expansion of the exact rational coefficient witness. +set_option maxHeartbeats 4000000 in +lemma legacy_integral : R 5 (999999999 / 1000000000) (999999999000000003 / 1000000000000000000) = legacyValue := by + unfold R + rw [integral_coefficients 11 (fun k => legacyCoeffs k / 31250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) _ (by + intro t + simp [P, legacyCoeffs, Fin.sum_univ_succ] + ring)] + norm_num [legacyCoeffs, Fin.sum_univ_succ, legacyValue] + +noncomputable def twentyValue : ℝ := (1182519467309602248471006652606768554894193590679433 / 1173046875000000000000000000000000000000000000000000) +private noncomputable def twentyCoeffs : Fin 21 → ℝ := + ![11872720174860282032226562500000000000000000000, 41607288257232588366269531250000000000000000000, 70906115783044139771673457031250000000000000000, 78007291862154365631737486250000000000000000000, 62060754046839521488027293922031250000000000000, 37919128118078847803887866969844875000000000000, 18449569974371155617189838386762568125000000000, 7315976650377368786558608476549680805000000000, 2400393836570299654349587056655860973811250000, 657906643473222179876447533861375938798165000, 151432591335625019536292532087062857758306249, 29321518307880642831530562928883544926683650, 4767897045811279092432442231526420636611125, 647647748089500616297106722878640477005000, 72790546517834256355220385661008608681250, 6667595704033504337638471948682866987500, 486351372918838520071794158750684531250, 27245230230762419687601107285362500000, 1103725711683864137908773959220703125, 28864833648012778341320552988281250, 367089584546347247981988291015625] +-- Kernel-checked expansion of the exact rational coefficient witness. +set_option maxHeartbeats 4000000 in +lemma twenty_integral : R 10 (9 / 10) (83 / 100) = twentyValue := by + unfold R + rw [integral_coefficients 21 (fun k => twentyCoeffs k / 97656250000000000000000000000000000000000000000) _ (by + intro t + simp [P, twentyCoeffs, Fin.sum_univ_succ] + ring)] + norm_num [twentyCoeffs, Fin.sum_univ_succ, twentyValue] + +end Sendov.PaperLegacy diff --git a/Sendov/Analytic/PaperLegacyHelpers.lean b/Sendov/Analytic/PaperLegacyHelpers.lean new file mode 100644 index 0000000..b2a228f --- /dev/null +++ b/Sendov/Analytic/PaperLegacyHelpers.lean @@ -0,0 +1,150 @@ +import Sendov.Analytic.PaperTaylor +import Sendov.Analytic.PaperPolar +import Mathlib.Analysis.SpecialFunctions.Integrals.Basic + +/-! Conjugate-pair full polar and a finite split bound for the actual T integral. +No centered budget or numerical quadrature is used. -/ +namespace Sendov.PaperLegacy +open MeasureTheory +open scoped BigOperators + +noncomputable def pair (x : ℝ) (j : Fin 2) : ℂ := + ⟨x, if j.val = 0 then Real.sqrt (1 - x ^ 2) else -Real.sqrt (1 - x ^ 2)⟩ +noncomputable def q (n : ℕ) (x : ℝ) (j : Fin n × Fin 2) : ℂ := pair x j.2 +noncomputable def P (a x t : ℝ) := + a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2 +noncomputable def R (n : ℕ) (a x : ℝ) := ∫ t in (0 : ℝ)..1, P a x t ^ n +noncomputable def K (n : ℕ) (a x : ℝ) : ℂ := + ∫ t in (0 : ℝ)..1, ∏ j : Fin n × Fin 2, + ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * q n x j) + +lemma pair_norm {x : ℝ} (hx : x ^ 2 ≤ 1) (j : Fin 2) : ‖pair x j‖ = 1 := by + have hy := Real.sq_sqrt (sub_nonneg.mpr hx) + have h : ‖pair x j‖ ^ 2 = 1 := by + rw [Complex.sq_norm, Complex.normSq_apply] + fin_cases j <;> simp [pair] <;> nlinarith + nlinarith [norm_nonneg (pair x j)] + +theorem norm_q {n : ℕ} {x : ℝ} (hx : x ^ 2 ≤ 1) (j : Fin n × Fin 2) : + ‖q n x j‖ = 1 := pair_norm hx j.2 + +/-- The scalar parameter is exactly the real part of the family's mean. -/ +theorem mean_re {n : ℕ} (hn : 0 < n) (x : ℝ) : + ((∑ j : Fin n × Fin 2, q n x j) / (2 * n : ℂ)).re = x := by + have hpair : (∑ j : Fin 2, pair x j) = 2 * (x : ℂ) := by + apply Complex.ext <;> simp [Fin.sum_univ_succ, pair] <;> ring + rw [Fintype.sum_prod_type] + simp only [q, hpair, Finset.sum_const, Finset.card_univ, + Fintype.card_fin, nsmul_eq_mul] + have hn' : (n : ℂ) ≠ 0 := by exact_mod_cast (Nat.ne_of_gt hn) + have he : (n : ℂ) * (2 * x) / (2 * n) = x := by field_simp + rw [he, Complex.ofReal_re] + +lemma pair_product {x : ℝ} (hx : x ^ 2 ≤ 1) (s r : ℝ) : + (∏ j : Fin 2, ((s : ℂ) + r * pair x j)) = + ((s ^ 2 + 2 * s * r * x + r ^ 2 : ℝ) : ℂ) := by + have hy := Real.sq_sqrt (sub_nonneg.mpr hx) + simp only [Fin.prod_univ_succ] + apply Complex.ext <;> simp [pair, pow_two] + · simp only [pow_two] at hy + nlinarith [congrArg (fun z : ℝ => r ^ 2 * z) hy] + · ring + +lemma product_eq {x : ℝ} (hx : x ^ 2 ≤ 1) (n : ℕ) (a t : ℝ) : + (∏ j : Fin n × Fin 2, ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * q n x j)) = + ((P a x t ^ n : ℝ) : ℂ) := by + rw [Fintype.prod_prod_type] + simp only [q, pair_product hx] + simp only [Finset.prod_const, Finset.card_univ, Fintype.card_fin] + push_cast + congr 1 + unfold P + push_cast + ring + +/-- Literal full complex K equals the real polynomial integral for all pair counts. -/ +theorem K_eq_R {x : ℝ} (hx : x ^ 2 ≤ 1) (n : ℕ) (a : ℝ) : K n a x = (R n a x : ℂ) := by + unfold K R + simp_rw [product_eq hx] + rw [intervalIntegral.integral_ofReal] + +lemma norm_K_eq {x : ℝ} (hx : x ^ 2 ≤ 1) (n : ℕ) (a : ℝ) + (hr : 0 ≤ R n a x) : ‖K n a x‖ = R n a x := by + rw [K_eq_R hx, Complex.norm_real, Real.norm_eq_abs, abs_of_nonneg hr] + +lemma raw_even (n : ℕ) (a x : ℝ) : PaperPolar.RawPolar (2 * n) a x ↔ 1 ≤ R n a x := by + unfold PaperPolar.RawPolar R P + push_cast + rw [show (2 * (n : ℝ)) / 2 = n by ring] + simp only [Real.rpow_natCast] + +/-- Finite polynomial integral from an explicitly verified coefficient identity. -/ +lemma integral_coefficients (N : ℕ) (c : Fin N → ℝ) (f : ℝ → ℝ) + (hf : ∀ t, f t = ∑ k : Fin N, c k * t ^ k.val) : + (∫ t in (0 : ℝ)..1, f t) = ∑ k : Fin N, c k / (k.val + 1) := by + simp_rw [hf] + rw [intervalIntegral.integral_finsetSum] + · apply Finset.sum_congr rfl + intro k hk + rw [intervalIntegral.integral_const_mul, integral_pow] + simp + ring + · intro k hk + exact (continuous_const.mul (continuous_pow k.val)).intervalIntegrable _ _ + +/-- A finite split, a left chord extended only to its zero, and a bounded right tail. +The natural exponent on the tail rounds DOWN the actual half-integer exponent. -/ +lemma budget_split_le {m a x s c r : ℝ} {n : ℕ} + (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1) (hx : x ≤ 1) + (hs : 0 ≤ s) (hs1 : s ≤ 1) (hc : 0 < c) (hsc : s ≤ 1 / c) + (hr : 0 < r) (hr1 : r ≤ 1) (hn : (n : ℝ) ≤ (m - 1) / 2) + (hl : ∀ t ∈ Set.Icc (0 : ℝ) s, PaperTaylor.beta a x t ≤ 1 - c * t) + (htail : ∀ t ∈ Set.Icc s 1, PaperTaylor.beta a x t ≤ r) : + PaperTaylor.budget m a x ≤ PaperTaylor.beta a x 1 ^ (m / 2) + m * a ^ 2 * + (1 / (c ^ 2 * (((m - 1) / 2 + 1) * ((m - 1) / 2 + 2))) + + r ^ n * ((1 - s ^ 2) / 2)) := by + let p := (m - 1) / 2 + have hp : 0 < p := by dsimp [p]; linarith + have hf : Continuous (fun t : ℝ => t * PaperTaylor.beta a x t ^ p) := + continuous_id.mul ((continuous_rpow_const hp.le).comp (by unfold PaperTaylor.beta; fun_prop)) + have hg : Continuous (fun t : ℝ => t * (1 - c * t) ^ p) := + continuous_id.mul ((continuous_rpow_const hp.le).comp (by fun_prop)) + have hleft : (∫ t in (0 : ℝ)..s, t * PaperTaylor.beta a x t ^ p) ≤ + 1 / (c ^ 2 * ((p + 1) * (p + 2))) := by + have hmono := intervalIntegral.integral_mono_on (μ := volume) hs (hf.intervalIntegrable 0 s) + (hg.intervalIntegrable 0 s) (fun t ht => + mul_le_mul_of_nonneg_left (Real.rpow_le_rpow + (PaperTaylor.beta_pos ha ha1 hx ⟨ht.1, ht.2.trans hs1⟩).le (hl t ht) hp.le) ht.1) + have hrest : 0 ≤ ∫ t in s..1 / c, t * (1 - c * t) ^ p := by + apply intervalIntegral.integral_nonneg hsc + intro t ht + have := (le_div_iff₀ hc).mp ht.2 + exact mul_nonneg (hs.trans ht.1) (Real.rpow_nonneg (by nlinarith) _) + have hadd := intervalIntegral.integral_add_adjacent_intervals (μ := volume) + (hg.intervalIntegrable 0 s) (hg.intervalIntegrable s (1 / c)) + rw [integral_chord_lin hp hc] at hadd + linarith + have hright : (∫ t in s..1, t * PaperTaylor.beta a x t ^ p) ≤ + r ^ n * ((1 - s ^ 2) / 2) := by + have hpow : r ^ p ≤ r ^ n := by + rw [← Real.rpow_natCast] + exact Real.rpow_le_rpow_of_exponent_ge hr hr1 hn + have hmono := intervalIntegral.integral_mono_on (μ := volume) hs1 (hf.intervalIntegrable s 1) + ((by fun_prop : Continuous (fun t : ℝ => r ^ n * t)).intervalIntegrable s 1) + (fun t ht => by + have ht0 := hs.trans ht.1 + have h := (Real.rpow_le_rpow (PaperTaylor.beta_pos ha ha1 hx ⟨ht0, ht.2⟩).le + (htail t ht) hp.le).trans hpow + simpa only [mul_comm] using mul_le_mul_of_nonneg_left h ht0) + rw [intervalIntegral.integral_const_mul, integral_id] at hmono + simpa using hmono + have hadd := intervalIntegral.integral_add_adjacent_intervals (μ := volume) + (hf.intervalIntegrable 0 s) (hf.intervalIntegrable s 1) + have hi : (∫ t in (0 : ℝ)..1, t * PaperTaylor.beta a x t ^ p) ≤ + 1 / (c ^ 2 * ((p + 1) * (p + 2))) + r ^ n * ((1 - s ^ 2) / 2) := by + rw [← hadd] + exact add_le_add hleft hright + have h := mul_le_mul_of_nonneg_left hi (show 0 ≤ m * a ^ 2 by positivity) + exact add_le_add le_rfl h + +end Sendov.PaperLegacy diff --git a/Sendov/Analytic/PaperLegacyHundred.lean b/Sendov/Analytic/PaperLegacyHundred.lean new file mode 100644 index 0000000..b1c5dfc --- /dev/null +++ b/Sendov/Analytic/PaperLegacyHundred.lean @@ -0,0 +1,25 @@ +import Sendov.Analytic.PaperLegacyHelpers + +/-! Exact rational polar evaluations, retaining the original certificate values. +The coefficients are only proof witnesses: Lean checks the polynomial identities +and performs the actual interval integrals. -/ +namespace Sendov.PaperLegacy +open MeasureTheory +open scoped BigOperators +set_option maxRecDepth 4096 +set_option linter.style.longLine false + +noncomputable def hundredValue : ℝ := (14313215927707901402812696032528538119334551902447926006635832271609803863644007817037599529155215149965230748737891573673073813461328796095825584593099403616561318103317457698514761610758806542012939294274038354076074324868302713135069383609883803251414851327227994737708450444463078064775328139839194381937553501581252448598855714828779410582917232004133053591418576446613090226774400343085737079866679727436329886774681351007 / 14295771323094814150976518270000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) +private noncomputable def hundredCoeffs : Fin 101 → ℝ := + ![3660323412732295049306160265725173861897120766389236914059573726993170447507247481871965435100269504006615691006528432747182356968017994158571053544917075742738903500609827083711497821991676084949000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 6474705414522015242772674603371640875711351400101850185758712637081252613812819990155743302977365611531702422313770294370571458103427385222716796937231093980489260414412049685854116147345275919154231288000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 5685934683473940570970005349810097168709643933214346029478813974916670120802436672462442298101512266251829718872124788638819463714711254405690736544728229752126180455403542192733256260688834990313331837325600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 3304823324616858068820339097916520143329831833133534553992120488451233835584801178859844237333050574079482485914935336733029501473154236582101212457627690726251780379337948600675894977346995485962850221622792960000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 1430064767120726669691852822469658014644619456908874469284288492050653422399582075241688902118056755475193647750625646032445636955388579625258202554482931512322933047578353593633051892244031277121277025694169611328000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 491356252448812598456199212805495091875496268943961148627413343126021990392111747187469019137185382220992401009273252659742573773240250599303627725283699817845938028690320634566824553603079136051560516043185254648053760000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 139618288913540675364028563725302851293324618248163913308371375343752362065819049663866644099102789645509523560122786676807987177857827201131723471346147961229847328661722019131687926824419141312405293163762915405115064320000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 33741935200068512243581743269965542622670027494159397420952175234422309775152379410288176269682127701140942639209368418414214551615964237395374898606808795790196993185738280221093944240762969320248036868423475073209912786944000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 7079067472631173176576252732311727597624842910598897273693252965744526845181327869598666902807691868550576783940386571423701805953452180892485113141908408170848680170350173217071108134022049015330639965324810259351391519106662400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 1309606798113604468572459108212021195534467744415240158082688071183650028134219016196704913216958363832205226433372042851212030227834094212010957880043208551651123730580126183070142124220697860632318882000247217281239416807484293120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 216271784838640573314449246866886880994790485662261734250918582754740308536744126101777949229320655542239242515978952669277861591133241489010547764034476563938549299387204614886724960247325766834694151503032563641863888254476200653619200000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 32200092830014990365013611420267354452889322797197242343473006585454078188360278543143145379315961633204345488840940544191341251746540008397059171483766107988264502090007833203191823999662620714257840660668683557616852279641675439852748800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 4357680712522214325908575159705029641370730873083477241927776705793553173943166369228188057618287984885375588344449446291985834964852736180527751768393312147053440298785684387342188949207057340768768803061665548755286030590343339765514895360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 539707987938702384651516080002344633925779670068314317147978909108497793256638982053373233111806607846991660926321191670025022441914386635892490756233398029986822390074417401043688414113698097737892539591014921795245376050467736805284601921536000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 61529245284895944193795083438628639388669836397380307779725796983406933531348573398100684567541046599183638246293289947561647626610654334321001030401356580016320153559696205326426437557488675856553879213324117716439290650095096227373521828629708800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 6489045292659917056712190623483713194861525910611813993968677586169195402375774190262884358261616975324567673381302785697405065829091372976877380863498775925043880738376156263936905185103965823749745032637724288371122690048428170654794616037034688512000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 635807498043060126742676962918965947136234606000040028728824252701233438261037127491886982217057718331255907459380097658059657829927135249964234645978023348437075683708855756298587591685854810476199439032090556699098375685827544110964882309598268096512000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 58096426199798328505900722970708270288577223184967674922793994995590404286246494342328544547100264417021269145328190073221500033821978352568580572773619676549933895289802323178695743391441442420069516145435166309245077106694040945914748979437447835706982400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 4966950394926642679883116159513687934279767135499808913732272219814876510996870636051691380081599269576877813013868954090708712012806723224367451156594641650457139148171331041083625707288222815989429337721173630559946939040010730519294041002911488303106621440000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 398492776031857615085537608340098687268694015279290104704257422984540593087605381973379567020048786415006417859112452266597774903978999385306403701592976781807512400724298958695744843318665606935950995706445488470025098009390722365748540213785197022806049554432000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 30079859980467078014348519419768149364595501153410084928967589160869640319769683113694728050679065883833405277752115728996190840108969869379084719724692936661399101308305488122720765422542730622039300422916786165849637632587189190381392313844372984510005250055208960000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 2141269959675448821805152883917149512155291442488512815294734190313068177386124283690519084059439228114311136956513810950918275352942919343266347022963287630962226543456368161498747269031778247468257595753102065075473431032668956469224598019516042200486078076713697280000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 144052302997934854745993315709021934050281383204917337096251807954209624972681474911242459364756897479336745640053920620229400176428107379073117781971756786759425485502304923946457565336715537781062082818294257854071397227396294182806054366130120024234114923735648567296000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 9175840996991866256799428551000136561675104552378398330942780715798047533437361743019776153934835006744027170451351573076215329318610744426918025957755873895447255691113575931818431249405841935684197632087548019870986840278226191001415302331311213835101370380945200880025600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 554362838232862330424221625374057830150658115709385049670218422943640670723422720623593743903212373126666000476895837900398879220816742839248293316932136557954370903197214375784077008741377853779752323898943715773632489335685300160077258699122645549582135567161824193156218880000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 31815723017193187476860322023787785380742028153934213824303893353337364497567611944348094066607782645608823524147084062615730117704230569300028758260892129398388403378424522275814078336372711227601382692621586639902183868697544622606783723205497317540162016375269123443176002027520000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 1737020315757775622464348435013743800505013766398504910638142385505938216019220134893685514854489053812164034889641344111718542469336510278734846259613038986924230226220119623750282799832898441521006158344581789787015454985595437093733043970542746438614028292840490842598197218508800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 90332711645142955350953056111319957842995734368757132430519764144051206235607761669195029389661101149913188190105042864715450524419725972049529074891922474770423195698496123604483575929660875835396366464456356309135688633332605889765033853835503734993464317687826108609765959071170560000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 4479971004921364933018428041289693946461322748947911943504575085834621022241109567816926189249209851574591359736550599694788098702820044292117787596815819165099015886113063834999359627927631595450316719463057305690550775132032514740955187097525455527630222711821589126587197368351850496000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 212111629658217229486100722670025762645673265928826534381529890360401525023648004402761172142536285230376068056027687804245693202133558597377507149101100609671037667435517256348806251143233419105311147909056067986283510009513691631985570027732332560848595089449321147138964345217501416652800000000000000000000000000000000000000000000000000000000000000000000000000000000000000, 9597150678875540980762465369141555780865915840433308943309084141625647421748046097623745751069567682615705095346506261973123953584957031835807340842023388334946571162816428076791470607143793664014032491914228268782461414675359343988563185149808697033901779939578948635059999918231398326992896000000000000000000000000000000000000000000000000000000000000000000000000000000000, 415338367881843673463425057826951637070752330522604780737764121189933855780807906337075732425719892272850028818916823802889680541171883151956613771672171179148885463326956018990610722643990450191170650482102012923308965008635440912556738752426268826231087205105013040521261841290581831929823232000000000000000000000000000000000000000000000000000000000000000000000000000000, 17206957506622843676602396732056720444572582213216368525077523791737610389794397080548196190209963362331766150345494047094951244828542186397804449915217048061624360169496453611748642033234889199897500584186315424166301074201289239463162466150919910736654139075727097481828811836566545917389727334400000000000000000000000000000000000000000000000000000000000000000000000000, 682933733290803197717296633249287168824160485375694844117917239394847516210206030834545291032032205415221917729039174860504781056184865997657215348462694653926094989533772689350834689171370692100783223694818951218290671227257863359151293445099501822241495611956473100848354271543323221382742136586240000000000000000000000000000000000000000000000000000000000000000000000, 25985302179787863270261887475533583775078653198869303773413873505613474326863947666146917571428949784361858981159945806586808910852415327097492606930217455461203921481066069025742126690301040780094934259664808000454599478599456595810240600697202569996558465131898087052539405932079833882070244195827712000000000000000000000000000000000000000000000000000000000000000000, 948480052421005286081939103522756624768821765119196626763604054683588935039821605159806676309736153035536716175815807827645234178382183161008612882978670786915179736698771710356974425242964533453708235591036939999780987806627632735729979714760253395397967207827714285346621888706796248492241083601906565120000000000000000000000000000000000000000000000000000000000000, 33230156605529894856147629948722008635610027106489992676501184884935552210754212668485187728119759043184405748748688796991054433606412177077984138109727893390194065362510240518483428453630327102046384766033423341253834709748445947469996095073505219980230562217449459610777495837874994710544134005249152122880000000000000000000000000000000000000000000000000000000000, 1118073878561386873819473192775261062479629641682741885942063298891549534665713588178839644115437387142819631275277091775534981461986469307614216895875896369130802332655276243409322082678469165784382753384177897743137969293301329614921517318033354278549479348055250814576025473868062705296957570664308550926336000000000000000000000000000000000000000000000000000000, 36145293594326141608978689781090504652515457539347343069850315703005415765663221260302961190391053468627717750380542307985992768857748183587934630358970610471496333610382702297407064898598733071467239556741513525986257794913562846374935325214427150713995941657708754405486890960768700260179464566853072169048473600000000000000000000000000000000000000000000000000, 1123222128865013704836178796419948716913073101370858249963257953059409747476132349004836056855185603494498057835975248524281773029472866548415810299315982774292880044955892111374035864439677214137035729990886374478088301502397231513063186759862034755494310732589621104385303647768734357071194679036872134939776122880000000000000000000000000000000000000000000000, 33564721410122029501368428992926592122985263913452894395708969090988941531947411650700664677190920602391478730459297192834592129652451059092301183955932686709373806927671729779966461012022909646724466876595744809804041988997806671380329874313315489175181705077122151436066375294603171665935555164514461991957618176819200000000000000000000000000000000000000000, 964844051671586695454579569037601461856115380362470539976421394097121879382820127992656287635221384893403170018778612799200529393368876175881742734977219054214759079828743759553983970652186955131929001558463432754374059255281314680164084196058925996957749596689509451802660215385604822633929545466496586958278252245811200000000000000000000000000000000000000, 26688502613998067671585536457133883359177065382564509723755061453482711452966639663550318627556330323075302166134264795624772882464558783374842789007740402738451692976223544307731573034394942998244562957660805686804108079626760936331565825545362847449538338618431748914290373330549531932098554576299110437691061981927178240000000000000000000000000000000000, 710566115854874108717374376549795279916419771012876605165132412622683458981745520696733203295400751467952788065698364695145300714632514211774667480976113340991947951200659524786095011742917471636364020968753227331467531449606870642836704153104706108354256740810729278891067988866521681211263600072015144133832503282571935744000000000000000000000000000000, 18213888196167655315584382616269600915968928838433731923704908610988981048160686766735850157873253212879878270308094188169918542344166865683404164393095284747354572877693190786299798308775095181148091502908039221596876018877630153605657942656013788759351637265430084280975162232983565726335236252087529862105341410199022547763200000000000000000000000000, 449581501154003715295770866609639330823827506639406592325354710181287571897616162850124320949790155074850001998694211239095501118771130545074313455907160858421322385108443117485768745748371887187578458075205159584779000585957511454742505003791835390244732025911494691780838386124182311494155343993621103030526720975703149564133376000000000000000000000, 10688012975004148145525200098741765926874584553357951842835320348513492552849571621743438303788115048326125734301621534161775614373155479345116361032100064264699433576341463830456328762157139263204894182982192024574201621883917088565498021636856822477150690980265787669903167772715742463479433461988251631950812718472731701467414528000000000000000000, 244753721440681366608158646369944297952085301311987064273339954498540874340911742957749563634287789354271669039343618287953907269535238947122382766848807701604126192134578606225121496311280356192033928625051116814616357821232562723101792871573742644079657792159771111948539036643255678517737090240641166777055359539266195079602739609600000000000000, 5399488070382238334749842349377958935643555081036030108967212387929818001508659282163672109852080687186122191855662927598549278810106086850413588732504754018844907090220000633887266751464869485033986389797734539708403772590044440389793752516966944673232290557034280146380926522887738121676742145264370318129957099208064437561812645314560000000000, 114762590489932884067643397100572869297905900022674228927392452157265729023619791486583966728438115602365958205107957220736912922819784252727800322882262201249064095474213177174187956409419741847624335372087610983972880514263180939919160743434282220943949694731875894783789747743827868113991299515084220353590601706347081329876814778073088000000, 2350133998545737491916582277177075124455985686303566401622752040702072236237468083305722209524763125961486738602296092900597423461063922416482847219047461790660664724509481100857289862673319784430946805152309376305841003175108255328292358812365146924267052200974306371298245783998086603523863547039559181712580753523222533751923429039329509376, 46369894357635263156440630227321561035265498896009816750879180674215693654365548032447828450289540005808532913789207365558641859571332274178896241061733143879850905467547352609682861562793910793875842312723614759476686473271464426096711402925630142144692907469411461170623995514777343181126103990377004491608421775054083948009914723257548800, 881503646606368187046671503545434585788510535358504571583498883203185470941249967011792054058231123098283034138783642970000444803043373079129197394168424473386567162410538089608227784996851329913287925668281067101497736318100779301736042293367425111182901272988140396957362674439296769995492161389721162955094903572036771870252870506905600, 16144945925823545875910580010399629264756167941115922443345007770252575629544770792117938927693450844900904878106268612874967420183257677316509418981966558544246806979829934370601317576026973884499030917287658762153174812821509907285291435862266989635231938334643355187667661318995350617698461286168599733660581444759378229605202237849600, 284865612649300095227659585822481070858676387217131738218625303947036170163953003620975696083625346889916325435188549629994586040426592867373236502483536352997078995669047774981582798856732786708045171402222201546612569593322647145849935661916545116594572660142746900781860106958426373371238162449704355404127878206359701049261739212800, 4841581548357659055743947051119650920210540246298546491203752706080949380402684171927539968021449800396655715348528221992243102252606322295854158367473985735920330510252142187008826182736979760770939599997235268171478038496021745930391622944160183561383837946294807060800708600438882290668211368867485394325548044080741251370723573760, 79253280551921813579652778346882260403429077040843284523916180968943030875196526241405535103407827562261821320236617385614485053933595641405840282457553833695241466710386338905831547935196620662004089774325578363454870999562165193796417271342478708856667810071136109687316481459547261893608271269178584186258914077397314157359923200, 1249265766454375731494969065253406468873564709045741328722418432005292437910239866845970677930197167947185386468943807505462635352915564092354364577299831528252741114652447471373036449681185269529572976399655166559671748566611695480499566444830288277251099881559818567007231042404450872564052985934486068267718677733508576077414400, 18958776941204855942991004913404375483760270339974075720818254945941387118302626559986001644837451727487599409695419717799418553398863843075780236097022623955247913987418314278967992407732408428932734837475740149016585310076693583227020438280155246624323172113177611232991641602384370078702873408457544266369860579884911715942400, 276935733002715306654044740983251994849546231152973614801202545834942557926931198824597467156504525461825352502010198697924061142876338556205293936551921833813026500204546594236227734275200218008213287252373027828443459988606295007672571887337232961967737849265148569185338977793592400032077329298367508656504988727101305651200, 3892608109689358246812973107144954761133122070143642533872527579786862992349392625375556940150573847367688760716174922590963891223370950342838976640066182775332612622640963900342035207458389752764500350415428252095628107609682059981458134071712332652673179351828625037468154380648006544155240471695139236205033648688117841920, 52633112228233519297473168996002382756380645264464717746123498744203323372060700154839717754183464514236537475758790695522614859496707510035978807410725521903251630323467643543094362738388679123284142678232856092974531164743715346618999817830187293060311120818460107339580800655374499187940651114805392738412401691249868800, 684354173614939446270800761873275571418015545680103536604054350788282677872795424008566354718937321766976377080159197920476810763513879013097251427662112518777704122419879649002424620921527538774440047680811267536720826691040795394865324877829912840535567529156224503052273429033926818156233758682561071409602980583833600, 8553333944147820514077474261778210990655053103260841224020385929775900302327380395754073940533148637394283691989172143823632726918186037545480770530981997891343079241183522334452419274451334499566627314773462739684909537821946862976421720991663009819599813942217524387613553619268951132448163054976651139427235109273600, 102714812745726334288369908642781818323131481706827991406560254572904451917831500328696794908578418839059128818523330896168203882901929598183118356113526842217309762193171202404766552704140528237113794366236116593844658354233402159687438402700674614636689009947989836462931064460322046547687087618049572142190480588800, 1184580709424464029490357114266626017133986205592346687248800742302173683228346093563686083398709874126292804054775020233046617911498622668175236917181060358280025781073154550828258001012807555402955238296690562212319900008673902507766986623754902988334614817239854941080867978705210538935632346236367064584547205120, 13112937448365797936320996270680566076301163571831863175865321295088331209008679129039830498066960853161701280642495278335227042910319692261625501498308769995415307041011456051799219685858171083424202463870416174873891883838191418408386743081201863655068425699926190200580793500507262661396838249496909333082931200, 139247224242987707521572411988387754522187257317861714701732297831738482489102975013637941238783739262298506310406225961911378188145984344801661838096608034048107366869902637536564292086283021829327471097940224332826263645756069292476954230715007861267684114800610654181519153201065161381411400947622081881702400, 1417580829452898129775471592285976470898584822177454204620067975938587786850243565165097400691588681725746146344494982358428286389353815051944332088911812117414786294649254704835271015004517873305982843887800016825079548639897306911818883718084044758794592329978246986565403661558717738745841356148587259494400, 13825522738621030519250274564719881478204887996875573788718999872219432577622840285427160774209124828639566509547840590265390637260185492831740120763349534699267965527204691957494528869930753485341751106406627644478832853223749002480283301566718122275569127677257814392910448945610817505715210634891834163200, 129079592574172774025249253935088172303509052813786537138435537797427472487315282387854629404748010916660220499050818795211401288323469619927924689205042666907896308280741515367590583719301220572604952719605381250985015123780794310962532479750501363542012770441917522694336825280640193022888500272258088960, 1152697939346053562687090088811435896651693309005151725805572197435265535973788065710718529535613833670939972986428296947393010822454334325353089904549991620307263040377158315361133114447368126029170038942158264018601967669184820544111225988078860428013554572770442179310112143150591432449412177906892800, 9836984858829212799675617821462001172836397574972059729991032121543356319194971347095506064901842472764832585710890952112803330499586889364061060072924711896326225894900571227652865779767402065880884125710468472258029676149576850513368127000012565762067216619266046453036794868765026956530406758809600, 80143371884635385907285836527558231299459574834175201383105302823737191715004176144277836694824746507594887703542882214086313485784233050419472275949093762884225794928536892322796375614449108280070134886204751785239633807039583642833345779689508207521916237792119778894206317535246260556451649945600, 622677574228927237952623402917760265891146431142711356763752060344122306455246199756376363735529362657555925814459443351132309891468650694613888098269325652590213423963882377619900689383574869450316750752948309791429740758013699983526212842683744960640764100202362447265047432822749807309016268800, 4608248471410756768021268652760953495183124017726529898088197270565557535032097719985388223199687461700863685304486518619603285385958446648241402113965084584837824897722020313036664525804996984271084482394576141264983056916111775780412794506866967779412224831599014277041302139361234564522442752, 32443220918364242145316128248085618864157999413262303406392265478182175062232230877630287858976147405821415863879409142625593611903555030294666783419100322226509531559365808445415401326739212694368383342337618658332439353499322604403759227067328603293303357235660169468604529733581373492428800, 216975899352643187080824969482437631384781299010987900309358178037763674421905849412149151729194522822055553711093789999965306408817717307951240103307645058112538084950563763753781592628607447439623237242176180087170835310088662200260357939244739751353471926048706837438021902534983653785600, 1376326865689217000834000032791896729561438199069598542207141635557250355872123194367370496688331260335147056643705893787388933047928700259086648293902621029555011255000529464728627625054626727734516585127438103041124879885108869969444453619028757462481805365865130989966948492272834969600, 8266250640038554569731592054446897142129085210220718824444122285945407398314392944884824309110096319356402730649138205760977449207678967384192162076312304596399340341143605225159108437827527514959650824339964265641731976093711244124005934368383334736002734667457857402140256866454732800, 46918996949433175364382124701434264895731675445548898282655242361524809301681930880127454370813996858023470439267859832212910373187520552488623369673564068488659065564405411602802908143613258429459967792023167135614437887129755186607677654189464551797576664239710467564595961617448960, 251147653681517584369352748755590948507579417471686273830894719788503847639224666189980376148664701146886161796334957154255821432090656236745240365584715907618929578895176073882815286592510879176481641417719001645926199542663897731786055054747985154434871812594212629494537335603200, 1264836118279404835229555452577738824792950966811395899136444557376175729896786371334547135829554086139952983993960306934922811243820331789971130366887207436848013581768900265606476523776911623408572699895436100617775691297770968615183781432739861208358512314957868360609982054400, 5977638084732975547727333419867767900958635505188496025155517631479635863663604377109165149460996240211972370917057210051948663243476623193965084773545068519093970090038116575194968615596229577138747655446310355019712244906658177874080272077761225988071791846844439527319142400, 26432704961343711730949844032192259418447119186950821883808513113552894665043228005087109166653855983338493771582713469910988841740467720941778435274567518519840324283857794041179083921957435029496210202784018458164649194924720473483708309236919689804047723451577219101491200, 109001514534072721256855908495561965634665703428270676730535251082517899097529928462740962383703195634049038876064926383787469280415316286843733158942925436657770800994731250998145531191233794507912750142133371693381098411888532494764533597906489169769679564586500615045120, 417608258497404689862282199034242154724663582927989152596987132120423225032108409974943469250066533845713223592211173453968864475207961110145170443527285635837293869039714233426895376207961779214611931632291220412207354523115493537918519629623546775211068471261318348800, 1480069468749038333693151274416436711146632194847289880458384661634013913773482059720038847961371597269143940364999360173765840123833440299717740974687158727384691728675252418217011114216619449650363952738020902206301867115137296464275741047552321044409387207727513600, 4828524329436815201624281340027288916809895603826136012995886413521115498005123571180888314123415232187291566731601451206213697297227774982502105371135906396923922073782138643440438513433950834099406149116744814153917152162180829312676738921549206793104102365593600, 14416236723551142214882786539911373069871484578603222352788198194516075852504056843118509470003856241261255455313478640334596596568741743587838092661309076684603040550024233512507053667632089577430741734026854906127015566872493889794100109563392426203308412108800, 39122843229544953388417590784862119904299387807240486273245274941193051735886204932589847605200926075639357784393846952608412677126919475372633905477203769302370156746942537353305673553657195839352069341485067782336912935583800030405756743414574924077906001920, 95721000519948078785702763771273621970418751267721813431598195960220964215844545680352286494717759346625652312193279800882849747029735466828935930149369410848816067458146935970705571584358991142125439779202521052344506786544697419075884280575174824375091200, 209063455312792163689308430274608026567407757152432222502873603238734318498366395733095200015345686597092787328757981244699149073774122830969706104610650683234109084242464934444330270523678166408780502194492658955728047106656172280134628154249687590502400, 402631568460861144806333894853629215179152343164703069157007150031759814834133463557957832135043576170051957782367416266215693735267613151221651467759741694908736824435299594397515854443514237072769001849304586705047719574047071975675645392207242854400, 673156293845671876970883669420633280526421502964999487077140095275823301449566799402547665751350330720132601519451599749998806752295083096942634757576868028188499195704135943056299532118655264052785022513416309160075378154741472044698832483570483200, 957206964599208360547788538063713500494547499450437279294670208623342062893468151383227244163038575956843403801747825407694366371241273198066735668756603821501423920681330648081868447110902417349286357015243716009240746235042886147266781268213760, 1125643411355580321652986919732328699524252602099593855062335376046518687952459976412498083257623014708927817963813668674421160159849427991325143233708337346269096990171198061292306018779189789187708008582122708294253448260911875356391371372800, 1051063942266861518986585577191329692920988776406204260492317327513377152127345895555141185841776691507719735070232107717084913525381595709689790039992559523797829058730790643155779565766030851198395061559340339757349409441893498581081689600, 730665363378038021631599011680366644107974128286871657477697660430697022106260430752005192470223783888072077570440283113984990632105700238859919916126961080936455578754871187353796593038569668792651777294876178715458274812724634695565600, 336180432292739331082969074511963714795825446932433151923900170458942754088653579706619300001559566981168990149469764699981302610069603335698867001244506535309585284539931438554229634750112399141153453611059920891108930107840000888800, 76790525741798814147739722024656541832379779544942834289320631222830128631361412260809504936077081989500262901451426968889209388663740890500544689219073462496105913250053209678939046505133571429166135524105744097027866266597980001] +-- Kernel-checked expansion of the exact rational coefficient witness. +set_option maxHeartbeats 4000000 in +lemma hundred_integral : R 50 (99 / 100) (22 / 25) = hundredValue := by + unfold R + rw [integral_coefficients 101 (fun k => hundredCoeffs k / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) _ (by + intro t + simp [P, hundredCoeffs, Fin.sum_univ_succ] + ring)] + norm_num [hundredCoeffs, Fin.sum_univ_succ, hundredValue] + +end Sendov.PaperLegacy diff --git a/Sendov/Analytic/PaperRateDetails.lean b/Sendov/Analytic/PaperRateDetails.lean new file mode 100644 index 0000000..80654d4 --- /dev/null +++ b/Sendov/Analytic/PaperRateDetails.lean @@ -0,0 +1,145 @@ +import Sendov.Analytic.PaperHistoricalBounds +import Sendov.Analytic.PaperRayGeometry + +/-! +# Preserved paper rates (PO06, HI04, RA04) + +These statements retain quantitative outputs, not merely `T < B`. +The endpoint keeps its delta-dependent exponent. The two historical small-radius +ratios follow from the stronger accepted `T < 3/5` and bulk-116 bounds. The +missing low ray uses the existing rational polar bound and continuous polynomial +comparison; neither a degree table nor an assumed geometric estimate is used. +-/ +namespace Sendov.PaperRateDetails + +open PaperPolar + +/-- PO06: the original delta-sensitive rate, not just `4/(m+2)`. +In fact the logarithmic proof works for every positive `N*delta`. -/ +theorem endpoint_delta_rate {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (hlarge : 2 ≤ (((m : ℝ) + 2) / 2) * (1 - a ^ 2)) : + b a x ^ ((m : ℝ) / 2) ≤ + ((((m : ℝ) + 2) / 2) * (1 - a ^ 2)) ^ + (-(m : ℝ) / (((m : ℝ) + 2) * (1 - a ^ 2))) := by + have hD : 0 < (((m : ℝ) + 2) / 2) * (1 - a ^ 2) := by linarith + have hb := b_pos ha.le ha1 hx1 + have hlog := PaperGlobalPolar.log_mul_delta_le hm ha ha1 hx0 hx1 hr + have hlogb : Real.log (b a x) ≤ -c a x := by + have h := Real.log_le_sub_one_of_pos hb + unfold c + linarith + have hscale := mul_le_mul_of_nonneg_left hlogb hD.le + have hcombined : Real.log (b a x) ≤ + -Real.log ((((m : ℝ) + 2) / 2) * (1 - a ^ 2)) / + ((((m : ℝ) + 2) / 2) * (1 - a ^ 2)) := by + apply (le_div_iff₀ hD).mpr + nlinarith only [hscale, hlog] + have hmul := mul_le_mul_of_nonneg_left hcombined + (show 0 ≤ (m : ℝ) / 2 by positivity) + apply (Real.log_le_log_iff (Real.rpow_pos_of_pos hb _) + (Real.rpow_pos_of_pos hD _)).mp + rw [Real.log_rpow hb, Real.log_rpow hD] + calc + _ ≤ (m : ℝ) / 2 * + (-Real.log ((((m : ℝ) + 2) / 2) * (1 - a ^ 2)) / + ((((m : ℝ) + 2) / 2) * (1 - a ^ 2))) := hmul + _ = _ := by field_simp + +/-- The small-radius branch of both historical ratios uses a stronger modern bound. -/ +lemma small_radius_ratio {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (ha5 : a ≤ 1 / 5) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar m a x) : + PaperTaylor.budget m a x / (1 - a) < 3 / 4 := by + apply (div_lt_iff₀ (show 0 < 1 - a by linarith)).mpr + have ht := PaperHistoricalBounds.budget_lt_three_fifths hm ha ha1 hx0 hx1 hr + linarith + +/-- HI04, original uniform small-a ratio at degree 100000. -/ +theorem small_a_ratio_100000 {m : ℕ} {a x : ℝ} (hm : 100000 ≤ m) + (ha : 0 < a) (ha2 : a ≤ 1 / 2) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + PaperTaylor.budget m a x / (1 - a) < 83567 / 100000 := by + have ha1 : a < 1 := by linarith + by_cases ha5 : a ≤ 1 / 5 + · exact (small_radius_ratio (by omega) ha ha1 ha5 hx0 hx1 hr).trans (by norm_num) + have hm' : (100000 : ℝ) ≤ m := by exact_mod_cast hm + have hm0 : 0 < (m : ℝ) := by linarith + have haSq : 1 / 25 ≤ a ^ 2 := by nlinarith + have hma : (4000 : ℝ) ≤ (m : ℝ) * a ^ 2 := by + nlinarith only [mul_nonneg (sub_nonneg.mpr hm') (sq_nonneg a), haSq] + have hbound : 116 / ((m : ℝ) * a ^ 2) ≤ (83567 / 100000 : ℝ) * (1 - a) := by + apply (div_le_iff₀ (by positivity : 0 < (m : ℝ) * a ^ 2)).mpr + have hprod := mul_nonneg (show 0 ≤ 1 - a - 1 / 2 by linarith) + (show 0 ≤ (m : ℝ) * a ^ 2 by positivity) + nlinarith only [hprod, hma] + apply (div_lt_iff₀ (show 0 < 1 - a by linarith)).mpr + exact (PaperHistoricalBounds.budget_lt_bulk116 (by omega) ha ha1 hx0 hx1 hr).trans_le hbound + +/-- HI04, round3's small-a ratio, retaining its bulk-complement hypothesis. -/ +theorem small_a_ratio_10000 {m : ℕ} {a x : ℝ} (hm : 10000 ≤ m) + (ha : 0 < a) (ha2 : a ≤ 1 / 2) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hbulk : (m : ℝ) * a ^ 2 * (1 - a) < 116) : + PaperTaylor.budget m a x / (1 - a) < 106 / 125 := by + have hm' : (10000 : ℝ) ≤ m := by exact_mod_cast hm + have ha1 : a < 1 := by linarith + have hma : (m : ℝ) * a ^ 2 < 232 := by + have h := mul_nonneg (show 0 ≤ 1 - a - 1 / 2 by linarith) + (show 0 ≤ (m : ℝ) * a ^ 2 by positivity) + nlinarith only [h, hbulk] + have haSq : a ^ 2 < 1 / 25 := by + have h := mul_nonneg (sub_nonneg.mpr hm') (sq_nonneg a) + nlinarith only [h, hma] + have ha5 : a ≤ 1 / 5 := by nlinarith + exact (small_radius_ratio (by omega) ha ha1 ha5 hx0 hx1 hr).trans (by norm_num) + +/-- The missing continuous strip of RA04 has the same stronger product bound +already used above lambda=2/5. No numerical sampling is involved. -/ +lemma product_lower_low_ray {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hl0 : 1 / 5 ≤ lambda m a) (hl1 : lambda m a ≤ 2 / 5) : + 11 / 10 ≤ (lambda m a + 1) * x ^ 2 := by + have hlpos : 0 ≤ lambda m a := by linarith + have hb := PaperRayGeometry.b_le_lambda (by omega) ha ha1 hx0 hx1 hr + have hrat : lambda m a / (3 + lambda m a) ≤ lambda m a / 3 := by + apply (div_le_div_iff₀ (by positivity) (by norm_num)).mpr + nlinarith [sq_nonneg (lambda m a)] + have ha' := PaperRayGeometry.a_lower hm ha1 (show lambda m a ≤ 1 by linarith) + norm_num at ha' + have hx := PaperRayGeometry.x_lower_constant (by norm_num : (0 : ℝ) < 255 / 256) + ha' (show 0 ≤ lambda m a / 3 by positivity) (hb.trans hrat) + have hxlin : 1 - 128 / 765 * lambda m a ≤ x := by + convert hx using 1 + ring + have hx2 : 1 - 256 / 765 * lambda m a ≤ x ^ 2 := by + nlinarith [sq_nonneg (x - 1)] + have hmul := mul_nonneg (show 0 ≤ lambda m a + 1 by positivity) + (sub_nonneg.mpr hx2) + have hquad := mul_nonneg hlpos (sub_nonneg.mpr hl1) + nlinarith + +/-- RA04's exact round5 lower formula, on the full original first ray. -/ +theorem scaled_budget_paper_lower_one {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hl0 : 1 / 5 ≤ lambda m a) (hl1 : lambda m a ≤ 1) : + (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ≤ + (m : ℝ) * x ^ 2 * PaperRayGeometry.B m a := by + have hp : 11 / 10 ≤ (lambda m a + 1) * x ^ 2 := by + by_cases hl : 2 / 5 ≤ lambda m a + · exact PaperRayGeometry.product_lower_one hm ha ha1 hx0 hx1 hr hl hl1 + · exact product_lower_low_ray hm ha ha1 hx0 hx1 hr hl0 (by linarith) + apply PaperRayGeometry.scaled_budget_lower + have hdiv : 0 ≤ 8 / (m : ℝ) := by positivity + linarith + +/-- RA04 on the entire original first ray, including the formerly missing +`[1/5,2/5)` strip: a lower bound on the actual available budget from raw polar. -/ +theorem scaled_budget_lower_one {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hl0 : 1 / 5 ≤ lambda m a) (hl1 : lambda m a ≤ 1) : + 1 + 18 / (m : ℝ) < (m : ℝ) * x ^ 2 * PaperRayGeometry.B m a := + (PaperRay.ray_one (by exact_mod_cast hm)).trans_le + (scaled_budget_paper_lower_one hm ha ha1 hx0 hx1 hr hl0 hl1) + +end Sendov.PaperRateDetails diff --git a/Sendov/Analytic/PaperWideRays.lean b/Sendov/Analytic/PaperWideRays.lean new file mode 100644 index 0000000..835e173 --- /dev/null +++ b/Sendov/Analytic/PaperWideRays.lean @@ -0,0 +1,210 @@ +import Sendov.Analytic.PaperRayGeometry +import Sendov.Analytic.PaperTail + +/-! +# Historical quantitative bounds on wide rays + +The conclusions concern the actual `PaperTaylor.budget`, under `RawPolar`. +They preserve HI01--HI03, not just the later conclusion `T < B`. + +Sources: first-origin-uniform/REPORT.md §4.3; round3/REPORT.md §3; +round4/REPORT.md §5. The lower lambda cutoffs are retained in the historical +interfaces, although the upper estimates themselves do not need them. +HI01 follows from the sharp Laplace estimate on the *whole* lambda <= 400 +band, including lambda < 1/10. No appeal to a whole-domain D theorem is made. + +Numerical certificates are fixed rational Taylor sums at two endpoints. +Uniformity in degree comes from generic exponential-polynomial monotonicity. +-/ +namespace Sendov.PaperWideRays + +open PaperPolar + +/-- Generic endpoint certificate, with arbitrary real cutoff and coefficient. -/ +lemma tail_certificate {m M r A C : ℝ} {n : ℕ} + (hM : 0 < M) (hm : M ≤ m) (hm1 : 1 ≤ m) + (hr : 0 < r) (hr1 : r ≤ 1) (hA : 0 ≤ A) (hn : 1 ≤ n) + (hcrit : (n : ℝ) ≤ (1 - r) / 2 * M) + (hbase : A * M ^ n < C * Real.exp ((1 - r) / 2 * (M - 1))) : + A * m ^ n * r ^ ((m - 1) / 2) < C := by + have hmono := PaperTail.power_exp_antitone (d := 1) hn hM + (show 0 ≤ (1 - r) / 2 by linarith) hcrit + (show M ∈ Set.Ici M by simp) hm hm + have hpow := mul_le_mul_of_nonneg_left (PaperTail.rpow_le_exp hr hm1) + (show 0 ≤ A * m ^ n by positivity) + have hbound : A * m ^ n * r ^ ((m - 1) / 2) ≤ + A * M ^ n * Real.exp (-((1 - r) / 2) * (M - 1)) := by + have h := mul_le_mul_of_nonneg_left hmono hA + dsimp at h + nlinarith only [hpow, h] + apply hbound.trans_lt + rw [show -((1 - r) / 2) * (M - 1) = -((1 - r) / 2 * (M - 1)) by ring, + Real.exp_neg] + exact (div_lt_iff₀ (Real.exp_pos _)).mpr hbase |>.trans_eq (by ring) + +/-- The complete right tail of the lambda <= 400 estimate. -/ +lemma tail_10000 {m : ℝ} (hm : 10000 ≤ m) : + (m ^ 2 / 2 + m) * (99 / 100 : ℝ) ^ ((m - 1) / 2) < 1 / m := by + have he : (5001 / 10000 : ℝ) * 10000 ^ (3 : ℕ) < + Real.exp ((1 - 99 / 100) / 2 * (10000 - 1)) := by + have h := Real.sum_le_exp_of_nonneg + (by norm_num : (0 : ℝ) ≤ (1 - 99 / 100) / 2 * (10000 - 1)) 16 + norm_num [Finset.sum_range_succ, Nat.factorial_succ] at h ⊢ + linarith + have h := tail_certificate (n := 3) (C := 1) (by norm_num : (0 : ℝ) < 10000) + hm (by linarith) (by norm_num : (0 : ℝ) < 99 / 100) (by norm_num) + (by norm_num : (0 : ℝ) ≤ 5001 / 10000) (by norm_num) (by norm_num) + (by simpa using he) + have hc : (m ^ 2 / 2 + m) * m ≤ (5001 / 10000 : ℝ) * m ^ 3 := by + nlinarith only [mul_nonneg (sq_nonneg m) (show 0 ≤ m - 10000 by linarith)] + apply (lt_div_iff₀ (show 0 < m by linarith)).mpr + nlinarith only [mul_le_mul_of_nonneg_right hc + (Real.rpow_nonneg (by norm_num : (0 : ℝ) ≤ 99 / 100) ((m - 1) / 2)), h] + +/-- The historical 1/32 tail, uniformly for every real m >= 512. -/ +lemma tail_512 {m : ℝ} (hm : 512 ≤ m) : + (m ^ 2 / 2 + m) * (15 / 16 : ℝ) ^ ((m - 1) / 2) < 1 / 32 := by + have he : (257 / 512 : ℝ) * 512 ^ (2 : ℕ) < + (1 / 32 : ℝ) * Real.exp ((1 - 15 / 16) / 2 * (512 - 1)) := by + have h := Real.sum_le_exp_of_nonneg + (by norm_num : (0 : ℝ) ≤ (1 - 15 / 16) / 2 * (512 - 1)) 20 + norm_num [Finset.sum_range_succ, Nat.factorial_succ] at h ⊢ + linarith + have h := tail_certificate (n := 2) (by norm_num : (0 : ℝ) < 512) + hm (by linarith) (by norm_num : (0 : ℝ) < 15 / 16) (by norm_num) + (by norm_num : (0 : ℝ) ≤ 257 / 512) (by norm_num) (by norm_num) he + have hc : m ^ 2 / 2 + m ≤ (257 / 512 : ℝ) * m ^ 2 := by + nlinarith only [mul_nonneg (show 0 ≤ m by linarith) (show 0 ≤ m - 512 by linarith)] + exact (mul_le_mul_of_nonneg_right hc (Real.rpow_nonneg (by norm_num) _)).trans_lt h + +lemma exp_four_lt : Real.exp (4 : ℝ) < 68 := by + have he : Real.exp (1 : ℝ) < 11 / 4 := Real.exp_one_lt_d9.trans (by norm_num) + calc + Real.exp (4 : ℝ) = Real.exp (1 : ℝ) ^ 4 := by rw [← Real.exp_nat_mul]; norm_num + _ ≤ (11 / 4 : ℝ) ^ 4 := pow_le_pow_left₀ (Real.exp_nonneg _) he.le _ + _ < 68 := by norm_num + +/-- Convexity in alpha extends this single endpoint check to 0 < alpha <= 400. -/ +lemma fixed_400 : + (∫ t in (0 : ℝ)..1, Real.exp (400 * (-1 + (2 - 99 / 100) * t))) < 1 := by + rw [Sendov.integral_exp_eq' (by norm_num : (0 : ℝ) < 400) + (by norm_num : (99 / 100 : ℝ) < 2)] + norm_num + have he := exp_four_lt + have hp := Real.exp_pos (-400 : ℝ) + linarith + +lemma fixed_64 : + (∫ t in (0 : ℝ)..1, Real.exp (64 * (-1 + (2 - 15 / 16) * t))) < 1 := by + rw [Sendov.integral_exp_eq' (by norm_num : (0 : ℝ) < 64) + (by norm_num : (15 / 16 : ℝ) < 2)] + norm_num + have he := exp_four_lt + have hp := Real.exp_pos (-64 : ℝ) + linarith + +/-- Retained radius from a real lower degree bound and the actual lambda. -/ +lemma a_lower {m : ℕ} {a M L : ℝ} (hM : 0 < M) (hm : M ≤ m) + (ha1 : a < 1) (hl : lambda m a ≤ L) : 1 - L / M ≤ a := by + have hh := mul_nonneg (sub_nonneg.mpr hm) (show 0 ≤ 1 - a by linarith) + unfold lambda at hl + have hdiv : 1 - a ≤ L / M := (le_div_iff₀ hM).mpr (by nlinarith) + linarith + +/-- Actual endpoint and x bounds over the entire wide band. -/ +theorem geometry_400 {m : ℕ} {a x : ℝ} (hm : 10000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hl : lambda m a ≤ 400) : + 24 / 25 ≤ a ∧ 12 / 25 < x ∧ b a x < 99 / 100 := by + have hm' : (10000 : ℝ) ≤ m := by exact_mod_cast hm + have ha' := a_lower (by norm_num : (0 : ℝ) < 10000) hm' ha1 hl + norm_num at ha' + have hx := (geometry (by omega) ha ha1 hx0 hx1 hr).1 + exact ⟨ha', by linarith, PaperRayGeometry.b_lt_of_fixed (by omega) ha ha1 hx0 hx1 hr hl fixed_400⟩ + +/-- The full lambda <= 400 estimate; no artificial lower cutoff is needed. -/ +theorem scaled_budget_lt_400 {m : ℕ} {a x : ℝ} (hm : 10000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hl : lambda m a ≤ 400) : + (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 1 + 46 / (m : ℝ) := by + have hm' : (10000 : ℝ) ≤ m := by exact_mod_cast hm + obtain ⟨ha', hx, hb⟩ := geometry_400 hm ha ha1 hx0 hx1 hr hl + have h := PaperLaplace.sharp_laplace (by omega : 7 ≤ m) (by linarith : 1 / 2 < a) + ha1 hx0 hx1 hr (by nlinarith : 1 - 3 * x ^ 2 / 4 ≤ (99 / 100 : ℝ)) hb.le + have hmain := PaperTail.laplace_main_lt (K := 45) (by linarith : (256 : ℝ) ≤ m) + (by norm_num : (0 : ℝ) < 12 / 25) hx.le (by norm_num) + have ht := tail_10000 hm' + have heq : 45 / (m : ℝ) + 1 / m = 46 / m := by ring + linarith only [h, hmain, ht, heq] + +/-- HI01: the exact historical constant, on its original closed lambda band. -/ +theorem HI01 {m : ℕ} {a x : ℝ} (hm : 100000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (_hl0 : 1 / 50 ≤ lambda m a) (hl1 : lambda m a ≤ 400) : + (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 5011 / 5000 := by + have hm' : (100000 : ℝ) ≤ m := by exact_mod_cast hm + have h := scaled_budget_lt_400 (by omega : 10000 ≤ m) ha ha1 hx0 hx1 hr hl1 + have hsmall : 46 / (m : ℝ) ≤ 46 / 100000 := by + apply (div_le_div_iff₀ (by linarith) (by norm_num)).mpr + linarith + linarith + +/-- HI02: the exact historical O(1/m) bound, not a statement of D. -/ +theorem HI02 {m : ℕ} {a x : ℝ} (hm : 10000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (_hl0 : 1 / 10 ≤ lambda m a) (hl1 : lambda m a ≤ 400) : + (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 1 + 46 / (m : ℝ) := + scaled_budget_lt_400 hm ha ha1 hx0 hx1 hr hl1 + +/-- HI03: the whole historical band through lambda=64 with its 1/32 tail. -/ +theorem HI03 {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (_hl0 : 5 ≤ lambda m a) (hl1 : lambda m a ≤ 64) : + (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 1 + 53 / (m : ℝ) + 1 / 32 := by + have hm' : (512 : ℝ) ≤ m := by exact_mod_cast hm + have ha' := a_lower (by norm_num : (0 : ℝ) < 512) hm' ha1 hl1 + norm_num at ha' + have hb := PaperRayGeometry.b_lt_of_fixed (by omega : 0 < m) ha ha1 hx0 hx1 hr hl1 fixed_64 + -- Retain the endpoint information also in the x lower bound. This permits + -- reuse of the existing general Laplace constants without a new cube bound. + have hx' := PaperRayGeometry.x_lower_constant (by norm_num : (0 : ℝ) < 7 / 8) + ha' (by norm_num : (0 : ℝ) ≤ 15 / 16) hb.le + have hx : 9 / 20 ≤ x := by norm_num at hx'; linarith + have h := PaperLaplace.sharp_laplace (by omega : 7 ≤ m) (by linarith : 1 / 2 < a) + ha1 hx0 hx1 hr (by nlinarith : 1 - 3 * x ^ 2 / 4 ≤ (15 / 16 : ℝ)) hb.le + have hmain := PaperTail.laplace_main_lt (K := 53) (by linarith : (256 : ℝ) ≤ m) + (by norm_num : (0 : ℝ) < 9 / 20) hx (by norm_num) + have ht := tail_512 hm' + linarith only [h, hmain, ht] + +/-- HI03's first retained small-ray band, including both seams. -/ +theorem HI03_small_one {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (_hl0 : 1 / 10 ≤ lambda m a) (hl1 : lambda m a ≤ 1) : + (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 1 + 18 / (m : ℝ) := by + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast (show 256 ≤ m by omega) + have hx := PaperRayGeometry.geometry_one (by omega) ha ha1 hx0 hx1 hr hl1 + have hb := (PaperRayGeometry.geometry_ten (by omega) ha ha1 hx0 hx1 hr + (by linarith : lambda m a ≤ 10)).1 + have ha' := PaperRayGeometry.a_lower (by omega) ha1 hl1 + have hb' : PaperTaylor.beta a x 1 ≤ 4 / 5 := by + simpa [PaperTaylor.beta, b] using hb.le + exact PaperTail.budget_region_one hm' ha ha1 hx hx1 (by linarith) hb' + +/-- HI03's second retained small-ray band; the available 33/m is stronger. -/ +theorem HI03_small_five {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (_hl0 : 1 ≤ lambda m a) (hl1 : lambda m a ≤ 5) : + (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 1 + 34 / (m : ℝ) := by + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast (show 256 ≤ m by omega) + obtain ⟨hb, hx⟩ := PaperRayGeometry.geometry_ten (by omega) ha ha1 hx0 hx1 hr + (by linarith : lambda m a ≤ 10) + have ha' := PaperRayGeometry.a_lower (by omega) ha1 hl1 + have hb' : PaperTaylor.beta a x 1 ≤ 4 / 5 := by + simpa [PaperTaylor.beta, b] using hb.le + have h := PaperTail.budget_region_two hm' ha ha1 hx hx1 (by linarith) hb' + have hc : 33 / (m : ℝ) ≤ 34 / m := + div_le_div_of_nonneg_right (by norm_num) (by positivity) + linarith only [h, hc] + +end Sendov.PaperWideRays diff --git a/docs/paper-formalization/checkpoint5.json b/docs/paper-formalization/checkpoint5.json new file mode 100644 index 0000000..33b49dc --- /dev/null +++ b/docs/paper-formalization/checkpoint5.json @@ -0,0 +1,8 @@ +{ + "gates": 40, + "compile_gates": 20, + "kernel_gates": 20, + "seconds": 598.3440327788703, + "interruption": "Initial outer tool timed out at420 seconds; exact accepted source retained and remaining gates resumed successfully.", + "full_replay_pending": true +} \ No newline at end of file diff --git a/docs/paper-formalization/generator-replay.json b/docs/paper-formalization/generator-replay.json new file mode 100644 index 0000000..937fc66 --- /dev/null +++ b/docs/paper-formalization/generator-replay.json @@ -0,0 +1,5 @@ +{ + "generators": 2, + "files_byte_identical": 8, + "changed": [] +} \ No newline at end of file diff --git a/docs/paper-formalization/modules.json b/docs/paper-formalization/modules.json new file mode 100644 index 0000000..39ed56c --- /dev/null +++ b/docs/paper-formalization/modules.json @@ -0,0 +1,181 @@ +{ + "baseline": "0a4e966c41e1287f92d305d3bad8e70c8c295dde", + "source_tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "changed_seeds": [ + "Sendov", + "Sendov.Analytic.FirstOriginAlgebra", + "Sendov.Analytic.FirstOriginBounds", + "Sendov.Analytic.FirstOriginBudget", + "Sendov.Analytic.FirstOriginMargins", + "Sendov.Analytic.FirstOriginSmall", + "Sendov.Analytic.PaperBulkAlgebra", + "Sendov.Analytic.PaperCentered", + "Sendov.Analytic.PaperCenteredBound", + "Sendov.Analytic.PaperCenteredCertificate", + "Sendov.Analytic.PaperCoefficient", + "Sendov.Analytic.PaperConjugate", + "Sendov.Analytic.PaperConsequences", + "Sendov.Analytic.PaperGlobalPolar", + "Sendov.Analytic.PaperHistoricalBounds", + "Sendov.Analytic.PaperLaplace", + "Sendov.Analytic.PaperLegacyExact", + "Sendov.Analytic.PaperLegacyHelpers", + "Sendov.Analytic.PaperLegacyHundred", + "Sendov.Analytic.PaperNear", + "Sendov.Analytic.PaperNearAlgebra", + "Sendov.Analytic.PaperNearMargins", + "Sendov.Analytic.PaperPolar", + "Sendov.Analytic.PaperRateDetails", + "Sendov.Analytic.PaperRayAlgebra", + "Sendov.Analytic.PaperRayGeometry", + "Sendov.Analytic.PaperSecant", + "Sendov.Analytic.PaperTail", + "Sendov.Analytic.PaperTaylor", + "Sendov.Analytic.PaperTwoEnd", + "Sendov.Analytic.PaperUniform", + "Sendov.Analytic.PaperWideRays", + "Sendov.Boundary", + "Sendov.Collinear.Balance", + "Sendov.Collinear.Diameter", + "Sendov.Collinear.Gate", + "Sendov.Collinear.Mass", + "Sendov.Collinear.Moment", + "Sendov.Interior", + "tests.BoundaryAudit", + "tests.BoundaryContracts", + "tests.BoundaryProbe", + "tests.BoundaryWiring", + "tests.CollinearAcceptance", + "tests.CollinearRound2Tests", + "tests.CollinearTests", + "tests.FirstOriginAudit", + "tests.FirstOriginBudget", + "tests.FirstOriginMargins", + "tests.FirstOriginWiring", + "tests.Localanalytic", + "tests.PaperBulkAlgebra", + "tests.PaperCentered", + "tests.PaperCenteredBoundTests", + "tests.PaperCenteredHundred", + "tests.PaperCoefficientTests", + "tests.PaperConjugateBudgets", + "tests.PaperConjugateDI03", + "tests.PaperConjugateDI04", + "tests.PaperConjugateDI05", + "tests.PaperConjugateDI06", + "tests.PaperConjugateDI07", + "tests.PaperConsequencesTests", + "tests.PaperGlobalPolarTests", + "tests.PaperHistoricalBoundsTests", + "tests.PaperLaplace", + "tests.PaperLegacyCertificates", + "tests.PaperNear", + "tests.PaperNearAlgebra", + "tests.PaperNearMargins", + "tests.PaperPolar", + "tests.PaperPolarCounterexample", + "tests.PaperPolarDomainWitnesses", + "tests.PaperRateDetailsTests", + "tests.PaperRayAlgebra", + "tests.PaperRayGeometry", + "tests.PaperSecantNeighborhoods", + "tests.PaperSecantTests", + "tests.PaperTailTests", + "tests.PaperTaylor", + "tests.PaperTwoEndTests", + "tests.PaperUniform", + "tests.PaperWideRaysTests" + ], + "affected_modules_topological": [ + "Sendov.Analytic.FirstOriginAlgebra", + "Sendov.Analytic.FirstOriginBounds", + "Sendov.Analytic.FirstOriginSmall", + "Sendov.Analytic.PaperPolar", + "Sendov.Analytic.PaperTaylor", + "Sendov.Analytic.PaperNearAlgebra", + "Sendov.Analytic.PaperNear", + "Sendov.Analytic.PaperSecant", + "Sendov.Analytic.PaperGlobalPolar", + "Sendov.Analytic.PaperTwoEnd", + "Sendov.Analytic.PaperLaplace", + "Sendov.Analytic.PaperTail", + "Sendov.Analytic.PaperRayAlgebra", + "Sendov.Analytic.PaperRayGeometry", + "Sendov.Analytic.PaperBulkAlgebra", + "Sendov.Analytic.PaperUniform", + "Sendov.Analytic.FirstOriginBudget", + "Sendov.Interior", + "Sendov.Boundary", + "Sendov.Conjecture", + "Sendov.Collinear.Gate", + "Sendov.Collinear.Mass", + "Sendov.Collinear.Balance", + "Sendov.Collinear.Diameter", + "Sendov.Collinear.Moment", + "Sendov", + "Sendov.Analytic.FirstOriginMargins", + "Sendov.Analytic.PaperCentered", + "Sendov.Analytic.PaperCoefficient", + "Sendov.Analytic.PaperCenteredBound", + "Sendov.Analytic.PaperCenteredCertificate", + "Sendov.Analytic.PaperConjugate", + "Sendov.Analytic.PaperConsequences", + "Sendov.Analytic.PaperHistoricalBounds", + "Sendov.Analytic.PaperLegacyHelpers", + "Sendov.Analytic.PaperLegacyExact", + "Sendov.Analytic.PaperLegacyHundred", + "Sendov.Analytic.PaperNearMargins", + "Sendov.Analytic.PaperRateDetails", + "Sendov.Analytic.PaperWideRays", + "Solution", + "scripts.axioms", + "tests.BoundaryAudit", + "tests.BoundaryContracts", + "tests.BoundaryProbe", + "tests.BoundaryWiring", + "tests.CollinearAcceptance", + "tests.CollinearTests", + "tests.CollinearRound2Tests", + "tests.FirstOriginAudit", + "tests.FirstOriginBudget", + "tests.FirstOriginMargins", + "tests.FirstOriginWiring", + "tests.LocalMiddleAlpha", + "tests.LocalPeakClosure", + "tests.Localanalytic", + "tests.Localreduction", + "tests.NoFiniteRows", + "tests.PaperBulkAlgebra", + "tests.PaperCentered", + "tests.PaperCenteredBoundTests", + "tests.PaperCenteredHundred", + "tests.PaperCoefficientTests", + "tests.PaperConjugateDI03", + "tests.PaperConjugateDI04", + "tests.PaperConjugateDI05", + "tests.PaperConjugateDI06", + "tests.PaperConjugateDI07", + "tests.PaperConjugateBudgets", + "tests.PaperConsequencesTests", + "tests.PaperGlobalPolarTests", + "tests.PaperHistoricalBoundsTests", + "tests.PaperLaplace", + "tests.PaperLegacyCertificates", + "tests.PaperNear", + "tests.PaperNearAlgebra", + "tests.PaperNearMargins", + "tests.PaperPolar", + "tests.PaperPolarCounterexample", + "tests.PaperPolarDomainWitnesses", + "tests.PaperRateDetailsTests", + "tests.PaperRayAlgebra", + "tests.PaperRayGeometry", + "tests.PaperSecantNeighborhoods", + "tests.PaperSecantTests", + "tests.PaperTailTests", + "tests.PaperTaylor", + "tests.PaperTwoEndTests", + "tests.PaperUniform", + "tests.PaperWideRaysTests" + ] +} \ No newline at end of file diff --git a/docs/paper-formalization/round5-files.json b/docs/paper-formalization/round5-files.json new file mode 100644 index 0000000..49fedf8 --- /dev/null +++ b/docs/paper-formalization/round5-files.json @@ -0,0 +1,127 @@ +[ + { + "path": "Sendov/Analytic/PaperWideRays.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-wide-rays/Sendov/Analytic/PaperWideRays.lean", + "bytes": 10909 + }, + { + "path": "tests/PaperWideRaysTests.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-wide-rays/tests/PaperWideRaysTests.lean", + "bytes": 4453 + }, + { + "path": "Sendov/Analytic/PaperRateDetails.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-rate-details/Sendov/Analytic/PaperRateDetails.lean", + "bytes": 7193 + }, + { + "path": "tests/PaperRateDetailsTests.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-rate-details/tests/PaperRateDetailsTests.lean", + "bytes": 8450 + }, + { + "path": "Sendov/Analytic/PaperCenteredCertificate.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-centered-100/Sendov/Analytic/PaperCenteredCertificate.lean", + "bytes": 6603 + }, + { + "path": "tests/PaperCenteredHundred.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-centered-100/tests/PaperCenteredHundred.lean", + "bytes": 92902 + }, + { + "path": "scripts/generate_centered_hundred.py", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-centered-100/scripts/generate_centered_hundred.py", + "bytes": 4011 + }, + { + "path": "tests/data/di02-witnesses.json", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-centered-100/tests/data/di02-witnesses.json", + "bytes": 61695 + }, + { + "path": "Sendov/Analytic/PaperConjugate.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-conjugate-cases/Sendov/Analytic/PaperConjugate.lean", + "bytes": 8157 + }, + { + "path": "tests/PaperConjugateDI03.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-conjugate-cases/tests/PaperConjugateDI03.lean", + "bytes": 4861 + }, + { + "path": "tests/PaperConjugateDI04.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-conjugate-cases/tests/PaperConjugateDI04.lean", + "bytes": 6567 + }, + { + "path": "tests/PaperConjugateDI05.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-conjugate-cases/tests/PaperConjugateDI05.lean", + "bytes": 14683 + }, + { + "path": "tests/PaperConjugateDI06.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-conjugate-cases/tests/PaperConjugateDI06.lean", + "bytes": 143025 + }, + { + "path": "tests/PaperConjugateDI07.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-conjugate-cases/tests/PaperConjugateDI07.lean", + "bytes": 167306 + }, + { + "path": "tests/PaperConjugateBudgets.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-conjugate-cases/tests/PaperConjugateBudgets.lean", + "bytes": 4474 + }, + { + "path": "tests/generate_conjugate_budgets.py", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-conjugate-cases/tests/generate_conjugate_budgets.py", + "bytes": 6035 + }, + { + "path": "tests/conjugate-data.json", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-conjugate-cases/tests/conjugate-data.json", + "bytes": 3796 + }, + { + "path": "tests/CONJUGATE_BUDGETS.md", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-conjugate-cases/tests/CONJUGATE_BUDGETS.md", + "bytes": 3928 + }, + { + "path": "Sendov/Analytic/PaperLegacyHelpers.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-legacy-cases/Sendov/Analytic/PaperLegacyHelpers.lean", + "bytes": 7144 + }, + { + "path": "Sendov/Analytic/PaperLegacyExact.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-legacy-cases/Sendov/Analytic/PaperLegacyExact.lean", + "bytes": 13930 + }, + { + "path": "Sendov/Analytic/PaperLegacyHundred.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-legacy-cases/Sendov/Analytic/PaperLegacyHundred.lean", + "bytes": 36194 + }, + { + "path": "tests/PaperLegacyCertificates.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-legacy-cases/tests/PaperLegacyCertificates.lean", + "bytes": 10588 + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-polar-witnesses/tests/PaperPolarDomainWitnesses.lean", + "bytes": 13982 + }, + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-paper-corollaries/Sendov/Analytic/PaperConsequences.lean", + "bytes": 14145 + }, + { + "path": "tests/PaperConsequencesTests.lean", + "source": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914-paper-corollaries/tests/PaperConsequencesTests.lean", + "bytes": 4943 + } +] \ No newline at end of file diff --git a/scripts/check_paper.py b/scripts/check_paper.py new file mode 100644 index 0000000..1d4316c --- /dev/null +++ b/scripts/check_paper.py @@ -0,0 +1,53 @@ +"""Direct Lean checks with private project objects and baseline package cache.""" +import argparse +import json +import os +from pathlib import Path +import subprocess +import time + +p = argparse.ArgumentParser() +p.add_argument('tree', type=Path) +p.add_argument('module') +p.add_argument('--config', type=Path, required=True, help='Pinned Lean/cache environment JSON') +p.add_argument('--kernel', action='store_true') +p.add_argument('--tag', default='check') +a = p.parse_args() +a.tree = a.tree.resolve() +assert all(x.isidentifier() for x in a.module.split('.')) +config = json.loads(a.config.read_text()) +cache = a.tree / '.lake/paper' +objects = cache / 'objects' +rel = Path(*a.module.split('.')) +setup = dict(config['setup_template'], name=a.module, importArts={}) +setup_path = cache / 'setups' / rel.with_suffix('.json') +setup_path.parent.mkdir(parents=True, exist_ok=True) +setup_path.write_text(json.dumps(setup)) +env = os.environ.copy() +env.update(config['environment']) +parts = env['LEAN_PATH'].split(os.pathsep) +parts[parts.index(config['project_lib'])] = str(objects) +env['LEAN_PATH'] = os.pathsep.join(parts) +env['LEAN_NUM_THREADS'] = '1' +source = a.tree / rel.with_suffix('.lean') +output = objects / rel.with_suffix('.olean') +output.parent.mkdir(parents=True, exist_ok=True) +cmd = [config['leanchecker'], a.module] if a.kernel else [config['lean'], str(source), '-o', str(output), '-i', str(output.with_suffix('.ilean')), '--setup', str(setup_path)] +logs = cache / 'logs' +logs.mkdir(parents=True, exist_ok=True) +tag = a.tag + '-' + a.module + ('-kernel' if a.kernel else '') +start = time.monotonic() +try: + result = subprocess.run(cmd, cwd=a.tree, env=env, text=True, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, timeout=600) + text, code = result.stdout, result.returncode +except subprocess.TimeoutExpired as e: + text = e.stdout or b'' + if isinstance(text, bytes): + text = text.decode(errors='replace') + code = 124 +record = dict(command=cmd, exit_code=code, seconds=time.monotonic()-start, module=a.module, kernel=a.kernel, lean_path=env['LEAN_PATH'], options=setup['options']) +(logs / (tag + '.log')).write_text(text) +(logs / (tag + '.json')).write_text(json.dumps(record, indent=2)) +print(text, end='') +print(json.dumps(record)) +raise SystemExit(code) diff --git a/scripts/generate_centered_hundred.py b/scripts/generate_centered_hundred.py new file mode 100644 index 0000000..41f67fa --- /dev/null +++ b/scripts/generate_centered_hundred.py @@ -0,0 +1,92 @@ +#!/usr/bin/env python3 +"""Regenerate the bounded DI02 per-degree Lean arithmetic certificates. + +The Fraction/sqrt code is an untrusted witness generator. Each emitted +row proves the binomial values, squared envelope, and actual coefficient bound in +Lean. No generated numerical result is accepted as an axiom. +""" +from fractions import Fraction as Q +from math import comb, isqrt +from pathlib import Path +import json + +ROOT = Path(__file__).resolve().parents[1] + + +def coeff_bound_sq(m, k, v): + if k == m: + return v ** m + return Q(m ** m, k ** k * (m - k) ** (m - k)) * v ** k + + +def sqrt_upper(x, den): + assert x >= 0 and den > 0 + n = isqrt(x.numerator * den * den // x.denominator) + if Q(n * n, den * den) < x: + n += 1 + r = Q(n, den) + assert r * r >= x + return r + +DEN = 10**12 +rows = [] +witnesses = [] +for k in range(3, 101): + divisor = comb(100, k) * Q(7, 10)**k + sq = coeff_bound_sq(100, k, Q(9, 100)) / divisor**2 + envelope = sqrt_upper(sq, DEN) + actual = Q(0) if k % 2 else Q(comb(50, k//2)) * Q(3, 10)**k / divisor + rounded_actual = Q((actual.numerator * DEN + actual.denominator - 1)//actual.denominator, DEN) + expected_g = {3:410439009, 4:38153285, 5:3927325, 6:440942, 7:53400, + 8:6917, 9:952, 10:139, 11:22, 12:4}.get(k, 1) + expected_a = 0 if k % 2 else {4:10539189, 6:101883, 8:1409, 10:26}.get(k, 1) + assert envelope == Q(expected_g, DEN) and rounded_actual == Q(expected_a, DEN) + witnesses.append(dict(k=k, normalized_C_square=str(sq), envelope=str(envelope), + actual=str(actual), actual_envelope=str(rounded_actual))) + rows.append(f'''private lemma generic_{k} : C 100 {k} (9/100) / + (((100 : ℕ).choose {k} : ℝ) * (7/10)^{k}) ≤ (genericNumerator {k} : ℝ) / 10^12 := by + apply normalized_C_le 100 {k} (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose {k} = {comb(100,k)} := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] +''') + actual_proof = f''' rw [esymm_exact {k} (by decide)] +''' + if k % 2: + actual_proof += ' norm_num [actualNumerator]\n' + else: + actual_proof += f''' have hc : (100 : ℕ).choose {k} = {comb(100,k)} := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose {(100-k)//2} = {comb(50,(100-k)//2)} := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] +''' + rows.append(f'''private lemma actual_{k} : ‖r.esymm {k}‖ / + (((100 : ℕ).choose {k} : ℝ) * (7/10)^{k}) ≤ (actualNumerator {k} : ℝ) / 10^12 := by +{actual_proof}''') + +for kind in ['generic', 'actual']: + numerator = 'C 100 k (9/100)' if kind == 'generic' else '‖r.esymm k‖' + rows.append(f'''lemma {kind}_rows (k : ℕ) (hk : k ∈ Finset.Ico 3 101) : + {numerator} / (((100 : ℕ).choose k : ℝ) * (7/10)^k) ≤ + ({kind}Numerator k : ℝ) / 10^12 := by + obtain ⟨hlo, hhi⟩ := Finset.mem_Ico.mp hk + interval_cases k +'''+''.join(f' · exact {kind}_{k}\n' for k in range(3,101))) +assert len(witnesses) == 98 and len({w['k'] for w in witnesses}) == 98 +path = ROOT/'tests/PaperCenteredHundred.lean' +text = path.read_text() +start = '-- BEGIN GENERATED COEFFICIENT CERTIFICATES\n' +end = '-- END GENERATED COEFFICIENT CERTIFICATES' +assert text.count(start) == 1 and text.count(end) == 1 +path.write_text(text.split(start)[0]+start+'\n'.join(rows)+'\n'+end+text.split(end)[1]) +manifest = ROOT/'tests/data/di02-witnesses.json' +manifest.parent.mkdir(parents=True, exist_ok=True) +manifest.write_text(json.dumps(dict(degrees=98, denominator=DEN, + generic_sum=str(sum(Q(w['envelope']) for w in witnesses)), + actual_sum=str(sum(Q(w['actual_envelope']) for w in witnesses)), rows=witnesses), indent=2)+'\n') +print(json.dumps(dict(degrees=len(witnesses), lean=str(path), manifest=str(manifest)))) diff --git a/scripts/verify_paper_results.py b/scripts/verify_paper_results.py new file mode 100644 index 0000000..7336334 --- /dev/null +++ b/scripts/verify_paper_results.py @@ -0,0 +1,67 @@ +#!/usr/bin/env python3 +"""Bounded direct replay of the complete affected paper-proof module DAG. + +Package caches and pinned config are inputs. Private project objects must be +prepared first. No Lake build or dependency download occurs. Each completed +module records a source-bound receipt so an interrupted run can resume. +""" +import argparse +import hashlib +import json +from pathlib import Path +import subprocess +import sys + +TREE = Path(__file__).resolve().parents[1] +p = argparse.ArgumentParser() +p.add_argument('--config', type=Path, required=True) +p.add_argument('--tag', required=True) +p.add_argument('--resume', action='store_true') +a = p.parse_args() +config = a.config.resolve() +manifest = json.loads((TREE / 'docs/paper-formalization/modules.json').read_text()) +modules = manifest['affected_modules_topological'] +assert len(modules) == len(set(modules)) +logs = TREE / '.lake/paper/logs' +result_file = TREE / '.lake/paper' / (a.tag + '-receipts.json') +prior = json.loads(result_file.read_text()) if a.resume and result_file.exists() else [] +accepted = {(r['module'], r['kernel']): r for r in prior} +rows = [] + + +def digest(path): + return hashlib.sha256(path.read_bytes()).hexdigest() + + +config_digest = digest(config) +for module in modules: + source = TREE / Path(*module.split('.')).with_suffix('.lean') + source_digest = digest(source) + for kernel in [False, True]: + previous = accepted.get((module, kernel)) + if previous and previous['exit_code'] == 0: + assert previous['source_sha256'] == source_digest, 'source changed; use a new tag' + assert previous['config_sha256'] == config_digest, 'config changed; use a new tag' + rows.append(previous) + print(module, 'kernel' if kernel else 'compile', 'REUSED', flush=True) + continue + command = [sys.executable, str(TREE / 'scripts/check_paper.py'), str(TREE), + module, '--config', str(config), '--tag', a.tag] + if kernel: + command.append('--kernel') + result = subprocess.run(command, cwd=TREE, capture_output=True, text=True) + stem = a.tag + '-' + module + ('-kernel' if kernel else '') + record = json.loads((logs / (stem + '.json')).read_text()) + record.update(source_sha256=source_digest, config_sha256=config_digest) + assert digest(source) == source_digest, 'source changed during verification' + assert record['exit_code'] == result.returncode + rows.append(record) + result_file.write_text(json.dumps(rows, indent=2)) + print(module, 'kernel' if kernel else 'compile', result.returncode, + round(record['seconds'], 3), flush=True) + if result.returncode: + print(result.stdout + result.stderr, flush=True) + raise SystemExit(result.returncode) +assert len(rows) == 2 * len(modules) +result_file.write_text(json.dumps(rows, indent=2)) +print(f'PASS: {len(modules)} affected modules, {len(rows)} compile/kernel gates', flush=True) diff --git a/tests/CONJUGATE_BUDGETS.md b/tests/CONJUGATE_BUDGETS.md new file mode 100644 index 0000000..0b7c6a4 --- /dev/null +++ b/tests/CONJUGATE_BUDGETS.md @@ -0,0 +1,87 @@ +# DI03–DI07 exact conjugate budgets + +**Accepted: 5. Incomplete: 0.** + +| ID | m | a | x | Compile | Independent kernel | +|---|---:|---|---|---|---| +| DI03 | 6 | 9/10 | 49/50 | PASS | PASS | +| DI04 | 8 | 99/100 | 497/500 | PASS | PASS | +| DI05 | 20 | 9/10 | 83/100 | PASS | PASS | +| DI06 | 100 | 9/10 | 61/100 | PASS | PASS | +| DI07 | 100 | 99/100 | 22/25 | PASS | PASS | + +`tests/PaperConjugateBudgets.lean` exports `Budgets.DI03_closed` through +`Budgets.DI07_closed` and `Budgets.all_datasets_closed`. The latter proves +acceptance for every entry of the exact rational input registry; +`Budgets.dataset_count` proves its length is five. + +The common `Accepted` contract includes the actual family cardinality, all +pointwise norms equal to one, actual mean and centered variance, full complex +polar norm greater than one, literal `PaperCenteredBound.majorant_Efin + Gamma` +strictly below `1 - a * norm(mean)`, and the actual first-origin `norm J > 1`. +The full polar integral is evaluated exactly, not replaced by its AM–GM bound. +The m=8 exact integral and full-polar result are independently reusable as +`Sendov.PaperConjugate.DI04.polar_integral` and `.full_polar`. + +## Certificate method + +- `family n x` is the multiset containing n copies of each of + `x ± i * sqrt(1 - x^2)`; multiplicities are never erased. +- `PaperConjugate.variance_family` proves the actual centered variance is + `1 - x^2`; `budget_eq` binds the scalar arithmetic back to the literal PAPER + square-root definition. +- Compute each real B endpoint by one binomial recurrence, checked in Lean. + Retain `abs(1-B)` in every term, including k=m. +- Bound `sqrt(s) / d * abs(h)` by b using the exact rational certificate + `s * h^2 ≤ (b*d)^2`, with `s ≥ 0`, `d > 0`, `b ≥ 0` proved in Lean. + This eliminates the need for separately rounded square-root envelopes. +- All 224 finite-tail terms across the five families are checked. The chosen + per-term bounds are deliberately coarser than the research script's displays; + each final strict PAPER budget is nevertheless proved. +- Exact polynomial coefficients are generated, their expansions checked by + `ring`, and their finite integrals proved by `integral_coeffs`. + +The Python generator and `conjugate-data.json` are untrusted convenience data; +Lean does not read either. No new axiom, admission, native decision procedure, +or umbrella import is used. The 36 printed audit roots use only `propext`, +`Classical.choice`, and `Quot.sound`. + +## Files and replay + +Common helper: `Sendov/Analytic/PaperConjugate.lean`. +Generated certificates: `tests/PaperConjugateDI03.lean` through +`tests/PaperConjugateDI07.lean`. +Registry/contracts: `tests/PaperConjugateBudgets.lean`. +Generator: `tests/generate_conjugate_budgets.py`. + +Run the generator from this checkout, then the supplied private-object runner +on the common helper, each generated module, and the aggregate module, in that +order. Run the same module list again with `--kernel`. Do not use Lake or alter +shared package caches. + +Successful compile receipt tags in `.lake/paper/logs/`: + +- helper: `conj-helper-4` +- DI03: `conj-di03-2` +- DI04: `conj-di04-1` +- DI05: `conj-di05-1` +- DI06: `conj-di06-1` +- DI07: `conj-di07-1` +- aggregate: `conj-aggregate-2` + +Successful independent kernel receipt tags: + +- helper: `conj-helper-k1` +- DI03, DI04, DI05: `conj-small-k1` +- DI06: `conj-di06-k1` +- DI07: `conj-di07-k1` +- aggregate: `conj-aggregate-k1` + +All seven compilation exits and all seven kernel exits are zero. Generated +modules emit style warnings (long rational literals and option scoping), not +proof failures. No original project source, Lake configuration, research source, +remote, or shared cache was modified. + +These finite diagnostic families cannot satisfy the first-origin bound together +with the corresponding root-disk information. They are not Sendov polynomial +counterexamples, and do not provide all-parameter coverage at any degree. diff --git a/tests/PaperCenteredHundred.lean b/tests/PaperCenteredHundred.lean new file mode 100644 index 0000000..b60c365 --- /dev/null +++ b/tests/PaperCenteredHundred.lean @@ -0,0 +1,2106 @@ +import Sendov.Analytic.PaperCenteredCertificate + +/-! +# DI02: the actual repeated hundred-point multiset +The certificates are arithmetic witnesses, not assumptions about an unrelated +scalar bound. Both error definitions retain their actual complex endpoints. +-/ +noncomputable section +open scoped BigOperators +namespace Sendov.PaperCenteredHundred +open PaperCentered PaperCenteredBound PaperCenteredCertificate + +def a : ℝ := 9 / 10 +def μ : ℂ := 7 / 10 +def q : Multiset ℂ := Multiset.replicate 50 (2 / 5) + Multiset.replicate 50 1 +def r : Multiset ℂ := q.map (fun w => w - μ) + +@[simp] lemma q_card : q.card = 100 := by norm_num [q] +@[simp] lemma r_card : r.card = 100 := by simp [r] +lemma mean : q.sum = q.card * μ := by norm_num [q, μ] +lemma mean_div : q.sum / q.card = (7 / 10 : ℂ) := by norm_num [q] +lemma pointwise (w : ℂ) (hw : w ∈ q) : w ≠ 0 ∧ ‖w‖ ≤ 1 := by + simp only [q, Multiset.mem_add, Multiset.mem_replicate] at hw + rcases hw with ⟨_, rfl⟩ | ⟨_, rfl⟩ <;> norm_num [norm_div] +lemma deviations : r = Multiset.replicate 50 (-(3 / 10 : ℂ)) + + Multiset.replicate 50 (3 / 10 : ℂ) := by + norm_num [r, q, μ, Multiset.map_add, Multiset.map_replicate] +@[simp] lemma norm_mu : ‖μ‖ = (7 / 10 : ℝ) := by norm_num [μ, norm_div] +lemma variance_exact : variance r = 9 / 100 := by + norm_num [variance, deviations, Multiset.map_add, Multiset.map_replicate, + norm_div, norm_neg] +lemma kappa_exact : kappa r = 9 / 100 := by + norm_num [kappa, deviations, Multiset.map_add, Multiset.map_replicate] +@[simp] lemma Gamma_exact : Gamma r μ = 1 / 539 := by + norm_num [Gamma, variance_exact] +lemma scale : (a : ℂ) * μ = ((63 / 100 : ℝ) : ℂ) := by norm_num [a, μ] +lemma mu_ne : μ ≠ 0 := by norm_num [μ] + +lemma norm_endpoints (k : ℕ) (hk : k ≤ 100) : ‖H 100 k ((a : ℂ) * μ)‖ ≤ 1 := by + rw [scale] + exact norm_H_ofReal_le_one _ _ _ hk (by norm_num) (by norm_num) + +lemma low_endpoints : + ‖1 - (a : ℂ) * μ‖ ^ (r.card + 1) + Gamma r μ * ‖B r.card 2 ((a : ℂ) * μ)‖ ≤ + (1 / 10^12 : ℝ) := by + rw [scale, r_card, Gamma_exact, B_ofReal] + have hn : ‖1 - ((63 / 100 : ℝ) : ℂ)‖ = (37 / 100 : ℝ) := by + norm_num [norm_div] + rw [hn, Complex.norm_real, Real.norm_eq_abs, + abs_of_nonneg (realB_nonneg 100 2 (63/100) (by norm_num) (by norm_num))] + norm_num [realB, Finset.sum_range_succ, Nat.choose] + +lemma esymm_exact (k : ℕ) (hk : k ≤ 100) : + r.esymm k = if 2 ∣ (100-k) then + (-(3 / 10 : ℂ)^2) ^ (50-(100-k)/2) * ((50 : ℕ).choose ((100-k)/2) : ℂ) else 0 := by + rw [deviations] + exact esymm_opposite_replicate 50 k (3/10) hk + +/-- Fixed-denominator outward envelopes for normalized coefficients. -/ +def genericNumerator (k : ℕ) : ℕ := + if k = 3 then 410439009 else if k = 4 then 38153285 else + if k = 5 then 3927325 else if k = 6 then 440942 else + if k = 7 then 53400 else if k = 8 then 6917 else + if k = 9 then 952 else if k = 10 then 139 else + if k = 11 then 22 else if k = 12 then 4 else 1 + +def actualNumerator (k : ℕ) : ℕ := + if k % 2 = 1 then 0 else if k = 4 then 10539189 else + if k = 6 then 101883 else if k = 8 then 1409 else if k = 10 then 26 else 1 + +-- BEGIN GENERATED COEFFICIENT CERTIFICATES +private lemma generic_3 : C 100 3 (9/100) / + (((100 : ℕ).choose 3 : ℝ) * (7/10)^3) ≤ (genericNumerator 3 : ℝ) / 10^12 := by + apply normalized_C_le 100 3 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 3 = 161700 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_3 : ‖r.esymm 3‖ / + (((100 : ℕ).choose 3 : ℝ) * (7/10)^3) ≤ (actualNumerator 3 : ℝ) / 10^12 := by + rw [esymm_exact 3 (by decide)] + norm_num [actualNumerator] + +private lemma generic_4 : C 100 4 (9/100) / + (((100 : ℕ).choose 4 : ℝ) * (7/10)^4) ≤ (genericNumerator 4 : ℝ) / 10^12 := by + apply normalized_C_le 100 4 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 4 = 3921225 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_4 : ‖r.esymm 4‖ / + (((100 : ℕ).choose 4 : ℝ) * (7/10)^4) ≤ (actualNumerator 4 : ℝ) / 10^12 := by + rw [esymm_exact 4 (by decide)] + have hc : (100 : ℕ).choose 4 = 3921225 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 48 = 1225 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_5 : C 100 5 (9/100) / + (((100 : ℕ).choose 5 : ℝ) * (7/10)^5) ≤ (genericNumerator 5 : ℝ) / 10^12 := by + apply normalized_C_le 100 5 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 5 = 75287520 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_5 : ‖r.esymm 5‖ / + (((100 : ℕ).choose 5 : ℝ) * (7/10)^5) ≤ (actualNumerator 5 : ℝ) / 10^12 := by + rw [esymm_exact 5 (by decide)] + norm_num [actualNumerator] + +private lemma generic_6 : C 100 6 (9/100) / + (((100 : ℕ).choose 6 : ℝ) * (7/10)^6) ≤ (genericNumerator 6 : ℝ) / 10^12 := by + apply normalized_C_le 100 6 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 6 = 1192052400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_6 : ‖r.esymm 6‖ / + (((100 : ℕ).choose 6 : ℝ) * (7/10)^6) ≤ (actualNumerator 6 : ℝ) / 10^12 := by + rw [esymm_exact 6 (by decide)] + have hc : (100 : ℕ).choose 6 = 1192052400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 47 = 19600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_7 : C 100 7 (9/100) / + (((100 : ℕ).choose 7 : ℝ) * (7/10)^7) ≤ (genericNumerator 7 : ℝ) / 10^12 := by + apply normalized_C_le 100 7 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 7 = 16007560800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_7 : ‖r.esymm 7‖ / + (((100 : ℕ).choose 7 : ℝ) * (7/10)^7) ≤ (actualNumerator 7 : ℝ) / 10^12 := by + rw [esymm_exact 7 (by decide)] + norm_num [actualNumerator] + +private lemma generic_8 : C 100 8 (9/100) / + (((100 : ℕ).choose 8 : ℝ) * (7/10)^8) ≤ (genericNumerator 8 : ℝ) / 10^12 := by + apply normalized_C_le 100 8 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 8 = 186087894300 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_8 : ‖r.esymm 8‖ / + (((100 : ℕ).choose 8 : ℝ) * (7/10)^8) ≤ (actualNumerator 8 : ℝ) / 10^12 := by + rw [esymm_exact 8 (by decide)] + have hc : (100 : ℕ).choose 8 = 186087894300 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 46 = 230300 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_9 : C 100 9 (9/100) / + (((100 : ℕ).choose 9 : ℝ) * (7/10)^9) ≤ (genericNumerator 9 : ℝ) / 10^12 := by + apply normalized_C_le 100 9 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 9 = 1902231808400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_9 : ‖r.esymm 9‖ / + (((100 : ℕ).choose 9 : ℝ) * (7/10)^9) ≤ (actualNumerator 9 : ℝ) / 10^12 := by + rw [esymm_exact 9 (by decide)] + norm_num [actualNumerator] + +private lemma generic_10 : C 100 10 (9/100) / + (((100 : ℕ).choose 10 : ℝ) * (7/10)^10) ≤ (genericNumerator 10 : ℝ) / 10^12 := by + apply normalized_C_le 100 10 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 10 = 17310309456440 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_10 : ‖r.esymm 10‖ / + (((100 : ℕ).choose 10 : ℝ) * (7/10)^10) ≤ (actualNumerator 10 : ℝ) / 10^12 := by + rw [esymm_exact 10 (by decide)] + have hc : (100 : ℕ).choose 10 = 17310309456440 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 45 = 2118760 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_11 : C 100 11 (9/100) / + (((100 : ℕ).choose 11 : ℝ) * (7/10)^11) ≤ (genericNumerator 11 : ℝ) / 10^12 := by + apply normalized_C_le 100 11 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 11 = 141629804643600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_11 : ‖r.esymm 11‖ / + (((100 : ℕ).choose 11 : ℝ) * (7/10)^11) ≤ (actualNumerator 11 : ℝ) / 10^12 := by + rw [esymm_exact 11 (by decide)] + norm_num [actualNumerator] + +private lemma generic_12 : C 100 12 (9/100) / + (((100 : ℕ).choose 12 : ℝ) * (7/10)^12) ≤ (genericNumerator 12 : ℝ) / 10^12 := by + apply normalized_C_le 100 12 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 12 = 1050421051106700 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_12 : ‖r.esymm 12‖ / + (((100 : ℕ).choose 12 : ℝ) * (7/10)^12) ≤ (actualNumerator 12 : ℝ) / 10^12 := by + rw [esymm_exact 12 (by decide)] + have hc : (100 : ℕ).choose 12 = 1050421051106700 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 44 = 15890700 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_13 : C 100 13 (9/100) / + (((100 : ℕ).choose 13 : ℝ) * (7/10)^13) ≤ (genericNumerator 13 : ℝ) / 10^12 := by + apply normalized_C_le 100 13 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 13 = 7110542499799200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_13 : ‖r.esymm 13‖ / + (((100 : ℕ).choose 13 : ℝ) * (7/10)^13) ≤ (actualNumerator 13 : ℝ) / 10^12 := by + rw [esymm_exact 13 (by decide)] + norm_num [actualNumerator] + +private lemma generic_14 : C 100 14 (9/100) / + (((100 : ℕ).choose 14 : ℝ) * (7/10)^14) ≤ (genericNumerator 14 : ℝ) / 10^12 := by + apply normalized_C_le 100 14 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 14 = 44186942677323600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_14 : ‖r.esymm 14‖ / + (((100 : ℕ).choose 14 : ℝ) * (7/10)^14) ≤ (actualNumerator 14 : ℝ) / 10^12 := by + rw [esymm_exact 14 (by decide)] + have hc : (100 : ℕ).choose 14 = 44186942677323600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 43 = 99884400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_15 : C 100 15 (9/100) / + (((100 : ℕ).choose 15 : ℝ) * (7/10)^15) ≤ (genericNumerator 15 : ℝ) / 10^12 := by + apply normalized_C_le 100 15 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 15 = 253338471349988640 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_15 : ‖r.esymm 15‖ / + (((100 : ℕ).choose 15 : ℝ) * (7/10)^15) ≤ (actualNumerator 15 : ℝ) / 10^12 := by + rw [esymm_exact 15 (by decide)] + norm_num [actualNumerator] + +private lemma generic_16 : C 100 16 (9/100) / + (((100 : ℕ).choose 16 : ℝ) * (7/10)^16) ≤ (genericNumerator 16 : ℝ) / 10^12 := by + apply normalized_C_le 100 16 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 16 = 1345860629046814650 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_16 : ‖r.esymm 16‖ / + (((100 : ℕ).choose 16 : ℝ) * (7/10)^16) ≤ (actualNumerator 16 : ℝ) / 10^12 := by + rw [esymm_exact 16 (by decide)] + have hc : (100 : ℕ).choose 16 = 1345860629046814650 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 42 = 536878650 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_17 : C 100 17 (9/100) / + (((100 : ℕ).choose 17 : ℝ) * (7/10)^17) ≤ (genericNumerator 17 : ℝ) / 10^12 := by + apply normalized_C_le 100 17 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 17 = 6650134872937201800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_17 : ‖r.esymm 17‖ / + (((100 : ℕ).choose 17 : ℝ) * (7/10)^17) ≤ (actualNumerator 17 : ℝ) / 10^12 := by + rw [esymm_exact 17 (by decide)] + norm_num [actualNumerator] + +private lemma generic_18 : C 100 18 (9/100) / + (((100 : ℕ).choose 18 : ℝ) * (7/10)^18) ≤ (genericNumerator 18 : ℝ) / 10^12 := by + apply normalized_C_le 100 18 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 18 = 30664510802988208300 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_18 : ‖r.esymm 18‖ / + (((100 : ℕ).choose 18 : ℝ) * (7/10)^18) ≤ (actualNumerator 18 : ℝ) / 10^12 := by + rw [esymm_exact 18 (by decide)] + have hc : (100 : ℕ).choose 18 = 30664510802988208300 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 41 = 2505433700 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_19 : C 100 19 (9/100) / + (((100 : ℕ).choose 19 : ℝ) * (7/10)^19) ≤ (genericNumerator 19 : ℝ) / 10^12 := by + apply normalized_C_le 100 19 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 19 = 132341572939212267400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_19 : ‖r.esymm 19‖ / + (((100 : ℕ).choose 19 : ℝ) * (7/10)^19) ≤ (actualNumerator 19 : ℝ) / 10^12 := by + rw [esymm_exact 19 (by decide)] + norm_num [actualNumerator] + +private lemma generic_20 : C 100 20 (9/100) / + (((100 : ℕ).choose 20 : ℝ) * (7/10)^20) ≤ (genericNumerator 20 : ℝ) / 10^12 := by + apply normalized_C_le 100 20 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 20 = 535983370403809682970 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_20 : ‖r.esymm 20‖ / + (((100 : ℕ).choose 20 : ℝ) * (7/10)^20) ≤ (actualNumerator 20 : ℝ) / 10^12 := by + rw [esymm_exact 20 (by decide)] + have hc : (100 : ℕ).choose 20 = 535983370403809682970 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 40 = 10272278170 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_21 : C 100 21 (9/100) / + (((100 : ℕ).choose 21 : ℝ) * (7/10)^21) ≤ (genericNumerator 21 : ℝ) / 10^12 := by + apply normalized_C_le 100 21 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 21 = 2041841411062132125600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_21 : ‖r.esymm 21‖ / + (((100 : ℕ).choose 21 : ℝ) * (7/10)^21) ≤ (actualNumerator 21 : ℝ) / 10^12 := by + rw [esymm_exact 21 (by decide)] + norm_num [actualNumerator] + +private lemma generic_22 : C 100 22 (9/100) / + (((100 : ℕ).choose 22 : ℝ) * (7/10)^22) ≤ (genericNumerator 22 : ℝ) / 10^12 := by + apply normalized_C_le 100 22 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 22 = 7332066885177656269200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_22 : ‖r.esymm 22‖ / + (((100 : ℕ).choose 22 : ℝ) * (7/10)^22) ≤ (actualNumerator 22 : ℝ) / 10^12 := by + rw [esymm_exact 22 (by decide)] + have hc : (100 : ℕ).choose 22 = 7332066885177656269200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 39 = 37353738800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_23 : C 100 23 (9/100) / + (((100 : ℕ).choose 23 : ℝ) * (7/10)^23) ≤ (genericNumerator 23 : ℝ) / 10^12 := by + apply normalized_C_le 100 23 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 23 = 24865270306254660391200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_23 : ‖r.esymm 23‖ / + (((100 : ℕ).choose 23 : ℝ) * (7/10)^23) ≤ (actualNumerator 23 : ℝ) / 10^12 := by + rw [esymm_exact 23 (by decide)] + norm_num [actualNumerator] + +private lemma generic_24 : C 100 24 (9/100) / + (((100 : ℕ).choose 24 : ℝ) * (7/10)^24) ≤ (genericNumerator 24 : ℝ) / 10^12 := by + apply normalized_C_le 100 24 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 24 = 79776075565900368755100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_24 : ‖r.esymm 24‖ / + (((100 : ℕ).choose 24 : ℝ) * (7/10)^24) ≤ (actualNumerator 24 : ℝ) / 10^12 := by + rw [esymm_exact 24 (by decide)] + have hc : (100 : ℕ).choose 24 = 79776075565900368755100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 38 = 121399651100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_25 : C 100 25 (9/100) / + (((100 : ℕ).choose 25 : ℝ) * (7/10)^25) ≤ (genericNumerator 25 : ℝ) / 10^12 := by + apply normalized_C_le 100 25 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 25 = 242519269720337121015504 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_25 : ‖r.esymm 25‖ / + (((100 : ℕ).choose 25 : ℝ) * (7/10)^25) ≤ (actualNumerator 25 : ℝ) / 10^12 := by + rw [esymm_exact 25 (by decide)] + norm_num [actualNumerator] + +private lemma generic_26 : C 100 26 (9/100) / + (((100 : ℕ).choose 26 : ℝ) * (7/10)^26) ≤ (genericNumerator 26 : ℝ) / 10^12 := by + apply normalized_C_le 100 26 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 26 = 699574816500972464467800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_26 : ‖r.esymm 26‖ / + (((100 : ℕ).choose 26 : ℝ) * (7/10)^26) ≤ (actualNumerator 26 : ℝ) / 10^12 := by + rw [esymm_exact 26 (by decide)] + have hc : (100 : ℕ).choose 26 = 699574816500972464467800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 37 = 354860518600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_27 : C 100 27 (9/100) / + (((100 : ℕ).choose 27 : ℝ) * (7/10)^27) ≤ (genericNumerator 27 : ℝ) / 10^12 := by + apply normalized_C_le 100 27 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 27 = 1917353200780443050763600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_27 : ‖r.esymm 27‖ / + (((100 : ℕ).choose 27 : ℝ) * (7/10)^27) ≤ (actualNumerator 27 : ℝ) / 10^12 := by + rw [esymm_exact 27 (by decide)] + norm_num [actualNumerator] + +private lemma generic_28 : C 100 28 (9/100) / + (((100 : ℕ).choose 28 : ℝ) * (7/10)^28) ≤ (genericNumerator 28 : ℝ) / 10^12 := by + apply normalized_C_le 100 28 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 28 = 4998813702034726525205100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_28 : ‖r.esymm 28‖ / + (((100 : ℕ).choose 28 : ℝ) * (7/10)^28) ≤ (actualNumerator 28 : ℝ) / 10^12 := by + rw [esymm_exact 28 (by decide)] + have hc : (100 : ℕ).choose 28 = 4998813702034726525205100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 36 = 937845656300 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_29 : C 100 29 (9/100) / + (((100 : ℕ).choose 29 : ℝ) * (7/10)^29) ≤ (genericNumerator 29 : ℝ) / 10^12 := by + apply normalized_C_le 100 29 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 29 = 12410847811948286545336800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_29 : ‖r.esymm 29‖ / + (((100 : ℕ).choose 29 : ℝ) * (7/10)^29) ≤ (actualNumerator 29 : ℝ) / 10^12 := by + rw [esymm_exact 29 (by decide)] + norm_num [actualNumerator] + +private lemma generic_30 : C 100 30 (9/100) / + (((100 : ℕ).choose 30 : ℝ) * (7/10)^30) ≤ (genericNumerator 30 : ℝ) / 10^12 := by + apply normalized_C_le 100 30 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 30 = 29372339821610944823963760 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_30 : ‖r.esymm 30‖ / + (((100 : ℕ).choose 30 : ℝ) * (7/10)^30) ≤ (actualNumerator 30 : ℝ) / 10^12 := by + rw [esymm_exact 30 (by decide)] + have hc : (100 : ℕ).choose 30 = 29372339821610944823963760 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 35 = 2250829575120 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_31 : C 100 31 (9/100) / + (((100 : ℕ).choose 31 : ℝ) * (7/10)^31) ≤ (genericNumerator 31 : ℝ) / 10^12 := by + apply normalized_C_le 100 31 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 31 = 66324638306863423796047200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_31 : ‖r.esymm 31‖ / + (((100 : ℕ).choose 31 : ℝ) * (7/10)^31) ≤ (actualNumerator 31 : ℝ) / 10^12 := by + rw [esymm_exact 31 (by decide)] + norm_num [actualNumerator] + +private lemma generic_32 : C 100 32 (9/100) / + (((100 : ℕ).choose 32 : ℝ) * (7/10)^32) ≤ (genericNumerator 32 : ℝ) / 10^12 := by + apply normalized_C_le 100 32 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 32 = 143012501349174257560226775 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_32 : ‖r.esymm 32‖ / + (((100 : ℕ).choose 32 : ℝ) * (7/10)^32) ≤ (actualNumerator 32 : ℝ) / 10^12 := by + rw [esymm_exact 32 (by decide)] + have hc : (100 : ℕ).choose 32 = 143012501349174257560226775 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 34 = 4923689695575 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_33 : C 100 33 (9/100) / + (((100 : ℕ).choose 33 : ℝ) * (7/10)^33) ≤ (genericNumerator 33 : ℝ) / 10^12 := by + apply normalized_C_le 100 33 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 33 = 294692427022540894366527900 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_33 : ‖r.esymm 33‖ / + (((100 : ℕ).choose 33 : ℝ) * (7/10)^33) ≤ (actualNumerator 33 : ℝ) / 10^12 := by + rw [esymm_exact 33 (by decide)] + norm_num [actualNumerator] + +private lemma generic_34 : C 100 34 (9/100) / + (((100 : ℕ).choose 34 : ℝ) * (7/10)^34) ≤ (genericNumerator 34 : ℝ) / 10^12 := by + apply normalized_C_le 100 34 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 34 = 580717429720889409486981450 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_34 : ‖r.esymm 34‖ / + (((100 : ℕ).choose 34 : ℝ) * (7/10)^34) ≤ (actualNumerator 34 : ℝ) / 10^12 := by + rw [esymm_exact 34 (by decide)] + have hc : (100 : ℕ).choose 34 = 580717429720889409486981450 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 33 = 9847379391150 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_35 : C 100 35 (9/100) / + (((100 : ℕ).choose 35 : ℝ) * (7/10)^35) ≤ (genericNumerator 35 : ℝ) / 10^12 := by + apply normalized_C_le 100 35 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 35 = 1095067153187962886461165020 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_35 : ‖r.esymm 35‖ / + (((100 : ℕ).choose 35 : ℝ) * (7/10)^35) ≤ (actualNumerator 35 : ℝ) / 10^12 := by + rw [esymm_exact 35 (by decide)] + norm_num [actualNumerator] + +private lemma generic_36 : C 100 36 (9/100) / + (((100 : ℕ).choose 36 : ℝ) * (7/10)^36) ≤ (genericNumerator 36 : ℝ) / 10^12 := by + apply normalized_C_le 100 36 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 36 = 1977204582144932989443770175 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_36 : ‖r.esymm 36‖ / + (((100 : ℕ).choose 36 : ℝ) * (7/10)^36) ≤ (actualNumerator 36 : ℝ) / 10^12 := by + rw [esymm_exact 36 (by decide)] + have hc : (100 : ℕ).choose 36 = 1977204582144932989443770175 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 32 = 18053528883775 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_37 : C 100 37 (9/100) / + (((100 : ℕ).choose 37 : ℝ) * (7/10)^37) ≤ (genericNumerator 37 : ℝ) / 10^12 := by + apply normalized_C_le 100 37 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 37 = 3420029547493938143902737600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_37 : ‖r.esymm 37‖ / + (((100 : ℕ).choose 37 : ℝ) * (7/10)^37) ≤ (actualNumerator 37 : ℝ) / 10^12 := by + rw [esymm_exact 37 (by decide)] + norm_num [actualNumerator] + +private lemma generic_38 : C 100 38 (9/100) / + (((100 : ℕ).choose 38 : ℝ) * (7/10)^38) ≤ (genericNumerator 38 : ℝ) / 10^12 := by + apply normalized_C_le 100 38 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 38 = 5670048986634686922786117600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_38 : ‖r.esymm 38‖ / + (((100 : ℕ).choose 38 : ℝ) * (7/10)^38) ≤ (actualNumerator 38 : ℝ) / 10^12 := by + rw [esymm_exact 38 (by decide)] + have hc : (100 : ℕ).choose 38 = 5670048986634686922786117600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 31 = 30405943383200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_39 : C 100 39 (9/100) / + (((100 : ℕ).choose 39 : ℝ) * (7/10)^39) ≤ (genericNumerator 39 : ℝ) / 10^12 := by + apply normalized_C_le 100 39 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 39 = 9013924030034630492634340800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_39 : ‖r.esymm 39‖ / + (((100 : ℕ).choose 39 : ℝ) * (7/10)^39) ≤ (actualNumerator 39 : ℝ) / 10^12 := by + rw [esymm_exact 39 (by decide)] + norm_num [actualNumerator] + +private lemma generic_40 : C 100 40 (9/100) / + (((100 : ℕ).choose 40 : ℝ) * (7/10)^40) ≤ (genericNumerator 40 : ℝ) / 10^12 := by + apply normalized_C_le 100 40 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 40 = 13746234145802811501267369720 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_40 : ‖r.esymm 40‖ / + (((100 : ℕ).choose 40 : ℝ) * (7/10)^40) ≤ (actualNumerator 40 : ℝ) / 10^12 := by + rw [esymm_exact 40 (by decide)] + have hc : (100 : ℕ).choose 40 = 13746234145802811501267369720 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 30 = 47129212243960 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_41 : C 100 41 (9/100) / + (((100 : ℕ).choose 41 : ℝ) * (7/10)^41) ≤ (genericNumerator 41 : ℝ) / 10^12 := by + apply normalized_C_le 100 41 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 41 = 20116440213369968050635175200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_41 : ‖r.esymm 41‖ / + (((100 : ℕ).choose 41 : ℝ) * (7/10)^41) ≤ (actualNumerator 41 : ℝ) / 10^12 := by + rw [esymm_exact 41 (by decide)] + norm_num [actualNumerator] + +private lemma generic_42 : C 100 42 (9/100) / + (((100 : ℕ).choose 42 : ℝ) * (7/10)^42) ≤ (genericNumerator 42 : ℝ) / 10^12 := by + apply normalized_C_le 100 42 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 42 = 28258808871162574166368460400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_42 : ‖r.esymm 42‖ / + (((100 : ℕ).choose 42 : ℝ) * (7/10)^42) ≤ (actualNumerator 42 : ℝ) / 10^12 := by + rw [esymm_exact 42 (by decide)] + have hc : (100 : ℕ).choose 42 = 28258808871162574166368460400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 29 = 67327446062800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_43 : C 100 43 (9/100) / + (((100 : ℕ).choose 43 : ℝ) * (7/10)^43) ≤ (genericNumerator 43 : ℝ) / 10^12 := by + apply normalized_C_le 100 43 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 43 = 38116532895986727945334202400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_43 : ‖r.esymm 43‖ / + (((100 : ℕ).choose 43 : ℝ) * (7/10)^43) ≤ (actualNumerator 43 : ℝ) / 10^12 := by + rw [esymm_exact 43 (by decide)] + norm_num [actualNumerator] + +private lemma generic_44 : C 100 44 (9/100) / + (((100 : ℕ).choose 44 : ℝ) * (7/10)^44) ≤ (genericNumerator 44 : ℝ) / 10^12 := by + apply normalized_C_le 100 44 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 44 = 49378235797073715747364762200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_44 : ‖r.esymm 44‖ / + (((100 : ℕ).choose 44 : ℝ) * (7/10)^44) ≤ (actualNumerator 44 : ℝ) / 10^12 := by + rw [esymm_exact 44 (by decide)] + have hc : (100 : ℕ).choose 44 = 49378235797073715747364762200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 28 = 88749815264600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_45 : C 100 45 (9/100) / + (((100 : ℕ).choose 45 : ℝ) * (7/10)^45) ≤ (genericNumerator 45 : ℝ) / 10^12 := by + apply normalized_C_le 100 45 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 45 = 61448471214136179596720592960 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_45 : ‖r.esymm 45‖ / + (((100 : ℕ).choose 45 : ℝ) * (7/10)^45) ≤ (actualNumerator 45 : ℝ) / 10^12 := by + rw [esymm_exact 45 (by decide)] + norm_num [actualNumerator] + +private lemma generic_46 : C 100 46 (9/100) / + (((100 : ℕ).choose 46 : ℝ) * (7/10)^46) ≤ (genericNumerator 46 : ℝ) / 10^12 := by + apply normalized_C_le 100 46 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 46 = 73470998190814997343905056800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_46 : ‖r.esymm 46‖ / + (((100 : ℕ).choose 46 : ℝ) * (7/10)^46) ≤ (actualNumerator 46 : ℝ) / 10^12 := by + rw [esymm_exact 46 (by decide)] + have hc : (100 : ℕ).choose 46 = 73470998190814997343905056800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 27 = 108043253365600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_47 : C 100 47 (9/100) / + (((100 : ℕ).choose 47 : ℝ) * (7/10)^47) ≤ (genericNumerator 47 : ℝ) / 10^12 := by + apply normalized_C_le 100 47 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 47 = 84413487283064039501507937600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_47 : ‖r.esymm 47‖ / + (((100 : ℕ).choose 47 : ℝ) * (7/10)^47) ≤ (actualNumerator 47 : ℝ) / 10^12 := by + rw [esymm_exact 47 (by decide)] + norm_num [actualNumerator] + +private lemma generic_48 : C 100 48 (9/100) / + (((100 : ℕ).choose 48 : ℝ) * (7/10)^48) ≤ (genericNumerator 48 : ℝ) / 10^12 := by + apply normalized_C_le 100 48 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 48 = 93206558875049876949581681100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_48 : ‖r.esymm 48‖ / + (((100 : ℕ).choose 48 : ℝ) * (7/10)^48) ≤ (actualNumerator 48 : ℝ) / 10^12 := by + rw [esymm_exact 48 (by decide)] + have hc : (100 : ℕ).choose 48 = 93206558875049876949581681100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 26 = 121548660036300 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_49 : C 100 49 (9/100) / + (((100 : ℕ).choose 49 : ℝ) * (7/10)^49) ≤ (genericNumerator 49 : ℝ) / 10^12 := by + apply normalized_C_le 100 49 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 49 = 98913082887808032681188722800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_49 : ‖r.esymm 49‖ / + (((100 : ℕ).choose 49 : ℝ) * (7/10)^49) ≤ (actualNumerator 49 : ℝ) / 10^12 := by + rw [esymm_exact 49 (by decide)] + norm_num [actualNumerator] + +private lemma generic_50 : C 100 50 (9/100) / + (((100 : ℕ).choose 50 : ℝ) * (7/10)^50) ≤ (genericNumerator 50 : ℝ) / 10^12 := by + apply normalized_C_le 100 50 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 50 = 100891344545564193334812497256 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_50 : ‖r.esymm 50‖ / + (((100 : ℕ).choose 50 : ℝ) * (7/10)^50) ≤ (actualNumerator 50 : ℝ) / 10^12 := by + rw [esymm_exact 50 (by decide)] + have hc : (100 : ℕ).choose 50 = 100891344545564193334812497256 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 25 = 126410606437752 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_51 : C 100 51 (9/100) / + (((100 : ℕ).choose 51 : ℝ) * (7/10)^51) ≤ (genericNumerator 51 : ℝ) / 10^12 := by + apply normalized_C_le 100 51 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 51 = 98913082887808032681188722800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_51 : ‖r.esymm 51‖ / + (((100 : ℕ).choose 51 : ℝ) * (7/10)^51) ≤ (actualNumerator 51 : ℝ) / 10^12 := by + rw [esymm_exact 51 (by decide)] + norm_num [actualNumerator] + +private lemma generic_52 : C 100 52 (9/100) / + (((100 : ℕ).choose 52 : ℝ) * (7/10)^52) ≤ (genericNumerator 52 : ℝ) / 10^12 := by + apply normalized_C_le 100 52 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 52 = 93206558875049876949581681100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_52 : ‖r.esymm 52‖ / + (((100 : ℕ).choose 52 : ℝ) * (7/10)^52) ≤ (actualNumerator 52 : ℝ) / 10^12 := by + rw [esymm_exact 52 (by decide)] + have hc : (100 : ℕ).choose 52 = 93206558875049876949581681100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 24 = 121548660036300 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_53 : C 100 53 (9/100) / + (((100 : ℕ).choose 53 : ℝ) * (7/10)^53) ≤ (genericNumerator 53 : ℝ) / 10^12 := by + apply normalized_C_le 100 53 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 53 = 84413487283064039501507937600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_53 : ‖r.esymm 53‖ / + (((100 : ℕ).choose 53 : ℝ) * (7/10)^53) ≤ (actualNumerator 53 : ℝ) / 10^12 := by + rw [esymm_exact 53 (by decide)] + norm_num [actualNumerator] + +private lemma generic_54 : C 100 54 (9/100) / + (((100 : ℕ).choose 54 : ℝ) * (7/10)^54) ≤ (genericNumerator 54 : ℝ) / 10^12 := by + apply normalized_C_le 100 54 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 54 = 73470998190814997343905056800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_54 : ‖r.esymm 54‖ / + (((100 : ℕ).choose 54 : ℝ) * (7/10)^54) ≤ (actualNumerator 54 : ℝ) / 10^12 := by + rw [esymm_exact 54 (by decide)] + have hc : (100 : ℕ).choose 54 = 73470998190814997343905056800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 23 = 108043253365600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_55 : C 100 55 (9/100) / + (((100 : ℕ).choose 55 : ℝ) * (7/10)^55) ≤ (genericNumerator 55 : ℝ) / 10^12 := by + apply normalized_C_le 100 55 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 55 = 61448471214136179596720592960 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_55 : ‖r.esymm 55‖ / + (((100 : ℕ).choose 55 : ℝ) * (7/10)^55) ≤ (actualNumerator 55 : ℝ) / 10^12 := by + rw [esymm_exact 55 (by decide)] + norm_num [actualNumerator] + +private lemma generic_56 : C 100 56 (9/100) / + (((100 : ℕ).choose 56 : ℝ) * (7/10)^56) ≤ (genericNumerator 56 : ℝ) / 10^12 := by + apply normalized_C_le 100 56 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 56 = 49378235797073715747364762200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_56 : ‖r.esymm 56‖ / + (((100 : ℕ).choose 56 : ℝ) * (7/10)^56) ≤ (actualNumerator 56 : ℝ) / 10^12 := by + rw [esymm_exact 56 (by decide)] + have hc : (100 : ℕ).choose 56 = 49378235797073715747364762200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 22 = 88749815264600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_57 : C 100 57 (9/100) / + (((100 : ℕ).choose 57 : ℝ) * (7/10)^57) ≤ (genericNumerator 57 : ℝ) / 10^12 := by + apply normalized_C_le 100 57 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 57 = 38116532895986727945334202400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_57 : ‖r.esymm 57‖ / + (((100 : ℕ).choose 57 : ℝ) * (7/10)^57) ≤ (actualNumerator 57 : ℝ) / 10^12 := by + rw [esymm_exact 57 (by decide)] + norm_num [actualNumerator] + +private lemma generic_58 : C 100 58 (9/100) / + (((100 : ℕ).choose 58 : ℝ) * (7/10)^58) ≤ (genericNumerator 58 : ℝ) / 10^12 := by + apply normalized_C_le 100 58 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 58 = 28258808871162574166368460400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_58 : ‖r.esymm 58‖ / + (((100 : ℕ).choose 58 : ℝ) * (7/10)^58) ≤ (actualNumerator 58 : ℝ) / 10^12 := by + rw [esymm_exact 58 (by decide)] + have hc : (100 : ℕ).choose 58 = 28258808871162574166368460400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 21 = 67327446062800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_59 : C 100 59 (9/100) / + (((100 : ℕ).choose 59 : ℝ) * (7/10)^59) ≤ (genericNumerator 59 : ℝ) / 10^12 := by + apply normalized_C_le 100 59 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 59 = 20116440213369968050635175200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_59 : ‖r.esymm 59‖ / + (((100 : ℕ).choose 59 : ℝ) * (7/10)^59) ≤ (actualNumerator 59 : ℝ) / 10^12 := by + rw [esymm_exact 59 (by decide)] + norm_num [actualNumerator] + +private lemma generic_60 : C 100 60 (9/100) / + (((100 : ℕ).choose 60 : ℝ) * (7/10)^60) ≤ (genericNumerator 60 : ℝ) / 10^12 := by + apply normalized_C_le 100 60 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 60 = 13746234145802811501267369720 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_60 : ‖r.esymm 60‖ / + (((100 : ℕ).choose 60 : ℝ) * (7/10)^60) ≤ (actualNumerator 60 : ℝ) / 10^12 := by + rw [esymm_exact 60 (by decide)] + have hc : (100 : ℕ).choose 60 = 13746234145802811501267369720 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 20 = 47129212243960 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_61 : C 100 61 (9/100) / + (((100 : ℕ).choose 61 : ℝ) * (7/10)^61) ≤ (genericNumerator 61 : ℝ) / 10^12 := by + apply normalized_C_le 100 61 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 61 = 9013924030034630492634340800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_61 : ‖r.esymm 61‖ / + (((100 : ℕ).choose 61 : ℝ) * (7/10)^61) ≤ (actualNumerator 61 : ℝ) / 10^12 := by + rw [esymm_exact 61 (by decide)] + norm_num [actualNumerator] + +private lemma generic_62 : C 100 62 (9/100) / + (((100 : ℕ).choose 62 : ℝ) * (7/10)^62) ≤ (genericNumerator 62 : ℝ) / 10^12 := by + apply normalized_C_le 100 62 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 62 = 5670048986634686922786117600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_62 : ‖r.esymm 62‖ / + (((100 : ℕ).choose 62 : ℝ) * (7/10)^62) ≤ (actualNumerator 62 : ℝ) / 10^12 := by + rw [esymm_exact 62 (by decide)] + have hc : (100 : ℕ).choose 62 = 5670048986634686922786117600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 19 = 30405943383200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_63 : C 100 63 (9/100) / + (((100 : ℕ).choose 63 : ℝ) * (7/10)^63) ≤ (genericNumerator 63 : ℝ) / 10^12 := by + apply normalized_C_le 100 63 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 63 = 3420029547493938143902737600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_63 : ‖r.esymm 63‖ / + (((100 : ℕ).choose 63 : ℝ) * (7/10)^63) ≤ (actualNumerator 63 : ℝ) / 10^12 := by + rw [esymm_exact 63 (by decide)] + norm_num [actualNumerator] + +private lemma generic_64 : C 100 64 (9/100) / + (((100 : ℕ).choose 64 : ℝ) * (7/10)^64) ≤ (genericNumerator 64 : ℝ) / 10^12 := by + apply normalized_C_le 100 64 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 64 = 1977204582144932989443770175 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_64 : ‖r.esymm 64‖ / + (((100 : ℕ).choose 64 : ℝ) * (7/10)^64) ≤ (actualNumerator 64 : ℝ) / 10^12 := by + rw [esymm_exact 64 (by decide)] + have hc : (100 : ℕ).choose 64 = 1977204582144932989443770175 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 18 = 18053528883775 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_65 : C 100 65 (9/100) / + (((100 : ℕ).choose 65 : ℝ) * (7/10)^65) ≤ (genericNumerator 65 : ℝ) / 10^12 := by + apply normalized_C_le 100 65 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 65 = 1095067153187962886461165020 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_65 : ‖r.esymm 65‖ / + (((100 : ℕ).choose 65 : ℝ) * (7/10)^65) ≤ (actualNumerator 65 : ℝ) / 10^12 := by + rw [esymm_exact 65 (by decide)] + norm_num [actualNumerator] + +private lemma generic_66 : C 100 66 (9/100) / + (((100 : ℕ).choose 66 : ℝ) * (7/10)^66) ≤ (genericNumerator 66 : ℝ) / 10^12 := by + apply normalized_C_le 100 66 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 66 = 580717429720889409486981450 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_66 : ‖r.esymm 66‖ / + (((100 : ℕ).choose 66 : ℝ) * (7/10)^66) ≤ (actualNumerator 66 : ℝ) / 10^12 := by + rw [esymm_exact 66 (by decide)] + have hc : (100 : ℕ).choose 66 = 580717429720889409486981450 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 17 = 9847379391150 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_67 : C 100 67 (9/100) / + (((100 : ℕ).choose 67 : ℝ) * (7/10)^67) ≤ (genericNumerator 67 : ℝ) / 10^12 := by + apply normalized_C_le 100 67 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 67 = 294692427022540894366527900 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_67 : ‖r.esymm 67‖ / + (((100 : ℕ).choose 67 : ℝ) * (7/10)^67) ≤ (actualNumerator 67 : ℝ) / 10^12 := by + rw [esymm_exact 67 (by decide)] + norm_num [actualNumerator] + +private lemma generic_68 : C 100 68 (9/100) / + (((100 : ℕ).choose 68 : ℝ) * (7/10)^68) ≤ (genericNumerator 68 : ℝ) / 10^12 := by + apply normalized_C_le 100 68 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 68 = 143012501349174257560226775 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_68 : ‖r.esymm 68‖ / + (((100 : ℕ).choose 68 : ℝ) * (7/10)^68) ≤ (actualNumerator 68 : ℝ) / 10^12 := by + rw [esymm_exact 68 (by decide)] + have hc : (100 : ℕ).choose 68 = 143012501349174257560226775 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 16 = 4923689695575 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_69 : C 100 69 (9/100) / + (((100 : ℕ).choose 69 : ℝ) * (7/10)^69) ≤ (genericNumerator 69 : ℝ) / 10^12 := by + apply normalized_C_le 100 69 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 69 = 66324638306863423796047200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_69 : ‖r.esymm 69‖ / + (((100 : ℕ).choose 69 : ℝ) * (7/10)^69) ≤ (actualNumerator 69 : ℝ) / 10^12 := by + rw [esymm_exact 69 (by decide)] + norm_num [actualNumerator] + +private lemma generic_70 : C 100 70 (9/100) / + (((100 : ℕ).choose 70 : ℝ) * (7/10)^70) ≤ (genericNumerator 70 : ℝ) / 10^12 := by + apply normalized_C_le 100 70 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 70 = 29372339821610944823963760 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_70 : ‖r.esymm 70‖ / + (((100 : ℕ).choose 70 : ℝ) * (7/10)^70) ≤ (actualNumerator 70 : ℝ) / 10^12 := by + rw [esymm_exact 70 (by decide)] + have hc : (100 : ℕ).choose 70 = 29372339821610944823963760 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 15 = 2250829575120 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_71 : C 100 71 (9/100) / + (((100 : ℕ).choose 71 : ℝ) * (7/10)^71) ≤ (genericNumerator 71 : ℝ) / 10^12 := by + apply normalized_C_le 100 71 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 71 = 12410847811948286545336800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_71 : ‖r.esymm 71‖ / + (((100 : ℕ).choose 71 : ℝ) * (7/10)^71) ≤ (actualNumerator 71 : ℝ) / 10^12 := by + rw [esymm_exact 71 (by decide)] + norm_num [actualNumerator] + +private lemma generic_72 : C 100 72 (9/100) / + (((100 : ℕ).choose 72 : ℝ) * (7/10)^72) ≤ (genericNumerator 72 : ℝ) / 10^12 := by + apply normalized_C_le 100 72 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 72 = 4998813702034726525205100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_72 : ‖r.esymm 72‖ / + (((100 : ℕ).choose 72 : ℝ) * (7/10)^72) ≤ (actualNumerator 72 : ℝ) / 10^12 := by + rw [esymm_exact 72 (by decide)] + have hc : (100 : ℕ).choose 72 = 4998813702034726525205100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 14 = 937845656300 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_73 : C 100 73 (9/100) / + (((100 : ℕ).choose 73 : ℝ) * (7/10)^73) ≤ (genericNumerator 73 : ℝ) / 10^12 := by + apply normalized_C_le 100 73 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 73 = 1917353200780443050763600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_73 : ‖r.esymm 73‖ / + (((100 : ℕ).choose 73 : ℝ) * (7/10)^73) ≤ (actualNumerator 73 : ℝ) / 10^12 := by + rw [esymm_exact 73 (by decide)] + norm_num [actualNumerator] + +private lemma generic_74 : C 100 74 (9/100) / + (((100 : ℕ).choose 74 : ℝ) * (7/10)^74) ≤ (genericNumerator 74 : ℝ) / 10^12 := by + apply normalized_C_le 100 74 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 74 = 699574816500972464467800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_74 : ‖r.esymm 74‖ / + (((100 : ℕ).choose 74 : ℝ) * (7/10)^74) ≤ (actualNumerator 74 : ℝ) / 10^12 := by + rw [esymm_exact 74 (by decide)] + have hc : (100 : ℕ).choose 74 = 699574816500972464467800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 13 = 354860518600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_75 : C 100 75 (9/100) / + (((100 : ℕ).choose 75 : ℝ) * (7/10)^75) ≤ (genericNumerator 75 : ℝ) / 10^12 := by + apply normalized_C_le 100 75 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 75 = 242519269720337121015504 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_75 : ‖r.esymm 75‖ / + (((100 : ℕ).choose 75 : ℝ) * (7/10)^75) ≤ (actualNumerator 75 : ℝ) / 10^12 := by + rw [esymm_exact 75 (by decide)] + norm_num [actualNumerator] + +private lemma generic_76 : C 100 76 (9/100) / + (((100 : ℕ).choose 76 : ℝ) * (7/10)^76) ≤ (genericNumerator 76 : ℝ) / 10^12 := by + apply normalized_C_le 100 76 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 76 = 79776075565900368755100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_76 : ‖r.esymm 76‖ / + (((100 : ℕ).choose 76 : ℝ) * (7/10)^76) ≤ (actualNumerator 76 : ℝ) / 10^12 := by + rw [esymm_exact 76 (by decide)] + have hc : (100 : ℕ).choose 76 = 79776075565900368755100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 12 = 121399651100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_77 : C 100 77 (9/100) / + (((100 : ℕ).choose 77 : ℝ) * (7/10)^77) ≤ (genericNumerator 77 : ℝ) / 10^12 := by + apply normalized_C_le 100 77 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 77 = 24865270306254660391200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_77 : ‖r.esymm 77‖ / + (((100 : ℕ).choose 77 : ℝ) * (7/10)^77) ≤ (actualNumerator 77 : ℝ) / 10^12 := by + rw [esymm_exact 77 (by decide)] + norm_num [actualNumerator] + +private lemma generic_78 : C 100 78 (9/100) / + (((100 : ℕ).choose 78 : ℝ) * (7/10)^78) ≤ (genericNumerator 78 : ℝ) / 10^12 := by + apply normalized_C_le 100 78 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 78 = 7332066885177656269200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_78 : ‖r.esymm 78‖ / + (((100 : ℕ).choose 78 : ℝ) * (7/10)^78) ≤ (actualNumerator 78 : ℝ) / 10^12 := by + rw [esymm_exact 78 (by decide)] + have hc : (100 : ℕ).choose 78 = 7332066885177656269200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 11 = 37353738800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_79 : C 100 79 (9/100) / + (((100 : ℕ).choose 79 : ℝ) * (7/10)^79) ≤ (genericNumerator 79 : ℝ) / 10^12 := by + apply normalized_C_le 100 79 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 79 = 2041841411062132125600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_79 : ‖r.esymm 79‖ / + (((100 : ℕ).choose 79 : ℝ) * (7/10)^79) ≤ (actualNumerator 79 : ℝ) / 10^12 := by + rw [esymm_exact 79 (by decide)] + norm_num [actualNumerator] + +private lemma generic_80 : C 100 80 (9/100) / + (((100 : ℕ).choose 80 : ℝ) * (7/10)^80) ≤ (genericNumerator 80 : ℝ) / 10^12 := by + apply normalized_C_le 100 80 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 80 = 535983370403809682970 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_80 : ‖r.esymm 80‖ / + (((100 : ℕ).choose 80 : ℝ) * (7/10)^80) ≤ (actualNumerator 80 : ℝ) / 10^12 := by + rw [esymm_exact 80 (by decide)] + have hc : (100 : ℕ).choose 80 = 535983370403809682970 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 10 = 10272278170 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_81 : C 100 81 (9/100) / + (((100 : ℕ).choose 81 : ℝ) * (7/10)^81) ≤ (genericNumerator 81 : ℝ) / 10^12 := by + apply normalized_C_le 100 81 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 81 = 132341572939212267400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_81 : ‖r.esymm 81‖ / + (((100 : ℕ).choose 81 : ℝ) * (7/10)^81) ≤ (actualNumerator 81 : ℝ) / 10^12 := by + rw [esymm_exact 81 (by decide)] + norm_num [actualNumerator] + +private lemma generic_82 : C 100 82 (9/100) / + (((100 : ℕ).choose 82 : ℝ) * (7/10)^82) ≤ (genericNumerator 82 : ℝ) / 10^12 := by + apply normalized_C_le 100 82 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 82 = 30664510802988208300 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_82 : ‖r.esymm 82‖ / + (((100 : ℕ).choose 82 : ℝ) * (7/10)^82) ≤ (actualNumerator 82 : ℝ) / 10^12 := by + rw [esymm_exact 82 (by decide)] + have hc : (100 : ℕ).choose 82 = 30664510802988208300 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 9 = 2505433700 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_83 : C 100 83 (9/100) / + (((100 : ℕ).choose 83 : ℝ) * (7/10)^83) ≤ (genericNumerator 83 : ℝ) / 10^12 := by + apply normalized_C_le 100 83 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 83 = 6650134872937201800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_83 : ‖r.esymm 83‖ / + (((100 : ℕ).choose 83 : ℝ) * (7/10)^83) ≤ (actualNumerator 83 : ℝ) / 10^12 := by + rw [esymm_exact 83 (by decide)] + norm_num [actualNumerator] + +private lemma generic_84 : C 100 84 (9/100) / + (((100 : ℕ).choose 84 : ℝ) * (7/10)^84) ≤ (genericNumerator 84 : ℝ) / 10^12 := by + apply normalized_C_le 100 84 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 84 = 1345860629046814650 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_84 : ‖r.esymm 84‖ / + (((100 : ℕ).choose 84 : ℝ) * (7/10)^84) ≤ (actualNumerator 84 : ℝ) / 10^12 := by + rw [esymm_exact 84 (by decide)] + have hc : (100 : ℕ).choose 84 = 1345860629046814650 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 8 = 536878650 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_85 : C 100 85 (9/100) / + (((100 : ℕ).choose 85 : ℝ) * (7/10)^85) ≤ (genericNumerator 85 : ℝ) / 10^12 := by + apply normalized_C_le 100 85 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 85 = 253338471349988640 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_85 : ‖r.esymm 85‖ / + (((100 : ℕ).choose 85 : ℝ) * (7/10)^85) ≤ (actualNumerator 85 : ℝ) / 10^12 := by + rw [esymm_exact 85 (by decide)] + norm_num [actualNumerator] + +private lemma generic_86 : C 100 86 (9/100) / + (((100 : ℕ).choose 86 : ℝ) * (7/10)^86) ≤ (genericNumerator 86 : ℝ) / 10^12 := by + apply normalized_C_le 100 86 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 86 = 44186942677323600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_86 : ‖r.esymm 86‖ / + (((100 : ℕ).choose 86 : ℝ) * (7/10)^86) ≤ (actualNumerator 86 : ℝ) / 10^12 := by + rw [esymm_exact 86 (by decide)] + have hc : (100 : ℕ).choose 86 = 44186942677323600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 7 = 99884400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_87 : C 100 87 (9/100) / + (((100 : ℕ).choose 87 : ℝ) * (7/10)^87) ≤ (genericNumerator 87 : ℝ) / 10^12 := by + apply normalized_C_le 100 87 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 87 = 7110542499799200 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_87 : ‖r.esymm 87‖ / + (((100 : ℕ).choose 87 : ℝ) * (7/10)^87) ≤ (actualNumerator 87 : ℝ) / 10^12 := by + rw [esymm_exact 87 (by decide)] + norm_num [actualNumerator] + +private lemma generic_88 : C 100 88 (9/100) / + (((100 : ℕ).choose 88 : ℝ) * (7/10)^88) ≤ (genericNumerator 88 : ℝ) / 10^12 := by + apply normalized_C_le 100 88 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 88 = 1050421051106700 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_88 : ‖r.esymm 88‖ / + (((100 : ℕ).choose 88 : ℝ) * (7/10)^88) ≤ (actualNumerator 88 : ℝ) / 10^12 := by + rw [esymm_exact 88 (by decide)] + have hc : (100 : ℕ).choose 88 = 1050421051106700 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 6 = 15890700 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_89 : C 100 89 (9/100) / + (((100 : ℕ).choose 89 : ℝ) * (7/10)^89) ≤ (genericNumerator 89 : ℝ) / 10^12 := by + apply normalized_C_le 100 89 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 89 = 141629804643600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_89 : ‖r.esymm 89‖ / + (((100 : ℕ).choose 89 : ℝ) * (7/10)^89) ≤ (actualNumerator 89 : ℝ) / 10^12 := by + rw [esymm_exact 89 (by decide)] + norm_num [actualNumerator] + +private lemma generic_90 : C 100 90 (9/100) / + (((100 : ℕ).choose 90 : ℝ) * (7/10)^90) ≤ (genericNumerator 90 : ℝ) / 10^12 := by + apply normalized_C_le 100 90 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 90 = 17310309456440 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_90 : ‖r.esymm 90‖ / + (((100 : ℕ).choose 90 : ℝ) * (7/10)^90) ≤ (actualNumerator 90 : ℝ) / 10^12 := by + rw [esymm_exact 90 (by decide)] + have hc : (100 : ℕ).choose 90 = 17310309456440 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 5 = 2118760 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_91 : C 100 91 (9/100) / + (((100 : ℕ).choose 91 : ℝ) * (7/10)^91) ≤ (genericNumerator 91 : ℝ) / 10^12 := by + apply normalized_C_le 100 91 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 91 = 1902231808400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_91 : ‖r.esymm 91‖ / + (((100 : ℕ).choose 91 : ℝ) * (7/10)^91) ≤ (actualNumerator 91 : ℝ) / 10^12 := by + rw [esymm_exact 91 (by decide)] + norm_num [actualNumerator] + +private lemma generic_92 : C 100 92 (9/100) / + (((100 : ℕ).choose 92 : ℝ) * (7/10)^92) ≤ (genericNumerator 92 : ℝ) / 10^12 := by + apply normalized_C_le 100 92 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 92 = 186087894300 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_92 : ‖r.esymm 92‖ / + (((100 : ℕ).choose 92 : ℝ) * (7/10)^92) ≤ (actualNumerator 92 : ℝ) / 10^12 := by + rw [esymm_exact 92 (by decide)] + have hc : (100 : ℕ).choose 92 = 186087894300 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 4 = 230300 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_93 : C 100 93 (9/100) / + (((100 : ℕ).choose 93 : ℝ) * (7/10)^93) ≤ (genericNumerator 93 : ℝ) / 10^12 := by + apply normalized_C_le 100 93 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 93 = 16007560800 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_93 : ‖r.esymm 93‖ / + (((100 : ℕ).choose 93 : ℝ) * (7/10)^93) ≤ (actualNumerator 93 : ℝ) / 10^12 := by + rw [esymm_exact 93 (by decide)] + norm_num [actualNumerator] + +private lemma generic_94 : C 100 94 (9/100) / + (((100 : ℕ).choose 94 : ℝ) * (7/10)^94) ≤ (genericNumerator 94 : ℝ) / 10^12 := by + apply normalized_C_le 100 94 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 94 = 1192052400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_94 : ‖r.esymm 94‖ / + (((100 : ℕ).choose 94 : ℝ) * (7/10)^94) ≤ (actualNumerator 94 : ℝ) / 10^12 := by + rw [esymm_exact 94 (by decide)] + have hc : (100 : ℕ).choose 94 = 1192052400 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 3 = 19600 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_95 : C 100 95 (9/100) / + (((100 : ℕ).choose 95 : ℝ) * (7/10)^95) ≤ (genericNumerator 95 : ℝ) / 10^12 := by + apply normalized_C_le 100 95 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 95 = 75287520 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_95 : ‖r.esymm 95‖ / + (((100 : ℕ).choose 95 : ℝ) * (7/10)^95) ≤ (actualNumerator 95 : ℝ) / 10^12 := by + rw [esymm_exact 95 (by decide)] + norm_num [actualNumerator] + +private lemma generic_96 : C 100 96 (9/100) / + (((100 : ℕ).choose 96 : ℝ) * (7/10)^96) ≤ (genericNumerator 96 : ℝ) / 10^12 := by + apply normalized_C_le 100 96 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 96 = 3921225 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_96 : ‖r.esymm 96‖ / + (((100 : ℕ).choose 96 : ℝ) * (7/10)^96) ≤ (actualNumerator 96 : ℝ) / 10^12 := by + rw [esymm_exact 96 (by decide)] + have hc : (100 : ℕ).choose 96 = 3921225 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 2 = 1225 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_97 : C 100 97 (9/100) / + (((100 : ℕ).choose 97 : ℝ) * (7/10)^97) ≤ (genericNumerator 97 : ℝ) / 10^12 := by + apply normalized_C_le 100 97 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 97 = 161700 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_97 : ‖r.esymm 97‖ / + (((100 : ℕ).choose 97 : ℝ) * (7/10)^97) ≤ (actualNumerator 97 : ℝ) / 10^12 := by + rw [esymm_exact 97 (by decide)] + norm_num [actualNumerator] + +private lemma generic_98 : C 100 98 (9/100) / + (((100 : ℕ).choose 98 : ℝ) * (7/10)^98) ≤ (genericNumerator 98 : ℝ) / 10^12 := by + apply normalized_C_le 100 98 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 98 = 4950 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_98 : ‖r.esymm 98‖ / + (((100 : ℕ).choose 98 : ℝ) * (7/10)^98) ≤ (actualNumerator 98 : ℝ) / 10^12 := by + rw [esymm_exact 98 (by decide)] + have hc : (100 : ℕ).choose 98 = 4950 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 1 = 50 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +private lemma generic_99 : C 100 99 (9/100) / + (((100 : ℕ).choose 99 : ℝ) * (7/10)^99) ≤ (genericNumerator 99 : ℝ) / 10^12 := by + apply normalized_C_le 100 99 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 99 = 100 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_99 : ‖r.esymm 99‖ / + (((100 : ℕ).choose 99 : ℝ) * (7/10)^99) ≤ (actualNumerator 99 : ℝ) / 10^12 := by + rw [esymm_exact 99 (by decide)] + norm_num [actualNumerator] + +private lemma generic_100 : C 100 100 (9/100) / + (((100 : ℕ).choose 100 : ℝ) * (7/10)^100) ≤ (genericNumerator 100 : ℝ) / 10^12 := by + apply normalized_C_le 100 100 (9/100) (7/10) _ (by decide) (by decide) + (by norm_num) (by positivity) + have hc : (100 : ℕ).choose 100 = 1 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [genericNumerator, hc] + +private lemma actual_100 : ‖r.esymm 100‖ / + (((100 : ℕ).choose 100 : ℝ) * (7/10)^100) ≤ (actualNumerator 100 : ℝ) / 10^12 := by + rw [esymm_exact 100 (by decide)] + have hc : (100 : ℕ).choose 100 = 1 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + have hd : (50 : ℕ).choose 0 = 1 := by + rw [Nat.choose_eq_factorial_div_factorial (by decide)] + norm_num [Nat.factorial] + norm_num [hc, hd, actualNumerator, norm_mul, norm_pow, norm_div] + +lemma generic_rows (k : ℕ) (hk : k ∈ Finset.Ico 3 101) : + C 100 k (9/100) / (((100 : ℕ).choose k : ℝ) * (7/10)^k) ≤ + (genericNumerator k : ℝ) / 10^12 := by + obtain ⟨hlo, hhi⟩ := Finset.mem_Ico.mp hk + interval_cases k + · exact generic_3 + · exact generic_4 + · exact generic_5 + · exact generic_6 + · exact generic_7 + · exact generic_8 + · exact generic_9 + · exact generic_10 + · exact generic_11 + · exact generic_12 + · exact generic_13 + · exact generic_14 + · exact generic_15 + · exact generic_16 + · exact generic_17 + · exact generic_18 + · exact generic_19 + · exact generic_20 + · exact generic_21 + · exact generic_22 + · exact generic_23 + · exact generic_24 + · exact generic_25 + · exact generic_26 + · exact generic_27 + · exact generic_28 + · exact generic_29 + · exact generic_30 + · exact generic_31 + · exact generic_32 + · exact generic_33 + · exact generic_34 + · exact generic_35 + · exact generic_36 + · exact generic_37 + · exact generic_38 + · exact generic_39 + · exact generic_40 + · exact generic_41 + · exact generic_42 + · exact generic_43 + · exact generic_44 + · exact generic_45 + · exact generic_46 + · exact generic_47 + · exact generic_48 + · exact generic_49 + · exact generic_50 + · exact generic_51 + · exact generic_52 + · exact generic_53 + · exact generic_54 + · exact generic_55 + · exact generic_56 + · exact generic_57 + · exact generic_58 + · exact generic_59 + · exact generic_60 + · exact generic_61 + · exact generic_62 + · exact generic_63 + · exact generic_64 + · exact generic_65 + · exact generic_66 + · exact generic_67 + · exact generic_68 + · exact generic_69 + · exact generic_70 + · exact generic_71 + · exact generic_72 + · exact generic_73 + · exact generic_74 + · exact generic_75 + · exact generic_76 + · exact generic_77 + · exact generic_78 + · exact generic_79 + · exact generic_80 + · exact generic_81 + · exact generic_82 + · exact generic_83 + · exact generic_84 + · exact generic_85 + · exact generic_86 + · exact generic_87 + · exact generic_88 + · exact generic_89 + · exact generic_90 + · exact generic_91 + · exact generic_92 + · exact generic_93 + · exact generic_94 + · exact generic_95 + · exact generic_96 + · exact generic_97 + · exact generic_98 + · exact generic_99 + · exact generic_100 + +lemma actual_rows (k : ℕ) (hk : k ∈ Finset.Ico 3 101) : + ‖r.esymm k‖ / (((100 : ℕ).choose k : ℝ) * (7/10)^k) ≤ + (actualNumerator k : ℝ) / 10^12 := by + obtain ⟨hlo, hhi⟩ := Finset.mem_Ico.mp hk + interval_cases k + · exact actual_3 + · exact actual_4 + · exact actual_5 + · exact actual_6 + · exact actual_7 + · exact actual_8 + · exact actual_9 + · exact actual_10 + · exact actual_11 + · exact actual_12 + · exact actual_13 + · exact actual_14 + · exact actual_15 + · exact actual_16 + · exact actual_17 + · exact actual_18 + · exact actual_19 + · exact actual_20 + · exact actual_21 + · exact actual_22 + · exact actual_23 + · exact actual_24 + · exact actual_25 + · exact actual_26 + · exact actual_27 + · exact actual_28 + · exact actual_29 + · exact actual_30 + · exact actual_31 + · exact actual_32 + · exact actual_33 + · exact actual_34 + · exact actual_35 + · exact actual_36 + · exact actual_37 + · exact actual_38 + · exact actual_39 + · exact actual_40 + · exact actual_41 + · exact actual_42 + · exact actual_43 + · exact actual_44 + · exact actual_45 + · exact actual_46 + · exact actual_47 + · exact actual_48 + · exact actual_49 + · exact actual_50 + · exact actual_51 + · exact actual_52 + · exact actual_53 + · exact actual_54 + · exact actual_55 + · exact actual_56 + · exact actual_57 + · exact actual_58 + · exact actual_59 + · exact actual_60 + · exact actual_61 + · exact actual_62 + · exact actual_63 + · exact actual_64 + · exact actual_65 + · exact actual_66 + · exact actual_67 + · exact actual_68 + · exact actual_69 + · exact actual_70 + · exact actual_71 + · exact actual_72 + · exact actual_73 + · exact actual_74 + · exact actual_75 + · exact actual_76 + · exact actual_77 + · exact actual_78 + · exact actual_79 + · exact actual_80 + · exact actual_81 + · exact actual_82 + · exact actual_83 + · exact actual_84 + · exact actual_85 + · exact actual_86 + · exact actual_87 + · exact actual_88 + · exact actual_89 + · exact actual_90 + · exact actual_91 + · exact actual_92 + · exact actual_93 + · exact actual_94 + · exact actual_95 + · exact actual_96 + · exact actual_97 + · exact actual_98 + · exact actual_99 + · exact actual_100 + +-- END GENERATED COEFFICIENT CERTIFICATES + +/-- The envelopes are summed as small integers before real division. -/ +lemma generic_sum : (∑ k ∈ Finset.Ico 3 101, genericNumerator k) = 453022083 := by + norm_num [Finset.sum_Ico_succ_top, genericNumerator] + +lemma actual_sum : (∑ k ∈ Finset.Ico 3 101, actualNumerator k) = 10642552 := by + norm_num [Finset.sum_Ico_succ_top, actualNumerator] + +/-- REPORT §3.4, the actual square-root majorant, strictly below 1/2000. -/ +theorem majorant_error : majorant_Efin r μ ((a : ℂ) * μ) < 1 / 2000 := by + have h := majorant_le r μ ((a : ℂ) * μ) (1 / 10^12) + (fun k => (genericNumerator k : ℝ) / 10^12) low_endpoints + (by + intro k hk + apply norm_endpoints k + simp only [r_card] at hk + obtain ⟨_, _⟩ := Finset.mem_Ico.mp hk + omega) + (by + intro k hk + simpa only [r_card, variance_exact, norm_mu] using + generic_rows k (by simpa using hk)) + simp only [r_card, Nat.reduceAdd, ← Finset.sum_div, ← Nat.cast_sum, generic_sum] at h + linarith + +/-- Independent sharper bound using the literal elementary coefficients. -/ +theorem actual_error : Efin r μ ((a : ℂ) * μ) < 11 / 10^6 := by + have h := actual_le r μ ((a : ℂ) * μ) (1 / 10^12) + (fun k => (actualNumerator k : ℝ) / 10^12) low_endpoints + (by + intro k hk + apply norm_endpoints k + simp only [r_card] at hk + obtain ⟨_, _⟩ := Finset.mem_Ico.mp hk + omega) + (by intro k hk; simpa only [r_card, norm_mu] using actual_rows k (by simpa using hk)) + simp only [r_card, Nat.reduceAdd, ← Finset.sum_div, ← Nat.cast_sum, actual_sum] at h + linarith + +theorem C_budget_exact : majorant_Efin r μ ((a : ℂ) * μ) + Gamma r μ < + 1 - a * ‖μ‖ := by + rw [Gamma_exact, norm_mu] + have h := majorant_error + norm_num [a] at * + linarith + +def J : ℂ := (q.card + 1 : ℂ) * + (∫ t in (0 : ℝ)..1, (q.map (fun w => 1 - (a : ℂ) * t * w)).prod) + +/-- First-origin's closed-disk norm conclusion is impossible for these data. -/ +theorem norm_J_gt_one : 1 < ‖J‖ := by + exact PaperCenteredBound.C_budget q a μ (by simp) (by norm_num [a]) mean mu_ne + C_budget_exact + +/-- The literal polar product reduces to this real polynomial only because every +entry of this particular multiset is real. This is not the AM–GM relaxation. -/ +def polarReal (t : ℝ) : ℝ := + ((a + (1 - a^2) * t * (2/5)) * (a + (1 - a^2) * t)) ^ 50 + +def K : ℂ := ∫ t in (0 : ℝ)..1, + (q.map (fun w => (a : ℂ) + ((1-a^2)*t : ℝ) * w)).prod + +lemma polar_product (t : ℝ) : + (q.map (fun w => (a : ℂ) + ((1-a^2)*t : ℝ) * w)).prod = (polarReal t : ℂ) := by + simp only [q, Multiset.map_add, Multiset.map_replicate, Multiset.prod_add, + Multiset.prod_replicate, mul_one, ← mul_pow] + unfold polarReal + push_cast + rfl + +lemma polar_continuous : Continuous polarReal := by unfold polarReal; fun_prop + +lemma polar_mono (s t : ℝ) (hs : 0 ≤ s) (hst : s ≤ t) : + polarReal s ≤ polarReal t := by + have ht : 0 ≤ t := hs.trans hst + unfold polarReal + apply pow_le_pow_left₀ + · apply mul_nonneg <;> norm_num [a] <;> nlinarith + · apply mul_le_mul + · norm_num [a]; linarith + · norm_num [a]; linarith + · norm_num [a]; nlinarith + · norm_num [a]; nlinarith + +lemma polar_at_four_fifths : (17/10 : ℝ) ≤ polarReal (4/5) := by + norm_num [polarReal, a] +lemma polar_at_nine_tenths : (61/10 : ℝ) ≤ polarReal (9/10) := by + norm_num [polarReal, a] +lemma polar_at_nineteen_twentieths : (117/10 : ℝ) ≤ polarReal (19/20) := by + norm_num [polarReal, a] + +/-- Three exact positive rectangles plus the nonnegative initial interval. -/ +theorem polar_real_gt_one : 1 < ∫ t in (0 : ℝ)..1, polarReal t := by + have hi (s t : ℝ) : IntervalIntegrable polarReal MeasureTheory.volume s t := + polar_continuous.intervalIntegrable s t + have h0 : 0 ≤ ∫ t in (0 : ℝ)..(4/5), polarReal t := by + apply intervalIntegral.integral_nonneg (by norm_num) + intro t ht + exact pow_nonneg (by + apply mul_nonneg <;> norm_num [a] <;> nlinarith [ht.1]) 50 + have h1 := lower_rectangle polarReal (4/5) (9/10) (17/10) (by norm_num) + (hi _ _) (by + intro t ht + exact polar_at_four_fifths.trans (polar_mono _ _ (by norm_num) ht.1)) + have h2 := lower_rectangle polarReal (9/10) (19/20) (61/10) (by norm_num) + (hi _ _) (by + intro t ht + exact polar_at_nine_tenths.trans (polar_mono _ _ (by norm_num) ht.1)) + have h3 := lower_rectangle polarReal (19/20) 1 (117/10) (by norm_num) + (hi _ _) (by + intro t ht + exact polar_at_nineteen_twentieths.trans (polar_mono _ _ (by norm_num) ht.1)) + have hadd1 := intervalIntegral.integral_add_adjacent_intervals (hi 0 (4/5)) (hi (4/5) (9/10)) + have hadd2 := intervalIntegral.integral_add_adjacent_intervals (hi 0 (9/10)) (hi (9/10) (19/20)) + have hadd3 := intervalIntegral.integral_add_adjacent_intervals (hi 0 (19/20)) (hi (19/20) 1) + linarith + +/-- Equality for the full complex K, prior to taking its norm. -/ +theorem polar_complex : K = ((∫ t in (0 : ℝ)..1, polarReal t : ℝ) : ℂ) := by + unfold K + simp_rw [polar_product] + exact intervalIntegral.integral_ofReal + +theorem full_polar : 1 < ‖K‖ := by + rw [polar_complex, Complex.norm_real, Real.norm_eq_abs, + abs_of_pos (lt_trans (by norm_num) polar_real_gt_one)] + exact polar_real_gt_one + +theorem polar_re_gt_one : 1 < K.re := by + rw [polar_complex, Complex.ofReal_re] + exact polar_real_gt_one + +theorem polar_im_zero : K.im = 0 := by rw [polar_complex, Complex.ofReal_im] + +/-- Both actual error bounds and both literal complex integrals in one audit root. -/ +theorem diagnostic_DI02 : + q.card = 100 ∧ q.sum / q.card = (7 / 10 : ℂ) ∧ + variance r = 9 / 100 ∧ kappa r = 9 / 100 ∧ Gamma r μ = 1 / 539 ∧ + 1 < K.re ∧ K.im = 0 ∧ 1 < ‖K‖ ∧ + majorant_Efin r μ ((a : ℂ) * μ) < 1 / 2000 ∧ + Efin r μ ((a : ℂ) * μ) < 11 / 10^6 ∧ + majorant_Efin r μ ((a : ℂ) * μ) + Gamma r μ < 1 - a * ‖μ‖ ∧ + 1 < ‖J‖ := + ⟨q_card, mean_div, variance_exact, kappa_exact, Gamma_exact, + polar_re_gt_one, polar_im_zero, full_polar, majorant_error, actual_error, + C_budget_exact, norm_J_gt_one⟩ + +#print axioms diagnostic_DI02 +#print axioms mean_div +#print axioms variance_exact +#print axioms kappa_exact +#print axioms Gamma_exact +#print axioms majorant_error +#print axioms actual_error +#print axioms C_budget_exact +#print axioms norm_J_gt_one +#print axioms polar_complex +#print axioms full_polar + +end Sendov.PaperCenteredHundred diff --git a/tests/PaperConjugateBudgets.lean b/tests/PaperConjugateBudgets.lean new file mode 100644 index 0000000..593d424 --- /dev/null +++ b/tests/PaperConjugateBudgets.lean @@ -0,0 +1,100 @@ +import tests.PaperConjugateDI03 +import tests.PaperConjugateDI04 +import tests.PaperConjugateDI05 +import tests.PaperConjugateDI06 +import tests.PaperConjugateDI07 + +/-! +# Exact centered conjugate diagnostics DI03–DI07 + +All five requested families, including both m=100 cases, satisfy the literal +PAPER square-root budget with their actual mean and centered variance. Every +finite H endpoint is retained in the certificates. `K` is the complex product +integral, not the AM–GM relaxation; `J` is the actual first-origin integral. +These are finite diagnostic data, not Sendov polynomial counterexamples and +not all-parameter theorems for any of the degrees. + +The generated modules share `Sendov.Analytic.PaperConjugate`. Each endpoint is +checked by one binomial recurrence; each C*H term is checked by a squared +rational inequality. The generator and JSON are untrusted convenience data: +Lean proves the statements without reading either file. +-/ +noncomputable section +namespace Sendov.PaperConjugate.Budgets +open PaperCentered PaperCenteredBound + +/-- A single acceptance contract, bound throughout to the same actual family. -/ +def Accepted (m : ℕ) (a x : ℝ) : Prop := + let q := family (m / 2) x + 0 < a ∧ a < 1 ∧ q.card = m ∧ + (∀ w ∈ q, ‖w‖ = 1) ∧ + q.sum / q.card = (x : ℂ) ∧ + variance (q.map (fun w => w - (x : ℂ))) = 1 - x ^ 2 ∧ + 1 < ‖K (m / 2) a x‖ ∧ + majorant_Efin (q.map (fun w => w - (x : ℂ))) (x : ℂ) ((a : ℂ) * x) + + Gamma (q.map (fun w => w - (x : ℂ))) (x : ℂ) < 1 - a * ‖(x : ℂ)‖ ∧ + 1 < ‖J (m / 2) a x‖ + +theorem DI03_closed : Accepted 6 (9 / 10) (49 / 50) := + ⟨by norm_num, by norm_num, DI03.cardinality, DI03.pointwise, + DI03.mean, DI03.actual_variance, DI03.full_polar, DI03.paper_budget, + DI03.norm_J_gt_one⟩ + +theorem DI04_closed : Accepted 8 (99 / 100) (497 / 500) := + ⟨by norm_num, by norm_num, DI04.cardinality, DI04.pointwise, + DI04.mean, DI04.actual_variance, DI04.full_polar, DI04.paper_budget, + DI04.norm_J_gt_one⟩ + +theorem DI05_closed : Accepted 20 (9 / 10) (83 / 100) := + ⟨by norm_num, by norm_num, DI05.cardinality, DI05.pointwise, + DI05.mean, DI05.actual_variance, DI05.full_polar, DI05.paper_budget, + DI05.norm_J_gt_one⟩ + +theorem DI06_closed : Accepted 100 (9 / 10) (61 / 100) := + ⟨by norm_num, by norm_num, DI06.cardinality, DI06.pointwise, + DI06.mean, DI06.actual_variance, DI06.full_polar, DI06.paper_budget, + DI06.norm_J_gt_one⟩ + +theorem DI07_closed : Accepted 100 (99 / 100) (22 / 25) := + ⟨by norm_num, by norm_num, DI07.cardinality, DI07.pointwise, + DI07.mean, DI07.actual_variance, DI07.full_polar, DI07.paper_budget, + DI07.norm_J_gt_one⟩ + +/-- The exact input registry. Its length and all entries are checked below. -/ +def datasets : List (ℕ × ℚ × ℚ) := + [(6, 9 / 10, 49 / 50), (8, 99 / 100, 497 / 500), + (20, 9 / 10, 83 / 100), (100, 9 / 10, 61 / 100), + (100, 99 / 100, 22 / 25)] + +theorem dataset_count : datasets.length = 5 := rfl + +theorem all_datasets_closed : + ∀ d ∈ datasets, Accepted d.1 (d.2.1 : ℝ) (d.2.2 : ℝ) := by + intro d hd + simp only [datasets, List.mem_cons, List.not_mem_nil, or_false] at hd + rcases hd with rfl | rfl | rfl | rfl | rfl + · simpa only [Rat.cast_div, Rat.cast_ofNat] using DI03_closed + · simpa only [Rat.cast_div, Rat.cast_ofNat] using DI04_closed + · simpa only [Rat.cast_div, Rat.cast_ofNat] using DI05_closed + · simpa only [Rat.cast_div, Rat.cast_ofNat] using DI06_closed + · simpa only [Rat.cast_div, Rat.cast_ofNat] using DI07_closed + +-- Explicit rational variances, not a freely supplied variance parameter. +example : variance (DI03.q.map (fun w => w - (DI03.x : ℂ))) = 99 / 2500 := by + rw [DI03.actual_variance]; norm_num [DI03.x] +example : variance (DI04.q.map (fun w => w - (DI04.x : ℂ))) = 2991 / 250000 := by + rw [DI04.actual_variance]; norm_num [DI04.x] +example : variance (DI05.q.map (fun w => w - (DI05.x : ℂ))) = 3111 / 10000 := by + rw [DI05.actual_variance]; norm_num [DI05.x] +example : variance (DI06.q.map (fun w => w - (DI06.x : ℂ))) = 6279 / 10000 := by + rw [DI06.actual_variance]; norm_num [DI06.x] +example : variance (DI07.q.map (fun w => w - (DI07.x : ℂ))) = 141 / 625 := by + rw [DI07.actual_variance]; norm_num [DI07.x] + +#print axioms DI03_closed +#print axioms DI04_closed +#print axioms DI05_closed +#print axioms DI06_closed +#print axioms DI07_closed +#print axioms all_datasets_closed +end Sendov.PaperConjugate.Budgets diff --git a/tests/PaperConjugateDI03.lean b/tests/PaperConjugateDI03.lean new file mode 100644 index 0000000..2003a7c --- /dev/null +++ b/tests/PaperConjugateDI03.lean @@ -0,0 +1,126 @@ +import Sendov.Analytic.PaperConjugate + +noncomputable section +set_option maxRecDepth 10000 +set_option maxHeartbeats 4000000 +set_option linter.style.whitespace false +open scoped BigOperators +namespace Sendov.PaperConjugate.DI03 +open PaperCentered PaperCenteredBound +def a : ℝ := (9 / 10) +def x : ℝ := (49 / 50) +def q : Multiset ℂ := family 3 x + +theorem endpoint_0 : BR 6 0 (a*x) = (2488651484819 / 7812500000000000000) := by + norm_num [BR, a, x] + +theorem endpoint_1 : BR 6 1 (a*x) = (66349979417293 / 3906250000000000000) := by + change BR 6 (0+1) (a*x) = _ + rw [BR_succ, endpoint_0] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_2 : BR 6 2 (a*x) = (610504600660957 / 1562500000000000000) := by + change BR 6 (1+1) (a*x) = _ + rw [BR_succ, endpoint_1] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_3 : BR 6 3 (a*x) = (1971329487186931 / 390625000000000000) := by + change BR 6 (2+1) (a*x) = _ + rw [BR_succ, endpoint_2] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_4 : BR 6 4 (a*x) = (62261465177667457 / 1562500000000000000) := by + change BR 6 (3+1) (a*x) = _ + rw [BR_succ, endpoint_3] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_5 : BR 6 5 (a*x) = (765311652637904293 / 3906250000000000000) := by + change BR 6 (4+1) (a*x) = _ + rw [BR_succ, endpoint_4] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_6 : BR 6 6 (a*x) = (4568580067478491319 / 7812500000000000000) := by + change BR 6 (5+1) (a*x) = _ + rw [BR_succ, endpoint_5] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_3 : term 6 3 x (a*x) ≤ (1 / 250) := by + unfold term + rw [endpoint_3] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_4 : term 6 4 x (a*x) ≤ (1 / 1000) := by + unfold term + rw [endpoint_4] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_5 : term 6 5 x (a*x) ≤ (1 / 1000) := by + unfold term + rw [endpoint_5] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_6 : term 6 6 x (a*x) ≤ (1 / 1000) := by + unfold term + rw [endpoint_6] + rw [C_top] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem scalar_bound : scalarBudget 6 a x ≤ (65685551353840242581 / 9378906250000000000000) := by + have h := scalarBudget_le 6 (by norm_num) a x (1 / 250) (1 / 1000) term_3 (by + intro k hk + obtain ⟨hlo, hhi⟩ := Finset.mem_Ico.mp hk + interval_cases k + · exact term_4 + · exact term_5 + · exact term_6) + rw [endpoint_2] at h + norm_num [a, x] at h ⊢ + exact h + +theorem scalar_budget : scalarBudget 6 a x + (1-x^2)/(6-1)/x^2 < 1-a*x := by + have h := scalar_bound + norm_num [a, x] at h ⊢ + linarith + +theorem pointwise : ∀ w ∈ q, ‖w‖ = 1 := norm_family _ _ (by norm_num [x]) +theorem cardinality : q.card = 6 := by simp [q] +theorem mean : q.sum / q.card = (x : ℂ) := mean_family _ (by norm_num) _ +theorem actual_variance : variance (q.map (fun w => w-(x : ℂ))) = 1-x^2 := + variance_family _ (by norm_num) _ (by norm_num [x]) + +theorem paper_budget : + majorant_Efin (q.map (fun w => w-(x : ℂ))) (x : ℂ) ((a : ℂ)*x) + + Gamma (q.map (fun w => w-(x : ℂ))) (x : ℂ) < 1-a*‖(x : ℂ)‖ := by + rw [show q = family 3 x from rfl, budget_eq _ (by norm_num) _ _ (by norm_num [x]) (by norm_num [x])] + rw [Gamma, variance_family 3 (by norm_num) x (by norm_num [x])] + simpa [x, Complex.norm_real, Real.norm_eq_abs, div_mul_eq_div_div] using scalar_budget + +theorem norm_J_gt_one : 1 < ‖J 3 a x‖ := + budget_implies_J _ (by norm_num) _ _ (by norm_num [a]) + (by norm_num [x]) (by norm_num [x]) scalar_budget + +def pc : Fin 7 → ℝ := ![(531441 / 1000000), (164923857 / 250000000), (10750716819 / 31250000000), (1507058595189 / 15625000000000), (47913688539 / 3125000000000), (3275878977 / 2500000000000), (47045881 / 1000000000000)] +theorem expansion (t : ℝ) : + (a^2+2*a*(1-a^2)*x*t+(1-a^2)^2*t^2)^3 = + ∑ k : Fin 7, pc k*t^k.val := by + norm_num [a, x, pc, Fin.sum_univ_succ] + ring + +theorem polar_integral : K 3 a x = ((21948665224007 / 21875000000000) : ℝ) := by + rw [K_eq _ _ _ (by norm_num [x]), integral_coeffs _ pc _ expansion] + norm_num [pc, Fin.sum_univ_succ] + +theorem full_polar : 1 < ‖K 3 a x‖ := by + rw [polar_integral] + norm_num [Complex.norm_real, Real.norm_eq_abs] + +#print axioms pointwise +#print axioms mean +#print axioms actual_variance +#print axioms paper_budget +#print axioms norm_J_gt_one +#print axioms full_polar +end Sendov.PaperConjugate.DI03 diff --git a/tests/PaperConjugateDI04.lean b/tests/PaperConjugateDI04.lean new file mode 100644 index 0000000..24de602 --- /dev/null +++ b/tests/PaperConjugateDI04.lean @@ -0,0 +1,150 @@ +import Sendov.Analytic.PaperConjugate + +noncomputable section +set_option maxRecDepth 10000 +set_option maxHeartbeats 4000000 +set_option linter.style.whitespace false +open scoped BigOperators +namespace Sendov.PaperConjugate.DI04 +open PaperCentered PaperCenteredBound +def a : ℝ := (99 / 100) +def x : ℝ := (497 / 500) +def q : Multiset ℂ := family 4 x + +theorem endpoint_0 : BR 8 0 (a*x) = (129755236194000249690739517 / 1953125000000000000000000000000000000000000) := by + norm_num [BR, a, x] + +theorem endpoint_1 : BR 8 1 (a*x) = (9028001396067623395358316733 / 244140625000000000000000000000000000000000) := by + change BR 8 (0+1) (a*x) = _ + rw [BR_succ, endpoint_0] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_2 : BR 8 2 (a*x) = (4468813436467503875509648389119 / 488281250000000000000000000000000000000000) := by + change BR 8 (1+1) (a*x) = _ + rw [BR_succ, endpoint_1] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_3 : BR 8 3 (a*x) = (322797837513696767092920695004631 / 244140625000000000000000000000000000000000) := by + change BR 8 (2+1) (a*x) = _ + rw [BR_succ, endpoint_2] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_4 : BR 8 4 (a*x) = (24006317294496528406918441461601619 / 195312500000000000000000000000000000000000) := by + change BR 8 (3+1) (a*x) = _ + rw [BR_succ, endpoint_3] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_5 : BR 8 5 (a*x) = (1862625105278352074530902903881792131 / 244140625000000000000000000000000000000000) := by + change BR 8 (4+1) (a*x) = _ + rw [BR_succ, endpoint_4] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_6 : BR 8 6 (a*x) = (154574709880501273390612630543274814119 / 488281250000000000000000000000000000000000) := by + change BR 8 (5+1) (a*x) = _ + rw [BR_succ, endpoint_5] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_7 : BR 8 7 (a*x) = (2072872396383237544848745613388152654233 / 244140625000000000000000000000000000000000) := by + change BR 8 (6+1) (a*x) = _ + rw [BR_succ, endpoint_6] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_8 : BR 8 8 (a*x) = (262978890825066615143918380930259298289517 / 1953125000000000000000000000000000000000000) := by + change BR 8 (7+1) (a*x) = _ + rw [BR_succ, endpoint_7] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_3 : term 8 3 x (a*x) ≤ (1 / 2500) := by + unfold term + rw [endpoint_3] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_4 : term 8 4 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_4] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_5 : term 8 5 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_5] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_6 : term 8 6 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_6] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_7 : term 8 7 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_7] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_8 : term 8 8 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_8] + rw [C_top] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem scalar_bound : scalarBudget 8 a x ≤ (3039368554741189238931856523020328452468902287 / 3377076171875000000000000000000000000000000000000) := by + have h := scalarBudget_le 8 (by norm_num) a x (1 / 2500) (1 / 10000) term_3 (by + intro k hk + obtain ⟨hlo, hhi⟩ := Finset.mem_Ico.mp hk + interval_cases k + · exact term_4 + · exact term_5 + · exact term_6 + · exact term_7 + · exact term_8) + rw [endpoint_2] at h + norm_num [a, x] at h ⊢ + exact h + +theorem scalar_budget : scalarBudget 8 a x + (1-x^2)/(8-1)/x^2 < 1-a*x := by + have h := scalar_bound + norm_num [a, x] at h ⊢ + linarith + +theorem pointwise : ∀ w ∈ q, ‖w‖ = 1 := norm_family _ _ (by norm_num [x]) +theorem cardinality : q.card = 8 := by simp [q] +theorem mean : q.sum / q.card = (x : ℂ) := mean_family _ (by norm_num) _ +theorem actual_variance : variance (q.map (fun w => w-(x : ℂ))) = 1-x^2 := + variance_family _ (by norm_num) _ (by norm_num [x]) + +theorem paper_budget : + majorant_Efin (q.map (fun w => w-(x : ℂ))) (x : ℂ) ((a : ℂ)*x) + + Gamma (q.map (fun w => w-(x : ℂ))) (x : ℂ) < 1-a*‖(x : ℂ)‖ := by + rw [show q = family 4 x from rfl, budget_eq _ (by norm_num) _ _ (by norm_num [x]) (by norm_num [x])] + rw [Gamma, variance_family 4 (by norm_num) x (by norm_num [x])] + simpa [x, Complex.norm_real, Real.norm_eq_abs, div_mul_eq_div_div] using scalar_budget + +theorem norm_J_gt_one : 1 < ‖J 4 a x‖ := + budget_implies_J _ (by norm_num) _ _ (by norm_num [a]) + (by norm_num [x]) (by norm_num [x]) scalar_budget + +def pc : Fin 9 → ℝ := ![(9227446944279201 / 10000000000000000), (9218405910404503197 / 62500000000000000000), (32288565629303218449027 / 3125000000000000000000000), (16184167604918085401840673 / 39062500000000000000000000000), (40629962660741150697562618881 / 3906250000000000000000000000000000), (65392227458663513926976073 / 390625000000000000000000000000000), (527133090672889027378227 / 312500000000000000000000000000000), (608083358527578314997 / 62500000000000000000000000000000), (2459374191553118401 / 100000000000000000000000000000000)] +theorem expansion (t : ℝ) : + (a^2+2*a*(1-a^2)*x*t+(1-a^2)^2*t^2)^4 = + ∑ k : Fin 9, pc k*t^k.val := by + norm_num [a, x, pc, Fin.sum_univ_succ] + ring + +theorem polar_integral : K 4 a x = ((9844160902221705118371486810769458499 / 9843750000000000000000000000000000000) : ℝ) := by + rw [K_eq _ _ _ (by norm_num [x]), integral_coeffs _ pc _ expansion] + norm_num [pc, Fin.sum_univ_succ] + +theorem full_polar : 1 < ‖K 4 a x‖ := by + rw [polar_integral] + norm_num [Complex.norm_real, Real.norm_eq_abs] + +#print axioms pointwise +#print axioms mean +#print axioms actual_variance +#print axioms paper_budget +#print axioms norm_J_gt_one +#print axioms full_polar +end Sendov.PaperConjugate.DI04 diff --git a/tests/PaperConjugateDI05.lean b/tests/PaperConjugateDI05.lean new file mode 100644 index 0000000..cb19088 --- /dev/null +++ b/tests/PaperConjugateDI05.lean @@ -0,0 +1,294 @@ +import Sendov.Analytic.PaperConjugate + +noncomputable section +set_option maxRecDepth 10000 +set_option maxHeartbeats 4000000 +set_option linter.style.whitespace false +open scoped BigOperators +namespace Sendov.PaperConjugate.DI05 +open PaperCentered PaperCenteredBound +def a : ℝ := (9 / 10) +def x : ℝ := (83 / 100) +def q : Multiset ℂ := family 10 x + +theorem endpoint_0 : BR 20 0 (a*x) = (292099588188958046829728812997991907303491895333453 / 1000000000000000000000000000000000000000000000000000000000000000) := by + norm_num [BR, a, x] + +theorem endpoint_1 : BR 20 1 (a*x) = (920171429986559538827248474147824308778193836287597 / 50000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (0+1) (a*x) = _ + rw [BR_succ, endpoint_0] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_2 : BR 20 2 (a*x) = (55315294526463426781596334025208673196174994266735707 / 100000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (1+1) (a*x) = _ + rw [BR_succ, endpoint_1] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_3 : BR 20 3 (a*x) = (527637877172649985618760284030144888537701386060192729 / 50000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (2+1) (a*x) = _ + rw [BR_succ, endpoint_2] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_4 : BR 20 4 (a*x) = (28682623332255967880724759023147655686087755546256926157 / 200000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (3+1) (a*x) = _ + rw [BR_succ, endpoint_3] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_5 : BR 20 5 (a*x) = (92322692342579151881657605635286221403747119279055871293 / 62500000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (4+1) (a*x) = _ + rw [BR_succ, endpoint_4] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_6 : BR 20 6 (a*x) = (299461677920570523270466659540408144485095106646538331257 / 25000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (5+1) (a*x) = _ + rw [BR_succ, endpoint_5] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_7 : BR 20 7 (a*x) = (980244050146212126263124219576223387494917988491460466193 / 12500000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (6+1) (a*x) = _ + rw [BR_succ, endpoint_6] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_8 : BR 20 8 (a*x) = (42172020237463859659427060656180340455332031698401820572641 / 100000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (7+1) (a*x) = _ + rw [BR_succ, endpoint_7] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_9 : BR 20 9 (a*x) = (47145913355177626474756478785227522930480369709103693931403 / 25000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (8+1) (a*x) = _ + rw [BR_succ, endpoint_8] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_10 : BR 20 10 (a*x) = (1768330556333024226103062941608320180247202713044740625076117 / 250000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (9+1) (a*x) = _ + rw [BR_succ, endpoint_9] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_11 : BR 20 11 (a*x) = (559743313663971287089577883431885606306922668505034004509303 / 25000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (10+1) (a*x) = _ + rw [BR_succ, endpoint_10] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_12 : BR 20 12 (a*x) = (6007536663732428518134541799675856396858852606942642957105241 / 100000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (11+1) (a*x) = _ + rw [BR_succ, endpoint_11] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_13 : BR 20 13 (a*x) = (1713850710179293040101478567083627490139292638312266906250893 / 12500000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (12+1) (a*x) = _ + rw [BR_succ, endpoint_12] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_14 : BR 20 14 (a*x) = (6676906364584069482009808174559063649176863034483343943951657 / 25000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (13+1) (a*x) = _ + rw [BR_succ, endpoint_13] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_15 : BR 20 15 (a*x) = (27884685314197362577256420364071419023909940455670624798845793 / 62500000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (14+1) (a*x) = _ + rw [BR_succ, endpoint_14] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_16 : BR 20 16 (a*x) = (128886663964378659476741000086636281490059321569553012365356757 / 200000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (15+1) (a*x) = _ + rw [BR_succ, endpoint_15] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_17 : BR 20 17 (a*x) = (40830938894586144503122642438085768302740356882512944650790629 / 50000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (16+1) (a*x) = _ + rw [BR_succ, endpoint_16] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_18 : BR 20 18 (a*x) = (92959421678338973743269847256620800292575080542580820517936507 / 100000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (17+1) (a*x) = _ + rw [BR_succ, endpoint_17] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_19 : BR 20 19 (a*x) = (49113140822071769011813001878215413660202505524930996992466497 / 50000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (18+1) (a*x) = _ + rw [BR_succ, endpoint_18] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_20 : BR 20 20 (a*x) = (997813584798969014692489479877976613875152711640671467832912453 / 1000000000000000000000000000000000000000000000000000000000000000) := by + change BR 20 (19+1) (a*x) = _ + rw [BR_succ, endpoint_19] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_3 : term 20 3 x (a*x) ≤ (1 / 50) := by + unfold term + rw [endpoint_3] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_4 : term 20 4 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_4] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_5 : term 20 5 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_5] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_6 : term 20 6 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_6] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_7 : term 20 7 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_7] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_8 : term 20 8 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_8] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_9 : term 20 9 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_9] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_10 : term 20 10 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_10] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_11 : term 20 11 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_11] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_12 : term 20 12 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_12] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_13 : term 20 13 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_13] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_14 : term 20 14 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_14] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_15 : term 20 15 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_15] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_16 : term 20 16 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_16] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_17 : term 20 17 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_17] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_18 : term 20 18 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_18] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_19 : term 20 19 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_19] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_20 : term 20 20 x (a*x) ≤ (7 / 1000) := by + unfold term + rw [endpoint_20] + rw [C_top] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem scalar_bound : scalarBudget 20 a x ≤ (18193849001759092019915918114883051985586361981871865429310238841393 / 130891000000000000000000000000000000000000000000000000000000000000000) := by + have h := scalarBudget_le 20 (by norm_num) a x (1 / 50) (7 / 1000) term_3 (by + intro k hk + obtain ⟨hlo, hhi⟩ := Finset.mem_Ico.mp hk + interval_cases k + · exact term_4 + · exact term_5 + · exact term_6 + · exact term_7 + · exact term_8 + · exact term_9 + · exact term_10 + · exact term_11 + · exact term_12 + · exact term_13 + · exact term_14 + · exact term_15 + · exact term_16 + · exact term_17 + · exact term_18 + · exact term_19 + · exact term_20) + rw [endpoint_2] at h + norm_num [a, x] at h ⊢ + exact h + +theorem scalar_budget : scalarBudget 20 a x + (1-x^2)/(20-1)/x^2 < 1-a*x := by + have h := scalar_bound + norm_num [a, x] at h ⊢ + linarith + +theorem pointwise : ∀ w ∈ q, ‖w‖ = 1 := norm_family _ _ (by norm_num [x]) +theorem cardinality : q.card = 20 := by simp [q] +theorem mean : q.sum / q.card = (x : ℂ) := mean_family _ (by norm_num) _ +theorem actual_variance : variance (q.map (fun w => w-(x : ℂ))) = 1-x^2 := + variance_family _ (by norm_num) _ (by norm_num [x]) + +theorem paper_budget : + majorant_Efin (q.map (fun w => w-(x : ℂ))) (x : ℂ) ((a : ℂ)*x) + + Gamma (q.map (fun w => w-(x : ℂ))) (x : ℂ) < 1-a*‖(x : ℂ)‖ := by + rw [show q = family 10 x from rfl, budget_eq _ (by norm_num) _ _ (by norm_num [x]) (by norm_num [x])] + rw [Gamma, variance_family 10 (by norm_num) x (by norm_num [x])] + simpa [x, Complex.norm_real, Real.norm_eq_abs, div_mul_eq_div_div] using scalar_budget + +theorem norm_J_gt_one : 1 < ‖J 10 a x‖ := + budget_implies_J _ (by norm_num) _ _ (by norm_num [a]) + (by norm_num [x]) (by norm_num [x]) scalar_budget + +def pc : Fin 21 → ℝ := ![(12157665459056928801 / 100000000000000000000), (2130293158770308524353 / 5000000000000000000000), (3630393128091859956309681 / 5000000000000000000000000), (62405833489723492505389989 / 78125000000000000000000000), (397188825899772937523374681101 / 625000000000000000000000000000), (303353024944630782431102935758759 / 781250000000000000000000000000000), (29519311958993848987503741418820109 / 156250000000000000000000000000000000), (1463195330075473757311721695309936161 / 19531250000000000000000000000000000000), (1920315069256239723479669645324688779049 / 78125000000000000000000000000000000000000), (131581328694644435975289506772275187759633 / 19531250000000000000000000000000000000000000), (151432591335625019536292532087062857758306249 / 97656250000000000000000000000000000000000000000), (586430366157612856630611258577670898533673 / 1953125000000000000000000000000000000000000000), (38143176366490232739459537852211365092889 / 781250000000000000000000000000000000000000000), (129529549617900123259421344575728095401 / 19531250000000000000000000000000000000000000), (11646487442853481016835261705761377389 / 15625000000000000000000000000000000000000000), (533407656322680347011077755894629359 / 7812500000000000000000000000000000000000000), (3112648786680566528459482616004381 / 625000000000000000000000000000000000000000), (2179618418460993575008088582829 / 7812500000000000000000000000000000000000), (565107564382138438609292267121 / 50000000000000000000000000000000000000000), (1477879482778254251075612313 / 5000000000000000000000000000000000000000), (37589973457545958193355601 / 10000000000000000000000000000000000000000)] +theorem expansion (t : ℝ) : + (a^2+2*a*(1-a^2)*x*t+(1-a^2)^2*t^2)^10 = + ∑ k : Fin 21, pc k*t^k.val := by + norm_num [a, x, pc, Fin.sum_univ_succ] + ring + +theorem polar_integral : K 10 a x = ((1182519467309602248471006652606768554894193590679433 / 1173046875000000000000000000000000000000000000000000) : ℝ) := by + rw [K_eq _ _ _ (by norm_num [x]), integral_coeffs _ pc _ expansion] + norm_num [pc, Fin.sum_univ_succ] + +theorem full_polar : 1 < ‖K 10 a x‖ := by + rw [polar_integral] + norm_num [Complex.norm_real, Real.norm_eq_abs] + +#print axioms pointwise +#print axioms mean +#print axioms actual_variance +#print axioms paper_budget +#print axioms norm_J_gt_one +#print axioms full_polar +end Sendov.PaperConjugate.DI05 diff --git a/tests/PaperConjugateDI06.lean b/tests/PaperConjugateDI06.lean new file mode 100644 index 0000000..f58c940 --- /dev/null +++ b/tests/PaperConjugateDI06.lean @@ -0,0 +1,1254 @@ +import Sendov.Analytic.PaperConjugate + +noncomputable section +set_option maxRecDepth 10000 +set_option maxHeartbeats 4000000 +set_option linter.style.whitespace false +open scoped BigOperators +namespace Sendov.PaperConjugate.DI06 +open PaperCentered PaperCenteredBound +def a : ℝ := (9 / 10) +def x : ℝ := (61 / 100) +def q : Multiset ℂ := family 50 x + +theorem endpoint_0 : BR 100 0 (a*x) = (11798606843134026065535641213084405931032342651815197222442756056107691557325415922528849187278842483379312597361996616150516435378784841453968959274615951872994236591999818904304407027078195869397751397459695718333260476195440487838850570164802200772404290475597670451 / 1000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + norm_num [BR, a, x] + +theorem endpoint_1 : BR 100 1 (a*x) = (14623993847698271775242624031295305799217471269101319838903549080630154280587378050318462739886636248800522709368860550838444983096986089518334031562107133252779996130660529417973755051300912396881026676673990923610404891781044861866779309805153947298833699281284030559 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (0+1) (a*x) = _ + rw [BR_succ, endpoint_0] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_2 : BR 100 2 (a*x) = (1795056916923233661401573922767976308984027883908082719235864241069890790466441722000892504672589781446100943707870111564568233755554467603866622329461060071382162989343926745018422084068353844874624578923628976873487480642426981272874700848618013656198377232423743574669 / 20000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (1+1) (a*x) = _ + rw [BR_succ, endpoint_1] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_3 : BR 100 3 (a*x) = (36364446829659759917295214366747039905639228264346632713668177417736340562281692724875091849050548430213042331392972215445479765915298404103091051123959615897054070960465275142540133277663366886744392528660019351952124312327926617239308829097183292064152470279252799480243 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (2+1) (a*x) = _ + rw [BR_succ, endpoint_2] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_4 : BR 100 4 (a*x) = (4376480275582946122473955543195021220188460294373054380146493768384979647786913651653787911507998798890786852312089133350028598242190492961296818140829415575590547900778916000461964697459482022889881186587681802611477023934689044911280275883036144020296828639509312731698939 / 40000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (3+1) (a*x) = _ + rw [BR_succ, endpoint_3] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_5 : BR 100 5 (a*x) = (16295981401675352590547494185766332970194084723462756208811508473351344021168462794157938354146067205280851997300773546039143216139853127746733380708089129300749504650291396907218679154437312847789102575096598770590343732022527937939576351261912491329647111843317539758055653 / 6250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (4+1) (a*x) = _ + rw [BR_succ, endpoint_4] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_6 : BR 100 6 (a*x) = (128147821788234401437348651727287732465661827642706462484809949493828184007896421212553203363187762562564135911551486795697182572030276880844082383983072936775985497518068282241712155604403942415003104525432812747066582838028988729695126762974984256994619672341739199948015221 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (5+1) (a*x) = _ + rw [BR_succ, endpoint_5] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_7 : BR 100 7 (a*x) = (1068759194607074755552522458130548276800205577300047487002151130286913014709399806667250534444163172129233188338936822921465625063197506949983454709303068556142076919972285984332465420695425980713980909025827446169415755305607451183972348697124851255743950787027397547211286169 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (6+1) (a*x) = _ + rw [BR_succ, endpoint_6] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_8 : BR 100 8 (a*x) = (123511911142867435239000150205545204422250728617250703094991621687078418098024500152501243242615724054416050691841008263850174324464057459822542373759521942951658273319048963308757975581412007035493163647189121386885947841406092712814913315073188510978745736916844415954468553853 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (7+1) (a*x) = _ + rw [BR_succ, endpoint_7] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_9 : BR 100 9 (a*x) = (392395995870772002604013991473925736633904064374644096786930745185547102091314100946857602750867401721358522958569859111059130618153953563489578929255156272330378739950018638686191370181666251871749902771706223146528148526597130381787765004566459086387558442550057534934882711919 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (8+1) (a*x) = _ + rw [BR_succ, endpoint_8] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_10 : BR 100 10 (a*x) = (44410771616002543092028352297709593973136083954576816605416622021232131435778633797047845653487170643615502758422882698945931479278462447030799137419731051479871814850045441692987117177357925571269986637074669510695070537123916156675133801755672493762177534306363793828803331740261 / 25000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (9+1) (a*x) = _ + rw [BR_succ, endpoint_9] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_11 : BR 100 11 (a*x) = (45212708356657542467914891316060317319889167491724054095055395090079040147534024520093269371723635688800441584513461034324058169249135737354318280383492155315078132571515134974352310597690760524118930299988392209344875552841016225703708906950013627543850632166738889602897821510331 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (10+1) (a*x) = _ + rw [BR_succ, endpoint_10] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_12 : BR 100 12 (a*x) = (1669783795250562622142141968238045537538579859136535138767009120636663102397581716666178719972470839306218484417464521366017494098640972980383782874495872737118378970185904066636284571776258213751369543926221504544242737645174369397928228811780391202904700783176064967111564751449177 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (11+1) (a*x) = _ + rw [BR_succ, endpoint_11] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_13 : BR 100 13 (a*x) = (1759779461010430074279537332668486937958230124512519889675332604463059519294956122602227002658330631857231511943921191984511131720605929565219272386846343571180838312769619011228823211526285209991771420524211459315110432315901897827814018204970400493904070073028544766345397143762571 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (12+1) (a*x) = _ + rw [BR_succ, endpoint_12] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_14 : BR 100 14 (a*x) = (27255587107265633690997025970275327992306238521474620142664159256216116827883204677327272396990883020989190732990678108589333365381098090782746375871012920006292867618752148700972180622070963740312317054730796170606443010151805211893595180446744160565619969521589176455494749712123099 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (13+1) (a*x) = _ + rw [BR_succ, endpoint_13] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_15 : BR 100 15 (a*x) = (487098285658720669115690594555315299899880518560526648986720418902074720898242943857206641761707013093017256052683178166905676045365083025334241747771141421331306993662116237509226348431642863954943114428442361318659602845583440466457574314985980454449905949843713912200778752678338871 / 6250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (14+1) (a*x) = _ + rw [BR_succ, endpoint_14] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_16 : BR 100 16 (a*x) = (10330663620486947648447984523833420591564802554930026038052252045690668606967702603130568919605717891472492292141459289169549438299983838546962886853768610886971290924900034117830571532331784869170638303674043547927765269260238730112383708576787347735408171950116438934884285909539483263 / 20000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (15+1) (a*x) = _ + rw [BR_succ, endpoint_15] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_17 : BR 100 17 (a*x) = (15930227045371442531556281793568582381552416014701051625784725819507512483092356707740352065313215065486153984765706680248215380501253580211506323099901759506533284458787405770679302867355229226656951053992685963056558674700730621054221175071272456236406066346532680615919366520710454471 / 5000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (16+1) (a*x) = _ + rw [BR_succ, endpoint_16] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_18 : BR 100 18 (a*x) = (183507689750697411879149192711781963754856644859696615836438631746834864163168324803177611440271639391670291099700530167959097677246728995955382804745743707849577269343361338069118662850921496457709976461981099397967528301162387825274441841003599177010033453516866463671714705994858360493 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (17+1) (a*x) = _ + rw [BR_succ, endpoint_17] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_19 : BR 100 19 (a*x) = (494957811926180070359363432820046049893366871574324329329978793640544670539336071615218457685277799529084357668674873881135071266707181534954206224082689603061985687204170729385267845990426810123260165036249232958990179358825454714079927117261378283344995949887044787144401433961910704043 / 5000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (18+1) (a*x) = _ + rw [BR_succ, endpoint_18] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_20 : BR 100 20 (a*x) = (50146243131415677601089827059822945059821930791544183996609749199020503213205957461083038049862455432118744872143444792102407209519237367662739876685051963747843564987781058793621534100929694017015829130922624133678625759781254399734697760894501875388199663270033212809140883306420097092547 / 100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (19+1) (a*x) = _ + rw [BR_succ, endpoint_19] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_21 : BR 100 21 (a*x) = (2988969981704222915777867466114134068040112341166614814641581317056195655469399522328260057693813320482668213995422015565410114030043858222693771799198923616021820643220442598494451526419044845964534761036357041180390650095619099630558008186964822274308570028079204421569226452079051704163 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (20+1) (a*x) = _ + rw [BR_succ, endpoint_20] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_22 : BR 100 22 (a*x) = (26890109710899327399377872415777949940248637103111291641965988502857776701820870476731221555528282356217422101014868165936018907796726486510669999780764950057706258797416502541914943935505706627913886396057854295876844958743885284590638017752767270974642292343598526634531736685671370399463 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (21+1) (a*x) = _ + rw [BR_succ, endpoint_21] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_23 : BR 100 23 (a*x) = (57163444623039899141606121438730257604299013196381893172379255735732181023615839657555424532721259611840428380340893581215202741224004817366072752087694902323358739350917038500630050735813068012240828893662278936254492899457108782169352495900463780851397926267170195001952945894557072583931 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (22+1) (a*x) = _ + rw [BR_succ, endpoint_22] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_24 : BR 100 24 (a*x) = (1840980052644148507318937445977754407442395634086021563768901532420104010517523042492184863087175639030170285504019390064312391294063009334619647814627141451850224851520924398728646590665421405746051208576062008488757870415824634072348066073149874315385090193022782134000597724525128606219261 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (23+1) (a*x) = _ + rw [BR_succ, endpoint_23] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_25 : BR 100 25 (a*x) = (43929621675493757770847859082362106192945201737934073467898687935864122864690590222073609400453589056661261095782719259586539803312853203267231127264761173844985082284141869154559032460594112440264909999033638742116251118800761989421803734817864205419507568380957457031554075331744289119237731 / 62500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (24+1) (a*x) = _ + rw [BR_succ, endpoint_24] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_26 : BR 100 26 (a*x) = (12744033466326887435481645270185268090821288155645873809089882811223501577861197175261367319001781393896993002676279638279921464420008340135753471556828189868041686934552371456474279176789903072479842643915575101500650101601323959640995003894178293058694406514594303717158856932414749044082749 / 5000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (25+1) (a*x) = _ + rw [BR_succ, endpoint_25] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_27 : BR 100 27 (a*x) = (21976492555489679738878372778090812407897506411893891001860275506432612115700081608895212278816166484953197693572989817706836981917703314090517363935689179567807309694024587540063163739627901057104046612522253297147563153293262950710804957923632898029711999922795492668798563312615012016142471 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (26+1) (a*x) = _ + rw [BR_succ, endpoint_26] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_28 : BR 100 28 (a*x) = (288712886521555065041903770526187764726424130552221297665196174303192694982070841868552892095404797128751337063722753075635049708039829862337298521158486077894988813349389630491973927422239766165263178548433006034055629601410114534357198516047736042056706798972948075761023386056971508576242721 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (27+1) (a*x) = _ + rw [BR_succ, endpoint_27] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_29 : BR 100 29 (a*x) = (113003809803447716356251649999807466800907634621874659950731619345662050915812648021695311589483861335977797013322385224324385268209553609671790490604193984234555118510307187275966438883747872998876959386806020024343694979685179018710753145540673163412906523076903127880602483195635084520939969 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (28+1) (a*x) = _ + rw [BR_succ, endpoint_28] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_30 : BR 100 30 (a*x) = (3377106997966241949784148939778189821145081780272653566816100489290511449803972985264294162950066232188580633777535101467472618590715222521919636258265517150508415189327823043774858934885889106394566404979561217765971103009289617487432536975835308884375318557050251084075232818097937982732311597 / 12500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (29+1) (a*x) = _ + rw [BR_succ, endpoint_29] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_31 : BR 100 31 (a*x) = (964193059073072657907626043896917104953277620942559253246441627981402442995091890617412226345544620174211035455513385574193174643222060533916720698842236000115431147862591158500948222438027348962334502598772931461246697298050870555977131032400679251482726823197448159616939332820543566054545681 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (30+1) (a*x) = _ + rw [BR_succ, endpoint_30] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_32 : BR 100 32 (a*x) = (84237142562165186317721604339049331528557898706602571148202046913546475476740308956645149979736308606094076232022796437435703602540767103752036646212159416915073352030433414331375481258874789101934828785010822490088239387372206473006341155291861673058149791825098425050043297764100218006951486301 / 40000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (31+1) (a*x) = _ + rw [BR_succ, endpoint_31] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_33 : BR 100 33 (a*x) = (55027573027719172873982088657228166187685706199515811290607105984014211548001398117266722637447896309106541268822837286482985488936108302419587517694137803746808533772491073240863980136559701068016178200599665398997922235842710163621506992833970723880045454924983743530170456888641126730094678241 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (32+1) (a*x) = _ + rw [BR_succ, endpoint_32] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_34 : BR 100 34 (a*x) = (275452838078149246729861086203890855521667475423891733520926586658401357736092908536794056301415408738063008867921584632754074871239872241543268317175085135523808353353590688319892397454411739893019731845868784609838402800384422911793674877038601428096356061298493574509965199486738782536622942819 / 20000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (33+1) (a*x) = _ + rw [BR_succ, endpoint_33] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_35 : BR 100 35 (a*x) = (1652177123017890549643327723377967567199830406368318098562443213278247242117621343374619295867328677014058352104320717953311513676316734339190236549029606229613215223880975136135999997886817449148967864771668559491178969149287856783368723075917217231423791810789967714333121757229824388875364231649 / 50000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (34+1) (a*x) = _ + rw [BR_succ, endpoint_34] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_36 : BR 100 36 (a*x) = (3042022089551099661234833168359817940554070123718769053982668664609920956067386832572593489238483413766454992688496246713585969469577493164676755418392626354588875245553079718728675391264519541691902018000070237133281537008638132345825418135345389394860701773807615941072860360007028976014307561437 / 40000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (35+1) (a*x) = _ + rw [BR_succ, endpoint_35] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_37 : BR 100 37 (a*x) = (105012910841949807528851953285441293254364364923290424261232260189709221665056751779859728531170741327810798676746660552331893184654617310729580063981656218912486615843126210563282476302316691978770485523159949008575203980777070597399883228910439278953075620883229145215105586355481713757535260909 / 625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (36+1) (a*x) = _ + rw [BR_succ, endpoint_36] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_38 : BR 100 38 (a*x) = (445720010991776231152442945106035490047200176692552156283716894886919506177871545274598392303243311706406570083121775500856422814311754178278740756200203678231069301759241307667520758130829913421565427979417039828228340421682606342703155718492202601262055051024569866416784815439676998147921971937 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (37+1) (a*x) = _ + rw [BR_succ, endpoint_37] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_39 : BR 100 39 (a*x) = (454594468102958685843682360773363798656129280797854042254043218524559851466200181892871364358372226135183495735735069119497365899261799651869452679220954569001419146178229631569619110253502948198991648322104643736382418832095019245901993583813702775631045862279875617120144712599536499741379062757 / 625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (38+1) (a*x) = _ + rw [BR_succ, endpoint_38] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_40 : BR 100 40 (a*x) = (35673307855425371980895484482473662752329491969534584622424578492775044055466911848311673779260334524915194400622974351122191488747193476518695050329706442671045095006716884562503521599009605853182849318263563271988260492907379456633301584667031523455509293796949463041764158689114853663086595986393 / 25000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (39+1) (a*x) = _ + rw [BR_succ, endpoint_39] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_41 : BR 100 41 (a*x) = (3367427333927347083332929912393634145633774412392067351229796809928309435328286631925872149170004568069453792105945967177593483643567088226119530271918552235112711608335499362645433122560534592393605686920614142865289458251593694702175495770533813474374153091476401782600832614380928505255744746271 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (40+1) (a*x) = _ + rw [BR_succ, endpoint_40] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_42 : BR 100 42 (a*x) = (12243155622524868939388048439676106450288756286548598610851128425203257582551806907761458360130546514417070685694715437948437940706252773257443007251045487908658687803568753992010037080679636245631179117478113636487412378966395322929281106706813894155448844241199758384026061486468078209964620983681 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (41+1) (a*x) = _ + rw [BR_succ, endpoint_41] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_43 : BR 100 43 (a*x) = (10721675171720373701974857804762107182986278078663685951553295968389360821312476262623047237494688412672052617640585587403265334505621371136465561733942966404550863863476874052785832817000921244245924194539148433681353605629378452853440928755193347869046990270052700146391956623277410704824686146187 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (42+1) (a*x) = _ + rw [BR_succ, endpoint_42] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_44 : BR 100 44 (a*x) = (72412260080491996931319367322888728293646740563529738683455521016833589888842840220008998380470073420950116752353505781686775171391512958179320480817714361739943757534176089495161611493249168869865114934404631875980316463421905820968728753025950286053348455943116812443929801472416443561524288947921 / 5000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (43+1) (a*x) = _ + rw [BR_succ, endpoint_43] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_45 : BR 100 45 (a*x) = (73711201910502541286933561847607207283317616793818713392284868664116105027725399190834323098053862085765842965173234698177378328745002839943986131777012179805671896777345061158570120360436647255292274142560109062494154107882751841326800658319711185558505490241145403351603738725983599338125135623147 / 3125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (44+1) (a*x) = _ + rw [BR_succ, endpoint_44] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_46 : BR 100 46 (a*x) = (46350876485589937912443988362556409695470972115791027162173914030210755194513942533665986550430172525065588756970929162518882198569213819286613378700201979704251936065676345115304061168728433188866114183665959975529976172182222538513503189192871767046994256465238354718287195058486716801029095172111 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (45+1) (a*x) = _ + rw [BR_succ, endpoint_45] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_47 : BR 100 47 (a*x) = (35188478267499844212217245127449619226818276721682078774506419448870047988668046498638142813167261408130652593878559768731047282499572871159460542967354508498089595910045409244055677639994758996385980398950795343813561874929964239273030559697471202361265733762536569892002301554779436642746895103759 / 625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (46+1) (a*x) = _ + rw [BR_succ, endpoint_46] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_48 : BR 100 48 (a*x) = (826237074728187257461429513724484188990724661115735515916207207347026029033598379101710257813433155454254598673929609609218735017843040953413081284918247016810703092615187552195447028944441687215122001507244324943305252041685514413071080381164929527702268059151014548448776765409392328168074619154481 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (47+1) (a*x) = _ + rw [BR_succ, endpoint_47] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_49 : BR 100 49 (a*x) = (293202937275365258159975366318207468768784078308392464989559839812638535693738588091736885108612142444884122101963313227988662762016959764433989487795112314271439295606290800011420168980324862871395764994711749240852123688048518986940009820193703548786747484859936146839473729450072099925207539853473 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (48+1) (a*x) = _ + rw [BR_succ, endpoint_48] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_50 : BR 100 50 (a*x) = (20144633451355967860213301172230868253482321345940651438897024070754942633405460626746486131408848834083533925566043803864236314836356600351527347487567893737614228724824065940054639354723191843344246285903721098866279894435462764586634858341205680480474802313109149443291593908454437063952785619794307 / 125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (49+1) (a*x) = _ + rw [BR_succ, endpoint_49] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_51 : BR 100 51 (a*x) = (536417420095219136306961302296943380744088620681830522170004721414546112133584762023428320850441043191639236091669661009132927805720224160435225545347763224428524171194296384910915996284402410533234258838087963734141423467784076203775236752855366654823883984643188568183948560312636714900480649703613 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (50+1) (a*x) = _ + rw [BR_succ, endpoint_50] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_52 : BR 100 52 (a*x) = (2770819674721544963506710193751367097982910549381736244165634336448705900406640571794768463548642669389213759236297294280303352263621196763002786446975451132169627459014781235484470243412181337023144982503020748203595271245450450139263954283561650158632897171483994789925339341854400155850961406438041 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (51+1) (a*x) = _ + rw [BR_succ, endpoint_51] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_53 : BR 100 53 (a*x) = (217148638985240896495263776280655562336152563514365447436016657913884331240421476584247887256135171746371970735453775507754758672536638392116370207376009562914014032000679511163867562079356209636619144309997303795775897454102065988171294810975131785585273019120317555893876655230750283561950705617419 / 625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (52+1) (a*x) = _ + rw [BR_succ, endpoint_52] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_54 : BR 100 54 (a*x) = (529457081721215434244337139769928499091656254473819067385223035562979410520413432695646687340475941700542176779973515415665038356857902212530761144538012062284193075603934515745433695647201552414986494637451598421392070671466080858737451094709616039140878054207167822135819642284325106479899732498431 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (53+1) (a*x) = _ + rw [BR_succ, endpoint_53] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_55 : BR 100 55 (a*x) = (1571113820628394375297604467923506403155719666769672654892994530887658456926415267209694727190757386055005700534879271245997196644722732746240612687052344783747010182900307510554561485652723201986521765707561946505240772880988127667145442953626446037283607855532477459503140675961199945095418015338447 / 3125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (54+1) (a*x) = _ + rw [BR_succ, endpoint_54] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_56 : BR 100 56 (a*x) = (2909704543900618527416267111526251037899504766698232434544130339237689171754636241591512642709167373479544352424017997774298777691778370277129156918758729393395562528352241159741713288921949884106369467656220921865386319694374362587971323960923673152488799292402654167181416688449752526396014845958601 / 5000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (55+1) (a*x) = _ + rw [BR_succ, endpoint_55] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_57 : BR 100 57 (a*x) = (822548706240701057468249389448214554582901031924375391796285164009054178250159290551664159254855561480029997312569411735968537674809692130715720623708133792040157152425504979846914691681764644157691146852967095456672286517223923993055250655921908935324220043325892099979669287146833673035984528573607 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (56+1) (a*x) = _ + rw [BR_succ, endpoint_56] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_58 : BR 100 58 (a*x) = (1820782159582444966617529069056536209298032971492652174526056168154686674535688224011414149356077754557937223067204885199520658008236506748317745150918807004051736742749267772179636000112902435662642950346683102199093312882733980894397358827283191681628790299952542748128182975147773829667940355983521 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (57+1) (a*x) = _ + rw [BR_succ, endpoint_57] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_59 : BR 100 59 (a*x) = (988323167145394353721671484428859038408676281994767970380897982008573454030235993702335700496186441489030765914297950119829960253356751824832046619015802616747679966914943032982832333582747807132437306683698188867269428841654313149403344101660260532381404949017780018632130680534217850950511469502691 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (58+1) (a*x) = _ + rw [BR_succ, endpoint_58] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_60 : BR 100 60 (a*x) = (21094591997906035624308380502182373488521075959109382276008088321988397411947832962118305180740319026052317576756082440975878996157261642021860479384250605762341279877817299912471964116185145910649580459591039426752743851042860902210117996871589815568657006553377851907343166242819841664224722442277793 / 25000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (59+1) (a*x) = _ + rw [BR_succ, endpoint_59] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_61 : BR 100 61 (a*x) = (554531067890794838218788051923756461038317700961657751935454840177783469348895864490785630739756411484138212887609131358973152448956857981744184536959471918709643644344673300710294232451837074838983849974443442133969045066726003812067631816211248671692016455100810533620635914455085500257732691670617 / 625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (60+1) (a*x) = _ + rw [BR_succ, endpoint_60] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_62 : BR 100 62 (a*x) = (1151732276975455715314572364812219941546157325359904686545550106758005591708477151198487283711013835119692834141773392146978052189863931242016434966893439279185857045994784555190057962425789667775204354918009074667387618453512976682117554913553762065733220003843660879928330438031520296846231229008657 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (61+1) (a*x) = _ + rw [BR_succ, endpoint_61] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_63 : BR 100 63 (a*x) = (591943469165619417126461682063227170538360996518350453121202290377957746046259579630609371486286282131943286805450309141538840286815013157849881841917787846112198312770853932966832581878893062831746301971443829535196886178518453084318180522632325881531278373124619910091265699075894766093513452141769 / 625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (62+1) (a*x) = _ + rw [BR_succ, endpoint_62] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_64 : BR 100 64 (a*x) = (38628074427047921440319577084079308363464682598763478595450713808739624285554719939158006097865823395032141744467813345647521751019274229493946322242879053912610861317232560921333087273717127312213436775348698912664479188524201193569041306796309855160445965680491403571321204774148902266880292619539477 / 40000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (63+1) (a*x) = _ + rw [BR_succ, endpoint_63] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_65 : BR 100 65 (a*x) = (48929243798363282583763932205042920454234126939522844084213080715311824558054695007427646434966116131506934822709596811525762742786792012438157534093362447484995668962284613389953145153285540166776719761319510704392448185043806721573087545304814839309386896589693054131066025124954293755187305215236949 / 50000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (64+1) (a*x) = _ + rw [BR_succ, endpoint_64] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_66 : BR 100 66 (a*x) = (19742778560944896690058891490339266773887271702104612360283061253570950109330372742336797517652308876157621715671961316544366106178843493064758432743854263213341183294493401648093064010549636151477766233194460237199247466945230886681339254646840610350804480359483395093492036020878015711767111444533539 / 20000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (65+1) (a*x) = _ + rw [BR_succ, endpoint_65] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_67 : BR 100 67 (a*x) = (9925784525108514135158711010730561415023862645551554068276972325324031542694685103949824343803808514734441797692531202734124713233830428923742595895565743915547616589490655785706001034539116267630854690302922182401840752486844404282708593879104778699556861798682899894266883798418826668128904673559101 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (66+1) (a*x) = _ + rw [BR_succ, endpoint_66] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_68 : BR 100 68 (a*x) = (39835568208217649085118066352425347599856180117372899601650494589534119571790690767448976515582116932924203492239066047786192739495323341561305174528948555074933201139745023470766569535345377298233806317594947900460654111671598014280188666598772888477876614683861178684779088708535264667738219910464741 / 40000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (67+1) (a*x) = _ + rw [BR_succ, endpoint_67] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_69 : BR 100 69 (a*x) = (1247270842706867556806323754581598149244201297901947026502064776682573340845512398487541712031261763174909776732764051633512118805193889305836710624686137013960026844842858394517939537211273979495210833972244338379270070325852131677532258033100976126218353678367352546059130551822868223788916670310101 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (68+1) (a*x) = _ + rw [BR_succ, endpoint_68] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_70 : BR 100 70 (a*x) = (12486115844985292574792308592064952177776534840629759615759372019947436546580202409107170268843065670799280611927561833681627709808896046307585602109418639168777152890772365506611234179468789568484418844272573931557704658968645782873220309555840813783897118019060874979508976038798301703500634974612797 / 12500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (69+1) (a*x) = _ + rw [BR_succ, endpoint_69] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_71 : BR 100 71 (a*x) = (1249324181998678861918573978209996770176729801363327338672912149884810378707084010630589007256061650233468118755749409375845836762038393835182062228632948397710797942099468268577517236573382223753742757219920557305586531360874472695741884969129566162959348724691313760286426895874378603207380815823789 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (70+1) (a*x) = _ + rw [BR_succ, endpoint_70] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_72 : BR 100 72 (a*x) = (9997484926998907117353021776403716602412307725007822745053949426659019847860190263730667100355171255461931879847054263020203524206068313085214831958497477647150998292961342698036990859519432465055885732283917873952815088579098013866175285617311999715564890836769898242100769056906389429049048062296281 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (71+1) (a*x) = _ + rw [BR_succ, endpoint_71] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_73 : BR 100 73 (a*x) = (2499720798237758481571743653297180277498686611033607338997992521103822837634171073228926914114433105540550932399593199659630717124911874209023815799322126072030301372384645599662375589667471161863461525423631223555366725846563219868847107234637584143784324026248410372057591523720558814044543509134611 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (72+1) (a*x) = _ + rw [BR_succ, endpoint_72] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_74 : BR 100 74 (a*x) = (4999763615775212733907146487499542572294629289521133848957500796253151241564606696955733066983713850778419820009488858262223095430396937316869079267528648103864552301696619788613052353376722615987686621270044419837552467951524962452154938972392500854916688649715244984234799600263145285166885970688029 / 5000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (73+1) (a*x) = _ + rw [BR_succ, endpoint_73] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_75 : BR 100 75 (a*x) = (62498809163220976028987047294245949944664841982971838991925355674604349503005303383798128213890327999191941781930256459582859167262680260085117119371777503113596609714420530683243527034659627405012859707626071575290040837567839304190906182576084464916244271747666985995208859069246786855740625214422231 / 62500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (74+1) (a*x) = _ + rw [BR_succ, endpoint_74] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_76 : BR 100 76 (a*x) = (9999927000722072840051060959755093879574320678214374961175091321883872835078737446045384302988942842971778350461061508121417466534879463584409245779862288426808648183941637898882900554937487117543570327483431435970667212368620640881982729270252159209453374820976961529958202773415706870534744893640741 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (75+1) (a*x) = _ + rw [BR_succ, endpoint_75] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_77 : BR 100 77 (a*x) = (1249996681676190751743954451017542915363589543101321512053256269136717306046575217068024414327170135418561567668602632700258301743740943352596249252690500914339974900205433647076739684970334984442266930591759894161293223192276298629346751884935266986279992858827781836913842925754714938505856561953991 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (76+1) (a*x) = _ + rw [BR_succ, endpoint_76] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_78 : BR 100 78 (a*x) = (2499997713092345991373192115741976832669970015924852170832212077474221960156996843053641741051406894403013650567868747382586579972363585101365456169490209345218108065585403431194981722273781144756786334212789035603586537919620782784172339845133583127898861013452129586803729652858480693657482708334583 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (77+1) (a*x) = _ + rw [BR_succ, endpoint_77] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_79 : BR 100 79 (a*x) = (1249999627325124574295699192108223711761907193115003127933513320466718067619577158025213271446831745157757345026525911300931472268516424530930222210663695754471123195754879545489194953349837817848921837247860497557290029405140122490772931593148993164955127808924038884495475439688586169919287433801223 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (78+1) (a*x) = _ + rw [BR_succ, endpoint_78] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_80 : BR 100 80 (a*x) = (99999990827846278951285087597742881194093076895481459812342363084632776680788232463364253330658707201790418594252938960059462272847251179896655546371598416647556976170938443083552452200909368733441563560690538481937725351654430402831543413166535486316026215880103002272340095013105471977772740934294347 / 100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (79+1) (a*x) = _ + rw [BR_succ, endpoint_79] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_81 : BR 100 81 (a*x) = (4999999867115303809140664136051936678924572326576071382696252448762130572872073099284814692385392697878712276114711981480636502327257429351052124235963537866220171811429554449919159841507325073459231824746572206256176042921851423974698593208221121918982243101025061927213596751794738971027073914426983 / 5000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (80+1) (a*x) = _ + rw [BR_succ, endpoint_80] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_82 : BR 100 82 (a*x) = (9999999927645697590706236558442601547727177476157169121188778465959975779478537145936472186342359759984633517861064981163898282236048884796490080993308943399499383511002059665467116330110598763646761039623383836995019423100944010898273570581595017440415767189075089065248164796245977308561099146115373 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (81+1) (a*x) = _ + rw [BR_succ, endpoint_81] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_83 : BR 100 83 (a*x) = (4999999990771167170882253244823834283716095354924221163555826061344705376241598495389409085760514052958069126099923769144602204864624787363790663597000880772427447279680485385805366166362405945832314749988922269214506786256350275568012236940768237508271481382260374817587531113877803188141501262614411 / 5000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (82+1) (a*x) = _ + rw [BR_succ, endpoint_82] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_84 : BR 100 84 (a*x) = (19999999991202426279028845281067508620912578060776874191808028006111599268836737587656890013485282935224480589751603493298516260694261435269704080581396323686922499507270286995175387869854314635988565098848244279665055451671319069257027008496365183364692352869161550888553988905842653701105116506080023 / 20000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (83+1) (a*x) = _ + rw [BR_succ, endpoint_83] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_85 : BR 100 85 (a*x) = (6249999999389983395113560704334832883314623542545006313561684658872498800386871105864021236901696852837239990680164024136293397048779522096087298321954179246380268069873550280937251037380772558517762381678880772863880069826418163116594908467555560502554487850566131595355206009687797280590356140569171 / 6250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (84+1) (a*x) = _ + rw [BR_succ, endpoint_84] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_86 : BR 100 86 (a*x) = (2499999999949784457996368817704096210951081474161124433348283425419361913488852821408068139559600037459663869827125777745155981663535236696700201928318747983599309966858431898751390626983481224492356471924157456994319576205898429065599759268592745679063955844125018540730845669409688364132931437092619 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (85+1) (a*x) = _ + rw [BR_succ, endpoint_85] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_87 : BR 100 87 (a*x) = (1249999999995228515004964084333281288179924176061289704909110297744245708243092842408539449586094038089549337349094663526940060550662193983755644229536286385807399135057981044321924598300425056468940504497456094153741595581188531173332417660709366243355883845000102488600997235037147612965490328702831 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (86+1) (a*x) = _ + rw [BR_succ, endpoint_86] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_88 : BR 100 88 (a*x) = (9999999999993334811079444298481762952539956019255460044951972997671696905617943745936493050668025804575049799602976461610688165892784693239472085006958895936357101072686926064665442801932436661849518552400312013144564446221317841746895803142359120090324301343290144939116106249769884828313703551546257 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (87+1) (a*x) = _ + rw [BR_succ, endpoint_87] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_89 : BR 100 89 (a*x) = (2499999999999734231270512340217312320401342895998441242268485225578126572361956448857318798735730603268200162938453911970731234170922796593666820472977558962624623491473857289210735612743197430189137821311507496335362108038662410065981079938478211878469344816084475450637101702411869347975043058467351 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (88+1) (a*x) = _ + rw [BR_succ, endpoint_88] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_90 : BR 100 90 (a*x) = (24999999999999615454307067363186227412924672969623236815399531028617780395993995564087997593570845011296388338793859676443053647817289802397290646037860057928436644891361978803123946894115753924463411450611231036329296844080193322674480907012086624590702790199762137003063059158171020395795494373731461 / 25000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (89+1) (a*x) = _ + rw [BR_succ, endpoint_89] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_91 : BR 100 91 (a*x) = (2499999999999994993694964769944894363128229102411042914764299354437421206448329137230499852463791359860791294438638634104984056206369182550554090609632652083326176820338724008566163339395745722459529197791902778895959595806244191631855860443567016082428604637219999360737394930333176214784822555041139 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (90+1) (a*x) = _ + rw [BR_succ, endpoint_90] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_92 : BR 100 92 (a*x) = (9999999999999997677563121068076910066402662125629274193560394267373735822226423981555869409966591319558274308041867477600802513837457325081849004178827348729983488029287207655214541518039272787820610034153437821184342983010598522809174011126003084226777679672823734382674507773939785474378560384629733 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (91+1) (a*x) = _ + rw [BR_succ, endpoint_91] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_93 : BR 100 93 (a*x) = (1249999999999999970374919785311395701786818095742886295458967862308517027766906530538593395598727126665598113853770774787762916851121369195122719122116210339274990147604865240927499559795245174777350647831851001020155302922878343644867186156882167748596684165804341294827795308723410364875417805400029 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (92+1) (a*x) = _ + rw [BR_succ, endpoint_92] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_94 : BR 100 94 (a*x) = (2499999999999999994762411832297246576276973624591036782897514457384445756224946085384934580384506709144651637479243960183867304227003835811344833398742878826275357556152405914012417375627531253791555998523882793315034283383354606630491090221621616598827358552669796746885168964761076336539485200371941 / 2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (93+1) (a*x) = _ + rw [BR_succ, endpoint_93] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_95 : BR 100 95 (a*x) = (6249999999999999999017729615847266938340871787899784178610195355155895763287071959431216994422921726047012985619725746180747515511298648776190591816310090674143792700849138351712158992689457624208276892277245481412732347084654972873726154012444491448846866706072779981708970351494748508339539256777953 / 6250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (94+1) (a*x) = _ + rw [BR_succ, endpoint_94] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_96 : BR 100 96 (a*x) = (39999999999999999999610873815721558182063612535069291496568805623082375877166629944827119512298227711267424799021647967841371692145162965051928302983479603455134032883613642735310750980208294284832247858588720203410183699484427198903888749070914241524084585684359947248665419401527401237566367087689859 / 40000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (95+1) (a*x) = _ + rw [BR_succ, endpoint_95] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_97 : BR 100 97 (a*x) = (9999999999999999999995229796039282107502966137167223419941098812655536622578712135755679362057668605098927867195162613504798502518517966429093048353481370441817343513020594643559491081607170927996947556392324794154384178817100434132591804284375614848814769031847761382302154934514093518083677240598223 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (96+1) (a*x) = _ + rw [BR_succ, endpoint_96] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_98 : BR 100 98 (a*x) = (19999999999999999999999652537789733411174247146295448767506722658367742509224502963325892561249457000383449172179261032471908623324875698750976706953865984794823532779310085435160569571109495202095908450920870134771994603422037513414599268959201337467722066922613305150957457838834712493712393609175629 / 20000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (97+1) (a*x) = _ + rw [BR_succ, endpoint_97] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_99 : BR 100 99 (a*x) = (9999999999999999999999995822318082182597686123194979307433595967467419982220019613148741452182432987351970866992208146995841736188407883356377355863063136888013213554828214255081958893158538476107082268282338752127256161112265894992155819306394900715510593306215134149425778514103366543039500791729539 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (98+1) (a*x) = _ + rw [BR_succ, endpoint_98] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_100 : BR 100 100 (a*x) = (999999999999999999999999995024843008933288784558859096832496842052363586920257680623901646545006845358039548819910460461389841894072529127901629432470328985144293393148808437366681118074498997013845527473507600813270853866487275436769400314098071150743634090510004574073828096321567783583793244977569451 / 1000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (99+1) (a*x) = _ + rw [BR_succ, endpoint_99] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_3 : term 100 3 x (a*x) ≤ (3 / 250) := by + unfold term + rw [endpoint_3] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_4 : term 100 4 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_4] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_5 : term 100 5 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_5] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_6 : term 100 6 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_6] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_7 : term 100 7 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_7] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_8 : term 100 8 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_8] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_9 : term 100 9 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_9] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_10 : term 100 10 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_10] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_11 : term 100 11 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_11] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_12 : term 100 12 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_12] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_13 : term 100 13 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_13] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_14 : term 100 14 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_14] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_15 : term 100 15 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_15] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_16 : term 100 16 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_16] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_17 : term 100 17 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_17] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_18 : term 100 18 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_18] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_19 : term 100 19 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_19] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_20 : term 100 20 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_20] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_21 : term 100 21 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_21] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_22 : term 100 22 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_22] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_23 : term 100 23 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_23] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_24 : term 100 24 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_24] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_25 : term 100 25 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_25] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_26 : term 100 26 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_26] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_27 : term 100 27 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_27] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_28 : term 100 28 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_28] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_29 : term 100 29 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_29] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_30 : term 100 30 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_30] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_31 : term 100 31 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_31] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_32 : term 100 32 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_32] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_33 : term 100 33 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_33] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_34 : term 100 34 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_34] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_35 : term 100 35 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_35] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_36 : term 100 36 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_36] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_37 : term 100 37 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_37] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_38 : term 100 38 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_38] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_39 : term 100 39 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_39] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_40 : term 100 40 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_40] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_41 : term 100 41 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_41] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_42 : term 100 42 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_42] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_43 : term 100 43 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_43] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_44 : term 100 44 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_44] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_45 : term 100 45 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_45] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_46 : term 100 46 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_46] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_47 : term 100 47 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_47] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_48 : term 100 48 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_48] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_49 : term 100 49 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_49] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_50 : term 100 50 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_50] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_51 : term 100 51 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_51] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_52 : term 100 52 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_52] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_53 : term 100 53 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_53] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_54 : term 100 54 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_54] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_55 : term 100 55 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_55] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_56 : term 100 56 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_56] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_57 : term 100 57 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_57] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_58 : term 100 58 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_58] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_59 : term 100 59 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_59] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_60 : term 100 60 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_60] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_61 : term 100 61 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_61] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_62 : term 100 62 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_62] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_63 : term 100 63 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_63] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_64 : term 100 64 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_64] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_65 : term 100 65 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_65] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_66 : term 100 66 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_66] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_67 : term 100 67 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_67] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_68 : term 100 68 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_68] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_69 : term 100 69 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_69] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_70 : term 100 70 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_70] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_71 : term 100 71 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_71] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_72 : term 100 72 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_72] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_73 : term 100 73 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_73] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_74 : term 100 74 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_74] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_75 : term 100 75 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_75] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_76 : term 100 76 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_76] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_77 : term 100 77 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_77] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_78 : term 100 78 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_78] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_79 : term 100 79 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_79] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_80 : term 100 80 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_80] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_81 : term 100 81 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_81] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_82 : term 100 82 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_82] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_83 : term 100 83 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_83] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_84 : term 100 84 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_84] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_85 : term 100 85 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_85] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_86 : term 100 86 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_86] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_87 : term 100 87 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_87] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_88 : term 100 88 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_88] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_89 : term 100 89 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_89] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_90 : term 100 90 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_90] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_91 : term 100 91 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_91] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_92 : term 100 92 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_92] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_93 : term 100 93 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_93] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_94 : term 100 94 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_94] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_95 : term 100 95 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_95] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_96 : term 100 96 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_96] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_97 : term 100 97 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_97] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_98 : term 100 98 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_98] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_99 : term 100 99 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_99] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_100 : term 100 100 x (a*x) ≤ (33 / 10000) := by + unfold term + rw [endpoint_100] + rw [C_top] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem scalar_bound : scalarBudget 100 a x ≤ (3707232300000000000000000000000017209226607827759920758184455376999472060706591111381825506236924760154817428344182251680508385459230308732699163316256883548729742567469252845385199482532095316721648062124329899465649984476615592765479246003713286523718443950028548139401988192880523691456128501348166981863 / 11163000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + have h := scalarBudget_le 100 (by norm_num) a x (3 / 250) (33 / 10000) term_3 (by + intro k hk + obtain ⟨hlo, hhi⟩ := Finset.mem_Ico.mp hk + interval_cases k + · exact term_4 + · exact term_5 + · exact term_6 + · exact term_7 + · exact term_8 + · exact term_9 + · exact term_10 + · exact term_11 + · exact term_12 + · exact term_13 + · exact term_14 + · exact term_15 + · exact term_16 + · exact term_17 + · exact term_18 + · exact term_19 + · exact term_20 + · exact term_21 + · exact term_22 + · exact term_23 + · exact term_24 + · exact term_25 + · exact term_26 + · exact term_27 + · exact term_28 + · exact term_29 + · exact term_30 + · exact term_31 + · exact term_32 + · exact term_33 + · exact term_34 + · exact term_35 + · exact term_36 + · exact term_37 + · exact term_38 + · exact term_39 + · exact term_40 + · exact term_41 + · exact term_42 + · exact term_43 + · exact term_44 + · exact term_45 + · exact term_46 + · exact term_47 + · exact term_48 + · exact term_49 + · exact term_50 + · exact term_51 + · exact term_52 + · exact term_53 + · exact term_54 + · exact term_55 + · exact term_56 + · exact term_57 + · exact term_58 + · exact term_59 + · exact term_60 + · exact term_61 + · exact term_62 + · exact term_63 + · exact term_64 + · exact term_65 + · exact term_66 + · exact term_67 + · exact term_68 + · exact term_69 + · exact term_70 + · exact term_71 + · exact term_72 + · exact term_73 + · exact term_74 + · exact term_75 + · exact term_76 + · exact term_77 + · exact term_78 + · exact term_79 + · exact term_80 + · exact term_81 + · exact term_82 + · exact term_83 + · exact term_84 + · exact term_85 + · exact term_86 + · exact term_87 + · exact term_88 + · exact term_89 + · exact term_90 + · exact term_91 + · exact term_92 + · exact term_93 + · exact term_94 + · exact term_95 + · exact term_96 + · exact term_97 + · exact term_98 + · exact term_99 + · exact term_100) + rw [endpoint_2] at h + norm_num [a, x] at h ⊢ + exact h + +theorem scalar_budget : scalarBudget 100 a x + (1-x^2)/(100-1)/x^2 < 1-a*x := by + have h := scalar_bound + norm_num [a, x] at h ⊢ + linarith + +theorem pointwise : ∀ w ∈ q, ‖w‖ = 1 := norm_family _ _ (by norm_num [x]) +theorem cardinality : q.card = 100 := by simp [q] +theorem mean : q.sum / q.card = (x : ℂ) := mean_family _ (by norm_num) _ +theorem actual_variance : variance (q.map (fun w => w-(x : ℂ))) = 1-x^2 := + variance_family _ (by norm_num) _ (by norm_num [x]) + +theorem paper_budget : + majorant_Efin (q.map (fun w => w-(x : ℂ))) (x : ℂ) ((a : ℂ)*x) + + Gamma (q.map (fun w => w-(x : ℂ))) (x : ℂ) < 1-a*‖(x : ℂ)‖ := by + rw [show q = family 50 x from rfl, budget_eq _ (by norm_num) _ _ (by norm_num [x]) (by norm_num [x])] + rw [Gamma, variance_family 50 (by norm_num) x (by norm_num [x])] + simpa [x, Complex.norm_real, Real.norm_eq_abs, div_mul_eq_div_div] using scalar_budget + +theorem norm_J_gt_one : 1 < ‖J 50 a x‖ := + budget_implies_J _ (by norm_num) _ _ (by norm_num [a]) + (by norm_num [x]) (by norm_num [x]) scalar_budget + +def pc : Fin 101 → ℝ := ![(265613988875874769338781322035779626829233452653394495974574961739092490901302182994384699044001 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (34205179234126539740405283582163176388342396847253802314948042295067577439401025565610207354666351 / 100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (221757410554178726225095165746990651590863505138406089514173286861132185917605718844123308082520153849 / 100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (60259037489090987703241857251668674983766003737324221374147137381606817208460873672877122880896581472373 / 6250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (197494331570045200855250376249647550086484012550895997664261636887953814241381063392838150494688439622210003 / 6250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (650082522954975334120947330933776514366234250435775520213237998332456521377335075250294132462136748131215824719 / 7812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (286356179490141923839464447653772581324832068396563722966725860721970555569215914385185644200999337375491966003107 / 1562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (67778552772598931665226565020872991435344016339618780429194605420286636008335678719396464408225943411095829538530911 / 195312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (450298447314983507948509981391162650637557898906961127181709766068697762088338703793380992615589528056438406720670131973 / 781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (166520738964525503055686659270470863099308287954964273009292470294742312469535279589995713044185456367212746613910145169887 / 195312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1110002851777520083330999520176736567083487543100123664161800012367465766780938319080435413601926389719571395211434397824812817 / 976562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (4208031073013069318820744254285195870803863332444647032481594491452833257611505969405124868137143501154437552001669070025419793 / 3051757812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (37454564576198442737837874477468768228630873439677309769900308823075834368116293834623979142688990194933526785062580020225903410711 / 24414062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (9617359264661853039560478962710008422721054773312903738004553935094338207273125987284555498649528916159068587056030562816225851520743 / 6103515625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (9169509198305623203137196066527909007200802311967162663023606421432444322469734009854374872651621758810677941099380741147097959711128763 / 6103515625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (5096254555799494336231118448587922275113186540440177873524195181222392142567571991623153917087525894784557482817097549202098419786465129189 / 3814697265625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (6790568926017708816993344986869570804449532215853744448318030403051669118468870437111847604928318320518601553363742232174353362386335050284623 / 6103515625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1328733115557568762686990824158534467747287374883314723299383510403180640050452559370775970967644757551531331223168389247528771776668384472388673 / 1525878906250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (980489731656068923054234271867783664518565186126742698644415133784893782435733148508931687955011642411410646512874268535694047473983746761697779151 / 1525878906250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (42750469478248840330252639408430968667360361328440667165124574151021748945414781456239938927582597912310936396038360955018267579447494868324523565941 / 95367431640625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (70660424027336252590615430996748650372942487266788894295769568422893292613835873775915552739045882771928494802029376441816872748986858905875669083533849 / 238418579101562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2218553642918445783327028494038017612947292569691823518469592413636174901179222827026522903932843175499302470185539340300345003996076438887368638812831107 / 11920928955078125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1325789584631374494629501912698688603357562079804065925172827743598000947366676469825820923336355108146674781592937780933144651640285351276557190410052734923 / 11920928955078125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (94414300740213642293473831554674141777194796765890969035097823891523255599723797934639680478167785337695389941813356687024877611392294924823649562560243409307 / 1490116119384765625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (205443620864621199431967227504814021917871220694267654513469745185112157653533781079280994507800082381270820368729226787904546888453348113254605129957591941535563 / 5960464477539062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (667939685146449563640616949488741567949826281442215918736742962511894855226510684291179415811821158783538945636872198745833648164859945487097457880771730870779181969 / 37252902984619140625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (13307661760033047894448804812340607955325765864609367008435337847184232366187724567858721930653476099275192332843098516437775137271758466210807470167355688839562944163 / 1490116119384765625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (198570721042573666243765214146723043793335129275816374437562853224091223952116343011338603670225348519942047896574520210556343843675060193121602644488895039783973938491 / 46566128730773925781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (363974283290034991063362109906854442677662664723791780666970526237438563396876674708666930973555728818679767315057420700330705130462130648960958064171754429017921485451723 / 186264514923095703125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (40056243233431819146368956465265350931517794138411443959574203431738909515037141935515204151575667933522547068404123805732038625158809683050559912364108039495196245709982707 / 46566128730773925781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (84773187656871235701563379561919922755132363377321646768142227297860982687007918269140450913323568995164416040935009556885404948841057796982097641432965150445491777289481079099 / 232830643653869628906250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (863250132753459798995912391940225797059319557682545498844404453660937036094414905078411704694612934764518330788859301580553170658370325612567258817221356405684445816864709514129 / 5820766091346740722656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (5418073914461943949080422299227851438224244896736552612337567095601553448260521696978181934125697117179268180617490093318025002737820342951188807192625457699455454117428991018514551 / 93132257461547851562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (512065568008234209249266081504966270230855787936143604909184168656037957894605593421077825620393140047006360491199852672429040908790757053218169856177761321262601201339857171464533473 / 23283064365386962890625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (186678757475280245244064898102278703836701466204585079112061835442122665591467563061986187532632149880727190275287349156359783403226692664802648478425668882587744293989325665974880410023 / 23283064365386962890625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (20520852595826758356660813227619268616820695021547168920453893193202481224545347849464570898555648077177812908771519313875667652815152624165750042330729276722940222216419339369401895165003 / 7275957614183425903320312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1393757931349856121570869365750801541207345928407948790597742855424307144687358192370847547788858810860641073695215036317854993251847952428251053259145152352817792855111579765851105938460863 / 1455191522836685180664062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (114290599250553849465553273163853635362424284949905023757858088743331580163702077669731482637371786739439479222611066618907937530505158527019776285441535811977842154840114153792011323767765943 / 363797880709171295166015625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (36224741512382520103992285759402984422429480652685855756400028637112399352507730626327924249654170795895728336154346143978833825901533383929404250655516946498381538257574024193916862273963670311 / 363797880709171295166015625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1387375659889575482623639826757170505805826251609405168832299536721477040999325690105431662099275450770751858744248912322193313068782909040302726271133001906153508590093434374395341023014251721147 / 45474735088646411895751953125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (8221329918799145167363470923194975300566996387854000286287997305436605846959211676634964008497317854542879120821641655189440674282781418402911466993005363667199931758475918327100621376007253701223817 / 909494701772928237915039062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (117817129312639957925118967615189191341076584820419207833432936125999908096384536951850772623763014018357133069365130107723952166311465635388688004929309635099857457030152811699965259937097270361712287 / 45474735088646411895751953125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (32674342030005113281202491834125301203103594442437123081977869500007034705152625028501545437483376940258106839898952740878211732311825669039635646667773488237170575356073376573092829740572624007298152173 / 45474735088646411895751953125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (34259132931088185051332655924206998875485706578118352949070327722991465790984889813167853220631359049301072588729918844976643919101028121569807467808101833091925804933650352628524374670705206842457037321 / 177635683940025046467781066894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (284866767612508937109268865301959899466687591225143530193358852168157367763992445377579583286651919013997068453641430865900452172434130927472018070296500729485754281546748795573343939216137333182944657510707 / 5684341886080801486968994140625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (89588957509929175408864355937018963515611255874957097916299573724798051901133472987716037253036648167767440213694711250937414271192496175194425408341252827010154035366282955477158211931164154819030128564910719 / 7105427357601001858711242675781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (4365585417796120273452006614578406585053428040950646535883574368122761762091686715741439642640965792013788560758222485797011591336671720955808345717015663807111072161885152749715855422783555399060823814469216103 / 1421085471520200371742248535156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (128771896331216778305260921402428484171081607366554895927983602130379526678389719116016400532479268851917903818753911668292413448348982298637080634312604178945003332484899145936966157706427985251001905403941154349 / 177635683940025046467781066894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (235468560847597724383446154748213398295515887379646263744221769831611790729347479437087516328764365138399437618675964482161376419701064951714321384441291837372903352822297032050024837368092156525789772738044618263249 / 1421085471520200371742248535156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (13034020259084077664231511973804962890029381228557063908520580113964366910519131638937539861573156490711400758146833163139884164167075680248878146104098823449415905790365554932112189213033081915058932285538590460139151 / 355271367880050092935562133789062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (69891699328535637244113122500809715542100947814302201387505456793426333095157576137247111715438585473174733642351371892575664560552003154477192583060824293720444870213265468648774013018807784325106626419366296353541349001 / 8881784197001252323389053344726562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (58089892759621630083797232377081377818526007697643210752789252112853536477745759526622862839850734483294020662851935455475286213139682969998086552389872534138754839386690930006080250690184476189336722902215199458151031 / 35527136788005009293556213378906250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (4677106891970703100041927500829434275151642426337887629539814855391781767968189737497436704081832164182495520485211151848765849168093657304124687874070049312341737211271844461788033353246020108306271753238029674849089 / 14210854715202003717422485351562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (11399548230081535179545211946855819512087115863201493700702996411223789088436624191877429053270930013631496863859849158478544855014622258525003824901118455299364054193575579446734714401944607076210512121584658463509 / 177635683940025046467781066894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1722388916777441235289217801900436455417461959219668206827808183518197941569310363008067147016595160820511099158561469679357772474100724837437253689981587044749191422744525631271978309569414609258285049084970249863 / 142108547152020037174224853515625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (157530770845241677096333809392304589894610594077952309364226148549455180008973940531579968876604054248051049170628153518904682047457464601225079150488959727587457770389897831302311913365365283477342839793420045319 / 71054273576010018587112426757812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2232414762842394822365876092311850919248766056538586346086957388400746124546098195832640364431557800781531421942630266912171577851045768089922877737066451201779147156986026814486211699478081874553682116519813667 / 5684341886080801486968994140625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1196552196508997042748790302574406708229202360710431748419622046464033277490078194566039917576158311652754483345571100932528500071736320306861396867318089932516719309110933281339328524508079353252865800348081 / 17763568394002504646778106689453125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (5086093211087060602120854299328158519540572710200309143105402538525489161626337882080448395450784097970046481578263260062723814260158508769720677498792976184332955749474918166959820617892454826168915896395693 / 454747350886464118957519531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (81735003191528754424845003113122652870355410917708001781042807133482197821713801407824915684656424732419592607735489141894443657424329105502438177075421577997249794498427756708977931152052381340678739949127 / 45474735088646411895751953125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (25419318739616031677389442301193356549646902135378628900970813953644080728382384791511674095763402262762225055492357028299259884601582767808879886825256008339608497184404489919045482226847057225765409039417 / 90949470177292823791503906250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (19117807497771347253901672099445061383622011755087262827265493382558360734293246688463029843264353237435126910205468500849829603668455479448029980963753680488703460316549402807205402426093617532916961107 / 454747350886464118957519531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2224700187940933581928365404179490538018114988476692125587317837055319561587415210340032765057616268272598756902861083539632821915300399525817357578066223164522291913465177485710510236278575830874356871 / 363797880709171295166015625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (31282315309408138492400125870287787076435576118435813703165501745336789455200413239224041049793587042413438192282431375466826744088213097046821325698336154593464226838899979316058140534290663181718463 / 36379788070917129516601562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1700191787991541918898414203530631297737709456415645006761274924566285835252243717784535045841825648205148983705038523177610095453464734529126719660383448628722356586793564580137802111074588707490223 / 14551915228366851806640625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (111565045319652835536859628243205267431352576955307127131811432343934284490217982942010302320934609219571103738319330687654643297648861468619618901390487273839119227726222723182019633949548772825603 / 7275957614183425903320312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (4523242065203826835194581158505002462533674437486829973572159705195953486220239932935027512069540642411683978649974415802070271630849546147550581412321215670297233135950853701579048387627054349863 / 2328306436538696289062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (55297142010976371465875048002019045343843875688582528351848194218042809737167259233777627420882845215659075875183248906649122861660848262235954076842429670809718344803967749860658634981487861753 / 232830643653869628906250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2607619499313794954925188080274679572822274085494175968447953431326752247301518357338297531431790650533526162564455048788371277750005871446623513368653271508052170635624865648082731472694979591 / 93132257461547851562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1851646724819653590532956320719029538218956084299409172095375369207460270953901938555335666092736896460501289522587084897600167592918608617281052540204259225495369988136701744111950127971609 / 582076609134674072265625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (810405116764723320315847360468678067920655036997787541730230461602963270032825757599692400027686761298049600869948868915458979404132872619373225826022277365453448630520990076887566529425499 / 2328306436538696289062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1706616967412125109016130811075343924288365132807618319893070674570708123461340444006311252242047365841003588158280009101984470369374669413084352688045555874592072734797201422548096319067 / 46566128730773925781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (69112837877585999814399207282676705843453873026332278066247265511744998119783293536411575187258168031680389677982884878140366869107545999612573803691777685445928222527321054109554390203 / 18626451492309570312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (168044933213689202800370269208966136279234800109057403574518508371344673012932829775759715054300768051182597199181451403449544822741662075833481438893128040679065775064849596196036531 / 465661287307739257812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (50191958994978010601586296701962042234281118419973621058850809289497914541522255474956753800497281433502624668705137663503036788317879476181300199949703386519846355016495845920845923 / 1490116119384765625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (11227726454240727135045122931786585501169015009776003301972315569348048170971237156021979842565120951382096566538622819784986973219388036596914963046956839181117078068036039650004969 / 3725290298461914062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (15391091477484961534449488384774787633890486442880144663588515177614583817019229391748768531245869411768832785532012530427882070165610366728579838703203535209799441554870834999003 / 59604644775390625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (31523666383830515581134125459906074048477838470663154324120771154474506659954434024605202245045294750759144272950863280082863635907196066249650309319879909561148493015806645427 / 1490116119384765625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1972857547520946736330465141768794689639061430649455619191886118828453976990753655175987584590428590117402416240609633134713217135387413398341044925519825398705822621445363243 / 1192092895507812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (14713406774509492486140343233263703825114692213181418272435169764913843382987067487583923585131646563644419774548576244029462327659054999089129981679172595461654994487909547 / 119209289550781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2088534867483538594076116907558547264915644235378902727047909480957480267358072738751356418413490109568105961426105609836591271969189469404536764858809380064015831760593449 / 238418579101562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (5631558012424214517665723598615152463001277440684813764465269391886531526290356763862524407556124566410438220996266868754263463770943439356015901037413262106576325551421 / 9536743164062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (575642574256295476879979170583678619668598230118568370570756911615913657424766507070212062986967165213995444610525817359489507408647300127214901863661188781400413781711 / 15258789062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (3476720663738929620545339223434282080421994802841586414820293649546294998407758275135630354391608603211768514504552193789237635790331958955227963672460062251698623193 / 1525878906250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (79188184212169127996481366457160841238586164919069868961281982940897021720888019368501693728972796185409359926078531545945756950739522657951296980106993808618869983 / 610351562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (264866796353467542521956991447611787699165331824070921367280026808466457317665313142667525091639178240397160708159370001329997387127084159103281534729648182197389 / 38146972656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2123951910709598772185825930865298601136870629224469992431377576615568079764939838596831870581214251014343830005553182589562064886846827556743933849502163328603 / 6103515625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (9928339324569198287753230500815688798304841954250579187886927602494821344092947015850938044098358718702942032620436552645368534780342139362485044558512319023 / 610351562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (172324770040813437233455227294982819352807322371839212687620099742701652556381857486820667974534136914253927021355024267115745014163100513508294651567655751 / 244140625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (86286742964242427885730702579849337950694221651723723161371974549881389577829354916999243138775498723635978753310985137254211021724059733364176067509753 / 3051757812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (101440508049468227469447737980230839110133262364965844627652744346107208488324441109483902350072939011429327717980218536035903482452599817501003457355217 / 97656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (67823130816447948729483028062740795279018197148179816770410889697695661443501121321631125785418357324219686683780225938571239428810613725877868531847 / 1953125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (817395300746851254469554193906915111216867023209174395337009672682930868393081608564721798454178925165821758717325376718653850714602743033596171253 / 781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (548335244905626858878004014952093214315202233286119264756374284042805182232340684140032563436053301604823310325409703688040783901782006254147351 / 19531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (10324822940132969996402687504468427518329055335117210304741721059935173456828788360910605404002163689234660582457046571289948659239002179970947 / 15625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (104464018143065347382703250855738900945508462797837325256913839967847671418392672386026517552849605868181580403174186138167153637458495476119 / 7812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (141440914085511806498283135828538551490429830137218981712085342136648282783774907812592820081314313389106874910637038708026767656879965443 / 625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (192337865783336966920365105912667620598450463653234407954912335006404984830646062024334559878342718609787595525529709981902331895505853 / 62500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (3154590034526820015231237425559342707727209231475278873418658765200290862894406454352361915417392015905881165399979005532006941868409 / 100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2168596930781070497866204601543735708154480144724491381646565673148511211169544894926031776517225099770941481267108591130871974871 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (75051624198251984443456989853061891539043939434909537798332873934101480896578056472849915762891214746171016655874432115640378001 / 100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000)] +theorem expansion (t : ℝ) : + (a^2+2*a*(1-a^2)*x*t+(1-a^2)^2*t^2)^50 = + ∑ k : Fin 101, pc k*t^k.val := by + norm_num [a, x, pc, Fin.sum_univ_succ] + ring + +theorem polar_integral : K 50 a x = ((4874819668353986344372759158996379788203162905021053969220512027464011516697234322492412798178083531872222373173129125064055696582260367287677751296177367615012912487174742599035378515486086963925803530899510738528131130982750545622228064732114888343133733918883 / 4523697211450944933646848582498023461084812879562377929687500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) : ℝ) := by + rw [K_eq _ _ _ (by norm_num [x]), integral_coeffs _ pc _ expansion] + norm_num [pc, Fin.sum_univ_succ] + +theorem full_polar : 1 < ‖K 50 a x‖ := by + rw [polar_integral] + norm_num [Complex.norm_real, Real.norm_eq_abs] + +#print axioms pointwise +#print axioms mean +#print axioms actual_variance +#print axioms paper_budget +#print axioms norm_J_gt_one +#print axioms full_polar +end Sendov.PaperConjugate.DI06 diff --git a/tests/PaperConjugateDI07.lean b/tests/PaperConjugateDI07.lean new file mode 100644 index 0000000..59d75a8 --- /dev/null +++ b/tests/PaperConjugateDI07.lean @@ -0,0 +1,1254 @@ +import Sendov.Analytic.PaperConjugate + +noncomputable section +set_option maxRecDepth 10000 +set_option maxHeartbeats 4000000 +set_option linter.style.whitespace false +open scoped BigOperators +namespace Sendov.PaperConjugate.DI07 +open PaperCentered PaperCenteredBound +def a : ℝ := (99 / 100) +def x : ℝ := (22 / 25) +def q : Multiset ℂ := family 50 x + +theorem endpoint_0 : BR 100 0 (a*x) = (7751994915962201569944950578828347586209940463848204475710782138487533290748636016082938439039470062379072141910614400186944696513433561448161590576795752928085400140476078767600966994228393572033130223835508005382887696161 / 6136366831622158191369714943732844553719019390624311956389436396483881568402144820575122355046664940346479464456414848141459898263030898628509393530136204315316381830574827410673677263730496633797883987426757812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + norm_num [BR, a, x] + +theorem endpoint_1 : BR 100 1 (a*x) = (106072327949470373034712584628315836847332290943214872422303435099925688444218913934352257026111506505721092724404245488272292959124808297331055801494913314910385941052601251708229380672578577883161403000680895253779513010203 / 122727336632443163827394298874656891074380387812486239127788727929677631368042896411502447100933298806929589289128296962829197965260617972570187870602724086306327636611496548213473545274609932675957679748535156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (0+1) (a*x) = _ + rw [BR_succ, endpoint_0] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_2 : BR 100 2 (a*x) = (1122723986643059725211377893625118807365737794164358832139045778822443487553108277221932606462123738137811293713101628741893363357193667852703656910578528817087034477109982241316032075864416536525113218256294158091283194933827 / 3835229269763848869606071839833027846074387119140194972743397747802425980251340512859451471904165587716549665285259280088412436414394311642818370956335127697072738644109267131671048289831560396123677492141723632812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (1+1) (a*x) = _ + rw [BR_succ, endpoint_1] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_3 : BR 100 3 (a*x) = (8031596110468306347490818312899114611406498832672139695972226498252522055729983775198605753027853398560637811585965513343376961384491903558506243954780849464948534895573348541131660799580672074422894479155696517193772859031264101 / 122727336632443163827394298874656891074380387812486239127788727929677631368042896411502447100933298806929589289128296962829197965260617972570187870602724086306327636611496548213473545274609932675957679748535156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (2+1) (a*x) = _ + rw [BR_succ, endpoint_2] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_4 : BR 100 4 (a*x) = (2666105990120681737468605346250607520586211779704580969231927597565033046557108284838508615986115786842397662665633494040068496407555131036037707201611976110485450924867117797127001698762004862021538597505933444287429947759625494239 / 245454673264886327654788597749313782148760775624972478255577455859355262736085792823004894201866597613859178578256593925658395930521235945140375741205448172612655273222993096426947090549219865351915359497070312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (3+1) (a*x) = _ + rw [BR_succ, endpoint_3] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_5 : BR 100 5 (a*x) = (109502401472279086010820815459056373807710327649772079556715311035033839318641164933769437665105205607077178071002398000192084139558810935837185597433938191888504894552701119968056321957432477964818904509434486243270189892392437621991 / 76704585395276977392121436796660556921487742382803899454867954956048519605026810257189029438083311754330993305705185601768248728287886232856367419126702553941454772882185342633420965796631207922473549842834472656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (4+1) (a*x) = _ + rw [BR_succ, endpoint_4] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_6 : BR 100 6 (a*x) = (593503969805534352621045802402848377471737325646195830940177297758487099217329636878692509915164795074874323324646830577121002059379674726150833358746281333676324624355076937339414253842140064763240111222045227634708457513096228188379 / 3835229269763848869606071839833027846074387119140194972743397747802425980251340512859451471904165587716549665285259280088412436414394311642818370956335127697072738644109267131671048289831560396123677492141723632812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (5+1) (a*x) = _ + rw [BR_succ, endpoint_5] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_7 : BR 100 7 (a*x) = (218290696088683804875427644130359734357179767145980812304733355914894858981406448972976980348768736987458732951451418566676042712124728670601436211269839186003358005930808062262700472603064359903022751813745365599922640741326554586292453 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (6+1) (a*x) = _ + rw [BR_succ, endpoint_6] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_8 : BR 100 8 (a*x) = (69514550630074465193776251944885801233000074942363668288555100984326492395232234159658568233513576478408413557217211646816174712097313001523144857802975849832234870064487738082941642450816196030775481265840181983870071861969938680461588523 / 61363668316221581913697149437328445537190193906243119563894363964838815684021448205751223550466649403464794644564148481414598982630308986285093935301362043153163818305748274106736772637304966337978839874267578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (7+1) (a*x) = _ + rw [BR_succ, endpoint_7] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_9 : BR 100 9 (a*x) = (2433581925712192889120215498699785040094961117122248514043811381424414089461831222413575335334985042035012856690889821379616758165591839479702060746029466920946415081841942577578034885903127107227690941191489225986053671824460525539597439463 / 30681834158110790956848574718664222768595096953121559781947181982419407842010724102875611775233324701732397322282074240707299491315154493142546967650681021576581909152874137053368386318652483168989419937133789062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (8+1) (a*x) = _ + rw [BR_succ, endpoint_8] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_10 : BR 100 10 (a*x) = (94818133142230924482625260004547208146203783403201820121655680037862443388582582003595964933750457379258869455234457700530519134981799409105749208585995885635484157189571281739426209890619311621738670602826173195119683348032962139216186850537 / 19176146348819244348030359199165139230371935595700974863716988739012129901256702564297257359520827938582748326426296400442062182071971558214091854781675638485363693220546335658355241449157801980618387460708618164062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (9+1) (a*x) = _ + rw [BR_succ, endpoint_9] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_11 : BR 100 11 (a*x) = (8504642918596714150751514244465405431645257176320638310322431309194193930840509352012646567154992735557718644852619484356365275615771081046751034305048150102813772054739601149064974131851337068354878927922183147092469792253869910757724597136377 / 30681834158110790956848574718664222768595096953121559781947181982419407842010724102875611775233324701732397322282074240707299491315154493142546967650681021576581909152874137053368386318652483168989419937133789062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (10+1) (a*x) = _ + rw [BR_succ, endpoint_10] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_12 : BR 100 12 (a*x) = (864494847001615653209876266922865915793825259024514220896528853812286431587617204429991737450883304609444780467255124002875222036149158929436919982009835079475776317909881374661078451506499970304605319301393415021687088730363488229943256863198737 / 61363668316221581913697149437328445537190193906243119563894363964838815684021448205751223550466649403464794644564148481414598982630308986285093935301362043153163818305748274106736772637304966337978839874267578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (11+1) (a*x) = _ + rw [BR_succ, endpoint_11] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_13 : BR 100 13 (a*x) = (10027297633587117537328322225146318999848164626789405864369253129662315790405440022171329008133218038790442689396712539648122393326727248488652995832174231610963316906222427217481482212350485090747270024386272786593242579321325343091077733360564997 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (12+1) (a*x) = _ + rw [BR_succ, endpoint_12] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_14 : BR 100 14 (a*x) = (106790810574929159599243966079499093146463909719116720486721775088334421948728023184445789157709246044916402349349095818884743622704448463356984030641709189547345524959987584081605872530991232733194209557689570664229726304737075105525562334347367231 / 3835229269763848869606071839833027846074387119140194972743397747802425980251340512859451471904165587716549665285259280088412436414394311642818370956335127697072738644109267131671048289831560396123677492141723632812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (13+1) (a*x) = _ + rw [BR_succ, endpoint_13] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_15 : BR 100 15 (a*x) = (83959234028275206783714873277082513181560967910401367777200249993511358769870986546991630864847400066829872393603985652465701084198594400637248378907289943119350907914293298871504773052214208593403858063982576777972512239275235290745615659275995884487 / 76704585395276977392121436796660556921487742382803899454867954956048519605026810257189029438083311754330993305705185601768248728287886232856367419126702553941454772882185342633420965796631207922473549842834472656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (14+1) (a*x) = _ + rw [BR_succ, endpoint_14] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_16 : BR 100 16 (a*x) = (4894018235446729713375608923894075827373188398758534456143298903349776779727305310404150881595492716676538264300616605553004832141376081270545162642319340731439624790497137022616975144779021263810783758670016262313378532322098739993660108444043302702573 / 122727336632443163827394298874656891074380387812486239127788727929677631368042896411502447100933298806929589289128296962829197965260617972570187870602724086306327636611496548213473545274609932675957679748535156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (15+1) (a*x) = _ + rw [BR_succ, endpoint_15] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_17 : BR 100 17 (a*x) = (82932960810745444632558818793044242960920295065232693928771320106321048663193035824000865696055222423311961681292480645111378574965888686907839981042863087440977489024154120897584512667081686396451923415064270054779824613568694678731312932651224468338427 / 61363668316221581913697149437328445537190193906243119563894363964838815684021448205751223550466649403464794644564148481414598982630308986285093935301362043153163818305748274106736772637304966337978839874267578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (16+1) (a*x) = _ + rw [BR_succ, endpoint_16] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_18 : BR 100 18 (a*x) = (163968095184187975934323938142979859924980526128016140611602449069887218689376554360054189229147276464421401927573217867860548365712312796175989814570496010347227052935165695144241407636112495630921674275776962956006337576983778455847974910843965782349043 / 3835229269763848869606071839833027846074387119140194972743397747802425980251340512859451471904165587716549665285259280088412436414394311642818370956335127697072738644109267131671048289831560396123677492141723632812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (17+1) (a*x) = _ + rw [BR_succ, endpoint_17] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_19 : BR 100 19 (a*x) = (77691579088756203034500902786889652128240268454683345179251057856196422352677239310444594318287348465097502096076210271988187860759137863380139187653204268402086967870822385828574877378550892409061003069065266789391993308975019607530640939606426086282613061 / 61363668316221581913697149437328445537190193906243119563894363964838815684021448205751223550466649403464794644564148481414598982630308986285093935301362043153163818305748274106736772637304966337978839874267578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (18+1) (a*x) = _ + rw [BR_succ, endpoint_18] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_20 : BR 100 20 (a*x) = (21595022194762187907907522917965179463028691243899131565542209201201540315380775359328593395350182016752708886135167362103030386752583438245456337726443770373641289414610790907354791918643907719701568892025239295069071969045213990287934282711461544558321483567 / 613636683162215819136971494373284455371901939062431195638943639648388156840214482057512235504666494034647946445641484814145989826303089862850939353013620431531638183057482741067367726373049663379788398742675781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (19+1) (a*x) = _ + rw [BR_succ, endpoint_19] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_21 : BR 100 21 (a*x) = (14118286881247174144857639180103100368034593113187886927971350008234817918460900245027771346331744185942049329023899100681739814349098559531147286278674726230457030493899945436920273426809742320041097860273586851916012409545529239314294571777028471455542994121 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (20+1) (a*x) = _ + rw [BR_succ, endpoint_20] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_22 : BR 100 22 (a*x) = (87024150683754888273409140205475658151911052463200726716119960672386230047755703647804215795176164240075570039099544448852872308453617086089375449253882940261992135113843488890870065825989442914035572922169181252382063687580201568595811236497980804281085173757 / 3835229269763848869606071839833027846074387119140194972743397747802425980251340512859451471904165587716549665285259280088412436414394311642818370956335127697072738644109267131671048289831560396123677492141723632812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (21+1) (a*x) = _ + rw [BR_succ, endpoint_21] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_23 : BR 100 23 (a*x) = (8107342752131695635551751442746195248893319321309951105664847688724054617358393609383815772066185634246552622665130710981016423693988712999608947898339471151376170731515479428206764759420868954970784961483802401174135011655326979270337030969238374706358025546967 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (22+1) (a*x) = _ + rw [BR_succ, endpoint_22] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_24 : BR 100 24 (a*x) = (714712897325351275084812796972240747261140373887095997282391114955582887927809154200757764660263215800597676943431494721617289652246059085441881272689277201058152871862943366012274131158969883411096781313572440644835284503168962520210029793014220664869415185721411 / 61363668316221581913697149437328445537190193906243119563894363964838815684021448205751223550466649403464794644564148481414598982630308986285093935301362043153163818305748274106736772637304966337978839874267578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (23+1) (a*x) = _ + rw [BR_succ, endpoint_23] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_25 : BR 100 25 (a*x) = (186609440819811251724818307196932253251530086199537294189219591636945342913051550731501696978491762180655335236526447425822110246447301360577132938040094606139015446882523810970350741355593425206446279573828924869578311052919706694347809670556054353572625806292133107 / 767045853952769773921214367966605569214877423828038994548679549560485196050268102571890294380833117543309933057051856017682487282878862328563674191267025539414547728821853426334209657966312079224735498428344726562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (24+1) (a*x) = _ + rw [BR_succ, endpoint_24] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_26 : BR 100 26 (a*x) = (18497712197031349947245531213169646148042914741095165510946184621183826193960961987130528675167920940876102570633238832789038842473556728231411622900054388766641998390885854401055899138172881066432816332819479991567988297263037561990275638476452537093047253197220363 / 3835229269763848869606071839833027846074387119140194972743397747802425980251340512859451471904165587716549665285259280088412436414394311642818370956335127697072738644109267131671048289831560396123677492141723632812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (25+1) (a*x) = _ + rw [BR_succ, endpoint_25] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_27 : BR 100 27 (a*x) = (2788136311420732211159571952735646822222873729757078049354663248674925313908060630369386394647717178367644762463852740568959917249353356674114200987414501947461803639218094881035405698942382535225215048835214944819042919771658489875727083871742482538169569359809965877 / 30681834158110790956848574718664222768595096953121559781947181982419407842010724102875611775233324701732397322282074240707299491315154493142546967650681021576581909152874137053368386318652483168989419937133789062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (26+1) (a*x) = _ + rw [BR_succ, endpoint_26] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_28 : BR 100 28 (a*x) = (99968242326156184490515877870155819811155158181606761077579787316629252937160695039526778880042674782823793523976345887019509904676079056263097392404107970244953780930346559939981760000981677508206747945701444364519811435520671862342827708147270441823229320112892473361 / 61363668316221581913697149437328445537190193906243119563894363964838815684021448205751223550466649403464794644564148481414598982630308986285093935301362043153163818305748274106736772637304966337978839874267578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (27+1) (a*x) = _ + rw [BR_succ, endpoint_27] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_29 : BR 100 29 (a*x) = (426784650831293292281412207847841256124072684607202708581949295926943490434224077255935995437302025097117267850493431424976593357990103997558135674517625299903728738379187555493315566424554438870750230569897280008974916432633208290139488376034447405109241081914118772663 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (28+1) (a*x) = _ + rw [BR_succ, endpoint_28] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_30 : BR 100 30 (a*x) = (8686626107613322343306702152905749507587292626982009142417592262781147940137091045151344841771104931144134353178671820102185622355310500747379622719873905352133796250364948363408146650752541288873612582542823519915563341164711900054085565400945273785161508292835015563173 / 19176146348819244348030359199165139230371935595700974863716988739012129901256702564297257359520827938582748326426296400442062182071971558214091854781675638485363693220546335658355241449157801980618387460708618164062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (29+1) (a*x) = _ + rw [BR_succ, endpoint_29] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_31 : BR 100 31 (a*x) = (107994068025745799157714528724894921958194924664469451369478236367028187903278581388854746525691637392806040644194926945650361378282117612147115989709522870980574997629992129278804242512196596700200782259636536835581262938360886027444626569580211771045817188309774064399977 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (30+1) (a*x) = _ + rw [BR_succ, endpoint_30] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_32 : BR 100 32 (a*x) = (25649155396038986885928285256511162455997254364844664738539389395863485906718314131336234061873502394970333261837339821160888266129313788615460852678855900752008158467676284018551442387509597685388421341987419537933986415068623714821739892438402322281790077631353361241908031 / 245454673264886327654788597749313782148760775624972478255577455859355262736085792823004894201866597613859178578256593925658395930521235945140375741205448172612655273222993096426947090549219865351915359497070312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (31+1) (a*x) = _ + rw [BR_succ, endpoint_31] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_33 : BR 100 33 (a*x) = (181981990587667947431612744549282118853852014428929632236851553539725489748096287500121063718706835731189325526739518340081713127607741949685558475447060089434259571523412755227773355209764138962718187367957299762388702821636462164545152865161113622609512414474341012402334837 / 122727336632443163827394298874656891074380387812486239127788727929677631368042896411502447100933298806929589289128296962829197965260617972570187870602724086306327636611496548213473545274609932675957679748535156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (32+1) (a*x) = _ + rw [BR_succ, endpoint_32] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_34 : BR 100 34 (a*x) = (4824873177385831622716497317260653873308652607554718676020554986865811631021702401661466531743437556617929196002800736755227577684147972929351276270179050287119034515988487009675360989368696248476439361076133349517384810435243033984741821243527084558409114699569825039021537 / 239701829360240554350379489989564240379649194946262185796462359237651623765708782053715716994010349232284354080328705005525777275899644477676148184770945481067046165256829195729440518114472524757729843258857727050781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (33+1) (a*x) = _ + rw [BR_succ, endpoint_33] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_35 : BR 100 35 (a*x) = (160501724581004294249574199169637799296215524425286535788827642855556955749717886816692187592210287615770989088443396863164290209662388163967419895692213884526799324601083179554024447632244172538235845179081667425186288977184228560316107982734521263815371800751539201616326533303 / 613636683162215819136971494373284455371901939062431195638943639648388156840214482057512235504666494034647946445641484814145989826303089862850939353013620431531638183057482741067367726373049663379788398742675781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (34+1) (a*x) = _ + rw [BR_succ, endpoint_34] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_36 : BR 100 36 (a*x) = (799061741562660084438478032944302259898011274842830389124242340623089426463103550221181547398240289296023374212120432434016193214161030579376091622082026143321969373054010343458078481330344896838337429420705930124526916786951623757676094744599286848249076617459270730235487848777 / 245454673264886327654788597749313782148760775624972478255577455859355262736085792823004894201866597613859178578256593925658395930521235945140375741205448172612655273222993096426947090549219865351915359497070312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (35+1) (a*x) = _ + rw [BR_succ, endpoint_35] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_37 : BR 100 37 (a*x) = (297848908538353536871512702119998108212083131690715370298848727464982841198033722950657271439849726149920713020062321045973418806890868674709934196823010252456788114561418250754192602211652082486570847785186000493850302490579608354429602681020717413571545034258961481372582355983 / 7670458539527697739212143679666055692148774238280389945486795495604851960502681025718902943808331175433099330570518560176824872828788623285636741912670255394145477288218534263342096579663120792247354984283447265625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (36+1) (a*x) = _ + rw [BR_succ, endpoint_36] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_38 : BR 100 38 (a*x) = (851616569091339546439598677785748866211711424868920010474187545200764970241544995889154828649370700729133296333319978176615785575563157612887292564769738735681745865595281494549961711823173414364293205815127244427490487424763884898598699056275229782487194604220440262272313918023 / 1917614634881924434803035919916513923037193559570097486371698873901212990125670256429725735952082793858274832642629640044206218207197155821409185478167563848536369322054633565835524144915780198061838746070861816406250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (37+1) (a*x) = _ + rw [BR_succ, endpoint_37] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_39 : BR 100 39 (a*x) = (37372529623157412325937135592340762568946408605674608410158770408413420044586694476532131003547272976149051402882717611552014736480670275016545104089815313816013699854779069608851861625485880364577429190745058029766941051471934694647793750434164527850364903704603119536481803243089 / 7670458539527697739212143679666055692148774238280389945486795495604851960502681025718902943808331175433099330570518560176824872828788623285636741912670255394145477288218534263342096579663120792247354984283447265625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (38+1) (a*x) = _ + rw [BR_succ, endpoint_38] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_40 : BR 100 40 (a*x) = (7869564459074036170234855217488774379747233415283489825247632183720430815572882639644681744960734071064326261015737999903878656641844469244863186120254869873856213492070501758805492927522287731798832650336086821765472718524784205665922926531315454325904987351037312957039480868894623 / 153409170790553954784242873593321113842975484765607798909735909912097039210053620514378058876166623508661986611410371203536497456575772465712734838253405107882909545764370685266841931593262415844947099685668945312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (39+1) (a*x) = _ + rw [BR_succ, endpoint_39] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_41 : BR 100 41 (a*x) = (7954278094825668635725767564428618430830020251065385406699982414602229372192859091434934846626110790473801547176752388556650243235273635433583956793979189778185726253186583353198556918323960644122079496739953816033096653411610476339451378633997050765178055180766449821221243655547207 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (40+1) (a*x) = _ + rw [BR_succ, endpoint_40] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_42 : BR 100 42 (a*x) = (9651353612421077485152039872437159758622406407254771075046474847848651420528251830878499737316297023706147060134970582452300589604626735802764241249810378246653555444951019935675230333787407244951874507110473209668048213572962854281388326314567438917949662586733672769676096976761817 / 1917614634881924434803035919916513923037193559570097486371698873901212990125670256429725735952082793858274832642629640044206218207197155821409185478167563848536369322054633565835524144915780198061838746070861816406250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (41+1) (a*x) = _ + rw [BR_succ, endpoint_41] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_43 : BR 100 43 (a*x) = (719967241689010272412490826991858458252530636702066522345367880463040804599835183735921525870204644016085261253317586619460783264198766431021859605047244542565412414331656792747021561412197976407937310357880657108965306275370082451206438158066046319753826239515532895884461372769002009 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (42+1) (a*x) = _ + rw [BR_succ, endpoint_42] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_44 : BR 100 44 (a*x) = (12901758465483990634373361234750729017790626662284911949050262161572058778016030146690559317620389554676257475184242544957601497022034747492763407614224888551815049549697795735146901585606950118437820983188817325896090009738589207637063540123676403490102480325968928822268102906143838521 / 30681834158110790956848574718664222768595096953121559781947181982419407842010724102875611775233324701732397322282074240707299491315154493142546967650681021576581909152874137053368386318652483168989419937133789062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (43+1) (a*x) = _ + rw [BR_succ, endpoint_43] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_45 : BR 100 45 (a*x) = (138879061443011627590505791556714936835229812034549823326635271157330453182654251033163643379594157594035178540591262874898454480927568076148677382069469565847720827311306753032529535084200110132976723530192026801072387919633787515355158040497193504264107180625365573017513460259540730709 / 38352292697638488696060718398330278460743871191401949727433977478024259802513405128594514719041655877165496652852592800884124364143943116428183709563351276970727386441092671316710482898315603961236774921417236328125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (44+1) (a*x) = _ + rw [BR_succ, endpoint_44] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_46 : BR 100 46 (a*x) = (57483378100619231736810759908443737895862728696846364970513669388827920959448840467700784728249001769532100682269387380584575613236880042711549362660671484971784810644388373420229858199686927656398616180673434837782079856747110942998689607925838587081905063514178639579707318813223371339 / 1917614634881924434803035919916513923037193559570097486371698873901212990125670256429725735952082793858274832642629640044206218207197155821409185478167563848536369322054633565835524144915780198061838746070861816406250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (45+1) (a*x) = _ + rw [BR_succ, endpoint_45] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_47 : BR 100 47 (a*x) = (1830070349764776286349708082822233058725194620724821667891292288098688425583498801295342153205283231886580005440899551724273552775698991381186885959488133070883618315369997382863157853138031575913958716526258061987018970568812112210898765052524885695691578916672766398061063410421786955983 / 7670458539527697739212143679666055692148774238280389945486795495604851960502681025718902943808331175433099330570518560176824872828788623285636741912670255394145477288218534263342096579663120792247354984283447265625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (46+1) (a*x) = _ + rw [BR_succ, endpoint_46] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_48 : BR 100 48 (a*x) = (112050135114813216635540272664379590607045221946499270701506349614948733776404881154461537716814359583959932951468609106844917542785015343052905572614999644262078209830032914204986745792466495860052402849767418074494687614494681831660470672536173177090465295012263647217492462306916686365971 / 61363668316221581913697149437328445537190193906243119563894363964838815684021448205751223550466649403464794644564148481414598982630308986285093935301362043153163818305748274106736772637304966337978839874267578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (47+1) (a*x) = _ + rw [BR_succ, endpoint_47] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_49 : BR 100 49 (a*x) = (412355926056752893094009780522834378106367877273864551654048157998529004262872115002199108822216264197420044100759942556008903989574950381033414565951923821133247854458325406119828710228420254763492857106596079204313619231967110331100601265186686958715377060584722548724533357030869685880221 / 30681834158110790956848574718664222768595096953121559781947181982419407842010724102875611775233324701732397322282074240707299491315154493142546967650681021576581909152874137053368386318652483168989419937133789062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (48+1) (a*x) = _ + rw [BR_succ, endpoint_48] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_50 : BR 100 50 (a*x) = (4560902379630792353205682706606490329719678406856721879122297356372515622975332851146119949823257328901493026157039861488031229994432010155527798702177295996820598272035717912309450038778313057805059642401418193985899394326158063007237989520100025578348936949053076882587206305955852190526947 / 47940365872048110870075897997912848075929838989252437159292471847530324753141756410743143398802069846456870816065741001105155455179928895535229636954189096213409233051365839145888103622894504951545968651771545410156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (49+1) (a*x) = _ + rw [BR_succ, endpoint_49] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_51 : BR 100 51 (a*x) = (19873703728129378770094220585688357925577068988410801282898008950544188898993779799251559815846039449752819831676424296564790605906201783599235096269690632026350134808220235792441407239651557694450956475354356676616285615635492343200135632535973405991541018262519867394464274651913445121105571 / 30681834158110790956848574718664222768595096953121559781947181982419407842010724102875611775233324701732397322282074240707299491315154493142546967650681021576581909152874137053368386318652483168989419937133789062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (50+1) (a*x) = _ + rw [BR_succ, endpoint_50] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_52 : BR 100 52 (a*x) = (260288459026079785277197203696677268655167528635403801755987792646014718247286869410377807630109655736935599257060631167142466111178557515377762658547785588691391294872936205242378014968476709040231072450144953156800686300041792595519037565307805929251382249041428926481279430681451722948545421 / 61363668316221581913697149437328445537190193906243119563894363964838815684021448205751223550466649403464794644564148481414598982630308986285093935301362043153163818305748274106736772637304966337978839874267578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (51+1) (a*x) = _ + rw [BR_succ, endpoint_51] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_53 : BR 100 53 (a*x) = (204929867480469334771546471291695621874040534700259366157442680282615405536141440987199681512822073274718322136709529937904725982095452538783453563284640771055737046142368356425507046100855559139061101331104302083751002642431379600610137643438081365739713646594948386961799671323043862796827633 / 7670458539527697739212143679666055692148774238280389945486795495604851960502681025718902943808331175433099330570518560176824872828788623285636741912670255394145477288218534263342096579663120792247354984283447265625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (52+1) (a*x) = _ + rw [BR_succ, endpoint_52] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_54 : BR 100 54 (a*x) = (310358566526854386550520348510910570789621883092715783197637054547989148978853999496727834945237348420788475438261992125264281419771988287151878557863474183680541581389920176351039930491739510053000036702405617578543476616459581777998512195713275379628446358496403460831734499706926805311870189 / 1917614634881924434803035919916513923037193559570097486371698873901212990125670256429725735952082793858274832642629640044206218207197155821409185478167563848536369322054633565835524144915780198061838746070861816406250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (53+1) (a*x) = _ + rw [BR_succ, endpoint_53] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_55 : BR 100 55 (a*x) = (36162792242407833245210897625900247533534871700123379801492120394637823717681207404342372512082364495499314551962896703588193179886782034920126728231751148263299623162759610730733040229741466253435065197473857921609116560219331553388972346595620096231436977025386245418293004515127347329037956459 / 38352292697638488696060718398330278460743871191401949727433977478024259802513405128594514719041655877165496652852592800884124364143943116428183709563351276970727386441092671316710482898315603961236774921417236328125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (54+1) (a*x) = _ + rw [BR_succ, endpoint_54] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_56 : BR 100 56 (a*x) = (162079912051180315024594572484547697342017736819996707293358529220630203316166985328739658909871709910660596751946841124990090558497473510115081350153199011419501306618259748359454314322888561660039665221940869707783827996634087163183762733684639534241179403222733297900372789380905206114780576871 / 30681834158110790956848574718664222768595096953121559781947181982419407842010724102875611775233324701732397322282074240707299491315154493142546967650681021576581909152874137053368386318652483168989419937133789062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (55+1) (a*x) = _ + rw [BR_succ, endpoint_55] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_57 : BR 100 57 (a*x) = (436548291156718774883715450897360838097884649315103598234961799017289160309101748137566332283452043605780740575711981473613486076616465123052577904599316381491501939369661158328544884317724629590539365039838648544160121764919133982199869864623788118587939674784887565275184193241188524435139995559 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (56+1) (a*x) = _ + rw [BR_succ, endpoint_56] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_58 : BR 100 58 (a*x) = (282595648545788696051523447982607406451277398441227515260363825201702923180667472335648399555499797582000481151460047221269998155789738485220539413725622700127517130712014255029807002893810797043337846790046886743524559064913801627239702849319364036467708850901206204636542414219362829967760658667 / 1917614634881924434803035919916513923037193559570097486371698873901212990125670256429725735952082793858274832642629640044206218207197155821409185478167563848536369322054633565835524144915780198061838746070861816406250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (57+1) (a*x) = _ + rw [BR_succ, endpoint_57] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_59 : BR 100 59 (a*x) = (11253564919457319999884738859814300688555380722531455100736231854290593883440351701672179743664327186325105597616406358755356628747697996318672887525150353243810683010950225957408201143491757490711463692983358579466125748945869042705837952981930925730658374432649625796370360455800980213958142363257 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (58+1) (a*x) = _ + rw [BR_succ, endpoint_58] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_60 : BR 100 60 (a*x) = (538325166897099737384656446837851603617435585991261528909686963941393802848167342413801574998510144444714177889761741556809181277607541541786443446665030041959798332551316515130510378219771672452472229991746151695923213229829227284890781250430286589262248537722328172635606431674887127283985170383873 / 153409170790553954784242873593321113842975484765607798909735909912097039210053620514378058876166623508661986611410371203536497456575772465712734838253405107882909545764370685266841931593262415844947099685668945312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (59+1) (a*x) = _ + rw [BR_succ, endpoint_59] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_61 : BR 100 61 (a*x) = (123704142348012034867089398257505802538481949038493768922629715738038454221170922054781388129621026995628168574358888033187643432551283522068950804341410269655438261462738235370307059225503147319307610952908426385964295585897347221923792216088154828875028104313723063545667855072907657913799517600239 / 7670458539527697739212143679666055692148774238280389945486795495604851960502681025718902943808331175433099330570518560176824872828788623285636741912670255394145477288218534263342096579663120792247354984283447265625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (60+1) (a*x) = _ + rw [BR_succ, endpoint_60] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_62 : BR 100 62 (a*x) = (136518106994975384262420327096036237398232463662844764718747295947247525879248272813059638671844668723686032918363617260123282103862742858660711534241919285376253121291854418659655604119646033138872059424929869944990471745280197052939079374633210319981305786565971987286160025248590404147368615263873 / 1917614634881924434803035919916513923037193559570097486371698873901212990125670256429725735952082793858274832642629640044206218207197155821409185478167563848536369322054633565835524144915780198061838746070861816406250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (61+1) (a*x) = _ + rw [BR_succ, endpoint_61] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_63 : BR 100 63 (a*x) = (2314622507746437970767206795418404164277880756680842841736732156044926956247236939027571623885300893560164033949081839735679094373129433954107098199668079420349857881496062105789625230034297681206363461850741095544180727969638461708668195766373547014180653849868881822384702238086944785170228727395633 / 7670458539527697739212143679666055692148774238280389945486795495604851960502681025718902943808331175433099330570518560176824872828788623285636741912670255394145477288218534263342096579663120792247354984283447265625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (62+1) (a*x) = _ + rw [BR_succ, endpoint_62] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_64 : BR 100 64 (a*x) = (301354067455646296741875585479636494816186091753486568023726508738453745952964224622294817025038998944274337272612891710387028048699924917526674592261018439287087974539774496235860549070919072600685986449464635875907274219832276627625231166635084202264210219396368989938733612479543961952182639306746327 / 245454673264886327654788597749313782148760775624972478255577455859355262736085792823004894201866597613859178578256593925658395930521235945140375741205448172612655273222993096426947090549219865351915359497070312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (63+1) (a*x) = _ + rw [BR_succ, endpoint_63] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_65 : BR 100 65 (a*x) = (2941163651544582781898753688181077141939803360415038891505296075039142737205523348753661283430051548848171703259950743250070186743779897737651255400308061244778068097438606618782896781925706564754534927189360926177956964773928842776140879114094588003719681695602569952864582625251098877555001808484796553 / 613636683162215819136971494373284455371901939062431195638943639648388156840214482057512235504666494034647946445641484814145989826303089862850939353013620431531638183057482741067367726373049663379788398742675781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (64+1) (a*x) = _ + rw [BR_succ, endpoint_64] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_66 : BR 100 66 (a*x) = (68830270448157036089746653343922866745439254303549177390188845930820999761258472622084878327154736255750087154946920301392789376523075865271723061247087494466852320317336291547780828997810311862486614136277659743347639991764959064594832897852807216709860539766161970665906074050173015103068134551067667 / 3835229269763848869606071839833027846074387119140194972743397747802425980251340512859451471904165587716549665285259280088412436414394311642818370956335127697072738644109267131671048289831560396123677492141723632812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (65+1) (a*x) = _ + rw [BR_succ, endpoint_65] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_67 : BR 100 67 (a*x) = (7906695264564796289712719715711519597082407734312166353719811459967079622201193474899144440062796536502131407405975060232079440192414242178404942671624545663523980372141804049471074165218297461690408194473672512872846515769131485415370971204115348847418565878840909920593837889140708108152946557897686987 / 122727336632443163827394298874656891074380387812486239127788727929677631368042896411502447100933298806929589289128296962829197965260617972570187870602724086306327636611496548213473545274609932675957679748535156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (66+1) (a*x) = _ + rw [BR_succ, endpoint_66] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_68 : BR 100 68 (a*x) = (54395961203251870628131404615775963298995094280399906778915236441095025759289122603405459409837997912820673159467332492698932707567828248203356328393315086484791718302320188981034902597561018451312002689325143036816197983336765418870109959904547399601256996057598208349021182565696334846534715778621306081 / 245454673264886327654788597749313782148760775624972478255577455859355262736085792823004894201866597613859178578256593925658395930521235945140375741205448172612655273222993096426947090549219865351915359497070312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (67+1) (a*x) = _ + rw [BR_succ, endpoint_67] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_69 : BR 100 69 (a*x) = (11200527586432494694865976036922462698284174048180199443095623395074279306786318987897831352451644002284224484001727613716319597150094892219396575839474519329729209503463608259913606327380703496595598613468752481770590736394313785632250990128188576709094960350560096264038668256265474584935004037372173527 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (68+1) (a*x) = _ + rw [BR_succ, endpoint_68] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_70 : BR 100 70 (a*x) = (44151677876043834972244774136826762051270876598409875882010489658976336176424107148808240430095137382788424868220033708991897930821356068632123025878909230710356623937253916828970904918883694062670616126730453130003374486837343398789823832082929962770464024404800534796003456856074150356286591085813297923 / 19176146348819244348030359199165139230371935595700974863716988739012129901256702564297257359520827938582748326426296400442062182071971558214091854781675638485363693220546335658355241449157801980618387460708618164062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (69+1) (a*x) = _ + rw [BR_succ, endpoint_69] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_71 : BR 100 71 (a*x) = (106556980822706861474290314894943196872204470220732961235847963603971648178836932808264597970552388836449479615123465675446230488571744477889414979250241117189089693373473506250943287430796792792590088410591175446049218946567054454018944099529749440377524157449723615096442618370879759178344155335200344713 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (70+1) (a*x) = _ + rw [BR_succ, endpoint_70] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_72 : BR 100 72 (a*x) = (1229288071844847975065717219130390450995686207775721813032738580852997781016100709288528455311119159434909797918839212114695931526989507201715706834783644125320085329493656302083253353106274470173796849600193058863789625060376175698073039357510804769848559874118633496884194901981202866473417066538240615311 / 61363668316221581913697149437328445537190193906243119563894363964838815684021448205751223550466649403464794644564148481414598982630308986285093935301362043153163818305748274106736772637304966337978839874267578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (71+1) (a*x) = _ + rw [BR_succ, endpoint_71] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_73 : BR 100 73 (a*x) = (1693578884534885585919320183570472875085625314030003337479938547961188265039067107812383008951756048990757130950145568782147701716677710186941460994627200529176636230858820513521294178596925203683321805164436584946683318223441019775836296821636056563871655403700245809603364441392428755097162770475804921227 / 30681834158110790956848574718664222768595096953121559781947181982419407842010724102875611775233324701732397322282074240707299491315154493142546967650681021576581909152874137053368386318652483168989419937133789062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (72+1) (a*x) = _ + rw [BR_succ, endpoint_72] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_74 : BR 100 74 (a*x) = (556867763075371473986935191598408803980619388356216077384559569216440169106463072436618778830943053432489215586717835759139471073285136723498425471452174199530325825419032847016353872714064856630070061490668063263930209930677613625999794831434540090717121403480148748410943396698022440893030970374716374313 / 3835229269763848869606071839833027846074387119140194972743397747802425980251340512859451471904165587716549665285259280088412436414394311642818370956335127697072738644109267131671048289831560396123677492141723632812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (73+1) (a*x) = _ + rw [BR_succ, endpoint_73] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_75 : BR 100 75 (a*x) = (279473682552262573709016587286599977279342457170784379979568243002014956763228390014909093280725392657778611907908755639832726658066858168760873200857396841460807870803112330992314688874092060502102809620765032126921425205617664926221203487990413788643063786238920394933633865415451378345273771787411581969357 / 767045853952769773921214367966605569214877423828038994548679549560485196050268102571890294380833117543309933057051856017682487282878862328563674191267025539414547728821853426334209657966312079224735498428344726562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (74+1) (a*x) = _ + rw [BR_succ, endpoint_74] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_76 : BR 100 76 (a*x) = (53476476356659259764677384841374041866596176305274443969651574535291592723980595805887407072700558020891943660289207459028192672054998538773628797221497678091764825608913408405715279002544796229065107459383242524326118334699935418875175961206693465209305795674147340189979489871036233498606052088536095223261 / 61363668316221581913697149437328445537190193906243119563894363964838815684021448205751223550466649403464794644564148481414598982630308986285093935301362043153163818305748274106736772637304966337978839874267578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (75+1) (a*x) = _ + rw [BR_succ, endpoint_75] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_77 : BR 100 77 (a*x) = (30453965991867494249774324737329747848751024962684835834678451499938188898105342695176228883381495617793393058251062921635463648279695390250212518594070554986090715045317181797007126568344305243495155448932334341502270641277034100132339290515618440890104890493117231847259675502043731177820495299245679184617 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (76+1) (a*x) = _ + rw [BR_succ, endpoint_76] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_78 : BR 100 78 (a*x) = (16502836111938788405764566189534545184408997131857457813532103327062689408440812972835656207209311700238684327114925687857788252256075270305678305331933831541252642885707573298503944147811889801940797356294346997056497909592374969015574469992968722131790782047415978824186572245953364080958239782658812394107 / 3835229269763848869606071839833027846074387119140194972743397747802425980251340512859451471904165587716549665285259280088412436414394311642818370956335127697072738644109267131671048289831560396123677492141723632812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (77+1) (a*x) = _ + rw [BR_succ, endpoint_77] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_79 : BR 100 79 (a*x) = (136033017392532117560682515540525854184282869760716088056625716037459414691867163491026540171696764049531055370805469070866063883980676483517565418935259622392576075567770217807654872205970241969224109859410414066493861739334590707866502046188625831523106023038740476375391717702886206204497648303118508449271 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (78+1) (a*x) = _ + rw [BR_succ, endpoint_78] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_80 : BR 100 80 (a*x) = (10651194113126646509935380746603779137665619077966134641750216153257323810650008012017543730421374643476246650042404692899927011080360108682876743932196307532411162107895624593963230455746654503610830020970686248321685003358854579085980340897920558392280762271842091882103206538089190302965510351982982313360817 / 613636683162215819136971494373284455371901939062431195638943639648388156840214482057512235504666494034647946445641484814145989826303089862850939353013620431531638183057482741067367726373049663379788398742675781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (79+1) (a*x) = _ + rw [BR_succ, endpoint_79] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_81 : BR 100 81 (a*x) = (1978734894658271576657998502374743336093534108944492341649960294924040517267919494183717180216012817769212399294722349779702004212756444158726905390537162114171090717032117128498498847992707803702917409079542004491724434521453552174293325894278198652118132869771729785424222215297067999324171520419816027020411 / 61363668316221581913697149437328445537190193906243119563894363964838815684021448205751223550466649403464794644564148481414598982630308986285093935301362043153163818305748274106736772637304966337978839874267578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (80+1) (a*x) = _ + rw [BR_succ, endpoint_80] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_82 : BR 100 82 (a*x) = (217873254556818191353634129033338890042173022303845960109580651867322820952652260525680693045839675890543681583924877948689092946322629207929097182659102064423674369376897681333711609831203088927203591400670276058006714092154138051582449363533787347892407513171690725053445300406963794654689093417224041711143 / 3835229269763848869606071839833027846074387119140194972743397747802425980251340512859451471904165587716549665285259280088412436414394311642818370956335127697072738644109267131671048289831560396123677492141723632812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (81+1) (a*x) = _ + rw [BR_succ, endpoint_81] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_83 : BR 100 83 (a*x) = (5819747756152951419671919409487790662039006763181339083145044064713287373550505053124986377301419438147303657018374957669888480875476274389048956663680652991530859355688276789377310702331177331348858303799296990131819201708005449921358713158270096625837943579161358544137382197427844573577496465365258313838277 / 61363668316221581913697149437328445537190193906243119563894363964838815684021448205751223550466649403464794644564148481414598982630308986285093935301362043153163818305748274106736772637304966337978839874267578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (82+1) (a*x) = _ + rw [BR_succ, endpoint_82] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_84 : BR 100 84 (a*x) = (18404752972073153761820322863310915514492358578223191704699013706187543116712776784476192193601601756753118160287069140338578559381834992852767987407474979640361639633261562161026050681875583125088075036007171262123910251645800341422807153696691278812971926328340055849324573530724328674828260598204486284273523 / 122727336632443163827394298874656891074380387812486239127788727929677631368042896411502447100933298806929589289128296962829197965260617972570187870602724086306327636611496548213473545274609932675957679748535156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (83+1) (a*x) = _ + rw [BR_succ, endpoint_83] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_85 : BR 100 85 (a*x) = (17222974779662597075188083097241044970906498770920627768330765517526138791506986975226465593881166297364579526861559234469138726803111918356982873087159277347275414432226965749782264970337771903135870133946206153692223443553656814228321018511506996599917536762781542600535344597200336202541101142417518955647737 / 76704585395276977392121436796660556921487742382803899454867954956048519605026810257189029438083311754330993305705185601768248728287886232856367419126702553941454772882185342633420965796631207922473549842834472656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (84+1) (a*x) = _ + rw [BR_succ, endpoint_84] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_86 : BR 100 86 (a*x) = (1221055400455628940036501670046481316941443130325861160810092367733135979594905906154795053200717272091394428136049307827397253630886633738466745119774909989765145001045496197682066061305925997323593535845658570639269263467788830213871256482369838788842109984315165495159597067040540855787160460815213643317081 / 3835229269763848869606071839833027846074387119140194972743397747802425980251340512859451471904165587716549665285259280088412436414394311642818370956335127697072738644109267131671048289831560396123677492141723632812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (85+1) (a*x) = _ + rw [BR_succ, endpoint_85] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_87 : BR 100 87 (a*x) = (6563117957973946494589181638574630581466233908530836470769092563809334771158793001365767325027120981344918800582517196643454962390781918062252364911907754447366840832212771144123533523986872680490112981431686577942053114761818942908060390467278449077765303917495231394344328266832502620937696392942301351753147 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (86+1) (a*x) = _ + rw [BR_succ, endpoint_86] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_88 : BR 100 88 (a*x) = (33479025712721509574438218766493384328314747692189075923308700089793960581380292366241857304899829029942925972581967767793503712122097364759016114380152901891307355588635773662847684469754173349281240837329188800599196373315784405684631174444857722324856412802294941749415924365954513987277585589963258931795087 / 61363668316221581913697149437328445537190193906243119563894363964838815684021448205751223550466649403464794644564148481414598982630308986285093935301362043153163818305748274106736772637304966337978839874267578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (87+1) (a*x) = _ + rw [BR_succ, endpoint_87] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_89 : BR 100 89 (a*x) = (20309417360891767731239127711393899274516854246193516961569525335141173553633152287787873372382606002350273131955584828733344236626591774600324730057977641301915411705329536053124840652142115844679716260019740548473938310682572108358390670802399785880737181409946742524772538222987972887959014298840001150953927 / 30681834158110790956848574718664222768595096953121559781947181982419407842010724102875611775233324701732397322282074240707299491315154493142546967650681021576581909152874137053368386318652483168989419937133789062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (88+1) (a*x) = _ + rw [BR_succ, endpoint_88] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_90 : BR 100 90 (a*x) = (14705614631838034488358719808933976147598641644920527878883451207690938679791389769920372617576965723392069904485051298976481505260085918870787509471093373794012364318466408274627656503034793813987232274953204382838580178681201986516440217915365465046184586095803881172662092759746194032673515001838026995239787 / 19176146348819244348030359199165139230371935595700974863716988739012129901256702564297257359520827938582748326426296400442062182071971558214091854781675638485363693220546335658355241449157801980618387460708618164062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (89+1) (a*x) = _ + rw [BR_succ, endpoint_89] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_91 : BR 100 91 (a*x) = (26161375856066649909731405553496098306425877154571135907502883425543607758486110440335560805538742627816216820872508025622359795616121627418553290709155163842716135558192219738239896396784935439420494962284462515447199319471853317552885329287826407727969568511382140488740441808347069013670882186370232777687513 / 30681834158110790956848574718664222768595096953121559781947181982419407842010724102875611775233324701732397322282074240707299491315154493142546967650681021576581909152874137053368386318652483168989419937133789062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (90+1) (a*x) = _ + rw [BR_succ, endpoint_90] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_92 : BR 100 92 (a*x) = (56193498907302069005502869509194047836348793222480699072775297861263150290565060111586823026639982751248849407820370975044514949942454903795173523195027690534515079696421514168934584158964105218616260648373024899465905465261181549376425111584983320072853581116156757938042469769419211850400444040246008707408373 / 61363668316221581913697149437328445537190193906243119563894363964838815684021448205751223550466649403464794644564148481414598982630308986285093935301362043153163818305748274106736772637304966337978839874267578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (91+1) (a*x) = _ + rw [BR_succ, endpoint_91] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_93 : BR 100 93 (a*x) = (14681801449256711848189625952733968177638832553760659733688367533350488980441696092182500012552736587340304433089543982794084629937339905930059895464381828685920571949299784624193664242042316806960507230549877857336077288053383473144658677113911766633293513935276076993534595701268488405393774928802266025664603 / 15340917079055395478424287359332111384297548476560779890973590991209703921005362051437805887616662350866198661141037120353649745657577246571273483825340510788290954576437068526684193159326241584494709968566894531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (92+1) (a*x) = _ + rw [BR_succ, endpoint_92] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_94 : BR 100 94 (a*x) = (3761609566850661497917678252244442463598650876146652065366529229854047490662778909923810538312915855515675061140816998646438293321513489763815255942329833105264439591717269166918570655767101648814491207340028068504680799979881870061875196931185514669268568019519028564800605754173604650205626236166298214009229 / 3835229269763848869606071839833027846074387119140194972743397747802425980251340512859451471904165587716549665285259280088412436414394311642818370956335127697072738644109267131671048289831560396123677492141723632812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (93+1) (a*x) = _ + rw [BR_succ, endpoint_93] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_95 : BR 100 95 (a*x) = (76140862950196118476090187022576492352034881517096560636277882266246964389058914324886682599716283524530180945230265485151024547681413053521943628512676619925802283845175953213315105144947094256509346629876866358119706155254916174086462882457106604679827300018548169882539034869510623857251854213657148074865241 / 76704585395276977392121436796660556921487742382803899454867954956048519605026810257189029438083311754330993305705185601768248728287886232856367419126702553941454772882185342633420965796631207922473549842834472656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (94+1) (a*x) = _ + rw [BR_succ, endpoint_94] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_96 : BR 100 96 (a*x) = (244880007883802940112078885843302965978918291525074301550652710409408658558093908500085836277645803458722621531207364934855998681627099421244754191397535462106094255881947510647594275122513821787487126587121619714877981658940920059725769782663447449260742413792365963326892384435845126901055287291119841730757889 / 245454673264886327654788597749313782148760775624972478255577455859355262736085792823004894201866597613859178578256593925658395930521235945140375741205448172612655273222993096426947090549219865351915359497070312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (95+1) (a*x) = _ + rw [BR_succ, endpoint_95] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_97 : BR 100 97 (a*x) = (122654297560493063850714288113923105164440074295550504793921417879102198214625452315809128707892661468790484148703252047277505043018154157830910770186656031161278677840405732870296094979343918299373599426873952584071277763061151273633272520283181939437422227181008791943319691919748253592279892204226290532009051 / 122727336632443163827394298874656891074380387812486239127788727929677631368042896411502447100933298806929589289128296962829197965260617972570187870602724086306327636611496548213473545274609932675957679748535156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (96+1) (a*x) = _ + rw [BR_succ, endpoint_96] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_98 : BR 100 98 (a*x) = (1917397810551127899613161585275991431382653474106550690383259348763063680949879107987896562848584942324290287658271838053548573773156940512795192295120480549394441241689226442099047373218717663822293194196358530854559020499568124775448391685357575247321391083334645104002435218154769151901049853751894566684901 / 1917614634881924434803035919916513923037193559570097486371698873901212990125670256429725735952082793858274832642629640044206218207197155821409185478167563848536369322054633565835524144915780198061838746070861816406250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (97+1) (a*x) = _ + rw [BR_succ, endpoint_97] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_99 : BR 100 99 (a*x) = (122725586312462937233064861708243771065965857656855693873286591827526870320441360735130574391102936741790697109676371575855288357440481280735683553540721971881734075081242523729080751873076082050548220609038180644818960449326831336534591540348165529623027690644159400479283762951912555412783841872323325170207653 / 122727336632443163827394298874656891074380387812486239127788727929677631368042896411502447100933298806929589289128296962829197965260617972570187870602724086306327636611496548213473545274609932675957679748535156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (98+1) (a*x) = _ + rw [BR_succ, endpoint_98] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem endpoint_100 : BR 100 100 (a*x) = (6136361338543027163239384231703380900436127680712261052118102603356382494105781499677229071527917781012369223581996557805971173297854734774308312258434416699730265437184491293487787488473233338895662370703667880413423192879875848200248329070429833607376014856229076619947953941944186665257987330832738043545694911 / 6136366831622158191369714943732844553719019390624311956389436396483881568402144820575122355046664940346479464456414848141459898263030898628509393530136204315316381830574827410673677263730496633797883987426757812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + change BR 100 (99+1) (a*x) = _ + rw [BR_succ, endpoint_99] + norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_3 : term 100 3 x (a*x) ≤ (1 / 1000) := by + unfold term + rw [endpoint_3] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_4 : term 100 4 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_4] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_5 : term 100 5 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_5] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_6 : term 100 6 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_6] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_7 : term 100 7 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_7] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_8 : term 100 8 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_8] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_9 : term 100 9 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_9] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_10 : term 100 10 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_10] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_11 : term 100 11 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_11] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_12 : term 100 12 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_12] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_13 : term 100 13 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_13] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_14 : term 100 14 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_14] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_15 : term 100 15 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_15] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_16 : term 100 16 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_16] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_17 : term 100 17 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_17] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_18 : term 100 18 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_18] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_19 : term 100 19 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_19] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_20 : term 100 20 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_20] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_21 : term 100 21 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_21] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_22 : term 100 22 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_22] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_23 : term 100 23 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_23] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_24 : term 100 24 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_24] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_25 : term 100 25 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_25] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_26 : term 100 26 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_26] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_27 : term 100 27 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_27] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_28 : term 100 28 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_28] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_29 : term 100 29 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_29] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_30 : term 100 30 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_30] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_31 : term 100 31 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_31] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_32 : term 100 32 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_32] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_33 : term 100 33 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_33] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_34 : term 100 34 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_34] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_35 : term 100 35 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_35] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_36 : term 100 36 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_36] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_37 : term 100 37 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_37] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_38 : term 100 38 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_38] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_39 : term 100 39 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_39] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_40 : term 100 40 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_40] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_41 : term 100 41 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_41] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_42 : term 100 42 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_42] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_43 : term 100 43 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_43] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_44 : term 100 44 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_44] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_45 : term 100 45 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_45] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_46 : term 100 46 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_46] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_47 : term 100 47 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_47] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_48 : term 100 48 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_48] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_49 : term 100 49 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_49] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_50 : term 100 50 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_50] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_51 : term 100 51 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_51] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_52 : term 100 52 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_52] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_53 : term 100 53 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_53] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_54 : term 100 54 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_54] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_55 : term 100 55 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_55] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_56 : term 100 56 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_56] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_57 : term 100 57 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_57] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_58 : term 100 58 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_58] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_59 : term 100 59 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_59] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_60 : term 100 60 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_60] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_61 : term 100 61 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_61] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_62 : term 100 62 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_62] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_63 : term 100 63 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_63] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_64 : term 100 64 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_64] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_65 : term 100 65 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_65] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_66 : term 100 66 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_66] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_67 : term 100 67 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_67] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_68 : term 100 68 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_68] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_69 : term 100 69 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_69] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_70 : term 100 70 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_70] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_71 : term 100 71 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_71] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_72 : term 100 72 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_72] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_73 : term 100 73 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_73] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_74 : term 100 74 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_74] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_75 : term 100 75 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_75] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_76 : term 100 76 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_76] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_77 : term 100 77 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_77] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_78 : term 100 78 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_78] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_79 : term 100 79 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_79] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_80 : term 100 80 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_80] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_81 : term 100 81 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_81] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_82 : term 100 82 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_82] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_83 : term 100 83 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_83] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_84 : term 100 84 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_84] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_85 : term 100 85 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_85] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_86 : term 100 86 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_86] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_87 : term 100 87 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_87] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_88 : term 100 88 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_88] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_89 : term 100 89 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_89] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_90 : term 100 90 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_90] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_91 : term 100 91 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_91] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_92 : term 100 92 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_92] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_93 : term 100 93 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_93] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_94 : term 100 94 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_94] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_95 : term 100 95 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_95] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_96 : term 100 96 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_96] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_97 : term 100 97 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_97] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_98 : term 100 98 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_98] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_99 : term 100 99 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_99] + rw [C_interior _ _ _ (by norm_num) (by norm_num)] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem term_100 : term 100 100 x (a*x) ≤ (1 / 10000) := by + unfold term + rw [endpoint_100] + rw [C_top] + apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial] + +theorem scalar_bound : scalarBudget 100 a x ≤ (262176886517739870942090207942480156842100475366362790767934308983413488398138477673575298296268853202702212461434583523499075906100383538917612263309363261278752340264877110778448939341561773685546932854854511916132169095841691259150049487202678093172428587119260433687458984862205256792202105355581617935326718473 / 24502512758667277658139271770325248303000044426762877641863019531160139102629764268556463563701333106803492501574464488628849373764282378223638008365833863831058312649485285850819993314075873058754950761795043945312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) := by + have h := scalarBudget_le 100 (by norm_num) a x (1 / 1000) (1 / 10000) term_3 (by + intro k hk + obtain ⟨hlo, hhi⟩ := Finset.mem_Ico.mp hk + interval_cases k + · exact term_4 + · exact term_5 + · exact term_6 + · exact term_7 + · exact term_8 + · exact term_9 + · exact term_10 + · exact term_11 + · exact term_12 + · exact term_13 + · exact term_14 + · exact term_15 + · exact term_16 + · exact term_17 + · exact term_18 + · exact term_19 + · exact term_20 + · exact term_21 + · exact term_22 + · exact term_23 + · exact term_24 + · exact term_25 + · exact term_26 + · exact term_27 + · exact term_28 + · exact term_29 + · exact term_30 + · exact term_31 + · exact term_32 + · exact term_33 + · exact term_34 + · exact term_35 + · exact term_36 + · exact term_37 + · exact term_38 + · exact term_39 + · exact term_40 + · exact term_41 + · exact term_42 + · exact term_43 + · exact term_44 + · exact term_45 + · exact term_46 + · exact term_47 + · exact term_48 + · exact term_49 + · exact term_50 + · exact term_51 + · exact term_52 + · exact term_53 + · exact term_54 + · exact term_55 + · exact term_56 + · exact term_57 + · exact term_58 + · exact term_59 + · exact term_60 + · exact term_61 + · exact term_62 + · exact term_63 + · exact term_64 + · exact term_65 + · exact term_66 + · exact term_67 + · exact term_68 + · exact term_69 + · exact term_70 + · exact term_71 + · exact term_72 + · exact term_73 + · exact term_74 + · exact term_75 + · exact term_76 + · exact term_77 + · exact term_78 + · exact term_79 + · exact term_80 + · exact term_81 + · exact term_82 + · exact term_83 + · exact term_84 + · exact term_85 + · exact term_86 + · exact term_87 + · exact term_88 + · exact term_89 + · exact term_90 + · exact term_91 + · exact term_92 + · exact term_93 + · exact term_94 + · exact term_95 + · exact term_96 + · exact term_97 + · exact term_98 + · exact term_99 + · exact term_100) + rw [endpoint_2] at h + norm_num [a, x] at h ⊢ + exact h + +theorem scalar_budget : scalarBudget 100 a x + (1-x^2)/(100-1)/x^2 < 1-a*x := by + have h := scalar_bound + norm_num [a, x] at h ⊢ + linarith + +theorem pointwise : ∀ w ∈ q, ‖w‖ = 1 := norm_family _ _ (by norm_num [x]) +theorem cardinality : q.card = 100 := by simp [q] +theorem mean : q.sum / q.card = (x : ℂ) := mean_family _ (by norm_num) _ +theorem actual_variance : variance (q.map (fun w => w-(x : ℂ))) = 1-x^2 := + variance_family _ (by norm_num) _ (by norm_num [x]) + +theorem paper_budget : + majorant_Efin (q.map (fun w => w-(x : ℂ))) (x : ℂ) ((a : ℂ)*x) + + Gamma (q.map (fun w => w-(x : ℂ))) (x : ℂ) < 1-a*‖(x : ℂ)‖ := by + rw [show q = family 50 x from rfl, budget_eq _ (by norm_num) _ _ (by norm_num [x]) (by norm_num [x])] + rw [Gamma, variance_family 50 (by norm_num) x (by norm_num [x])] + simpa [x, Complex.norm_real, Real.norm_eq_abs, div_mul_eq_div_div] using scalar_budget + +theorem norm_J_gt_one : 1 < ‖J 50 a x‖ := + budget_implies_J _ (by norm_num) _ _ (by norm_num [a]) + (by norm_num [x]) (by norm_num [x]) scalar_budget + +def pc : Fin 101 → ℝ := ![(36603234127322950493061602657251738618971207663892369140595737269931704475072474818719654351002695040066156910065284327471823569680179941585710535449170757427389035006098270837114978219916760849490001 / 100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (809338176815251905346584325421455109463918925012731273219839079635156576726602498769467912872170701441462802789221286796321432262928423152839599617153886747561157551801506210731764518418159489894278911 / 1250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (7107418354342425713712506687262621460887054916517932536848517468645837651003045840578052872626890332814787148590155985798524329643389068007113420680910287190157725569254427740916570325861043737891664796657 / 12500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2581893222356920366265889920247281361976431119635573870306344131602526434050625920984253310416445760999595692121043231822679298025901747329766572232521633379884203421357772344278042951052340223408476735642807 / 7812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (22344761986261354213935200351088406478822179014201163582567007688291459724993469925651389095594636804299900746103525719256963077427946556644659414913795804880045828868411774900516435816312988705019953526471400177 / 156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1499500282131386103687131386735519689561451016064334560020182321551580781225926962852383481253617499453712161283182533751655803751343538205882652970226134698016168300446535139669264384775021777501100207651322188257 / 30517578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (852162407919559786157400901643694160725858265674828572438790132713332287999383848046061060175187925082455588135515055400439374864854902350657491890540453864928267386851330683176806193996698860549348713157732637970673 / 61035156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (128715267944597290968253110008108301630668745018613423999603939950646628475770490304138856009224425129474421078526948617607935148681504201489924997737155135308063481085732575306297089541484715729705951188749218266334201 / 38146972656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1080179973240840633632851063890339294071173539825271190443916773337482733944904765258585648011427592247097287588559962680618561699440335219190233328538270289741314723258998598796250630801704256489660639240235940452788012559 / 1525878906250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (62446918397598479679701762590981540466998469563257224945196536597425938994131995019755597744796674911127339669865228788910485755340294561958835500719223430235439478425031956819064241610560315162292427158367501129209490623831 / 476837158203125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (515632116409875329290507428328721239554382528453497253062530953299380084363804164175457833360005987983320337572047597573465970971901992533232087526403609666677830933063518082825481796854319016539321306951123627762469978939238073 / 23841857910156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (9596375474338230599467042511781261698272622465252054436049761350588225778448664707882149630581129083992345776808542175349992886706155541061478606308628948923428208258750388980863041877646035168843817907771075832133547150981925559 / 2980232238769531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (25973801091445769822052569149166522272650783497592671167420010005197245919365682418514418945421504884275052477982338942837630718736962891701029251625498009604534150950823333187950783665222271327786259669433030776711023036183973191771 / 59604644775390625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (502642232867611930381055995824136430328506669093216133441756394792811752535997873221871660195110931850030702470169581165560542086059587668527374748357942355784422149951027148443915335567386911937866862482405194821996033238682650779639 / 9313225746154785156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (573035751328765826241998779015882307558039542263190334473976837316592536227298652735545156221287759013321606873472127575070109466190024598697210013879058696481586932760627989903338603279447889482172943775766694140055129771075176330036687 / 93132257461547851562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (188856074023640163263544400207573582734374967130477714642436406172613945160287379702287852946366677506726924137366667439270679193697036621652001656577304701933284544455124887868788360650184500955212425691940713684631124198449198466690566159 / 291038304567337036132812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (296070938018644287596771941948200551390757135115582509305711953295969142700097117336414280448601449994023846210623205480193559932488545426150893161994415963272133694826092457537812922003611368348914868678939787996513012650342445872242042007669 / 4656612873077392578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (8454142691305362460247229751360758424354895132268964505462499072832056013612090368744763625305533702633877567907357308027203548964750131209232578515892917719601812901936111037313202307478268982969095835205395459960720779300615096277724511955959 / 1455191522836685180664062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (7227864109047576028217905200310179402411110838147300693864631786440261219099732459365173970700706223690762727366918922184717247746894606424564628333020142818651422782817580505919796570798240741699452828792234694352296266937644003365558515365281329 / 14551915228366851806640625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (362427068495760627306970134977835811940798535287549479748356518925484663748289114640446829998880990765434415024276361024565426218013271304977391720597531076971347284347119929130480926067926345182014297921746664060288001573454241557327386739221035007 / 9094947017729282379150390625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2735747328230634413043710030230445169272161470272302260943214529185719613430563469018555047175965763365948557998500812481887882323369000858209321424937382895350228983107216492746444184608001762357098452677454239696966181562601304029284830343783413310121 / 909494701772928237915039062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (3042927630297425625095048763906148554035683336122293689093587247374825007833186821941522856689401845804796859278715446281066583868753979435363059768296931836974616975704134576828248653202675551864697348141109593307580540557451281059150855440287901672727 / 14210854715202003717422485351562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2047106349293910266538792309760053939986070520332608241123065908399917489257994061961802278869369295639113852872326342268101486985587305569440527818468308208244728312796282295188029327970234842568147581947275993088501838135986960520626416356010964026298139 / 142108547152020037174224853515625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (81497839561278573377473475778388736771474616847918056192259512433988955257267876524272197915042736997506508793266202888682906018745650772911286682977979313373204701164041593946571417900467099710263930774867695737659783719293093460235646772916162328882284619 / 88817841970012523233890533447265625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (196949243840855931759471397901271611683660763855167292629111281223558432431070287060348442730348627494644375871109729523453381439714157906183904357864426713559556568781237606836525702910512995124659711585104459094577751917997439136370466421198928781273499867823 / 3552713678800500929355621337890625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (88306370596961079813159495376894651488103383113287863715745433105634333563659399258660970451505996663435003946460388931138180461944493985504491701701546361720186482597917738345855371663230857303132311488307289559513368528413780951821187357191060056494263986668539 / 27755575615628913510590791702270507812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1928479948795942114330546551818894363555816092057898403931018178065690777977203723574023980063528786801545539130888045189181115267969557656984987148011166920773795914434555891226222623472284435931507660493912969842406573956589618361304787586599503377964324505145489 / 11102230246251565404236316680908203125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (62680910215789195188246973954954126164587451231461576483055933672918773488519196316611662843130346155157964348276391264799430411438861657259464434729880396281481155575443594832665533629387830002602487500557274172863004175574184940859130586606961881702599013793543523 / 6938893903907228377647697925567626953125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (62172086991459997909726221139293993823445354920230631383456719266581161662548049126843593820818249123452572387445871911132279345785501327327740411732512603797104698362578132295177541332237719443752864682304588940389017058974381806659636849586934241979483166560005296211 / 138777878078144567552953958511352539062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (459943779369759749120528085036701057738784512182438707310533984162947117104516823847973799145195863514266341100987875714819896372694948011864361670606545926824610331051784319129918331707926628315675583191651934795396417507231033826278006571469338973243048722761800301557 / 21684043449710088680149056017398834228515625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1040525161570759525744938610253542750877716709148396530543209945968851782882683284193824270195002889011703873475758466311328216505095412159027157971262596577549237697589470168917554828123968158061630041076316260243758424238625438436470908631676929944861432427965504901748537 / 1084202172485504434007452800869941711425781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (5628884509675982116919474199575219281978335672200503425461098541687021427014986655228142019932625648960604434596264610615865742935917214470368111717249524449635293136820913918676432872057218193201576066939491968457982983570852372287150608253185032217817630722169812382050313 / 135525271560688054250931600108742713928222656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (37311641421092491328463998231710665585476399280993286850562949581153216241443872689338085639758440739182344406003658599782298488429506619699318266381758198985529960074511724955000431770593008993841317253990938277246954585863340010195009712413733383337719046604385439179992654111 / 21684043449710088680149056017398834228515625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (462773898310953056397241615482420624142520670929250301151652548304151464329140674277316300065285952364814890691763773489042291427300971629636097945207570852881527696959639625556969314795705474841391255997802034494953404578344168797864866680261118797786383915021132294911346944033 / 6776263578034402712546580005437135696411132812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (176083256725114470526046859309888852100288764605257072386360657804444247181486173736153494287841213090876054609475242889899755500989707599411895372033060618361055245174551113724820791656113725792777846820515955543084601920554451092201367946993031154705623184851323759484192321738879 / 67762635780344027125465800054371356964111328125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (20084846355351934777569122658225217467431336832734885957173732066569913829223244115478946399246773338586427330166729703774079729987829854245914710696290692326884137321964040644422271512228266210546371549759258727660580902600905832952914952561810669084167699041020270669419320453855597 / 211758236813575084767080625169910490512847900390625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2814703748730394342868257699635008546435326502054497094340031919049410353233254129210920263243728162029664716712144077330434079341790224212751278943451834793706751998742417761699026552556256028941887288505982032066100695962232165201630939912609894372036426318749688718387309330837865687 / 847032947254300339068322500679641962051391601562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1849698071495894942500040316629435592580145192825632169075016636722074695997506353147531736035592103428296357853556220280997804950105290496552958451108938071663780627003371778124889006195005802965919274760266877528267141640672033497610493888613711373964523738052950836604145594418998697 / 16543612251060553497428173841399257071316242218017578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (597973721925274504354565320300104831095613126870436887411118141940042504718651871230563623182595525559930090956244643658925070895543916031504679404385119416921014790588290854100339613547497184730079753371814260860561901810973944104408713542916986620433251000974186787200405337701475437997 / 165436122510605534974281738413992570713162422180175781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (11613844607345972800563875649325649523925570732387237954760992215563007742031220966340180158481695734828365772322742618918925395166773133164863944229853749801047936341962345271414641693579361800937594472141515381001132746167229567109045209034679325434474390587424761316888255253896377109861 / 103397576569128459358926086508745356695726513862609863281250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (69410217040491157991925919867089603058810516547951886575790675503710100754805369823821155892421338132896480330746287230677747735262676167241982321738758942960638973983215790723576690458868491007396254995117329378940751215603125912196532849566168598616004094958844254966431999125156935059387523 / 20679515313825691871785217301749071339145302772521972656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (124703170887476276291659943955380149827288270741001567343852517785973701541351499942397525244748756619489201603059467796958979268476742684101143814105875490954456131605729762267564743583217909419328136791558546914128600118226895584816573977617358807644398317925839959766238249534057263533673383 / 1292469707114105741986576081359316958696581423282623291015625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (34494081156828128015341255340690161503764736596964278259297390054294785321146128736019930018794216759571296417750261827608204506684543785960403751109276484427255417539276656762955889046430212923988301634558813425846207879676895487902221936218113346169376903899243305676974305441451883526575345541 / 12924697071141057419865760813593169586965814232826232910156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (573990737277598042309981749395215161114222937065863992979978828043203169182665401403129919305365328240063524721191991789558196942264082999454948694555109871462316617122489435454499191198907293213429052467670733606685144281128080141640315786806949765122351626925711530929848196718746118654386760231 / 8077935669463160887416100508495730991853633895516395568847656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (294261234278873465196182370584187660852760478759429334650309024289662186317298581544148293374571251177171902662211272164185502247104604302152040907915083503481028330526566871948456989501099240200889283059926284762502958409486356060186241042785329673115337670198181421589695388348115891358879694606211 / 161558713389263217748322010169914619837072677910327911376953125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (5674516319535499751541530224773728698858350230674334087935836480949839904172882734184903369156829358093031722142758652108884254891688948736574143596324761420735216385205962316283139977059387802280325796927522721587457863214077063407085347755653981538750206141103011330447834978720452680673036294582391 / 126217744835361888865876570445245796747713029617443680763244628906250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (269803378895222135318487294792054644930744951787896663817580451139192571722152549453611673290634709820393323856041686246825762686051850113559294110798301098141748994499712623340684989157906010452082177288782861663375033349952930828438679983173521741927420442228604205611652879596239094289408255309670771 / 252435489670723777731753140890491593495426059234887361526489257812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (3861532845038145370719861959985990952463246647533905218394286187474796730907454336029983959052282334069718909210572030156107428037830761114026721731645888384484250371484195969725499230611197924194196637214807930164796437276371442044422320669789849659082020235463873859867854410389830449076237483344594567 / 157772181044202361082345713056557245934641287021804600954055786132812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (6815112075090858936657156152193405790031147291600607066051175656880278410788582817243733049806404926836446835797513932025595205380390714317567216952881186307139206909595218903683841852679057601909038499428966204463339533620386356482576918488335266192213634807100297443426061142184461939543837445331089134171 / 12621774483536188886587657044524579674771302961744368076324462890625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (45265860509698367816384094610616946278991307635208523247830340503318655264911874277211522437274196619613435081834333615991475508958691987347438779923854613334762280673019803045819797945234540298760049742467509285310096461601101976938734966849283834402703592419435871111184759818778912502093716453737074953169 / 3944304526105059027058642826413931148366032175545115023851394653320312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (231741104185433314967977924658632400441291452535017750503710021504944316267955179693446740538462757844987418894862377778591367664968881216242372077514120141908366766459937608378407283050159940869168999208957937748629879613344583932416131620068522682754872270248117062427718670862700750235630888971101700440786047 / 986076131526264756764660706603482787091508043886278755962848663330078125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (182896984189834207111175036289668573573547063938566751263884227555547604034871455285364095504386844233579394212398882310670178719546287255478616786426340836921734626765866464689063342355803798629853762866182617611219786753990943718880812511192581280091976835363950610333030065665081493112479672001269452629369 / 39443045261050590270586428264139311483660321755451150238513946533203125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (111261402338803599873654775799537425661670405998178672805220687282019607468415748439727965768728205181119301582879481734951072058223256984892128300407785852267282792895186867650358490492332619651947196938937117974741433956159648601929312584498336878095084145427511817267915039832369363960663733547466102885771 / 1262177448353618888658765704452457967477130296174436807632446289062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (254722333155788978346416625084431152669942860138073408420750832213394506565771636915684450040858433339069642069429036632453489227595376916990194260881762138890908639235572784651586522575011199019051175220154425819197989495043177450268532858242739242383301340421867683457922639155133666372386852088166884367 / 157772181044202361082345713056557245934641287021804600954055786132812500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (71910190419476794908549656938010485413828735854650975033593211908206790328564795996791039999727372541101438490195713698594064183848592792885084776686082319882772311478479582554066942771587263072599306685055170746351992238183329647679516701738416725690927797549938687167575272509065039738265871199359253971 / 2524354896707237777317531408904915934954260592348873615264892578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (6110935044702033384714006331372486568463821790358603814466088247341384878447629126873726848765694958088133029040871493998943877578505539207117190925923726420908072838282416205469406356579986527084734126512312104141567060785483317207585170359298959527370911750627314969996286372807629586260824152409041391 / 12621774483536188886587657044524579674771302961744368076324462890625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1280405803784680488330622075826082373219591572994185150859320744495735829178672961965367911092192562963096741384493596732846509747266668932022982682316724612506013673821202926446923977985196426753086764312146071100606655574615811411556640506015249587917251781228300002654644352988448011832755955521093011 / 161558713389263217748322010169914619837072677910327911376953125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (10091488495481036423580740935760539205160581302185521861568627100241171422046411763005767585452582807977216319074726599210960505659065767148732661368195453589294263855314141543224048455364012273002494062008580800905408054892486648186194799608568559161102635556266870116459841262314587262359273824306831 / 80779356694631608874161005084957309918536338955163955688476562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2450364488044070169764896220625582019151849752514802340788618973964748527599575334078491800698531242695391139796445642960075370648716070707107856257718627998590670854632764335945722088286431206878616006170514818163020383042804783354015000013422128387338187297970178186333622966275746735206008009119941 / 1292469707114105741986576081359316958696581423282623291015625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (35793104572344963989243951207550553844181040406100707019441368453986134579874348024574892564184276549845684218457803614029069938968577778294598001746540171206975280415310456502933671750769933624359775033753747750221979525660501615266152928169789462695385778284946568593559520813993430381145664633983 / 1292469707114105741986576081359316958696581423282623291015625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (80497249015043162414327433492518396245933304047612291779145295106880212880768229135771270291079068676978218213743787687303274793734022046504190584353031813502603965430826803654081268180286952190046461911454667713050645705947862366062858515746920531678733671871621564275235843860747107149779633441523 / 206795153138256918717852173017490713391453027725219726562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (54421362516903067310279447219981145617817514602945702338172179647230889751025877381835142793063520663982256642025376124795018455396136480965374558204029836744931337974967662998857759949518272780772749101594807162407645358959725156048651676079214717346766298755567532603283959281567777071844905661 / 10339757656912845935892608650874535669572651386260986328125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (11321690090680533218640728018016118768724528305606868818510612986070970325444661421043825123162254803677758455969383732885279511790562618645663254497477895123768189020046376500012027569339949144727189174858989992025496153128893100223315393018414380737961542353541117570020022362121451733264685197 / 165436122510605534974281738413992570713162422180175781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (141503040225815967496630488228983352027163355581720467891680017237752585748627266820869643596429508441198553209980987256965154016037413073130116396294484887924949348056915057652267039391116993416034831898769211219871386828899059094579425087016111054362952377775538874211886939934416366154416497 / 165436122510605534974281738413992570713162422180175781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (870028305666861502963625720182052297181829882864770745933427955178945978221485527644698426147263950361498631495472871266460952770879219216272108108571927347532986822557863757190324867234348544102442641913984652898634635076261449574631969560029889505064888786227872980162243561940507435342442087 / 84703294725430033906832250067964196205139160156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (25084472239109842921378682712428087291131615242543129125491070650747339559366626358153061294369991293574979038504625297220967847845174115363429778604071582369488531000868800319922762717381656062398642928893720383854319251620067219736157383404483329213325839645368130223572936456746181714914597 / 211758236813575084767080625169910490512847900390625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (888567204324045327944769431845645928708655670495504117120734293380400373611567464146099267677838849527735814093176491493905969013829900976109397573370213149663282613410619090911849967844770445308841802416439471496939844969621250458896589890389352757147697866631509003143193994370069555886079 / 677626357803440271254658000543713569641113281250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (9435758939801467066086884573517656641215393500570935617314419712000289050935252224469304698703502427374499935461010793955680138596444686321954915029107306915369727422149926825779916068245215220539238199926202638539000095677007727448424135858516874666936294938077943587488568975002123141833 / 677626357803440271254658000543713569641113281250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (3073888429933271004521297912952024538850491187442038047315595889480482084889925124230415210664090368548160217087130432943370691283531870334010142732545792833926683853259326889985501797465049479752549890197287805039798029224428685470978114559906679747492628412262897936319598931034081194511 / 21684043449710088680149056017398834228515625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1873707723620082770740100965663096806998391815397675759242421033123100707976749902150184991728665071723570571743432571836108438995044375061579418573620499363606966084666698434088687293056184536639432155320814420021624553434380270504990237635279971312831575648200366830408798754288310913 / 1355252715606880542509316001087427139282226562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1399483746924619072360767841289692006880258194772708337508298535926124129834467240761522860737755873503662635627446011784543001506313378853439565777680980478450606258660334059186899129538562671808793737462824126359828878294524278572678578633285406549835415092427449498881800792761400537 / 108420217248550443400745280086994171142578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2499515220117110985834888247880498352735221805510298325696547869907152561395951923907396006185039648449025134468024242323932442591656457297150388496636222316796408644253443636850901115215046600804530121729854896152436225635758540592165342373272589908088618687534176878123418385592157 / 21684043449710088680149056017398834228515625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1365155885395154644567586008288839923401957961858763053451947272690558165985498704649779020528755145819759323726329390840228868234050142638777583524851243476128968264829501192921377386547604768901720846090218141091480973957291829361716546248352666914914090942510256139896362269187811 / 1387778780781445675529539585113525390625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (5561063546088664399042317024704373214190304327715297468208800942250452073109824323601651833633482021307026778557591904373230243653918953462796956051870500759308893127290169567017190073058362806417846336146434390121348193480847996369536136141536201116375176380932072929139547807723 / 693889390390722837764769792556762695312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (691310979826695024500064382564090987738521433428563863503315612240165751129213011779013746389043596105090567565620233548986728213080089283219962335313241888579375764538473145415121356309268018603205464281900371793987126476392579536607533133500674794192657590888154092462255998289 / 11102230246251565404236316680908203125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (127904588903847614923016924669578561623659696481384581647994171676051487347217031631124390478318127487035829195751904758238206721464537325656557534668963510139311903705039994234478732010457018971357881009636607329698705840418154083282597913342109257600959915979172262152677223539 / 277555756156289135105907917022705078125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1152614747410191929522089830871522723901918518168312154386692664267221710696000189870968024016525085280499349376249865266629285965775687482969643703935258906288280356000292970201407219361272378477010510605453627105008228905778459406539554772568884405831943142418799989052208223 / 355271367880050092935562133789062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1927133114000440513187805975214296262485736290868024947447862320950694886984296600226588507080500914466152850500202742267366552731446536732129360765487691670050712433153739089364556426074836603131707921596104605363305098376335619649960388415308363286668508660858972424972019 / 88817841970012523233890533447265625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (195587811289388042842176678390145629231460332998380883709492882695322230670189355005187862941558486843284051793106342214995966777440898491006272521119430653805439313686140602716339405028325405699905073948832253882006409623543969185198598895997968933000067489425806995479739 / 1421085471520200371742248535156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (1174704868850334743474887780855467716226184678905144497838950071290100737302622199093324341718882851545857126133276182963666293688856820748496852797346762229778866574910069463322643690308315103004538688131214636547629762630679016996851648623360139074521091326269279506127 / 1421085471520200371742248535156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (4267257913800965558437576392082907195411432935138591190721421513583191817968502698943434949870970454687582827252104819509705555282154869245334645681720218680189560979161379837278482968359936278780875708618911370250720018441802966354560126473139876161219641675389581684121 / 909494701772928237915039062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2284174603860424980387986113379074126965673872034006070233724310933247103450636734032563037077713498973809344500613925940850289699398274358329584770987966363635947153808738893374677778342728553766225026426755008705424184360380402102110156690723535161258694757582021607 / 90949470177292823791503906250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (184057879709784877956489137807182680232355919260793001614575704643528403524656659477411759992472665346569990505516806578805380740060402864760709106760217027745677271998851249461073388196660616581877213305478813798658039202240029206613512568981948600901307118322855729 / 1455191522836685180664062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (869860826748914485175531214898767633852350337138122416968037960975145086364297367560963197241798660283089320134176117433809655375586098408379633441443012055110589439578778776223039111296563289526784160326687612544586917633810397510253863886138602682050520066236559 / 1455191522836685180664062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (123086874193249790607718024552763716403614353327782926539930110394735330087334048026646995761682540100712765807205408205795049861727597755108859554280375682375581582467340836493201013291056431035959209328442897918469501635640489279682321051307579920646025442758469 / 46566128730773925781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (317236159852684711970085943163029051021049100173028060032914075658534126989339502943740698927149629552292867086551054333649428096877283785852292665929200117993665629167608133861054466080484546569387749018302919847719308489143535537774830584840642898837336003159 / 29103830456733703613281250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (3889279984844892191349362945503016512139361192732948368387176954377658898309882823144490544219189638697665404455840340386786167278959984985600881683894299304460118236390075026330495031624676466124243397566408109033548780932235471326098960168878983475370970287 / 93132257461547851562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (13784221082451179006073170103285803563395814922147336233951008521337191702551041354611877798674363617497905533434817196556980164012251797129565300184182438323131685412258397957468508875152277291290126300770984051807800932928335819992010863940718779753981039 / 93132257461547851562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2878024774454125882163215482251220295911965134040198333856991775942513643506242973316245266272673149220521191794634730342753945170180663456023994309387151239469004913438641216421388693710536261856201976011243351789663524724352854080603563142746214147272171 / 5960464477539062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (4296373344526035253668661874506286701521719866574770913358985839639924720675962222551855286956982684511320428643667292694627224376422686454009441334399305786074114009745190594347433348784473412463290016063110502400104870460180607376724514235077031315359 / 2980232238769531250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (932761269320129236898841638204148290259823508435260922270900605707002919575839160265680494432471420184120125398489164176187817505047785648647163044862837059554342192338527139504091109124593635543634160554053015287802527799220085868972700677265523054073 / 238418579101562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (456433298682918924263490504127853498317807918871506755025855045128922291831228950883637840722645565732124578057257079128660439238690068563599280977961394361728744828501448325971153123781008678160311888595593076001856359417651640982989713099361299631 / 47683715820312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (31900551652952905836381291240632328272614709038151889419994141119191637954462645833296997072654065948042722675896908759261955119899615910487320877778724774663407758215708150397389262470043665528683548308485818322102057969155299725362339501075696959 / 1525878906250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (15359175432619519989255290788788956267515271879757044569282804490347282975545252363508523259546034857561186133665749216698291539583878065155855234823598544880246613480960830474758752992382592661772499155018027752115162642442591551806474509895601 / 381469726562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (410861995755414963971486614636616992508802186868285819749231015182997620513651610963469034272064410839924683544587158050536381074398854429286276097153850114861144528628012660556823444896640175813467420967661321508835069674524824246032002248273 / 6103515625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (2921163832395045045617030450633891297895957945100211423628754298777289010295007786203696423837397997915171520391076127342817280185672830804647020473500377873234325929813631128179530173067939506070820181320934191922731769516122089072469425257 / 30517578125000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (175881783024309425258279206208176359300664469078061539853489902507268544992571871314452825509003596048269971556845885730378306274976473123644553630266927710354546404714249697076922815434248404560579376340956673170977101290767480524436151777 / 1562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (82114370489598556170826998218072632259452248156734707850962291211982590009948898090245405143888804024040604302361883415397258869170437164819514846874418712796705395213343018996545278575471160249874614184323464043542922612647929576647007 / 781250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (913331704222547527039498764600458305134967660358589571847122075538371277632825538440006490587779729860090096963050353892481238290132125298574899895158701351170569473443588984192245741298212085990814721618595223394322843515905793369457 / 12500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (420225540365924163853711343139954643494781808665541439904875213073678442610816974633274125001949458726461237686837205874976628262587004169623583751555633169136981605674914298192787043437640498926441817013824901113886162634800001111 / 12500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000), (76790525741798814147739722024656541832379779544942834289320631222830128631361412260809504936077081989500262901451426968889209388663740890500544689219073462496105913250053209678939046505133571429166135524105744097027866266597980001 / 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000)] +theorem expansion (t : ℝ) : + (a^2+2*a*(1-a^2)*x*t+(1-a^2)^2*t^2)^50 = + ∑ k : Fin 101, pc k*t^k.val := by + norm_num [a, x, pc, Fin.sum_univ_succ] + ring + +theorem polar_integral : K 50 a x = ((14313215927707901402812696032528538119334551902447926006635832271609803863644007817037599529155215149965230748737891573673073813461328796095825584593099403616561318103317457698514761610758806542012939294274038354076074324868302713135069383609883803251414851327227994737708450444463078064775328139839194381937553501581252448598855714828779410582917232004133053591418576446613090226774400343085737079866679727436329886774681351007 / 14295771323094814150976518270000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) : ℝ) := by + rw [K_eq _ _ _ (by norm_num [x]), integral_coeffs _ pc _ expansion] + norm_num [pc, Fin.sum_univ_succ] + +theorem full_polar : 1 < ‖K 50 a x‖ := by + rw [polar_integral] + norm_num [Complex.norm_real, Real.norm_eq_abs] + +#print axioms pointwise +#print axioms mean +#print axioms actual_variance +#print axioms paper_budget +#print axioms norm_J_gt_one +#print axioms full_polar +end Sendov.PaperConjugate.DI07 diff --git a/tests/PaperConsequencesTests.lean b/tests/PaperConsequencesTests.lean new file mode 100644 index 0000000..4274bbc --- /dev/null +++ b/tests/PaperConsequencesTests.lean @@ -0,0 +1,102 @@ +import Sendov.Analytic.PaperConsequences + +open Polynomial Filter +open Sendov Sendov.PaperConsequences + +-- AS03: smallest allowed degree, then arbitrary fixed degree and all means. +example : Tendsto (PaperSecant.U1 1) (nhdsWithin 0 (Set.Ioi 0)) (nhds (1 / 2 : ℝ)) := by + simpa only [Nat.cast_one, show (1 : ℝ) + 1 = 2 by norm_num] using tendsto_U1_zero_right 1 + +example : PaperSecant.U1 1 0 < 1 := by + rw [U1_zero] + norm_num + +example (m : ℕ) (hm : 1 ≤ m) : + ∃ ε > (0 : ℝ), ∀ a : ℝ, 0 < a → a < ε → + ∀ x : ℝ, -1 ≤ x → x ≤ 1 → ¬ PaperPolar.RawPolar m a x := + exists_small_radius_not_rawPolar hm + +-- Degree zero must not accidentally be excluded by the fixed-degree statement. +example : PaperSecant.U1 0 0 = 1 := by norm_num [U1_zero] + +-- EX03: an actual polynomial, with the extra root-distance hypothesis at equality. +-- p=X(X-2), a=0, q={-1}; this separate theorem needs no unit-disk root hypothesis. +example {r : ℝ} (hr : 0 < r) : + (1 : ℝ) ≤ (({-1} : Multiset ℂ).map (fun v => ‖v‖ ^ r)).sum := by + have h := moment_ge_degree_of_root_distance_product + (m := 1) (p := X * (X - C 2)) (c := 1) (a := 0) + (q := {-1}) (z := {2}) (by omega) (by simp) (by simp) + (by norm_num) (by simp) (by simp) (by + norm_num [derivative_mul, derivative_sub, derivative_X, derivative_C, map_ofNat] + ring) (by norm_num) hr + simpa only [Nat.cast_one] using h + +-- AM-GM permits every positive real exponent, not only natural powers or r≥1. +example (q : Multiset ℂ) (hp : 1 ≤ ‖q.prod‖) : + (q.card : ℝ) ≤ (q.map (fun v => ‖v‖ ^ (1 / 2 : ℝ))).sum := + moment_ge_card_of_one_le_norm_prod q (by norm_num) hp + +-- EX01/02: actual complex mean/variance, and the still-conditional finite majorant. +example (q : Multiset ℂ) {μ : ℂ} {a x : ℝ} + (hm : 7 ≤ q.card) (ha : 0 < a) (ha1 : a < 1) + (hmean : q.sum = q.card * μ) (hq : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hx : μ.re = x) + (hr : PaperPolar.RawPolar q.card a x) : + PaperCentered.Gamma (q.map (fun v => v - μ)) μ < 7 * (1 - a) / 18 := + Gamma_lt_seven_eighteenths q hm ha ha1 hmean hq hx0 hx1 hx hr + +example (q : Multiset ℂ) {μ : ℂ} {a x : ℝ} + (hm : 7 ≤ q.card) (ha : 0 < a) (ha1 : a < 1) + (hmean : q.sum = q.card * μ) (hq : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hx : μ.re = x) + (hr : PaperPolar.RawPolar q.card a x) + (hfin : PaperCenteredBound.majorant_Efin (q.map (fun v => v - μ)) μ (a * μ) ≤ + (1 - a) / 2) + (hJ : ‖(q.card + 1 : ℂ) * + (∫ t in (0 : ℝ)..1, (q.map (fun v => 1 - (a : ℂ) * t * v)).prod)‖ ≤ 1) : False := + (not_lt_of_ge hJ) (norm_J_gt_one_of_majorant_half q hm ha ha1 hmean hq hx0 hx1 hx hr hfin) + +-- AS05: arbitrary positive scale, and the endpoint x=1 is not discarded. +example {ℓ x : ℝ} (hℓ : 0 < ℓ) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hG : 1 ≤ ∫ t in (0 : ℝ)..1, Real.exp (ℓ * (2 * x * t - 1))) : + 0 < (1 + ℓ) * x ^ 2 - 1 := + (limiting_exponential_model hℓ hx0 hx1 hG).2.2.2 + +example {ℓ : ℝ} (hℓ : 0 < ℓ) + (hG : 1 ≤ ∫ t in (0 : ℝ)..1, Real.exp (ℓ * (2 * (1 : ℝ) * t - 1))) : + 0 < (1 + ℓ) * (1 : ℝ) ^ 2 - 1 := + (limiting_exponential_model hℓ (by norm_num) (by norm_num) hG).2.2.2 + +-- UN: all four retained historical cutoffs, with no extra radius restriction. +example {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : PaperPolar.RawPolar m a x) : + PaperTaylor.budget (m : ℝ) a x < 1 - (m : ℝ) * a / ((m : ℝ) + 1) := + old_all_a_cutoff (by norm_num : 256 ≤ 512) hm ha ha1 hx0 hx1 hr + +example {m : ℕ} {a x : ℝ} (hm : 10000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : PaperPolar.RawPolar m a x) : + PaperTaylor.budget (m : ℝ) a x < 1 - (m : ℝ) * a / ((m : ℝ) + 1) := + old_all_a_cutoff (by norm_num : 256 ≤ 10000) hm ha ha1 hx0 hx1 hr + +example {m : ℕ} {a x : ℝ} (hm : 100000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : PaperPolar.RawPolar m a x) : + PaperTaylor.budget (m : ℝ) a x < 1 - (m : ℝ) * a / ((m : ℝ) + 1) := + old_all_a_cutoff (by norm_num : 256 ≤ 100000) hm ha ha1 hx0 hx1 hr + +example {m : ℕ} {a x : ℝ} (hm : 1000000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : PaperPolar.RawPolar m a x) : + PaperTaylor.budget (m : ℝ) a x < 1 - (m : ℝ) * a / ((m : ℝ) + 1) := + old_all_a_cutoff (by norm_num : 256 ≤ 1000000) hm ha ha1 hx0 hx1 hr + +#print axioms tendsto_U1_zero_right +#print axioms exists_small_radius_not_rawPolar +#print axioms root_distance_product_identity +#print axioms moment_ge_degree_of_root_distance_product +#print axioms Gamma_lt_seven_eighteenths +#print axioms norm_J_gt_one_of_majorant_half +#print axioms limiting_exponential_model +#print axioms old_all_a_cutoff diff --git a/tests/PaperLegacyCertificates.lean b/tests/PaperLegacyCertificates.lean new file mode 100644 index 0000000..114ea3d --- /dev/null +++ b/tests/PaperLegacyCertificates.lean @@ -0,0 +1,232 @@ +import Sendov.Analytic.PaperLegacyExact +import Sendov.Analytic.PaperLegacyHundred +import Sendov.Analytic.PaperNearMargins + +/-! +# DI08–DI10: original full-polar and direct-budget certificates + +Sources: first-origin-uniform/{certificates.json,legacy_RESULT.json}, +REPORT.md §2.1–2.2, legacy_RESULT.md §19–25. +The binary64 diagnostic's serialized decimal is retained exactly as a rational; +no approximate equality or assumption that it is a feasible root is used. + +The polar integrals retain the original exact values. The direct inequalities +use structural integral estimates, not the original Simpson implementation or +its displayed approximate gaps. In particular the legacy 3h/5 margin consumes +PaperTaylor.budget_le, not the weaker uniform h/3 theorem. +-/ +namespace Sendov.PaperLegacyCertificates +open MeasureTheory PaperLegacy +open scoped BigOperators + +noncomputable def h : ℝ := 1 / 1000000000 +noncomputable def a : ℝ := 999999999 / 1000000000 +noncomputable def rejectedX : ℝ := 499999993298327 / 500000000000000 +noncomputable def upperX : ℝ := a + 100 * h ^ 2 +noncomputable def legacyX : ℝ := a + 3 * h ^ 2 + +theorem exact_source_parameters : a = 1 - h ∧ + rejectedX = 0.999999986596654 ∧ + upperX = 9999999990000001 / 10000000000000000 ∧ + legacyX = 999999999000000003 / 1000000000000000000 := by + norm_num [a, h, rejectedX, upperX, legacyX] + +/-- Pair indexing has the original total multiplicities, not half the degree. -/ +theorem pair_cardinalities : Fintype.card (Fin 5 × Fin 2) = 10 ∧ + Fintype.card (Fin 10 × Fin 2) = 20 ∧ Fintype.card (Fin 50 × Fin 2) = 100 := by + norm_num + +lemma rejected_R : R 5 a rejectedX = rejectedValue := rejected_integral +lemma lower_R : R 5 a a = lowerValue := lower_integral +lemma upper_R : R 5 a upperX = upperValue := by + convert upper_integral using 1 <;> norm_num [a, h, upperX] +lemma legacy_R : R 5 a legacyX = legacyValue := by + convert legacy_integral using 1 <;> norm_num [a, h, legacyX] + +/-- DI08: the exact decimal rejected by the certificate fails FULL complex polar. -/ +theorem rejected_full_polar : ‖K 5 a rejectedX‖ < 1 := by + rw [norm_K_eq (by norm_num [rejectedX]) 5 a (by rw [rejected_R]; norm_num [rejectedValue]), + rejected_R] + norm_num [rejectedValue] + +theorem rejected_not_raw : ¬ PaperPolar.RawPolar 10 a rejectedX := by + rw [show 10 = 2 * 5 by rfl, raw_even, rejected_R] + norm_num [rejectedValue] + +/-- DI08: strict endpoints for the true raw threshold. -/ +theorem raw_threshold_bracket : + (∫ t in (0 : ℝ)..1, P a a t ^ ((10 : ℝ) / 2)) < 1 ∧ + 1 < ∫ t in (0 : ℝ)..1, P a upperX t ^ ((10 : ℝ) / 2) := by + norm_num only [show (10 : ℝ) / 2 = 5 by norm_num, Real.rpow_ofNat] + change R 5 a a < 1 ∧ 1 < R 5 a upperX + rw [lower_R, upper_R] + norm_num [lowerValue, upperValue] + +/-- The same bracket is a FULL complex K bracket for five unit-circle pairs. -/ +theorem full_threshold_bracket : ‖K 5 a a‖ < 1 ∧ 1 < ‖K 5 a upperX‖ := by + rw [norm_K_eq (by norm_num [a]) 5 a (by rw [lower_R]; norm_num [lowerValue]), + norm_K_eq (by norm_num [a, h, upperX]) 5 a (by rw [upper_R]; norm_num [upperValue]), + lower_R, upper_R] + norm_num [lowerValue, upperValue] + +/-- DI08 includes ALL raw-feasible x, not only the replacement witness. -/ +theorem all_feasible_D (x : ℝ) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hraw : PaperPolar.RawPolar 10 a x) : + PaperTaylor.budget 10 a x < 1 - 10 * a / 11 := by + have hg := PaperNearMargins.near_endpoint_one_fiftieth (m := 10) + (by norm_num) (by norm_num [a]) (by norm_num [a]) hx0 hx1 hraw (by norm_num [a]) + norm_num at hg + have hh : 0 < 1 - a := by norm_num [a] + linarith + +/-- DI09: the original a+3h² witness, not the later a+100h² endpoint. -/ +theorem legacy_full_polar : 1 < ‖K 5 a legacyX‖ := by + rw [norm_K_eq (by norm_num [a, h, legacyX]) 5 a + (by rw [legacy_R]; norm_num [legacyValue]), legacy_R] + norm_num [legacyValue] + +/-- DI09's stronger finite margin is for the actual T integral. -/ +theorem legacy_three_fifths : + (3 / 5 : ℝ) * h < 1 - 10 * a / 11 - PaperTaylor.budget 10 a legacyX := by + have ht := PaperTaylor.budget_le (m := 10) (a := a) (x := legacyX) + (by norm_num) (by norm_num [a]) (by norm_num [a]) + (by norm_num [legacyX, a, h]) (by norm_num [PaperTaylor.chord, legacyX, a, h]) + norm_num only [show (10 : ℝ) / 2 = 5 by norm_num, Real.rpow_ofNat] at ht + have hc : 1 / ((10 : ℝ) + 1) + PaperTaylor.beta a legacyX 1 ^ (5 : ℕ) + + PaperTaylor.defect a legacyX / (a * (10 - 2)) + + 12 * 10 * a ^ 2 * PaperTaylor.defect a legacyX ^ 2 / + (PaperTaylor.chord a legacyX ^ 4 * (10 + 1) * (10 + 3)) < + 1 - 10 * a / 11 - (3 / 5) * h := by + norm_num [PaperTaylor.beta, PaperTaylor.defect, PaperTaylor.chord, legacyX, a, h] + linarith + +/-- DI10: left chord on [0,1/2], bounded right tail; direct T, not Cbudget. -/ +theorem twenty_D : PaperTaylor.budget 20 (9 / 10) (83 / 100) < + 1 - 20 * (9 / 10) / 21 := by + have ht := budget_split_le (m := 20) (a := 9 / 10) (x := 83 / 100) + (s := 1 / 2) (c := 27 / 25) (r := 1 / 2) (n := 9) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) + (by + intro t ht + have := mul_nonneg ht.1 (sub_nonneg.mpr ht.2) + dsimp [PaperTaylor.beta] + nlinarith) + (by + intro t ht + have := mul_nonneg (sub_nonneg.mpr ht.1) (sub_nonneg.mpr ht.2) + dsimp [PaperTaylor.beta] + nlinarith) + norm_num only [show (20 : ℝ) / 2 = 10 by norm_num, Real.rpow_ofNat] at ht + apply ht.trans_lt + norm_num [PaperTaylor.beta] + +/-- DI10: a different finite split at 1/4 handles m=100 without Simpson. -/ +theorem hundred_D : PaperTaylor.budget 100 (99 / 100) (22 / 25) < + 1 - 100 * (99 / 100) / 101 := by + have ht := budget_split_le (m := 100) (a := 99 / 100) (x := 22 / 25) + (s := 1 / 4) (c := 149 / 100) (r := 2 / 3) (n := 49) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) (by norm_num) + (by norm_num) (by norm_num) (by norm_num) + (by + intro t ht + have := mul_nonneg ht.1 (sub_nonneg.mpr ht.2) + dsimp [PaperTaylor.beta] + nlinarith) + (by + intro t ht + have := mul_nonneg (sub_nonneg.mpr ht.1) (sub_nonneg.mpr ht.2) + dsimp [PaperTaylor.beta] + nlinarith) + norm_num only [show (100 : ℝ) / 2 = 50 by norm_num, Real.rpow_ofNat] at ht + apply ht.trans_lt + norm_num [PaperTaylor.beta] + +theorem twenty_full_polar : 1 < ‖K 10 (9 / 10) (83 / 100)‖ := by + rw [norm_K_eq (by norm_num) 10 (9 / 10) + (by rw [twenty_integral]; norm_num [twentyValue]), twenty_integral] + norm_num [twentyValue] + +theorem hundred_full_polar : 1 < ‖K 50 (99 / 100) (22 / 25)‖ := by + rw [norm_K_eq (by norm_num) 50 (99 / 100) + (by rw [hundred_integral]; norm_num [hundredValue]), hundred_integral] + norm_num [hundredValue] + +/-- Literal complex-integral form and unit-circle hypothesis for the legacy point. -/ +theorem legacy_complete : + (∀ j : Fin 5 × Fin 2, ‖q 5 legacyX j‖ = 1) ∧ + 1 < ‖∫ t in (0 : ℝ)..1, ∏ j : Fin 5 × Fin 2, + ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * q 5 legacyX j)‖ ∧ + (3 / 5 : ℝ) * (1 - a) < 1 - 10 * a / 11 - PaperTaylor.budget 10 a legacyX := by + refine ⟨norm_q (by norm_num [a, h, legacyX]), legacy_full_polar, ?_⟩ + rw [show 1 - a = h by norm_num [a, h]] + exact legacy_three_fifths + +theorem twenty_complete : + (∀ j : Fin 10 × Fin 2, ‖q 10 (83 / 100) j‖ = 1) ∧ + 1 < ‖K 10 (9 / 10) (83 / 100)‖ ∧ + PaperTaylor.budget 20 (9 / 10) (83 / 100) < 1 - 20 * (9 / 10) / 21 := + ⟨norm_q (by norm_num), twenty_full_polar, twenty_D⟩ + +theorem hundred_complete : + (∀ j : Fin 50 × Fin 2, ‖q 50 (22 / 25) j‖ = 1) ∧ + 1 < ‖K 50 (99 / 100) (22 / 25)‖ ∧ + PaperTaylor.budget 100 (99 / 100) (22 / 25) < 1 - 100 * (99 / 100) / 101 := + ⟨norm_q (by norm_num), hundred_full_polar, hundred_D⟩ + +#print axioms exact_source_parameters +#print axioms rejected_full_polar +#print axioms raw_threshold_bracket +#print axioms full_threshold_bracket +#print axioms all_feasible_D +#print axioms legacy_complete +#print axioms twenty_complete +#print axioms hundred_complete + +-- Check transitive proof VALUES: an imported centered theorem cannot silently +-- replace the actual T estimates, nor h/3 replace the finite legacy margin. +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + let roots := #[ + (`Sendov.PaperLegacyCertificates.legacy_three_fifths, + #[`Sendov.PaperTaylor.budget_le]), + (`Sendov.PaperLegacyCertificates.twenty_D, + #[`Sendov.PaperLegacy.budget_split_le]), + (`Sendov.PaperLegacyCertificates.hundred_D, + #[`Sendov.PaperLegacy.budget_split_le]), + (`Sendov.PaperLegacyCertificates.rejected_full_polar, + #[`Sendov.PaperLegacy.K_eq_R, `Sendov.PaperLegacy.rejected_integral]), + (`Sendov.PaperLegacyCertificates.full_threshold_bracket, + #[`Sendov.PaperLegacy.K_eq_R, `Sendov.PaperLegacy.lower_integral, + `Sendov.PaperLegacy.upper_integral]), + (`Sendov.PaperLegacyCertificates.legacy_full_polar, + #[`Sendov.PaperLegacy.K_eq_R, `Sendov.PaperLegacy.legacy_integral]), + (`Sendov.PaperLegacyCertificates.twenty_full_polar, + #[`Sendov.PaperLegacy.K_eq_R, `Sendov.PaperLegacy.twenty_integral]), + (`Sendov.PaperLegacyCertificates.hundred_full_polar, + #[`Sendov.PaperLegacy.K_eq_R, `Sendov.PaperLegacy.hundred_integral])] + for (root, required) in roots do + let mut pending := [root] + let mut visited : Std.HashSet Name := {} + while !pending.isEmpty do + let name := pending.head! + pending := pending.tail! + unless visited.contains name do + visited := visited.insert name + let some ci := env.find? name | throwError "missing declaration {name}" + if let some value := ci.value? (allowOpaque := true) then + for used in value.getUsedConstants do pending := used :: pending + for target in required do + unless visited.contains target do + throwError "legacy proof missing required dependency {root} -> {target}" + for name in visited.toList do + for banned in #[`Sendov.PaperCentered, `Sendov.PaperCenteredBound, + `Sendov.PaperUniform, `Sendov.PaperNearMargins, `Sendov.PaperNearClosure] do + if banned.isPrefixOf name then + throwError "legacy proof uses a forbidden substitute: {root} -> {name}" + logInfo m!"LEGACY_CERTIFICATE_PROOF_CLOSURE_OK {root}" + +end Sendov.PaperLegacyCertificates diff --git a/tests/PaperPolarDomainWitnesses.lean b/tests/PaperPolarDomainWitnesses.lean new file mode 100644 index 0000000..04f02e5 --- /dev/null +++ b/tests/PaperPolarDomainWitnesses.lean @@ -0,0 +1,332 @@ +import Sendov.Analytic.PaperPolar +import Mathlib.Analysis.SpecialFunctions.Integrals.Basic +import Mathlib.Algebra.Polynomial.Derivative +import Mathlib.Algebra.Polynomial.FieldDivision +import Mathlib.Analysis.Convex.Hull + +/-! +# Literal full-polar witnesses and domain countermodels (DI15–17) + +The neighborhood assertions concern every real parameter in the indicated +closed intervals, not a grid and not a raw-feasibility hypothesis. +The last example refutes a convex-hull **nonroot** reciprocal-moment variant; +it does not refute the marked-root theorem, Sendov, or the nearest-point bound. +-/ +namespace Sendov.PaperPolar.DomainWitnesses +open MeasureTheory +open scoped BigOperators + +noncomputable def K {m : ℕ} (a : ℝ) (q : Fin m → ℂ) : ℂ := + ∫ t in (0 : ℝ)..1, ∏ j : Fin m, ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * q j) + +lemma integral_affine_pow (m : ℕ) (a d : ℝ) (hd : d ≠ 0) : + (∫ t in (0 : ℝ)..1, (a + d * t) ^ m) = + ((a + d) ^ (m + 1) - a ^ (m + 1)) / (((m : ℝ) + 1) * d) := by + rw [intervalIntegral.integral_comp_add_mul (fun y : ℝ => y ^ m) hd, integral_pow] + simp only [mul_zero, add_zero, mul_one, smul_eq_mul] + rw [mul_comm ((m : ℝ) + 1), ← div_div] + ring + +lemma K_one (m : ℕ) (a : ℝ) : + K a (fun _ : Fin m => 1) = + ((∫ t in (0 : ℝ)..1, (a + (1 - a ^ 2) * t) ^ m : ℝ) : ℂ) := by + unfold K + simp only [mul_one, Finset.prod_const, Finset.card_univ, Fintype.card_fin] + simp_rw [← Complex.ofReal_add, ← Complex.ofReal_pow] + rw [intervalIntegral.integral_ofReal] + +lemma norm_K_one_lower (m : ℕ) {a l d : ℝ} + (hl : 0 ≤ l) (hla : l ≤ a) (hd : 0 ≤ d) (hda : d ≤ 1 - a ^ 2) : + (∫ t in (0 : ℝ)..1, (l + d * t) ^ m) ≤ ‖K a (fun _ : Fin m => 1)‖ := by + rw [K_one, Complex.norm_real, Real.norm_eq_abs] + apply le_trans _ (le_abs_self _) + refine intervalIntegral.integral_mono_on (by norm_num) + ((by fun_prop : Continuous fun t : ℝ => (l + d * t) ^ m).intervalIntegrable _ _) + ((by fun_prop : Continuous fun t : ℝ => (a + (1 - a ^ 2) * t) ^ m).intervalIntegrable _ _) ?_ + intro t ht + exact pow_le_pow_left₀ (add_nonneg hl (mul_nonneg hd ht.1)) + (add_le_add hla (mul_le_mul_of_nonneg_right hda ht.1)) m + +/-- DI15: actual complex full polar throughout the degree-seven neighborhood. -/ +theorem neighborhood_7 {a : ℝ} + (ha : a ∈ Set.Icc (7999 / 10000) (8001 / 10000)) : + (∀ _j : Fin 7, ‖(1 : ℂ)‖ = 1) ∧ 1 ≤ ‖K a (fun _ : Fin 7 => 1)‖ := by + constructor + · intro j; exact norm_one + · have hd : (3598 : ℝ) / 10000 ≤ 1 - a ^ 2 := by + have := ha.1; have := ha.2; nlinarith + have h := norm_K_one_lower 7 (by norm_num : (0 : ℝ) ≤ 7999 / 10000) + ha.1 (by norm_num : (0 : ℝ) ≤ 3598 / 10000) hd + rw [integral_affine_pow 7 _ _ (by norm_num)] at h + exact le_trans (by norm_num) h + +noncomputable def x : ℝ := 93 / 100 +noncomputable def y : ℝ := Real.sqrt (1 - x ^ 2) +noncomputable def plus : ℂ := ⟨x, y⟩ +noncomputable def minus : ℂ := ⟨x, -y⟩ +/-- Exactly five conjugate pairs. -/ +noncomputable def q10 (j : Fin 10) : ℂ := if j.val % 2 = 0 then plus else minus + +lemma y_sq : y ^ 2 = 1 - x ^ 2 := Real.sq_sqrt (by norm_num [x]) + +lemma norm_plus : ‖plus‖ = 1 := by + have h : ‖plus‖ ^ 2 = 1 := by + rw [Complex.sq_norm, Complex.normSq_apply] + change x * x + y * y = 1 + nlinarith [y_sq] + nlinarith [norm_nonneg plus] + +lemma norm_minus : ‖minus‖ = 1 := by + have h : ‖minus‖ ^ 2 = 1 := by + rw [Complex.sq_norm, Complex.normSq_apply] + change x * x + (-y) * (-y) = 1 + nlinarith [y_sq] + nlinarith [norm_nonneg minus] + +theorem norm_q10 (j : Fin 10) : ‖q10 j‖ = 1 := by + unfold q10 + split <;> first | exact norm_plus | exact norm_minus + +theorem mean_q10 : (∑ j : Fin 10, q10 j) / 10 = (x : ℂ) := by + norm_num [q10, Fin.sum_univ_succ] + apply Complex.ext <;> simp [plus, minus] + ring + +lemma pair_product (s r : ℝ) : + ((s : ℂ) + r * plus) * (s + r * minus) = + ((s ^ 2 + 2 * s * r * x + r ^ 2 : ℝ) : ℂ) := by + apply Complex.ext <;> + simp only [plus, minus, pow_two, Complex.mul_re, Complex.mul_im, Complex.add_re, + Complex.add_im, Complex.ofReal_re, Complex.ofReal_im, Complex.ofReal_add, + Complex.ofReal_mul, Complex.ofReal_ofNat, Complex.re_ofNat, Complex.im_ofNat, + zero_mul, mul_zero, sub_zero, add_zero, zero_add] + · have h := congrArg (fun z : ℝ => r ^ 2 * z) y_sq + nlinarith only [h] + · ring + +lemma product_q10 (a t : ℝ) : + (∏ j : Fin 10, ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * q10 j)) = + (((a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + + (1 - a ^ 2) ^ 2 * t ^ 2) ^ 5 : ℝ) : ℂ) := by + have hp := pair_product a ((1 - a ^ 2) * t) + norm_num [q10, Fin.prod_univ_succ] + calc + _ = (((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * plus) * + ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * minus)) ^ 5 := by push_cast; ring + _ = _ := by rw [hp]; push_cast; ring + +noncomputable def fifthCoeffs (A B C : ℝ) : Fin 11 → ℝ := + ![A^5, 5*A^4*B, 10*A^3*B^2+5*A^4*C, + 10*A^2*B^3+20*A^3*B*C, 5*A*B^4+30*A^2*B^2*C+10*A^3*C^2, + B^5+20*A*B^3*C+30*A^2*B*C^2, + 5*B^4*C+30*A*B^2*C^2+10*A^2*C^3, + 10*B^3*C^2+20*A*B*C^3, 10*B^2*C^3+5*A*C^4, 5*B*C^4, C^5] + +lemma fifth_expansion (A B C t : ℝ) : + (A + B * t + C * t ^ 2) ^ 5 = + ∑ k : Fin 11, fifthCoeffs A B C k * t ^ k.val := by + simp [fifthCoeffs, Fin.sum_univ_succ] + ring + +lemma integral_fifth (A B C : ℝ) : + (∫ t in (0 : ℝ)..1, (A + B * t + C * t ^ 2) ^ 5) = + ∑ k : Fin 11, fifthCoeffs A B C k / (k.val + 1) := by + simp_rw [fifth_expansion] + rw [intervalIntegral.integral_finsetSum] + · apply Finset.sum_congr rfl + intro k hk + rw [intervalIntegral.integral_const_mul, integral_pow] + simp + ring + · intro k hk + exact ((continuous_const.mul (continuous_pow k.val))).intervalIntegrable _ _ + +lemma K_q10 (a : ℝ) : K a q10 = + ((∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ 5 : ℝ) : ℂ) := by + unfold K + simp_rw [product_q10] + rw [intervalIntegral.integral_ofReal] + +/-- DI15: no raw-polar hypothesis is used for the five-pair neighborhood. -/ +theorem neighborhood_10 {a : ℝ} + (ha : a ∈ Set.Icc (899999 / 1000000) (900001 / 1000000)) : + (∀ j, ‖q10 j‖ = 1) ∧ 1 ≤ ‖K a q10‖ := by + refine ⟨norm_q10, ?_⟩ + let l : ℝ := 89999 / 100000 + let d : ℝ := 18999 / 100000 + have hl : 0 ≤ l := by norm_num [l] + have hd : 0 ≤ d := by norm_num [d] + have hla : l ≤ a := by have := ha.1; dsimp [l]; linarith + have hda : d ≤ 1 - a ^ 2 := by + have := ha.1; have := ha.2; dsimp [d]; nlinarith + have ha0 := hl.trans hla + have hdelta := hd.trans hda + have hA := pow_le_pow_left₀ hl hla 2 + have hB : 2 * l * d * x ≤ 2 * a * (1 - a ^ 2) * x := by + exact mul_le_mul_of_nonneg_right + (mul_le_mul (mul_le_mul_of_nonneg_left hla (by norm_num)) hda hd (by positivity)) + (by norm_num [x]) + have hC := pow_le_pow_left₀ hd hda 2 + have hi : (∫ t in (0 : ℝ)..1, (l ^ 2 + (2*l*d*x) * t + d ^ 2 * t ^ 2) ^ 5) ≤ + ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2*a*(1-a^2)*x*t + (1-a^2)^2*t^2)^5 := by + refine intervalIntegral.integral_mono_on (by norm_num) + ((by fun_prop : Continuous fun t : ℝ => (l^2+(2*l*d*x)*t+d^2*t^2)^5).intervalIntegrable _ _) + ((by fun_prop : Continuous fun t : ℝ => + (a^2+2*a*(1-a^2)*x*t+(1-a^2)^2*t^2)^5).intervalIntegrable _ _) ?_ + intro t ht + apply pow_le_pow_left₀ + · have hx : 0 ≤ x := by norm_num [x] + have ht0 := ht.1 + positivity + · exact add_le_add (add_le_add hA (mul_le_mul_of_nonneg_right hB ht.1)) + (mul_le_mul_of_nonneg_right hC (sq_nonneg t)) + have hlo : 1 ≤ ∫ t in (0 : ℝ)..1, (l ^ 2 + (2*l*d*x) * t + d ^ 2 * t ^ 2) ^ 5 := by + rw [integral_fifth] + norm_num [fifthCoeffs, Fin.sum_univ_succ, l, d, x] + rw [K_q10, Complex.norm_real, Real.norm_eq_abs] + exact (hlo.trans hi).trans (le_abs_self _) + +/-- DI16: the literal all-ones complex integral, evaluated exactly. -/ +theorem K_64_exact : K (1/2) (fun _ : Fin 64 => 1) = + ((((5/4 : ℝ)^65 - (1/2 : ℝ)^65) / (65 * (3/4 : ℝ)) : ℝ) : ℂ) := by + rw [K_one, integral_affine_pow 64 _ _ (by norm_num)] + norm_num + +theorem domain_64 : alpha 64 (1/2) = 24 ∧ 17 < alpha 64 (1/2) ∧ + (∀ _j : Fin 64, ‖(1 : ℂ)‖ = 1) ∧ 1 < ‖K (1/2) (fun _ : Fin 64 => 1)‖ := by + refine ⟨by norm_num [alpha], by norm_num [alpha], fun _ => norm_one, ?_⟩ + rw [K_64_exact, Complex.norm_real, Real.norm_eq_abs] + norm_num + +/-- Full polar and the unit-disc pointwise bound alone do not imply alpha ≤ 17. -/ +theorem not_polar_implies_alpha17 : + ¬ (∀ (m : ℕ) (a : ℝ) (q : Fin m → ℂ), 7 ≤ m → 0 < a → a < 1 → + (∀ j, ‖q j‖ ≤ 1) → 1 ≤ ‖K a q‖ → alpha m a ≤ 17) := by + intro h + have hh := h 64 (1/2) (fun _ => 1) (by norm_num) (by norm_num) (by norm_num) + (fun j => (domain_64.2.2.1 j).le) domain_64.2.2.2.le + exact (not_le_of_gt domain_64.2.1) hh + +namespace Nonroot +open Polynomial + +/-- A genuine degree-ten complex polynomial with two collinear unit roots. -/ +noncomputable def p : ℂ[X] := (X - C 1)^9 * (X + C 1) +noncomputable def marked : ℂ := ((-1/4 : ℝ) : ℂ) + +lemma derivative_eq : p.derivative = (X - C 1)^8 * (C 10 * X + C 8) := by + simp [p, derivative_mul, derivative_pow, map_ofNat] + ring + +lemma linear_ne_zero : (C (10 : ℂ) * X + C 8 : ℂ[X]) ≠ 0 := by + intro h + have hh := congrArg (Polynomial.eval (0 : ℂ)) h + norm_num at hh + +/-- The complete critical multiset, including all eight repeated critical points. -/ +theorem critical_roots : p.derivative.roots = + 8 • ({1} : Multiset ℂ) + {(-4/5 : ℂ)} := by + rw [derivative_eq, roots_mul (mul_ne_zero (pow_ne_zero 8 (X_sub_C_ne_zero 1)) linear_ne_zero), + roots_pow, roots_X_sub_C, roots_C_mul_X_add_C _ (by norm_num)] + norm_num + +theorem critical_multiplicities : p.derivative.rootMultiplicity 1 = 8 ∧ + p.derivative.rootMultiplicity (-4/5) = 1 ∧ p.derivative.roots.card = 9 := by + rw [← count_roots, ← count_roots, critical_roots] + norm_num + +theorem root_multiset : p.roots = 9 • ({1} : Multiset ℂ) + {-1} := by + have hn : (X + C (1 : ℂ) : ℂ[X]) ≠ 0 := by + simpa only [C_neg, sub_neg_eq_add] using X_sub_C_ne_zero (-1 : ℂ) + rw [p, roots_mul (mul_ne_zero (pow_ne_zero 9 (X_sub_C_ne_zero 1)) hn), + roots_pow, roots_X_sub_C, roots_X_add_C] + +lemma mem_roots_iff (z : ℂ) : z ∈ p.roots ↔ z = 1 ∨ z = -1 := by + rw [root_multiset] + simp + +/-- The marked point is in the actual root convex hull, but is not a root. -/ +theorem convex_hull_nonroot : + marked ∈ convexHull ℝ {z : ℂ | z ∈ p.roots} ∧ ¬ p.IsRoot marked := by + constructor + · have hs : {z : ℂ | z ∈ p.roots} = {1, -1} := by + ext z + simp only [Set.mem_ofPred_eq, Set.mem_insert_iff, Set.mem_singleton_iff, mem_roots_iff] + rw [hs, convexHull_pair] + refine ⟨3/8, 5/8, by norm_num, by norm_num, by norm_num, ?_⟩ + apply Complex.ext <;> norm_num [marked, Complex.smul_re, Complex.smul_im] + · norm_num [Polynomial.IsRoot, p, marked] + +lemma distance_one : ‖marked - (1 : ℂ)‖ = 5/4 := by + have he : marked - (1 : ℂ) = ((-5/4 : ℝ) : ℂ) := by + dsimp [marked]; push_cast; ring + rw [he, Complex.norm_real, Real.norm_eq_abs] + norm_num + +lemma distance_other : ‖marked - (-4/5 : ℂ)‖ = 11/20 := by + have he : marked - (-4/5 : ℂ) = ((11/20 : ℝ) : ℂ) := by + dsimp [marked]; push_cast; ring + rw [he, Complex.norm_real, Real.norm_eq_abs] + norm_num + +/-- DI17: the reciprocal-square sum is over the actual derivative roots. -/ +theorem reciprocal_square_exact : + (p.derivative.roots.map (fun w => 1 / ‖marked - w‖ ^ 2)).sum = 25488/3025 := by + rw [critical_roots] + simp only [Multiset.map_add, Multiset.map_nsmul, Multiset.map_singleton, + Multiset.sum_add, Multiset.sum_nsmul, Multiset.sum_singleton, distance_one, distance_other] + norm_num + +theorem reciprocal_square_lt_nine : + (p.derivative.roots.map (fun w => 1 / ‖marked - w‖ ^ 2)).sum < 9 := by + rw [reciprocal_square_exact] + norm_num + +/-- Exact minimum, expressed by a lower bound and an attained value. -/ +theorem nearest_critical_distance : + (∀ w ∈ p.derivative.roots, (11 : ℝ)/20 ≤ ‖marked - w‖) ∧ + (∃ w ∈ p.derivative.roots, ‖marked - w‖ = 11/20) ∧ (11 : ℝ)/20 < 1 := by + constructor + · intro w hw + rw [critical_roots] at hw + have hh : w = 1 ∨ w = -4/5 := by simpa using hw + rcases hh with rfl | rfl + · rw [distance_one]; norm_num + · exact distance_other.ge + · refine ⟨⟨-4/5, ?_, distance_other⟩, by norm_num⟩ + rw [critical_roots] + simp + +/-- All actual roots lie on the unit circle and in the real line. -/ +theorem root_geometry : ∀ z ∈ p.roots, ‖z‖ = 1 ∧ z.im = 0 := by + intro z hz + rcases (mem_roots_iff z).mp hz with rfl | rfl <;> simp + +/-- Only the NONroot convex-hull variant is refuted, not the marked-root theorem. -/ +theorem not_convex_hull_nonroot_moment : + ¬ (∀ (f : ℂ[X]) (a : ℂ), (∀ z ∈ f.roots, ‖z‖ = 1 ∧ z.im = 0) → + a ∈ convexHull ℝ {z : ℂ | z ∈ f.roots} → ¬ f.IsRoot a → + (f.derivative.roots.card : ℝ) ≤ + (f.derivative.roots.map (fun w => 1 / ‖a - w‖ ^ 2)).sum) := by + intro h + have hh := h p marked root_geometry convex_hull_nonroot.1 convex_hull_nonroot.2 + rw [critical_multiplicities.2.2] at hh + norm_num only [Nat.cast_ofNat] at hh + exact (not_le_of_gt reciprocal_square_lt_nine) hh + +#print axioms derivative_eq +#print axioms critical_roots +#print axioms critical_multiplicities +#print axioms convex_hull_nonroot +#print axioms reciprocal_square_exact +#print axioms nearest_critical_distance +#print axioms not_convex_hull_nonroot_moment +end Nonroot + +#print axioms neighborhood_7 +#print axioms neighborhood_10 +#print axioms domain_64 +#print axioms not_polar_implies_alpha17 +end Sendov.PaperPolar.DomainWitnesses diff --git a/tests/PaperRateDetailsTests.lean b/tests/PaperRateDetailsTests.lean new file mode 100644 index 0000000..31c43e7 --- /dev/null +++ b/tests/PaperRateDetailsTests.lean @@ -0,0 +1,165 @@ +import Sendov.Analytic.PaperRateDetails + +/-! Exact-contract, boundary, nonvacuity, and proof-value regressions for PO06, +HI04 and the missing first-ray component of RA04. -/ +namespace Sendov.PaperRateDetails.Tests +open MeasureTheory PaperPolar + +-- PO06: both the integral input and the delta-sensitive output are expanded. +example {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : 1 ≤ ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2)) + (hlarge : 2 ≤ (((m : ℝ) + 2) / 2) * (1 - a ^ 2)) : + (1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) ≤ + ((((m : ℝ) + 2) / 2) * (1 - a ^ 2)) ^ + (-(m : ℝ) / (((m : ℝ) + 2) * (1 - a ^ 2))) := + endpoint_delta_rate hm ha ha1 hx0 hx1 hr hlarge + +-- The split is closed at N*delta=2, including the minimal odd degree. +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 7 a x) (heq : (9 : ℝ) / 2 * (1 - a ^ 2) = 2) : + b a x ^ ((7 : ℝ) / 2) ≤ + ((9 : ℝ) / 2 * (1 - a ^ 2)) ^ (-(7 : ℝ) / (9 * (1 - a ^ 2))) := by + simpa only [Nat.cast_ofNat, show (7 : ℝ) + 2 = 9 by norm_num] using + endpoint_delta_rate (by norm_num) ha ha1 hx0 hx1 hr (by norm_num; linarith) + +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 8 a x) (hlarge : 2 ≤ 5 * (1 - a ^ 2)) : + b a x ^ (4 : ℝ) ≤ + (5 * (1 - a ^ 2)) ^ (-(8 : ℝ) / (10 * (1 - a ^ 2))) := by + simpa only [Nat.cast_ofNat, show (8 : ℝ) + 2 = 10 by norm_num, + show (10 : ℝ) / 2 = 5 by norm_num, show (8 : ℝ) / 2 = 4 by norm_num] using + endpoint_delta_rate (by norm_num) ha ha1 hx0 hx1 hr (by norm_num; exact hlarge) + +-- HI04: an upper ratio for the actual integral T, not an abstract scalar or D. +example {m : ℕ} {a x : ℝ} (hm : 100000 ≤ m) + (ha : 0 < a) (ha2 : a ≤ 1 / 2) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : 1 ≤ ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2)) : + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + m * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) / + (1 - a) < 83567 / 100000 := by + simpa [PaperTaylor.budget, PaperTaylor.beta] using + small_a_ratio_100000 hm ha ha2 hx0 hx1 hr + +example {m : ℕ} {a x : ℝ} (hm : 10000 ≤ m) + (ha : 0 < a) (ha2 : a ≤ 1 / 2) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : 1 ≤ ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2)) (hbulk : (m : ℝ) * a ^ 2 * (1 - a) < 116) : + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + m * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) / + (1 - a) < 106 / 125 := by + simpa [PaperTaylor.budget, PaperTaylor.beta] using + small_a_ratio_10000 hm ha ha2 hx0 hx1 hr hbulk + +-- Exact degree cutoffs, closed a=1/2, and the small-radius branch seam. +example {x : ℝ} (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar 100000 (1 / 2) x) : + PaperTaylor.budget 100000 (1 / 2) x / (1 - 1 / 2) < 83567 / 100000 := + small_a_ratio_100000 (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hr + +example {a x : ℝ} (ha : 0 < a) (ha2 : a ≤ 1 / 2) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 10000 a x) (hbulk : 10000 * a ^ 2 * (1 - a) < 116) : + PaperTaylor.budget 10000 a x / (1 - a) < 106 / 125 := + small_a_ratio_10000 (by norm_num) ha ha2 hx0 hx1 hr hbulk + +example {x : ℝ} (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar 100001 (1 / 5) x) : + PaperTaylor.budget 100001 (1 / 5) x / (1 - 1 / 5) < 83567 / 100000 := + small_a_ratio_100000 (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hr + +-- RA04: expanded raw integral and B, on precisely the previously missing strip. +example {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : 1 ≤ ∫ t in (0 : ℝ)..1, + (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^ + ((m : ℝ) / 2)) + (hl0 : 1 / 5 ≤ (m : ℝ) * (1 - a)) (hl1 : (m : ℝ) * (1 - a) < 2 / 5) : + 1 + 18 / (m : ℝ) < + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1)) := + scaled_budget_lower_one hm ha ha1 hx0 hx1 hr hl0 (by unfold lambda; linarith) + +example {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hl0 : 1 / 5 ≤ lambda m a) (hl1 : lambda m a ≤ 1) : + (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1)) := + scaled_budget_paper_lower_one hm ha ha1 hx0 hx1 hr hl0 hl1 + +-- Both first-ray endpoints and the stitching point are retained at m=256. +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 256 a x) (hl : lambda 256 a = 1 / 5) : + 1 + 18 / (256 : ℝ) < 256 * x ^ 2 * PaperRayGeometry.B 256 a := + scaled_budget_lower_one (by norm_num) ha ha1 hx0 hx1 hr (by linarith) (by linarith) + +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 256 a x) (hl : lambda 256 a = 2 / 5) : + 1 + 18 / (256 : ℝ) < 256 * x ^ 2 * PaperRayGeometry.B 256 a := + scaled_budget_lower_one (by norm_num) ha ha1 hx0 hx1 hr (by linarith) (by linarith) + +example {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 256 a x) (hl : lambda 256 a = 1) : + 1 + 18 / (256 : ℝ) < 256 * x ^ 2 * PaperRayGeometry.B 256 a := + scaled_budget_lower_one (by norm_num) ha ha1 hx0 hx1 hr (by linarith) (by linarith) + +-- Genuine nonvacuity at the least odd degree and the closed x=1 endpoint. +theorem raw_feasible : RawPolar 7 (3 / 5) 1 := by + rw [rawPolar_iff] + change 1 ≤ PaperSecant.R 7 (3 / 5) 1 + rw [PaperSecant.R_one (by norm_num) (by norm_num)] + norm_num [PaperSecant.U1] + +example : b (3 / 5) 1 ^ ((7 : ℝ) / 2) ≤ + ((9 : ℝ) / 2 * (1 - (3 / 5) ^ 2)) ^ (-(7 : ℝ) / (9 * (1 - (3 / 5) ^ 2))) := by + simpa only [Nat.cast_ofNat, show (7 : ℝ) + 2 = 9 by norm_num] using + endpoint_delta_rate (by norm_num) (by norm_num) (by norm_num) + (by norm_num) (by norm_num) raw_feasible (by norm_num) + +#print axioms endpoint_delta_rate +#print axioms small_a_ratio_100000 +#print axioms small_a_ratio_10000 +#print axioms scaled_budget_paper_lower_one +#print axioms scaled_budget_lower_one +#print axioms raw_feasible + +-- Audit proof values, not just signatures. Forbid replacing rates with D. +open Lean Elab Command in +run_cmd do + let env := (← getEnv).setExporting false + let roots := #[ + (`Sendov.PaperRateDetails.endpoint_delta_rate, + #[`Sendov.PaperGlobalPolar.log_mul_delta_le, `Sendov.PaperGlobalPolar.integral_chord]), + (`Sendov.PaperRateDetails.small_a_ratio_100000, + #[`Sendov.PaperHistoricalBounds.budget_lt_three_fifths, + `Sendov.PaperHistoricalBounds.budget_lt_bulk116]), + (`Sendov.PaperRateDetails.small_a_ratio_10000, + #[`Sendov.PaperHistoricalBounds.budget_lt_three_fifths]), + (`Sendov.PaperRateDetails.scaled_budget_lower_one, + #[`Sendov.PaperRateDetails.product_lower_low_ray, + `Sendov.PaperRayGeometry.product_lower_one, + `Sendov.PaperPolar.b_le_alpha, `Sendov.PaperRay.ray_one])] + for (root, required) in roots do + let mut pending := [root] + let mut visited : Std.HashSet Name := {} + while !pending.isEmpty do + let name := pending.head! + pending := pending.tail! + unless visited.contains name do + visited := visited.insert name + let some ci := env.find? name | throwError "missing declaration {name}" + if let some value := ci.value? (allowOpaque := true) then + for used in value.getUsedConstants do pending := used :: pending + for target in required do + unless visited.contains target do + throwError "rate proof missing required dependency {root} -> {target}" + if visited.contains `sorryAx then throwError "unexpected proof hole" + for name in visited.toList do + if (`Sendov.PaperUniform).isPrefixOf name || (`Sendov.PaperNearClosure).isPrefixOf name then + throwError "quantitative rate incorrectly depends on D closure: {name}" + logInfo m!"PAPER_RATE_PROOF_CLOSURE_OK {root}" + +end Sendov.PaperRateDetails.Tests diff --git a/tests/PaperWideRaysTests.lean b/tests/PaperWideRaysTests.lean new file mode 100644 index 0000000..b538861 --- /dev/null +++ b/tests/PaperWideRaysTests.lean @@ -0,0 +1,93 @@ +import Sendov.Analytic.PaperWideRays + +/-! Exact historical contracts and cutoff/seam regressions on the actual T. -/ +namespace Sendov.PaperWideRaysTests + +open PaperPolar PaperWideRays + +-- Full contracts: no endpoint suppression, x lower bound, or desired T bound +-- is supplied as an assumption. Lambda is the actual m*(1-a). +example {m : ℕ} {a x : ℝ} (hm : 100000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hl0 : 1 / 50 ≤ (m : ℝ) * (1 - a)) + (hl1 : (m : ℝ) * (1 - a) ≤ 400) : + (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < (5011 : ℝ) / 5000 := + HI01 hm ha ha1 hx0 hx1 hr hl0 hl1 + +example {m : ℕ} {a x : ℝ} (hm : 10000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hl0 : 1 / 10 ≤ (m : ℝ) * (1 - a)) + (hl1 : (m : ℝ) * (1 - a) ≤ 400) : + (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 1 + 46 / (m : ℝ) := + HI02 hm ha ha1 hx0 hx1 hr hl0 hl1 + +example {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hl0 : 5 ≤ (m : ℝ) * (1 - a)) + (hl1 : (m : ℝ) * (1 - a) ≤ 64) : + (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 1 + 53 / (m : ℝ) + 1 / 32 := + HI03 hm ha ha1 hx0 hx1 hr hl0 hl1 + +-- The HI01 lower seam lies below HI02's historical lower seam. The helper +-- really covers it; it does not silently assume lambda >= 1/10. +example {x : ℝ} (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 100000 (1 - (1 / 50) / 100000) x) : + (100000 : ℝ) * x ^ 2 * PaperTaylor.budget 100000 (1 - (1 / 50) / 100000) x < + 5011 / 5000 := by + apply HI01 (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hr <;> norm_num [lambda] + +example {x : ℝ} (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 100000 (1 - 400 / 100000) x) : + (100000 : ℝ) * x ^ 2 * PaperTaylor.budget 100000 (1 - 400 / 100000) x < + 5011 / 5000 := by + apply HI01 (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hr <;> norm_num [lambda] + +example {x : ℝ} (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 10000 (1 - (1 / 10) / 10000) x) : + (10000 : ℝ) * x ^ 2 * PaperTaylor.budget 10000 (1 - (1 / 10) / 10000) x < + 1 + 46 / 10000 := by + apply HI02 (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hr <;> norm_num [lambda] + +example {x : ℝ} (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 10000 (24 / 25) x) : + (10000 : ℝ) * x ^ 2 * PaperTaylor.budget 10000 (24 / 25) x < 1 + 46 / 10000 := by + apply HI02 (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hr <;> norm_num [lambda] + +example {x : ℝ} (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 512 (1 - 5 / 512) x) : + (512 : ℝ) * x ^ 2 * PaperTaylor.budget 512 (1 - 5 / 512) x < + 1 + 53 / 512 + 1 / 32 := by + apply HI03 (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hr <;> norm_num [lambda] + +example {x : ℝ} (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 512 (7 / 8) x) : + (512 : ℝ) * x ^ 2 * PaperTaylor.budget 512 (7 / 8) x < 1 + 53 / 512 + 1 / 32 := by + apply HI03 (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hr <;> norm_num [lambda] + +-- Odd degree: the proof keeps real powers and never relies on even m. +example {x : ℝ} (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar 513 (1 - 64 / 513) x) : + (513 : ℝ) * x ^ 2 * PaperTaylor.budget 513 (1 - 64 / 513) x < + 1 + 53 / 513 + 1 / 32 := by + apply HI03 (by norm_num) (by norm_num) (by norm_num) hx0 hx1 hr <;> norm_num [lambda] + +example {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hl0 : 1 / 10 ≤ lambda m a) (hl1 : lambda m a ≤ 1) : + (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 1 + 18 / (m : ℝ) := + HI03_small_one hm ha ha1 hx0 hx1 hr hl0 hl1 + +example {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hl0 : 1 ≤ lambda m a) (hl1 : lambda m a ≤ 5) : + (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 1 + 34 / (m : ℝ) := + HI03_small_five hm ha ha1 hx0 hx1 hr hl0 hl1 + +#print axioms Sendov.PaperWideRays.HI01 +#print axioms Sendov.PaperWideRays.HI02 +#print axioms Sendov.PaperWideRays.HI03 +#print axioms Sendov.PaperWideRays.HI03_small_one +#print axioms Sendov.PaperWideRays.HI03_small_five +#print axioms Sendov.PaperWideRays.tail_certificate + +end Sendov.PaperWideRaysTests diff --git a/tests/conjugate-data.json b/tests/conjugate-data.json new file mode 100644 index 0000000..52d1d79 --- /dev/null +++ b/tests/conjugate-data.json @@ -0,0 +1,47 @@ +[ + { + "id": "DI03", + "m": 6, + "a": "9/10", + "x": "49/50", + "terms": 4, + "majorant_upper": "65685551353840242581/9378906250000000000000", + "polar": "21948665224007/21875000000000" + }, + { + "id": "DI04", + "m": 8, + "a": "99/100", + "x": "497/500", + "terms": 6, + "majorant_upper": "3039368554741189238931856523020328452468902287/3377076171875000000000000000000000000000000000000", + "polar": "9844160902221705118371486810769458499/9843750000000000000000000000000000000" + }, + { + "id": "DI05", + "m": 20, + "a": "9/10", + "x": "83/100", + "terms": 18, + "majorant_upper": "18193849001759092019915918114883051985586361981871865429310238841393/130891000000000000000000000000000000000000000000000000000000000000000", + "polar": "1182519467309602248471006652606768554894193590679433/1173046875000000000000000000000000000000000000000000" + }, + { + "id": "DI06", + "m": 100, + "a": "9/10", + "x": "61/100", + "terms": 98, + "majorant_upper": "3707232300000000000000000000000017209226607827759920758184455376999472060706591111381825506236924760154817428344182251680508385459230308732699163316256883548729742567469252845385199482532095316721648062124329899465649984476615592765479246003713286523718443950028548139401988192880523691456128501348166981863/11163000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "polar": "4874819668353986344372759158996379788203162905021053969220512027464011516697234322492412798178083531872222373173129125064055696582260367287677751296177367615012912487174742599035378515486086963925803530899510738528131130982750545622228064732114888343133733918883/4523697211450944933646848582498023461084812879562377929687500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" + }, + { + "id": "DI07", + "m": 100, + "a": "99/100", + "x": "22/25", + "terms": 98, + "majorant_upper": "262176886517739870942090207942480156842100475366362790767934308983413488398138477673575298296268853202702212461434583523499075906100383538917612263309363261278752340264877110778448939341561773685546932854854511916132169095841691259150049487202678093172428587119260433687458984862205256792202105355581617935326718473/24502512758667277658139271770325248303000044426762877641863019531160139102629764268556463563701333106803492501574464488628849373764282378223638008365833863831058312649485285850819993314075873058754950761795043945312500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "polar": "14313215927707901402812696032528538119334551902447926006635832271609803863644007817037599529155215149965230748737891573673073813461328796095825584593099403616561318103317457698514761610758806542012939294274038354076074324868302713135069383609883803251414851327227994737708450444463078064775328139839194381937553501581252448598855714828779410582917232004133053591418576446613090226774400343085737079866679727436329886774681351007/14295771323094814150976518270000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" + } +] diff --git a/tests/data/di02-witnesses.json b/tests/data/di02-witnesses.json new file mode 100644 index 0000000..8b9d94e --- /dev/null +++ b/tests/data/di02-witnesses.json @@ -0,0 +1,694 @@ +{ + "degrees": 98, + "denominator": 1000000000000, + "generic_sum": "453022083/1000000000000", + "actual_sum": "1330319/125000000000", + "rows": [ + { + "k": 3, + "normalized_C_square": "30000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/178083627819955160612629799148557734120164268092935270499008375389363217186408601278918172604369072483176204378218462916124827460193793395131480761456410763968844699087982390968633172802266198291676256073", + "envelope": "410439009/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 4, + "normalized_C_square": "99568244445778267314305024860481987849444034699538674129617865836635181344566135058943117170011417871311465432881959713995456695556640625/68400140691441518113627348559609710665311121013804204132329697231091426756207479875703868061418743637137450630197820696183627256763582085769199616", + "envelope": "7630657/200000000000", + "actual": "27/2561867", + "actual_envelope": "10539189/1000000000000" + }, + { + "k": 5, + "normalized_C_square": "360983315455616888160584623718400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/23404183232632970599791874440183946256342404034832687175699449913463247532125934604232006488428199673875052406150089387777172515941517594739", + "envelope": "157093/40000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 6, + "normalized_C_square": "39936083326813722648968758617441052877206075777394289616495370864868164062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/205401365735095585616810470922181687099906248415053014026837822936643752549471227905353702418735842028301679487388622419423855556145375846890609176930066696442950259200862207566401", + "envelope": "220471/500000000000", + "actual": "243/2385098177", + "actual_envelope": "101883/1000000000000" + }, + { + "k": 7, + "normalized_C_square": "156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/54795618813368148990118942603349835164712664507615481743596243207193528392668336457996557552373676374616346943770439804633954099804594328140815592815567744963730486949036728162692484926985810613176337010873979", + "envelope": "267/5000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 8, + "normalized_C_square": "52914647396508848159781576716879408104696387244757532518118248238087237408937571381859789131948037924947636501116221552365459501743316650390625/1106218013387825586100396313484492226044044963173438144935336511069091289766983374601625572967107197517855221599245756722673225390473811478032298960458521841664", + "envelope": "6917/1000000000000", + "actual": "729/517566304409", + "actual_envelope": "1409/1000000000000" + }, + { + "k": 9, + "normalized_C_square": "625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/690141777122602033414605985858881629578848854340286216226192033448597178352882699950505433152867407501182912964383036019029349371821128813012994064845264653544046827038769095418264447826883369154211246847495363219", + "envelope": "119/125000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 10, + "normalized_C_square": "6250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/326475981680969007199809535520436465058830175856658495851006601859875842915909093015146698444305989505542983697352121", + "envelope": "139/1000000000000", + "actual": "59049/2307828151359731", + "actual_envelope": "13/500000000000" + }, + { + "k": 11, + "normalized_C_square": "242137805625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/540619017762196021237136748692079123264822431557681316434179977301110228689709167017500055631044648130621038910017923419153291368425221201704296840716404795516126908007796631318839726118028236024432537720876922044331286127851", + "envelope": "11/500000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 12, + "normalized_C_square": "5879405266278760906642397412986600900521820804973059168679805359787470823215285709095532125772004213883070722346246839151717722415924072265625/510685091151845822078642297510003066493725122991137111975680920067973182780081220774408071987583701159788442372522811321911355017970149229691298244167138682177847296", + "envelope": "1/250000000000", + "actual": "531441/914948960734526081", + "actual_envelope": "1/1000000000000" + }, + { + "k": 13, + "normalized_C_square": "156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/483571252173295416513130103633151479314095077764006994156763126849770384012447793932003754322021952948264900500089109023743914893920116316066749729443408617804398025980014413915893225672018733504533728888089153628945819", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 14, + "normalized_C_square": "139248512380970273165164666283627789709258313483042357461272331420332193374633789062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/14137993116923917836201080162689398575707624373817454734258560386848793200696077493613897586283746064759782352224346155401586698013163903290589488586672169985647431877686449695288286037119029541002726801", + "envelope": "1/1000000000000", + "actual": "1594323/100010959477212427777", + "actual_envelope": "1/1000000000000" + }, + { + "k": 15, + "normalized_C_square": "789470510901434134407198572072140800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/2432312289823039259550141768225934274672803480253863888757790269719722507046843323067247563128356288943193677020389052618588727439915164648248500212032121138257", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 16, + "normalized_C_square": "99568244445778267314305024860481987849444034699538674129617865836635181344566135058943117170011417871311465432881959713995456695556640625/8644858885463545391789978170335959141189712272784910225118787817404560294933468492675672887492538380172163345025654403125136902374474068613819295229688718952975302656", + "envelope": "1/1000000000000", + "actual": "43046721/83309129244517952338241", + "actual_envelope": "1/1000000000000" + }, + { + "k": 17, + "normalized_C_square": "514727830236622500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/1173714818630866254656232976060217335336416570246580660956331538041173597011347905741086407143448613346247252308504107148659874314150542730926047099225181762433318103981096727036181173418807873174319481623044633511059636521062800678497310251", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 18, + "normalized_C_square": "7888609052210118054117285652827862296732064351090230047702789306640625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/441649530322419809581172409869751465193182619570787312904973828274195424142393320562270208178592076541351587183678759390107314497637900464318144554053035412614861200191192341669873186443569251479609", + "envelope": "1/1000000000000", + "actual": "387420489/19930484037497324244683891", + "actual_envelope": "1/1000000000000" + }, + { + "k": 19, + "normalized_C_square": "2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/3221479569325648074911494025619572886137833145615793815863145476440427738388239934618384091102662201595320290301015049904274463625809797200561895655955247928698714371650543886853888429905868727690197147868435660350412972747385971", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 20, + "normalized_C_square": "584710073428189415831453040311604434100764028647834180674180970527231693267822265625/16297218604960542321474296842916177424718983160462889772508374124569721938321296187028529404513706546367362232406245376", + "envelope": "1/1000000000000", + "actual": "43046721/51399669359861520420500561", + "actual_envelope": "1/1000000000000" + }, + { + "k": 21, + "normalized_C_square": "2242016718750000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/1273072818961171592239608036241055436614272431759038455826430430929448750144497910459390999618732806977779602228807624752550642963354288946607140358135457992269486004443462941131376850763909984876161038909779359419259215643383999839948377", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 22, + "normalized_C_square": "493038065763132378382330353301741393545754021943139377981424331665039062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/5382571753449707985166017340712562352929407302650793665173869976090112157335547564524230195969595337047582581739466110341301958986652137791598522309052952568546038304226318295985864178074684524995572009", + "envelope": "1/1000000000000", + "actual": "1162261467/28424017156003420792536810233", + "actual_envelope": "1/1000000000000" + }, + { + "k": 23, + "normalized_C_square": "211070580886405013906250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/41886325669351741955769817357122181232619087876935949421330365701326464964194771091542097491682863035483550703656226630523161519196862926251502467823975294115963242134487345128624818976008924854197673863628723377048175737378485258695485748025703684411", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 24, + "normalized_C_square": "38574777952054950308480769426605088508323666301428241205708202965565596071115489537375786277190119647286827009313725511674419976770877838134765625/131776291036281388456208312220970018643020672551471360485113281695694171159575563941383770808524389558811027596532234521522424058940715554993562032578472977787570833948281026600799043584", + "envelope": "1/1000000000000", + "actual": "240588123669/107243816729600906650241385009109", + "actual_envelope": "1/1000000000000" + }, + { + "k": 25, + "normalized_C_square": "6277101735386680763835789423207666416102355444464034512896/350094998969037961043518912291510372585948910881908895416079467997976984699792676573107229531570027", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 26, + "normalized_C_square": "1942118163329690070868020219976496075393400850928960280072921307237265864387154579162597656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/1679542999352101557512943604284506230283480147669283292860231565260715652832734470386483136154771421217934118024315849052776016180372013998791411638698875808589963639726906947657399744858828720624972345285688499960346937806999561", + "envelope": "1/1000000000000", + "actual": "721764371007/5254947019750444425861827865446341", + "actual_envelope": "1/1000000000000" + }, + { + "k": 27, + "normalized_C_square": "625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/7969316772347742044116345258504026101516799928282653057128820619457625361884218408055771748798641365645096513594405906641419321797970772471335330595334945218440859733641497639485973238466238195286680443902122523657974611199938853187894299", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 28, + "normalized_C_square": "99568244445778267314305024860481987849444034699538674129617865836635181344566135058943117170011417871311465432881959713995456695556640625/17820478048298309595073245372697160017576512906876918393258921396138603389256788662844200195501224173879246235762345156780775118618342801508943182539824649576659878332878783455952896", + "envelope": "1/1000000000000", + "actual": "175388742154701/18796945489647339711307758274701561757", + "actual_envelope": "1/1000000000000" + }, + { + "k": 29, + "normalized_C_square": "1009544045191667702958162656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/2416943047473542747187326882452962825384084055069841704901847186051099356789500293289758182422729023509338339968578131782188912524808446933590103697477087458429069389853885698915646988993540220643934149583604104812339103858238666031945903858274712922146594958199779", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 30, + "normalized_C_square": "3971665356764062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/121326954768114362145631383550784069159025357070121690347488359115803571499567014712660071857897976740495338533140895275899803897662596696804662854543231161", + "envelope": "1/1000000000000", + "actual": "1578498679392309/2254985288223554995022058311644370115607", + "actual_envelope": "1/1000000000000" + }, + { + "k": 31, + "normalized_C_square": "156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/58147395195756938175426656404171330518647692549792536672481944142066975578043010119790376822230117449385258177678278114075323245997470506342415609660015587570203545029054408595812635199882918195469288123403733002900050273648180611335668645259", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 32, + "normalized_C_square": "468979245498489243293029769030756310526298556974394155316223547186797976103241188419608401877051365411089006957408333912625843231669620081447646953165531158447265625/2031520729189040261666560530596900965007595027809850219402903952584194332936430291085398553534459929457657399627052464407289247123546582539847801899181029934082720942203849123350526969998747372316654264705041301504", + "envelope": "1/1000000000000", + "actual": "205891132094649/3564331584611425637292930879695939860153", + "actual_envelope": "1/1000000000000" + }, + { + "k": 33, + "normalized_C_square": "686303773648830000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/33089786444486641457975774033197286692284972462261191895356093079549763279169270086630692778658501010923105308569177790252870798039930336688750719732351573654037734956759810545815679467201833870613901213500783092884450714223109678958342833972535945855474445257", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 34, + "normalized_C_square": "31554436208840472216469142611311449186928257404360920190811157226562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/16202964204128322983328337890174202569254721687402891564381916921008247187197378843948392439462737904842247018612353608349013400717659456418492820007686626117263985159668708915745098995509448734165219625857013589883481", + "envelope": "1/1000000000000", + "actual": "5559060566555523/1063790962934482760657517461640160960080209", + "actual_envelope": "1/1000000000000" + }, + { + "k": 35, + "normalized_C_square": "108817783894694080747957168042049897781426245399113877579366400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/569778538054724928379418608861044214603600438075758569353758880466579128965374047352665348731103948464509958374199001375900916451150927160342492236883162143874237024823477477701821510921962955617150575997697019", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 36, + "normalized_C_square": "99568244445778267314305024860481987849444034699538674129617865836635181344566135058943117170011417871311465432881959713995456695556640625/5092850998179526942281874785745689015465781967012728195666312161266754954517710067544677601386263755983279773832009824794507194753051669400990148094492488754701359248453251096467531171364864", + "envelope": "1/1000000000000", + "actual": "50031545098999707/96804977627037931219834089009254647367299019", + "actual_envelope": "1/1000000000000" + }, + { + "k": 37, + "normalized_C_square": "39062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/18707694487579071986960873493208490546108948599189202552722207987935167694860553783825015504147911021464645436428565039396744166374117559807598835376151401899504269092358281527754476366045800005397703259481135854413757650900992287369276344326639659", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 38, + "normalized_C_square": "308537737121551172794111683030429811849429030530429691965143496946467893682353178519406355917453765869140625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/1326719201656741960999777862579509978410542727121978748750807725924213233083602759743699420211726361422990034681771282242342814487923584272914868786402852731068624050679212292187942706257281501866014490465327154255476412129379691170513866060945613659921", + "envelope": "1/1000000000000", + "actual": "1851167168662989159/33204107326074010408403092530174344046983563517", + "actual_envelope": "1/1000000000000" + }, + { + "k": 39, + "normalized_C_square": "1954357230429676054687500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/72387003563048779656646082768334447788521253881303659229475243902803034678292934883791695439464190957601520262240576529503364008753674679931372825179481804190424060932626731872978452058040963835034646251556314115902652552314919197608434826921696833084503101379467297", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 40, + "normalized_C_square": "13583150117942535410105987870983353972553775435017087147571146488189697265625/4158967000863326271428919679602915387926066800875652533605864153161017600413796765207964564793092870016828805191218739902368559661056", + "envelope": "1/1000000000000", + "actual": "49981513553900707293/7634390522895016700824372582514701104341067027101", + "actual_envelope": "1/1000000000000" + }, + { + "k": 41, + "normalized_C_square": "285125056740636426149851871540091237656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/692852603016076963822855618765289404766704737298242169487353064778591021126817424224995845894155731437596865292764221052996642331047567953981360976513429027210706271368572340398482693840082679668822858568163156569201954742060291227029477740633818110377858715839719373562573916941180885059", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 42, + "normalized_C_square": "666021318014297006470514478729936925717901526381673621424184261741174850612878799438476562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/12335013313093471488641487988428804313789530339696527342834152773916390000528689978481172990057880784717489870837453370676623800446062644148648578638535171349159582099871991826919688781859471373795980185876733945547259340274784014666289923369", + "envelope": "1/1000000000000", + "actual": "18443178501389360991117/22071023001689493282083261136050000892650024775348991", + "actual_envelope": "1/1000000000000" + }, + { + "k": 43, + "normalized_C_square": "132388845225468750000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/17951141601582057519952070969544998562384861208147861659152139326733619230608720203234133291833555709674703167813854420735369460904247825983411221234130416901888700625459029517478759213901353896442272891999963459180286703098981560851435530522167801899017472085189753", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 44, + "normalized_C_square": "132453590925347422769014835725490993414808202606897311071756538411344983913427323447097585873668787484082024252415419855989390057502221899332628396450672880746424198150634765625/126339530611845922669250813371254781013440087532130248242999973860370299002975597751965317714446294883011486771360754916576475325905503391156651911209730541733787969825452698885772899835766783590872489664803389271220906627562503233601536", + "envelope": "1/1000000000000", + "actual": "2379170026679227567854093/20548122414572918245619516117662550831057173065849910621", + "actual_envelope": "1/1000000000000" + }, + { + "k": 45, + "normalized_C_square": "123794003928538027489912422400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/798258392695368507643599256784783076846822333080593757368535460546985013529869807405820045278907932725874540346644838585853002948615330600438687317861764442116097411932236897216333287691", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 46, + "normalized_C_square": "123259516440783094595582588325435348386438505485784844495356082916259765625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/5164637866312039798739150659980542637872579134369714099159961038718449638633156794052492736490302191133182100022853203489110097243716064284273970250498909108590315322514447240906171297758681698344123877934926609908561958295801", + "envelope": "1/1000000000000", + "actual": "192712772161017432996181533/11075437981454802934388919187420114897939816282493101824719", + "actual_envelope": "1/1000000000000" + }, + { + "k": 47, + "normalized_C_square": "4209087368869460081930650790642711873090976562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/1101665767023295544954996182361084144860714123780801995878166630918347180728084922508898715380416848216421247606754398178335416329685944191625472275594299900254123035752822907550474173748497672682893734537583172111612716947572315712927589411516966259336624483862830476626086267490465156798234790611", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 48, + "normalized_C_square": "10894656656856378057065711672458311296841832783834897792011232334904160902365622422660448443379726075096149761497706966173470988223925814963877201080322265625/17125022399108357057376431875031784043809904154752461120624072903516892191262830919335991331975102492386493403736517146595542748367327943306304884986224393232861224202567526226886940231958237809590717418431501812308639744", + "envelope": "1/1000000000000", + "actual": "81517502624110374157384788459/28762912437838123220608023129730038389949702885634585438795243", + "actual_envelope": "1/1000000000000" + }, + { + "k": 49, + "normalized_C_square": "22795622735731741501875000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/206904910585257210238853526717080687670910856223930139373071795463545405691583245352426672382820691682479562615617563493663894266591745272495636534599765981024624370241630034943958250115473046466732610888014252704599100248146064819262008682651912864191122042365948148273879574073", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 50, + "normalized_C_square": "1555876160979821354635083893361477434216258264919969496701798426234322944/78408258723193668914391631767776078682381690865418464724001937365715238286676682746137537144843572569173461552215164492159874413845917609", + "envelope": "1/1000000000000", + "actual": "244552507872331122472154365377/488969511443248094750336393205410652629144949055787952459519131", + "actual_envelope": "1/1000000000000" + }, + { + "k": 51, + "normalized_C_square": "1846445441594271061651875000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/496778690315202561783487317647710731097856965793656264634745380907972519065491372091176440391152480729633429840097769948287010134086780399262023319574038120440123112950153713900443758527250784566624998742122220743742439695798701631048082847047242786922884023720641504005584857349273", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 52, + "normalized_C_square": "71479842325634696432408134282998980418579264894740764413385695349306199680420848715075202237014382778705838585186455405064143153737177271977998316287994384765625/98722346251402255872720711849615103687539379281221142620634776098267083621084158946619042166561402823212149560353677783211131431330720494900129707273471368333191618144185477760284059936133081282966377364491340079098658704850944", + "envelope": "1/1000000000000", + "actual": "6602917712552940306748167865179/69059752763249333852679863534481822174269236628408639638547378443", + "actual_envelope": "1/1000000000000" + }, + { + "k": 53, + "normalized_C_square": "2236881600399354735401306986829953440547341675351562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/15248472280879388495225908779918335934744632329207144395063722543875409708686075699163496597800305567262711092523821532656251713529088455689145940793763727877942969822244813109897984442586131029884024379498141613621445242555268481499275833561412907079704867219033826515757377516937637764327865346676949269811", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 54, + "normalized_C_square": "123259516440783094595582588325435348386438505485784844495356082916259765625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/3987203848308916957412771661381737529369817468021042771028240794416617566859241799877292639464561623506428742364932656936786408994873486516027338912611960389191396830276625417422144422424637248165643994237128202583436677818830241081", + "envelope": "1/1000000000000", + "actual": "1264388498148435377887947038013/63847695950928629410968175720558665783758350845132515892241915919", + "actual_envelope": "1/1000000000000" + }, + { + "k": 55, + "normalized_C_square": "47960333537262123665237313253382553600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/7077205138250286499448167787441009519321356300802989062832627099661762950048192779058954405839709853215497706587569288387738966225824587816050241603415741119648000509292116172641624958075453048736353299", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 56, + "normalized_C_square": "37408806290289860486540805582962780626284504023782743419561468473997235918453680393244234303074369072046580275393887574584087205594262467656121681248981847289769575581885874271392822265625/24204282846660207209361457159524556062841538366666612113067915580290094198405988601961036703204844770571936465504704261479830042828143622438971221113496066312806944121158060732870415978562818591323838539652677432478850390225255833774741804498520657086119936", + "envelope": "1/1000000000000", + "actual": "1264388498148435377887947038013/284412463781409349194312782755215874854923562855590298065441261821", + "actual_envelope": "1/1000000000000" + }, + { + "k": 57, + "normalized_C_square": "3028632135575003108874487968750000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/8257283452335926933890343029010511094250198816172820800268717913165679131911457894508635987111576522723672494533200055215101244622481527906571270456037865429989053508883932461013117285019770911267608275949629568610770497979148311629359363684951082866730813957285864230915156391915315920153", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 58, + "normalized_C_square": "1234150948486204691176446732121719247397716122121718767860573987785871574729412714077625423669815063476562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/13623130065147620880299865531663176359217058450169005710004397204152504874479057559506577847251902843014511250974298062380474285562272377981490423920136336243366794890711812077339247666466741349058305562223111786042140398382468910044787384969616506362647571612906928169", + "envelope": "1/1000000000000", + "actual": "793918359302505934952896977357/733484775015213584764280334473977782520592346311785505537190622591", + "actual_envelope": "1/1000000000000" + }, + { + "k": 59, + "normalized_C_square": "42795741405522005277710615509964302310325113062458350156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/1837258619051884461476919368767577479901152676491511422182683775420629226448488403428403820099085465456788714055649474853706065072857829998524609657479805241234093454624571752757753527465671100773950205415332659552416782115664024380032127246725510669965059404030775495045687600985279235731491486883860225081884276399459", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 60, + "normalized_C_square": "165139395014095011352347445395924648128503094658966012832357339590316769317723810672760009765625/26479335060527168073252856264900916332936239076564375900298735028348324188540343940843428778793541992963352547582424768302327087613399034189157687070555307979420205056", + "envelope": "1/1000000000000", + "actual": "174274761798111058892099336493/609165321622804502600842989647879853279813982530126945276649839101", + "actual_envelope": "1/1000000000000" + }, + { + "k": 61, + "normalized_C_square": "1924594132999295876511500132895615854179687500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/1106558453111687294557557096007469595793579250075214473332609988730974464705014571291667722882631748794008373210260980275208100013143130942395915131890233950667433076753842082564198033743778493862739162309455650193887654853189803305866605641924384318557718610212118394477137130902073687893512460125708097", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 62, + "normalized_C_square": "24610957845173265936360186183656294447847125104449232372091805233241135732770565262744256497529082849951009848155081272125244140625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/48695063379361898505705382901995516937174246418250214723471594700671981871100980171047383030510928596736467448806514870425635491074499128573969335094582134469729585863354148246769671550532522530536582329409389809855489988608126881169006852705510621267578331545611522182484565976857745466744721", + "envelope": "1/1000000000000", + "actual": "522824285394333176676298009479/6361283768421745379618639088618024041626909948716243674446327008317", + "actual_envelope": "1/1000000000000" + }, + { + "k": 63, + "normalized_C_square": "39062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/255160300073958087778904636343447686297282131557367472150722707359966598761712458571798041655517624290247950109485294932752802439879213618115799771936115525970279419734903724933810278744545440735239354115076506152105424712151944939763526200620668806197827039944124699", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 64, + "normalized_C_square": "5789867228376410411025058876922917413904920456474001917484241323293802174114088745921091381198165005075172925400102887810195595452711359030217863619327545166015625/119731576684011823105935385631684064884446228009969826593811762196042735973580242642440071849964513113161257492364059862557883705637251771145645298186475123041230682578368072191040431092673662576729171569912813273394089690739862138781696", + "envelope": "1/1000000000000", + "actual": "1144561273430837494885949696427/44528986378952217657330473620326168291388369641013705721124289058219", + "actual_envelope": "1/1000000000000" + }, + { + "k": 65, + "normalized_C_square": "4612911900238249496988047728041858185462564514814027741408517817214057451112744580703846400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/289459953112063659708071153306336428555168263773299614561133609528699604571446457954972760630809549562540683962148850069560714179716860823139487499860599762732660427199973411487261938441977983031961204109779592093856078323862399691276061056310939652134661581019", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 66, + "normalized_C_square": "12038661896527526327586128769362906848567875600638622335478850056134092483262065798044204711914062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/2195970613197061526854449863831747801329508691877199140330732844600543776350535243687428301416447820743415822453407490926070125809241668853343991475338407736465188816801280558810517462448428622724485421697327485400293628748780185253147399673877078410946071081110202528209", + "envelope": "1/1000000000000", + "actual": "10301051460877537453973547267843/1174880179075431588958796342443990440303554675912900081718894703613009", + "actual_envelope": "1/1000000000000" + }, + { + "k": 67, + "normalized_C_square": "190880563234078270754244862876156026926706489630000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/96908235332351752966519479774529059988745031556949562268783600880204921117232217759512991774639417706900861753106894625910174680017607579642716632937965944685617444285764720121567963087549926747300690862861612443542240785467756980383223834466251542620748740675928430143565154962190732143353718521131459243587604450857", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 68, + "normalized_C_square": "10565351820874082428347876859888515122956419356669939624233298449398733741724077267732486898043054130289637761220652997390409065834470098893173700937284372283232747324888123330310918390750885009765625/14284996527802939227007616743760552413265792340755110112251647874178410375982030969407388124767154271702323204009666168789255741625268565763171545840073775584082717955993839247301859456407516998808590047951163952571607671634042166438017268443737674389014291144456680247394304", + "envelope": "1/1000000000000", + "actual": "30903154382632612361920641803529/9451648007785934723116286993691206676471880153985867821589317093244953", + "actual_envelope": "1/1000000000000" + }, + { + "k": 69, + "normalized_C_square": "1609539290762115227183366760600468750000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/5541757322033947879228198474998279112740385815122171773074944995368534248774123637784559901022524333369775032580966917577417229193303247877952953622089391594977614356798323242501958429920859363203981778969478383391427562424650071641851271774051973041972601587008118643068389346102913827252870799289297", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 70, + "normalized_C_square": "587047207208806656758719005623652980937244349279264062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/4918135596225268939730615937097308535720035241741212560754876595490842175432205811211879087969521192424574624013452525792517445804145084445839495271453942355497361730675909864680657177475124052521526112562835614081197359161", + "envelope": "1/1000000000000", + "actual": "19190858871614852276752718559991509/14357053323826834844413639943416942941560785953904533220994172664639083607", + "actual_envelope": "1/1000000000000" + }, + { + "k": 71, + "normalized_C_square": "12086781408522319404429444819332427338361679102644030236997681425156250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/235234912424634509997598024501477641737158304571998498428764915398164074650093600622654230046475708436213468576749000012808248869302054220139822684639149159588547061455054383982985865165803234353565177965775708203875054639585419737095440356535260133059687702658380648563835796000023831948842774793460441812253795642065459328836585461379", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 72, + "normalized_C_square": "99568244445778267314305024860481987849444034699538674129617865836635181344566135058943117170011417871311465432881959713995456695556640625/4294142537403799287800461338122018235067665496355419414457008435944766882564774096482122405826751746585878675842988726885340751464179015802372816438722964116034467467214963831198331095917921391673334796544362151936", + "envelope": "1/1000000000000", + "actual": "172717729844533670490774467039923581/287343278495182145266363131825288393238843335781666784606094638823269546557", + "actual_envelope": "1/1000000000000" + }, + { + "k": 73, + "normalized_C_square": "715350795894273434303718560266875000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/65151494800534879211815676031703331933856985611530899807120915121530598753552535261912020157879622778913042504627909218249025843366765356291181735232543171108401758231288865593244945588526711489365241106423304523995437513989530467439797117686901406372671474817842522278139363809205687828890940539324153", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 74, + "normalized_C_square": "12357086962783495220514051249978502362175141993952027394926486528716131659214928051692836161141531362006595884395210305228829383850097656250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/2262574918079584597338655797598656163088720771234894471774017726000030880102356339545535845889023821200414667780665908272102804307771365137935336447442094065651149974226055140066173483822669967103737693350324234995943600453655096276581413859319505483454876913255179035400841963195375985878862967414715013073161", + "envelope": "1/1000000000000", + "actual": "57572576614844556830258155679974527/192874255428272946822627307663549743406894841826050307475323798662194627141", + "actual_envelope": "1/1000000000000" + }, + { + "k": 75, + "normalized_C_square": "5237520588111933367187567688111440715247027535943975496693327749045159125284975410117869568/1833289335618236898581641719234200295499104873929321243048826018018231444542954213852023613833683736209462728162094763556645856550682820070071459183017629060210663940641", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 76, + "normalized_C_square": "1610326447321152633493046313045041171003874311335153120596448475750454769352854331311154838903071807695418040118983843528487892978885855645964593954775853114347317074361853883601725101470947265625/1023371790235468828277012826460925933325459248897755780106180153368287515885894786726415504352274977335113753402473998980585195263327006944917759654450844268027713961048478299519165852458888984159664329900203941437054670567711650427215118797151671502473207629154491966685184", + "envelope": "1/1000000000000", + "actual": "1554459568600803034416970203359312229/9450838515985374394308738075513937426937847249476465066290866134447536729909", + "actual_envelope": "1/1000000000000" + }, + { + "k": 77, + "normalized_C_square": "713712355391834438512154287136760501902918789332027341464476090474051406250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/781017179058887892773743940529642462999999021926601568795159674193050049004247865632250536198072177507149946776285499518301834528788874227119196508237083257410002487400326308976360899059360484383625386174372881116615454501811990259060726610037435267822032577522118846334874356972762178898508360332009514823430186209946117584430145166436877211", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 78, + "normalized_C_square": "11107358536375842220588020589095473226579445099095468910745165890072844172564714426698628813028335571289062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/19820751688957911102088356680561579639519353587737260464584457055169551571967040183815739750118912479279194853209352031201540569217768593118108209338840005008142186300358940701339765430627836624723257325432849767993425961386974822831564858697351396753938059036965351417154857609", + "envelope": "1/1000000000000", + "actual": "608266787713357709119683992618861307/6014169964717965523651015138963414726233175522394114133094187540102977919033", + "actual_envelope": "1/1000000000000" + }, + { + "k": 79, + "normalized_C_square": "49739841187334647754853682384084063120829955154913704679002804218750000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/136844040049653721447856271447594400176585835670275110439415741234944438696301509874662519787629499666737428820056389024554800059255132116121781399724644310087374885455860016544141226067440103211554334313166862258650115556602718953132627362876003770609358106645172276798107131342006081311062948279318290311478298618861411806461756107577", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 80, + "normalized_C_square": "1050730024414179757357633265654372043817075141825257502525940308369188756016774492595150806770114650968983571743819993571378290653228759765625/4206087399419394995706272584376211630140940564925771319420131363942430707913584441439251361287526623628141065666137206396609422364918614357353703573694901823192491944817164075888583594521602307942394295139497429618917376", + "envelope": "1/1000000000000", + "actual": "1824800363140073127359051977856583921/26112155669598255374839217628663939887316192457989634780396282610826853496561", + "actual_envelope": "1/1000000000000" + }, + { + "k": 81, + "normalized_C_square": "2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/13714398288044188988141619251822401631920912716612256332533262007784764738742753098026318665813689516559644112425454562784336292330246347865705188468897983639349810619804165170420294507028584719739475277888379537896485655277190395491355988209744128219802515956790037181018691", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 82, + "normalized_C_square": "93008156787176715537672488573358113974459192978727854229737536461929972728599622924786278523046068045232459553517401218414306640625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/657093081791172260282635271419402077362244410261062585205605875432181732176061513326669939492394807055110804990859062891369465783911815135073410784003284098097404819220008920939796759768677140532949219980891707819180209187322275646605845515322398245450973874712866986036707667990381314550374146977974090809", + "envelope": "1/1000000000000", + "actual": "1330279464729113309844748891857449678409/24310416928395975753975311612286128035091375178388349980548939110679800605298291", + "actual_envelope": "1/1000000000000" + }, + { + "k": 83, + "normalized_C_square": "491567626188882284045189771317280290707758627360536917318288538844915977992022500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/4192797325288610005706363913151165600555102890437087252829070092876111076328696417249439058809816352427702877779341483235325227634065302545831760728661554781992129723010231775758335916669798406741169628759774141135716480605943428827166442433747543449808609354845058687444133430766198087185612373581624278550500696712462691632594330271015317417374469451", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 84, + "normalized_C_square": "132453590925347422769014835725490993414808202606897311071756538411344983913427323447097585873668787484082024252415419855989390057502221899332628396450672880746424198150634765625/1275098090947967012421166443233364488554508332711682973712021002489391708077948566681776584967920830991604561530768435708464619249266995590012640698194972562154046339660861523746477167296649679161197412306895505256463466997606811589188957239643059806797824", + "envelope": "1/1000000000000", + "actual": "11972515182562019788602740026717047105681/243982859052455997627246199675112586183507415946957777515629714207184022942331041", + "actual_envelope": "1/1000000000000" + }, + { + "k": 85, + "normalized_C_square": "4946654444754852901452863613734312784373891598822589635003312080859094676063182109574741947235224780800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/50089296970523989199577048116258493480808189097921479355917084116501294061828297966219952425628050248783397094009175633917231371681006007042240968532416328692918344157944977418196533579295158182645986708664967708380149200839318606474183157448311433873575255758342874860685126257", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 86, + "normalized_C_square": "70672628448875600716908963135847868438114701040917641350610855807847552150923692035406285518684432059803461666312035527326429473760072141885757446289062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/699045634547810207842873750371843770104742559060066266791736978236884929443437693230746002708806942117828687759268121784579595433626835746749973376590199069707129918312270407346984470579299827623725773493141357288306023511170407884859300919584250534850663228197836614547831287262273805788918242118918134517213570951427133201", + "envelope": "1/1000000000000", + "actual": "35917545547686059365808220080151141317043/703244711386490816690297869651795101352462551847113594015638588008942183774954177", + "actual_envelope": "1/1000000000000" + }, + { + "k": 87, + "normalized_C_square": "5612116491825946775907534387523615830787968750000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/50156976539193653779604189262562218927793440576951710969960291607469582265787441279798327524590330404491263996958525865292684181562718879205931068556745745238978027595266755417587853869377673618138849628110127372916535584008935810478700298188369357172489354766349371106221235172500612036056186597395039065029534897", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 88, + "normalized_C_square": "19577810226402234406149878558157749724385839922957689797650514088011467269485759852064158909341786368319374332149048846863101586519537608580908166738722442317855191665841954086479947960697245434857904911041259765625/145564429122293303378829200867363109690893823402820691775841876533736510469079704989982975343630033121975588975405704544114423527881112963280933958423384202784914625887933114239627817657244021211414905192363714385668454822881611802025839852418223704150564172066614273070609547684071414742122496", + "envelope": "1/1000000000000", + "actual": "969773729787523602876821942164080815560161/15447133832868781042473094585110119984879953294021081358205578640058488657401579681", + "actual_envelope": "1/1000000000000" + }, + { + "k": 89, + "normalized_C_square": "65309797707361447478814924314656688743505488170777774969137144843070248065014607355625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/369986230332723699799861322653625402397090560675504008606504551041606093728621150899722138110919601910565289462022133229458271867230661135918204992615445023981587894604191695324806903323427501313659083155039764759779128888423444245715258139382590589043939016395401514878964681124723241730637839773851311518852204030517040487158985036063247133935094113141451", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 90, + "normalized_C_square": "6250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/24554827276579373660408815578172876613156626124040877715034711839621070586056397124358838450471552178662375044622941880203102543177884873127143092885142014582838675395605028921", + "envelope": "1/1000000000000", + "actual": "8727963568087712425891397479476727340041449/93550619504677224515651662712071400807306683432329919686211313336983431307184847731", + "actual_envelope": "1/1000000000000" + }, + { + "k": 91, + "normalized_C_square": "1106027158924985139101676985463880654092456911561208063966149212401060950482050625000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/2722807136180635318796009758536768928079160308896955321153881164276741614523965631182697952652191194696460850658193433354591587031336151541078214500307249570117474200958363926682144154275732529602571219579341257999464040435928991378335451125487643875295304544131230806376536047640081394611693713005504109099864408697402647541533788244781991316176912819", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 92, + "normalized_C_square": "7584844811461954364323210558292090337361177327627990507716073219078791687151667860423264104030901542947826111935232925136588932706075068370306038022009383838057751786369214448899609727627879607325667166151106357574462890625/10478797517388591673948283933281021265159090585156412761533304942528820106769064891113804144855240823975397546519075605456977112720636400301846702539593083911047574752854248684383274398446177958356097027255275843906716191444571042380491040984129739611322532894437562484800365637114090235431368216612864", + "envelope": "1/1000000000000", + "actual": "8727963568087712425891397479476727340041449/50373410502518505508427818383423061973165137232793033677190707181452616857714918009", + "actual_envelope": "1/1000000000000" + }, + { + "k": 93, + "normalized_C_square": "4091232922541115199636592568504715940644429218750000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/2810522626518273759961192240672908239545592062722643716074512083998977134182277352936598545996808705462244043873546281769257323433482950261121658808697214055978473135259696391016789403580013303985761788262135033405330213459630694667445524177989627615474687742702895263523587793141389684844780366788997694147977078793", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 94, + "normalized_C_square": "37558332335498898120594816277878127050620114835886312237009983821378310962639037818988351782335173258294011471406534472677885005964526499155908823013305664062500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/11216526053468435282288396328863316738581195080185589387132895146221479846018876340253685943819621817257601252519909178736110645955346144051028300865407356679170328319064979265327116663069374543587971126068205943280680592659796796457098806279768826942699242107670920265083156449386551379616170446108990792851113535796738668472001", + "envelope": "1/1000000000000", + "actual": "235655016338368235499067731945871638181119123/557357412979478948044862635661745492154698131317677759718593953652846696199877963777", + "actual_envelope": "1/1000000000000" + }, + { + "k": 95, + "normalized_C_square": "27498751660213308618710848371260473354015088427887087452599966929901141553258466641544286103558680175845227708704358400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/3068602907039185903759970481945923564116297151057133497021615358168407394638358979428014998752869993914064036449986174635509139851824120191236886474263021908803351986308999877791440724573145697435058282990565690519201086649503789740956992126954319434025364335551948540260655276509461263006739", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 96, + "normalized_C_square": "70391268814957559703788013312790659031359086001612113893285366529863589595935730200048988134288414089328035050727903143686857441549038308403231367638142046416760422289371490478515625/2467081137752604820589826407812627391495791414008991923927768626263401413467096600428170943256597087264658437778056784931029463602173971251455767600533212476416592313208668613873403885491920685746374346619510743572075537072844340707325176797864072858025590784", + "envelope": "1/1000000000000", + "actual": "2120895147045314119491609587512844743630072107/1437395433473393076536751007759238374504221496556116327695321248894183584936527380267", + "actual_envelope": "1/1000000000000" + }, + { + "k": 97, + "normalized_C_square": "14993987415867882004142397107248761019336113660033446571185228185579913343229192873398064830000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/134603240979522365403944606386728290502019098411222322444297801673295335967458922250867956644357882900367190577872085445855032005319435971557482954921750324897808338469014901887333201421420102091939542519197598755196603614709569396240287054497347531371925261885466811686633586095064257789614731232162510110714717276418491305384189020342955904193027301578940170473", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 98, + "normalized_C_square": "1277442412461431674630849904482037101946150684703888490339124659969095101202934585443903274211583155939905776024048645548442104669106811343226581811904907226562500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/2297296526361789129170890534380737916387232441788093787566747721376126021397486971234547502764313035084739167960337003349786398685861839665444808627946927318039815784798246529949874287125100865444986626754970598284221700111110110311000187193318074100614739673562589682021295476865995251756542972865680821713394880312873373748263339321", + "envelope": "1/1000000000000", + "actual": "6362685441135942358474828762538534230890216321/726106971548415059281451540002089488151617044652058763474956094802216450122575686939", + "actual_envelope": "1/1000000000000" + }, + { + "k": 99, + "normalized_C_square": "10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000/2674778067801702499293765435680942893595102075366301386346002666723173487273473945528098965336326588645878422584387961306499660796117784940123722637714470749097749250156364273907191427122721160908005911402997258011858799200353932847838717945162625297615698087600455477859", + "envelope": "1/1000000000000", + "actual": "0", + "actual_envelope": "0" + }, + { + "k": 100, + "normalized_C_square": "265613988875874769338781322035779626829233452653394495974574961739092490901302182994384699044001/10461838291314357175018899611816813659819188550170233659950140084035125767424262251774382614909364050293065248252546314174063180343683591188150754267339816534637456120001", + "envelope": "1/1000000000000", + "actual": "515377520732011331036461129765621272702107522001/3234476509624757991344647769100216810857203198904625400933895331391691459636928060001", + "actual_envelope": "1/1000000000000" + } + ] +} diff --git a/tests/generate_conjugate_budgets.py b/tests/generate_conjugate_budgets.py new file mode 100644 index 0000000..d02c823 --- /dev/null +++ b/tests/generate_conjugate_budgets.py @@ -0,0 +1,95 @@ +#!/usr/bin/env python3 +"""Generate exact conjugate diagnostics. All rational claims are replayed by Lean. +Uses squares of the complete normalized C*H term, so no irrational approximation +or omitted high endpoint enters the proof. Run only in this checkout. +""" +from fractions import Fraction as Q +from math import comb +from pathlib import Path +import json +ROOT = Path(__file__).resolve().parents[1] +DATA = [(3, 6, Q(9,10), Q(49,50), Q(1,250), Q(1,1000)), + (4, 8, Q(99,100), Q(497,500), Q(1,2500), Q(1,10000)), + (5, 20, Q(9,10), Q(83,100), Q(1,50), Q(7,1000)), + (6, 100, Q(9,10), Q(61,100), Q(3,250), Q(33,10000)), + (7, 100, Q(99,100), Q(22,25), Q(1,1000), Q(1,10000))] +def rat(x): + x=Q(x) + return str(x.numerator) if x.denominator==1 else f'({x.numerator} / {x.denominator})' +def multiply(p,q): + out=[Q(0)]*(len(p)+len(q)-1) + for i,a in enumerate(p): + for j,b in enumerate(q):out[i+j]+=a*b + return out +records=[] +for num,m,a,x,b,c in DATA: + name=f'DI{num:02d}'; n=m//2; z=a*x; v=1-x*x + endpoints=[sum((Q(comb(m+1,j))*z**j*(1-z)**(m+1-j) for j in range(k+1)),Q()) for k in range(m+1)] + prefix=(1-z)**(m+1)+v/((m-1)*x*x)*endpoints[2] + majorant=prefix+b+(m-3)*c + assert majorant+v/((m-1)*x*x)<1-z + lines=['import Sendov.Analytic.PaperConjugate', '', 'noncomputable section', + 'set_option maxRecDepth 10000', 'set_option maxHeartbeats 4000000', + 'set_option linter.style.whitespace false', + 'open scoped BigOperators', f'namespace Sendov.PaperConjugate.{name}', + 'open PaperCentered PaperCenteredBound', + f'def a : ℝ := {rat(a)}', f'def x : ℝ := {rat(x)}', + f'def q : Multiset ℂ := family {n} x', ''] + lines+= [f'theorem endpoint_0 : BR {m} 0 (a*x) = {rat(endpoints[0])} := by', + ' norm_num [BR, a, x]', ''] + for k in range(1,m+1): + lines += [f'theorem endpoint_{k} : BR {m} {k} (a*x) = {rat(endpoints[k])} := by', + f' change BR {m} ({k-1}+1) (a*x) = _', + f' rw [BR_succ, endpoint_{k-1}]', + ' norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial]', ''] + for k in range(3,m+1): + s=v**m if k==m else Q(m**m,k**k*(m-k)**(m-k))*v**k + bound=b if k==3 else c + assert s*(1-endpoints[k])**2 <= (bound*comb(m,k)*x**k)**2 + lines += [f'theorem term_{k} : term {m} {k} x (a*x) ≤ {rat(bound)} := by', + f' unfold term', f' rw [endpoint_{k}]', + (' rw [C_top]' if k==m else ' rw [C_interior _ _ _ (by norm_num) (by norm_num)]'), + ' apply sqrt_term_le <;> norm_num [a, x, Nat.choose_eq_descFactorial_div_factorial]', ''] + lines += [f'theorem scalar_bound : scalarBudget {m} a x ≤ {rat(majorant)} := by', + f' have h := scalarBudget_le {m} (by norm_num) a x {rat(b)} {rat(c)} term_3 (by', + ' intro k hk', ' obtain ⟨hlo, hhi⟩ := Finset.mem_Ico.mp hk', ' interval_cases k'] + lines += [f' · exact term_{k}' for k in range(4,m+1)] + lines[-1]+=')' + lines += [' rw [endpoint_2] at h', ' norm_num [a, x] at h ⊢', ' exact h', '', + f'theorem scalar_budget : scalarBudget {m} a x + (1-x^2)/({m}-1)/x^2 < 1-a*x := by', + f' have h := scalar_bound', ' norm_num [a, x] at h ⊢', ' linarith', '', + 'theorem pointwise : ∀ w ∈ q, ‖w‖ = 1 := norm_family _ _ (by norm_num [x])', + f'theorem cardinality : q.card = {m} := by simp [q]', + 'theorem mean : q.sum / q.card = (x : ℂ) := mean_family _ (by norm_num) _', + 'theorem actual_variance : variance (q.map (fun w => w-(x : ℂ))) = 1-x^2 :=', + ' variance_family _ (by norm_num) _ (by norm_num [x])', '', + 'theorem paper_budget :', + ' majorant_Efin (q.map (fun w => w-(x : ℂ))) (x : ℂ) ((a : ℂ)*x) +', + ' Gamma (q.map (fun w => w-(x : ℂ))) (x : ℂ) < 1-a*‖(x : ℂ)‖ := by', + f' rw [show q = family {n} x from rfl, budget_eq _ (by norm_num) _ _ (by norm_num [x]) (by norm_num [x])]', + f' rw [Gamma, variance_family {n} (by norm_num) x (by norm_num [x])]', + ' simpa [x, Complex.norm_real, Real.norm_eq_abs, div_mul_eq_div_div] using scalar_budget', '', + f'theorem norm_J_gt_one : 1 < ‖J {n} a x‖ :=', + ' budget_implies_J _ (by norm_num) _ _ (by norm_num [a])', + ' (by norm_num [x]) (by norm_num [x]) scalar_budget', ''] + p=[Q(1)] + for _ in range(n): p=multiply(p,[a*a,2*a*(1-a*a)*x,(1-a*a)**2]) + polar=sum((v/Q(k+1) for k,v in enumerate(p)),Q()) + assert polar>1 + lines += [f'def pc : Fin {m+1} → ℝ := !['+', '.join(rat(v) for v in p)+']', + f'theorem expansion (t : ℝ) :', + f' (a^2+2*a*(1-a^2)*x*t+(1-a^2)^2*t^2)^{n} =', + f' ∑ k : Fin {m+1}, pc k*t^k.val := by', + ' norm_num [a, x, pc, Fin.sum_univ_succ]', ' ring', '', + f'theorem polar_integral : K {n} a x = ({rat(polar)} : ℝ) := by', + ' rw [K_eq _ _ _ (by norm_num [x]), integral_coeffs _ pc _ expansion]', + ' norm_num [pc, Fin.sum_univ_succ]', '', + f'theorem full_polar : 1 < ‖K {n} a x‖ := by', + ' rw [polar_integral]', ' norm_num [Complex.norm_real, Real.norm_eq_abs]', '', + '#print axioms pointwise', '#print axioms mean', '#print axioms actual_variance', + '#print axioms paper_budget', '#print axioms norm_J_gt_one', '#print axioms full_polar', + f'end Sendov.PaperConjugate.{name}', ''] + path=ROOT/'tests'/f'PaperConjugate{name}.lean';path.write_text('\n'.join(lines)) + records.append(dict(id=name,m=m,a=str(a),x=str(x),terms=m-2,majorant_upper=str(majorant),polar=str(polar))) +(ROOT/'tests'/'conjugate-data.json').write_text(json.dumps(records,indent=2)+'\n') +print(json.dumps([dict(id=r['id'],m=r['m'],terms=r['terms']) for r in records])) From 8e1b056a241e6a99af2e2029569dc92a334c1a6d Mon Sep 17 00:00:00 2001 From: Methode Date: Mon, 14 Sep 2026 14:10:18 -0700 Subject: [PATCH 22/24] Export all paper corollaries and validate the complete declaration inventory --- Sendov/Analytic/PaperMomentCorollaries.lean | 265 +++++++++++++ Sendov/Analytic/PaperOriginCorollaries.lean | 279 ++++++++++++++ Sendov/Analytic/PaperRegionCorollaries.lean | 310 ++++++++++++++++ docs/paper-formalization/modules.json | 29 +- scripts/verify_paper_results.py | 13 +- tests/PaperAcceptance.lean | 295 +++++++++++++++ tests/PaperMomentCorollaries.lean | 98 +++++ tests/PaperOriginCorollaries.lean | 118 ++++++ tests/PaperRegionCorollaries.lean | 389 ++++++++++++++++++++ 9 files changed, 1791 insertions(+), 5 deletions(-) create mode 100644 Sendov/Analytic/PaperMomentCorollaries.lean create mode 100644 Sendov/Analytic/PaperOriginCorollaries.lean create mode 100644 Sendov/Analytic/PaperRegionCorollaries.lean create mode 100644 tests/PaperAcceptance.lean create mode 100644 tests/PaperMomentCorollaries.lean create mode 100644 tests/PaperOriginCorollaries.lean create mode 100644 tests/PaperRegionCorollaries.lean diff --git a/Sendov/Analytic/PaperMomentCorollaries.lean b/Sendov/Analytic/PaperMomentCorollaries.lean new file mode 100644 index 0000000..00081b2 --- /dev/null +++ b/Sendov/Analytic/PaperMomentCorollaries.lean @@ -0,0 +1,265 @@ +import Sendov.Analytic.PaperConsequences +import Sendov.Analytic.PaperGlobalPolar +import Sendov.Analytic.FirstOriginBounds + +/-! # Exported finite-moment and raw-polar paper corollaries + +The identifiers FO05, FO06, PO01, PO07, PO09, EX01, EX02 refer to the +paper acceptance ledger. All moments are actual finite multiset moments. +The remainder premise in EX02 is deliberately retained. +-/ +noncomputable section +open scoped BigOperators +namespace Sendov.PaperMomentCorollaries +open PaperPolar PaperCentered + +/-- Actual arithmetic mean (only used below for nonempty multisets). -/ +def mean (q : Multiset ℂ) : ℂ := q.sum / (q.card : ℂ) +/-- Actual second absolute moment. -/ +def secondMoment (q : Multiset ℂ) : ℝ := + (q.map (fun z => ‖z‖ ^ 2)).sum / (q.card : ℝ) + +lemma mean_spec (q : Multiset ℂ) (hm : 0 < q.card) : q.sum = q.card * mean q := by + have hc : (q.card : ℂ) ≠ 0 := by exact_mod_cast (Nat.ne_of_gt hm) + unfold mean + field_simp + +/-- FO05: finite mean/variance identities, including the centered square moment. -/ +theorem FO05 (q : Multiset ℂ) (hm : 0 < q.card) (hq : ∀ z ∈ q, ‖z‖ ≤ 1) : + ‖mean q‖ ≤ 1 ∧ secondMoment q ≤ 1 ∧ + variance (q.map (fun z => z - mean q)) = secondMoment q - ‖mean q‖ ^ 2 ∧ + ‖kappa (q.map (fun z => z - mean q))‖ ≤ variance (q.map (fun z => z - mean q)) := by + have hc : (0 : ℝ) < q.card := by exact_mod_cast hm + have hn := (PaperConsequences.centered_variance_le q (mean q) hm (mean_spec q hm) hq).2 + have hs := PaperCoefficient.sum_norm_add_sq (q.map (fun z => z - mean q)) (mean q) + rw [centered_sum q (mean q) (mean_spec q hm)] at hs + have hmap : (q.map (fun z => z - mean q)).map (fun w => ‖mean q + w‖ ^ 2) = + q.map (fun z => ‖z‖ ^ 2) := by + simp only [Multiset.map_map, Function.comp_def] + congr 1 + funext z + congr 2 + ring + rw [hmap] at hs + simp only [Multiset.card_map, map_zero, mul_zero, Complex.zero_re, add_zero] at hs + refine ⟨hn, ?_, ?_, norm_kappa_le_variance _⟩ + · unfold secondMoment + exact (div_le_one hc).mpr (Sendov.sum_norm_sq_le_card q hq) + · unfold variance secondMoment + rw [Multiset.card_map] + apply (div_eq_iff hc.ne').mpr + have hid : (q.map (fun z => ‖z‖ ^ 2)).sum / (q.card : ℝ) * q.card = + (q.map (fun z => ‖z‖ ^ 2)).sum := div_mul_cancel₀ _ hc.ne' + nlinarith only [hs, hid] + +/-- FO06, cubic half-mean deficit, extended monotonically to x below half-mean. -/ +theorem FO06_six {a x : ℝ} (ha : 0 ≤ a) (ha1 : a ≤ 1) + (hx0 : -1 ≤ x) (hx : x ≤ (1 + a) / 2) : + (∫ t in (0 : ℝ)..1, Ppolar a x t ^ (3 : ℕ)) ≤ 1 - 23 * (1 - a) ^ 2 / 35 := by + have hid := FirstOriginSmall.polar_cube_integral a + have hQ := FirstOriginSmall.Q_lower ha ha1 + have hi := intervalIntegral.integral_mono_on (μ := MeasureTheory.volume) + (by norm_num : (0 : ℝ) ≤ 1) + (((continuous_Ppolar a x).pow 3).intervalIntegrable 0 1) + (((continuous_Ppolar a ((1+a)/2)).pow 3).intervalIntegrable 0 1) + (show ∀ t ∈ Set.Icc (0 : ℝ) 1, + Ppolar a x t ^ (3 : ℕ) ≤ Ppolar a ((1+a)/2) t ^ (3 : ℕ) from by + intro t ht + exact pow_le_pow_left₀ (FirstOriginSmall.Ppolar_nonneg_small ha ha1 hx0 ht.1) + (FirstOriginSmall.Ppolar_le_half ha ha1 hx ht.1) 3) + have hp := mul_nonneg (sq_nonneg (1-a)) (sub_nonneg.mpr hQ) + dsimp only [Pi.pow_apply] at hi + nlinarith only [hid, hp, hi] + +/-- FO06, fifth-power square-root deficit with the exact 23/42 constant. -/ +theorem FO06_five {a x : ℝ} (ha : 0 ≤ a) (ha1 : a ≤ 1) + (hx0 : -1 ≤ x) (hx : x ≤ (1 + a) / 2) : + (∫ t in (0 : ℝ)..1, Ppolar a x t ^ (5 / 2 : ℝ)) ≤ 1 - 23 * (1 - a) ^ 2 / 42 := by + have hcube := FO06_six ha ha1 (by linarith : -1 ≤ (1+a)/2) (le_refl ((1+a)/2)) + have hcp : Continuous (fun t => Ppolar a ((1 + a) / 2) t ^ (3 : ℕ)) := + (continuous_Ppolar _ _).pow 3 + have hcont : Continuous (fun t => Ppolar a x t ^ (5 / 2 : ℝ)) := + (continuous_rpow_const (by norm_num : (0 : ℝ) ≤ 5 / 2)).comp (continuous_Ppolar a x) + have hi := intervalIntegral.integral_mono_on (μ := MeasureTheory.volume) + (by norm_num : (0 : ℝ) ≤ 1) + (hcont.intervalIntegrable 0 1) + ((continuous_const.add (continuous_const.mul hcp)).intervalIntegrable 0 1) + (show ∀ t ∈ Set.Icc (0 : ℝ) 1, + Ppolar a x t ^ (5 / 2 : ℝ) ≤ + (1 / 6 : ℝ) + (5 / 6 : ℝ) * Ppolar a ((1 + a) / 2) t ^ (3 : ℕ) from by + intro t ht + have hp0 := FirstOriginSmall.Ppolar_nonneg_small ha ha1 hx0 ht.1 + have hp1 := FirstOriginSmall.Ppolar_le_half ha ha1 hx ht.1 + have hz := hp0.trans hp1 + have hmono := Real.rpow_le_rpow hp0 hp1 (by norm_num : (0 : ℝ) ≤ 5 / 2) + have hf := FirstOriginSmall.fifth_sixth_majorant (Real.sqrt_nonneg (Ppolar a ((1+a)/2) t)) + rw [FirstOriginSmall.sqrt_pow_eq_rpow hz 5, FirstOriginSmall.sqrt_pow_eq_rpow hz 6] at hf + norm_num [Real.rpow_natCast] at hf + linarith) + dsimp only [Pi.add_apply, Pi.mul_apply, Pi.pow_apply] at hi + simp (disch := exact Continuous.intervalIntegrable (by fun_prop) _ _) + only [intervalIntegral.integral_add, intervalIntegral.integral_const_mul, + intervalIntegral.integral_const] at hi + norm_num at hi + linarith + +/-- FO06: the natural degree is exactly five or six, not an extrapolation. -/ +theorem FO06 {m : ℕ} (hm : m = 5 ∨ m = 6) {a x : ℝ} + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hr : RawPolar m a x) : + (1 + a) / 2 < x := by + apply FirstOriginSmall.polar_mean_gt_half_add_one (n := m+1) (by omega) ha ha1 hx0 + simpa only [Nat.cast_add, Nat.cast_one, add_sub_cancel_right] using (rawPolar_iff m a x).mp hr + +/-- PO01: raw-polar geometry for every natural m ≥ 1, including m < 7. -/ +theorem PO01 {m : ℕ} {a x : ℝ} (hm : 1 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar m a x) : + a / 2 < x ∧ 0 < c a x ∧ c a x < 1 ∧ 0 < b a x ∧ b a x < 1 := by + have hb := b_lt_one (by omega : 0 < m) ha ha1 hx0 hx1 hr + have hp := b_pos ha.le ha1 hx1 + refine ⟨?_, ?_, ?_, hp, hb⟩ + · unfold b at hb + nlinarith + · unfold c + linarith + · unfold c + linarith + +/-- PO07: y=(1+c)/2 and the two exact Gaussian consequences of rational polar. -/ +theorem PO07 {m : ℕ} {a x : ℝ} (hm : 1 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar m a x) : + let y := (1 + c a x) / 2 + 1 - y ≤ alpha m a * y ^ 2 / 6 ∧ + alpha m a * y ^ 2 / 6 ≤ lambda m a * y ^ 2 / 6 ∧ + 1 - x ≤ lambda m a / (6 * a) := by + dsimp only + have hA := PaperPolar.alpha_pos (by omega : 0 < m) ha ha1 + have hL := alpha_le_lambda m a + have hb := (le_div_iff₀ (by positivity : 0 < 3 + alpha m a)).mp + (b_le_alpha (by omega : 0 < m) ha ha1 hx0 hx1 hr) + obtain ⟨_, hc0, hc1, _, _⟩ := PO01 hm ha ha1 hx0 hx1 hr + have hy0 : 0 ≤ (1 + c a x) / 2 := by linarith + have hy1 : (1 + c a x) / 2 ≤ 1 := by linarith + have hysq := pow_le_one₀ hy0 hy1 (n := 2) + have hfirst : 1 - (1 + c a x) / 2 ≤ alpha m a * ((1 + c a x) / 2) ^ 2 / 6 := by + have hp := mul_nonneg hA.le (sq_nonneg (b a x)) + unfold c + nlinarith only [hb, hp] + have hsecond : alpha m a * ((1 + c a x) / 2) ^ 2 / 6 ≤ + lambda m a * ((1 + c a x) / 2) ^ 2 / 6 := by + exact div_le_div_of_nonneg_right (mul_le_mul_of_nonneg_right hL (sq_nonneg _)) (by norm_num) + refine ⟨hfirst, hsecond, ?_⟩ + apply (le_div_iff₀ (by positivity : 0 < 6 * a)).mpr + have hl := mul_le_mul_of_nonneg_left hysq (lambda_pos (by omega : 0 < m) ha1).le + have hid : 1 - (1 + c a x) / 2 = a * (1-x) + (1-a)^2/2 := by unfold c b; ring + nlinarith only [hfirst.trans hsecond, hl, hid, sq_nonneg (1-a)] + +/-- The rational bound evaluates strictly positively in the Gaussian quadratic. -/ +lemma rational_quadratic {A : ℝ} (hA : 0 < A) : + A * ((A+6)/(2*(A+3)))^2 + 6*((A+6)/(2*(A+3))) - 6 = A^3/(4*(A+3)^2) := by + have hd : A+3 ≠ 0 := by positivity + field_simp + ring + +/-- PO09: strict comparison, with the explicit positive Gaussian root. -/ +theorem PO09 {m : ℕ} {a x : ℝ} (hm : 1 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar m a x) : + (Real.sqrt (36 + 24 * alpha m a) - 6) / (2 * alpha m a) < + (alpha m a + 6) / (2 * (alpha m a + 3)) ∧ + (alpha m a + 6) / (2 * (alpha m a + 3)) ≤ (1 + c a x) / 2 := by + let A := alpha m a + have hA : 0 < A := PaperPolar.alpha_pos (by omega : 0 < m) ha ha1 + have hd : 0 < A+3 := by positivity + have hb := (le_div_iff₀ (by positivity : 0 < 3 + A)).mp + (b_le_alpha (by omega : 0 < m) ha ha1 hx0 hx1 hr) + have hy : (A+6)/(2*(A+3)) ≤ (1+c a x)/2 := by + apply (div_le_iff₀ (by positivity : 0 < 2*(A+3))).mpr + unfold c + nlinarith only [hb] + refine ⟨?_, hy⟩ + change (Real.sqrt (36+24*A)-6)/(2*A) < (A+6)/(2*(A+3)) + let g := (Real.sqrt (36+24*A)-6)/(2*A) + let y := (A+6)/(2*(A+3)) + have hs := Real.sq_sqrt (by positivity : 0 ≤ 36+24*A) + have hs0 := Real.sqrt_nonneg (36+24*A) + have hg0 : 0 ≤ g := by + dsimp [g] + apply div_nonneg _ (by positivity) + nlinarith only [hs, hs0, hA] + have hy0 : 0 ≤ y := by dsimp [y]; positivity + have hg : A*g^2+6*g-6 = 0 := by + dsimp [g] + field_simp + simp only [mul_comm A 24] + nlinarith only [hs] + have hypos : 0 < A*y^2+6*y-6 := by + dsimp [y] + rw [rational_quadratic hA] + positivity + change g < y + by_contra h + have hle : y ≤ g := le_of_not_gt h + have hp := mul_nonneg hA.le (mul_nonneg (sub_nonneg.mpr hle) (add_nonneg hg0 hy0)) + nlinarith only [hg, hypos, hp, hle] + +/-- EX01: the complete actual variance/mean-square and Gamma chains. -/ +theorem EX01 (q : Multiset ℂ) {μ : ℂ} {a x : ℝ} + (hm : 7 ≤ q.card) (ha : 0 < a) (ha1 : a < 1) + (hmean : q.sum = q.card * μ) (hq : ∀ z ∈ q, ‖z‖ ≤ 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hx : μ.re = x) (hr : RawPolar q.card a x) : + variance (q.map (fun z => z-μ)) / ‖μ‖^2 ≤ b a x / (1-b a x) ∧ + b a x / (1-b a x) ≤ alpha q.card a / 3 ∧ + Gamma (q.map (fun z => z-μ)) μ ≤ alpha q.card a / (3*((q.card : ℝ)-1)) ∧ + alpha q.card a / (3*((q.card : ℝ)-1)) < 7*(1-a)/18 := by + have hc : 0 < 1-b a x := by + have := b_lt_one (by omega : 0 < q.card) ha ha1 hx0 hx1 hr + linarith + have hs : 0 < ‖μ‖^2 := sq_pos_of_pos (norm_pos_iff.mpr + (PaperConsequences.mean_ne_zero_of_rawPolar hm ha ha1 hx0 hx1 hx hr)) + have hv := (PaperConsequences.centered_variance_le q μ (by omega) hmean hq).1 + have hn : 1-b a x ≤ ‖μ‖^2 := by + have hh := Complex.sq_norm_sub_sq_re μ + rw [hx] at hh + unfold b + nlinarith only [hh, sq_nonneg μ.im, sq_nonneg (x-a)] + have hratio : variance (q.map (fun z => z-μ)) / ‖μ‖^2 ≤ b a x / (1-b a x) := by + apply (div_le_div_iff₀ hs hc).mpr + have hh := mul_le_mul_of_nonneg_right hv hc.le + nlinarith only [hh, hn] + have hA := PaperPolar.alpha_pos (by omega : 0 < q.card) ha ha1 + have hb := (le_div_iff₀ (by positivity : 0 < 3+alpha q.card a)).mp + (b_le_alpha (by omega : 0 < q.card) ha ha1 hx0 hx1 hr) + have hbound : b a x / (1-b a x) ≤ alpha q.card a / 3 := by + apply (div_le_iff₀ hc).mpr + nlinarith only [hb] + have hm' : (7 : ℝ) ≤ q.card := by exact_mod_cast hm + have hd : 0 < (q.card : ℝ)-1 := by linarith + refine ⟨hratio, hbound, ?_, ?_⟩ + · unfold Gamma + rw [Multiset.card_map, mul_comm ((q.card : ℝ)-1), ← div_div] + exact (div_le_div_of_nonneg_right (hratio.trans hbound) hd.le).trans_eq (div_div _ _ _) + · apply (div_lt_iff₀ (by positivity : 0 < 3*((q.card : ℝ)-1))).mpr + unfold alpha + have hstrict : (q.card : ℝ)*(1-a^2) < 2*q.card*(1-a) := by + nlinarith only [mul_pos (show (0 : ℝ) < q.card by linarith) (sq_pos_of_pos (sub_pos.mpr ha1))] + have hscale := mul_nonneg (show 0 ≤ (q.card : ℝ)-7 by linarith) (sub_pos.mpr ha1).le + nlinarith only [hstrict, hscale] + +/-- EX02: conditional finite remainder closure; no assertion of the premise globally. -/ +theorem EX02 (q : Multiset ℂ) {μ : ℂ} {a x : ℝ} + (hm : 7 ≤ q.card) (ha : 0 < a) (ha1 : a < 1) + (hmean : q.sum = q.card * μ) (hq : ∀ z ∈ q, ‖z‖ ≤ 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hx : μ.re = x) (hr : RawPolar q.card a x) + (hfin : PaperCenteredBound.majorant_Efin (q.map (fun z => z - μ)) μ (a * μ) ≤ + (1 - a) / 2) : + Gamma (q.map (fun z => z-μ)) μ + + PaperCenteredBound.majorant_Efin (q.map (fun z => z-μ)) μ (a*μ) < 8*(1-a)/9 ∧ + 8*(1-a)/9 < 1-a ∧ 1-a ≤ 1-a*‖μ‖ ∧ + 1 < ‖(q.card+1 : ℂ) * + (∫ t in (0 : ℝ)..1, (q.map (fun z => 1-(a : ℂ)*t*z)).prod)‖ := by + have hg := PaperConsequences.Gamma_lt_seven_eighteenths q hm ha ha1 hmean hq hx0 hx1 hx hr + have hn := (PaperConsequences.centered_variance_le q μ (by omega) hmean hq).2 + refine ⟨by linarith, by linarith, ?_, ?_⟩ + · nlinarith only [mul_le_mul_of_nonneg_left hn ha.le] + · exact PaperConsequences.norm_J_gt_one_of_majorant_half q hm ha ha1 hmean hq hx0 hx1 hx hr hfin + +end Sendov.PaperMomentCorollaries diff --git a/Sendov/Analytic/PaperOriginCorollaries.lean b/Sendov/Analytic/PaperOriginCorollaries.lean new file mode 100644 index 0000000..142afa9 --- /dev/null +++ b/Sendov/Analytic/PaperOriginCorollaries.lean @@ -0,0 +1,279 @@ +import Sendov.Analytic.FirstOriginMargins +import Sendov.Analytic.Polar +import Sendov.Counterexample.Identities + +/-! Literal interfaces for first-origin report FO02--FO04. All integrals below +are the actual complex product/residual integrals, not abstract error budgets. -/ + +namespace Sendov.PaperOriginCorollaries +open MeasureTheory Polynomial + +/-- The signed complex residual appearing with a plus sign in FO02. -/ +noncomputable def residual (a : ℝ) (q : Multiset ℂ) : ℂ := + (a : ℂ) ^ 2 * ∫ t in (0 : ℝ)..1, + (t : ℂ) * sumEraseProdC q (fun v => v ^ 2) + (fun v => 1 - (a : ℂ) * (t : ℂ) * v) + +/-- FO02: the exact derivative decomposition. -/ +theorem derivative_decomposition (a t : ℝ) (q : Multiset ℂ) : + HasDerivAt (Fprod a q) + (-(a : ℂ) * q.sum * Fprod a q t - (a : ℂ) ^ 2 * (t : ℂ) * + sumEraseProdC q (fun v => v ^ 2) (fun v => 1 - (a : ℂ) * (t : ℂ) * v)) t := by + apply (hasDerivAt_Fprod a t q).congr_deriv + rw [sumEraseProdC_id_eq] + ring + +private theorem residual_eq (a : ℝ) (q : Multiset ℂ) (c : ℂ) + (hc : c = (a : ℂ) * q.sum) : + residual a q = -(∫ t in (0 : ℝ)..1, + (-(a : ℂ) * sumEraseProdC q id (fun v => 1 - (a : ℂ) * (t : ℂ) * v) + + c * Fprod a q t)) := by + have he : ∀ t : ℝ, + -(a : ℂ) * sumEraseProdC q id (fun v => 1 - (a : ℂ) * (t : ℂ) * v) + + c * Fprod a q t = + -((a : ℂ) ^ 2 * ((t : ℂ) * sumEraseProdC q (fun v => v ^ 2) + (fun v => 1 - (a : ℂ) * (t : ℂ) * v))) := by + intro t + rw [sumEraseProdC_id_eq, hc] + ring + simp_rw [he] + rw [intervalIntegral.integral_neg, intervalIntegral.integral_const_mul, neg_neg] + rfl + +/-- FO02: FTC with the actual complex residual and its correct sign. -/ +theorem integrated_residual_sum (a : ℝ) (q : Multiset ℂ) : + (1 : ℂ) = Fprod a q 1 + (a : ℂ) * q.sum * + (∫ t in (0 : ℝ)..1, Fprod a q t) + residual a q := by + let D : ℝ → ℂ := fun t => -(a : ℂ) * + sumEraseProdC q id (fun v => 1 - (a : ℂ) * (t : ℂ) * v) + have hDint : IntervalIntegrable D volume 0 1 := + (continuous_const.mul (continuous_sumEraseProdC a id q)).intervalIntegrable _ _ + have hFint := (continuous_Fprod a q).intervalIntegrable (μ := volume) 0 1 + have hFTC : ∫ t in (0 : ℝ)..1, D t = Fprod a q 1 - Fprod a q 0 := + intervalIntegral.integral_eq_sub_of_hasDerivAt + (fun t _ => hasDerivAt_Fprod a t q) hDint + rw [residual_eq a q ((a : ℂ) * q.sum) rfl] + change (1 : ℂ) = Fprod a q 1 + (a : ℂ) * q.sum * + (∫ t in (0 : ℝ)..1, Fprod a q t) + + -(∫ t in (0 : ℝ)..1, (D t + (a : ℂ) * q.sum * Fprod a q t)) + rw [intervalIntegral.integral_add hDint (hFint.const_mul _), + hFTC, Fprod_zero, intervalIntegral.integral_const_mul] + ring + +/-- FO02 in the paper's `m, μ, I` notation (`q.sum = m μ`). -/ +theorem integrated_residual {m : ℕ} {μ : ℂ} (a : ℝ) (q : Multiset ℂ) + (hsum : q.sum = (m : ℂ) * μ) : + (1 : ℂ) = Fprod a q 1 + (m : ℂ) * (a : ℂ) * μ * + (∫ t in (0 : ℝ)..1, Fprod a q t) + residual a q := by + have h := integrated_residual_sum a q + rw [hsum] at h + convert h using 1; ring + +/-- FO03: the norm of the actual residual, not merely a surrogate inequality. -/ +theorem residual_norm_bound {n : ℕ} (hn : 2 ≤ n) {a x y : ℝ} {q : Multiset ℂ} + (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) (ha0 : 0 ≤ a) + (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x) + (hsum : q.sum = ((n : ℂ) - 1) * ((x : ℂ) + (y : ℂ) * Complex.I)) : + ‖residual a q‖ ≤ a ^ 2 * ((n : ℝ) - 1) * + ∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2) := by + have hq0 : q ≠ 0 := by + intro h + simp [h] at hqcard + omega + set c : ℂ := ((n : ℂ) - 1) * (a : ℂ) * ((x : ℂ) + (y : ℂ) * Complex.I) with hc + set D : ℝ → ℂ := fun t => -(a : ℂ) * sumEraseProdC q id (fun v => 1 - (a : ℂ) * (t : ℂ) * v) + with hDdef + have hDcont : Continuous D := by + rw [hDdef] + exact continuous_const.mul (continuous_sumEraseProdC a id q) + have hFcont : Continuous (Fprod a q) := continuous_Fprod a q + have hDint : IntervalIntegrable D MeasureTheory.volume 0 1 := hDcont.intervalIntegrable _ _ + have hFint : IntervalIntegrable (Fprod a q) MeasureTheory.volume 0 1 := + hFcont.intervalIntegrable _ _ + have hexp : (0 : ℝ) ≤ ((n : ℝ) - 2) / 2 := by + have : (2 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn + linarith + have hRcont : Continuous fun t : ℝ => + a ^ 2 * ((n : ℝ) - 1) * (t ^ 1 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2)) := + continuous_const.mul (continuous_pow_mul_QQ (a * x) (a ^ 2) 1 hexp) + have hGnorm : ∀ t ∈ Set.Icc (0 : ℝ) 1, ‖D t + c * Fprod a q t‖ + ≤ a ^ 2 * ((n : ℝ) - 1) * (t ^ 1 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2)) := by + intro t ht + have h := norm_deriv_add_le hn hqcard hq0 hq1 ha0 ht.1 hx hsum (t := t) (y := y) + rw [hDdef, hc] + calc ‖-(a : ℂ) * sumEraseProdC q id (fun v => 1 - (a : ℂ) * (t : ℂ) * v) + + ((n : ℂ) - 1) * (a : ℂ) * ((x : ℂ) + (y : ℂ) * Complex.I) * Fprod a q t‖ + ≤ a ^ 2 * t * ((n : ℝ) - 1) * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2) := h + _ = a ^ 2 * ((n : ℝ) - 1) * (t ^ 1 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2)) := by ring + have hint : ‖∫ t in (0 : ℝ)..1, (D t + c * Fprod a q t)‖ + ≤ a ^ 2 * ((n : ℝ) - 1) + * ∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2) := by + refine (intervalIntegral.norm_integral_le_integral_norm (by norm_num : (0 : ℝ) ≤ 1)).trans ?_ + have hni : IntervalIntegrable (fun t : ℝ => ‖D t + c * Fprod a q t‖) + MeasureTheory.volume 0 1 := + (hDcont.add (continuous_const.mul hFcont)).norm.intervalIntegrable _ _ + have hri : IntervalIntegrable (fun t : ℝ => + a ^ 2 * ((n : ℝ) - 1) * (t ^ 1 * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2))) + MeasureTheory.volume 0 1 := hRcont.intervalIntegrable _ _ + have hmono := intervalIntegral.integral_mono_on (by norm_num : (0 : ℝ) ≤ 1) hni hri hGnorm + refine hmono.trans ?_ + rw [intervalIntegral.integral_const_mul] + simp + have hc' : c = (a : ℂ) * q.sum := by rw [hc, hsum]; ring + rw [residual_eq a q c hc', norm_neg] + exact hint + +/-- FO03 endpoint norm majorant. -/ +theorem endpoint_norm_bound {n : ℕ} (hn : 2 ≤ n) {a x : ℝ} {q : Multiset ℂ} + (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x) + (hβ : 0 ≤ QQ (a * x) (a ^ 2) 1) : + ‖Fprod a q 1‖ ≤ QQ (a * x) (a ^ 2) 1 ^ (((n : ℝ) - 1) / 2) := + FirstOriginSmall.norm_Fprod_le hn hqcard hq1 hx hβ + +/-- FO03 retains the actual J=(m+1)I. No first-origin upper bound is assumed. -/ +theorem norm_budget {m : ℕ} (hm : 1 ≤ m) {a x y : ℝ} {q : Multiset ℂ} + (ha : 0 ≤ a) (hx1 : x ≤ 1) + (hqcard : q.card = m) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = (m : ℝ) * x) + (hsum : q.sum = (m : ℂ) * ((x : ℂ) + (y : ℂ) * Complex.I)) : + 1 ≤ FirstOriginMargins.T (m : ℝ) a x + (m : ℝ) * a / ((m : ℝ) + 1) * + ‖((m : ℂ) + 1) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ := by + have hβ : 0 ≤ QQ (a * x) (a ^ 2) 1 := by + unfold QQ + nlinarith [sq_nonneg (1 - a), mul_nonneg ha (sub_nonneg.mpr hx1)] + have h := FirstOriginMargins.lower_budget_norm (n := m + 1) (by omega) ha + (by simpa using hqcard) hq1 (by simpa using hx) (by simpa using hsum) hβ + simpa [Nat.cast_add, Nat.cast_one, mul_comm a] using h + +/-- FO03 first-origin consumer, with the hypothesis on the actual J integral. -/ +theorem first_origin_budget {m : ℕ} (hm : 1 ≤ m) {a x y : ℝ} {q : Multiset ℂ} + (ha : 0 ≤ a) (hx1 : x ≤ 1) + (hqcard : q.card = m) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = (m : ℝ) * x) + (hsum : q.sum = (m : ℂ) * ((x : ℂ) + (y : ℂ) * Complex.I)) + (hfirst : ‖((m : ℂ) + 1) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ ≤ 1) : + 1 ≤ FirstOriginMargins.T (m : ℝ) a x + (m : ℝ) * a / ((m : ℝ) + 1) := by + have h := norm_budget hm ha hx1 hqcard hq1 hx hsum + have hcoef : 0 ≤ (m : ℝ) * a / ((m : ℝ) + 1) := by positivity + have hb := mul_le_mul_of_nonneg_left hfirst hcoef + linarith + +/-- FO02 with the actual mean `q.sum / m`, rather than a supplied mean. -/ +theorem integrated_residual_mean {m : ℕ} (hm : 1 ≤ m) (a : ℝ) (q : Multiset ℂ) + (hqcard : q.card = m) : + (1 : ℂ) = Fprod a q 1 + (m : ℂ) * (a : ℂ) * (q.sum / (m : ℂ)) * + (∫ t in (0 : ℝ)..1, Fprod a q t) + residual a q := by + have hm0 : (m : ℂ) ≠ 0 := by exact_mod_cast (show m ≠ 0 by omega) + apply integrated_residual + field_simp + +/-- FO03 in literal m-notation: residual and endpoint bounds together. -/ +theorem norm_majorants {m : ℕ} (hm : 1 ≤ m) {a x y : ℝ} {q : Multiset ℂ} + (ha : 0 ≤ a) (hx1 : x ≤ 1) + (hqcard : q.card = m) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = (m : ℝ) * x) + (hsum : q.sum = (m : ℂ) * ((x : ℂ) + (y : ℂ) * Complex.I)) : + (‖residual a q‖ ≤ (m : ℝ) * a ^ 2 * + ∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (((m : ℝ) - 1) / 2)) ∧ + (‖Fprod a q 1‖ ≤ QQ (a * x) (a ^ 2) 1 ^ ((m : ℝ) / 2)) := by + have hβ : 0 ≤ QQ (a * x) (a ^ 2) 1 := by + unfold QQ + nlinarith [sq_nonneg (1 - a), mul_nonneg ha (sub_nonneg.mpr hx1)] + constructor + · have h := residual_norm_bound (n := m + 1) (by omega) + (by simpa using hqcard) hq1 ha (by simpa using hx) (by simpa using hsum) + have he : (m : ℝ) + 1 - 2 = (m : ℝ) - 1 := by ring + simpa [Nat.cast_add, Nat.cast_one, he, mul_comm (a ^ 2)] using h + · simpa using endpoint_norm_bound (n := m + 1) (by omega) + (by simpa using hqcard) hq1 (by simpa using hx) hβ + +/-- FO04: the entire hierarchy from the actual polar and denominator identities. +In particular `1 ≤ ‖K‖` is proved, never required as a premise. -/ +theorem polar_hierarchy {n : ℕ} (hn : 2 ≤ n) {a x : ℝ} (ha : |a| ≤ 1) + {z q : Multiset ℂ} (hz : ∀ w ∈ z, ‖w‖ ≤ 1) + (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x) + (hpolar : q.prod * (z.map (fun w => 1 - (a : ℂ) * w)).prod + = (n : ℂ) * ∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod) + (hdenom : q.prod * (z.map (fun w => (a : ℂ) - w)).prod = (n : ℂ)) : + (1 ≤ ‖∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod‖) ∧ + (‖∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod‖ ≤ + ∫ t in (0 : ℝ)..1, + (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) ∧ + ((∫ t in (0 : ℝ)..1, + (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) ≤ + ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) := by + have hnpos : (0 : ℝ) < (n : ℝ) := by + have : (0 : ℕ) < n := by omega + exact_mod_cast this + -- the Möbius estimate, multiplied over the multiset + have hmob : (z.map (fun w => ‖(a : ℂ) - w‖)).prod + ≤ (z.map (fun w => ‖1 - (a : ℂ) * w‖)).prod := + prod_map_le_of_le (fun w hw => norm_sub_le_norm_one_sub_mul ha (hz w hw)) + -- take norms in the two identities + have h1 : (n : ℝ) = ‖q.prod‖ * (z.map (fun w => ‖(a : ℂ) - w‖)).prod := by + have := congrArg (fun w : ℂ => ‖w‖) hdenom + simpa [norm_mul, norm_prod_map] using this.symm + have h2 : ‖q.prod‖ * (z.map (fun w => ‖1 - (a : ℂ) * w‖)).prod + = (n : ℝ) * ‖∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod‖ := by + have := congrArg (fun w : ℂ => ‖w‖) hpolar + simpa [norm_mul, norm_prod_map] using this + -- so the integral has norm at least one + have h3 : (1 : ℝ) ≤ ‖∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod‖ := by + have hstep : (n : ℝ) ≤ (n : ℝ) * ‖∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod‖ := by + rw [← h2, h1] + exact mul_le_mul_of_nonneg_left hmob (norm_nonneg _) + exact (mul_le_mul_iff_right₀ hnpos).mp (by simpa only [mul_one] using hstep) + refine ⟨h3, ?_, ?_⟩ + · refine (intervalIntegral.norm_integral_le_integral_norm (by norm_num)).trans_eq ?_ + exact intervalIntegral.integral_congr (fun t _ => norm_prod_map q _) + · have he : (0 : ℝ) ≤ ((n : ℝ) - 1) / 2 := by + have : (2 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn + linarith + apply intervalIntegral.integral_mono_on (by norm_num) + ((continuous_prod_norm a q).intervalIntegrable _ _) + (((continuous_rpow_const he).comp (continuous_Ppolar a x)).intervalIntegrable _ _) + intro t _ + exact prod_norm_le_Ppolar hn hqcard hq1 hx + +/-- FO04 from polynomial root/derivative factorizations: both exact identities +and all three inequalities. No polar inequality is an input. -/ +theorem polar_factorization_hierarchy {n : ℕ} (hn : 2 ≤ n) {a x : ℝ} + (ha : |a| ≤ 1) (ha0 : a ≠ 0) (ha2 : a ^ 2 ≠ 1) + {c : ℂ} {p : ℂ[X]} {z q : Multiset ℂ} + (hc0 : c ≠ 0) (hzcard : z.card = n - 1) + (hz : ∀ w ∈ z, ‖w‖ ≤ 1) + (hqcard : q.card = n - 1) (hq0 : ∀ v ∈ q, v ≠ 0) + (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x) + (hpz : p = C c * ((X - C (a : ℂ)) * (z.map (fun w => X - C w)).prod)) + (hpq : derivative p = C ((n : ℂ) * c) * + ((q.map (fun v => (a : ℂ) - v⁻¹)).map (fun w => X - C w)).prod) : + (q.prod * (z.map (fun w => (a : ℂ) - w)).prod = (n : ℂ)) ∧ + (q.prod * (z.map (fun w => 1 - (a : ℂ) * w)).prod = + (n : ℂ) * ∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod) ∧ + (1 ≤ ‖∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod‖) ∧ + (‖∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod‖ ≤ + ∫ t in (0 : ℝ)..1, + (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) ∧ + ((∫ t in (0 : ℝ)..1, + (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) ≤ + ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) := by + have ha0C : (a : ℂ) ≠ 0 := by exact_mod_cast ha0 + have ha2C : (a : ℂ) ^ 2 ≠ 1 := by exact_mod_cast ha2 + have hpa : p.eval (a : ℂ) = 0 := by simp [hpz] + have hdenom := prod_sub_mul_prod hc0 hq0 hpz hpq + have hpolar := polar_identity hc0 ha0C ha2C hzcard hqcard hq0 hpa hpz hpq + exact ⟨hdenom, hpolar, polar_hierarchy hn ha hz hqcard hq1 hx hpolar hdenom⟩ + +end Sendov.PaperOriginCorollaries diff --git a/Sendov/Analytic/PaperRegionCorollaries.lean b/Sendov/Analytic/PaperRegionCorollaries.lean new file mode 100644 index 0000000..2ba7505 --- /dev/null +++ b/Sendov/Analytic/PaperRegionCorollaries.lean @@ -0,0 +1,310 @@ +import Sendov.Analytic.PaperConsequences +import Sendov.Analytic.PaperRateDetails + +/-! +# Literal region corollaries of the paper + +The eleven acceptance families are exported with the actual integral expression T. +All ray intervals are closed, so adjacent bands both apply at each seam. The +first ray starts at 1/5, including the full interval [1/5,2/5). +Only the paper's conditional bulk estimates retain a bulk hypothesis. +-/ +namespace Sendov.PaperRegionCorollaries + +open PaperPolar + +private lemma literal_budget (m : ℕ) (a x : ℝ) : + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) = + PaperTaylor.budget (m : ℝ) a x := by + simp only [PaperTaylor.budget, PaperTaylor.beta, mul_one, one_pow] + +/-- IN02: both finite two-end estimates, with exact denominators and endpoint rates. -/ +theorem in02_two_end {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + (((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) ≤ 100 * (m : ℝ) / + (9 * ((m : ℝ) + 1) * ((m : ℝ) + 3) * x ^ 2) + + 29 * (1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2)) ∧ + (((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) ≤ 16 * (m : ℝ) / + (((m : ℝ) + 1) * ((m : ℝ) + 3) * x ^ 2) + + 13 * (1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2)) := by + simp only [literal_budget] + obtain ⟨hax, hc⟩ := geometry hm ha ha1 hx0 hx1 hr + have hx : 0 < x := by linarith + have hc' : 0 < PaperTaylor.chord a x := by + rw [PaperUniform.chord_eq] + exact hc + have h₁ := PaperHistoricalBounds.total_le_A5 (m := (m : ℝ)) + (by exact_mod_cast hm) ha ha1 hx hx1 hc' + have h₂ := PaperHistoricalBounds.total_le_A5b (m := (m : ℝ)) + (by exact_mod_cast hm) ha ha1 hx hx1 hc' + rw [PaperTwoEnd.total_eq_budget ha] at h₁ h₂ + constructor + · simpa only [PaperTaylor.budget, PaperTaylor.beta, PaperTwoEnd.endpoint, + PaperTwoEnd.Q, mul_one, one_pow, mul_right_comm] using h₁ + · simpa only [PaperTaylor.budget, PaperTaylor.beta, PaperTwoEnd.endpoint, + PaperTwoEnd.Q, mul_one, one_pow, mul_right_comm] using h₂ + +/-- IN04: retain the original exponent at m=7,8; relax only from m=9. -/ +theorem in04_middle {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx : 0 < x) (hx1 : x ≤ 1) + (hxa : x < a) (hax : a < 3 * x / 2) : + (((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 4 / ((m : ℝ) * x ^ 2) + + (1 + 5 * ((m : ℝ) * x ^ 2) / 8) * + Real.exp (-3 * ((m : ℝ) - 1) * ((m : ℝ) * x ^ 2) / (8 * (m : ℝ)))) ∧ + (9 ≤ m → ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 4 / ((m : ℝ) * x ^ 2) + + (1 + 5 * ((m : ℝ) * x ^ 2) / 8) * Real.exp (-((m : ℝ) * x ^ 2) / 3)) := by + simp only [literal_budget] + have hm' : (7 : ℝ) ≤ m := by exact_mod_cast hm + have hm0 : (m : ℝ) ≠ 0 := by linarith + have ht := PaperTwoEnd.budget_lt_middle hm' ha ha1 hx hx1 hxa hax + change PaperTaylor.budget (m : ℝ) a x < _ ∧ + (9 ≤ m → PaperTaylor.budget (m : ℝ) a x < _) + constructor + · convert ht using 1; field_simp + · intro hm9 + have hm9' : (9 : ℝ) ≤ m := by exact_mod_cast hm9 + apply ht.trans_le + apply add_le_add le_rfl + rw [mul_assoc 5 (m : ℝ) (x ^ 2)] + apply mul_le_mul_of_nonneg_left _ (by positivity) + apply Real.exp_le_exp.mpr + nlinarith only [mul_nonneg (show 0 ≤ (m : ℝ) - 9 by linarith) (sq_nonneg x)] + +/-- NE05: the original lambda ≤ 3/10 margin. -/ +theorem ne05_near {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (hl : lambda m a ≤ 3 / 10) : + (1 - (m : ℝ) * a / ((m : ℝ) + 1)) - ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) > (1 - a) / 1000 := by + simp only [literal_budget] + exact PaperNearClosure.near_endpoint_D hm ha ha1 hx0 hx1 hr (by + change (m : ℝ) * (1 - a) ≤ 3 / 10 at hl + linarith) + +private lemma h_lt_B {m : ℕ} {a : ℝ} (ha : 0 < a) : + 1 - a < (1 - (m : ℝ) * a / ((m : ℝ) + 1)) := by + have hd : 0 < (m : ℝ) + 1 := by positivity + have he : (1 - (m : ℝ) * a / ((m : ℝ) + 1)) - (1 - a) = a / ((m : ℝ) + 1) := by field_simp; ring + have hp := div_pos ha hd + linarith + +/-- UN04: retained-radius rate, and the original conditional strict chain. -/ +theorem un04_bulk40 {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (ha2 : 2 / 5 ≤ a) : + (((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 40 / ((m : ℝ) * a ^ 2)) ∧ + (40 ≤ (m : ℝ) * a ^ 2 * (1 - a) → + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < + 1 - a ∧ 1 - a < (1 - (m : ℝ) * a / ((m : ℝ) + 1))) := by + simp only [literal_budget] + refine ⟨PaperHistoricalBounds.budget_lt_forty hm ha ha1 ha2 hx0 hx1 hr, ?_⟩ + intro hbulk + exact ⟨PaperHistoricalBounds.budget_lt_one_sub_of_bulk40 hm ha ha1 ha2 hx0 hx1 hr hbulk, + h_lt_B ha⟩ + +/-- UN05: the original degree-seven bulk theorem, including T < h < B. -/ +theorem un05_bulk116 {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (hbulk : 116 ≤ (m : ℝ) * a ^ 2 * (1 - a)) : + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < + 1 - a ∧ 1 - a < (1 - (m : ℝ) * a / ((m : ℝ) + 1)) := by + simp only [literal_budget] + exact ⟨PaperHistoricalBounds.budget_lt_one_sub_of_bulk116 hm ha ha1 hx0 hx1 hr hbulk, + h_lt_B ha⟩ + +/-- UN08: explicit all-a cutoff 512; no radius or ray restriction. -/ +theorem un08_all_a_512 {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < + (1 - (m : ℝ) * a / ((m : ℝ) + 1)) := by + simp only [literal_budget] + exact PaperConsequences.old_all_a_cutoff (M := 512) (by norm_num) + hm ha ha1 hx0 hx1 hr + +/-- UN09: explicit all-a cutoff 10000; no radius or ray restriction. -/ +theorem un09_all_a_10000 {m : ℕ} {a x : ℝ} (hm : 10000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < + (1 - (m : ℝ) * a / ((m : ℝ) + 1)) := by + simp only [literal_budget] + exact PaperConsequences.old_all_a_cutoff (M := 10000) (by norm_num) + hm ha ha1 hx0 hx1 hr + +/-- UN10: explicit all-a cutoff 100000; no radius or ray restriction. -/ +theorem un10_all_a_100000 {m : ℕ} {a x : ℝ} (hm : 100000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < + (1 - (m : ℝ) * a / ((m : ℝ) + 1)) := by + simp only [literal_budget] + exact PaperConsequences.old_all_a_cutoff (M := 100000) (by norm_num) + hm ha ha1 hx0 hx1 hr + +/-- UN11: explicit all-a cutoff 1000000; no radius or ray restriction. -/ +theorem un11_all_a_1000000 {m : ℕ} {a x : ℝ} (hm : 1000000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < + (1 - (m : ℝ) * a / ((m : ℝ) + 1)) := by + simp only [literal_budget] + exact PaperConsequences.old_all_a_cutoff (M := 1000000) (by norm_num) + hm ha ha1 hx0 hx1 hr + +/-- RA03: all four round5 upper bands, with the actual integral on the left. -/ +theorem ra03_scaled_upper {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + (lambda m a ∈ Set.Icc (1 / 5) (1) → + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 18 / (m : ℝ)) ∧ + (lambda m a ∈ Set.Icc (1) (10) → + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 33 / (m : ℝ)) ∧ + (lambda m a ∈ Set.Icc (10) (25) → + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 51 / (m : ℝ) + 1 / 4) ∧ + (lambda m a ∈ Set.Icc (25) (49) → + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 62 / (m : ℝ) + 2) := by + simp only [literal_budget] + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast hm + have half (hl : lambda m a ≤ 49) : x < 2 * a := by + exact (div_lt_one (by positivity : 0 < 2 * a)).mp + (PaperRayGeometry.halfpoint_mem hm ha ha1 hx0 hx1 hr hl).2 + refine ⟨?_, ?_, ?_, ?_⟩ + · intro hl + have hx := PaperRayGeometry.geometry_one hm ha ha1 hx0 hx1 hr hl.2 + have hb := (PaperRayGeometry.geometry_ten hm ha ha1 hx0 hx1 hr + (by linarith [hl.2])).1 + exact PaperTail.budget_region_one hm' ha ha1 hx hx1 (half (by linarith [hl.2])) + (by rw [PaperUniform.beta_one]; exact hb.le) + · intro hl + obtain ⟨hb, hx⟩ := PaperRayGeometry.geometry_ten hm ha ha1 hx0 hx1 hr hl.2 + exact PaperTail.budget_region_two hm' ha ha1 hx hx1 (half (by linarith [hl.2])) + (by rw [PaperUniform.beta_one]; exact hb.le) + · intro hl + obtain ⟨hb, hx⟩ := PaperRayGeometry.geometry_twentyfive hm ha ha1 hx0 hx1 hr hl.2 + exact PaperTail.budget_region_three hm' ha ha1 hx hx1 (half (by linarith [hl.2])) + (by rw [PaperUniform.beta_one]; exact hb.le) + · intro hl + obtain ⟨hb, hx⟩ := PaperRayGeometry.geometry_fortynine hm ha ha1 hx0 hx1 hr hl.2 + exact PaperTail.budget_region_four hm' ha ha1 hx hx1 (half hl.2) + (by rw [PaperUniform.beta_one]; exact hb.le) + +/-- The original second lower expression needs 31/25, not merely 6/5. -/ +private lemma product_five_original {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) (hl0 : 1 ≤ lambda m a) (hl1 : lambda m a ≤ 5) : + 31 / 25 ≤ (lambda m a + 1) * x ^ 2 := by + have hlpos : 0 ≤ lambda m a := by linarith + have hb := PaperRayGeometry.b_le_lambda (by omega) ha ha1 hx0 hx1 hr + have ha' := PaperRayGeometry.a_lower hm ha1 hl1 + norm_num at ha' + by_cases hl2 : lambda m a ≤ 2 + · have hb2 := hb.trans (rational_mono hlpos hl2) + norm_num at hb2 + have hx := PaperRayGeometry.x_lower_constant (by norm_num : (0 : ℝ) < 251 / 256) ha' + (by norm_num : (0 : ℝ) ≤ 2 / 5) hb2 + have hxs : 79 / 100 ≤ x := by norm_num at hx; linarith + have hx2 : (79 / 100 : ℝ) ^ 2 ≤ x ^ 2 := by nlinarith + have hmul := mul_nonneg (sq_nonneg x) (show 0 ≤ lambda m a - 1 by linarith) + nlinarith + · have hb5 := hb.trans (rational_mono hlpos hl1) + norm_num at hb5 + have hx := PaperRayGeometry.x_lower_constant (by norm_num : (0 : ℝ) < 251 / 256) ha' + (by norm_num : (0 : ℝ) ≤ 5 / 8) hb5 + have hxs : 17 / 25 ≤ x := by norm_num at hx; linarith + have hx2 : (17 / 25 : ℝ) ^ 2 ≤ x ^ 2 := by nlinarith + have hmul := mul_nonneg (sq_nonneg x) (show 0 ≤ lambda m a - 2 by linarith) + nlinarith + +/-- RA04: all five original rational lower bounds and their strict comparisons. +The first band uses RateDetails on the full [1/5,1], not the shortened [2/5,1]. -/ +theorem ra04_scaled_lower {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + (lambda m a ∈ Set.Icc (1 / 5) (1) → + 1 + 18 / (m : ℝ) < (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) ∧ + (lambda m a ∈ Set.Icc (1) (5) → + 1 + 33 / (m : ℝ) < (m : ℝ) / ((m : ℝ) + 1) * (1 + 6 / 25 - 24 / (m : ℝ)) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (1 + 6 / 25 - 24 / (m : ℝ)) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) ∧ + (lambda m a ∈ Set.Icc (5) (10) → + 1 + 33 / (m : ℝ) < (m : ℝ) / ((m : ℝ) + 1) * (6 * (7 / 12) ^ 2) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (6 * (7 / 12) ^ 2) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) ∧ + (lambda m a ∈ Set.Icc (10) (25) → + 1 + 51 / (m : ℝ) + 1 / 4 < (m : ℝ) / ((m : ℝ) + 1) * (11 * (231 / 512) ^ 2) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (11 * (231 / 512) ^ 2) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) ∧ + (lambda m a ∈ Set.Icc (25) (49) → + 1 + 62 / (m : ℝ) + 2 < (m : ℝ) / ((m : ℝ) + 1) * (26 * (207 / 512) ^ 2) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (26 * (207 / 512) ^ 2) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) := by + have hm' : (256 : ℝ) ≤ m := by exact_mod_cast hm + refine ⟨?_, ?_, ?_, ?_, ?_⟩ + · intro hl + exact ⟨PaperRay.ray_one hm', + PaperRateDetails.scaled_budget_paper_lower_one hm ha ha1 hx0 hx1 hr hl.1 hl.2⟩ + · intro hl + refine ⟨PaperRay.ray_two hm', PaperRayGeometry.scaled_budget_lower ?_⟩ + have hp := product_five_original hm ha ha1 hx0 hx1 hr hl.1 hl.2 + have hd : 0 ≤ 24 / (m : ℝ) := by positivity + linarith + · intro hl + refine ⟨PaperRay.ray_three hm', ?_⟩ + have hx := (PaperRayGeometry.geometry_ten hm ha ha1 hx0 hx1 hr hl.2).2 + simpa only [PaperRayGeometry.B, show (5 : ℝ) + 1 = 6 by norm_num] using + PaperRayGeometry.scaled_budget_lower_of_x hl.1 (by norm_num) + (by norm_num : (0 : ℝ) ≤ 7 / 12) hx.le + · intro hl + refine ⟨PaperRay.ray_four hm', ?_⟩ + have hx := (PaperRayGeometry.geometry_twentyfive hm ha ha1 hx0 hx1 hr hl.2).2 + simpa only [PaperRayGeometry.B, show (10 : ℝ) + 1 = 11 by norm_num] using + PaperRayGeometry.scaled_budget_lower_of_x hl.1 (by norm_num) + (by norm_num : (0 : ℝ) ≤ 231 / 512) hx.le + · intro hl + refine ⟨PaperRay.ray_five hm', ?_⟩ + have hx := (PaperRayGeometry.geometry_fortynine hm ha ha1 hx0 hx1 hr hl.2).2 + simpa only [PaperRayGeometry.B, show (25 : ℝ) + 1 = 26 by norm_num] using + PaperRayGeometry.scaled_budget_lower_of_x hl.1 (by norm_num) + (by norm_num : (0 : ℝ) ≤ 207 / 512) hx.le + +end Sendov.PaperRegionCorollaries diff --git a/docs/paper-formalization/modules.json b/docs/paper-formalization/modules.json index 39ed56c..0af0daa 100644 --- a/docs/paper-formalization/modules.json +++ b/docs/paper-formalization/modules.json @@ -1,6 +1,5 @@ { "baseline": "0a4e966c41e1287f92d305d3bad8e70c8c295dde", - "source_tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", "changed_seeds": [ "Sendov", "Sendov.Analytic.FirstOriginAlgebra", @@ -84,7 +83,14 @@ "tests.PaperTaylor", "tests.PaperTwoEndTests", "tests.PaperUniform", - "tests.PaperWideRaysTests" + "tests.PaperWideRaysTests", + "Sendov.Analytic.PaperOriginCorollaries", + "tests.PaperOriginCorollaries", + "Sendov.Analytic.PaperMomentCorollaries", + "tests.PaperMomentCorollaries", + "Sendov.Analytic.PaperRegionCorollaries", + "tests.PaperRegionCorollaries", + "tests.PaperAcceptance" ], "affected_modules_topological": [ "Sendov.Analytic.FirstOriginAlgebra", @@ -176,6 +182,23 @@ "tests.PaperTaylor", "tests.PaperTwoEndTests", "tests.PaperUniform", - "tests.PaperWideRaysTests" + "tests.PaperWideRaysTests", + "Sendov.Analytic.PaperOriginCorollaries", + "tests.PaperOriginCorollaries", + "Sendov.Analytic.PaperMomentCorollaries", + "tests.PaperMomentCorollaries", + "Sendov.Analytic.PaperRegionCorollaries", + "tests.PaperRegionCorollaries", + "tests.PaperAcceptance" + ], + "reviewed_base_source_tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "supplemental_modules": [ + "Sendov.Analytic.PaperOriginCorollaries", + "tests.PaperOriginCorollaries", + "Sendov.Analytic.PaperMomentCorollaries", + "tests.PaperMomentCorollaries", + "Sendov.Analytic.PaperRegionCorollaries", + "tests.PaperRegionCorollaries", + "tests.PaperAcceptance" ] } \ No newline at end of file diff --git a/scripts/verify_paper_results.py b/scripts/verify_paper_results.py index 7336334..893e3dc 100644 --- a/scripts/verify_paper_results.py +++ b/scripts/verify_paper_results.py @@ -34,10 +34,19 @@ def digest(path): config_digest = digest(config) +expected_gates = 0 for module in modules: source = TREE / Path(*module.split('.')).with_suffix('.lean') source_digest = digest(source) - for kernel in [False, True]: + # leanchecker targets are namespace prefixes. An import-only umbrella has + # no declarations to replay, and passing it would replay every descendant. + import_only = all(not line.strip() or line.startswith('import ') + for line in source.read_text().splitlines()) + checks = [False] if import_only else [False, True] + expected_gates += len(checks) + if import_only: + print(module, 'IMPORT_ONLY: no local kernel declarations', flush=True) + for kernel in checks: previous = accepted.get((module, kernel)) if previous and previous['exit_code'] == 0: assert previous['source_sha256'] == source_digest, 'source changed; use a new tag' @@ -62,6 +71,6 @@ def digest(path): if result.returncode: print(result.stdout + result.stderr, flush=True) raise SystemExit(result.returncode) -assert len(rows) == 2 * len(modules) +assert len(rows) == expected_gates result_file.write_text(json.dumps(rows, indent=2)) print(f'PASS: {len(modules)} affected modules, {len(rows)} compile/kernel gates', flush=True) diff --git a/tests/PaperAcceptance.lean b/tests/PaperAcceptance.lean new file mode 100644 index 0000000..64e7f4a --- /dev/null +++ b/tests/PaperAcceptance.lean @@ -0,0 +1,295 @@ +import Sendov.Analytic.FirstOriginAlgebra +import Sendov.Analytic.FirstOriginBounds +import Sendov.Analytic.FirstOriginBudget +import Sendov.Analytic.FirstOriginMargins +import Sendov.Analytic.FirstOriginSmall +import Sendov.Analytic.Origin +import Sendov.Analytic.PaperBulkAlgebra +import Sendov.Analytic.PaperCentered +import Sendov.Analytic.PaperCenteredBound +import Sendov.Analytic.PaperCoefficient +import Sendov.Analytic.PaperConsequences +import Sendov.Analytic.PaperGlobalPolar +import Sendov.Analytic.PaperHistoricalBounds +import Sendov.Analytic.PaperLaplace +import Sendov.Analytic.PaperMomentCorollaries +import Sendov.Analytic.PaperNear +import Sendov.Analytic.PaperNearMargins +import Sendov.Analytic.PaperOriginCorollaries +import Sendov.Analytic.PaperPolar +import Sendov.Analytic.PaperRateDetails +import Sendov.Analytic.PaperRayGeometry +import Sendov.Analytic.PaperRegionCorollaries +import Sendov.Analytic.PaperSecant +import Sendov.Analytic.PaperTail +import Sendov.Analytic.PaperTaylor +import Sendov.Analytic.PaperTwoEnd +import Sendov.Analytic.PaperUniform +import Sendov.Analytic.PaperWideRays +import Sendov.Analytic.Polar +import Sendov.Boundary +import Sendov.Collinear.Balance +import Sendov.Collinear.Diameter +import Sendov.Collinear.Gate +import Sendov.Collinear.Mass +import Sendov.Collinear.Moment +import Sendov.Conjecture +import Sendov.Counterexample.Identities +import Sendov.Reduction.Setup +import scripts.axioms +import tests.BoundaryProbe +import tests.CollinearRound2Tests +import tests.PaperCenteredHundred +import tests.PaperConjugateBudgets +import tests.PaperLegacyCertificates +import tests.PaperPolarCounterexample +import tests.PaperPolarDomainWitnesses +import tests.PaperSecantNeighborhoods +import tests.PaperSecantTests + +/-! Complete named declaration existence and transitive axiom audit. +Anonymous examples are checked by their imported compiled test modules. -/ + +#sendov_axioms Collinear.adjacent_gap_unique +#sendov_axioms Collinear.derivative_root_budget +#sendov_axioms Collinear.diameter_moment +#sendov_axioms Collinear.diameter_reciprocal +#sendov_axioms Collinear.new_critical_point_gap +#sendov_axioms Collinear.reciprocal_balance +#sendov_axioms Collinear.reciprocal_decomposition +#sendov_axioms Collinear.signed_reciprocal_domination +#sendov_axioms Collinear.two_sided_mass +#sendov_axioms Sendov.FirstOriginBudget.lower_budget +#sendov_axioms Sendov.FirstOriginBudget.near_contradiction +#sendov_axioms Sendov.FirstOriginMargins.A5_lower +#sendov_axioms Sendov.FirstOriginMargins.A6_lower +#sendov_axioms Sendov.FirstOriginMargins.lower_budget_norm +#sendov_axioms Sendov.FirstOriginMargins.norm_J_seven +#sendov_axioms Sendov.FirstOriginMargins.norm_J_six +#sendov_axioms Sendov.FirstOriginMargins.upper_five_gap_identity +#sendov_axioms Sendov.FirstOriginMargins.upper_six_gap_identity +#sendov_axioms Sendov.FirstOriginSmall.B_five_halves +#sendov_axioms Sendov.FirstOriginSmall.Ppolar_nonneg_small +#sendov_axioms Sendov.FirstOriginSmall.Q_lower +#sendov_axioms Sendov.FirstOriginSmall.direct_budget_five +#sendov_axioms Sendov.FirstOriginSmall.direct_budget_six +#sendov_axioms Sendov.FirstOriginSmall.fifth_sixth_majorant +#sendov_axioms Sendov.FirstOriginSmall.first_origin_polar_six_seven +#sendov_axioms Sendov.FirstOriginSmall.five_halves_majorant +#sendov_axioms Sendov.FirstOriginSmall.norm_Fprod_le +#sendov_axioms Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_factorization +#sendov_axioms Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_first_origin +#sendov_axioms Sendov.FirstOriginSmall.norm_sum_le_card +#sendov_axioms Sendov.FirstOriginSmall.polar_cube_integral +#sendov_axioms Sendov.FirstOriginSmall.polar_mean_gt_half_add_one +#sendov_axioms Sendov.FirstOriginSmall.upper_five_gap +#sendov_axioms Sendov.FirstOriginSmall.upper_six_gap +#sendov_axioms Sendov.PaperBulk.large_ray_budget +#sendov_axioms Sendov.PaperBulk.middle_budget +#sendov_axioms Sendov.PaperCentered.H_top +#sendov_axioms Sendov.PaperCentered.centered_integral +#sendov_axioms Sendov.PaperCentered.centered_product +#sendov_axioms Sendov.PaperCentered.coeff_one +#sendov_axioms Sendov.PaperCentered.coeff_two +#sendov_axioms Sendov.PaperCentered.finite_beta +#sendov_axioms Sendov.PaperCentered.norm_kappa_le_variance +#sendov_axioms Sendov.PaperCentered.second_order +#sendov_axioms Sendov.PaperCentered.two_mul_esymm_two +#sendov_axioms Sendov.PaperCenteredBound.C_budget +#sendov_axioms Sendov.PaperCenteredBound.coeff_top_suppression +#sendov_axioms Sendov.PaperCenteredBound.majorant_Efin +#sendov_axioms Sendov.PaperCenteredBound.majorant_top_suppression +#sendov_axioms Sendov.PaperCenteredBound.norm_epsilon_le_majorant_Efin +#sendov_axioms Sendov.PaperCenteredBound.norm_esymm_le_C +#sendov_axioms Sendov.PaperCenteredHundred.diagnostic_DI02 +#sendov_axioms Sendov.PaperCenteredHundred.pointwise +#sendov_axioms Sendov.PaperCoefficient.esymm_eq_zero_of_variance_eq_zero +#sendov_axioms Sendov.PaperCoefficient.norm_esymm_card_sq_le +#sendov_axioms Sendov.PaperCoefficient.norm_esymm_sq_le_optimized +#sendov_axioms Sendov.PaperCoefficient.sum_norm_add_sq +#sendov_axioms Sendov.PaperConjugate.Budgets.DI03_closed +#sendov_axioms Sendov.PaperConjugate.Budgets.DI04_closed +#sendov_axioms Sendov.PaperConjugate.Budgets.DI05_closed +#sendov_axioms Sendov.PaperConjugate.Budgets.DI06_closed +#sendov_axioms Sendov.PaperConjugate.Budgets.DI07_closed +#sendov_axioms Sendov.PaperConsequences.Gamma_lt_seven_eighteenths +#sendov_axioms Sendov.PaperConsequences.U1_limit_lt_one +#sendov_axioms Sendov.PaperConsequences.U1_zero +#sendov_axioms Sendov.PaperConsequences.centered_variance_le +#sendov_axioms Sendov.PaperConsequences.exists_small_radius_not_rawPolar +#sendov_axioms Sendov.PaperConsequences.limiting_exponential_model +#sendov_axioms Sendov.PaperConsequences.moment_ge_degree_of_root_distance_product +#sendov_axioms Sendov.PaperConsequences.norm_J_gt_one_of_majorant_half +#sendov_axioms Sendov.PaperConsequences.old_all_a_cutoff +#sendov_axioms Sendov.PaperConsequences.root_distance_product_identity +#sendov_axioms Sendov.PaperConsequences.tendsto_U1_zero_right +#sendov_axioms Sendov.PaperConsequences.variance_ratio_le_alpha +#sendov_axioms Sendov.PaperGlobalPolar.endpoint_le +#sendov_axioms Sendov.PaperGlobalPolar.integral_chord +#sendov_axioms Sendov.PaperGlobalPolar.log_mul_delta_le +#sendov_axioms Sendov.PaperGlobalPolar.log_mul_div_delta +#sendov_axioms Sendov.PaperGlobalPolar.raw_integral_le_chord +#sendov_axioms Sendov.PaperGlobalPolar.three_fifths_lt_c +#sendov_axioms Sendov.PaperHistoricalBounds.budget_lt_forty +#sendov_axioms Sendov.PaperHistoricalBounds.budget_lt_one_sub_of_bulk116 +#sendov_axioms Sendov.PaperHistoricalBounds.budget_lt_one_sub_of_bulk40 +#sendov_axioms Sendov.PaperHistoricalBounds.budget_lt_three_fifths +#sendov_axioms Sendov.PaperHistoricalBounds.total_le_A5 +#sendov_axioms Sendov.PaperHistoricalBounds.total_le_A5b +#sendov_axioms Sendov.PaperLaplace.budget_le +#sendov_axioms Sendov.PaperLaplace.sharp_laplace +#sendov_axioms Sendov.PaperLegacyCertificates.all_feasible_D +#sendov_axioms Sendov.PaperLegacyCertificates.exact_source_parameters +#sendov_axioms Sendov.PaperLegacyCertificates.full_threshold_bracket +#sendov_axioms Sendov.PaperLegacyCertificates.hundred_complete +#sendov_axioms Sendov.PaperLegacyCertificates.legacy_complete +#sendov_axioms Sendov.PaperLegacyCertificates.legacy_three_fifths +#sendov_axioms Sendov.PaperLegacyCertificates.raw_threshold_bracket +#sendov_axioms Sendov.PaperLegacyCertificates.rejected_full_polar +#sendov_axioms Sendov.PaperLegacyCertificates.rejected_not_raw +#sendov_axioms Sendov.PaperLegacyCertificates.twenty_complete +#sendov_axioms Sendov.PaperMomentCorollaries.EX01 +#sendov_axioms Sendov.PaperMomentCorollaries.EX02 +#sendov_axioms Sendov.PaperMomentCorollaries.FO05 +#sendov_axioms Sendov.PaperMomentCorollaries.FO06 +#sendov_axioms Sendov.PaperMomentCorollaries.FO06_five +#sendov_axioms Sendov.PaperMomentCorollaries.FO06_six +#sendov_axioms Sendov.PaperMomentCorollaries.PO01 +#sendov_axioms Sendov.PaperMomentCorollaries.PO07 +#sendov_axioms Sendov.PaperMomentCorollaries.PO09 +#sendov_axioms Sendov.PaperNearClosure.near_endpoint_D +#sendov_axioms Sendov.PaperNearMargins.near_endpoint_one_fifth +#sendov_axioms Sendov.PaperNearMargins.near_endpoint_one_fiftieth +#sendov_axioms Sendov.PaperNearMargins.near_endpoint_one_hundredth +#sendov_axioms Sendov.PaperNearMargins.near_endpoint_one_tenth +#sendov_axioms Sendov.PaperOriginCorollaries.derivative_decomposition +#sendov_axioms Sendov.PaperOriginCorollaries.first_origin_budget +#sendov_axioms Sendov.PaperOriginCorollaries.integrated_residual +#sendov_axioms Sendov.PaperOriginCorollaries.integrated_residual_mean +#sendov_axioms Sendov.PaperOriginCorollaries.norm_budget +#sendov_axioms Sendov.PaperOriginCorollaries.norm_majorants +#sendov_axioms Sendov.PaperOriginCorollaries.polar_factorization_hierarchy +#sendov_axioms Sendov.PaperOriginCorollaries.polar_hierarchy +#sendov_axioms Sendov.PaperPolar.Counterexample.full_polar +#sendov_axioms Sendov.PaperPolar.Counterexample.mean_q +#sendov_axioms Sendov.PaperPolar.Counterexample.norm_q +#sendov_axioms Sendov.PaperPolar.Counterexample.not_universal_mean_half +#sendov_axioms Sendov.PaperPolar.DomainWitnesses.K_64_exact +#sendov_axioms Sendov.PaperPolar.DomainWitnesses.Nonroot.convex_hull_nonroot +#sendov_axioms Sendov.PaperPolar.DomainWitnesses.Nonroot.critical_multiplicities +#sendov_axioms Sendov.PaperPolar.DomainWitnesses.Nonroot.critical_roots +#sendov_axioms Sendov.PaperPolar.DomainWitnesses.Nonroot.nearest_critical_distance +#sendov_axioms Sendov.PaperPolar.DomainWitnesses.Nonroot.reciprocal_square_exact +#sendov_axioms Sendov.PaperPolar.DomainWitnesses.Nonroot.reciprocal_square_lt_nine +#sendov_axioms Sendov.PaperPolar.DomainWitnesses.Nonroot.root_geometry +#sendov_axioms Sendov.PaperPolar.DomainWitnesses.domain_64 +#sendov_axioms Sendov.PaperPolar.DomainWitnesses.mean_q10 +#sendov_axioms Sendov.PaperPolar.DomainWitnesses.neighborhood_10 +#sendov_axioms Sendov.PaperPolar.DomainWitnesses.neighborhood_7 +#sendov_axioms Sendov.PaperPolar.DomainWitnesses.not_polar_implies_alpha17 +#sendov_axioms Sendov.PaperPolar.b_le_alpha +#sendov_axioms Sendov.PaperPolar.b_lt_one +#sendov_axioms Sendov.PaperPolar.b_pos +#sendov_axioms Sendov.PaperPolar.c_lower_bound +#sendov_axioms Sendov.PaperPolar.endpoint_bounds +#sendov_axioms Sendov.PaperPolar.geometry +#sendov_axioms Sendov.PaperPolar.integral_le_exp +#sendov_axioms Sendov.PaperPolar.one_le_integral_exp +#sendov_axioms Sendov.PaperRateDetails.endpoint_delta_rate +#sendov_axioms Sendov.PaperRateDetails.scaled_budget_lower_one +#sendov_axioms Sendov.PaperRateDetails.scaled_budget_paper_lower_one +#sendov_axioms Sendov.PaperRateDetails.small_a_ratio_10000 +#sendov_axioms Sendov.PaperRateDetails.small_a_ratio_100000 +#sendov_axioms Sendov.PaperRayGeometry.budget_lower_five +#sendov_axioms Sendov.PaperRayGeometry.budget_lower_fortynine +#sendov_axioms Sendov.PaperRayGeometry.budget_lower_ten +#sendov_axioms Sendov.PaperRayGeometry.budget_lower_twentyfive +#sendov_axioms Sendov.PaperRayGeometry.geometry_fortynine +#sendov_axioms Sendov.PaperRayGeometry.geometry_one +#sendov_axioms Sendov.PaperRayGeometry.geometry_ten +#sendov_axioms Sendov.PaperRayGeometry.geometry_twentyfive +#sendov_axioms Sendov.PaperRayGeometry.halfpoint_mem +#sendov_axioms Sendov.PaperRegionCorollaries.in02_two_end +#sendov_axioms Sendov.PaperRegionCorollaries.in04_middle +#sendov_axioms Sendov.PaperRegionCorollaries.ne05_near +#sendov_axioms Sendov.PaperRegionCorollaries.ra03_scaled_upper +#sendov_axioms Sendov.PaperRegionCorollaries.ra04_scaled_lower +#sendov_axioms Sendov.PaperRegionCorollaries.un04_bulk40 +#sendov_axioms Sendov.PaperRegionCorollaries.un05_bulk116 +#sendov_axioms Sendov.PaperRegionCorollaries.un08_all_a_512 +#sendov_axioms Sendov.PaperRegionCorollaries.un09_all_a_10000 +#sendov_axioms Sendov.PaperRegionCorollaries.un10_all_a_100000 +#sendov_axioms Sendov.PaperRegionCorollaries.un11_all_a_1000000 +#sendov_axioms Sendov.PaperSecant.Neighborhoods.D_10_interval +#sendov_axioms Sendov.PaperSecant.Neighborhoods.D_7_interval +#sendov_axioms Sendov.PaperSecant.Neighborhoods.gate_10_interval +#sendov_axioms Sendov.PaperSecant.Neighborhoods.gate_7_interval +#sendov_axioms Sendov.PaperSecant.R_half_le_V0 +#sendov_axioms Sendov.PaperSecant.R_mono +#sendov_axioms Sendov.PaperSecant.R_one +#sendov_axioms Sendov.PaperSecant.R_secant +#sendov_axioms Sendov.PaperSecant.S_bounds +#sendov_axioms Sendov.PaperSecant.Tests.gate_10_nine_tenths +#sendov_axioms Sendov.PaperSecant.Tests.gate_16_nine_tenths_negative +#sendov_axioms Sendov.PaperSecant.Tests.gate_7_four_fifths +#sendov_axioms Sendov.PaperSecant.Tests.gate_8_nine_tenths +#sendov_axioms Sendov.PaperSecant.Tests.linear_simplification_fails +#sendov_axioms Sendov.PaperSecant.Tests.raw_feasible_at_negative_gate +#sendov_axioms Sendov.PaperSecant.V0_lt_one +#sendov_axioms Sendov.PaperSecant.V0_pos +#sendov_axioms Sendov.PaperSecant.budget_S_le_Wsec +#sendov_axioms Sendov.PaperSecant.budget_antitone +#sendov_axioms Sendov.PaperSecant.gate_denominators_pos +#sendov_axioms Sendov.PaperSecant.gate_implies_D +#sendov_axioms Sendov.PaperSecant.one_le_U1 +#sendov_axioms Sendov.PaperSecant.plain_secant_le_S +#sendov_axioms Sendov.PaperSecant.raw_implies_secant +#sendov_axioms Sendov.PaperTail.budget_region_four +#sendov_axioms Sendov.PaperTail.budget_region_one +#sendov_axioms Sendov.PaperTail.budget_region_three +#sendov_axioms Sendov.PaperTail.budget_region_two +#sendov_axioms Sendov.PaperTail.middle_tail +#sendov_axioms Sendov.PaperTail.tail_four_fifths +#sendov_axioms Sendov.PaperTail.tail_nine_tenths +#sendov_axioms Sendov.PaperTail.tail_twenty_three_twenty_fifths +#sendov_axioms Sendov.PaperTaylor.budget_le +#sendov_axioms Sendov.PaperTaylor.finite_taylor_budget +#sendov_axioms Sendov.PaperTwoEnd.budget_lt_middle +#sendov_axioms Sendov.PaperTwoEnd.budget_lt_separated +#sendov_axioms Sendov.PaperTwoEnd.left_le +#sendov_axioms Sendov.PaperTwoEnd.left_lt +#sendov_axioms Sendov.PaperTwoEnd.total_eq_budget +#sendov_axioms Sendov.PaperUniform.beta_one +#sendov_axioms Sendov.PaperUniform.budget_lt_retained +#sendov_axioms Sendov.PaperUniform.budget_lt_two_thirds +#sendov_axioms Sendov.PaperUniform.uniform_D +#sendov_axioms Sendov.PaperWideRays.HI01 +#sendov_axioms Sendov.PaperWideRays.HI02 +#sendov_axioms Sendov.PaperWideRays.HI03 +#sendov_axioms Sendov.PaperWideRays.HI03_small_five +#sendov_axioms Sendov.PaperWideRays.HI03_small_one +#sendov_axioms Sendov.all_eq_one_of_sum_norm_sq_le_card +#sendov_axioms Sendov.all_q_eq_one_of_sum_norm_sq_le +#sendov_axioms Sendov.boundary_reciprocal +#sendov_axioms Sendov.continuous_Fprod +#sendov_axioms Sendov.continuous_Ppolar +#sendov_axioms Sendov.first_origin_identity +#sendov_axioms Sendov.half_le_re_inv_one_sub +#sendov_axioms Sendov.hasDerivAt_Fprod +#sendov_axioms Sendov.norm_deriv_add_le +#sendov_axioms Sendov.norm_prod_map +#sendov_axioms Sendov.norm_sub_le_norm_one_sub_mul +#sendov_axioms Sendov.one_le_integral_Ppolar +#sendov_axioms Sendov.one_le_integral_prod_norm +#sendov_axioms Sendov.one_le_tri +#sendov_axioms Sendov.phelps_rodriguez +#sendov_axioms Sendov.polar_identity +#sendov_axioms Sendov.prod_map_le_of_le +#sendov_axioms Sendov.prod_norm_le_Ppolar +#sendov_axioms Sendov.prod_sub_mul_prod +#sendov_axioms Sendov.rubinstein_one +#sendov_axioms Sendov.sendov +#sendov_axioms Sendov.sendov_boundary_one +#sendov_axioms Sendov.sumEraseProdC_id_eq +#sendov_axioms Sendov.sum_norm_sq_le_card +#sendov_axioms Sendov.sum_norm_sub_one_sq diff --git a/tests/PaperMomentCorollaries.lean b/tests/PaperMomentCorollaries.lean new file mode 100644 index 0000000..bc0556f --- /dev/null +++ b/tests/PaperMomentCorollaries.lean @@ -0,0 +1,98 @@ +import Sendov.Analytic.PaperMomentCorollaries + +/-! Compiled signatures and regression contracts for the seven paper families. -/ +noncomputable section +open Sendov Sendov.PaperPolar Sendov.PaperCentered Sendov.PaperMomentCorollaries + +#check Sendov.PaperMomentCorollaries.FO05 +#check Sendov.PaperMomentCorollaries.FO06_six +#check Sendov.PaperMomentCorollaries.FO06_five +#check Sendov.PaperMomentCorollaries.FO06 +#check Sendov.PaperMomentCorollaries.PO01 +#check Sendov.PaperMomentCorollaries.PO07 +#check Sendov.PaperMomentCorollaries.PO09 +#check Sendov.PaperMomentCorollaries.EX01 +#check Sendov.PaperMomentCorollaries.EX02 + +#print axioms Sendov.PaperMomentCorollaries.FO05 +#print axioms Sendov.PaperMomentCorollaries.FO06_six +#print axioms Sendov.PaperMomentCorollaries.FO06_five +#print axioms Sendov.PaperMomentCorollaries.FO06 +#print axioms Sendov.PaperMomentCorollaries.PO01 +#print axioms Sendov.PaperMomentCorollaries.PO07 +#print axioms Sendov.PaperMomentCorollaries.PO09 +#print axioms Sendov.PaperMomentCorollaries.EX01 +#print axioms Sendov.PaperMomentCorollaries.EX02 + +namespace Sendov.PaperMomentCorollariesTests + +/-- The disk bound is closed: unit points and s=1 are admitted. -/ +theorem unit_mean : mean ({(1 : ℂ)} : Multiset ℂ) = 1 := by simp [mean] +theorem unit_secondMoment : secondMoment ({(1 : ℂ)} : Multiset ℂ) = 1 := by + simp [secondMoment] + +/-- The variance is the actual centered moment, not a scalar supplied in a premise. -/ +theorem actual_variance (q : Multiset ℂ) (hm : 0 < q.card) (hq : ∀ z ∈ q, ‖z‖ ≤ 1) : + variance (q.map (fun z => z - q.sum / (q.card : ℂ))) = + (q.map (fun z => ‖z‖ ^ 2)).sum / (q.card : ℝ) - ‖q.sum / (q.card : ℂ)‖ ^ 2 := + (FO05 q hm hq).2.2.1 + +/-- Both deficits use precisely the raw natural degree exponent m/2. -/ +theorem raw_deficits {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) + (hx0 : -1 ≤ x) (hx : x ≤ (1 + a) / 2) : + (∫ t in (0 : ℝ)..1, Ppolar a x t ^ ((5 : ℕ) / (2 : ℝ))) ≤ + 1 - 23 * (1 - a) ^ 2 / 42 ∧ + (∫ t in (0 : ℝ)..1, Ppolar a x t ^ ((6 : ℕ) / (2 : ℝ))) ≤ + 1 - 23 * (1 - a) ^ 2 / 35 := by + constructor + · exact FO06_five ha.le ha1.le hx0 hx + · norm_num [Real.rpow_natCast] + exact FO06_six ha.le ha1.le hx0 hx + +theorem degree_five_mean {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) + (hr : RawPolar 5 a x) : (1 + a) / 2 < x := FO06 (Or.inl rfl) ha ha1 hx0 hr + +theorem degree_six_mean {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) + (hr : RawPolar 6 a x) : (1 + a) / 2 < x := FO06 (Or.inr rfl) ha ha1 hx0 hr + +/-- Regression below seven: no invocation of the restricted geometry API. -/ +theorem degree_one_geometry {a x : ℝ} (ha : 0 < a) (ha1 : a < 1) + (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar 1 a x) : + a / 2 < x ∧ 0 < c a x ∧ c a x < 1 ∧ 0 < b a x ∧ b a x < 1 := + PO01 (by norm_num) ha ha1 hx0 hx1 hr + +/-- PO07 is uniform in natural degree, and retains the full quadratic y factor. -/ +theorem y_chain {m : ℕ} {a x : ℝ} (hm : 1 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar m a x) : + 1 - (1 + c a x) / 2 ≤ alpha m a * ((1 + c a x) / 2) ^ 2 / 6 ∧ + alpha m a * ((1 + c a x) / 2) ^ 2 / 6 ≤ + lambda m a * ((1 + c a x) / 2) ^ 2 / 6 ∧ + 1 - x ≤ lambda m a / (6 * a) := PO07 hm ha ha1 hx0 hx1 hr + +/-- Strictness is retained, not weakened to a non-strict root comparison. -/ +theorem strict_gaussian {m : ℕ} {a x : ℝ} (hm : 1 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar m a x) : + (Real.sqrt (36 + 24 * alpha m a) - 6) / (2 * alpha m a) < + (alpha m a + 6) / (2 * (alpha m a + 3)) := (PO09 hm ha ha1 hx0 hx1 hr).1 + +/-- EX01 accepts the actual arithmetic mean without an independent mean assumption. -/ +theorem actual_ratio (q : Multiset ℂ) {a : ℝ} (hm : 7 ≤ q.card) + (ha : 0 < a) (ha1 : a < 1) (hq : ∀ z ∈ q, ‖z‖ ≤ 1) + (hx0 : -1 ≤ (mean q).re) (hx1 : (mean q).re ≤ 1) + (hr : RawPolar q.card a (mean q).re) : + variance (q.map (fun z => z - mean q)) / ‖mean q‖ ^ 2 ≤ + b a (mean q).re / (1 - b a (mean q).re) := + (EX01 q hm ha ha1 (mean_spec q (by omega)) hq hx0 hx1 rfl hr).1 + +/-- EX02's conditional hypothesis remains exactly the actual finite majorant. -/ +theorem conditional_norm (q : Multiset ℂ) {a : ℝ} (hm : 7 ≤ q.card) + (ha : 0 < a) (ha1 : a < 1) (hq : ∀ z ∈ q, ‖z‖ ≤ 1) + (hx0 : -1 ≤ (mean q).re) (hx1 : (mean q).re ≤ 1) + (hr : RawPolar q.card a (mean q).re) + (hfin : PaperCenteredBound.majorant_Efin (q.map (fun z => z - mean q)) + (mean q) (a * mean q) ≤ (1 - a) / 2) : + 1 < ‖(q.card + 1 : ℂ) * + (∫ t in (0 : ℝ)..1, (q.map (fun z => 1 - (a : ℂ) * t * z)).prod)‖ := + (EX02 q hm ha ha1 (mean_spec q (by omega)) hq hx0 hx1 rfl hr hfin).2.2.2 + +end Sendov.PaperMomentCorollariesTests diff --git a/tests/PaperOriginCorollaries.lean b/tests/PaperOriginCorollaries.lean new file mode 100644 index 0000000..138c619 --- /dev/null +++ b/tests/PaperOriginCorollaries.lean @@ -0,0 +1,118 @@ +import Sendov.Analytic.PaperOriginCorollaries + +namespace Sendov.PaperOriginCorollariesTests +open MeasureTheory Polynomial PaperOriginCorollaries + +-- Test the literal derivative with mμ, including the negative residual sign. +example {m : ℕ} {μ : ℂ} (a t : ℝ) (q : Multiset ℂ) + (hsum : q.sum = (m : ℂ) * μ) : + HasDerivAt (Fprod a q) + (-(m : ℂ) * (a : ℂ) * μ * Fprod a q t - + (a : ℂ) ^ 2 * (t : ℂ) * sumEraseProdC q (fun v => v ^ 2) + (fun v => 1 - (a : ℂ) * (t : ℂ) * v)) t := by + apply (derivative_decomposition a t q).congr_deriv + rw [hsum] + ring + +-- The residual is tested expanded as a complex integral, not as an abstract R. +example {m : ℕ} (hm : 1 ≤ m) (a : ℝ) (q : Multiset ℂ) (hqcard : q.card = m) : + (1 : ℂ) = Fprod a q 1 + (m : ℂ) * (a : ℂ) * (q.sum / (m : ℂ)) * + (∫ t in (0 : ℝ)..1, Fprod a q t) + + (a : ℂ) ^ 2 * ∫ t in (0 : ℝ)..1, + (t : ℂ) * sumEraseProdC q (fun v => v ^ 2) + (fun v => 1 - (a : ℂ) * (t : ℂ) * v) := by + exact integrated_residual_mean hm a q hqcard + +-- Public consumer: norm_majorants. +example {m : ℕ} (hm : 1 ≤ m) {a x y : ℝ} {q : Multiset ℂ} + (ha : 0 ≤ a) (hx1 : x ≤ 1) + (hqcard : q.card = m) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = (m : ℝ) * x) + (hsum : q.sum = (m : ℂ) * ((x : ℂ) + (y : ℂ) * Complex.I)) : + (‖(a : ℂ) ^ 2 * ∫ t in (0 : ℝ)..1, + (t : ℂ) * sumEraseProdC q (fun v => v ^ 2) + (fun v => 1 - (a : ℂ) * (t : ℂ) * v)‖ ≤ (m : ℝ) * a ^ 2 * + ∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (((m : ℝ) - 1) / 2)) ∧ + (‖Fprod a q 1‖ ≤ QQ (a * x) (a ^ 2) 1 ^ ((m : ℝ) / 2)) := by + exact norm_majorants hm ha hx1 hqcard hq1 hx hsum + +-- Public consumer: norm_budget. +example {m : ℕ} (hm : 1 ≤ m) {a x y : ℝ} {q : Multiset ℂ} + (ha : 0 ≤ a) (hx1 : x ≤ 1) + (hqcard : q.card = m) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = (m : ℝ) * x) + (hsum : q.sum = (m : ℂ) * ((x : ℂ) + (y : ℂ) * Complex.I)) : + 1 ≤ FirstOriginMargins.T (m : ℝ) a x + (m : ℝ) * a / ((m : ℝ) + 1) * + ‖((m : ℂ) + 1) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ := by + exact norm_budget hm ha hx1 hqcard hq1 hx hsum + +-- Public consumer: first_origin_budget. +example {m : ℕ} (hm : 1 ≤ m) {a x y : ℝ} {q : Multiset ℂ} + (ha : 0 ≤ a) (hx1 : x ≤ 1) + (hqcard : q.card = m) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = (m : ℝ) * x) + (hsum : q.sum = (m : ℂ) * ((x : ℂ) + (y : ℂ) * Complex.I)) + (hfirst : ‖((m : ℂ) + 1) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖ ≤ 1) : + 1 ≤ FirstOriginMargins.T (m : ℝ) a x + (m : ℝ) * a / ((m : ℝ) + 1) := by + exact first_origin_budget hm ha hx1 hqcard hq1 hx hsum hfirst + +-- Public consumer: polar_hierarchy. +example {n : ℕ} (hn : 2 ≤ n) {a x : ℝ} (ha : |a| ≤ 1) + {z q : Multiset ℂ} (hz : ∀ w ∈ z, ‖w‖ ≤ 1) + (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x) + (hpolar : q.prod * (z.map (fun w => 1 - (a : ℂ) * w)).prod + = (n : ℂ) * ∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod) + (hdenom : q.prod * (z.map (fun w => (a : ℂ) - w)).prod = (n : ℂ)) : + (1 ≤ ‖∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod‖) ∧ + (‖∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod‖ ≤ + ∫ t in (0 : ℝ)..1, + (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) ∧ + ((∫ t in (0 : ℝ)..1, + (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) ≤ + ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) := by + exact polar_hierarchy hn ha hz hqcard hq1 hx hpolar hdenom + +-- Public consumer: polar_factorization_hierarchy. +example {n : ℕ} (hn : 2 ≤ n) {a x : ℝ} + (ha : |a| ≤ 1) (ha0 : a ≠ 0) (ha2 : a ^ 2 ≠ 1) + {c : ℂ} {p : ℂ[X]} {z q : Multiset ℂ} + (hc0 : c ≠ 0) (hzcard : z.card = n - 1) + (hz : ∀ w ∈ z, ‖w‖ ≤ 1) + (hqcard : q.card = n - 1) (hq0 : ∀ v ∈ q, v ≠ 0) + (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) + (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x) + (hpz : p = C c * ((X - C (a : ℂ)) * (z.map (fun w => X - C w)).prod)) + (hpq : derivative p = C ((n : ℂ) * c) * + ((q.map (fun v => (a : ℂ) - v⁻¹)).map (fun w => X - C w)).prod) : + (q.prod * (z.map (fun w => (a : ℂ) - w)).prod = (n : ℂ)) ∧ + (q.prod * (z.map (fun w => 1 - (a : ℂ) * w)).prod = + (n : ℂ) * ∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod) ∧ + (1 ≤ ‖∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod‖) ∧ + (‖∫ t in (0 : ℝ)..1, + (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod‖ ≤ + ∫ t in (0 : ℝ)..1, + (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) ∧ + ((∫ t in (0 : ℝ)..1, + (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) ≤ + ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) := by + exact polar_factorization_hierarchy hn ha ha0 ha2 hc0 hzcard hz hqcard hq0 hq1 hx hpz hpq + +end Sendov.PaperOriginCorollariesTests + +#print axioms Sendov.PaperOriginCorollaries.derivative_decomposition +#print axioms Sendov.PaperOriginCorollaries.integrated_residual_sum +#print axioms Sendov.PaperOriginCorollaries.integrated_residual +#print axioms Sendov.PaperOriginCorollaries.residual_norm_bound +#print axioms Sendov.PaperOriginCorollaries.endpoint_norm_bound +#print axioms Sendov.PaperOriginCorollaries.norm_budget +#print axioms Sendov.PaperOriginCorollaries.first_origin_budget +#print axioms Sendov.PaperOriginCorollaries.integrated_residual_mean +#print axioms Sendov.PaperOriginCorollaries.norm_majorants +#print axioms Sendov.PaperOriginCorollaries.polar_hierarchy +#print axioms Sendov.PaperOriginCorollaries.polar_factorization_hierarchy diff --git a/tests/PaperRegionCorollaries.lean b/tests/PaperRegionCorollaries.lean new file mode 100644 index 0000000..64dd910 --- /dev/null +++ b/tests/PaperRegionCorollaries.lean @@ -0,0 +1,389 @@ +import Sendov.Analytic.PaperRegionCorollaries + +/-! Full-domain literal-contract tests for all eleven families, plus explicit +closed seams and the entire formerly omitted [1/5,2/5) strip. -/ +namespace Sendov.PaperRegionCorollaries.Tests + +open PaperPolar + +/-- Full quantified contract: in02_two_end. -/ +example {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + (((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) ≤ 100 * (m : ℝ) / + (9 * ((m : ℝ) + 1) * ((m : ℝ) + 3) * x ^ 2) + + 29 * (1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2)) ∧ + (((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) ≤ 16 * (m : ℝ) / + (((m : ℝ) + 1) * ((m : ℝ) + 3) * x ^ 2) + + 13 * (1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2)) := + in02_two_end hm ha ha1 hx0 hx1 hr + +/-- Full quantified contract: in04_middle. -/ +example {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx : 0 < x) (hx1 : x ≤ 1) + (hxa : x < a) (hax : a < 3 * x / 2) : + (((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 4 / ((m : ℝ) * x ^ 2) + + (1 + 5 * ((m : ℝ) * x ^ 2) / 8) * + Real.exp (-3 * ((m : ℝ) - 1) * ((m : ℝ) * x ^ 2) / (8 * (m : ℝ)))) ∧ + (9 ≤ m → ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 4 / ((m : ℝ) * x ^ 2) + + (1 + 5 * ((m : ℝ) * x ^ 2) / 8) * Real.exp (-((m : ℝ) * x ^ 2) / 3)) := + in04_middle hm ha ha1 hx hx1 hxa hax + +/-- Full quantified contract: ne05_near. -/ +example {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (hl : lambda m a ≤ 3 / 10) : + (1 - (m : ℝ) * a / ((m : ℝ) + 1)) - ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) > (1 - a) / 1000 := + ne05_near hm ha ha1 hx0 hx1 hr hl + +/-- Full quantified contract: un04_bulk40. -/ +example {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (ha2 : 2 / 5 ≤ a) : + (((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 40 / ((m : ℝ) * a ^ 2)) ∧ + (40 ≤ (m : ℝ) * a ^ 2 * (1 - a) → + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < + 1 - a ∧ 1 - a < (1 - (m : ℝ) * a / ((m : ℝ) + 1))) := + un04_bulk40 hm ha ha1 hx0 hx1 hr ha2 + +/-- Full quantified contract: un05_bulk116. -/ +example {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (hbulk : 116 ≤ (m : ℝ) * a ^ 2 * (1 - a)) : + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < + 1 - a ∧ 1 - a < (1 - (m : ℝ) * a / ((m : ℝ) + 1)) := + un05_bulk116 hm ha ha1 hx0 hx1 hr hbulk + +/-- Full quantified contract: un08_all_a_512. -/ +example {m : ℕ} {a x : ℝ} (hm : 512 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < + (1 - (m : ℝ) * a / ((m : ℝ) + 1)) := + un08_all_a_512 hm ha ha1 hx0 hx1 hr + +/-- Full quantified contract: un09_all_a_10000. -/ +example {m : ℕ} {a x : ℝ} (hm : 10000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < + (1 - (m : ℝ) * a / ((m : ℝ) + 1)) := + un09_all_a_10000 hm ha ha1 hx0 hx1 hr + +/-- Full quantified contract: un10_all_a_100000. -/ +example {m : ℕ} {a x : ℝ} (hm : 100000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < + (1 - (m : ℝ) * a / ((m : ℝ) + 1)) := + un10_all_a_100000 hm ha ha1 hx0 hx1 hr + +/-- Full quantified contract: un11_all_a_1000000. -/ +example {m : ℕ} {a x : ℝ} (hm : 1000000 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < + (1 - (m : ℝ) * a / ((m : ℝ) + 1)) := + un11_all_a_1000000 hm ha ha1 hx0 hx1 hr + +/-- Full quantified contract: ra03_scaled_upper. -/ +example {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + (lambda m a ∈ Set.Icc (1 / 5) (1) → + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 18 / (m : ℝ)) ∧ + (lambda m a ∈ Set.Icc (1) (10) → + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 33 / (m : ℝ)) ∧ + (lambda m a ∈ Set.Icc (10) (25) → + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 51 / (m : ℝ) + 1 / 4) ∧ + (lambda m a ∈ Set.Icc (25) (49) → + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 62 / (m : ℝ) + 2) := + ra03_scaled_upper hm ha ha1 hx0 hx1 hr + +/-- Full quantified contract: ra04_scaled_lower. -/ +example {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) : + (lambda m a ∈ Set.Icc (1 / 5) (1) → + 1 + 18 / (m : ℝ) < (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) ∧ + (lambda m a ∈ Set.Icc (1) (5) → + 1 + 33 / (m : ℝ) < (m : ℝ) / ((m : ℝ) + 1) * (1 + 6 / 25 - 24 / (m : ℝ)) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (1 + 6 / 25 - 24 / (m : ℝ)) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) ∧ + (lambda m a ∈ Set.Icc (5) (10) → + 1 + 33 / (m : ℝ) < (m : ℝ) / ((m : ℝ) + 1) * (6 * (7 / 12) ^ 2) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (6 * (7 / 12) ^ 2) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) ∧ + (lambda m a ∈ Set.Icc (10) (25) → + 1 + 51 / (m : ℝ) + 1 / 4 < (m : ℝ) / ((m : ℝ) + 1) * (11 * (231 / 512) ^ 2) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (11 * (231 / 512) ^ 2) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) ∧ + (lambda m a ∈ Set.Icc (25) (49) → + 1 + 62 / (m : ℝ) + 2 < (m : ℝ) / ((m : ℝ) + 1) * (26 * (207 / 512) ^ 2) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (26 * (207 / 512) ^ 2) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) := + ra04_scaled_lower hm ha ha1 hx0 hx1 hr + +/-- The whole [1/5,2/5) strip, not a sampled point. -/ +example {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (hl0 : 1 / 5 ≤ lambda m a) (hl1 : lambda m a < 2 / 5) : + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 18 / (m : ℝ) ∧ + 1 + 18 / (m : ℝ) < (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1)) := by + have hl : lambda m a ∈ Set.Icc (1 / 5) 1 := ⟨hl0, by linarith⟩ + exact ⟨(ra03_scaled_upper hm ha ha1 hx0 hx1 hr).1 hl, + (ra04_scaled_lower hm ha ha1 hx0 hx1 hr).1 hl⟩ + +/-- Seam lambda=1 / 5: every adjacent original band applies. -/ +example {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (hl : lambda m a = 1 / 5) : + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 18 / (m : ℝ) ∧ + (1 + 18 / (m : ℝ) < (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) := by + exact ⟨(ra03_scaled_upper hm ha ha1 hx0 hx1 hr).1 (by rw [hl]; constructor <;> norm_num), + (ra04_scaled_lower hm ha ha1 hx0 hx1 hr).1 (by rw [hl]; constructor <;> norm_num)⟩ + +/-- Seam lambda=2 / 5: every adjacent original band applies. -/ +example {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (hl : lambda m a = 2 / 5) : + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 18 / (m : ℝ) ∧ + (1 + 18 / (m : ℝ) < (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) := by + exact ⟨(ra03_scaled_upper hm ha ha1 hx0 hx1 hr).1 (by rw [hl]; constructor <;> norm_num), + (ra04_scaled_lower hm ha ha1 hx0 hx1 hr).1 (by rw [hl]; constructor <;> norm_num)⟩ + +/-- Seam lambda=1: every adjacent original band applies. -/ +example {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (hl : lambda m a = 1) : + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 18 / (m : ℝ) ∧ + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 33 / (m : ℝ) ∧ + (1 + 18 / (m : ℝ) < (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) ∧ + (1 + 33 / (m : ℝ) < (m : ℝ) / ((m : ℝ) + 1) * (1 + 6 / 25 - 24 / (m : ℝ)) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (1 + 6 / 25 - 24 / (m : ℝ)) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) := by + exact ⟨(ra03_scaled_upper hm ha ha1 hx0 hx1 hr).1 (by rw [hl]; constructor <;> norm_num), + (ra03_scaled_upper hm ha ha1 hx0 hx1 hr).2.1 (by rw [hl]; constructor <;> norm_num), + (ra04_scaled_lower hm ha ha1 hx0 hx1 hr).1 (by rw [hl]; constructor <;> norm_num), + (ra04_scaled_lower hm ha ha1 hx0 hx1 hr).2.1 (by rw [hl]; constructor <;> norm_num)⟩ + +/-- Seam lambda=5: every adjacent original band applies. -/ +example {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (hl : lambda m a = 5) : + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 33 / (m : ℝ) ∧ + (1 + 33 / (m : ℝ) < (m : ℝ) / ((m : ℝ) + 1) * (1 + 6 / 25 - 24 / (m : ℝ)) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (1 + 6 / 25 - 24 / (m : ℝ)) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) ∧ + (1 + 33 / (m : ℝ) < (m : ℝ) / ((m : ℝ) + 1) * (6 * (7 / 12) ^ 2) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (6 * (7 / 12) ^ 2) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) := by + exact ⟨(ra03_scaled_upper hm ha ha1 hx0 hx1 hr).2.1 (by rw [hl]; constructor <;> norm_num), + (ra04_scaled_lower hm ha ha1 hx0 hx1 hr).2.1 (by rw [hl]; constructor <;> norm_num), + (ra04_scaled_lower hm ha ha1 hx0 hx1 hr).2.2.1 (by rw [hl]; constructor <;> norm_num)⟩ + +/-- Seam lambda=10: every adjacent original band applies. -/ +example {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (hl : lambda m a = 10) : + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 33 / (m : ℝ) ∧ + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 51 / (m : ℝ) + 1 / 4 ∧ + (1 + 33 / (m : ℝ) < (m : ℝ) / ((m : ℝ) + 1) * (6 * (7 / 12) ^ 2) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (6 * (7 / 12) ^ 2) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) ∧ + (1 + 51 / (m : ℝ) + 1 / 4 < (m : ℝ) / ((m : ℝ) + 1) * (11 * (231 / 512) ^ 2) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (11 * (231 / 512) ^ 2) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) := by + exact ⟨(ra03_scaled_upper hm ha ha1 hx0 hx1 hr).2.1 (by rw [hl]; constructor <;> norm_num), + (ra03_scaled_upper hm ha ha1 hx0 hx1 hr).2.2.1 (by rw [hl]; constructor <;> norm_num), + (ra04_scaled_lower hm ha ha1 hx0 hx1 hr).2.2.1 (by rw [hl]; constructor <;> norm_num), + (ra04_scaled_lower hm ha ha1 hx0 hx1 hr).2.2.2.1 (by rw [hl]; constructor <;> norm_num)⟩ + +/-- Seam lambda=25: every adjacent original band applies. -/ +example {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (hl : lambda m a = 25) : + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 51 / (m : ℝ) + 1 / 4 ∧ + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 62 / (m : ℝ) + 2 ∧ + (1 + 51 / (m : ℝ) + 1 / 4 < (m : ℝ) / ((m : ℝ) + 1) * (11 * (231 / 512) ^ 2) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (11 * (231 / 512) ^ 2) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) ∧ + (1 + 62 / (m : ℝ) + 2 < (m : ℝ) / ((m : ℝ) + 1) * (26 * (207 / 512) ^ 2) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (26 * (207 / 512) ^ 2) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) := by + exact ⟨(ra03_scaled_upper hm ha ha1 hx0 hx1 hr).2.2.1 (by rw [hl]; constructor <;> norm_num), + (ra03_scaled_upper hm ha ha1 hx0 hx1 hr).2.2.2 (by rw [hl]; constructor <;> norm_num), + (ra04_scaled_lower hm ha ha1 hx0 hx1 hr).2.2.2.1 (by rw [hl]; constructor <;> norm_num), + (ra04_scaled_lower hm ha ha1 hx0 hx1 hr).2.2.2.2 (by rw [hl]; constructor <;> norm_num)⟩ + +/-- Seam lambda=49: every adjacent original band applies. -/ +example {m : ℕ} {a x : ℝ} (hm : 256 ≤ m) + (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1) + (hr : RawPolar m a x) + (hl : lambda m a = 49) : + (m : ℝ) * x ^ 2 * ((1 - 2 * a * x + a ^ 2) ^ ((m : ℝ) / 2) + + (m : ℝ) * a ^ 2 * ∫ t in (0 : ℝ)..1, + t * (1 - 2 * a * x * t + a ^ 2 * t ^ 2) ^ (((m : ℝ) - 1) / 2)) < 1 + 62 / (m : ℝ) + 2 ∧ + (1 + 62 / (m : ℝ) + 2 < (m : ℝ) / ((m : ℝ) + 1) * (26 * (207 / 512) ^ 2) ∧ + (m : ℝ) / ((m : ℝ) + 1) * (26 * (207 / 512) ^ 2) ≤ + (m : ℝ) * x ^ 2 * (1 - (m : ℝ) * a / ((m : ℝ) + 1))) := by + exact ⟨(ra03_scaled_upper hm ha ha1 hx0 hx1 hr).2.2.2 (by rw [hl]; constructor <;> norm_num), + (ra04_scaled_lower hm ha ha1 hx0 hx1 hr).2.2.2.2 (by rw [hl]; constructor <;> norm_num)⟩ + +/-- The historical cutoff itself, with every radius 0 Date: Mon, 14 Sep 2026 14:14:28 -0700 Subject: [PATCH 23/24] Record complete paper formalization acceptance, scope and measured costs --- docs/paper-formalization/ACCEPTANCE.json | 8879 +++++++++++++++++ docs/paper-formalization/METRICS.json | 105 + docs/paper-formalization/REPORT.md | 116 + docs/paper-formalization/RESULT.json | 27 + docs/paper-formalization/RESULT.md | 15 + docs/paper-formalization/SCOPE.md | 72 + docs/paper-formalization/STATUS.md | 114 +- docs/paper-formalization/VERIFICATION.json | 18 + docs/paper-formalization/axioms.json | 1946 ++++ docs/paper-formalization/receipts.json | 4416 ++++++++ .../reviews/diagnostics.md | 81 + .../mapping-before-corollary-exports.md | 648 ++ docs/paper-formalization/reviews/uniform.md | 99 + 13 files changed, 16433 insertions(+), 103 deletions(-) create mode 100644 docs/paper-formalization/ACCEPTANCE.json create mode 100644 docs/paper-formalization/METRICS.json create mode 100644 docs/paper-formalization/REPORT.md create mode 100644 docs/paper-formalization/RESULT.json create mode 100644 docs/paper-formalization/RESULT.md create mode 100644 docs/paper-formalization/SCOPE.md create mode 100644 docs/paper-formalization/VERIFICATION.json create mode 100644 docs/paper-formalization/axioms.json create mode 100644 docs/paper-formalization/receipts.json create mode 100644 docs/paper-formalization/reviews/diagnostics.md create mode 100644 docs/paper-formalization/reviews/mapping-before-corollary-exports.md create mode 100644 docs/paper-formalization/reviews/uniform.md diff --git a/docs/paper-formalization/ACCEPTANCE.json b/docs/paper-formalization/ACCEPTANCE.json new file mode 100644 index 0000000..973921d --- /dev/null +++ b/docs/paper-formalization/ACCEPTANCE.json @@ -0,0 +1,8879 @@ +{ + "schema": "paper-to-lean-acceptance-map/v2", + "target_kind": "accepted_source_commit_with_separate_parent_kernel_receipts", + "target_tree": "5fc14c166f5d4b9d2f183a8d8e4de0b60aad9c2d", + "target_commit": "8e1b056a241e6a99af2e2029569dc92a334c1a6d", + "repository": "/home/v-zhouziyu/work/sendov-paper-formalization-20260914", + "source_ledger": "/home/v-zhouziyu/work/sendov-research-20260914-research/paper-formalization/acceptance-map.json", + "source_ledger_target_commit": "a5f0c11401e0294eb4f4022970a4a429b48885e9", + "source_ledger_sha256": "91fcc5827c3d837901442c0837e260abe6d5228f6c14c244effb31dbce4a62ab", + "verdict": { + "mathematically_mapped_92_of_92": true, + "mapped_required": 92, + "required": 92, + "genuine_remaining_required_gaps": [], + "full_acceptance_including_dispositions_and_kernel": "PASS by parent: all92 obtained families have compiled source contracts; explicit scope/disposition is in SCOPE.md; 193 successful gates in VERIFICATION.json.", + "exact_tree_kernel_verified_by_this_audit": false, + "full_m_ge_7_D_claimed": false, + "external_OP04_OP05_adopted": false, + "parent_verified_source_commit": "8e1b056a241e6a99af2e2029569dc92a334c1a6d" + }, + "kernel_evidence": { + "status": "PASS by parent (separate from source audit)", + "file": "VERIFICATION.json", + "receipts": "receipts.json", + "axioms": "axioms.json", + "modules": 97, + "compile_gates": 97, + "kernel_gates": 96, + "source_commit": "8e1b056a241e6a99af2e2029569dc92a334c1a6d" + }, + "counts": { + "normalized_units": 101, + "required": 92, + "compiled_result_families": 92, + "remaining_required_gaps": 0, + "named_axiom_roots": 243, + "by_status": { + "theorem": 92, + "asymptotic_proof_incomplete": 3, + "diagnostic_only": 1, + "paper_open": 3, + "external_unadopted": 2 + } + }, + "status_legend": { + "theorem": "Matching named theorem/lemma or exact anonymous test theorem exists in immutable source, including ordinary unfolding/restriction of an equivalent contract. No final-tree kernel receipt is asserted by this status.", + "derived_corollary": "Matching explicit mathematical composition/restriction; exact recipe required and provided. Not independently compiled as a wrapper by this audit.", + "asymptotic_proof_incomplete": "Heuristic calculation/remainder or convergence proof incomplete; explicit paper disposition or additional proof required, not counted among the 92 obtained proofs.", + "paper_open": "Not an obtained proof. Kept visible without claiming closure.", + "external_unadopted": "External-paper result not adopted into local acceptance scope.", + "diagnostic_only": "Uncertified floating/empirical screen; no theorem obligation except separately indexed certified examples." + }, + "acceptance_policy": { + "obtained_local_proofs": "All 92 inherited required units mapped. No hidden scope reduction or omission of historical rates, finite certified datasets, older margins, or EX03/AS03.", + "asymptotics": "AS01,AS02,AS04 stay incomplete; mathematical 92/92 does not dispose of their misleading proved-result presentation. AS03 and AS05 are mapped, but AS05 does not imply AS04.", + "external": "OP04 and OP05 are not adopted. External complex-collinear/equality and averaged-L² material is not called globally unknown, but no local verification/completion is claimed.", + "non_goals": "No full D for all m≥7; m≥256 uniform D and existing near/finite domains only. No global centered remainder premise, all-domain Fsec positivity, new complex-collinear transport, old endgame retirement, or whole-repository performance claim.", + "finite_certificates": "Test-only theorem evidence is mathematically admissible but must be deliberately included in parent kernel acceptance. Approximate display values and screen counts are not promoted to additional exact conclusions." + }, + "closure_checks": { + "formerly_missing_or_partial_ids": [ + "PO06", + "IN02", + "RA04", + "DI02", + "DI03", + "DI04", + "DI05", + "DI06", + "DI07", + "DI08", + "DI09", + "DI10", + "DI15", + "DI16", + "DI17", + "EX03", + "AS03", + "HI01", + "HI02", + "HI03", + "HI04" + ], + "formerly_missing_or_partial_now_mapped": [ + "PO06", + "IN02", + "RA04", + "DI02", + "DI03", + "DI04", + "DI05", + "DI06", + "DI07", + "DI08", + "DI09", + "DI10", + "DI15", + "DI16", + "DI17", + "EX03", + "AS03", + "HI01", + "HI02", + "HI03", + "HI04" + ], + "formerly_inflight_ids": [ + "FO10", + "FO11", + "UN01", + "UN02", + "UN03", + "UN07" + ], + "formerly_inflight_now_mapped": [ + "FO10", + "FO11", + "UN01", + "UN02", + "UN03", + "UN07" + ], + "all_required_ids": [ + "AS03", + "AS05", + "BO01", + "BO02", + "BO03", + "BO04", + "CE01", + "CE02", + "CE03", + "CE04", + "CE05", + "CO01", + "CO02", + "CO03", + "CO04", + "CO05", + "CO06", + "CO07", + "DI01", + "DI02", + "DI03", + "DI04", + "DI05", + "DI06", + "DI07", + "DI08", + "DI09", + "DI10", + "DI11", + "DI12", + "DI13", + "DI14", + "DI15", + "DI16", + "DI17", + "EX01", + "EX02", + "EX03", + "FO01", + "FO02", + "FO03", + "FO04", + "FO05", + "FO06", + "FO07", + "FO08", + "FO09", + "FO10", + "FO11", + "HI01", + "HI02", + "HI03", + "HI04", + "IN01", + "IN02", + "IN03", + "IN04", + "IN05", + "NE01", + "NE02", + "NE03", + "NE04", + "NE05", + "NE06", + "PO01", + "PO02", + "PO03", + "PO04", + "PO05", + "PO06", + "PO07", + "PO08", + "PO09", + "RA01", + "RA02", + "RA03", + "RA04", + "SE01", + "SE02", + "SE03", + "SE04", + "UN01", + "UN02", + "UN03", + "UN04", + "UN05", + "UN06", + "UN07", + "UN08", + "UN09", + "UN10", + "UN11" + ], + "duplicate_ids": [], + "duplicate_whitespace_normalized_statements": [], + "unresolved_qualified_references": [], + "local_import_closure_trust_marker_scan": { + "files": 97, + "tokens": [ + "sorry", + "admit", + "axiom", + "native_decide" + ], + "hits": [], + "limitation": "Comment-stripped static first-party source scan, not transitive elaborated axiom certification of mathlib or kernel replay." + } + }, + "source_manifest": [ + { + "path": "Sendov/Analytic/FirstOriginAlgebra.lean", + "blob": "d916c3264d120623b21039f3df26b81ade7af025", + "sha256": "c18e2d5d0207cb386dca31949eef8b4240958e53a17c2819f653c40f7575d75b", + "bytes": 7187, + "lines": 122 + }, + { + "path": "Sendov/Analytic/FirstOriginBounds.lean", + "blob": "39563a6a6a04cdebfd789068642058f8b9966cae", + "sha256": "931ee26dd1b7458f24a337eb4177d5ff2a9211d5e67a89ffe96cde98c0baebf7", + "bytes": 8592, + "lines": 166 + }, + { + "path": "Sendov/Analytic/FirstOriginBudget.lean", + "blob": "aed9631b5d52531251e4780e658126e33e15761d", + "sha256": "24fd1fac40334f9dcd6369dab211ceb2f16e055f70162ce4a51b791fabd3b1fb", + "bytes": 4802, + "lines": 101 + }, + { + "path": "Sendov/Analytic/FirstOriginMargins.lean", + "blob": "c0c69554b4e7678e1f5c9b17ba8eb71e0234f34f", + "sha256": "7251d36dcf270ba21bc65dcb71df75a0c5e98c65da182b91a98c254a49d1dee8", + "bytes": 13618, + "lines": 284 + }, + { + "path": "Sendov/Analytic/FirstOriginSmall.lean", + "blob": "f7170c9953a6ed1b6660dfe7efe692afe9bb74a7", + "sha256": "69cd012979351d0bb4b1e92acb1ea9d1d3ce5e3700250a6b05f80a6167578075", + "bytes": 7518, + "lines": 158 + }, + { + "path": "Sendov/Analytic/Origin.lean", + "blob": "f06d3725e21af74440649dc5e6d4ce196fb011af", + "sha256": "ef15fa2ef6f10d169762d777406a63d64f599f3421bb0338bbcc882b61abfff1", + "bytes": 20854, + "lines": 423 + }, + { + "path": "Sendov/Analytic/PaperBulkAlgebra.lean", + "blob": "02f421046263afd4e6bb6305a914bead72943122", + "sha256": "9478fd84e059bbc039517889a19fae783febb059654f9ca39918fcfde3e3ff10", + "bytes": 3312, + "lines": 90 + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "sha256": "facbdcf9fd2e65319f2e36f36aa35d5c1d19e6bbf2bc4f140b553c01faa23081", + "bytes": 16943, + "lines": 362 + }, + { + "path": "Sendov/Analytic/PaperCenteredBound.lean", + "blob": "5615181f428ef9f5d699ffc42e474824c400b762", + "sha256": "252ff2584f4cfe420d21e00ebc38639fd37a6b77fcdb6986e555da7c4bf3501b", + "bytes": 6561, + "lines": 143 + }, + { + "path": "Sendov/Analytic/PaperCoefficient.lean", + "blob": "10efaefe8bff8f3983fd269047f8f5f3dfa64ad5", + "sha256": "8ad4e46e7bf7b75a95c6519ebd47827f180144645e8a6737fc31b10d4a2a3215", + "bytes": 11591, + "lines": 261 + }, + { + "path": "Sendov/Analytic/PaperConjugate.lean", + "blob": "632d0e52fdadee2ba298663a8d330b2e727f46bf", + "sha256": "9811b0c47e0f37954f278a8b898443c82e830d8c716f539fafb02834d31d7ac2", + "bytes": 8157, + "lines": 193 + }, + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "sha256": "0aa07e5a1d3a207c47c15175ed2df2bf5d380f989695b364b1dffb03412d2556", + "bytes": 14145, + "lines": 279 + }, + { + "path": "Sendov/Analytic/PaperGlobalPolar.lean", + "blob": "4579b325911203a308137777929bf08495503812", + "sha256": "819659f501f33b9ad45bbd3b7884c413cd86dbe584556d2a61a4960f93cd2ef5", + "bytes": 10930, + "lines": 229 + }, + { + "path": "Sendov/Analytic/PaperHistoricalBounds.lean", + "blob": "734f40af971c2f781f83df84bdb6892b36bc2bab", + "sha256": "7994ec4e64bb4650bf595850d42ac02d6dede56a2691c473152fd60ee00cf6bc", + "bytes": 22108, + "lines": 443 + }, + { + "path": "Sendov/Analytic/PaperLaplace.lean", + "blob": "436d5d4e4aaf66b94c93e4a05bf48a02c85c963e", + "sha256": "5527e05b401492f825a6adbd16dcecfd7b8c13d025104cdb61146e293fcb0d01", + "bytes": 14265, + "lines": 292 + }, + { + "path": "Sendov/Analytic/PaperNear.lean", + "blob": "8e258a06357ae182a76feee8e55d2480221ab0f2", + "sha256": "b4dfa38f5564f219f1403ca587eaf56360c22064c8b1bb9ba9c46fe49c67447f", + "bytes": 9223, + "lines": 191 + }, + { + "path": "Sendov/Analytic/PaperNearMargins.lean", + "blob": "f897fdb771f2fa90796500842851b1833352d26f", + "sha256": "79c8d4c47c9743d63ed4d41b16a34ed975f0b8d5a2a3d1a6f18addeb1b756f78", + "bytes": 7268, + "lines": 147 + }, + { + "path": "Sendov/Analytic/PaperPolar.lean", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "sha256": "9ae07de0fc8fdafab25a31cf6402eeafacce7f18bf7a06daa1d12aca2366e52e", + "bytes": 7620, + "lines": 189 + }, + { + "path": "Sendov/Analytic/PaperRateDetails.lean", + "blob": "80654d487a115521c5bf6bdb793ce5e5678c1575", + "sha256": "837f03254999fc3ed5ef8dc085228545f46cf4825416b0f0c900e23053366faf", + "bytes": 7193, + "lines": 145 + }, + { + "path": "Sendov/Analytic/PaperRayGeometry.lean", + "blob": "630798c6c402c6d5fb22d7bbcb61d456e8175751", + "sha256": "ef09de5cc8d32a4fd53ca340d476dedd0c013b54d0023a230446f23b781af67c", + "bytes": 17294, + "lines": 373 + }, + { + "path": "Sendov/Analytic/PaperSecant.lean", + "blob": "d5a1481b495db34a9a82222596a45f36bc7a77a0", + "sha256": "fed557b44b40b33c8083aca410b2d8193da8030bde01888211c950326c2b51d0", + "bytes": 19280, + "lines": 390 + }, + { + "path": "Sendov/Analytic/PaperTail.lean", + "blob": "5adc927ce4b253aad92605c908417b6eb005fe37", + "sha256": "aa15616e350bb3d18843ebf1c2a4d52329b19bf55c97fb3adcbc0b90846665f3", + "bytes": 12235, + "lines": 237 + }, + { + "path": "Sendov/Analytic/PaperTaylor.lean", + "blob": "d982ee5ca7fd67f2b03d7959d45749da20f4f397", + "sha256": "c030a67c12c7b585e125a5a2f8b2bd2afcea8426e9c2823f54e2a421f3740649", + "bytes": 14550, + "lines": 305 + }, + { + "path": "Sendov/Analytic/PaperTwoEnd.lean", + "blob": "80e4a5f2cf45619625301fcdd1501ff76b59329a", + "sha256": "128dacc7bc77b951c8e672627aa9b862dbaa1e59d8d34da6a9a5669ae6303e96", + "bytes": 17385, + "lines": 380 + }, + { + "path": "Sendov/Analytic/PaperUniform.lean", + "blob": "6ec67449aca5bacd31f0cc69b8a83b819940263a", + "sha256": "24a8335da842ef474ea7e35d48aafc5420307044be9bf7cdbe36caf79bdaf12e", + "bytes": 8992, + "lines": 188 + }, + { + "path": "Sendov/Analytic/PaperWideRays.lean", + "blob": "835e17361dfc34773628df7156e33d1dfa09fa53", + "sha256": "e7f616a6a1e2682868e716c83eb0139252546abbb26968e7bff483f0b272613c", + "bytes": 10909, + "lines": 210 + }, + { + "path": "Sendov/Analytic/Polar.lean", + "blob": "932fec570996fe54c72608f801e8920f9bcbf69a", + "sha256": "7fd03b20db2e2280dc6a431c5ba3fd7bd946db450a384cde3f1fb6f3d1e67e83", + "bytes": 11769, + "lines": 252 + }, + { + "path": "Sendov/Boundary.lean", + "blob": "2650f7b3909fb7d12cfa4ea39da474e315e3d0c0", + "sha256": "204d914bfeec14999b4b3b86d9070af17bc0f096462e52f28ff738b7e4f81705", + "bytes": 14201, + "lines": 292 + }, + { + "path": "Sendov/Collinear/Balance.lean", + "blob": "678b146e32fea6310d574f980dce37d6be5bd4d3", + "sha256": "5a552794875eedebc032168861169d2cdddc038baaaeea66745826d164211e99", + "bytes": 3674, + "lines": 72 + }, + { + "path": "Sendov/Collinear/Diameter.lean", + "blob": "9201a1bdccaf44c08d19f2a673bca71e8a59a05c", + "sha256": "aeb12605fe0b815917e96829c21d71c600c32522e10b759c32bb2065273de38f", + "bytes": 3383, + "lines": 70 + }, + { + "path": "Sendov/Collinear/Gate.lean", + "blob": "d3023b0775d1ce53810139a98f4b997e905acca2", + "sha256": "f4e77cf2ad3b20ac4761da256a4ae2b8ecdea45fd091d212ecd3640ef364e63f", + "bytes": 7605, + "lines": 161 + }, + { + "path": "Sendov/Collinear/Mass.lean", + "blob": "a4588a1ebce23b6f3d13fbcbbc144248a57133ea", + "sha256": "8bfc6af8f0be863382eb16b0020413ba604aa1ed7ed7bfe929cda45b154c21e8", + "bytes": 5177, + "lines": 104 + }, + { + "path": "Sendov/Collinear/Moment.lean", + "blob": "71906f976e430cc73648c3cf520083535da92131", + "sha256": "0f1612f32a7a37307d71627ab865ca8f5d93ba7345dd96e11c04269dd09b81d8", + "bytes": 2725, + "lines": 52 + }, + { + "path": "Sendov/Conjecture.lean", + "blob": "e93285098fb6d1aa8af03052283fb7ae76ca2d62", + "sha256": "260df47ae05aee1735d8f24451f53bf7d25f55c4ecf6eb5a583860cfde4d42c8", + "bytes": 7968, + "lines": 169 + }, + { + "path": "Sendov/Counterexample/Identities.lean", + "blob": "91f7da51b1f2a1996ebf7242958eca6b4baeaa93", + "sha256": "09c7c0bceebb324f81438a4112ac1a0695cd18f3d38fdef9a1955ce2eb7240d6", + "bytes": 19335, + "lines": 420 + }, + { + "path": "Sendov/Reduction/Setup.lean", + "blob": "eced975e75a01a791465bdc28c98d0ef34cf5fb9", + "sha256": "96b471e3e11a6d63b2321d194d9e554e81b79ebdff6e20815cce0b0093d9ec89", + "bytes": 2132, + "lines": 65 + }, + { + "path": "tests/BoundaryProbe.lean", + "blob": "c5c124686c53d94572b74ab4b0db98bc9d7da810", + "sha256": "9c1e09608d0a7d262aef189c78a2a7df0ecd018e99b56550c653ce1fa066e833", + "bytes": 6211, + "lines": 141 + }, + { + "path": "tests/CollinearRound2Tests.lean", + "blob": "4efdd95b479d9ad25e2abc8821cbf70578923041", + "sha256": "b441c8c5bc06f2caf0862aa633edde72dc1dbe8593f7981267c5587dbfb5e0a6", + "bytes": 4921, + "lines": 102 + }, + { + "path": "tests/PaperCenteredHundred.lean", + "blob": "b60c36550bb5134a760765ca880df63748acea4b", + "sha256": "89ae6b1bf9763c912a8a455ef94ab37cb9dc5ad54377f3ed4f5a252d07c8f17e", + "bytes": 92902, + "lines": 2106 + }, + { + "path": "tests/PaperConjugateBudgets.lean", + "blob": "593d4247e262b561a92ab5e2fb03f5a3eab7cbf3", + "sha256": "57eb9bbcacdb2447342b75091d69105d80b17a73acef1fded6dc25d7e1c6396c", + "bytes": 4474, + "lines": 100 + }, + { + "path": "tests/PaperLegacyCertificates.lean", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "sha256": "3f776cd5adcf2352d29f8c2be64f27c573200d1f6827e1cace415a16a53caf69", + "bytes": 10588, + "lines": 232 + }, + { + "path": "tests/PaperPolarCounterexample.lean", + "blob": "5aa353dd456feb742c1814939cdbfe8ea6fe68ef", + "sha256": "753dea2f5fa8f07879019b3079e320252d45f86736f3180ba61a4c15e7c4cade", + "bytes": 5936, + "lines": 161 + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "sha256": "b2362ca11c2febe4cdca12eb0c4c7cd0a21a6d3a787c941659e53aa6a180b747", + "bytes": 13982, + "lines": 332 + }, + { + "path": "tests/PaperSecantNeighborhoods.lean", + "blob": "715f50e923a68e5227dfb95af626a7845a18022b", + "sha256": "1fc9d8d3fa468ce46881edf3f1959a58094911425abbd5a7291f82d7d95df961", + "bytes": 12386, + "lines": 219 + }, + { + "path": "tests/PaperSecantTests.lean", + "blob": "645c3392fe1a3b3d6ef1e58ecad7cbd379f40d8f", + "sha256": "e3b746e49e650fc0abc977e11ac4b36be1ec45b93e4020e5efd3a034e0146c74", + "bytes": 4439, + "lines": 109 + } + ], + "definition_evidence": [ + { + "path": "Sendov/Analytic/PaperPolar.lean", + "line": 24, + "declaration": "RawPolar", + "qualified_declaration": "Sendov.PaperPolar.RawPolar", + "kind": "def", + "signature": "def RawPolar (m : ℕ) (a x : ℝ) : Prop", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def RawPolar (m : ℕ) (a x : ℝ) : Prop :=\n 1 ≤ ∫ t in (0 : ℝ)..1,\n (a ^ 2 + 2 * a * (1 - a ^ 2) * x * t + (1 - a ^ 2) ^ 2 * t ^ 2) ^\n ((m : ℝ) / 2)" + }, + { + "path": "Sendov/Analytic/PaperPolar.lean", + "line": 17, + "declaration": "b", + "qualified_declaration": "Sendov.PaperPolar.b", + "kind": "def", + "signature": "noncomputable def b (a x : ℝ) : ℝ", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def b (a x : ℝ) : ℝ := 1 - 2 * a * x + a ^ 2" + }, + { + "path": "Sendov/Analytic/PaperPolar.lean", + "line": 18, + "declaration": "c", + "qualified_declaration": "Sendov.PaperPolar.c", + "kind": "def", + "signature": "noncomputable def c (a x : ℝ) : ℝ", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def c (a x : ℝ) : ℝ := 1 - b a x" + }, + { + "path": "Sendov/Analytic/PaperPolar.lean", + "line": 20, + "declaration": "alpha", + "qualified_declaration": "Sendov.PaperPolar.alpha", + "kind": "def", + "signature": "noncomputable def alpha (m : ℕ) (a : ℝ) : ℝ", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def alpha (m : ℕ) (a : ℝ) : ℝ := (m : ℝ) * (1 - a ^ 2) / 2" + }, + { + "path": "Sendov/Analytic/PaperPolar.lean", + "line": 21, + "declaration": "lambda", + "qualified_declaration": "Sendov.PaperPolar.lambda", + "kind": "def", + "signature": "noncomputable def lambda (m : ℕ) (a : ℝ) : ℝ", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def lambda (m : ℕ) (a : ℝ) : ℝ := (m : ℝ) * (1 - a)" + }, + { + "path": "Sendov/Analytic/PaperTaylor.lean", + "line": 22, + "declaration": "budget", + "qualified_declaration": "Sendov.PaperTaylor.budget", + "kind": "def", + "signature": "noncomputable def budget (m a x : ℝ) : ℝ", + "blob": "d982ee5ca7fd67f2b03d7959d45749da20f4f397", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def budget (m a x : ℝ) : ℝ :=\n beta a x 1 ^ (m / 2) + m * a ^ 2 *\n ∫ t in (0 : ℝ)..1, t * beta a x t ^ ((m - 1) / 2)" + }, + { + "path": "Sendov/Analytic/PaperTaylor.lean", + "line": 21, + "declaration": "chord", + "qualified_declaration": "Sendov.PaperTaylor.chord", + "kind": "def", + "signature": "noncomputable def chord (a x : ℝ) : ℝ", + "blob": "d982ee5ca7fd67f2b03d7959d45749da20f4f397", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def chord (a x : ℝ) : ℝ := a * (2 * x - a)" + }, + { + "path": "Sendov/Analytic/PaperTaylor.lean", + "line": 19, + "declaration": "beta", + "qualified_declaration": "Sendov.PaperTaylor.beta", + "kind": "def", + "signature": "noncomputable def beta (a x t : ℝ) : ℝ", + "blob": "d982ee5ca7fd67f2b03d7959d45749da20f4f397", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def beta (a x t : ℝ) : ℝ := 1 - 2 * a * x * t + a ^ 2 * t ^ 2" + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 275, + "declaration": "variance", + "qualified_declaration": "Sendov.PaperCentered.variance", + "kind": "def", + "signature": "def variance (r : Multiset ℂ) : ℝ", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def variance (r : Multiset ℂ) : ℝ := (r.map (fun v => ‖v‖ ^ 2)).sum / r.card" + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 207, + "declaration": "kappa", + "qualified_declaration": "Sendov.PaperCentered.kappa", + "kind": "def", + "signature": "def kappa (r : Multiset ℂ) : ℂ", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def kappa (r : Multiset ℂ) : ℂ := (r.map (fun v => v ^ 2)).sum / r.card" + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 278, + "declaration": "Gamma", + "qualified_declaration": "Sendov.PaperCentered.Gamma", + "kind": "def", + "signature": "def Gamma (r : Multiset ℂ) (μ : ℂ) : ℝ", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def Gamma (r : Multiset ℂ) (μ : ℂ) : ℝ :=\n variance r / (((r.card : ℝ) - 1) * ‖μ‖ ^ 2)" + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 155, + "declaration": "coeff", + "qualified_declaration": "Sendov.PaperCentered.coeff", + "kind": "def", + "signature": "def coeff (r : Multiset ℂ) (μ : ℂ) (k : ℕ) : ℂ", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def coeff (r : Multiset ℂ) (μ : ℂ) (k : ℕ) : ℂ :=\n (-1) ^ k * r.esymm k / ((r.card.choose k : ℂ) * μ ^ k)" + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 210, + "declaration": "correction", + "qualified_declaration": "Sendov.PaperCentered.correction", + "kind": "def", + "signature": "def correction (r : Multiset ℂ) (μ : ℂ) : ℂ", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def correction (r : Multiset ℂ) (μ : ℂ) : ℂ :=\n kappa r / (((r.card : ℂ) - 1) * μ ^ 2)" + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 308, + "declaration": "Efin", + "qualified_declaration": "Sendov.PaperCentered.Efin", + "kind": "def", + "signature": "def Efin (r : Multiset ℂ) (μ z : ℂ) : ℝ", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def Efin (r : Multiset ℂ) (μ z : ℂ) : ℝ :=\n ‖1 - z‖ ^ (r.card + 1) + Gamma r μ * ‖B r.card 2 z‖ +\n ∑ k ∈ Finset.Ico 3 (r.card + 1),\n (‖r.esymm k‖ / ((r.card.choose k : ℝ) * ‖μ‖ ^ k)) * ‖H r.card k z‖" + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 13, + "declaration": "B", + "qualified_declaration": "Sendov.PaperCentered.B", + "kind": "def", + "signature": "def B (m k : ℕ) (z : ℂ) : ℂ", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def B (m k : ℕ) (z : ℂ) : ℂ :=\n ∑ j ∈ Finset.range (k + 1), (m + 1).choose j * z ^ j * (1 - z) ^ (m + 1 - j)" + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 17, + "declaration": "H", + "qualified_declaration": "Sendov.PaperCentered.H", + "kind": "def", + "signature": "def H (m k : ℕ) (z : ℂ) : ℂ", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def H (m k : ℕ) (z : ℂ) : ℂ := 1 - B m k z" + }, + { + "path": "Sendov/Analytic/PaperCenteredBound.lean", + "line": 24, + "declaration": "C", + "qualified_declaration": "Sendov.PaperCenteredBound.C", + "kind": "def", + "signature": "def C (m k : ℕ) (v : ℝ) : ℝ", + "blob": "5615181f428ef9f5d699ffc42e474824c400b762", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def C (m k : ℕ) (v : ℝ) : ℝ :=\n if k = m then Real.sqrt (v ^ m)\n else if 0 < k ∧ k < m then\n Real.sqrt ((m : ℝ) ^ m / ((k : ℝ) ^ k * ((m - k : ℕ) : ℝ) ^ (m - k)) * v ^ k)\n else 0" + }, + { + "path": "Sendov/Analytic/PaperCenteredBound.lean", + "line": 85, + "declaration": "majorant_Efin", + "qualified_declaration": "Sendov.PaperCenteredBound.majorant_Efin", + "kind": "def", + "signature": "def majorant_Efin (r : Multiset ℂ) (μ z : ℂ) : ℝ", + "blob": "5615181f428ef9f5d699ffc42e474824c400b762", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def majorant_Efin (r : Multiset ℂ) (μ z : ℂ) : ℝ :=\n ‖1 - z‖ ^ (r.card + 1) + Gamma r μ * ‖B r.card 2 z‖ +\n ∑ k ∈ Finset.Ico 3 (r.card + 1),\n (C r.card k (variance r) / ((r.card.choose k : ℝ) * ‖μ‖ ^ k)) * ‖H r.card k z‖" + }, + { + "path": "tests/PaperConjugateBudgets.lean", + "line": 27, + "declaration": "Accepted", + "qualified_declaration": "Sendov.PaperConjugate.Budgets.Accepted", + "kind": "def", + "signature": "def Accepted (m : ℕ) (a x : ℝ) : Prop", + "blob": "593d4247e262b561a92ab5e2fb03f5a3eab7cbf3", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def Accepted (m : ℕ) (a x : ℝ) : Prop :=\n let q := family (m / 2) x\n 0 < a ∧ a < 1 ∧ q.card = m ∧\n (∀ w ∈ q, ‖w‖ = 1) ∧\n q.sum / q.card = (x : ℂ) ∧\n variance (q.map (fun w => w - (x : ℂ))) = 1 - x ^ 2 ∧\n 1 < ‖K (m / 2) a x‖ ∧\n majorant_Efin (q.map (fun w => w - (x : ℂ))) (x : ℂ) ((a : ℂ) * x) +\n Gamma (q.map (fun w => w - (x : ℂ))) (x : ℂ) < 1 - a * ‖(x : ℂ)‖ ∧\n 1 < ‖J (m / 2) a x‖" + }, + { + "path": "tests/PaperCenteredHundred.lean", + "line": 13, + "declaration": "a", + "qualified_declaration": "Sendov.PaperCenteredHundred.a", + "kind": "def", + "signature": "def a : ℝ", + "blob": "b60c36550bb5134a760765ca880df63748acea4b", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def a : ℝ := 9 / 10" + }, + { + "path": "tests/PaperCenteredHundred.lean", + "line": 14, + "declaration": "μ", + "qualified_declaration": "Sendov.PaperCenteredHundred.μ", + "kind": "def", + "signature": "def μ : ℂ", + "blob": "b60c36550bb5134a760765ca880df63748acea4b", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def μ : ℂ := 7 / 10" + }, + { + "path": "tests/PaperCenteredHundred.lean", + "line": 15, + "declaration": "q", + "qualified_declaration": "Sendov.PaperCenteredHundred.q", + "kind": "def", + "signature": "def q : Multiset ℂ", + "blob": "b60c36550bb5134a760765ca880df63748acea4b", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def q : Multiset ℂ := Multiset.replicate 50 (2 / 5) + Multiset.replicate 50 1" + }, + { + "path": "tests/PaperCenteredHundred.lean", + "line": 16, + "declaration": "r", + "qualified_declaration": "Sendov.PaperCenteredHundred.r", + "kind": "def", + "signature": "def r : Multiset ℂ", + "blob": "b60c36550bb5134a760765ca880df63748acea4b", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def r : Multiset ℂ := q.map (fun w => w - μ)" + }, + { + "path": "tests/PaperCenteredHundred.lean", + "line": 1993, + "declaration": "J", + "qualified_declaration": "Sendov.PaperCenteredHundred.J", + "kind": "def", + "signature": "def J : ℂ", + "blob": "b60c36550bb5134a760765ca880df63748acea4b", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def J : ℂ := (q.card + 1 : ℂ) *\n (∫ t in (0 : ℝ)..1, (q.map (fun w => 1 - (a : ℂ) * t * w)).prod)" + }, + { + "path": "tests/PaperCenteredHundred.lean", + "line": 2006, + "declaration": "K", + "qualified_declaration": "Sendov.PaperCenteredHundred.K", + "kind": "def", + "signature": "def K : ℂ", + "blob": "b60c36550bb5134a760765ca880df63748acea4b", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def K : ℂ := ∫ t in (0 : ℝ)..1,\n (q.map (fun w => (a : ℂ) + ((1-a^2)*t : ℝ) * w)).prod" + }, + { + "path": "Sendov/Analytic/FirstOriginMargins.lean", + "line": 15, + "declaration": "A5", + "qualified_declaration": "Sendov.FirstOriginMargins.A5", + "kind": "def", + "signature": "noncomputable def A5 (a : ℝ) : ℝ", + "blob": "c0c69554b4e7678e1f5c9b17ba8eb71e0234f34f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def A5 (a : ℝ) : ℝ :=\n 7 / 6 - (7 / 3) * a + a ^ 2 + (7 / 12) * a ^ 3 + (1 / 12) * a ^ 4" + }, + { + "path": "Sendov/Analytic/FirstOriginMargins.lean", + "line": 18, + "declaration": "A6", + "qualified_declaration": "Sendov.FirstOriginMargins.A6", + "kind": "def", + "signature": "noncomputable def A6 (a : ℝ) : ℝ", + "blob": "c0c69554b4e7678e1f5c9b17ba8eb71e0234f34f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def A6 (a : ℝ) : ℝ :=\n 15 / 7 - (27 / 7) * a + (15 / 7) * a ^ 2 + (65 / 112) * a ^ 3 -\n (229 / 112) * a ^ 4 + (23 / 14) * a ^ 5" + }, + { + "path": "Sendov/Analytic/PaperSecant.lean", + "line": 17, + "declaration": "U1", + "qualified_declaration": "Sendov.PaperSecant.U1", + "kind": "def", + "signature": "noncomputable def U1 (m : ℕ) (a : ℝ) : ℝ", + "blob": "d5a1481b495db34a9a82222596a45f36bc7a77a0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def U1 (m : ℕ) (a : ℝ) : ℝ :=\n ((a + (1 - a ^ 2)) ^ (m + 1) - a ^ (m + 1)) / (((m : ℝ) + 1) * (1 - a ^ 2))" + }, + { + "path": "Sendov/Analytic/PaperSecant.lean", + "line": 26, + "declaration": "Wsec", + "qualified_declaration": "Sendov.PaperSecant.Wsec", + "kind": "def", + "signature": "noncomputable def Wsec (m : ℕ) (a : ℝ) : ℝ", + "blob": "d5a1481b495db34a9a82222596a45f36bc7a77a0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def Wsec (m : ℕ) (a : ℝ) : ℝ :=\n 1 / ((m : ℝ) + 1) + (PaperTaylor.beta a (S m a) 1) ^ (m / 2) +\n PaperTaylor.defect a (S m a) / (a * ((m : ℝ) - 2)) +\n 12 * (m : ℝ) * a ^ 2 * PaperTaylor.defect a (S m a) ^ 2 /\n (PaperTaylor.chord a (S m a) ^ 4 * ((m : ℝ) + 1) * ((m : ℝ) + 3))" + }, + { + "path": "Sendov/Analytic/PaperSecant.lean", + "line": 31, + "declaration": "Fsec", + "qualified_declaration": "Sendov.PaperSecant.Fsec", + "kind": "def", + "signature": "noncomputable def Fsec (m : ℕ) (a : ℝ) : ℝ", + "blob": "d5a1481b495db34a9a82222596a45f36bc7a77a0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def Fsec (m : ℕ) (a : ℝ) : ℝ := B m a - Wsec m a" + }, + { + "path": "Sendov/Analytic/PaperTwoEnd.lean", + "line": 17, + "declaration": "total", + "qualified_declaration": "Sendov.PaperTwoEnd.total", + "kind": "def", + "signature": "noncomputable def total (m a x : ℝ) : ℝ", + "blob": "80e4a5f2cf45619625301fcdd1501ff76b59329a", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def total (m a x : ℝ) : ℝ :=\n endpoint m a x + m * ∫ u in (0 : ℝ)..a, u * Q x u ^ ((m - 1) / 2)" + }, + { + "path": "Sendov/Analytic/PaperTwoEnd.lean", + "line": 16, + "declaration": "endpoint", + "qualified_declaration": "Sendov.PaperTwoEnd.endpoint", + "kind": "def", + "signature": "noncomputable def endpoint (m a x : ℝ) : ℝ", + "blob": "80e4a5f2cf45619625301fcdd1501ff76b59329a", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def endpoint (m a x : ℝ) : ℝ := Q x a ^ (m / 2)" + }, + { + "path": "Sendov/Analytic/PaperTwoEnd.lean", + "line": 15, + "declaration": "Q", + "qualified_declaration": "Sendov.PaperTwoEnd.Q", + "kind": "def", + "signature": "noncomputable def Q (x u : ℝ) : ℝ", + "blob": "80e4a5f2cf45619625301fcdd1501ff76b59329a", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def Q (x u : ℝ) : ℝ := 1 - 2 * x * u + u ^ 2" + }, + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 22, + "declaration": "h", + "qualified_declaration": "Sendov.PaperLegacyCertificates.h", + "kind": "def", + "signature": "noncomputable def h : ℝ", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def h : ℝ := 1 / 1000000000" + }, + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 23, + "declaration": "a", + "qualified_declaration": "Sendov.PaperLegacyCertificates.a", + "kind": "def", + "signature": "noncomputable def a : ℝ", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def a : ℝ := 999999999 / 1000000000" + }, + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 24, + "declaration": "rejectedX", + "qualified_declaration": "Sendov.PaperLegacyCertificates.rejectedX", + "kind": "def", + "signature": "noncomputable def rejectedX : ℝ", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def rejectedX : ℝ := 499999993298327 / 500000000000000" + }, + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 25, + "declaration": "upperX", + "qualified_declaration": "Sendov.PaperLegacyCertificates.upperX", + "kind": "def", + "signature": "noncomputable def upperX : ℝ", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def upperX : ℝ := a + 100 * h ^ 2" + }, + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 26, + "declaration": "legacyX", + "qualified_declaration": "Sendov.PaperLegacyCertificates.legacyX", + "kind": "def", + "signature": "noncomputable def legacyX : ℝ", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def legacyX : ℝ := a + 3 * h ^ 2" + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 19, + "declaration": "K", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.K", + "kind": "def", + "signature": "noncomputable def K {m : ℕ} (a : ℝ) (q : Fin m → ℂ) : ℂ", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def K {m : ℕ} (a : ℝ) (q : Fin m → ℂ) : ℂ :=\n ∫ t in (0 : ℝ)..1, ∏ j : Fin m, ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * q j)" + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 63, + "declaration": "x", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.x", + "kind": "def", + "signature": "noncomputable def x : ℝ", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def x : ℝ := 93 / 100" + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 64, + "declaration": "y", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.y", + "kind": "def", + "signature": "noncomputable def y : ℝ", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def y : ℝ := Real.sqrt (1 - x ^ 2)" + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 68, + "declaration": "q10", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.q10", + "kind": "def", + "signature": "noncomputable def q10 (j : Fin 10) : ℂ", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def q10 (j : Fin 10) : ℂ := if j.val % 2 = 0 then plus else minus" + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 216, + "declaration": "p", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.Nonroot.p", + "kind": "def", + "signature": "noncomputable def p : ℂ[X]", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def p : ℂ[X] := (X - C 1)^9 * (X + C 1)" + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 217, + "declaration": "marked", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.Nonroot.marked", + "kind": "def", + "signature": "noncomputable def marked : ℂ", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "noncomputable def marked : ℂ := ((-1/4 : ℝ) : ℂ)" + }, + { + "path": "Sendov/Analytic/PaperConjugate.lean", + "line": 14, + "declaration": "family", + "qualified_declaration": "Sendov.PaperConjugate.family", + "kind": "def", + "signature": "def family (n : ℕ) (x : ℝ) : Multiset ℂ", + "blob": "632d0e52fdadee2ba298663a8d330b2e727f46bf", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def family (n : ℕ) (x : ℝ) : Multiset ℂ :=\n Multiset.replicate n (plus x) + Multiset.replicate n (minus x)" + }, + { + "path": "Sendov/Analytic/PaperConjugate.lean", + "line": 93, + "declaration": "K", + "qualified_declaration": "Sendov.PaperConjugate.K", + "kind": "def", + "signature": "def K (n : ℕ) (a x : ℝ) : ℂ", + "blob": "632d0e52fdadee2ba298663a8d330b2e727f46bf", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def K (n : ℕ) (a x : ℝ) : ℂ :=\n ∫ t in (0 : ℝ)..1, ((family n x).map\n (fun q => (a : ℂ) + ((1-a^2)*t : ℝ)*q)).prod" + }, + { + "path": "Sendov/Analytic/PaperConjugate.lean", + "line": 97, + "declaration": "J", + "qualified_declaration": "Sendov.PaperConjugate.J", + "kind": "def", + "signature": "def J (n : ℕ) (a x : ℝ) : ℂ", + "blob": "632d0e52fdadee2ba298663a8d330b2e727f46bf", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_definition": "def J (n : ℕ) (a x : ℝ) : ℂ :=\n ((family n x).card+1 : ℂ) * (∫ t in (0 : ℝ)..1,\n ((family n x).map (fun q => 1 - (a : ℂ)*t*q)).prod)" + } + ], + "claims": [ + { + "id": "FO01", + "claim": "Division-free first-origin identity and closed bound |J|≤1 from both pointwise disk families", + "paper_sources": [ + "first-origin/REPORT.md:24-30,299-320" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Counterexample/Identities.lean", + "line": 230, + "declaration": "first_origin_identity", + "qualified_declaration": "Sendov.first_origin_identity", + "kind": "theorem", + "signature": "theorem first_origin_identity {p : ℂ[X]} (hc0 : c ≠ 0) (ha0 : a ≠ 0)\n (hzcard : z.card = n - 1) (hq0 : ∀ v ∈ q, v ≠ 0) (hpa : p.eval a = 0)\n (hpz : p = C c * ((X - C a) * (z.map (fun w => X - C w)).prod))\n (hpq : derivative p\n = C ((n : ℂ) * c) * ((q.map (fun v => a - v⁻¹)).map (fun w => X - C w)).prod) :\n (n : ℂ) * ∫ t in (0 : ℝ)..1, (q.map (fun v => 1 - a * (t : ℂ) * v)).prod\n = (-1) ^ (n - 1) * q.prod * z.prod", + "blob": "91f7da51b1f2a1996ebf7242958eca6b4baeaa93", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 36, + "text": "namespace Sendov" + }, + { + "line": 38, + "text": "open Polynomial Multiset" + }, + { + "line": 40, + "text": "open scoped Classical in" + }, + { + "line": 46, + "text": "variable {n : ℕ} {a c : ℂ} {z q : Multiset ℂ} {p : ℂ[X]}" + }, + { + "line": 104, + "text": "open scoped Classical in" + }, + { + "line": 151, + "text": "open scoped Classical in" + }, + { + "line": 190, + "text": "open MeasureTheory in" + }, + { + "line": 196, + "text": "open MeasureTheory in" + }, + { + "line": 226, + "text": "open MeasureTheory in" + } + ] + }, + { + "path": "Sendov/Analytic/FirstOriginSmall.lean", + "line": 49, + "declaration": "norm_integral_Fprod_le_of_first_origin", + "qualified_declaration": "Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_first_origin", + "kind": "lemma", + "signature": "lemma norm_integral_Fprod_le_of_first_origin {n : ℕ} (hn : 0 < n)\n {a : ℝ} {q z : Multiset ℂ}\n (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) (hz1 : ∀ v ∈ z, ‖v‖ ≤ 1)\n (hfirst : (n : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t) =\n (-1) ^ (n - 1) * q.prod * z.prod) :\n ‖∫ t in (0 : ℝ)..1, Fprod a q t‖ ≤ 1 / (n : ℝ)", + "blob": "f7170c9953a6ed1b6660dfe7efe692afe9bb74a7", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.FirstOriginSmall" + } + ] + }, + { + "path": "Sendov/Analytic/FirstOriginSmall.lean", + "line": 144, + "declaration": "norm_integral_Fprod_le_of_factorization", + "qualified_declaration": "Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_factorization", + "kind": "theorem", + "signature": "theorem norm_integral_Fprod_le_of_factorization\n {n : ℕ} (hn : 0 < n) {a : ℝ} (ha0 : a ≠ 0)\n {c : ℂ} (hc0 : c ≠ 0) {p : Polynomial ℂ} {q z : Multiset ℂ}\n (hzcard : z.card = n - 1) (hq0 : ∀ v ∈ q, v ≠ 0)\n (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) (hz1 : ∀ v ∈ z, ‖v‖ ≤ 1)\n (hpa : p.eval (a : ℂ) = 0)\n (hpz : p = Polynomial.C c * ((Polynomial.X - Polynomial.C (a : ℂ)) * (z.map (fun w => Polynomial.X - Polynomial.C w)).prod))\n (hpq : Polynomial.derivative p = Polynomial.C ((n : ℂ) * c) * ((q.map (fun v => (a : ℂ) - v⁻¹)).map\n (fun w => Polynomial.X - Polynomial.C w)).prod) :\n ‖∫ t in (0 : ℝ)..1, Fprod a q t‖ ≤ 1 / (n : ℝ)", + "blob": "f7170c9953a6ed1b6660dfe7efe692afe9bb74a7", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.FirstOriginSmall" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "FO02", + "claim": "Exact F derivative decomposition and integrated residual 1=F(1)+maμI+R", + "paper_sources": [ + "first-origin/REPORT.md:32-47" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "derived_corollary", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/Origin.lean", + "line": 275, + "declaration": "hasDerivAt_Fprod", + "qualified_declaration": "Sendov.hasDerivAt_Fprod", + "kind": "lemma", + "signature": "lemma hasDerivAt_Fprod (a t : ℝ) : ∀ (q : Multiset ℂ),\n HasDerivAt (Fprod a q)\n (-(a : ℂ) * sumEraseProdC q id (fun v => 1 - (a : ℂ) * (t : ℂ) * v)) t", + "blob": "f06d3725e21af74440649dc5e6d4ce196fb011af", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 54, + "text": "namespace Sendov" + }, + { + "line": 58, + "text": "open scoped Classical in" + }, + { + "line": 63, + "text": "open scoped Classical in" + }, + { + "line": 215, + "text": "open scoped Classical in" + }, + { + "line": 222, + "text": "open scoped Classical in" + }, + { + "line": 226, + "text": "open scoped Classical in" + } + ] + }, + { + "path": "Sendov/Analytic/Origin.lean", + "line": 261, + "declaration": "sumEraseProdC_id_eq", + "qualified_declaration": "Sendov.sumEraseProdC_id_eq", + "kind": "lemma", + "signature": "lemma sumEraseProdC_id_eq (a t : ℝ) : ∀ (q : Multiset ℂ),\n sumEraseProdC q id (fun v => 1 - (a : ℂ) * (t : ℂ) * v)\n = q.sum * Fprod a q t\n + (a : ℂ) * (t : ℂ) * sumEraseProdC q (fun v => v ^ 2)\n (fun v => 1 - (a : ℂ) * (t : ℂ) * v)", + "blob": "f06d3725e21af74440649dc5e6d4ce196fb011af", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 54, + "text": "namespace Sendov" + }, + { + "line": 58, + "text": "open scoped Classical in" + }, + { + "line": 63, + "text": "open scoped Classical in" + }, + { + "line": 215, + "text": "open scoped Classical in" + }, + { + "line": 222, + "text": "open scoped Classical in" + }, + { + "line": 226, + "text": "open scoped Classical in" + } + ] + }, + { + "path": "Sendov/Analytic/Origin.lean", + "line": 357, + "declaration": "one_le_tri", + "qualified_declaration": "Sendov.one_le_tri", + "kind": "theorem", + "signature": "theorem one_le_tri {n : ℕ} (hn : 2 ≤ n) {a x y : ℝ} {q : Multiset ℂ}\n (hqcard : q.card = n - 1) (hq0 : q ≠ 0) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) (ha0 : 0 ≤ a)\n (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x)\n (hsum : q.sum = ((n : ℂ) - 1) * ((x : ℂ) + (y : ℂ) * Complex.I)) :\n 1 ≤ ‖Fprod a q 1 + ((n : ℂ) - 1) * (a : ℂ) * ((x : ℂ) + (y : ℂ) * Complex.I)\n * ∫ t in (0 : ℝ)..1, Fprod a q t‖\n + a ^ 2 * ((n : ℝ) - 1)\n * ∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2)", + "blob": "f06d3725e21af74440649dc5e6d4ce196fb011af", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 54, + "text": "namespace Sendov" + }, + { + "line": 58, + "text": "open scoped Classical in" + }, + { + "line": 63, + "text": "open scoped Classical in" + }, + { + "line": 215, + "text": "open scoped Classical in" + }, + { + "line": 222, + "text": "open scoped Classical in" + }, + { + "line": 226, + "text": "open scoped Classical in" + } + ] + }, + { + "path": "Sendov/Analytic/Origin.lean", + "line": 340, + "declaration": "continuous_Fprod", + "qualified_declaration": "Sendov.continuous_Fprod", + "kind": "lemma", + "signature": "lemma continuous_Fprod (a : ℝ) (q : Multiset ℂ) : Continuous (Fprod a q)", + "blob": "f06d3725e21af74440649dc5e6d4ce196fb011af", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 54, + "text": "namespace Sendov" + }, + { + "line": 58, + "text": "open scoped Classical in" + }, + { + "line": 63, + "text": "open scoped Classical in" + }, + { + "line": 215, + "text": "open scoped Classical in" + }, + { + "line": 222, + "text": "open scoped Classical in" + }, + { + "line": 226, + "text": "open scoped Classical in" + } + ] + }, + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.derivative_decomposition", + "kind": "theorem" + }, + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.integrated_residual", + "kind": "theorem" + }, + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.integrated_residual_mean", + "kind": "theorem" + } + ], + "mapping_note": "Original mathematical recipe is now also an exported Lean contract; parent compilation and kernel receipt tag: final-corollaries.", + "corollary_recipe": "Let m=q.card>0, μ=q.sum/m, F(t)=Fprod a q t, I=∫₀¹F(t)dt, and S₂(t)=sumEraseProdC q (v↦v²) (v↦1−atv). Apply hasDerivAt_Fprod and substitute sumEraseProdC_id_eq: F′=−a q.sum F−a²t S₂. All functions are finite polynomial products, hence continuous and interval-integrable. FTC gives F(1)−1=−maμI−a²∫₀¹tS₂(t)dt. Define R=a²∫₀¹tS₂(t)dt and rearrange. This is precisely the hFTC/hG/hkey argument inside one_le_tri, not an inference that its inequality alone implies an equality.", + "remaining_contract": null, + "compiled_corollary_exports": [ + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.derivative_decomposition", + "kind": "theorem" + }, + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.integrated_residual", + "kind": "theorem" + }, + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.integrated_residual_mean", + "kind": "theorem" + } + ] + }, + { + "id": "FO03", + "claim": "Residual and endpoint norm majorants, hence 1≤T+[ma/(m+1)]|J| and under first-origin 1≤T+ma/(m+1)", + "paper_sources": [ + "first-origin/REPORT.md:43-57" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "derived_corollary", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/Origin.lean", + "line": 298, + "declaration": "norm_deriv_add_le", + "qualified_declaration": "Sendov.norm_deriv_add_le", + "kind": "theorem", + "signature": "theorem norm_deriv_add_le {n : ℕ} (hn : 2 ≤ n) {a x y t : ℝ} {q : Multiset ℂ}\n (hqcard : q.card = n - 1) (hq0 : q ≠ 0) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1)\n (ha0 : 0 ≤ a) (ht0 : 0 ≤ t)\n (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x)\n (hsum : q.sum = (((n : ℝ) - 1) : ℂ) * ((x : ℂ) + (y : ℂ) * Complex.I)) :\n ‖(-(a : ℂ) * sumEraseProdC q id (fun v => 1 - (a : ℂ) * (t : ℂ) * v))\n + (((n : ℝ) - 1) : ℂ) * (a : ℂ) * ((x : ℂ) + (y : ℂ) * Complex.I) * Fprod a q t‖\n ≤ a ^ 2 * t * ((n : ℝ) - 1) * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2)", + "blob": "f06d3725e21af74440649dc5e6d4ce196fb011af", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 54, + "text": "namespace Sendov" + }, + { + "line": 58, + "text": "open scoped Classical in" + }, + { + "line": 63, + "text": "open scoped Classical in" + }, + { + "line": 215, + "text": "open scoped Classical in" + }, + { + "line": 222, + "text": "open scoped Classical in" + }, + { + "line": 226, + "text": "open scoped Classical in" + } + ] + }, + { + "path": "Sendov/Analytic/Origin.lean", + "line": 357, + "declaration": "one_le_tri", + "qualified_declaration": "Sendov.one_le_tri", + "kind": "theorem", + "signature": "theorem one_le_tri {n : ℕ} (hn : 2 ≤ n) {a x y : ℝ} {q : Multiset ℂ}\n (hqcard : q.card = n - 1) (hq0 : q ≠ 0) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) (ha0 : 0 ≤ a)\n (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x)\n (hsum : q.sum = ((n : ℂ) - 1) * ((x : ℂ) + (y : ℂ) * Complex.I)) :\n 1 ≤ ‖Fprod a q 1 + ((n : ℂ) - 1) * (a : ℂ) * ((x : ℂ) + (y : ℂ) * Complex.I)\n * ∫ t in (0 : ℝ)..1, Fprod a q t‖\n + a ^ 2 * ((n : ℝ) - 1)\n * ∫ t in (0 : ℝ)..1, t * QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 2) / 2)", + "blob": "f06d3725e21af74440649dc5e6d4ce196fb011af", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 54, + "text": "namespace Sendov" + }, + { + "line": 58, + "text": "open scoped Classical in" + }, + { + "line": 63, + "text": "open scoped Classical in" + }, + { + "line": 215, + "text": "open scoped Classical in" + }, + { + "line": 222, + "text": "open scoped Classical in" + }, + { + "line": 226, + "text": "open scoped Classical in" + } + ] + }, + { + "path": "Sendov/Analytic/FirstOriginSmall.lean", + "line": 13, + "declaration": "norm_Fprod_le", + "qualified_declaration": "Sendov.FirstOriginSmall.norm_Fprod_le", + "kind": "lemma", + "signature": "lemma norm_Fprod_le {n : ℕ} (hn : 2 ≤ n) {a x t : ℝ} {q : Multiset ℂ}\n (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1)\n (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x)\n (hb : 0 ≤ QQ (a * x) (a ^ 2) t) :\n ‖Fprod a q t‖ ≤ QQ (a * x) (a ^ 2) t ^ (((n : ℝ) - 1) / 2)", + "blob": "f7170c9953a6ed1b6660dfe7efe692afe9bb74a7", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.FirstOriginSmall" + } + ] + }, + { + "path": "Sendov/Analytic/FirstOriginBudget.lean", + "line": 14, + "declaration": "lower_budget", + "qualified_declaration": "Sendov.FirstOriginBudget.lower_budget", + "kind": "theorem", + "signature": "theorem lower_budget {n : ℕ} (hn : 2 ≤ n) {a x y : ℝ} {q : Multiset ℂ}\n (ha : 0 < a) (ha1 : a < 1) (hx1 : x ≤ 1)\n (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1)\n (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x)\n (hsum : q.sum = ((n : ℂ) - 1) * ((x : ℂ) + (y : ℂ) * Complex.I))\n (hfirst : ‖∫ t in (0 : ℝ)..1, Fprod a q t‖ ≤ 1 / (n : ℝ)) :\n 1 ≤ PaperTaylor.budget ((n : ℝ) - 1) a x + a * ((n : ℝ) - 1) / (n : ℝ)", + "blob": "aed9631b5d52531251e4780e658126e33e15761d", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 7, + "text": "namespace Sendov.FirstOriginBudget" + } + ] + }, + { + "path": "Sendov/Analytic/FirstOriginMargins.lean", + "line": 135, + "declaration": "lower_budget_norm", + "qualified_declaration": "Sendov.FirstOriginMargins.lower_budget_norm", + "kind": "theorem", + "signature": "theorem lower_budget_norm {n : ℕ} (hn : 2 ≤ n) {a x y : ℝ} {q : Multiset ℂ}\n (ha : 0 ≤ a)\n (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1)\n (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x)\n (hsum : q.sum = ((n : ℂ) - 1) * ((x : ℂ) + (y : ℂ) * Complex.I))\n (hβ : 0 ≤ QQ (a * x) (a ^ 2) 1) :\n 1 ≤ T ((n : ℝ) - 1) a x + a * ((n : ℝ) - 1) / (n : ℝ) *\n ‖(n : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖", + "blob": "c0c69554b4e7678e1f5c9b17ba8eb71e0234f34f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 11, + "text": "namespace Sendov.FirstOriginMargins" + }, + { + "line": 13, + "text": "open FirstOriginSmall" + } + ] + }, + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.norm_majorants", + "kind": "theorem" + }, + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.norm_budget", + "kind": "theorem" + }, + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.first_origin_budget", + "kind": "theorem" + } + ], + "mapping_note": "Original mathematical recipe is now also an exported Lean contract; parent compilation and kernel receipt tag: final-corollaries.", + "corollary_recipe": "Use n=m+1, μ=x+iy=q.sum/m. Apply norm_deriv_add_le pointwise on t∈[0,1] and integrate to obtain |R|≤ma²∫tβ(t)^((m−1)/2); apply norm_Fprod_le at t=1 for |F(1)|≤β(1)^(m/2). FO02 and |μ|≤1 give 1≤T+ma|I|=T+ma/(m+1)|J|. This latter inequality is now directly lower_budget_norm, with β(1)≥(1−a)²≥0 from x≤1. For first-origin |J|≤1 use FO01, or apply lower_budget to its equivalent |I|≤1/(m+1).", + "remaining_contract": null, + "compiled_corollary_exports": [ + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.norm_majorants", + "kind": "theorem" + }, + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.norm_budget", + "kind": "theorem" + }, + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.first_origin_budget", + "kind": "theorem" + } + ] + }, + { + "id": "FO04", + "claim": "Polar identities and hierarchy 1≤|K|≤∫∏|a+δtq|≤∫P_x^(m/2)", + "paper_sources": [ + "first-origin/REPORT.md:59-73" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "derived_corollary", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Counterexample/Identities.lean", + "line": 299, + "declaration": "prod_sub_mul_prod", + "qualified_declaration": "Sendov.prod_sub_mul_prod", + "kind": "theorem", + "signature": "theorem prod_sub_mul_prod (hc0 : c ≠ 0) (hq0 : ∀ v ∈ q, v ≠ 0)\n (hpz : p = C c * ((X - C a) * (z.map (fun w => X - C w)).prod))\n (hpq : derivative p\n = C ((n : ℂ) * c) * ((q.map (fun v => a - v⁻¹)).map (fun w => X - C w)).prod) :\n q.prod * (z.map (fun w => a - w)).prod = (n : ℂ)", + "blob": "91f7da51b1f2a1996ebf7242958eca6b4baeaa93", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 36, + "text": "namespace Sendov" + }, + { + "line": 38, + "text": "open Polynomial Multiset" + }, + { + "line": 40, + "text": "open scoped Classical in" + }, + { + "line": 46, + "text": "variable {n : ℕ} {a c : ℂ} {z q : Multiset ℂ} {p : ℂ[X]}" + }, + { + "line": 104, + "text": "open scoped Classical in" + }, + { + "line": 151, + "text": "open scoped Classical in" + }, + { + "line": 190, + "text": "open MeasureTheory in" + }, + { + "line": 196, + "text": "open MeasureTheory in" + }, + { + "line": 226, + "text": "open MeasureTheory in" + } + ] + }, + { + "path": "Sendov/Counterexample/Identities.lean", + "line": 332, + "declaration": "polar_identity", + "qualified_declaration": "Sendov.polar_identity", + "kind": "theorem", + "signature": "theorem polar_identity (hc0 : c ≠ 0) (ha0 : a ≠ 0) (ha2 : a ^ 2 ≠ 1)\n (hzcard : z.card = n - 1) (hqcard : q.card = n - 1) (hq0 : ∀ v ∈ q, v ≠ 0)\n (hpa : p.eval a = 0)\n (hpz : p = C c * ((X - C a) * (z.map (fun w => X - C w)).prod))\n (hpq : derivative p\n = C ((n : ℂ) * c) * ((q.map (fun v => a - v⁻¹)).map (fun w => X - C w)).prod) :\n q.prod * (z.map (fun w => 1 - a * w)).prod\n = (n : ℂ) * ∫ t in (0 : ℝ)..1,\n (q.map (fun v => a + (t : ℂ) * (1 - a ^ 2) * v)).prod", + "blob": "91f7da51b1f2a1996ebf7242958eca6b4baeaa93", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 36, + "text": "namespace Sendov" + }, + { + "line": 38, + "text": "open Polynomial Multiset" + }, + { + "line": 40, + "text": "open scoped Classical in" + }, + { + "line": 46, + "text": "variable {n : ℕ} {a c : ℂ} {z q : Multiset ℂ} {p : ℂ[X]}" + }, + { + "line": 104, + "text": "open scoped Classical in" + }, + { + "line": 151, + "text": "open scoped Classical in" + }, + { + "line": 190, + "text": "open MeasureTheory in" + }, + { + "line": 196, + "text": "open MeasureTheory in" + }, + { + "line": 226, + "text": "open MeasureTheory in" + }, + { + "line": 328, + "text": "open MeasureTheory in" + } + ] + }, + { + "path": "Sendov/Analytic/Polar.lean", + "line": 93, + "declaration": "one_le_integral_prod_norm", + "qualified_declaration": "Sendov.one_le_integral_prod_norm", + "kind": "theorem", + "signature": "theorem one_le_integral_prod_norm {n : ℕ} (hn : 2 ≤ n) {a : ℝ} (ha : |a| ≤ 1)\n {z q : Multiset ℂ} (hz : ∀ w ∈ z, ‖w‖ ≤ 1)\n (hpolar : q.prod * (z.map (fun w => 1 - (a : ℂ) * w)).prod\n = (n : ℂ) * ∫ t in (0 : ℝ)..1,\n (q.map (fun v => (a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v)).prod)\n (hdenom : q.prod * (z.map (fun w => (a : ℂ) - w)).prod = (n : ℂ)) :\n 1 ≤ ∫ t in (0 : ℝ)..1,\n (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod", + "blob": "932fec570996fe54c72608f801e8920f9bcbf69a", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 41, + "text": "namespace Sendov" + }, + { + "line": 43, + "text": "open Polynomial MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/Polar.lean", + "line": 237, + "declaration": "one_le_integral_Ppolar", + "qualified_declaration": "Sendov.one_le_integral_Ppolar", + "kind": "theorem", + "signature": "theorem one_le_integral_Ppolar {n : ℕ} (hn : 2 ≤ n) {a x : ℝ}\n {q : Multiset ℂ} (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1)\n (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x)\n (hstar : 1 ≤ ∫ t in (0 : ℝ)..1,\n (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) :\n 1 ≤ ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)", + "blob": "932fec570996fe54c72608f801e8920f9bcbf69a", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 41, + "text": "namespace Sendov" + }, + { + "line": 43, + "text": "open Polynomial MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/Polar.lean", + "line": 50, + "declaration": "norm_sub_le_norm_one_sub_mul", + "qualified_declaration": "Sendov.norm_sub_le_norm_one_sub_mul", + "kind": "lemma", + "signature": "lemma norm_sub_le_norm_one_sub_mul {a : ℝ} (ha : |a| ≤ 1) {z : ℂ} (hz : ‖z‖ ≤ 1) :\n ‖(a : ℂ) - z‖ ≤ ‖1 - (a : ℂ) * z‖", + "blob": "932fec570996fe54c72608f801e8920f9bcbf69a", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 41, + "text": "namespace Sendov" + }, + { + "line": 43, + "text": "open Polynomial MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/Polar.lean", + "line": 72, + "declaration": "prod_map_le_of_le", + "qualified_declaration": "Sendov.prod_map_le_of_le", + "kind": "lemma", + "signature": "lemma prod_map_le_of_le {s : Multiset ℂ} {f g : ℂ → ℂ} (h : ∀ w ∈ s, ‖f w‖ ≤ ‖g w‖) :\n (s.map (fun w => ‖f w‖)).prod ≤ (s.map (fun w => ‖g w‖)).prod", + "blob": "932fec570996fe54c72608f801e8920f9bcbf69a", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 41, + "text": "namespace Sendov" + }, + { + "line": 43, + "text": "open Polynomial MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/Polar.lean", + "line": 79, + "declaration": "norm_prod_map", + "qualified_declaration": "Sendov.norm_prod_map", + "kind": "lemma", + "signature": "lemma norm_prod_map (s : Multiset ℂ) (f : ℂ → ℂ) :\n ‖(s.map f).prod‖ = (s.map (fun w => ‖f w‖)).prod", + "blob": "932fec570996fe54c72608f801e8920f9bcbf69a", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 41, + "text": "namespace Sendov" + }, + { + "line": 43, + "text": "open Polynomial MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/Polar.lean", + "line": 172, + "declaration": "prod_norm_le_Ppolar", + "qualified_declaration": "Sendov.prod_norm_le_Ppolar", + "kind": "lemma", + "signature": "lemma prod_norm_le_Ppolar {n : ℕ} (hn : 2 ≤ n) {a x t : ℝ}\n {q : Multiset ℂ} (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1)\n (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x) :\n (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod\n ≤ Ppolar a x t ^ (((n : ℝ) - 1) / 2)", + "blob": "932fec570996fe54c72608f801e8920f9bcbf69a", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 41, + "text": "namespace Sendov" + }, + { + "line": 43, + "text": "open Polynomial MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.polar_hierarchy", + "kind": "theorem" + }, + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.polar_factorization_hierarchy", + "kind": "theorem" + } + ], + "mapping_note": "Original mathematical recipe is now also an exported Lean contract; parent compilation and kernel receipt tag: final-corollaries.", + "corollary_recipe": "Set n=m+1 and K=∫∏(a+δtqj), δ=1−a². Apply prod_sub_mul_prod and polar_identity to the actual root/derivative factorizations. For each root z, norm_sub_le_norm_one_sub_mul gives |a−z|≤|1−az|. Multiply with prod_map_le_of_le and then by |q.prod|; take norms of both identities with norm_prod_map to get n≤n|K|. Cancel positive n. The norm-integral triangle inequality and norm_prod_map give |K|≤∫∏|a+δtqj|. Integrate prod_norm_le_Ppolar at n=m+1 and actual real mean x for the final upper bound. All integrands are continuous finite products or nonnegative quadratic real powers. This retains the full hierarchy, not only exported weaker one_le_integral_* inequalities.", + "remaining_contract": null, + "compiled_corollary_exports": [ + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.polar_hierarchy", + "kind": "theorem" + }, + { + "path": "Sendov/Analytic/PaperOriginCorollaries.lean", + "qualified_declaration": "Sendov.PaperOriginCorollaries.polar_factorization_hierarchy", + "kind": "theorem" + } + ] + }, + { + "id": "FO05", + "claim": "Finite mean/variance facts |μ|≤1, s≤1, v=s−|μ|² and |κ|≤v", + "paper_sources": [ + "first-origin/REPORT.md:18,240,283-297" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "derived_corollary", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/FirstOriginSmall.lean", + "line": 8, + "declaration": "norm_sum_le_card", + "qualified_declaration": "Sendov.FirstOriginSmall.norm_sum_le_card", + "kind": "lemma", + "signature": "lemma norm_sum_le_card (q : Multiset ℂ) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) :\n ‖q.sum‖ ≤ (q.card : ℝ)", + "blob": "f7170c9953a6ed1b6660dfe7efe692afe9bb74a7", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.FirstOriginSmall" + } + ] + }, + { + "path": "Sendov/Analytic/Polar.lean", + "line": 155, + "declaration": "sum_norm_sq_le_card", + "qualified_declaration": "Sendov.sum_norm_sq_le_card", + "kind": "lemma", + "signature": "lemma sum_norm_sq_le_card (q : Multiset ℂ) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1) :\n (q.map (fun v => ‖v‖ ^ 2)).sum ≤ (q.card : ℝ)", + "blob": "932fec570996fe54c72608f801e8920f9bcbf69a", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 41, + "text": "namespace Sendov" + }, + { + "line": 43, + "text": "open Polynomial MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 281, + "declaration": "norm_kappa_le_variance", + "qualified_declaration": "Sendov.PaperCentered.norm_kappa_le_variance", + "kind": "theorem", + "signature": "theorem norm_kappa_le_variance (r : Multiset ℂ) : ‖kappa r‖ ≤ variance r", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 7, + "text": "noncomputable section" + }, + { + "line": 8, + "text": "open scoped BigOperators" + }, + { + "line": 9, + "text": "open Polynomial" + }, + { + "line": 10, + "text": "namespace Sendov.PaperCentered" + } + ] + }, + { + "path": "Sendov/Analytic/PaperCoefficient.lean", + "line": 107, + "declaration": "sum_norm_add_sq", + "qualified_declaration": "Sendov.PaperCoefficient.sum_norm_add_sq", + "kind": "theorem", + "signature": "theorem sum_norm_add_sq (r : Multiset ℂ) (z : ℂ) :\n (r.map (fun w ↦ ‖z + w‖ ^ 2)).sum =\n r.card * ‖z‖ ^ 2 + (r.map (fun w ↦ ‖w‖ ^ 2)).sum +\n 2 * (z * (starRingEnd ℂ) r.sum).re", + "blob": "10efaefe8bff8f3983fd269047f8f5f3dfa64ad5", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 18, + "text": "open scoped BigOperators" + }, + { + "line": 19, + "text": "open Polynomial Complex" + }, + { + "line": 20, + "text": "open scoped Real" + }, + { + "line": 22, + "text": "namespace Sendov.PaperCoefficient" + } + ] + }, + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "line": 138, + "declaration": "centered_variance_le", + "qualified_declaration": "Sendov.PaperConsequences.centered_variance_le", + "kind": "theorem", + "signature": "theorem centered_variance_le (q : Multiset ℂ) (μ : ℂ) (hm : 0 < q.card)\n (hmean : q.sum = q.card * μ) (hq : ∀ v ∈ q, ‖v‖ ≤ 1) :\n PaperCentered.variance (q.map (fun v => v - μ)) ≤ 1 - ‖μ‖ ^ 2 ∧ ‖μ‖ ≤ 1", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "noncomputable section" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 18, + "text": "open Polynomial Filter" + }, + { + "line": 19, + "text": "namespace Sendov.PaperConsequences" + } + ] + }, + { + "path": "Sendov/Analytic/PaperMomentCorollaries.lean", + "qualified_declaration": "Sendov.PaperMomentCorollaries.FO05", + "kind": "theorem" + } + ], + "mapping_note": "Original mathematical recipe is now also an exported Lean contract; parent compilation and kernel receipt tag: final-corollaries.", + "corollary_recipe": "For m=q.card>0, set μ=q.sum/m, r=q.map(v↦v−μ), s=(Σ|qj|²)/m and v=variance r. Finite-sum linearity gives r.sum=0. Divide norm_sum_le_card and sum_norm_sq_le_card by m to obtain |μ|≤1 and s≤1. Apply sum_norm_add_sq to (r,μ): its cross term vanishes and μ+(qj−μ)=qj, giving Σ|qj|²=m|μ|²+Σ|qj−μ|². Divide by m to get v=s−|μ|². Apply norm_kappa_le_variance to r. centered_variance_le independently exports v≤1−|μ|² and |μ|≤1.", + "remaining_contract": null, + "compiled_corollary_exports": [ + { + "path": "Sendov/Analytic/PaperMomentCorollaries.lean", + "qualified_declaration": "Sendov.PaperMomentCorollaries.FO05", + "kind": "theorem" + } + ] + }, + { + "id": "FO06", + "claim": "For m=5,6 raw polar forces x>(1+a)/2; cubic deficit bounds 23h²/35 and 23h²/42", + "paper_sources": [ + "first-origin/REPORT.md:75-101" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "derived_corollary", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/FirstOriginBounds.lean", + "line": 31, + "declaration": "polar_mean_gt_half_add_one", + "qualified_declaration": "Sendov.FirstOriginSmall.polar_mean_gt_half_add_one", + "kind": "lemma", + "signature": "lemma polar_mean_gt_half_add_one {n : ℕ} (hn : n = 6 ∨ n = 7) {a x : ℝ}\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x)\n (hpolar : 1 ≤ ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2)) :\n (1 + a) / 2 < x", + "blob": "39563a6a6a04cdebfd789068642058f8b9966cae", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.FirstOriginSmall" + } + ] + }, + { + "path": "Sendov/Analytic/FirstOriginAlgebra.lean", + "line": 60, + "declaration": "polar_cube_integral", + "qualified_declaration": "Sendov.FirstOriginSmall.polar_cube_integral", + "kind": "lemma", + "signature": "lemma polar_cube_integral (a : ℝ) :\n 1 - (∫ t in (0 : ℝ)..1, Ppolar a ((1 + a) / 2) t ^ (3 : ℕ)) = (1 - a) ^ 2 * Q a / 140", + "blob": "d916c3264d120623b21039f3df26b81ade7af025", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.FirstOriginSmall" + } + ] + }, + { + "path": "Sendov/Analytic/FirstOriginAlgebra.lean", + "line": 70, + "declaration": "Q_lower", + "qualified_declaration": "Sendov.FirstOriginSmall.Q_lower", + "kind": "lemma", + "signature": "lemma Q_lower {a : ℝ} (ha0 : 0 ≤ a) (ha1 : a ≤ 1) : 92 ≤ Q a", + "blob": "d916c3264d120623b21039f3df26b81ade7af025", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.FirstOriginSmall" + } + ] + }, + { + "path": "Sendov/Analytic/FirstOriginAlgebra.lean", + "line": 86, + "declaration": "fifth_sixth_majorant", + "qualified_declaration": "Sendov.FirstOriginSmall.fifth_sixth_majorant", + "kind": "lemma", + "signature": "lemma fifth_sixth_majorant {y : ℝ} (hy : 0 ≤ y) : 6 * y ^ 5 ≤ 1 + 5 * y ^ 6", + "blob": "d916c3264d120623b21039f3df26b81ade7af025", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.FirstOriginSmall" + } + ] + }, + { + "path": "Sendov/Analytic/FirstOriginBounds.lean", + "line": 14, + "declaration": "Ppolar_nonneg_small", + "qualified_declaration": "Sendov.FirstOriginSmall.Ppolar_nonneg_small", + "kind": "lemma", + "signature": "lemma Ppolar_nonneg_small {a x t : ℝ} (ha : 0 ≤ a) (ha1 : a ≤ 1)\n (hx : -1 ≤ x) (ht : 0 ≤ t) : 0 ≤ Ppolar a x t", + "blob": "39563a6a6a04cdebfd789068642058f8b9966cae", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.FirstOriginSmall" + } + ] + }, + { + "path": "Sendov/Reduction/Setup.lean", + "line": 34, + "declaration": "continuous_Ppolar", + "qualified_declaration": "Sendov.continuous_Ppolar", + "kind": "lemma", + "signature": "lemma continuous_Ppolar (a x : ℝ) : Continuous fun t : ℝ => Ppolar a x t", + "blob": "eced975e75a01a791465bdc28c98d0ef34cf5fb9", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "namespace Sendov" + }, + { + "line": 22, + "text": "variable {n : ℕ} {a x t α : ℝ}" + } + ] + }, + { + "path": "Sendov/Analytic/PaperMomentCorollaries.lean", + "qualified_declaration": "Sendov.PaperMomentCorollaries.FO06", + "kind": "theorem" + }, + { + "path": "Sendov/Analytic/PaperMomentCorollaries.lean", + "qualified_declaration": "Sendov.PaperMomentCorollaries.FO06_five", + "kind": "theorem" + }, + { + "path": "Sendov/Analytic/PaperMomentCorollaries.lean", + "qualified_declaration": "Sendov.PaperMomentCorollaries.FO06_six", + "kind": "theorem" + } + ], + "mapping_note": "Original mathematical recipe is now also an exported Lean contract; parent compilation and kernel receipt tag: final-corollaries.", + "corollary_recipe": "Put x₀=(1+a)/2. polar_cube_integral and Q_lower give ∫P₀³≤1−(92/140)h²=1−23h²/35. For x≤x₀,t∈[0,1], P₀−P_x=2a(1−a²)(x₀−x)t≥0; nonnegativity is Ppolar_nonneg_small, so the same bound holds for m=6. For m=5 apply fifth_sixth_majorant at y=sqrt(P₀(t)), integrate 6P₀^(5/2)≤1+5P₀³, and obtain deficit (5/6)(23/35)h²=23h²/42. Monotonicity extends to x≤x₀. Under raw polar≥1 and 0 ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod)\n (hfirst_bound : ‖∫ t in (0 : ℝ)..1, Sendov.Fprod a q t‖ ≤ 1 / (n : ℝ)) :\n False", + "blob": "f7170c9953a6ed1b6660dfe7efe692afe9bb74a7", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.FirstOriginSmall" + } + ] + } + ], + "mapping_note": "Already wired before centroid/second-origin; not a replacement of the remaining n≥8 proof.", + "corollary_recipe": null, + "remaining_contract": null, + "consumer_evidence": [ + { + "path": "Sendov/Interior.lean", + "line": 101, + "source_excerpt": " (p := p) hc0 hq0 hpz hpq')\n -- the branch: low degree needs nothing further\n rcases (by omega : n ≤ 5 ∨ 6 ≤ n) with hn5 | hn6\n · exact low_degree_contradiction hn hn5 ha0 ha1 hqcard hq1 hstar\n by_cases hn67 : n = 6 ∨ n = 7\n · exact FirstOriginSmall.first_origin_polar_six_seven hn67 ha0 ha1 hqcard hq1 hstar\n (FirstOriginSmall.norm_integral_Fprod_le_of_factorization (by omega) (ne_of_gt ha0)", + "blob": "ce28aada7a4679579e08d1e65f9a939d7df2b8e8", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d" + } + ] + }, + { + "id": "FO10", + "claim": "Quantitative A5≥1/16 and A6≥93/560 on [0,1]", + "paper_sources": [ + "first-origin/REPORT.md:153-157" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "inflight", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/FirstOriginMargins.lean", + "line": 37, + "declaration": "A5_lower", + "qualified_declaration": "Sendov.FirstOriginMargins.A5_lower", + "kind": "lemma", + "signature": "lemma A5_lower {a : ℝ} (ha0 : 0 ≤ a) (ha1 : a ≤ 1) : 1 / 16 ≤ A5 a", + "blob": "c0c69554b4e7678e1f5c9b17ba8eb71e0234f34f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 11, + "text": "namespace Sendov.FirstOriginMargins" + }, + { + "line": 13, + "text": "open FirstOriginSmall" + } + ] + }, + { + "path": "Sendov/Analytic/FirstOriginMargins.lean", + "line": 42, + "declaration": "A6_lower", + "qualified_declaration": "Sendov.FirstOriginMargins.A6_lower", + "kind": "lemma", + "signature": "lemma A6_lower {a : ℝ} (ha0 : 0 ≤ a) (ha1 : a ≤ 1) : 93 / 560 ≤ A6 a", + "blob": "c0c69554b4e7678e1f5c9b17ba8eb71e0234f34f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 11, + "text": "namespace Sendov.FirstOriginMargins" + }, + { + "line": 13, + "text": "open FirstOriginSmall" + } + ] + } + ], + "mapping_note": "Exact closed [0,1] coefficient constants; no desired bound assumed.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "FO11", + "claim": "Pointwise+polar gives |J|≥1+(3/40)h for m=5 and ≥1+(31/160)h for m=6", + "paper_sources": [ + "first-origin/REPORT.md:159-164" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "inflight", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/FirstOriginMargins.lean", + "line": 243, + "declaration": "norm_J_six", + "qualified_declaration": "Sendov.FirstOriginMargins.norm_J_six", + "kind": "theorem", + "signature": "theorem norm_J_six {a : ℝ} (ha0 : 0 < a) (ha1 : a < 1) {q : Multiset ℂ}\n (hqcard : q.card = 6 - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1)\n (hstar : 1 ≤ ∫ t in (0 : ℝ)..1,\n (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) :\n 1 + (3 / 40 : ℝ) * (1 - a) ≤\n ‖(6 : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖", + "blob": "c0c69554b4e7678e1f5c9b17ba8eb71e0234f34f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 11, + "text": "namespace Sendov.FirstOriginMargins" + }, + { + "line": 13, + "text": "open FirstOriginSmall" + } + ] + }, + { + "path": "Sendov/Analytic/FirstOriginMargins.lean", + "line": 264, + "declaration": "norm_J_seven", + "qualified_declaration": "Sendov.FirstOriginMargins.norm_J_seven", + "kind": "theorem", + "signature": "theorem norm_J_seven {a : ℝ} (ha0 : 0 < a) (ha1 : a < 1) {q : Multiset ℂ}\n (hqcard : q.card = 7 - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1)\n (hstar : 1 ≤ ∫ t in (0 : ℝ)..1,\n (q.map (fun v => ‖(a : ℂ) + (t : ℂ) * (1 - (a : ℂ) ^ 2) * v‖)).prod) :\n 1 + (31 / 160 : ℝ) * (1 - a) ≤\n ‖(7 : ℂ) * (∫ t in (0 : ℝ)..1, Fprod a q t)‖", + "blob": "c0c69554b4e7678e1f5c9b17ba8eb71e0234f34f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 11, + "text": "namespace Sendov.FirstOriginMargins" + }, + { + "line": 13, + "text": "open FirstOriginSmall" + } + ] + } + ], + "mapping_note": "Set n=m+1. The source takes pointwise disk and integral-of-product-norm polar, not first-origin |J|≤1; full-complex polar implies that polar premise by the norm-integral inequality. Hence the norm lower bounds are nonvacuous, not deductions from contradiction.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "CE01", + "claim": "Full finite centered expansion with every k≤m, exact B/H endpoint terms and binomial factors", + "paper_sources": [ + "first-origin/REPORT.md:193-211" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 41, + "declaration": "centered_product", + "qualified_declaration": "Sendov.PaperCentered.centered_product", + "kind": "theorem", + "signature": "theorem centered_product (q : Multiset ℂ) (a μ : ℂ) (t : ℝ) :\n (q.map (fun v => 1 - a * t * v)).prod =\n ∑ k ∈ Finset.range (q.card + 1), (-a) ^ k *\n (q.map (fun v => v - μ)).esymm k * (t : ℂ) ^ k *\n (1 - a * μ * t) ^ (q.card - k)", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 7, + "text": "noncomputable section" + }, + { + "line": 8, + "text": "open scoped BigOperators" + }, + { + "line": 9, + "text": "open Polynomial" + }, + { + "line": 10, + "text": "namespace Sendov.PaperCentered" + } + ] + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 135, + "declaration": "finite_beta", + "qualified_declaration": "Sendov.PaperCentered.finite_beta", + "kind": "theorem", + "signature": "theorem finite_beta (m k : ℕ) (hk : k ≤ m) (z : ℂ) :\n ((m + 1) * (m.choose k : ℂ) * z ^ (k + 1)) *\n (∫ t in (0 : ℝ)..1, (t : ℂ) ^ k * (1 - z * t) ^ (m - k)) = H m k z", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 7, + "text": "noncomputable section" + }, + { + "line": 8, + "text": "open scoped BigOperators" + }, + { + "line": 9, + "text": "open Polynomial" + }, + { + "line": 10, + "text": "namespace Sendov.PaperCentered" + } + ] + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 160, + "declaration": "centered_integral", + "qualified_declaration": "Sendov.PaperCentered.centered_integral", + "kind": "theorem", + "signature": "theorem centered_integral (q : Multiset ℂ) (a μ : ℂ) (hμ : μ ≠ 0) :\n (q.card + 1) * (a * μ) *\n (∫ t in (0 : ℝ)..1, (q.map (fun v => 1 - a * t * v)).prod) =\n ∑ k ∈ Finset.range (q.card + 1),\n coeff (q.map (fun v => v - μ)) μ k * H q.card k (a * μ)", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 7, + "text": "noncomputable section" + }, + { + "line": 8, + "text": "open scoped BigOperators" + }, + { + "line": 9, + "text": "open Polynomial" + }, + { + "line": 10, + "text": "namespace Sendov.PaperCentered" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "CE02", + "claim": "Exact second-order expansion (m+1)aμI=1−κ/((m−1)μ²)+ε with e1=0 and e2=−mκ/2", + "paper_sources": [ + "first-origin/REPORT.md:195-211" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 216, + "declaration": "coeff_one", + "qualified_declaration": "Sendov.PaperCentered.coeff_one", + "kind": "theorem", + "signature": "theorem coeff_one (r : Multiset ℂ) (μ : ℂ) (hr : r.sum = 0) : coeff r μ 1 = 0", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 7, + "text": "noncomputable section" + }, + { + "line": 8, + "text": "open scoped BigOperators" + }, + { + "line": 9, + "text": "open Polynomial" + }, + { + "line": 10, + "text": "namespace Sendov.PaperCentered" + } + ] + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 220, + "declaration": "coeff_two", + "qualified_declaration": "Sendov.PaperCentered.coeff_two", + "kind": "theorem", + "signature": "theorem coeff_two (r : Multiset ℂ) (μ : ℂ) (hm : 2 ≤ r.card)\n (hr : r.sum = 0) (hμ : μ ≠ 0) : coeff r μ 2 = -correction r μ", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 7, + "text": "noncomputable section" + }, + { + "line": 8, + "text": "open scoped BigOperators" + }, + { + "line": 9, + "text": "open Polynomial" + }, + { + "line": 10, + "text": "namespace Sendov.PaperCentered" + } + ] + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 251, + "declaration": "second_order", + "qualified_declaration": "Sendov.PaperCentered.second_order", + "kind": "theorem", + "signature": "theorem second_order (q : Multiset ℂ) (a μ : ℂ) (hm : 2 ≤ q.card)\n (hmean : q.sum = q.card * μ) (hμ : μ ≠ 0) :\n (q.card + 1) * (a * μ) *\n (∫ t in (0 : ℝ)..1, (q.map (fun v => 1 - a * t * v)).prod) =\n 1 - correction (q.map (fun v => v - μ)) μ +\n epsilon (q.map (fun v => v - μ)) μ (a * μ)", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 7, + "text": "noncomputable section" + }, + { + "line": 8, + "text": "open scoped BigOperators" + }, + { + "line": 9, + "text": "open Polynomial" + }, + { + "line": 10, + "text": "namespace Sendov.PaperCentered" + } + ] + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 68, + "declaration": "two_mul_esymm_two", + "qualified_declaration": "Sendov.PaperCentered.two_mul_esymm_two", + "kind": "theorem", + "signature": "theorem two_mul_esymm_two (r : Multiset ℂ) :\n 2 * r.esymm 2 = r.sum ^ 2 - (r.map (fun v => v ^ 2)).sum", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 7, + "text": "noncomputable section" + }, + { + "line": 8, + "text": "open scoped BigOperators" + }, + { + "line": 9, + "text": "open Polynomial" + }, + { + "line": 10, + "text": "namespace Sendov.PaperCentered" + } + ] + } + ], + "mapping_note": "For r=q−μ the actual mean relation gives r.sum=0. e1=r.sum=0; two_mul_esymm_two gives e2=−Σrj²/2=−mκ/2. Unfold coeff/correction in coeff_two and second_order for the normalized identity.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "CE03", + "claim": "Optimized centered coefficient bound |e_k|²≤m^m v^k/[k^k(m−k)^(m−k)] for 1≤k1", + "paper_sources": [ + "first-origin/REPORT.md:232-244" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperCenteredBound.lean", + "line": 85, + "declaration": "majorant_Efin", + "qualified_declaration": "Sendov.PaperCenteredBound.majorant_Efin", + "kind": "def", + "signature": "def majorant_Efin (r : Multiset ℂ) (μ z : ℂ) : ℝ", + "blob": "5615181f428ef9f5d699ffc42e474824c400b762", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 13, + "text": "noncomputable section" + }, + { + "line": 14, + "text": "open scoped BigOperators" + }, + { + "line": 15, + "text": "namespace Sendov.PaperCenteredBound" + }, + { + "line": 16, + "text": "open PaperCentered" + } + ] + }, + { + "path": "Sendov/Analytic/PaperCenteredBound.lean", + "line": 103, + "declaration": "norm_epsilon_le_majorant_Efin", + "qualified_declaration": "Sendov.PaperCenteredBound.norm_epsilon_le_majorant_Efin", + "kind": "theorem", + "signature": "theorem norm_epsilon_le_majorant_Efin (r : Multiset ℂ) (hr : r.sum = 0)\n (μ z : ℂ) (hm : 2 ≤ r.card) :\n ‖epsilon r μ z‖ ≤ majorant_Efin r μ z", + "blob": "5615181f428ef9f5d699ffc42e474824c400b762", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 13, + "text": "noncomputable section" + }, + { + "line": 14, + "text": "open scoped BigOperators" + }, + { + "line": 15, + "text": "namespace Sendov.PaperCenteredBound" + }, + { + "line": 16, + "text": "open PaperCentered" + } + ] + }, + { + "path": "Sendov/Analytic/PaperCenteredBound.lean", + "line": 110, + "declaration": "C_budget", + "qualified_declaration": "Sendov.PaperCenteredBound.C_budget", + "kind": "theorem", + "signature": "theorem C_budget (q : Multiset ℂ) (a : ℝ) (μ : ℂ) (hm : 2 ≤ q.card)\n (ha : 0 ≤ a) (hmean : q.sum = q.card * μ) (hμ : μ ≠ 0)\n (hbudget : majorant_Efin (q.map (fun v => v - μ)) μ (a * μ) +\n Gamma (q.map (fun v => v - μ)) μ < 1 - a * ‖μ‖) :\n 1 < ‖(q.card + 1 : ℂ) *\n (∫ t in (0 : ℝ)..1, (q.map (fun v => 1 - (a : ℂ) * t * v)).prod)‖", + "blob": "5615181f428ef9f5d699ffc42e474824c400b762", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 13, + "text": "noncomputable section" + }, + { + "line": 14, + "text": "open scoped BigOperators" + }, + { + "line": 15, + "text": "namespace Sendov.PaperCenteredBound" + }, + { + "line": 16, + "text": "open PaperCentered" + } + ] + } + ], + "mapping_note": "The literal square-root majorant and its epsilon bound/C-budget are present. PaperCentered.Efin uses actual coefficients and is a different definition; both are preserved in definition_evidence.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "CE05", + "claim": "Top endpoint H_{m,m}(aμ)=(aμ)^(m+1) exactly cancels inverse-μ tail growth", + "paper_sources": [ + "first-origin/REPORT.md:246" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 192, + "declaration": "H_top", + "qualified_declaration": "Sendov.PaperCentered.H_top", + "kind": "theorem", + "signature": "theorem H_top (m : ℕ) (z : ℂ) : H m m z = z ^ (m + 1)", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 7, + "text": "noncomputable section" + }, + { + "line": 8, + "text": "open scoped BigOperators" + }, + { + "line": 9, + "text": "open Polynomial" + }, + { + "line": 10, + "text": "namespace Sendov.PaperCentered" + } + ] + }, + { + "path": "Sendov/Analytic/PaperCenteredBound.lean", + "line": 123, + "declaration": "majorant_top_suppression", + "qualified_declaration": "Sendov.PaperCenteredBound.majorant_top_suppression", + "kind": "theorem", + "signature": "theorem majorant_top_suppression (r : Multiset ℂ) (a μ : ℂ) (hμ : μ ≠ 0) :\n (C r.card r.card (variance r) / ((r.card.choose r.card : ℝ) * ‖μ‖ ^ r.card)) *\n ‖H r.card r.card (a * μ)‖ =\n Real.sqrt (variance r ^ r.card) * ‖a‖ ^ (r.card + 1) * ‖μ‖", + "blob": "5615181f428ef9f5d699ffc42e474824c400b762", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 13, + "text": "noncomputable section" + }, + { + "line": 14, + "text": "open scoped BigOperators" + }, + { + "line": 15, + "text": "namespace Sendov.PaperCenteredBound" + }, + { + "line": 16, + "text": "open PaperCentered" + } + ] + }, + { + "path": "Sendov/Analytic/PaperCenteredBound.lean", + "line": 134, + "declaration": "coeff_top_suppression", + "qualified_declaration": "Sendov.PaperCenteredBound.coeff_top_suppression", + "kind": "theorem", + "signature": "theorem coeff_top_suppression (r : Multiset ℂ) (a μ : ℂ) (hμ : μ ≠ 0) :\n coeff r μ r.card * H r.card r.card (a * μ) =\n (-1) ^ r.card * r.prod * a ^ (r.card + 1) * μ", + "blob": "5615181f428ef9f5d699ffc42e474824c400b762", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 13, + "text": "noncomputable section" + }, + { + "line": 14, + "text": "open scoped BigOperators" + }, + { + "line": 15, + "text": "namespace Sendov.PaperCenteredBound" + }, + { + "line": 16, + "text": "open PaperCentered" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "PO01", + "claim": "Raw polar implies x>a/2, 0a/2 because a>0. The bounds 01.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "PO05", + "claim": "When Nδ<2, c>1/3; globally E=b^(m/2)≤4/(m+2)", + "paper_sources": [ + "first-origin-uniform/REPORT.md:155-171" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperGlobalPolar.lean", + "line": 149, + "declaration": "three_fifths_lt_c", + "qualified_declaration": "Sendov.PaperGlobalPolar.three_fifths_lt_c", + "kind": "theorem", + "signature": "theorem three_fifths_lt_c {m : ℕ} {a x : ℝ} (hm : 7 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hr : RawPolar m a x) (hsmall : (((m : ℝ) + 2) / 2) * (1 - a ^ 2) < 2) :\n (3 : ℝ) / 5 < c a x", + "blob": "4579b325911203a308137777929bf08495503812", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperGlobalPolar" + }, + { + "line": 14, + "text": "open MeasureTheory PaperPolar" + } + ] + }, + { + "path": "Sendov/Analytic/PaperGlobalPolar.lean", + "line": 199, + "declaration": "endpoint_le", + "qualified_declaration": "Sendov.PaperGlobalPolar.endpoint_le", + "kind": "theorem", + "signature": "theorem endpoint_le {m : ℕ} {a x : ℝ} (hm : 7 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hr : RawPolar m a x) : b a x ^ ((m : ℝ) / 2) ≤ 4 / ((m : ℝ) + 2)", + "blob": "4579b325911203a308137777929bf08495503812", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperGlobalPolar" + }, + { + "line": 14, + "text": "open MeasureTheory PaperPolar" + } + ] + } + ], + "mapping_note": "three_fifths_lt_c implies the weaker paper c>1/3 by 1/3<3/5. endpoint_le is exactly E≤4/(m+2).", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "PO06", + "claim": "Refined large-Nδ decay E≤(Nδ)^(−m/((m+2)δ))", + "paper_sources": [ + "first-origin-uniform/REPORT.md:149-153" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperRateDetails.lean", + "line": 19, + "declaration": "endpoint_delta_rate", + "qualified_declaration": "Sendov.PaperRateDetails.endpoint_delta_rate", + "kind": "theorem", + "signature": "theorem endpoint_delta_rate {m : ℕ} {a x : ℝ} (hm : 7 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hr : RawPolar m a x)\n (hlarge : 2 ≤ (((m : ℝ) + 2) / 2) * (1 - a ^ 2)) :\n b a x ^ ((m : ℝ) / 2) ≤\n ((((m : ℝ) + 2) / 2) * (1 - a ^ 2)) ^\n (-(m : ℝ) / (((m : ℝ) + 2) * (1 - a ^ 2)))", + "blob": "80654d487a115521c5bf6bdb793ce5e5678c1575", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 13, + "text": "namespace Sendov.PaperRateDetails" + }, + { + "line": 15, + "text": "open PaperPolar" + } + ] + } + ], + "mapping_note": "Take N=(m+2)/2 and δ=1−a². The report A3 assumes Nδ≥2 (REPORT.md:149–151), exactly the hlarge premise; m≥7 is the standing report domain. The exponent is precisely −m/((m+2)δ), not merely O(1/m).", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "PO07", + "claim": "Raw polar implies 1−y≤αy²/6≤λy²/6 and 1−x≤λ/(6a)", + "paper_sources": [ + "first-origin-uniform/REPORT.md:233-253" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "derived_corollary", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperPolar.lean", + "line": 125, + "declaration": "b_le_alpha", + "qualified_declaration": "Sendov.PaperPolar.b_le_alpha", + "kind": "theorem", + "signature": "theorem b_le_alpha {m : ℕ} {a x : ℝ} (hm : 0 < m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) : b a x ≤ alpha m a / (3 + alpha m a)", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperPolar" + }, + { + "line": 14, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperPolar.lean", + "line": 132, + "declaration": "endpoint_bounds", + "qualified_declaration": "Sendov.PaperPolar.endpoint_bounds", + "kind": "theorem", + "signature": "theorem endpoint_bounds {m : ℕ} {a x : ℝ} (hm : 7 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) :\n b a x ≤ alpha m a / (3 + alpha m a) ∧\n alpha m a / (3 + alpha m a) ≤ lambda m a / (3 + lambda m a)", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperPolar" + }, + { + "line": 14, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperMomentCorollaries.lean", + "qualified_declaration": "Sendov.PaperMomentCorollaries.PO07", + "kind": "theorem" + } + ], + "mapping_note": "Original mathematical recipe is now also an exported Lean contract; parent compilation and kernel receipt tag: final-corollaries.", + "corollary_recipe": "Put A=alpha=m(1−a²)/2>0,L=lambda=m(1−a)>0,y=1−b/2,y₀=(A+6)/(2(A+3)). b_le_alpha gives y≥y₀>0, and b>0 gives y≤1. F(y)=Ay²+6y−6 is increasing on y≥0 and F(y₀)=A³/[4(A+3)²]≥0. Thus 1−y≤Ay²/6. Since A=L(1+a)/2≤L, obtain ≤Ly²/6. Finally 1−y=a(1−x)+(1−a)²/2≥a(1−x), and y²≤1. Divide by a>0 to get 1−x≤L/(6a).", + "remaining_contract": null, + "compiled_corollary_exports": [ + { + "path": "Sendov/Analytic/PaperMomentCorollaries.lean", + "qualified_declaration": "Sendov.PaperMomentCorollaries.PO07", + "kind": "theorem" + } + ] + }, + { + "id": "PO08", + "claim": "Restored rational polar b≤α/(3+α)≤λ/(3+λ) and c≥3/(3+λ)", + "paper_sources": [ + "first-origin-uniform/round7/REPORT.md:36-80", + "first-origin-uniform/round7/MATH_NOTE.md:30-49" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperPolar.lean", + "line": 125, + "declaration": "b_le_alpha", + "qualified_declaration": "Sendov.PaperPolar.b_le_alpha", + "kind": "theorem", + "signature": "theorem b_le_alpha {m : ℕ} {a x : ℝ} (hm : 0 < m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) : b a x ≤ alpha m a / (3 + alpha m a)", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperPolar" + }, + { + "line": 14, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperPolar.lean", + "line": 132, + "declaration": "endpoint_bounds", + "qualified_declaration": "Sendov.PaperPolar.endpoint_bounds", + "kind": "theorem", + "signature": "theorem endpoint_bounds {m : ℕ} {a x : ℝ} (hm : 7 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) :\n b a x ≤ alpha m a / (3 + alpha m a) ∧\n alpha m a / (3 + alpha m a) ≤ lambda m a / (3 + lambda m a)", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperPolar" + }, + { + "line": 14, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperPolar.lean", + "line": 161, + "declaration": "c_lower_bound", + "qualified_declaration": "Sendov.PaperPolar.c_lower_bound", + "kind": "theorem", + "signature": "theorem c_lower_bound {m : ℕ} {a x : ℝ} (hm : 7 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) : 3 / (3 + lambda m a) ≤ c a x", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperPolar" + }, + { + "line": 14, + "text": "open MeasureTheory" + } + ] + } + ], + "mapping_note": "Attribution is Tao/previous beta_le, not a new local discovery. Non-strict form suffices.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "PO09", + "claim": "Rational y lower bound (α+6)/(2(α+3)) is strictly stronger than Gaussian positive-root bound", + "paper_sources": [ + "first-origin-uniform/round7/MATH_NOTE.md:37-49" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "derived_corollary", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperPolar.lean", + "line": 125, + "declaration": "b_le_alpha", + "qualified_declaration": "Sendov.PaperPolar.b_le_alpha", + "kind": "theorem", + "signature": "theorem b_le_alpha {m : ℕ} {a x : ℝ} (hm : 0 < m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) : b a x ≤ alpha m a / (3 + alpha m a)", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperPolar" + }, + { + "line": 14, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperMomentCorollaries.lean", + "qualified_declaration": "Sendov.PaperMomentCorollaries.PO09", + "kind": "theorem" + } + ], + "mapping_note": "Original mathematical recipe is now also an exported Lean contract; parent compilation and kernel receipt tag: final-corollaries.", + "corollary_recipe": "With A=alpha>0, b_le_alpha gives y≥y₀=(A+6)/(2(A+3)). F(y)=Ay²+6y−6 satisfies F(y₀)=A³/[4(A+3)²]>0. F is strictly increasing on nonnegative reals and has positive root yG=(sqrt(36+24A)−6)/(2A)=12/(sqrt(36+24A)+6), with F(0)<0yG. This is strict comparison of rational and Gaussian lower bounds, not convergence.", + "remaining_contract": null, + "compiled_corollary_exports": [ + { + "path": "Sendov/Analytic/PaperMomentCorollaries.lean", + "qualified_declaration": "Sendov.PaperMomentCorollaries.PO09", + "kind": "theorem" + } + ] + }, + { + "id": "IN01", + "claim": "Universal finite second-order Taylor bound T≤1/(m+1)+E+d/[a(m−2)]+12ma²d²/[c⁴(m+1)(m+3)]", + "paper_sources": [ + "first-origin-uniform/REPORT.md:255-277", + "first-origin-uniform/round6/REPORT.md:38-42" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperTaylor.lean", + "line": 294, + "declaration": "finite_taylor_budget", + "qualified_declaration": "Sendov.PaperTaylor.finite_taylor_budget", + "kind": "theorem", + "signature": "theorem finite_taylor_budget {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1)\n (hx : x ≤ 1) (hc : 0 < 1 - beta a x 1) :\n let b := beta a x 1\n let c := 1 - b\n let d := 2 * a * (1 - x)\n b ^ (m / 2) + m * a ^ 2 * (∫ t in (0 : ℝ)..1, t * beta a x t ^ ((m - 1) / 2)) ≤\n 1 / (m + 1) + b ^ (m / 2) + d / (a * (m - 2)) +\n 12 * m * a ^ 2 * d ^ 2 / (c ^ 4 * (m + 1) * (m + 3))", + "blob": "d982ee5ca7fd67f2b03d7959d45749da20f4f397", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperTaylor" + }, + { + "line": 17, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperTaylor.lean", + "line": 235, + "declaration": "budget_le", + "qualified_declaration": "Sendov.PaperTaylor.budget_le", + "kind": "theorem", + "signature": "theorem budget_le {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1)\n (hx : x ≤ 1) (hc : 0 < chord a x) :\n budget m a x ≤ 1 / (m + 1) + beta a x 1 ^ (m / 2) +\n defect a x / (a * (m - 2)) +\n 12 * m * a ^ 2 * defect a x ^ 2 / (chord a x ^ 4 * (m + 1) * (m + 3))", + "blob": "d982ee5ca7fd67f2b03d7959d45749da20f4f397", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperTaylor" + }, + { + "line": 17, + "text": "open MeasureTheory" + } + ] + } + ], + "mapping_note": "Actual finite integrals; real m≥7 generality is stronger than integer paper premise.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "IN02", + "claim": "All-m finite two-end estimates A5 and A5b: 100m/[9(m+1)(m+3)x²]+29E, and 16m/[(m+1)(m+3)x²]+13E", + "paper_sources": [ + "first-origin-uniform/REPORT.md:173-202", + "first-origin-uniform/round3/REPORT.md:23-32" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperHistoricalBounds.lean", + "line": 303, + "declaration": "total_le_A5", + "qualified_declaration": "Sendov.PaperHistoricalBounds.total_le_A5", + "kind": "theorem", + "signature": "theorem total_le_A5 {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1)\n (hx : 0 < x) (hx1 : x ≤ 1) (hc : 0 < PaperTaylor.chord a x) :\n PaperTwoEnd.total m a x ≤ 100 * m / (9 * (m + 1) * (m + 3) * x ^ 2) +\n 29 * PaperTwoEnd.endpoint m a x", + "blob": "734f40af971c2f781f83df84bdb6892b36bc2bab", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 13, + "text": "namespace Sendov.PaperHistoricalBounds" + }, + { + "line": 15, + "text": "open PaperPolar" + } + ] + }, + { + "path": "Sendov/Analytic/PaperHistoricalBounds.lean", + "line": 329, + "declaration": "total_le_A5b", + "qualified_declaration": "Sendov.PaperHistoricalBounds.total_le_A5b", + "kind": "theorem", + "signature": "theorem total_le_A5b {m a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1)\n (hx : 0 < x) (hx1 : x ≤ 1) (hc : 0 < PaperTaylor.chord a x) :\n PaperTwoEnd.total m a x ≤ 16 * m / ((m + 1) * (m + 3) * x ^ 2) +\n 13 * PaperTwoEnd.endpoint m a x", + "blob": "734f40af971c2f781f83df84bdb6892b36bc2bab", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 13, + "text": "namespace Sendov.PaperHistoricalBounds" + }, + { + "line": 15, + "text": "open PaperPolar" + } + ] + }, + { + "path": "Sendov/Analytic/PaperTwoEnd.lean", + "line": 25, + "declaration": "total_eq_budget", + "qualified_declaration": "Sendov.PaperTwoEnd.total_eq_budget", + "kind": "theorem", + "signature": "theorem total_eq_budget {m a x : ℝ} (ha : 0 < a) :\n total m a x = PaperTaylor.budget m a x", + "blob": "80e4a5f2cf45619625301fcdd1501ff76b59329a", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 11, + "text": "namespace Sendov.PaperTwoEnd" + }, + { + "line": 13, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperPolar.lean", + "line": 150, + "declaration": "geometry", + "qualified_declaration": "Sendov.PaperPolar.geometry", + "kind": "theorem", + "signature": "theorem geometry {m : ℕ} {a x : ℝ} (hm : 7 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) : a / 2 < x ∧ 0 < c a x", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperPolar" + }, + { + "line": 14, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRegionCorollaries.lean", + "qualified_declaration": "Sendov.PaperRegionCorollaries.in02_two_end", + "kind": "theorem" + } + ], + "mapping_note": "Original mathematical recipe is now also an exported Lean contract; parent compilation and kernel receipt tag: final-corollaries.", + "corollary_recipe": "For natural m≥7, apply geometry to obtain a/20. Rewrite their left sides by total_eq_budget (ha:0h/3 (legacy)", + "paper_sources": [ + "first-origin-uniform/legacy_RESULT.md:7-9" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperNearMargins.lean", + "line": 140, + "declaration": "near_endpoint_one_hundredth", + "qualified_declaration": "Sendov.PaperNearMargins.near_endpoint_one_hundredth", + "kind": "theorem", + "signature": "theorem near_endpoint_one_hundredth {m : ℕ} {a x : ℝ} (hm : 7 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 1 / 100) :\n 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x >\n (1 - a) / 3", + "blob": "f897fdb771f2fa90796500842851b1833352d26f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 17, + "text": "namespace Sendov.PaperNearMargins" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "NE02", + "claim": "m≥7, λ≤1/50 ⇒ B−T>h/3", + "paper_sources": [ + "first-origin-uniform/REPORT.md:255-299" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperNearMargins.lean", + "line": 110, + "declaration": "near_endpoint_one_fiftieth", + "qualified_declaration": "Sendov.PaperNearMargins.near_endpoint_one_fiftieth", + "kind": "theorem", + "signature": "theorem near_endpoint_one_fiftieth {m : ℕ} {a x : ℝ} (hm : 7 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 1 / 50) :\n 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x >\n (1 - a) / 3", + "blob": "f897fdb771f2fa90796500842851b1833352d26f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 17, + "text": "namespace Sendov.PaperNearMargins" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "NE03", + "claim": "m≥7, λ≤1/10 ⇒ B−T>h/5", + "paper_sources": [ + "first-origin-uniform/round3/REPORT.md:36-57" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperNearMargins.lean", + "line": 120, + "declaration": "near_endpoint_one_tenth", + "qualified_declaration": "Sendov.PaperNearMargins.near_endpoint_one_tenth", + "kind": "theorem", + "signature": "theorem near_endpoint_one_tenth {m : ℕ} {a x : ℝ} (hm : 7 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 1 / 10) :\n 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x >\n (1 - a) / 5", + "blob": "f897fdb771f2fa90796500842851b1833352d26f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 17, + "text": "namespace Sendov.PaperNearMargins" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "NE04", + "claim": "m≥7, λ≤1/5 ⇒ B−T>h/80", + "paper_sources": [ + "first-origin-uniform/round5/REPORT.md:51-69" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperNearMargins.lean", + "line": 130, + "declaration": "near_endpoint_one_fifth", + "qualified_declaration": "Sendov.PaperNearMargins.near_endpoint_one_fifth", + "kind": "theorem", + "signature": "theorem near_endpoint_one_fifth {m : ℕ} {a x : ℝ} (hm : 7 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 1 / 5) :\n 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x >\n (1 - a) / 80", + "blob": "f897fdb771f2fa90796500842851b1833352d26f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 17, + "text": "namespace Sendov.PaperNearMargins" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "NE05", + "claim": "m≥7, λ≤3/10 ⇒ B−T>h/1000", + "paper_sources": [ + "first-origin-uniform/round6/REPORT.md:148-233" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "derived_corollary", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperNear.lean", + "line": 158, + "declaration": "near_endpoint_D", + "qualified_declaration": "Sendov.PaperNearClosure.near_endpoint_D", + "kind": "theorem", + "signature": "theorem near_endpoint_D {m : ℕ} {a x : ℝ} (hm : 7 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 2 / 5) :\n 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x >\n (1 - a) / 1000", + "blob": "8e258a06357ae182a76feee8e55d2480221ab0f2", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperNearClosure" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRegionCorollaries.lean", + "qualified_declaration": "Sendov.PaperRegionCorollaries.ne05_near", + "kind": "theorem" + } + ], + "mapping_note": "Original mathematical recipe is now also an exported Lean contract; parent compilation and kernel receipt tag: final-corollaries.", + "corollary_recipe": "Combine λ=m(1−a)≤3/10 with 3/10≤2/5; apply near_endpoint_D with unchanged m≥7,a,x,RawPolar hypotheses and this λ≤2/5 proof. Its exact margin is h/1000.", + "remaining_contract": null, + "compiled_corollary_exports": [ + { + "path": "Sendov/Analytic/PaperRegionCorollaries.lean", + "qualified_declaration": "Sendov.PaperRegionCorollaries.ne05_near", + "kind": "theorem" + } + ] + }, + { + "id": "NE06", + "claim": "m≥7, λ≤2/5 ⇒ B−T>h/1000", + "paper_sources": [ + "first-origin-uniform/round7/MATH_NOTE.md:9-114" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperNear.lean", + "line": 158, + "declaration": "near_endpoint_D", + "qualified_declaration": "Sendov.PaperNearClosure.near_endpoint_D", + "kind": "theorem", + "signature": "theorem near_endpoint_D {m : ℕ} {a x : ℝ} (hm : 7 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : PaperPolar.RawPolar m a x) (hnear : (m : ℝ) * (1 - a) ≤ 2 / 5) :\n 1 - (m : ℝ) * a / ((m : ℝ) + 1) - PaperTaylor.budget (m : ℝ) a x >\n (1 - a) / 1000", + "blob": "8e258a06357ae182a76feee8e55d2480221ab0f2", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperNearClosure" + } + ] + }, + { + "path": "Sendov/Analytic/FirstOriginBudget.lean", + "line": 53, + "declaration": "near_contradiction", + "qualified_declaration": "Sendov.FirstOriginBudget.near_contradiction", + "kind": "theorem", + "signature": "theorem near_contradiction {n : ℕ} (hn : 8 ≤ n) {a x y : ℝ} {q : Multiset ℂ}\n (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hqcard : q.card = n - 1) (hq1 : ∀ v ∈ q, ‖v‖ ≤ 1)\n (hx : (q.map (fun v => v.re)).sum = ((n : ℝ) - 1) * x)\n (hsum : q.sum = ((n : ℂ) - 1) * ((x : ℂ) + (y : ℂ) * Complex.I))\n (hraw : 1 ≤ ∫ t in (0 : ℝ)..1, Ppolar a x t ^ (((n : ℝ) - 1) / 2))\n (hnear : ((n : ℝ) - 1) * (1 - a) ≤ 2 / 5)\n (hfirst : ‖∫ t in (0 : ℝ)..1, Fprod a q t‖ ≤ 1 / (n : ℝ)) : False", + "blob": "aed9631b5d52531251e4780e658126e33e15761d", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 7, + "text": "namespace Sendov.FirstOriginBudget" + } + ] + } + ], + "mapping_note": "Standalone analytic result and actual near first-origin Solution consumer are both present.", + "corollary_recipe": null, + "remaining_contract": null, + "consumer_evidence": [ + { + "path": "Sendov/Interior.lean", + "line": 113, + "source_excerpt": " rw [Complex.re_add_im, mul_div_cancel₀ _ hne]\n obtain ⟨hxre, hx2⟩ := xy_bounds hn hqcard hq1 hxy\n have hpolar := one_le_integral_Ppolar hn (a := a) (x := x) hqcard hq1 hxre hstar\n -- All sufficiently large degrees use only the first-origin channel.\n by_cases hlarge : 257 ≤ n\n · have hxSq : x ^ 2 ≤ 1 := (le_add_of_nonneg_right (sq_nonneg y)).trans hx2\n exact FirstOriginBudget.uniform_contradiction hlarge ha0 ha1", + "blob": "ce28aada7a4679579e08d1e65f9a939d7df2b8e8", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d" + } + ] + }, + { + "id": "UN01", + "claim": "m≥256 raw polar ⇒ T<2/3", + "paper_sources": [ + "first-origin-uniform/round5/REPORT.md:73-111" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "inflight", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperUniform.lean", + "line": 43, + "declaration": "budget_lt_two_thirds", + "qualified_declaration": "Sendov.PaperUniform.budget_lt_two_thirds", + "kind": "theorem", + "signature": "theorem budget_lt_two_thirds (hm : 256 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hr : RawPolar m a x) : PaperTaylor.budget (m : ℝ) a x < 2 / 3", + "blob": "6ec67449aca5bacd31f0cc69b8a83b819940263a", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 14, + "text": "namespace Sendov.PaperUniform" + }, + { + "line": 16, + "text": "open PaperPolar" + }, + { + "line": 40, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + } + ], + "mapping_note": "Actual finite T integral; integer m≥256 and raw polar, no assumed analytic estimate.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "UN02", + "claim": "m≥256, a≥1/3 raw polar ⇒ T<16/(ma²)+24/m", + "paper_sources": [ + "first-origin-uniform/round5/REPORT.md:113-141" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "inflight", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperUniform.lean", + "line": 79, + "declaration": "budget_lt_retained", + "qualified_declaration": "Sendov.PaperUniform.budget_lt_retained", + "kind": "theorem", + "signature": "theorem budget_lt_retained (hm : 256 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (ha3 : 1 / 3 ≤ a)\n (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : RawPolar m a x) :\n PaperTaylor.budget (m : ℝ) a x < 16 / ((m : ℝ) * a ^ 2) + 24 / (m : ℝ)", + "blob": "6ec67449aca5bacd31f0cc69b8a83b819940263a", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 14, + "text": "namespace Sendov.PaperUniform" + }, + { + "line": 16, + "text": "open PaperPolar" + }, + { + "line": 40, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + } + ], + "mapping_note": "Actual finite T with the exact 16/(ma²)+24/m bound and a≥1/3.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "UN03", + "claim": "m≥512 raw polar ⇒ T<3/5", + "paper_sources": [ + "first-origin-uniform/round4/REPORT.md:104-135" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "inflight", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperHistoricalBounds.lean", + "line": 90, + "declaration": "budget_lt_three_fifths", + "qualified_declaration": "Sendov.PaperHistoricalBounds.budget_lt_three_fifths", + "kind": "theorem", + "signature": "theorem budget_lt_three_fifths {m : ℕ} {a x : ℝ} (hm : 512 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hr : RawPolar m a x) : PaperTaylor.budget m a x < 3 / 5", + "blob": "734f40af971c2f781f83df84bdb6892b36bc2bab", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 13, + "text": "namespace Sendov.PaperHistoricalBounds" + }, + { + "line": 15, + "text": "open PaperPolar" + } + ] + } + ], + "mapping_note": "Preserves the stronger all-a 3/5 quantitative bound, rather than replacing it by D.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "UN04", + "claim": "m≥512, a≥2/5 ⇒ T<40/(ma²), hence ma²h≥40 ⇒ T0; combine strict inequalities to obtain T0, obtain T5/6; λ≤10 gives b<4/5,x>7/12; λ≤25 gives b<9/10,x>231/512; λ≤49 gives b<23/25,x>207/512", + "paper_sources": [ + "first-origin-uniform/round5/REPORT.md:5.1-5.3" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperRayGeometry.lean", + "line": 78, + "declaration": "geometry_one", + "qualified_declaration": "Sendov.PaperRayGeometry.geometry_one", + "kind": "theorem", + "signature": "theorem geometry_one (hm : 256 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) (hl : lambda m a ≤ 1) : 5 / 6 < x", + "blob": "630798c6c402c6d5fb22d7bbcb61d456e8175751", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "namespace Sendov.PaperRayGeometry" + }, + { + "line": 18, + "text": "open MeasureTheory PaperPolar" + }, + { + "line": 61, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRayGeometry.lean", + "line": 64, + "declaration": "geometry_ten", + "qualified_declaration": "Sendov.PaperRayGeometry.geometry_ten", + "kind": "theorem", + "signature": "theorem geometry_ten (hm : 256 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) (hl : lambda m a ≤ 10) :\n b a x < 4 / 5 ∧ 7 / 12 < x", + "blob": "630798c6c402c6d5fb22d7bbcb61d456e8175751", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "namespace Sendov.PaperRayGeometry" + }, + { + "line": 18, + "text": "open MeasureTheory PaperPolar" + }, + { + "line": 61, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRayGeometry.lean", + "line": 92, + "declaration": "geometry_twentyfive", + "qualified_declaration": "Sendov.PaperRayGeometry.geometry_twentyfive", + "kind": "theorem", + "signature": "theorem geometry_twentyfive (hm : 256 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) (hl : lambda m a ≤ 25) :\n b a x < 9 / 10 ∧ 231 / 512 < x", + "blob": "630798c6c402c6d5fb22d7bbcb61d456e8175751", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "namespace Sendov.PaperRayGeometry" + }, + { + "line": 18, + "text": "open MeasureTheory PaperPolar" + }, + { + "line": 61, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRayGeometry.lean", + "line": 176, + "declaration": "geometry_fortynine", + "qualified_declaration": "Sendov.PaperRayGeometry.geometry_fortynine", + "kind": "theorem", + "signature": "theorem geometry_fortynine (hm : 256 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) (hl : lambda m a ≤ 49) :\n b a x < 23 / 25 ∧ 207 / 512 < x", + "blob": "630798c6c402c6d5fb22d7bbcb61d456e8175751", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "namespace Sendov.PaperRayGeometry" + }, + { + "line": 18, + "text": "open MeasureTheory PaperPolar" + }, + { + "line": 61, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + } + ], + "mapping_note": "Family of four parameter restrictions; actual x and endpoint hypotheses for Laplace are derived, not assumed.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "RA02", + "claim": "Uniform finite tails for r=4/5,9/10,23/25 and the middle-geometry exponential tail", + "paper_sources": [ + "first-origin-uniform/round5/REPORT.md:4,5.3" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperTail.lean", + "line": 61, + "declaration": "tail_four_fifths", + "qualified_declaration": "Sendov.PaperTail.tail_four_fifths", + "kind": "theorem", + "signature": "theorem tail_four_fifths {m : ℝ} (hm : 256 ≤ m) :\n (m ^ 2 / 2 + m) * (4 / 5 : ℝ) ^ ((m - 1) / 2) < 1 / m", + "blob": "5adc927ce4b253aad92605c908417b6eb005fe37", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.PaperTail" + } + ] + }, + { + "path": "Sendov/Analytic/PaperTail.lean", + "line": 76, + "declaration": "tail_nine_tenths", + "qualified_declaration": "Sendov.PaperTail.tail_nine_tenths", + "kind": "theorem", + "signature": "theorem tail_nine_tenths {m : ℝ} (hm : 256 ≤ m) :\n (m ^ 2 / 2 + m) * (9 / 10 : ℝ) ^ ((m - 1) / 2) < 1 / 4", + "blob": "5adc927ce4b253aad92605c908417b6eb005fe37", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.PaperTail" + } + ] + }, + { + "path": "Sendov/Analytic/PaperTail.lean", + "line": 89, + "declaration": "tail_twenty_three_twenty_fifths", + "qualified_declaration": "Sendov.PaperTail.tail_twenty_three_twenty_fifths", + "kind": "theorem", + "signature": "theorem tail_twenty_three_twenty_fifths {m : ℝ} (hm : 256 ≤ m) :\n (m ^ 2 / 2 + m) * (23 / 25 : ℝ) ^ ((m - 1) / 2) < 2", + "blob": "5adc927ce4b253aad92605c908417b6eb005fe37", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.PaperTail" + } + ] + }, + { + "path": "Sendov/Analytic/PaperTail.lean", + "line": 121, + "declaration": "middle_tail", + "qualified_declaration": "Sendov.PaperTail.middle_tail", + "kind": "theorem", + "signature": "theorem middle_tail {m : ℝ} (hm : 256 ≤ m) :\n m * (1 + 5 * m / 162) * Real.exp (-22 * m / 1215) < 24", + "blob": "5adc927ce4b253aad92605c908417b6eb005fe37", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.PaperTail" + } + ] + } + ], + "mapping_note": "Exact tail bounds <1/m,<1/4,<2 and <24, not numerical diagnostics.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "RA03", + "claim": "Round5 actual scaled upper bounds mx²T<1+18/m,1+33/m,1+51/m+1/4,1+62/m+2 on respective ray intervals", + "paper_sources": [ + "first-origin-uniform/round5/REPORT.md:5.3" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "derived_corollary", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperTail.lean", + "line": 186, + "declaration": "budget_region_one", + "qualified_declaration": "Sendov.PaperTail.budget_region_one", + "kind": "theorem", + "signature": "theorem budget_region_one {m a x : ℝ} (hm : 256 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx : 5 / 6 < x) (hx1 : x ≤ 1) (hxa : x < 2 * a)\n (hb : PaperTaylor.beta a x 1 ≤ 4 / 5) :\n m * x ^ 2 * PaperTaylor.budget m a x < 1 + 18 / m", + "blob": "5adc927ce4b253aad92605c908417b6eb005fe37", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.PaperTail" + } + ] + }, + { + "path": "Sendov/Analytic/PaperTail.lean", + "line": 200, + "declaration": "budget_region_two", + "qualified_declaration": "Sendov.PaperTail.budget_region_two", + "kind": "theorem", + "signature": "theorem budget_region_two {m a x : ℝ} (hm : 256 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx : 7 / 12 < x) (hx1 : x ≤ 1) (hxa : x < 2 * a)\n (hb : PaperTaylor.beta a x 1 ≤ 4 / 5) :\n m * x ^ 2 * PaperTaylor.budget m a x < 1 + 33 / m", + "blob": "5adc927ce4b253aad92605c908417b6eb005fe37", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.PaperTail" + } + ] + }, + { + "path": "Sendov/Analytic/PaperTail.lean", + "line": 214, + "declaration": "budget_region_three", + "qualified_declaration": "Sendov.PaperTail.budget_region_three", + "kind": "theorem", + "signature": "theorem budget_region_three {m a x : ℝ} (hm : 256 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx : 231 / 512 < x) (hx1 : x ≤ 1) (hxa : x < 2 * a)\n (hb : PaperTaylor.beta a x 1 ≤ 9 / 10) :\n m * x ^ 2 * PaperTaylor.budget m a x < 1 + 51 / m + 1 / 4", + "blob": "5adc927ce4b253aad92605c908417b6eb005fe37", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.PaperTail" + } + ] + }, + { + "path": "Sendov/Analytic/PaperTail.lean", + "line": 226, + "declaration": "budget_region_four", + "qualified_declaration": "Sendov.PaperTail.budget_region_four", + "kind": "theorem", + "signature": "theorem budget_region_four {m a x : ℝ} (hm : 256 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx : 207 / 512 < x) (hx1 : x ≤ 1) (hxa : x < 2 * a)\n (hb : PaperTaylor.beta a x 1 ≤ 23 / 25) :\n m * x ^ 2 * PaperTaylor.budget m a x < 1 + 62 / m + 2", + "blob": "5adc927ce4b253aad92605c908417b6eb005fe37", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 6, + "text": "namespace Sendov.PaperTail" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRayGeometry.lean", + "line": 317, + "declaration": "halfpoint_mem", + "qualified_declaration": "Sendov.PaperRayGeometry.halfpoint_mem", + "kind": "theorem", + "signature": "theorem halfpoint_mem (hm : 256 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) (hl : lambda m a ≤ 49) :\n x / (2 * a) ∈ Set.Ioo (0 : ℝ) 1", + "blob": "630798c6c402c6d5fb22d7bbcb61d456e8175751", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "namespace Sendov.PaperRayGeometry" + }, + { + "line": 18, + "text": "open MeasureTheory PaperPolar" + }, + { + "line": 61, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRayGeometry.lean", + "line": 78, + "declaration": "geometry_one", + "qualified_declaration": "Sendov.PaperRayGeometry.geometry_one", + "kind": "theorem", + "signature": "theorem geometry_one (hm : 256 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) (hl : lambda m a ≤ 1) : 5 / 6 < x", + "blob": "630798c6c402c6d5fb22d7bbcb61d456e8175751", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "namespace Sendov.PaperRayGeometry" + }, + { + "line": 18, + "text": "open MeasureTheory PaperPolar" + }, + { + "line": 61, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRayGeometry.lean", + "line": 64, + "declaration": "geometry_ten", + "qualified_declaration": "Sendov.PaperRayGeometry.geometry_ten", + "kind": "theorem", + "signature": "theorem geometry_ten (hm : 256 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) (hl : lambda m a ≤ 10) :\n b a x < 4 / 5 ∧ 7 / 12 < x", + "blob": "630798c6c402c6d5fb22d7bbcb61d456e8175751", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "namespace Sendov.PaperRayGeometry" + }, + { + "line": 18, + "text": "open MeasureTheory PaperPolar" + }, + { + "line": 61, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRayGeometry.lean", + "line": 92, + "declaration": "geometry_twentyfive", + "qualified_declaration": "Sendov.PaperRayGeometry.geometry_twentyfive", + "kind": "theorem", + "signature": "theorem geometry_twentyfive (hm : 256 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) (hl : lambda m a ≤ 25) :\n b a x < 9 / 10 ∧ 231 / 512 < x", + "blob": "630798c6c402c6d5fb22d7bbcb61d456e8175751", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "namespace Sendov.PaperRayGeometry" + }, + { + "line": 18, + "text": "open MeasureTheory PaperPolar" + }, + { + "line": 61, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRayGeometry.lean", + "line": 176, + "declaration": "geometry_fortynine", + "qualified_declaration": "Sendov.PaperRayGeometry.geometry_fortynine", + "kind": "theorem", + "signature": "theorem geometry_fortynine (hm : 256 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) (hl : lambda m a ≤ 49) :\n b a x < 23 / 25 ∧ 207 / 512 < x", + "blob": "630798c6c402c6d5fb22d7bbcb61d456e8175751", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "namespace Sendov.PaperRayGeometry" + }, + { + "line": 18, + "text": "open MeasureTheory PaperPolar" + }, + { + "line": 61, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + }, + { + "path": "Sendov/Analytic/PaperUniform.lean", + "line": 18, + "declaration": "beta_one", + "qualified_declaration": "Sendov.PaperUniform.beta_one", + "kind": "lemma", + "signature": "lemma beta_one (a x : ℝ) : PaperTaylor.beta a x 1 = b a x", + "blob": "6ec67449aca5bacd31f0cc69b8a83b819940263a", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 14, + "text": "namespace Sendov.PaperUniform" + }, + { + "line": 16, + "text": "open PaperPolar" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRegionCorollaries.lean", + "qualified_declaration": "Sendov.PaperRegionCorollaries.ra03_scaled_upper", + "kind": "theorem" + } + ], + "mapping_note": "Original mathematical recipe is now also an exported Lean contract; parent compilation and kernel receipt tag: final-corollaries.", + "corollary_recipe": "Keep m≥256 and original a,x,RawPolar. On [1/5,1] use geometry_one for x>5/6 and geometry_ten with λ≤1≤10 for b<4/5. On [1,10] use geometry_ten; on [10,25] use geometry_twentyfive; on [25,49] use geometry_fortynine. In every band λ≤49, halfpoint_mem gives x/(2a)<1, hence x<2a since a>0. Rewrite beta a x 1=b a x with beta_one and weaken strict endpoint bounds to ≤. Cast m to ℝ and apply budget_region_one,two,three,four respectively. These give exactly the four constants; the upper-bound lemmas do not need the lower λ restrictions.", + "remaining_contract": null, + "compiled_corollary_exports": [ + { + "path": "Sendov/Analytic/PaperRegionCorollaries.lean", + "qualified_declaration": "Sendov.PaperRegionCorollaries.ra03_scaled_upper", + "kind": "theorem" + } + ] + }, + { + "id": "RA04", + "claim": "Round5 scaled lower bounds on [1/5,1], [1,5], [5,10], [10,25], [25,49] exceed matching upper estimates", + "paper_sources": [ + "first-origin-uniform/round5/REPORT.md:5.4" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "partial", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperRateDetails.lean", + "line": 123, + "declaration": "scaled_budget_paper_lower_one", + "qualified_declaration": "Sendov.PaperRateDetails.scaled_budget_paper_lower_one", + "kind": "theorem", + "signature": "theorem scaled_budget_paper_lower_one {m : ℕ} {a x : ℝ} (hm : 256 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hr : RawPolar m a x) (hl0 : 1 / 5 ≤ lambda m a) (hl1 : lambda m a ≤ 1) :\n (m : ℝ) / ((m : ℝ) + 1) * (1 + (24 / 49 - 8 / (m : ℝ)) / 5) ≤\n (m : ℝ) * x ^ 2 * PaperRayGeometry.B m a", + "blob": "80654d487a115521c5bf6bdb793ce5e5678c1575", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 13, + "text": "namespace Sendov.PaperRateDetails" + }, + { + "line": 15, + "text": "open PaperPolar" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRateDetails.lean", + "line": 138, + "declaration": "scaled_budget_lower_one", + "qualified_declaration": "Sendov.PaperRateDetails.scaled_budget_lower_one", + "kind": "theorem", + "signature": "theorem scaled_budget_lower_one {m : ℕ} {a x : ℝ} (hm : 256 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hr : RawPolar m a x) (hl0 : 1 / 5 ≤ lambda m a) (hl1 : lambda m a ≤ 1) :\n 1 + 18 / (m : ℝ) < (m : ℝ) * x ^ 2 * PaperRayGeometry.B m a", + "blob": "80654d487a115521c5bf6bdb793ce5e5678c1575", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 13, + "text": "namespace Sendov.PaperRateDetails" + }, + { + "line": 15, + "text": "open PaperPolar" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRayGeometry.lean", + "line": 268, + "declaration": "budget_lower_five", + "qualified_declaration": "Sendov.PaperRayGeometry.budget_lower_five", + "kind": "theorem", + "signature": "theorem budget_lower_five (hm : 256 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) (hl0 : 1 ≤ lambda m a) (hl1 : lambda m a ≤ 5) :\n 1 + 33 / (m : ℝ) < (m : ℝ) * x ^ 2 * B m a", + "blob": "630798c6c402c6d5fb22d7bbcb61d456e8175751", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "namespace Sendov.PaperRayGeometry" + }, + { + "line": 18, + "text": "open MeasureTheory PaperPolar" + }, + { + "line": 61, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRayGeometry.lean", + "line": 281, + "declaration": "budget_lower_ten", + "qualified_declaration": "Sendov.PaperRayGeometry.budget_lower_ten", + "kind": "theorem", + "signature": "theorem budget_lower_ten (hm : 256 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) (hl0 : 1 ≤ lambda m a) (hl1 : lambda m a ≤ 10) :\n 1 + 33 / (m : ℝ) < (m : ℝ) * x ^ 2 * B m a", + "blob": "630798c6c402c6d5fb22d7bbcb61d456e8175751", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "namespace Sendov.PaperRayGeometry" + }, + { + "line": 18, + "text": "open MeasureTheory PaperPolar" + }, + { + "line": 61, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRayGeometry.lean", + "line": 294, + "declaration": "budget_lower_twentyfive", + "qualified_declaration": "Sendov.PaperRayGeometry.budget_lower_twentyfive", + "kind": "theorem", + "signature": "theorem budget_lower_twentyfive (hm : 256 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) (hl0 : 10 ≤ lambda m a) (hl1 : lambda m a ≤ 25) :\n 1 + 51 / (m : ℝ) + 1 / 4 < (m : ℝ) * x ^ 2 * B m a", + "blob": "630798c6c402c6d5fb22d7bbcb61d456e8175751", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "namespace Sendov.PaperRayGeometry" + }, + { + "line": 18, + "text": "open MeasureTheory PaperPolar" + }, + { + "line": 61, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRayGeometry.lean", + "line": 305, + "declaration": "budget_lower_fortynine", + "qualified_declaration": "Sendov.PaperRayGeometry.budget_lower_fortynine", + "kind": "theorem", + "signature": "theorem budget_lower_fortynine (hm : 256 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) (hl0 : 25 ≤ lambda m a) (hl1 : lambda m a ≤ 49) :\n 1 + 62 / (m : ℝ) + 2 < (m : ℝ) * x ^ 2 * B m a", + "blob": "630798c6c402c6d5fb22d7bbcb61d456e8175751", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "namespace Sendov.PaperRayGeometry" + }, + { + "line": 18, + "text": "open MeasureTheory PaperPolar" + }, + { + "line": 61, + "text": "variable {m : ℕ} {a x : ℝ}" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRegionCorollaries.lean", + "qualified_declaration": "Sendov.PaperRegionCorollaries.ra04_scaled_lower", + "kind": "theorem" + } + ], + "mapping_note": "Original mathematical recipe is now also an exported Lean contract; parent compilation and kernel receipt tag: final-corollaries.", + "corollary_recipe": "On [1/5,1], apply scaled_budget_paper_lower_one (the original rational lower expression) and scaled_budget_lower_one (strictly exceeds 1+18/m). On [1,5], apply budget_lower_five. On [5,10], apply budget_lower_ten after weakening 5≤λ to 1≤λ. On [10,25] and [25,49], apply budget_lower_twentyfive and budget_lower_fortynine. These yield respectively lower comparisons with 1+33/m, 1+33/m, 1+51/m+1/4, and 1+62/m+2, exactly the upper bounds in RA03; no λ<2/5 omission.", + "remaining_contract": null, + "compiled_corollary_exports": [ + { + "path": "Sendov/Analytic/PaperRegionCorollaries.lean", + "qualified_declaration": "Sendov.PaperRegionCorollaries.ra04_scaled_lower", + "kind": "theorem" + } + ] + }, + { + "id": "SE01", + "claim": "Exact maximal raw polar U1=R(1), monotonicity, and U1<1 excludes all x", + "paper_sources": [ + "first-origin-uniform/round6/REPORT.md:44-51" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperSecant.lean", + "line": 42, + "declaration": "R_one", + "qualified_declaration": "Sendov.PaperSecant.R_one", + "kind": "theorem", + "signature": "theorem R_one {m : ℕ} {a : ℝ} (ha : 0 < a) (ha1 : a < 1) : R m a 1 = U1 m a", + "blob": "d5a1481b495db34a9a82222596a45f36bc7a77a0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperSecant" + }, + { + "line": 13, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperSecant.lean", + "line": 192, + "declaration": "R_mono", + "qualified_declaration": "Sendov.PaperSecant.R_mono", + "kind": "theorem", + "signature": "theorem R_mono {m : ℕ} {a x y : ℝ} (ha : 0 < a) (ha1 : a < 1)\n (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hxy : x ≤ y) : R m a x ≤ R m a y", + "blob": "d5a1481b495db34a9a82222596a45f36bc7a77a0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperSecant" + }, + { + "line": 13, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperSecant.lean", + "line": 205, + "declaration": "one_le_U1", + "qualified_declaration": "Sendov.PaperSecant.one_le_U1", + "kind": "theorem", + "signature": "theorem one_le_U1 {m : ℕ} {a x : ℝ} (ha : 0 < a) (ha1 : a < 1)\n (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hraw : PaperPolar.RawPolar m a x) : 1 ≤ U1 m a", + "blob": "d5a1481b495db34a9a82222596a45f36bc7a77a0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperSecant" + }, + { + "line": 13, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "tests/PaperSecantTests.lean", + "line": 33, + "declaration": null, + "qualified_declaration": null, + "kind": "anonymous_example", + "signature": "example {m : ℕ} {a x : ℝ} (ha : 0 < a) (ha1 : a < 1)\n (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hu : U1 m a < 1) : ¬ PaperPolar.RawPolar m a x", + "blob": "645c3392fe1a3b3d6ef1e58ecad7cbd379f40d8f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 5, + "text": "namespace Sendov.PaperSecant.Tests" + }, + { + "line": 6, + "text": "open MeasureTheory" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "SE02", + "claim": "Curvature correction R(a/2)≤V0=U0−ma^(m−2)δ²/12, with 00 ⇒ D for every raw-polar feasible x, retaining floor(m/2)", + "paper_sources": [ + "first-origin-uniform/round6/REPORT.md:99-122" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperSecant.lean", + "line": 329, + "declaration": "budget_antitone", + "qualified_declaration": "Sendov.PaperSecant.budget_antitone", + "kind": "theorem", + "signature": "theorem budget_antitone {m a x y : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1)\n (hxy : x ≤ y) (hy : y ≤ 1) : PaperTaylor.budget m a y ≤ PaperTaylor.budget m a x", + "blob": "d5a1481b495db34a9a82222596a45f36bc7a77a0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperSecant" + }, + { + "line": 13, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperSecant.lean", + "line": 361, + "declaration": "budget_S_le_Wsec", + "qualified_declaration": "Sendov.PaperSecant.budget_S_le_Wsec", + "kind": "theorem", + "signature": "theorem budget_S_le_Wsec {m : ℕ} {a : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1)\n (hu : 1 ≤ U1 m a) : PaperTaylor.budget m a (S m a) ≤ Wsec m a", + "blob": "d5a1481b495db34a9a82222596a45f36bc7a77a0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperSecant" + }, + { + "line": 13, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperSecant.lean", + "line": 380, + "declaration": "gate_implies_D", + "qualified_declaration": "Sendov.PaperSecant.gate_implies_D", + "kind": "theorem", + "signature": "theorem gate_implies_D {m : ℕ} {a x : ℝ} (hm : 7 ≤ m) (ha : 0 < a) (ha1 : a < 1)\n (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hraw : PaperPolar.RawPolar m a x)\n (hgate : 0 < Fsec m a) : PaperTaylor.budget m a x < B m a", + "blob": "d5a1481b495db34a9a82222596a45f36bc7a77a0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperSecant" + }, + { + "line": 13, + "text": "open MeasureTheory" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI01", + "claim": "Full complex-polar unit-circle m=8 counterexample to universal mean-half, at a=99/100, x=497/500", + "paper_sources": [ + "first-origin/REPORT.md:177-189" + ], + "paper_evidence": "exact_certified_example", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperPolarCounterexample.lean", + "line": 43, + "declaration": "norm_q", + "qualified_declaration": "Sendov.PaperPolar.Counterexample.norm_q", + "kind": "theorem", + "signature": "theorem norm_q (j : Fin 8) : ‖q j‖ = 1", + "blob": "5aa353dd456feb742c1814939cdbfe8ea6fe68ef", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 11, + "text": "namespace Sendov.PaperPolar.Counterexample" + }, + { + "line": 12, + "text": "open MeasureTheory" + }, + { + "line": 13, + "text": "open scoped BigOperators" + } + ] + }, + { + "path": "tests/PaperPolarCounterexample.lean", + "line": 47, + "declaration": "mean_q", + "qualified_declaration": "Sendov.PaperPolar.Counterexample.mean_q", + "kind": "theorem", + "signature": "theorem mean_q : (∑ j : Fin 8, q j) / 8 = (x : ℂ)", + "blob": "5aa353dd456feb742c1814939cdbfe8ea6fe68ef", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 11, + "text": "namespace Sendov.PaperPolar.Counterexample" + }, + { + "line": 12, + "text": "open MeasureTheory" + }, + { + "line": 13, + "text": "open scoped BigOperators" + } + ] + }, + { + "path": "tests/PaperPolarCounterexample.lean", + "line": 118, + "declaration": "full_polar", + "qualified_declaration": "Sendov.PaperPolar.Counterexample.full_polar", + "kind": "theorem", + "signature": "theorem full_polar :\n 1 < ‖∫ t in (0 : ℝ)..1,\n ∏ j : Fin 8, ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * q j)‖", + "blob": "5aa353dd456feb742c1814939cdbfe8ea6fe68ef", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 11, + "text": "namespace Sendov.PaperPolar.Counterexample" + }, + { + "line": 12, + "text": "open MeasureTheory" + }, + { + "line": 13, + "text": "open scoped BigOperators" + } + ] + }, + { + "path": "tests/PaperPolarCounterexample.lean", + "line": 144, + "declaration": "not_universal_mean_half", + "qualified_declaration": "Sendov.PaperPolar.Counterexample.not_universal_mean_half", + "kind": "theorem", + "signature": "theorem not_universal_mean_half :\n ¬ (∀ (m : ℕ) (a : ℝ) (q : Fin m → ℂ), 7 ≤ m → 0 < a → a < 1 →\n (∀ j, ‖q j‖ ≤ 1) →\n 1 ≤ ‖∫ t in (0 : ℝ)..1,\n ∏ j : Fin m, ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * q j)‖ →\n (1 + a) / 2 < ((∑ j : Fin m, q j) / (m : ℂ)).re)", + "blob": "5aa353dd456feb742c1814939cdbfe8ea6fe68ef", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 11, + "text": "namespace Sendov.PaperPolar.Counterexample" + }, + { + "line": 12, + "text": "open MeasureTheory" + }, + { + "line": 13, + "text": "open scoped BigOperators" + } + ] + } + ], + "mapping_note": "Not a Sendov or D counterexample.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI02", + "claim": "m=100, a=9/10, q=50×(2/5)+50×1: full polar>1; E_fin<1/2000; actual-coefficient error<11/10^6; Γ=1/539; C-budget and J>1", + "paper_sources": [ + "first-origin/REPORT.md:248-257" + ], + "paper_evidence": "exact_certified_example", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperCenteredHundred.lean", + "line": 2082, + "declaration": "diagnostic_DI02", + "qualified_declaration": "Sendov.PaperCenteredHundred.diagnostic_DI02", + "kind": "theorem", + "signature": "theorem diagnostic_DI02 :\n q.card = 100 ∧ q.sum / q.card = (7 / 10 : ℂ) ∧\n variance r = 9 / 100 ∧ kappa r = 9 / 100 ∧ Gamma r μ = 1 / 539 ∧\n 1 < K.re ∧ K.im = 0 ∧ 1 < ‖K‖ ∧\n majorant_Efin r μ ((a : ℂ) * μ) < 1 / 2000 ∧\n Efin r μ ((a : ℂ) * μ) < 11 / 10^6 ∧\n majorant_Efin r μ ((a : ℂ) * μ) + Gamma r μ < 1 - a * ‖μ‖ ∧\n 1 < ‖J‖", + "blob": "b60c36550bb5134a760765ca880df63748acea4b", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 8, + "text": "noncomputable section" + }, + { + "line": 9, + "text": "open scoped BigOperators" + }, + { + "line": 10, + "text": "namespace Sendov.PaperCenteredHundred" + }, + { + "line": 11, + "text": "open PaperCentered PaperCenteredBound PaperCenteredCertificate" + } + ] + }, + { + "path": "tests/PaperCenteredHundred.lean", + "line": 22, + "declaration": "pointwise", + "qualified_declaration": "Sendov.PaperCenteredHundred.pointwise", + "kind": "lemma", + "signature": "lemma pointwise (w : ℂ) (hw : w ∈ q) : w ≠ 0 ∧ ‖w‖ ≤ 1", + "blob": "b60c36550bb5134a760765ca880df63748acea4b", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 8, + "text": "noncomputable section" + }, + { + "line": 9, + "text": "open scoped BigOperators" + }, + { + "line": 10, + "text": "namespace Sendov.PaperCenteredHundred" + }, + { + "line": 11, + "text": "open PaperCentered PaperCenteredBound PaperCenteredCertificate" + } + ] + } + ], + "mapping_note": "Unfold a=9/10, μ=7/10, q=50 copies of 2/5 plus 50 copies of 1, r=q−μ. The bundled theorem retains full complex polar, actual variance/kappa/Gamma, literal square-root majorant <1/2000, actual-coefficient error <11/10^6, C-budget and actual J>1. Test-only artifact must be in parent replay.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI03", + "claim": "Conjugate unit-circle family m=6, a=9/10, x=49/50: full polar>1 and finite centered C-budget succeeds", + "paper_sources": [ + "first-origin/REPORT.md:259-269" + ], + "paper_evidence": "exact_certified_example", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperConjugateBudgets.lean", + "line": 38, + "declaration": "DI03_closed", + "qualified_declaration": "Sendov.PaperConjugate.Budgets.DI03_closed", + "kind": "theorem", + "signature": "theorem DI03_closed : Accepted 6 (9 / 10) (49 / 50)", + "blob": "593d4247e262b561a92ab5e2fb03f5a3eab7cbf3", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 22, + "text": "noncomputable section" + }, + { + "line": 23, + "text": "namespace Sendov.PaperConjugate.Budgets" + }, + { + "line": 24, + "text": "open PaperCentered PaperCenteredBound" + } + ] + } + ], + "mapping_note": "Unfold the Accepted definition recorded in definition_evidence: the same actual conjugate family supplies cardinality, unit-circle norms, actual mean/variance, full complex polar, the literal centered majorant plus Gamma budget, and J>1. This is finite data, not a Sendov counterexample or an all-a theorem.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI04", + "claim": "Conjugate unit-circle family m=8, a=99/100, x=497/500: full polar>1 and finite centered C-budget succeeds", + "paper_sources": [ + "first-origin/REPORT.md:259-269" + ], + "paper_evidence": "exact_certified_example", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperConjugateBudgets.lean", + "line": 43, + "declaration": "DI04_closed", + "qualified_declaration": "Sendov.PaperConjugate.Budgets.DI04_closed", + "kind": "theorem", + "signature": "theorem DI04_closed : Accepted 8 (99 / 100) (497 / 500)", + "blob": "593d4247e262b561a92ab5e2fb03f5a3eab7cbf3", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 22, + "text": "noncomputable section" + }, + { + "line": 23, + "text": "namespace Sendov.PaperConjugate.Budgets" + }, + { + "line": 24, + "text": "open PaperCentered PaperCenteredBound" + } + ] + } + ], + "mapping_note": "Unfold the Accepted definition recorded in definition_evidence: the same actual conjugate family supplies cardinality, unit-circle norms, actual mean/variance, full complex polar, the literal centered majorant plus Gamma budget, and J>1. This is finite data, not a Sendov counterexample or an all-a theorem.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI05", + "claim": "Conjugate unit-circle family m=20, a=9/10, x=83/100: full polar>1 and finite centered C-budget succeeds", + "paper_sources": [ + "first-origin/REPORT.md:259-269" + ], + "paper_evidence": "exact_certified_example", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperConjugateBudgets.lean", + "line": 48, + "declaration": "DI05_closed", + "qualified_declaration": "Sendov.PaperConjugate.Budgets.DI05_closed", + "kind": "theorem", + "signature": "theorem DI05_closed : Accepted 20 (9 / 10) (83 / 100)", + "blob": "593d4247e262b561a92ab5e2fb03f5a3eab7cbf3", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 22, + "text": "noncomputable section" + }, + { + "line": 23, + "text": "namespace Sendov.PaperConjugate.Budgets" + }, + { + "line": 24, + "text": "open PaperCentered PaperCenteredBound" + } + ] + } + ], + "mapping_note": "Unfold the Accepted definition recorded in definition_evidence: the same actual conjugate family supplies cardinality, unit-circle norms, actual mean/variance, full complex polar, the literal centered majorant plus Gamma budget, and J>1. This is finite data, not a Sendov counterexample or an all-a theorem.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI06", + "claim": "Conjugate unit-circle family m=100, a=9/10, x=61/100: full polar>1 and finite centered C-budget succeeds", + "paper_sources": [ + "first-origin/REPORT.md:259-269" + ], + "paper_evidence": "exact_certified_example", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperConjugateBudgets.lean", + "line": 53, + "declaration": "DI06_closed", + "qualified_declaration": "Sendov.PaperConjugate.Budgets.DI06_closed", + "kind": "theorem", + "signature": "theorem DI06_closed : Accepted 100 (9 / 10) (61 / 100)", + "blob": "593d4247e262b561a92ab5e2fb03f5a3eab7cbf3", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 22, + "text": "noncomputable section" + }, + { + "line": 23, + "text": "namespace Sendov.PaperConjugate.Budgets" + }, + { + "line": 24, + "text": "open PaperCentered PaperCenteredBound" + } + ] + } + ], + "mapping_note": "Unfold the Accepted definition recorded in definition_evidence: the same actual conjugate family supplies cardinality, unit-circle norms, actual mean/variance, full complex polar, the literal centered majorant plus Gamma budget, and J>1. This is finite data, not a Sendov counterexample or an all-a theorem.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI07", + "claim": "Conjugate unit-circle family m=100, a=99/100, x=22/25: full polar>1 and finite centered C-budget succeeds", + "paper_sources": [ + "first-origin/REPORT.md:259-269" + ], + "paper_evidence": "exact_certified_example", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperConjugateBudgets.lean", + "line": 58, + "declaration": "DI07_closed", + "qualified_declaration": "Sendov.PaperConjugate.Budgets.DI07_closed", + "kind": "theorem", + "signature": "theorem DI07_closed : Accepted 100 (99 / 100) (22 / 25)", + "blob": "593d4247e262b561a92ab5e2fb03f5a3eab7cbf3", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 22, + "text": "noncomputable section" + }, + { + "line": 23, + "text": "namespace Sendov.PaperConjugate.Budgets" + }, + { + "line": 24, + "text": "open PaperCentered PaperCenteredBound" + } + ] + } + ], + "mapping_note": "Unfold the Accepted definition recorded in definition_evidence: the same actual conjugate family supplies cardinality, unit-circle norms, actual mean/variance, full complex polar, the literal centered majorant plus Gamma budget, and J>1. This is finite data, not a Sendov counterexample or an all-a theorem.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI08", + "claim": "m=10,a=1−10^−9: rejected floating root has full K<1; true polar threshold is bracketed between x=a and a+100h²; certified T gap>0 for all feasible x", + "paper_sources": [ + "first-origin-uniform/REPORT.md:53-94" + ], + "paper_evidence": "exact_certified_example", + "acceptance_scope": "required", + "previous_status": "partial", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 28, + "declaration": "exact_source_parameters", + "qualified_declaration": "Sendov.PaperLegacyCertificates.exact_source_parameters", + "kind": "theorem", + "signature": "theorem exact_source_parameters : a = 1 - h ∧\n rejectedX = 0.999999986596654 ∧\n upperX = 9999999990000001 / 10000000000000000 ∧\n legacyX = 999999999000000003 / 1000000000000000000", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 18, + "text": "namespace Sendov.PaperLegacyCertificates" + }, + { + "line": 19, + "text": "open MeasureTheory PaperLegacy" + }, + { + "line": 20, + "text": "open scoped BigOperators" + } + ] + }, + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 47, + "declaration": "rejected_full_polar", + "qualified_declaration": "Sendov.PaperLegacyCertificates.rejected_full_polar", + "kind": "theorem", + "signature": "theorem rejected_full_polar : ‖K 5 a rejectedX‖ < 1", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 18, + "text": "namespace Sendov.PaperLegacyCertificates" + }, + { + "line": 19, + "text": "open MeasureTheory PaperLegacy" + }, + { + "line": 20, + "text": "open scoped BigOperators" + } + ] + }, + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 52, + "declaration": "rejected_not_raw", + "qualified_declaration": "Sendov.PaperLegacyCertificates.rejected_not_raw", + "kind": "theorem", + "signature": "theorem rejected_not_raw : ¬ PaperPolar.RawPolar 10 a rejectedX", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 18, + "text": "namespace Sendov.PaperLegacyCertificates" + }, + { + "line": 19, + "text": "open MeasureTheory PaperLegacy" + }, + { + "line": 20, + "text": "open scoped BigOperators" + } + ] + }, + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 57, + "declaration": "raw_threshold_bracket", + "qualified_declaration": "Sendov.PaperLegacyCertificates.raw_threshold_bracket", + "kind": "theorem", + "signature": "theorem raw_threshold_bracket :\n (∫ t in (0 : ℝ)..1, P a a t ^ ((10 : ℝ) / 2)) < 1 ∧\n 1 < ∫ t in (0 : ℝ)..1, P a upperX t ^ ((10 : ℝ) / 2)", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 18, + "text": "namespace Sendov.PaperLegacyCertificates" + }, + { + "line": 19, + "text": "open MeasureTheory PaperLegacy" + }, + { + "line": 20, + "text": "open scoped BigOperators" + } + ] + }, + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 66, + "declaration": "full_threshold_bracket", + "qualified_declaration": "Sendov.PaperLegacyCertificates.full_threshold_bracket", + "kind": "theorem", + "signature": "theorem full_threshold_bracket : ‖K 5 a a‖ < 1 ∧ 1 < ‖K 5 a upperX‖", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 18, + "text": "namespace Sendov.PaperLegacyCertificates" + }, + { + "line": 19, + "text": "open MeasureTheory PaperLegacy" + }, + { + "line": 20, + "text": "open scoped BigOperators" + } + ] + }, + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 73, + "declaration": "all_feasible_D", + "qualified_declaration": "Sendov.PaperLegacyCertificates.all_feasible_D", + "kind": "theorem", + "signature": "theorem all_feasible_D (x : ℝ) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : PaperPolar.RawPolar 10 a x) :\n PaperTaylor.budget 10 a x < 1 - 10 * a / 11", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 18, + "text": "namespace Sendov.PaperLegacyCertificates" + }, + { + "line": 19, + "text": "open MeasureTheory PaperLegacy" + }, + { + "line": 20, + "text": "open scoped BigOperators" + } + ] + } + ], + "mapping_note": "Exact rejected x=0.999999986596654, a=1−10^−9, h=10^−9 and upper x=a+100h². Brackets are strict at both endpoints; all-feasible D has no surrogate-budget hypothesis. Root existence between endpoints follows from continuity, and monotonicity makes this a threshold bracket. The approximate gap display is not claimed as an exact constant.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI09", + "claim": "Legacy m=10,a=1−10^−9,x=a+3h²: full K>1 and B−T>(3/5)h", + "paper_sources": [ + "first-origin-uniform/legacy_RESULT.md:19-25" + ], + "paper_evidence": "exact_certified_example", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 158, + "declaration": "legacy_complete", + "qualified_declaration": "Sendov.PaperLegacyCertificates.legacy_complete", + "kind": "theorem", + "signature": "theorem legacy_complete :\n (∀ j : Fin 5 × Fin 2, ‖q 5 legacyX j‖ = 1) ∧\n 1 < ‖∫ t in (0 : ℝ)..1, ∏ j : Fin 5 × Fin 2,\n ((a : ℂ) + ((1 - a ^ 2) * t : ℝ) * q 5 legacyX j)‖ ∧\n (3 / 5 : ℝ) * (1 - a) < 1 - 10 * a / 11 - PaperTaylor.budget 10 a legacyX", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 18, + "text": "namespace Sendov.PaperLegacyCertificates" + }, + { + "line": 19, + "text": "open MeasureTheory PaperLegacy" + }, + { + "line": 20, + "text": "open scoped BigOperators" + } + ] + }, + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 89, + "declaration": "legacy_three_fifths", + "qualified_declaration": "Sendov.PaperLegacyCertificates.legacy_three_fifths", + "kind": "theorem", + "signature": "theorem legacy_three_fifths :\n (3 / 5 : ℝ) * h < 1 - 10 * a / 11 - PaperTaylor.budget 10 a legacyX", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 18, + "text": "namespace Sendov.PaperLegacyCertificates" + }, + { + "line": 19, + "text": "open MeasureTheory PaperLegacy" + }, + { + "line": 20, + "text": "open scoped BigOperators" + } + ] + } + ], + "mapping_note": "Exact λ-small finite point x=a+3h² with full polar and strict (3/5)h margin, not weakened to h/3.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI10", + "claim": "Direct-budget certified data m=20,a=9/10,x=83/100 and m=100,a=99/100,x=22/25", + "paper_sources": [ + "first-origin-uniform/REPORT.md:82-94" + ], + "paper_evidence": "exact_certified_example", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 167, + "declaration": "twenty_complete", + "qualified_declaration": "Sendov.PaperLegacyCertificates.twenty_complete", + "kind": "theorem", + "signature": "theorem twenty_complete :\n (∀ j : Fin 10 × Fin 2, ‖q 10 (83 / 100) j‖ = 1) ∧\n 1 < ‖K 10 (9 / 10) (83 / 100)‖ ∧\n PaperTaylor.budget 20 (9 / 10) (83 / 100) < 1 - 20 * (9 / 10) / 21", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 18, + "text": "namespace Sendov.PaperLegacyCertificates" + }, + { + "line": 19, + "text": "open MeasureTheory PaperLegacy" + }, + { + "line": 20, + "text": "open scoped BigOperators" + } + ] + }, + { + "path": "tests/PaperLegacyCertificates.lean", + "line": 173, + "declaration": "hundred_complete", + "qualified_declaration": "Sendov.PaperLegacyCertificates.hundred_complete", + "kind": "theorem", + "signature": "theorem hundred_complete :\n (∀ j : Fin 50 × Fin 2, ‖q 50 (22 / 25) j‖ = 1) ∧\n 1 < ‖K 50 (99 / 100) (22 / 25)‖ ∧\n PaperTaylor.budget 100 (99 / 100) (22 / 25) < 1 - 100 * (99 / 100) / 101", + "blob": "114ea3d35d829a2e36e7fff872b5efc708fc1019", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 18, + "text": "namespace Sendov.PaperLegacyCertificates" + }, + { + "line": 19, + "text": "open MeasureTheory PaperLegacy" + }, + { + "line": 20, + "text": "open scoped BigOperators" + } + ] + } + ], + "mapping_note": "Both full-polar/direct-T diagnostics at their exact rational triples, separate from the centered budgets DI05/DI07.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI11", + "claim": "Secant positive gates at (7,4/5),(8,9/10),(10,9/10); negative gate at (16,9/10) with feasible raw polar", + "paper_sources": [ + "first-origin-uniform/round6/REPORT.md:124-133" + ], + "paper_evidence": "exact_certified_example", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperSecantTests.lean", + "line": 48, + "declaration": "gate_7_four_fifths", + "qualified_declaration": "Sendov.PaperSecant.Tests.gate_7_four_fifths", + "kind": "theorem", + "signature": "theorem gate_7_four_fifths : 0 < Fsec 7 (4 / 5)", + "blob": "645c3392fe1a3b3d6ef1e58ecad7cbd379f40d8f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 5, + "text": "namespace Sendov.PaperSecant.Tests" + }, + { + "line": 6, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "tests/PaperSecantTests.lean", + "line": 52, + "declaration": "gate_8_nine_tenths", + "qualified_declaration": "Sendov.PaperSecant.Tests.gate_8_nine_tenths", + "kind": "theorem", + "signature": "theorem gate_8_nine_tenths : 0 < Fsec 8 (9 / 10)", + "blob": "645c3392fe1a3b3d6ef1e58ecad7cbd379f40d8f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 5, + "text": "namespace Sendov.PaperSecant.Tests" + }, + { + "line": 6, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "tests/PaperSecantTests.lean", + "line": 56, + "declaration": "gate_10_nine_tenths", + "qualified_declaration": "Sendov.PaperSecant.Tests.gate_10_nine_tenths", + "kind": "theorem", + "signature": "theorem gate_10_nine_tenths : 0 < Fsec 10 (9 / 10)", + "blob": "645c3392fe1a3b3d6ef1e58ecad7cbd379f40d8f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 5, + "text": "namespace Sendov.PaperSecant.Tests" + }, + { + "line": 6, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "tests/PaperSecantTests.lean", + "line": 60, + "declaration": "gate_16_nine_tenths_negative", + "qualified_declaration": "Sendov.PaperSecant.Tests.gate_16_nine_tenths_negative", + "kind": "theorem", + "signature": "theorem gate_16_nine_tenths_negative : Fsec 16 (9 / 10) < 0", + "blob": "645c3392fe1a3b3d6ef1e58ecad7cbd379f40d8f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 5, + "text": "namespace Sendov.PaperSecant.Tests" + }, + { + "line": 6, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "tests/PaperSecantTests.lean", + "line": 71, + "declaration": "raw_feasible_at_negative_gate", + "qualified_declaration": "Sendov.PaperSecant.Tests.raw_feasible_at_negative_gate", + "kind": "theorem", + "signature": "theorem raw_feasible_at_negative_gate : PaperPolar.RawPolar 16 (9 / 10) 1", + "blob": "645c3392fe1a3b3d6ef1e58ecad7cbd379f40d8f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 5, + "text": "namespace Sendov.PaperSecant.Tests" + }, + { + "line": 6, + "text": "open MeasureTheory" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI12", + "claim": "Curvature secant does not imply the proposed linear asymptotic extrapolation, exact m=10,a=49/50 counterexample", + "paper_sources": [ + "first-origin-uniform/round6/REPORT.md:84-97" + ], + "paper_evidence": "exact_certified_example", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperSecantTests.lean", + "line": 65, + "declaration": "linear_simplification_fails", + "qualified_declaration": "Sendov.PaperSecant.Tests.linear_simplification_fails", + "kind": "theorem", + "signature": "theorem linear_simplification_fails :\n S 10 (49 / 50) - (1 - (10 - 4 : ℝ) * (1 - 49 / 50) / 6) =\n -(580765093537365039347573397 : ℝ) / 317624371446602655376674688925300", + "blob": "645c3392fe1a3b3d6ef1e58ecad7cbd379f40d8f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 5, + "text": "namespace Sendov.PaperSecant.Tests" + }, + { + "line": 6, + "text": "open MeasureTheory" + } + ] + } + ], + "mapping_note": "Refutes S≥linear formula, not D and not the possibility of another stronger raw-polar mean estimate.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI13", + "claim": "m=7, a∈[7999/10000,8001/10000]: F_sec>0 and D for all feasible x", + "paper_sources": [ + "first-origin-uniform/round6/REPORT.md:135-142" + ], + "paper_evidence": "exact_certified_interval", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperSecantNeighborhoods.lean", + "line": 187, + "declaration": "gate_7_interval", + "qualified_declaration": "Sendov.PaperSecant.Neighborhoods.gate_7_interval", + "kind": "theorem", + "signature": "theorem gate_7_interval {a : ℝ} (ha : a ∈ Set.Icc (7999 / 10000) (8001 / 10000)) :\n 0 < Fsec 7 a", + "blob": "715f50e923a68e5227dfb95af626a7845a18022b", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 10, + "text": "namespace Sendov.PaperSecant.Neighborhoods" + }, + { + "line": 15, + "text": "namespace Bounds" + }, + { + "line": 16, + "text": "variable {z w l u L U l' u' : ℝ}" + } + ] + }, + { + "path": "tests/PaperSecantNeighborhoods.lean", + "line": 192, + "declaration": "D_7_interval", + "qualified_declaration": "Sendov.PaperSecant.Neighborhoods.D_7_interval", + "kind": "theorem", + "signature": "theorem D_7_interval {a x : ℝ} (ha : a ∈ Set.Icc (7999 / 10000) (8001 / 10000))\n (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : PaperPolar.RawPolar 7 a x) :\n PaperTaylor.budget 7 a x < B 7 a", + "blob": "715f50e923a68e5227dfb95af626a7845a18022b", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 10, + "text": "namespace Sendov.PaperSecant.Neighborhoods" + }, + { + "line": 15, + "text": "namespace Bounds" + }, + { + "line": 16, + "text": "variable {z w l u L U l' u' : ℝ}" + } + ] + } + ], + "mapping_note": "Current rational lower certificate differs from the paper display; positive gate and full closed interval are exactly covered.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI14", + "claim": "m=10, a∈[899999/10^6,900001/10^6]: F_sec>0 and D for all feasible x", + "paper_sources": [ + "first-origin-uniform/round6/REPORT.md:135-142" + ], + "paper_evidence": "exact_certified_interval", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperSecantNeighborhoods.lean", + "line": 200, + "declaration": "gate_10_interval", + "qualified_declaration": "Sendov.PaperSecant.Neighborhoods.gate_10_interval", + "kind": "theorem", + "signature": "theorem gate_10_interval {a : ℝ} (ha : a ∈ Set.Icc (899999 / 1000000) (900001 / 1000000)) :\n 0 < Fsec 10 a", + "blob": "715f50e923a68e5227dfb95af626a7845a18022b", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 10, + "text": "namespace Sendov.PaperSecant.Neighborhoods" + }, + { + "line": 15, + "text": "namespace Bounds" + }, + { + "line": 16, + "text": "variable {z w l u L U l' u' : ℝ}" + } + ] + }, + { + "path": "tests/PaperSecantNeighborhoods.lean", + "line": 205, + "declaration": "D_10_interval", + "qualified_declaration": "Sendov.PaperSecant.Neighborhoods.D_10_interval", + "kind": "theorem", + "signature": "theorem D_10_interval {a x : ℝ} (ha : a ∈ Set.Icc (899999 / 1000000) (900001 / 1000000))\n (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hr : PaperPolar.RawPolar 10 a x) :\n PaperTaylor.budget 10 a x < B 10 a", + "blob": "715f50e923a68e5227dfb95af626a7845a18022b", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 10, + "text": "namespace Sendov.PaperSecant.Neighborhoods" + }, + { + "line": 15, + "text": "namespace Bounds" + }, + { + "line": 16, + "text": "variable {z w l u L U l' u' : ℝ}" + } + ] + } + ], + "mapping_note": "Current lower certificate 155747/10^7 is slightly below the paper interval slack; both prove the advertised positivity. Do not claim equality of certificates.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI15", + "claim": "Full-polar nonvacuity throughout both secant neighborhoods: q≡1 for m=7 and five unit-circle pairs at x=93/100 for m=10", + "paper_sources": [ + "first-origin-uniform/round6/REPORT.md:144-146" + ], + "paper_evidence": "exact_certified_interval", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 51, + "declaration": "neighborhood_7", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.neighborhood_7", + "kind": "theorem", + "signature": "theorem neighborhood_7 {a : ℝ}\n (ha : a ∈ Set.Icc (7999 / 10000) (8001 / 10000)) :\n (∀ _j : Fin 7, ‖(1 : ℂ)‖ = 1) ∧ 1 ≤ ‖K a (fun _ : Fin 7 => 1)‖", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperPolar.DomainWitnesses" + }, + { + "line": 16, + "text": "open MeasureTheory" + }, + { + "line": 17, + "text": "open scoped BigOperators" + } + ] + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 152, + "declaration": "neighborhood_10", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.neighborhood_10", + "kind": "theorem", + "signature": "theorem neighborhood_10 {a : ℝ}\n (ha : a ∈ Set.Icc (899999 / 1000000) (900001 / 1000000)) :\n (∀ j, ‖q10 j‖ = 1) ∧ 1 ≤ ‖K a q10‖", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperPolar.DomainWitnesses" + }, + { + "line": 16, + "text": "open MeasureTheory" + }, + { + "line": 17, + "text": "open scoped BigOperators" + } + ] + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 90, + "declaration": "mean_q10", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.mean_q10", + "kind": "theorem", + "signature": "theorem mean_q10 : (∑ j : Fin 10, q10 j) / 10 = (x : ℂ)", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperPolar.DomainWitnesses" + }, + { + "line": 16, + "text": "open MeasureTheory" + }, + { + "line": 17, + "text": "open scoped BigOperators" + } + ] + } + ], + "mapping_note": "Both complete closed neighborhoods have actual full-complex-polar witnesses: seven ones; ten alternating conjugate roots with x=93/100 and imaginary part sqrt(1−x²). No mere assumed raw-polar antecedent.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI16", + "claim": "Pointwise+full polar does not imply α≤17: m=64,a=1/2,q≡1 gives α=24 and K>1", + "paper_sources": [ + "first-origin-uniform/round7/REPORT.md:73-80" + ], + "paper_evidence": "exact_certified_example", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 192, + "declaration": "K_64_exact", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.K_64_exact", + "kind": "theorem", + "signature": "theorem K_64_exact : K (1/2) (fun _ : Fin 64 => 1) =\n ((((5/4 : ℝ)^65 - (1/2 : ℝ)^65) / (65 * (3/4 : ℝ)) : ℝ) : ℂ)", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperPolar.DomainWitnesses" + }, + { + "line": 16, + "text": "open MeasureTheory" + }, + { + "line": 17, + "text": "open scoped BigOperators" + } + ] + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 197, + "declaration": "domain_64", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.domain_64", + "kind": "theorem", + "signature": "theorem domain_64 : alpha 64 (1/2) = 24 ∧ 17 < alpha 64 (1/2) ∧\n (∀ _j : Fin 64, ‖(1 : ℂ)‖ = 1) ∧ 1 < ‖K (1/2) (fun _ : Fin 64 => 1)‖", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperPolar.DomainWitnesses" + }, + { + "line": 16, + "text": "open MeasureTheory" + }, + { + "line": 17, + "text": "open scoped BigOperators" + } + ] + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 204, + "declaration": "not_polar_implies_alpha17", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.not_polar_implies_alpha17", + "kind": "theorem", + "signature": "theorem not_polar_implies_alpha17 :\n ¬ (∀ (m : ℕ) (a : ℝ) (q : Fin m → ℂ), 7 ≤ m → 0 < a → a < 1 →\n (∀ j, ‖q j‖ ≤ 1) → 1 ≤ ‖K a q‖ → alpha m a ≤ 17)", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperPolar.DomainWitnesses" + }, + { + "line": 16, + "text": "open MeasureTheory" + }, + { + "line": 17, + "text": "open scoped BigOperators" + } + ] + } + ], + "mapping_note": "Exact m=64,a=1/2,q≡1 witness and universal-implication refutation. α=24>17 and full-complex K>1.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DI17", + "claim": "Convex-hull finite-moment strengthening fails: p=(z−1)^9(z+1), a=−1/4, reciprocal-square sum 25488/3025<9, nearest critical distance 11/20", + "paper_sources": [ + "first-origin-uniform/round7/REPORT.md:171-181" + ], + "paper_evidence": "exact_certified_example", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 303, + "declaration": "root_geometry", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.Nonroot.root_geometry", + "kind": "theorem", + "signature": "theorem root_geometry : ∀ z ∈ p.roots, ‖z‖ = 1 ∧ z.im = 0", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperPolar.DomainWitnesses" + }, + { + "line": 16, + "text": "open MeasureTheory" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 212, + "text": "namespace Nonroot" + }, + { + "line": 213, + "text": "open Polynomial" + } + ] + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 229, + "declaration": "critical_roots", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.Nonroot.critical_roots", + "kind": "theorem", + "signature": "theorem critical_roots : p.derivative.roots =\n 8 • ({1} : Multiset ℂ) + {(-4/5 : ℂ)}", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperPolar.DomainWitnesses" + }, + { + "line": 16, + "text": "open MeasureTheory" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 212, + "text": "namespace Nonroot" + }, + { + "line": 213, + "text": "open Polynomial" + } + ] + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 235, + "declaration": "critical_multiplicities", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.Nonroot.critical_multiplicities", + "kind": "theorem", + "signature": "theorem critical_multiplicities : p.derivative.rootMultiplicity 1 = 8 ∧\n p.derivative.rootMultiplicity (-4/5) = 1 ∧ p.derivative.roots.card = 9", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperPolar.DomainWitnesses" + }, + { + "line": 16, + "text": "open MeasureTheory" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 212, + "text": "namespace Nonroot" + }, + { + "line": 213, + "text": "open Polynomial" + } + ] + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 251, + "declaration": "convex_hull_nonroot", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.Nonroot.convex_hull_nonroot", + "kind": "theorem", + "signature": "theorem convex_hull_nonroot :\n marked ∈ convexHull ℝ {z : ℂ | z ∈ p.roots} ∧ ¬ p.IsRoot marked", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperPolar.DomainWitnesses" + }, + { + "line": 16, + "text": "open MeasureTheory" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 212, + "text": "namespace Nonroot" + }, + { + "line": 213, + "text": "open Polynomial" + } + ] + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 275, + "declaration": "reciprocal_square_exact", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.Nonroot.reciprocal_square_exact", + "kind": "theorem", + "signature": "theorem reciprocal_square_exact :\n (p.derivative.roots.map (fun w => 1 / ‖marked - w‖ ^ 2)).sum = 25488/3025", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperPolar.DomainWitnesses" + }, + { + "line": 16, + "text": "open MeasureTheory" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 212, + "text": "namespace Nonroot" + }, + { + "line": 213, + "text": "open Polynomial" + } + ] + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 282, + "declaration": "reciprocal_square_lt_nine", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.Nonroot.reciprocal_square_lt_nine", + "kind": "theorem", + "signature": "theorem reciprocal_square_lt_nine :\n (p.derivative.roots.map (fun w => 1 / ‖marked - w‖ ^ 2)).sum < 9", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperPolar.DomainWitnesses" + }, + { + "line": 16, + "text": "open MeasureTheory" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 212, + "text": "namespace Nonroot" + }, + { + "line": 213, + "text": "open Polynomial" + } + ] + }, + { + "path": "tests/PaperPolarDomainWitnesses.lean", + "line": 288, + "declaration": "nearest_critical_distance", + "qualified_declaration": "Sendov.PaperPolar.DomainWitnesses.Nonroot.nearest_critical_distance", + "kind": "theorem", + "signature": "theorem nearest_critical_distance :\n (∀ w ∈ p.derivative.roots, (11 : ℝ)/20 ≤ ‖marked - w‖) ∧\n (∃ w ∈ p.derivative.roots, ‖marked - w‖ = 11/20) ∧ (11 : ℝ)/20 < 1", + "blob": "04f02e5db6551a4aeaaa92cad82ab2dd02e6bba6", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 15, + "text": "namespace Sendov.PaperPolar.DomainWitnesses" + }, + { + "line": 16, + "text": "open MeasureTheory" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 212, + "text": "namespace Nonroot" + }, + { + "line": 213, + "text": "open Polynomial" + } + ] + } + ], + "mapping_note": "Unfold p=(X−1)^9(X+1), marked=−1/4. The actual derivative roots are eight copies of 1 and one −4/5; exact reciprocal-square sum 25488/3025<9 and attained nearest distance 11/20. Marked is explicitly NOT a root; no marked-root theorem is refuted.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "BO01", + "claim": "Unrestricted squared-distance multiset identity and aggregate first/second-moment rigidity", + "paper_sources": [ + "boundary-refine/REPORT.md:35-41" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Boundary.lean", + "line": 91, + "declaration": "sum_norm_sub_one_sq", + "qualified_declaration": "Sendov.sum_norm_sub_one_sq", + "kind": "lemma", + "signature": "lemma sum_norm_sub_one_sq (s : Multiset ℂ) :\n (s.map (fun v => ‖v - 1‖ ^ 2)).sum =\n (s.map (fun v => ‖v‖ ^ 2)).sum - 2 * s.sum.re + s.card", + "blob": "2650f7b3909fb7d12cfa4ea39da474e315e3d0c0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 48, + "text": "namespace Sendov" + }, + { + "line": 50, + "text": "open Polynomial" + } + ] + }, + { + "path": "Sendov/Boundary.lean", + "line": 101, + "declaration": "all_eq_one_of_sum_norm_sq_le_card", + "qualified_declaration": "Sendov.all_eq_one_of_sum_norm_sq_le_card", + "kind": "lemma", + "signature": "lemma all_eq_one_of_sum_norm_sq_le_card {s : Multiset ℂ}\n (hsecond : (s.map (fun v => ‖v‖ ^ 2)).sum ≤ (s.card : ℝ))\n (hfirst : (s.card : ℝ) ≤ s.sum.re) : ∀ v ∈ s, v = 1", + "blob": "2650f7b3909fb7d12cfa4ea39da474e315e3d0c0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 48, + "text": "namespace Sendov" + }, + { + "line": 50, + "text": "open Polynomial" + } + ] + } + ], + "mapping_note": "Includes empty and repeated multisets; no cardinality division.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "BO02", + "claim": "Boundary reciprocal/half-plane identity and weaker averaged q-bound force q≡1", + "paper_sources": [ + "boundary-refine/REPORT.md:18-24,43-55" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Boundary.lean", + "line": 78, + "declaration": "half_le_re_inv_one_sub", + "qualified_declaration": "Sendov.half_le_re_inv_one_sub", + "kind": "lemma", + "signature": "lemma half_le_re_inv_one_sub {z : ℂ} (hz : ‖z‖ ≤ 1) (hz1 : z ≠ 1) :\n (1 : ℝ) / 2 ≤ (((1 : ℂ) - z)⁻¹).re", + "blob": "2650f7b3909fb7d12cfa4ea39da474e315e3d0c0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 48, + "text": "namespace Sendov" + }, + { + "line": 50, + "text": "open Polynomial" + } + ] + }, + { + "path": "Sendov/Boundary.lean", + "line": 121, + "declaration": "boundary_reciprocal", + "qualified_declaration": "Sendov.boundary_reciprocal", + "kind": "theorem", + "signature": "theorem boundary_reciprocal {n : ℕ} {Zs Qi : Multiset ℂ} (hn0 : (n : ℂ) ≠ 0)\n (hZ : ∀ u ∈ Zs, u ≠ 0) (hQ : ∀ u ∈ Qi, u ≠ 0)\n (hI : Zs.prod = (n : ℂ) * Qi.prod)\n (hII : 2 * sumEraseProd Zs = (n : ℂ) * sumEraseProd Qi) :\n (Qi.map (fun u => u⁻¹)).sum = 2 * (Zs.map (fun u => u⁻¹)).sum", + "blob": "2650f7b3909fb7d12cfa4ea39da474e315e3d0c0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 48, + "text": "namespace Sendov" + }, + { + "line": 50, + "text": "open Polynomial" + } + ] + }, + { + "path": "Sendov/Boundary.lean", + "line": 138, + "declaration": "all_q_eq_one_of_sum_norm_sq_le", + "qualified_declaration": "Sendov.all_q_eq_one_of_sum_norm_sq_le", + "kind": "theorem", + "signature": "theorem all_q_eq_one_of_sum_norm_sq_le {N : ℕ} {qs zs : Multiset ℂ}\n (hqcard : qs.card = N) (hzcard : zs.card = N)\n (hqsecond : (qs.map (fun v => ‖v‖ ^ 2)).sum ≤ (N : ℝ))\n (hz1 : ∀ w ∈ zs, ‖w‖ ≤ 1) (hzne : ∀ w ∈ zs, w ≠ 1)\n (hBR : qs.sum = 2 * (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum) :\n ∀ v ∈ qs, v = 1", + "blob": "2650f7b3909fb7d12cfa4ea39da474e315e3d0c0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 48, + "text": "namespace Sendov" + }, + { + "line": 50, + "text": "open Polynomial" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "BO03", + "claim": "Rubinstein strict-or-extremal p=c(X^n−1) and boundary Sendov, with unchanged final contracts", + "paper_sources": [ + "boundary-refine/REPORT.md:67-77,123-129" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Boundary.lean", + "line": 159, + "declaration": "rubinstein_one", + "qualified_declaration": "Sendov.rubinstein_one", + "kind": "theorem", + "signature": "theorem rubinstein_one {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegree = n)\n (hroots : ∀ w ∈ p.roots, ‖w‖ ≤ 1) (hp1 : p.eval 1 = 0) :\n (∃ ζ : ℂ, (derivative p).eval ζ = 0 ∧ ‖ζ - 1‖ < 1)\n ∨ p = C p.leadingCoeff * (X ^ n - 1)", + "blob": "2650f7b3909fb7d12cfa4ea39da474e315e3d0c0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 48, + "text": "namespace Sendov" + }, + { + "line": 50, + "text": "open Polynomial" + } + ] + }, + { + "path": "Sendov/Boundary.lean", + "line": 283, + "declaration": "sendov_boundary_one", + "qualified_declaration": "Sendov.sendov_boundary_one", + "kind": "theorem", + "signature": "theorem sendov_boundary_one {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegree = n)\n (hroots : ∀ w ∈ p.roots, ‖w‖ ≤ 1) (hp1 : p.eval 1 = 0) :\n ∃ ζ : ℂ, (derivative p).eval ζ = 0 ∧ ‖ζ - 1‖ ≤ 1", + "blob": "2650f7b3909fb7d12cfa4ea39da474e315e3d0c0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 48, + "text": "namespace Sendov" + }, + { + "line": 50, + "text": "open Polynomial" + } + ] + }, + { + "path": "Sendov/Conjecture.lean", + "line": 158, + "declaration": "sendov", + "qualified_declaration": "Sendov.sendov", + "kind": "theorem", + "signature": "theorem sendov {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegree = n)\n (hroots : ∀ w ∈ p.roots, ‖w‖ ≤ 1) {a : ℂ} (hpa : p.eval a = 0) :\n ∃ ζ : ℂ, (derivative p).eval ζ = 0 ∧ ‖ζ - a‖ ≤ 1", + "blob": "e93285098fb6d1aa8af03052283fb7ae76ca2d62", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 36, + "text": "namespace Sendov" + }, + { + "line": 38, + "text": "open Polynomial" + } + ] + }, + { + "path": "Sendov/Conjecture.lean", + "line": 83, + "declaration": "phelps_rodriguez", + "qualified_declaration": "Sendov.phelps_rodriguez", + "kind": "theorem", + "signature": "theorem phelps_rodriguez {n : ℕ} (hn : 2 ≤ n) {p : ℂ[X]} (hdeg : p.natDegree = n)\n (hroots : ∀ w ∈ p.roots, ‖w‖ ≤ 1) {a : ℂ} (hpa : p.eval a = 0) :\n (∃ ζ : ℂ, (derivative p).eval ζ = 0 ∧ ‖ζ - a‖ < 1)\n ∨ (‖a‖ = 1 ∧ ∃ c : ℂ, c ≠ 0 ∧ p = C c * (X ^ n - C (a ^ n)))", + "blob": "e93285098fb6d1aa8af03052283fb7ae76ca2d62", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 36, + "text": "namespace Sendov" + }, + { + "line": 38, + "text": "open Polynomial" + } + ] + } + ], + "mapping_note": "The boundary equality classification IS proved; do not conflate with missing general collinear equality. Actual Solution consumption retained.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "BO04", + "claim": "Moment premise alone is strictly weaker than pointwise disk; consistent countermodels show necessity of each generic/boundary hypothesis", + "paper_sources": [ + "boundary-refine/REPORT.md:94-99" + ], + "paper_evidence": "kernel_proved_countermodel_family", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "tests/BoundaryProbe.lean", + "line": 63, + "declaration": null, + "qualified_declaration": null, + "kind": "anonymous_example", + "signature": "example : ∃ s : Multiset ℂ,\n (s.map (fun v => ‖v‖ ^ 2)).sum ≤ (s.card : ℝ) ∧ ¬ (∀ v ∈ s, ‖v‖ ≤ 1)", + "blob": "c5c124686c53d94572b74ab4b0db98bc9d7da810", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Sendov" + } + ] + }, + { + "path": "tests/BoundaryProbe.lean", + "line": 68, + "declaration": null, + "qualified_declaration": null, + "kind": "anonymous_example", + "signature": "example : ∃ s : Multiset ℂ,\n (s.map (fun v => ‖v‖ ^ 2)).sum ≤ (s.card : ℝ) ∧ ¬ (∀ v ∈ s, v = 1)", + "blob": "c5c124686c53d94572b74ab4b0db98bc9d7da810", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Sendov" + } + ] + }, + { + "path": "tests/BoundaryProbe.lean", + "line": 72, + "declaration": null, + "qualified_declaration": null, + "kind": "anonymous_example", + "signature": "example : ∃ s : Multiset ℂ,\n (s.card : ℝ) ≤ s.sum.re ∧ ¬ (∀ v ∈ s, v = 1)", + "blob": "c5c124686c53d94572b74ab4b0db98bc9d7da810", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Sendov" + } + ] + }, + { + "path": "tests/BoundaryProbe.lean", + "line": 77, + "declaration": null, + "qualified_declaration": null, + "kind": "anonymous_example", + "signature": "example : ∃ s : Multiset ℂ,\n (s.card : ℝ) = s.sum.re ∧ ¬ (∀ v ∈ s, v = 1)", + "blob": "c5c124686c53d94572b74ab4b0db98bc9d7da810", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Sendov" + } + ] + }, + { + "path": "tests/BoundaryProbe.lean", + "line": 84, + "declaration": null, + "qualified_declaration": null, + "kind": "anonymous_example", + "signature": "example : ∃ qs zs : Multiset ℂ,\n qs.card = 1 ∧ zs.card = 1 ∧\n (∀ w ∈ zs, ‖w‖ ≤ 1) ∧ (∀ w ∈ zs, w ≠ 1) ∧\n qs.sum = 2 * (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum ∧\n ¬ (∀ v ∈ qs, v = 1)", + "blob": "c5c124686c53d94572b74ab4b0db98bc9d7da810", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Sendov" + } + ] + }, + { + "path": "tests/BoundaryProbe.lean", + "line": 93, + "declaration": null, + "qualified_declaration": null, + "kind": "anonymous_example", + "signature": "example : ∃ qs zs : Multiset ℂ,\n qs.card = 1 ∧ zs.card = 1 ∧\n (qs.map (fun v => ‖v‖ ^ 2)).sum ≤ (1 : ℝ) ∧ (∀ w ∈ zs, ‖w‖ ≤ 1) ∧\n qs.sum = 2 * (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum ∧\n ¬ (∀ v ∈ qs, v = 1)", + "blob": "c5c124686c53d94572b74ab4b0db98bc9d7da810", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Sendov" + } + ] + }, + { + "path": "tests/BoundaryProbe.lean", + "line": 102, + "declaration": null, + "qualified_declaration": null, + "kind": "anonymous_example", + "signature": "example : ∃ qs zs : Multiset ℂ,\n qs.card = 1 ∧ zs.card = 1 ∧\n (qs.map (fun v => ‖v‖ ^ 2)).sum ≤ (1 : ℝ) ∧ (∀ w ∈ zs, w ≠ 1) ∧\n qs.sum = 2 * (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum ∧\n ¬ (∀ v ∈ qs, v = 1)", + "blob": "c5c124686c53d94572b74ab4b0db98bc9d7da810", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Sendov" + } + ] + }, + { + "path": "tests/BoundaryProbe.lean", + "line": 111, + "declaration": null, + "qualified_declaration": null, + "kind": "anonymous_example", + "signature": "example : ∃ qs zs : Multiset ℂ,\n qs.card = 1 ∧ zs.card = 1 ∧\n (qs.map (fun v => ‖v‖ ^ 2)).sum ≤ (1 : ℝ) ∧\n (∀ w ∈ zs, ‖w‖ ≤ 1) ∧ (∀ w ∈ zs, w ≠ 1) ∧ ¬ (∀ v ∈ qs, v = 1)", + "blob": "c5c124686c53d94572b74ab4b0db98bc9d7da810", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Sendov" + } + ] + }, + { + "path": "tests/BoundaryProbe.lean", + "line": 119, + "declaration": null, + "qualified_declaration": null, + "kind": "anonymous_example", + "signature": "example : ∃ qs zs : Multiset ℂ,\n qs.card = 1 ∧ (qs.map (fun v => ‖v‖ ^ 2)).sum ≤ (1 : ℝ) ∧\n (∀ w ∈ zs, ‖w‖ ≤ 1) ∧ (∀ w ∈ zs, w ≠ 1) ∧\n qs.sum = 2 * (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum ∧\n ¬ (∀ v ∈ qs, v = 1)", + "blob": "c5c124686c53d94572b74ab4b0db98bc9d7da810", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Sendov" + } + ] + }, + { + "path": "tests/BoundaryProbe.lean", + "line": 135, + "declaration": null, + "qualified_declaration": null, + "kind": "anonymous_example", + "signature": "example : ∃ qs zs : Multiset ℂ,\n zs.card = 0 ∧ (qs.map (fun v => ‖v‖ ^ 2)).sum ≤ (0 : ℝ) ∧\n (∀ w ∈ zs, ‖w‖ ≤ 1) ∧ (∀ w ∈ zs, w ≠ 1) ∧\n qs.sum = 2 * (zs.map (fun w => ((1 : ℂ) - w)⁻¹)).sum ∧\n ¬ (∀ v ∈ qs, v = 1)", + "blob": "c5c124686c53d94572b74ab4b0db98bc9d7da810", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Sendov" + } + ] + } + ], + "mapping_note": "A finite countermodel family, not ten new universal theorem routes.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "CO01", + "claim": "Real-split derivative multiset exhausts inherited roots with one less multiplicity plus distinct simple new gap roots", + "paper_sources": [ + "collinear/REPORT.md:已通过的数学声明 1" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Collinear/Gate.lean", + "line": 11, + "declaration": "derivative_root_budget", + "qualified_declaration": "Collinear.derivative_root_budget", + "kind": "theorem", + "signature": "theorem derivative_root_budget (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree) :\n p.derivative.Splits ∧\n p.derivative.roots = (p.roots - p.roots.dedup) +\n (p.derivative.roots.toFinset \\ p.roots.toFinset).val ∧\n (p.derivative.roots.toFinset \\ p.roots.toFinset).card + 1 =\n p.roots.toFinset.card", + "blob": "d3023b0775d1ce53810139a98f4b997e905acca2", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 4, + "text": "open Polynomial" + }, + { + "line": 6, + "text": "namespace Collinear" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "CO02", + "claim": "Every new critical point occupies one adjacent real-root gap; every gap has a unique simple critical point", + "paper_sources": [ + "collinear/REPORT.md:已通过的数学声明 2-3" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Collinear/Gate.lean", + "line": 97, + "declaration": "new_critical_point_gap", + "qualified_declaration": "Collinear.new_critical_point_gap", + "kind": "theorem", + "signature": "theorem new_critical_point_gap (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree)\n (z : ℝ) (hz : z ∈ p.derivative.roots) (hzp : z ∉ p.roots) :\n p.derivative.rootMultiplicity z = 1 ∧\n ∃ a ∈ p.roots, ∃ b ∈ p.roots,\n a < z ∧ z < b ∧\n (∀ x ∈ p.roots, x ∉ Set.Ioo a b) ∧\n (∀ w ∈ p.derivative.roots, w ∈ Set.Ioo a b → w = z)", + "blob": "d3023b0775d1ce53810139a98f4b997e905acca2", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 4, + "text": "open Polynomial" + }, + { + "line": 6, + "text": "namespace Collinear" + } + ] + }, + { + "path": "Sendov/Collinear/Gate.lean", + "line": 130, + "declaration": "adjacent_gap_unique", + "qualified_declaration": "Collinear.adjacent_gap_unique", + "kind": "theorem", + "signature": "theorem adjacent_gap_unique (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree)\n (a : ℝ) (ha : a ∈ p.roots) (b : ℝ) (hb : b ∈ p.roots)\n (hab : a < b) (hgap : ∀ x ∈ p.roots, x ∉ Set.Ioo a b) :\n ∃! z : ℝ, z ∈ p.derivative.roots ∧ z ∈ Set.Ioo a b ∧\n p.derivative.rootMultiplicity z = 1", + "blob": "d3023b0775d1ce53810139a98f4b997e905acca2", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 4, + "text": "open Polynomial" + }, + { + "line": 6, + "text": "namespace Collinear" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "CO03", + "claim": "Occurrence-counted signed-side domination P_-≤Q_-, P_+≤Q_+ at any marked real root", + "paper_sources": [ + "collinear/REPORT.md:已通过的数学声明 4" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Collinear/Mass.lean", + "line": 67, + "declaration": "signed_reciprocal_domination", + "qualified_declaration": "Collinear.signed_reciprocal_domination", + "kind": "theorem", + "signature": "theorem signed_reciprocal_domination (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree)\n (a : ℝ) (ha : a ∈ p.roots) :\n (((p.roots.filter (· < a)).map (fun x => 1 / (a - x))).sum ≤\n ((p.derivative.roots.filter (· < a)).map (fun y => 1 / (a - y))).sum) ∧\n (((p.roots.filter (a < ·)).map (fun x => 1 / (x - a))).sum ≤\n ((p.derivative.roots.filter (a < ·)).map (fun y => 1 / (y - a))).sum)", + "blob": "a4588a1ebce23b6f3d13fbcbbc144248a57133ea", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Polynomial" + }, + { + "line": 4, + "text": "open scoped BigOperators" + }, + { + "line": 6, + "text": "namespace Collinear" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "CO04", + "claim": "Simple marked-root reciprocal balance, signed/absolute decomposition and two-sided mass 2P_±≤Q", + "paper_sources": [ + "collinear/REPORT.round2.md:26-35" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Collinear/Balance.lean", + "line": 7, + "declaration": "reciprocal_balance", + "qualified_declaration": "Collinear.reciprocal_balance", + "kind": "theorem", + "signature": "theorem reciprocal_balance (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree)\n (a : ℝ) (ha : a ∈ p.roots) (hd : p.derivative.eval a ≠ 0) :\n (p.derivative.roots.map (fun x => 1 / (a - x))).sum =\n 2 * (p.roots.map (fun x => 1 / (a - x))).sum", + "blob": "678b146e32fea6310d574f980dce37d6be5bd4d3", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Polynomial" + }, + { + "line": 4, + "text": "namespace Collinear" + } + ] + }, + { + "path": "Sendov/Collinear/Balance.lean", + "line": 33, + "declaration": "reciprocal_decomposition", + "qualified_declaration": "Collinear.reciprocal_decomposition", + "kind": "theorem", + "signature": "theorem reciprocal_decomposition (s : Multiset ℝ) (a : ℝ) :\n (s.map (fun x => 1 / (a - x))).sum =\n ((s.filter (· < a)).map (fun x => 1 / (a - x))).sum -\n ((s.filter (a < ·)).map (fun x => 1 / (x - a))).sum ∧\n (s.map (fun x => 1 / |a - x|)).sum =\n ((s.filter (· < a)).map (fun x => 1 / (a - x))).sum +\n ((s.filter (a < ·)).map (fun x => 1 / (x - a))).sum", + "blob": "678b146e32fea6310d574f980dce37d6be5bd4d3", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Polynomial" + }, + { + "line": 4, + "text": "namespace Collinear" + } + ] + }, + { + "path": "Sendov/Collinear/Balance.lean", + "line": 59, + "declaration": "two_sided_mass", + "qualified_declaration": "Collinear.two_sided_mass", + "kind": "theorem", + "signature": "theorem two_sided_mass (p : ℝ[X]) (hs : p.Splits) (hn : 0 < p.natDegree)\n (a : ℝ) (ha : a ∈ p.roots) (hd : p.derivative.eval a ≠ 0) :\n 2 * ((p.roots.filter (· < a)).map (fun x => 1 / (a - x))).sum ≤\n (p.derivative.roots.map (fun x => 1 / |a - x|)).sum ∧\n 2 * ((p.roots.filter (a < ·)).map (fun x => 1 / (x - a))).sum ≤\n (p.derivative.roots.map (fun x => 1 / |a - x|)).sum", + "blob": "678b146e32fea6310d574f980dce37d6be5bd4d3", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Polynomial" + }, + { + "line": 4, + "text": "namespace Collinear" + } + ] + } + ], + "mapping_note": "", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "CO05", + "claim": "Real-split interval-diameter reciprocal lower bound Q≥2(n−1)/(B−A), with repeated-root disjunction", + "paper_sources": [ + "collinear/REPORT.round2.md:37-43" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Collinear/Diameter.lean", + "line": 34, + "declaration": "diameter_reciprocal", + "qualified_declaration": "Collinear.diameter_reciprocal", + "kind": "theorem", + "signature": "theorem diameter_reciprocal (p : ℝ[X]) (hs : p.Splits) (hn : 2 ≤ p.natDegree)\n (A B : ℝ) (hAB : A < B) (hroots : ∀ x ∈ p.roots, x ∈ Set.Icc A B)\n (a : ℝ) (ha : a ∈ p.roots) :\n p.derivative.eval a = 0 ∨\n (p.natDegree - 1 : ℝ) * (2 / (B - A)) ≤\n (p.derivative.roots.map (fun x => 1 / |a - x|)).sum", + "blob": "9201a1bdccaf44c08d19f2a673bca71e8a59a05c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 3, + "text": "open Polynomial" + }, + { + "line": 4, + "text": "namespace Collinear" + } + ] + } + ], + "mapping_note": "Endpoints a=A,B are allowed; no division by side lengths.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "CO06", + "claim": "Real-split diameter moment for all real r≥1, with full multiplicity and p′(a)=0 disjunction", + "paper_sources": [ + "collinear/REPORT.round2.md:9-22,45-50" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Collinear/Moment.lean", + "line": 31, + "declaration": "diameter_moment", + "qualified_declaration": "Collinear.diameter_moment", + "kind": "theorem", + "signature": "theorem diameter_moment (p : ℝ[X]) (hs : p.Splits) (hn : 2 ≤ p.natDegree)\n (A B : ℝ) (hAB : A < B) (hroots : ∀ x ∈ p.roots, x ∈ Set.Icc A B)\n (a : ℝ) (ha : a ∈ p.roots) (r : ℝ) (hr : 1 ≤ r) :\n p.derivative.eval a = 0 ∨\n (p.natDegree - 1 : ℝ) * (2 / (B - A)) ^ r ≤\n (p.derivative.roots.map (fun x => |a - x| ^ (-r))).sum", + "blob": "71906f976e430cc73648c3cf520083535da92131", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 4, + "text": "open Polynomial" + }, + { + "line": 5, + "text": "open scoped BigOperators" + }, + { + "line": 6, + "text": "namespace Collinear" + } + ] + } + ], + "mapping_note": "No monic/squarefree/interior assumptions. This is not arbitrary complex-collinear affine transport.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "CO07", + "claim": "Repeated-root finite-real reciprocal formulation cannot omit the p′(a)=0 disjunction: p=(X−a)^2", + "paper_sources": [ + "collinear/REPORT.round2.md:65-74" + ], + "paper_evidence": "kernel_proved_countermodel_family", + "acceptance_scope": "required", + "previous_status": "theorem", + "current_status": "theorem", + "lean": [ + { + "path": "tests/CollinearRound2Tests.lean", + "line": 73, + "declaration": null, + "qualified_declaration": null, + "kind": "anonymous_example", + "signature": "example (a : ℝ) :\n let p : ℝ[X] := (X - C a) ^ 2\n p.Splits ∧ p.natDegree = 2 ∧ a - 1 < a + 1 ∧\n (∀ x ∈ p.roots, x ∈ Set.Icc (a - 1) (a + 1)) ∧\n a ∈ p.roots ∧\n ¬((p.natDegree - 1 : ℝ) * (2 / ((a + 1) - (a - 1))) ≤\n (p.derivative.roots.map (fun x => 1 / |a - x|)).sum)", + "blob": "4efdd95b479d9ad25e2abc8821cbf70578923041", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 4, + "text": "open Polynomial" + }, + { + "line": 5, + "text": "namespace Collinear.Round2Tests" + } + ] + } + ], + "mapping_note": "Real inverse zero equals zero, not infinity.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "EX01", + "claim": "Under pointwise+raw polar, v/|μ|²≤b/(1−b)≤α/3, hence Γ≤α/[3(m−1)]<7h/18 for m≥7", + "paper_sources": [ + "first-origin-uniform/round7/REPORT.md:115-129" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "derived_corollary", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperPolar.lean", + "line": 125, + "declaration": "b_le_alpha", + "qualified_declaration": "Sendov.PaperPolar.b_le_alpha", + "kind": "theorem", + "signature": "theorem b_le_alpha {m : ℕ} {a x : ℝ} (hm : 0 < m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) : b a x ≤ alpha m a / (3 + alpha m a)", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperPolar" + }, + { + "line": 14, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperCentered.lean", + "line": 281, + "declaration": "norm_kappa_le_variance", + "qualified_declaration": "Sendov.PaperCentered.norm_kappa_le_variance", + "kind": "theorem", + "signature": "theorem norm_kappa_le_variance (r : Multiset ℂ) : ‖kappa r‖ ≤ variance r", + "blob": "75c413bee43d1b3667a4fba5f98dca14ba8cba24", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 7, + "text": "noncomputable section" + }, + { + "line": 8, + "text": "open scoped BigOperators" + }, + { + "line": 9, + "text": "open Polynomial" + }, + { + "line": 10, + "text": "namespace Sendov.PaperCentered" + } + ] + }, + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "line": 138, + "declaration": "centered_variance_le", + "qualified_declaration": "Sendov.PaperConsequences.centered_variance_le", + "kind": "theorem", + "signature": "theorem centered_variance_le (q : Multiset ℂ) (μ : ℂ) (hm : 0 < q.card)\n (hmean : q.sum = q.card * μ) (hq : ∀ v ∈ q, ‖v‖ ≤ 1) :\n PaperCentered.variance (q.map (fun v => v - μ)) ≤ 1 - ‖μ‖ ^ 2 ∧ ‖μ‖ ≤ 1", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "noncomputable section" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 18, + "text": "open Polynomial Filter" + }, + { + "line": 19, + "text": "namespace Sendov.PaperConsequences" + } + ] + }, + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "line": 179, + "declaration": "variance_ratio_le_alpha", + "qualified_declaration": "Sendov.PaperConsequences.variance_ratio_le_alpha", + "kind": "theorem", + "signature": "theorem variance_ratio_le_alpha (q : Multiset ℂ) {μ : ℂ} {a x : ℝ}\n (hm : 7 ≤ q.card) (ha : 0 < a) (ha1 : a < 1)\n (hmean : q.sum = q.card * μ) (hq : ∀ v ∈ q, ‖v‖ ≤ 1)\n (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hx : μ.re = x)\n (hr : PaperPolar.RawPolar q.card a x) :\n PaperCentered.variance (q.map (fun v => v - μ)) / ‖μ‖ ^ 2 ≤\n PaperPolar.alpha q.card a / 3", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "noncomputable section" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 18, + "text": "open Polynomial Filter" + }, + { + "line": 19, + "text": "namespace Sendov.PaperConsequences" + } + ] + }, + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "line": 202, + "declaration": "Gamma_lt_seven_eighteenths", + "qualified_declaration": "Sendov.PaperConsequences.Gamma_lt_seven_eighteenths", + "kind": "theorem", + "signature": "theorem Gamma_lt_seven_eighteenths (q : Multiset ℂ) {μ : ℂ} {a x : ℝ}\n (hm : 7 ≤ q.card) (ha : 0 < a) (ha1 : a < 1)\n (hmean : q.sum = q.card * μ) (hq : ∀ v ∈ q, ‖v‖ ≤ 1)\n (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hx : μ.re = x)\n (hr : PaperPolar.RawPolar q.card a x) :\n PaperCentered.Gamma (q.map (fun v => v - μ)) μ < 7 * (1 - a) / 18", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "noncomputable section" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 18, + "text": "open Polynomial Filter" + }, + { + "line": 19, + "text": "namespace Sendov.PaperConsequences" + } + ] + }, + { + "path": "Sendov/Analytic/PaperPolar.lean", + "line": 150, + "declaration": "geometry", + "qualified_declaration": "Sendov.PaperPolar.geometry", + "kind": "theorem", + "signature": "theorem geometry {m : ℕ} {a x : ℝ} (hm : 7 ≤ m)\n (ha0 : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hraw : RawPolar m a x) : a / 2 < x ∧ 0 < c a x", + "blob": "e3afdd8868720b80604a65af389936088093319f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperPolar" + }, + { + "line": 14, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperMomentCorollaries.lean", + "qualified_declaration": "Sendov.PaperMomentCorollaries.EX01", + "kind": "theorem" + } + ], + "mapping_note": "Original mathematical recipe is now also an exported Lean contract; parent compilation and kernel receipt tag: final-corollaries.", + "corollary_recipe": "Set m=q.card≥7,r=q−μ,s=|μ|²,c=1−b. centered_variance_le gives v≤1−s. geometry gives c>0; algebra gives s≥x²≥c since x²−c=(x−a)². Hence v/s≤(1−s)/s≤(1−c)/c=b/(1−b). Clear positive denominators in b_le_alpha to obtain b/(1−b)≤alpha/3. Divide by m−1>0 and unfold Gamma=v/((m−1)s) to get Gamma≤alpha/[3(m−1)]. Since alpha=m(1+a)h/2,1+a<2 and m/(m−1)≤7/6, Gamma<7h/18. variance_ratio_le_alpha and Gamma_lt_seven_eighteenths independently export the terminal bounds; the intermediate b/(1−b) comparison is the explicit algebra just given.", + "remaining_contract": null, + "compiled_corollary_exports": [ + { + "path": "Sendov/Analytic/PaperMomentCorollaries.lean", + "qualified_declaration": "Sendov.PaperMomentCorollaries.EX01", + "kind": "theorem" + } + ] + }, + { + "id": "EX02", + "claim": "Conditional E_fin≤h/2 implies centered contradiction via Γ+E_fin<8h/9 v - μ)) μ (a * μ) +\n Gamma (q.map (fun v => v - μ)) μ < 1 - a * ‖μ‖) :\n 1 < ‖(q.card + 1 : ℂ) *\n (∫ t in (0 : ℝ)..1, (q.map (fun v => 1 - (a : ℂ) * t * v)).prod)‖", + "blob": "5615181f428ef9f5d699ffc42e474824c400b762", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 13, + "text": "noncomputable section" + }, + { + "line": 14, + "text": "open scoped BigOperators" + }, + { + "line": 15, + "text": "namespace Sendov.PaperCenteredBound" + }, + { + "line": 16, + "text": "open PaperCentered" + } + ] + }, + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "line": 226, + "declaration": "norm_J_gt_one_of_majorant_half", + "qualified_declaration": "Sendov.PaperConsequences.norm_J_gt_one_of_majorant_half", + "kind": "theorem", + "signature": "theorem norm_J_gt_one_of_majorant_half (q : Multiset ℂ) {μ : ℂ} {a x : ℝ}\n (hm : 7 ≤ q.card) (ha : 0 < a) (ha1 : a < 1)\n (hmean : q.sum = q.card * μ) (hq : ∀ v ∈ q, ‖v‖ ≤ 1)\n (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hx : μ.re = x)\n (hr : PaperPolar.RawPolar q.card a x)\n (hfin : PaperCenteredBound.majorant_Efin (q.map (fun v => v - μ)) μ (a * μ) ≤\n (1 - a) / 2) :\n 1 < ‖(q.card + 1 : ℂ) *\n (∫ t in (0 : ℝ)..1, (q.map (fun v => 1 - (a : ℂ) * t * v)).prod)‖", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "noncomputable section" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 18, + "text": "open Polynomial Filter" + }, + { + "line": 19, + "text": "namespace Sendov.PaperConsequences" + } + ] + }, + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "line": 202, + "declaration": "Gamma_lt_seven_eighteenths", + "qualified_declaration": "Sendov.PaperConsequences.Gamma_lt_seven_eighteenths", + "kind": "theorem", + "signature": "theorem Gamma_lt_seven_eighteenths (q : Multiset ℂ) {μ : ℂ} {a x : ℝ}\n (hm : 7 ≤ q.card) (ha : 0 < a) (ha1 : a < 1)\n (hmean : q.sum = q.card * μ) (hq : ∀ v ∈ q, ‖v‖ ≤ 1)\n (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hx : μ.re = x)\n (hr : PaperPolar.RawPolar q.card a x) :\n PaperCentered.Gamma (q.map (fun v => v - μ)) μ < 7 * (1 - a) / 18", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "noncomputable section" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 18, + "text": "open Polynomial Filter" + }, + { + "line": 19, + "text": "namespace Sendov.PaperConsequences" + } + ] + }, + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "line": 138, + "declaration": "centered_variance_le", + "qualified_declaration": "Sendov.PaperConsequences.centered_variance_le", + "kind": "theorem", + "signature": "theorem centered_variance_le (q : Multiset ℂ) (μ : ℂ) (hm : 0 < q.card)\n (hmean : q.sum = q.card * μ) (hq : ∀ v ∈ q, ‖v‖ ≤ 1) :\n PaperCentered.variance (q.map (fun v => v - μ)) ≤ 1 - ‖μ‖ ^ 2 ∧ ‖μ‖ ≤ 1", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "noncomputable section" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 18, + "text": "open Polynomial Filter" + }, + { + "line": 19, + "text": "namespace Sendov.PaperConsequences" + } + ] + }, + { + "path": "Sendov/Analytic/PaperMomentCorollaries.lean", + "qualified_declaration": "Sendov.PaperMomentCorollaries.EX02", + "kind": "theorem" + } + ], + "mapping_note": "Original mathematical recipe is now also an exported Lean contract; parent compilation and kernel receipt tag: final-corollaries.", + "corollary_recipe": "Retain the explicit majorant_Efin≤h/2 hypothesis. Add Gamma_lt_seven_eighteenths to obtain E_fin+Gamma0). norm_J_gt_one_of_majorant_half also exports the same conditional conclusion. No global proof of the majorant premise is claimed.", + "remaining_contract": null, + "compiled_corollary_exports": [ + { + "path": "Sendov/Analytic/PaperMomentCorollaries.lean", + "qualified_declaration": "Sendov.PaperMomentCorollaries.EX02", + "kind": "theorem" + } + ] + }, + { + "id": "EX03", + "claim": "Simple-root distance-product identity implies all-r>0 moment lower bounds; if ∏|a−z_j|≤m+1 then Σ|q_j|^r≥m", + "paper_sources": [ + "first-origin-uniform/round7/REPORT.md:161-169" + ], + "paper_evidence": "local_finite_proof_sketch", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "line": 97, + "declaration": "root_distance_product_identity", + "qualified_declaration": "Sendov.PaperConsequences.root_distance_product_identity", + "kind": "theorem", + "signature": "theorem root_distance_product_identity {m : ℕ} {p : ℂ[X]} {c a : ℂ}\n {q z : Multiset ℂ} (hc : c ≠ 0) (hq : ∀ v ∈ q, v ≠ 0)\n (hpz : p = C c * ((X - C a) * (z.map (fun w => X - C w)).prod))\n (hpq : derivative p = C (((m + 1 : ℕ) : ℂ) * c) *\n ((q.map (fun v => a - v⁻¹)).map (fun w => X - C w)).prod) :\n 0 < (z.map (fun w => ‖a - w‖)).prod ∧\n (q.map norm).prod = ((m : ℝ) + 1) / (z.map (fun w => ‖a - w‖)).prod", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "noncomputable section" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 18, + "text": "open Polynomial Filter" + }, + { + "line": 19, + "text": "namespace Sendov.PaperConsequences" + } + ] + }, + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "line": 123, + "declaration": "moment_ge_degree_of_root_distance_product", + "qualified_declaration": "Sendov.PaperConsequences.moment_ge_degree_of_root_distance_product", + "kind": "theorem", + "signature": "theorem moment_ge_degree_of_root_distance_product {m : ℕ} {p : ℂ[X]} {c a : ℂ}\n {q z : Multiset ℂ} (_hm : 1 ≤ m) (hqcard : q.card = m)\n (_hzcard : z.card = m) (hc : c ≠ 0) (hq : ∀ v ∈ q, v ≠ 0)\n (hpz : p = C c * ((X - C a) * (z.map (fun w => X - C w)).prod))\n (hpq : derivative p = C (((m + 1 : ℕ) : ℂ) * c) *\n ((q.map (fun v => a - v⁻¹)).map (fun w => X - C w)).prod)\n (hprod : (z.map (fun w => ‖a - w‖)).prod ≤ (m : ℝ) + 1)\n {r : ℝ} (hr : 0 < r) : (m : ℝ) ≤ (q.map (fun v => ‖v‖ ^ r)).sum", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "noncomputable section" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 18, + "text": "open Polynomial Filter" + }, + { + "line": 19, + "text": "namespace Sendov.PaperConsequences" + } + ] + } + ], + "mapping_note": "Exact polynomial/derivative factorizations tie q to inverse critical-root distances. The theorem derives positive root-distance product; retains q.card=z.card=m, nonzero leading coefficient/nonzero q, explicit product≤m+1 and arbitrary real r>0. No product hypothesis is silently inserted into D.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "AS01", + "claim": "Fixed m, h→0: R=1+m[(m−4)/6−k]h²+O_m(h³), polar root x*=1−(m−4)h/6+O_m(h²)", + "paper_sources": [ + "first-origin-uniform/REPORT.md:96-110" + ], + "paper_evidence": "asymptotic_calculation_not_full_proof", + "acceptance_scope": "explicit_disposition_required", + "previous_status": "asymptotic_proof_incomplete", + "current_status": "asymptotic_proof_incomplete", + "lean": [], + "mapping_note": "Second-order coefficient is given; full controlled remainder and degenerate root existence/uniqueness/asymptotic inversion are not supplied. No uniform-in-m conclusion; no Lean asymptotic theorem found.", + "corollary_recipe": null, + "remaining_contract": "For each fixed paper degree m, supply a controlled O_m(h³) remainder for the displayed R expansion, and prove existence/uniqueness of the relevant polar-root branch plus its x*=1−(m−4)h/6+O_m(h²) inversion. Alternatively explicitly relabel the displayed expansion/root assertion as heuristic, not a proved result.", + "disposition": "OPEN: incomplete heuristic calculation, not an obtained-local-proof unit. Explicit correction/reclassification or missing proof still required; this ledger does not perform a user-authorized paper correction." + }, + { + "id": "AS02", + "claim": "At (a,x)=(1,1), T=1/(m+1), ∂aT=0, ∂xT=−2/(m−2); along polar root B−T=[m/(m+1)−(m−4)/(3(m−2))]h+O_m(h²)", + "paper_sources": [ + "first-origin-uniform/REPORT.md:106-110" + ], + "paper_evidence": "asymptotic_calculation_not_full_proof", + "acceptance_scope": "explicit_disposition_required", + "previous_status": "asymptotic_proof_incomplete", + "current_status": "asymptotic_proof_incomplete", + "lean": [], + "mapping_note": "Derivative values and gap expansion asserted; differentiating the parameter integral, remainder control and root substitution are not fully proved in the report. Positive coefficient is elementary, but not an all-m finite proof.", + "corollary_recipe": null, + "remaining_contract": "Justify differentiation under the parameter integral at (a,x)=(1,1), establish the stated partial derivatives and a controlled O_m(h²) remainder along an actually proved polar-root branch, then prove the asserted gap expansion. Alternatively explicitly retain it only as heuristic calculation.", + "disposition": "OPEN: incomplete heuristic calculation, not an obtained-local-proof unit. Explicit correction/reclassification or missing proof still required; this ledger does not perform a user-authorized paper correction." + }, + { + "id": "AS03", + "claim": "Fixed m≥1, a→0: exact R_max formula tends to 1/(m+1)<1, so a neighborhood is polar infeasible", + "paper_sources": [ + "first-origin-uniform/REPORT.md:112-116" + ], + "paper_evidence": "complete_short_asymptotic_argument", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperSecant.lean", + "line": 42, + "declaration": "R_one", + "qualified_declaration": "Sendov.PaperSecant.R_one", + "kind": "theorem", + "signature": "theorem R_one {m : ℕ} {a : ℝ} (ha : 0 < a) (ha1 : a < 1) : R m a 1 = U1 m a", + "blob": "d5a1481b495db34a9a82222596a45f36bc7a77a0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperSecant" + }, + { + "line": 13, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperSecant.lean", + "line": 192, + "declaration": "R_mono", + "qualified_declaration": "Sendov.PaperSecant.R_mono", + "kind": "theorem", + "signature": "theorem R_mono {m : ℕ} {a x y : ℝ} (ha : 0 < a) (ha1 : a < 1)\n (hx0 : -1 ≤ x) (hx1 : x ≤ 1) (hxy : x ≤ y) : R m a x ≤ R m a y", + "blob": "d5a1481b495db34a9a82222596a45f36bc7a77a0", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 12, + "text": "namespace Sendov.PaperSecant" + }, + { + "line": 13, + "text": "open MeasureTheory" + } + ] + }, + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "line": 22, + "declaration": "U1_zero", + "qualified_declaration": "Sendov.PaperConsequences.U1_zero", + "kind": "theorem", + "signature": "theorem U1_zero (m : ℕ) : PaperSecant.U1 m 0 = 1 / ((m : ℝ) + 1)", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "noncomputable section" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 18, + "text": "open Polynomial Filter" + }, + { + "line": 19, + "text": "namespace Sendov.PaperConsequences" + } + ] + }, + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "line": 34, + "declaration": "tendsto_U1_zero_right", + "qualified_declaration": "Sendov.PaperConsequences.tendsto_U1_zero_right", + "kind": "theorem", + "signature": "theorem tendsto_U1_zero_right (m : ℕ) :\n Tendsto (PaperSecant.U1 m) (nhdsWithin 0 (Set.Ioi 0))\n (nhds (1 / ((m : ℝ) + 1)))", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "noncomputable section" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 18, + "text": "open Polynomial Filter" + }, + { + "line": 19, + "text": "namespace Sendov.PaperConsequences" + } + ] + }, + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "line": 39, + "declaration": "U1_limit_lt_one", + "qualified_declaration": "Sendov.PaperConsequences.U1_limit_lt_one", + "kind": "theorem", + "signature": "theorem U1_limit_lt_one {m : ℕ} (hm : 1 ≤ m) : 1 / ((m : ℝ) + 1) < 1", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "noncomputable section" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 18, + "text": "open Polynomial Filter" + }, + { + "line": 19, + "text": "namespace Sendov.PaperConsequences" + } + ] + }, + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "line": 44, + "declaration": "exists_small_radius_not_rawPolar", + "qualified_declaration": "Sendov.PaperConsequences.exists_small_radius_not_rawPolar", + "kind": "theorem", + "signature": "theorem exists_small_radius_not_rawPolar {m : ℕ} (hm : 1 ≤ m) :\n ∃ ε > (0 : ℝ), ∀ a : ℝ, 0 < a → a < ε →\n ∀ x : ℝ, -1 ≤ x → x ≤ 1 → ¬ PaperPolar.RawPolar m a x", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "noncomputable section" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 18, + "text": "open Polynomial Filter" + }, + { + "line": 19, + "text": "namespace Sendov.PaperConsequences" + } + ] + } + ], + "mapping_note": "Fixed natural m≥1 only. Exact Rmax=U1 formula, right limit 1/(m+1)<1, and one ε excludes every x∈[−1,1]. No uniform moving-degree exclusion.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "AS04", + "claim": "Fixed λ>0, m→∞ with a=1−λ/m: polar integral tends to Gλ(x), mT→1/x² and mB→1+λ", + "paper_sources": [ + "first-origin-uniform/REPORT.md:118-128" + ], + "paper_evidence": "limit_formulas_not_full_proof", + "acceptance_scope": "explicit_disposition_required", + "previous_status": "asymptotic_proof_incomplete", + "current_status": "asymptotic_proof_incomplete", + "lean": [], + "mapping_note": "Only limit formulas are stated; no full convergence proof or uniform domination for the scaled residual/endpoints. Finite Taylor/Laplace results elsewhere prove D without requiring these limits.", + "corollary_recipe": null, + "remaining_contract": "For each fixed λ>0 and the stated x domain (in particular x>0 for 1/x²), prove convergence of the rescaled finite polar integrals and mT, with appropriate domination/tail control, and mB→1+λ. AS05 is only the limiting-model inequality and does not establish these convergences. Alternatively explicitly classify the limiting formulas as heuristic.", + "disposition": "OPEN: incomplete heuristic calculation, not an obtained-local-proof unit. Explicit correction/reclassification or missing proof still required; this ledger does not perform a user-authorized paper correction." + }, + { + "id": "AS05", + "claim": "Whole limiting ray budget: Gλ(x)≥1 ⇒ 1−x≤λx²/6 ⇒ (1+λ)x²−1≥(1−x)(5−x), strictly positive for λ>0", + "paper_sources": [ + "first-origin-uniform/REPORT.md:118-128,239-243" + ], + "paper_evidence": "complete_limiting_model_argument", + "acceptance_scope": "required", + "previous_status": "derived_corollary", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperConsequences.lean", + "line": 244, + "declaration": "limiting_exponential_model", + "qualified_declaration": "Sendov.PaperConsequences.limiting_exponential_model", + "kind": "theorem", + "signature": "theorem limiting_exponential_model {ℓ x : ℝ} (hℓ : 0 < ℓ)\n (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hG : 1 ≤ ∫ t in (0 : ℝ)..1, Real.exp (ℓ * (2 * x * t - 1))) :\n 1 / 2 < x ∧ 1 - x ≤ ℓ * x ^ 2 / 6 ∧\n (1 - x) * (5 - x) ≤ (1 + ℓ) * x ^ 2 - 1 ∧\n 0 < (1 + ℓ) * x ^ 2 - 1", + "blob": "3fb1b509669f34cda7d037bcf28c883b29c90b8c", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 16, + "text": "noncomputable section" + }, + { + "line": 17, + "text": "open scoped BigOperators" + }, + { + "line": 18, + "text": "open Polynomial Filter" + }, + { + "line": 19, + "text": "namespace Sendov.PaperConsequences" + } + ] + } + ], + "mapping_note": "Entire feasible exponential model with λ>0 and x∈[−1,1]; theorem proves x>1/2, the quadratic inequality and strict limiting budget. Does not assert convergence AS04.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "DG01", + "claim": "Floating/high-precision screens, root finding and loss diagnostics suggest D but prove no continuous coverage", + "paper_sources": [ + "first-origin/REPORT.md:175,269", + "first-origin-uniform/REPORT.md:53-79", + "first-origin-uniform/round3/REPORT.md:168", + "first-origin-uniform/round4/REPORT.md:295-300", + "first-origin-uniform/round5/REPORT.md:7", + "first-origin-uniform/round6/REPORT.md:253-262", + "first-origin-uniform/round7/REPORT.md:197" + ], + "paper_evidence": "uncertified_numerical_diagnostics", + "acceptance_scope": "not_a_theorem", + "previous_status": "diagnostic_only", + "current_status": "diagnostic_only", + "lean": [], + "mapping_note": "Includes 80/424-point screens, 60/95-digit consistency, weak-ray versus true-root Taylor loss, secant scan counts. No exact mathematical acceptance obligation attaches to every sample or timing; failed floating polar point is separately DI08.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "OP01", + "claim": "Full D for every integer m≥7 and all 02/5, U1≥1, F_sec≤0, raw polar feasible. Do not require solving this new mathematics for all obtained proofs; do not retire old endgame.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "OP02", + "claim": "Global C-near m≥7,9/10≤a<1, full polar and pointwise ⇒ E_fin+Γ<1−a|μ|; stronger finite remainder target E_fin≤h/2", + "paper_sources": [ + "first-origin/REPORT.md:271-281", + "first-origin-uniform/round7/REPORT.md:125-129" + ], + "paper_evidence": "explicitly_unproved", + "acceptance_scope": "not_obtained", + "previous_status": "paper_open", + "current_status": "paper_open", + "lean": [], + "mapping_note": "Conditional C-budget is complete; its geometric antecedent is not established uniformly. Also no complete averaged-L² strengthening follows.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "OP03", + "claim": "F_sec positivity on the whole remaining domain", + "paper_sources": [ + "first-origin-uniform/round6/REPORT.md:118-133" + ], + "paper_evidence": "unproved_goal_with_counterexample_to_universal_variant", + "acceptance_scope": "not_obtained", + "previous_status": "paper_open", + "current_status": "paper_open", + "lean": [ + { + "path": "tests/PaperSecantTests.lean", + "line": 60, + "declaration": "gate_16_nine_tenths_negative", + "qualified_declaration": "Sendov.PaperSecant.Tests.gate_16_nine_tenths_negative", + "kind": "theorem", + "signature": "theorem gate_16_nine_tenths_negative : Fsec 16 (9 / 10) < 0", + "blob": "645c3392fe1a3b3d6ef1e58ecad7cbd379f40d8f", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 5, + "text": "namespace Sendov.PaperSecant.Tests" + }, + { + "line": 6, + "text": "open MeasureTheory" + } + ] + } + ], + "mapping_note": "The unconditional universal-positivity variant is actually refuted by a feasible negative gate; gate positivity is only sufficient. No requirement to prove a false statement.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "OP04", + "claim": "Arbitrary complex-collinear affine transport and general collinear equality classification", + "paper_sources": [ + "collinear/REPORT.round2.md:102-109", + "first-origin-uniform/round7/REPORT.md:141-151" + ], + "paper_evidence": "external_paper_blueprint_not_locally_audited", + "acceptance_scope": "external_scope_requires_explicit_decision", + "previous_status": "external_unadopted", + "current_status": "external_unadopted", + "lean": [], + "mapping_note": "Not locally completed or validated paper proofs; Zhang recovered note STATES and supplies proofs of these externally, so do not call them globally unknown. They remain separate formalization scope only if user includes every downloaded third-party paper. Boundary equality BO03 is already complete.", + "corollary_recipe": null, + "remaining_contract": null, + "disposition": "NOT ADOPTED: external-paper material is outside the unchanged obtained-local-proof scope. No claim that the external results are globally unknown or false; expansion would require explicit authorization." + }, + { + "id": "OP05", + "claim": "Tao averaged-L² working proof, Zhang explicit huge quadratic threshold, n≥100 suggestion, spectral/interpolation comments", + "paper_sources": [ + "first-origin-uniform/round7/REPORT.md:98-113,183,217" + ], + "paper_evidence": "external_claims_and_conjectural_suggestions", + "acceptance_scope": "external_scope_requires_explicit_decision", + "previous_status": "external_unadopted", + "current_status": "external_unadopted", + "lean": [], + "mapping_note": "Working notes flag independent checks; report explicitly does not certify all external mathematical correctness. n≥100 is a suggestion, not proved threshold. Huge explicit threshold is a different averaged-L² theorem, not the local D cutoff.", + "corollary_recipe": null, + "remaining_contract": null, + "disposition": "NOT ADOPTED: external-paper material is outside the unchanged obtained-local-proof scope. No claim that the external results are globally unknown or false; expansion would require explicit authorization." + }, + { + "id": "HI01", + "claim": "m≥100000, 1/50≤λ≤400: mx²T<1.0022", + "paper_sources": [ + "first-origin-uniform/REPORT.md:301-350" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperWideRays.lean", + "line": 141, + "declaration": "HI01", + "qualified_declaration": "Sendov.PaperWideRays.HI01", + "kind": "theorem", + "signature": "theorem HI01 {m : ℕ} {a x : ℝ} (hm : 100000 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hr : RawPolar m a x) (_hl0 : 1 / 50 ≤ lambda m a) (hl1 : lambda m a ≤ 400) :\n (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 5011 / 5000", + "blob": "835e17361dfc34773628df7156e33d1dfa09fa53", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 19, + "text": "namespace Sendov.PaperWideRays" + }, + { + "line": 21, + "text": "open PaperPolar" + } + ] + } + ], + "mapping_note": "Exact degree, entire λ≤400 band, and quantitative normalized T bound. For HI01, 5011/5000 is exactly 1.0022.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "HI02", + "claim": "m≥10000, 1/10≤λ≤400: mx²T<1+46/m", + "paper_sources": [ + "first-origin-uniform/round3/REPORT.md:59-108" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperWideRays.lean", + "line": 153, + "declaration": "HI02", + "qualified_declaration": "Sendov.PaperWideRays.HI02", + "kind": "theorem", + "signature": "theorem HI02 {m : ℕ} {a x : ℝ} (hm : 10000 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hr : RawPolar m a x) (_hl0 : 1 / 10 ≤ lambda m a) (hl1 : lambda m a ≤ 400) :\n (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 1 + 46 / (m : ℝ)", + "blob": "835e17361dfc34773628df7156e33d1dfa09fa53", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 19, + "text": "namespace Sendov.PaperWideRays" + }, + { + "line": 21, + "text": "open PaperPolar" + } + ] + } + ], + "mapping_note": "Exact degree, entire λ≤400 band, and quantitative normalized T bound. For HI01, 5011/5000 is exactly 1.0022.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "HI03", + "claim": "m≥512, 5≤λ≤64: mx²T<1+53/m+1/32; earlier small-ray bounds on [1/10,1] and [1,5]", + "paper_sources": [ + "first-origin-uniform/round4/REPORT.md:192-230" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "partial", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperWideRays.lean", + "line": 160, + "declaration": "HI03", + "qualified_declaration": "Sendov.PaperWideRays.HI03", + "kind": "theorem", + "signature": "theorem HI03 {m : ℕ} {a x : ℝ} (hm : 512 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hr : RawPolar m a x) (_hl0 : 5 ≤ lambda m a) (hl1 : lambda m a ≤ 64) :\n (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 1 + 53 / (m : ℝ) + 1 / 32", + "blob": "835e17361dfc34773628df7156e33d1dfa09fa53", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 19, + "text": "namespace Sendov.PaperWideRays" + }, + { + "line": 21, + "text": "open PaperPolar" + } + ] + }, + { + "path": "Sendov/Analytic/PaperWideRays.lean", + "line": 181, + "declaration": "HI03_small_one", + "qualified_declaration": "Sendov.PaperWideRays.HI03_small_one", + "kind": "theorem", + "signature": "theorem HI03_small_one {m : ℕ} {a x : ℝ} (hm : 512 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hr : RawPolar m a x) (_hl0 : 1 / 10 ≤ lambda m a) (hl1 : lambda m a ≤ 1) :\n (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 1 + 18 / (m : ℝ)", + "blob": "835e17361dfc34773628df7156e33d1dfa09fa53", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 19, + "text": "namespace Sendov.PaperWideRays" + }, + { + "line": 21, + "text": "open PaperPolar" + } + ] + }, + { + "path": "Sendov/Analytic/PaperWideRays.lean", + "line": 195, + "declaration": "HI03_small_five", + "qualified_declaration": "Sendov.PaperWideRays.HI03_small_five", + "kind": "theorem", + "signature": "theorem HI03_small_five {m : ℕ} {a x : ℝ} (hm : 512 ≤ m)\n (ha : 0 < a) (ha1 : a < 1) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hr : RawPolar m a x) (_hl0 : 1 ≤ lambda m a) (hl1 : lambda m a ≤ 5) :\n (m : ℝ) * x ^ 2 * PaperTaylor.budget m a x < 1 + 34 / (m : ℝ)", + "blob": "835e17361dfc34773628df7156e33d1dfa09fa53", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 19, + "text": "namespace Sendov.PaperWideRays" + }, + { + "line": 21, + "text": "open PaperPolar" + } + ] + } + ], + "mapping_note": "All three original bands are covered at m≥512, including λ up to 64, tail 1/32, and the 18/m and 34/m small-ray terms.", + "corollary_recipe": null, + "remaining_contract": null + }, + { + "id": "HI04", + "claim": "Small-a quantitative ratios: m≥100000,a≤1/2 gives T/h<83567/100000; m≥10000,a≤1/2,ma²h<116 gives T/h<106/125", + "paper_sources": [ + "first-origin-uniform/REPORT.md:214-229", + "first-origin-uniform/round3/REPORT.md:129-149" + ], + "paper_evidence": "complete_local_proof", + "acceptance_scope": "required", + "previous_status": "missing", + "current_status": "theorem", + "lean": [ + { + "path": "Sendov/Analytic/PaperRateDetails.lean", + "line": 60, + "declaration": "small_a_ratio_100000", + "qualified_declaration": "Sendov.PaperRateDetails.small_a_ratio_100000", + "kind": "theorem", + "signature": "theorem small_a_ratio_100000 {m : ℕ} {a x : ℝ} (hm : 100000 ≤ m)\n (ha : 0 < a) (ha2 : a ≤ 1 / 2) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hr : RawPolar m a x) :\n PaperTaylor.budget m a x / (1 - a) < 83567 / 100000", + "blob": "80654d487a115521c5bf6bdb793ce5e5678c1575", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 13, + "text": "namespace Sendov.PaperRateDetails" + }, + { + "line": 15, + "text": "open PaperPolar" + } + ] + }, + { + "path": "Sendov/Analytic/PaperRateDetails.lean", + "line": 81, + "declaration": "small_a_ratio_10000", + "qualified_declaration": "Sendov.PaperRateDetails.small_a_ratio_10000", + "kind": "theorem", + "signature": "theorem small_a_ratio_10000 {m : ℕ} {a x : ℝ} (hm : 10000 ≤ m)\n (ha : 0 < a) (ha2 : a ≤ 1 / 2) (hx0 : -1 ≤ x) (hx1 : x ≤ 1)\n (hr : RawPolar m a x) (hbulk : (m : ℝ) * a ^ 2 * (1 - a) < 116) :\n PaperTaylor.budget m a x / (1 - a) < 106 / 125", + "blob": "80654d487a115521c5bf6bdb793ce5e5678c1575", + "tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "source_context": [ + { + "line": 13, + "text": "namespace Sendov.PaperRateDetails" + }, + { + "line": 15, + "text": "open PaperPolar" + } + ] + } + ], + "mapping_note": "Both original small-a ratios, exact thresholds and domains; the second retains the bulk-complement hypothesis.", + "corollary_recipe": null, + "remaining_contract": null + } + ], + "corollary_extension": { + "base_review_tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d", + "families": 21, + "receipt_tag": "final-corollaries", + "source_changed_since_review": "Only additive exported corollary modules; earlier source contracts unchanged." + }, + "accepted_source_commit": "8e1b056a241e6a99af2e2029569dc92a334c1a6d", + "base_audit_counts": { + "normalized_units": 101, + "required": 92, + "mapped_required": 92, + "required_theorem": 92, + "required_derived_corollary": 0, + "required_remaining_gaps": 0, + "by_status": { + "asymptotic_proof_incomplete": 3, + "derived_corollary": 0, + "diagnostic_only": 1, + "external_unadopted": 2, + "paper_open": 3, + "theorem": 92 + }, + "by_scope": { + "explicit_disposition_required": 3, + "external_scope_requires_explicit_decision": 2, + "not_a_theorem": 1, + "not_obtained": 3, + "required": 92 + }, + "distinct_qualified_references": 215, + "distinct_named_theorems_or_lemmas": 214, + "distinct_anonymous_examples": 12, + "source_manifest_files": 45, + "local_proof_import_closure_files": 97, + "definitions_recorded": 47, + "report_hashes_matched": 14, + "accepted_named_axiom_roots": 243 + }, + "base_audit_method": { + "source": "All repository source bytes read with git show 1b08ca1ec9c505dbecffb6341b62dfde2fb5634d:path; namespace/declaration census and exact source signatures checked against the immutable tree, never the mutable index/worktree. Git blob and SHA256 hashes recorded. This is contract reconciliation, not Lean elaboration or a fresh kernel replay.", + "signature_format": "Literal source theorem/lemma signatures (comments stripped), with preceding file namespace/open/variable context. These are not manufactured #check outputs. Anonymous examples are pinned by file, blob and exact start line. Definitions are evidence, not counted as named theorems.", + "enumeration": "Python checked unique claim IDs and whitespace-normalized statements, equality of the inherited required-ID set, per-unit reference deduplication, every qualified reference against its source namespace/declaration, and exact object hashes. No unit was removed or moved out of the required scope.", + "corollaries": "Each derived_corollary has a concrete parameter/lemma/algebra recipe. A recipe is a mathematical mapping, not a claim that an independent Lean wrapper was compiled.", + "scope": "The inherited 101 normalized units and 92 obtained-local-proof units are unchanged. Families are the inherited granularity, not 92 atomic Lean declarations.", + "writes": "Only final-acceptance-map.json and final-acceptance-map.md. No source, build, cache, index or remote writes performed by audit commands; tool-managed runtime storage is outside the artifact.", + "reports": [ + { + "path": "first-origin/REPORT.md", + "sha256": "c496193dd6061ee359e3c285f60e67043c345baf0cf870755eaff10cbe2deec1", + "matches_prior_inventory": true, + "lines": 338 + }, + { + "path": "first-origin-uniform/REPORT.md", + "sha256": "1322c08c7faffe80cbece6f779ee811c76a2c97ede309412e572e3c75aaa5c35", + "matches_prior_inventory": true, + "lines": 428 + }, + { + "path": "first-origin-uniform/legacy_RESULT.md", + "sha256": "c7c32918bd720fcc5dd663317c6101e2c6205ef622224a1339ed92d8ad4c1de9", + "matches_prior_inventory": true, + "lines": 41 + }, + { + "path": "first-origin-uniform/round3/REPORT.md", + "sha256": "02c4e837bfa78d90f087ee763585dc892feb9230a203b705ce44dc80691ab1f1", + "matches_prior_inventory": true, + "lines": 175 + }, + { + "path": "first-origin-uniform/round4/REPORT.md", + "sha256": "7e7fcc67a70d341cc6565068b6991fa5e98f243d3c9e66343e5793d389acbca6", + "matches_prior_inventory": true, + "lines": 315 + }, + { + "path": "first-origin-uniform/round5/REPORT.md", + "sha256": "a3ca71ea692714537178baeae74e51b8a2b771b7b248c4c9f820dd5eb7a9715a", + "matches_prior_inventory": true, + "lines": 305 + }, + { + "path": "first-origin-uniform/round6/REPORT.md", + "sha256": "12773b57d018ce1a97a9c6d47f5e341271c0fa3493685dca79dfd62a8d3b5ee2", + "matches_prior_inventory": true, + "lines": 269 + }, + { + "path": "first-origin-uniform/round7/REPORT.md", + "sha256": "b699d4abca1e797e7b9df9b78b41e1cc9ef3b697f70ebba940a7784f19fae657", + "matches_prior_inventory": true, + "lines": 233 + }, + { + "path": "first-origin-uniform/round7/MATH_NOTE.md", + "sha256": "b5c74370eaf11abcfd37bb646069c188075299b623fa12fb805de5ee84febece", + "matches_prior_inventory": true, + "lines": 126 + }, + { + "path": "boundary-refine/REPORT.md", + "sha256": "a88d44b9fb995bdbd93dfd0319ba9377b9786c2ec42ff7bbfa518e09ea3c3a54", + "matches_prior_inventory": true, + "lines": 178 + }, + { + "path": "collinear/REPORT.round2.md", + "sha256": "2584bcab4948feb9e69318cde0ecc2146b820557f34cb002a6c4f8aeabc4f090", + "matches_prior_inventory": true, + "lines": 109 + }, + { + "path": "first-origin-lean/REPORT.md", + "sha256": "ae718eea5255c8547898965b47acde4d6039bc9fd75da58559c23263726029de", + "matches_prior_inventory": true, + "lines": 98 + }, + { + "path": "boundary/REPORT.md", + "sha256": "8018e3fdb1bae1f0651c88aa53cb9a509b19cb9802a52229469587818c373834", + "matches_prior_inventory": true, + "lines": 128 + }, + { + "path": "collinear/REPORT.md", + "sha256": "6a31a5cf1ea86504a671490a8eb362d445748616cb3df56001d16aad9b196148", + "matches_prior_inventory": true, + "lines": 96 + } + ] + }, + "base_audit_tree": "1b08ca1ec9c505dbecffb6341b62dfde2fb5634d" +} \ No newline at end of file diff --git a/docs/paper-formalization/METRICS.json b/docs/paper-formalization/METRICS.json new file mode 100644 index 0000000..b4cfe17 --- /dev/null +++ b/docs/paper-formalization/METRICS.json @@ -0,0 +1,105 @@ +{ + "source_commit": "8e1b056a241e6a99af2e2029569dc92a334c1a6d", + "baseline_commit": "0a4e966c41e1287f92d305d3bad8e70c8c295dde", + "baseline": { + "production": { + "files": 49, + "lines": 8350, + "bytes": 388596 + }, + "tests_and_audits": { + "files": 13, + "lines": 1222, + "bytes": 55503 + } + }, + "candidate": { + "production": { + "files": 88, + "lines": 16237, + "bytes": 815037 + }, + "tests_and_audits": { + "files": 60, + "lines": 10818, + "bytes": 697910 + } + }, + "delta": { + "production": { + "files": 39, + "lines": 7887, + "bytes": 426441 + }, + "tests_and_audits": { + "files": 47, + "lines": 9596, + "bytes": 642407 + } + }, + "cached_import_timings": { + "baseline": { + "Sendov.Interior": { + "seconds": [ + 3.4430825840099715, + 3.4967094399617054, + 3.608164331992157 + ], + "median_seconds": 3.4967094399617054 + }, + "Sendov.Conjecture": { + "seconds": [ + 3.5816891019931063, + 3.661514418956358, + 3.740386394027155 + ], + "median_seconds": 3.661514418956358 + }, + "Solution": { + "seconds": [ + 2.849442850041669, + 2.8681032629683614, + 2.854003844957333 + ], + "median_seconds": 2.854003844957333 + } + }, + "candidate": { + "Sendov.Interior": { + "seconds": [ + 7.3726481680059806, + 7.41232837602729, + 7.326444656995591 + ], + "median_seconds": 7.3726481680059806 + }, + "Sendov.Conjecture": { + "seconds": [ + 3.703548660967499, + 3.695611385977827, + 3.551374059985392 + ], + "median_seconds": 3.695611385977827 + }, + "Solution": { + "seconds": [ + 2.8146336569916457, + 2.881257256027311, + 2.7444792250171304 + ], + "median_seconds": 2.8146336569916457 + } + }, + "scope": "Three cached-import elaborations per module, sequential on shared host; not whole-DAG builds or controlled performance experiment. No speedup claim." + }, + "affected_primary_olean": { + "files": 97, + "bytes": 190024872, + "MiB": 181.22183990478516, + "note": "Only primary .olean for 97 acceptance modules; excludes dependency packages and .ilean/auxiliary files." + }, + "successful_gate_seconds": { + "elaboration": 873.4082650328637, + "kernel_replay": 562.3478519659839 + } +} \ No newline at end of file diff --git a/docs/paper-formalization/REPORT.md b/docs/paper-formalization/REPORT.md new file mode 100644 index 0000000..821358c --- /dev/null +++ b/docs/paper-formalization/REPORT.md @@ -0,0 +1,116 @@ +# 纸面成果形式化:最终报告 + +## 交付结论 + +**已完成此前取得完整本地证明的全部 92 项结果族的 Lean 形式化及验收。** +这些结果族来自 14 份本地报告/笔记;一个结果族可以包含成对不等式或有限实例, +并非声称只有 92 条原子定理。原来仅有数学组合说明的 21 项,也已补成实际 +导出的 Lean 定理,不再以文字推论代替形式化。 + +- 本地分支:`formalize/paper-results-20260914` +- 工作树:`/home/v-zhouziyu/work/sendov-paper-formalization-20260914` +- 已验收 Lean 源码提交:`8e1b056a241e6a99af2e2029569dc92a334c1a6d` +- 原基线:`0a4e966c41e1287f92d305d3bad8e70c8c295dde` +- 未推送远程,未改原 BASE 工作树。 + +## 数学与生产接线 + +### 统一直接预算 D + +`Sendov.PaperUniform.uniform_D` 对所有自然数 **m≥256**、全部 **0(1-a)/1000**。 +旧的 h/3、h/5、h/80 余量、m≥512 时 T<3/5、较宽射线上的更强收敛率, +均独立保留。旧大次数 cutoff 也有明确形式化推论。 + +两条新路线已经由 `Interior → Conjecture → Solution` 真正消费: +- n=6、7:小次数 first-origin 路线及定量 J 范数余量; +- n≥257:全部半径使用 polar + first-origin; +- 8≤n≤256 的近端点区域:使用统一近端点 first-origin 路线。 + +独立证明值依赖检查确认新分支不消费 polynomial centroid identity、 +second-origin 或旧不相容性定理。全局 Solution 仍有旧分支用于其余有限区域; +不能据此删除旧 endgame。两个最终公开定理的严格性、等号分类和假设不变。 + +### 其余取得成果 + +- 平均二次矩边界刚性,已接入 Rubinstein 与两个公开结论。 +- 实根分裂多项式的带重数临界点结构、倒数平衡及所有实指数 r≥1 的直径矩界。 +- 实际积分的有限 Taylor、两端估计、sharp Laplace、全域 polar 端点/log 界。 +- 曲率修正 secant 及不含积分的充分 gate;未声称 gate 处处为正。 +- 保留全部有限 H 端点的复数 centered 展开、优化系数界、完整 majorant C-budget。 +- 所有保留的认证实例:m=100 centered 误差、五组共轭族、浮点伪反例的精确排除、 + 旧 3h/5 余量、两个 secant 连续邻域及完整复 polar 非空见证、两个域反例。 +- 21 项补充推论的公开接口,包括完整复 polar hierarchy、实际均值/方差链、 + 原始所有射线边界与准确常数。 + +## 验收证据 + +`VERIFICATION.json` 与 `receipts.json` 记录真实执行: + +- **97 个受影响模块完成编译**; +- **96 次独立 Lean kernel 重放通过**; +- 合计 **193 项检查,零失败**; +- `Sendov` 是纯 import 汇总文件,没有本地声明:已编译,其声明所在模块逐个重放。 + 不将这记作一次虚构 kernel 成功,也不通过命名空间前缀重复重放整个库。 +- 总验收入口 `tests/PaperAcceptance.lean` 核对 **243 个命名审计根**; + 传递公理均限于 `propext`、`Classical.choice`、`Quot.sound`。 +- 10 个边界/最终契约与冻结基线的完整类型和 universe 记录一致。 +- 两个标准库生成器均实际重放;8 个输出逐字节不变。生成器只是见证产生器, + 数学正确性由相应 Lean 证明而非 Python 返回值保证。 + +成功编译/kernel 检查的记录用时合计约 **23.93 分钟**,不包含研究时间、 +外层工具超时以及主动取消的重复命名空间重放。它不是整个任务的墙钟耗时。 +本验收复用同一固定工具链的已验收依赖缓存;没有宣称重编或从空环境重放整个 Mathlib。 + +独立语义审阅分别检查了完整 D 与最终接线、精确实例的定义绑定、全部纸面清单。 +来源审阅和父代理编译/kernel 证据在账本中分开记录。 + +## 实际效果与成本 + +相对基线,生产 Lean 从 **8,350 行增至 16,237 行**,净增 **7,887 行**; +测试/审计从 **1,222 行增至 10,818 行**,净增 **9,596 行**。 +边界生产文件仍保留此前 **306→292 行**的局部缩短。 + +97 个验收模块的主 `.olean` 合计约 **181.22 MiB**,不包括 Mathlib 等依赖、 +`.ilean` 或辅助文件。源码及对象计量见 `METRICS.json`。 + +缓存依赖下每模块重复三次的编译中位数: +- Interior:基线 **3.50 秒**,候选 **7.37 秒**; +- Conjecture:**3.66 秒 → 3.70 秒**; +- Solution:**2.85 秒 → 2.81 秒**。 + +这是共享主机上的有限测量,不是控制负载后的基准,也不是全 DAG 编译时间。 +**当前收益是形式化覆盖、定量结论和可复用接口增强,不是全库压缩或加速。** +旧全域路线尚有消费者,新旧证明并存带来真实成本;未把新增行数或编译通过包装成优化。 + +## 明确未声称的事项 + +`SCOPE.md` 给出完整边界与对旧证据标签的纠正: +- 全部 m≥7、所有半径的 D 仍未在这项研究中证明;有限剩余域仍由旧路线覆盖。 +- 全域 C-near 的几何前提尚不能推出其预算;这里只形式化已经取得的条件定理。 +- AS01、AS02、AS04 三组旧渐近展开/收敛计算没有完整余项、根反演或收敛证明, + 明确保留为待证诊断,不算入 92 项已得证明。 +- 不把全部下载的第三方论文、复共线搬运及一般共线等号分类算作已完成本地成果。 + +## 重放 + +当前机器已准备好固定环境与私有对象目录。完整串行重放: + +```sh +python3 scripts/verify_paper_results.py \ + --config /home/v-zhouziyu/work/sendov-research-20260914-research/environment/config.json \ + --tag replay-new +``` + +中断后使用同一 tag 加 `--resume`;已记录成功且源码/配置未变的检查不重跑。 +环境 JSON 指定固定 Lean、package cache 与项目 options。移到另一台机器时须提供 +该机器相同工具链/依赖的环境配置,并准备私有项目对象;脚本不下载依赖或修改共享缓存。 +生成见证可运行 `scripts/generate_centered_hundred.py` 与 +`tests/generate_conjugate_budgets.py`。 + +入口索引:`ACCEPTANCE.json`、`SCOPE.md`、`VERIFICATION.json`、`METRICS.json`、 +`receipts.json`、`axioms.json`、`modules.json`。 diff --git a/docs/paper-formalization/RESULT.json b/docs/paper-formalization/RESULT.json new file mode 100644 index 0000000..0388596 --- /dev/null +++ b/docs/paper-formalization/RESULT.json @@ -0,0 +1,27 @@ +{ + "status": "PASS", + "modules": 97, + "compile_gates": 97, + "kernel_gates": 96, + "total_gates": 193, + "seconds_sum": 1435.7561169988476, + "axiom_roots": 243, + "allowed_axioms": [ + "propext", + "Classical.choice", + "Quot.sound" + ], + "exact_baseline_contracts": 10, + "import_only_umbrella": "Sendov: compiled; no local declarations, no redundant namespace-prefix replay", + "baseline": "0a4e966c41e1287f92d305d3bad8e70c8c295dde", + "source_commit": "8e1b056a241e6a99af2e2029569dc92a334c1a6d", + "result_families": 92, + "branch": "formalize/paper-results-20260914", + "remote_modified": false, + "all_m_ge_7_D_proved": false, + "asymptotic_dispositions": [ + "AS01", + "AS02", + "AS04" + ] +} \ No newline at end of file diff --git a/docs/paper-formalization/RESULT.md b/docs/paper-formalization/RESULT.md new file mode 100644 index 0000000..cb8b2c1 --- /dev/null +++ b/docs/paper-formalization/RESULT.md @@ -0,0 +1,15 @@ +# 结果:PASS + +此前取得完整本地证明的 **92/92 项结果族**已形式化,包括21项原推论接口。 + +- 97个模块编译、96次独立kernel重放,193项检查全部通过。 +- 243个命名根仅依赖标准三公理;10个基线公开/边界契约保持不变。 +- 全m≥256、全a的D与统一近端点D已接入两个公开定理。 +- 历史强估计、完整centered预算及精确实例全部保留。 +- 本地源码提交:`8e1b056a241e6a99af2e2029569dc92a334c1a6d`;未推远程。 + +**不是全m≥7的D新证明,不是全库压缩或编译加速。** +三组原先没有完整证明的渐近计算已明确降为待证诊断;第三方全文不在本地已得证明范围。 + +详细交付、证据、成本与重放见 [REPORT.md](REPORT.md)、[SCOPE.md](SCOPE.md)、 +[ACCEPTANCE.json](ACCEPTANCE.json) 和 [VERIFICATION.json](VERIFICATION.json)。 diff --git a/docs/paper-formalization/SCOPE.md b/docs/paper-formalization/SCOPE.md new file mode 100644 index 0000000..5523198 --- /dev/null +++ b/docs/paper-formalization/SCOPE.md @@ -0,0 +1,72 @@ +# Formalization scope and mathematical status + +## Obtained local results + +The acceptance inventory contains 92 normalized result families from 14 local +reports/notes. A family may contain several paired inequalities or a finite +list of certified examples; **92 is not a count of atomic propositions**. +Repeated historical cutoffs are identified rather than counted as new proof +methods. Every obtained family is mapped in `ACCEPTANCE.json`. + +The final three corollary modules turn the previously prose-only composition +recipes into public Lean contracts: + +- `PaperOriginCorollaries`: actual derivative/residual and full polar hierarchy. +- `PaperMomentCorollaries`: exact finite moments, deficits and polar consequences. +- `PaperRegionCorollaries`: historical cutoffs, margins and all original ray bands. + +The main accepted mathematical result is `Sendov.PaperUniform.uniform_D`: +all natural m≥256, all 0(1-a)/1000. Stronger +historical quantitative margins and estimates are separately retained. + +## Explicit correction of asymptotic evidence labels + +Three groups of formulas in the exploratory reports were not supplied with +complete mathematical proofs. They are **not obtained theorems**, and are not +part of the 92 proved families: + +- **AS01:** fixed-m expansion of the polar integral/root as a→1. The report + computes coefficients but does not prove the required remainder bound and + degenerate-root inversion/existence statement. +- **AS02:** parameter derivatives of T at the boundary and the gap expansion + along the polar root. Parameter differentiation, remainder control and root + substitution were not fully justified in the report. +- **AS04:** fixed-scale m→∞ convergence of the polar integral, mT and mB. + The report states limits without a full domination/scaled-tail convergence + proof. The finite Laplace estimates do not by themselves constitute that proof. + +These remain heuristic/diagnostic calculations needing proof. No Lean theorem, +uniform limit, or O-term estimate is claimed for them. By contrast AS03 +(fixed-degree small-a exclusion) and AS05 (the entire limiting-model inequality, +without asserting convergence to that model) have actual formal contracts. + +## Open research, not missing formalization of obtained proofs + +- Uniform D for the residual domain 7≤m<256, m(1-a)>2/5 beyond the sufficient + secant gate remains open in this work. No general m≥7 all-a theorem is claimed. +- The centered finite expansion and conditional majorant C-budget are proved; + the geometric hypotheses do not yet force that budget throughout C-near. +- Universal positivity of Fsec is not asserted. A feasible negative gate is + formally exhibited; its failure is not a counterexample to D. +- Complex-collinear affine transport and general collinear equality were not + locally completed. The recovered third-party papers supply separate blueprints; + they are not being called globally unknown, nor silently adopted as checked. +- Tao's external averaged-L2 working proof and the entirety of downloaded PDFs + are outside this local obtained-results inventory. This deliverable does not + claim to formalize every theorem in those documents. + +The existing full-domain endgame remains in the public proof for the remaining +finite-degree/radius region. It cannot be deleted on the strength of the new +partial-domain route. The two public mathematical statements and their strict +or extremal alternatives are unchanged. + +## Evidence levels + +Source-contract review, Lean elaboration, independent Lean kernel replay, and +Python witness generation are separate evidence. Python generators are +untrusted convenience tools; exact emitted arithmetic and its binding to the +actual complex families/integrals are proved by Lean. Uncertified floating-point +screens and timing displays do not become theorems. diff --git a/docs/paper-formalization/STATUS.md b/docs/paper-formalization/STATUS.md index 384f806..d1db978 100644 --- a/docs/paper-formalization/STATUS.md +++ b/docs/paper-formalization/STATUS.md @@ -1,106 +1,14 @@ -# Paper formalization acceptance ledger +# Paper formalization — COMPLETE -Baseline: `0a4e966c41e1287f92d305d3bad8e70c8c295dde`. -Integration branch: `formalize/paper-results-20260914`. -Status: **IN PROGRESS**, not complete and not a uniform D proof. +The obtained-local-proof acceptance scope is complete: **92/92 result families**. +All 21 former corollary recipes now have exported Lean contracts. -## Checkpoint 2 — actual near-endpoint D, now wired into Solution +- [REPORT.md](REPORT.md): final deliverable, actual effects and replay instructions. +- [RESULT.json](RESULT.json): completion and verification counts. +- [ACCEPTANCE.json](ACCEPTANCE.json): full paper-to-Lean inventory. +- [SCOPE.md](SCOPE.md): explicit unproved/asymptotic/external boundaries. +- [VERIFICATION.json](VERIFICATION.json): 97 compilations + 96 kernel checks. +- [METRICS.json](METRICS.json): code/object costs and limited timing measurements. -`PaperNearClosure.near_endpoint_D` proves the actual raw-polar integral -implication for every natural m≥7 and m(1-a)≤2/5, with strict gap >h/1000. -The two-endpoint integral bounds, sharp Laplace estimate, curvature secant -and its sufficient D gate, finite complex centered expansion, and optimized -coefficient bounds have also been integrated and freshly checked (24 gates). -The centered actual-coefficient budget and independent optimized coefficient -bound still need their common majorant interface; this is in the next batch. - -`FirstOriginBudget.lower_budget` connects the scalar integral to actual Fprod. -`Interior` now branches into the new near-endpoint contradiction before -constructing the polynomial centroid and second-origin identities. Both -public Solution proof-value closures contain `near_endpoint_D`; the standalone -near contradiction's closure excludes all old centroid/second-origin/endgame -entries. Exact final sources passed the `near-wiring-clean` gates. The original -remaining-domain proof is retained; no all-a m≥256 Lean claim is made yet. - -Next dispatched items: global polar endpoint/log bounds, quantitative tails, -ray geometry, centered majorant assembly, older stronger near margins, exact -full-complex-polar diagnostic, and independent semantic review of checkpoint2. - -## Checkpoint 1 — integrated and freshly rechecked - -Boundary rigidity and first-origin n=6/n=7 are now actual consumers of both -public Solution theorem proofs. The real-collinear moment theorem is exported -independently; it is not a proof dependency of the general complex theorem. -`PaperPolar`, `PaperTaylor`, and `PaperNearAlgebra` are now integrated, with -actual raw-integral domination, actual integral Taylor budget, and the full -rational near-endpoint rectangle respectively. Parent replay passed 60 gates -(34 elaborations, 26 independent kernel checks); the prior bulk module gates -are separate. Ten boundary/final theorem contracts match baseline exactly. -Near-endpoint D still requires endpoint decay and parameter assembly. - -The initial task allocation below is retained as the acceptance inventory; -worker assignments marked there refer to the completed first dispatch, not -claims that all enclosing targets are finished. - -## Acceptance units - -- Existing boundary average-square rigidity: re-integrate refined production - source and verify Solution/Conjecture consumers. Worker `existing`. -- Existing first-origin m=5,6: integrate production namespace and verify - complete polar/first-origin contradiction, not only scalar lemmas. Worker `existing`. -- Existing real-split collinear reciprocal/moment results: integrate and verify; - complex affine transport and general equality classification remain distinct - unfinished mathematics, not previously completed formalizations. Worker `existing`. -- Raw polar geometry and stronger `b ≤ α/(3+α) ≤ λ/(3+λ)`: worker `polar`. -- Finite Taylor integral budget (T): worker `taylor`. -- Latest near-endpoint rational algebra: worker `near`; full near-endpoint - result additionally needs Taylor, parameter conversions and integer endpoint - decay. Do not count algebra alone as raw-polar D. -- Latest near-endpoint `m≥7, m(1-a)≤2/5`, gap `>(1-a)/1000`: pending assembly. -- Old narrower near-endpoint **stronger margins**: pending preservation. - Round3 `λ≤1/10` gap `>h/5`; round5 `λ≤1/5` gap `>h/80`. - Weaker old cutoffs can be corollaries; stronger margins cannot be discarded. -- Two-endpoint quadratic integral estimates, polar endpoint/log lower bounds, - sharp Laplace estimate (S), finite-ray quantitative tails: pending. -- Round5 full `m≥256` all-a theorem: pending the above analytic inputs and - finite-ray comparisons. The all-a theorem is NOT currently formalized. -- Round4 stronger bound `T<3/5` for m≥512: preserve separately; does not follow - merely from the weaker round5 bound `T<2/3`. -- Curvature-corrected polar secant and rational sufficient gate F_sec: pending. - Universal positivity of F_sec was never proved and is not an acceptance claim. -- Finite centered expansion including H terms, coefficient estimate from finite - Fourier/AM-GM, C-budget: pending. Universal C-near was never proved. -- Exact full-polar mean-half counterexample: pending Lean translation; it is - NOT a D or Sendov counterexample. -- Rational diagnostic certificates: keep distinct from universal proofs; - scoped certified intervals are eligible theorems, floating grids are not. - -## Accepted first independent module - -`Sendov/Analytic/PaperBulkAlgebra.lean` contains: - -- `Sendov.PaperBulk.middle_cubic_pos`: an explicit positive decomposition, - avoiding differentiation/concavity infrastructure for the middle interval. -- `middle_budget`: for real m≥256 and 1/3≤a≤4/5, - `16/(m*a²)+24/m < 1-a`. -- `direct_budget_middle`: converts the explicitly hypothesized analytic bound - on T to D. This is an honest consumer, not a proof of its analytic premise. -- `large_ray_budget`: for m>0, a≥4/5 and m(1-a)≥49, - `16/(m*a²)+24/m ≤ 1-a`. -- `direct_budget_small`: consumes T<2/3 for 0:`, not from the changing working tree. Independently rehashed the raw Git tree object and recovered the exact requested OID. +- Executed both generator bodies in memory: replaced only `ROOT`/filesystem path operations with an in-memory read/write adapter; retained their arithmetic, assertions, templates and serialization. All assertions passed and **all 8 generated outputs matched the target blobs byte-for-byte**. Neither generator was allowed to write the checkout. +- Independently rebuilt the polar polynomials using a multinomial formula, integrated rational coefficients with `Fraction`, and compared against generated Lean literals and the paper JSON certificates. Independently evaluated the literal finite J polynomials as an additional nonvacuity check. +- Checked the 34-file in-tree import closure of the four diagnostic entry points for executable `axiom`, `sorry`, `admit`, `sorryAx`, `native_decide`, `implemented_by`, `unsafe`, and `extern` tokens after removing comments/strings: no findings. This is a source scan, not a replacement for `#print axioms` or kernel replay. +- HEAD remained `1108d11ee7e6c1d231d41c91607745e0330dcbc2`. Three untracked paths appeared concurrently (`docs/paper-formalization/modules.json`, `scripts/check_paper.py`, `scripts/verify_paper_results.py`); none was read as target source or created by this audit. They do not change the immutable review object. + +## 1. Actual q, mean, variance, and actual complex integrals + +**DI02 — PASS.** `tests/PaperCenteredHundred.lean:13–37` defines exactly 50 copies of `2/5` and 50 copies of `1`, as a **complex multiset**, and defines `r` by mapping subtraction of the same `μ`. It proves cardinality 100, mean `7/10`, actual variance and signed second moment `9/100`, and `Gamma = 1/539`. Multiplicity is not erased. Its pointwise theorem also supplies nonzero entries and norm at most one. + +`tests/PaperCenteredHundred.lean:1993–1999,2003–2015,2064–2092` binds J and K to the literal complex product integrals of that q. K is not an AM–GM relaxation. The proof of full polar uses three positive rectangles plus the nonnegative initial interval and actual complex-to-real equality. Independent exact polynomial integration confirmed K>1 and J>1 (display only: K≈1.7305046879164039, J≈1.58437325574623). + +**DI03–DI07 — PASS.** `Sendov/Analytic/PaperConjugate.lean:10–70` defines `x ± i sqrt(1-x²)` and exactly n copies of each. `card_family`, `sum_family`, `mean_family`, and `variance_family` prove the actual multiset facts. `pair_product`, `polar_product`, K/J definitions and `K_eq` at lines 72–106 bind the rational polar polynomial to the **same actual complex family**. Generated `expansion` proofs use `ring`; `integral_coeffs` at lines 108–120 proves finite integration with integrability obligations, rather than trusting a coefficient list. + +The exact registry matches `first-origin/REPORT.md:259–269` and `first-origin/verify.py:174–185`: + +| ID | m | a | x = actual mean | Actual centered variance | Checked C·H degrees | +|---|---:|---|---|---|---| +| DI03 | 6 | 9/10 | 49/50 | 99/2500 | 3–6 | +| DI04 | 8 | 99/100 | 497/500 | 2991/250000 | 3–8 | +| DI05 | 20 | 9/10 | 83/100 | 3111/10000 | 3–20 | +| DI06 | 100 | 9/10 | 61/100 | 6279/10000 | 3–100 | +| DI07 | 100 | 99/100 | 22/25 | 141/625 | 3–100 | + +`tests/PaperConjugateBudgets.lean:26–80` has one `Accepted` proposition containing cardinality, pointwise norm, actual mean/variance, literal full polar, the paper majorant budget, and literal norm J>1. All five named closed instances feed `all_datasets_closed`; `dataset_count` proves length five. Programmatic enumeration confirmed five distinct IDs and the exact five triples, not merely five imports or duplicate rows. + +## 2. All finite H terms, square roots, and the genuine majorant + +**PASS.** The paper's E_fin is `PaperCenteredBound.majorant_Efin`, **not** `PaperCentered.Efin`: + +- `Sendov/Analytic/PaperCenteredBound.lean:24–36,83–100` defines the interior square-root coefficient, explicit top branch `sqrt(v^m)`, and the sum over `Ico 3 (r.card+1)`. Every term multiplies the actual `‖H‖`. Its comparison with the independently defined actual-coefficient bound has the correct direction. +- `Sendov/Analytic/PaperConjugate.lean:123–145` proves exact BR/B and norm-H equalities and `budget_eq`, including the actual variance and `Gamma`. `scalarBudget` is therefore tied back to the literal majorant, not simply given a similar name. +- `sqrt_term_le` at lines 151–163 requires and consumes `s≥0`, **d>0**, b≥0, and `s*h²≤(b*d)²`. Generated term proofs discharge these with `norm_num`, retaining `abs(1-BR)` at every degree. The degree-100 proof explicitly uses `endpoint_100`, then `C_top` (`tests/PaperConjugateDI06.lean:1099–1103`, likewise DI07). +- Independent enumeration found **224 C·H term proofs** across the five conjugate modules, with endpoint ranges 0…m and term ranges 3…m exactly. The scalar summation consumer exhaustively invokes the corresponding terms, including term m, and the actual paper-budget and norm-J consumers follow (`DI06:1105–1231` is the degree-100 instance). +- DI02's `normalized_C_le` (`PaperCenteredCertificate.lean:64–79`) proves its normalization denominator positive from `choose_pos` and `u>0`, with an explicit top branch. There are **98 generic and 98 actual-coefficient rows**, each covering 3…100. Integer envelope sums are `453022083` and `10642552` over denominator `10^12`; their consumers prove the requested distinct bounds `<1/2000` and `<11/10^6` (`PaperCenteredHundred.lean:1948–1984`). No actual coefficients are substituted into the generic majorant proof. + +For DI02 only, replacing each norm-H by its proved upper bound one is legitimate: its scale is proved to be the real `63/100`, and the proof first bounds the actual finite H terms (`PaperCenteredCertificate.lean:24–60`; `PaperCenteredHundred.lean:36–51`). This is expressly allowed for this dataset in `first-origin/REPORT.md:250–256`; it is not a false general complex-scale probability argument. + +Both generators are stdlib-only untrusted witness producers. Their assertions are useful diagnostics, **not axioms**. The emitted Lean independently proves binomial constants, square inequalities, polynomial identities and integral values. Coarser generated envelopes differ from paper display-only decimal error estimates and DI02's original `10^35` rounding denominator, but preserve the exact required final bounds; they do not claim those displays are equal. + +## 3. Nonvacuous norm-J conclusions + +**PASS.** `PaperCenteredBound.C_budget:110–119` consumes the proved majorant budget and actual mean, forwarding to `PaperCentered.C_budget:332–360`. The latter derives its norm conclusion from the proved centered integral identity, not a hypothesized identity or a first-origin upper bound. The local `hJ : ‖J‖≤1` is introduced **only by negating the desired conclusion inside `by_contra`**; it is not an external first-origin premise. + +Every DI02–DI07 final norm-J theorem is closed at its concrete inputs. The conjugate route is `scalar_budget → budget_implies_J → PaperCenteredBound.C_budget`, with `budget_eq` restoring the actual family. Independent exact J calculations also gave J>1 for every dataset (display only: DI03 1.14353584; DI04 1.0179691061941714; DI05 1.373591961593296; DI06 1.8543274511846286; DI07 1.1512506640471187). These are finite q diagnostics, not Sendov polynomial counterexamples. + +## 4. DI08–DI10: rejected decimal, historical margin, and direct T + +**PASS.** `tests/PaperLegacyCertificates.lean:22–32` preserves exactly `0.999999986596654 = 499999993298327/500000000000000`, `a=999999999/10^9`, upper endpoint `a+100h²`, and the distinct legacy witness `a+3h²`. The rejected value is neither repaired to a nearby root nor confused with binary64's exact binary fraction. + +`PaperLegacyHelpers.lean:11–79` supplies actual indexed complex pairs, unit norms, actual mean real part, and K=R. `PaperLegacyExact.lean` and `PaperLegacyHundred.lean` prove their coefficient expansions and actual integrals. Independent multinomial reconstruction checked **every coefficient and integral** for rejected/lower/upper/legacy/twenty/hundred, and the exact values matched `first-origin-uniform/certificates.json` and `legacy_RESULT.json` (for gap fields, compared K−1 exactly). + +`PaperLegacyCertificates.lean:46–80` proves rejected full K<1, strict raw and full-complex endpoint brackets, and D for **all** raw-feasible x in the stated domain, not just a replacement sample. `legacy_three_fifths:89–101` consumes the actual `PaperTaylor.budget_le` estimate and proves **B−T>3h/5**, not the weaker uniform h/3. Independent rational evaluation of that Taylor bound gave a margin/h of approximately 0.6590909064842657, strictly above 3/5. + +DI10 uses the actual T integral (`PaperTaylor.budget:19–24`) through a finite split (`PaperLegacyHelpers.lean:95–148`), not a centered C-budget or uncorrected quadrature. Positivity, split endpoints, chord extension to its zero, and the direction of rounding the half-integer tail exponent downward are explicit. Independent rational checks confirmed both split majorants are below B, with positive displayed margins approximately 0.0159601261 and 0.0028272840. Full K and unit-circle facts are packaged alongside them (`PaperLegacyCertificates.lean:103–177`). Source-level proof-closure assertions at lines 188–230 require the relevant integral/T lemmas and forbid centered/near substitutes for the selected legacy roots. + +Paper sources: `first-origin-uniform/REPORT.md:53–94`, `legacy_RESULT.md:19–25`. The original Simpson/displayed gaps are not asserted as equal to these new structural certificates. + +## 5. DI15–DI17: intervals and correctly scoped countermodels + +**PASS.** `tests/PaperPolarDomainWitnesses.lean:19–61,63–189` proves full complex polar throughout both **closed intervals**, using all-ones q for m=7 and exactly five conjugate pairs at x=93/100 for m=10. No raw-polar hypothesis or grid is substituted. Uniform lower-polynomial comparisons include coefficient positivity and integrability. Independent exact evaluation of the proof's lower certificates gave approximately 1.0783885631 and 1.0091408796, both >1. The latter is deliberately weaker than the paper's displayed >1.00927; the formal theorem claims full-polar nonvacuity, not that sharper display. + +Lines 191–210 preserve the exact m=64,a=1/2,all-ones integral, prove alpha=24>17 and full K>1, and refute precisely pointwise+full-polar ⇒ alpha≤17. This does not assume first-origin/root-disk data. + +Lines 215–317 define the actual polynomial `(X−1)^9*(X+1)`, prove its derivative and complete critical multiset (eight copies of 1, one of −4/5), and use that derivative-root multiset in the reciprocal-square sum. They prove the marked point −1/4 lies in the actual root convex hull **and is not a root**, sum `25488/3025<9`, and attained nearest distance `11/20<1`. Independent rational checks verified the moment, distances and barycentric combination. The final negation targets only the **nonroot convex-hull moment variant**, not a marked-root theorem or the nearest-critical-point bound. + +Paper sources: `first-origin-uniform/round6/REPORT.md:135–146`, `round7/REPORT.md:73–80,171–181`. All exact input tokens agree. + +## Style/performance, separately + +Large rational literals, repeated per-degree statements, broad local arithmetic options, and coarse envelopes are readability/performance considerations, not semantic blockers. No Lean timing or memory performance was measured in this read-only audit. No additional scope or all-parameter theorem is demanded. + +**Remaining verification boundary:** the parent's compile/kernel replay is separate and must be reported from its actual receipts. This audit created only this review file; it made no build, source, cache, Git-index, research-input, or remote writes. diff --git a/docs/paper-formalization/reviews/mapping-before-corollary-exports.md b/docs/paper-formalization/reviews/mapping-before-corollary-exports.md new file mode 100644 index 0000000..f1e2522 --- /dev/null +++ b/docs/paper-formalization/reviews/mapping-before-corollary-exports.md @@ -0,0 +1,648 @@ +# Final acceptance map — exact Git tree `1b08ca1ec9c505dbecffb6341b62dfde2fb5634d` + +**Mathematical mapping: 92/92 obtained-local-proof units.** No genuine required mathematical gap remains in this ledger: 71 units map to source theorem families and 21 to explicit corollary recipes. This is **not** a claim of exact-tree kernel success. + +All 101 inherited units and all 92 required IDs are preserved. The source was read only through immutable `git show TREE:path`; the obsolete ledger commit is retained only as provenance. The JSON contains exact source signatures, source namespace/variable context, blob identities, definitions and report hashes. Every recorded qualified declaration exists at its cited source location. Anonymous test examples are pinned by blob and line, not given fictitious theorem names. + +## Separate acceptance axes + +- **Mathematical mapping: yes, 92/92.** No required unit is missing, partial or in flight. This counts the inherited normalized families, not atomic propositions or compiled declarations. +- **Kernel evidence: not supplied by this audit.** No builds or Lean commands were run. The caller reported earlier uniform/historical/small-margin PASS at `1108d11`; the parent must separately establish exact-tree replay for all additions and all cited test modules. Worker claims of closure were not treated as kernel receipts. +- **Heuristic dispositions remain open:** AS01, AS02 and AS04 are incomplete calculations, not among the 92 obtained proofs. Explicitly correct their presentation or supply the missing remainder/root/convergence contracts below. +- **External scope not adopted:** OP04/OP05 remain external; no arbitrary complex-collinear transport/general equality or averaged-L² adoption is inferred. +- **No full m≥7 D claim:** the uniform result is m≥256, alongside the existing near-boundary and certified finite domains. The old endgame is not retired. + +## Validation counts + +| Check | Count/result | +|---|---| +| normalized_units | 101 | +| required | 92 | +| mapped_required | 92 | +| required_theorem | 71 | +| required_derived_corollary | 21 | +| required_remaining_gaps | 0 | +| distinct_qualified_references | 215 | +| distinct_named_theorems_or_lemmas | 214 | +| distinct_anonymous_examples | 12 | +| source_manifest_files | 45 | +| local_proof_import_closure_files | 97 | +| definitions_recorded | 47 | +| report_hashes_matched | 14 | +| Formerly missing/partial focus units now mapped | 21/21 | +| Formerly in-flight units now mapped | 6/6 | +| Duplicate IDs / normalized statements / unresolved qualified references | 0 / 0 / 0 | + +The static first-party import-closure scan found no `sorry`, `admit`, `axiom`, or `native_decide` tokens outside comments. This is not a kernel or elaborated transitive-axiom audit. All 14 report hashes match the prior inventory; no paper statement was silently replaced. + +## Whole ledger + +`theorem` means exact immutable source evidence, including anonymous examples and routine unfolding. `derived_corollary` means the concrete recipe below, not a compiled wrapper. The claim text and acceptance scope are inherited unchanged. + +| ID | Scope | Status | Claim | Immutable source theorem(s) / evidence | +|---|---|---|---|---| +| FO01 | required | theorem | Division-free first-origin identity and closed bound \|J\|≤1 from both pointwise disk families | `Sendov.first_origin_identity` — `Sendov/Counterexample/Identities.lean:230`
`Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_first_origin` — `Sendov/Analytic/FirstOriginSmall.lean:49`
`Sendov.FirstOriginSmall.norm_integral_Fprod_le_of_factorization` — `Sendov/Analytic/FirstOriginSmall.lean:144` | +| FO02 | required | derived_corollary | Exact F derivative decomposition and integrated residual 1=F(1)+maμI+R | `Sendov.hasDerivAt_Fprod` — `Sendov/Analytic/Origin.lean:275`
`Sendov.sumEraseProdC_id_eq` — `Sendov/Analytic/Origin.lean:261`
`Sendov.one_le_tri` — `Sendov/Analytic/Origin.lean:357`
`Sendov.continuous_Fprod` — `Sendov/Analytic/Origin.lean:340` | +| FO03 | required | derived_corollary | Residual and endpoint norm majorants, hence 1≤T+[ma/(m+1)]\|J\| and under first-origin 1≤T+ma/(m+1) | `Sendov.norm_deriv_add_le` — `Sendov/Analytic/Origin.lean:298`
`Sendov.one_le_tri` — `Sendov/Analytic/Origin.lean:357`
`Sendov.FirstOriginSmall.norm_Fprod_le` — `Sendov/Analytic/FirstOriginSmall.lean:13`
`Sendov.FirstOriginBudget.lower_budget` — `Sendov/Analytic/FirstOriginBudget.lean:14`
`Sendov.FirstOriginMargins.lower_budget_norm` — `Sendov/Analytic/FirstOriginMargins.lean:135` | +| FO04 | required | derived_corollary | Polar identities and hierarchy 1≤\|K\|≤∫∏\|a+δtq\|≤∫P_x^(m/2) | `Sendov.prod_sub_mul_prod` — `Sendov/Counterexample/Identities.lean:299`
`Sendov.polar_identity` — `Sendov/Counterexample/Identities.lean:332`
`Sendov.one_le_integral_prod_norm` — `Sendov/Analytic/Polar.lean:93`
`Sendov.one_le_integral_Ppolar` — `Sendov/Analytic/Polar.lean:237`
`Sendov.norm_sub_le_norm_one_sub_mul` — `Sendov/Analytic/Polar.lean:50`
`Sendov.prod_map_le_of_le` — `Sendov/Analytic/Polar.lean:72`
`Sendov.norm_prod_map` — `Sendov/Analytic/Polar.lean:79`
`Sendov.prod_norm_le_Ppolar` — `Sendov/Analytic/Polar.lean:172` | +| FO05 | required | derived_corollary | Finite mean/variance facts \|μ\|≤1, s≤1, v=s−\|μ\|² and \|κ\|≤v | `Sendov.FirstOriginSmall.norm_sum_le_card` — `Sendov/Analytic/FirstOriginSmall.lean:8`
`Sendov.sum_norm_sq_le_card` — `Sendov/Analytic/Polar.lean:155`
`Sendov.PaperCentered.norm_kappa_le_variance` — `Sendov/Analytic/PaperCentered.lean:281`
`Sendov.PaperCoefficient.sum_norm_add_sq` — `Sendov/Analytic/PaperCoefficient.lean:107`
`Sendov.PaperConsequences.centered_variance_le` — `Sendov/Analytic/PaperConsequences.lean:138` | +| FO06 | required | derived_corollary | For m=5,6 raw polar forces x>(1+a)/2; cubic deficit bounds 23h²/35 and 23h²/42 | `Sendov.FirstOriginSmall.polar_mean_gt_half_add_one` — `Sendov/Analytic/FirstOriginBounds.lean:31`
`Sendov.FirstOriginSmall.polar_cube_integral` — `Sendov/Analytic/FirstOriginAlgebra.lean:60`
`Sendov.FirstOriginSmall.Q_lower` — `Sendov/Analytic/FirstOriginAlgebra.lean:70`
`Sendov.FirstOriginSmall.fifth_sixth_majorant` — `Sendov/Analytic/FirstOriginAlgebra.lean:86`
`Sendov.FirstOriginSmall.Ppolar_nonneg_small` — `Sendov/Analytic/FirstOriginBounds.lean:14`
`Sendov.continuous_Ppolar` — `Sendov/Reduction/Setup.lean:34` | +| FO07 | required | theorem | Finite five-halves Taylor/algebra majorant without a fixed near-boundary loss | `Sendov.FirstOriginSmall.five_halves_majorant` — `Sendov/Analytic/FirstOriginAlgebra.lean:91`
`Sendov.FirstOriginSmall.B_five_halves` — `Sendov/Analytic/FirstOriginBounds.lean:99` | +| FO08 | required | theorem | Exact positive A5/A6 gap identities and T5,T6`Sendov.FirstOriginSmall.upper_six_gap` — `Sendov/Analytic/FirstOriginAlgebra.lean:113`
`Sendov.FirstOriginSmall.direct_budget_five` — `Sendov/Analytic/FirstOriginBounds.lean:116`
`Sendov.FirstOriginSmall.direct_budget_six` — `Sendov/Analytic/FirstOriginBounds.lean:138`
`Sendov.FirstOriginMargins.upper_five_gap_identity` — `Sendov/Analytic/FirstOriginMargins.lean:47`
`Sendov.FirstOriginMargins.upper_six_gap_identity` — `Sendov/Analytic/FirstOriginMargins.lean:58` | +| FO09 | required | theorem | Closed-domain first-origin+polar contradiction for n=6,7, consumed by strict interior Sendov | `Sendov.FirstOriginSmall.first_origin_polar_six_seven` — `Sendov/Analytic/FirstOriginSmall.lean:134` | +| FO10 | required | theorem | Quantitative A5≥1/16 and A6≥93/560 on [0,1] | `Sendov.FirstOriginMargins.A5_lower` — `Sendov/Analytic/FirstOriginMargins.lean:37`
`Sendov.FirstOriginMargins.A6_lower` — `Sendov/Analytic/FirstOriginMargins.lean:42` | +| FO11 | required | theorem | Pointwise+polar gives \|J\|≥1+(3/40)h for m=5 and ≥1+(31/160)h for m=6 | `Sendov.FirstOriginMargins.norm_J_six` — `Sendov/Analytic/FirstOriginMargins.lean:243`
`Sendov.FirstOriginMargins.norm_J_seven` — `Sendov/Analytic/FirstOriginMargins.lean:264` | +| CE01 | required | theorem | Full finite centered expansion with every k≤m, exact B/H endpoint terms and binomial factors | `Sendov.PaperCentered.centered_product` — `Sendov/Analytic/PaperCentered.lean:41`
`Sendov.PaperCentered.finite_beta` — `Sendov/Analytic/PaperCentered.lean:135`
`Sendov.PaperCentered.centered_integral` — `Sendov/Analytic/PaperCentered.lean:160` | +| CE02 | required | theorem | Exact second-order expansion (m+1)aμI=1−κ/((m−1)μ²)+ε with e1=0 and e2=−mκ/2 | `Sendov.PaperCentered.coeff_one` — `Sendov/Analytic/PaperCentered.lean:216`
`Sendov.PaperCentered.coeff_two` — `Sendov/Analytic/PaperCentered.lean:220`
`Sendov.PaperCentered.second_order` — `Sendov/Analytic/PaperCentered.lean:251`
`Sendov.PaperCentered.two_mul_esymm_two` — `Sendov/Analytic/PaperCentered.lean:68` | +| CE03 | required | theorem | Optimized centered coefficient bound \|e_k\|²≤m^m v^k/[k^k(m−k)^(m−k)] for 1≤k`Sendov.PaperCoefficient.norm_esymm_card_sq_le` — `Sendov/Analytic/PaperCoefficient.lean:257`
`Sendov.PaperCoefficient.esymm_eq_zero_of_variance_eq_zero` — `Sendov/Analytic/PaperCoefficient.lean:192`
`Sendov.PaperCenteredBound.norm_esymm_le_C` — `Sendov/Analytic/PaperCenteredBound.lean:50` | +| CE04 | required | theorem | \|ε\|≤E_fin with the paper C_{m,k}(v) majorant, and C-budget E_fin+Γ<1−a\|μ\| ⇒ \|J\|>1 | `Sendov.PaperCenteredBound.majorant_Efin` — `Sendov/Analytic/PaperCenteredBound.lean:85`
`Sendov.PaperCenteredBound.norm_epsilon_le_majorant_Efin` — `Sendov/Analytic/PaperCenteredBound.lean:103`
`Sendov.PaperCenteredBound.C_budget` — `Sendov/Analytic/PaperCenteredBound.lean:110` | +| CE05 | required | theorem | Top endpoint H_{m,m}(aμ)=(aμ)^(m+1) exactly cancels inverse-μ tail growth | `Sendov.PaperCentered.H_top` — `Sendov/Analytic/PaperCentered.lean:192`
`Sendov.PaperCenteredBound.majorant_top_suppression` — `Sendov/Analytic/PaperCenteredBound.lean:123`
`Sendov.PaperCenteredBound.coeff_top_suppression` — `Sendov/Analytic/PaperCenteredBound.lean:134` | +| PO01 | required | derived_corollary | Raw polar implies x>a/2, 0`Sendov.PaperPolar.b_pos` — `Sendov/Analytic/PaperPolar.lean:111`
`Sendov.PaperPolar.geometry` — `Sendov/Analytic/PaperPolar.lean:150` | +| PO02 | required | theorem | Raw-polar domination by exponential chord, without α≤17 or origin identities | `Sendov.PaperPolar.integral_le_exp` — `Sendov/Analytic/PaperPolar.lean:81`
`Sendov.PaperPolar.one_le_integral_exp` — `Sendov/Analytic/PaperPolar.lean:94` | +| PO03 | required | theorem | Exact finite affine polar chord integral and its raw-polar upper bound (A1) | `Sendov.PaperGlobalPolar.integral_chord` — `Sendov/Analytic/PaperGlobalPolar.lean:25`
`Sendov.PaperGlobalPolar.raw_integral_le_chord` — `Sendov/Analytic/PaperGlobalPolar.lean:42` | +| PO04 | required | theorem | Nδc≥log(Nδ), and for Nδ≥2, log(Nδ)/δ≥log N | `Sendov.PaperGlobalPolar.log_mul_delta_le` — `Sendov/Analytic/PaperGlobalPolar.lean:57`
`Sendov.PaperGlobalPolar.log_mul_div_delta` — `Sendov/Analytic/PaperGlobalPolar.lean:119` | +| PO05 | required | theorem | When Nδ<2, c>1/3; globally E=b^(m/2)≤4/(m+2) | `Sendov.PaperGlobalPolar.three_fifths_lt_c` — `Sendov/Analytic/PaperGlobalPolar.lean:149`
`Sendov.PaperGlobalPolar.endpoint_le` — `Sendov/Analytic/PaperGlobalPolar.lean:199` | +| PO06 | required | theorem | Refined large-Nδ decay E≤(Nδ)^(−m/((m+2)δ)) | `Sendov.PaperRateDetails.endpoint_delta_rate` — `Sendov/Analytic/PaperRateDetails.lean:19` | +| PO07 | required | derived_corollary | Raw polar implies 1−y≤αy²/6≤λy²/6 and 1−x≤λ/(6a) | `Sendov.PaperPolar.b_le_alpha` — `Sendov/Analytic/PaperPolar.lean:125`
`Sendov.PaperPolar.endpoint_bounds` — `Sendov/Analytic/PaperPolar.lean:132` | +| PO08 | required | theorem | Restored rational polar b≤α/(3+α)≤λ/(3+λ) and c≥3/(3+λ) | `Sendov.PaperPolar.b_le_alpha` — `Sendov/Analytic/PaperPolar.lean:125`
`Sendov.PaperPolar.endpoint_bounds` — `Sendov/Analytic/PaperPolar.lean:132`
`Sendov.PaperPolar.c_lower_bound` — `Sendov/Analytic/PaperPolar.lean:161` | +| PO09 | required | derived_corollary | Rational y lower bound (α+6)/(2(α+3)) is strictly stronger than Gaussian positive-root bound | `Sendov.PaperPolar.b_le_alpha` — `Sendov/Analytic/PaperPolar.lean:125` | +| IN01 | required | theorem | Universal finite second-order Taylor bound T≤1/(m+1)+E+d/[a(m−2)]+12ma²d²/[c⁴(m+1)(m+3)] | `Sendov.PaperTaylor.finite_taylor_budget` — `Sendov/Analytic/PaperTaylor.lean:294`
`Sendov.PaperTaylor.budget_le` — `Sendov/Analytic/PaperTaylor.lean:235` | +| IN02 | required | derived_corollary | All-m finite two-end estimates A5 and A5b: 100m/[9(m+1)(m+3)x²]+29E, and 16m/[(m+1)(m+3)x²]+13E | `Sendov.PaperHistoricalBounds.total_le_A5` — `Sendov/Analytic/PaperHistoricalBounds.lean:303`
`Sendov.PaperHistoricalBounds.total_le_A5b` — `Sendov/Analytic/PaperHistoricalBounds.lean:329`
`Sendov.PaperTwoEnd.total_eq_budget` — `Sendov/Analytic/PaperTwoEnd.lean:25`
`Sendov.PaperPolar.geometry` — `Sendov/Analytic/PaperPolar.lean:150` | +| IN03 | required | theorem | Scale-adapted left estimate and separated bound T<4/k+6E | `Sendov.PaperTwoEnd.left_le` — `Sendov/Analytic/PaperTwoEnd.lean:94`
`Sendov.PaperTwoEnd.left_lt` — `Sendov/Analytic/PaperTwoEnd.lean:107`
`Sendov.PaperTwoEnd.budget_lt_separated` — `Sendov/Analytic/PaperTwoEnd.lean:364` | +| IN04 | required | derived_corollary | Middle geometry T<4/k+(1+5k/8)exp(−3(m−1)k/(8m)); for m≥9 the exp(−k/3) relaxation | `Sendov.PaperTwoEnd.budget_lt_middle` — `Sendov/Analytic/PaperTwoEnd.lean:373` | +| IN05 | required | theorem | Sharp finite Laplace bound (S) with exact main coefficients, finite split and full right-tail term | `Sendov.PaperLaplace.sharp_laplace` — `Sendov/Analytic/PaperLaplace.lean:276`
`Sendov.PaperLaplace.budget_le` — `Sendov/Analytic/PaperLaplace.lean:265` | +| NE01 | required | theorem | m≥7, λ≤1/100 ⇒ B−T>h/3 (legacy) | `Sendov.PaperNearMargins.near_endpoint_one_hundredth` — `Sendov/Analytic/PaperNearMargins.lean:140` | +| NE02 | required | theorem | m≥7, λ≤1/50 ⇒ B−T>h/3 | `Sendov.PaperNearMargins.near_endpoint_one_fiftieth` — `Sendov/Analytic/PaperNearMargins.lean:110` | +| NE03 | required | theorem | m≥7, λ≤1/10 ⇒ B−T>h/5 | `Sendov.PaperNearMargins.near_endpoint_one_tenth` — `Sendov/Analytic/PaperNearMargins.lean:120` | +| NE04 | required | theorem | m≥7, λ≤1/5 ⇒ B−T>h/80 | `Sendov.PaperNearMargins.near_endpoint_one_fifth` — `Sendov/Analytic/PaperNearMargins.lean:130` | +| NE05 | required | derived_corollary | m≥7, λ≤3/10 ⇒ B−T>h/1000 | `Sendov.PaperNearClosure.near_endpoint_D` — `Sendov/Analytic/PaperNear.lean:158` | +| NE06 | required | theorem | m≥7, λ≤2/5 ⇒ B−T>h/1000 | `Sendov.PaperNearClosure.near_endpoint_D` — `Sendov/Analytic/PaperNear.lean:158`
`Sendov.FirstOriginBudget.near_contradiction` — `Sendov/Analytic/FirstOriginBudget.lean:53` | +| UN01 | required | theorem | m≥256 raw polar ⇒ T<2/3 | `Sendov.PaperUniform.budget_lt_two_thirds` — `Sendov/Analytic/PaperUniform.lean:43` | +| UN02 | required | theorem | m≥256, a≥1/3 raw polar ⇒ T<16/(ma²)+24/m | `Sendov.PaperUniform.budget_lt_retained` — `Sendov/Analytic/PaperUniform.lean:79` | +| UN03 | required | theorem | m≥512 raw polar ⇒ T<3/5 | `Sendov.PaperHistoricalBounds.budget_lt_three_fifths` — `Sendov/Analytic/PaperHistoricalBounds.lean:90` | +| UN04 | required | derived_corollary | m≥512, a≥2/5 ⇒ T<40/(ma²), hence ma²h≥40 ⇒ T`Sendov.PaperHistoricalBounds.budget_lt_one_sub_of_bulk40` — `Sendov/Analytic/PaperHistoricalBounds.lean:426` | +| UN05 | required | derived_corollary | m≥7, ma²h≥116 ⇒ T`Sendov.PaperBulk.large_ray_budget` — `Sendov/Analytic/PaperBulkAlgebra.lean:61` | +| UN07 | required | theorem | All a, integer m≥256: raw polar ⇒ D | `Sendov.PaperUniform.uniform_D` — `Sendov/Analytic/PaperUniform.lean:161` | +| UN08 | required | derived_corollary | All a, integer m≥512: raw polar ⇒ D | `Sendov.PaperConsequences.old_all_a_cutoff` — `Sendov/Analytic/PaperConsequences.lean:273`
`Sendov.PaperUniform.uniform_D` — `Sendov/Analytic/PaperUniform.lean:161` | +| UN09 | required | derived_corollary | All a, integer m≥10000: raw polar ⇒ D | `Sendov.PaperConsequences.old_all_a_cutoff` — `Sendov/Analytic/PaperConsequences.lean:273`
`Sendov.PaperUniform.uniform_D` — `Sendov/Analytic/PaperUniform.lean:161` | +| UN10 | required | derived_corollary | All a, integer m≥100000: raw polar ⇒ D | `Sendov.PaperConsequences.old_all_a_cutoff` — `Sendov/Analytic/PaperConsequences.lean:273`
`Sendov.PaperUniform.uniform_D` — `Sendov/Analytic/PaperUniform.lean:161` | +| UN11 | required | derived_corollary | All a, integer m≥1000000: raw polar ⇒ D | `Sendov.PaperConsequences.old_all_a_cutoff` — `Sendov/Analytic/PaperConsequences.lean:273`
`Sendov.PaperUniform.uniform_D` — `Sendov/Analytic/PaperUniform.lean:161` | +| RA01 | required | theorem | m≥256 polar geometry: λ≤1 gives x>5/6; λ≤10 gives b<4/5,x>7/12; λ≤25 gives b<9/10,x>231/512; λ≤49 gives b<23/25,x>207/512 | `Sendov.PaperRayGeometry.geometry_one` — `Sendov/Analytic/PaperRayGeometry.lean:78`
`Sendov.PaperRayGeometry.geometry_ten` — `Sendov/Analytic/PaperRayGeometry.lean:64`
`Sendov.PaperRayGeometry.geometry_twentyfive` — `Sendov/Analytic/PaperRayGeometry.lean:92`
`Sendov.PaperRayGeometry.geometry_fortynine` — `Sendov/Analytic/PaperRayGeometry.lean:176` | +| RA02 | required | theorem | Uniform finite tails for r=4/5,9/10,23/25 and the middle-geometry exponential tail | `Sendov.PaperTail.tail_four_fifths` — `Sendov/Analytic/PaperTail.lean:61`
`Sendov.PaperTail.tail_nine_tenths` — `Sendov/Analytic/PaperTail.lean:76`
`Sendov.PaperTail.tail_twenty_three_twenty_fifths` — `Sendov/Analytic/PaperTail.lean:89`
`Sendov.PaperTail.middle_tail` — `Sendov/Analytic/PaperTail.lean:121` | +| RA03 | required | derived_corollary | Round5 actual scaled upper bounds mx²T<1+18/m,1+33/m,1+51/m+1/4,1+62/m+2 on respective ray intervals | `Sendov.PaperTail.budget_region_one` — `Sendov/Analytic/PaperTail.lean:186`
`Sendov.PaperTail.budget_region_two` — `Sendov/Analytic/PaperTail.lean:200`
`Sendov.PaperTail.budget_region_three` — `Sendov/Analytic/PaperTail.lean:214`
`Sendov.PaperTail.budget_region_four` — `Sendov/Analytic/PaperTail.lean:226`
`Sendov.PaperRayGeometry.halfpoint_mem` — `Sendov/Analytic/PaperRayGeometry.lean:317`
`Sendov.PaperRayGeometry.geometry_one` — `Sendov/Analytic/PaperRayGeometry.lean:78`
`Sendov.PaperRayGeometry.geometry_ten` — `Sendov/Analytic/PaperRayGeometry.lean:64`
`Sendov.PaperRayGeometry.geometry_twentyfive` — `Sendov/Analytic/PaperRayGeometry.lean:92`
`Sendov.PaperRayGeometry.geometry_fortynine` — `Sendov/Analytic/PaperRayGeometry.lean:176`
`Sendov.PaperUniform.beta_one` — `Sendov/Analytic/PaperUniform.lean:18` | +| RA04 | required | derived_corollary | Round5 scaled lower bounds on [1/5,1], [1,5], [5,10], [10,25], [25,49] exceed matching upper estimates | `Sendov.PaperRateDetails.scaled_budget_paper_lower_one` — `Sendov/Analytic/PaperRateDetails.lean:123`
`Sendov.PaperRateDetails.scaled_budget_lower_one` — `Sendov/Analytic/PaperRateDetails.lean:138`
`Sendov.PaperRayGeometry.budget_lower_five` — `Sendov/Analytic/PaperRayGeometry.lean:268`
`Sendov.PaperRayGeometry.budget_lower_ten` — `Sendov/Analytic/PaperRayGeometry.lean:281`
`Sendov.PaperRayGeometry.budget_lower_twentyfive` — `Sendov/Analytic/PaperRayGeometry.lean:294`
`Sendov.PaperRayGeometry.budget_lower_fortynine` — `Sendov/Analytic/PaperRayGeometry.lean:305` | +| SE01 | required | theorem | Exact maximal raw polar U1=R(1), monotonicity, and U1<1 excludes all x | `Sendov.PaperSecant.R_one` — `Sendov/Analytic/PaperSecant.lean:42`
`Sendov.PaperSecant.R_mono` — `Sendov/Analytic/PaperSecant.lean:192`
`Sendov.PaperSecant.one_le_U1` — `Sendov/Analytic/PaperSecant.lean:205`
`anonymous example` — `tests/PaperSecantTests.lean:33` | +| SE02 | required | theorem | Curvature correction R(a/2)≤V0=U0−ma^(m−2)δ²/12, with 0`Sendov.PaperSecant.V0_pos` — `Sendov/Analytic/PaperSecant.lean:188`
`Sendov.PaperSecant.V0_lt_one` — `Sendov/Analytic/PaperSecant.lean:173` | +| SE03 | required | theorem | Convex secant forces a/2`Sendov.PaperSecant.raw_implies_secant` — `Sendov/Analytic/PaperSecant.lean:294`
`Sendov.PaperSecant.gate_denominators_pos` — `Sendov/Analytic/PaperSecant.lean:280`
`Sendov.PaperSecant.plain_secant_le_S` — `Sendov/Analytic/PaperSecant.lean:263`
`Sendov.PaperSecant.S_bounds` — `Sendov/Analytic/PaperSecant.lean:244` | +| SE04 | required | theorem | Integral-free rational gate F_sec>0 ⇒ D for every raw-polar feasible x, retaining floor(m/2) | `Sendov.PaperSecant.budget_antitone` — `Sendov/Analytic/PaperSecant.lean:329`
`Sendov.PaperSecant.budget_S_le_Wsec` — `Sendov/Analytic/PaperSecant.lean:361`
`Sendov.PaperSecant.gate_implies_D` — `Sendov/Analytic/PaperSecant.lean:380` | +| DI01 | required | theorem | Full complex-polar unit-circle m=8 counterexample to universal mean-half, at a=99/100, x=497/500 | `Sendov.PaperPolar.Counterexample.norm_q` — `tests/PaperPolarCounterexample.lean:43`
`Sendov.PaperPolar.Counterexample.mean_q` — `tests/PaperPolarCounterexample.lean:47`
`Sendov.PaperPolar.Counterexample.full_polar` — `tests/PaperPolarCounterexample.lean:118`
`Sendov.PaperPolar.Counterexample.not_universal_mean_half` — `tests/PaperPolarCounterexample.lean:144` | +| DI02 | required | theorem | m=100, a=9/10, q=50×(2/5)+50×1: full polar>1; E_fin<1/2000; actual-coefficient error<11/10^6; Γ=1/539; C-budget and J>1 | `Sendov.PaperCenteredHundred.diagnostic_DI02` — `tests/PaperCenteredHundred.lean:2082`
`Sendov.PaperCenteredHundred.pointwise` — `tests/PaperCenteredHundred.lean:22` | +| DI03 | required | theorem | Conjugate unit-circle family m=6, a=9/10, x=49/50: full polar>1 and finite centered C-budget succeeds | `Sendov.PaperConjugate.Budgets.DI03_closed` — `tests/PaperConjugateBudgets.lean:38` | +| DI04 | required | theorem | Conjugate unit-circle family m=8, a=99/100, x=497/500: full polar>1 and finite centered C-budget succeeds | `Sendov.PaperConjugate.Budgets.DI04_closed` — `tests/PaperConjugateBudgets.lean:43` | +| DI05 | required | theorem | Conjugate unit-circle family m=20, a=9/10, x=83/100: full polar>1 and finite centered C-budget succeeds | `Sendov.PaperConjugate.Budgets.DI05_closed` — `tests/PaperConjugateBudgets.lean:48` | +| DI06 | required | theorem | Conjugate unit-circle family m=100, a=9/10, x=61/100: full polar>1 and finite centered C-budget succeeds | `Sendov.PaperConjugate.Budgets.DI06_closed` — `tests/PaperConjugateBudgets.lean:53` | +| DI07 | required | theorem | Conjugate unit-circle family m=100, a=99/100, x=22/25: full polar>1 and finite centered C-budget succeeds | `Sendov.PaperConjugate.Budgets.DI07_closed` — `tests/PaperConjugateBudgets.lean:58` | +| DI08 | required | theorem | m=10,a=1−10^−9: rejected floating root has full K<1; true polar threshold is bracketed between x=a and a+100h²; certified T gap>0 for all feasible x | `Sendov.PaperLegacyCertificates.exact_source_parameters` — `tests/PaperLegacyCertificates.lean:28`
`Sendov.PaperLegacyCertificates.rejected_full_polar` — `tests/PaperLegacyCertificates.lean:47`
`Sendov.PaperLegacyCertificates.rejected_not_raw` — `tests/PaperLegacyCertificates.lean:52`
`Sendov.PaperLegacyCertificates.raw_threshold_bracket` — `tests/PaperLegacyCertificates.lean:57`
`Sendov.PaperLegacyCertificates.full_threshold_bracket` — `tests/PaperLegacyCertificates.lean:66`
`Sendov.PaperLegacyCertificates.all_feasible_D` — `tests/PaperLegacyCertificates.lean:73` | +| DI09 | required | theorem | Legacy m=10,a=1−10^−9,x=a+3h²: full K>1 and B−T>(3/5)h | `Sendov.PaperLegacyCertificates.legacy_complete` — `tests/PaperLegacyCertificates.lean:158`
`Sendov.PaperLegacyCertificates.legacy_three_fifths` — `tests/PaperLegacyCertificates.lean:89` | +| DI10 | required | theorem | Direct-budget certified data m=20,a=9/10,x=83/100 and m=100,a=99/100,x=22/25 | `Sendov.PaperLegacyCertificates.twenty_complete` — `tests/PaperLegacyCertificates.lean:167`
`Sendov.PaperLegacyCertificates.hundred_complete` — `tests/PaperLegacyCertificates.lean:173` | +| DI11 | required | theorem | Secant positive gates at (7,4/5),(8,9/10),(10,9/10); negative gate at (16,9/10) with feasible raw polar | `Sendov.PaperSecant.Tests.gate_7_four_fifths` — `tests/PaperSecantTests.lean:48`
`Sendov.PaperSecant.Tests.gate_8_nine_tenths` — `tests/PaperSecantTests.lean:52`
`Sendov.PaperSecant.Tests.gate_10_nine_tenths` — `tests/PaperSecantTests.lean:56`
`Sendov.PaperSecant.Tests.gate_16_nine_tenths_negative` — `tests/PaperSecantTests.lean:60`
`Sendov.PaperSecant.Tests.raw_feasible_at_negative_gate` — `tests/PaperSecantTests.lean:71` | +| DI12 | required | theorem | Curvature secant does not imply the proposed linear asymptotic extrapolation, exact m=10,a=49/50 counterexample | `Sendov.PaperSecant.Tests.linear_simplification_fails` — `tests/PaperSecantTests.lean:65` | +| DI13 | required | theorem | m=7, a∈[7999/10000,8001/10000]: F_sec>0 and D for all feasible x | `Sendov.PaperSecant.Neighborhoods.gate_7_interval` — `tests/PaperSecantNeighborhoods.lean:187`
`Sendov.PaperSecant.Neighborhoods.D_7_interval` — `tests/PaperSecantNeighborhoods.lean:192` | +| DI14 | required | theorem | m=10, a∈[899999/10^6,900001/10^6]: F_sec>0 and D for all feasible x | `Sendov.PaperSecant.Neighborhoods.gate_10_interval` — `tests/PaperSecantNeighborhoods.lean:200`
`Sendov.PaperSecant.Neighborhoods.D_10_interval` — `tests/PaperSecantNeighborhoods.lean:205` | +| DI15 | required | theorem | Full-polar nonvacuity throughout both secant neighborhoods: q≡1 for m=7 and five unit-circle pairs at x=93/100 for m=10 | `Sendov.PaperPolar.DomainWitnesses.neighborhood_7` — `tests/PaperPolarDomainWitnesses.lean:51`
`Sendov.PaperPolar.DomainWitnesses.neighborhood_10` — `tests/PaperPolarDomainWitnesses.lean:152`
`Sendov.PaperPolar.DomainWitnesses.mean_q10` — `tests/PaperPolarDomainWitnesses.lean:90` | +| DI16 | required | theorem | Pointwise+full polar does not imply α≤17: m=64,a=1/2,q≡1 gives α=24 and K>1 | `Sendov.PaperPolar.DomainWitnesses.K_64_exact` — `tests/PaperPolarDomainWitnesses.lean:192`
`Sendov.PaperPolar.DomainWitnesses.domain_64` — `tests/PaperPolarDomainWitnesses.lean:197`
`Sendov.PaperPolar.DomainWitnesses.not_polar_implies_alpha17` — `tests/PaperPolarDomainWitnesses.lean:204` | +| DI17 | required | theorem | Convex-hull finite-moment strengthening fails: p=(z−1)^9(z+1), a=−1/4, reciprocal-square sum 25488/3025<9, nearest critical distance 11/20 | `Sendov.PaperPolar.DomainWitnesses.Nonroot.root_geometry` — `tests/PaperPolarDomainWitnesses.lean:303`
`Sendov.PaperPolar.DomainWitnesses.Nonroot.critical_roots` — `tests/PaperPolarDomainWitnesses.lean:229`
`Sendov.PaperPolar.DomainWitnesses.Nonroot.critical_multiplicities` — `tests/PaperPolarDomainWitnesses.lean:235`
`Sendov.PaperPolar.DomainWitnesses.Nonroot.convex_hull_nonroot` — `tests/PaperPolarDomainWitnesses.lean:251`
`Sendov.PaperPolar.DomainWitnesses.Nonroot.reciprocal_square_exact` — `tests/PaperPolarDomainWitnesses.lean:275`
`Sendov.PaperPolar.DomainWitnesses.Nonroot.reciprocal_square_lt_nine` — `tests/PaperPolarDomainWitnesses.lean:282`
`Sendov.PaperPolar.DomainWitnesses.Nonroot.nearest_critical_distance` — `tests/PaperPolarDomainWitnesses.lean:288` | +| BO01 | required | theorem | Unrestricted squared-distance multiset identity and aggregate first/second-moment rigidity | `Sendov.sum_norm_sub_one_sq` — `Sendov/Boundary.lean:91`
`Sendov.all_eq_one_of_sum_norm_sq_le_card` — `Sendov/Boundary.lean:101` | +| BO02 | required | theorem | Boundary reciprocal/half-plane identity and weaker averaged q-bound force q≡1 | `Sendov.half_le_re_inv_one_sub` — `Sendov/Boundary.lean:78`
`Sendov.boundary_reciprocal` — `Sendov/Boundary.lean:121`
`Sendov.all_q_eq_one_of_sum_norm_sq_le` — `Sendov/Boundary.lean:138` | +| BO03 | required | theorem | Rubinstein strict-or-extremal p=c(X^n−1) and boundary Sendov, with unchanged final contracts | `Sendov.rubinstein_one` — `Sendov/Boundary.lean:159`
`Sendov.sendov_boundary_one` — `Sendov/Boundary.lean:283`
`Sendov.sendov` — `Sendov/Conjecture.lean:158`
`Sendov.phelps_rodriguez` — `Sendov/Conjecture.lean:83` | +| BO04 | required | theorem | Moment premise alone is strictly weaker than pointwise disk; consistent countermodels show necessity of each generic/boundary hypothesis | `anonymous example` — `tests/BoundaryProbe.lean:63`
`anonymous example` — `tests/BoundaryProbe.lean:68`
`anonymous example` — `tests/BoundaryProbe.lean:72`
`anonymous example` — `tests/BoundaryProbe.lean:77`
`anonymous example` — `tests/BoundaryProbe.lean:84`
`anonymous example` — `tests/BoundaryProbe.lean:93`
`anonymous example` — `tests/BoundaryProbe.lean:102`
`anonymous example` — `tests/BoundaryProbe.lean:111`
`anonymous example` — `tests/BoundaryProbe.lean:119`
`anonymous example` — `tests/BoundaryProbe.lean:135` | +| CO01 | required | theorem | Real-split derivative multiset exhausts inherited roots with one less multiplicity plus distinct simple new gap roots | `Collinear.derivative_root_budget` — `Sendov/Collinear/Gate.lean:11` | +| CO02 | required | theorem | Every new critical point occupies one adjacent real-root gap; every gap has a unique simple critical point | `Collinear.new_critical_point_gap` — `Sendov/Collinear/Gate.lean:97`
`Collinear.adjacent_gap_unique` — `Sendov/Collinear/Gate.lean:130` | +| CO03 | required | theorem | Occurrence-counted signed-side domination P_-≤Q_-, P_+≤Q_+ at any marked real root | `Collinear.signed_reciprocal_domination` — `Sendov/Collinear/Mass.lean:67` | +| CO04 | required | theorem | Simple marked-root reciprocal balance, signed/absolute decomposition and two-sided mass 2P_±≤Q | `Collinear.reciprocal_balance` — `Sendov/Collinear/Balance.lean:7`
`Collinear.reciprocal_decomposition` — `Sendov/Collinear/Balance.lean:33`
`Collinear.two_sided_mass` — `Sendov/Collinear/Balance.lean:59` | +| CO05 | required | theorem | Real-split interval-diameter reciprocal lower bound Q≥2(n−1)/(B−A), with repeated-root disjunction | `Collinear.diameter_reciprocal` — `Sendov/Collinear/Diameter.lean:34` | +| CO06 | required | theorem | Real-split diameter moment for all real r≥1, with full multiplicity and p′(a)=0 disjunction | `Collinear.diameter_moment` — `Sendov/Collinear/Moment.lean:31` | +| CO07 | required | theorem | Repeated-root finite-real reciprocal formulation cannot omit the p′(a)=0 disjunction: p=(X−a)^2 | `anonymous example` — `tests/CollinearRound2Tests.lean:73` | +| EX01 | required | derived_corollary | Under pointwise+raw polar, v/\|μ\|²≤b/(1−b)≤α/3, hence Γ≤α/[3(m−1)]<7h/18 for m≥7 | `Sendov.PaperPolar.b_le_alpha` — `Sendov/Analytic/PaperPolar.lean:125`
`Sendov.PaperCentered.norm_kappa_le_variance` — `Sendov/Analytic/PaperCentered.lean:281`
`Sendov.PaperConsequences.centered_variance_le` — `Sendov/Analytic/PaperConsequences.lean:138`
`Sendov.PaperConsequences.variance_ratio_le_alpha` — `Sendov/Analytic/PaperConsequences.lean:179`
`Sendov.PaperConsequences.Gamma_lt_seven_eighteenths` — `Sendov/Analytic/PaperConsequences.lean:202`
`Sendov.PaperPolar.geometry` — `Sendov/Analytic/PaperPolar.lean:150` | +| EX02 | required | derived_corollary | Conditional E_fin≤h/2 implies centered contradiction via Γ+E_fin<8h/9`Sendov.PaperConsequences.norm_J_gt_one_of_majorant_half` — `Sendov/Analytic/PaperConsequences.lean:226`
`Sendov.PaperConsequences.Gamma_lt_seven_eighteenths` — `Sendov/Analytic/PaperConsequences.lean:202`
`Sendov.PaperConsequences.centered_variance_le` — `Sendov/Analytic/PaperConsequences.lean:138` | +| EX03 | required | theorem | Simple-root distance-product identity implies all-r>0 moment lower bounds; if ∏\|a−z_j\|≤m+1 then Σ\|q_j\|^r≥m | `Sendov.PaperConsequences.root_distance_product_identity` — `Sendov/Analytic/PaperConsequences.lean:97`
`Sendov.PaperConsequences.moment_ge_degree_of_root_distance_product` — `Sendov/Analytic/PaperConsequences.lean:123` | +| AS01 | explicit_disposition_required | asymptotic_proof_incomplete | Fixed m, h→0: R=1+m[(m−4)/6−k]h²+O_m(h³), polar root x*=1−(m−4)h/6+O_m(h²) | No local theorem claimed | +| AS02 | explicit_disposition_required | asymptotic_proof_incomplete | At (a,x)=(1,1), T=1/(m+1), ∂aT=0, ∂xT=−2/(m−2); along polar root B−T=[m/(m+1)−(m−4)/(3(m−2))]h+O_m(h²) | No local theorem claimed | +| AS03 | required | theorem | Fixed m≥1, a→0: exact R_max formula tends to 1/(m+1)<1, so a neighborhood is polar infeasible | `Sendov.PaperSecant.R_one` — `Sendov/Analytic/PaperSecant.lean:42`
`Sendov.PaperSecant.R_mono` — `Sendov/Analytic/PaperSecant.lean:192`
`Sendov.PaperConsequences.U1_zero` — `Sendov/Analytic/PaperConsequences.lean:22`
`Sendov.PaperConsequences.tendsto_U1_zero_right` — `Sendov/Analytic/PaperConsequences.lean:34`
`Sendov.PaperConsequences.U1_limit_lt_one` — `Sendov/Analytic/PaperConsequences.lean:39`
`Sendov.PaperConsequences.exists_small_radius_not_rawPolar` — `Sendov/Analytic/PaperConsequences.lean:44` | +| AS04 | explicit_disposition_required | asymptotic_proof_incomplete | Fixed λ>0, m→∞ with a=1−λ/m: polar integral tends to Gλ(x), mT→1/x² and mB→1+λ | No local theorem claimed | +| AS05 | required | theorem | Whole limiting ray budget: Gλ(x)≥1 ⇒ 1−x≤λx²/6 ⇒ (1+λ)x²−1≥(1−x)(5−x), strictly positive for λ>0 | `Sendov.PaperConsequences.limiting_exponential_model` — `Sendov/Analytic/PaperConsequences.lean:244` | +| DG01 | not_a_theorem | diagnostic_only | Floating/high-precision screens, root finding and loss diagnostics suggest D but prove no continuous coverage | No local theorem claimed | +| OP01 | not_obtained | paper_open | Full D for every integer m≥7 and all 0`Sendov.PaperWideRays.HI03_small_one` — `Sendov/Analytic/PaperWideRays.lean:181`
`Sendov.PaperWideRays.HI03_small_five` — `Sendov/Analytic/PaperWideRays.lean:195` | +| HI04 | required | theorem | Small-a quantitative ratios: m≥100000,a≤1/2 gives T/h<83567/100000; m≥10000,a≤1/2,ma²h<116 gives T/h<106/125 | `Sendov.PaperRateDetails.small_a_ratio_100000` — `Sendov/Analytic/PaperRateDetails.lean:60`
`Sendov.PaperRateDetails.small_a_ratio_10000` — `Sendov/Analytic/PaperRateDetails.lean:81` | + +## Per-unit contract notes and corollary recipes + +### FO01 — theorem + +The recorded immutable source signatures match this inherited theorem family. + +### FO02 — derived_corollary + +Explicit finite mathematical composition from the recorded immutable declarations; no independently compiled corollary wrapper is claimed. + +**Concrete recipe:** Let m=q.card>0, μ=q.sum/m, F(t)=Fprod a q t, I=∫₀¹F(t)dt, and S₂(t)=sumEraseProdC q (v↦v²) (v↦1−atv). Apply hasDerivAt_Fprod and substitute sumEraseProdC_id_eq: F′=−a q.sum F−a²t S₂. All functions are finite polynomial products, hence continuous and interval-integrable. FTC gives F(1)−1=−maμI−a²∫₀¹tS₂(t)dt. Define R=a²∫₀¹tS₂(t)dt and rearrange. This is precisely the hFTC/hG/hkey argument inside one_le_tri, not an inference that its inequality alone implies an equality. + +### FO03 — derived_corollary + +Explicit finite mathematical composition from the recorded immutable declarations; no independently compiled corollary wrapper is claimed. + +**Concrete recipe:** Use n=m+1, μ=x+iy=q.sum/m. Apply norm_deriv_add_le pointwise on t∈[0,1] and integrate to obtain |R|≤ma²∫tβ(t)^((m−1)/2); apply norm_Fprod_le at t=1 for |F(1)|≤β(1)^(m/2). FO02 and |μ|≤1 give 1≤T+ma|I|=T+ma/(m+1)|J|. This latter inequality is now directly lower_budget_norm, with β(1)≥(1−a)²≥0 from x≤1. For first-origin |J|≤1 use FO01, or apply lower_budget to its equivalent |I|≤1/(m+1). + +### FO04 — derived_corollary + +Explicit finite mathematical composition from the recorded immutable declarations; no independently compiled corollary wrapper is claimed. + +**Concrete recipe:** Set n=m+1 and K=∫∏(a+δtqj), δ=1−a². Apply prod_sub_mul_prod and polar_identity to the actual root/derivative factorizations. For each root z, norm_sub_le_norm_one_sub_mul gives |a−z|≤|1−az|. Multiply with prod_map_le_of_le and then by |q.prod|; take norms of both identities with norm_prod_map to get n≤n|K|. Cancel positive n. The norm-integral triangle inequality and norm_prod_map give |K|≤∫∏|a+δtqj|. Integrate prod_norm_le_Ppolar at n=m+1 and actual real mean x for the final upper bound. All integrands are continuous finite products or nonnegative quadratic real powers. This retains the full hierarchy, not only exported weaker one_le_integral_* inequalities. + +### FO05 — derived_corollary + +Explicit finite mathematical composition from the recorded immutable declarations; no independently compiled corollary wrapper is claimed. + +**Concrete recipe:** For m=q.card>0, set μ=q.sum/m, r=q.map(v↦v−μ), s=(Σ|qj|²)/m and v=variance r. Finite-sum linearity gives r.sum=0. Divide norm_sum_le_card and sum_norm_sq_le_card by m to obtain |μ|≤1 and s≤1. Apply sum_norm_add_sq to (r,μ): its cross term vanishes and μ+(qj−μ)=qj, giving Σ|qj|²=m|μ|²+Σ|qj−μ|². Divide by m to get v=s−|μ|². Apply norm_kappa_le_variance to r. centered_variance_le independently exports v≤1−|μ|² and |μ|≤1. + +### FO06 — derived_corollary + +Explicit finite mathematical composition from the recorded immutable declarations; no independently compiled corollary wrapper is claimed. + +**Concrete recipe:** Put x₀=(1+a)/2. polar_cube_integral and Q_lower give ∫P₀³≤1−(92/140)h²=1−23h²/35. For x≤x₀,t∈[0,1], P₀−P_x=2a(1−a²)(x₀−x)t≥0; nonnegativity is Ppolar_nonneg_small, so the same bound holds for m=6. For m=5 apply fifth_sixth_majorant at y=sqrt(P₀(t)), integrate 6P₀^(5/2)≤1+5P₀³, and obtain deficit (5/6)(23/35)h²=23h²/42. Monotonicity extends to x≤x₀. Under raw polar≥1 and 0a/2 because a>0. The bounds 01. + +### PO05 — theorem + +three_fifths_lt_c implies the weaker paper c>1/3 by 1/3<3/5. endpoint_le is exactly E≤4/(m+2). + +### PO06 — theorem + +Take N=(m+2)/2 and δ=1−a². The report A3 assumes Nδ≥2 (REPORT.md:149–151), exactly the hlarge premise; m≥7 is the standing report domain. The exponent is precisely −m/((m+2)δ), not merely O(1/m). + +### PO07 — derived_corollary + +Explicit finite mathematical composition from the recorded immutable declarations; no independently compiled corollary wrapper is claimed. + +**Concrete recipe:** Put A=alpha=m(1−a²)/2>0,L=lambda=m(1−a)>0,y=1−b/2,y₀=(A+6)/(2(A+3)). b_le_alpha gives y≥y₀>0, and b>0 gives y≤1. F(y)=Ay²+6y−6 is increasing on y≥0 and F(y₀)=A³/[4(A+3)²]≥0. Thus 1−y≤Ay²/6. Since A=L(1+a)/2≤L, obtain ≤Ly²/6. Finally 1−y=a(1−x)+(1−a)²/2≥a(1−x), and y²≤1. Divide by a>0 to get 1−x≤L/(6a). + +### PO08 — theorem + +Attribution is Tao/previous beta_le, not a new local discovery. Non-strict form suffices. + +### PO09 — derived_corollary + +Explicit finite mathematical composition from the recorded immutable declarations; no independently compiled corollary wrapper is claimed. + +**Concrete recipe:** With A=alpha>0, b_le_alpha gives y≥y₀=(A+6)/(2(A+3)). F(y)=Ay²+6y−6 satisfies F(y₀)=A³/[4(A+3)²]>0. F is strictly increasing on nonnegative reals and has positive root yG=(sqrt(36+24A)−6)/(2A)=12/(sqrt(36+24A)+6), with F(0)<0yG. This is strict comparison of rational and Gaussian lower bounds, not convergence. + +### IN01 — theorem + +Actual finite integrals; real m≥7 generality is stronger than integer paper premise. + +### IN02 — derived_corollary + +Both exact all-m≥7 historical denominators and endpoint multipliers are retained. The ≤ bounds, as normalized in the original ledger, do not use the looser 116/(m+2),52/(m+2) exported relaxations. + +**Concrete recipe:** For natural m≥7, apply geometry to obtain a/20. Rewrite their left sides by total_eq_budget (ha:00; combine strict inequalities to obtain T0, obtain T5/6 and geometry_ten with λ≤1≤10 for b<4/5. On [1,10] use geometry_ten; on [10,25] use geometry_twentyfive; on [25,49] use geometry_fortynine. In every band λ≤49, halfpoint_mem gives x/(2a)<1, hence x<2a since a>0. Rewrite beta a x 1=b a x with beta_one and weaken strict endpoint bounds to ≤. Cast m to ℝ and apply budget_region_one,two,three,four respectively. These give exactly the four constants; the upper-bound lemmas do not need the lower λ restrictions. + +### RA04 — derived_corollary + +Low strip [1/5,2/5) is now covered by an actual scaled lower bound; it is not inferred from near D. Later-band exact lower comparisons were already present. + +**Concrete recipe:** On [1/5,1], apply scaled_budget_paper_lower_one (the original rational lower expression) and scaled_budget_lower_one (strictly exceeds 1+18/m). On [1,5], apply budget_lower_five. On [5,10], apply budget_lower_ten after weakening 5≤λ to 1≤λ. On [10,25] and [25,49], apply budget_lower_twentyfive and budget_lower_fortynine. These yield respectively lower comparisons with 1+33/m, 1+33/m, 1+51/m+1/4, and 1+62/m+2, exactly the upper bounds in RA03; no λ<2/5 omission. + +### SE01 — theorem + +The recorded immutable source signatures match this inherited theorem family. + +### SE02 — theorem + +The recorded immutable source signatures match this inherited theorem family. + +### SE03 — theorem + +S_bounds gives a/21. Test-only artifact must be in parent replay. + +### DI03 — theorem + +Unfold the Accepted definition recorded in definition_evidence: the same actual conjugate family supplies cardinality, unit-circle norms, actual mean/variance, full complex polar, the literal centered majorant plus Gamma budget, and J>1. This is finite data, not a Sendov counterexample or an all-a theorem. + +### DI04 — theorem + +Unfold the Accepted definition recorded in definition_evidence: the same actual conjugate family supplies cardinality, unit-circle norms, actual mean/variance, full complex polar, the literal centered majorant plus Gamma budget, and J>1. This is finite data, not a Sendov counterexample or an all-a theorem. + +### DI05 — theorem + +Unfold the Accepted definition recorded in definition_evidence: the same actual conjugate family supplies cardinality, unit-circle norms, actual mean/variance, full complex polar, the literal centered majorant plus Gamma budget, and J>1. This is finite data, not a Sendov counterexample or an all-a theorem. + +### DI06 — theorem + +Unfold the Accepted definition recorded in definition_evidence: the same actual conjugate family supplies cardinality, unit-circle norms, actual mean/variance, full complex polar, the literal centered majorant plus Gamma budget, and J>1. This is finite data, not a Sendov counterexample or an all-a theorem. + +### DI07 — theorem + +Unfold the Accepted definition recorded in definition_evidence: the same actual conjugate family supplies cardinality, unit-circle norms, actual mean/variance, full complex polar, the literal centered majorant plus Gamma budget, and J>1. This is finite data, not a Sendov counterexample or an all-a theorem. + +### DI08 — theorem + +Exact rejected x=0.999999986596654, a=1−10^−9, h=10^−9 and upper x=a+100h². Brackets are strict at both endpoints; all-feasible D has no surrogate-budget hypothesis. Root existence between endpoints follows from continuity, and monotonicity makes this a threshold bracket. The approximate gap display is not claimed as an exact constant. + +### DI09 — theorem + +Exact λ-small finite point x=a+3h² with full polar and strict (3/5)h margin, not weakened to h/3. + +### DI10 — theorem + +Both full-polar/direct-T diagnostics at their exact rational triples, separate from the centered budgets DI05/DI07. + +### DI11 — theorem + +The recorded immutable source signatures match this inherited theorem family. + +### DI12 — theorem + +Refutes S≥linear formula, not D and not the possibility of another stronger raw-polar mean estimate. + +### DI13 — theorem + +Current rational lower certificate differs from the paper display; positive gate and full closed interval are exactly covered. + +### DI14 — theorem + +Current lower certificate 155747/10^7 is slightly below the paper interval slack; both prove the advertised positivity. Do not claim equality of certificates. + +### DI15 — theorem + +Both complete closed neighborhoods have actual full-complex-polar witnesses: seven ones; ten alternating conjugate roots with x=93/100 and imaginary part sqrt(1−x²). No mere assumed raw-polar antecedent. + +### DI16 — theorem + +Exact m=64,a=1/2,q≡1 witness and universal-implication refutation. α=24>17 and full-complex K>1. + +### DI17 — theorem + +Unfold p=(X−1)^9(X+1), marked=−1/4. The actual derivative roots are eight copies of 1 and one −4/5; exact reciprocal-square sum 25488/3025<9 and attained nearest distance 11/20. Marked is explicitly NOT a root; no marked-root theorem is refuted. + +### BO01 — theorem + +Includes empty and repeated multisets; no cardinality division. + +### BO02 — theorem + +The recorded immutable source signatures match this inherited theorem family. + +### BO03 — theorem + +The boundary equality classification IS proved; do not conflate with missing general collinear equality. Actual Solution consumption retained. + +### BO04 — theorem + +A finite countermodel family, not ten new universal theorem routes. + +### CO01 — theorem + +The recorded immutable source signatures match this inherited theorem family. + +### CO02 — theorem + +The recorded immutable source signatures match this inherited theorem family. + +### CO03 — theorem + +The recorded immutable source signatures match this inherited theorem family. + +### CO04 — theorem + +The recorded immutable source signatures match this inherited theorem family. + +### CO05 — theorem + +Endpoints a=A,B are allowed; no division by side lengths. + +### CO06 — theorem + +No monic/squarefree/interior assumptions. This is not arbitrary complex-collinear affine transport. + +### CO07 — theorem + +Real inverse zero equals zero, not infinity. + +### EX01 — derived_corollary + +Explicit finite mathematical composition from the recorded immutable declarations; no independently compiled corollary wrapper is claimed. + +**Concrete recipe:** Set m=q.card≥7,r=q−μ,s=|μ|²,c=1−b. centered_variance_le gives v≤1−s. geometry gives c>0; algebra gives s≥x²≥c since x²−c=(x−a)². Hence v/s≤(1−s)/s≤(1−c)/c=b/(1−b). Clear positive denominators in b_le_alpha to obtain b/(1−b)≤alpha/3. Divide by m−1>0 and unfold Gamma=v/((m−1)s) to get Gamma≤alpha/[3(m−1)]. Since alpha=m(1+a)h/2,1+a<2 and m/(m−1)≤7/6, Gamma<7h/18. variance_ratio_le_alpha and Gamma_lt_seven_eighteenths independently export the terminal bounds; the intermediate b/(1−b) comparison is the explicit algebra just given. + +### EX02 — derived_corollary + +Explicit finite mathematical composition from the recorded immutable declarations; no independently compiled corollary wrapper is claimed. + +**Concrete recipe:** Retain the explicit majorant_Efin≤h/2 hypothesis. Add Gamma_lt_seven_eighteenths to obtain E_fin+Gamma0). norm_J_gt_one_of_majorant_half also exports the same conditional conclusion. No global proof of the majorant premise is claimed. + +### EX03 — theorem + +Exact polynomial/derivative factorizations tie q to inverse critical-root distances. The theorem derives positive root-distance product; retains q.card=z.card=m, nonzero leading coefficient/nonzero q, explicit product≤m+1 and arbitrary real r>0. No product hypothesis is silently inserted into D. + +### AS03 — theorem + +Fixed natural m≥1 only. Exact Rmax=U1 formula, right limit 1/(m+1)<1, and one ε excludes every x∈[−1,1]. No uniform moving-degree exclusion. + +### AS05 — theorem + +Entire feasible exponential model with λ>0 and x∈[−1,1]; theorem proves x>1/2, the quadratic inequality and strict limiting budget. Does not assert convergence AS04. + +### HI01 — theorem + +Exact degree, entire λ≤400 band, and quantitative normalized T bound. For HI01, 5011/5000 is exactly 1.0022. + +### HI02 — theorem + +Exact degree, entire λ≤400 band, and quantitative normalized T bound. For HI01, 5011/5000 is exactly 1.0022. + +### HI03 — theorem + +All three original bands are covered at m≥512, including λ up to 64, tail 1/32, and the 18/m and 34/m small-ray terms. + +### HI04 — theorem + +Both original small-a ratios, exact thresholds and domains; the second retains the bulk-complement hypothesis. + +## Remaining non-obtained or incomplete items + +### AS01 — asymptotic_proof_incomplete + +Fixed m, h→0: R=1+m[(m−4)/6−k]h²+O_m(h³), polar root x*=1−(m−4)h/6+O_m(h²) + +Second-order coefficient is given; full controlled remainder and degenerate root existence/uniqueness/asymptotic inversion are not supplied. No uniform-in-m conclusion; no Lean asymptotic theorem found. + +**Disposition:** OPEN: incomplete heuristic calculation, not an obtained-local-proof unit. Explicit correction/reclassification or missing proof still required; this ledger does not perform a user-authorized paper correction. + +**Minimal missing contract / correction:** For each fixed paper degree m, supply a controlled O_m(h³) remainder for the displayed R expansion, and prove existence/uniqueness of the relevant polar-root branch plus its x*=1−(m−4)h/6+O_m(h²) inversion. Alternatively explicitly relabel the displayed expansion/root assertion as heuristic, not a proved result. + +### AS02 — asymptotic_proof_incomplete + +At (a,x)=(1,1), T=1/(m+1), ∂aT=0, ∂xT=−2/(m−2); along polar root B−T=[m/(m+1)−(m−4)/(3(m−2))]h+O_m(h²) + +Derivative values and gap expansion asserted; differentiating the parameter integral, remainder control and root substitution are not fully proved in the report. Positive coefficient is elementary, but not an all-m finite proof. + +**Disposition:** OPEN: incomplete heuristic calculation, not an obtained-local-proof unit. Explicit correction/reclassification or missing proof still required; this ledger does not perform a user-authorized paper correction. + +**Minimal missing contract / correction:** Justify differentiation under the parameter integral at (a,x)=(1,1), establish the stated partial derivatives and a controlled O_m(h²) remainder along an actually proved polar-root branch, then prove the asserted gap expansion. Alternatively explicitly retain it only as heuristic calculation. + +### AS04 — asymptotic_proof_incomplete + +Fixed λ>0, m→∞ with a=1−λ/m: polar integral tends to Gλ(x), mT→1/x² and mB→1+λ + +Only limit formulas are stated; no full convergence proof or uniform domination for the scaled residual/endpoints. Finite Taylor/Laplace results elsewhere prove D without requiring these limits. + +**Disposition:** OPEN: incomplete heuristic calculation, not an obtained-local-proof unit. Explicit correction/reclassification or missing proof still required; this ledger does not perform a user-authorized paper correction. + +**Minimal missing contract / correction:** For each fixed λ>0 and the stated x domain (in particular x>0 for 1/x²), prove convergence of the rescaled finite polar integrals and mT, with appropriate domination/tail control, and mB→1+λ. AS05 is only the limiting-model inequality and does not establish these convergences. Alternatively explicitly classify the limiting formulas as heuristic. + +### DG01 — diagnostic_only + +Floating/high-precision screens, root finding and loss diagnostics suggest D but prove no continuous coverage + +Includes 80/424-point screens, 60/95-digit consistency, weak-ray versus true-root Taylor loss, secant scan counts. No exact mathematical acceptance obligation attaches to every sample or timing; failed floating polar point is separately DI08. + +### OP01 — paper_open + +Full D for every integer m≥7 and all 02/5, U1≥1, F_sec≤0, raw polar feasible. Do not require solving this new mathematics for all obtained proofs; do not retire old endgame. + +### OP02 — paper_open + +Global C-near m≥7,9/10≤a<1, full polar and pointwise ⇒ E_fin+Γ<1−a|μ|; stronger finite remainder target E_fin≤h/2 + +Conditional C-budget is complete; its geometric antecedent is not established uniformly. Also no complete averaged-L² strengthening follows. + +### OP03 — paper_open + +F_sec positivity on the whole remaining domain + +The unconditional universal-positivity variant is actually refuted by a feasible negative gate; gate positivity is only sufficient. No requirement to prove a false statement. + +### OP04 — external_unadopted + +Arbitrary complex-collinear affine transport and general collinear equality classification + +Not locally completed or validated paper proofs; Zhang recovered note STATES and supplies proofs of these externally, so do not call them globally unknown. They remain separate formalization scope only if user includes every downloaded third-party paper. Boundary equality BO03 is already complete. + +**Disposition:** NOT ADOPTED: external-paper material is outside the unchanged obtained-local-proof scope. No claim that the external results are globally unknown or false; expansion would require explicit authorization. + +### OP05 — external_unadopted + +Tao averaged-L² working proof, Zhang explicit huge quadratic threshold, n≥100 suggestion, spectral/interpolation comments + +Working notes flag independent checks; report explicitly does not certify all external mathematical correctness. n≥100 is a suggestion, not proved threshold. Huge explicit threshold is a different averaged-L² theorem, not the local D cutoff. + +**Disposition:** NOT ADOPTED: external-paper material is outside the unchanged obtained-local-proof scope. No claim that the external results are globally unknown or false; expansion would require explicit authorization. + +## Parent replay inclusion + +The following cited test modules are part of the mathematical acceptance evidence, not optional decorations. Parent receipts must cover them and their imports at this source tree. + +- `tests/BoundaryProbe.lean` +- `tests/CollinearRound2Tests.lean` +- `tests/PaperCenteredHundred.lean` +- `tests/PaperConjugateBudgets.lean` +- `tests/PaperLegacyCertificates.lean` +- `tests/PaperPolarCounterexample.lean` +- `tests/PaperPolarDomainWitnesses.lean` +- `tests/PaperSecantNeighborhoods.lean` +- `tests/PaperSecantTests.lean` + +## Source verification limitations + +Exact source signatures and definitions are recorded in `final-acceptance-map.json`. No `.olean` contents, current-index metadata, worker reports, or generated JSON certificates were accepted as replacements for theorem source. The old `acceptance-map.json` was not edited. One optional symbolic-package import was unavailable; the small polynomial coefficient check was instead performed with exact Python integer coefficients, without installing anything. + +**Final disposition:** the 92 obtained-local-proof obligations are mathematically mapped. No minimal missing required theorem contract remains. Full publication/acceptance still needs the three explicit heuristic dispositions and the parent’s exact-tree kernel evidence. diff --git a/docs/paper-formalization/reviews/uniform.md b/docs/paper-formalization/reviews/uniform.md new file mode 100644 index 0000000..96c12a0 --- /dev/null +++ b/docs/paper-formalization/reviews/uniform.md @@ -0,0 +1,99 @@ +# Independent semantic audit — PASS + +**Exact commit:** `1108d11ee7e6c1d231d41c91607745e0330dcbc2` +**Tree:** `b523f240810971abca6ff8eaa0ea500c242d3831` + +## Verdict and evidence boundary + +**PASS** for FULL natural `m ≥ 256` `uniform_D`, its actual large-degree first-origin consumption in `Interior → Conjecture → Solution`, historical `T < 3/5`, and the `m=5,6` norm-J margins. **No actual theorem mismatch found in these targets.** + +All repository source inspected came from immutable `git show :` blobs. This was a read-only semantic review, not a new Lean build or kernel replay. The parent supplied successful exact-candidate compilation/kernel checks and Kernel3/proof-value independence results; I independently inspected theorem types, proof bodies, integral definitions, caller discharge, and the corresponding proof-value audit code. Exact rational arithmetic below was independently executed with Python `Fraction`. Repository status was empty before and after inspection; commit/tree identity was rechecked. No source, build, cache, or remote operation was performed by this review. The only authored file is this report. + +## 1. Public D contract and actual integrals + +`Sendov/Analytic/PaperUniform.lean:150–186` proves, for **every natural** `m ≥ 256`, all real `0 < a < 1` and `−1 ≤ x ≤ 1`, from `RawPolar m a x` alone: + +`PaperTaylor.budget (m : ℝ) a x < 1 − (m : ℝ)*a/((m : ℝ)+1)`. + +The definitions are literal, not assumed approximations: + +- `PaperPolar.lean:24–38`: raw polar is `1 ≤ ∫₀¹ P(t)^(m/2) dt`, with `P(t)=a²+2a(1−a²)xt+(1−a²)²t²`; `raw_kernel_eq` and `rawPolar_iff` identify the existing `Sendov.Ppolar` exactly. +- `PaperTaylor.lean:19–24`: `β(t)=1−2axt+a²t²`; `T=β(1)^(m/2)+ma²∫₀¹ tβ(t)^((m−1)/2)dt`. +- `PaperTwoEnd.lean:24–45`: genuine substitution `u=at` proves `total_eq_budget`, including both factors of `a` from the Jacobian and weight. The endpoint is `Q(x,a)^(m/2)`, not an independently chosen scalar. +- `PaperLaplace.lean:74–126,146–271`: the first and cubic exponential moments have explicit finite-endpoint primitives; interval monotonicity and an actual split at `x/(2a)` establish the sharp bound on this same T. Continuity/integrability, split location, endpoint positivity, and cancellation factors are proved. Only the decaying majorants are extended/bounded, not a growing quadratic integrated to infinity. + +There is no first-origin, polynomial existence, endpoint estimate, tail bound, finite-degree table, `α≤17`, `s<1`, or open-disk assumption in the public D type. Both x-boundaries are retained. Natural odd and even degrees, including exactly 256, use real exponents without parity substitution. + +## 2. Complete all-a partition, including seams + +The actual priority partition in `uniform_D` is: + +| Region selected by the proof | Consumed closure | +|---|---| +| `a ≤ 1/3` | proved `T < 2/3`, then `PaperBulk.direct_budget_small` | +| `1/3 < a ≤ 4/5` | proved retained estimate `T < 16/(ma²)+24/m`, then positive middle cubic | +| `4/5 < a`, `49 ≤ λ` | retained estimate, `large_ray_budget`, and strict `1−a < B` | +| `4/5 < a`, `λ < 49`, `λ ≤ 2/5` | `near_endpoint_D`: `B−T > (1−a)/1000 > 0` | +| `4/5 < a`, `2/5 < λ < 49` | `finite_rays_D` | + +Here `λ=m(1−a)>0`. Thus `a=1/3`, `a=4/5`, `λ=2/5`, and `λ=49` are included; no uncovered seam exists. `finite_rays_D` itself accepts the closed interval `[2/5,49]`, with branches ending at 1, 10, 25, 49. Its `[1,10]` lower-budget proof splits at 5, and the `[1,5]` helper splits at 2, also without an open gap. + +**Intentional difference from round5, not a contract defect:** the first finite-ray interval is `[2/5,1]`, not the report's `[1/5,1]`. The separately proved near theorem covers everything through `2/5`, including the omitted `[1/5,2/5]`. The resulting full D domain is unchanged. This is explicitly documented in `PaperRayGeometry.lean:12–14,202–238`; it does not misstate the narrower helper as the original paper interval. + +The retained middle cubic is proved positive on the entire closed `[1/3,4/5]`, using a positive polynomial decomposition (`PaperBulkAlgebra.lean:17–43`). Strictness is maintained even when the large-ray scalar comparison is non-strict. + +## 3. Analytic estimates are discharged and genuinely consumed + +The source proof chain is: + +- `RawPolar → integral_le_exp / b_le_alpha / geometry` (`PaperPolar.lean:67–158`). +- Exact affine polar integration, logarithmic comparison, and small-delta rational bound prove the global endpoint `E≤4/(m+2)` and `mx²>19/2` (`PaperGlobalPolar.lean:24–79,148–227`). The small-delta branch does not assume an alpha cap. +- Two-endpoint integration proves separated and unrelaxed middle estimates (`PaperTwoEnd.lean:63–113,165–205,207–378`). `PaperUniform.middle_relax` weakens the unrelaxed exponent only under `m≥256`; it does not illicitly strengthen the historical `exp(−k/3)` estimate. +- Fixed rational Taylor lower certificates and proved exponential monotonicity supply the actual tails and global two-thirds/retained bounds (`PaperTail.lean:8–140`; `PaperUniform.lean:24–117`). These are uniform in degree, not sample checks. +- Finite-ray geometry derives its endpoint and x bounds from raw polar. Through λ=25 it uses the proved rational polar estimate; at 49 it proves an exponential integral obstruction and interpolates by convexity (`PaperRayGeometry.lean:38–184`). The altered rational geometry is a valid replacement for the paper's sinh-root route. +- `PaperTail.budget_region_one/two/three/four` apply the sharp Laplace theorem with proved geometry, then `finite_rays_D` composes those strict T upper bounds with independently proved bounds on the true scaled B. Generic helper premises are explicitly discharged at these calls. + +Independent exact arithmetic confirmed all five consumed base budget gaps positive: `4179/164480`, `21851/328960`, `178589/197376`, `205583/263168`, `130417/131584`. The uniform separated/middle comparisons to `2/3` have positive rational gaps `374/2451` and `169/26448` respectively. + +`tests/PaperUniform.lean:56–98` traverses opaque proof **values**, not just types/imports, from the expanded-integral wrapper, checks only standard logical axioms, and requires positive reachability of the global bounds, two-endpoint estimates, tails, bulk, near, all four finite-ray upper/lower consumers, and split geometry. The inspected source bodies establish those same substantive edges. Static scans of the project-local import closures of Uniform, HistoricalBounds, Margins and FirstOriginBudget found no `axiom`, `sorry`, `admit`, `sorryAx`, `native_decide`, `unsafe`, or `implemented_by` tokens outside comments; these scans are supplementary, not substitutes for the parent's kernel checks. + +## 4. Actual Interior and final public wiring + +`FirstOriginBudget.lean:79–99` is a real contradiction consumer: + +1. From `n≥257`, `omega` proves `256≤n−1` in naturals. +2. `Nat.cast_sub` with proved `1≤n` establishes `((n−1 : ℕ) : ℝ)=(n : ℝ)−1`; no truncated-subtraction ambiguity remains. +3. `rawPolar_iff` transports the actual existing polar integral to `RawPolar (n−1) a x`. +4. `uniform_D` gives strict `T32/3`, original `exp(−k/3)` relaxation at valid degrees, and strict fixed Taylor certificate; it is not an inference from the weaker conclusion `T 1` for m=5 and `7103906425351/7000000000000 > 1` for m=6. Their actual J norms are `111111/100000` and `1111111/1000000`, respectively, and satisfy the claimed margins. Thus these hypotheses have concrete closed-disk models and are not strengthened into a contradictory first-origin domain. The same a,x=1 gives raw-feasible examples at m=256 and m=512 as well. + +## Scope conclusion + +No blocker or theorem mismatch in the requested contracts. The difference in the first finite-ray boundary is compensated by a proved overlapping near region, not by an assumption. Historical and norm-J quantitative results remain substantive standalone theorems. This verdict does not assert completion of peripheral diagnostics/rates or the all-paper ledger, and requests no unrelated changes. From 908818f531f255922c7e00f986dbf4ab1b09b128 Mon Sep 17 00:00:00 2001 From: Methode Date: Tue, 15 Sep 2026 00:01:44 -0700 Subject: [PATCH 24/24] [verified] Preserve centered C-near proofs and reproducible research Publish reviewed global paper closure and exact diagnostics while explicitly retaining the incomplete global kernel status. Include checked Lean structural/partial-domain modules, historical research, replay scripts and verified archives. Exclude local dependency and compiler caches. --- .gitattributes | 2 + .gitignore | 10 +- Sendov/Analytic/PaperCenteredEndpoint.lean | 153 + Sendov/Analytic/PaperCenteredTail.lean | 69 + .../PaperCenteredVarianceEndpoint.lean | 61 + research/README.md | 24 + research/centered-global-verified.zip | Bin 0 -> 2651489 bytes .../BinomialMode.lean | 112 + .../CoefficientBound.lean | 67 + .../centered-global-verified/FirstMoment.lean | 81 + .../HISTORICAL_RATIONAL_VERIFICATION.json | 13 + .../LEAN_VERIFICATION.json | 1140 + .../centered-global-verified/MANIFEST.json | 355 + .../centered-global-verified/MODULES.json | 43 + .../PAPER_VERIFICATION.json | 54 + research/centered-global-verified/REPORT.md | 171 + research/centered-global-verified/RESULT.json | 25 + research/centered-global-verified/RESULT.md | 15 + .../SOURCE_ORIGINS.json | 43 + .../Sendov/Analytic/CenteredActualPolar.lean | 139 + .../Sendov/Analytic/CenteredActualTail.lean | 168 + .../Analytic/CenteredBandCertificate.lean | 75 + .../Sendov/Analytic/CenteredBandEndpoint.lean | 69 + .../Sendov/Analytic/CenteredBandScalar.lean | 88 + .../Sendov/Analytic/CenteredBandTail.lean | 124 + .../Sendov/Analytic/CenteredBandTheorem.lean | 87 + .../Analytic/CenteredBernsteinMoment.lean | 119 + .../Sendov/Analytic/CenteredChordGeneral.lean | 122 + .../Analytic/CenteredEndpointMoment.lean | 153 + .../Sendov/Analytic/CenteredMeanBudget.lean | 94 + .../Sendov/Analytic/CenteredMomentAudit.lean | 18 + .../Sendov/Analytic/CenteredNearChord.lean | 92 + .../Sendov/Analytic/CenteredNearEndpoint.lean | 169 + .../Sendov/Analytic/CenteredNearScalar.lean | 77 + .../Sendov/Analytic/CenteredNearTheorem.lean | 93 + .../Analytic/CenteredQuarterActual.lean | 115 + .../Sendov/Analytic/CenteredQuarterAudit.lean | 24 + .../Analytic/CenteredQuarterEndpoint.lean | 103 + .../Analytic/CenteredQuarterScalar.lean | 113 + .../Analytic/CenteredQuarterTheorem.lean | 62 + .../Sendov/Analytic/CenteredThinVariance.lean | 173 + .../Sendov/Analytic/CenteredThirdActual.lean | 63 + .../Analytic/CenteredThirdEndpoint.lean | 62 + .../Sendov/Analytic/CenteredThirdScalar.lean | 177 + .../Sendov/Analytic/CenteredThirdTail.lean | 121 + .../Sendov/Analytic/CenteredThirdTheorem.lean | 84 + .../Analytic/PaperCenteredEndpoint.lean | 153 + .../Sendov/Analytic/PaperCenteredTail.lean | 69 + .../PaperCenteredVarianceEndpoint.lean | 61 + .../Sendov/Analytic/PaperFactorialTail.lean | 295 + .../VERIFICATION_NOTES.md | 6 + research/centered-global-verified/check.py | 59 + .../final-verification.log | 50 + .../historical/centered-verified.zip | Bin 0 -> 2213253 bytes .../interfaces/BAND_INTERFACE.md | 131 + .../interfaces/MOMENT_INTERFACE.md | 123 + .../logs/global-BinomialMode-kernel.json | 18 + .../logs/global-BinomialMode-kernel.log | 0 .../logs/global-BinomialMode.json | 24 + .../logs/global-BinomialMode.log | 3 + .../logs/global-CoefficientBound-kernel.json | 18 + .../logs/global-CoefficientBound-kernel.log | 0 .../logs/global-CoefficientBound.json | 24 + .../logs/global-CoefficientBound.log | 3 + .../logs/global-FirstMoment-kernel.json | 18 + .../logs/global-FirstMoment-kernel.log | 0 .../logs/global-FirstMoment.json | 24 + .../logs/global-FirstMoment.log | 2 + ...v.Analytic.CenteredActualPolar-kernel.json | 18 + ...ov.Analytic.CenteredActualPolar-kernel.log | 0 ...l-Sendov.Analytic.CenteredActualPolar.json | 24 + ...al-Sendov.Analytic.CenteredActualPolar.log | 87 + ...ov.Analytic.CenteredActualTail-kernel.json | 18 + ...dov.Analytic.CenteredActualTail-kernel.log | 0 ...al-Sendov.Analytic.CenteredActualTail.json | 24 + ...bal-Sendov.Analytic.CenteredActualTail.log | 49 + ...alytic.CenteredBandCertificate-kernel.json | 18 + ...nalytic.CenteredBandCertificate-kernel.log | 0 ...ndov.Analytic.CenteredBandCertificate.json | 24 + ...endov.Analytic.CenteredBandCertificate.log | 185 + ....Analytic.CenteredBandEndpoint-kernel.json | 18 + ...v.Analytic.CenteredBandEndpoint-kernel.log | 0 ...-Sendov.Analytic.CenteredBandEndpoint.json | 24 + ...l-Sendov.Analytic.CenteredBandEndpoint.log | 81 + ...ov.Analytic.CenteredBandScalar-kernel.json | 18 + ...dov.Analytic.CenteredBandScalar-kernel.log | 0 ...al-Sendov.Analytic.CenteredBandScalar.json | 24 + ...bal-Sendov.Analytic.CenteredBandScalar.log | 113 + ...ndov.Analytic.CenteredBandTail-kernel.json | 18 + ...endov.Analytic.CenteredBandTail-kernel.log | 0 ...obal-Sendov.Analytic.CenteredBandTail.json | 24 + ...lobal-Sendov.Analytic.CenteredBandTail.log | 118 + ...v.Analytic.CenteredBandTheorem-kernel.json | 18 + ...ov.Analytic.CenteredBandTheorem-kernel.log | 0 ...l-Sendov.Analytic.CenteredBandTheorem.json | 24 + ...al-Sendov.Analytic.CenteredBandTheorem.log | 199 + ...alytic.CenteredBernsteinMoment-kernel.json | 18 + ...nalytic.CenteredBernsteinMoment-kernel.log | 0 ...ndov.Analytic.CenteredBernsteinMoment.json | 24 + ...endov.Analytic.CenteredBernsteinMoment.log | 0 ....Analytic.CenteredChordGeneral-kernel.json | 18 + ...v.Analytic.CenteredChordGeneral-kernel.log | 0 ...-Sendov.Analytic.CenteredChordGeneral.json | 24 + ...l-Sendov.Analytic.CenteredChordGeneral.log | 55 + ...nalytic.CenteredEndpointMoment-kernel.json | 18 + ...Analytic.CenteredEndpointMoment-kernel.log | 0 ...endov.Analytic.CenteredEndpointMoment.json | 24 + ...Sendov.Analytic.CenteredEndpointMoment.log | 0 ...ov.Analytic.CenteredMeanBudget-kernel.json | 18 + ...dov.Analytic.CenteredMeanBudget-kernel.log | 0 ...al-Sendov.Analytic.CenteredMeanBudget.json | 24 + ...bal-Sendov.Analytic.CenteredMeanBudget.log | 75 + ...v.Analytic.CenteredMomentAudit-kernel.json | 18 + ...ov.Analytic.CenteredMomentAudit-kernel.log | 0 ...l-Sendov.Analytic.CenteredMomentAudit.json | 24 + ...al-Sendov.Analytic.CenteredMomentAudit.log | 20 + ...dov.Analytic.CenteredNearChord-kernel.json | 18 + ...ndov.Analytic.CenteredNearChord-kernel.log | 0 ...bal-Sendov.Analytic.CenteredNearChord.json | 24 + ...obal-Sendov.Analytic.CenteredNearChord.log | 0 ....Analytic.CenteredNearEndpoint-kernel.json | 18 + ...v.Analytic.CenteredNearEndpoint-kernel.log | 0 ...-Sendov.Analytic.CenteredNearEndpoint.json | 24 + ...l-Sendov.Analytic.CenteredNearEndpoint.log | 70 + ...ov.Analytic.CenteredNearScalar-kernel.json | 18 + ...dov.Analytic.CenteredNearScalar-kernel.log | 0 ...al-Sendov.Analytic.CenteredNearScalar.json | 24 + ...bal-Sendov.Analytic.CenteredNearScalar.log | 0 ...v.Analytic.CenteredNearTheorem-kernel.json | 18 + ...ov.Analytic.CenteredNearTheorem-kernel.log | 0 ...l-Sendov.Analytic.CenteredNearTheorem.json | 24 + ...al-Sendov.Analytic.CenteredNearTheorem.log | 153 + ...Analytic.CenteredQuarterActual-kernel.json | 18 + ....Analytic.CenteredQuarterActual-kernel.log | 0 ...Sendov.Analytic.CenteredQuarterActual.json | 24 + ...-Sendov.Analytic.CenteredQuarterActual.log | 135 + ....Analytic.CenteredQuarterAudit-kernel.json | 18 + ...v.Analytic.CenteredQuarterAudit-kernel.log | 0 ...-Sendov.Analytic.CenteredQuarterAudit.json | 24 + ...l-Sendov.Analytic.CenteredQuarterAudit.log | 47 + ...alytic.CenteredQuarterEndpoint-kernel.json | 18 + ...nalytic.CenteredQuarterEndpoint-kernel.log | 0 ...ndov.Analytic.CenteredQuarterEndpoint.json | 24 + ...endov.Analytic.CenteredQuarterEndpoint.log | 105 + ...Analytic.CenteredQuarterScalar-kernel.json | 18 + ....Analytic.CenteredQuarterScalar-kernel.log | 0 ...Sendov.Analytic.CenteredQuarterScalar.json | 24 + ...-Sendov.Analytic.CenteredQuarterScalar.log | 111 + ...nalytic.CenteredQuarterTheorem-kernel.json | 18 + ...Analytic.CenteredQuarterTheorem-kernel.log | 0 ...endov.Analytic.CenteredQuarterTheorem.json | 24 + ...Sendov.Analytic.CenteredQuarterTheorem.log | 18 + ....Analytic.CenteredThinVariance-kernel.json | 18 + ...v.Analytic.CenteredThinVariance-kernel.log | 0 ...-Sendov.Analytic.CenteredThinVariance.json | 24 + ...l-Sendov.Analytic.CenteredThinVariance.log | 204 + ...v.Analytic.CenteredThirdActual-kernel.json | 18 + ...ov.Analytic.CenteredThirdActual-kernel.log | 0 ...l-Sendov.Analytic.CenteredThirdActual.json | 24 + ...al-Sendov.Analytic.CenteredThirdActual.log | 22 + ...Analytic.CenteredThirdEndpoint-kernel.json | 18 + ....Analytic.CenteredThirdEndpoint-kernel.log | 0 ...Sendov.Analytic.CenteredThirdEndpoint.json | 24 + ...-Sendov.Analytic.CenteredThirdEndpoint.log | 18 + ...v.Analytic.CenteredThirdScalar-kernel.json | 18 + ...ov.Analytic.CenteredThirdScalar-kernel.log | 0 ...l-Sendov.Analytic.CenteredThirdScalar.json | 24 + ...al-Sendov.Analytic.CenteredThirdScalar.log | 418 + ...dov.Analytic.CenteredThirdTail-kernel.json | 18 + ...ndov.Analytic.CenteredThirdTail-kernel.log | 0 ...bal-Sendov.Analytic.CenteredThirdTail.json | 24 + ...obal-Sendov.Analytic.CenteredThirdTail.log | 55 + ....Analytic.CenteredThirdTheorem-kernel.json | 18 + ...v.Analytic.CenteredThirdTheorem-kernel.log | 0 ...-Sendov.Analytic.CenteredThirdTheorem.json | 24 + ...l-Sendov.Analytic.CenteredThirdTheorem.log | 250 + ...Analytic.PaperCenteredEndpoint-kernel.json | 18 + ....Analytic.PaperCenteredEndpoint-kernel.log | 0 ...Sendov.Analytic.PaperCenteredEndpoint.json | 24 + ...-Sendov.Analytic.PaperCenteredEndpoint.log | 0 ...dov.Analytic.PaperCenteredTail-kernel.json | 18 + ...ndov.Analytic.PaperCenteredTail-kernel.log | 0 ...bal-Sendov.Analytic.PaperCenteredTail.json | 24 + ...obal-Sendov.Analytic.PaperCenteredTail.log | 0 ....PaperCenteredVarianceEndpoint-kernel.json | 18 + ...c.PaperCenteredVarianceEndpoint-kernel.log | 0 ...nalytic.PaperCenteredVarianceEndpoint.json | 24 + ...Analytic.PaperCenteredVarianceEndpoint.log | 0 ...ov.Analytic.PaperFactorialTail-kernel.json | 18 + ...dov.Analytic.PaperFactorialTail-kernel.log | 0 ...al-Sendov.Analytic.PaperFactorialTail.json | 24 + ...bal-Sendov.Analytic.PaperFactorialTail.log | 0 .../global-tests.ActualPolarAudit-kernel.json | 18 + .../global-tests.ActualPolarAudit-kernel.log | 0 .../logs/global-tests.ActualPolarAudit.json | 24 + .../logs/global-tests.ActualPolarAudit.log | 9 + ...global-tests.CenteredBandAudit-kernel.json | 18 + .../global-tests.CenteredBandAudit-kernel.log | 0 .../logs/global-tests.CenteredBandAudit.json | 24 + .../logs/global-tests.CenteredBandAudit.log | 36 + ...global-tests.CenteredNearAudit-kernel.json | 18 + .../global-tests.CenteredNearAudit-kernel.log | 0 .../logs/global-tests.CenteredNearAudit.json | 24 + .../logs/global-tests.CenteredNearAudit.log | 12 + ...ests.CenteredQuarterFinalAudit-kernel.json | 18 + ...tests.CenteredQuarterFinalAudit-kernel.log | 0 ...lobal-tests.CenteredQuarterFinalAudit.json | 24 + ...global-tests.CenteredQuarterFinalAudit.log | 7 + ...global-tests.CenteredThinAudit-kernel.json | 18 + .../global-tests.CenteredThinAudit-kernel.log | 0 .../logs/global-tests.CenteredThinAudit.json | 24 + .../logs/global-tests.CenteredThinAudit.log | 5 + ...lobal-tests.CenteredThirdAudit-kernel.json | 18 + ...global-tests.CenteredThirdAudit-kernel.log | 0 .../logs/global-tests.CenteredThirdAudit.json | 24 + .../logs/global-tests.CenteredThirdAudit.log | 35 + .../global-tests.MeanBudgetAudit-kernel.json | 18 + .../global-tests.MeanBudgetAudit-kernel.log | 0 .../logs/global-tests.MeanBudgetAudit.json | 24 + .../logs/global-tests.MeanBudgetAudit.log | 7 + .../logs/historical-full-rational.log | 24 + ...d-round2-verified_math-bound_verify.py.log | 63 + ...ound2-verified_math-cutoff45_verify.py.log | 66 + ...-round2-verified_math-middle_verify.py.log | 51 + ...ed-round3_diagnostics_certify_chord.py.log | 4 + ...r-centered-round3_math-polar_verify.py.log | 12 + ...centered-round4_math-residual_audit.py.log | 7 + ...entered-round4_math-residual_verify.py.log | 9 + ...aper-centered-round4_review35_audit.py.log | 18 + ...tered-round5_boundary-family_verify.py.log | 2 + ...d5_review-global_independent_checks.py.log | 9 + research/centered-global-verified/pack.py | 37 + .../pack_receipt.json | 7 + .../centered-global-verified/paper-replay.log | 18 + research/centered-global-verified/rebuild.log | 90 + .../receipts/BinomialMode-kernel.json | 7 + .../receipts/BinomialMode.json | 7 + .../receipts/CoefficientBound-kernel.json | 7 + .../receipts/CoefficientBound.json | 7 + .../receipts/FirstMoment-kernel.json | 7 + .../receipts/FirstMoment.json | 7 + ...v.Analytic.CenteredActualPolar-kernel.json | 7 + .../Sendov.Analytic.CenteredActualPolar.json | 7 + ...ov.Analytic.CenteredActualTail-kernel.json | 7 + .../Sendov.Analytic.CenteredActualTail.json | 7 + ...alytic.CenteredBandCertificate-kernel.json | 7 + ...ndov.Analytic.CenteredBandCertificate.json | 7 + ....Analytic.CenteredBandEndpoint-kernel.json | 7 + .../Sendov.Analytic.CenteredBandEndpoint.json | 7 + ...ov.Analytic.CenteredBandScalar-kernel.json | 7 + .../Sendov.Analytic.CenteredBandScalar.json | 7 + ...ndov.Analytic.CenteredBandTail-kernel.json | 7 + .../Sendov.Analytic.CenteredBandTail.json | 7 + ...v.Analytic.CenteredBandTheorem-kernel.json | 7 + .../Sendov.Analytic.CenteredBandTheorem.json | 7 + ...alytic.CenteredBernsteinMoment-kernel.json | 7 + ...ndov.Analytic.CenteredBernsteinMoment.json | 7 + ....Analytic.CenteredChordGeneral-kernel.json | 7 + .../Sendov.Analytic.CenteredChordGeneral.json | 7 + ...nalytic.CenteredEndpointMoment-kernel.json | 7 + ...endov.Analytic.CenteredEndpointMoment.json | 7 + ...ov.Analytic.CenteredMeanBudget-kernel.json | 7 + .../Sendov.Analytic.CenteredMeanBudget.json | 7 + ...v.Analytic.CenteredMomentAudit-kernel.json | 7 + .../Sendov.Analytic.CenteredMomentAudit.json | 7 + ...dov.Analytic.CenteredNearChord-kernel.json | 7 + .../Sendov.Analytic.CenteredNearChord.json | 7 + ....Analytic.CenteredNearEndpoint-kernel.json | 7 + .../Sendov.Analytic.CenteredNearEndpoint.json | 7 + ...ov.Analytic.CenteredNearScalar-kernel.json | 7 + .../Sendov.Analytic.CenteredNearScalar.json | 7 + ...v.Analytic.CenteredNearTheorem-kernel.json | 7 + .../Sendov.Analytic.CenteredNearTheorem.json | 7 + ...Analytic.CenteredQuarterActual-kernel.json | 7 + ...Sendov.Analytic.CenteredQuarterActual.json | 7 + ....Analytic.CenteredQuarterAudit-kernel.json | 7 + .../Sendov.Analytic.CenteredQuarterAudit.json | 7 + ...alytic.CenteredQuarterEndpoint-kernel.json | 7 + ...ndov.Analytic.CenteredQuarterEndpoint.json | 7 + ...Analytic.CenteredQuarterScalar-kernel.json | 7 + ...Sendov.Analytic.CenteredQuarterScalar.json | 7 + ...nalytic.CenteredQuarterTheorem-kernel.json | 7 + ...endov.Analytic.CenteredQuarterTheorem.json | 7 + ....Analytic.CenteredThinVariance-kernel.json | 7 + .../Sendov.Analytic.CenteredThinVariance.json | 7 + ...v.Analytic.CenteredThirdActual-kernel.json | 7 + .../Sendov.Analytic.CenteredThirdActual.json | 7 + ...Analytic.CenteredThirdEndpoint-kernel.json | 7 + ...Sendov.Analytic.CenteredThirdEndpoint.json | 7 + ...v.Analytic.CenteredThirdScalar-kernel.json | 7 + .../Sendov.Analytic.CenteredThirdScalar.json | 7 + ...dov.Analytic.CenteredThirdTail-kernel.json | 7 + .../Sendov.Analytic.CenteredThirdTail.json | 7 + ....Analytic.CenteredThirdTheorem-kernel.json | 7 + .../Sendov.Analytic.CenteredThirdTheorem.json | 7 + ...Analytic.PaperCenteredEndpoint-kernel.json | 7 + ...Sendov.Analytic.PaperCenteredEndpoint.json | 7 + ...dov.Analytic.PaperCenteredTail-kernel.json | 7 + .../Sendov.Analytic.PaperCenteredTail.json | 7 + ....PaperCenteredVarianceEndpoint-kernel.json | 7 + ...nalytic.PaperCenteredVarianceEndpoint.json | 7 + ...ov.Analytic.PaperFactorialTail-kernel.json | 7 + .../Sendov.Analytic.PaperFactorialTail.json | 7 + .../tests.ActualPolarAudit-kernel.json | 7 + .../receipts/tests.ActualPolarAudit.json | 7 + .../tests.CenteredBandAudit-kernel.json | 7 + .../receipts/tests.CenteredBandAudit.json | 7 + .../tests.CenteredNearAudit-kernel.json | 7 + .../receipts/tests.CenteredNearAudit.json | 7 + ...ests.CenteredQuarterFinalAudit-kernel.json | 7 + .../tests.CenteredQuarterFinalAudit.json | 7 + .../tests.CenteredThinAudit-kernel.json | 7 + .../receipts/tests.CenteredThinAudit.json | 7 + .../tests.CenteredThirdAudit-kernel.json | 7 + .../receipts/tests.CenteredThirdAudit.json | 7 + .../tests.MeanBudgetAudit-kernel.json | 7 + .../receipts/tests.MeanBudgetAudit.json | 7 + .../math-bound/PROOF.md | 448 + .../math-bound/verify.py | 187 + .../math-cutoff45/PROOF.md | 504 + .../math-cutoff45/verify.py | 295 + .../math-middle/PROOF.md | 449 + .../math-middle/verify.py | 100 + .../diagnostics/certify_chord.py | 49 + .../diagnostics/chord_obstruction.json | 56 + .../diagnostics/rational_support.py | 95 + .../centered-round3/math-polar/PROOF.md | 401 + .../math-polar/cache/exact-verification.json | 317 + .../centered-round3/math-polar/verify.py | 88 + .../centered-round4/math-residual/PROOF.md | 341 + .../centered-round4/math-residual/audit.py | 88 + .../cache/exact-verification.json | 1245 + .../cache/independent-audit.json | 482 + .../centered-round4/math-residual/verify.py | 123 + .../centered-round4/review35/AUDIT.md | 163 + .../centered-round4/review35/ISSUES.md | 48 + .../centered-round4/review35/audit.py | 208 + .../review35/cache/exact-verification.json | 317 + .../centered-round4/review35/evidence.json | 1352 + .../review35/source-replay.json | 12 + .../centered-round5/boundary-family/NOTE.md | 61 + .../boundary-family/RESULT.json | 201 + .../centered-round5/boundary-family/verify.py | 55 + .../centered-round5/review-global/AUDIT.md | 153 + .../centered-round5/review-global/ISSUES.md | 37 + .../cache/exact-verification.json | 1245 + .../cache/independent-audit.json | 482 + .../review-global/evidence.json | 1392 + .../review-global/independent_checks.py | 259 + .../review-global/source-replay.json | 6 + .../research/centered-verified/MATH_NOTE.md | 157 + .../tests/ActualPolarAudit.lean | 8 + .../tests/CenteredBandAudit.lean | 25 + .../tests/CenteredNearAudit.lean | 13 + .../tests/CenteredQuarterFinalAudit.lean | 6 + .../tests/CenteredThinAudit.lean | 6 + .../tests/CenteredThirdAudit.lean | 25 + .../tests/MeanBudgetAudit.lean | 8 + .../centered-global-verified/verification.log | 49 + research/centered-global-verified/verify.py | 22 + .../centered-global-verified/verify_lean.py | 37 + .../centered-global-verified/verify_paper.py | 35 + research/centered-round2-verified.zip | Bin 0 -> 171813 bytes .../BinomialMode.lean | 112 + .../CoefficientBound.lean | 67 + .../centered-round2-verified/FirstMoment.lean | 81 + .../centered-round2-verified/MANIFEST.json | 180 + .../centered-round2-verified/NEAR_PROOF.md | 106 + research/centered-round2-verified/REPORT.md | 178 + research/centered-round2-verified/RESULT.json | 319 + research/centered-round2-verified/RESULT.md | 31 + .../Sendov/Analytic/CenteredActualTail.lean | 168 + .../Sendov/Analytic/CenteredChordGeneral.lean | 122 + .../Sendov/Analytic/CenteredNearChord.lean | 92 + .../Sendov/Analytic/CenteredNearEndpoint.lean | 169 + .../Sendov/Analytic/CenteredNearScalar.lean | 77 + .../Sendov/Analytic/CenteredNearTheorem.lean | 93 + .../Analytic/CenteredQuarterActual.lean | 115 + .../Sendov/Analytic/CenteredQuarterAudit.lean | 24 + .../Analytic/CenteredQuarterEndpoint.lean | 103 + .../Analytic/CenteredQuarterScalar.lean | 113 + .../Analytic/CenteredQuarterTheorem.lean | 62 + .../Sendov/Analytic/CenteredThinVariance.lean | 173 + .../Analytic/PaperCenteredEndpoint.lean | 153 + .../Sendov/Analytic/PaperCenteredTail.lean | 69 + .../PaperCenteredVarianceEndpoint.lean | 61 + .../Sendov/Analytic/PaperFactorialTail.lean | 295 + research/centered-round2-verified/check.py | 22 + .../cutoff_verification.log | 66 + .../intermediate_witness.json | 50 + .../logs/round2-BinomialMode-kernel.json | 18 + .../logs/round2-BinomialMode-kernel.log | 0 .../logs/round2-BinomialMode.json | 24 + .../logs/round2-BinomialMode.log | 3 + .../logs/round2-CoefficientBound-kernel.json | 18 + .../logs/round2-CoefficientBound-kernel.log | 0 .../logs/round2-CoefficientBound.json | 24 + .../logs/round2-CoefficientBound.log | 3 + .../logs/round2-FirstMoment-kernel.json | 18 + .../logs/round2-FirstMoment-kernel.log | 0 .../logs/round2-FirstMoment.json | 24 + .../logs/round2-FirstMoment.log | 2 + ...ov.Analytic.CenteredActualTail-kernel.json | 18 + ...dov.Analytic.CenteredActualTail-kernel.log | 0 ...d2-Sendov.Analytic.CenteredActualTail.json | 24 + ...nd2-Sendov.Analytic.CenteredActualTail.log | 49 + ....Analytic.CenteredChordGeneral-kernel.json | 18 + ...v.Analytic.CenteredChordGeneral-kernel.log | 0 ...-Sendov.Analytic.CenteredChordGeneral.json | 24 + ...2-Sendov.Analytic.CenteredChordGeneral.log | 55 + ...dov.Analytic.CenteredNearChord-kernel.json | 18 + ...ndov.Analytic.CenteredNearChord-kernel.log | 0 ...nd2-Sendov.Analytic.CenteredNearChord.json | 24 + ...und2-Sendov.Analytic.CenteredNearChord.log | 0 ....Analytic.CenteredNearEndpoint-kernel.json | 18 + ...v.Analytic.CenteredNearEndpoint-kernel.log | 0 ...-Sendov.Analytic.CenteredNearEndpoint.json | 24 + ...2-Sendov.Analytic.CenteredNearEndpoint.log | 70 + ...ov.Analytic.CenteredNearScalar-kernel.json | 18 + ...dov.Analytic.CenteredNearScalar-kernel.log | 0 ...d2-Sendov.Analytic.CenteredNearScalar.json | 24 + ...nd2-Sendov.Analytic.CenteredNearScalar.log | 0 ...v.Analytic.CenteredNearTheorem-kernel.json | 18 + ...ov.Analytic.CenteredNearTheorem-kernel.log | 0 ...2-Sendov.Analytic.CenteredNearTheorem.json | 24 + ...d2-Sendov.Analytic.CenteredNearTheorem.log | 153 + ...Analytic.CenteredQuarterActual-kernel.json | 18 + ....Analytic.CenteredQuarterActual-kernel.log | 0 ...Sendov.Analytic.CenteredQuarterActual.json | 24 + ...-Sendov.Analytic.CenteredQuarterActual.log | 135 + ....Analytic.CenteredQuarterAudit-kernel.json | 18 + ...v.Analytic.CenteredQuarterAudit-kernel.log | 0 ...-Sendov.Analytic.CenteredQuarterAudit.json | 24 + ...2-Sendov.Analytic.CenteredQuarterAudit.log | 47 + ...alytic.CenteredQuarterEndpoint-kernel.json | 18 + ...nalytic.CenteredQuarterEndpoint-kernel.log | 0 ...ndov.Analytic.CenteredQuarterEndpoint.json | 24 + ...endov.Analytic.CenteredQuarterEndpoint.log | 105 + ...Analytic.CenteredQuarterScalar-kernel.json | 18 + ....Analytic.CenteredQuarterScalar-kernel.log | 0 ...Sendov.Analytic.CenteredQuarterScalar.json | 24 + ...-Sendov.Analytic.CenteredQuarterScalar.log | 111 + ...nalytic.CenteredQuarterTheorem-kernel.json | 18 + ...Analytic.CenteredQuarterTheorem-kernel.log | 0 ...endov.Analytic.CenteredQuarterTheorem.json | 24 + ...Sendov.Analytic.CenteredQuarterTheorem.log | 18 + ....Analytic.CenteredThinVariance-kernel.json | 18 + ...v.Analytic.CenteredThinVariance-kernel.log | 0 ...-Sendov.Analytic.CenteredThinVariance.json | 24 + ...2-Sendov.Analytic.CenteredThinVariance.log | 204 + ...Analytic.PaperCenteredEndpoint-kernel.json | 18 + ....Analytic.PaperCenteredEndpoint-kernel.log | 0 ...Sendov.Analytic.PaperCenteredEndpoint.json | 24 + ...-Sendov.Analytic.PaperCenteredEndpoint.log | 0 ...dov.Analytic.PaperCenteredTail-kernel.json | 18 + ...ndov.Analytic.PaperCenteredTail-kernel.log | 0 ...nd2-Sendov.Analytic.PaperCenteredTail.json | 24 + ...und2-Sendov.Analytic.PaperCenteredTail.log | 0 ....PaperCenteredVarianceEndpoint-kernel.json | 18 + ...c.PaperCenteredVarianceEndpoint-kernel.log | 0 ...nalytic.PaperCenteredVarianceEndpoint.json | 24 + ...Analytic.PaperCenteredVarianceEndpoint.log | 0 ...ov.Analytic.PaperFactorialTail-kernel.json | 18 + ...dov.Analytic.PaperFactorialTail-kernel.log | 0 ...d2-Sendov.Analytic.PaperFactorialTail.json | 24 + ...nd2-Sendov.Analytic.PaperFactorialTail.log | 0 ...round2-tests.CenteredNearAudit-kernel.json | 18 + .../round2-tests.CenteredNearAudit-kernel.log | 0 .../logs/round2-tests.CenteredNearAudit.json | 24 + .../logs/round2-tests.CenteredNearAudit.log | 12 + ...ests.CenteredQuarterFinalAudit-kernel.json | 18 + ...tests.CenteredQuarterFinalAudit-kernel.log | 0 ...ound2-tests.CenteredQuarterFinalAudit.json | 24 + ...round2-tests.CenteredQuarterFinalAudit.log | 7 + ...round2-tests.CenteredThinAudit-kernel.json | 18 + .../round2-tests.CenteredThinAudit-kernel.log | 0 .../logs/round2-tests.CenteredThinAudit.json | 24 + .../logs/round2-tests.CenteredThinAudit.log | 5 + .../math-bound/PROOF.md | 448 + .../math-bound/RESULT.md | 32 + .../math-bound/VERIFICATION.txt | 29 + .../math-bound/verify.py | 187 + .../math-cutoff45/PROOF.md | 504 + .../math-cutoff45/verify.py | 295 + .../math-middle/PROOF.md | 449 + .../math-middle/verification.json | 7 + .../math-middle/verify.py | 100 + .../middle_verification.log | 51 + research/centered-round2-verified/pack.py | 27 + .../pack_receipt.json | 7 + .../paper_verification.log | 63 + research/centered-round2-verified/rebuild.log | 1095 + .../receipts/BinomialMode-kernel.json | 6 + .../receipts/BinomialMode.json | 6 + .../receipts/CoefficientBound-kernel.json | 6 + .../receipts/CoefficientBound.json | 6 + .../receipts/FirstMoment-kernel.json | 6 + .../receipts/FirstMoment.json | 6 + ...ov.Analytic.CenteredActualTail-kernel.json | 6 + .../Sendov.Analytic.CenteredActualTail.json | 6 + ....Analytic.CenteredChordGeneral-kernel.json | 6 + .../Sendov.Analytic.CenteredChordGeneral.json | 6 + ...dov.Analytic.CenteredNearChord-kernel.json | 6 + .../Sendov.Analytic.CenteredNearChord.json | 6 + ....Analytic.CenteredNearEndpoint-kernel.json | 6 + .../Sendov.Analytic.CenteredNearEndpoint.json | 6 + ...ov.Analytic.CenteredNearScalar-kernel.json | 6 + .../Sendov.Analytic.CenteredNearScalar.json | 6 + ...v.Analytic.CenteredNearTheorem-kernel.json | 6 + .../Sendov.Analytic.CenteredNearTheorem.json | 6 + ...Analytic.CenteredQuarterActual-kernel.json | 6 + ...Sendov.Analytic.CenteredQuarterActual.json | 6 + ....Analytic.CenteredQuarterAudit-kernel.json | 6 + .../Sendov.Analytic.CenteredQuarterAudit.json | 6 + ...alytic.CenteredQuarterEndpoint-kernel.json | 6 + ...ndov.Analytic.CenteredQuarterEndpoint.json | 6 + ...Analytic.CenteredQuarterScalar-kernel.json | 6 + ...Sendov.Analytic.CenteredQuarterScalar.json | 6 + ...nalytic.CenteredQuarterTheorem-kernel.json | 6 + ...endov.Analytic.CenteredQuarterTheorem.json | 6 + ....Analytic.CenteredThinVariance-kernel.json | 6 + .../Sendov.Analytic.CenteredThinVariance.json | 6 + ...Analytic.PaperCenteredEndpoint-kernel.json | 6 + ...Sendov.Analytic.PaperCenteredEndpoint.json | 6 + ...dov.Analytic.PaperCenteredTail-kernel.json | 6 + .../Sendov.Analytic.PaperCenteredTail.json | 6 + ....PaperCenteredVarianceEndpoint-kernel.json | 6 + ...nalytic.PaperCenteredVarianceEndpoint.json | 6 + ...ov.Analytic.PaperFactorialTail-kernel.json | 6 + .../Sendov.Analytic.PaperFactorialTail.json | 6 + .../tests.CenteredNearAudit-kernel.json | 6 + .../receipts/tests.CenteredNearAudit.json | 6 + ...ests.CenteredQuarterFinalAudit-kernel.json | 6 + .../tests.CenteredQuarterFinalAudit.json | 6 + .../tests.CenteredThinAudit-kernel.json | 6 + .../receipts/tests.CenteredThinAudit.json | 6 + .../support/rational.py | 95 + .../tests/CenteredNearAudit.lean | 13 + .../tests/CenteredQuarterFinalAudit.lean | 6 + .../tests/CenteredThinAudit.lean | 6 + .../verify_intermediate_witness.py | 22 + .../centered-round2-verified/verify_round2.py | 46 + .../witness_verification.log | 1 + research/centered-round2/BinomialMode.lean | 112 + .../centered-round2/CoefficientBound.lean | 67 + research/centered-round2/FirstMoment.lean | 81 + research/centered-round2/NEAR_PROOF.md | 106 + research/centered-round2/REPORT.md | 13 + research/centered-round2/RESULT.json | 277 + .../Sendov/Analytic/CenteredActualTail.lean | 168 + .../Sendov/Analytic/CenteredChordGeneral.lean | 122 + .../Sendov/Analytic/CenteredNearChord.lean | 92 + .../Sendov/Analytic/CenteredNearEndpoint.lean | 169 + .../Sendov/Analytic/CenteredNearScalar.lean | 77 + .../Sendov/Analytic/CenteredNearTheorem.lean | 93 + .../Analytic/CenteredQuarterActual.lean | 115 + .../Sendov/Analytic/CenteredQuarterAudit.lean | 24 + .../Analytic/CenteredQuarterEndpoint.lean | 103 + .../Analytic/CenteredQuarterScalar.lean | 113 + .../Analytic/CenteredQuarterTheorem.lean | 62 + .../Sendov/Analytic/CenteredThinVariance.lean | 173 + .../Analytic/PaperCenteredEndpoint.lean | 153 + .../Sendov/Analytic/PaperCenteredTail.lean | 69 + .../PaperCenteredVarianceEndpoint.lean | 61 + .../Sendov/Analytic/PaperFactorialTail.lean | 295 + research/centered-round2/check.py | 22 + .../centered-round2/intermediate_witness.json | 50 + .../lean-mode/BinomialMode.lean | 112 + .../lean-mode/CoefficientBound.lean | 67 + .../lean-mode/FirstMoment.lean | 81 + research/centered-round2/lean-mode/README.md | 79 + .../centered-round2/lean-mode/VERIFIED.json | 46 + research/centered-round2/lean-mode/run.py | 16 + research/centered-round2/lean-mode/verify.py | 43 + .../centered-round2/lean-quarter/README.md | 84 + .../Analytic/CenteredQuarterActual.lean | 115 + .../Sendov/Analytic/CenteredQuarterAudit.lean | 24 + .../Analytic/CenteredQuarterEndpoint.lean | 103 + .../Analytic/CenteredQuarterScalar.lean | 113 + .../lean-quarter/receipts/acceptance.json | 349 + .../lean-quarter/receipts/overlay.json | 4 + .../lean-quarter/verify_receipts.py | 87 + research/centered-round2/lean-tail/README.md | 123 + .../Sendov/Analytic/PaperFactorialTail.lean | 295 + .../centered-round2/lean-tail/TailAudit.lean | 28 + .../lean-tail/verification.json | 114 + research/centered-round2/lean-tail/verify.py | 67 + research/centered-round2/math-bound/PROOF.md | 448 + research/centered-round2/math-bound/RESULT.md | 32 + .../math-bound/VERIFICATION.txt | 29 + research/centered-round2/math-bound/verify.py | 187 + .../centered-round2/math-cutoff45/PROOF.md | 504 + .../centered-round2/math-cutoff45/verify.py | 295 + research/centered-round2/math-middle/PROOF.md | 449 + .../math-middle/verification.json | 7 + .../centered-round2/math-middle/verify.py | 100 + .../centered-round2/middle_verification.log | 51 + .../centered-round2/paper_verification.log | 63 + .../receipts/BinomialMode-kernel.json | 6 + .../receipts/BinomialMode.json | 6 + .../receipts/CoefficientBound-kernel.json | 6 + .../receipts/CoefficientBound.json | 6 + .../receipts/FirstMoment-kernel.json | 6 + .../centered-round2/receipts/FirstMoment.json | 6 + ...ov.Analytic.CenteredActualTail-kernel.json | 6 + .../Sendov.Analytic.CenteredActualTail.json | 6 + ....Analytic.CenteredChordGeneral-kernel.json | 6 + .../Sendov.Analytic.CenteredChordGeneral.json | 6 + ...dov.Analytic.CenteredNearChord-kernel.json | 6 + .../Sendov.Analytic.CenteredNearChord.json | 6 + ....Analytic.CenteredNearEndpoint-kernel.json | 6 + .../Sendov.Analytic.CenteredNearEndpoint.json | 6 + ...ov.Analytic.CenteredNearScalar-kernel.json | 6 + .../Sendov.Analytic.CenteredNearScalar.json | 6 + ...v.Analytic.CenteredNearTheorem-kernel.json | 6 + .../Sendov.Analytic.CenteredNearTheorem.json | 6 + ...Analytic.CenteredQuarterActual-kernel.json | 6 + ...Sendov.Analytic.CenteredQuarterActual.json | 6 + ....Analytic.CenteredQuarterAudit-kernel.json | 6 + .../Sendov.Analytic.CenteredQuarterAudit.json | 6 + ...alytic.CenteredQuarterEndpoint-kernel.json | 6 + ...ndov.Analytic.CenteredQuarterEndpoint.json | 6 + ...Analytic.CenteredQuarterScalar-kernel.json | 6 + ...Sendov.Analytic.CenteredQuarterScalar.json | 6 + ...nalytic.CenteredQuarterTheorem-kernel.json | 6 + ...endov.Analytic.CenteredQuarterTheorem.json | 6 + ....Analytic.CenteredThinVariance-kernel.json | 6 + .../Sendov.Analytic.CenteredThinVariance.json | 6 + ...ov.Analytic.PaperFactorialTail-kernel.json | 6 + .../Sendov.Analytic.PaperFactorialTail.json | 6 + .../tests.CenteredNearAudit-kernel.json | 6 + .../receipts/tests.CenteredNearAudit.json | 6 + ...ests.CenteredQuarterFinalAudit-kernel.json | 6 + .../tests.CenteredQuarterFinalAudit.json | 6 + .../tests.CenteredThinAudit-kernel.json | 6 + .../receipts/tests.CenteredThinAudit.json | 6 + research/centered-round2/support/rational.py | 95 + .../tests/CenteredNearAudit.lean | 13 + .../tests/CenteredQuarterFinalAudit.lean | 6 + .../tests/CenteredThinAudit.lean | 6 + .../verify_intermediate_witness.py | 22 + research/centered-round2/verify_round2.py | 46 + .../centered-round2/witness_verification.log | 1 + research/centered-round3/REPORT.md | 90 + research/centered-round3/RESULT.json | 27 + .../diagnostics/certify_chord.py | 49 + .../diagnostics/chord-stable.log | 6 + .../centered-round3/diagnostics/chord.log | 12 + .../diagnostics/chord_obstruction.json | 56 + .../diagnostics/chord_probe.py | 26 + .../diagnostics/chord_results.json | 194 + .../diagnostics/high_precision.json | 698 + .../diagnostics/rational_support.py | 95 + .../centered-round3/diagnostics/relaxation.py | 61 + .../diagnostics/relaxation_results.json | 410 + .../centered-round3/diagnostics/replay.py | 44 + .../centered-round3/diagnostics/search.log | 13 + .../Sendov/Analytic/CenteredMeanBudget.lean | 94 + .../Sendov/Analytic/CenteredThirdActual.lean | 63 + .../Analytic/CenteredThirdEndpoint.lean | 62 + .../Sendov/Analytic/CenteredThirdScalar.lean | 177 + .../Sendov/Analytic/CenteredThirdTail.lean | 121 + .../Sendov/Analytic/CenteredThirdTheorem.lean | 84 + .../integrated/VERIFICATION.json | 124 + research/centered-round3/integrated/check.py | 59 + .../integrated/integration.log | 26 + ...ov.Analytic.CenteredMeanBudget-kernel.json | 7 + .../Sendov.Analytic.CenteredMeanBudget.json | 7 + ...v.Analytic.CenteredThirdActual-kernel.json | 7 + .../Sendov.Analytic.CenteredThirdActual.json | 7 + ...Analytic.CenteredThirdEndpoint-kernel.json | 7 + ...Sendov.Analytic.CenteredThirdEndpoint.json | 7 + ...v.Analytic.CenteredThirdScalar-kernel.json | 7 + .../Sendov.Analytic.CenteredThirdScalar.json | 7 + ...dov.Analytic.CenteredThirdTail-kernel.json | 7 + .../Sendov.Analytic.CenteredThirdTail.json | 7 + ....Analytic.CenteredThirdTheorem-kernel.json | 7 + .../Sendov.Analytic.CenteredThirdTheorem.json | 7 + .../tests.CenteredThirdAudit-kernel.json | 7 + .../receipts/tests.CenteredThirdAudit.json | 7 + .../tests.MeanBudgetAudit-kernel.json | 7 + .../receipts/tests.MeanBudgetAudit.json | 7 + .../integrated/tests/CenteredThirdAudit.lean | 25 + .../integrated/tests/MeanBudgetAudit.lean | 8 + research/centered-round3/integrated/verify.py | 41 + .../Sendov/Analytic/CenteredMeanBudget.lean | 94 + .../centered-round3/lean-geometry/check.py | 22 + ...ov.Analytic.CenteredMeanBudget-kernel.json | 6 + .../Sendov.Analytic.CenteredMeanBudget.json | 6 + .../tests.MeanBudgetAudit-kernel.json | 6 + .../receipts/tests.MeanBudgetAudit.json | 6 + .../lean-geometry/tests/MeanBudgetAudit.lean | 8 + research/centered-round3/lean-third/REPORT.md | 90 + .../Sendov/Analytic/CenteredThirdActual.lean | 63 + .../Analytic/CenteredThirdEndpoint.lean | 62 + .../Sendov/Analytic/CenteredThirdScalar.lean | 177 + .../Sendov/Analytic/CenteredThirdTail.lean | 121 + .../Sendov/Analytic/CenteredThirdTheorem.lean | 84 + .../lean-third/VERIFICATION.json | 116 + .../centered-round3/lean-third/WORKFLOW.md | 28 + research/centered-round3/lean-third/check.py | 59 + ...v.Analytic.CenteredThirdActual-kernel.json | 7 + .../Sendov.Analytic.CenteredThirdActual.json | 7 + ...Analytic.CenteredThirdEndpoint-kernel.json | 7 + ...Sendov.Analytic.CenteredThirdEndpoint.json | 7 + ...v.Analytic.CenteredThirdScalar-kernel.json | 7 + .../Sendov.Analytic.CenteredThirdScalar.json | 7 + ...dov.Analytic.CenteredThirdTail-kernel.json | 7 + .../Sendov.Analytic.CenteredThirdTail.json | 7 + ....Analytic.CenteredThirdTheorem-kernel.json | 7 + .../Sendov.Analytic.CenteredThirdTheorem.json | 7 + .../tests.CenteredThirdAudit-kernel.json | 7 + .../receipts/tests.CenteredThirdAudit.json | 7 + research/centered-round3/lean-third/replay.py | 79 + .../lean-third/tests/CenteredThirdAudit.lean | 25 + research/centered-round3/math-polar/PROOF.md | 401 + research/centered-round3/math-polar/REPORT.md | 55 + .../math-polar/cache/exact-verification.json | 317 + .../math-polar/cache/tail-comparison.json | 30 + .../centered-round3/math-polar/chord_probe.py | 14 + .../centered-round3/math-polar/compare.py | 44 + .../math-polar/moment-bernstein.json | 188 + .../math-polar/probe-results.json | 98 + research/centered-round3/math-polar/probe.py | 53 + research/centered-round3/math-polar/verify.py | 88 + research/centered-round4/lean-polar/REPORT.md | 24 + .../Sendov/Analytic/CenteredActualPolar.lean | 139 + .../lean-polar/VERIFICATION.json | 37 + .../lean-polar/audit-kernel.log | 2 + research/centered-round4/lean-polar/audit.log | 11 + research/centered-round4/lean-polar/check.py | 59 + .../centered-round4/lean-polar/compile.log | 89 + .../centered-round4/lean-polar/kernel.log | 2 + ...v.Analytic.CenteredActualPolar-kernel.json | 7 + .../Sendov.Analytic.CenteredActualPolar.json | 7 + .../tests.ActualPolarAudit-kernel.json | 7 + .../receipts/tests.ActualPolarAudit.json | 7 + .../lean-polar/tests/ActualPolarAudit.lean | 8 + .../centered-round4/math-residual/PROOF.md | 341 + .../centered-round4/math-residual/REPORT.md | 75 + .../centered-round4/math-residual/audit.py | 88 + .../cache/exact-verification.json | 1245 + .../cache/independent-audit.json | 482 + .../math-residual/explore.json | 102 + .../centered-round4/math-residual/explore.py | 32 + .../centered-round4/math-residual/verify.py | 123 + research/centered-round4/review35/AUDIT.md | 163 + research/centered-round4/review35/ISSUES.md | 48 + research/centered-round4/review35/audit.py | 208 + .../review35/cache/exact-verification.json | 317 + .../centered-round4/review35/evidence.json | 1353 + .../review35/source-replay.json | 12 + research/centered-round5/REPORT.md | 16 + research/centered-round5/RESULT.json | 26 + .../centered-round5/boundary-family/NOTE.md | 61 + .../boundary-family/RESULT.json | 201 + .../centered-round5/boundary-family/verify.py | 55 + research/centered-round5/lean-band/REPORT.md | 131 + .../Analytic/CenteredBandCertificate.lean | 75 + .../Sendov/Analytic/CenteredBandEndpoint.lean | 69 + .../Sendov/Analytic/CenteredBandScalar.lean | 88 + .../Sendov/Analytic/CenteredBandTail.lean | 124 + .../Sendov/Analytic/CenteredBandTheorem.lean | 87 + research/centered-round5/lean-band/check.py | 59 + ...alytic.CenteredBandCertificate-kernel.json | 7 + ...ndov.Analytic.CenteredBandCertificate.json | 7 + ....Analytic.CenteredBandEndpoint-kernel.json | 7 + .../Sendov.Analytic.CenteredBandEndpoint.json | 7 + ...ov.Analytic.CenteredBandScalar-kernel.json | 7 + .../Sendov.Analytic.CenteredBandScalar.json | 7 + ...ndov.Analytic.CenteredBandTail-kernel.json | 7 + .../Sendov.Analytic.CenteredBandTail.json | 7 + ...v.Analytic.CenteredBandTheorem-kernel.json | 7 + .../Sendov.Analytic.CenteredBandTheorem.json | 7 + .../lean-band/receipts/audit.json | 903 + .../tests.CenteredBandAudit-kernel.json | 7 + .../receipts/tests.CenteredBandAudit.json | 7 + .../lean-band/tests/CenteredBandAudit.lean | 25 + research/centered-round5/lean-band/verify.py | 84 + .../centered-round5/lean-moment/README.md | 123 + .../Analytic/CenteredBernsteinMoment.lean | 119 + .../Analytic/CenteredEndpointMoment.lean | 153 + .../Sendov/Analytic/CenteredMomentAudit.lean | 18 + research/centered-round5/lean-moment/check.py | 73 + ...alytic.CenteredBernsteinMoment-kernel.json | 13 + ...ndov.Analytic.CenteredBernsteinMoment.json | 13 + ...nalytic.CenteredEndpointMoment-kernel.json | 13 + ...endov.Analytic.CenteredEndpointMoment.json | 13 + ...v.Analytic.CenteredMomentAudit-kernel.json | 13 + .../Sendov.Analytic.CenteredMomentAudit.json | 13 + .../lean-moment/receipts/verification.json | 124 + .../centered-round5/lean-moment/verify.py | 49 + .../centered-round5/review-global/AUDIT.md | 153 + .../centered-round5/review-global/ISSUES.md | 37 + .../cache/exact-verification.json | 1245 + .../cache/independent-audit.json | 482 + .../review-global/evidence.json | 1392 + .../review-global/independent_checks.py | 259 + .../review-global/source-replay.json | 6 + .../reviewed-paper/cutoff35.md | 401 + research/centered-verified.zip | Bin 0 -> 2213253 bytes research/centered-verified/MANIFEST.json | 63 + research/centered-verified/MATH_NOTE.md | 157 + research/centered-verified/REPORT.md | 153 + research/centered-verified/RESULT.json | 53 + research/centered-verified/RESULT.md | 28 + .../Analytic/PaperCenteredEndpoint.lean | 153 + .../Sendov/Analytic/PaperCenteredTail.lean | 69 + .../PaperCenteredVarianceEndpoint.lean | 61 + research/centered-verified/envelope.py | 33 + .../centered-verified/envelope_results.json | 78797 ++++ research/centered-verified/finalists.log | 5 + research/centered-verified/finalists.py | 21 + .../centered-verified/finalists_results.json | 665 + .../full_rational_replay.log | 24 + research/centered-verified/high_precision.log | 24 + research/centered-verified/high_precision.py | 56 + .../high_precision_results.json | 2305 + .../centered-verified/large_precision.log | 3 + research/centered-verified/large_precision.py | 21 + .../large_precision_results.json | 126 + ...inal-tests.PaperCenteredVarianceAudit.json | 24 + ...final-tests.PaperCenteredVarianceAudit.log | 16 + ...Analytic.PaperCenteredEndpoint-kernel.json | 18 + ....Analytic.PaperCenteredEndpoint-kernel.log | 0 ...Sendov.Analytic.PaperCenteredEndpoint.json | 24 + ...-Sendov.Analytic.PaperCenteredEndpoint.log | 0 ...Analytic.PaperCenteredEndpoint-kernel.json | 18 + ....Analytic.PaperCenteredEndpoint-kernel.log | 0 ...Sendov.Analytic.PaperCenteredEndpoint.json | 24 + ...-Sendov.Analytic.PaperCenteredEndpoint.log | 54 + ...d-final-tests.PaperCenteredStructural.json | 24 + ...ed-final-tests.PaperCenteredStructural.log | 9 + ...dov.Analytic.PaperCenteredTail-kernel.json | 18 + ...ndov.Analytic.PaperCenteredTail-kernel.log | 0 ...-02-Sendov.Analytic.PaperCenteredTail.json | 24 + ...l-02-Sendov.Analytic.PaperCenteredTail.log | 0 ...nalytic.PaperCenteredVarianceEndpoint.json | 24 + ...Analytic.PaperCenteredVarianceEndpoint.log | 0 ....PaperCenteredVarianceEndpoint-kernel.json | 18 + ...c.PaperCenteredVarianceEndpoint-kernel.log | 0 ...Analytic.PaperCenteredEndpoint-kernel.json | 18 + ....Analytic.PaperCenteredEndpoint-kernel.log | 0 ...Sendov.Analytic.PaperCenteredEndpoint.json | 24 + ...-Sendov.Analytic.PaperCenteredEndpoint.log | 0 ...dov.Analytic.PaperCenteredTail-kernel.json | 18 + ...ndov.Analytic.PaperCenteredTail-kernel.log | 0 ...nal-Sendov.Analytic.PaperCenteredTail.json | 24 + ...inal-Sendov.Analytic.PaperCenteredTail.log | 0 ....PaperCenteredVarianceEndpoint-kernel.json | 18 + ...c.PaperCenteredVarianceEndpoint-kernel.log | 0 ...nalytic.PaperCenteredVarianceEndpoint.json | 24 + ...Analytic.PaperCenteredVarianceEndpoint.log | 0 ...-tests.PaperCenteredStructural-kernel.json | 18 + ...l-tests.PaperCenteredStructural-kernel.log | 0 ...n-final-tests.PaperCenteredStructural.json | 24 + ...en-final-tests.PaperCenteredStructural.log | 9 + ...sts.PaperCenteredVarianceAudit-kernel.json | 18 + ...ests.PaperCenteredVarianceAudit-kernel.log | 0 ...inal-tests.PaperCenteredVarianceAudit.json | 24 + ...final-tests.PaperCenteredVarianceAudit.log | 16 + .../centered-verified/lean_verification.json | 61 + research/centered-verified/optimization.log | 27 + .../optimization_results.json | 1554 + research/centered-verified/optimize.log | 26 + research/centered-verified/optimize.py | 46 + research/centered-verified/pack.py | 26 + research/centered-verified/pack_receipt.json | 7 + research/centered-verified/rational.log | 9 + research/centered-verified/rational.py | 95 + .../centered-verified/rational_results.json | 386 + .../centered-verified/scalar_results.json | 303346 +++++++++++++++ research/centered-verified/scalar_scan.log | 85 + research/centered-verified/scalar_scan.py | 31 + research/centered-verified/search.log | 202 + research/centered-verified/search.py | 73 + .../centered-verified/search_results.json | 132168 +++++++ .../centered-verified/structural_replay.py | 47 + .../centered-verified/structural_results.json | 67 + .../tests/PaperCenteredStructural.lean | 15 + .../tests/PaperCenteredVarianceAudit.lean | 12 + .../verification_receipt.json | 10 + research/centered-verified/verify.py | 43 + research/centered-verified/verify_lean.log | 46 + research/centered-verified/verify_lean.py | 33 + research/centered/MATH_NOTE.md | 165 + research/centered/REPORT.md | 86 + research/centered/RESULT.json | 42 + research/centered/RESULT.md | 24 + research/centered/envelope.py | 33 + research/centered/envelope_results.json | 78797 ++++ research/centered/finalists.log | 14 + research/centered/finalists.py | 20 + research/centered/high_precision.log | 24 + research/centered/high_precision.py | 56 + research/centered/high_precision_results.json | 2305 + research/centered/instability.py | 19 + research/centered/instability_regression.json | 75 + research/centered/large_precision.log | 3 + research/centered/large_precision.py | 21 + .../centered/large_precision_results.json | 126 + research/centered/optimization.log | 27 + research/centered/optimization_precision.log | 12 + .../optimization_precision_results.json | 895 + research/centered/optimization_results.json | 1554 + research/centered/optimize.log | 26 + research/centered/optimize.py | 46 + .../centered/optimized_rational_results.json | 88 + research/centered/rational.log | 9 + research/centered/rational.py | 95 + research/centered/rational_results.json | 386 + research/centered/scalar_results.json | 303346 +++++++++++++++ research/centered/scalar_scan.log | 78 + research/centered/scalar_scan.py | 29 + research/centered/search.log | 202 + research/centered/search.py | 73 + research/centered/search_results.json | 132168 +++++++ research/centered/structural_replay.py | 47 + research/centered/structural_results.json | 67 + research/centered/verify.log | 42 + research/centered/verify.py | 49 + research/centered/verify_optimization.py | 29 + tests/PaperCenteredStructural.lean | 15 + tests/PaperCenteredVarianceAudit.lean | 12 + 924 files changed, 1098994 insertions(+), 1 deletion(-) create mode 100644 .gitattributes create mode 100644 Sendov/Analytic/PaperCenteredEndpoint.lean create mode 100644 Sendov/Analytic/PaperCenteredTail.lean create mode 100644 Sendov/Analytic/PaperCenteredVarianceEndpoint.lean create mode 100644 research/README.md create mode 100644 research/centered-global-verified.zip create mode 100644 research/centered-global-verified/BinomialMode.lean create mode 100644 research/centered-global-verified/CoefficientBound.lean create mode 100644 research/centered-global-verified/FirstMoment.lean create mode 100644 research/centered-global-verified/HISTORICAL_RATIONAL_VERIFICATION.json create mode 100644 research/centered-global-verified/LEAN_VERIFICATION.json create mode 100644 research/centered-global-verified/MANIFEST.json create mode 100644 research/centered-global-verified/MODULES.json create mode 100644 research/centered-global-verified/PAPER_VERIFICATION.json create mode 100644 research/centered-global-verified/REPORT.md create mode 100644 research/centered-global-verified/RESULT.json create mode 100644 research/centered-global-verified/RESULT.md create mode 100644 research/centered-global-verified/SOURCE_ORIGINS.json create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredActualPolar.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredActualTail.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredBandCertificate.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredBandEndpoint.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredBandScalar.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredBandTail.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredBandTheorem.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredBernsteinMoment.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredChordGeneral.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredEndpointMoment.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredMeanBudget.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredMomentAudit.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredNearChord.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredNearEndpoint.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredNearScalar.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredNearTheorem.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredQuarterActual.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredQuarterAudit.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredQuarterEndpoint.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredQuarterScalar.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredQuarterTheorem.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredThinVariance.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredThirdActual.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredThirdEndpoint.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredThirdScalar.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredThirdTail.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/CenteredThirdTheorem.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/PaperCenteredEndpoint.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/PaperCenteredTail.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/PaperCenteredVarianceEndpoint.lean create mode 100644 research/centered-global-verified/Sendov/Analytic/PaperFactorialTail.lean create mode 100644 research/centered-global-verified/VERIFICATION_NOTES.md create mode 100644 research/centered-global-verified/check.py create mode 100644 research/centered-global-verified/final-verification.log create mode 100644 research/centered-global-verified/historical/centered-verified.zip create mode 100644 research/centered-global-verified/interfaces/BAND_INTERFACE.md create mode 100644 research/centered-global-verified/interfaces/MOMENT_INTERFACE.md create mode 100644 research/centered-global-verified/logs/global-BinomialMode-kernel.json create mode 100644 research/centered-global-verified/logs/global-BinomialMode-kernel.log create mode 100644 research/centered-global-verified/logs/global-BinomialMode.json create mode 100644 research/centered-global-verified/logs/global-BinomialMode.log create mode 100644 research/centered-global-verified/logs/global-CoefficientBound-kernel.json create mode 100644 research/centered-global-verified/logs/global-CoefficientBound-kernel.log create mode 100644 research/centered-global-verified/logs/global-CoefficientBound.json create mode 100644 research/centered-global-verified/logs/global-CoefficientBound.log create mode 100644 research/centered-global-verified/logs/global-FirstMoment-kernel.json create mode 100644 research/centered-global-verified/logs/global-FirstMoment-kernel.log create mode 100644 research/centered-global-verified/logs/global-FirstMoment.json create mode 100644 research/centered-global-verified/logs/global-FirstMoment.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredActualPolar-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredActualPolar-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredActualPolar.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredActualPolar.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredActualTail-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredActualTail-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredActualTail.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredActualTail.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandCertificate-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandCertificate-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandCertificate.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandCertificate.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandEndpoint-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandEndpoint-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandEndpoint.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandEndpoint.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandScalar-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandScalar-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandScalar.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandScalar.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandTail-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandTail-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandTail.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandTail.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandTheorem-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandTheorem-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandTheorem.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBandTheorem.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBernsteinMoment-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBernsteinMoment-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBernsteinMoment.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredBernsteinMoment.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredChordGeneral-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredChordGeneral-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredChordGeneral.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredChordGeneral.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredEndpointMoment-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredEndpointMoment-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredEndpointMoment.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredEndpointMoment.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredMeanBudget-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredMeanBudget-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredMeanBudget.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredMeanBudget.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredMomentAudit-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredMomentAudit-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredMomentAudit.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredMomentAudit.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearChord-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearChord-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearChord.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearChord.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearEndpoint-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearEndpoint-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearEndpoint.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearEndpoint.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearScalar-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearScalar-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearScalar.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearScalar.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearTheorem-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearTheorem-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearTheorem.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredNearTheorem.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterActual-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterActual-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterActual.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterActual.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterAudit-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterAudit-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterAudit.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterAudit.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterEndpoint-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterEndpoint-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterEndpoint.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterEndpoint.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterScalar-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterScalar-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterScalar.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterScalar.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterTheorem-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterTheorem-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterTheorem.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredQuarterTheorem.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThinVariance-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThinVariance-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThinVariance.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThinVariance.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdActual-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdActual-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdActual.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdActual.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdEndpoint-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdEndpoint-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdEndpoint.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdEndpoint.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdScalar-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdScalar-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdScalar.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdScalar.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdTail-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdTail-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdTail.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdTail.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdTheorem-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdTheorem-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdTheorem.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.CenteredThirdTheorem.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperCenteredEndpoint-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperCenteredEndpoint-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperCenteredEndpoint.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperCenteredEndpoint.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperCenteredTail-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperCenteredTail-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperCenteredTail.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperCenteredTail.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperCenteredVarianceEndpoint-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperCenteredVarianceEndpoint-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperCenteredVarianceEndpoint.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperCenteredVarianceEndpoint.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperFactorialTail-kernel.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperFactorialTail-kernel.log create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperFactorialTail.json create mode 100644 research/centered-global-verified/logs/global-Sendov.Analytic.PaperFactorialTail.log create mode 100644 research/centered-global-verified/logs/global-tests.ActualPolarAudit-kernel.json create mode 100644 research/centered-global-verified/logs/global-tests.ActualPolarAudit-kernel.log create mode 100644 research/centered-global-verified/logs/global-tests.ActualPolarAudit.json create mode 100644 research/centered-global-verified/logs/global-tests.ActualPolarAudit.log create mode 100644 research/centered-global-verified/logs/global-tests.CenteredBandAudit-kernel.json create mode 100644 research/centered-global-verified/logs/global-tests.CenteredBandAudit-kernel.log create mode 100644 research/centered-global-verified/logs/global-tests.CenteredBandAudit.json create mode 100644 research/centered-global-verified/logs/global-tests.CenteredBandAudit.log create mode 100644 research/centered-global-verified/logs/global-tests.CenteredNearAudit-kernel.json create mode 100644 research/centered-global-verified/logs/global-tests.CenteredNearAudit-kernel.log create mode 100644 research/centered-global-verified/logs/global-tests.CenteredNearAudit.json create mode 100644 research/centered-global-verified/logs/global-tests.CenteredNearAudit.log create mode 100644 research/centered-global-verified/logs/global-tests.CenteredQuarterFinalAudit-kernel.json create mode 100644 research/centered-global-verified/logs/global-tests.CenteredQuarterFinalAudit-kernel.log create mode 100644 research/centered-global-verified/logs/global-tests.CenteredQuarterFinalAudit.json create mode 100644 research/centered-global-verified/logs/global-tests.CenteredQuarterFinalAudit.log create mode 100644 research/centered-global-verified/logs/global-tests.CenteredThinAudit-kernel.json create mode 100644 research/centered-global-verified/logs/global-tests.CenteredThinAudit-kernel.log create mode 100644 research/centered-global-verified/logs/global-tests.CenteredThinAudit.json create mode 100644 research/centered-global-verified/logs/global-tests.CenteredThinAudit.log create mode 100644 research/centered-global-verified/logs/global-tests.CenteredThirdAudit-kernel.json create mode 100644 research/centered-global-verified/logs/global-tests.CenteredThirdAudit-kernel.log create mode 100644 research/centered-global-verified/logs/global-tests.CenteredThirdAudit.json create mode 100644 research/centered-global-verified/logs/global-tests.CenteredThirdAudit.log create mode 100644 research/centered-global-verified/logs/global-tests.MeanBudgetAudit-kernel.json create mode 100644 research/centered-global-verified/logs/global-tests.MeanBudgetAudit-kernel.log create mode 100644 research/centered-global-verified/logs/global-tests.MeanBudgetAudit.json create mode 100644 research/centered-global-verified/logs/global-tests.MeanBudgetAudit.log create mode 100644 research/centered-global-verified/logs/historical-full-rational.log create mode 100644 research/centered-global-verified/logs/paper-centered-round2-verified_math-bound_verify.py.log create mode 100644 research/centered-global-verified/logs/paper-centered-round2-verified_math-cutoff45_verify.py.log create mode 100644 research/centered-global-verified/logs/paper-centered-round2-verified_math-middle_verify.py.log create mode 100644 research/centered-global-verified/logs/paper-centered-round3_diagnostics_certify_chord.py.log create mode 100644 research/centered-global-verified/logs/paper-centered-round3_math-polar_verify.py.log create mode 100644 research/centered-global-verified/logs/paper-centered-round4_math-residual_audit.py.log create mode 100644 research/centered-global-verified/logs/paper-centered-round4_math-residual_verify.py.log create mode 100644 research/centered-global-verified/logs/paper-centered-round4_review35_audit.py.log create mode 100644 research/centered-global-verified/logs/paper-centered-round5_boundary-family_verify.py.log create mode 100644 research/centered-global-verified/logs/paper-centered-round5_review-global_independent_checks.py.log create mode 100644 research/centered-global-verified/pack.py create mode 100644 research/centered-global-verified/pack_receipt.json create mode 100644 research/centered-global-verified/paper-replay.log create mode 100644 research/centered-global-verified/rebuild.log create mode 100644 research/centered-global-verified/receipts/BinomialMode-kernel.json create mode 100644 research/centered-global-verified/receipts/BinomialMode.json create mode 100644 research/centered-global-verified/receipts/CoefficientBound-kernel.json create mode 100644 research/centered-global-verified/receipts/CoefficientBound.json create mode 100644 research/centered-global-verified/receipts/FirstMoment-kernel.json create mode 100644 research/centered-global-verified/receipts/FirstMoment.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredActualPolar-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredActualPolar.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredActualTail-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredActualTail.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredBandCertificate-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredBandCertificate.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredBandEndpoint-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredBandEndpoint.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredBandScalar-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredBandScalar.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredBandTail-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredBandTail.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredBandTheorem-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredBandTheorem.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredBernsteinMoment-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredBernsteinMoment.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredChordGeneral-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredChordGeneral.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredEndpointMoment-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredEndpointMoment.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredMeanBudget-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredMeanBudget.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredMomentAudit-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredMomentAudit.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredNearChord-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredNearChord.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredNearEndpoint-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredNearEndpoint.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredNearScalar-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredNearScalar.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredNearTheorem-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredNearTheorem.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredQuarterActual-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredQuarterActual.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredQuarterAudit-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredQuarterAudit.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredQuarterEndpoint-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredQuarterEndpoint.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredQuarterScalar-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredQuarterScalar.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredQuarterTheorem-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredQuarterTheorem.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredThinVariance-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredThinVariance.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredThirdActual-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredThirdActual.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredThirdEndpoint-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredThirdEndpoint.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredThirdScalar-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredThirdScalar.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredThirdTail-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredThirdTail.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredThirdTheorem-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.CenteredThirdTheorem.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.PaperCenteredEndpoint-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.PaperCenteredEndpoint.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.PaperCenteredTail-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.PaperCenteredTail.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.PaperCenteredVarianceEndpoint-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.PaperCenteredVarianceEndpoint.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.PaperFactorialTail-kernel.json create mode 100644 research/centered-global-verified/receipts/Sendov.Analytic.PaperFactorialTail.json create mode 100644 research/centered-global-verified/receipts/tests.ActualPolarAudit-kernel.json create mode 100644 research/centered-global-verified/receipts/tests.ActualPolarAudit.json create mode 100644 research/centered-global-verified/receipts/tests.CenteredBandAudit-kernel.json create mode 100644 research/centered-global-verified/receipts/tests.CenteredBandAudit.json create mode 100644 research/centered-global-verified/receipts/tests.CenteredNearAudit-kernel.json create mode 100644 research/centered-global-verified/receipts/tests.CenteredNearAudit.json create mode 100644 research/centered-global-verified/receipts/tests.CenteredQuarterFinalAudit-kernel.json create mode 100644 research/centered-global-verified/receipts/tests.CenteredQuarterFinalAudit.json create mode 100644 research/centered-global-verified/receipts/tests.CenteredThinAudit-kernel.json create mode 100644 research/centered-global-verified/receipts/tests.CenteredThinAudit.json create mode 100644 research/centered-global-verified/receipts/tests.CenteredThirdAudit-kernel.json create mode 100644 research/centered-global-verified/receipts/tests.CenteredThirdAudit.json create mode 100644 research/centered-global-verified/receipts/tests.MeanBudgetAudit-kernel.json create mode 100644 research/centered-global-verified/receipts/tests.MeanBudgetAudit.json create mode 100644 research/centered-global-verified/research/centered-round2-verified/math-bound/PROOF.md create mode 100644 research/centered-global-verified/research/centered-round2-verified/math-bound/verify.py create mode 100644 research/centered-global-verified/research/centered-round2-verified/math-cutoff45/PROOF.md create mode 100644 research/centered-global-verified/research/centered-round2-verified/math-cutoff45/verify.py create mode 100644 research/centered-global-verified/research/centered-round2-verified/math-middle/PROOF.md create mode 100644 research/centered-global-verified/research/centered-round2-verified/math-middle/verify.py create mode 100644 research/centered-global-verified/research/centered-round3/diagnostics/certify_chord.py create mode 100644 research/centered-global-verified/research/centered-round3/diagnostics/chord_obstruction.json create mode 100644 research/centered-global-verified/research/centered-round3/diagnostics/rational_support.py create mode 100644 research/centered-global-verified/research/centered-round3/math-polar/PROOF.md create mode 100644 research/centered-global-verified/research/centered-round3/math-polar/cache/exact-verification.json create mode 100644 research/centered-global-verified/research/centered-round3/math-polar/verify.py create mode 100644 research/centered-global-verified/research/centered-round4/math-residual/PROOF.md create mode 100644 research/centered-global-verified/research/centered-round4/math-residual/audit.py create mode 100644 research/centered-global-verified/research/centered-round4/math-residual/cache/exact-verification.json create mode 100644 research/centered-global-verified/research/centered-round4/math-residual/cache/independent-audit.json create mode 100644 research/centered-global-verified/research/centered-round4/math-residual/verify.py create mode 100644 research/centered-global-verified/research/centered-round4/review35/AUDIT.md create mode 100644 research/centered-global-verified/research/centered-round4/review35/ISSUES.md create mode 100644 research/centered-global-verified/research/centered-round4/review35/audit.py create mode 100644 research/centered-global-verified/research/centered-round4/review35/cache/exact-verification.json create mode 100644 research/centered-global-verified/research/centered-round4/review35/evidence.json create mode 100644 research/centered-global-verified/research/centered-round4/review35/source-replay.json create mode 100644 research/centered-global-verified/research/centered-round5/boundary-family/NOTE.md create mode 100644 research/centered-global-verified/research/centered-round5/boundary-family/RESULT.json create mode 100644 research/centered-global-verified/research/centered-round5/boundary-family/verify.py create mode 100644 research/centered-global-verified/research/centered-round5/review-global/AUDIT.md create mode 100644 research/centered-global-verified/research/centered-round5/review-global/ISSUES.md create mode 100644 research/centered-global-verified/research/centered-round5/review-global/cache/exact-verification.json create mode 100644 research/centered-global-verified/research/centered-round5/review-global/cache/independent-audit.json create mode 100644 research/centered-global-verified/research/centered-round5/review-global/evidence.json create mode 100644 research/centered-global-verified/research/centered-round5/review-global/independent_checks.py create mode 100644 research/centered-global-verified/research/centered-round5/review-global/source-replay.json create mode 100644 research/centered-global-verified/research/centered-verified/MATH_NOTE.md create mode 100644 research/centered-global-verified/tests/ActualPolarAudit.lean create mode 100644 research/centered-global-verified/tests/CenteredBandAudit.lean create mode 100644 research/centered-global-verified/tests/CenteredNearAudit.lean create mode 100644 research/centered-global-verified/tests/CenteredQuarterFinalAudit.lean create mode 100644 research/centered-global-verified/tests/CenteredThinAudit.lean create mode 100644 research/centered-global-verified/tests/CenteredThirdAudit.lean create mode 100644 research/centered-global-verified/tests/MeanBudgetAudit.lean create mode 100644 research/centered-global-verified/verification.log create mode 100644 research/centered-global-verified/verify.py create mode 100644 research/centered-global-verified/verify_lean.py create mode 100644 research/centered-global-verified/verify_paper.py create mode 100644 research/centered-round2-verified.zip create mode 100644 research/centered-round2-verified/BinomialMode.lean create mode 100644 research/centered-round2-verified/CoefficientBound.lean create mode 100644 research/centered-round2-verified/FirstMoment.lean create mode 100644 research/centered-round2-verified/MANIFEST.json create mode 100644 research/centered-round2-verified/NEAR_PROOF.md create mode 100644 research/centered-round2-verified/REPORT.md create mode 100644 research/centered-round2-verified/RESULT.json create mode 100644 research/centered-round2-verified/RESULT.md create mode 100644 research/centered-round2-verified/Sendov/Analytic/CenteredActualTail.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/CenteredChordGeneral.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/CenteredNearChord.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/CenteredNearEndpoint.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/CenteredNearScalar.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/CenteredNearTheorem.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/CenteredQuarterActual.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/CenteredQuarterAudit.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/CenteredQuarterEndpoint.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/CenteredQuarterScalar.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/CenteredQuarterTheorem.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/CenteredThinVariance.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/PaperCenteredEndpoint.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/PaperCenteredTail.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/PaperCenteredVarianceEndpoint.lean create mode 100644 research/centered-round2-verified/Sendov/Analytic/PaperFactorialTail.lean create mode 100644 research/centered-round2-verified/check.py create mode 100644 research/centered-round2-verified/cutoff_verification.log create mode 100644 research/centered-round2-verified/intermediate_witness.json create mode 100644 research/centered-round2-verified/logs/round2-BinomialMode-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-BinomialMode-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-BinomialMode.json create mode 100644 research/centered-round2-verified/logs/round2-BinomialMode.log create mode 100644 research/centered-round2-verified/logs/round2-CoefficientBound-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-CoefficientBound-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-CoefficientBound.json create mode 100644 research/centered-round2-verified/logs/round2-CoefficientBound.log create mode 100644 research/centered-round2-verified/logs/round2-FirstMoment-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-FirstMoment-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-FirstMoment.json create mode 100644 research/centered-round2-verified/logs/round2-FirstMoment.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredActualTail-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredActualTail-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredActualTail.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredActualTail.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredChordGeneral-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredChordGeneral-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredChordGeneral.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredChordGeneral.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearChord-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearChord-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearChord.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearChord.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearEndpoint-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearEndpoint-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearEndpoint.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearEndpoint.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearScalar-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearScalar-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearScalar.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearScalar.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearTheorem-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearTheorem-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearTheorem.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredNearTheorem.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterActual-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterActual-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterActual.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterActual.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterAudit-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterAudit-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterAudit.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterAudit.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterEndpoint-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterEndpoint-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterEndpoint.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterEndpoint.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterScalar-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterScalar-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterScalar.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterScalar.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterTheorem-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterTheorem-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterTheorem.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredQuarterTheorem.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredThinVariance-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredThinVariance-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredThinVariance.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.CenteredThinVariance.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperCenteredEndpoint-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperCenteredEndpoint-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperCenteredEndpoint.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperCenteredEndpoint.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperCenteredTail-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperCenteredTail-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperCenteredTail.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperCenteredTail.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperCenteredVarianceEndpoint-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperCenteredVarianceEndpoint-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperCenteredVarianceEndpoint.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperCenteredVarianceEndpoint.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperFactorialTail-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperFactorialTail-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperFactorialTail.json create mode 100644 research/centered-round2-verified/logs/round2-Sendov.Analytic.PaperFactorialTail.log create mode 100644 research/centered-round2-verified/logs/round2-tests.CenteredNearAudit-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-tests.CenteredNearAudit-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-tests.CenteredNearAudit.json create mode 100644 research/centered-round2-verified/logs/round2-tests.CenteredNearAudit.log create mode 100644 research/centered-round2-verified/logs/round2-tests.CenteredQuarterFinalAudit-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-tests.CenteredQuarterFinalAudit-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-tests.CenteredQuarterFinalAudit.json create mode 100644 research/centered-round2-verified/logs/round2-tests.CenteredQuarterFinalAudit.log create mode 100644 research/centered-round2-verified/logs/round2-tests.CenteredThinAudit-kernel.json create mode 100644 research/centered-round2-verified/logs/round2-tests.CenteredThinAudit-kernel.log create mode 100644 research/centered-round2-verified/logs/round2-tests.CenteredThinAudit.json create mode 100644 research/centered-round2-verified/logs/round2-tests.CenteredThinAudit.log create mode 100644 research/centered-round2-verified/math-bound/PROOF.md create mode 100644 research/centered-round2-verified/math-bound/RESULT.md create mode 100644 research/centered-round2-verified/math-bound/VERIFICATION.txt create mode 100644 research/centered-round2-verified/math-bound/verify.py create mode 100644 research/centered-round2-verified/math-cutoff45/PROOF.md create mode 100644 research/centered-round2-verified/math-cutoff45/verify.py create mode 100644 research/centered-round2-verified/math-middle/PROOF.md create mode 100644 research/centered-round2-verified/math-middle/verification.json create mode 100644 research/centered-round2-verified/math-middle/verify.py create mode 100644 research/centered-round2-verified/middle_verification.log create mode 100644 research/centered-round2-verified/pack.py create mode 100644 research/centered-round2-verified/pack_receipt.json create mode 100644 research/centered-round2-verified/paper_verification.log create mode 100644 research/centered-round2-verified/rebuild.log create mode 100644 research/centered-round2-verified/receipts/BinomialMode-kernel.json create mode 100644 research/centered-round2-verified/receipts/BinomialMode.json create mode 100644 research/centered-round2-verified/receipts/CoefficientBound-kernel.json create mode 100644 research/centered-round2-verified/receipts/CoefficientBound.json create mode 100644 research/centered-round2-verified/receipts/FirstMoment-kernel.json create mode 100644 research/centered-round2-verified/receipts/FirstMoment.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredActualTail-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredActualTail.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredChordGeneral-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredChordGeneral.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredNearChord-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredNearChord.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredNearEndpoint-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredNearEndpoint.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredNearScalar-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredNearScalar.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredNearTheorem-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredNearTheorem.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredQuarterActual-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredQuarterActual.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredQuarterAudit-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredQuarterAudit.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredQuarterEndpoint-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredQuarterEndpoint.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredQuarterScalar-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredQuarterScalar.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredQuarterTheorem-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredQuarterTheorem.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredThinVariance-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.CenteredThinVariance.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.PaperCenteredEndpoint-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.PaperCenteredEndpoint.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.PaperCenteredTail-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.PaperCenteredTail.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.PaperCenteredVarianceEndpoint-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.PaperCenteredVarianceEndpoint.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.PaperFactorialTail-kernel.json create mode 100644 research/centered-round2-verified/receipts/Sendov.Analytic.PaperFactorialTail.json create mode 100644 research/centered-round2-verified/receipts/tests.CenteredNearAudit-kernel.json create mode 100644 research/centered-round2-verified/receipts/tests.CenteredNearAudit.json create mode 100644 research/centered-round2-verified/receipts/tests.CenteredQuarterFinalAudit-kernel.json create mode 100644 research/centered-round2-verified/receipts/tests.CenteredQuarterFinalAudit.json create mode 100644 research/centered-round2-verified/receipts/tests.CenteredThinAudit-kernel.json create mode 100644 research/centered-round2-verified/receipts/tests.CenteredThinAudit.json create mode 100644 research/centered-round2-verified/support/rational.py create mode 100644 research/centered-round2-verified/tests/CenteredNearAudit.lean create mode 100644 research/centered-round2-verified/tests/CenteredQuarterFinalAudit.lean create mode 100644 research/centered-round2-verified/tests/CenteredThinAudit.lean create mode 100644 research/centered-round2-verified/verify_intermediate_witness.py create mode 100644 research/centered-round2-verified/verify_round2.py create mode 100644 research/centered-round2-verified/witness_verification.log create mode 100644 research/centered-round2/BinomialMode.lean create mode 100644 research/centered-round2/CoefficientBound.lean create mode 100644 research/centered-round2/FirstMoment.lean create mode 100644 research/centered-round2/NEAR_PROOF.md create mode 100644 research/centered-round2/REPORT.md create mode 100644 research/centered-round2/RESULT.json create mode 100644 research/centered-round2/Sendov/Analytic/CenteredActualTail.lean create mode 100644 research/centered-round2/Sendov/Analytic/CenteredChordGeneral.lean create mode 100644 research/centered-round2/Sendov/Analytic/CenteredNearChord.lean create mode 100644 research/centered-round2/Sendov/Analytic/CenteredNearEndpoint.lean create mode 100644 research/centered-round2/Sendov/Analytic/CenteredNearScalar.lean create mode 100644 research/centered-round2/Sendov/Analytic/CenteredNearTheorem.lean create mode 100644 research/centered-round2/Sendov/Analytic/CenteredQuarterActual.lean create mode 100644 research/centered-round2/Sendov/Analytic/CenteredQuarterAudit.lean create mode 100644 research/centered-round2/Sendov/Analytic/CenteredQuarterEndpoint.lean create mode 100644 research/centered-round2/Sendov/Analytic/CenteredQuarterScalar.lean create mode 100644 research/centered-round2/Sendov/Analytic/CenteredQuarterTheorem.lean create mode 100644 research/centered-round2/Sendov/Analytic/CenteredThinVariance.lean create mode 100644 research/centered-round2/Sendov/Analytic/PaperCenteredEndpoint.lean create mode 100644 research/centered-round2/Sendov/Analytic/PaperCenteredTail.lean create mode 100644 research/centered-round2/Sendov/Analytic/PaperCenteredVarianceEndpoint.lean create mode 100644 research/centered-round2/Sendov/Analytic/PaperFactorialTail.lean create mode 100644 research/centered-round2/check.py create mode 100644 research/centered-round2/intermediate_witness.json create mode 100644 research/centered-round2/lean-mode/BinomialMode.lean create mode 100644 research/centered-round2/lean-mode/CoefficientBound.lean create mode 100644 research/centered-round2/lean-mode/FirstMoment.lean create mode 100644 research/centered-round2/lean-mode/README.md create mode 100644 research/centered-round2/lean-mode/VERIFIED.json create mode 100644 research/centered-round2/lean-mode/run.py create mode 100644 research/centered-round2/lean-mode/verify.py create mode 100644 research/centered-round2/lean-quarter/README.md create mode 100644 research/centered-round2/lean-quarter/Sendov/Analytic/CenteredQuarterActual.lean create mode 100644 research/centered-round2/lean-quarter/Sendov/Analytic/CenteredQuarterAudit.lean create mode 100644 research/centered-round2/lean-quarter/Sendov/Analytic/CenteredQuarterEndpoint.lean create mode 100644 research/centered-round2/lean-quarter/Sendov/Analytic/CenteredQuarterScalar.lean create mode 100644 research/centered-round2/lean-quarter/receipts/acceptance.json create mode 100644 research/centered-round2/lean-quarter/receipts/overlay.json create mode 100644 research/centered-round2/lean-quarter/verify_receipts.py create mode 100644 research/centered-round2/lean-tail/README.md create mode 100644 research/centered-round2/lean-tail/Sendov/Analytic/PaperFactorialTail.lean create mode 100644 research/centered-round2/lean-tail/TailAudit.lean create mode 100644 research/centered-round2/lean-tail/verification.json create mode 100644 research/centered-round2/lean-tail/verify.py create mode 100644 research/centered-round2/math-bound/PROOF.md create mode 100644 research/centered-round2/math-bound/RESULT.md create mode 100644 research/centered-round2/math-bound/VERIFICATION.txt create mode 100644 research/centered-round2/math-bound/verify.py create mode 100644 research/centered-round2/math-cutoff45/PROOF.md create mode 100644 research/centered-round2/math-cutoff45/verify.py create mode 100644 research/centered-round2/math-middle/PROOF.md create mode 100644 research/centered-round2/math-middle/verification.json create mode 100644 research/centered-round2/math-middle/verify.py create mode 100644 research/centered-round2/middle_verification.log create mode 100644 research/centered-round2/paper_verification.log create mode 100644 research/centered-round2/receipts/BinomialMode-kernel.json create mode 100644 research/centered-round2/receipts/BinomialMode.json create mode 100644 research/centered-round2/receipts/CoefficientBound-kernel.json create mode 100644 research/centered-round2/receipts/CoefficientBound.json create mode 100644 research/centered-round2/receipts/FirstMoment-kernel.json create mode 100644 research/centered-round2/receipts/FirstMoment.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredActualTail-kernel.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredActualTail.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredChordGeneral-kernel.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredChordGeneral.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredNearChord-kernel.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredNearChord.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredNearEndpoint-kernel.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredNearEndpoint.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredNearScalar-kernel.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredNearScalar.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredNearTheorem-kernel.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredNearTheorem.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredQuarterActual-kernel.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredQuarterActual.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredQuarterAudit-kernel.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredQuarterAudit.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredQuarterEndpoint-kernel.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredQuarterEndpoint.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredQuarterScalar-kernel.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredQuarterScalar.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredQuarterTheorem-kernel.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredQuarterTheorem.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredThinVariance-kernel.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.CenteredThinVariance.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.PaperFactorialTail-kernel.json create mode 100644 research/centered-round2/receipts/Sendov.Analytic.PaperFactorialTail.json create mode 100644 research/centered-round2/receipts/tests.CenteredNearAudit-kernel.json create mode 100644 research/centered-round2/receipts/tests.CenteredNearAudit.json create mode 100644 research/centered-round2/receipts/tests.CenteredQuarterFinalAudit-kernel.json create mode 100644 research/centered-round2/receipts/tests.CenteredQuarterFinalAudit.json create mode 100644 research/centered-round2/receipts/tests.CenteredThinAudit-kernel.json create mode 100644 research/centered-round2/receipts/tests.CenteredThinAudit.json create mode 100644 research/centered-round2/support/rational.py create mode 100644 research/centered-round2/tests/CenteredNearAudit.lean create mode 100644 research/centered-round2/tests/CenteredQuarterFinalAudit.lean create mode 100644 research/centered-round2/tests/CenteredThinAudit.lean create mode 100644 research/centered-round2/verify_intermediate_witness.py create mode 100644 research/centered-round2/verify_round2.py create mode 100644 research/centered-round2/witness_verification.log create mode 100644 research/centered-round3/REPORT.md create mode 100644 research/centered-round3/RESULT.json create mode 100644 research/centered-round3/diagnostics/certify_chord.py create mode 100644 research/centered-round3/diagnostics/chord-stable.log create mode 100644 research/centered-round3/diagnostics/chord.log create mode 100644 research/centered-round3/diagnostics/chord_obstruction.json create mode 100644 research/centered-round3/diagnostics/chord_probe.py create mode 100644 research/centered-round3/diagnostics/chord_results.json create mode 100644 research/centered-round3/diagnostics/high_precision.json create mode 100644 research/centered-round3/diagnostics/rational_support.py create mode 100644 research/centered-round3/diagnostics/relaxation.py create mode 100644 research/centered-round3/diagnostics/relaxation_results.json create mode 100644 research/centered-round3/diagnostics/replay.py create mode 100644 research/centered-round3/diagnostics/search.log create mode 100644 research/centered-round3/integrated/Sendov/Analytic/CenteredMeanBudget.lean create mode 100644 research/centered-round3/integrated/Sendov/Analytic/CenteredThirdActual.lean create mode 100644 research/centered-round3/integrated/Sendov/Analytic/CenteredThirdEndpoint.lean create mode 100644 research/centered-round3/integrated/Sendov/Analytic/CenteredThirdScalar.lean create mode 100644 research/centered-round3/integrated/Sendov/Analytic/CenteredThirdTail.lean create mode 100644 research/centered-round3/integrated/Sendov/Analytic/CenteredThirdTheorem.lean create mode 100644 research/centered-round3/integrated/VERIFICATION.json create mode 100644 research/centered-round3/integrated/check.py create mode 100644 research/centered-round3/integrated/integration.log create mode 100644 research/centered-round3/integrated/receipts/Sendov.Analytic.CenteredMeanBudget-kernel.json create mode 100644 research/centered-round3/integrated/receipts/Sendov.Analytic.CenteredMeanBudget.json create mode 100644 research/centered-round3/integrated/receipts/Sendov.Analytic.CenteredThirdActual-kernel.json create mode 100644 research/centered-round3/integrated/receipts/Sendov.Analytic.CenteredThirdActual.json create mode 100644 research/centered-round3/integrated/receipts/Sendov.Analytic.CenteredThirdEndpoint-kernel.json create mode 100644 research/centered-round3/integrated/receipts/Sendov.Analytic.CenteredThirdEndpoint.json create mode 100644 research/centered-round3/integrated/receipts/Sendov.Analytic.CenteredThirdScalar-kernel.json create mode 100644 research/centered-round3/integrated/receipts/Sendov.Analytic.CenteredThirdScalar.json create mode 100644 research/centered-round3/integrated/receipts/Sendov.Analytic.CenteredThirdTail-kernel.json create mode 100644 research/centered-round3/integrated/receipts/Sendov.Analytic.CenteredThirdTail.json create mode 100644 research/centered-round3/integrated/receipts/Sendov.Analytic.CenteredThirdTheorem-kernel.json create mode 100644 research/centered-round3/integrated/receipts/Sendov.Analytic.CenteredThirdTheorem.json create mode 100644 research/centered-round3/integrated/receipts/tests.CenteredThirdAudit-kernel.json create mode 100644 research/centered-round3/integrated/receipts/tests.CenteredThirdAudit.json create mode 100644 research/centered-round3/integrated/receipts/tests.MeanBudgetAudit-kernel.json create mode 100644 research/centered-round3/integrated/receipts/tests.MeanBudgetAudit.json create mode 100644 research/centered-round3/integrated/tests/CenteredThirdAudit.lean create mode 100644 research/centered-round3/integrated/tests/MeanBudgetAudit.lean create mode 100644 research/centered-round3/integrated/verify.py create mode 100644 research/centered-round3/lean-geometry/Sendov/Analytic/CenteredMeanBudget.lean create mode 100644 research/centered-round3/lean-geometry/check.py create mode 100644 research/centered-round3/lean-geometry/receipts/Sendov.Analytic.CenteredMeanBudget-kernel.json create mode 100644 research/centered-round3/lean-geometry/receipts/Sendov.Analytic.CenteredMeanBudget.json create mode 100644 research/centered-round3/lean-geometry/receipts/tests.MeanBudgetAudit-kernel.json create mode 100644 research/centered-round3/lean-geometry/receipts/tests.MeanBudgetAudit.json create mode 100644 research/centered-round3/lean-geometry/tests/MeanBudgetAudit.lean create mode 100644 research/centered-round3/lean-third/REPORT.md create mode 100644 research/centered-round3/lean-third/Sendov/Analytic/CenteredThirdActual.lean create mode 100644 research/centered-round3/lean-third/Sendov/Analytic/CenteredThirdEndpoint.lean create mode 100644 research/centered-round3/lean-third/Sendov/Analytic/CenteredThirdScalar.lean create mode 100644 research/centered-round3/lean-third/Sendov/Analytic/CenteredThirdTail.lean create mode 100644 research/centered-round3/lean-third/Sendov/Analytic/CenteredThirdTheorem.lean create mode 100644 research/centered-round3/lean-third/VERIFICATION.json create mode 100644 research/centered-round3/lean-third/WORKFLOW.md create mode 100644 research/centered-round3/lean-third/check.py create mode 100644 research/centered-round3/lean-third/receipts/Sendov.Analytic.CenteredThirdActual-kernel.json create mode 100644 research/centered-round3/lean-third/receipts/Sendov.Analytic.CenteredThirdActual.json create mode 100644 research/centered-round3/lean-third/receipts/Sendov.Analytic.CenteredThirdEndpoint-kernel.json create mode 100644 research/centered-round3/lean-third/receipts/Sendov.Analytic.CenteredThirdEndpoint.json create mode 100644 research/centered-round3/lean-third/receipts/Sendov.Analytic.CenteredThirdScalar-kernel.json create mode 100644 research/centered-round3/lean-third/receipts/Sendov.Analytic.CenteredThirdScalar.json create mode 100644 research/centered-round3/lean-third/receipts/Sendov.Analytic.CenteredThirdTail-kernel.json create mode 100644 research/centered-round3/lean-third/receipts/Sendov.Analytic.CenteredThirdTail.json create mode 100644 research/centered-round3/lean-third/receipts/Sendov.Analytic.CenteredThirdTheorem-kernel.json create mode 100644 research/centered-round3/lean-third/receipts/Sendov.Analytic.CenteredThirdTheorem.json create mode 100644 research/centered-round3/lean-third/receipts/tests.CenteredThirdAudit-kernel.json create mode 100644 research/centered-round3/lean-third/receipts/tests.CenteredThirdAudit.json create mode 100644 research/centered-round3/lean-third/replay.py create mode 100644 research/centered-round3/lean-third/tests/CenteredThirdAudit.lean create mode 100644 research/centered-round3/math-polar/PROOF.md create mode 100644 research/centered-round3/math-polar/REPORT.md create mode 100644 research/centered-round3/math-polar/cache/exact-verification.json create mode 100644 research/centered-round3/math-polar/cache/tail-comparison.json create mode 100644 research/centered-round3/math-polar/chord_probe.py create mode 100644 research/centered-round3/math-polar/compare.py create mode 100644 research/centered-round3/math-polar/moment-bernstein.json create mode 100644 research/centered-round3/math-polar/probe-results.json create mode 100644 research/centered-round3/math-polar/probe.py create mode 100644 research/centered-round3/math-polar/verify.py create mode 100644 research/centered-round4/lean-polar/REPORT.md create mode 100644 research/centered-round4/lean-polar/Sendov/Analytic/CenteredActualPolar.lean create mode 100644 research/centered-round4/lean-polar/VERIFICATION.json create mode 100644 research/centered-round4/lean-polar/audit-kernel.log create mode 100644 research/centered-round4/lean-polar/audit.log create mode 100644 research/centered-round4/lean-polar/check.py create mode 100644 research/centered-round4/lean-polar/compile.log create mode 100644 research/centered-round4/lean-polar/kernel.log create mode 100644 research/centered-round4/lean-polar/receipts/Sendov.Analytic.CenteredActualPolar-kernel.json create mode 100644 research/centered-round4/lean-polar/receipts/Sendov.Analytic.CenteredActualPolar.json create mode 100644 research/centered-round4/lean-polar/receipts/tests.ActualPolarAudit-kernel.json create mode 100644 research/centered-round4/lean-polar/receipts/tests.ActualPolarAudit.json create mode 100644 research/centered-round4/lean-polar/tests/ActualPolarAudit.lean create mode 100644 research/centered-round4/math-residual/PROOF.md create mode 100644 research/centered-round4/math-residual/REPORT.md create mode 100644 research/centered-round4/math-residual/audit.py create mode 100644 research/centered-round4/math-residual/cache/exact-verification.json create mode 100644 research/centered-round4/math-residual/cache/independent-audit.json create mode 100644 research/centered-round4/math-residual/explore.json create mode 100644 research/centered-round4/math-residual/explore.py create mode 100644 research/centered-round4/math-residual/verify.py create mode 100644 research/centered-round4/review35/AUDIT.md create mode 100644 research/centered-round4/review35/ISSUES.md create mode 100644 research/centered-round4/review35/audit.py create mode 100644 research/centered-round4/review35/cache/exact-verification.json create mode 100644 research/centered-round4/review35/evidence.json create mode 100644 research/centered-round4/review35/source-replay.json create mode 100644 research/centered-round5/REPORT.md create mode 100644 research/centered-round5/RESULT.json create mode 100644 research/centered-round5/boundary-family/NOTE.md create mode 100644 research/centered-round5/boundary-family/RESULT.json create mode 100644 research/centered-round5/boundary-family/verify.py create mode 100644 research/centered-round5/lean-band/REPORT.md create mode 100644 research/centered-round5/lean-band/Sendov/Analytic/CenteredBandCertificate.lean create mode 100644 research/centered-round5/lean-band/Sendov/Analytic/CenteredBandEndpoint.lean create mode 100644 research/centered-round5/lean-band/Sendov/Analytic/CenteredBandScalar.lean create mode 100644 research/centered-round5/lean-band/Sendov/Analytic/CenteredBandTail.lean create mode 100644 research/centered-round5/lean-band/Sendov/Analytic/CenteredBandTheorem.lean create mode 100644 research/centered-round5/lean-band/check.py create mode 100644 research/centered-round5/lean-band/receipts/Sendov.Analytic.CenteredBandCertificate-kernel.json create mode 100644 research/centered-round5/lean-band/receipts/Sendov.Analytic.CenteredBandCertificate.json create mode 100644 research/centered-round5/lean-band/receipts/Sendov.Analytic.CenteredBandEndpoint-kernel.json create mode 100644 research/centered-round5/lean-band/receipts/Sendov.Analytic.CenteredBandEndpoint.json create mode 100644 research/centered-round5/lean-band/receipts/Sendov.Analytic.CenteredBandScalar-kernel.json create mode 100644 research/centered-round5/lean-band/receipts/Sendov.Analytic.CenteredBandScalar.json create mode 100644 research/centered-round5/lean-band/receipts/Sendov.Analytic.CenteredBandTail-kernel.json create mode 100644 research/centered-round5/lean-band/receipts/Sendov.Analytic.CenteredBandTail.json create mode 100644 research/centered-round5/lean-band/receipts/Sendov.Analytic.CenteredBandTheorem-kernel.json create mode 100644 research/centered-round5/lean-band/receipts/Sendov.Analytic.CenteredBandTheorem.json create mode 100644 research/centered-round5/lean-band/receipts/audit.json create mode 100644 research/centered-round5/lean-band/receipts/tests.CenteredBandAudit-kernel.json create mode 100644 research/centered-round5/lean-band/receipts/tests.CenteredBandAudit.json create mode 100644 research/centered-round5/lean-band/tests/CenteredBandAudit.lean create mode 100644 research/centered-round5/lean-band/verify.py create mode 100644 research/centered-round5/lean-moment/README.md create mode 100644 research/centered-round5/lean-moment/Sendov/Analytic/CenteredBernsteinMoment.lean create mode 100644 research/centered-round5/lean-moment/Sendov/Analytic/CenteredEndpointMoment.lean create mode 100644 research/centered-round5/lean-moment/Sendov/Analytic/CenteredMomentAudit.lean create mode 100644 research/centered-round5/lean-moment/check.py create mode 100644 research/centered-round5/lean-moment/receipts/Sendov.Analytic.CenteredBernsteinMoment-kernel.json create mode 100644 research/centered-round5/lean-moment/receipts/Sendov.Analytic.CenteredBernsteinMoment.json create mode 100644 research/centered-round5/lean-moment/receipts/Sendov.Analytic.CenteredEndpointMoment-kernel.json create mode 100644 research/centered-round5/lean-moment/receipts/Sendov.Analytic.CenteredEndpointMoment.json create mode 100644 research/centered-round5/lean-moment/receipts/Sendov.Analytic.CenteredMomentAudit-kernel.json create mode 100644 research/centered-round5/lean-moment/receipts/Sendov.Analytic.CenteredMomentAudit.json create mode 100644 research/centered-round5/lean-moment/receipts/verification.json create mode 100644 research/centered-round5/lean-moment/verify.py create mode 100644 research/centered-round5/review-global/AUDIT.md create mode 100644 research/centered-round5/review-global/ISSUES.md create mode 100644 research/centered-round5/review-global/cache/exact-verification.json create mode 100644 research/centered-round5/review-global/cache/independent-audit.json create mode 100644 research/centered-round5/review-global/evidence.json create mode 100644 research/centered-round5/review-global/independent_checks.py create mode 100644 research/centered-round5/review-global/source-replay.json create mode 100644 research/centered-round5/reviewed-paper/cutoff35.md create mode 100644 research/centered-verified.zip create mode 100644 research/centered-verified/MANIFEST.json create mode 100644 research/centered-verified/MATH_NOTE.md create mode 100644 research/centered-verified/REPORT.md create mode 100644 research/centered-verified/RESULT.json create mode 100644 research/centered-verified/RESULT.md create mode 100644 research/centered-verified/Sendov/Analytic/PaperCenteredEndpoint.lean create mode 100644 research/centered-verified/Sendov/Analytic/PaperCenteredTail.lean create mode 100644 research/centered-verified/Sendov/Analytic/PaperCenteredVarianceEndpoint.lean create mode 100644 research/centered-verified/envelope.py create mode 100644 research/centered-verified/envelope_results.json create mode 100644 research/centered-verified/finalists.log create mode 100644 research/centered-verified/finalists.py create mode 100644 research/centered-verified/finalists_results.json create mode 100644 research/centered-verified/full_rational_replay.log create mode 100644 research/centered-verified/high_precision.log create mode 100644 research/centered-verified/high_precision.py create mode 100644 research/centered-verified/high_precision_results.json create mode 100644 research/centered-verified/large_precision.log create mode 100644 research/centered-verified/large_precision.py create mode 100644 research/centered-verified/large_precision_results.json create mode 100644 research/centered-verified/lean-logs/centered-audit-final-tests.PaperCenteredVarianceAudit.json create mode 100644 research/centered-verified/lean-logs/centered-audit-final-tests.PaperCenteredVarianceAudit.log create mode 100644 research/centered-verified/lean-logs/centered-endpoint-final-Sendov.Analytic.PaperCenteredEndpoint-kernel.json create mode 100644 research/centered-verified/lean-logs/centered-endpoint-final-Sendov.Analytic.PaperCenteredEndpoint-kernel.log create mode 100644 research/centered-verified/lean-logs/centered-endpoint-final-Sendov.Analytic.PaperCenteredEndpoint.json create mode 100644 research/centered-verified/lean-logs/centered-endpoint-final-Sendov.Analytic.PaperCenteredEndpoint.log create mode 100644 research/centered-verified/lean-logs/centered-final-Sendov.Analytic.PaperCenteredEndpoint-kernel.json create mode 100644 research/centered-verified/lean-logs/centered-final-Sendov.Analytic.PaperCenteredEndpoint-kernel.log create mode 100644 research/centered-verified/lean-logs/centered-final-Sendov.Analytic.PaperCenteredEndpoint.json create mode 100644 research/centered-verified/lean-logs/centered-final-Sendov.Analytic.PaperCenteredEndpoint.log create mode 100644 research/centered-verified/lean-logs/centered-final-tests.PaperCenteredStructural.json create mode 100644 research/centered-verified/lean-logs/centered-final-tests.PaperCenteredStructural.log create mode 100644 research/centered-verified/lean-logs/centered-tail-02-Sendov.Analytic.PaperCenteredTail-kernel.json create mode 100644 research/centered-verified/lean-logs/centered-tail-02-Sendov.Analytic.PaperCenteredTail-kernel.log create mode 100644 research/centered-verified/lean-logs/centered-tail-02-Sendov.Analytic.PaperCenteredTail.json create mode 100644 research/centered-verified/lean-logs/centered-tail-02-Sendov.Analytic.PaperCenteredTail.log create mode 100644 research/centered-verified/lean-logs/centered-variance-01-Sendov.Analytic.PaperCenteredVarianceEndpoint.json create mode 100644 research/centered-verified/lean-logs/centered-variance-01-Sendov.Analytic.PaperCenteredVarianceEndpoint.log create mode 100644 research/centered-verified/lean-logs/centered-variance-final-Sendov.Analytic.PaperCenteredVarianceEndpoint-kernel.json create mode 100644 research/centered-verified/lean-logs/centered-variance-final-Sendov.Analytic.PaperCenteredVarianceEndpoint-kernel.log create mode 100644 research/centered-verified/lean-logs/frozen-final-Sendov.Analytic.PaperCenteredEndpoint-kernel.json create mode 100644 research/centered-verified/lean-logs/frozen-final-Sendov.Analytic.PaperCenteredEndpoint-kernel.log create mode 100644 research/centered-verified/lean-logs/frozen-final-Sendov.Analytic.PaperCenteredEndpoint.json create mode 100644 research/centered-verified/lean-logs/frozen-final-Sendov.Analytic.PaperCenteredEndpoint.log create mode 100644 research/centered-verified/lean-logs/frozen-final-Sendov.Analytic.PaperCenteredTail-kernel.json create mode 100644 research/centered-verified/lean-logs/frozen-final-Sendov.Analytic.PaperCenteredTail-kernel.log create mode 100644 research/centered-verified/lean-logs/frozen-final-Sendov.Analytic.PaperCenteredTail.json create mode 100644 research/centered-verified/lean-logs/frozen-final-Sendov.Analytic.PaperCenteredTail.log create mode 100644 research/centered-verified/lean-logs/frozen-final-Sendov.Analytic.PaperCenteredVarianceEndpoint-kernel.json create mode 100644 research/centered-verified/lean-logs/frozen-final-Sendov.Analytic.PaperCenteredVarianceEndpoint-kernel.log create mode 100644 research/centered-verified/lean-logs/frozen-final-Sendov.Analytic.PaperCenteredVarianceEndpoint.json create mode 100644 research/centered-verified/lean-logs/frozen-final-Sendov.Analytic.PaperCenteredVarianceEndpoint.log create mode 100644 research/centered-verified/lean-logs/frozen-final-tests.PaperCenteredStructural-kernel.json create mode 100644 research/centered-verified/lean-logs/frozen-final-tests.PaperCenteredStructural-kernel.log create mode 100644 research/centered-verified/lean-logs/frozen-final-tests.PaperCenteredStructural.json create mode 100644 research/centered-verified/lean-logs/frozen-final-tests.PaperCenteredStructural.log create mode 100644 research/centered-verified/lean-logs/frozen-final-tests.PaperCenteredVarianceAudit-kernel.json create mode 100644 research/centered-verified/lean-logs/frozen-final-tests.PaperCenteredVarianceAudit-kernel.log create mode 100644 research/centered-verified/lean-logs/frozen-final-tests.PaperCenteredVarianceAudit.json create mode 100644 research/centered-verified/lean-logs/frozen-final-tests.PaperCenteredVarianceAudit.log create mode 100644 research/centered-verified/lean_verification.json create mode 100644 research/centered-verified/optimization.log create mode 100644 research/centered-verified/optimization_results.json create mode 100644 research/centered-verified/optimize.log create mode 100644 research/centered-verified/optimize.py create mode 100644 research/centered-verified/pack.py create mode 100644 research/centered-verified/pack_receipt.json create mode 100644 research/centered-verified/rational.log create mode 100644 research/centered-verified/rational.py create mode 100644 research/centered-verified/rational_results.json create mode 100644 research/centered-verified/scalar_results.json create mode 100644 research/centered-verified/scalar_scan.log create mode 100644 research/centered-verified/scalar_scan.py create mode 100644 research/centered-verified/search.log create mode 100644 research/centered-verified/search.py create mode 100644 research/centered-verified/search_results.json create mode 100644 research/centered-verified/structural_replay.py create mode 100644 research/centered-verified/structural_results.json create mode 100644 research/centered-verified/tests/PaperCenteredStructural.lean create mode 100644 research/centered-verified/tests/PaperCenteredVarianceAudit.lean create mode 100644 research/centered-verified/verification_receipt.json create mode 100644 research/centered-verified/verify.py create mode 100644 research/centered-verified/verify_lean.log create mode 100644 research/centered-verified/verify_lean.py create mode 100644 research/centered/MATH_NOTE.md create mode 100644 research/centered/REPORT.md create mode 100644 research/centered/RESULT.json create mode 100644 research/centered/RESULT.md create mode 100644 research/centered/envelope.py create mode 100644 research/centered/envelope_results.json create mode 100644 research/centered/finalists.log create mode 100644 research/centered/finalists.py create mode 100644 research/centered/high_precision.log create mode 100644 research/centered/high_precision.py create mode 100644 research/centered/high_precision_results.json create mode 100644 research/centered/instability.py create mode 100644 research/centered/instability_regression.json create mode 100644 research/centered/large_precision.log create mode 100644 research/centered/large_precision.py create mode 100644 research/centered/large_precision_results.json create mode 100644 research/centered/optimization.log create mode 100644 research/centered/optimization_precision.log create mode 100644 research/centered/optimization_precision_results.json create mode 100644 research/centered/optimization_results.json create mode 100644 research/centered/optimize.log create mode 100644 research/centered/optimize.py create mode 100644 research/centered/optimized_rational_results.json create mode 100644 research/centered/rational.log create mode 100644 research/centered/rational.py create mode 100644 research/centered/rational_results.json create mode 100644 research/centered/scalar_results.json create mode 100644 research/centered/scalar_scan.log create mode 100644 research/centered/scalar_scan.py create mode 100644 research/centered/search.log create mode 100644 research/centered/search.py create mode 100644 research/centered/search_results.json create mode 100644 research/centered/structural_replay.py create mode 100644 research/centered/structural_results.json create mode 100644 research/centered/verify.log create mode 100644 research/centered/verify.py create mode 100644 research/centered/verify_optimization.py create mode 100644 tests/PaperCenteredStructural.lean create mode 100644 tests/PaperCenteredVarianceAudit.lean diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..645bbce --- /dev/null +++ b/.gitattributes @@ -0,0 +1,2 @@ +# Preserve captured verification logs verbatim, including trailing blank lines. +research/**/*.log -whitespace diff --git a/.gitignore b/.gitignore index bfb30ec..605e5af 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,9 @@ -/.lake +# Build outputs and local dependency environments (including research stages). +.lake/ +.venv/ +__pycache__/ +.pytest_cache/ +.mypy_cache/ +.ruff_cache/ +*.pyc +*.pyo diff --git a/Sendov/Analytic/PaperCenteredEndpoint.lean b/Sendov/Analytic/PaperCenteredEndpoint.lean new file mode 100644 index 0000000..c1e8207 --- /dev/null +++ b/Sendov/Analytic/PaperCenteredEndpoint.lean @@ -0,0 +1,153 @@ +import Sendov.Analytic.PaperCenteredTail +import Sendov.Analytic.PaperPolar +import Mathlib.Data.Nat.Choose.Cast + +/-! # Uniform control of the zeroth centered endpoint +A single binomial term proves the h/2 bound for the zeroth endpoint in every +degree; no finite table or bound on alpha is used. The positive-variance tail +and the second endpoint remain separate obligations. +-/ +noncomputable section +open scoped BigOperators +namespace Sendov.PaperCenteredEndpoint + +lemma binomial_term (n k : ℕ) (hk : k ≤ n) (b : ℝ) + (hb0 : 0 ≤ b) (hb1 : b ≤ 1) : + (n.choose k : ℝ) * (1 - b) ^ k * b ^ (n-k) ≤ 1 := by + have ht := Finset.single_le_sum + (s := Finset.range (n+1)) + (f := fun j => (1-b)^j * b^(n-j) * (n.choose j : ℝ)) + (a := k) (fun j _ => by positivity) (by simp; omega) + have hs := add_pow (1-b) b n + rw [show 1-b+b = 1 by ring, one_pow] at hs + rw [← hs] at ht + nlinarith only [ht] + +/-- Any fixed endpoint order, with the finite binomial factor retained. +This provides arbitrarily high algebraic endpoint decay without a degree table. -/ +theorem endpoint_power_order (m k : ℕ) (hk : k ≤ m + 1) (b L : ℝ) + (hb0 : 0 ≤ b) (hb1 : b ≤ 1) (hL : 0 ≤ L) + (hslope : 3 * b ≤ L * (1 - b)) : + 3^k * ((m+1).choose k : ℝ) * b^(m+1) ≤ L^k := by + have hs := pow_le_pow_left₀ (by positivity : 0 ≤ 3*b) hslope k + have hc := binomial_term (m+1) k hk b hb0 hb1 + have he : b^k*b^(m+1-k) = b^(m+1) := by + rw [← pow_add, Nat.add_sub_of_le hk] + have ht := mul_le_mul_of_nonneg_right hs + (mul_nonneg (Nat.cast_nonneg ((m+1).choose k)) (pow_nonneg hb0 (m+1-k))) + have ht' := mul_le_mul_of_nonneg_left hc (pow_nonneg hL k) + calc + _ = (3*b)^k * (((m+1).choose k : ℝ)*b^(m+1-k)) := by rw [mul_pow, ← he]; ring + _ ≤ (L*(1-b))^k * (((m+1).choose k : ℝ)*b^(m+1-k)) := ht + _ = L^k * (((m+1).choose k : ℝ)*(1-b)^k*b^(m+1-k)) := by rw [mul_pow]; ring + _ ≤ L^k := by simpa only [mul_one] using ht' + +lemma binomial_second_term (n : ℕ) (hn : 2 ≤ n) (b : ℝ) + (hb0 : 0 ≤ b) (hb1 : b ≤ 1) : + (n.choose 2 : ℝ) * (1-b)^2 * b^(n-2) ≤ 1 := by + have ht := Finset.single_le_sum + (s := Finset.range (n+1)) + (f := fun k => (1-b)^k * b^(n-k) * (n.choose k : ℝ)) + (a := 2) (fun k _ => by positivity) (by simp; omega) + have hs := add_pow (1-b) b n + rw [show 1-b+b = 1 by ring, one_pow] at hs + rw [← hs] at ht + nlinarith only [ht] + +/-- The rational polar slope controls the entire zeroth endpoint uniformly. -/ +theorem endpoint_power_half (m : ℕ) (hm : 1 ≤ m) (b h : ℝ) + (hb0 : 0 ≤ b) (hb1 : b ≤ 1) (_hh : 0 ≤ h) + (hslope : 3 * b ≤ (m : ℝ) * h * (1 - b)) : + 4*b^(m+1) ≤ h^2 := by + have hc := binomial_second_term (m+1) (by omega) b hb0 hb1 + have hchoose : ((m+1).choose 2 : ℝ) = (m : ℝ)*((m : ℝ)+1)/2 := by + rw [Nat.cast_choose_two] + push_cast + ring + have he : b^2*b^(m-1) = b^(m+1) := by + rw [← pow_add] + congr 1 + omega + have hs : 9*b^2 ≤ (m : ℝ)^2*h^2*(1-b)^2 := by + have hp := mul_self_le_mul_self (by positivity : 0 ≤ 3*b) hslope + nlinarith only [hp] + have hm0 : (0 : ℝ) < m := by exact_mod_cast (show 0 < m by omega) + have hn : 0 ≤ ((m+1).choose 2 : ℝ) := Nat.cast_nonneg _ + have hs' := mul_le_mul_of_nonneg_right hs (mul_nonneg hn (pow_nonneg hb0 (m-1))) + have hc' := mul_le_mul_of_nonneg_left hc (by positivity : 0 ≤ (m : ℝ)^2*h^2) + have hbpow : 9*((m+1).choose 2 : ℝ)*b^(m+1) ≤ (m : ℝ)^2*h^2 := by + calc + _ = (9*b^2)*(((m+1).choose 2 : ℝ)*b^(m-1)) := by rw [← he]; ring + _ ≤ ((m : ℝ)^2*h^2*(1-b)^2)*(((m+1).choose 2 : ℝ)*b^(m-1)) := hs' + _ = (m : ℝ)^2*h^2 * (((m+1).choose 2 : ℝ)*(1-b)^2*b^(m-1)) := by ring + _ ≤ (m : ℝ)^2*h^2 := by + simpa only [show m+1-2 = m-1 by omega, mul_one] using hc' + have hcoef : 4*(m : ℝ)^2 ≤ 9*((m+1).choose 2 : ℝ) := by rw [hchoose]; nlinarith + have ht := (mul_le_mul_of_nonneg_right hcoef (pow_nonneg hb0 (m+1))).trans hbpow + have hcancel : (m : ℝ)^2*(4*b^(m+1)) ≤ (m : ℝ)^2*h^2 := by nlinarith only [ht] + exact (mul_le_mul_iff_right₀ (sq_pos_of_pos hm0)).mp (by simpa only [mul_comm] using hcancel) + +/-- A norm endpoint form, suitable for actual complex means. -/ +theorem norm_endpoint_half (m : ℕ) (hm : 1 ≤ m) (z : ℂ) (b h : ℝ) + (hb0 : 0 ≤ b) (hb1 : b ≤ 1) (hh : 0 ≤ h) + (hslope : 3 * b ≤ (m : ℝ) * h * (1 - b)) (hz : ‖1 - z‖ ^ 2 ≤ b) : + ‖1-z‖^(m+1) ≤ h/2 := by + have hp := pow_le_pow_left₀ (sq_nonneg ‖1-z‖) hz (m+1) + have he : (‖1-z‖^2)^(m+1) = (‖1-z‖^(m+1))^2 := by rw [← pow_mul, ← pow_mul]; congr 1; omega + rw [he] at hp + have hb := endpoint_power_half m hm b h hb0 hb1 hh hslope + nlinarith only [hp, hb, hh, pow_nonneg (norm_nonneg (1-z)) (m+1)] + +/-- The actual complex endpoint is at most h/2 on raw polar, uniformly in degree. +In fact the proof only needs 0