Thomas Le Couedic
email: thomas.le-couedic@isep.fr

Anne Joutel
email: anne.joutel@inserm.fr

Raphael Caillon
email: raphael.caillon@isep.fr

Helene Urien
email: helene.urien@isep.fr

Florence Rossant
email: florence.rossant@isep.fr

Rikesh M Rajani
email: rikesh.rajani@cantab.net

Deep-learning based segmentation of challenging myelin sheaths

Keywords: deep learning, segmentation, myelin, axon, gratio, convolutional neural network (CNN), electron microscopy

The segmentation of axons and myelin in electron microscopy images allows neurologists to highlight the density of axons and the thickness of the myelin surrounding them. These properties are of great interest for preventing and anticipating white matter diseases. This task is generally performed manually, which is a long and tedious process. We present an update of the methods used to compute that segmentation via machine learning. Our model is based on the architecture of the U-Net network. Our main contribution consists in using transfer learning in the encoder part of the U-Net network, as well as test time augmentation when segmenting. We use the SE-Resnet50 backbone weights which was pre-trained on the ImageNet 2012 dataset. We used a data set of 23 images with the corresponding segmented masks, which also was challenging due to its extremely small size. The results show very encouraging performances compared to the state-of-the-art with an average precision of 92% on the test images. It is also important to note that the available samples were taken from elderly mices in the corpus callosum. This represented an additional difficulty, compared to related works that had samples taken from the spinal cord or the optic nerve of healthy individuals, with better contours and less debris.

I. INTRODUCTION

In the central nervous system, white matter consists of myelinated and unmyelinated axons that connect different brain regions. Myelinated axons are wrapped by multiple layers of myelin lamellae which are tightly sealed to the axon. The myelin sheath exhibits periodic small gaps, the Nodes of Ranvier, where the axon is unmyelinated. The primary function of myelin is to speed the propagation of action potentials along the axon of a neuron by preventing the leakage of current below the myelin sheath and restricting the propagation of action potentials from one node of Ranvier to another. The axon and its associated myelin sheath are also metabolically coupled; the myelin sheath provides trophic support to the axon needed for its long-term integrity and survival [START_REF] Stadelmann | Myelin in the central nervous system: structure, function, and pathology[END_REF]. The white matter has been recognized for its importance to brain health due to the devastating effect of white matter diseases such as sclerosis, leukodystrophies or small vessel diseases of the brain. Moreover, recent works indicate that white matter can exhibit learning-dependent plasticity with formation of new myelin or changes in myelin thickness [START_REF] Sampaio | White matter plasticity in the adult brain[END_REF]. The myelin g-ratio is a quantitative measure of the relative thickness of the myelin sheath and as such a critical parameter in white matter study. It is defined as the ratio of the inner axonal diameter to the outer radius of the myelin sheath wrapped around the axon. Studies that measure the g-ratio ex vivo in the CNS typically use electron microscopy. The optimal g-ratio, to achieve maximal efficiency, is roughly comprised between 0.6-0.8. Its computation requires a robust and precise segmentation. Through this article, we present the related works as well as the method we propose for segmenting these electron microscopy images in three classes : axon, myelin and background (Fig. 1, left). It was an exciting challenge because working with images so hard to read (Fig. 1, right) in such a small dataset is a big feat. However, by presenting the results and compare them to the state of the art, we demonstrate that our model, based on the U-Net architecture to which we add transfer learning approaches, provides very encouraging and promising results.

II. RELATED WORKS

Segmenting axons and myelin sheaths has been a challenge for several years. First works proposed traditional image segmentation methods, favoring unsupervised approaches.

Researchers from the university of Laval, Quebec, Canada, sought to tackle this challenge in 2014 [START_REF] Bégin | Automated method for the segmentation and morphometry of nerve fibers in large-scale cars images of spinal cord tissue[END_REF]. They used an unsupervised approach of boundary detection and watershed: first segmenting the axons, and then the myelin surrounding each of them. The final goal of this approach is to produce the histogram of g-ratio versus the axon equivalent diameter. This approach of segmenting axons and myelin in two parts allows for this calculation. Another work was precedently done by AxonSeg [START_REF] Zaimi | Axonseg: open source software for axon and myelin segmentation and morphometric analysis[END_REF], with similar methods, dataset and results. The segmentation of axons is based on the detection and analyis of local regional minima, morpholgical operations, feature extraction and discriminant analysis. The outer border of the myelin sheaths is obtained through minimal path and active contour algorithms. Our results will be compared to theirs towards the end of the article.V The main issue, in the context of this problem, is the lack of generalization. This set of techniques might work out fine and give out satisfactory results on an image of good quality with normal axons and myelin sheaths, but it may fail when the image is more complex, or acquired from a sick or elderly subject. The aim of our article is to be able to treat more complex images with higher accuracy.

More recent approaches rely on deep-learning methods. CNNs have proven to be very effective in computer vision, and U-net architectures [START_REF] Ronneberger | U-net: Convolutional networks for biomedical image segmentation[END_REF] have achieved very good performances in the segmentation of medical images. The first to use CNNs for myelin and axon segmentation were Mesbah et al. [START_REF] Mesbah | Deep convolutional encoder-decoder for myelin and axon segmentation[END_REF]. They did so in two main paths: the encoder-decoder architecture outperformed the per pixel approach. Another framework developped in 2018 by Zaimi et al, called AxonDeepSeg or ADS [START_REF] Zaimi | Axondeepseg: automatic axon and myelin segmentation from microscopy data using convolutional neural networks[END_REF] aims to answer the same problem. The authors worked with scanning electron microscopy images (SEM) and transmission electron microscopy (TEM) images. They used multiple resolutions of images, in order to improve generalization, and then manually segmented them. They produced images at multiple resolutions to train a custom U-Net model and achieved the best results so far. They concluded that the use of transfer learning as well as combining multiple models would be great steps to improve both the accuracy and the robustness of the model.

III. MATERIAL

Animal experiments were conducted in full accordance with the guidelines of our local institutional Animal Care and Use Committee (Lariboisire-Villemin, CEA9). A mouse model of cerebral autosomal dominant arteriopathy with subcortical infarcts and leukoencephalopathy (CADASIL), Tg-Notch3R169C, and relevant controls, non-transgenic and Tg-Notch3WT mice, were used at ages 6 months and 15 months. Brains were perfusion fixed, and the anterior corpus callosum was extracted and frozen using a high pressure freezing machine. Freeze substitution was carried out using a Leica EM AFS machine by modifying a previously used protocol (Weil et al., 2017), and brains were embedded in Epon. 70nm ultrathin sections were mounted on copper-palladium grids and stained. Images were taken using a Tecnai Spirit transmission electron microscope at 6500x (pixel size: 5.96nm; image size: 7.97x5.29m). The dataset consists of 23 electron microscropy images, of dimensions 1336 by 888 pixels. The images are in gray levels, coded on 2 bytes. All images were segmented by an expert, who delineated manually the boundaries of the axons and myelin sheaths with a stylus. This was a very tedious task, with ambiguous parts: especially the so-called "inner tongues", which are not strictly myelin or axon, and unmyelinated axons difficult to identify. Our data set is also complex because the imaged samples come from pathological states, resulting in a high level of structural variability: the thickness of the myelin can vary from a few nm to a few um; the number of axons with myelin can range from 20% to 80%; the size of the "inner tongue" can also vary considerably. We also can observe blur in some images, as well as uneven illumination. All these characteristics make the segmentation task very delicate, whether manually or automatically. Our aim is to achieve a good robustness and accuracy, despite all these features and the small size of our dataset. Fig. 1 shows two pre-processed images. While the myelin on the first image (Fig. 1, left) is rather well-defined, it is not the case for the second one (Fig. 1, right). Not only is it much more blurry and vague, but there are a lot of debris in the background that resemble the shape and size of axons. The axons in the second image also have more complex shapes than the round ones in the first.

IV. METHODS

A. Dataset preparation

In an effort to improve generalization, we normalized our images in Matlab using the Imadjust function. We then split the dataset into 3 categories (Fig. 2): train, validation and test sets. The training set consists of 17 .tif images, the validation set of 3 and the test set of 2.

B. U-Net choice

The neural network we used to segment these electron microscopy images is based on the U-Net architecture [START_REF] Ronneberger | U-net: Convolutional networks for biomedical image segmentation[END_REF]. U-Net is a CNN specifically developed for the segmentation of biomedical images. This architecture is composed of two paths giving it this U shape. The first path is the contraction path, also called encoder. It is a convolution neural network used to extract the characteristics and capture the context of the image, by computing highlevel features. The other part of the network is the expansive path, symmetrical to the contractive path, also called decoder. It consists of a sequence of upconvolutions and ascending concatenations that allows the image to be reconstructed, this time segmented, by capturing the precise localization information of the image. It is therefore an endto-end fully convolutional network (FCN) [START_REF] Long | Fully convolutional networks for semantic segmentation[END_REF]. One of the main strength of this network is the connections between the encoder and decoder parts. Those connections are used to skip features from the contracting path to the expanding path in order to recover spatial information lost during downsampling.

C. Transfer learning

Our main contribution is the use of Transfer Learning [START_REF] Van Opbroek | Transfer learning improves supervised image segmentation across imaging protocols[END_REF] approaches in addition to the standard U-Net architecture (Fig. 2). Transfer Learning focuses on using stored knowledge, the network weights, gained while solving one problem and applying it to a different but related problem. We used the SE-Resnet50 [START_REF] Hu | Squeeze-and-excitation networks[END_REF] model, which is pre-trained on ImageNet dataset and fine-tuned to make it fit with our small dataset of electron microscopy images. We started by removing the model's original classifier, then we added a new classifier that best fits our purpose. Finally, to fine-tune the model, we have frozen the convolutional base and used its outputs to feed the classifier; the pre-trained model is used as a fixed feature extraction mechanism. We implement our methods in Keras thanks to the Segmentation Model API [START_REF] Yakubovskiy | Segmentation models[END_REF]. We used the weights trained on the ImageNet 2012 dataset, provided by Segmentation Model.

D. Data augmentation

We used data augmentation [START_REF] Perez | The effectiveness of data augmentation in image classification using deep learning[END_REF] on the inputs of the model in order to reduce over-fitting and improve generalization and robustness (Fig 2). All the transformations have been applied by using Albumentations [START_REF] Buslaev | Albumentations: Fast and flexible image augmentations[END_REF], a fast augmentation library. Considering the context and scale of these images, we chose the following parameters and their values are summarized in table I.

E. Training parameters

We performed more than fifty tests with different sets of hyper-parameters to evaluate their influence on the training and validation test. Once the model and the hyper parameters were optimized we applied it to the test images. We thus manually performed a method similar to the grid search [START_REF] Bergstra | Random search for hyper-parameter optimization[END_REF]. The table II summarizes the best set of hyper-parameters. Several hyper-parameters have a considerable influence on the performances. Among them, the use of batch normalization [START_REF] Santurkar | How does batch normalization help optimization?[END_REF] [START_REF] Ioffe | Batch normalization: Accelerating deep network training by reducing internal covariate shift[END_REF] layers between the convolution and activation layers of the decoder, the learning rate which controls how much you adjust the weights of your network, the cost function and the optimizer, that govern the way in which the model achieves learning. Last but no least, the backbone which differentiates us from the others existing methods, especially from AxonDeepSeg. Indeed, we have not used the original U-Net encoder part but we have used the SE-Resnet50 model thanks to transfer learning approaches. This model has been chosen by using grid searches as well.

