Metamath Proof Explorer


Theorem fsum00

Description: A sum of nonnegative numbers is zero iff all terms are zero. (Contributed by Jeff Madsen, 2-Sep-2009) (Proof shortened by Mario Carneiro, 24-Apr-2014)

Ref Expression
Hypotheses fsumge0.1 φ A Fin
fsumge0.2 φ k A B
fsumge0.3 φ k A 0 B
Assertion fsum00 φ k A B = 0 k A B = 0

Proof

Step Hyp Ref Expression
1 fsumge0.1 φ A Fin
2 fsumge0.2 φ k A B
3 fsumge0.3 φ k A 0 B
4 1 adantr φ m A A Fin
5 2 adantlr φ m A k A B
6 3 adantlr φ m A k A 0 B
7 snssi m A m A
8 7 adantl φ m A m A
9 4 5 6 8 fsumless φ m A k m B k A B
10 9 adantlr φ k A B = 0 m A k m B k A B
11 simpr φ k A B = 0 m A m A
12 2 3 jca φ k A B 0 B
13 12 ralrimiva φ k A B 0 B
14 13 adantr φ k A B = 0 k A B 0 B
15 nfcsb1v _ k m / k B
16 15 nfel1 k m / k B
17 nfcv _ k 0
18 nfcv _ k
19 17 18 15 nfbr k 0 m / k B
20 16 19 nfan k m / k B 0 m / k B
21 csbeq1a k = m B = m / k B
22 21 eleq1d k = m B m / k B
23 21 breq2d k = m 0 B 0 m / k B
24 22 23 anbi12d k = m B 0 B m / k B 0 m / k B
25 20 24 rspc m A k A B 0 B m / k B 0 m / k B
26 14 25 mpan9 φ k A B = 0 m A m / k B 0 m / k B
27 26 simpld φ k A B = 0 m A m / k B
28 27 recnd φ k A B = 0 m A m / k B
29 sumsns m A m / k B k m B = m / k B
30 11 28 29 syl2anc φ k A B = 0 m A k m B = m / k B
31 simplr φ k A B = 0 m A k A B = 0
32 10 30 31 3brtr3d φ k A B = 0 m A m / k B 0
33 26 simprd φ k A B = 0 m A 0 m / k B
34 0re 0
35 letri3 m / k B 0 m / k B = 0 m / k B 0 0 m / k B
36 27 34 35 sylancl φ k A B = 0 m A m / k B = 0 m / k B 0 0 m / k B
37 32 33 36 mpbir2and φ k A B = 0 m A m / k B = 0
38 37 ralrimiva φ k A B = 0 m A m / k B = 0
39 nfv m B = 0
40 15 nfeq1 k m / k B = 0
41 21 eqeq1d k = m B = 0 m / k B = 0
42 39 40 41 cbvralw k A B = 0 m A m / k B = 0
43 38 42 sylibr φ k A B = 0 k A B = 0
44 43 ex φ k A B = 0 k A B = 0
45 sumz A 0 A Fin k A 0 = 0
46 45 olcs A Fin k A 0 = 0
47 sumeq2 k A B = 0 k A B = k A 0
48 47 eqeq1d k A B = 0 k A B = 0 k A 0 = 0
49 46 48 syl5ibrcom A Fin k A B = 0 k A B = 0
50 1 49 syl φ k A B = 0 k A B = 0
51 44 50 impbid φ k A B = 0 k A B = 0