Users' Mathboxes Mathbox for Thierry Arnoux < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >   Mathboxes  >  ballotlemrinv0 Structured version   Visualization version   GIF version

Theorem ballotlemrinv0 30824
Description: Lemma for ballotlemrinv 30825. (Contributed by Thierry Arnoux, 18-Apr-2017.)
Hypotheses
Ref Expression
ballotth.m 𝑀 ∈ ℕ
ballotth.n 𝑁 ∈ ℕ
ballotth.o 𝑂 = {𝑐 ∈ 𝒫 (1...(𝑀 + 𝑁)) ∣ (♯‘𝑐) = 𝑀}
ballotth.p 𝑃 = (𝑥 ∈ 𝒫 𝑂 ↦ ((♯‘𝑥) / (♯‘𝑂)))
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
ballotlemrinv0 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → (𝐷 ∈ (𝑂𝐸) ∧ 𝐶 = ((𝑆𝐷) “ 𝐷)))
Distinct variable groups:   𝑀,𝑐   𝑁,𝑐   𝑂,𝑐   𝑖,𝑀   𝑖,𝑁   𝑖,𝑂   𝑘,𝑀   𝑘,𝑁   𝑘,𝑂   𝑖,𝑐,𝐹,𝑘   𝐶,𝑖,𝑘   𝑖,𝐸,𝑘   𝐶,𝑘   𝑘,𝐼,𝑐   𝐸,𝑐   𝑖,𝐼,𝑐   𝑆,𝑘   𝐷,𝑖,𝑘   𝑆,𝑖,𝑐   𝑅,𝑖,𝑘   𝑥,𝑐   𝑥,𝐶   𝑥,𝐹   𝑥,𝑀   𝑥,𝑁,𝑖,𝑘
Allowed substitution hints:   𝐶(𝑐)   𝐷(𝑥,𝑐)   𝑃(𝑥,𝑖,𝑘,𝑐)   𝑅(𝑥,𝑐)   𝑆(𝑥)   𝐸(𝑥)   𝐼(𝑥)   𝑂(𝑥)

