# Is it Possible to have Two Distinct Analytic Functions with the Same Real Part?

My professor says given the real part $u$ of an analytic function $f$ defined on a domain $D\subset \mathbb{C}$, that we can't rule out the possibility that there could exist some other analytic function $g$, distinct from $f$ beyond just the addition of a constant, defined on a domain $E\subset \mathbb{C}$ either disjoint from, or not homeomorphic to, $D$, provided that $f$ is not analytic on $E$.

Since differentiating $u$ with respect to one variable and then integrating it with respect to the other completely determines the imaginary part, what this says to me is that $u$ would have to either produce different partial derivatives on $D$ and $E$ respectively, or $\frac{\partial u}{\partial x}$ different primitives.

The case of D and E being disjoint is trivial, but can anyone give me an example for D and E overlapping but non-homeomorphic?

-
Since the domains $D$ and $E$ can be disjoint I can't seem to see what is the problem. How can the functions have the same real part if they are not defined on the same domain? – Beni Bogosel Apr 23 '12 at 16:23
Ya I considered that and added an edit. I'll probably change the post to ask for the case of overlapping but non-homeomorphic. – esproff Apr 23 '12 at 16:23
This question does not make much sense to me. What does it mean for two functions defined on disjoint domains to "have the same real part"? – t.b. Apr 23 '12 at 16:32
Well I guess knowing they are defined on disjoint domains doesn't necessarily rule out that they could both in fact be defined on, for example, all of $\mathbb{C}$, it's possible I'm being a bit sloppy. – esproff Apr 23 '12 at 16:34
@t.b. Ok. Sorry about that. – Beni Bogosel Apr 23 '12 at 16:36

Let $f$ and $g$ be two analytic functions defined on the domains $D$ and $E$, respectively, and suppose $A=D\cap E$ is nonempty and connected. Suppose that $\Re f(z) = \Re g(z)$ for all $z\in A$. Then I claim that $f$ and $g$ differ by an additive (imaginary) constant, that is, $f(z) = g(z) + i\alpha$ for some $\alpha\in\mathbb R$. (Furthermore, by the uniqueness of analytic continuation, this relationship continues to hold wherever $f$ and $g$ are both defined.)
To prove the claim, we set $h=f-g$; then $\Re h(z)=0$ for all $z\in A$, and we need to show that $h$ is constant. But this follows immediately from the Cauchy-Riemann equations (the integral of the derivative of $0$ is constant), since the difference of two analytic functions is also analytic. (More precisely, the derivative being zero forces $h$ to be locally constant; since $A$ is connected, that implies that $h$ is constant.)
In particular, suppose that $g(z)$ were an analytic function defined on the annulus such that $\Re g(z) = \log |z|$ everywhere in the annulus. In particular, on the slit annulus, $\Re g(z) = \Re(\log z)$ (for your favorite branch of $\log$ defined on that slit annulus). Then on the slit annulus, $g(z) = \log z + i\alpha$ for some $\alpha\in\mathbb R$. However, the function $\log z + i\alpha$ is not continuous on the slit, contradicting the analyticity of $g$ there; hence there can be no such $g$.
But if $A = D \cap E$ is not connected, $f - g$ could be different constants in different components of $A$. For example, let $f(z)$ be the principal value of $\ln(z)$, analytic in $D = {\mathbb C} \backslash (-\infty,0]$, and $g(z)$ the branch of $\ln(z)$ with imaginary part in $(0,2\pi)$, defined in $E = {\mathbb C} \backslash [0,+\infty)$. Then $f(z)-g(z) = 0$ in the upper half plane and $-2\pi i$ in the lower half plane. – Robert Israel Apr 23 '12 at 17:26