Show that $f(z)=\sum_{n=0}^{\infty}z^{2^n}$ can't be analytically continued past the unit disk. 
I'm reading the problems of Stein and Shakarchi's Complex Analysis, Chapter 2 Problem 1 asks to show that  $$f(z)=\sum_{n=0}^{\infty}z^{2^n}$$ cannot be analytically continued past the unit disk. (Hint: Suppose $\theta =\frac{2\pi p}{2^k}$ for $p,k$ positive integers, let $z=re^{i\theta}$ and show $\mid f(z)\mid\rightarrow\infty$ as $r \rightarrow1$).


I understand from the hint they want me to "pepper" the unit circle with points where the power expansion explodes so that it is dense with poles. I do not understand why they choose such particular points, but I assume that in retrospect it will show that those are the ones that I can show divergence for the easiest and are dense in the unit circle, so plowing ahead:
$$\lim_{r \rightarrow 1}\left| \sum_{n=0}^\infty r^{2^n}e^{ i2\pi p 2^{n-k}}\right| = \left| \sum_{n=0}^k e^{ \frac{i2\pi p}{2^{k-n}}} + \sum_{n=k+1}^\infty e^{ i2\pi p2^{n-k}} \right|  $$
Where do I go from here? Is there some oversimplification of these sinusoids that I'm not seeing? Furthermore, once I manage to show this explodes, if I show that these numbers are dense on the unit circle I'm done, right?
Any insight is much appreciated.
 A: This may be already answered by the OP himself. Here is a short answer any way.

First, recall that for any power series $f(z)=\sum_{n\geq0}a_nz^n$ with radius of convergence $1$, a point $p\in\mathbb{S}^1$ is called regular (for $f$) if  there is an open ball $D(p;r)$, $r>0$,  and an analytic function $g$ on $D(p;r)$ such that $f(z)=g(z)$ on $D(p;r)\cap D(0;1)$. Any point in $\mathbb{S}^1$ which is not regular for $f$ is said to be singular.

*

*It is easy to see that the set of regular points of $f$ is open and so the set of singular points of $f$ is closed.

*Furthermore, it is well known that the set of singular points is non empty (This can proven by contradiction using the properties of the radius of convergence).

The following result will be useful:
Lemma: If $f(z)=\sum_na_kz^k$ is a power series with radius of convergence $1$ and $a_k\geq0$, then $$\lim_{r\rightarrow1-}f(r)=\sum_ka_k$$
Proof: Since $a_n\geq0$, for each $0<r<1$ and $n\in\mathbb{N}$
$$f_n(r)=\sum^n_{k=0}a_kr^k\leq f(r)=\sum^\infty_{k=0}a_kr^k\leq \sum^\infty_{k=0}a_k $$
Clearly $f$ is monotone nondecreasing over $(0,1)$ and so, $\lim_{r\rightarrow1-}f(r)=\sup_{0<r<1}f(r)$ exists (as an extended real number). Putting things together, we obtain that
$$
\lim_{r\rightarrow1-}f_n(r)=\sum^n_{k=0}a_n\leq \lim_{r\rightarrow1-}f(r)\leq\sum_{k\geq0}a_k
$$
Letting $n\rightarrow\infty$ gives $\sum_ka_k=\lim_{r\rightarrow1-}f(r)$.

