$ \lim_{a\to\infty} {a\int_{0}^{\frac{\pi}{4}}e^x\space \tan^a{x}\space dx}$ $$Let \space I(a) = \int_{0}^{\frac{\pi}{4}} {e^{x} \tan^{a} x} \space . \space Find 
\space \lim_{a\to\infty}aI(a). $$
Well this is an integral that I'm curently dealing with and so far I've tried to solve it using different approaches. Still, I haven't solved it and what I find always is an undefined answer. Even when I used mathematica it returned an undefined answer. This solution in my opinion is most likely to be the one that works: $$\\$$ Our Integral is $$\int_{0}^{\frac{\pi}{4}}e^x\space \lim_{a\to\infty}[{a\tan^a{x}}]\space dx,$$
letting $$A=\lim_{a\to\infty}{a\tan^a{x}}$$
We know that $$x \in [0,\frac{\pi}{4}]\space \Rightarrow \space \tan{x} \in[0,1] \space \Rightarrow \space \lim_{a\to\infty}a\tan{^ax}=
\  \begin{cases} 
      0 & 0\leq x< \frac{\pi}{4} \\
      1 & x=\frac{\pi}{4}\\
   \end{cases}
  \
$$
Which tells us that
$$ A =
\  \begin{cases} 
      0 \times \infty & 0\leq x< \frac{\pi}{4} \\
      \infty & x=\frac{\pi}{4}\\
   \end{cases}
$$
Which are some undefined integrands... . Mathematica says the integral is undefined but the book, Advanced Calculus Explored, says it has an answer.
I think this is the right solution and I just need to work on the limit a little bit more, but this is something that I'm stuck in. I appreciate any kind of hints or helps.
 A: Our problem is a disguised form of the result
$$\tag 1 \lim_{a\to \infty} a\int_0^1 y^a f(y)\,dy=f(1),$$
which holds for any continuous $f$ on $[0,1].$ It has been proved on MSE many times. The proof is quite simple for $f$ continuously differentiable on $[0,1],$ using integration by parts.
To see why the above will help us in the question at hand, let $x=\arctan y.$ The original expression then turns into
$$a\int_0^1 y^a e^{\arctan y}\frac{1}{1+y^2}\,dy.$$
Letting $f(y) = e^{\arctan y}\frac{1}{1+y^2},$ we see that $(1)$ implies our limit is
$$f(1)= e^{\arctan 1}\frac{1}{1+1^2} = \frac{e^{\pi/4}}{2}.$$
A: Rewrite the integral as
$$\int_0^{\pi/4} dx \, \exp{x} \, \exp{\left [a \left (\log{\tan{x}} \right ) \right ]}$$
Sub $x=\pi/4-y$ and use the tangent addition rule and the integral is
$$\exp{\left ( \frac{\pi}{4} \right )} \int_0^{\pi/4} dy \, \exp{(-y)} \, \exp{\left [a \left (\log{\left (\frac{1-\tan{y}}{1+\tan{y}} \right )} \right ) \right ]}$$
Not that the dominant contribution to the integral as $a \to \infty$ is in the interval in a small neighborhood about $y=0$.  So expand the integrand about $y=0$; then the interval of integration may be expanded out to $[0,\infty)$ because the other contributions are exponentially subdominant.  Accordingly, as $a \to \infty$, the integral behaves as
$$\exp{\left ( \frac{\pi}{4} \right )} \int_0^{\infty} dy \, e^{-2 a y} = \frac1{2 a} \exp{\left ( \frac{\pi}{4} \right )}$$
Accordingly, the sought-after limit is $$ \frac12 \exp{\left ( \frac{\pi}{4} \right )}$$
This has been verified in Mathematica.
A: Another approach (that works for this type of limits, with $a$ times an integral of an $a$-th power times something else) is to "absorb" the factor $a$ using integration by parts. Let $g_a(x)=\tan^a x$. Then $a\cdot e^x\tan^a x=f(x)g_a'(x)$, where $f(x)=e^x\tan x\cos^2 x\color{LightGray}{[{}=\ldots]}$. Hence $$aI(a)=\int_0^{\pi/4}f(x)g_a'(x)\,dx=\underbrace{f(\pi/4)g_a(\pi/4)}_{=(1/2)e^{\pi/4}}-\underbrace{f(0)g_a(0)}_{=0}-\int_0^{\pi/4}f'(x)g_a(x)\,dx.$$ The last integral tends to $0$ as $a\to\infty$ (by DCT as noted in comments if you know it, or by bounding the integrand from above: $f'(x)$ by a constant, and $g_a(x)$ by, say, $\tan x\leqslant 4x/\pi$).
