Sum of the first $n$ odd numbers is $n^2$ My textbook provides the following proof that giving the sum of the first $n$ odd numbers is equal to $n^2$ then it is true for all $n$.

I don't understand the part where it "adds $2k+1$ to both sides" and ends up with $(k+1)^2$.
I looked up another proof of the same problem that made a lot more sense to me, hoping it would help me understand the first one but I still don't know how to square what I'm seeing in my textbook.
 A: 
I don't understand the part where it "adds $2k+1$ to both sides" and
  ends up with $(k+1)^2$.

Since you are trying to proof the assertion with the help of induction you have to first show that $P(1)$ is true. In the second step (induction step) you have to show that $P(k+1)$ is true, where you assume that $P(k)$ is true. The author realized that the term $1 + 3 + \dotsc + 2k-1$ is obviously part of the term $1 + 3 + \dotsc + 2k-1 +2k +1$. Since the author knows that $1 + 3 + \dotsc + 2k-1=k^2$ (by the assumption "$P(k)$ is true") he just added $2k+1$ on both sides and calculated that the right hand side to get $k^2+2k+1=(k+1)^2$, which shows that $P(k+1)$ is true.
A better way would be the following: Let us assume that $P(k)$ is true for a $k\in \mathbf N$. Let us show that $P(k+1)$ is true aswell. Therefore we have to show that $1 + 3 + \dotsc + 2k-1 +2k +1 =(k+1)^2$. We have by the induction hypothesis
$$1 + 3 + \dotsc + 2k-1 +2k +1= k^2 +2k+1$$
and since the right hand side equals $(k+1)^2$, we are done.
A: We need to proof that $\sum_{i=1}^n 2i-1 = n^2$, so we can divide the serie in two parts, so: $$\sum_{i=1}^n 2i - \sum_{i=1}^n 1 = n^2 $$ Now we can calculating the series, first we have that: $$\sum_{i=1}^n 2i = 2\sum_{i=1}^ni = 2\frac{n(n+1)}{2}= n(n+1)$$
For the other serie we simply have: $$\sum_{i=1}^n 1 = n $$ Hence $$\sum_{i=1}^n 2i - \sum_{i=1}^n 1 = n(n+1) - n = n^2+n-n = n^2 $$
This is how we can show that the sum of the the first n odd numbers is equal to $n^2$ for every positive integer.
A: if we assume that $$1+3+5+...+2k-1=k^2$$ (I) is true, then we have to Show that $$1+3+5+...+2k-1+2k+1=(k+1)^2$$ if we add $2k+1$ in (I) we get
$$2k+1+k^2=(k+1)^2$$ therefore our Statement is true.