For the OP, $f(z)=\sum_{n\geq0}z^{2^n}$ can be expressed as the power series $f(z)=\sum_ka_kz^k$ where $a_k=1$ if $k=2^n$ form some $n\in\mathbb{Z}_+$, and $0$ otherwise. Clearly it has radius of convergence $1$.
Thus, $\lim_{r\rightarrow1-}f(r)=\infty$ by the Lemma above.
On the other hand, for any $z\in B(0;1)$, $f(z^2)=f(z)-z$ from where we obtain (by induction) that
$$ f(z^{2^n})=f(z)-\sum^{n-1}_{j=0}z^{2^j}, \qquad n\in\mathbb{N}$$
Along the line $rz_{k, m}=re^{2\pi i k2^{-m}}$, $0<r<1$,  we have
$$
f(r^{2^m})=f\big(re^{2\pi ik2^{-m}}\big) - \sum^{m-1}_{j=0}r^{2^j}e^{2\pi ik 2^{j-m}}
$$
The term $p_{m,k}=\sum^{m-1}_{j=0}r^{2^j}e^{2\pi ik 2^{j-m}}$ is  bounded by $m+1$. By the Lemma above,  $\lim_{r\rightarrow1-}f(r^{2^m})=\infty$, we conclude that $\lim_{r\rightarrow1-}|f(rz_{m,k})|=\infty$.
As a consequence, all points in  $\mathcal{D}=\{z_{k, m}:k\in\mathbb{Z},m\in\mathbb{Z}\}$ are singular points of $f$. Since $\mathcal{D}$ is dense in $\mathbb{S}^1$, it follows that all points in $\mathbb{S}^1$ are singular for $f$; hence, $f$ cannot be analytically extended to any open domain $\Omega$ that properly contains $D(0;1)$.
A: Yes, your "I understand from the hint" paragraph is good (I especially liked "plowing ahead"). Working with the sum, I wouldn't right off the bat start taking limits. What we can say is that for $0\le r <1,$
$$\tag 1\left| \sum_{n=0}^\infty r^{2^n}e^{ i2\pi p 2^{n-k}}\right| \ge \left |\sum_{n=k+1}^\infty r^{2^n}e^{ i2\pi p2^{n-k}} \right| - \left| \sum_{n=0}^k r^{2^n}e^{ \frac{i2\pi p}{2^{k-n}}}\right|.$$
Now the $n$th summand in first sum on the right is simply $r^{2^n}.$ (That's why those weird points on the boundary were chosen.) In the second sum, move the absolute values inside the sum. This shows $(1)$ is at least
$$\sum_{n=k+1}^\infty r^{2^n} - \sum_{n=0}^k r^{2^n} \ge \sum_{n=k+1}^\infty r^{2^n} - (k+1).$$
Thus we're done if we show the first sum on the right has limit $\infty.$ One way to do this is let $N\in \mathbb N, N>k+1 .$ Then
$$\sum_{n=k+1}^\infty r^{2^n} > \sum_{n=k+1}^N r^{2^n}.$$
This implies
$$\tag 2 \lim_{r\to 1^-} \sum_{n=k+1}^\infty r^{2^n} \ge N-k.$$
Since $N$ is arbitrarily large, the left side of $(2)$ is $\infty,$ and we're done.
A: In the comments I made the claim that a holomorphic function in $\mathbb D$ cannot have radial limit $\infty$ at each boundary point. There was some interest in this, which is why I'm posting another answer (4 years later!). I'll here sketch a proof for the analogous result in the upper half place $H$ to make things a little easier.
Thm: Suppose $f$ is holomorphic on $H.$ Then it is impossible to have
$$\lim_{y\to 0^+}|f(x+iy)|=\infty\, \text {for all } x\in \mathbb R.$$
Proof: Suppose otherwise. The first step is to use Baire. For $m=1,2,\dots,$ let $E_m=\{x\in \mathbb R: |f(x+iy)|\ge 1, 0<y\le 1/m\}.$ Then each $E_m$ is closed and $\mathbb R=\cup E_m.$ By Baire there exists $m$ such that $E_m$ contains a nontrivial interval. Thus there exists a rectangle $R=(a,b)\times (0,h)$ with $|f|\ge 1$ on $R.$
We then have $1/f$ holomorphic on $R$ with $|1/f|\le 1$ in $R.$ So $1/f\in H^\infty(R)!$ Furthermore, $1/f(x+iy) \to 0$ as $y\to 0^+$ for $x\in (a,b).$ It is well known that such a function is identically $0.$ So we conclude $1/f\equiv 0,$ contradiction.
