# Complex integral without theory of holomorphic functions

Let's $$z_0=-e^{i\theta_0}$$ and $$z$$ not in the line $$(Oz_0)$$

How can I compute the following integral

$$\int_0^1 \frac{dt}{z_0 + t(z-z_0)}$$

without talking about complex logarithm and holomorphic functions?

The value is obviously $$\frac{1}{z-z_0}(\log(z) - \log(z_0))$$, where $$\log$$ is a determination of logarithm everywhere except on $$(Oz_0)$$ but I'd like to compute this integral without all the theory of complex logarithms.

If $$z$$ and $$z_0$$ are any distinct, nonzero complex numbers which are not on the same line through the origin, then the number $$z_0/(z - z_0)$$ has a nonzero imaginary part. Let $$a$$ and $$b$$ denote the real and imaginary parts of $$z_0/(z - z_0),$$ respectively.

The integral is

\begin{align} \frac{1}{z - z_0}\int_0^1 \frac{dt}{(a + bi) + t} &= \frac{1}{z - z_0}\int_0^1 \frac{(a - bi + t)\,dt}{\lvert a + bi + t\rvert^2}\\ &= \frac{1}{z - z_0}\biggl[\int_0^1 \frac{(t + a)\,dt}{(t + a)^2 + b^2} + i\int_0^1 \frac{(-b)\,dt}{(t + a)^2 + b^2}\biggr]. \end{align}

The first integrand has $$\log\sqrt{(t + a)^2 + b^2}$$ as an antiderivative. This is the usual logarithm defined on the positive reals, so there is no complex logarithm being used here.

The second integrand has $$\cot^{-1}[(t + a)/b]$$, with range in $$(0,\pi),$$ as an antiderivative. So, the result is

$$\frac{1}{z - z_0}\biggl[\log \sqrt{\frac{(1 + a)^2 + b^2}{a^2 + b^2}} + i\Bigl(\cot^{-1}\frac{1 + a}{b} - \cot^{-1}\frac{a}{b}\Bigr)\biggr].$$

This simplifies to

$$\frac{1}{z - z_0}\Bigl[\log\frac{\lvert z\rvert}{\lvert z_0\rvert}{} + i \Bigl(\cot^{-1}\frac{1 + a}{b} - \cot^{-1}\frac{a}{b}\Bigr)\Bigr],$$

using the definition of $$a$$ and $$b$$.

Edit: I would like to point out that the imaginary part of the expression in brackets is one way to calculate the difference of the arguments of $$z$$ and $$z_0$$, so this (expectedly) agrees with a complex logarithm.