\documentclass{article}
\usepackage{graphicx}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{enumerate}
\usepackage{ifthen}
\usepackage{ulem} % for strikethrough \sout{...} command
\usepackage{color}

\usepackage{tikz}
\tikzset{node distance=1.5cm, auto}

\setlength{\oddsidemargin}{-0.50in}
\setlength{\evensidemargin}{-0.50in}
\setlength{\topmargin}{-0.5in}
\setlength{\headheight}{0.0in}
\setlength{\headsep}{0.0in}
\setlength{\topskip}{0.0in}
\setlength{\textheight}{9.6in}
\setlength{\textwidth}{7.5in}


\newcommand{\myspace}{\mbox{\parbox[c][0.35in]{0.35in}{\hfill}}}
\newcommand{\varspace}[2]{\mbox{\parbox[c][#1]{#2}{\hfill}}}

\newcommand{\bdot}{\, {\scriptstyle{\bullet}} \,}
\newcommand{\B}[1]{{\bf {#1}}}
\newcommand{\la}{\langle}
\newcommand{\ra}{\rangle}

\newcommand{\force}{{$\mbox{\;}$}}

\begin{document}

\noindent
\parbox{1.5in}{\bf Math 5160}
\hfill {\Large \bf Complex Differentiability} \hfill
\parbox{1.5in}{\bf \hfill Supplement}

\vspace{0.1in}

For a function of one variable, differentiability is synonymous with the existence of the derivative. However, the notion of differentiability is much more subtle for functions of more than one real variable. But when we consider a function of a single complex variable, once again differentiability is equivalent to the existence of the derivative. Let's see why that is true and how complex differentiability relates to real differentiability.

\vspace{0.05in}

\noindent {\bf Definition:} Let $f:D \to \mathbb{C}$ where $D \subseteq \mathbb{C}$ and $z_0 = x_0+y_0i \in D$. We say $f(z)$ is {\it differentiable} at $z=z_0$ if 

\vspace{-0.1in}

$$f'(z_0) = \lim\limits_{\Delta z \to 0} \dfrac{f(z_0+\Delta z)-f(z_0)}{\Delta z} = \lim\limits_{z \to z_0} \dfrac{f(z)-f(z_0)}{z-z_0}$$ 

\vspace{-0.05in}

\noindent exists (where $z = z_0 + \Delta z$, $z=x+yi$, and $\Delta z = \Delta x+\Delta y\, i$). 

\vspace{0.05in}

Let's see how this relates to differentiability of a function on $\mathbb{R}^2$. First, notice that $f(z)$ being differentiable at $z=z_0$ is the same as there being some number $L = p+qi \in \mathbb{C}$ such that $\lim\limits_{z \to z_0} \dfrac{f(z)-f(z_0)}{z-z_0}=L$. This limit exists (and equals $L$) if and only if $\lim\limits_{z \to z_0} \dfrac{f(z)-f(z_0)}{z-z_0} - L =0$
and so $\lim\limits_{z \to z_0} \dfrac{f(z)-f(z_0)}{z-z_0}-\dfrac{L(z-z_0)}{z-z_0} = 0$. Thus $f(z)$ is differentiable at $z=z_0$ if and only if $\lim\limits_{z \to z_0} \dfrac{f(z)-[f(z_0)+L(z-z_0)]}{z-z_0}=0$ for some $L \in \mathbb{C}$.

We need one more minor modification before we identify with the real situation. Recall that for vector valued functions in $\mathbb{R}^n$, $\lim\limits_{\B x \to \B x_0} g(\B x)=\B 0$ if and only if $\lim\limits_{\B x \to \B x_0} |g(\B x_0)| = 0$. Also, recall that $\left|\frac{a}{b}\right| = \frac{|a|}{|b|}$ (for $a,b\in \mathbb{C}$ and $b \not=0$). Thus $f(z)$ is differentiable at $z=z_0$ if and only if there is some complex number $L$ such that $\lim\limits_{z \to z_0} \dfrac{|f(z)-[f(z_0)+L(z-z_0)]|}{|z-z_0|}=0$

Now we identify $\mathbb{C}$ with $\mathbb{R}^2$ as follows: $x+yi = (x,y)$. Thus $L=p+qi = (p,q)$. For convenience we are going to write elements of $\mathbb{R}^2$ ($=\mathbb{C}$) as ordered pairs, $(x,y)$, or column vectors, $\begin{bmatrix} x\\ y\end{bmatrix}$, as suits our purposes. Thus $x+yi=(x,y)=[x\; y]^T$. So at this point we can think of $f:D \to \mathbb{R}^2$ where $D$ is a subset of $\mathbb{R}^2=\mathbb{C}$. Thus $f(x,y) = (u(x,y), v(x,y))$ where $\mathrm{Re}(f(x,y))=u(x,y)$ and $\mathrm{Im}(f(x,y))=v(x,y)$.

We need to unpack the term $L(z-z_0)$ and rewrite it in a real form. Notice that $L(z-z_0) = (p+qi)((x+yi)-(x_0+y_0i)) =$ 

\vspace{-0.2in}

$$(p+qi)((x-x_0)+(y-y_0)i) = (p(x-x_0)-q(y-y_0))+(q(x-x_0)+p(y-y_0))i =  \begin{bmatrix} p(x-x_0)-q(y-y_0) \\ q(x-x_0)+p(y-y_0) \end{bmatrix} = \begin{bmatrix} p & -q \\ q & p \end{bmatrix} \begin{bmatrix} x-x_0 \\ y-y_0 \end{bmatrix}.$$

\vspace{-0.1in}

\noindent
Therefore, $f(z)$ being differentiable at $z=z_0$ is equivalent to the existence of a real matrix (the Jacobian) $J \in \mathbb{R}^{2 \times 2}$ where $J$ has the form $J = \begin{bmatrix} p & -q \\ q & p \end{bmatrix}$ and

\vspace{-0.35in}
  
$$\hspace*{0.3in} \lim\limits_{(x,y) \to (x_0,y_0)} \dfrac{\left| f(x,y) - \left( f(x_0,y_0) + J [x-x_0\; y-y_0]^T\right)\right|}{|(x,y)-(x_0,y_0)|}=0.$$

Next, the numerator of the fraction in the limit is the length of $\begin{bmatrix} u(x,y) \\ v(x,y) \end{bmatrix} - \left( \begin{bmatrix} u(x_0,y_0) \\ v(x_0,y_0) \end{bmatrix} + \begin{bmatrix} p & -q \\ q & p \end{bmatrix} \begin{bmatrix} x-x_0 \\ y-y_0 \end{bmatrix} \right)$. 
We know

\vspace{0.03in}

\noindent that $\lim\limits_{\B x \to \B x_0} |(g(\B x), h(\B x))| =0$ if and only if both $\lim\limits_{\B x \to \B x_0} |g(\B x)| =0$ and $\lim\limits_{\B x \to \B x_0} |h(\B x)| =0$ (limits of vectors are determined by limits of their components). Therefore, $f(z)$ is differentiable at $z=z_0$ if and only if there is a complex number $L=p+qi$ such that both

\vspace{-0.25in}

$$\lim\limits_{(x,y) \to (x_0,y_0)} \dfrac{\left| u(x,y) - \left( u(x_0,y_0) + p(x-x_0)-q(y-y_0)\right)\right|}{|(x,y)-(x_0,y_0)|}=0$$

\vspace{-0.15in} 

\noindent and 

\vspace{-0.15in}

$$\lim\limits_{(x,y) \to (x_0,y_0)} \dfrac{\left| v(x,y) - \left( v(x_0,y_0) + q(x-x_0)+p(y-y_0)\right)\right|}{|(x,y)-(x_0,y_0)|}=0.$$
This says that not only are $u(x,y)$ and $v(x,y)$ differentiable at $(x_0,y_0)$, but also $u_x(x_0,y_0)=p=v_y(x_0,y_0)$ and $u_y(x_0,y_0)=-q=-v_x(x_0,y_0)$.
Let's sum up what we have found.

\vspace{0.05in}

\noindent {\bf Theorem:} Suppose $f:D \to \mathbb{C}$ where $D \subseteq \mathbb{C}$ and $z_0=(x_0,y_0) \in \mathbb{C} = \mathbb{R}^2$, $z=x+yi=(x,y)$, and $f(z)=u(x,y)+v(x,y)i$. Then $f(z)$ is differentiable (as a complex function) at $z=z_0$ if and only if 

\vspace{-0.1in}

\begin{itemize} \setlength\itemsep{0pt}
\item Both $u(x,y)$ and $v(x,y)$ are differentiable (as real scalar valued functions of two variables) at $(x_0,y_0)$ and\dots
\item The Cauchy-Riemann equations hold: $u_x(x_0,y_0)=v_y(x_0,y_0)$ and $-u_y(x_0,y_0)=v_x(x_0,y_0)$.
\end{itemize}

\vspace{-0.1in}

\noindent
Moreover, if $f(z)$ is differentiable at $z=z_0$, we have that $f'(z_0)=u_x(x_0,y_0)+v_x(x_0,y_0)i = -u_y(x_0,y_0)+v_x(x_0,y_0)i$.

\vspace{0.05in}

%\newpage

Recall that a (real) multivariate scalar valued function is differentiable if its partials exist and are continuous. Since (i) we tend to work nearly exclusively with elementary functions,  (ii) elementary functions have elementary functions as derivatives (where they exist), and (iii) elementary functions are continuous wherever they are defined, we have that testing if partials exist and are continuous to see if a function is differentiable works in nearly every case we run into.
Therefore, an easy way to establish that $f(z)=u(x,y)+v(x,y)i$ is differentiable (as a complex function) is to compute $u_x,u_y,v_x,v_y$, make sure these partials are continuous, and then check the Cauchy-Riemann equations: $u_x=v_y$ and $-u_y=v_x$. 

By the way, if we are only interested in showing that the existence of $f'(z)$ implies the Cauchy-Riemann equations, this can be done much more efficiently as follows: Suppose that $f(z)$ is differentiable at $z=z_0$. Then 

\vspace{-0.1in}

$$ f'(z_0) = \lim\limits_{\Delta x + \Delta y\, i \to 0} \dfrac{(u(x_0+\Delta x,y_0+\Delta y)+v(x_0+\Delta x,y_0+\Delta y)i) - (u(x_0,y_0)+v(x_0,y_0)i)}{\Delta x+\Delta y \, i}$$

\vspace{-0.05in}

\noindent
exists. Thus the limit exists along every (continuous) path through $0$. In particular, we can approach along the imaginary and real axes. 
Approaching along the real axis, $\Delta x \to 0$ and $\Delta y =0$ yields

\vspace{-0.1in}

$$ \begin{array}{rcl} f'(z_0) & = & \lim\limits_{\Delta x \to 0} \dfrac{(u(x_0+\Delta x,y_0)+v(x_0+\Delta x,y_0)i) - (u(x_0,y_0)+v(x_0,y_0)i)}{\Delta x} \vspace{0.05in} \\
 & = & \lim\limits_{\Delta x \to 0} \dfrac{u(x_0+\Delta x,y_0)-u(x_0,y_0)}{\Delta x} + \dfrac{(v(x_0+\Delta x,y_0) - v(x_0,y_0))i}{\Delta x}  \vspace{0.05in} 
 = u_x(x_0,y_0)+v_x(x_0,y_0)i\\
 \end{array}
$$

\vspace{-0.05in}

\noindent
Approaching along the imaginary axis, $\Delta x=0$ and $\Delta y \to 0$ yields

\vspace{-0.1in}

$$ \begin{array}{rcl} f'(z_0) & = & \lim\limits_{\Delta y \to 0} \dfrac{(u(x_0,y_0+\Delta y)+v(x_0,y_0+\Delta y)i) - (u(x_0,y_0)+v(x_0,y_0)i)}{\Delta y \, i} \vspace{0.05in} \\
 & = & \lim\limits_{\Delta y \to 0} \dfrac{u(x_0,y_0+\Delta y)-u(x_0,y_0)}{\Delta y\, i} + \dfrac{(v(x_0,y_0+\Delta y) - v(x_0,y_0))i}{\Delta y \, i}  \vspace{0.05in} \\
 & = & \lim\limits_{\Delta y \to 0} -\dfrac{u(x_0,y_0+\Delta y)-u(x_0,y_0)}{\Delta y}i + \dfrac{v(x_0,y_0+\Delta y) - v(x_0,y_0)}{\Delta y}  \vspace{0.05in}  = -u_y(x_0,y_0)i+v_y(x_0,y_0)\\
 \end{array}
$$

\vspace{-0.05in}

\noindent
Therefore, we have that $f'(z_0) = u_x(x_0,y_0)+v_x(x_0,y_0)i = v_y(x_0,y_0)-u_y(x_0,y_0)i$ and so $u_x(x_0,y_0)=v_y(x_0,y_0)$ and $-u_y(x_0,y_0)=v_x(x_0,y_0)$.

\vspace{0.05in}

While this calculation is faster, it does not help determine when $f$ is differentiable. Just because a multivariate limit exists and matches along axes does not mean the (multivariate) limit exists.

\vspace{0.1in}

\noindent {\bf Example:} Consider the function $f(x+yi) = (x^2+y^2)+(xy)i$ so $u(x,y)=x^2+y^2$ and $v(x,y)=xy$.

\vspace{0.05in}

We get that $u_x=2x$, $u_y=2y$, $v_x=y$, and $v_y=x$. Thus (since all of these partials are continuous) $f$ is differentiable as a function on $\mathbb{R}^2$. But the Cauchy-Riemann equations don't hold (everywhere): $u_x = 2x \not= x = v_y$ (and $-u_y=-2y \not= y=v_x$ as well). In fact, to make the Cauchy-Riemann equations hold we need $2x=x$ and $-2y=y$ so $x=y=0$. Since $f$ is (real) differentiable at $0$ and the Cauchy-Riemann equations hold there, $f$ is complex differentiable at $0$. Moreover, since the Cauchy-Riemann equations fail to hold everywhere else, $z=0$ is the {\it only} place where $f$ is (complex) differentiable. Also, we have $f'(0)=u_x(0,0)+v_x(0,0)i = 0$. 

We could use the limit definition to figure all of this out, but this is much harder! I'll illustrate by using the limit definition to show $f'(0)=0$ and then (again using the limit definition) I'll show that $f'(1+2i)$ does not exist.

\vspace{-0.2in}

$$f'(0) = \lim\limits_{\Delta z \to 0} \dfrac{f(0+\Delta z)-f(0)}{\Delta z} = \lim\limits_{\Delta z \to 0} \dfrac{((0+\Delta x)^2+(0+\Delta y)^2)+(0+\Delta x)(0+\Delta y)i - ((0^2+0^2)+(0\cdot 0)i)}{\Delta x + i\Delta y}$$

\vspace{-0.1in}

$$ = \lim\limits_{\Delta z \to 0} \dfrac{(\Delta x)^2+(\Delta y)^2+\Delta x\,\Delta y\,i}{\Delta x+\Delta y\,i} = 
\lim\limits_{\Delta z \to 0} \dfrac{(\Delta x)^2+(\Delta y)^2+\Delta x\,\Delta y\,i}{\Delta x+\Delta y\,i} \cdot \dfrac{\Delta x - \Delta y\,i}{\Delta x - \Delta y\,i}$$

$$ = \lim\limits_{\Delta z \to 0} \dfrac{((\Delta x)^2+(\Delta y)^2)\Delta x+(\Delta x\,\Delta y)\Delta y + ((\Delta x\,\Delta y)\Delta x-((\Delta x)^2+(\Delta y)^2)\Delta y)i}{(\Delta x)^2+(\Delta y)^2}$$

$$ = \lim\limits_{\Delta z \to 0} \dfrac{((\Delta x)^2+(\Delta y)^2)\Delta x+(\Delta x\,\Delta y)\Delta y + ((\Delta x\,\Delta y)\Delta x-((\Delta x)^2+(\Delta y)^2)\Delta y)i}{(\Delta x)^2+(\Delta y)^2}$$

$$ = \lim\limits_{\Delta z \to 0} \dfrac{(\Delta x)^3+2(\Delta y)^2\Delta x - (\Delta y)^3i}{(\Delta x)^2+(\Delta y)^2} = \lim\limits_{(r,\theta) \to (0,\theta)} \dfrac{r^3\cos^3(\theta)+2r^3\sin^2(\theta)\cos(\theta)-r^3\sin^3(\theta)i}{r^2}$$

$=\lim\limits_{(r,\theta) \to (0,\theta)} r\cos^3(\theta)+2r\sin^3(\theta)-r\sin^3(\theta)i = 0$. {\it Note:} I shifted to polar coordinates (a Calculus 3 trick): $\Delta x = r\cos(\theta)$, $\Delta y = r\sin(\theta)$, so $(\Delta x)^2+(\Delta y)^2=r^2$ and the origin is $(0,\theta)$ with $\theta$ arbitrary. Thus $f'(0)=0$.

\vspace{0.05in}

\noindent
Alternatively, consider $f'(1+2i)$.

\vspace{-0.2in}

$$f'(1+2i) = \lim\limits_{\Delta z \to 0} \dfrac{f((1+2i)+\Delta z)- f(1+2i)}{\Delta z} = \lim\limits_{\Delta z \to 0} \dfrac{((1+\Delta x)^2+(2+\Delta y)^2)+(1+\Delta x)(2+\Delta y)i - (5+2i)}{\Delta z}$$

Approaching along $\Delta y=0$ (the real axis): $\lim\limits_{\Delta x \to 0} \dfrac{(1+\Delta x)^2+2^2+(1+\Delta x)(2)i - (5+2i)}{\Delta x}$
$=\lim\limits_{\Delta x \to 0} \dfrac{(\Delta x)^2+2\Delta x+2\Delta x\,i}{\Delta x}$ $= \lim\limits_{\Delta x \to 0} \Delta x+2+2i = 2+2i$
and along $\Delta x=0$ (the imaginary axis): $\lim\limits_{\Delta y \to 0} \dfrac{1^2+(2+\Delta y)^2+1(2+\Delta y)i-(5+2i)}{\Delta y\, i}$
$= \lim\limits_{\Delta y \to 0} \dfrac{(\Delta y)^2+4\Delta y+2\Delta y\, i}{\Delta y\,i}$
$ = \lim\limits_{\Delta y \to 0} \dfrac{\Delta y+4+2i}{i} =  2-4i$. Since $2+2i \not= 2-4i$, the limit cannot exist. Thus $f'(1+2i)$ does not exist.



\end{document}