Answer:Proof by induction: the base case n=1 gives 1=1, and the inductive step shows P(k)⇒P(k+1) for every k≥1, so the identity holds for all n≥1.
Let P(n) be the statement i=1∑n(2i−1)2=3n(2n−1)(2n+1).
Base case (n=1). The left side is 12=1. The right side is 31⋅1⋅3=1. So P(1) is true.
Inductive step. Assume P(k) holds for some integer k≥1 (the inductive hypothesis):
12+32+⋯+(2k−1)2=3k(2k−1)(2k+1).
We must show P(k+1), whose right side is 3(k+1)(2k+1)(2k+3) (replace k by k+1: 2(k+1)−1=2k+1 and 2(k+1)+1=2k+3). The next odd number after 2k−1 is 2k+1, so the sum for k+1 is the sum for k plus (2k+1)2. Using the hypothesis,
i=1∑k+1(2i−1)2=3k(2k−1)(2k+1)+(2k+1)2.
Factor out the common factor (2k+1) and combine over 3:
=(2k+1)[3k(2k−1)+(2k+1)]=(2k+1)⋅32k2−k+6k+3=3(2k+1)(2k2+5k+3).
Since 2k2+5k+3=(k+1)(2k+3) (expand: 2k2+3k+2k+3), this equals
3(k+1)(2k+1)(2k+3),
which is exactly the right side of P(k+1). Thus P(k)⇒P(k+1).
Conclusion. By the principle of mathematical induction, P(n) is true for every integer n≥1. (For instance, n=2 gives 1+9=10 on the left and 32⋅3⋅5=10 on the right.)
The identity i=1∑n(2i−1)2=3n(2n−1)(2n+1) holds for all integers n≥1.