hard integral problems to solve I'm practicing harder integration using techniques of solving with special functions 
I have difficulties with these two hard integrals; don't even know how to start,
$$\int_0 ^\infty x^p e^{-\frac{\theta}{x}+Bx}dx$$
where $\theta,B>0$
$$pv\int_0 ^\infty \frac{x^p e^{\cos{\theta x}} \cos(\frac{\pi p}{2} - \sin\theta x)}{1-x^2}dx$$
please help me to start of giving your solutions! thank you so much and have a good day/night 
 A: Let $\theta=b$ and $B = -a \lt 0$.  Then the first integral is a generalization of this integral.  Using the same substitutions:
$u=a x+b/x$.  Then $a x^2-u x+b = 0$, and therefore
$$x = \frac{u}{2 a} \pm \frac{\sqrt{u^2-4 a b}}{2 a}$$
$$dx = \frac1{2 a}\left (1 \pm  \frac{u}{\sqrt{u^2-4 a b}}\right ) du $$
Now, it should be understood that as $x$ traverses from $0$ to $\infty$, $u$ traverses from $\infty$ down to a min of $2 \sqrt{a b}$ (corresponding to $x \in [0,\sqrt{b/a}]$), then from $2 \sqrt{a b}$ back to $\infty$ (corresponding to $x \in [\sqrt{b/a},\infty)$).  Therefore the integral is
$$\frac1{2 a} \int_{\infty}^{2 \sqrt{a b}} du \, \left (\frac{u}{2 a} - \frac{\sqrt{u^2-4 a b}}{2 a} \right )^p \left (1 -  \frac{u}{\sqrt{u^2-4 a b}}\right ) e^{-u} \\+ \frac1{2 a} \int_{2 \sqrt{a b}}^{\infty} du \, \left (\frac{u}{2 a} + \frac{\sqrt{u^2-4 a b}}{2 a} \right )^p \left (1 +  \frac{u}{\sqrt{u^2-4 a b}}\right ) e^{-u}  $$
which simplifies, subbing $u=2 \sqrt{a b} \cosh{v}$, to
$$\begin{align}\int_0^{\infty} dx \, x^p e^{-\left (a x+\frac{b}{x} \right )} &=2 \left (\sqrt{\frac{b}{a}} \right )^{p+1} \int_0^{\infty} dv \, \cosh{[(p+1) v]} \, e^{-2 \sqrt{a b} \cosh{v}} \\ &=2 \left (\sqrt{\frac{b}{a}} \right )^{p+1} K_{p+1} \left ( 2 \sqrt{a b}\right )\end{align}$$
A: $\newcommand{\angles}[1]{\left\langle\,{#1}\,\right\rangle}
 \newcommand{\braces}[1]{\left\lbrace\,{#1}\,\right\rbrace}
 \newcommand{\bracks}[1]{\left\lbrack\,{#1}\,\right\rbrack}
 \newcommand{\dd}{\mathrm{d}}
 \newcommand{\ds}[1]{\displaystyle{#1}}
 \newcommand{\expo}[1]{\,\mathrm{e}^{#1}\,}
 \newcommand{\half}{{1 \over 2}}
 \newcommand{\ic}{\mathrm{i}}
 \newcommand{\iff}{\Longleftrightarrow}
 \newcommand{\imp}{\Longrightarrow}
 \newcommand{\Li}[2]{\,\mathrm{Li}_{#1}\left(\,{#2}\,\right)}
 \newcommand{\ol}[1]{\overline{#1}}
 \newcommand{\pars}[1]{\left(\,{#1}\,\right)}
 \newcommand{\partiald}[3][]{\frac{\partial^{#1} #2}{\partial #3^{#1}}}
 \newcommand{\ul}[1]{\underline{#1}}
 \newcommand{\root}[2][]{\,\sqrt[#1]{\,{#2}\,}\,}
 \newcommand{\totald}[3][]{\frac{\mathrm{d}^{#1} #2}{\mathrm{d} #3^{#1}}}
 \newcommand{\verts}[1]{\left\vert\,{#1}\,\right\vert}$

With $\ds{\theta > 0}$ and $\ds{B > 0}$,
  $\ds{\int_{0}^{\infty}x^{p}
\exp\pars{-\,{\theta \over x} \color{#f00}{\large -} Bx}\,\dd x =\, ?}$.



Write $\ds{x \equiv \root{\theta \over B}\expo{t}}$ such that

\begin{align}
&\color{#f00}{\int_{0}^{\infty}x^{p} \exp\pars{-\,{\theta \over x} - Bx}\,\dd x}
=
\int_{-\infty}^{\infty}\pars{\root{\theta \over B}\expo{t}}^{p}
\exp\pars{-\root{\theta B}\bracks{\expo{-t} + \expo{t}}}\root{\theta \over B}
\expo{t}\,\dd t
\\[3mm] = &\
\pars{\theta \over B}^{\pars{p + 1}/2}\int_{-\infty}^{\infty}
\expo{\pars{p + 1}t}\exp\pars{-2\root{\theta B}\cosh\pars{t}}\,\dd t
\\[3mm] = &\
\pars{\theta \over B}^{\pars{p + 1}/2}\int_{-\infty}^{\infty}
\braces{\vphantom{\Large A}\cosh\pars{\vphantom{\large A}\bracks{p + 1}t} + \sinh\pars{\vphantom{\large A}\bracks{p + 1}t}}
\exp\pars{-2\root{\theta B}\cosh\pars{t}}\,\dd t
\\[3mm] = &\
2\pars{\theta \over B}^{\pars{p + 1}/2}\int_{0}^{\infty}
\cosh\pars{\bracks{p + 1}t}\exp\pars{-2\root{\theta B}\cosh\pars{t}}\,\dd t
\\[3mm] = &\
\color{#f00}{2\pars{\theta \over B}^{\pars{p + 1}/2}\,
\mathrm{K}_{p + 1}\pars{2\root{\theta B}}}
\end{align}

$\ds{\mathrm{K}_{\nu}\pars{z}}$ is the 
Modified Bessel Function of the Second Kind.