The best results have been obtained with the use of the dice loss function and the Nadam optimizer. The loss is computed for a whole batch during the training : Eq. 1,

L(Y, Ŷ ) = 1 - 2 Y ∩ Ŷ |Y | + Ŷ (1)
where Y and Ŷ are respectively the ground-truth and the predicted output maps. This training phase has been executed on the Google Collab cloud platform and took only a few minutes on the NVIDIA TESLA K80 GPU provided.

F. Test time augmentation

As the model was very fast and we did not have time limitations, we chose to do test time augmentation (TTA) (Fig. 2). It is a quite uncommon method of improving the accuracy of the model. After flipping the same image, or applying the same deformations as in the data augmentation, these images are then segmented, and finally assembled together. Our program takes an image as input, flips it vertically and horizontally. It then segments the resulting images separately using the same model, and flips them back so that they all have the same orientation. Each image "votes" for the color of a pixel ; the stemming image's ( of same dimensions ) accuracy is improved by around 1%. It aims to removes biases that could have grown in the treatment of verticality of the image.

G. Evaluation method

After the training, we evaluated our model on the two test images. The numerical results are presented in the results part V-B.

1) Confusion matrix: As the segmented images of the test set and the masks have the same dimensions, we were able to create a confusion matrix V-B1.

2) Precision: Precision (Eq. 2) effectively describes the purity of our positive detections relative to the ground truth.

[P recision(T P, F P ) = T P T P + F P ]

(2)

3) Recall: Recall (Eq. 3) effectively describes the completeness of our positive predictions relative to the ground truth.

[Recall(T P ) = T P T

P + F N ] (3)
4) Dice coefficient: The Dice coefficient (Eq. 4), also known as F1-score is a metric used to gauge the similarity between the ground truth and the predicted output.

[DiceScore(T P, F P, F N ) = 2 * T P 2 * T P

+ F P + F N ] (4)
V. RESULTS AND DISCUSSION A. Qualitative results

Below are the images (Fig. 3) that compose our test set, after passing through the model. We identified 4 classes of errors, in which the other visible ones can be associated with. Error 1 can is linked to the dark nucleus of the axon, which is detected as background. Training the model on more axons with nuclei or tuning these spots down in pre-processing could solve this issue. Error 2 can be attributed to the extreme shape of the axon. Very elongated, the model chooses to split it in two. These odd shapes are rare in the dataset ; training the model with more diverse profiles of axons could help with generalization. Error 3 can be attributed to myelin debris or noise in the image. This particular method of obtaining the image leaves room for some indistinguishable parts. Error 4 is actually due to the fact that axon debris are present. They are hard to distinguish from background, but could be relevant for computing the g-ratio.

Even though the contours of the myelin sheaths are matching the one of the segmented image, the distinction between each individual myelin sheath is not made.

B. Quantitative results

1) Confusion matrix: We obtained this table by computing the difference by pixel in the starting and final images. We then averaged the results between test images, and scaled them to 100%. The true positives are in majority, but there is a net distinction between the three classes. Myelin contour is hard to define, and as previously mentioned, there are some structures in the image that are very ambiguous, and even an expert has difficulty to know wether it is an axon or not. The posteriori qualitative analysis of the segmentations showed that some axons were rightly segmented although they were not in the ground truth. Dr Joutel also identified myelin debris that were not manually segmented. 2) Metrics results: For each metric, we computed the score obtained on each class separately, doing a pixel-by-pixel analysis. We finally compute the average of these scores for the two test images. Using TTA slightly improved an already well-performing model. We can see that the scores computed on the axon class are the best, slightly ahead of those calculated on the myelin class. On the other hand, the results of the scores computed on the background class are much worse. We can interpret these results as follow: the axons are well segmented while the myelin is more difficult to circumvent and sometimes spills over into the background or the axons. Finally, the less good scores of the background class are due to the fact that the model sometimes finds axons and myelin which are not segmented on the ground truth image. Paradoxically, this bad score partly reflects the strength of our model. The results obtained are presented in the table V. It is also interesting to compare the time it takes to process a full image. The AxonSeg technique takes around 8 hours to segment a 110000 axon images, while ours segments images of same axon density in around 7 minutes. 3) Performance comparison: Table V presents the comparison of our performance with other similar works. ADS stands for AxonDeepSeg, which is the reference algorithm in this field. It is worth noting that the data sets are different, ours being much more challenging because of the extremely small dataset and the high image variability. We originally tried to use the same architecture and techniques as AxonDeepSeg, in order to optimise furthermore the hyperparameters of their model. These results can be seen in the "Ferreira" column, by the name of the student who used this method. This approach did not bear great fruits, as our dataset was much smaller, but this first step was necessary. Our final results, labelled "Our model", compete with the ones of AxonDeepSeg. Even though the size of the dataset has a strong influence on the results obtained, we can achieve slightly better dice scores. Moreover, the designers of ADS trained their model and tested it on electron microscopy images taken from young and healthy animals. In our case, we were dealing with older mices which represents an additional difficulty on the segmentation of the images. Finally, ADS images are taken from the spinal cord while ours are taken from the corpus callosum where segmentation is more difficult to perform.

VI. CONCLUSION AND PERSPECTIVES

Using transfer learning and test time augmentation, paired via the standard hyper-parameters optimization techniques only betters the outcome of the model. Taking the most steps possible in order to improve the generalization of the model is important as well, and we tried our best at it. This also was an exercise of working with a rather extreme dataset. The total number of training images and their definition was very low, and the quality of the myelin in some cases was challenging. The Hausdorff Distance is widely used in evaluating medical image segmentation methods. Using this boundary-based metric could improve the qualitative results of the predictions. One could build on the work described in [START_REF] Karimi | Reducing the hausdorff distance in medical image segmentation with convolutional neural networks[END_REF]. Moreover, we could see that increasing the size of the dataset had a favourable impact on the quantitative results obtained. This avenue will soon be explored because the Paris Lariboisire hospital will provide us additional images. We also consider adversarial normalization as a possible improvement [START_REF] Delisle | Adversarial normalization for multi domain image segmentation[END_REF]. There exist many ways of collecting these images, and there might exist disparities within a same image: adapting the normalization to the dataset could improve the robustness of the model further more. The ultimate goal of this segmentation tool would be to then compute the g-ratio of each axon. Computing the g-ratio for every axon will enable us to get a very reliable histogram, which is valuable to characterize diseases affecting the white matter.

Fig. 1 .

 1 Fig. 1. Electron microscopy images

Fig. 2 .

 2 Fig. 2. Complete pipeline in 4 steps

Fig. 3 .

 3 Fig. 3. Qualitative results of our model

TABLE I DATA

 I AUGMENTATION PARAMETERS

	Parameter	Description
	Flip	Randomly flips vertically and horizontally with prob-ability of 0.5
	Shift	Randomly shifts the image up to 10% to any direc-
		tion with probability of 1
	Rotate	Rotates the image 360 with probability of 1
	Scale	Scales the image up to half or double its size with a
		probability 1
	Perspective	Changes the perspective with a probability 0.5
	Brightness	Changes the brightness with a probability of 0.9
	Gaussian noise	Adds statistical noise with a probability of 0.2
	Contrast	Changes the contrast with a probability of 0.45
	Hue saturation	Changes the color partitions with a probability of
		0.45
	CLAHE	Updates the histogram with a probability of 0.45
	Gamma	Changes the gamma profile with a probability of 0.45

VII. ACKNOWLEDGEMENTS

We would like to thank all the authors who contributed to the writing of this paper, as well Stephanie Ferreira who has previously worked on the subject (cf. III and V-B3).


Max Reppen
email: max.reppen@math.ethz.ch.

Jean-Charles Rochet
email: jeancharles.rochet@gmail.com.

H Mete Soner
email: mete.soner@math.ethz.ch.

Optimal dividend policies with random profitability *

We study an optimal dividend problem under a bankruptcy constraint. Firms face a trade-off between potential bankruptcy and extraction of profits. In contrast to previous works, general cash flow drifts, including Ornstein-Uhlenbeck and CIR processes, are considered. We provide rigorous proofs of continuity of the value function, whence dynamic programming, as well as comparison between the sub-and supersolutions of the Hamilton-Jacobi-Bellman equation, and we provide an efficient and convergent numerical scheme for finding the solution. The value function is given by a nonlinear PDE with a gradient constraint from below in one dimension. We find that the optimal strategy is both a barrier and a band strategy and that it includes voluntary liquidation in parts of the state space. Finally, we present and numerically study extensions of the model, including equity issuance and gambling for resurrection.

Introduction

The problem of optimizing dividend flows has its origins in the actuarial field of ruin theory, which was first treated theoretically by Lundberg [START_REF] Lundberg | Approximerad framställning af sannolikhetsfunktionen: 2. Återförsäkring af kollektivrisker. Akademisk afhandling[END_REF] in 1903. The theory typically models an insurance firm, and initially revolved around minimizing the probability of ruin. However, in many situations in practice, there is an emphasis on maximizing the shareholder value-an idea which fits well into de Finetti's [START_REF] De | Su un'impostazione alternativa della teoria collettiva del rischio[END_REF] 1957 proposal to optimize the net present value of dividends paid out until the time of ruin. With a positive discount rate of the dividends, de Finetti solved the problem for cash reserves described by a random walk. Since then, this new class of dividend problems has been extensively studied, especially in the context of modelling insurance firms.

Although a dividend problem can be seen as assigning a value to a given cash flow, the problem formulation nevertheless retains an emphasis on the ruin time. This is 1 contrasted by cash flow valuation principles such as real option valuation, first introduced by Myers [START_REF] Stewart | Determinants of corporate borrowing[END_REF] in 1977. Whereas the dividend problem seeks the value of a cash flow after passing through a buffer (the cash reserves), the real option approach evaluates a cash flow without such a buffer. In other words, the latter is a valuation of a cash flow without any liquidity constraint, as opposed to the optimal dividend problem where the firm can reach ruin. The real option value thus provides a natural bound for the optimal dividend value, which turns out to be helpful in our analysis.

In the actuarial literature, the cash reserves are commonly described by a spectrally negative Lévy process with a positive drift of premiums and negative jumps of claims. Our direct focus is not an insurance firm, and we instead study cash reserves described by a diffusion process. Although this is not the natural insurance perspective, it is studied also there as the limiting case of the jump processes, as initiated by Iglehart [START_REF] Donald | Limiting diffusion approximations for the many server queue and the repairman problem[END_REF].

