Evaluating $\int e^{-x}\tan(x) \ \mathrm dx$ . I was told years ago by a visiting professor that this integral:$$\int e^{-x}\tan(x)dx$$ has an elementary form, but I have never been able to find it.  Any suggestions?  I don't think it's possible anymore, but thought I would ask...
 A: It can be proved to be non-elementary using the Risch algorithm.
A: Well, you can prove that this integral is not elementary:
Let denote $\theta_2 = e^{-x}$ and $\theta_1 = e^{ix}$. 
We can convert the tangent to complex exponentials: 
$\tan(x) = \frac{i \left(e^{-i x}-e^{i x}\right)}{e^{-i x}+e^{i x}} = -\frac{i \left(\theta _1^2-1\right)}{\theta _1^2+1}$
So our integral becomes: 
$$\int{ e^{-x}\tan(x)}{dx} = \int{-\theta_2\frac{i \left(\theta _1^2-1\right)}{\theta _1^2+1}}{dx}$$ 
We know by differentiation of exponential polynomials that $\deg(p(\theta_2)) = \deg(p'(\theta_2))$
So we can write:
$$\int{-\theta_2\frac{i \left(\theta _1^2-1\right)}{\theta _1^2+1}}{dx} = q_1\theta_2+q_0$$
Where $q_1, q_0 \in \mathbb{Q}(i)(x,\theta_1)$. If we differentiate both sides (note that $\theta_2' = -\theta_2$), we get: 
$$-\theta_2\frac{i \left(\theta _1^2-1\right)}{\theta _1^2+1} = q_1'\theta_2-q_1\theta_2+q_0'$$
So we get two Risch differential equations by equating the coefficients of $\theta_2$:
$$-\frac{i \left(\theta _1^2-1\right)}{\theta _1^2+1} = q_1'-q_1$$
$$0 = q_0'$$
Since the first one does not have a solution in $\mathbb{Q}(i)(x,\theta_1)$, we can conclude that the integral is not elementary.
