# Identity theorem

In real analysis and complex analysis, branches of mathematics, the identity theorem for analytic functions states: given functions f and g analytic on a domain D (open and connected subset of $\mathbb {R}$ or $\mathbb {C}$), if f = g on some $S\subseteq D$, where $S$ has an accumulation point in D, then f = g on D.
Thus an analytic function is completely determined by its values on a single open neighborhood in D, or even a countable subset of D (provided this contains a converging sequence together with its limit). This is not true in general for real-differentiable functions, even infinitely real-differentiable functions. In comparison, analytic functions are a much more rigid notion. Informally, one sometimes summarizes the theorem by saying analytic functions are "hard" (as opposed to, say, continuous functions which are "soft").
The underpinning fact from which the theorem is established is the expandability of a holomorphic function into its Taylor series.
The connectedness assumption on the domain D is necessary. For example, if D consists of two disjoint open sets, $f$ can be $0$ on one open set, and $1$ on another, while $g$ is $0$ on one, and $2$ on another.

## Lemma

If two holomorphic functions $f$ and $g$ on a domain D agree on a set S which has an accumulation point $c$ in $D$, then $f=g$ on a disk in $D$ centered at $c$.
To prove this, it is enough to show that $f^{(n)}(c)=g^{(n)}(c)$ for all $n\geq 0$, since both functions are analytic.
If this is not the case, let $m$ be the smallest nonnegative integer with $f^{(m)}(c)\neq g^{(m)}(c)$. By holomorphy, we have the following Taylor series representation in some open neighborhood U of $c$:
    ${\begin{aligned}(f-g)(z)&=(z-c)^{m}\cdot \left[{\frac {(f-g)^{(m)}(c)}{m!}}+{\frac {(z-c)\cdot (f-g)^{(m+1)}(c)}{(m+1)!}}+\cdots \right]\\[6pt]&=(z-c)^{m}\cdot h(z).\end{aligned}}$
By continuity, $h$ is non-zero in some small open disk $B$ around $c$. But then $f-g\neq 0$ on the punctured set $B-\{c\}$. This contradicts the assumption that $c$ is an accumulation point of $\{f=g\}$.
This lemma shows that for a complex number $a\in \mathbb {C}$, the fiber $f^{-1}(a)$ is a discrete (and therefore countable) set, unless $f\equiv a$.

## Proof

Define the set on which $f$ and $g$ have the same Taylor expansion: $S=\left\{z\in D\mathrel {\Big \vert } f^{(k)}(z)=g^{(k)}(z){\text{ for all }}k\geq 0\right\}=\bigcap _{k=0}^{\infty }\left\{z\in D\mathrel {\Big \vert } {\biglf^{(k)}-g^{(k)}{\bigr )}(z)=0\right\}.$
We'll show $S$ is nonempty, open, and closed. Then by connectedness of $D$, $S$ must be all of $D$, which implies $f=g$ on $S=D$.
By the lemma, $f=g$ in a disk centered at $c$ in $D$, they have the same Taylor series at $c$, so $c\in S$, $S$ is nonempty.
As $f$ and $g$ are holomorphic on $D$, $\forall w\in S$, the Taylor series of $f$ and $g$ at $w$ have non-zero radius of convergence. Therefore, the open disk $B_{r}(w)$ also lies in $S$ for some $r$. So $S$ is open.
By holomorphy of $f$ and $g$, they have holomorphic derivatives, so all $\textstyle f^{(n)},g^{(n)}$ are continuous. This means that $\textstyle {\bigl \z\in D\mathrel {\big \vert } {\biglf^{(k)}-g^{(k)}{\bigr )}(z)=0{\bigr \}}$ is closed for all $k$. $S$ is an intersection of closed sets, so it's closed.

## Full characterisation

Since the identity theorem is concerned with the equality of two holomorphic functions, we can simply consider the difference (which remains holomorphic) and can simply characterise when a holomorphic function is identically 0{\textstyle 0}. The following result can be found in.

### Claim

Let G⊆C{\textstyle G\subseteq \mathbb {C} } denote a non-empty, connected open subset of the complex plane. For h:G→C{\textstyle h:G\to \mathbb {C} } the following are equivalent.
* h≡0{\textstyle h\equiv 0} on G{\textstyle G};
* the set G$_0$={z∈G∣h(z)=0}{\textstyle G_{0}=\{z\in G\mid h(z)=0\}} contains an accumulation point, z$_0${\textstyle z_{0}};
* the set G$_∗$=⋂$_{n∈N0}$G$_n${\textstyle G_{\ast }=\bigcap _{n\in \mathbb {N} _{0}}G_{n}} is non-empty, where G$_n$:={z∈G∣h$^{(n)}$(z)=0}{\textstyle G_{n}:=\{z\in G\mid h^{(n)}(z)=0\}}.

### Proof