Formulated as a problem of 'storage or inventory type', the general diffusion problem with singular dividend policies was solved by Shreve et. al [START_REF] Steven E Shreve | Optimal consumption for general diffusions with absorbing and reflecting barriers[END_REF] in 1984. In the case of constant coefficients in the cash reserves dynamics, Jeanblanc-Picqué & Shiryaev [START_REF] Jeanblanc | Optimization of the flow of dividends[END_REF] found the solution by considering limits of solutions to problems with absolutely continuous dividend strategies. The optimal solution to this singular problem formulation is described by a so-called barrier strategy, which yields a reflected cash reserves process by paying any excess reserves as dividends. This divides the state space into two regions: dividends are paid above the barrier (dividend region), but not in the region between zero and the barrier (no-dividend region). This is contrasted by dividend band strategies which frequently appear in jump models and were first identified by Gerber [START_REF] Gerber | Entscheidungskriterien für den zusammengesetzten Poisson-Prozess[END_REF]. Instead of the two spatial regions, there then exists at least one no-dividend region in which the origin is not contained. It thus creates a band-shaped no-dividend region in-between two dividend regions.

In the financial and economics literature, the main focus is on diffusion models, and extensions often involve nonconstant interest rate, drift and/or diffusion coefficients. Indeed, external, macroeconomic conditions and their effects on profitability have a substantial impact on dividend policies, as shown by Gertler and Hubbard [START_REF] Gertler | Corporate financial policy, taxation, and macroeconomic risk[END_REF] and more recently by Hackbarth et al. [START_REF] Hackbarth | Capital structure, credit risk, and macroeconomic conditions[END_REF]. Such macroeconomic effects have been studied in various forms. In particular, Anderson and Carverhill [START_REF] Carverhill | Corporate liquidity and capital structure[END_REF] as well as Barth et al. [START_REF] Barth | A non-stationary model of dividend distribution in a stochastic interest-rate setting[END_REF] numerically study continuously changing stochastic parameters, whereas Akyildirim et al. [START_REF] Erdinç Akyildirim | Optimal dividend policy with random interest rates[END_REF] consider stochastic interest rates following a Markov chain, and Jiang and Pistorius [START_REF] Jiang | Optimal dividend distribution under Markov regime switching[END_REF] consider model coefficients and interest rate both governed by Markov chains. Bolton et al. [START_REF] Bolton | Market timing, investment, and risk management[END_REF] similarly study the macroeconomic impact on both financial and investment opportunities. In contrast to coefficients influenced by macroeconomic factors, Radner and Shepp [START_REF] Radner | Risk vs. profit potential: A model for corporate strategy[END_REF] already in 1996 modelled a firm which alternates between different operating strategies, thereby effectively controlling the model coefficients. Other extensions include transaction costs of dividend payments or the possibility of equity issuance, cf. [START_REF] Erdinç Akyildirim | Optimal dividend policy with random interest rates[END_REF][START_REF] Bolton | Market timing, investment, and risk management[END_REF][START_REF] Décamps | Free cash flow, issuance costs, and stock prices[END_REF]. The papers by Cai et al. [START_REF] Cai | Optimal dividends in an Ornstein-Uhlenbeck type model with credit and debit interest[END_REF], and Cadenillas et al. [START_REF] Cadenillas | Optimal dividend policy with mean-reverting cash reservoir[END_REF] both treat different models with mean-reverting cash reserves, contrasting the model here, where we instead consider mean-reverting profitability. Finally, Avanzi and Wong [START_REF] Avanzi | On a mean reverting dividend strategy with brownian motion[END_REF] and Albrecher and Cani [START_REF] Albrecher | Risk theory with affine dividend payment strategies[END_REF] propose dividend processes proportional and affine in the cash reserves respectively as a means to capture the more stable dividend streams seen in practise. For further references, we refer the reader to [START_REF] Albrecher | Optimality results for dividend problems in insurance[END_REF][START_REF] Asmussen | Ruin Probabilities (Advanced series on statistical science & applied probability[END_REF] and the references therein.

Our choice of diffusion model has a continuous, stochastic drift generated by a separate profitability process. This structure yields a two-dimensional problem in which the dividend strategy depends on the current profitability. In particular, for low (negative) rates, a band strategy is optimal, but at higher rates, dividends are optimally paid according to a barrier strategy, with a barrier level depending on the profitability. Additionally, for very low rates, we prove that it is optimal to perform a voluntary liquidation, meaning that all cash reserves are paid instantaneously. Band structures are common for jump models, but here appear in a continuous model. 1 Finally, in addition to qualitative and numerical results, we provide proofs for continuity of the value function as well as a comparison principle for the dynamic programming equation. The latter supports the convergence of the numerical scheme.

The paper is organized as follows: We begin by describing the problem in Section 2, followed by our assumptions and analytical results in Section 3. In Section 4, we present a numerical algorithm as well as its results. Intuition for these results are then provided by studying a related, simpler problem in Section 5. Finally, we suggest and numerically study some possible extensions of the model in Section 6. At the end of the paper, after the concluding comments in Section 7, the proofs of the statements in Section 3 are given in Section 8.

Problem formulation

Consider a cash flow on the form

dC µ t = µ t dt + σ dW t , C µ 0 = 0,
where W is a Brownian motion and the profitability (cash flow rate) (µ t ) t≥0 is described by

dµ t = κ(µ t ) dt + σ(µ t ) d Wt , µ 0 = µ,
for some functions κ and σ, as well as another Brownian motion W with correlation ρ ∈ [-1, 1] to W . To emphasize the starting point of (µ t ) t≥0 , a superscript will sometimes be added. In other words, (µ ν t ) t≥0 is the process with µ 0 = ν and solving the above SDE. Despite the formulation of µ t as a continuous process, most of the results extend naturally to the Markov chains studied in the literature.

The precise assumptions on the diffusion, given in Assumptions 3.2 and 3.3, include Ornstein-Uhlenbeck processes

dµ t = k(μ -µ t ) dt + σ d Wt ,
for constants k > 0, μ, and σ as well as another commonly considered process, the Cox-Ingersoll-Ross (CIR) process:

dµ t = k(μ -µ t ) dt + σ√ µ t -a d Wt ,
for constants k > 0, μ, σ, and a. In fact, the Assumption 3.2 only imposes asymptotic conditions as |µ| → ∞. This means that on any given bounded domain, κ and σ can be general, provided certain growth conditions are satisfied outside the bounded domain, and provided the SDE has a well-defined solution. This is naturally satisfied by bounded processes. Interpreting -κ as the derivative of some potential, it also includes the possibility of potentials with multiple wells (local minima), thus having several points of attraction.

We model a firm whose cash flow is given by the process C µ = (C µ t ) t≥0 . The firm pays dividends to its shareholders using cash accumulated from the cash flow. Let L t denote the cumulative dividends paid out until time t. Then the cash reserves X = (X t ) t≥0 of a firm with initial cash level x can be written as dX

(x,µ),L t = dC µ t -dL t , X (x,µ),L 0 = x.
The objective of the firm is to maximize its shareholders' value, defined as the expected present value of future dividends, computed under the risk-adjusted measure. 2 Denote by M the domain on which µ t resides. This domain is typically the whole real line, as for a Ornstein-Uhlenbeck process, a half-line, for a CIR process, or a bounded interval, for a bounded process. The value function is then defined as

V (x, µ) := sup L∈A(x,µ) J(x, µ; L) := sup L∈A(x,µ) E   θ (x,µ) (L) 0 e -rt dL t (X 0 , µ 0 ) = (x, µ)   , (x, µ) ∈ O := [0, ∞) × M, (1)
where A(x, µ) is the set of processes L = (L t ) t≥0 that are càdlàg, adapted to the filtration (F t ) t≥0 generated by C µ and µ, as well as nondecreasing3 with ∆L t ≤ X (x,µ),L t-, 45 and

θ (x,µ) (L) := inf{t > 0 : X (x,µ),L t < 0}
is the time of bankruptcy. We model a limited liability firm, and therefore do not impose a penalty at ruin. In particular, we interpret a payout ∆L t = X t-as a decision to liquidate the firm. Note that since µ satisfies comparison (see [START_REF] Revuz | ume 293 of Grundlehren der mathematischen Wissenschaften[END_REF]Theorem 3.7,p. 394]), X (x,µ),L t ≤ X (y,ν),L t P -a.s. for any t ≤ θ (x,µ) if x ≤ y and µ ≤ ν. Hence, the value function is monotone in each argument. We use this comparison property repeatedly in the proofs.

In this paper we prove that liquidation is optimal when the profitability falls below a certain level; that, by stochastic methods, the value function is continuous and is a viscosity solution of the dynamic programming equation (DPE); that the DPE satisfies the comparison principle; and finally we provide a numerical scheme and extensive numerical results. Thereafter, we describe a related deterministic problem whose solution turns out to share most of the structural properties, thus providing intuition for the original problem. Finally, we conduct numerical studies of some model extensions.

When the starting points (x, µ) of the cash reserves and the cash flow are clear from context, the superscripts will be dropped in order to simplify the notation. Similar omissions of superscripts will be done for the bankruptcy times and strategies L when it is clear what dividend policy is followed.

Main results

The state space can be divided into a number of regions, each characterized by its role in the DPE-interpreted as a control action. An illustration of these regions is presented in Figure 1. The value function is characterized by three main regions: the dividend region, retain earnings region, and the liquidation region. The region of retained earnings is bounded by two curves and is characterized by dL t = 0. The dividend region and liquidation region are both characterized by dL = 0, but correspond to different interpretations, and intersect at the line at the threshold value µ * . More precisely, in the liquidation region, all available cash reserves are 'paid', leading to a liquidation. This is in contrast to the dividend region, where only the excess of the dividend boundary (or dividend target) is paid to the shareholders.

The remainder of this section is devoted to the statements of the main results. The proof of these results are given in Section 8. For the proofs we need the following set of assumptions, satisfied by for example Ornstein-Uhlenbeck and CIR processes. This assumption essentially says that the profitability process is mean-reverting and wellbehaved in the sense of a Feller condition. Mean-reversion of profitability is empirically well established by Fama and French [START_REF] Fama | Forecasting Profitability and Earnings[END_REF] and others.

We will use the so-called big O notation.

Definition 3.1. A function f is said to be in O(g) (so-called big O) as y → a if lim sup y→a f (y) g(y) < ∞.
We are now ready to state the following set of assumptions on the growth of the coefficients and the regularity of µ at a boundary of its domain. Assumption 3.2. Throughout, we assume that the domain of (µ t ) t≥0 is some possibly unbounded interval M ⊆ R. In other words, for any starting point µ 0 ∈ M, the process remains in M.

Moreover, we assume that κ and σ2 are locally Lipschitz continuous on the interior M o , that -µ/κ is non-negative and bounded for large The figure shows the three regimes. In the region between the lines x and x the all incoming profits are retained. When the cash reserves fall to x, the firm liquidates, whereas when it increases to x, dividends are paid out according to the local time at the boundary, thus reflecting the cash reserves process. In the region above x, a lump sum of the excess of x is paid immediately. Finally, when µ ≤ µ * , liquidation is optimal at all cash levels.

