Finset.sum_range_sub_of_adjacent
Library · theorem
In an additive commutative group, let f(i+1)=g(i) at the interior nodes of a chain of length n>0. Then \sum_{i=0}^{n-1}(f(i)-g(i))=f(0)-g(n-1).
Finset.sum_range_sub_of_adjacent.{u_1} {G : Type u_1} [AddCommGroup G] (f g : ℕ → G) {n : ℕ}
(hn : 0 < n) (h : ∀ (i : ℕ), i + 1 < n → f (i + 1) = g i) :
∑ i ∈ Finset.range n, (f i - g i) = f 0 - g (n - 1)Import NLAlib.ForMathlib.Algebra.BigOperators.Grid.