Evaluate $\int_0^\tau \frac{t\sin(t z)}{z\cos(t z)-\sin(tz)}\text{d}t$ I'm trying to evaluate the following definite integral. Mathematica gives me a complicated expression which I think I can simplify, but I was wondering if there was a "nice" way to evaluate it.
$$\displaystyle\int_0^\tau \frac{t\sin(t z)}{z\cos(t z)-\sin(tz)}\text{d}t$$
 A: This integral doesn't seem to have an elementary expression, at least for general $\tau$. At least Mathematica and my own results agree on this, as the final answer involves polylogarithm.
Let's represent the integral as:
$$I=\frac{1}{z^2} \int_0^{\tau z} \frac{y \sin y}{z \cos y-\sin y}dy$$
My attempt uses integration by parts with:
$$u=y, \qquad dv=\frac{\sin y}{z \cos y-\sin y}dy$$
Antiderivative for $dv$ was obtained by Mathematica, but it's trivial to prove it by differentiation:
$$v=-\frac{1}{1+z^2} \left(y+z \log |z \cos y-\sin y| \right)$$
Using the integration by parts formula, we obtain:
$$I=-\frac{1}{1+z^2} \times \\ \times \left( \tau^2 +\tau \log |z \cos \tau z-\sin \tau z|-\frac{1}{z^2} \int_0^{\tau z}  y dy-\frac{1}{z} \int_0^{\tau z} \log |z \cos y-\sin y| dy  \right)$$

To simplify the last integral, we do a series of transformations:
$$ \log |z \cos y-\sin y|=\frac{1}{2} \log (z \cos y-\sin y)^2=$$
$$=\frac{1}{2} \log ((z^2-1) \cos^2 y-2 \sin y \cos y+1)=$$
$$=\frac{1}{2} \log \left(\frac{z^2+1}{2}+ \frac{z^2-1}{2}\cos 2y-z \sin 2y \right)=$$
$$=\frac{1}{2} \log \left(\frac{z^2+1}{2}\right)+\frac{1}{2} \log \left(1+ \frac{z^2-1}{z^2+1}\cos 2y-\frac{2z}{z^2+1} \sin 2y \right)=$$
$$=\frac{1}{2} \log \left(\frac{z^2+1}{2}\right)+\frac{1}{2} \log \left(1+ \cos \left( 2y+\arcsin \frac{2z}{z^2+1} \right)\right)$$

Simplifying and making a substitution in the last integral $x=2y+\arcsin \frac{2z}{z^2+1}$, we obtain:

$$I=-\frac{1}{2(1+z^2)} \left(\tau^2 +\tau \log \frac{ 2(z \cos \tau z-\sin \tau z)^2}{1+z^2}-\frac{1}{2z} \int_a^{2\tau z+a} \log (1+\cos x) dx  \right)$$
$$a=\arcsin \frac{2z}{1+z^2}$$

The last integral is well known in it's definite form:
$$\int_0^{\pi/2} \log (1+\cos x) dx=2 G-\frac{\pi}{2} \log 2$$
where $G$ is Catalan's constant. However, the indefinite integral isn't so nice and involves polylogarithm.
