Metamath Proof Explorer


Theorem psrbagconcl

Description: The complement of a bag is a bag. (Contributed by Mario Carneiro, 29-Dec-2014) Remove a sethood antecedent. (Revised by SN, 6-Aug-2024)

Ref Expression
Hypotheses psrbag.d 𝐷 = { 𝑓 ∈ ( ℕ0m 𝐼 ) ∣ ( 𝑓 “ ℕ ) ∈ Fin }
psrbagconf1o.s 𝑆 = { 𝑦𝐷𝑦r𝐹 }
Assertion psrbagconcl ( ( 𝐹𝐷𝑋𝑆 ) → ( 𝐹f𝑋 ) ∈ 𝑆 )

Proof

Step Hyp Ref Expression
1 psrbag.d 𝐷 = { 𝑓 ∈ ( ℕ0m 𝐼 ) ∣ ( 𝑓 “ ℕ ) ∈ Fin }
2 psrbagconf1o.s 𝑆 = { 𝑦𝐷𝑦r𝐹 }
3 simpl ( ( 𝐹𝐷𝑋𝑆 ) → 𝐹𝐷 )
4 simpr ( ( 𝐹𝐷𝑋𝑆 ) → 𝑋𝑆 )
5 breq1 ( 𝑦 = 𝑋 → ( 𝑦r𝐹𝑋r𝐹 ) )
6 5 2 elrab2 ( 𝑋𝑆 ↔ ( 𝑋𝐷𝑋r𝐹 ) )
7 4 6 sylib ( ( 𝐹𝐷𝑋𝑆 ) → ( 𝑋𝐷𝑋r𝐹 ) )
8 7 simpld ( ( 𝐹𝐷𝑋𝑆 ) → 𝑋𝐷 )
9 1 psrbagf ( 𝑋𝐷𝑋 : 𝐼 ⟶ ℕ0 )
10 8 9 syl ( ( 𝐹𝐷𝑋𝑆 ) → 𝑋 : 𝐼 ⟶ ℕ0 )
11 7 simprd ( ( 𝐹𝐷𝑋𝑆 ) → 𝑋r𝐹 )
12 1 psrbagcon ( ( 𝐹𝐷𝑋 : 𝐼 ⟶ ℕ0𝑋r𝐹 ) → ( ( 𝐹f𝑋 ) ∈ 𝐷 ∧ ( 𝐹f𝑋 ) ∘r𝐹 ) )
13 3 10 11 12 syl3anc ( ( 𝐹𝐷𝑋𝑆 ) → ( ( 𝐹f𝑋 ) ∈ 𝐷 ∧ ( 𝐹f𝑋 ) ∘r𝐹 ) )
14 breq1 ( 𝑦 = ( 𝐹f𝑋 ) → ( 𝑦r𝐹 ↔ ( 𝐹f𝑋 ) ∘r𝐹 ) )
15 14 2 elrab2 ( ( 𝐹f𝑋 ) ∈ 𝑆 ↔ ( ( 𝐹f𝑋 ) ∈ 𝐷 ∧ ( 𝐹f𝑋 ) ∘r𝐹 ) )
16 13 15 sylibr ( ( 𝐹𝐷𝑋𝑆 ) → ( 𝐹f𝑋 ) ∈ 𝑆 )