"We listen to it daily. At noon we listen to it. We listen to it before going to sleep. Then we pray. Then we sleep."—a Kanwasa villager speaking about the solar MegaVoice audio Bible.
Gifts to last year's Wycliffe gift catalog helped provide audio Bible players for people in Papua New Guinea, bringing the Scriptures in their language to life.
In many language groups living in Papua New Guinea, information of value is shared orally, and literacy is growing slowly. In the highlands, thirty-nine New Testaments have been published in the local languages but are not accessible to the people.
Now six of these New Testaments have been recorded and placed on flash drives as well as small solar-powered audio Bible players. Translated Scripture in numerous other languages has been checked, and recordings have been made of as much as half of the New Testament.
One Kamano speaker in Papua New Guinea reported how much his children love listening to Bible verses with the audio Bible player. Public school principals in that language group are asking for these solar Bibles to give to their teachers to play for class language study and devotion times. Local pastors are also using the units during their sermons instead of reading from the trade language and translating orally.
Many families listen to the players during their evening meal, and keep listening to God's Word until the batteries go dead for or five hours later. Children are asking if they can "recharge the batteries by putting the players close to the fire" so they can finish listening to one of the Bible stories.
Providing these players makes translated Scripture accessible to thousands of people in the highlands of Papua New Guinea. Translation has bridged the language barrier, and Scripture in this format is bringing God's Word to the ears and hearts of the people.
Note: We are thankful for ministry partners like Wycliffe for their amazing work among unreached people groups (UPGs). Because of Wycliffe's Bible translation work, countless millions are encountering Jesus Christ for the first time.


This will be the third year of our prayerful journey upstream to walk, ride, run, and paddle as we continue the work to BRING OUR SALMON HOME!
We just got back from Aotearoa (New Zealand) from releasing our salmon fingerlings into the streams there and we are excited to return to Aotearoa this summer to work on collecting DNA samples from the Chinook returning home to spawn and move forward with our historical restoration project!
We are all in this together. The journey continues until our salmon are restored and our sacred sites are protected!
Save the date today and JOIN US!


All offsite activities will be offered at 50% of the total actual cost for your children and these need to be paid for prior to your child attending the activity. . However if it is to be a substantial amount we can take it on a week by week basis as long as it is paid on the Friday prior to the week of activities. We reserve the right to cancel an event if not sufficient numbers and your child may not be guaranteed a place if the spaces fill up quickly.
Please read the form and any additional information and then tick the box of the sessions your child will be attending. Please check that the activities are relevant for the age of your child before booking. You will then need to sign the medical and photographic consent form and return to one of the 3 centres. If you have any questions or queries please contact 01429881521 and ask for Donna, Annette or Terri. Alternatively if you attend TGCC or TVH you may want to contact Pamela or Victoria first.
I hope your child enjoys what we have on offer and we look forward to your feedback.


I received an email from the bump and saw this "What are Brixton Hicks contractions"? I just read something about it at What to Expect application from Hubs's IP. So, I went to reading about it abit further.. This is what The Expert from the Bump said.. Re: What are Braxton Hicks contractions? When could they start, and what do they feel like?
pic credit: Google I hope it is not too late for me to wish everyone who has kindly visited my blog, "Selamat Menyambut Bulan Ramadhan dan Selamat Berpuasa" Today is our second day of fasting in Brunei and I know, in Malaysia it is your third day. Mudah-mudahan ibadah puasa kita akan diterima oleh Allah SWT jua. Aminnnn! I must say, being pregnant during this fasting is quite a challenge. Unfortunately I didn't managed to fulfilled my puasa yesterday. Baby was kicking me throughout the afternoon. Belum biasa puasa maybe. Hehe.. But Alhamdulillah, today Baby has been behaving well. Less kicking. Mudah-mudahan Allah SWT akan sentiasa melindungi Baby, Aminnn! p/s: bought 3 items for Baby already Thank you so much Bff!


Parents are their child's first teacher, and teachers are only as good as the learning materials that they have access to, and the training and support they receive. In many parts of the world, parents don't have the funds to purchase learning materials. What if school districts provided learning materials and children's books to the parents of children under the age of five? Some of the materials can be loaned out, but some materials such as workbooks might require the student to have their own copy, which they will be allowed to keep.
This would ensure that students receive a foundational education before they enter kindergarten. Well, provided that the school district provides parents with a professional development series that gives them tips on how to use the materials. Nothing too fancy, just 5 to 10 professional development sessions, sprinkled throughout the year and taught by expert teachers or professors.
This may seem like a huge burden to place on a U.S. education system that in some states, is not fully funded. But I promise it will save taxpayers millions of dollars. How? Remember, there are a lot of children that don't attend a structured preschool program, and so their parents or family members are responsible for their educations. In some instances, these students enter kindergarten as blank slates, without an understanding of what a number or letter is, or the ability to follow directions.
So, helping parents and caregivers provide foundational skills to their children would save the U.S. education system billions of dollars. Why? Because students who lack school readiness usually end up repeating kindergarten, which means the school district must pay for an additional year of kindergarten and the cost of performing expensive interventions. School districts can prevent this, by providing parents with some learning materials and professional development sessions. Talk about a sound investment.


All private hire vehicles must be licensed unless exempt by legislation.
"any motor vehicle adapted to carry less than nine passengers and which is provided for hire with the services of a driver to carry passengers, but which is not already licensed as a Hackney Carriage (taxi) or as a public service vehicle (bus or coach)".
The only exemption from this legislation is where the transport is provided solely in connection with a wedding or a funeral (section 75).
If you have any questions please contact us on 01202 262202.
If you need assistance to complete the application forms, please contact us and we will be happy to help you.
The licence fee is £153 per year.


Large Chicken Coop that can easily be moved around your yard... Large access gate to access run and also easy access to the roosting area through drop down doors and also back lid opens to get your eggs. We paid over $1100 3 Mon. asking $850 or best offer. We are located in Arlington IN.... West of Rushville and South of Knighstown... No delivery available.


text:
Q: Call a method from a file and parse the file I am doing something wrong.It should open the file using a constructor and will call a method read_names_from_files() that will parse the above file that counts each word. As an example in idle, I ran this program:
>>> import fish
>>> a = fish.Fishes("filename.txt")
>>> freqs = a.read_names_from_files()
>>> freqs
>>> {}

But it did not show the parsing content from dictionary.
class Fishes:
def __init__(self, fn):
    self.file1 = open(fn, 'r')
    self.freqs=self.read_names_from_files()

def read_names_from_files(self):
    freqs = {}
    for line in self.file1:
        for word in line.split():
            if word in freqs:
                freqs[word] += 1
            else:
                freqs[word] = 1
    return freqs

A: This seems to work. Sorry, your code had too many errors for me to discuss each one or to even figure out which one was the primary cause your problem.
class Fishes:
    def __init__(self, fn):
        self.file1 = open(fn, 'r')

    def read_names_from_files(self):
        freqs = {}
        for line in self.file1:
            for word in line.split():
                if word in freqs:
                    freqs[word] += 1
                else:
                    freqs[word] = 1
        return freqs

if __name__ == '__main__':
    import fish  # assume this file is named "fish.py"
    a = fish.Fishes("fish.py")  # read it as test data
    freqs = a.read_names_from_files()
    assert freqs['for'] == 2  # raise exception if untrue

redpajama_set_name: RedPajamaStackExchange


text:
\section{Introduction} \label{section_introduction}

In this paper, we revisit the study of risk processes where a  company is bailed out by capital injections.  In the classical setting, capital injections can be made at all times and instantaneously; the resulting process becomes the classical reflected process that stays at or above zero uniformly in time. In reality, however, this may not be  observable continuously, and it is necessary to consider the time taken to execute this process.  Motivated by recent research on Poisson observations and Parisian ruin found in (among others) \cite{albrecher2015strikingly,AIZ,BPPR,LRZ}, we consider the scenario where bail-outs can only be made at independent Poisson times.

We consider  a general spectrally negative L\'{e}vy  process as the underlying process.  Additionally, we are
 given \emph{Poisson observation times}, or an increasing sequence of jump times of an independent Poisson process.   At each Poisson observation time when the process is below zero, the process is pushed up to zero: we call this \emph{Parisian reflection}.
Related processes with underlying compound Poisson processes have been studied in \cite{albrecher2011randomized}  and
\cite{avanzi2013periodic}. In the former study, a number of  identities were obtained when solvency is only observed periodically, whereas the latter study analyzes a  case where observation intervals are Erlang-distributed.

In this paper, we are also interested in the case of a dividend-paying company that pays dividends according to a barrier strategy.
With regard to this, we consider a version of the (doubly) reflected process, where, given a spectrally negative L\'{e}vy  process reflected from above, it is pushed up to zero at Poisson observation times at which the process is below zero.

Our objective is to obtain, using fluctuation/excursion theories, concise expressions of several identities of  the following
\begin{enumerate}
\item[(1)] the spectrally negative L\'{e}vy  process with Parisian reflection below, and
\item[(2)] its variant with additional classical reflection above.
\end{enumerate}
In particular, we are interested in the following:
\begin{description}
\item[(absolute ruin)]  We define \emph{absolute ruin} to be the event that the process goes below a specified level $a < 0$.  The absolute ruin probability and its time can be used to evaluate the risk of the company just like the classical ruin, which is the event that the process goes below $0$.
\item[(capital injections)]  Capital injections correspond to Parisian reflection below. We compute their total discounted values for both (1) and (2) for the infinite horizon case as well as for the cases that are killed upon exiting $[a,b]$, $[a, \infty)$ and $(-\infty, b]$ for $a < 0 < b$.
\item[(dividends)]  If dividends are assumed to be paid continuously, then they are modeled by the
 classical reflection above in process (2).  We compute their total expected discounted values  for the infinite horizon case and for the case that is killed upon exiting $[a, \infty)$ for $a < 0$.
 \end{description}

We use the scale function to compute these fluctuation identities.
 It is well known, as in \cite{K}, that the scale function existing for every spectrally one-sided L\'{e}vy  process can be applied to obtain various fluctuation identities of the process and its reflected/refracted processes.

The main difficulty with the spectrally negative L\'{e}vy  process is handling the possible overshoot at its down-crossing time: it is  typically necessary to express the identities in terms of the convolution of the L\'{e}vy  measure and the resolvent measure via the scale function.  Recent results show, however, that these can be concisely written under some conditions.  In this paper, for process (1), we use the simplifying formula obtained in \cite{LRZ}. Together with this, the desired identities for the \emph{bounded variation case} can be obtained using a well-known technique via the strong Markov property; see, e.g., \cite{AIZ}.

For the \emph{unbounded variation case}, we shall use excursion theory instead of using the commonly used approximation methods as in \cite{AIZ}.  In doing so, we first obtain an excursion-measure version of the simplifying formula in \cite{LRZ} (see Theorem \ref{lemma_key_excursion}). Using this and excursion theory, we can obtain identities directly without relying on the approximation scheme.  Our approach follows from the recent characterization of the excursion measure away from $0$, as obtained in \cite{PPR2}.

For  process (2), we derive an analogue of the simplifying formula in \cite{LRZ} for the spectrally negative L\'{e}vy  process reflected from above (see Theorem \ref{lemma_simplifying_reflected}). With this and the results for (1), similar fluctuation identities can be obtained when process (1) is replaced with (2).

The rest of the paper is organized as follows.  Section \ref{section_model} introduces (1) the spectrally negative L\'{e}vy  process with Parisian reflection below and (2) its version with additional classical reflection above.
The scale functions and their applications are also reviewed.
Section \ref{section_main} presents the main results for both processes (1) and (2) and their corollaries.  Sections \ref{section_bounded} and \ref{section_unbounded}  give the proofs of the main results related to process (1) for the bounded and unbounded variation cases, respectively.   Finally, Section \ref{section_proof_reflected} gives those of the theorems related to (2).  Some proofs of the  corollaries are provided in the appendix.

