Infinite Series for Signal Energy and Power A doubt came up to me on an Oppenheim's Signals and Systems 2ed exercise:
1.3) (f) Determine $P_{\infty}$ and $E_{\infty}$ for the following signal: $x\left[n\right]=\cos\left(\frac{\pi}{4}n\right)$
On theory, $P_{\infty}$ and $E_{\infty}$ are defined as:
$$
\begin{align}
E_{\infty}&\triangleq\lim\limits_{N\to \infty}{\sum_{n=-N}^{+N}{|x\left[n\right]|^{2}}}\\
P_{\infty}&\triangleq\lim\limits_{N\to \infty}{\frac{E_{\infty}}{2N+1}}
\end{align}
$$
Starting by $E_{\infty}$:
$$
\begin{align}
E_{\infty}&=\lim\limits_{N\to \infty}{\sum_{n=-N}^{+N}{\left|\cos\left(\frac{\pi}{4}n\right)\right|^{2}}}\\
&=\lim\limits_{N\to \infty}{\sum_{n=-N}^{+N}{\cos^{2}\left(\frac{\pi}{4}n\right)}}\\
&=\lim\limits_{N\to \infty}{\sum_{n=-N}^{+N}{\left(\frac{e^{j\frac{\pi}{4}n}+e^{-j\frac{\pi}{4}n}}{2}\right)^{2}}}\\
&=\lim\limits_{N\to \infty}{\frac{1}{4}\sum_{n=-N}^{+N}{\left(e^{j\frac{\pi}{2}n}+2+e^{-j\frac{\pi}{2}n}\right)}}\\
&=\lim\limits_{N\to \infty}{\frac{1}{4}\sum_{n=-N}^{+N}{\left(j^{n}+2+j^{-n}\right)}}\\
&=\lim\limits_{N\to \infty}{\frac{1}{4}\left[\sum_{n=-N}^{+N}{2}+\sum_{n=-N}^{+N}{j^{n}}+\sum_{n=-N}^{+N}{\left(-j\right)^{n}}\right]}
\end{align}
$$
So far, so good... Now here's what I imagined:
$$
\begin{align}
\sum_{n=-N}^{+N}{j^{n}}&=\color{red}{\sum_{n=-N}^{-1}{j^{n}}}+1+\sum_{n=1}^{+N}{j^{n}} \\ 
&=\color{red}{\sum_{n=1}^{+N}{\left(-j\right)^{n}}}+1+\sum_{n=1}^{+N}{j^{n}}
\end{align}
$$
and
$$
\begin{align}
\sum_{n=-N}^{+N}{\left(-j\right)^{n}}&=\color{red}{\sum_{n=-N}^{-1}{\left(-j\right)^{n}}}+1+\sum_{n=1}^{+N}{\left(-j\right)^{n}} \\ 
&=\color{red}{\sum_{n=1}^{+N}{j^{n}}}+1+\sum_{n=1}^{+N}{\left(-j\right)^{n}}
\end{align}
$$
Which gives us:
$$\sum_{n=-N}^{+N}{j^{n}}+\sum_{n=-N}^{+N}{\left(-j\right)^{n}}=2+2\sum_{n=1}^{+N}{j^{n}}+2\sum_{n=1}^{+N}{\left(-j\right)^{n}}$$
Putting this all back into $E_{\infty}$:
$$
\begin{align}
E_{\infty}&=\lim\limits_{N\to \infty}{\frac{1}{4}\left[2+2\sum_{n=-N}^{+N}{1}+2\sum_{n=1}^{+N}{j^{n}}+2\sum_{n=1}^{+N}{\left(-j\right)^{n}}\right]}\\
&=\lim\limits_{N\to \infty}{\frac{1}{2}\left[\left(2N+2\right)+\sum_{n=1}^{+N}{j^{n}}+\sum_{n=1}^{+N}{\left(-j\right)^{n}}\right]}
\end{align}
$$
That's where I got stuck, because this should sum up to:
$$E_{\infty}=\lim\limits_{N\to \infty}{\frac{1}{2}\left[2N+1\right]}=\infty$$
So that:
$$P_{\infty}=\lim\limits_{N\to \infty}{\frac{E_{\infty}}{2N+1}}=\frac{1}{2}\left(\lim\limits_{N\to \infty}{\frac{2N+1}{2N+1}}\right)=\frac{1}{2}$$
Which are the books answers to this exercise...
What am I doing wrong or missing here???

I got to a solution!
All the previous assumtions about the sums were correct... Now:
$$
\begin{align}
E_{\infty}&=\lim\limits_{N\to \infty}{\frac{1}{4}\left[2+2\sum_{n=-N}^{+N}{1}+2\sum_{n=1}^{+N}{j^{n}}+2\sum_{n=1}^{+N}{\left(-j\right)^{n}}\right]}\\
&=\lim\limits_{N\to \infty}{\frac{1}{2}\left[\left(2N+2\right)+\underbrace{\sum_{n=1}^{+N}{j^{n}}+\sum_{n=1}^{+N}{\left(-j\right)^{n}}}_{0}\right]}\\
&=\lim\limits_{N\to \infty}{\frac{1}{2}\left(2N+2\right)}\\
&=\lim\limits_{N\to \infty}{\left(N+1\right)}= \infty
\end{align}
$$
Then:
$$
\begin{align}
P_{\infty}&=\lim\limits_{N\to \infty}{\frac{E_{\infty}}{2N+1}}\\
&=\lim\limits_{N\to \infty}{\frac{N+1}{2N+1}}\\
&=\underbrace{\lim\limits_{N\to \infty}\frac{\frac{d}{dN}\left(N+1\right)}{\frac{d}{dN}\left(2N+1\right)}}_{L'Hopital}=\frac{1}{2}
\end{align}
$$
Actually, I was doing nothing wrong... My mistake was trying to adapt my soluton induced by the answers I already had from the book.
