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

Theorem mpocurryd 8085
Description: The currying of an operation given in maps-to notation, splitting the operation (function of two arguments) into a function of the first argument, producing a function over the second argument. (Contributed by AV, 27-Oct-2019.)
Hypotheses
Ref Expression
mpocurryd.f 𝐹 = (𝑥𝑋, 𝑦𝑌𝐶)
mpocurryd.c (𝜑 → ∀𝑥𝑋𝑦𝑌 𝐶𝑉)
mpocurryd.n (𝜑𝑌 ≠ ∅)
Assertion
Ref Expression
mpocurryd (𝜑 → curry 𝐹 = (𝑥𝑋 ↦ (𝑦𝑌𝐶)))
Distinct variable groups:   𝑥,𝐹,𝑦   𝑥,𝑉,𝑦   𝑥,𝑋,𝑦   𝑥,𝑌,𝑦   𝜑,𝑥,𝑦
Allowed substitution hints:   𝐶(𝑥,𝑦)

Proof of Theorem mpocurryd
Dummy variables 𝑎 𝑏 𝑧 are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 df-cur 8083 . 2 curry 𝐹 = (𝑥 ∈ dom dom 𝐹 ↦ {⟨𝑦, 𝑧⟩ ∣ ⟨𝑥, 𝑦𝐹𝑧})
2 mpocurryd.c . . . . . . 7 (𝜑 → ∀𝑥𝑋𝑦𝑌 𝐶𝑉)
3 mpocurryd.f . . . . . . . 8 𝐹 = (𝑥𝑋, 𝑦𝑌𝐶)
43dmmpoga 7913 . . . . . . 7 (∀𝑥𝑋𝑦𝑌 𝐶𝑉 → dom 𝐹 = (𝑋 × 𝑌))
52, 4syl 17 . . . . . 6 (𝜑 → dom 𝐹 = (𝑋 × 𝑌))
65dmeqd 5814 . . . . 5 (𝜑 → dom dom 𝐹 = dom (𝑋 × 𝑌))
7 mpocurryd.n . . . . . 6 (𝜑𝑌 ≠ ∅)
8 dmxp 5838 . . . . . 6 (𝑌 ≠ ∅ → dom (𝑋 × 𝑌) = 𝑋)
97, 8syl 17 . . . . 5 (𝜑 → dom (𝑋 × 𝑌) = 𝑋)
106, 9eqtrd 2778 . . . 4 (𝜑 → dom dom 𝐹 = 𝑋)
1110mpteq1d 5169 . . 3 (𝜑 → (𝑥 ∈ dom dom 𝐹 ↦ {⟨𝑦, 𝑧⟩ ∣ ⟨𝑥, 𝑦𝐹𝑧}) = (𝑥𝑋 ↦ {⟨𝑦, 𝑧⟩ ∣ ⟨𝑥, 𝑦𝐹𝑧}))
12 df-mpt 5158 . . . . 5 (𝑦𝑌𝐶) = {⟨𝑦, 𝑧⟩ ∣ (𝑦𝑌𝑧 = 𝐶)}
133mpofun 7398 . . . . . . . 8 Fun 𝐹
14 funbrfv2b 6827 . . . . . . . 8 (Fun 𝐹 → (⟨𝑥, 𝑦𝐹𝑧 ↔ (⟨𝑥, 𝑦⟩ ∈ dom 𝐹 ∧ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧)))
1513, 14mp1i 13 . . . . . . 7 ((𝜑𝑥𝑋) → (⟨𝑥, 𝑦𝐹𝑧 ↔ (⟨𝑥, 𝑦⟩ ∈ dom 𝐹 ∧ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧)))
165adantr 481 . . . . . . . . . 10 ((𝜑𝑥𝑋) → dom 𝐹 = (𝑋 × 𝑌))
1716eleq2d 2824 . . . . . . . . 9 ((𝜑𝑥𝑋) → (⟨𝑥, 𝑦⟩ ∈ dom 𝐹 ↔ ⟨𝑥, 𝑦⟩ ∈ (𝑋 × 𝑌)))
18 opelxp 5625 . . . . . . . . 9 (⟨𝑥, 𝑦⟩ ∈ (𝑋 × 𝑌) ↔ (𝑥𝑋𝑦𝑌))
1917, 18bitrdi 287 . . . . . . . 8 ((𝜑𝑥𝑋) → (⟨𝑥, 𝑦⟩ ∈ dom 𝐹 ↔ (𝑥𝑋𝑦𝑌)))
2019anbi1d 630 . . . . . . 7 ((𝜑𝑥𝑋) → ((⟨𝑥, 𝑦⟩ ∈ dom 𝐹 ∧ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧) ↔ ((𝑥𝑋𝑦𝑌) ∧ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧)))
21 an21 641 . . . . . . . 8 (((𝑥𝑋𝑦𝑌) ∧ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧) ↔ (𝑦𝑌 ∧ (𝑥𝑋 ∧ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧)))
22 ibar 529 . . . . . . . . . . . . 13 (𝑥𝑋 → ((𝐹‘⟨𝑥, 𝑦⟩) = 𝑧 ↔ (𝑥𝑋 ∧ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧)))
2322bicomd 222 . . . . . . . . . . . 12 (𝑥𝑋 → ((𝑥𝑋 ∧ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧) ↔ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧))
2423adantl 482 . . . . . . . . . . 11 ((𝜑𝑥𝑋) → ((𝑥𝑋 ∧ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧) ↔ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧))
2524adantr 481 . . . . . . . . . 10 (((𝜑𝑥𝑋) ∧ 𝑦𝑌) → ((𝑥𝑋 ∧ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧) ↔ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧))
26 df-ov 7278 . . . . . . . . . . . . 13 (𝑥𝐹𝑦) = (𝐹‘⟨𝑥, 𝑦⟩)
27 nfcv 2907 . . . . . . . . . . . . . . . . 17 𝑎𝐶
28 nfcv 2907 . . . . . . . . . . . . . . . . 17 𝑏𝐶
29 nfcv 2907 . . . . . . . . . . . . . . . . . 18 𝑥𝑏
30 nfcsb1v 3857 . . . . . . . . . . . . . . . . . 18 𝑥𝑎 / 𝑥𝐶
3129, 30nfcsbw 3859 . . . . . . . . . . . . . . . . 17 𝑥𝑏 / 𝑦𝑎 / 𝑥𝐶
32 nfcsb1v 3857 . . . . . . . . . . . . . . . . 17 𝑦𝑏 / 𝑦𝑎 / 𝑥𝐶
33 csbeq1a 3846 . . . . . . . . . . . . . . . . . 18 (𝑥 = 𝑎𝐶 = 𝑎 / 𝑥𝐶)
34 csbeq1a 3846 . . . . . . . . . . . . . . . . . 18 (𝑦 = 𝑏𝑎 / 𝑥𝐶 = 𝑏 / 𝑦𝑎 / 𝑥𝐶)
3533, 34sylan9eq 2798 . . . . . . . . . . . . . . . . 17 ((𝑥 = 𝑎𝑦 = 𝑏) → 𝐶 = 𝑏 / 𝑦𝑎 / 𝑥𝐶)
3627, 28, 31, 32, 35cbvmpo 7369 . . . . . . . . . . . . . . . 16 (𝑥𝑋, 𝑦𝑌𝐶) = (𝑎𝑋, 𝑏𝑌𝑏 / 𝑦𝑎 / 𝑥𝐶)
373, 36eqtri 2766 . . . . . . . . . . . . . . 15 𝐹 = (𝑎𝑋, 𝑏𝑌𝑏 / 𝑦𝑎 / 𝑥𝐶)
3837a1i 11 . . . . . . . . . . . . . 14 (((𝜑𝑥𝑋) ∧ 𝑦𝑌) → 𝐹 = (𝑎𝑋, 𝑏𝑌𝑏 / 𝑦𝑎 / 𝑥𝐶))
3933eqcomd 2744 . . . . . . . . . . . . . . . . . 18 (𝑥 = 𝑎𝑎 / 𝑥𝐶 = 𝐶)
4039equcoms 2023 . . . . . . . . . . . . . . . . 17 (𝑎 = 𝑥𝑎 / 𝑥𝐶 = 𝐶)
4140csbeq2dv 3839 . . . . . . . . . . . . . . . 16 (𝑎 = 𝑥𝑏 / 𝑦𝑎 / 𝑥𝐶 = 𝑏 / 𝑦𝐶)
42 csbeq1a 3846 . . . . . . . . . . . . . . . . . 18 (𝑦 = 𝑏𝐶 = 𝑏 / 𝑦𝐶)
4342eqcomd 2744 . . . . . . . . . . . . . . . . 17 (𝑦 = 𝑏𝑏 / 𝑦𝐶 = 𝐶)
4443equcoms 2023 . . . . . . . . . . . . . . . 16 (𝑏 = 𝑦𝑏 / 𝑦𝐶 = 𝐶)
4541, 44sylan9eq 2798 . . . . . . . . . . . . . . 15 ((𝑎 = 𝑥𝑏 = 𝑦) → 𝑏 / 𝑦𝑎 / 𝑥𝐶 = 𝐶)
4645adantl 482 . . . . . . . . . . . . . 14 ((((𝜑𝑥𝑋) ∧ 𝑦𝑌) ∧ (𝑎 = 𝑥𝑏 = 𝑦)) → 𝑏 / 𝑦𝑎 / 𝑥𝐶 = 𝐶)
47 simpr 485 . . . . . . . . . . . . . . 15 ((𝜑𝑥𝑋) → 𝑥𝑋)
4847adantr 481 . . . . . . . . . . . . . 14 (((𝜑𝑥𝑋) ∧ 𝑦𝑌) → 𝑥𝑋)
49 simpr 485 . . . . . . . . . . . . . 14 (((𝜑𝑥𝑋) ∧ 𝑦𝑌) → 𝑦𝑌)
50 rsp2 3138 . . . . . . . . . . . . . . . 16 (∀𝑥𝑋𝑦𝑌 𝐶𝑉 → ((𝑥𝑋𝑦𝑌) → 𝐶𝑉))
512, 50syl 17 . . . . . . . . . . . . . . 15 (𝜑 → ((𝑥𝑋𝑦𝑌) → 𝐶𝑉))
5251impl 456 . . . . . . . . . . . . . 14 (((𝜑𝑥𝑋) ∧ 𝑦𝑌) → 𝐶𝑉)
5338, 46, 48, 49, 52ovmpod 7425 . . . . . . . . . . . . 13 (((𝜑𝑥𝑋) ∧ 𝑦𝑌) → (𝑥𝐹𝑦) = 𝐶)
5426, 53eqtr3id 2792 . . . . . . . . . . . 12 (((𝜑𝑥𝑋) ∧ 𝑦𝑌) → (𝐹‘⟨𝑥, 𝑦⟩) = 𝐶)
5554eqeq1d 2740 . . . . . . . . . . 11 (((𝜑𝑥𝑋) ∧ 𝑦𝑌) → ((𝐹‘⟨𝑥, 𝑦⟩) = 𝑧𝐶 = 𝑧))
56 eqcom 2745 . . . . . . . . . . 11 (𝐶 = 𝑧𝑧 = 𝐶)
5755, 56bitrdi 287 . . . . . . . . . 10 (((𝜑𝑥𝑋) ∧ 𝑦𝑌) → ((𝐹‘⟨𝑥, 𝑦⟩) = 𝑧𝑧 = 𝐶))
5825, 57bitrd 278 . . . . . . . . 9 (((𝜑𝑥𝑋) ∧ 𝑦𝑌) → ((𝑥𝑋 ∧ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧) ↔ 𝑧 = 𝐶))
5958pm5.32da 579 . . . . . . . 8 ((𝜑𝑥𝑋) → ((𝑦𝑌 ∧ (𝑥𝑋 ∧ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧)) ↔ (𝑦𝑌𝑧 = 𝐶)))
6021, 59bitrid 282 . . . . . . 7 ((𝜑𝑥𝑋) → (((𝑥𝑋𝑦𝑌) ∧ (𝐹‘⟨𝑥, 𝑦⟩) = 𝑧) ↔ (𝑦𝑌𝑧 = 𝐶)))
6115, 20, 603bitrrd 306 . . . . . 6 ((𝜑𝑥𝑋) → ((𝑦𝑌𝑧 = 𝐶) ↔ ⟨𝑥, 𝑦𝐹𝑧))
6261opabbidv 5140 . . . . 5 ((𝜑𝑥𝑋) → {⟨𝑦, 𝑧⟩ ∣ (𝑦𝑌𝑧 = 𝐶)} = {⟨𝑦, 𝑧⟩ ∣ ⟨𝑥, 𝑦𝐹𝑧})
6312, 62eqtr2id 2791 . . . 4 ((𝜑𝑥𝑋) → {⟨𝑦, 𝑧⟩ ∣ ⟨𝑥, 𝑦𝐹𝑧} = (𝑦𝑌𝐶))
6463mpteq2dva 5174 . . 3 (𝜑 → (𝑥𝑋 ↦ {⟨𝑦, 𝑧⟩ ∣ ⟨𝑥, 𝑦𝐹𝑧}) = (𝑥𝑋 ↦ (𝑦𝑌𝐶)))
6511, 64eqtrd 2778 . 2 (𝜑 → (𝑥 ∈ dom dom 𝐹 ↦ {⟨𝑦, 𝑧⟩ ∣ ⟨𝑥, 𝑦𝐹𝑧}) = (𝑥𝑋 ↦ (𝑦𝑌𝐶)))
661, 65eqtrid 2790 1 (𝜑 → curry 𝐹 = (𝑥𝑋 ↦ (𝑦𝑌𝐶)))
Colors of variables: wff setvar class
Syntax hints:  wi 4  wb 205  wa 396   = wceq 1539  wcel 2106  wne 2943  wral 3064  csb 3832  c0 4256  cop 4567   class class class wbr 5074  {copab 5136  cmpt 5157   × cxp 5587  dom cdm 5589  Fun wfun 6427  cfv 6433  (class class class)co 7275  cmpo 7277  curry ccur 8081
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1798  ax-4 1812  ax-5 1913  ax-6 1971  ax-7 2011  ax-8 2108  ax-9 2116  ax-10 2137  ax-11 2154  ax-12 2171  ax-ext 2709  ax-sep 5223  ax-nul 5230  ax-pr 5352  ax-un 7588
This theorem depends on definitions:  df-bi 206  df-an 397  df-or 845  df-3an 1088  df-tru 1542  df-fal 1552  df-ex 1783  df-nf 1787  df-sb 2068  df-mo 2540  df-eu 2569  df-clab 2716  df-cleq 2730  df-clel 2816  df-nfc 2889  df-ne 2944  df-ral 3069  df-rex 3070  df-rab 3073  df-v 3434  df-sbc 3717  df-csb 3833  df-dif 3890  df-un 3892  df-in 3894  df-ss 3904  df-nul 4257  df-if 4460  df-sn 4562  df-pr 4564  df-op 4568  df-uni 4840  df-iun 4926  df-br 5075  df-opab 5137  df-mpt 5158  df-id 5489  df-xp 5595  df-rel 5596  df-cnv 5597  df-co 5598  df-dm 5599  df-rn 5600  df-res 5601  df-ima 5602  df-iota 6391  df-fun 6435  df-fn 6436  df-f 6437  df-fv 6441  df-ov 7278  df-oprab 7279  df-mpo 7280  df-1st 7831  df-2nd 7832  df-cur 8083
This theorem is referenced by:  mpocurryvald  8086  curfv  35757
  Copyright terms: Public domain W3C validator