Throughout this course, a connected open subset of $\mathbb{C}$ is called a *domain*. Suppose that a function $f(z)=u(x,y)+iv(x,y)$ is analytic in a domain $\mathcal{D}$. Then $f(z)$ satisfies the Cauchy-Riemann equations i.e.

\begin{equation}

\label{eq:c-r}

u_x=v_y,\ u_y=-v_x.

\end{equation}

Differentiating the Cauchy-Riemann equations \eqref{eq:c-r} with respect to $x$, we obtain

\begin{equation}

\label{eq:c-r2}

u_{xx}=v_{yx},\ u_{yx}=-v_{xx}.

\end{equation}

Differentiating the Cauchy-Riemann equations \eqref{eq:c-r} with respect to $y$, we obtain

\begin{equation}

\label{eq:c-r3}

u_{xy}=v_{yy},\ u_{yy}=-v_{xy}.

\end{equation}

By the continuity of the partial derivatives of $u(x,y)$ and $v(x,y)$, we have

\begin{equation}

\label{eq:cont}

u_{xy}=u_{yx},\ v_{xy}=v_{yx}.

\end{equation}

Applying \eqref{eq:cont} to \eqref{eq:c-r2} and \eqref{eq:c-r3}, we obtain the Laplace equations:

$$u_{xx}+u_{yy}=0,\ v_{xx}+v_{yy}=0.$$

That is to say, $u(x,y)$ and $v(x,y)$ are harmonic maps in $\mathcal{D}$.

*Example*. The function $f(z)=e^{-y}\sin x-ie^{-y}\cos x$ is entire (i.e analytic on the complex plane $\mathbb{C}$), so both $e^{-y}\sin x$ and $-e^{-y}\cos x$ are harmonic. (You can of course check it for yourself!)

If two functions $u(x,y)$, $v(x,y)$ are harmonic in a domain $\mathcal{D}$ and their first-order partial derivatives satisfy the Cauchy-Riemann equations \eqref{eq:c-r} throughout $\mathcal{D}$, $v(x,y)$ is said to be a *harmonic conjugate* of $u(x,y)$.

*Theorem*. A function $f(z)=u(x,y)+iv(x,y)$ is analytic in a domain $\mathcal{D}$ if and only if $v(x,y)$ is a harmonic conjugate of $u(x,y)$.

*Remark*. If $v(x,y)$ is a harmonic conjugate of $u(x,y)$ in some domain, it is not in general true that $u$ is a harmonic conjugate of $v$ there.

*Example*. Let $u(x,y)=x^2-y^2$ and $v(x,y)=2xy$. Since $f(z)=z^2=(x^2-y^2)+i2xy$ is entire, $v(x,y)$ is a harmonic conjugate of $u(x,y)$. However, $u(x,y)$ cannot be a harmonic conjugate of $v(x,y)$ since $2xy+i(x^2-y^2)$ is not analytic anywhere.

*Example*. [Finding a harmonic conjugate of a harmonic function] Let $u(x,y)=y^3-3x^2y$ and $v(x,y)$ be a harmonic conjugate of $u(x,y)$. Then it follows from the Cauchy-Riemann equations \eqref{eq:c-r} that $v_y=-6xy$. Integrating this with respect to $y$, we obtain

$$v(x,y)=-3xy^2+\phi(x),$$

where $\phi(x)$ is some unknown function. We determine $\phi(x)$ using $u_y=-v_x$:

$$v_x=-3y^2+\phi’(x).$$

Comparing this with $-u_y=-3y^2+3x^2$, we get $\phi’(x)=3x^2$ and so, $\phi(x)=x^3+C$ where $C$ is a constant. Hence, we find a harmonic conjugate of $u(x,y)$:

$$v(x,y)=-3xy^2+x^3+C,$$

where $C$ is a constant. The corresponding analytic function is

$$f(z)=(y^3-3x^2y)+i(-3xy^2+x^3+C),$$

where $C$ is a constant.