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

Theorem csbif 4545
Description: Distribute proper substitution through the conditional operator. (Contributed by NM, 24-Feb-2013.) (Revised by NM, 19-Aug-2018.)
Assertion
Ref Expression
csbif ⦋𝐴 / 𝑥⦌if(𝜑, 𝐵, 𝐶) = if([𝐴 / 𝑥]𝜑, ⦋𝐴 / 𝑥⦌𝐵, ⦋𝐴 / 𝑥⦌𝐶)

Proof of Theorem csbif
Dummy variable 𝑦 is distinct from all other variables.
StepHypRef Expression
1 csbeq1 3856 . . . 4 (𝑦 = 𝐴 → ⦋𝑦 / 𝑥⦌if(𝜑, 𝐵, 𝐶) = ⦋𝐴 / 𝑥⦌if(𝜑, 𝐵, 𝐶))
2 dfsbcq2 3747 . . . . 5 (𝑦 = 𝐴 → ([𝑦 / 𝑥]𝜑 ↔ [𝐴 / 𝑥]𝜑))
3 csbeq1 3856 . . . . 5 (𝑦 = 𝐴 → ⦋𝑦 / 𝑥⦌𝐵 = ⦋𝐴 / 𝑥⦌𝐵)
4 csbeq1 3856 . . . . 5 (𝑦 = 𝐴 → ⦋𝑦 / 𝑥⦌𝐶 = ⦋𝐴 / 𝑥⦌𝐶)
52, 3, 4ifbieq12d 4516 . . . 4 (𝑦 = 𝐴 → if([𝑦 / 𝑥]𝜑, ⦋𝑦 / 𝑥⦌𝐵, ⦋𝑦 / 𝑥⦌𝐶) = if([𝐴 / 𝑥]𝜑, ⦋𝐴 / 𝑥⦌𝐵, ⦋𝐴 / 𝑥⦌𝐶))
61, 5eqeq12d 2785 . . 3 (𝑦 = 𝐴 → (⦋𝑦 / 𝑥⦌if(𝜑, 𝐵, 𝐶) = if([𝑦 / 𝑥]𝜑, ⦋𝑦 / 𝑥⦌𝐵, ⦋𝑦 / 𝑥⦌𝐶) ↔ ⦋𝐴 / 𝑥⦌if(𝜑, 𝐵, 𝐶) = if([𝐴 / 𝑥]𝜑, ⦋𝐴 / 𝑥⦌𝐵, ⦋𝐴 / 𝑥⦌𝐶)))
7 vex 3460 . . . 4 𝑦 ∈ V
8 nfs1v 2200 . . . . 5 Ⅎ𝑥[𝑦 / 𝑥]𝜑
9 nfcsb1v 3877 . . . . 5 Ⅎ𝑥⦋𝑦 / 𝑥⦌𝐵
10 nfcsb1v 3877 . . . . 5 Ⅎ𝑥⦋𝑦 / 𝑥⦌𝐶
118, 9, 10nfif 4518 . . . 4 Ⅎ𝑥if([𝑦 / 𝑥]𝜑, ⦋𝑦 / 𝑥⦌𝐵, ⦋𝑦 / 𝑥⦌𝐶)
12 sbequ12 2294 . . . . 5 (𝑥 = 𝑦 → (𝜑 ↔ [𝑦 / 𝑥]𝜑))
13 csbeq1a 3867 . . . . 5 (𝑥 = 𝑦 → 𝐵 = ⦋𝑦 / 𝑥⦌𝐵)
14 csbeq1a 3867 . . . . 5 (𝑥 = 𝑦 → 𝐶 = ⦋𝑦 / 𝑥⦌𝐶)
1512, 13, 14ifbieq12d 4516 . . . 4 (𝑥 = 𝑦 → if(𝜑, 𝐵, 𝐶) = if([𝑦 / 𝑥]𝜑, ⦋𝑦 / 𝑥⦌𝐵, ⦋𝑦 / 𝑥⦌𝐶))
167, 11, 15csbief 3887 . . 3 ⦋𝑦 / 𝑥⦌if(𝜑, 𝐵, 𝐶) = if([𝑦 / 𝑥]𝜑, ⦋𝑦 / 𝑥⦌𝐵, ⦋𝑦 / 𝑥⦌𝐶)
176, 16vtoclg 3523 . 2 (𝐴 ∈ V → ⦋𝐴 / 𝑥⦌if(𝜑, 𝐵, 𝐶) = if([𝐴 / 𝑥]𝜑, ⦋𝐴 / 𝑥⦌𝐵, ⦋𝐴 / 𝑥⦌𝐶))
18 csbprc 4372 . . 3 (¬ 𝐴 ∈ V → ⦋𝐴 / 𝑥⦌if(𝜑, 𝐵, 𝐶) = ∅)
19 csbprc 4372 . . . . 5 (¬ 𝐴 ∈ V → ⦋𝐴 / 𝑥⦌𝐵 = ∅)
20 csbprc 4372 . . . . 5 (¬ 𝐴 ∈ V → ⦋𝐴 / 𝑥⦌𝐶 = ∅)
2119, 20ifeq12d 4509 . . . 4 (¬ 𝐴 ∈ V → if([𝐴 / 𝑥]𝜑, ⦋𝐴 / 𝑥⦌𝐵, ⦋𝐴 / 𝑥⦌𝐶) = if([𝐴 / 𝑥]𝜑, ∅, ∅))
22 ifid 4528 . . . 4 if([𝐴 / 𝑥]𝜑, ∅, ∅) = ∅
2321, 22eqtr2di 2821 . . 3 (¬ 𝐴 ∈ V → ∅ = if([𝐴 / 𝑥]𝜑, ⦋𝐴 / 𝑥⦌𝐵, ⦋𝐴 / 𝑥⦌𝐶))
2418, 23eqtrd 2804 . 2 (¬ 𝐴 ∈ V → ⦋𝐴 / 𝑥⦌if(𝜑, 𝐵, 𝐶) = if([𝐴 / 𝑥]𝜑, ⦋𝐴 / 𝑥⦌𝐵, ⦋𝐴 / 𝑥⦌𝐶))
2517, 24pm2.61i 184 1 ⦋𝐴 / 𝑥⦌if(𝜑, 𝐵, 𝐶) = if([𝐴 / 𝑥]𝜑, ⦋𝐴 / 𝑥⦌𝐵, ⦋𝐴 / 𝑥⦌𝐶)
Colors of variables:    wff setvar class
This proof depends on syntax axioms:  ¬ wn 3   = wceq 1572  [wsb 2104   ∈ wcel 2151  Vcvv 3456  [wsbc 3744  ⦋csb 3853  ∅c0 4283  ifcif 4487
This proof depends on axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1830  ax-4 1844  ax-5 1947  ax-6 2004  ax-7 2045  ax-8 2153  ax-9 2161  ax-10 2184  ax-11 2201  ax-12 2220  ax-ext 2741
This proof depends on definitions:  df-bi 210  df-an 402  df-or 862  df-3an 1106  df-tru 1575  df-fal 1585  df-ex 1815  df-nf 1819  df-sb 2105  df-clab 2748  df-cleq 2761  df-clel 2845  df-nfc 2919  df-rab 3419  df-v 3458  df-sbc 3745  df-csb 3854  df-dif 4052  df-un 4156  df-nul 4284  df-if 4488
This theorem is used by:  csbopg  4859  fvmptnn04if  23239  csbrdgg  38540  csbfinxpg  38599  cdlemk40  42260
  Copyright terms: Public domain W3C validator