Metamath Proof Explorer


Theorem offval2f

Description: The function operation expressed as a mapping. (Contributed by Thierry Arnoux, 23-Jun-2017)

Ref Expression
Hypotheses offval2f.0 𝑥 𝜑
offval2f.a 𝑥 𝐴
offval2f.1 ( 𝜑𝐴𝑉 )
offval2f.2 ( ( 𝜑𝑥𝐴 ) → 𝐵𝑊 )
offval2f.3 ( ( 𝜑𝑥𝐴 ) → 𝐶𝑋 )
offval2f.4 ( 𝜑𝐹 = ( 𝑥𝐴𝐵 ) )
offval2f.5 ( 𝜑𝐺 = ( 𝑥𝐴𝐶 ) )
Assertion offval2f ( 𝜑 → ( 𝐹f 𝑅 𝐺 ) = ( 𝑥𝐴 ↦ ( 𝐵 𝑅 𝐶 ) ) )

Proof

Step Hyp Ref Expression
1 offval2f.0 𝑥 𝜑
2 offval2f.a 𝑥 𝐴
3 offval2f.1 ( 𝜑𝐴𝑉 )
4 offval2f.2 ( ( 𝜑𝑥𝐴 ) → 𝐵𝑊 )
5 offval2f.3 ( ( 𝜑𝑥𝐴 ) → 𝐶𝑋 )
6 offval2f.4 ( 𝜑𝐹 = ( 𝑥𝐴𝐵 ) )
7 offval2f.5 ( 𝜑𝐺 = ( 𝑥𝐴𝐶 ) )
8 4 ex ( 𝜑 → ( 𝑥𝐴𝐵𝑊 ) )
9 1 8 ralrimi ( 𝜑 → ∀ 𝑥𝐴 𝐵𝑊 )
10 2 fnmptf ( ∀ 𝑥𝐴 𝐵𝑊 → ( 𝑥𝐴𝐵 ) Fn 𝐴 )
11 9 10 syl ( 𝜑 → ( 𝑥𝐴𝐵 ) Fn 𝐴 )
12 6 fneq1d ( 𝜑 → ( 𝐹 Fn 𝐴 ↔ ( 𝑥𝐴𝐵 ) Fn 𝐴 ) )
13 11 12 mpbird ( 𝜑𝐹 Fn 𝐴 )
14 5 ex ( 𝜑 → ( 𝑥𝐴𝐶𝑋 ) )
15 1 14 ralrimi ( 𝜑 → ∀ 𝑥𝐴 𝐶𝑋 )
16 2 fnmptf ( ∀ 𝑥𝐴 𝐶𝑋 → ( 𝑥𝐴𝐶 ) Fn 𝐴 )
17 15 16 syl ( 𝜑 → ( 𝑥𝐴𝐶 ) Fn 𝐴 )
18 7 fneq1d ( 𝜑 → ( 𝐺 Fn 𝐴 ↔ ( 𝑥𝐴𝐶 ) Fn 𝐴 ) )
19 17 18 mpbird ( 𝜑𝐺 Fn 𝐴 )
20 inidm ( 𝐴𝐴 ) = 𝐴
21 6 adantr ( ( 𝜑𝑦𝐴 ) → 𝐹 = ( 𝑥𝐴𝐵 ) )
22 21 fveq1d ( ( 𝜑𝑦𝐴 ) → ( 𝐹𝑦 ) = ( ( 𝑥𝐴𝐵 ) ‘ 𝑦 ) )
23 7 adantr ( ( 𝜑𝑦𝐴 ) → 𝐺 = ( 𝑥𝐴𝐶 ) )
24 23 fveq1d ( ( 𝜑𝑦𝐴 ) → ( 𝐺𝑦 ) = ( ( 𝑥𝐴𝐶 ) ‘ 𝑦 ) )
25 13 19 3 3 20 22 24 offval ( 𝜑 → ( 𝐹f 𝑅 𝐺 ) = ( 𝑦𝐴 ↦ ( ( ( 𝑥𝐴𝐵 ) ‘ 𝑦 ) 𝑅 ( ( 𝑥𝐴𝐶 ) ‘ 𝑦 ) ) ) )
26 nfcv 𝑦 𝐴
27 nffvmpt1 𝑥 ( ( 𝑥𝐴𝐵 ) ‘ 𝑦 )
28 nfcv 𝑥 𝑅
29 nffvmpt1 𝑥 ( ( 𝑥𝐴𝐶 ) ‘ 𝑦 )
30 27 28 29 nfov 𝑥 ( ( ( 𝑥𝐴𝐵 ) ‘ 𝑦 ) 𝑅 ( ( 𝑥𝐴𝐶 ) ‘ 𝑦 ) )
31 nfcv 𝑦 ( ( ( 𝑥𝐴𝐵 ) ‘ 𝑥 ) 𝑅 ( ( 𝑥𝐴𝐶 ) ‘ 𝑥 ) )
32 fveq2 ( 𝑦 = 𝑥 → ( ( 𝑥𝐴𝐵 ) ‘ 𝑦 ) = ( ( 𝑥𝐴𝐵 ) ‘ 𝑥 ) )
33 fveq2 ( 𝑦 = 𝑥 → ( ( 𝑥𝐴𝐶 ) ‘ 𝑦 ) = ( ( 𝑥𝐴𝐶 ) ‘ 𝑥 ) )
34 32 33 oveq12d ( 𝑦 = 𝑥 → ( ( ( 𝑥𝐴𝐵 ) ‘ 𝑦 ) 𝑅 ( ( 𝑥𝐴𝐶 ) ‘ 𝑦 ) ) = ( ( ( 𝑥𝐴𝐵 ) ‘ 𝑥 ) 𝑅 ( ( 𝑥𝐴𝐶 ) ‘ 𝑥 ) ) )
35 26 2 30 31 34 cbvmptf ( 𝑦𝐴 ↦ ( ( ( 𝑥𝐴𝐵 ) ‘ 𝑦 ) 𝑅 ( ( 𝑥𝐴𝐶 ) ‘ 𝑦 ) ) ) = ( 𝑥𝐴 ↦ ( ( ( 𝑥𝐴𝐵 ) ‘ 𝑥 ) 𝑅 ( ( 𝑥𝐴𝐶 ) ‘ 𝑥 ) ) )
36 simpr ( ( 𝜑𝑥𝐴 ) → 𝑥𝐴 )
37 2 fvmpt2f ( ( 𝑥𝐴𝐵𝑊 ) → ( ( 𝑥𝐴𝐵 ) ‘ 𝑥 ) = 𝐵 )
38 36 4 37 syl2anc ( ( 𝜑𝑥𝐴 ) → ( ( 𝑥𝐴𝐵 ) ‘ 𝑥 ) = 𝐵 )
39 2 fvmpt2f ( ( 𝑥𝐴𝐶𝑋 ) → ( ( 𝑥𝐴𝐶 ) ‘ 𝑥 ) = 𝐶 )
40 36 5 39 syl2anc ( ( 𝜑𝑥𝐴 ) → ( ( 𝑥𝐴𝐶 ) ‘ 𝑥 ) = 𝐶 )
41 38 40 oveq12d ( ( 𝜑𝑥𝐴 ) → ( ( ( 𝑥𝐴𝐵 ) ‘ 𝑥 ) 𝑅 ( ( 𝑥𝐴𝐶 ) ‘ 𝑥 ) ) = ( 𝐵 𝑅 𝐶 ) )
42 1 41 mpteq2da ( 𝜑 → ( 𝑥𝐴 ↦ ( ( ( 𝑥𝐴𝐵 ) ‘ 𝑥 ) 𝑅 ( ( 𝑥𝐴𝐶 ) ‘ 𝑥 ) ) ) = ( 𝑥𝐴 ↦ ( 𝐵 𝑅 𝐶 ) ) )
43 35 42 eqtrid ( 𝜑 → ( 𝑦𝐴 ↦ ( ( ( 𝑥𝐴𝐵 ) ‘ 𝑦 ) 𝑅 ( ( 𝑥𝐴𝐶 ) ‘ 𝑦 ) ) ) = ( 𝑥𝐴 ↦ ( 𝐵 𝑅 𝐶 ) ) )
44 25 43 eqtrd ( 𝜑 → ( 𝐹f 𝑅 𝐺 ) = ( 𝑥𝐴 ↦ ( 𝐵 𝑅 𝐶 ) ) )