-κ/µ is non-negative and bounded for large -µ, as well as that σ2 ∈ O(µ) and never vanishes in M o .

The following assumption is needed to prove comparison for non-Lipschitz coefficients κ and σ.

Assumption 3.3. If M = R, i.e., it has an upper or lower boundary, we require some regularity at this boundary.

1. The function σ2 is also locally Lipschitz on the boundary ∂M.

2. For any sufficiently small η > 0, we assume that if -∞ < inf M = ν, then lim sup

µ→ν 1 µ -ν - 2κ(µ) + ηρσσ(µ) σ(µ) 2 < ∞,
and if ∞ > sup M = ν, then lim inf µ→ν 1 µ -ν - 2κ(µ) + ηρσσ(µ) σ(µ) 2 > -∞.
The economic interpretation of the growth conditions on κ is that even if the profitability is very large, it eventually returns to a more reasonable level. The growth condition on σ simply ensures that the diffusion does not overpower this effect. Finally, the origin of the lim sup and lim inf conditions at the boundary points are due to conditions needed for the comparison proof (cf. Section 8.4), while still general enough to encompass processes like the ones in Section 2.

Finiteness

We begin by establishing that the value function is finite. The proof of this result is provided in Section 8.1.

Theorem 3.4. Under Assumption 3.2, the value function is finite.

Liquidation threshold

The following theorem establishing the existence of the value µ * in Figure 1 is proven in Section 8.2. Theorem 3.5. If M has no lower bound, there exists a value µ * such that it is optimal to liquidate immediately whenever µ ≤ µ * , i.e. V (x, µ) ≡ x.

Continuity

Although the problem formulation bears resemblance to the Merton consumption problem, which has been extensively studied in the mathematical finance literature, the crucial difference here is that the firm is always exposed to the risk of its own operations. In other words, since X is the only asset and also volatile, there is no safe asset, and, t Cash and dividends

x + C t (ω) L 1 t θ(L 1 ) L 2 t θ(L 2 ) θ( Lt )
Figure 2: Recall that ruin occurs when the dividends reach the total cash accumulated, i.e. x+C t . The figure illustrates two dividend policies L 1 and L 2 (solid) as well as their convex combination L = (L 1 + L 2 )/2 (dashed), showing that for some path θ( L) < θ(L 1 ) ∨ θ(L 2 ), which corresponds to the possibility of dividend payments after ruin. Equivalently, the set of dividend strategies which are constant after ruin is nonconvex. as a result, the problem lacks desired concavity properties. More specifically, this happens due to the possible quasi-convexity of L → θ(L). Figure 2 shows a case where θ L 1 +L 2 2 < max{θ(L 1 ), θ(L 2 )} for two strategies L 1 and L 2 , which means that the convex combination of strategies in some scenario would pay out dividends after bankruptcy. Note that this loss of concavity corresponds to nonconvexity of the set of dividend processes that are constant after ruin.

Despite this lack of concavity, we can prove continuity, given by the following theorem:

Theorem 3.6. The value function is continuous everywhere.

Dynamic programming equation

Following the continuity of Theorem 3.6, we refer to [START_REF] Wendell | Controlled Markov processes and viscosity solutions[END_REF] for proving the dynamic programming principle. For a general proof of dynamic programming, we refer to [START_REF] Karoui | Capacities, measurable selection and dynamic programming part I: abstract framework[END_REF][START_REF] Karoui | Capacities, measurable selection and dynamic programming part II: application in stochastic control problems[END_REF].

Writing LV = µV x + κ(µ)V µ + Tr Σ(µ)D 2 V, where Σ = 1 2 σ 2 ρσσ ρσσ σ2
is the covariance matrix, the dynamic programming equation corresponding to ( 1) is given by min{rV -LV,

V x -1} = 0, in R >0 × M, (2)
with V (0, •) ≡ 0.

Theorem 3.7 (Comparison). Let u and v be upper and lower semicontinuous, polynomially growing viscosity sub-and supersolutions of (2). Then

u ≤ v for (x, µ) ∈ 0 × M implies that u ≤ v everywhere in O := R ≥0 × M.
Corollary 3.8 (Uniqueness). The value function is the unique subexponentially growing viscosity solution to the dynamic programming equation [START_REF] Albrecher | Risk theory with affine dividend payment strategies[END_REF].

Proof. By the dynamic programming principle, the value function V is a solution to (2). To obtain uniqueness, observe that, by Theorem 3.7, V , being both a sub-and a supersolution, both dominates and is dominated by any other solution. In other words, it is equal to any other solution, and thus unique.

Note that the comparison principle is essential for the stability property of viscosity solutions. The stability property, leads to convergence of monotone numerical schemes to a solution, which by the comparison theorem is unique, cf. [START_REF] Barles | Convergence of approximation schemes for fully nonlinear second order equations[END_REF]. It thus ensures that the stability property gives the correct solution.

Numerical results

The numerical results presented in this section are all obtained through policy iteration. Policy iteration is an iterative technique where one chooses a policy/control, calculates the corresponding payoff function, then updates/improves the policy where the payoff function suggests it is profitable, and finally iterates this procedure until convergence. That the scheme does indeed converge to the value function is supported by the comparison principle in Theorem 3.7 and the uniqueness result in Corollary 3.8.

The idea implemented here is to approximate the singularity with increasingly large controls which are absolutely continuous with respect to time. In particular, let K > 0 be any large constant and consider control variables L t = t 0 (X L t ) dt, where (x) ∈ [0, K] is measurable. Then, the problem of optimizing over functions amounts to a penalization of the DPE (2) with penalization factor K.

To see that the limit of these problems gives the solution to the original problem, we begin by writing out the PDE for the approximation: min

∈[0,K] rV K -LV K + V K x -1 = 0. (3)
By dividing by K and subtracting and adding equal terms, we reach min

λ∈[0,1] (1 -λ) rV K -LV K K + λ V K x -1 + rV K -LV K K = 0, which is equivalent to min rV K -LV K , V K x -1 + rV K -LV K K = 0.
With some abuse of notation, let

L(µ, p x , p µ , Y ) = µp x + κ(µ)p µ + Tr Σ(µ)Y,
and

F K (x, µ, u, p x , p µ , Y ) = min ru(x, µ) -L(µ, p x , p µ , Y ), p x -1 + ru(x, µ) -L(µ, p x , p µ , Y ) K . Letting K → ∞, lim K→∞ F K (x, µ, u, p x , p µ , Y ) = min {ru(x, µ) -L(µ, p x , p µ , Y ), p x -1} = F (x, µ, u, p x , p µ , Y ).
Finally, V K is bounded from above (by V ) and monotonically increasing, and hence converging to to some function

V ∞ as K → ∞. Moreover, V K satisfies F K (x, µ, V K , V K x , V K µ , D 2 V K ) = 0,
so, by the viscosity stability property, V ∞ is a viscosity solution to F = 0, and, by the comparison theorem, V ∞ ≡ V . Thanks to this approximation of the state dynamics, it holds that in any given space discretization, the transition rate between states is bounded away from zero. This means that the continuous-time Markov chain on the discretized space can be reduced to a discrete-time Markov chain (cf., e.g., [START_REF] Martin L Puterman | Markov Decision Processes: Discrete Stochastic Dynamic Programming[END_REF]). Thus, after a suitable space discretization, the problem is solved using standard methods of policy iteration that are known to converge. The convergence to V K of the solution to the discretized problem can be also be shown with standard viscosity methods.

Let D be a discretization of O consisting of N points, and let L D be a corresponding discretization of the terms from (3) involving V K , i.e. rV K -LV K + V K

x . Then, starting with any control 0 , the policy iteration scheme with tolerance 6 τ ≥ 0 is given by the following steps: 7 Policy iteration algorithm (step i)

1. Compute V i ∈ R N such that (x ,µ )∈D L i D (x, µ, x , µ )V i (x , µ ) -i = 0, ∀(x, µ) ∈ D. Halt if sup |V i -V i-1 | ≤ τ . 2. For each (x, µ) ∈ D, compute i+1 (x, µ) according to i+1 (x, µ) ∈ arg min ˆ ∈[0,K]    (x ,µ )∈D L ˆ D (x, µ, x , µ )V i (x , µ ) -ˆ    .
3. Return to step (i).

Remark 4.1. In the algorithm above, the second step is computationally the most difficult. In general, there is no known structure to be used, so it often has to be solved by brute force. Luckily, however, the problems given for each (x, µ) are fully independent, and the step can thus be entirely parallelized. Thanks to this, the computational burden can be partly mitigated.

Results and comparative statics

What follows is an account of an implementation of the scheme for the Ornstein-Uhlenbeck model dµ t = k(μ -µ) dt + σ d Wt .

The resulting dividend policies are presented in Figure 3, with k = 0.5, μ = 0.15, and σ = 0.3 (left) as well as σ = 0.1 (right). The other parameter choices are σ = 0.1, ρ = 0, and r = 0.05. The white regions indicate dividend payments or liquidation, i.e., V x = 1 and dL > 0, whereas the black regions indicate that the firm retains all its earnings, i.e., rV -LV = 0 and dL = 0. The figures show the (approximately) optimal policy, from which the value function can be obtained by solving a linear system of equations.

Figure 4 shows the effect of changing one parameter at a time. The figures presented here have been generated for τ = 0, without parallelization on an ultrabook laptop. 8On this system, the computations took around 10 minutes9 at this resolution, and were observed to converge. Varying the parameters does not seem to change the qualitative properties significantly. The parameter σ primarily changes the width of the band region; k and μ affect the size and extension into the region of negative µ; σ changes the height; Figure 3: The black region corresponds to dL = 0, whereas the white region corresponds to dL > 0. The latter case is interpreted as either dividend payments or liquidation, depending on the position in the state space, see Figure 1. and finally ρ influences the shape. Note that although the free boundary is nonmonotone in σ for x right below 2, it is monotone for smaller x.

A source of intuition: the deterministic problem

When the two parameters σ and σ are zero, the problem can be solved explicitly for a mean-reverting κ(µ) = k(μ -µ), with k, μ > 0. The solution of this deterministic problem provides intuition for the solution of the stochastic problem.

Since (µ t ) t≥0 is mean-reverting to the positive value μ, it will never attain negative values once it has been positive. In particular, solving the ODE describing the dynamics of (µ t ) t≥0 yields µ t = μ + (µμ)e -kt .

We will treat the cases µ ≥ 0 and µ < 0 separately. If µ ≥ 0, the firm is always profitable, and does not default at x = 0 unless µ < 0. Therefore, there is no need for a cash buffer, so it is optimal to pay all the initial cash reserves immediately. Thereafter, cash from µ is paid out as it flows in. The value of paying the incoming earnings as dividends is

∞ 0 e -rt µ t dt = ∞ 0 μe -rt + (µ -μ)e -(k+r)t dt = μ r + µ - μ r + k . ( 4
)
Hence, for µ ≥ 0, the value is given by

V (x, µ) = x + μ r + µ - μ r + k .
On the other hand, if the cash flow starts at a negative level, it will eventually reach a positive state, but the question is whether the firm is able to absorb the cumulated

