Metamath Proof Explorer


Theorem dffo3f

Description: An onto mapping expressed in terms of function values. As dffo3 but with less disjoint vars constraints. (Contributed by Glauco Siliprandi, 17-Aug-2020)

Ref Expression
Hypothesis dffo3f.1 𝑥 𝐹
Assertion dffo3f ( 𝐹 : 𝐴onto𝐵 ↔ ( 𝐹 : 𝐴𝐵 ∧ ∀ 𝑦𝐵𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ) )

Proof

Step Hyp Ref Expression
1 dffo3f.1 𝑥 𝐹
2 dffo2 ( 𝐹 : 𝐴onto𝐵 ↔ ( 𝐹 : 𝐴𝐵 ∧ ran 𝐹 = 𝐵 ) )
3 ffn ( 𝐹 : 𝐴𝐵𝐹 Fn 𝐴 )
4 fnrnfv ( 𝐹 Fn 𝐴 → ran 𝐹 = { 𝑦 ∣ ∃ 𝑤𝐴 𝑦 = ( 𝐹𝑤 ) } )
5 nfcv 𝑥 𝑤
6 1 5 nffv 𝑥 ( 𝐹𝑤 )
7 6 nfeq2 𝑥 𝑦 = ( 𝐹𝑤 )
8 nfv 𝑤 𝑦 = ( 𝐹𝑥 )
9 fveq2 ( 𝑤 = 𝑥 → ( 𝐹𝑤 ) = ( 𝐹𝑥 ) )
10 9 eqeq2d ( 𝑤 = 𝑥 → ( 𝑦 = ( 𝐹𝑤 ) ↔ 𝑦 = ( 𝐹𝑥 ) ) )
11 7 8 10 cbvrexw ( ∃ 𝑤𝐴 𝑦 = ( 𝐹𝑤 ) ↔ ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) )
12 11 abbii { 𝑦 ∣ ∃ 𝑤𝐴 𝑦 = ( 𝐹𝑤 ) } = { 𝑦 ∣ ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) }
13 4 12 eqtrdi ( 𝐹 Fn 𝐴 → ran 𝐹 = { 𝑦 ∣ ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) } )
14 13 eqeq1d ( 𝐹 Fn 𝐴 → ( ran 𝐹 = 𝐵 ↔ { 𝑦 ∣ ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) } = 𝐵 ) )
15 3 14 syl ( 𝐹 : 𝐴𝐵 → ( ran 𝐹 = 𝐵 ↔ { 𝑦 ∣ ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) } = 𝐵 ) )
16 dfbi2 ( ( ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ↔ 𝑦𝐵 ) ↔ ( ( ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) → 𝑦𝐵 ) ∧ ( 𝑦𝐵 → ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ) ) )
17 nfcv 𝑥 𝐴
18 nfcv 𝑥 𝐵
19 1 17 18 nff 𝑥 𝐹 : 𝐴𝐵
20 nfv 𝑥 𝑦𝐵
21 simpr ( ( ( 𝐹 : 𝐴𝐵𝑥𝐴 ) ∧ 𝑦 = ( 𝐹𝑥 ) ) → 𝑦 = ( 𝐹𝑥 ) )
22 ffvelrn ( ( 𝐹 : 𝐴𝐵𝑥𝐴 ) → ( 𝐹𝑥 ) ∈ 𝐵 )
23 22 adantr ( ( ( 𝐹 : 𝐴𝐵𝑥𝐴 ) ∧ 𝑦 = ( 𝐹𝑥 ) ) → ( 𝐹𝑥 ) ∈ 𝐵 )
24 21 23 eqeltrd ( ( ( 𝐹 : 𝐴𝐵𝑥𝐴 ) ∧ 𝑦 = ( 𝐹𝑥 ) ) → 𝑦𝐵 )
25 19 20 24 rexlimd3 ( 𝐹 : 𝐴𝐵 → ( ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) → 𝑦𝐵 ) )
26 25 biantrurd ( 𝐹 : 𝐴𝐵 → ( ( 𝑦𝐵 → ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ) ↔ ( ( ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) → 𝑦𝐵 ) ∧ ( 𝑦𝐵 → ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ) ) ) )
27 16 26 bitr4id ( 𝐹 : 𝐴𝐵 → ( ( ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ↔ 𝑦𝐵 ) ↔ ( 𝑦𝐵 → ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ) ) )
28 27 albidv ( 𝐹 : 𝐴𝐵 → ( ∀ 𝑦 ( ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ↔ 𝑦𝐵 ) ↔ ∀ 𝑦 ( 𝑦𝐵 → ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ) ) )
29 abeq1 ( { 𝑦 ∣ ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) } = 𝐵 ↔ ∀ 𝑦 ( ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ↔ 𝑦𝐵 ) )
30 df-ral ( ∀ 𝑦𝐵𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ↔ ∀ 𝑦 ( 𝑦𝐵 → ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ) )
31 28 29 30 3bitr4g ( 𝐹 : 𝐴𝐵 → ( { 𝑦 ∣ ∃ 𝑥𝐴 𝑦 = ( 𝐹𝑥 ) } = 𝐵 ↔ ∀ 𝑦𝐵𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ) )
32 15 31 bitrd ( 𝐹 : 𝐴𝐵 → ( ran 𝐹 = 𝐵 ↔ ∀ 𝑦𝐵𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ) )
33 32 pm5.32i ( ( 𝐹 : 𝐴𝐵 ∧ ran 𝐹 = 𝐵 ) ↔ ( 𝐹 : 𝐴𝐵 ∧ ∀ 𝑦𝐵𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ) )
34 2 33 bitri ( 𝐹 : 𝐴onto𝐵 ↔ ( 𝐹 : 𝐴𝐵 ∧ ∀ 𝑦𝐵𝑥𝐴 𝑦 = ( 𝐹𝑥 ) ) )