ILE Home Intuitionistic Logic Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  ILE Home  >  Th. List  >  ballotfilemirc GIF version

Theorem ballotfilemirc 13338
Description: Applying 𝑅 does not change first ties. (Contributed by Thierry Arnoux, 19-Apr-2017.) (Revised by AV, 6-Oct-2020.)
Hypotheses
Ref Expression
ballotth.m 𝑀 ∈ ℕ
ballotth.n 𝑁 ∈ ℕ
ballotfilem.o 𝑂 = {𝑐 ∈ (𝒫 (1...(𝑀 + 𝑁)) ∩ Fin) ∣ (♯‘𝑐) = 𝑀}
ballotfilem.p 𝑃 = (𝑥 ∈ (𝒫 𝑂 ∩ Fin) ↦ ((♯‘𝑥) / (♯‘𝑂)))
ballotth.f 𝐹 = (𝑐 ∈ 𝑂 ↦ (𝑖 ∈ ℤ ↦ ((♯‘((1...𝑖) ∩ 𝑐)) − (♯‘((1...𝑖) ∖ 𝑐)))))
ballotth.e 𝐸 = {𝑐 ∈ 𝑂 ∣ ∀𝑖 ∈ (1...(𝑀 + 𝑁))0 < ((𝐹‘𝑐)‘𝑖)}
ballotth.mgtn 𝑁 < 𝑀
ballotth.i 𝐼 = (𝑐 ∈ (𝑂 ∖ 𝐸) ↦ inf({𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘𝑐)‘𝑘) = 0}, ℝ, < ))
ballotth.s 𝑆 = (𝑐 ∈ (𝑂 ∖ 𝐸) ↦ (𝑖 ∈ (1...(𝑀 + 𝑁)) ↦ if(𝑖 ≤ (𝐼‘𝑐), (((𝐼‘𝑐) + 1) − 𝑖), 𝑖)))
ballotth.r 𝑅 = (𝑐 ∈ (𝑂 ∖ 𝐸) ↦ ((𝑆‘𝑐) “ 𝑐))
Assertion
Ref Expression
ballotfilemirc (𝐶 ∈ (𝑂 ∖ 𝐸) → (𝐼‘(𝑅‘𝐶)) = (𝐼‘𝐶))
Distinct variable groups:   𝑀,𝑐   𝑁,𝑐   𝑂,𝑐   𝑖,𝑀   𝑖,𝑁   𝑖,𝑂   𝑘,𝑀   𝑘,𝑁   𝑘,𝑂   𝑖,𝑐,𝐹,𝑘   𝐶,𝑖,𝑘   𝑖,𝐸,𝑘   𝐶,𝑘   𝑘,𝐼,𝑐   𝐸,𝑐   𝑖,𝐼,𝑐   𝑆,𝑘,𝑖,𝑐   𝑅,𝑖,𝑘   𝑥,𝑘,𝐶   𝑥,𝐹   𝑥,𝑀   𝑥,𝑁
Allowed substitution hints:   𝐶(𝑐)   𝑃(𝑥, 𝑖, 𝑘, 𝑐)   𝑅(𝑥, 𝑐)   𝑆(𝑥)   𝐸(𝑥)   𝐼(𝑥)   𝑂(𝑥)