-1 -0.5 0 0.5 1 0 1 2 σ = 0.1 σ = 0.5 µ x -0.5 0 0.5 1 0 1 2 σ = 0.1 σ = 0.4 µ -2 -1 0 1 0 2 4 μ = 0.15 μ = 0 μ = 0.3 µ x -2 -1 0 1 0 1 2 k = 0.5 k = 0.25 k = 1.0 µ -1 -0.5 0 0.5 1 0 1 2 ρ = -1 ρ = 1
L t = x -x b (µ) + t τ 0 (µ)∧t µ s ds µ x b (µ) e -rτ 0 (µ) V (0, 0)
Figure 5: The value x b (µ) is the cost of waiting for positive cash flow, whereas e -rτ 0 (µ) V (0, 0) is the present value of the future positive cash flow. For µ below the level at which these coincide, liquidation is thus optimal. Liquidation is also optimal when x < x b (µ). losses before then. If it can, are those losses larger than future earnings? More precisely, the company could face ruin before it sees positive earnings, but even if it does not, the losses incurred could offset the value of the future positive cash flows. To address the first possibility, we calculate the minimum amount of cash needed to reach a positive cash flow before the time of ruin. Denote by τ 0 the time such that µ τ 0 = 0. This time can be found explicitly:

τ 0 = τ 0 (µ) = ln μ μ-µ -k .
The cumulative losses until a positive cash flow is reached are:

τ 0 (µ) 0 µ t dt = μτ 0 (µ) + µ - μ k (1 -e -kτ 0 (µ) ) = μτ 0 (µ) + µ k .
Hence, the initial cash level needs to be at least this high to survive until µ ≥ 0, i.e.,

V (x, µ) = x, if x < -μτ 0 (µ) - µ k =: x b (µ).
At an initial cash level x above x b (µ), we identify two possible strategies: Either pay out dividends of size x -x b (µ) and wait for (µ t ) t≥0 to reach 0, or perform a liquidation by paying out x. Which strategy is optimal depends on the cost of waiting and the value of future cash flows. Hence, for x ≥ x b (µ),

V (x, µ) = max{x, x -x b (µ) + e -rτ 0 (µ) V (0, 0)} = x + max 0, e -rτ 0 (µ) V (0, 0) -x b (µ) .
Since x b and τ 0 are both decreasing in µ, there exists a µ * such that e -rτ 0 (µ * ) V (0, 0) = x b (µ), so from the last term we see that if µ ≤ µ * , it is optimal to liquidate regardless of the cash level. In the model, this corresponds to paying all cash reserves as dividends at time t = 0, yielding the value V (x, µ) = x. With x b (µ) = 0 for µ ≥ 0, we have proved the following result:

Theorem 5.1. There exist thresholds x b (µ) and µ * such that

• it is optimal to liquidate immediately if µ ≤ µ * ;

• it is optimal to liquidate immediately if x < x b (µ);

• if x ≥ x b (µ) and µ ≥ µ * , it is optimal to immediately pay the excess x -x b (µ) and thereafter all earnings as they arrive.

This is the same type of structure we observe in the numerical solutions. The deterministic solution suggests that liquidation is optimal for two different reasons: When µ is very negative, the firm can not expect to recover the initial 'investment' x even if it avoids ruin, suggesting that the cash flow represents a poor business opportunity. On the other hand, for initial points (x, µ) below the solid line in Figure 5, the net present value of the cash flow net of the investment x is positive, but the firm foresees a liquidity crisis at τ 0 (µ). This future liquidity crisis could be avoided with more initial capital. However, lacking the extra funds, the optimal decision is immediate liquidation.

Model extensions

In this section we present a few model extensions that we study numerically. The numerical method used is the same as in Section 4, but in the case of fixed costs, a slight generalization of the approximation of controls is necessary, due to the non-local behavior, as mentioned below.

Equity issuance

A firm in need of liquidity could see itself issuing equity to outside investors. In the sequel, we assume that this happens whenever desired, but at a cost. We consider two costs: one cost λ p proportional to the capital received and one fixed cost λ f which is independent of the amount of equity issued. Mathematically, we follow the model in [START_REF] Décamps | Free cash flow, issuance costs, and stock prices[END_REF] and write dX t = µ t dt + σ dW t -dL t + dI t ,

where I = (I t ) t≥0 , just like L, is an adapted, increasing, RCLL control process. We allow for the costs to be µ-dependent, 10 and write λ p (µ t ) and λ f (µ t ). For emphasis, we keep this dependence explicit. The figures presented in this section are generated with the Ornstein-Uhlenbeck model dµ t = k(μ -µ) dt + σ d Wt for k = 0.5, μ = 0.15, and σ = 0.3. The other parameter choices are σ = 0.1, ρ = 0, and r = 0.05.

Proportional issuance costs

If the costs are purely proportional, i.e., λ f = 0, the payoff corresponding to any two controls L and I is

J(x, µ; L, I) = E θ(L,I) 0 e -rt dL -(1 + λ p (µ t )) dI t ,
where θ(L, I) is the first time the process X becomes negative. In this case, the DPE bears great resemblance to that of the original model, since issuance simply has the opposite effect of dividend payments:

min{rV -LV, V x -1, 1 + λ p (µ) -V x } = 0.
The interpretation is that the state space consists of three different regions defined by the optimal action: pay dividends, issue equity, or doing neither. Equity is thus issued whenever V x (x, µ) = 1 + λ p (µ). This means that issuance occurs whenever the marginal value is equal to the marginal cost.

Since issuance is costly and can be done at any time, it is optimal to only issue equity at points where ruin would otherwise be reached, i.e., where x = 0. However, whether to do so at the boundary depends on the current profitability. Indeed, as seen in Figure 6, equity is only issued when the profitability is above a certain level, below which we still see the band structure of the original problem.

Fixed issuance costs

On the other hand, if the fixed cost is nonzero, we can assume, without loss of generality, that

I t = ∞ k=1 i k 1 {t≥τ k } ,
for some strictly increasing sequence of stopping times τ k and positive F τ k -measurable random variables i k . The stopping times are interpreted as issuance dates, and the random variables as the issued equity. If I t could not be written in this form, it would imply infinite issuance frequency, which would, because of the fixed cost, come at infinite cost. This form is therefore a natural restriction, and the corresponding payoff functional is given by

J(x, µ; L, I) = E   θ(L,I) 0 e -rt dL t - ∞ k=1 e -rτ k (λ f (µ t ) + λ p (µ t )i k )1 {τ k <θ(L,I)}   .
The value function given by this problem is then the solution to the following nonlocal DPE: Equity is issued according to local a time at the boundary x = 0 where otherwise ruin would occur, and no equity is issued below i = -1.0953. In the right figure fixed costs are present, starting at 0.14 decaying to 0.06 as a function of µ. Again, equity is only issued at the boundary, and no equity is issued below i = -0.7493. The dashed white line indicates the cash reserve level after issuance, i.e., how much equity was issued.

min rV -LV, V x -1, V (x, µ) -sup i≥0 V (x + i, µ) -λ p i -λ f = 0.
The last conditions states that the value at any given point is at least equal to the value in any point after issuance less the issuance costs.

Just like for proportional costs, issuance optimally only occurs at the boundary. However, with fixed costs, the amount of equity issued is now larger in order to avoid incurring another fixed cost soon in the future. The magnitude is presented as the issuance target in Figure 6. Note that, the numerical method employed in the fixed cost case can be interpreted as the issuance structure in [START_REF] Hugonnier | Capital supply uncertainty, cash holdings, and investment[END_REF] where the arrival of investors might not coincide with the desire for equity issuance. The approximation parameter K from the singular case will here describe the arrival rate of investors, and the value V is the limit when the investor arrival rate tends to infinity. This same approximation scheme is presented for another problem in [START_REF] Altarovici | Optimal consumption and investment with fixed and proportional transaction costs[END_REF] and turns out to be very accurate.

By letting the fixed cost grow sufficiently fast in -µ, one can obtain substantially different issuance policies. As shown in Figure 7, such structure can have a wave-like shape, not dissimilar to the shape of the continuity region. This seems to indicate two factors at play: Either one issues equity as a last resort at x = 0, or at an earlier time in fear of higher issuance costs in the future. Moreover, in this regime, the target points no longer constitute a continuous line, but instead has a jump discontinuity to the right of the gray region.

Gambling for resurrection

In Figure 3, we see that in the band region the solution first grows as x (liquidation region) and then reaches the region where V x > 1 (retain earnings region). We thus observe that the value function is not necessarily concave in the x-direction. However, it is sometimes argued that concavity is desirable, because of the possibility to enter (fair) speculative strategies and thus receiving the average of surrounding points. 11 Such possibilities can be incorporated into the model by considering another control process G = (G t ) t≥0 and cash reserves given by

X t = x + t 0 µ t dt + σW t -L t + G t ,
for processes of the form The figure on the right shows the model without gambling in gray, overlaid by the free boundaries of the gambling model in solid lines. When gambling is allowed, voluntary liquidation is no longer optimal in the 'band region'. This is because entering a 'lottery' gives a chance of reaching a higher point in the no activity region, thus concavifying the problem.

G t = ∞ k=1 g k 1 {t≥τ k } ,
for some sequence of predictable stopping times and F τ k -measurable random variables

g k 12 satisfying E[g k ] = 0 and X τ k -+ g k ≥ 0 P -a.s. This leads to the DPE min{rV -LV, V x -1, -V xx } = 0,
from which the last conditions makes it directly clear that the value function is now concave. However, as seen in Figure 8, this is not the concave envelope in the x-direction, since the retain earnings region shifts in the µ-direction. The cause of this is that gambling occurs in what otherwise would have been the no-dividend region, thus affecting the solution in the µ-direction through the elliptic operator L.

Concluding comments

In this paper, we have studied an optimal dividend problem where the profitability of the firm is stochastic. In this context, we have given a comparison result for general dynamics as well as outlined a numerical algorithm to compute the solution. The convergence of the numerical method is a consequence of the comparison result.

The numerical solution indicates that the problem exhibits both barrier and band structure, depending on the current profitability. The band structure is especially interesting, since it is unusual for Brownian dynamics. We also prove that when the profitability falls below a certain threshold, liquidation becomes optimal. Although mean reversion indicates that the profitability of the company will improve over time, that is not enough; when the initial profitability is too low, the expected cumulative losses are too large to be covered by the future income, so immediate closure is optimal.

The flexibility of the numerical method from Section 4 allows us to numerically study a number of extensions to our original model. The extended models allow for issuance with proportional and/or fixed costs as well as the possibility of gambling for resurrection. This last extension provides a way to concavify the problem (in the x-dimension) by giving the firm the opportunity of entering fair bets.

Proofs

This section is dedicated to the proofs of previous sections. We begin with a result that is needed in multiple proofs. It is proven under slightly stronger assumptions, which turn out to be satisfied without loss of generality where the lemma is needed.

Lemma 8.1. If, in addition to Assumption 3.2, inf M > -∞ or µ ∈ O(κ(µ))
as µ → -∞, there exists a sublinearly growing function H and a constant C such that, for any stopping time τ ,13

