MPE Home Metamath Proof Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >  indexfi Structured version   Visualization version   GIF version

Theorem indexfi 8134
Description: If for every element of a finite indexing set 𝐴 there exists a corresponding element of another set 𝐵, then there exists a finite subset of 𝐵 consisting only of those elements which are indexed by 𝐴. Proven without the Axiom of Choice, unlike indexdom 32495. (Contributed by Jeff Madsen, 2-Sep-2009.) (Proof shortened by Mario Carneiro, 12-Sep-2015.)
Assertion
Ref Expression
indexfi ((𝐴 ∈ Fin ∧ 𝐵𝑀 ∧ ∀𝑥𝐴𝑦𝐵 𝜑) → ∃𝑐 ∈ Fin (𝑐𝐵 ∧ ∀𝑥𝐴𝑦𝑐 𝜑 ∧ ∀𝑦𝑐𝑥𝐴 𝜑))
Distinct variable groups:   𝑥,𝑐,𝑦,𝐴   𝐵,𝑐,𝑥,𝑦   𝜑,𝑐
Allowed substitution hints:   𝜑(𝑥,𝑦)   𝑀(𝑥,𝑦,𝑐)

Proof of Theorem indexfi
Dummy variables 𝑓 𝑤 𝑧 are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 nfv 1829 . . . . . 6 𝑧𝜑
2 nfsbc1v 3421 . . . . . 6 𝑦[𝑧 / 𝑦]𝜑
3 sbceq1a 3412 . . . . . 6 (𝑦 = 𝑧 → (𝜑[𝑧 / 𝑦]𝜑))
41, 2, 3cbvrex 3143 . . . . 5 (∃𝑦𝐵 𝜑 ↔ ∃𝑧𝐵 [𝑧 / 𝑦]𝜑)
54ralbii 2962 . . . 4 (∀𝑥𝐴𝑦𝐵 𝜑 ↔ ∀𝑥𝐴𝑧𝐵 [𝑧 / 𝑦]𝜑)
6 dfsbcq 3403 . . . . 5 (𝑧 = (𝑓𝑥) → ([𝑧 / 𝑦]𝜑[(𝑓𝑥) / 𝑦]𝜑))
76ac6sfi 8066 . . . 4 ((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑧𝐵 [𝑧 / 𝑦]𝜑) → ∃𝑓(𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑))
85, 7sylan2b 490 . . 3 ((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) → ∃𝑓(𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑))
9 simpll 785 . . . . 5 (((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) → 𝐴 ∈ Fin)
10 ffn 5944 . . . . . . 7 (𝑓:𝐴𝐵𝑓 Fn 𝐴)
1110ad2antrl 759 . . . . . 6 (((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) → 𝑓 Fn 𝐴)
12 dffn4 6019 . . . . . 6 (𝑓 Fn 𝐴𝑓:𝐴onto→ran 𝑓)
1311, 12sylib 206 . . . . 5 (((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) → 𝑓:𝐴onto→ran 𝑓)
14 fofi 8112 . . . . 5 ((𝐴 ∈ Fin ∧ 𝑓:𝐴onto→ran 𝑓) → ran 𝑓 ∈ Fin)
159, 13, 14syl2anc 690 . . . 4 (((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) → ran 𝑓 ∈ Fin)
16 frn 5952 . . . . 5 (𝑓:𝐴𝐵 → ran 𝑓𝐵)
1716ad2antrl 759 . . . 4 (((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) → ran 𝑓𝐵)
18 fnfvelrn 6249 . . . . . . . . 9 ((𝑓 Fn 𝐴𝑥𝐴) → (𝑓𝑥) ∈ ran 𝑓)
1910, 18sylan 486 . . . . . . . 8 ((𝑓:𝐴𝐵𝑥𝐴) → (𝑓𝑥) ∈ ran 𝑓)
20 rspesbca 3485 . . . . . . . . 9 (((𝑓𝑥) ∈ ran 𝑓[(𝑓𝑥) / 𝑦]𝜑) → ∃𝑦 ∈ ran 𝑓𝜑)
2120ex 448 . . . . . . . 8 ((𝑓𝑥) ∈ ran 𝑓 → ([(𝑓𝑥) / 𝑦]𝜑 → ∃𝑦 ∈ ran 𝑓𝜑))
2219, 21syl 17 . . . . . . 7 ((𝑓:𝐴𝐵𝑥𝐴) → ([(𝑓𝑥) / 𝑦]𝜑 → ∃𝑦 ∈ ran 𝑓𝜑))
2322ralimdva 2944 . . . . . 6 (𝑓:𝐴𝐵 → (∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑 → ∀𝑥𝐴𝑦 ∈ ran 𝑓𝜑))
2423imp 443 . . . . 5 ((𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑) → ∀𝑥𝐴𝑦 ∈ ran 𝑓𝜑)
2524adantl 480 . . . 4 (((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) → ∀𝑥𝐴𝑦 ∈ ran 𝑓𝜑)
26 simpr 475 . . . . . . . 8 ((((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) ∧ 𝑤𝐴) → 𝑤𝐴)
27 simprr 791 . . . . . . . . . 10 (((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) → ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)
28 nfv 1829 . . . . . . . . . . 11 𝑤[(𝑓𝑥) / 𝑦]𝜑
29 nfsbc1v 3421 . . . . . . . . . . 11 𝑥[𝑤 / 𝑥][(𝑓𝑤) / 𝑦]𝜑
30 fveq2 6088 . . . . . . . . . . . . 13 (𝑥 = 𝑤 → (𝑓𝑥) = (𝑓𝑤))
3130sbceq1d 3406 . . . . . . . . . . . 12 (𝑥 = 𝑤 → ([(𝑓𝑥) / 𝑦]𝜑[(𝑓𝑤) / 𝑦]𝜑))
32 sbceq1a 3412 . . . . . . . . . . . 12 (𝑥 = 𝑤 → ([(𝑓𝑤) / 𝑦]𝜑[𝑤 / 𝑥][(𝑓𝑤) / 𝑦]𝜑))
3331, 32bitrd 266 . . . . . . . . . . 11 (𝑥 = 𝑤 → ([(𝑓𝑥) / 𝑦]𝜑[𝑤 / 𝑥][(𝑓𝑤) / 𝑦]𝜑))
3428, 29, 33cbvral 3142 . . . . . . . . . 10 (∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑 ↔ ∀𝑤𝐴 [𝑤 / 𝑥][(𝑓𝑤) / 𝑦]𝜑)
3527, 34sylib 206 . . . . . . . . 9 (((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) → ∀𝑤𝐴 [𝑤 / 𝑥][(𝑓𝑤) / 𝑦]𝜑)
3635r19.21bi 2915 . . . . . . . 8 ((((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) ∧ 𝑤𝐴) → [𝑤 / 𝑥][(𝑓𝑤) / 𝑦]𝜑)
37 rspesbca 3485 . . . . . . . 8 ((𝑤𝐴[𝑤 / 𝑥][(𝑓𝑤) / 𝑦]𝜑) → ∃𝑥𝐴 [(𝑓𝑤) / 𝑦]𝜑)
3826, 36, 37syl2anc 690 . . . . . . 7 ((((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) ∧ 𝑤𝐴) → ∃𝑥𝐴 [(𝑓𝑤) / 𝑦]𝜑)
3938ralrimiva 2948 . . . . . 6 (((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) → ∀𝑤𝐴𝑥𝐴 [(𝑓𝑤) / 𝑦]𝜑)
40 dfsbcq 3403 . . . . . . . . 9 (𝑧 = (𝑓𝑤) → ([𝑧 / 𝑦]𝜑[(𝑓𝑤) / 𝑦]𝜑))
4140rexbidv 3033 . . . . . . . 8 (𝑧 = (𝑓𝑤) → (∃𝑥𝐴 [𝑧 / 𝑦]𝜑 ↔ ∃𝑥𝐴 [(𝑓𝑤) / 𝑦]𝜑))
4241ralrn 6255 . . . . . . 7 (𝑓 Fn 𝐴 → (∀𝑧 ∈ ran 𝑓𝑥𝐴 [𝑧 / 𝑦]𝜑 ↔ ∀𝑤𝐴𝑥𝐴 [(𝑓𝑤) / 𝑦]𝜑))
4311, 42syl 17 . . . . . 6 (((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) → (∀𝑧 ∈ ran 𝑓𝑥𝐴 [𝑧 / 𝑦]𝜑 ↔ ∀𝑤𝐴𝑥𝐴 [(𝑓𝑤) / 𝑦]𝜑))
4439, 43mpbird 245 . . . . 5 (((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) → ∀𝑧 ∈ ran 𝑓𝑥𝐴 [𝑧 / 𝑦]𝜑)
45 nfv 1829 . . . . . 6 𝑧𝑥𝐴 𝜑
46 nfcv 2750 . . . . . . 7 𝑦𝐴
4746, 2nfrex 2989 . . . . . 6 𝑦𝑥𝐴 [𝑧 / 𝑦]𝜑
483rexbidv 3033 . . . . . 6 (𝑦 = 𝑧 → (∃𝑥𝐴 𝜑 ↔ ∃𝑥𝐴 [𝑧 / 𝑦]𝜑))
4945, 47, 48cbvral 3142 . . . . 5 (∀𝑦 ∈ ran 𝑓𝑥𝐴 𝜑 ↔ ∀𝑧 ∈ ran 𝑓𝑥𝐴 [𝑧 / 𝑦]𝜑)
5044, 49sylibr 222 . . . 4 (((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) → ∀𝑦 ∈ ran 𝑓𝑥𝐴 𝜑)
51 sseq1 3588 . . . . . 6 (𝑐 = ran 𝑓 → (𝑐𝐵 ↔ ran 𝑓𝐵))
52 rexeq 3115 . . . . . . 7 (𝑐 = ran 𝑓 → (∃𝑦𝑐 𝜑 ↔ ∃𝑦 ∈ ran 𝑓𝜑))
5352ralbidv 2968 . . . . . 6 (𝑐 = ran 𝑓 → (∀𝑥𝐴𝑦𝑐 𝜑 ↔ ∀𝑥𝐴𝑦 ∈ ran 𝑓𝜑))
54 raleq 3114 . . . . . 6 (𝑐 = ran 𝑓 → (∀𝑦𝑐𝑥𝐴 𝜑 ↔ ∀𝑦 ∈ ran 𝑓𝑥𝐴 𝜑))
5551, 53, 543anbi123d 1390 . . . . 5 (𝑐 = ran 𝑓 → ((𝑐𝐵 ∧ ∀𝑥𝐴𝑦𝑐 𝜑 ∧ ∀𝑦𝑐𝑥𝐴 𝜑) ↔ (ran 𝑓𝐵 ∧ ∀𝑥𝐴𝑦 ∈ ran 𝑓𝜑 ∧ ∀𝑦 ∈ ran 𝑓𝑥𝐴 𝜑)))
5655rspcev 3281 . . . 4 ((ran 𝑓 ∈ Fin ∧ (ran 𝑓𝐵 ∧ ∀𝑥𝐴𝑦 ∈ ran 𝑓𝜑 ∧ ∀𝑦 ∈ ran 𝑓𝑥𝐴 𝜑)) → ∃𝑐 ∈ Fin (𝑐𝐵 ∧ ∀𝑥𝐴𝑦𝑐 𝜑 ∧ ∀𝑦𝑐𝑥𝐴 𝜑))
5715, 17, 25, 50, 56syl13anc 1319 . . 3 (((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) ∧ (𝑓:𝐴𝐵 ∧ ∀𝑥𝐴 [(𝑓𝑥) / 𝑦]𝜑)) → ∃𝑐 ∈ Fin (𝑐𝐵 ∧ ∀𝑥𝐴𝑦𝑐 𝜑 ∧ ∀𝑦𝑐𝑥𝐴 𝜑))
588, 57exlimddv 1849 . 2 ((𝐴 ∈ Fin ∧ ∀𝑥𝐴𝑦𝐵 𝜑) → ∃𝑐 ∈ Fin (𝑐𝐵 ∧ ∀𝑥𝐴𝑦𝑐 𝜑 ∧ ∀𝑦𝑐𝑥𝐴 𝜑))
59583adant2 1072 1 ((𝐴 ∈ Fin ∧ 𝐵𝑀 ∧ ∀𝑥𝐴𝑦𝐵 𝜑) → ∃𝑐 ∈ Fin (𝑐𝐵 ∧ ∀𝑥𝐴𝑦𝑐 𝜑 ∧ ∀𝑦𝑐𝑥𝐴 𝜑))
Colors of variables: wff setvar class
Syntax hints:  wi 4  wb 194  wa 382  w3a 1030   = wceq 1474  wex 1694  wcel 1976  wral 2895  wrex 2896  [wsbc 3401  wss 3539  ran crn 5029   Fn wfn 5785  wf 5786  ontowfo 5788  cfv 5790  Fincfn 7818
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1712  ax-4 1727  ax-5 1826  ax-6 1874  ax-7 1921  ax-8 1978  ax-9 1985  ax-10 2005  ax-11 2020  ax-12 2033  ax-13 2233  ax-ext 2589  ax-sep 4703  ax-nul 4712  ax-pow 4764  ax-pr 4828  ax-un 6824
This theorem depends on definitions:  df-bi 195  df-or 383  df-an 384  df-3or 1031  df-3an 1032  df-tru 1477  df-ex 1695  df-nf 1700  df-sb 1867  df-eu 2461  df-mo 2462  df-clab 2596  df-cleq 2602  df-clel 2605  df-nfc 2739  df-ne 2781  df-ral 2900  df-rex 2901  df-reu 2902  df-rab 2904  df-v 3174  df-sbc 3402  df-dif 3542  df-un 3544  df-in 3546  df-ss 3553  df-pss 3555  df-nul 3874  df-if 4036  df-pw 4109  df-sn 4125  df-pr 4127  df-tp 4129  df-op 4131  df-uni 4367  df-br 4578  df-opab 4638  df-mpt 4639  df-tr 4675  df-eprel 4939  df-id 4943  df-po 4949  df-so 4950  df-fr 4987  df-we 4989  df-xp 5034  df-rel 5035  df-cnv 5036  df-co 5037  df-dm 5038  df-rn 5039  df-res 5040  df-ima 5041  df-ord 5629  df-on 5630  df-lim 5631  df-suc 5632  df-iota 5754  df-fun 5792  df-fn 5793  df-f 5794  df-f1 5795  df-fo 5796  df-f1o 5797  df-fv 5798  df-om 6935  df-1o 7424  df-er 7606  df-en 7819  df-dom 7820  df-fin 7822
This theorem is referenced by:  filbcmb  32501
  Copyright terms: Public domain W3C validator