Proof of Theorem ballotlemrinv0
StepHypRef Expression
1 ballotth.m . . . . . 6 𝑀 ∈ ℕ
2 ballotth.n . . . . . 6 𝑁 ∈ ℕ
3 ballotth.o . . . . . 6 𝑂 = {𝑐 ∈ 𝒫 (1...(𝑀 + 𝑁)) ∣ (♯‘𝑐) = 𝑀}
4 ballotth.p . . . . . 6 𝑃 = (𝑥 ∈ 𝒫 𝑂 ↦ ((♯‘𝑥) / (♯‘𝑂)))
5 ballotth.f . . . . . 6 𝐹 = (𝑐𝑂 ↦ (𝑖 ∈ ℤ ↦ ((♯‘((1...𝑖) ∩ 𝑐)) − (♯‘((1...𝑖) ∖ 𝑐)))))
6 ballotth.e . . . . . 6 𝐸 = {𝑐𝑂 ∣ ∀𝑖 ∈ (1...(𝑀 + 𝑁))0 < ((𝐹𝑐)‘𝑖)}
7 ballotth.mgtn . . . . . 6 𝑁 < 𝑀
8 ballotth.i . . . . . 6 𝐼 = (𝑐 ∈ (𝑂𝐸) ↦ inf({𝑘 ∈ (1...(𝑀 + 𝑁)) ∣ ((𝐹𝑐)‘𝑘) = 0}, ℝ, < ))
9 ballotth.s . . . . . 6 𝑆 = (𝑐 ∈ (𝑂𝐸) ↦ (𝑖 ∈ (1...(𝑀 + 𝑁)) ↦ if(𝑖 ≤ (𝐼𝑐), (((𝐼𝑐) + 1) − 𝑖), 𝑖)))
10 ballotth.r . . . . . 6 𝑅 = (𝑐 ∈ (𝑂𝐸) ↦ ((𝑆𝑐) “ 𝑐))
111, 2, 3, 4, 5, 6, 7, 8, 9, 10ballotlemrval 30809 . . . . 5 (𝐶 ∈ (𝑂𝐸) → (𝑅𝐶) = ((𝑆𝐶) “ 𝐶))
1211adantr 472 . . . 4 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → (𝑅𝐶) = ((𝑆𝐶) “ 𝐶))
13 simpr 479 . . . 4 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → 𝐷 = ((𝑆𝐶) “ 𝐶))
1412, 13eqtr4d 2761 . . 3 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → (𝑅𝐶) = 𝐷)
151, 2, 3, 4, 5, 6, 7, 8, 9, 10ballotlemrc 30822 . . . 4 (𝐶 ∈ (𝑂𝐸) → (𝑅𝐶) ∈ (𝑂𝐸))
1615adantr 472 . . 3 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → (𝑅𝐶) ∈ (𝑂𝐸))
1714, 16eqeltrrd 2804 . 2 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → 𝐷 ∈ (𝑂𝐸))
181, 2, 3, 4, 5, 6, 7, 8, 9ballotlemsf1o 30805 . . . . . . 7 (𝐶 ∈ (𝑂𝐸) → ((𝑆𝐶):(1...(𝑀 + 𝑁))–1-1-onto→(1...(𝑀 + 𝑁)) ∧ (𝑆𝐶) = (𝑆𝐶)))
1918simprd 482 . . . . . 6 (𝐶 ∈ (𝑂𝐸) → (𝑆𝐶) = (𝑆𝐶))
2019adantr 472 . . . . 5 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → (𝑆𝐶) = (𝑆𝐶))
2120eqcomd 2730 . . . 4 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → (𝑆𝐶) = (𝑆𝐶))
2221, 13imaeq12d 5577 . . 3 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → ((𝑆𝐶) “ 𝐷) = ((𝑆𝐶) “ ((𝑆𝐶) “ 𝐶)))
23 simpl 474 . . . . 5 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → 𝐶 ∈ (𝑂𝐸))
241, 2, 3, 4, 5, 6, 7, 8, 9, 10ballotlemirc 30823 . . . . . . 7 (𝐶 ∈ (𝑂𝐸) → (𝐼‘(𝑅𝐶)) = (𝐼𝐶))
2524adantr 472 . . . . . 6 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → (𝐼‘(𝑅𝐶)) = (𝐼𝐶))
2614fveq2d 6308 . . . . . 6 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → (𝐼‘(𝑅𝐶)) = (𝐼𝐷))
2725, 26eqtr3d 2760 . . . . 5 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → (𝐼𝐶) = (𝐼𝐷))
281, 2, 3, 4, 5, 6, 7, 8, 9ballotlemieq 30808 . . . . 5 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 ∈ (𝑂𝐸) ∧ (𝐼𝐶) = (𝐼𝐷)) → (𝑆𝐶) = (𝑆𝐷))
2923, 17, 27, 28syl3anc 1439 . . . 4 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → (𝑆𝐶) = (𝑆𝐷))
3029imaeq1d 5575 . . 3 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → ((𝑆𝐶) “ 𝐷) = ((𝑆𝐷) “ 𝐷))
3118simpld 477 . . . . 5 (𝐶 ∈ (𝑂𝐸) → (𝑆𝐶):(1...(𝑀 + 𝑁))–1-1-onto→(1...(𝑀 + 𝑁)))
32 f1of1 6249 . . . . 5 ((𝑆𝐶):(1...(𝑀 + 𝑁))–1-1-onto→(1...(𝑀 + 𝑁)) → (𝑆𝐶):(1...(𝑀 + 𝑁))–1-1→(1...(𝑀 + 𝑁)))
3323, 31, 323syl 18 . . . 4 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → (𝑆𝐶):(1...(𝑀 + 𝑁))–1-1→(1...(𝑀 + 𝑁)))
34 eldifi 3840 . . . . 5 (𝐶 ∈ (𝑂𝐸) → 𝐶𝑂)
351, 2, 3ballotlemelo 30779 . . . . . 6 (𝐶𝑂 ↔ (𝐶 ⊆ (1...(𝑀 + 𝑁)) ∧ (♯‘𝐶) = 𝑀))
3635simplbi 478 . . . . 5 (𝐶𝑂𝐶 ⊆ (1...(𝑀 + 𝑁)))
3723, 34, 363syl 18 . . . 4 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → 𝐶 ⊆ (1...(𝑀 + 𝑁)))
38 f1imacnv 6266 . . . 4 (((𝑆𝐶):(1...(𝑀 + 𝑁))–1-1→(1...(𝑀 + 𝑁)) ∧ 𝐶 ⊆ (1...(𝑀 + 𝑁))) → ((𝑆𝐶) “ ((𝑆𝐶) “ 𝐶)) = 𝐶)
3933, 37, 38syl2anc 696 . . 3 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → ((𝑆𝐶) “ ((𝑆𝐶) “ 𝐶)) = 𝐶)
4022, 30, 393eqtr3rd 2767 . 2 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → 𝐶 = ((𝑆𝐷) “ 𝐷))
4117, 40jca 555 1 ((𝐶 ∈ (𝑂𝐸) ∧ 𝐷 = ((𝑆𝐶) “ 𝐶)) → (𝐷 ∈ (𝑂𝐸) ∧ 𝐶 = ((𝑆𝐷) “ 𝐷)))
Colors of variables: wff setvar class
Syntax hints:  wi 4  wa 383   = wceq 1596  wcel 2103  wral 3014  {crab 3018  cdif 3677  cin 3679  wss 3680  ifcif 4194  𝒫 cpw 4266   class class class wbr 4760  cmpt 4837  ccnv 5217  cima 5221  1-1wf1 5998  1-1-ontowf1o 6000  cfv 6001  (class class class)co 6765  infcinf 8463  cr 10048  0cc0 10049  1c1 10050   + caddc 10052   < clt 10187  cle 10188  cmin 10379   / cdiv 10797  cn 11133  cz 11490  ...cfz 12440  chash 13232
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1835  ax-4 1850  ax-5 1952  ax-6 2018  ax-7 2054  ax-8 2105  ax-9 2112  ax-10 2132  ax-11 2147  ax-12 2160  ax-13 2355  ax-ext 2704  ax-rep 4879  ax-sep 4889  ax-nul 4897  ax-pow 4948  ax-pr 5011  ax-un 7066  ax-cnex 10105  ax-resscn 10106  ax-1cn 10107  ax-icn 10108  ax-addcl 10109  ax-addrcl 10110  ax-mulcl 10111  ax-mulrcl 10112  ax-mulcom 10113  ax-addass 10114  ax-mulass 10115  ax-distr 10116  ax-i2m1 10117  ax-1ne0 10118  ax-1rid 10119  ax-rnegex 10120  ax-rrecex 10121  ax-cnre 10122  ax-pre-lttri 10123  ax-pre-lttrn 10124  ax-pre-ltadd 10125  ax-pre-mulgt0 10126
This theorem depends on definitions:  df-bi 197  df-or 384  df-an 385  df-3or 1073  df-3an 1074  df-tru 1599  df-ex 1818  df-nf 1823  df-sb 2011  df-eu 2575  df-mo 2576  df-clab 2711  df-cleq 2717  df-clel 2720  df-nfc 2855  df-ne 2897  df-nel 3000  df-ral 3019  df-rex 3020  df-reu 3021  df-rmo 3022  df-rab 3023  df-v 3306  df-sbc 3542  df-csb 3640  df-dif 3683  df-un 3685  df-in 3687  df-ss 3694  df-pss 3696  df-nul 4024  df-if 4195  df-pw 4268  df-sn 4286  df-pr 4288  df-tp 4290  df-op 4292  df-uni 4545  df-int 4584  df-iun 4630  df-br 4761  df-opab 4821  df-mpt 4838  df-tr 4861  df-id 5128  df-eprel 5133  df-po 5139  df-so 5140  df-fr 5177  df-we 5179  df-xp 5224  df-rel 5225  df-cnv 5226  df-co 5227  df-dm 5228  df-rn 5229  df-res 5230  df-ima 5231  df-pred 5793  df-ord 5839  df-on 5840  df-lim 5841  df-suc 5842  df-iota 5964  df-fun 6003  df-fn 6004  df-f 6005  df-f1 6006  df-fo 6007  df-f1o 6008  df-fv 6009  df-riota 6726  df-ov 6768  df-oprab 6769  df-mpt2 6770  df-om 7183  df-1st 7285  df-2nd 7286  df-wrecs 7527  df-recs 7588  df-rdg 7626  df-1o 7680  df-oadd 7684  df-er 7862  df-en 8073  df-dom 8074  df-sdom 8075  df-fin 8076  df-sup 8464  df-inf 8465  df-card 8878  df-cda 9103  df-pnf 10189  df-mnf 10190  df-xr 10191  df-ltxr 10192  df-le 10193  df-sub 10381  df-neg 10382  df-nn 11134  df-2 11192  df-n0 11406  df-z 11491  df-uz 11801  df-rp 11947  df-fz 12441  df-hash 13233
This theorem is referenced by:  ballotlemrinv  30825
  Copyright terms: Public domain W3C validator