Proof of Theorem ballotfilemirc
Dummy variables 𝑦 𝑣 𝑢 𝑝 𝑞 are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 ballotth.m . . . 4 𝑀 ∈ ℕ
2 ballotth.n . . . 4 𝑁 ∈ ℕ
3 ballotfilem.o . . . 4 𝑂 = {𝑐 ∈ (𝒫 (1...(𝑀 + 𝑁)) ∩ Fin) ∣ (♯‘𝑐) = 𝑀}
4 ballotfilem.p . . . 4 𝑃 = (𝑥 ∈ (𝒫 𝑂 ∩ Fin) ↦ ((♯‘𝑥) / (♯‘𝑂)))
5 ballotth.f . . . 4 𝐹 = (𝑐 ∈ 𝑂 ↦ (𝑖 ∈ ℤ ↦ ((♯‘((1...𝑖) ∩ 𝑐)) − (♯‘((1...𝑖) ∖ 𝑐)))))
6 ballotth.e . . . 4 𝐸 = {𝑐 ∈ 𝑂 ∣ ∀𝑖 ∈ (1...(𝑀 + 𝑁))0 < ((𝐹‘𝑐)‘𝑖)}
7 ballotth.mgtn . . . 4 𝑁 < 𝑀
8 ballotth.i . . . 4 𝐼 = (𝑐 ∈ (𝑂 ∖ 𝐸) ↦ inf({𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘𝑐)‘𝑘) = 0}, ℝ, < ))
9 ballotth.s . . . 4 𝑆 = (𝑐 ∈ (𝑂 ∖ 𝐸) ↦ (𝑖 ∈ (1...(𝑀 + 𝑁)) ↦ if(𝑖 ≤ (𝐼‘𝑐), (((𝐼‘𝑐) + 1) − 𝑖), 𝑖)))
10 ballotth.r . . . 4 𝑅 = (𝑐 ∈ (𝑂 ∖ 𝐸) ↦ ((𝑆‘𝑐) “ 𝑐))
111, 2, 3, 4, 5, 6, 7, 8, 9, 10ballotfilemrc 13337 . . 3 (𝐶 ∈ (𝑂 ∖ 𝐸) → (𝑅‘𝐶) ∈ (𝑂 ∖ 𝐸))
121, 2, 3, 4, 5, 6, 7, 8ballotfilemi 13306 . . 3 ((𝑅‘𝐶) ∈ (𝑂 ∖ 𝐸) → (𝐼‘(𝑅‘𝐶)) = inf({𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘(𝑅‘𝐶))‘𝑘) = 0}, ℝ, < ))
1311, 12syl 14 . 2 (𝐶 ∈ (𝑂 ∖ 𝐸) → (𝐼‘(𝑅‘𝐶)) = inf({𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘(𝑅‘𝐶))‘𝑘) = 0}, ℝ, < ))
14 lttri3 8417 . . . 4 ((𝑝 ∈ ℝ ∧ 𝑞 ∈ ℝ) → (𝑝 = 𝑞 ↔ (¬ 𝑝 < 𝑞 ∧ ¬ 𝑞 < 𝑝)))
1514adantl 277 . . 3 ((𝐶 ∈ (𝑂 ∖ 𝐸) ∧ (𝑝 ∈ ℝ ∧ 𝑞 ∈ ℝ)) → (𝑝 = 𝑞 ↔ (¬ 𝑝 < 𝑞 ∧ ¬ 𝑞 < 𝑝)))
161, 2, 3, 4, 5, 6, 7, 8ballotfilemiex 13307 . . . . . 6 (𝐶 ∈ (𝑂 ∖ 𝐸) → ((𝐼‘𝐶) ∈ (1...(𝑀 + 𝑁)) ∧ ((𝐹‘𝐶)‘(𝐼‘𝐶)) = 0))
1716simpld 112 . . . . 5 (𝐶 ∈ (𝑂 ∖ 𝐸) → (𝐼‘𝐶) ∈ (1...(𝑀 + 𝑁)))
1817elfzelzd 10451 . . . 4 (𝐶 ∈ (𝑂 ∖ 𝐸) → (𝐼‘𝐶) ∈ ℤ)
1918zred 9784 . . 3 (𝐶 ∈ (𝑂 ∖ 𝐸) → (𝐼‘𝐶) ∈ ℝ)
20 fveqeq2 5711 . . . 4 (𝑘 = (𝐼‘𝐶) → (((𝐹‘(𝑅‘𝐶))‘𝑘) = 0 ↔ ((𝐹‘(𝑅‘𝐶))‘(𝐼‘𝐶)) = 0))
21 eqid 2238 . . . . 5 (𝑢 ∈ 𝑂, 𝑣 ∈ Fin ↦ ((♯‘(𝑣 ∩ 𝑢)) − (♯‘(𝑣 ∖ 𝑢)))) = (𝑢 ∈ 𝑂, 𝑣 ∈ Fin ↦ ((♯‘(𝑣 ∩ 𝑢)) − (♯‘(𝑣 ∖ 𝑢))))
221, 2, 3, 4, 5, 6, 7, 8, 9, 10, 21ballotfilemfrci 13334 . . . 4 (𝐶 ∈ (𝑂 ∖ 𝐸) → ((𝐹‘(𝑅‘𝐶))‘(𝐼‘𝐶)) = 0)
2320, 17, 22elrabd 2984 . . 3 (𝐶 ∈ (𝑂 ∖ 𝐸) → (𝐼‘𝐶) ∈ {𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘(𝑅‘𝐶))‘𝑘) = 0})
24 elrabi 2979 . . . . 5 (𝑦 ∈ {𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘(𝑅‘𝐶))‘𝑘) = 0} → 𝑦 ∈ (1...(𝑀 + 𝑁)))
2524anim2i 342 . . . 4 ((𝐶 ∈ (𝑂 ∖ 𝐸) ∧ 𝑦 ∈ {𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘(𝑅‘𝐶))‘𝑘) = 0}) → (𝐶 ∈ (𝑂 ∖ 𝐸) ∧ 𝑦 ∈ (1...(𝑀 + 𝑁))))
261, 2, 3, 4, 5, 6, 7, 8, 9, 10ballotfilemfrcn0 13336 . . . . . . . . 9 ((𝐶 ∈ (𝑂 ∖ 𝐸) ∧ 𝑦 ∈ (1...(𝑀 + 𝑁)) ∧ 𝑦 < (𝐼‘𝐶)) → ((𝐹‘(𝑅‘𝐶))‘𝑦) ≠ 0)
2726neneqd 2441 . . . . . . . 8 ((𝐶 ∈ (𝑂 ∖ 𝐸) ∧ 𝑦 ∈ (1...(𝑀 + 𝑁)) ∧ 𝑦 < (𝐼‘𝐶)) → ¬ ((𝐹‘(𝑅‘𝐶))‘𝑦) = 0)
28 fveqeq2 5711 . . . . . . . . . 10 (𝑘 = 𝑦 → (((𝐹‘(𝑅‘𝐶))‘𝑘) = 0 ↔ ((𝐹‘(𝑅‘𝐶))‘𝑦) = 0))
2928elrab 2982 . . . . . . . . 9 (𝑦 ∈ {𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘(𝑅‘𝐶))‘𝑘) = 0} ↔ (𝑦 ∈ (1...(𝑀 + 𝑁)) ∧ ((𝐹‘(𝑅‘𝐶))‘𝑦) = 0))
3029simprbi 275 . . . . . . . 8 (𝑦 ∈ {𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘(𝑅‘𝐶))‘𝑘) = 0} → ((𝐹‘(𝑅‘𝐶))‘𝑦) = 0)
3127, 30nsyl 637 . . . . . . 7 ((𝐶 ∈ (𝑂 ∖ 𝐸) ∧ 𝑦 ∈ (1...(𝑀 + 𝑁)) ∧ 𝑦 < (𝐼‘𝐶)) → ¬ 𝑦 ∈ {𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘(𝑅‘𝐶))‘𝑘) = 0})
32313expia 1236 . . . . . 6 ((𝐶 ∈ (𝑂 ∖ 𝐸) ∧ 𝑦 ∈ (1...(𝑀 + 𝑁))) → (𝑦 < (𝐼‘𝐶) → ¬ 𝑦 ∈ {𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘(𝑅‘𝐶))‘𝑘) = 0}))
3332con2d 633 . . . . 5 ((𝐶 ∈ (𝑂 ∖ 𝐸) ∧ 𝑦 ∈ (1...(𝑀 + 𝑁))) → (𝑦 ∈ {𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘(𝑅‘𝐶))‘𝑘) = 0} → ¬ 𝑦 < (𝐼‘𝐶)))
3433imp 124 . . . 4 (((𝐶 ∈ (𝑂 ∖ 𝐸) ∧ 𝑦 ∈ (1...(𝑀 + 𝑁))) ∧ 𝑦 ∈ {𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘(𝑅‘𝐶))‘𝑘) = 0}) → ¬ 𝑦 < (𝐼‘𝐶))
3525, 34sylancom 424 . . 3 ((𝐶 ∈ (𝑂 ∖ 𝐸) ∧ 𝑦 ∈ {𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘(𝑅‘𝐶))‘𝑘) = 0}) → ¬ 𝑦 < (𝐼‘𝐶))
3615, 19, 23, 35infminti 7379 . 2 (𝐶 ∈ (𝑂 ∖ 𝐸) → inf({𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹‘(𝑅‘𝐶))‘𝑘) = 0}, ℝ, < ) = (𝐼‘𝐶))
3713, 36eqtrd 2271 1 (𝐶 ∈ (𝑂 ∖ 𝐸) → (𝐼‘(𝑅‘𝐶)) = (𝐼‘𝐶))
Colors of variables:    wff set class
This proof depends on syntax axioms:  ¬ wn 3   → wi 4   ∧ wa 104   ↔ wb 105   ∧ w3a 1009   = wceq 1402   ∈ wcel 2209  ∀wral 2528  {crab 2532   ∖ cdif 3217   ∩ cin 3219  ifcif 3638  𝒫 cpw 3688   class class class wbr 4131   ↦ cmpt 4193   “ cima 4779  ‘cfv 5384  (class class class)co 6092   ∈ cmpo 6094  Fincfn 7033  infcinf 7335  ℝcr 8190  0cc0 8191  1c1 8192   + caddc 8194   < clt 8372   ≤ cle 8373   − cmin 8510   / cdiv 9016  ℕcn 9319  ℤcz 9659  ...cfz 10433  ♯chash 11241
This proof depends on axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-ia1 106  ax-ia2 107  ax-ia3 108  ax-in1 623  ax-in2 624  ax-io 721  ax-5 1500  ax-7 1501  ax-gen 1502  ax-ie1 1546  ax-ie2 1547  ax-8 1557  ax-10 1558  ax-11 1559  ax-i12 1560  ax-bndl 1562  ax-4 1563  ax-17 1579  ax-i9 1583  ax-ial 1587  ax-i5r 1588  ax-14 2212  ax-ext 2220  ax-coll 4248  ax-sep 4251  ax-nul 4261  ax-pow 4313  ax-pr 4348  ax-un 4580  ax-setind 4686  ax-iinf 4737  ax-cnex 8282  ax-resscn 8283  ax-1cn 8284  ax-1re 8285  ax-icn 8286  ax-addcl 8287  ax-addrcl 8288  ax-mulcl 8289  ax-mulrcl 8290  ax-addcom 8291  ax-mulcom 8292  ax-addass 8293  ax-mulass 8294  ax-distr 8295  ax-i2m1 8296  ax-0lt1 8297  ax-1rid 8298  ax-0id 8299  ax-rnegex 8300  ax-precex 8301  ax-cnre 8302  ax-pre-ltirr 8303  ax-pre-ltwlin 8304  ax-pre-lttrn 8305  ax-pre-apti 8306  ax-pre-ltadd 8307  ax-pre-mulgt0 8308  ax-pre-mulext 8309
This proof depends on definitions:  df-bi 117  df-dc 847  df-3or 1010  df-3an 1011  df-tru 1405  df-fal 1408  df-nf 1514  df-sb 1816  df-eu 2089  df-mo 2090  df-clab 2225  df-cleq 2231  df-clel 2234  df-nfc 2381  df-ne 2421  df-nel 2516  df-ral 2533  df-rex 2534  df-reu 2535  df-rmo 2536  df-rab 2537  df-v 2823  df-sbc 3052  df-csb 3148  df-dif 3222  df-un 3224  df-in 3226  df-ss 3233  df-nul 3521  df-if 3639  df-pw 3690  df-sn 3715  df-pr 3716  df-op 3718  df-uni 3936  df-int 3971  df-iun 4014  df-br 4132  df-opab 4194  df-mpt 4195  df-tr 4232  df-id 4440  df-po 4443  df-iso 4444  df-iord 4513  df-on 4515  df-ilim 4516  df-suc 4518  df-iom 4740  df-xp 4782  df-rel 4783  df-cnv 4784  df-co 4785  df-dm 4786  df-rn 4787  df-res 4788  df-ima 4789  df-iota 5344  df-fun 5386  df-fn 5387  df-f 5388  df-f1 5389  df-fo 5390  df-f1o 5391  df-fv 5392  df-isom 5393  df-riota 6045  df-ov 6095  df-oprab 6096  df-mpo 6097  df-1st 6382  df-2nd 6383  df-recs 6586  df-irdg 6651  df-frec 6672  df-1o 6697  df-oadd 6701  df-er 6817  df-en 7034  df-dom 7035  df-fin 7036  df-sup 7336  df-inf 7337  df-pnf 8374  df-mnf 8375  df-xr 8376  df-ltxr 8377  df-le 8378  df-sub 8512  df-neg 8513  df-reap 8917  df-ap 8924  df-div 9017  df-inn 9320  df-2 9378  df-n0 9581  df-z 9660  df-uz 9943  df-q 10041  df-rp 10077  df-fz 10434  df-fzo 10572  df-ihash 11242
This theorem is used by:  ballotfilemrinv0  13339
  Copyright terms: Public domain W3C validator