E max 0≤t≤τ |µ 0 t | ≤ CE[H(τ )].
Proof. We will use the result by Peskir [START_REF] Peskir | Bounding the maximal height of a diffusion by the time elapsed[END_REF] to obtain a function H which is sublinearly growing. For some c ∈ M o , let

S (µ) = exp -2 µ c κ(ν) σ(ν) 2 dν and m(dν) = 2 dν S (ν)σ(ν) 2 .

Finally, define

F (µ) = µ c m((c, ν])S (ν) dν.
Note that by the assumptions of the statement, κ and σ behave analogously for large positive and negative µ, so, without loss of generality, we may consider only positive values of µ. In particular, for large µ, S (µ) grows as exp(aµ γ ) for some a > 0 and γ ≥ 1, and we are done if we can verify the following condition:

sup µ>c F (µ) µ ∞ µ dν F (ν) < ∞.
All involved functions are continuous, so we are done if it has a finite limit (or is negative) as µ → ∞. L'Hôpital's rule yields the fraction

d dµ ∞ µ dν F (ν) d dµ µ F = F (µ) µF (µ) -F (µ)
.

If the denominator were bounded from above, Grönwall's inequality would imply linear growth of F , which contradicts the growth of S . Hence, the expression is either negative (and we are done), or we may use l'Hôpital's rule again: [START_REF] Peskir | Bounding the maximal height of a diffusion by the time elapsed[END_REF] allows us to conclude that

F (µ) µF (µ) = S (µ)m((c, µ]) 2µ σ(µ) 2 + µS (µ)m((c, µ]) µ→∞ ---→ 0, since S (µ)/µS (µ) = σ(µ) 2 /(-2κ(µ)µ) → 0. Thus, with H = F -1 ,
E max 0≤s≤τ |µ s | ≤ CE[H(τ )], (5)
for some constant C and any stopping time τ . In particular, for τ = t, the expression is finite and sublinearly growing in t.

Finiteness

In light of Lemma 8.1, the proof of the following theorem is natural.

Theorem 3.4. Under Assumption 3.2, the value function is finite.

Proof. Since X (x,µ),L t ≥ 0 for t ≤ θ (x,µ) (L),

L t ≤ x + t 0 |µ s | ds + σW t ≤ x + |µ 0 |t + t 0 |µ 0 s | ds + σW t .
Note that this bound is uniform in L. Hence, it follows from Lemma 8.1 that

V (x, µ) ≤ x + |µ 0 | r + ∞ 0 e -rt E[|µ 0 t |] dt < ∞.

Liquidation threshold

Before we present the proof of Theorem 3.5, we present an auxiliary problem whose properties are especially useful to prove the existence of a liquidation threshold. Consider the case where L is not restricted to be nondecreasing. This means that shareholders may inject new cash into the firm at no cost. In that case, cash reserves are useless and x must be distributed right away:

V a (x, µ) = x + V a (µ),
where the auxiliary function V a is given by

V a (µ) = sup τ E τ 0 e -rt µ t dt .
The liquidation time τ is chosen freely by the shareholders of the firm. This is a real option problem (see for example [START_REF] Avinash | Investment under uncertainty[END_REF]). Intuitively, the owners of the firm exert the liquidation option when the profitability µ falls below a (negative) threshold µ * , provided (µ t ) t≥0 can reach such a point. In particular, V a and µ * satisfies the following boundary value problem:

rV a (µ) -κ(µ)V a (µ) - σ(µ) 2 2 V a (µ) = µ, subject to V a (µ * ) = V a (µ * ) = 0.
The second part of this theorem characterizes an optimal liquidation time. This proves useful in the original problem since V (x, µ) ≤ V a (x, µ), thus showing that V (x, µ) ≡ x for levels of µ below some threshold. Lemma 8.2. When dividends can be of arbitrary sign, the optimal policy for shareholders is to immediately distribute the initial cash reserves at t = 0, and to maintain them at zero forever by choosing dL t = µ t dt + σ dW t . If M has no lower bound, there exists a µ * such that the firm is liquidated when profitability falls below the threshold µ * : τ = inf{t > 0 : µ t ≤ µ * } is a maximizer.

Proof. Suppose L be any strategy for which X L t ≥ 0 until some (liquidation) time τ . Then define

L t = L t + X L t . Since X L
t is nonnegative until τ , it is clear that X L t = 0 and that L t ≥ L t for t ≤ τ . Hence, L is admissible whenever L is, and it also produces a higher payoff.

It remains to prove the existence of µ * . If M has no lower bound, but κ is not growing linearly as µ → -∞, consider instead of (µ t ) t≥0 another process with the same σ, but which also fulfills this growth condition. The corresponding value function dominates our original one, so it is enough to prove it in this case.

Setting dL t = µ t dt + σ dW t until a stopping time τ yields

J(x, µ; L) = x + E τ 0 e -rt µ t dt + E τ 0 e -rt σ dW t .
Since the last term is zero, the value function is obtained by maximizing over τ :

V (x, µ) = x + sup τ E τ 0 e -rt µ t dt = x + V a (µ).
We now try to find a point in which V a is 0. Consider the equation

min -µ + rφ -κ(µ)φ - 1 2 σ(µ) 2 φ , φ = 0, (6)
and suppose it has a solution which never touches 0, i.e, φ > 0. Then,

φ(µ) = E ∞ 0 e -rt µ t dt = ∞ 0 e -rt E[µ t ] dt.
Using Itô's formula, the bounds on κ and σ, as well as ( 5), for µ < 0, we obtain

E[µ t ] ≤ µ + t 0 C 1   1 + E sup 0≤s≤t |µ 0 s |   ds ≤ µ + tC 2 (1 + H(t)),
for some constants C 1 and C 2 . Hence,

φ(µ) ≤ ∞ 0 e -rt µ + C 2 H(t) dt ≤ µ r + C 3 ,
for another constant C 3 . Thus, φ(µ) → -∞ as µ → -∞, which contradicts that φ ≥ 0. We conclude that a solution φ must indeed touch 0. Finally, we are done if V a satisfies the dynamic programming equation [START_REF] Carverhill | Corporate liquidity and capital structure[END_REF]. By Lemma 8.1 and [START_REF] Kobylanski | Optimal stopping in a general framework[END_REF], the optimal stopping time is the hitting time of

A 0 = {µ : V a (µ) = 0} = ∅.
Hence, the function is smooth everywhere, except possibly at µ * := sup A 0 . However, since σ never vanishes, an argument analogous to in the proof of Theorem 8.4 yields continuity also at µ * , from which (6) can be derived. Theorem 3.5. If M has no lower bound, there exists a value µ * such that it is optimal to liquidate immediately whenever µ ≤ µ * , i.e. V (x, µ) ≡ x.

Proof. Until the time of ruin θ(L), L t ≤ x + t 0 µ s ds + t 0 σ dW s . Hence, by stochastic integration by parts,

V (x, µ) = sup L∈A(x,µ) E θ(L) 0 e -rt dL t ≤ x+ sup L∈A(x,µ) E θ(L) 0 e -rt µ t dt +E θ(L) 0 e -rt σ dW t .
First observe that the last term is equal to 0. Then, since the second term is smaller than or equal to V a (µ), the result is a direct consequence of Theorem 8.2.

Continuity

When proving the continuity of the value function, we need the following weak form of a dynamic programming inequality: Lemma 8.3. For any control L and stopping time τ with values between 0 and θ(L),

E θ(L) τ e -rt dL t F τ ≤ e -rτ V (X τ , µ τ ), P -a.s., (7)
where V denotes the upper-semicontinuous envelope of V .

Proof. By the definition of J,

E θ(L) τ e -r(t-τ ) dL t F τ = J(X τ , µ τ ; L •+τ ) ≤ V (X τ , µ τ ) ≤ V (X τ , µ τ ), P -a.s.
From this, the lemma follows directly.

The necessity of this lemma stems from the a priori lack of the dynamic programming principle and the measurability of V . This inequality is very related to the weak dynamic programming principle [START_REF] Bouchard | Weak dynamic programming principle for viscosity solutions[END_REF] which also establishes a similar inequality in the other direction. However, as seen in the proof above, this equality is more primitive than that in the other direction.

The measurability issues are arguably the most notable obstacles in establishing the dynamic programming principle. However, for continuous value functions, proofs of the dynamic programming principle are well known [START_REF] Wendell | Controlled Markov processes and viscosity solutions[END_REF]. For the general case, we once again refer to [START_REF] Karoui | Capacities, measurable selection and dynamic programming part I: abstract framework[END_REF][START_REF] Karoui | Capacities, measurable selection and dynamic programming part II: application in stochastic control problems[END_REF].

In this section we establish the continuity of the value function, from which the dynamic programming principle then follows.

Theorem 8.4. The value function is continuous at x = 0.

Proof. Let {(x n , µ n )} n≥1 be a sequence converging to (0, µ ∞ ). Without loss of generality, assume x n > 0 converges monotonically to 0. Since V ≡ 0 at x = 0, it is sufficient to consider monotonically decreasing sequences in µ, by monotonicity in µ. For simplicity, also assume that

x 1 < 1 and |µ 1 -µ ∞ | < 1.
Let τ be any strictly positive, bounded stopping time such that for t ≤ τ , µ µ 1 t ≤ |µ ∞ |+1 and X (x 1 ,µ 1 ),0 t ≤ 1, P -a.s for the uncontrolled process corresponding to L = 0. Hence, we also have X (x n ,µ n ),L ≤ X x 1 ,µ 1 ,0 ≤ 1 for all n ∈ N and dividend processes L.

Starting with the definition of the value function, one obtains

V (x n , µ n ) = sup L∈A(x n ,µ n ) E τ ∧θn(L) 0 e -rt dL t + 1 {τ <θn(L)} θn(L) τ ∧θn(L) e -rt dL t ≤ sup L∈A(x n ,µ n ) E τ ∧θn(L) 0 e -rt dL t + 1 {τ <θn(L)} θn(L) 0 e -rt dL t ≤ sup L∈A(x n ,µ n ) E x n + (|µ ∞ | + 1)(τ ∧ θ n (L)) + V (1, |µ ∞ | + 1)1 {τ <θn(L)} ≤ x n + (|µ ∞ | + 1)E[τ ∧ θ n (0)] + V (1, |µ ∞ | + 1)P [τ < θ n (0)].
Now make the observation that,

{τ < θ n+1 (0)} ⊆ {τ < θ n (0)}.
Since σ > 0, θ n (0) → 0 P -a.s., and therefore

lim n→∞ P [τ < θ n (0)] = P lim n→∞ {τ < θ n (0)} = P [τ ≤ 0] = 0. By letting n → ∞, we obtain lim n V (x n , µ n ) ≤ (|µ ∞ | + 1)E[τ ]
, but since τ can be chosen arbitrarily small, we conclude that

lim n→∞ V (x n , µ n ) ≤ 0.
Since V is non-negative and zero where x = 0,