The directions (1 ⇒{\textstyle \Rightarrow } 2) and (1 ⇒{\textstyle \Rightarrow } 3) hold trivially.
For (3 ⇒{\textstyle \Rightarrow } 1), by connectedness of G{\textstyle G} it suffices to prove that the non-empty subset, G$_∗$⊆G{\textstyle G_{\ast }\subseteq G}, is clopen (since a topological space is connected if and only if it has no proper clopen subsets). Since holomorphic functions are infinitely differentiable, i.e. h∈C$^∞$(G){\textstyle h\in C^{\infty }(G)}, it is clear that G$_∗${\textstyle G_{\ast }} is closed. To show openness, consider some u∈G$_∗${\textstyle u\in G_{\ast }}. Consider an open ball U⊆G{\textstyle U\subseteq G} containing u{\textstyle u}, in which h{\textstyle h} has a convergent Taylor-series expansion centered on u{\textstyle u}. By virtue of u∈G$_∗${\textstyle u\in G_{\ast }}, all coefficients of this series are 0{\textstyle 0}, whence h≡0{\textstyle h\equiv 0} on U{\textstyle U}. It follows that all n{\textstyle n}-th derivatives of h{\textstyle h} are 0{\textstyle 0} on U{\textstyle U}, whence U⊆G$_∗${\textstyle U\subseteq G_{\ast }}. So each u∈G$_∗${\textstyle u\in G_{\ast }} lies in the interior of G$_∗${\textstyle G_{\ast }}.
Towards (2 ⇒{\textstyle \Rightarrow } 3), fix an accumulation point z$_0$∈G$_0${\textstyle z_{0}\in G_{0}}. We now prove directly by induction that z$_0$∈G$_n${\textstyle z_{0}\in G_{n}} for each n∈N$_0${\textstyle n\in \mathbb {N} _{0}}. To this end let r∈(0, ∞){\textstyle r\in (0, \infty )} be strictly smaller than the convergence radius of the power series expansion of h{\textstyle h} around z$_0${\textstyle z_{0}}, given by ∑$_{k∈N0}$ h$^{(k)}$(z$_0$)/k! (z−z$_0$)$^k${\textstyle \sum _{k\in \mathbb {N} _{0}}{\frac {h^{(k)}(z_{0})}{k!}}(z-z_{0})^{k}}. Fix now some n≥0{\textstyle n\geq 0} and assume that z$_0$∈G$_k${\textstyle z_{0}\in G_{k}} for all k<n{\textstyle k<n}. Then for z∈B$^¯$$_r$(z$_0$)∖{z$_0$}{\textstyle z\in {\bar {B}}_{r}(z_{0})\setminus \{z_{0}\}} manipulation of the power series expansion yields
| $h^{(n)}(z_{0})=n!{\frac {h(z)}{(z-z_{0})^{n}}}-(z-z_{0})\underbrace {n!\sum _{k=n+1}^{\infty }{\frac {h^{(k)}(z_{0})}{k!}}(z-z_{0})^{k-(n+1)}} _{=:R(z)}.$ | (1) |
Note that, since r{\textstyle r} is smaller than radius of the power series, one can readily derive that the power series R(⋅){\textstyle R(\cdot )} is continuous and thus bounded on B$^¯$$_r$(z$_0$){\textstyle {\bar {B}}_{r}(z_{0})}.
Now, since z$_0${\textstyle z_{0}} is an accumulation point in G$_0${\textstyle G_{0}}, there is a sequence of points (z$^{(i)}$)$_i$⊆G$_0$∩B$_r$(z$_0$)∖{z$_0$}{\textstyle (z^{(i)})_{i}\subseteq G_{0}\cap B_{r}(z_{0})\setminus \{z_{0}\}} convergent to z$_0${\textstyle z_{0}}. Since h≡0{\textstyle h\equiv 0} on G$_0${\textstyle G_{0}} and since each z$^{(i)}$∈G$_0$∩B$_r$(z$_0$)∖{z$_0$}{\textstyle z^{(i)}\in G_{0}\cap B_{r}(z_{0})\setminus \{z_{0}\}}, the expression in (1) yields
| $h^{(n)}(z_{0})=n!{\frac {h(z^{(i)})}{(z^{(i)}-z_{0})^{n}}}-(z^{(i)}-z_{0})R(z^{(i)})=0-\underbrace {(z^{(i)}-z_{0})} _{\longrightarrow _{i}0}R(z^{(i)}).$ | (2) |
By the boundedness of R(⋅){\textstyle R(\cdot )} on B$^¯$$_r$(z$_0$){\textstyle {\bar {B}}_{r}(z_{0})}, it follows that h$^{(n)}$(z$_0$)=0{\textstyle h^{(n)}(z_{0})=0}, whence z$_0$∈G$_n${\textstyle z_{0}\in G_{n}}. Via induction the claim holds. Q.E.D.