\section{L\'{e}vy  processes with Parisian reflection below} \label{section_model}

Let $X = (X(t); t \geq 0)$ denote a spectrally negative L\'{e}vy  process defined on a probability space $(\Omega, \mathcal{F}, \mathbb{P})$.
For $x\in \R$, we denote by $\mathbb{P}_x$ the law of $X$ when it starts at $x$ and write for convenience  $\mathbb{P}$ in place of $\mathbb{P}_0$. Accordingly, we shall write $\mathbb{E}_x$ and $\mathbb{E}$ for the associated expectation operators.  We assume that its
Laplace exponent $\kappa} \def\no{\nonumber}  \def\t{\tau} \def\kil{\mathbf{e}: [0, \infty) \to \R$ is given by
\begin{align}
 \E (e^{\th X(t)})=e^{ t \kappa} \def\no{\nonumber}  \def\t{\tau} \def\kil{\mathbf{e}(\th)}, \quad t \geq 0, \; \theta \geq 0, \label{def_Laplace_exp}
 \end{align}
with its L\'evy-Khintchine decomposition
 $$ \kappa} \def\no{\nonumber}  \def\t{\tau} \def\kil{\mathbf{e}(\th) = \frac{\s^2}{2}\th^2 + \gamma \th + \int_{(-\infty, 0)}[e^{\th y} - 1 - \th 1_{\{y > -1\}} ]\Pi({\rm d} y), \quad \theta \geq 0.$$
Here, $\s \geq 0,$ $\gamma \in \R$, and the L\'{e}vy  measure satisfies $ \int_{(-\infty, 0)} (1\wedge y^2) \Pi({\rm d} y) < \infty} \def\d{q} \def\s{\sigma} \def\r{\rho$. Let $\mathbb{F} = (\mathcal{F}(t); t \geq 0)$ be the filtration generated by $X$.

It is well known that $X$ has paths of bounded variation if and only if $\sigma=0$ and $\int_{(-1, 0)} |y|\Pi(\mathrm{d}y) < \infty$. In this case $X$ can be written as
\begin{equation}
X(t)=ct-S(t), \,\,\qquad t\geq 0,\notag
\end{equation}
where
\begin{align*}
c:=\gamma-\int_{(-1,0)} y\Pi(\mathrm{d}y)
\end{align*}
 and $(S(t); t\geq0)$ is a driftless subordinator. We exclude the case $X$ is the negative of a subordinator, and hence necessarily $c>0$. Its Laplace exponent is given by
\begin{equation*}
\kappa(\theta) = c \theta+\int_{(-\infty,0)}\big( {\rm e}^{\theta y}-1\big)\Pi(\ud y), \quad \theta \geq 0.
\end{equation*}

\subsection{L\'{e}vy  processes with Parisian reflection below} \label{subsection_process_defined}

Let $\mathcal{T}_\p=\{T(i); i \in \mathbb{N}\}$ be an increasing sequence of epochs of a Poisson process with rate $\p >0$, independent of $X$.   We construct the \emph{L\'{e}vy  process with Parisian reflection below} $X_r = (X_r(t); t \geq 0)$ as follows: the process is only observed at times $\mathcal{T}_\p$ and is pushed up to $0$ if and only if it is below $0$.

More precisely, we have
\begin{align} \label{X_X_r_the_same}
X_r(t) = X(t), \quad 0 \leq t < T_0^-(1)
\end{align}
 where
\begin{align} T_{0}^-(1) := \inf\{  S \in \mathcal{T}_r :  X(S-) < 0 \}; \label{def_T_0_1}
 \end{align}
 here and throughout, let $\inf \varnothing = \infty$.
 The process is then pushed upward by $|X(T_0^-(1))|$ so that $X_r(T_0^-(1)) = 0$. For $T_0^-(1) \leq t < T_0^-(2)  := \inf\{ S \in \mathcal{T}_r : S > T_0^-(1), X_r(S-) < 0\}$, we have $X_r(t) = X(t) + |X(T_0^-(1))|$.  The process can be constructed by repeating this procedure.

Suppose $R_r(t)$ is the cumulative amount of (Parisian) reflection until time $t \geq 0$. Then we have
\begin{align*}
X_r(t) = X(t) + R_r(t), \quad t \geq 0,
\end{align*}
 with
\begin{align}
	R_r(t) := \sum_{i=1}^\infty 1_{\{ T_0^-(i) \leq t\}} |X_r(T_0^-(i) -)|, \quad t \geq 0, \label{def_L_r}
\end{align}
where $(T_{0}^-(n); n \geq 1)$ can be constructed inductively by \eqref{def_T_0_1} and
\begin{eqnarray*} T_{0}^-(n+1) := \inf\{ S \in \mathcal{T}_r : S > T_0^-(n), X_r(S-) < 0 \}, \quad n \geq 1.
 \end{eqnarray*}
The process $Y_r^b$ with additional (classical) reflection above can be defined analogously.  Fix $b > 0$.  Let
 \begin{align*}
 Y^b(t) := X(t) - L^b(t) \quad \textrm{where } L^b(t) := \sup_{0 \leq s \leq t} (X(s) - b) \vee 0, \quad t \geq 0,
 \end{align*}
 be the process reflected from above at $b$.  We have
 \begin{align}
 Y^b_r(t) = Y^b(t), \quad 0 \leq t < \widehat{T}_0^{-} (1) \label{Y_matches}
 \end{align}
  where $\widehat{T}_{0}^-(1) := \inf\{ S \in \mathcal{T}_r : Y^b(S-) < 0 \}$.
The process then jumps upward by $|Y^b(\widehat{T}_0^-(1))|$ so that $Y^b_r(\widehat{T}_0^-(1)) = 0$. For $\widehat{T}_0^-(1) \leq t < \widehat{T}_0^-(2)  := \inf\{S \in \mathcal{T}_r : S > \widehat{T}_0^-(1), Y_r^b(S-) < 0 \}$, $Y_r^b(t)$ is the reflected process of $X(t) - X(\widehat{T}_0^-(1))$.
The process can be constructed by repeating this procedure.
It is clear that it admits a decomposition
\begin{align*}
Y^b_r(t) = X(t) + R_r^b (t) - L_r^b(t), \quad t \geq 0,
\end{align*}
where $R_r^b(t)$ and $L_r^b(t)$ are, respectively, the cumulative amounts of Parisian and classical reflection until time $t$.

For the sake of completeness, we provide below a formal construction of the processes $Y^b_r$, $R_r^b$, and $L_r^b$.
\begin{center}
\line(1,0){300}
\end{center}
 \textbf{Construction of the process $Y^b_r$, $R_r^b$, and $L_r^b$ under $\mathbb{P}_x$}
\begin{description}
\item[Step 0:] Set $n = 0$, $\widehat{T}_0^- (0) = 0$, $R_r^b (0-) = L_r^b(0-) = 0$,  and $\tilde{x} = x$ and go to \textbf{Step 1}.
\item[Step 1:] Let $\{ \widetilde{Y}^b(t); t \geq \widehat{T}_0^- (n) \}$ be the reflected L\'{e}vy  process with the barrier level $b$ that starts at the time $\widehat{T}_0^- (n)$ at the level $\tilde{x}$, given by
\begin{align*}
\widetilde{Y}^b(t) = \widetilde{X}(t) - \widetilde{L}^b(t)
\end{align*}
where $\widetilde{X}(t) := X(t) - X(\widehat{T}_0^- (n))$ and $\widetilde{L}^b(t) := \sup_{\widehat{T}_0^- (n) \leq s \leq t} (\widetilde{X}(s) - b) \vee 0$.
\begin{description}
\item[Step 1-0:]   Set $\widehat{T}_0^- (n+1) := \inf\{S \in \mathcal{T}_r : S > \widehat{T}_0^-(n), \widetilde{Y}^b(t)  < 0 \} $.
\item[Step 1-1:]  For $t \in (\widehat{T}_0^- (n), \widehat{T}_0^- (n+1))$,  set $R_r^b (t) = R_r^b (\widehat{T}_0^- (n))$.  Also, set $R_r^b (\widehat{T}_0^- (n+1)) = R_r^b (\widehat{T}_0^- (n)) + |\widetilde{Y}^b(\widehat{T}_0^- (n+1))|$.
\item[Step 1-2:]  For $t \in (\widehat{T}_0^- (n), \widehat{T}_0^- (n+1)]$,  set $L_r^b (t) = L_r^b (\widehat{T}_0^- (n)) + \widetilde{L}^b (t) $.
\item[Step 1-3:]  For $t \in [\widehat{T}_0^- (n), \widehat{T}_0^- (n+1))$,  set $Y^b_r(t) = X(t) + R_r^b (t) - L_r^b(t)$.
\end{description}
Increment the value of $n$, set $\tilde{x} = 0$ and go back to the beginning of \textbf{Step 1}.
\end{description}
\begin{center}
\line(1,0){300}
\end{center}

\subsection{Scale functions}
Fix $q \geq 0$. Let $W_q$ be the scale function of $X$.  Namely,  this is a mapping from $\R$ to $[0, \infty)$ that takes the value zero on the negative half-line, while on the positive half-line it is a strictly increasing function that is defined by its Laplace transform:
\begin{align} \label{scale_function_laplace}
\begin{split}
\int_0^\infty  \mathrm{e}^{-\theta x} W_q(x) {\rm d} x &= \frac 1 {\kappa(\theta)-q}, \quad \theta > \Phi_q, \\
\end{split}
\end{align}
where
\begin{align}
\begin{split}
\Phi_q := \sup \{ \lambda \geq 0: \kappa(\lambda) = q\}. \notag \end{split}
\end{align}
In particular, when $q=0$, we shall drop the superscript.
We also define, for $x \in \R$,
\begin{align*}
\overline{W}_q(x) &:=  \int_0^x W_q(y) {\rm d} y, \\
Z_q(x) &:= 1 + q \overline{W}_q(x),  \\
\overline{Z}_q(x) &:= \int_0^x Z_q (z) {\rm d} z = x + q \int_0^x \int_0^z W_q (w) {\rm d} w {\rm d} z.
\end{align*}
Noting that $W_q(x) = 0$ for $-\infty < x < 0$, we have
\begin{align*}
\overline{W}_q(x) = 0, \quad Z_q(x) = 1,  \quad \textrm{and} \quad \overline{Z}_q(x) = x, \quad x \leq 0.
\end{align*}

Let \begin{align*}
\tau_a^- := \inf \left\{ t > 0: X(t) < a \right\} \quad \textrm{and} \quad \tau_a^+ := \inf \left\{ t > 0: X(t) >  a \right\}, \quad a \in \R.
\end{align*}
Then, for any $b > a$ and $x \leq b$,
\begin{align}
\begin{split}
\E_x \left( e^{-q \tau_b^+}; \tau_b^+ < \tau_a^- \right) &= \frac {W_q(x-a)}  {W_q(b-a)}, \\
 \E_x \left( e^{-q \tau_a^-}; \tau_b^+ > \tau_a^- \right) &= Z_q(x-a) -  Z_q(b-a) \frac {W_q(x-a)}  {W_q(b-a)}.
\end{split}
 \label{laplace_in_terms_of_z}
\end{align}
In addition, as in Theorem 8.7 of \cite{K}, the \emph{$q$-resolvent measure} is known to have a density written as
\begin{align} \label{resolvent_density}
\E_x \Big( \int_0^{\tau_{a}^- \wedge \tau^+_b} e^{-qt} 1_{\left\{ X(t) \in {\rm d} y \right\}} {\rm d} t\Big) &= \Big[ \frac {W_q(x-a) W_q (b-y)} {W_q(b-a)} -W_q (x-y) \Big] {\rm d} y,  \quad x \leq b.
\end{align}

It is known that a spectrally negative L\'{e}vy  process creeps downwards (i.e.\ $\mathbb{P}_x ( X(\tau_a^-)= a, \tau_a^- < \infty ) > 0$ for $x > a$) if and only if $\sigma > 0$ (see Exercise 7.6 of \cite{K}).
On the other hand, it is known that  for any $a \leq x\leq  b$ and a positive measurable function $l$ (with a slight abuse of notation noting that $W_q$ is differentiable on $(0, \infty)$ when $\sigma > 0$ as in Remark \ref{remark_smoothness_zero} below),
\begin{align} \label{undershoot_expectation}
\E_x\Big(e^{-q\tau_a^-}l(X(\tau_a^-))&; \tau_a^-<\tau_b^+ \Big)=l(a)\frac{\sigma^2}{2}\left[W_q'(x-a)-W_q(x-a)\frac{W_q'(b-a)}{W_q(b-a)}\right]\\
&+\int_0^{b-a}\int_{(-\infty,-y)} l(y+u+a)\left\{\frac{W_q(x-a) W_q(b-a-y)}{ W_q(b-a)}-W_q(x-a-y)\right\}\Pi(\ud u)\ud y;\notag
\end{align}
see for instance the identity (4) in \cite{LRZ}.

By taking $a \downarrow -\infty$ and $b \uparrow \infty$ in \eqref{resolvent_density}, we obtain that $U_{q}({\rm d} y):=\int^{\infty}_{0}e^{-qt}\mathbb{P}(X(t)\in {\rm d} y) {\rm d} t $, $y\in \mathbb{R}$,
 is absolutely continuous with respect to the Lebesgue measure, and its density is given by
 \begin{equation}
 u_{\q}(y)=\kappa'(\Phi_q)^{-1}e^{-\Phi_{\q}y}-W_{\q}(-y),\qquad y\in \mathbb{R}; \label{u_q_resolvent}
 \end{equation}

 see for instance Corollary 8.9 in \cite{K} and Exercise 2 in Chapter VII in \cite{B}.

 \begin{remark} \label{remark_smoothness_zero}
\begin{enumerate}
\item If $X$ is of unbounded variation or the L\'{e}vy  measure is atomless, it is known that $W_q$ is $C^1(\R \backslash \{0\})$; see, e.g.,\ \cite[Theorem 3]{Chan2011}.
\item Regarding the asymptotic behavior near zero, as in Lemmas 3.1 and 3.2 of \cite{KKR},
\begin{align}\label{eq:Wqp0}
\begin{split}
W_q (0) &= \left\{ \begin{array}{ll} 0 & \textrm{if $X$ is of unbounded
variation,} \\ \frac 1 {c} & \textrm{if $X$ is of bounded variation,}
\end{array} \right. \\
W_q^{\prime} (0+) &:= \lim_{x \downarrow 0}W_q^{\prime} (x) =
\left\{ \begin{array}{ll}  \frac 2 {\sigma^2} & \textrm{if }\sigma > 0, \\
\infty & \textrm{if }\sigma = 0 \; \textrm{and} \; \Pi(-\infty,0) = \infty, \\
\frac {q + \Pi(-\infty, 0)} {c^2} &  \textrm{if }\sigma = 0 \; \textrm{and} \; \Pi(-\infty, 0) < \infty.
\end{array} \right.
\end{split}
\end{align}
On the other hand, as in Lemma 3.3 of \cite{KKR},
\begin{align}
\begin{split}
e^{-\Phi_q x}W_q (x) \nearrow \kappa'(\Phi_q)^{-1}, \quad \textrm{as } x \uparrow \infty,
\end{split}
\label{W_q_limit}
\end{align}
where in the case $\kappa'(0+) = 0$, the right hand side, when $q=0$,  is understood to be infinity.
\item As in (8.22) and Lemma 8.2 of \cite{K}, $ {W_q^{\prime}(y+)} / {W_q(y)} \leq  {W_q^{\prime}(x+)} / {W_q(x)}$ for  $y > x > 0$.
In all cases, $W_q^{\prime}(x-) \geq W_q^{\prime}(x+)$ for all $x >0$.
\end{enumerate}
\end{remark}

Along this work we also define, for $\theta\geq 0$, $\alpha\geq0$, and $x \in \R$,
\begin{align}
Z_{\alpha}(x, \theta) &:=e^{\theta x} \left( 1 + (\alpha- \kappa} \def\no{\nonumber}  \def\t{\tau} \def\kil{\mathbf{e}(\theta)) \int_0^{x} e^{-\theta z} W_{\alpha}(z) {\rm d} z	\right) \la{Zs}, \\
Z_{\alpha,\beta}(x,\th ) &:
\frac} \def\th{\theta} \def\p{r}  \def\q{q} \def\la{\label{\beta}{\alpha+\beta-\kappa} \def\no{\nonumber}  \def\t{\tau} \def\kil{\mathbf{e}(\th)} Z_{\alpha}(x,\th)
+\frac} \def\th{\theta} \def\p{r}  \def\q{q} \def\la{\label{\alpha-\kappa} \def\no{\nonumber}  \def\t{\tau} \def\kil{\mathbf{e}(\th)}{\alpha+\beta-\kappa} \def\no{\nonumber}  \def\t{\tau} \def\kil{\mathbf{e}(\th)} Z_{\alpha}(x,\Phi_{\alpha+\beta} ), \quad \beta \geq - \alpha
\la{Z2}
\end{align}
where the case $\th=\Phi_{\alpha+\beta}$ in \eqref{Z2} should be interpreted in the limiting sense as $\theta \rightarrow \Phi_{\alpha+\beta}$.

In particular,
\begin{align} \label{Z_special}
\begin{split}
Z_{\alpha}(x, 0) &=Z_{\alpha}(x), \\
Z_{\alpha}(x, \Phi_{\alpha+\beta}) &=e^{\Phi_{\alpha+\beta} x} \left( 1 -\beta \int_0^{x} e^{-\Phi_{\alpha+\beta} z} W_{\alpha}(z) {\rm d} z \right) = \beta \int_0^\infty e^{-\Phi_{\alpha+\beta} z} W_\alpha(z+x) {\rm d} z, \\
Z_{\alpha,\beta}(x) &:=Z_{\alpha,\beta}(x,0) =\frac} \def\th{\theta} \def\p{r}  \def\q{q} \def\la{\label{\beta}{\alpha+\beta} Z_{\alpha}(x)
+\frac} \def\th{\theta} \def\p{r}  \def\q{q} \def\la{\label{\alpha}{\alpha+\beta} Z_{\alpha}(x,\Phi_{\alpha+\beta} ).
\end{split}
\end{align}
Define also, for all $x \in \R$ and $a \leq 0$,
\begin{align} \label{W_a_def}
\begin{split}
W^a_{\alpha,\beta}(x) &:=W_{\alpha+\beta}(x-a)- \beta\int_{0}^{x}  W_{\alpha}(x-y)W_{\alpha+\beta}(y-a){\rm d} y =W_{\alpha}(x-a)+\beta\int_0^{-a}W_{\alpha}(x-u-a)W_{\alpha+\beta}(u) {\rm d} u, \\
Z_{\alpha,\beta}^a(x) &:= Z_{\alpha+\beta}(x-a)- \beta \int_0^x W_{\alpha}(x-y)  Z_{\alpha+\beta}(y-a)  {\rm d} y
=Z_{\alpha}(x-a)+\beta\int_0^{-a}W_{\alpha}(x-u-a)Z_{\alpha+\beta}(u) {\rm d} u, \\
\overline{Z}_{\alpha,\beta}^a(x) &:= \overline{Z}_{\alpha+\beta}(x-a)- \beta \int_0^x W_{\alpha}(x-y)  \overline{Z}_{\alpha+\beta}(y-a)  {\rm d} y =\overline{Z}_{\alpha}(x-a)+\beta\int_0^{-a}W_{\alpha}(x-u-a)\overline{Z}_{\alpha+\beta}(u){\rm d} u,
\end{split}
\end{align}
where the second equalities hold by (5) of \cite{LRZ} and (3.4) of \cite{YP}, and in particular
\begin{align}\label{rel_Z_0}
W^0_{\alpha,\beta}(x)=W_{\alpha}(x), \quad Z^0_{\alpha,\beta}(x)=Z_{\alpha}(x), \quad \textrm{and} \quad \overline{Z}^0_{\alpha,\beta}(x)=\overline{Z}_{\alpha}(x).
\end{align}
These functions are related by the following: by  \eqref{W_q_limit} and  \eqref{Z_special}, for $x \in \R$ and $a < 0$, respectively,
	\begin{align}\label{nl}
	\lim_{a\downarrow -\infty} \frac{W_{\alpha,\beta}^a(x)}{W_{\alpha+\beta}(-a)}

	= Z_{\alpha}(x,\Phi_{\alpha+\beta}) 	\quad
\textrm{and} \quad \lim_{x\uparrow \infty}\frac{W_{\alpha,\beta}^a(x)}{W_{\alpha}(x)}

	=Z_{\alpha+\beta}(-a,\Phi_{\alpha}).
	\end{align}

\section{Main results} \label{section_main}

In this section, we summarize the main results related to the processes $X_r$ and $Y_r^b$ as defined in Section \ref{subsection_process_defined}.
The proofs of Theorems \ref{theorem_laplace} and  \ref{expected_bailouts} are given in Section \ref{section_bounded} for the case $X$ is of bounded variation and in Section \ref{section_unbounded} for the case of unbounded variation.  The proofs of Theorems  \ref{theorem_R_b_r} and  \ref{theorem_L_b_r} are given in Section \ref{section_proof_reflected}.  Those for corollaries are given in Appendix \ref{appendix_proofs}.

Throughout, let us fix $r > 0$ and define \begin{align}
\tau_a^-(r) := \inf \left\{ t > 0: X_r(t) < a \right\} \quad \textrm{and} \quad \tau_a^+(r) := \inf \left\{ t > 0: X_r(t) >  a \right\}, \quad a \in \R. \label{def_tau_a_plus_minus}
\end{align}
In particular, the former for $a < 0$ can be understood as the ``absolute ruin" as discussed in Section \ref{section_introduction}.

\subsection{Identities for the process $X_r$} \label{subsection_joint_Laplace}

We shall first obtain the joint Laplace transform (with killing) of the stopping times \eqref{def_tau_a_plus_minus} and the value of capital injections as in \eqref{def_L_r}.

\begin{theorem[Joint Laplace transform with killing]  \label{theorem_laplace}
For all $q, \theta \geq 0$, $a< 0<b$, and $x \leq b$,
\begin{align}  \la{Parisbailouts}
g(x,a,b,\theta)&:=\E_x\left( e^{-q\tau_b^+ (r) - \theta R_r(\tau_b^+ (r))}; \t_b^+(r)< \tau_a^-(r)\right)=\frac{\mathcal{H}^a_{q,r}(x,\theta)}{\mathcal{H}^a_{q,r}(b,\theta)}, \\
h(x,a,b,\theta)&:=\E_x\left(e^{-q\tau_a^-(r) -\theta R_r(\tau_a^- (r) )}; \tau_a^-(r) < \t_b^+(r)\right)=\mathcal{I}_{\q,\p}^a(x)-
\frac{\mathcal{H}^a_{q,r}
(x,\theta)}{\mathcal{H}^a_{q,r}(b,\theta)} \mathcal{I}_{\q,\p}^a(b), \la{Parisbailouts_2}
\end{align}
where, for $y \in \R$,
\begin{align} \label{def_H_I}
\begin{split}
\mathcal{H}^a_{q,r}(y,\theta)&:=\p\int_{0}^{-a} e^{-\theta u}\Big[W^a_{\q,\p}(y)\frac{W_{\q+\p} (u)} {W_{\q+\p}(-a)}-W^{-u}_{\q,\p}(y)\Big]{\rm d} u+\frac{W^a_{\q,\p}(y)}{W_{\q+\p}(-a)}, \\
\mathcal{I}_{\q,\p}^a(y)&:=Z^a_{\q,\p}(y)-W^a_{\q,\p}(y)\frac{Z_{\q+\p}(-a)}{W_{\q+\p}(-a)}.
\end{split}
\end{align}
In particular, by  \eqref{Z_special} and \eqref{W_a_def}, simple computation gives
\begin{align*}
\mathcal{H}^a_{q,r}(y,0)
&= (q+r)^{-1} \Big( \frac {W^a_{\q,\p}(y)} {W_{\q+\p}(-a)} \big[ r Z_{q+r}(-a) + q \big] + r \big[ Z_{q}(y) - Z_{q,r}^a (y) \big] \Big) \\ &= (q+r)^{-1} \Big(- r \mathcal{I}^a_{q,r} (y) + q \frac {W^a_{\q,\p}(y)} {W_{\q+\p}(-a)} + r Z_q(y)\Big).
\end{align*}

\end{theorem}

\begin{remark}  In Theorem \ref{theorem_laplace}, by taking $a \uparrow 0$, we recover \eqref{laplace_in_terms_of_z}: for $\theta \geq 0$, $b > 0$, and $0 \leq x \leq b$,
\begin{align*}
\lim_{a\uparrow 0}g(x,a,b,\th)&=W_q(x)/W_q(b) = \E_x \big(e^{-q \tau_b^+}; \tau_b^+ < \tau_0^- \big), \\
\lim_{a\uparrow 0}h(x,a,b,\th)&=Z_q(x)- {Z_q(b)} \frac {W_q(x)} {W_q(b)} = \E_x \big(e^{-q \tau_0^-}; \tau_b^+ >  \tau_0^- \big).
\end{align*}
Indeed, the former is immediate by the convergence
\begin{align}
\lim_{a\uparrow 0}\mathcal{H}^a_{q,r}(x,\theta)W_{q+r}(-a)=\lim_{a\uparrow 0}W_{q,r}^a(x)=W_q(x). \label{limit_fraction_W_H}
\end{align}
The latter holds by \eqref{limit_fraction_W_H} and because
\begin{align*}
W_{q+r}(-a) &\big[ \mathcal{I}_{\q,\p}^a(x)\mathcal{H}^a_{q,r}(b,\theta) -\mathcal{I}_{\q,\p}^a(b)\mathcal{H}^a_{q,r}(x,\theta)\big] \\
&= W_{q+r}(-a) \big[ Z_{q,r}^a(x)\mathcal{H}^a_{q,r}(b,\theta) -Z_{q,r}^a(b)\mathcal{H}^a_{q,r}(x,\theta)\big] \\
				&+ Z_{q+r} (-a) r \Big( W^a_{\q,\p}(x) \int_0^{-a}e^{-\th u}W_{q,r}^{-u}(b) {\rm d} u -W^a_{\q,\p}(b) \int_0^{-a}e^{-\th u}W_{q,r}^{-u}(x){\rm d} u \Big) \\ &\xrightarrow{a \uparrow 0} Z_q(x)W_q(b)- Z_q(b)W_q(x).
\end{align*}
\end{remark}
By taking $b \uparrow \infty$ and $a \downarrow  - \infty$ in  Theorem \ref{theorem_laplace}, we have the following.
\begin{corollary} \label{corollary_laplace_tau_a_b_infty}
Fix $q, \theta \geq 0$.

(i) Suppose $q > 0$. For $a <  0$ and $x \in \R$,
	\begin{align*}

	\E_x\left( e^{-q\tau_a^-(r)-\theta R_r(\tau_a^-(r))};\tau_a^-(r)<\infty\right) =\mathcal{I}_{\q,\p}^a(x)-
	\mathcal{J}_{\q,\p}(-a)\frac{\mathcal{H}^a_{q,r}
		(x,\theta)}{\mathcal{G}_{q,r}(-a,\theta)},
	\end{align*}

where, for $y \in \R$,
	\begin{align*}
	\mathcal{G}_{q,r}(y,\theta)&:=\p\int_{0}^{y} e^{-\theta u}\Big[Z_{q+r}(y,\Phi_q)\frac{W_{\q+\p} (u)} {W_{\q+\p}(y)}-Z_{q+r}(u,\Phi_q)\Big]{\rm d} u+\frac{Z_{\q+\p}(y,\Phi_q)}{W_{\q+\p}(y)}, \\
	\mathcal{J}_{\q,\p}(y)&:=\frac{q}{\Phi_q}Z_{q+r,-r}(y)-Z_{q+r}(y,\Phi_q)\frac{Z_{q+r}(y)}{W_{q+r}(y)}.
	\end{align*}

	Here, in particular, using the fact that $Z'_{q+r}(x, \Phi_q) = \Phi_q Z_{q+r}(x, \Phi_q) + r W_{q+r}(x)$,

		\begin{align*}
	\mathcal{G}_{q,r}(y,0) = (q+r)^{-1} \Big[ \frac {Z_{q+r}(y,\Phi_q)} {W_{\q+\p}(y)} \big(r Z_{q+r}(y) + q \big) - \frac {rq} {\Phi_q} \big( Z_{q+r,-r} (y) - 1\big) \Big].
	\end{align*}

For the case $q = 0$, it holds with
	\begin{align*}
	\mathcal{J}_{0,\p}(y)&:= \left\{ \begin{array}{ll}r\Phi_0^{-1}[Z_r(y,\Phi_0)-Z_r(y)]-Z_{r}(y,\Phi_0)\frac{Z_{r}(y)}{W_{r}(y)} & \Phi_0 > 0, \\ r \overline{Z}_r(y)+{\kappa} \def\no{\nonumber}  \def\t{\tau} \def\kil{\mathbf{e}'(0+)} -\frac {Z_{r}(y)^2} {W_{\p}(y)} & \Phi_0 = 0,
	\end{array} \right. \\
	\mathcal{G}_{0,r}(y,0) &:= \left\{  \begin{array}{ll}
	\frac {Z_{r}(y,\Phi_0)} {W_{\p}(y)}  Z_{r}(y)  - r\Phi_0^{-1}[Z_r(y,\Phi_0)-Z_r(y)] & \Phi_0 > 0, \\
	\frac {Z_{r}(y)^2} {W_{\p}(y)}  - r\overline{Z}_r(y) & \Phi_0 = 0. \\
	\end{array} \right.
	\end{align*}

	(ii) For $b > 0$ and $x \leq b$,
\begin{align*}
\E_x\left(e^{-q\tau_b^+(r)-\theta R_r(\tau_b^+(r))} ; \tau_b^+(r) < \infty\right)=
\frac{Z_{\q,\p}(x,\th)}{Z_{\q,\p}(b,\th)}.
\end{align*}

(iii) For $b > 0$ and $x \leq b$,
		\begin{align*}

		\E_x \big(e^{- \q \tau_b^+(r)} ;\tau_b^+(r)<T ^-_0(1) \big) =\frac{Z_q(x,\Phi_{\q+\p})}{Z_q(b,\Phi_{\q+\p})},
		\end{align*}
		which matches the result in \cite{AIrisk} for the case $q = 0$.

\end{corollary}

\begin{remark}  (i) By Corollary \ref{corollary_laplace_tau_a_b_infty} (i), for $a < 0$, we have
	\begin{align*}
	\mathbb{P}_x\left( \tau_a^-(r)<\infty\right) =\mathcal{I}_{0,\p}^a(x)-
	\mathcal{J}_{0,\p}(-a)\frac{\mathcal{H}^a_{0,r}
		(x,0)}{\mathcal{G}_{0,r}(-a,0)} =\mathcal{I}_{0,\p}^a(x)-
	\mathcal{J}_{0,\p}(-a)\frac{1 - \mathcal{I}_{0,\p}^a(x)}{\mathcal{G}_{0,r}(-a,0)}.
	\end{align*}

(a) When $\Phi_0 > 0$ (or $X$ drifts to $-\infty$), then $\mathbb{P}_x\left( \tau_a^-(r)<\infty\right) = 1$.

(b) When $\Phi_0 = 0$, we have $\mathcal{J}_{0,\p}(y) = -\mathcal{G}_{0,r}(y,0) + \kappa'(0+)$. Therefore,
		\begin{align*}
	\mathbb{P}_x\left( \tau_a^-(r)<\infty\right)=\mathcal{I}_{0,\p}^a(x)+
	[\mathcal{G}_{0,r}(-a,0) - \kappa'(0+)] \frac{1 - \mathcal{I}_{0,\p}^a(x)}{\mathcal{G}_{0,r}(-a,0)} = 1 - \kappa'(0+) \frac{1 - \mathcal{I}_{0,\p}^a(x)}{\mathcal{G}_{0,r}(-a,0)}.
	\end{align*}

(ii) By Corollary \ref{corollary_laplace_tau_a_b_infty} (ii), for $b > 0$, we have $\mathbb{P}_x\left( \tau_b^+(r) < \infty\right)=
{Z_{0,\p}(x)} / {Z_{0,\p}(b)} = 1$.
\end{remark}

\subsection{Total discounted bailouts} \label{section_bailout}

We now state our results on the total discounted bailouts.  The first result is for the case killed upon exiting $[a,b]$.

\begin{theorem}[Total discounted capital injections with killing]\label{expected_bailouts}

For  $a < 0 < b$, $q \geq 0$, and $x \leq b$,

\begin{align*}
f(x,a,b) := \E_x\left( \int_0^{\t_b^{+}(r)\wedge\t_a^-(r)}e^{-qt}{\rm d} R_{\p}(t)\right) =  \frac{\mathcal{H}_{\q,\p}^{a}(x, 0)}{\mathcal{H}_{\q,\p}^{a}(b, 0)}h_{\q,\p}^{a}(b) -h_{\q,\p}^{a}(x),
 \end{align*}

 where, for $y \in \R$,

\begin{align} \label{small_h_def}
\begin{split}
 	h_{\q,\p}^{a}(y) &:=\frac r {q+r}\left(\overline{Z}_q(y)+\frac{aZ_{\q+\p}(-a)+\overline{Z}_{\q+\p}(-a)}{W_{\q+\p}(-a)}W_{\q,\p}^a(y)-aZ_{\q,\p}^a(y)-\overline{Z}_{\q,\p}^a(y)\right) \\
 	&= \frac r {q+r}\left(\overline{Z}_q(y)+\frac{\overline{Z}_{\q+\p}(-a)}{W_{\q+\p}(-a)}W_{\q,\p}^a(y)-\overline{Z}_{\q,\p}^a(y) - a \mathcal{I}_{\q,\p}^a(y)\right).

	\end{split}
 \end{align}

\end{theorem}

By taking $b \uparrow \infty$ and $a \downarrow -\infty$ in Theorem \ref{expected_bailouts}, we have the following.

\begin{corollary} \label{corollary_L_b}

(i)  Fix $a < 0$.  We have, for $x \in \R$, and either $q>0$ or $q = 0$ and $\Phi_0 > 0$,
\begin{align}\label{ParBail_a_b_infty}
\E_x&\left( \int_0^{\t_a^- (r)}e^{-qt}{\rm d} R_{\p}(t)\right) = \frac{\mathcal{H}_{\q,\p}^{a}(x, 0)}{\mathcal{G}_{\q,\p}(-a, 0)}h_{\q,\p}(-a) -h_{\q,\p}^{a}(x)
\end{align}
where, for $y \in \R$,
\begin{align*}
h_{\q,\p}(y)&:= \left\{ \begin{array}{ll}\displaystyle\frac r {q+r} \Bigg(\frac{q}{\Phi_q^2}+\frac{-yZ_{\q+\p}(y)+\overline{Z}_{\q+\p}(y)}{W_{\q+\p}(y)}Z_{q+r}(y,\Phi_q)+(y\Phi_q-1)\frac{q}{\Phi^2_q}Z_{\q+r,-\p}(y)&+\frac{r}{\Phi_q}\overline{Z}_{\q+\p}(y) \Bigg)\quad  q > 0, \\ \displaystyle\frac{-yZ_{r}(y)+\overline{Z}_{r}(y)}{W_{r}(y)}Z_{r}(y,\Phi_0)+  \frac {y\Phi_0-1} {\Phi_0^2} r [Z_r(y, \Phi_0) - Z_r(y)]+\frac{r}{\Phi_0}\overline{Z}_{r}(y) & \text{$q=0$ and $\Phi_0 > 0$}.
\end{array} \right.
\end{align*}
(ii)  Fix $b > 0$ and suppose $\kappa'(0+) > -\infty$.  We have, for $x \leq b$ and $q\geq0$,
\begin{align}\label{ParBail}
\E_x&\left( \int_0^{\t_b^+ (r)}e^{-qt}{\rm d} R_{\p}(t)\right)=  \frac {Z_{\q,\p}( x)}  {Z_{\q,\p}( b)} k_{q,r}(b) - k_{q,r}(x)  ,
\end{align}
where, for $y \in \R$,
\begin{align*}
k_{\q,\p}(y):=\frac{r}{q+r}\left(\overline{Z}_q(y)-\kappa'(0+)\overline{W}_{\q}(y)- \frac{\kappa'(0+)}{\q+\p} \big[Z_{\q}(y,\Phi_{\q+\p})-Z_{\q}(y) \big]\right).
\end{align*}
In particular, when $q>0$, \eqref{ParBail} can be simplified by replacing  $k_{q,r}$ with

\begin{align*} \tilde{h}_{q,r}(y)&:=\frac r {q+r} \Big(\overline{Z}_q(y)+\frac{\kappa} \def\no{\nonumber}  \def\t{\tau} \def\kil{\mathbf{e}'(0+)}{\q}\Big), \quad y \in \R.
\end{align*}

(iii) Suppose $\kappa'(0+) > -\infty$. For $q>0$, we have, for $x \in \R$,
\begin{align}\label{eq:localt0}
\E_x\left} \def\ri{\right} \def\T{\tilde( \int_0^{\infty} \def\d{q} \def\s{\sigma} \def\r{\rho} e^{-q t}{\rm d} R_{\p}(t)\ri)  &=\frac{\Phi_{\q+\p}-\Phi_{\q}}{\Phi_{\q+\p}\Phi_{\q}}Z_{\q,\p}(x)- \tilde{h}_{q,r}(x).
\end{align}

\end{corollary}

\subsection{Identities for the process $Y_r^b$} \label{subsection_reflected_case}

We shall now move onto obtaining the fluctuation identities for the process $Y_r^b$ with additional classical reflection above. In addition to the similar identities obtained above for $X_r$, we shall also obtain the results related to the dividends $L_r^b$.  We shall first obtain the cases killed at the absolute ruin
	 \begin{align*}
 \eta_a^-(r) := \inf \{ t > 0: Y^b_r(t) < a \}, \quad a < 0,
 \end{align*}
 and then obtain the infinite horizon case by taking limits.  Analogously to the classical case, the results can be written concisely using the \emph{derivatives} of the functions defined above for $X_r$.

Let the (right-hand) derivative of $W^{a}_{\q,\p}(x)$ defined in \eqref{W_a_def} be
	\begin{align}
	(W^{a}_{\q,\p})'(x) &=\frac{\partial_+}{\partial_+x}\left(W_{q+r}(x-a)- r\int_{0}^{x}  W_{q}(x-y)W_{q+r}(y-a){\rm d} y\right)\notag\\
&=W_{\q+\p}'((x-a)+)- \p \Big[ \int_{0}^{x}  W_\q'(x-y)W_{\q+\p}(y-a){\rm d} y + W_q(0) W_{q+r} (x-a) \Big], \quad a < 0, \; x \neq a. \label{W_a_derivative}
	\end{align

We first obtain a version of Theorem \ref{theorem_laplace}.

\begin{theorem}[Joint Laplace transform] \label{theorem_h_hat}
	Fix $a < 0<b$, $q \geq 0$, and $\theta \geq 0$.  For all $x \leq b$,
	\begin{align}\label{ref_dual_laplace}
	\widehat{h}(x,a,b,\th):=\E_x\left(e^{-q \eta_a^-(r) -\theta R^b_r(\eta_a^-(r))}; \eta_a^-(r)< \infty\right)=\mathcal{I}^a_{q,r}(x)-\frac{\mathcal{H}^a_{q,r}(x,\th)}{\mathcal{H}^{a \prime}_{q,r}(b,\theta)}\mathcal{I}_{\q,\p}^{a \prime} (b),
	\end{align}
where $\mathcal{H}^{a \prime}_{q,r}(y,\theta)$ and $\mathcal{I}_{\q,\p}^{a \prime} (y)$ are the (right-hand) derivatives of $\mathcal{H}^{a}_{q,r}(y,\theta)$ and $\mathcal{I}_{\q,\p}^{a} (y)$ with respect to $y$ given by, for $y \neq a$,
\begin{align*}
\mathcal{H}^{a \prime}_{q,r}(y,\theta)&=\p\int_{0}^{-a} e^{-\theta u}\Big((W^{a }_{\q,\p})'(y)\frac{W_{\q+\p} (u)} {W_{\q+\p}(-a)}-(W^{-u}_{\q,\p})'(y)\Big) {\rm d} u+\frac{(W^{a }_{\q,\p})'(y)}{W_{\q+\p}(-a)}, \\
\mathcal{I}_{\q,\p}^{a \prime}(y)&=(q+r)W^a_{\q,\p}(y)-Z_{\q+\p}(-a)\left(rW_q(y)+\frac{(W^{a }_{\q,\p})'(y)}{W_{\q+\p}(-a)}\right).
\end{align*}
Here, in particular,
				\begin{align}
				\label{H_big_zero}
				\begin{split}
\mathcal{H}^{a \prime}_{q,r}(y,0
&= \frac 1 {q+r}(W^{a}_{\q,\p})'(y)\frac{r Z_{\q+\p} (-a)+q} {W_{\q+\p}(-a)} - r W^a_{q,r} (y) +\frac r {q+r} W_q(y) \Big[  r  Z_{q+r} (-a) + q \Big] \\
&= \frac 1 {q+r} \Big[ q \Big(\frac{(W^{a }_{\q,\p})'(y)}{W_{q+r}(-a)}+r W_q(y) \Big) -r\mathcal{I}^{a \prime}_{q,r}(y) \Big].
\end{split}
\end{align}

\end{theorem}

\begin{remark}  By Theorem \ref{theorem_h_hat}, for all $a < 0 < b$ and $x \leq b$,
	\begin{align*}
	\mathbb{P}_x\left( \eta_a^-(r)<\infty\right) =\mathcal{I}_{0,\p}^a(x)-
	\frac{\mathcal{H}^a_{0,r}(x,0)}{\mathcal{H}^{a \prime}_{0,r}(b,0)}\mathcal{I}_{\q,\p}^{a \prime} (b) =\mathcal{I}_{0,\p}^a(x)-
	[1 - \mathcal{I}_{0,\p}^a(x)] \frac{\mathcal{I}_{0,\p}^{a \prime} (b)}{\mathcal{H}^{a \prime}_{0,r}(b,0)} = 1.
	\end{align*}
\end{remark}

Second, we obtain the total expected discounted dividends until the absolute ruin $\eta_a^-(r)$.  As its corollary, by taking $a \downarrow -\infty$, we also obtain the infinite horizon case.

\begin{theorem}[Total discounted dividends with killing] \label{theorem_R_b_r}
For $a < 0 < b$ and $q \geq 0$, we have \begin{align*}
		\widehat{j}(x,a, b) &:= \E_x\left( \int_{0}^{\eta_a^-(r)}e^{-qt} {\rm d} L^b_r(t)\right) = \left\{ \begin{array}{ll} \mathcal{H}^a_{q,r}(x,0) / \mathcal{H}^{a \prime}_{q,r}(b,0) & x \leq b, \\ \mathcal{H}^a_{q,r}(b,0) / \mathcal{H}^{a \prime}_{q,r}(b,0) + (x-b) & x > b. \end{array} \right.
		\end{align*}
\end{theorem}

\begin{remark}
We can confirm that these expressions in Theorems \ref{theorem_h_hat} and \ref{theorem_R_b_r} converge to the expressions given in (3.10) and (3.12) of \cite{APP}: \begin{align*}
\lim_{a \uparrow 0}  \widehat{h}(x,a,b,\th) &=Z_q(x)- q \frac {W_q(b)} {W_q'(b+)} W_q(x) = \E_x\left(e^{-q \eta_0^- }\right), \\
\lim_{a \uparrow 0}\widehat{j}(x,a, b) &= \left\{ \begin{array}{ll} W_q(x) / {W_q'(b+)} & x \leq b \\ W_q(b) / {W'_q(b+)} + (x-b) & x > b \end{array} \right\} = \E_x\left( \int_{0}^{\eta_0^-}e^{-qt} {\rm d} L^b(t)\right),
		\end{align*}

		where
 \begin{align*}
 \eta_0^- := \inf \{ t > 0: Y^b(t) < 0 \}.
 \end{align*}
Indeed, the latter holds because, similarly to \eqref{limit_fraction_W_H}, $\lim_{a\uparrow 0}\mathcal{H}^{a \prime}_{q,r}(x,\theta)W_{q+r}(-a)=W_q'(x+)$.
On the other hand, some algebra gives
\begin{align*}
\mathcal{I}_{\q,\p}^a(x)\mathcal{H}^{a \prime}_{q,r}(b,\th) &-\mathcal{I}_{\q,\p}^{a \prime}(b)\mathcal{H}^a_{q,r}(x,\th)
=  Z_{q,r}^a(x)\mathcal{H}^{a\prime}_{q,r}(b,\theta) -(q+r)W_{q,r}^a(b)\mathcal{H}^a_{q,r}(x,\theta)\\
&+ r\frac{Z_{q+r} (-a)}{W_{q+r}(-a)} \Big( W^a_{\q,\p}(x) \int_0^{-a}e^{-\th u}(W_{q,r}^{-u})'(b) {\rm d} u -(W^a_{\q,\p})'(b) \int_0^{-a}e^{-\th u}W_{q,r}^{-u}(x){\rm d} u \Big)\\
&+rZ_{q+r}(-a)W_q(b)\frac{W_{q,r}^a(x)}{W_{q+r}(-a)}.
\end{align*}
Therefore,
\begin{align*}
W_{q+r}(-a)\Big(\mathcal{I}_{\q,\p}^a(x)\mathcal{H}^{a \prime}_{q,r}(b,\th) -\mathcal{I}_{\q,\p}^{a \prime}(b)\mathcal{H}^a_{q,r}(x,\th) \Big)
\xrightarrow{a \uparrow 0} W'_{\q}(b +)   Z_{q}(x) - q W_q(b)  W_{\q}(x).
\end{align*}
Hence, the former holds as well.
\end{remark}

\begin{corollary}  \label{corollary_R_b_r}
For $b > 0$ and $q > 0$,
we have
\begin{align*}
\E_x\left(\int_{0}^{\infty}e^{-qt} {\rm d} L^b_r(t)\right)= \left\{ \begin{array}{ll} Z_{q,r}(x) /Z_{q,r}'(b)  & x \leq b, \\ Z_{q,r}(b) /Z_{q,r}'(b) + (x-b) & x > b.
\end{array} \right.
\end{align*}
Here, note that $Z_{q,r}'(y)= q \Phi_{q+r} Z_q(y, \Phi_{q+r}) / (q+r) $ for $y \in \R$.
\end{corollary}

Third, as a version of Theorem \ref{expected_bailouts}, we obtain the total expected discounted capital injections until the absolute ruin $\eta_a^-(r)$.  Again, as its corollary, by taking $a \downarrow -\infty$, we also obtain the infinite horizon case.

\begin{theorem}[Total discounted capital injections with killing] \label{theorem_L_b_r}
Suppose
$q \geq 0$ and $a < 0 < b$.  We have
 \begin{align*}
\widehat{f}(x,a,b) := \E_x\left(\int_0^{\eta_a^-(r)}e^{-qt}{\rm d} R_{\p}^b(t)\right)= \left\{ \begin{array}{ll}\frac{\mathcal{H}_{\q,\p}^{a}(x, 0)}{\mathcal{H}_{\q,\p}^{a\prime}(b, 0)}h_{\q,\p}^{a \prime}(b) -h_{\q,\p}^{a}(x) & x \leq b, \\
\frac{\mathcal{H}_{\q,\p}^{a}(b, 0)}{\mathcal{H}_{\q,\p}^{a\prime}(b, 0)}h_{\q,\p}^{a \prime}(b) -h_{\q,\p}^{a}(b) & x > b, \end{array} \right.
 \end{align*}
where $h^{a \prime}_{q,r}(y)$ is the (right-hand) derivatives of $h^{a}_{q,r}(y)$ with respect to $y$ given by, for $y\neq a$,
\begin{multline*}
h^{a \prime}_{q,r}(y) =  \frac r {q+r} \Big[Z_q(y) + \frac{aZ_{\q+\p}(-a)+\overline{Z}_{\q+\p}(-a)}{W_{\q+\p}(-a)} (W^{a}_{\q,\p})'(y) \notag\\
-a\left[(q+r)W^{a}_{\q,\p}(y)-rW_q(y)Z_{q+r}(-a)\right]-
Z_{\q,\p}^a(y)+ rW_q(y)\overline{Z}_{q+r}(-a)\Big].
\end{multline*}
\end{theorem}

\begin{corollary} \label{corollary_L_b_r}
Suppose $\kappa'(0+) > -\infty$, $q >0$, and $b > 0$.
We have
\begin{align*}
\E_x\left( \int_{0}^{\infty}e^{-qt} {\rm d} R^b_r(t)\right) = \left\{ \begin{array}{ll}\displaystyle \frac{r}{q+r}\frac{Z_{q,r}(x)}{Z_{q,r}'(b)}Z_q(b)- \tilde{h}_{q,r}(x) & x \leq b, \\ \displaystyle \frac{r}{q+r}\frac{Z_{q,r}(b)}{Z_{q,r}'(b)}Z_q(b)-\tilde{h}_{q,r}(b)  & x > b. \end{array} \right.
\end{align*}

\end{corollary}

\section{Proofs for the bounded variation case} \label{section_bounded}

In this section, we show Theorems \ref{theorem_laplace} and  \ref{expected_bailouts} for the case $X$ is of bounded variation. The proofs are direct applications of Lemma 2.1 of \cite{LRZ}.  We shall first review their results and use them to compute the expected values \eqref{def_big_U} defined below, in terms of the scale functions given in \eqref{W_a_def}. These together with an application of the strong Markov property complete the proofs.  For the proofs of their corollaries (both for bounded and unbounded variation cases), see Appendix \ref{appendix_proofs_regular}.

\subsection{Auxiliary results}

Fix $q \geq 0$. Let $\mathbf{e}_{\p}$ be the exponential random variable with parameter $r$ independent of $X$.
Define, for $a < 0$ and $x \leq 0$,
\begin{align*}
u_1(x, a, \theta) &:= \E_{x}
\left(e^{-q\mathbf{e}_{\p}+\theta X(\mathbf{e}_{\p})};
\mathbf{e}_{\p}<\tau_0^+\wedge\tau_a^-\right),  \quad \theta \geq 0, \\
u_2(x, a) &:= \E_{x} \left(e^{-q\tau_0^+};
\tau_0^+ < \mathbf{e}_{\p}\wedge\tau_a^-\right), \\
u_3(x,a) &:= \E_{x}\left(e^{-q\tau_a^-};\tau_a^-<\mathbf{e}_{\p}\wedge\tau_0^+\right), \\
u_4 (x, a) &:= \E_{x}
\left(e^{-q\mathbf{e}_{\p}}X(\mathbf{e}_{\p});
\mathbf{e}_{\p}<\tau_0^+\wedge\tau_a^-\right).
\end{align*}
Also, define for  $a < 0$ and $x \in \R$,
	\begin{align}
	\tilde{u}_1(x,a,\theta):=r \int_{0}^{-a} e^{-\theta u }\Big[ \frac {W_{\q+\p}(x-a) W_{\q+\p} (u)} {W_{\q+\p}(-a)} -W_{\q+\p} (x+u) \Big] {\rm d} u, \label{u_1_tilde}
	\end{align}
where in particular
\begin{align}
\tilde{u}_1(x, a, 0)
&=r \frac {W_{q+r}(x-a)} {W_{q+r}(-a)} \overline{W}_{q+r} (-a) - \frac r {q+r} [Z_{q+r}(x-a) - Z_{q+r}(x)],\label{u_1_tilde_zero}
\end{align}
and
\begin{align*}
\tilde{u}_2(x, a) &:= \frac{W_{q+\p}(x-a)}{W_{q+\p}(-a)}, \\
\tilde{u}_3(x,a) &:= Z_{\q+\p}(x-a)-W_{\q+\p}(x-a)\frac{Z_{\q+\p}(-a)}{W_{\q+\p}(-a)}.
\end{align*}
In particular, $\tilde{u}_1(x, a, \theta) = \tilde{u}_2(x,a) = 0$ and $\tilde{u}_3(x,a) = 1$ for  $x < a$.

We show below that $u_i$ and $\tilde{u}_i$ match for $x \leq 0$.

\begin{lemma} \label{lemma_u}
For $q \geq 0$, $a < 0$ and $x \leq 0$,
 we have $u_1(x, a, \theta) = \tilde{u}_1(x, a, \theta)$ for $\theta \geq 0$,
and $u_i(x, a) = \tilde{u}_i(x, a)$ for $i = 2,3$.

\end{lemma}
\begin{proof}
(i) By \eqref{resolvent_density},
\begin{align*}
u_1(x, a, \theta) &= r \E_{x-a}\left(\int_0^{\tau_0^-\wedge\tau_{-a}^+}e^{-(q+\p)s+\theta (X(s)+a)}{\rm d} s\right)\\
&=r \int_{0}^{-a} e^{\theta(y+a)}\Big[ \frac {W_{\q+\p}(x-a) W_{\q+\p} (-a-y)} {W_{\q+\p}(-a)} -W_{\q+\p} (x-a-y) \Big] {\rm d} y  = \tilde{u}_1(x,a, \theta).
\end{align*}
By setting $\th=0$ in the above expression we can easily obtain \eqref{u_1_tilde_zero}.

(ii), (iii)  For $i = 2,3$, the results are clear by following \eqref{laplace_in_terms_of_z} and noticing that $u_2(x,a) =\E_{x}
(e^{-(q+\p)\tau_0^+};\tau_a^->\tau_0^+)$ and $u_3(x,a) =\E_{x} (e^{-(q+\p)\tau_a^-};\tau_a^-<\tau_0^+)$.

\end{proof}

As in \cite{LRZ}, for any $p \geq 0$,  let $\mathcal{V}_0^{(p)}$ be the set of measurable functions $v_{p}: \R \to [0, \infty)$ satisfying
\begin{align*}
\E_x \big(e^{-p\tau_0^-} v_{p} (X(\tau_0^-)); \tau_0^- < \tau_b^+ \big) = v_{p} (x) - \frac {W_{p}(x)} {W_{p}(b)} v_{p} (b), \quad x \leq b.
\end{align*}
We shall further define $\tilde{\mathcal{V}}_0^{(p)}$ to be the set of positive measurable functions $v_{p}(x)$ that satisfy conditions (i) or (ii) in Lemma 2.1 of \cite{LRZ}, which state as follows:
\begin{enumerate}
\item[(i)] For the case $X$ is of bounded variation,  $v_p \in \mathcal{V}_0^{(p)}$ and there exists large enough $\lambda$ such that $\int_0^\infty e^{- \lambda z} v_p (z) {\rm d} z < \infty$.
\item[(ii)] For the case $X$ is of unbounded variation, there exist a sequence of functions $v_{p,n}$ that converge to $v_p$ uniformly on compact sets, where $v_{p,n}$ belongs to the class $\tilde{\mathcal{V}}_0^{(p)}$ for the process $X^n$; here $(X^n; n \geq 1)$ is a sequence of spectrally negative L\'{e}vy  processes of bounded variation that converge to $X$ almost surely uniformly on compact time intervals (which can be chosen as in, for example, page 210 of \cite{B}).
\end{enumerate}
Lemma 2.1 of \cite{LRZ} shows that, for all $p, q \geq 0$, $v_{p} \in \tilde{\mathcal{V}}_0^{(p)}$ and $x \leq b$,
\begin{multline} \label{LRZ_identity}
\E_x \big(e^{-q \tau_0^-} v_{p} (X(\tau_0^-)); \tau_0^- < \tau_b^+ \big) \\= v_{p} (x) - (p-q) \int_0^x W_{q} (x-y) v_{p}(y) {\rm d} y - \frac {W_{q}(x)} {W_{q}(b)} \Big( v_{p}(b) - (p-q) \int_0^b W_{q}(b-y) v_{p} (y) {\rm d} y\Big).
\end{multline}

Fix any $a < 0$.  By Lemma 2.2 of \cite{LRZ} and spatial homogeneity,
\begin{align}
(y \mapsto W_{q+r}(y-a)) \in \tilde{\mathcal{V}}_0^{({q+r})} \quad \textrm{and} \quad (y \mapsto Z_{q+r}(y-a)) \in \tilde{\mathcal{V}}_0^{({q+r})}. \label{W_Z_in_V}
\end{align}

\begin{lemma} \label{lemma_u_in_V}    For any $q \geq 0$ and $a < 0$, we have
	$(y \mapsto \tilde{u}_1(y, a, \theta)) \in \tilde{\mathcal{V}}_0^{({q+r})}$ for $\theta \geq 0$, and $(y \mapsto \tilde{u}_i(y, a)) \in \tilde{\mathcal{V}}_0^{({q+r})}$ for $i=2,3$.
\end{lemma}
\begin{proof}
 Recall as in  \cite{LRZ} that $\tilde{\mathcal{V}}_0^{({q+r})}$ is a linear space.

Hence using \eqref{u_1_tilde} and the fact that $(y \mapsto W_{\q+\p} (y+u)) \in \tilde{\mathcal{V}}_0^{({q+r})}$ for all $u > 0$,
 we have $(y \mapsto \tilde{u}_1(y, a, \theta)) \in \tilde{\mathcal{V}}_0^{({q+r})}$.

The proofs for $\tilde{u}_i(\cdot, a)$ for $i=2,3$ hold because these are linear combinations of \eqref{W_Z_in_V}.

\end{proof}

Using these identities, we shall now compute, for $a < 0 < b$ and $x \leq b$,
\begin{align} \label{def_big_U}
\begin{split}
U_1(x, a,b,\theta) &:= \E_x\Big(e^{-q\tau_0^-} u_1 (X(\tau_0^-), a, \theta);\tau_0^-<\t_b^+\Big), \quad \theta \geq 0, \\
U_i(x, a,b) &:= \E_x\Big(e^{-q\tau_0^-} u_i (X(\tau_0^-), a );\tau_0^-<\t_b^+\Big), \quad i = 2,3, 4.
\end{split}
\end{align}
For $a < 0$ and $x \in \R$, we define
\begin{align} \label{U_0_summary}
\begin{split}
U_1^0(a,x, \theta)&:=- \p\int_{0}^{-a} e^{-\theta u}\Big[ \frac {W_{\q,\p}^a(x) W_{\q+\p} (u)} {W_{\q+\p}(-a)} -W_{\q,\p}^{-u} (x) \Big]{\rm d} u, \quad \theta \geq 0, \\
U_2^0(a,x) &:= - W_{q,r}^a (x) / W_{q+r}(-a), \\
U_3^0(a,x) &:= - \mathcal{I}_{q,r}^a (x) , \\
U_4^0(a,x) &:= - h^{a}_{q,r}(x),
\end{split}
\end{align}
where $\mathcal{I}_{q,r}^a$ and $h^{a}_{q,r}$ are defined in \eqref{def_H_I} and  \eqref{small_h_def}, respectively.
In particular,
\begin{align} \label{U_0_summary_2}
\begin{split}
U_1^0(a, x, 0) &=- \frac{\p}{\q+\p}\Big( Z_{\q}(x)
- Z_{\q,\p}^a(x) +\frac{ (q+r) \overline{W}_{\q+\p}(-a)}{W_{\q+\p}(-a)}W_{\q,\p}^a(x)\Big).
\end{split}
\end{align}
Note that
\begin{align}
U_1^0(a,x, \theta) + U_2^0(a,x) = -\mathcal{H}_{q,r}^a(x, \theta), \quad x \in \R, \quad \theta \geq 0, \label{U_1_U_2_sum}
\end{align}
and
\begin{align}
U_1^0(a,0, \theta)  = U_3^0(a,0)  = U_4^0(a,0)  = 0 \quad \textrm{and} \quad U_2^0(a,0) = -1. \label{U_zero_value}
\end{align}

Here, we have the following results.

\begin{corollary} \label{corollary_big_U}
For $q \geq 0$, $a < 0 < b$, and $x \leq b$,
\begin{align*}
U_1(x, a,b,\theta) &=   \frac{W_q(x)}{W_q(b)}U_1^0(a,b,\theta) - U_1^0(a,x,\theta), \quad \theta \geq 0, \\
U_i(x, a,b) &=  \frac{W_q(x)}{W_q(b)}U_i^0(a,b) - U_i^0(a,x), \quad i = 2,3, 4.
\end{align*}

\end{corollary}
\begin{proof}
The case in which $i=1,2,3$ is a direct consequence of Lemma \ref{lemma_u_in_V} and \eqref{LRZ_identity}, and hence we omit the proof.
For the remaining case, it is clear that $U_4(x, a,b) = \lim_{\theta \downarrow 0} (\partial U_1(x, a,b, \theta) / \partial \theta)$.  We have
\begin{align*}
\lim_{\theta \downarrow 0} \frac \partial {\partial \theta}U_1^0(a,x, \theta)&= \p\int_{0}^{-a} u \Big[ \frac {W_{\q,\p}^a(x) W_{\q+\p} (u)} {W_{\q+\p}(-a)} -W_{\q,\p}^{-u} (x) \Big]{\rm d} u.
\end{align*}
Here integration by parts gives
\begin{align*}
\int_{0}^{-a} u W_{\q+\p} (u+x) {\rm d} u
= (q+r)^{-1} \Big( -aZ_{q+r} (x-a) - \overline{Z}_{q+r}(x-a) + \overline{Z}_{q+r} (x)\Big),
\end{align*}
and
\begin{align*}
\int_{0}^{-a} u W_{\q,\p}^{-u} (x) {\rm d} u = \int_{0}^{-a} u \Big( W_{q+r}(x+u)- r\int_{0}^{x}  W_{q}(x-y)W_{q+r}(y+u){\rm d} y \Big) {\rm d} u
\end{align*}
where another integration by parts and Fubini's theorem give
\begin{align*}
&\int_{0}^{-a} u \int_{0}^{x}  W_{q}(x-y)W_{q+r}(y+u){\rm d} y {\rm d} u \\
  &=  -a \int_0^x W_q (x-y) \overline{W}_{q+r} (y-a) {\rm d} y
 - \int_0^x W_q(x-y)  \int_0^{-a} \overline{W}_{q+r} (y+u) {\rm d} u {\rm d} y \\
 &=  (q+r)^{-1} \Big[-a \int_0^x W_q (x-y) Z_{q+r} (y-a) {\rm d} y
 - \int_0^x W_q(x-y)  \Big( \overline{Z}_{q+r}(y-a) - \overline{Z}_{q+r} (y) \Big) {\rm d} y \Big].
\end{align*}
Hence, substituting these and using \eqref{rel_Z_0}, we obtain,
\begin{align}\label{new_iden_u4}
\lim_{\theta \downarrow 0} \frac \partial {\partial \theta}U_1^0(a,x, \theta) = - h^a_{q,r} (x)=U_4^0(a,x).
\end{align}
Therefore, putting the pieces together we get the result.
\end{proof}

\subsection{Proofs of Theorem \ref{theorem_laplace} for the bounded variation case}
\subsubsection{Proof of \eqref{Parisbailouts}}
For all $a < 0 <  b$ and $x \leq b$,  by \eqref{X_X_r_the_same} and the strong Markov property
together with Corollary \ref{corollary_big_U} and \eqref{U_1_U_2_sum},
		\begin{align}\label{sdep_1}
		g(x,a, b,\theta) &=  \E_x\left(e^{-q\tau_b^+}; \tau_0^- > \tau_b^+ \right)\notag \\
		&+\E_x\Big[ e^{-q\tau_0^-}\E_{X(\tau_0^-)}
		\left(e^{-q\mathbf{e}_{\p}+\theta X(\mathbf{e}_{\p})};
		\mathbf{e}_{\p}<\tau_0^+\wedge\tau_a^-\right);\tau_0^-<\t_b^+\Big] g(0,a, b,\theta)\notag\\
		&+\E_x\Big[e^{-q\tau_0^-}\E_{X(\tau_0^-)}
		\left(e^{-q\tau_0^+}; \tau_0^+ <
		\mathbf{e}_{\p}\wedge\tau_a^- \right);\tau_0^-<\t_b^+\Big] g(0,a, b,\theta)\notag\\
		&=	\frac{W_q(x)}{W_q(b)} +[ U_1(x, a, b, \theta) + U_2(x,a,b) ] g(0,a, b,\theta) \notag\\
		&=\frac{W_q(x)}{W_q(b)} \Big( 1 - \mathcal{H}_{q,r}^a(b, \theta) g(0,a,b,\theta) \Big) +\mathcal{H}_{q,r}^a(x, \theta) g(0,a, b,\theta).
		\end{align}
Now setting $x=0$ and solving for $g(0,a, b, \theta)$ (using \eqref{U_zero_value}), we get
\begin{align}
g(0,a, b,\theta)=\mathcal{H}_{q,r}^a(b, \theta)^{-1}. \label{g_zero}
\end{align}
Substituting this in (\ref{sdep_1}) we have the result

\subsubsection{Proof of \eqref{Parisbailouts_2}}
Similarly, for all $a < 0 <  b$ and $x \leq b$,
\begin{align}\label{Exit_prob_a_new1}
h(x,a, b,\theta)&=\E_x\left[ e^{-q\tau_0^-}\E_{X(\tau_0^{-})}\left(e^{-q\tau_a^-};\tau_a^-<\mathbf{e}_{\p}\wedge\tau_0^+\right);\tau_0^-<\tau_b^+\right] \notag\\
&+\E_x\left[ e^{-q\tau_0^-}\E_{X(\tau_0^{-})}\left(e^{-q\mathbf{e}_{\p}+\theta X(\mathbf{e}_{\p})};\mathbf{e}_{\p}<\tau_0^+\wedge\tau_a^-\right);\tau_0^-<\tau_b^+\right] h(0,a, b,\theta)\notag\\
&+\E_x\left[ e^{-q\tau_0^-}\E_{X(\tau_0^{-})}\left(e^{-q\tau_0^+};\tau_0^+<\mathbf{e}_{\p}\wedge\tau_a^-\right);\tau_0^-<\tau_b^+\right] h(0,a, b,\theta)\notag\\
&=U_3 (x, a,b)+ [U_1(x, a,b, \theta) + U_2 (x, a,b)]  h(0,a, b,\theta)\notag \\
&=-\frac{W_q(x)}{W_q(b)} \Big( \mathcal{I}_{q,r}^a(b) + \mathcal{H}_{q,r}^a(b, \theta) h(0,a,b,\theta) \Big) + \mathcal{I}_{q,r}^a(x) +\mathcal{H}_{q,r}^a(x, \theta) h(0,a, b,\theta).
\end{align}
Now setting $x=0$ and solving for $h(0,a,b, \theta)$ (using \eqref{U_zero_value}), we get
\begin{align}
h(0,a, b,\theta)=-\mathcal{I}_{\q,\p}^a(b)/\mathcal{H}_{q,r}^a(b, \theta). \label{h_zero}
\end{align}
Substituting \eqref{h_zero} in (\ref{Exit_prob_a_new1}), we obtain the result

\subsection{Proof of Theorem \ref{expected_bailouts} for the bounded variation case}
By \eqref{X_X_r_the_same}, the strong Markov property, Corollary \ref{corollary_big_U}, and \eqref{U_1_U_2_sum},
\begin{align}\label{MPa}
f(x,a,b)&=-\E_x\left[ e^{-q\tau_0^-}
\E_{X(\tau_0^-)}
\left(e^{-q\mathbf{e}_{\p}}X(\mathbf{e}_{\p});
\mathbf{e}_{\p}<\tau_0^+\wedge\tau_a^-\right);
\tau_0^-<\t_b^+\right]\notag\\
&+\E_x\left[e^{-q\tau_0^-}\E_{X(\tau_0^-)} \left(e^{-q\tau_0^+
};\tau_0^+<\mathbf{e}_{\p}\wedge\tau_a^-\right);\tau_0^-<\t_b^+\right]f(0,a,b)\notag\\
&+\E_x\left[e^{-q\tau_0^-}\E_{X(\tau_0^-)}\left(e^{-q\mathbf{e}_{\p}
};\mathbf{e}_{\p}<\tau_0^+\wedge\tau_a^-\right);\tau_0^-<\t_b^+\right]f(0,a,b)\notag\\
&=- U_4 (x, a,b)
+ [U_1(x, a, b, 0) +U_2(x, a,b)] f(0,a,b) \notag \\
&=\frac{W_q(x)}{W_q(b)} \Big( h^{a}_{q,r}(b) - \mathcal{H}_{q,r}^a(b, 0) f(0,a,b) \Big) -h^{a}_{q,r}(x)+\mathcal{H}_{q,r}^a(x, 0) f(0,a, b).
\end{align}
Now setting $x=0$ and solving for $f(0,a,b)$ (using \eqref{U_zero_value}), we get $f(0,a, b)=   h^{a}_{q,r}(b)  /\mathcal{H}_{q,r}^a(b, 0)$.
Substituting this in (\ref{MPa}), we obtain the result

\section{Proofs for the unbounded variation case} \label{section_unbounded}

This section shows Theorems \ref{theorem_laplace} and  \ref{expected_bailouts} for the case $X$ is of unbounded variation. The proof is via excursion theory, and in particular we use the recent results obtained in \cite{PPR2}.  Toward this end, we shall first obtain a key formula (Theorem \ref{lemma_key_excursion}), which is an analogue of Lemma 2.1 in \cite{LRZ} (as discussed and used in the last section) under the excursion measure. Using this and well-known results in excursion theory, we derive the same expressions as in the bounded variation case.  We refer the reader to \cite{PPR2} for detailed introduction and definitions regarding excursions away from zero for the case of spectrally negative L\'{e}vy  processes.

\subsection{Key identities}

We assume throughout this section that $X$ is of unbounded variation so that $0$ is  a regular point.  Let $\mathbf{n}$ be the excursion measure away from zero for $X$.

\begin{theorem} \label{lemma_key_excursion} Fix $p, q > 0$ and  $b > 0$.
	Consider functions $w_p, v_q: \R \rightarrow [0, \infty)$
	that satisfy the following:
	\begin{enumerate}
		\item  $w_p$ and $v_q$ belong to the classes  $\tilde{\mathcal{V}}^{(p)}_0$ and $\tilde{\mathcal{V}}^{(q)}_0$, respectively.
		\item We have
		\begin{align}
		(w_p-v_q)(0)=0 \label{v_diff_zero}
		\end{align}
		 and the following limits are well defined and finite:
		\begin{align}
		\lim_{x \downarrow 0} \frac {(w_p-v_q)(x)} {W_q(x)}, \quad \lim_{x \uparrow 0} \frac {(w_p-v_q)(x)} {|x|}. \label{derivative_exist_left_right}
		\end{align}
		\item There exist bounded, $\mathcal{F}_{\tau_b^+ \wedge\tau_0^-}$-measurable functionals $F$ and $G$ such that
		\[w_p(x)=\E_x(F) \qquad\text{and}\qquad v_q(x)=\E_x(G), \quad x < 0.
		\]
	\end{enumerate}
	Then we have
	\begin{align}\label{LRZ_exc}
	\mathbf{n}\left(e^{-q\tau_0^-}(w_p-v_q)(X(\tau_0^-));\tau_0^-<\tau_b^+\right)
	&=\lim_{x\downarrow 0}\frac{(w_p-v_q)(x)}{W_q(x)}+\frac{\sigma^2}{2}\lim_{x\uparrow 0}\frac{(w_p-v_q)(x)}{|x|}\notag\\
	&-\frac{1}{W_q(b)}\left((w_p-v_q)(b)-(p-q)\int_0^bW_q(b-y) w_p(y) {\rm d} y\right).
	\end{align}

\end{theorem}
\begin{proof}
First, we decompose
	\begin{align*}
	\mathcal{N} :=\mathbf{n}&\left(e^{-q\tau_0^-}(w_p-v_q)(X(\tau_0^-));\tau_0^-<\tau_b^+\right)= \mathcal{N}_1 + \mathcal{N}_2,
	\end{align*}
	where
	\begin{align*}
	\mathcal{N}_1&:=\mathbf{n}\left(e^{-q\tau_0^-}(w_p-v_q)(X(\tau_0^-));\tau_0^-<\tau_b^+,\tau_0^->0\right), \\
	\mathcal{N}_2 &:= \mathbf{n}\left(e^{-q\tau_0^-}(w_p-v_q)(X(\tau_0^-));\tau_0^-<\tau_b^+,\tau_0^-=0\right).
	\end{align*}
	Now since under $\mathbf{n}$,  the jumps of $X$  constitute a Poisson point process (see  for instance Section 4 in \cite{PPR2}), an application of the Master's formula under $\mathbf{n}$ (see  for instance identity (14) in \cite{PPR2}) and Lemma 1 in \cite{PPR1} allow us to deduce,
	with $\zeta$ being the length of the excursion from the point it leaves $0$,
	\begin{align*}
	\mathcal{N}_1 &=\mathbf{n}\left(\sum_{0<s<\zeta}e^{-qs}1_{\{X(s-)>0, \,  \sup_{u\leq s}X(u)<b\}} (w_p-v_q)(X(s-)+\Delta X(s))\right)\\
	&=\mathbf{n}\left(\int_0^{\infty}\int_{(-\infty, 0)}e^{-qs}1_{\{X(s-)>0, \,  \sup_{u\leq s}X(u)<b\}} (w_p-v_q)(X(s-)+\theta)\Pi({\rm d} \theta){\rm d} s\right)\\
	&=\int_0^b\frac{W_q(b-y)}{W_q(b)}\int_{(-\infty, -y)} (w_p-v_q)(y+\theta)\Pi({\rm d} \theta){\rm d} y.
	\end{align*}

To see why this is finite, by our assumptions  \eqref{v_diff_zero} and \eqref{derivative_exist_left_right},
there exist $K > 0$ and $\bar{y} < 0$ such that
\[
|(w_p-v_q)(y+\th) | \leq K | y+\th |, \quad  \bar{y} < y + \theta < 0.
\]
Hence, for $\varepsilon$ small enough,
\[
\int_0^{\varepsilon}\int_{(-\varepsilon,-y)} |(w_p-v_q)(y+\th) | \Pi({\rm d} \th) {\rm d} y\leq K\int_{(-\varepsilon,0)} \int_0^{-\th} | y+\th| {\rm d} y\Pi( {\rm d} \th)=\frac{K}{2}\int_{(-\varepsilon,0)}\th^2\Pi({\rm d} \th)<\infty.
\]

On the other hand, using Theorem 3 (i) in \cite{PPR2} we obtain that
	\begin{align*}
	\mathcal{N}_2=\frac{\sigma^2}{2}\left[\bar{\mathbf{n}}(F)-\bar{\mathbf{n}}(G)\right]
	\end{align*}
where $\bar{\mathbf{n}}$ is the excursion measure of the spectrally negative L\'evy process reflected at its supremum.
By using the results of \cite{CD} (see, in particular, page 6 of \cite{PPR2} for the spectrally negative case),
	\begin{align*}
	\mathcal{N}_2 &=\frac{\sigma^2}{2}\lim_{x \uparrow  0}\frac{\E_x(F)-\E_x(G)}{|x|}=\frac{\sigma^2}{2}\lim_{x\uparrow  0}\frac{(w_p-v_q)(x)}{|x|}.
	\end{align*}

	Hence, summing up these,
	\begin{align} \label{eq_N_mathcal}
	\mathcal{N} =\int_0^b\frac{W_q(b-y)}{W_q(b)}\int_{(-\infty,-y)}(w_p-v_q)(y+\th)\Pi({\rm d} \th) {\rm d} y +\frac{\sigma^2}{2}\lim_{x\uparrow 0}\frac{(w_p-v_q)(x)}{|x|}.
	\end{align}

We shall now simplify \eqref{eq_N_mathcal} using the identities by \cite{LRZ} (as reviewed in the last section).
	Using the identities \eqref{undershoot_expectation} and  \eqref{v_diff_zero}, we obtain

	\begin{align*}
	\mathcal{V}_{p,q} (x)  &:= \E_x\left(e^{-q\tau_0^-}(w_p-v_q)(X(\tau_0^-));\tau_0^-<\tau_b^+\right)\\
	&=\int_0^b\int_{(-\infty, -y)} (w_p-v_q)(y+\theta) \left(\frac{W_q(b-y)}{W_q(b)}W_q(x)-W_q(x-y)\right)\Pi({\rm d} \theta){\rm d} y, \quad 0 <  x \leq b.
	\end{align*}
	On the other hand, by \eqref{LRZ_identity} applied to $w_p \in \tilde{\mathcal{V}}^{(p)}_0$ and $v_q\in \tilde{\mathcal{V}}^{(q)}_0$,

	\begin{align*}
	\mathcal{V}_{p,q} (x)
	&=(w_p-v_q)(x)-(p-q)\int_0^x W_q(x-y)w_p(y){\rm d} y\\&-\frac{W_q(x)}{W_q(b)}\left((w_p-v_q)(b)-(p-q)\int_0^bW_q(b-y)w_p(y){\rm d} y\right).
	\end{align*}

	By matching these,
	\begin{align*}
	\int_0^{b}\int_{(-\infty, -y)}&(w_p-v_q)(y+\theta)\left(\frac{W_q(b-y)}{W_q(b)}-\frac{W_q(x-y)}{W_q(x)}\right)\Pi({\rm d} \theta){\rm d} y\\
	&=\frac{1}{W_q(x)}\left((w_p-v_q)(x)-(p-q)\int_0^x W_q(x-y)w_p(y){\rm d} y\right)\\
	&-\frac{1}{W_q(b)}\left((w_p-v_q)(b)-(p-q)\int_0^bW_q(b-y)w_p(y){\rm d} y\right).
	\end{align*}

	We shall now take $x \downarrow 0$ on both sides.
Using that $W_q(x-y)/W_q(x)$ is increasing in $x$ by Remark \ref{remark_smoothness_zero} (3), monotone convergence gives
\begin{align*}

	 \int_0^{b} \frac {W_q(x-y)} {W_q(x)}w_p(y) {\rm d} y \xrightarrow{x \downarrow 0} 0

\quad \textrm{and} \quad
	\int_0^b \frac{W_q(x-y)}{W_q(x)} \int_{(-\infty, -y)} |(w_p-v_q)(y+\theta)| \Pi({\rm d} \theta){\rm d} y \xrightarrow{x \downarrow 0} 0.
	\end{align*}
	Hence,
	\begin{multline*}
	\int_0^b\frac{W_q(b-y)}{W_q(b)} \int_{(-\infty, -y)}(w_p-v_q)(y+\theta)\Pi({\rm d} \theta){\rm d} y-\lim_{x\downarrow 0}\frac{(w_p-v_q)(x)}{W_q(x)}\\
	=-\frac{1}{W_q(b)}\left((w_p-v_q)(b)-(p-q)\int_0^bW_q(b-y)w_p(y) {\rm d} y \right).
	\end{multline*}
	Substituting this in \eqref{eq_N_mathcal}, we have the result.
\end{proof}
\begin{remark} \label{remark_key_excursion}
	In particular, when $w_p-v_q$ is differentiable at $0$, we have, by \eqref{eq:Wqp0},
	\begin{align*}
	\lim_{x\downarrow 0}\frac{(w_p-v_q)(x)}{W_q(x)}&=\frac{(w_p-v_q)'(0)}{W_q'(0+)}=\frac{\sigma^2}{2}(w_p-v_q)'(0), \\
	\lim_{x\uparrow 0}\frac{(w_p-v_q)(x)}{|x|}&= -(w_p-v_q)'(0).
	\end{align*}
	Therefore \eqref{LRZ_exc} simplifies to
	\begin{align*}
	\mathbf{n}\Big(e^{-q\tau_0^-}&(w_p-v_q)(X(\tau_0^-));\tau_0^-<\tau_b^+\Big)=-\frac{1}{W_q(b)}\left((w_p-v_q)(b)-(p-q)\int_0^bW_q(b-y)w_p(y){\rm d} y\right).
	\end{align*}
\end{remark}

Using Theorem \ref{lemma_key_excursion} (in particular Remark \ref{remark_key_excursion}), we obtain the excursion measure version of Corollary \ref{corollary_big_U}.
\begin{corollary} \label{corollary_big_U_zero}
For $q > 0$ and $a < 0 < b$,
\begin{align*}
 \mathbf{n} \Big(e^{-q\tau_0^-} u_1 (X(\tau_0^-), a, \theta);\tau_0^-<\t_b^+\Big) &= U_1^0(a,b,\theta)/W_q(b), \quad \theta \geq 0, \\
 \mathbf{n} \Big(e^{-q\tau_0^-} u_i (X(\tau_0^-), a );\tau_0^-<\t_b^+\Big) &= U_i^0(a,b)/W_q(b), \quad i = 3, 4.
\end{align*}
\end{corollary}
\begin{proof}

By Lemma \ref{lemma_u_in_V},
	$\tilde{u}_1, \tilde{u}_3 \in \tilde{\mathcal{V}}_0^{(q+r)}$. In addition, $\tilde{u}_1$ and $\tilde{u}_3$ vanish and are differentiable at $0$.  Therefore we can apply Theorem \ref{lemma_key_excursion} (with $p=q+r$ and $v_q=0$) to obtain the result for $i=1,3$.

For the remaining case, it is not difficult to check, using monotone convergence, that
\begin{align*}
 \mathbf{n} \Big(e^{-q\tau_0^-} u_4 (X(\tau_0^-), a );\tau_0^-<\t_b^+\Big) = \lim_{\theta \downarrow 0} \frac \partial {\partial \theta} \mathbf{n} \Big(e^{-q\tau_0^-} u_1 (X(\tau_0^-), a, \theta );\tau_0^-<\t_b^+\Big).
\end{align*}
Therefore, using \eqref{new_iden_u4},
\[
\mathbf{n} \Big(e^{-q\tau_0^-} u_4 (X(\tau_0^-), a );\tau_0^-<\t_b^+\Big) =\frac{1}{W_q(b)}\lim_{\theta \downarrow 0} \frac \partial {\partial \theta}U_1^0(a,b,\theta)=\frac{1}{W_q(b)}U_4^0(a,b).
\]
\end{proof}

\subsection{Auxiliary results}

In order to show Theorems \ref{theorem_laplace} and  \ref{expected_bailouts} for the unbounded variation case, we shall first obtain some auxiliary results.

Fix $b > 0$ and $q > 0$.
Let us consider the event
\begin{align}
E_B:=\{\zeta^->\mathbf{e}_{\p}\}\cup\{\zeta>\tau_b^+ \}\cup\{\zeta>\tau_a^{-}\}, \label{E_B_laplace}
\end{align}
where $\mathbf{e}_{\p}$ is an independent exponential clock with rate $\p$,  $\zeta$ is the length of the excursion from the point it leaves $0$ and returns back to $0$, and $\zeta^-$ denotes the length of the negative component of the excursion.
 That is, $E_B$ is the event in which (1) the exponential clock $\mathbf{e}_{\p}$ that starts once the excursion becomes negative  rings before the excursion ends, (2) the excursion exceeds the level $b>0$, or (3) it goes below $a < 0$.  Due to the fact that $X$ is spectrally negative, once an excursion gets below zero, it stays until it ends at $\zeta$; consequently, if we denote, by $\Theta_t$, the shift operator at time $t\ge 0$, then $\zeta^- = \tau_0^+ \circ \Theta_{\tau_0^-}$.

Now let us denote by $T_{E_B}$ the first time an excursion in the event $E_B$  occurs, and also denote by
\begin{align}
l_{T_{E_B}} :=\sup\{t< T_{E_B}: X(t)=0\}, \label{g_E_B}
\end{align}
the left extrema of the first excursion on $E_B$.
On the event
$\{l_{T_{E_B}} < \infty \}$, we have
\begin{align}
T_{E_B}=l_{T_{E_B}}+T_{E_B}\circ\Theta_{l_{T_{E_B}}}. \label{g_E_B_recursion}
\end{align}

Let $(e_{t}; t\geq 0)$ be the point process of excursions away from $0$ and $V:=\inf\{t>0: e_{t}\in E_B\}.$
By, for instance, Proposition 0.2 in  \cite{B},  $(e_{t}, t<V)$ is independent of $(V,e_{V})$. The former is a Poisson point process with characteristic measure $\mathbf{n}(\cdot \cap E_B^c)$ and ${V}$ follows an exponential distribution with parameter $\mathbf{n}(E_B).$ Moreover, we have that $l_{T_{E_B}}=\sum_{s<V}\zeta(e_{s})$, where $\zeta(e_{s})$ denotes the lifetime of the excursion $e_{s}$.
Therefore,  the exponential formula  for Poisson point processes (see for instance Section 0.5 in \cite{B} or Proposition 1.12 in Chapter XII in \cite{RY}) and the independence between $(e_{t}, t<V)$ and  $(V,e_{V})$ implies
\begin{align} \label{laplace_T_E_B}
\begin{split}
\mathbb{E}\Big( e^{-q l_{T_{E_B}}}\Big) &=\mathbb{E}\Big( \exp\Big\{-q \sum_{s<V}\zeta(e_{s})\Big\}\Big)=\mathbf{n}(E_B)\int_0^\infty e^{-s[\mathbf{n}(E_B)+\mathbf{n}(1-e^{-q\zeta}; E_B^c)]}\ud s\\
&=\frac{\mathbf{n}(E_B)}{\mathbf{n}(E_B)+\mathbf{n}\left(\mathbf{e}_q<\zeta, E_B^c\right)}=\frac{\mathbf{n}(E_B)}{\mathbf{n}(E_1)+\mathbf{n}(E_2)+\mathbf{n}(E_3)},
 \end{split}
\end{align}
 where $\mathbf{e}_q$ is an exponential random variable with parameter $q$ that is independent of $\mathbf{e}_r$ and $X$, and

  \begin{align*}
 E_1 &:= \{\mathbf{e}_q<\zeta\}\cup\{\tau_b^+<\zeta\}, \\ E_2&:= \{ \mathbf{e}_q>\zeta,\tau_a^-<\zeta < \tau_b^+ \}, \\ E_3 &:= \{\mathbf{e}_q>\zeta,\zeta^->\mathbf{e}_{\p},\tau_a^- \wedge \tau_b^+>\zeta \}.
 \end{align*
 To see how the last equality of \eqref{laplace_T_E_B} holds, we have
 \begin{multline*}
 \mathbf{n}(E_B)+\mathbf{n}\left(\mathbf{e}_q<\zeta, E_B^c\right) =  \mathbf{n}(\mathbf{e}_q < \zeta) + \mathbf{n}(\mathbf{e}_q > \zeta, E_B) \\= \mathbf{n}(E_1) - \mathbf{n} (\mathbf{e}_q > \zeta, \tau_b^+ < \zeta) + \mathbf{n}(\mathbf{e}_q > \zeta, E_B)
 =\mathbf{n}(E_1)+\mathbf{n}(E_2)+\mathbf{n}(E_3).
 \end{multline*}

 \begin{lemma} \label{lemma_E_123}
For $q > 0$ and $b > 0$,  we have  \begin{itemize}
 \item[(i)] $\displaystyle\mathbf{n}(E_1)

 = e^{\Phi_{\q}b} / W_{\q}(b)$,
\item[(ii)]$\displaystyle\mathbf{n}(E_2)=-\frac{1}{W_q(b)}\left(e^{\Phi_q b}-\frac{W_q(b-a)}{W_q(-a)}\right)$,
\item[(iii)]$\displaystyle \mathbf{n}\left(E_3\right)=-\frac{1}{W_q(b)}\left(\frac{W_q(b-a)}{W_q(-a)}-\frac{W_{q,r}^a(b)}{W_{q+r}(-a)}\right)$,
\item[(iv)] $\mathbf{n} \big(e^{-q\tau_b^+}; \tau_0^- > \tau_b^+ \big) = W_q(b)^{-1}$.
\end{itemize}
 \end{lemma}
 \begin{proof}
(i)  Let $\mathbf{L} = (\mathbf{L}(t); t \geq 0)$
be the local time at zero of the process $X$ and observe that $\mathbf{L}(\tau^+_b\land \mathbf{e}_q)$ is the first time where the Poisson point process $(e_{t}, t\geq 0)$ enters the set $E_1$.

 In other words,  $\mathbf{L}(\tau^+_b\land \mathbf{e}_q)$ is the first time  an excursion that goes above the level $b$ or such that its length is bigger than $\mathbf{e}_q$ starts. Using Proposition 0.2 in  \cite{B}, we deduce that  $\mathbf{L}(\tau^+_b\land \mathbf{e}_q)$ is exponentially distributed with parameter
 \begin{equation}
 \mathbf{n}(E_1)

 =\mathbb{E}\Big( \mathbf{L}(\tau_{b}^+\wedge\mathbf{e}_q)\Big)^{-1}.\notag
 \end{equation}
By the identity  (2.25) of \cite{PPR1} we have, with $u_q$ defined in \eqref{u_q_resolvent},
 \begin{equation}\label{localtb}
 \mathbb{E}\Big( \mathbf{L}(\tau_{b}^+\wedge\mathbf{e}_q)\Big)=\mathbb{E}\left( \int_0^{\tau_b^+}e^{-qs}\ud \mathbf{L}(s)\right)=u_q(0)-\frac{u_q(b)u_q(-b)}{u_q(0)}=e^{-\Phi_{\q}b}W_{\q}(b).
 \end{equation}
 Hence, we have the result.

 (ii) By the memoryless property of $\mathbf{e}_q$, \begin{align*}
\mathbf{n}(E_2) &= \mathbf{n}\left(e^{-q\tau_0^-}\mathbb{P}_{X(\tau_0^-)}
\left(  \tau_a^- < \tau_0^+ < \tilde{\mathbf{e}}_q \right); \tau_0^-<\t_b^+\right),
\end{align*}
where $\tilde{\mathbf{e}}_q$ is an independent copy of $\mathbf{e}_q$.
In this case, if we define $w_q(x) := e^{\Phi_q x}- W_q(x-a) / W_q(-a)$, then $w_q(x) = \mathbb{P}_{x}
\left(\tilde{\mathbf{e}}_q > \tau_0^+ >  \tau_a^- \right)$ for all $x \leq 0$, $w_q \in\mathcal{V}_0^{(q)}$, $w_q(0)=0$, and is differentiable at $0$. Hence by Theorem \ref{lemma_key_excursion} for $p=q$ and $v_q = 0$, we obtain
\begin{align*}
\mathbf{n}(E_2)=-\frac{1}{W_q(b)}w_q(b)=-\frac{1}{W_q(b)}\left(e^{\Phi_q b}-\frac{W_q(b-a)}{W_q(-a)}\right).
\end{align*}

(iii) Again, by the memoryless property of $\mathbf{e}_q$,
\begin{align*}
\mathbf{n}\left(E_3\right)& =
\mathbf{n}\left(e^{-q\tau_0^-}\mathbb{P}_{X(\tau_0^-)}
\left( \tilde{\mathbf{e}}_q> \tau_0^+, \tau_a^- > \tau_0^+ > \mathbf{e}_r \right); \tau_0^-<\t_b^+\right)\\
&=\mathbf{n}\left(e^{-q\tau_0^-}\E_{X(\tau_0^-)}
\left(e^{-q\tau_0^+}-e^{-(\q+\p)\tau_0^+};\tau_0^+<\tau_a^-\right); \tau_0^-<\t_b^+\right).
\end{align*}
If we set
\begin{align*}
v_q(x):=\frac{W_q(x-a)}{W_q(-a)}\qquad\text{and}\qquad w_{q+r}(x):=\frac{W_{q+r}(x-a)}{W_{q+r}(-a)},
\end{align*}
then, for $x\leq0$, we have $v_q(x)=\E_{x}
\big( e^{-q\tau_0^+};\tau_0^+<\tau_a^-\big)$ and $w_{q+r}(x)=\E_{x}
\big(e^{-(\q+\p)\tau_0^+};\tau_0^+<\tau_a^-\big)$,
which satisfy the conditions of Lemma 2.1 (with $p=q+r$). Therefore, Theorem \ref{lemma_key_excursion}  shows the result.

(iv) By a small modification of the proof of Theorem 3 (ii) in \cite{PPR2}, it is not difficult to see that
\begin{align*}
\mathbf{n}\left(e^{-q\tau_b^+};  \tau_b^+ < \tau_0^- \right) = \mathbf{n}\left(e^{-q\tau_b^+};\tau_b^+<\zeta\right)=\underline{\mathbf{n}}\left(e^{-q\tau_b^+};\tau_b^+<\zeta\right),
\end{align*}
where $\underline{\mathbf{n}}$ is the excursion measure of the process reflected at its infimum. Now by Proposition 1 in \cite{CD}, which establishes that the measure $\underline{\mathbf{n}}$ can be constructed as a limit of the law of $X$ killed at its first passage time above $0$, and by  \eqref{laplace_in_terms_of_z},
\begin{align*}
\underline{\mathbf{n}}\left(e^{-q\tau_b^+};\tau_b^+<\zeta\right)=\lim_{x \downarrow 0}\frac{\mathbb{E}_x\left(e^{-q\tau_b^+};\tau_b^+<\tau_0^-\right)}{W(x)}=\lim_{x \downarrow 0}\frac{W_q(x)}{W(x)W_q(b)}=\frac{1}{W_q(b)}.
\end{align*}
To see how the last equality holds, by for instance the identity (3.6) in page 132 of \cite{KKR}, the scale function admits a series representation
$W_q(x)=\sum_{j\geq 0}q^{j}W^{*(j+1)}(x),$
where $W^{*(k)}$ denotes the $k$-th convolution of $W$ with itself.  In addition, because $W$ is increasing, $W^{*(k+1)}(x)\leq x W(x)W^{*(k)}(x)$, $x>0$. Hence, we deduce that
\begin{align*}
0 \leq \frac {W_q(x) - W(x)} {W(x)}= W(x)^{-1}\sum_{j\geq 1}q^{j}W^{*(j+1)}(x)\leq x  \sum_{j\geq 0}q^{j}W^{*(j+1)}(x) \leq x  W_q(x)\xrightarrow{x \downarrow 0} 0.
\end{align*}
In sum, $\mathbf{n} \big(e^{-q\tau_b^+};   \tau_b^+ < \tau_0^- \big) = W_q(b)^{-1}$.
 \end{proof}

 By Lemma \ref{lemma_E_123}, we have
 $\mathbf{n}(E_1) + \mathbf{n}(E_2) + \mathbf{n}\left(E_3\right)
 = {W_{q,r}^a(b)} / [W_q(b) W_{q+r}(-a)]$.
Hence, by \eqref{laplace_T_E_B},\begin{align}\label{laplace_T_E_B_2}
\begin{split}
\mathbb{E}\Big( e^{-q l_{T_{E_B}}}\Big) &=\frac  {\mathbf{n}(E_B) W_q(b)  W_{q+r}(-a)} {W_{q,r}^a(b)}.
 \end{split}
\end{align}

\subsection{Proof of Theorem \ref{theorem_laplace} for the  unbounded variation case}

We show for the case $q > 0$.  The case $q = 0$ holds by monotone convergence.

\subsubsection{Proof of \eqref{Parisbailouts}}

On the event
$\{l_{T_{E_B}} < \infty \}$,
before $T_{E_B}$, there is no contribution to the cumulative bail-outs (because no exponential clock has rung before the excursion ends) and hence $X_r(t) = X(t)$, $0 \leq t \leq l_{T_{E_B}}$.
	Therefore, using the memoryless property of the Poisson arrival times,
  \begin{align}\label{eqwexc1_g}
 g(0,a,b,\theta)&= g_0(0,b) + [g_1(0,a,b,\theta)+ g_2(0,a,b,\theta)] g(0,a,b,\theta),
 \end{align}
where, with $\tilde{T}_0^- :=l_{T_{E_B}}+\tau_0^- \circ \Theta_{l_{T_{E_B}}}$,
 \begin{align*}
 \begin{split}
    g_0(0, b) &:= \E\Big( e^{-q \tau_b^+}; \tilde{T}_0^- > \tau_b^+ \Big), \\
   g_1(0,a,b,\theta) &:= \E\Big( e^{-q (\tilde{T}_0^- +\mathbf{e}_{\p}) + \theta X(\tilde{T}_0^-+\mathbf{e}_{\p})}; \tilde{T}_0^- <\tau_b^+, (\tau_0^+ \circ \Theta_{\tilde{T}_0^-}) \wedge (\tau_a^- \circ \Theta_{\tilde{T}_0^-}) > \mathbf{e}_{\p} \Big), \\
   g_2(0,a,b,\theta) &:=  \E\Big( e^{-q (\tilde{T}_0^- + \tau_0^+ \circ \Theta_{\tilde{T}_0^-} )
   	}; \tilde{T}_0^- <\tau_b^+, \mathbf{e}_{\p} \wedge (\tau_a^- \circ \Theta_{\tilde{T}_0^-}) > \tau_0^+ \circ \Theta_{\tilde{T}_0^-} \Big).
   \end{split}
\end{align*}

In particular, $g_2(0,a,b,\theta) = 0$  because
 $\mathbb{P} ( \tilde{T}_0^- <\tau_b^+, \mathbf{e}_{\p} \wedge (\tau_a^- \circ \Theta_{\tilde{T}_0^-}) > \tau_0^+ \circ \Theta_{\tilde{T}_0^-} ) = 0$ in view of the definition of $\tilde{T}_0^-$ and \eqref{E_B_laplace}.
\par A simple application of the so-called Master's formula  at time $l_{T_B}$ (see for instance excursions straddling a terminal time in Chapter XII in Revuz-Yor \cite{RY}) and Corollary \ref{corollary_big_U_zero} imply
\begin{align}
g_0 (0,b) = \mathbb{E}\Big( e^{-q l_{T_{E_B}}}\Big) \mathbf{n}\big(e^{-q\tau_b^+}; \tau_0^- > \tau_b^+ \big) / \mathbf{n} (E_B)\quad\text{and}\quad g_1(0,a,b,\theta) = \mathbb{E}\Big( e^{-q l_{T_{E_B}}}\Big) U_1^0(a,b, \theta) / [W_q(b) \mathbf{n} (E_B)]. \label{g_0_1}
\end{align}

Substituting these, \eqref{laplace_T_E_B_2}, Lemma \ref{lemma_E_123}(iv), and \eqref{U_0_summary} in \eqref{eqwexc1_g}, we obtain
 \begin{align}\label{excu_descomp}
g(0,a,b,\theta) &=  \frac {W_q(b)\mathbf{n}\big(e^{-q\tau_b^+}; \tau_0^- > \tau_b^+ \big)}  {W_{q,r}^a(b)/W_{q+r}(-a) - U_1^0(a,b, \theta)} =  \mathcal{H}^{\q,\p}_a(b , \theta)^{-1}.
 \end{align}
Using this expression in (\ref{sdep_1}) (which also holds for the unbounded variation case), we get the result.
\subsubsection{Proof of \eqref{Parisbailouts_2}}
By modifying the above arguments, we have
 \begin{align} \label{h_a_expression_n}
h(0,a,b,\theta) &=  \frac {U_3^0(a,b)} {W_{q,r}^a(b)/W_{q+r}(-a) - U_1^0(a,b, \theta)}.
 \end{align}
This together with \eqref{U_0_summary} gives $h(0,a,b,\theta) = - \mathcal{I}_{q,r}^a(b)/ \mathcal{H}^a_{\q,\p}(b,\th)$.
Using this in (\ref{Exit_prob_a_new1}), we obtain the result.
\subsection{Proof of Theorem \ref{expected_bailouts} for the  unbounded variation case}

We shall show for the case $q > 0$; the case $q=0$ holds by monotone convergence.
With $g_1$ defined in \eqref{g_0_1}, using the memoryless property of the Poisson arrival times,
\begin{align}\label{eqwexc1_ga}
f(0,a,b)&= f_0(0,a,b) + g_1(0,a,b,0) f(0,a,b),
\end{align}
wher
\begin{align*}
f_0(0,a, b) &:= \E\Big( e^{-q (\tilde{T}_0^- + \mathbf{e}_{\p})}(-X(\tilde{T}_0^- + \mathbf{e}_{\p})); \tilde{T}_0^- <\tau_b^+, (\tau_0^+ \circ \Theta_{\tilde{T}_0^-})\wedge(\tau_a^- \circ \Theta_{\tilde{T}_0^-}) > \mathbf{e}_{\p}\Big)
\end{align*}
Again, by the Master's formula in excursion theory and Corollary \ref{corollary_big_U_zero},
\begin{align*}
f_0 (0, a,b) = \mathbb{E}\Big( e^{-q l_{T_{E_B}}}\Big) \widehat{f}_0(0,a,b) / \mathbf{n} (E_B),
\end{align*}
where
\begin{align} \label{g_partsa}
\widehat{f}_0(0,a,b)&:=\mathbf{n}\left(e^{-q (\t_0^- + \mathbf{e}_{\p})}(-X(\t_0^- + \mathbf{e}_{\p})); \t_0^- <\tau_b^+, (\tau_0^+ \circ \Theta_{\t^-_0})\wedge(\tau_a^- \circ \Theta_{\t^-_0}) > \mathbf{e}_{\p}\right)\notag\\
&= -U_4^0(a,b){/W_q(b)}.
\end{align}
Using this, \eqref{laplace_T_E_B_2}, and \eqref{g_0_1}, we obtain
\begin{align}\label{mainexclow}
f(0,a,b) &=  \frac {-U_4^0(a,b)} {W_{q,r}^a(b)/W_{q+r}(-a) - U_1^0(a,b, 0)}.
\end{align}
Using the above identity, \eqref{U_0_summary}, and \eqref{U_0_summary_2}, we get $f(0,a,b)=  {h_{\q,\p}^{a}(b)} / {\mathcal{H}_{\q,\p}^{a}(b,0)}$.
Substituting this in (\ref{MPa}), we obtain the result.

\section{Proofs for the case with classical reflection above} \label{section_proof_reflected}

In this section, we prove the theorems in Section \ref{subsection_reflected_case}.  Toward this end, we first show Theorem \ref{lemma_simplifying_reflected}, which is a version of Lemma 2.1 of \cite{LRZ} (see \eqref{LRZ_identity}), when the process $X$ is replaced with the reflected process $Y^b$. Using this and the results for the process $X_r$ as obtained in previous sections, the theorems can be proven by arguments via the strong Markov property. These proofs hold for both the bounded and unbounded variation cases.

\subsection{Simplifying formula for the spectrally negative L\'{e}vy  process reflected from above}

	\begin{theorem} \label{lemma_simplifying_reflected} Fix $p \geq 0$ and $b > 0$. Suppose $v_p: \R \to [0, \infty)$ and belongs to $\tilde{\mathcal{V}}_0^{(p)}$.  Assume also that $v_p$ is locally bounded, right-hand differentiable at $b$ and
	\begin{align} \label{integrability_cond_formula_reflected}
	\sup_{0 \leq y \leq b}\int_{(-\infty, -1]} v_p (y + \theta) \Pi ({\rm d} \theta) < \infty.
	\end{align}
	 In addition, for the case of unbounded variation, in (ii) for the definition of $\tilde{\mathcal{V}}_0^{(p)}$ above, $v_{p,n}'(b+)$ converges to $v_{p}'(b+)$.
	Then, for $x \leq b$ and $q \geq 0$,

	\begin{align}\label{LRZ_identity_reflected}
	\E_x \big[ e^{-q \eta_0^-} v_p(Y^b(\eta_0^-)) \big]  	&= - \frac {W_q(x)} {W_q'(b +)} \frac {\partial_+} {\partial_+ b} \Big( v_p(b) - (p-q) \int_0^b W_q(b-y) v_p(y) {\rm d} y \Big) \notag\\
	&+ v_p(x) - (p-q) \int_0^x W_q(x-y) v_p(y) {\rm d} y\notag\\
	&= - \frac {W_q(x)} {W_q'(b +)}\Big( v_p'(b +) - (p-q) \Big[ \int_0^b W_q'(b-y) v_p(y) {\rm d} y + W_q(0) v_p(b)\Big] \Big) \notag\\
	&+ v_p(x) - (p-q) \int_0^x W_q(x-y) v_p(y) {\rm d} y.
	\end{align}

	\end{theorem}
\begin{proof}	(i) We first consider the case of bounded variation.   We also focus on the case $0 \leq x \leq b$; the case $x < 0$ is immediate.

	Using the resolvent given in Theorem 1 of \cite{pistorius2007excursion} and the compensation formula, we have
	\begin{align} \label{resolvent_expression_reflected}
	\begin{split}
	\E_x \big[ e^{-q \eta_0^-} v_p(Y^b(\eta_0^-))\big] &= \int_0^\infty \int_{(-\infty, -y)} v_p(y + \theta) \Pi ({\rm d} \theta)  \Big[ \frac {W_q'(b-y)} {W_q'(b +)} W_q(x) - W_q(x-y)\Big] {\rm d} y \\
	&+  W_q(x) \frac {W_q(0)} {W_q'(b+)} \int_{(-\infty, -b )} v_p(b + \theta ) \Pi ({\rm d} \theta).
	\end{split}
	\end{align}
	By (19) of \cite{LRZ}, we have
	\begin{align}
\int_0^{b} W_q(b-y) \int_{(-\infty, -y)} v_p(y + \theta) \Pi ({\rm d} \theta)  {\rm d} y = c v_p (0) W_q(b) - v_p(b) + (p-q) \int_0^b W_q(b-y) v_p(y) {\rm d} y. \label{LRZ_simplifying}
	\end{align}

Taking the right-hand derivative with respect to $b$,
		\begin{align} \label{LRZ_simplifying_reflected}
		\begin{split}
&\int_0^{b} W_q'(b-y)  \int_{(-\infty, -y)} v_p(y + \theta) \Pi ({\rm d} \theta)  {\rm d} y + W_q(0)  \int_{(-\infty, -b )} v_p(b + \theta ) \Pi ({\rm d} \theta) \\
&=\frac {\partial_+} {\partial_+ b}\int_0^\infty W_q(b-y) \int_{(-\infty, -y)} v_p(y + \theta) \Pi ({\rm d} \theta)  {\rm d} y
 \\&= c v_p (0) W_q'(b+) - v_p'(b +) + (p-q) \Big[ \int_0^b W_q'(b-y) v_p(y) {\rm d} y + W_q(0) v_p(b) \Big].
 \end{split}
	\end{align}

Here the right-hand derivative on the left-hand side can be interchanged over integrations by the following arguments.
For $\epsilon > 0$ and $0 \leq \delta < b$,  define
\begin{align*}
		K_1(\delta, \epsilon
		&:= \int_0^{b-\delta} \frac {W_q(b+\epsilon-y)  - W_q(b-y)} \epsilon \int_{(-\infty, -y)} v_p(y + \theta) \Pi ({\rm d} \theta)  {\rm d} y, \\
		K_2(\delta, \epsilon
		&:= \int_{b-\delta}^b \frac {W_q(b+\epsilon-y)  - W_q(b-y)} \epsilon \int_{(-\infty, -y)} v_p(y + \theta) \Pi ({\rm d} \theta)  {\rm d} y.
	\end{align*}
Note that for all $0 < \delta < b$, we have
\begin{align} \label{K_sum}
K_1(0, \epsilon) = K_1(\delta, \epsilon) + K_2(\delta, \epsilon).
\end{align}
Here, we show how $\lim_{\epsilon \downarrow 0}K_1(0, \epsilon)$ can be computed.
For the first term, for any $0 < \epsilon < \bar{\epsilon}$ for fixed $\bar{\epsilon} > 0$ and $0 < y < b - \delta$, we have a bound: $| W_q (b+\epsilon-y) - W_q(b-y) | / \epsilon \leq \sup_{\delta < z < b + \bar{\epsilon}} W_q' (z) < \infty$ (because $W_q'(z)$ is finite if $z > 0$, which is clear from \eqref{eq:Wqp0} [see  also identity (8.26) in \cite{K}]), and
	\begin{align*}
	\int_0^{b-\delta} \sup_{\delta < z < b + \bar{\epsilon}} W_q' (z) \int_{(-\infty, -y)} v_p(y + \theta) \Pi ({\rm d} \theta)  {\rm d} y = \sup_{\delta < z < b + \bar{\epsilon}} W_q' (z) \int_0^{b-\delta}  \int_{(-\infty, -y)} v_p(y + \theta) \Pi ({\rm d} \theta)  {\rm d} y
	\end{align*}
is finite by \eqref{integrability_cond_formula_reflected} and because, for sufficiently small $c > 0$, by the assumption that $X$ is of bounded variation,
	\begin{align*}
\int_{0}^{c}\int_{(-\infty, -y)} 1_{\{u > -c \}}\Pi({\rm d} u){\rm d} y = \int_{0}^c \int_{(-c, -y)} \Pi({\rm d} u){\rm d} y = \int_{(-c,0)} |u| \Pi({\rm d} u) < \infty.
\end{align*}

Therefore, by dominated convergence, the limit as $\epsilon \downarrow 0$ can be interchanged over the integral and hence,
		\begin{align*}
		K:= \lim_{\delta \downarrow 0}\lim_{\epsilon \downarrow 0} K_1(\delta, \epsilon) &=\lim_{\delta \downarrow 0}\int_0^{b-\delta} W_q'(b-y)   \int_{(-\infty, -y)} v_p(y + \theta) \Pi ({\rm d} \theta)  {\rm d} y \\
		&=\int_0^{b} W_q'(b-y)   \int_{(-\infty, -y)} v_p(y + \theta) \Pi ({\rm d} \theta)  {\rm d} y.
	\end{align*}
On the other hand, by Fubini's theorem and because $k(\delta) := \sup_{0 \leq u \leq b}\int_{(-\infty, -b + \delta)} v_p(u + \theta)  \Pi({\rm d} \theta) < \infty$, $0 < \delta < b$, by \eqref{integrability_cond_formula_reflected},
\begin{multline*}
	0 \leq K_2(\delta, \epsilon)

		\leq  k(\delta) \int_{b-\delta}^b \frac {W_q(b+\epsilon-y)  - W_q(b-y)} \epsilon {\rm d} y = k(\delta)  \frac 1 \epsilon \int_{b-\delta}^b  \int_0^\epsilon W_q'(b+z-y)  {\rm d} z  {\rm d} y \\
= k(\delta)\frac 1 \epsilon   \int_0^\epsilon (W_q(\delta+z) - W_q(z))  {\rm d} z  \leq k(\delta) \sup_{0 \leq z \leq \epsilon}|W_q(\delta+z) - W_q(z)|  {\rm d} z.
		\end{multline*}
	Hence, noting that $\lim_{\delta \downarrow 0} \lim_{\epsilon \downarrow 0}K_2(\delta,\epsilon)=0$ and by \eqref{K_sum},
	\begin{multline*}
K  = \lim_{\delta \downarrow 0}\liminf_{\epsilon \downarrow 0} (K_1(\delta, \epsilon) + K_2 (\delta, \epsilon)) = \liminf_{\epsilon\downarrow 0} K_1(0, \epsilon)  \leq  \limsup_{\epsilon\downarrow 0} K_1(0, \epsilon) \\ =
	\lim_{\delta \downarrow 0}\limsup_{\epsilon\downarrow 0} (K_1(\delta, \epsilon) + K_2 (\delta, \epsilon)) = K,
	\end{multline*}
implying $K_1(0, \epsilon) \xrightarrow{\epsilon \downarrow 0} K$, as desired.

Now, substituting \eqref{LRZ_simplifying} and \eqref{LRZ_simplifying_reflected} in \eqref{resolvent_expression_reflected}, we have
	\begin{align*}
	\E_x \big[ e^{-q \eta_0^-} v_p(Y^b(\eta_0^-)) \big] &=  \frac {W_q(x)} {W_q'(b+)}\Big( c v_p (0) W_q'(b+) - v_p'(b +) + (p-q) \Big[ \int_0^b W_q'(b-y) v_p(y) {\rm d} y + W_q(0) v_p(b) \Big] \Big) \\
	&- \Big(c v_p (0) W_q(x) - v_p(x) + (p-q) \int_0^x W_q(x-y) v_p(y) {\rm d} y \Big),

	\end{align*}
as desired.

(ii)
The unbounded variation case can be similarly shown by approximation methods by \cite{LRZ}.  With the convergent sequence $X^n$ for $X$, the corresponding reflected processes $Y^{b,n}$ also converge uniformly in compacts to $Y^b$ (using the fact that $Y^b$ can be written as the difference between $X$ and its running supremum). Hence, it suffices to take the limit in the equality \eqref{LRZ_identity_reflected} for $Y^{b,n}$:
	\begin{align*}
	\E_x \big[ e^{-q \eta_{0,n}^-} v_{p,n}(Y^{b,n}(\eta_{0,n}^-)) \big]
	&= - \frac {W_{q,n}(x)} {W_{q,n}'(b +)}\Big( v_{p,n}'(b +) - (p-q) \Big[ \int_0^b W_{q,n}'(b-y) v_{p,n}(y) {\rm d} y + W_{q,n}(0) v_{p,n}(b)\Big] \Big) \notag\\
	&+ v_{p,n}(x) - (p-q) \int_0^x W_{q,n}(x-y) v_{p,n}(y) {\rm d} y,
	\end{align*}
where $\eta_{0,n}^-$ and $W_{q,n}$ correspond to those for $Y^{b,n}$. Similarly to the arguments in the proof of Lemma 2.1 of \cite{LRZ}, the left hand side converges to $\E_x \big[ e^{-q \eta_{0}^-} v_{p}(Y^{b}(\eta_0^-))\big]$
 thanks to the uniform convergence assumed in (ii) in the definition of $\tilde{\mathcal{V}}^{(p)}$.  Regarding the convergence on the right hand side, it is known that $W_{q,n}(x) \rightarrow W_{q}(x)$
 for $x \in \R$, and $W_{q,n}'(x) \rightarrow W_{q}'(x)$
 for $x > 0$, as in Remark 3.2 of \cite{PY20015b}.  In addition, triangle equality gives
 \begin{align*}
& \Big| \int_0^b [W_{q,n}'(b-y) v_{p,n}(y) - W_{q}'(b-y) v_{p}(y)] {\rm d} y  \Big|\\
 &\leq  \int_0^b W_{q,n}'(b-y) |v_{p,n}(y) - v_{p}(y)| {\rm d} y
 + \Big| \int_0^b (W_{q,n}'(b-y) - W_{q}'(b-y)) v_{p}(y) {\rm d} y \Big| \\
 &\leq  (W_{q,n}(b) - W_{q,n} (0)) \sup_{0 \leq y \leq b} |v_{p,n}(y) - v_{p}(y)|
 + \big( |W_{q,n}(b) - W_{q}(b) | +  |W_{q,n}(0) - W_{q}(0) | \big) \sup_{0 \leq y \leq b}v_{p}(y),
 \end{align*}
 which vanishes as $n \uparrow \infty$ by the assumed uniform convergence of $v_{p,n}$.
	\end{proof}

By Theorem \ref{lemma_simplifying_reflected} together with Lemma \ref{lemma_u_in_V}, we can compute, for $a < 0 < b$ and $x \leq b$,
\begin{align*}
\begin{split}
\widehat{U}_1(x, a,b,\theta) &:= \E_x\Big(e^{-q\eta_0^-} u_1 (Y^b(\eta_0^-), a, \theta); \eta_0^- < \infty \Big), \quad \theta \geq 0, \\
\widehat{U}_i(x, a,b) &:= \E_x\Big(e^{-q\eta_0^-} u_i (Y^b(\eta_0^-), a ); \eta_0^- < \infty \Big), \quad i = 2,3, 4.
\end{split}
\end{align*}
For $a < 0$ and $x \in \R$, we define the derivatives of \eqref{U_0_summary} with respect to $x$:
\begin{align} \label{U_0_hat}
\begin{split}
\widehat{U}_1^{0}(a,x, \theta)&:=-\left(\p\int_{0}^{-a} e^{-\theta u}\Big[ \frac {(W^{a }_{\q,\p})'(x) W_{\q+\p} (u)} {W_{\q+\p}(-a)} -(W^{-u }_{\q,\p})' (x) \Big]{\rm d} u\right), \quad \theta \geq 0, \\
\widehat{U}_2^{0}(a,x) &:= - (W^{a }_{\q,\p})' (x) / W_{q+r}(-a), \\
\widehat{U}_3^{0}(a,x) &:= - \mathcal{I}_{q,r}^{a \prime} (x) , \\
\widehat{U}_4^{0}(a,x) &:= - h^{a \prime}_{q,r}(x).
\end{split}
\end{align}
In particular,
\begin{align*}
\widehat{U}_1^{0}(a, x, 0) &=- r \frac { \overline{W}_{q+r} (-a)} {W_{q+r}(-a)} (W^{a}_{\q,\p})'(x)+ \frac r {q+r} \Big[ (q+r)W^{a}_{\q,\p}(x)-rW_q(x)Z_{q+r}(-a) - qW_q(x)  \Big].
\end{align*}

Similarly to Corollary \ref{corollary_big_U}, we have the following result.
\begin{lemma} \label{A3}
For $a < 0 < b$ and $x \leq b$,
\begin{align*}
\widehat{U}_1(x, a,b,\theta) &=   \frac{W_q(x)}{W_q'(b+)}\widehat{U}_1^0(a,b,\theta) - U_1^0(a,x,\theta), \quad \theta \geq 0, \\
\widehat{U}_i(x, a,b) &=  \frac{W_q(x)}{W_q'(b+)}\widehat{U}_i^0(a,b) - U_i^0(a,x), \quad i = 2,3, 4.
\end{align*}
\end{lemma}
\begin{proof}
For the case $i=1,2,3$, this is a direct consequence of Lemma \ref{lemma_u_in_V} and Theorem \ref{lemma_simplifying_reflected}

On the other hand, for the remaining case, we note that
\begin{align*}
\widehat{U}_4(x, a,b) =  \frac{W_q(x)}{W_q'(b+)} \lim_{\theta \downarrow 0} \frac \partial {\partial \theta}\widehat{U}_1^0(a,b,\theta) - \lim_{\theta \downarrow 0} \frac \partial {\partial \theta} U_1^0(a,x,\theta).
\end{align*}
Similarly to the computation for $\lim_{\theta \downarrow 0} (\partial U_1^0(a,x,\theta)/  {\partial \theta})$ as in the proof of Corollary \ref{corollary_big_U}, we have \\ $\lim_{\theta \downarrow 0} (\partial \widehat{U}_1^0(a,b,\theta) / {\partial \theta})  =- h^{a \prime}_{q,r}(x)$. Hence putting the pieces together we obtain the result.
\end{proof}

Note that by Lemma \ref{A3}, \eqref{U_0_summary},  \eqref{U_1_U_2_sum}, \eqref{U_0_hat}, and $\widehat{U}_1^0(a,x, \theta) + \widehat{U}_2^0(a,x) = -\mathcal{H}_{q,r}^{a \prime}(x, \theta)$ for $x \in \R$ and $\theta \geq 0$,
		\begin{align} \label{H_H_derivative_relation}
		\begin{split}
		 \mathcal{H}^a_{q,r}(b,\theta) - \widehat{U}_1(b,a,b,\theta) - \widehat{U}_2(b,a,b)  &= \frac {W_q(b)} {W_q'(b+)} \mathcal{H}^{a \prime}_{q,r}(b,\theta), \quad \theta \geq 0, \\
		 \mathcal{I}^a_{q,r}(b) - \widehat{U}_3(b,a,b)  &= \frac {W_q(b)} {W_q'(b+)} \mathcal{I}^{a \prime}_{q,r}(b), \\
		  h_{\q,\p}^{a}(b)  - \widehat{U}_4(b,a,b) &=\frac {W_q(b)} {W_q'(b+)}  h_{\q,\p}^{a \prime}(b).
			\end{split}
		\end{align}

\subsection{Proof of Theorem \ref{theorem_h_hat}}

Note that for $x \leq b$, $\mathbb{P}_x$-a.s.
\begin{align} \label{Y_X_matches}
Y^b_r(t) = X_r(t), \quad 0 \leq t \leq \tau_b^+(r).
\end{align}
By an application of the Markov property at $\tau_b^+(r)$ on $\{ \tau_b^+(r) < \tau_a^-(r)\}$, we have
\begin{align}
\widehat{h}(x,a,b,\th)=h(x,a,b,\th)+g(x,a,b,\th)\widehat{h}(b,a, b, \th), \quad x \leq b, \label{h_hat_recursion}
\end{align}
where  $g$ and $h$ are as defined in \eqref{Parisbailouts} and \eqref{Parisbailouts_2}.
Again by the strong Markov property and \eqref{Y_matches},
\begin{align*}
\widehat{h}(b,a,b,\th)&=\E_b\left[e^{-q\eta_0^-}\E_{Y^b(\eta_0^{-})}\left(e^{-q\tau_a^-};\tau_a^-<\mathbf{e}_{\p}\wedge\tau_0^+\right)\right]\\
&+\E_b\left[e^{-q\eta_0^-}\E_{Y^b(\eta_0^{-})}\left(e^{-q\tau_0^+};\tau_0^+<\mathbf{e}_{\p}\wedge\tau_a^-\right)\right]\widehat{h}(0,a,b, \theta)\\
&+\E_b\left[ e^{-q\eta_0^-}\E_{Y^b(\eta_0^{-})}\left(e^{-q\mathbf{e}_{\p}+\theta X(\mathbf{e}_{\p})};\mathbf{e}_{\p}<\tau_0^+\wedge\tau_a^-\right)\right] \widehat{h}(0,a, b, \theta)\\
&=\widehat{U}_3 (b, a,b)+ [\widehat{U}_1(b, a,b, \theta) + \widehat{U}_2 (b, a,b)] \widehat{h}(0,a, b, \theta).
\end{align*}
Substituting this in \eqref{h_hat_recursion},
\begin{align}\label{h_0_reflected_1}
\widehat{h}(x,a,b, \th)=h(x,a,b,\th)+g(x,a,b,\th)\left(\widehat{U}_3 (b, a,b)+ [\widehat{U}_1(b, a,b, \theta) + \widehat{U}_2 (b, a,b)] \widehat{h}(0,a, b, \theta)\right).
\end{align}
Setting $x=0$ and solving for $\widehat{h}(0,a,b, \th)$, we obtain by \eqref{g_zero}, \eqref{h_zero}, and \eqref{H_H_derivative_relation},
\begin{align}\label{h_0_reflected_2}
\widehat{h}(0,a, b, \theta)=\frac{\widehat{U}_3 (b, a,b)-\mathcal{I}^a_{q,r}(b)}{\mathcal{H}^a_{q,r}(b,\th)-[\widehat{U}_1 (b, a,b,\th)+\widehat{U}_2 (b, a,b)]}=-\frac{\mathcal{I}_{\q,\p}^{a \prime}(b)}{\mathcal{H}^{a \prime}_{q,r}(b,\theta)}.
\end{align}
Finally, substituting \eqref{h_0_reflected_2} in \eqref{h_0_reflected_1} and using  \eqref{g_zero}, \eqref{h_zero}, and \eqref{U_0_hat} allows us to obtain the result.
	\subsection{Proof of Theorem \ref{theorem_R_b_r}}

We shall prove for the case $x \leq b$.  The case $x > b$ is then immediate by reflection.
		By \eqref{Y_X_matches}, the strong Markov property at $\tau_b^+(r)$ on $\{ \tau_b^+(r) < \tau_a^-(r)\}$, and \eqref{Parisbailouts}, we have

				\begin{align}
		\widehat{j}(x,a, b) &=g(x,a,b,0)\widehat{j}(b,a,b)=\frac{\mathcal{H}^a_{q,r}(x,0)}{\mathcal{H}^a_{q,r}(b,0)}\widehat{j}(b,a,b), \quad x \leq b. \label{j_relation}
		\end{align}

By the strong Markov property and \eqref{Y_matches}, together with (3.12) of \cite{APP},
		\begin{align}
		\widehat{j}(b,a,b) &= \E_b \Big( \int_0^{\eta_0^-} e^{-qt} {\rm d} L^b (t) \Big) +\E_b\Big[e^{-q\eta_0^-}\E_{Y^b(\eta_0^-)}\left(e^{-q(\tau_0^+\wedge \mathbf{e}_{\p})}; \tau_a^- > \tau_0^+\wedge \mathbf{e}_{\p} \right)\Big] \widehat{j}(0,a,b)\notag \\
		&= \frac {W_q(b)} {W_q'(b+)} +\big[ \widehat{U}_1(b,a,b,0) + \widehat{U}_2(b,a,b) \big] \widehat{j}(0,a,b).
		 \label{j_b_b}
		\end{align}
		Substituting  \eqref{j_b_b} in \eqref{j_relation}, and setting $x=0$,

				\begin{align*}
		\widehat{j}(0,a,b) &=\frac{1}{\mathcal{H}^a_{q,r}(b,0)} \Big( \frac {W_q(b)} {W_q'(b+)}+\big[ \widehat{U}_1(b,a,b,0) + \widehat{U}_2(b,a,b)\big] \widehat{j}(0,a,b) \Big),
		\end{align*}
		and hence, together with \eqref{H_H_derivative_relation},
						\begin{align*}
		\widehat{j}(0,a,b)  &=  \frac {W_q(b)} {W_q'(b+)} \Big( \mathcal{H}^a_{q,r}(b,0) - \widehat{U}_1(b,a,b,0) - \widehat{U}_2(b,a,b) \Big)^{-1} =  \mathcal{H}^{a \prime}_{q,r}(b,0)^{-1}.
		\end{align*}
Substituting this in \eqref{j_b_b}  allows us to obtain that $\widehat{j}(b,a,b) =  \mathcal{H}^a_{q,r}(b,0) / \mathcal{H}^{a \prime}_{q,r}(b,0)$. This together with  \eqref{j_relation} completes the proof.

\subsection{Proof of Theorem \ref{theorem_L_b_r}}
We focus on  the case $x \leq b$.  The case $x > b$ is then immediate by reflection.

By \eqref{Y_X_matches}, the strong Markov property at $\tau_b^+(r)$ on $\{ \tau_b^+(r) < \tau_a^-(r)\}$, and  Theorems \ref{theorem_laplace} and \ref{expected_bailouts},		\begin{align
		\widehat{f}(x,a, b) &= -h_{\q,\p}^{a}(x) + \frac{\mathcal{H}^a_{q,r}(x,0)}{\mathcal{H}^a_{q,r}(b,0)} [\widehat{f}(b,a, b) + h_{\q,\p}^{a}(b)]. \label{f_hat_relation}
		\end{align}
By the strong Markov property and \eqref{Y_matches},
\begin{align} \label{f_hat_relation_b}
\begin{split}
		\widehat{f}(b,a,b) &= -\E_b\Big[ e^{-q\eta_0^-}\E_{Y^b(\eta_0^-)}\left(e^{-q \mathbf{e}_{\p} }X(\mathbf{e}_{\p});\mathbf{e}_{\p} <
		\tau_0^+ \wedge \tau_a^- \right)\Big] \\ &+\E_b\Big[e^{-q\eta_0^-}\E_{Y^b(\eta_0^-)}\left(e^{-q(\tau_0^+\wedge \mathbf{e}_{\p})}; \tau_a^- > \tau_0^+\wedge \mathbf{e}_{\p} \right)\Big] \widehat{f}(0,a,b)\\
		&= - \widehat{U}_4(b,a,b) +\big[ \widehat{U}_1(b,a,b,0) + \widehat{U}_2(b,a,b)\big] \widehat{f}(0,a,b).
		\end{split}
		\end{align}
Substituting \eqref{f_hat_relation_b} in \eqref{f_hat_relation} and setting $x = 0$ and noticing that $h_{\q,\p}^{a}(0) = 0$,
\begin{align*
		\widehat{f}(0,a, b) &=  \frac 1 {\mathcal{H}^a_{q,r}(b,0)} \Big[ - \widehat{U}_4(b,a,b) +\big[ \widehat{U}_1(b,a,b,0) + \widehat{U}_2(b,a,b)\big] \widehat{f}(0,a,b) +  h_{\q,\p}^{a}(b) \Big].
		\end{align*}
		Hence, by \eqref{H_H_derivative_relation},
		\begin{align*
		\widehat{f}(0,a, b)  &=  \frac {h_{\q,\p}^{a}(b)  - \widehat{U}_4(b,a,b)} {\mathcal{H}^a_{q,r}(b,0)  -  \widehat{U}_1(b,a,b,0) - \widehat{U}_2(b,a,b)} =  \frac {h_{\q,\p}^{a \prime}(b)} {\mathcal{H}^{a \prime}_{q,r}(b,0)}.
		\end{align*}
		Substituting this in \eqref{f_hat_relation_b} and then in \eqref{f_hat_relation} and using \eqref{U_0_hat}, we have the claim.

redpajama_set_name: RedPajamaArXiv