lim n→∞ V (x n , µ n ) = 0 = V (0, µ ∞ ).
Lemma 8.5. For each starting point (x, µ), the payoffs θ(L) 0 e -γt dL t for strategies L are uniformly bounded in • L 1 (Ω) for any γ > 0.

Proof. Without loss of generality, we may assume that µ ∈ O(κ(µ)) as µ → -∞, since this yields a larger or equally large process µ t , and therefore also θ(L) 0 e -γt dL t . Integration by parts yields

θ(L) 0 e -γt dL t ≤ x + θ(L) 0 e -γt µ t dt + θ(L) 0 e -γt σ(µ t ) dW t ≤ x + ∞ 0 e -γt |µ t | dt + sup T T 0 e -γt σ(µ t ) dW t ,
where the sup is taken over stopping times T . This provides the L-independent bound if it has finite expectation.

The expectation of the first integral is finite, since, by Lemma 8.1,

E ∞ 0 e -γt |µ t | dt ≤ ∞ 0 e -γt H(t) dt < ∞.
Similarly, by Doob's inequality, Itô isometry and Lemma 8.1, we obtain, for some C,

E   sup T T 0 e -γt σ(µ t ) dW t 2   ≤ 2 ∞ 0 e -2γt C 1 + H(t) dt < ∞.
Theorem 3.6. The value function is continuous everywhere.

Proof. Consider a sequence (x n , µ n ) which is non-decreasing in both coordinates and converges to some point (x ∞ , µ ∞ ). The goal is to show that V (x ∞ , µ ∞ )-ε ≤ lim n→∞ V (x n , µ n ) for any ε > 0. For the sake of readability, we introduce some notation: Let θ n (L) be the ruin time of starting in (x n , µ n ) and using the dividend policy L, and let X n,L = X (x n ,µ n ),L be the process associated with the starting point (x n , µ n ) and dividend process L.

Denote by L ∞ an ε-optimal strategy starting in (x ∞ , µ ∞ ). As L ∞ is the only strategy appearing in the first part of the proof, let θ n and X n are shorthand θ n (L ∞ ) and X n,L ∞ respectively. Then, since ∆L

∞ θ n = X n θ n -+ ∆L ∞ θ n -X n θ n -, V (x ∞ , µ ∞ ) -ε ≤ E [0,θ n ) e -rt dL ∞ t + e -rθ n X n θ n + ∆L ∞ θ n -X n θ n -+ (θ n ,θ ∞ ] e -rt dL ∞ t ≤ V (x n , µ n ) + E e -rθ n ∆L ∞ θ n -X n θ n - + E (θ n ,θ ∞ ] e -rt dL ∞ t . ( 8
)
The middle term is needed to cover the case that θ n occurs as a result of a jump in L ∞ . Note that it is non-negative, since either θ n is caused by a jump larger than X n θ n -, or the latter is zero. We want to show that the last two terms tend to zero as n tends to infinity.

By Lebesgue's dominated convergence theorem (see Lemma 8.5),

lim n→∞ E (θ n ,θ ∞ ] e -rt dL ∞ t = E lim n→∞ (θ n ,θ ∞ ] e -rt dL ∞ t . ( 9
)
Note that the middle term is also dominated by an integrable expression, since it is itself dominated by the total discounted payoff of L ∞ . Hence, we may take the limit inside both of the expectations. We will prove that the limits inside the expectations are 0 on the following set:

Ω =    sup L∈A(x ∞ ,µ ∞ ) θ (x ∞ ,µ ∞ ) (L) 0 e -rt dL t < ∞    ∩    E (θ n ,θ ∞ ] e -rt dL ∞ t F θ n ≤ e -rθ n V (X ∞ θ n , µ ∞ θ n ) , ∀n ∈ N    ,
where V denotes the upper semicontinuous envelope of V . Note that by Lemma 8.1 and (7), P (Ω ) = 1. For any ω ∈ Ω , consider the following two cases: First, consider any strictly increasing, divergent subsequence

θ n(k) = θ n(k) (L ∞ )(ω). Then, (θ n(k) ,θ ∞ ] e -rt dL ∞ t (ω) ≤ e -rθ n(k) /2 (θ n(k) ,θ ∞ ] e -rt/2 dL ∞ t (ω) k→∞ ---→ 0,
because ω ∈ Ω ensures that the integral factor is bounded, and the exponential factor converges to 0. Moreover, since θ n(k) is strictly increasing,

k∈N e -rθ n(k) ∆L ∞ θ n(k) (ω) ≤ θ ∞ 0 e -rt dL ∞ t (ω) < ∞, Since V is increasing, it is sufficient to find a bound to µ ∞ θ n(k) (ω). Begin by considering the process M ∞ t = sup 0≤s≤t µ ∞ s . Then, since θ n(k) is a bounded sequence and M ∞ t is continuous, M ∞ θ n(k) (ω) is bounded by some constant C. Therefore, by Theorem 8.4, lim k→∞ V X ∞ θ n(k) (ω), µ ∞ θ n(k) (ω) ≤ lim k→∞ V X ∞ θ n(k) (ω), C = V (0, C) = 0.
By the preceding arguments, it holds that for any bounded subsequence and any divergent subsequence,

e -rθ n ∆L ∞ θ n -X n θ n -+ (θ n ,θ ∞ ] e -rt dL ∞ t (ω)
converges to 0 for every ω ∈ Ω . As a consequence of this, the whole sequence converges to 0, for every ω ∈ Ω , i.e., P -a.s. Returning to [START_REF] Avanzi | On a mean reverting dividend strategy with brownian motion[END_REF], this yields

V (x ∞ , µ ∞ ) -ε ≤ lim n→∞ V (x n , µ n ) ≤ V (x ∞ , µ ∞ ),
by monotonicity. Since this holds for any choice of ε > 0, equality is obtained. Now let (x n , µ n ) be non-increasing in both coordinates and converge to (x ∞ , µ ∞ ). Then, in the same manner as above,

lim n→∞ V (x n , µ n ) -ε ≤ V (x ∞ , µ ∞ ) + E lim n→∞ e -rθ ∞ (L n ) ∆L n θ ∞ (L n ) -X ∞,L n θ ∞ (L n ) + E lim n→∞ (θ ∞ (L n ),θ n (L n )]
e -rt dL n t , for ε-optimal strategies L n starting in (x n , µ n ). By analogous arguments,

lim n→∞ V (x n , µ n ) = V (x ∞ , µ ∞ ).
As a final step, consider an arbitrary convergent sequence (x n , µ n ). By monotonicity,

V inf m≥n x m , inf m≥n µ m ≤ V (x n , µ n ) ≤ V sup m≥n x m , sup m≥n µ m .
Since the sequences (inf m≥n x m , inf m≥n µ m ) and (sup m≥n x m , sup m≥n µ m ) are non-decreasing and non-increasing, respectively, it follows that

lim n→∞ V (x n , µ n ) = V (x ∞ , µ ∞ ),
and V is continuous everywhere.

Comparison Principle

Lemma 8.6. If a function u is a viscosity subsolution to (2), then ũ(x, µ) := e -ηx-ηg(µ) u(x, µ) [START_REF] Barth | A non-stationary model of dividend distribution in a stochastic interest-rate setting[END_REF] is a viscosity subsolution to

min r -ηµ -ηg (µ)κ(µ) -η 2 Σ 11 -η 2 g (µ) 2 Σ 22 -ηg (µ)Σ 22 -2η 2 g (µ)Σ 12 Ṽ -(µ + ηΣ 11 + 2ηg (µ)Σ 12 ) Ṽx -(κ(µ) + ηg (µ)Σ 22 + 2ηΣ 12 ) Ṽµ -Tr ΣD 2 Ṽ , η Ṽ + Ṽx -e -ηx-ηg(µ) = 0, in R >0 × M, (11)
for any given η and g ∈ C 2 (R). A corresponding statement is true for supersolutions.

Proof. Let u be a viscosity subsolution to [START_REF] Albrecher | Risk theory with affine dividend payment strategies[END_REF]. Let φ ∈ C 2 and (x 0 , µ 0 ) be a local maximum of ũφ where (ũφ)(x 0 , µ 0 ) = 0. Finally, define ϕ(x, µ) := e ηx+ηg(µ) φ(x, µ).

Then (x 0 , µ 0 ) is also a local maximum of u -ϕ. Using the viscosity property of u and plugging in ϕ yields the viscosity property for ũ and the transformed equation [START_REF] Bolton | Market timing, investment, and risk management[END_REF].

Lemma 8.7. The parameter η and function g can be chosen in such a way that the coefficient of Ṽ in ( 11) is strictly positive.

Proof. Fix any large y > 0 and let g be a twice differentiable function with

g (µ) = -η -, if µ < -y, η + , if µ > y,
for strictly positive constants η -and η + as well as µ ∈ [-y, y] c . 14 For any such choice, the coefficient is strictly positive in [-y, y], provided η is small enough. Moreover, with our choice of g, the condition reduces to

r -η(µ + η ± κ(µ)) -η 2 (Σ 11 + η 2 ± Σ 22 + 2η ± Σ 12 ) > 0, in [-y, y] c .
Note that the last two terms both grow at most linearly in µ, by the growth conditions on κ, σ, and σ. Furthermore, since κ is negative and linearly growing for large (positive) µ, we can choose η + such that -(µ + η + κ(µ)) is linearly increasing. Then, for sufficiently small η, the whole expression is increasing, for large µ.

Similarly, if both η -and η are chosen sufficiently small, the same is true also for large, negative µ. Hence, for such a choice of η and g, the coefficient is strictly positive. Remark 8.8. Assumption 3.2 could possibly be generalized by finding strict supersolutions to the equation

r -ηµ -ηg (µ)κ(µ) -η 2 Σ 11 -η 2 g (µ) 2 Σ 22 -ηg (µ)Σ 22 -2η 2 g (µ)Σ 12 = 0,
since this is sufficient for the transformed equation to be proper. Theorem 3.7 (Comparison). Let u and v be upper and lower semicontinuous, polynomially growing viscosity sub-and supersolutions of (2). Then u ≤ v for (x, µ) ∈ 0 × M implies that u ≤ v everywhere in O := R ≥0 × M.

Proof of Theorem 3.7. Comparison is shown for the transformed DPE [START_REF] Bolton | Market timing, investment, and risk management[END_REF] with η chosen as in Lemma 8.7. Since the transformation (10) is sign-preserving, this is sufficient to establish comparison for (2) thanks to Lemma 8.6. For the sake of simpler presentation later on, [START_REF] Bolton | Market timing, investment, and risk management[END_REF] is shortened to min{f Ṽ -f x Ṽx -f µ Ṽµ -Tr ΣD 2 Ṽ , η Ṽ + Ṽx -e -ηx-ηg(µ) } = 0.

Note that the coefficients f x , and f µ are locally Lipschitz continuous on the interior of the domain, and the coefficient f is continuous. Denote by ũ and ṽ the functions transformed as in [START_REF] Barth | A non-stationary model of dividend distribution in a stochastic interest-rate setting[END_REF]. We note that these tend to 0 at infinity and that ũ as well as ṽ are bounded. We distinguish between two cases to argue that, without loss of generality, we may assume that the maximum of ũṽ is attained in the interior O o :

1. The function ũṽ attains a maximum in [0, ∞) × M o . If the maximum is at x = 0, we are done. Otherwise, the maximum is attained in the interior O o .

2. There exists a maximizing sequence converging to a point (x, μ) in [0, ∞) × ∂M. Without loss of generality, assume that μ is a lower boundary point. An upper boundary point is handled analogously. The method employed here originates in [START_REF] Lisa | Uniqueness and comparison properties of the viscosity solution to some singular HJB equations[END_REF].

For some small γ > 0, let N = {(x, µ) : µ -μ < γ} ∩ ([0, ∞) × M) and define Note that by Assumption 3.3, C < ∞. It is easily verified that h > 0, h(µ) → ∞ as µ → μ, and that

f µ h + σ2 2 h ≤ 0, in N.
Hence, wδ := ũ -δh is also a subsolution in N .

Let (x n , µ n ) → (x, μ) be the maximizing sequence, and set δ = δ n = 1/nh(µ n ). Then δ → 0 as µ → μ. Thus, sup By the preceding argument, we may assume that ũṽ attains local maximum (x 0 , µ 0 ) ∈ O o . Let N ⊆ N ⊆ O be two neighborhoods of (x 0 , µ 0 ) in which (x 0 , µ 0 ) is a maximum and with N ⊆ N . For all > 0, the function Φ (x, µ, y, ν) := ũ(x, µ) -ṽ(y, ν) -1 2 |x -y| 2 +|µ -ν| 2 -(x, µ) -(x 0 , µ 0 )

N (ũ -ṽ) ≥ sup N Ψ δ ≥ Ψ δ (x n , µ n ) = (ũ -ṽ)(x n , µ n ) -1/n,
4 2
has a maximum in N × N that we denote by (x , µ , y , ν ). In particular as → 0, the sequence converges along a subsequence. From the construction of Φ it follows that 1 2 |x -y | 2 +|µ -ν | 2 ≤ ũ(x , µ ) -ṽ(y , ν ) -max N (ũṽ).

Observing that the superior limit of the right-hand side is bounded from above by 0 yields lim sup In particular, X ≤ Y + o(1) as → 0. Using the viscosity property of ũ and ṽ yields min f (µ )ũ(x , µ ) -f x (µ )

x -y -f µ (µ ) µ -ν -Tr Σ(µ ) X , ηũ(x , µ ) + x -y -e -ηx -ηg(µ ) ≤ 0, and min f (ν )ṽ(y , ν ) -f x (ν )

x -y -f µ (ν ) µ -ν -Tr Σ(ν ) Ỹ , ηṽ(y , ν ) + x -y -e -ηy -ηg(ν

) ≥ 0. ( 12
)
The rest of the proof is dividend into two cases, depending on whether f (µ )ũ(x , µ ) -f x (µ )

x -y -f µ (µ ) µ -ν -Tr Σ(µ ) X ≤ 0 [START_REF] Cadenillas | Optimal dividend policy with mean-reverting cash reservoir[END_REF] or ηũ(x , µ ) + x -y -e -ηx -ηg(µ ) ≤ 0. ( 14)

Case 1. Assume [START_REF] Cadenillas | Optimal dividend policy with mean-reverting cash reservoir[END_REF]. Using [START_REF] Bouchard | Weak dynamic programming principle for viscosity solutions[END_REF] we arrive at f (µ )(ũ(x , µ ) -ṽ(y , ν )) + (f (µ ) -f (ν ))ṽ(y , ν )

-(f x (µ ) -f x (ν )) x -y -(f µ (µ ) -f µ (ν )) µ -ν -Tr(Σ(µ ) -Σ(ν ))Y ≤ Tr Σ(µ )(X -Y ) ∈ o(1).
Using the (local) Lipschitz continuity of the coefficients as well as the quadratic convergence rates of x -y and µ -ν , we find that f (µ 0 )(ũṽ)(x 0 , µ 0 ) = lim sup →0 f (µ )(ũ(x , µ ) -ṽ(y , ν )) ≤ 0.

We conclude that 0 ≥ (ũṽ)(x 0 , µ 0 ).

Case 2. Assume [START_REF] Cai | Optimal dividends in an Ornstein-Uhlenbeck type model with credit and debit interest[END_REF]. Using (12) yields η(ũ(x , µ ) -ṽ(y , ν )) ≤ e -ηx -ηg(µ ) -e -ηy -ηg(ν ) .

Once again we use the convergence results, and once again we conclude that 0 ≥ (ũṽ)(x 0 , µ 0 ) = max O (ũṽ).

The inequality ũ ≤ ṽ holds at any local maximum. Moreover, as mentioned in the beginning of the proof, we may assume that ũṽ is attains its maximum on the interior. The theorem statement follows from the fact that ũ ≤ ṽ ⇐⇒ u ≤ v.

Figure 1 :

 1 Figure1: The figure shows the three regimes. In the region between the lines x and x the all incoming profits are retained. When the cash reserves fall to x, the firm liquidates, whereas when it increases to x, dividends are paid out according to the local time at the boundary, thus reflecting the cash reserves process. In the region above x, a lump sum of the excess of x is paid immediately. Finally, when µ ≤ µ * , liquidation is optimal at all cash levels.

Figure 4 :

 4 Figure 4: Comparative statics. Apart from for the parameter being varied, the chosen values were r = 0.05, k = 0.5, μ = 0.15, σ = 0.3, σ = 0.1, and ρ = 0. The parameter varied is indicated in the respective figure. The values considered were k = 0.25, 0.5, 1.0, μ = 0.0, 0.15, 0.3, σ = 0.1, 0.2, 0.3, 0.4, 0.5, σ = 0.1, 0.2, 0.3, 0.4, andρ= -1.0, -0.5, 0.0, 0.5, 1.0. To address the effect of the boundary conditions, most calculations were run on a larger domain than plotted here. The lower boundary for ρ = -1.0 displayed signs of numerical instability around the origin and has therefore not been plotted in this region.

Figure 6 :

 6 Figure 6: In the left figure, proportional issuance costs start at 34 % for low µ and decaying to 25 %. Equity is issued according to local a time at the boundary x = 0 where otherwise ruin would occur, and no equity is issued below i = -1.0953. In the right figure fixed costs are present, starting at 0.14 decaying to 0.06 as a function of µ. Again, equity is only issued at the boundary, and no equity is issued below i = -0.7493. The dashed white line indicates the cash reserve level after issuance, i.e., how much equity was issued.

Figure 7 :

 7 Figure 7: When issuance costs are sufficiently high for negative µ, it is optimal to issue equity away from the boundary x = 0.

Figure 8 :

 8 Figure 8: The figure on the left shows the model which allows gambling for resurrection.The figure on the right shows the model without gambling in gray, overlaid by the free boundaries of the gambling model in solid lines. When gambling is allowed, voluntary liquidation is no longer optimal in the 'band region'. This is because entering a 'lottery' gives a chance of reaching a higher point in the no activity region, thus concavifying the problem.

Ψ

  δ (x, µ) = ũ(x, µ) -ṽ(x, µ) -δh(µ), (x, µ) ∈ N, for δ ≥ 0 andh(µ) = μ+γ µ e C(ξ-μ) (ξμ) -1 dξ, µ < γ + μ, with C = sup 1 µ -μ -2f µ (µ) σ(µ) 2 : 0 < µ -μ < γ .

  ṽ) .Moreover, Ψ δ attains a maximum (x δ , µ δ ) ∈ N . For sufficiently small δ > 0, a maximum is attained in the interior, or otherwise a maximum of ũṽ is attainedfor µ = μ + γ ∈ O o . It follows that sup N (ũṽ) ≥ (ũṽ)(x δ , µ δ ) = sup N Ψ δ + δh(µ δ ) ≥ sup N Ψ δ , so δh(µ δ ) → 0. If max N ( wδṽ) ≤ 0, sup O (ũṽ) = lim δ→0 max N ( wδṽ) ≤ 0follows. It therefore leads to no loss of generality to assume that ũṽ attains a maximum in O o .

→0 1 2 2 2

 22 |x -y | 2 +|µ -ν | 2 ≤ 0.This estimate is used later in the proof. Moreover, (x , µ ) → (x 0 , µ 0 ), which means they are local maxima in N .By the Crandall-Ishii lemma, there exist matrices X and Y such that(p , X ) ∈ J2,+ u(x , µ ), (p , Y ) ∈ J2,v(y , ν ) and X ≤ Y + O 1 (x, µ) -(x 0 , µ 0 ) + (x, µ) -(x 0 , µ 0 ) -y , µ -ν ).

Similar properties have been observed by Anderson and Carverhill[START_REF] Carverhill | Corporate liquidity and capital structure[END_REF] and Murto and Terviö[START_REF] Murto | Exit options and dividend policy under liquidity constraints[END_REF].

We assume that shareholders can diversify their portfolios and that the firm under study is small, so that its decisions do not alter the risk-adjusted measure.

The process L must be nondecreasing because the limited liability of shareholders implies that dLt cannot be negative. Section 6 considers the case when new shares can be issued at a cost, allowing to inject new cash into the firm.

Shareholders cannot distribute more dividends than available cash reserves. Otherwise this would constitute fraudulent bankruptcy.

Although the model allows dividend payments with infinite 'frequency' of very general type, we argue that it is not less realistic than the absolutely continuous case where the 'frequency' is also infinite, but interpreted as a rate. Indeed, as suggested by (2) in Section 3.4 and exploited in Section 4, this model can be considered the limit when there is no bound on the dividend rate.

Note that the policy iteration scheme halts even for τ = 0.

Since we solve in a bounded domain, some care has to be taken at the boundaries. However, thanks to the condition given on κ, it is natural to impose a reflecting boundary along the µ-directions, provided the domain is large enough. Moreover, the (approximately) optimal policy is expected to naturally reflect at the upper x-boundary, provided the domain is large enough to contain the no-dividend region. For these reasons, the precise choice of boundary condition is of relatively small importance, if D is chosen appropriately.

Intel Core i7-7600U, 1866MHz LPDDR3.

For the left solution in Figure3(same as 'default' values from Figure4), the runtime was just short of 8 minutes on a

× 1000 grid without parallelization. A more modest grid size of 300 × 300 runs in 7 seconds on the same hardware. All computations were generated with a starting point with 'no information', i.e., identically zero.

This reflects the fact that a more profitable company (higher µ) typically has better access to financial markets.

One example of such behavior by FedEx is described by Frock[START_REF] Frock | Changing how the world does business[END_REF] Chapter 18], one of the firm's co-founders.

One possible interpretation of g k is to think of it as a forward contract. More precisely, it should be interpreted as the limit when the forward contract can be entered with arbitrarily short maturity.

Recall that (µ 0 t ) t≥0 is the process started in 0.

This can be done by a mollification argument on g .

The first and third authors were partly supported by the ETH Foundation, the Swiss Finance Institute, and Swiss National Foundation grant SNF 200020_172815. The second author acknowledges support by the SCOR.