All code and checkpoints are provided in our GitHub repository
333333https://github.com/LAION-AI/laionide.

We finetune LAIONIDE-v1 first, using an NVIDIA RTX 2070 Super GPU. Due to the
8GB VRAM constrain posed by the RTX 2070, we only use a batch size of 1. This
initial checkpoint is provided as LAIONIDE-v1.

To accelerate training, LAIONIDE-v2 is finetuned from LAIONIDE-v1 using an
8xA100 pod from Stability. LAIONIDE-v2 sees roughly 25 million shuffled text-
image pairs from LAION-2B. Some data is filtered during finetuning: if a text-
image pair’s ‘nsfw’ metadata has a value of ’NSFW’ or ’LIKELY’, we remove the
sample. We remove any pairs where the language code is not ‘en’, to focus the
model on english. We remove any images with an aspect ratio greater than 1.3
or less than 0.8. We remove all images where the smallest side is less than
256 pixels in length. Finally, we perform a sub-string search against a list
of common slurs, and remove captions containing some slurs, although this is
far from comprehensive.

To reduce the number of watermarks output by LAIONIDE-v2, we finetune to
create LAIONIDE-v3. It sees roughly 1 million text-image pairs from a shuffled
mixture of datasets: COCO 2017’s training set (MS-COCO), Visual Genome, Open
Images “Localized Annotations” and LAION-5B [44, 36, 39, 55]. We find this
reduces the number of watermarks output compared to LAIONIDE-V2 during manual
analysis.

To improve inference time we make use of the pseudo linear multi-step
diffusion sampling method from Liu et al. [45] as implemented by Katherine
Crowson.

Figure 14: Comparison of GLIDE and LAIONIDE-v3 Generations. We compare the
output of GLIDE and our LAIONIDE-v3 across three different prompts. The top
row of each section depicts GLIDE’s results, while the bottom row depicts
LAIONIDE-v3’s resutls.

We compare some evaluations from OpenAI’s released filtered checkpoint and the
one we train. Those can be found at the following link:
https://wandb.ai/afiaka87/glide_compare/reports/laionide-v3-benchmark--
VmlldzoxNTg3MTkz

###  F.2 Stable Diffusion

Stable Diffusion is a generative latent diffusion model trained on various
LAION-5B subsets:

  * •

237,000 steps at 256x256 on LAION-2B-en

  * •

194,000 steps at 512x512 on laion-high-resolution

  * •

515,000 steps at 512x512 on laion-improved-aesthetics

  * •

390,000 steps at 512x512 on laion-improved-aesthetics with 10% dropping of the
text conditioning

Here we show representative generated samples for an artistic (Fig. 15) and a
photorealistic (Fig. 16) image. For more technical details, we refer to the
Stable Diffusion github repository343434https://github.com/CompVis/stable-
diffusion/.

Figure 15: "The sigil of water by Gerardo Dottori, oil on canvas"
Generated by Stable Diffusion Figure 16: "A wide river in the jungle, Provia,
Velvia"
Generated by Stable Diffusion

##  Appendix G Further Discussion on Safety and Ethics

###  G.1 Privacy

As any other dataset of links obtained from Common Crawl that gathers content
from publicly available Internet, LAION-5B can contain links to images with
personal information, like to photos of faces, medical images or other
personal related content. Tools like CLIP retrieval (see Appendix Section C.4
for more details) provided by LAION make it possible for the users to find out
by text or image prompt whether any of the links crawled for LAION-5B point to
their personal data and if yes, where on the public internet the corresponding
data is hosted. Thus, for the first time, the broad public can take a look
inside of a typical large-scale crawled dataset and become aware of the
possible content of datasets that can be used for model training. As most of
institutions and companies use same crawling procedures to obtain their closed
datasets, we thus also hope to increase awareness for the risks which publicly
available data can be used and exploited by third parties who do not disclose
their data collection and application procedures. At the same time,
researchers can access LAION-5B to study privacy related issues in such data
and develop measures that increase safety of applications arising from
training models on data crawled from public internet.

As LAION tools empower people to discover problematic personal or copyrighted
content available in the public internet, the users can also initiate
procedures of removing corresponding images from the public internet by
contacting the responsible host providers that have published those images
following the links provided in LAION-5B. In addition, we also provide a
contact form on our website 353535https://laion.ai/dataset-requests/ where
requests for removal or blacklisting of the corresponding links from LAION-5B
can be processed.

Further, to mitigate privacy concerns, there exist methods that allow personal
human attributes like faces to be obfuscated [87] or generated [48] and thus
made anonymous, without hurting the quality and richness of learned
representations. Especially generation based methods can be applied to open
data like LAION-5B to create training datasets that do not contain any private
facial data, while still allowing to learn proper face representation during
training. This line of work is currently in progress in LAION community.

###  G.2 Potential Biases Induced by CLIP Filtering

Unknown initial dataset. The CLIP model in itself introduces a bias, which
cannot be trivially assessed, as the underlying dataset on which the model was
trained is not openly accessible. With the release of a large openly
accessible image-text dataset, we offer a starting point in the open auditing
of contrastive image-text models like CLIP.

Selection heuristic based on cosine similarity. As noted by [6], cosine
similarity is only a heuristic that also may lead to suboptimal guidance for
dataset filtering. The work showed examples in which captions with malignant
descriptions obtain a higher similarity over a benign description. During
CLIP’s training, the cosine similarity only acted as a logit to represent the
likelihood of a given image-text pairing. It fails to encapsulate the nuance
and rich semantic and contextual meaning that the image or language might
contain. By using cosine similarity as a ground for filtering, the dataset
might exacerbate those biases already contained by CLIP.

## Author contributions

  * •

Christoph Schuhmann: He led this project and built POCs for most of its
components including clip filtering, the safety model, the watermark model and
the BLIP inference tuning project.

  * •

Richard Vencu: System architecture and download script optimizations, GPU
assisted filtering. Set up the AWS infrastructure.

  * •

Romain Beaumont: Guidance on scaling for the Common Crawl filtering pipeline.
Built and ran the dataset preparation pipeline: pyspark deduplication job,
img2dataset, CLIP inference, autofaiss, safety tags.

  * •

Clayton Mullis: DALLE-pytorch training/analysis, WDS filtering, trained
generative models (LAIONIDE) using LAION-5B.

  * •

Ludwig Schmidt: Provided advice on experiment design, scaling, ethical and
social content, and paper writing.

  * •

Jenia Jitsev: scientific organization & manuscript writing, ethical and social
content, experiments planning and design, compute and storage resource
acquisition, general supervision.

  * •

Robert Kaczmarczyk: Established WDS architecture, performed DALL-E training
runs, balancing calculation, sample (NSFW, watermark, caption quality)
annotation, manuscript writing coordination, supervision and revision.

  * •

Theo Coombes: He was one of our first contributors & build the first versions
of our worker swarm system. Without his enthusiasm this project might never
have taken off.

  * •

Aarush Katta: Trained the watermark model.

  * •

Cade Gordon: Ran distributed inference for the watermark tags, trained the
CLIP models on JUWELS Booster, and led the paper writing.

  * •

Mehdi Cherti: Evaluated the CLIP-B/32, B/16, B/16+ and L/14 model, performed
debugging of distributed training, executed experiments on JUWELS Booster,
performed results collection, distillation and analysis, manuscript writing.

  * •

Ross Wightman: Ross debugged & trained the CLIP-B/32, B/16, B/16+ and L/14
model and executed experiments on JUWELS Booster.

  * •

Katherine Crowson: Contributed to development of latent diffusion and stable
diffusion. Fine-tuned generative models on subsets of LAION-5B.

  * •

Patrick Schramowski: Patrick helped with NSFW and otherwise inappropriate
content tagging. Further, he wrote the corresponding parts as well as the
ethical and social content.

  * •

Srivatsa Kundurthy: Co-wrote the datasheet, researched usage cases & related
works, trained face classifier and developed visualizations.

  * •

Mitchell Wortsman Initially created openCLIP, provided insights on scaling,
performed experiments evaluating few-shot fine-tuning performance and
robustness on ImageNet and other downstream datasets

## Acknowledgments details

We want to thank our open community for their continuous efforts for openly
available datasets and models. Without the broad support from the community,
especially in the early crawling days with decentralized compute support, this
project would not have been possible.

Moreover, the following organizations and persons contributed to this project:

  * •

Aran Komatsuzaki: He led the initial crawling@home image-text-pair dataset
building project (the predecessor of LAION-400M).

  * •

Andreas Köpf: He conducted the hyperparameter search for the inference
strategies with the BLIP image-captioning model.

  * •

Bokai Yu: Accomplished most of the work to make the knn index building tool
autofaiss work in a distributed setting.

  * •

John David Pressman: Provided aestethic dataset for creating aestethic LAION
subset to fine-tune GLIDE.

  * •

Natalie Parde Assisted in manuscript revisions.

  * •

Gabriel Ilharco Initially created OpenCLIP and gave valuable insights on
scaling.

  * •

Fredde Frallan Provided zero-shot retrieval results.

  * •

Hugging Face: provided financial and computing support, helped hosting
LAION-5B as well as related subsets.

  * •

Emad Mostaque (Stability AI): provided financial and computation support for
open-source datasets and models.


# Systems of fully nonlinear parabolic obstacle problems
with Neumann boundary conditions

Niklas L.P. Lundström, Marcus Olofsson Department of Mathematics and
Mathematical Statistics, Umeå University, SE-901 87 Umeå, Sweden. E-mail:
<EMAIL_ADDRESS><EMAIL_ADDRESS>
###### Abstract

We prove the existence of a unique viscosity solution to certain systems of
fully nonlinear parabolic partial differential equations with interconnected
obstacles in the setting of Neumann boundary conditions. The method of proof
builds on the classical viscosity solution technique adapted to the setting of
interconnected obstacles and construction of explicit viscosity sub- and
supersolutions as bounds for Perron’s method. Our motivation stems from so
called optimal switching problems on bounded domains.

Keywords: Optimal switching; multi modes switching; constraints; fully
nonlinear PDE; Neumann boundary condition; viscosity solution; barrier

Mathematics Subject Classification: 35B50, 35D40, 35Q93, 49L25.

##  1 Introduction

This note deals with existence and uniqueness of viscosity solutions of
systems of non-linear partial differential equations (PDE) with interconnected
obstacles and Neumann boundary conditions. Let $\Omega\subset\mathbb{R}^{n}$
be a domain, i.e. an open connected set, and let $i\in\\{1,2,...,m\\}$ for
some positive integer $m$. The problem considered can in general be stated as

$\displaystyle\min\left\\{\partial_{t}u_{i}\left(t,x\right)+{F}_{i}\left(t,x,u_{i}(t,x),Du_{i},D^{2}u_{i}\right),u_{i}\left(t,x\right)-\mathcal{M}_{i}u(t,x)\right\\}$
$\displaystyle=0$ $\displaystyle\text{in}\quad(0,T)\times\Omega,$
$\displaystyle u_{i}(0,x)$ $\displaystyle=g_{i}\left(x\right)$
$\displaystyle\text{on}\quad\bar{\Omega},$ (BVP) $\displaystyle
B_{i}\left(t,x,u_{i},Du_{i}\right)$ $\displaystyle=0$
$\displaystyle\text{on}\quad(0,T)\times\partial\Omega.$

The solution is a vector-valued function $u:=(u_{1},u_{2},\dots,u_{m})$ where
the components are interconnected through the obstacle $\mathcal{M}_{\cdot}$
in the sense that component $i$ lies above the obstacle

$\mathcal{M}_{i}u(t,x)=\max_{i\neq j}\\{u_{j}(t,x)-c_{ij}(t,x)\\},$

which itself depends on all other components. Here and in the following,
$Du_{i}\in\mathbb{R}^{n}$ and $D^{2}u_{i}\in\mathcal{S}^{n}$
($\mathcal{S}^{n}$ being the set of symmetric $n\times n$ matrices) denote the
gradient and Hessian matrix of $u_{i}$ w.r.t. $x$.

In the standard setting of a single PDE without obstacle, the well-renowned
paper Crandall-Ishii-Lions [10] proves existence and uniqueness of viscosity
solutions of fully non-linear elliptic PDEs with Neumann boundary conditions
in smooth domains satisfying an exterior ball condition. Dupuis-Ishii [6, 7]
consider more general domains such as non-smooth boundaries and domains with
corners, and Barles [3] proved a comparison principle and existence of unique
solutions to degenerate elliptic and parabolic boundary value problems with
non-linear Neumann type boundary conditions in bounded domains with
$W^{3,\infty}$-boundary. Ishii and Sato [15] proved similar theorems for
boundary value problems for some singular degenerate parabolic partial
differential equations with non-linear oblique derivative boundary conditions
in bounded $C^{1}$-domains. Further, in bounded domains with
$W^{3,\infty}$-boundary, Bourgoing [4] considered singular degenerate
parabolic equations and equations having $L^{1}$-dependence in time.
Lundström-Önskog [22] recently extended parts of [6] by establishing existence
and uniqueness of viscosity solutions to a general parabolic PDE in non-
smooth, time-dependent domains.

For systems of variational inequalities with interconnected obstacles as in
(1), the literature on fully nonlinear PDEs on bounded spatial domains
$\Omega$ with boundary conditions is, to the authors’ knowledge, scarce.
Instead much focus has been directed to unbounded domains (essentially
$\Omega\equiv\mathbb{R}^{n}$) and often linear PDEs. In this setting the
literature is, on the contrary, rather rich, see, e.g., El–Asri-Hamadene [8],
Djehiche-Hamadene-Popier [11], Hu-Tang [13], Biswas-Jakobsen-Karlsen [4],
Hamadene-Morlais [12], Lundström-Nyström-Olofsson [18, 19], Lundström-
Olofsson-Önskog [20], Fuhrman-Morlais [9], Reisinger-Zhang [23] and the many
references listed therein. Extensions to more general operators have been
studied recently in Klimsiak [17]. A reason for this large amount of interest
is the close connection to stochastic optimization and so called “optimal
switching” problems. Under assumptions, the solution to (1) then represents
the value function of an optimal switching problem in which component $i$ of
the underlying stochastic process has the second order operator $F_{i}$ as
infinitesimal generator. With this interpretation, the domain $\Omega$
represents the constraints put on the underlying stochastic process and, in
particular, $\Omega\equiv\mathbb{R}^{n}$ means no constraints. However, when
studying applications of optimal switching theory, one can very easily think
of examples where constraints are not only natural, but also necessary for the
model to be meaningful. For example, consider a hydro power plant with a dam
in which the underlying (stochastic) process $X_{t}$ represents the amount of
water currently available in the dam. Then, naturally, the process can only
take values between $0$ and some $X_{max}$, the latter being the capacity of
the dam. (In case the power plant is of run-of-river type, i.e., has no dam,
the problem can be reduced to $\Omega=\mathbb{R}^{n}$ and an application of
the theory in this setting was recently studied in Lundström-Olofsson-Önskog
[21].) When the dam is full, additional increase of water must be spilled,
keeping the amount of water in the dam constant. Such situation may be
modelled through a reflection of the underlying stochastic process $X_{t}$. If
this reflection is assumed in the normal direction, then one obtains a Neumann
boundary conditions, i.e.

$\displaystyle B_{i}(t,x,u_{i},Du_{i})=\langle n(x),Du_{i}\rangle-f_{i}(x)=0$
(BC)

where $n(x)$ is the normal of $\partial\Omega$ at $x$. A more general
reflection model puts us in the “oblique derivative” problem in which $n(x)$
in (BC) should be replaced by $\nu(x)$, a vector field satisfying
$\langle\nu(x),n(x)\rangle>0$ on $\partial\Omega$. The Dirichlet setting,
which is studied in Barkhudaryan-Gomes-Shahgholian-Salehi [2], can be given a
similar interpretation but then in the sense that the game “ends” when the
process hits the boundary $\partial\Omega$.

Optimal switching problems with reflection is not as well-studied as the non-
reflected counterpart, and the ink to systems like (1) is in general not yet
rigorously established. However, given the close connection to real-world
applications and the growing interest of optimal switching problems under
constraints, see, e.g., Kharroubi [16], we expect this to change and a
thorough analysis of the related PDE-theory on bounded domains is motivated.
Moreover, although the study is motivated by applications, the results are of
independent mathematical interest, enlarging the class of problem for which
the viscosity theory is fully investigated.

##  2 Mathematical problem formulation, assumptions and main results

###  2.1 Notation and assumptions

We let $\Omega\subset\mathbb{R}^{n}$ be an open connected bounded set with
closure $\bar{\Omega}$ and boundary
$\partial\Omega:=\bar{\Omega}\setminus\Omega$ and consider $t\in[0,T]$. We
denote by $\mathcal{C}^{\alpha,\beta}$ the class of functions which are
$\alpha$ and $\beta$ times continuously differentiable on
$[0,T]\times\bar{\Omega}$ w.r.t. the first (time $t$) and second (space $x$)
variable, respectively. If $f(\cdot)$ only depends on the spatial variable we
simply write $f\in\mathcal{C}^{\beta}$. We assume that

$\mbox{$\partial\Omega\in\mathcal{C}^{1}$ and satisfies the exterior ball
condition},$ (D1)

i.e., that $\partial\Omega$ is once continuously differentiable and that

$\mbox{for every $\hat{x}\in\partial\Omega$ there exist $x$ and $r$ s.t.
$B(x,r)\not\subset\Omega$ and $\hat{x}\in\partial B(x,r)$},$

where $B(x,r):=\\{y:|y-x|<r\\}$. When establishing existence, we need to
strengthen (D1) to allow also for an interior ball. Requiring both exterior
and interior ball is equivalent to

$\mbox{$\partial\Omega\in\mathcal{C}^{1}$ with Lipschitz continuous
derivative},$ (D1*)

see Aikawa-Kilpeläinen-Shanmugalingam-Zhong [1, Lemma 2.2].

We assume that
$F_{i}(t,x,r,p,X):[0,T]\times\bar{\Omega}\times\mathbb{R}\times\mathbb{R}^{n}\times\mathcal{S}^{n}\to\mathbb{R}$
is a continuous function satisfying

$\displaystyle\quad r\mapsto F_{i}(t,x,r,p,X)-\lambda\,r\,\mbox{is non-
decreasing for some $\lambda\in\mathbb{R}$},$ (F1)
$|F_{i}(t,x,r,p,X)-F_{i}(t,x,r,q,Y)|\leq\omega(|p-q|+||X-Y||)$ for some
$\omega:[0,\infty)\to[0,\infty)$ with $\omega(0+)=0$ (F2)

and that

$F_{i}(t,y,r,p,Y)-F_{i}(t,x,r,p,X)\leq\omega\left(\frac{1}{\epsilon}|x-y|^{2}+|x-y|(|p|+1)\right)$
(F3)

for every $t\in[0,T)$ fixed and whenever

$\left(\begin{matrix}X&0\\\
0&-Y\end{matrix}\right)\leq\frac{3}{\epsilon}\left(\begin{matrix}I&-I\\\
-I&I\end{matrix}\right),$

where $I\equiv I^{n}$ denotes the $n\times n$ identity matrix. Note that these
assumptions on $F_{i}$ imply degenerate ellipticity.

Regarding the boundary condition $B_{i}$, we assume that

$\displaystyle B_{i}(t,x,r,p):=\langle n(x),p\rangle+f_{i}(t,x,r)$ where
$n(x)$ is the exterior unit normal at $x$ and $f_{i}$ is a continuous
function, non-decreasing in $r$ for every $(t,x)\in(0,T)\times\partial\Omega$.
(BC1)

Last, we assume that the obstacle functions $c_{ij}(t,x)$ satisfy

$\displaystyle(i)$
$\displaystyle\quad\mbox{$c_{ij}(t,x)\in\mathcal{C}^{1,2}$},$
$\displaystyle(ii)$ $\displaystyle\quad c_{i,i}(t,x)=0\mbox{ for each
$i\in\\{1,\dots,m\\}$},$ (O1)

and that the so called “no-loop”-condition holds;

for any sequence of indices $i_{1}$,…, $i_{k}$, $i_{j}\in\\{1,\dots,m\\}$ for
each $j\in\\{1,\dots,k\\}$, $\displaystyle\quad\mbox{we have
$c_{i_{1},i_{2}}(t,x)+c_{i_{2},i_{3}}(t,x)+\dots+c_{i_{k-1},i_{k}}(t,x)+c_{i_{k},i_{1}}(t,x)>0$},$
$\displaystyle\quad\mbox{for all $(t,x)\in[0,T]\times\bar{\Omega}$}.$ (O2)

As with D1, we need to strengthen the assumption on the obstacle slightly to
prove existence. In particular, we then also demand that

$c_{ij}(t,x)+c_{jk}(t,x)\geq c_{ik}(t,x)\quad\mbox{for all
$i,j,k\in\\{1,2,\dots,n\\}$}$ (O3)

which is an additional structural condition compared to $\eqref{ass:O2}$.

Last, we require that the initial data is continuous and compatible with the
obstacle functions, in particular that

$g_{i}(x)\geq g_{j}(x)-c_{ij}(0,x)$ for any $i,j\in\\{1,\dots,m\\}$. (I1)

###### Remark 2.1

In the parabolic setting studied here, it is a standard task to show that one
can assume $\lambda>0$ in (F1) w.l.o.g. Indeed, if $\lambda\leq 0$, then for
$\bar{\lambda}<\lambda$, $u(t,x)$ is a solution to (1) if and only if
$e^{\bar{\lambda}t}u(t,x)$ is a solution to (1) with $F_{i}$ and $f_{i}$
replaced by

$-\bar{\lambda}r+e^{\bar{\lambda}t}F_{i}(t,x,e^{-\bar{\lambda}t}r,e^{-\bar{\lambda}t}p,e^{-\bar{\lambda}t}X)\quad\text{and}\quad
e^{\bar{\lambda}t}f_{i}(t,x,e^{-\bar{\lambda}t}r),$

and with $c_{ij}$ similarly scaled. The function to the left in the above
display is strictly increasing and hence satisfies $\eqref{ass:F1}$ with
$\lambda$ positive. A consequence of this is that we may as well assume that
$F_{i}$ is strictly increasing in $r$ and that there exists $\gamma>0$ s.t.

$\gamma(s-r)\leq F_{i}(t,x,s,p,X)-F_{i}(t,x,r,p,X).$ (F1*)

We are looking for solutions in the viscosity sense and will use the classical
definitions of (parabolic) sub- and superjets, provided here for convenience.

######  Definition 2.2 (Definition (8.1) of [10])

For $(\hat{t},\hat{x})\in(0,T)\times\mathcal{O}$, the triplet
$(a,p,X)\in\mathbb{R}\times\mathbb{R}^{n}\times\mathcal{S}^{n}$ lies in the
parabolic superjet of $u$ at $(\hat{t},\hat{x})$, written
$(a,p,X)\in\mathcal{P}^{2,+}_{\mathcal{O}}u(\hat{t},\hat{x})$, if

$u(t,x)\leq u(\hat{t},\hat{x})+a(t-\hat{t})+\langle
p,x-\hat{x}\rangle+\frac{1}{2}\langle
X(x-\hat{x}),x-\hat{x}\rangle+o(|t-\hat{t}|+|x-\hat{x}|^{2})$

as $(0,T)\times\mathcal{O}\ni(t,x)\to(\hat{t},\hat{x})$. Analogously, the
parabolic subjet is defined by
$\mathcal{P}^{2,-}_{\mathcal{O}}u(\hat{t},\hat{x}):=-\mathcal{P}^{2,+}_{\mathcal{O}}-u(\hat{t},\hat{x})$.

The closure of $\mathcal{P}^{2,\cdot}_{\mathcal{O}}u(\hat{t},\hat{x})$,
denoted $\bar{\mathcal{P}}^{2,\cdot}_{\mathcal{O}}u(\hat{t},\hat{x})$, is
defined as

$\displaystyle\bar{\mathcal{P}}^{2,\cdot}_{\mathcal{O}}u(\hat{t},\hat{x}):=$
$\displaystyle\\{(a,p,X)\in\mathbb{R}\times\mathbb{R}^{n}\times\mathcal{S}^{n}:\exists((t_{n},x_{n}),p_{n},X_{n})\in\bar{\Omega}\times\mathbb{R}^{n}\times\mathcal{S}^{n}$
$\displaystyle\mbox{s.t.
}(a_{n},p_{n},X_{n})\in\mathcal{P}^{2,\cdot}_{\mathcal{O}}u(t_{n},x_{n})\mbox{
and
}(t_{n},x_{n},u(t_{n},x_{n}),a_{n},p_{n},X_{n})\to(\hat{t},\hat{x},u(\hat{t},\hat{x}),a,p,X)\\}.$

###### Definition 2.3

A function $u=(u_{1},\dots,u_{m})\in USC(\Omega_{p})$ is a viscosity
subsolution to (1) if, for all $i\in\\{1,\dots,m\\}$,

$\displaystyle(i)$
$\min\left\\{a+{F_{i}}(t,x,u(t,x),p,X),u_{i}\left(x,t\right)-\mathcal{M}_{i}u(t,x)\right\\}\leq
0,$$(t,x)\in(0,T)\times\Omega,(a,p,X)\in\bar{\mathcal{P}}^{2,+}_{\Omega}u_{i}(t,x)$
$\displaystyle(ii)$
$\displaystyle\quad\mbox{$\min\left\\{a+{F_{i}}(t,x,u(t,x),p,X),u_{i}(t,x)-\mathcal{M}_{i}u(t,x)\right\\}$}\wedge\mbox{$\langle
n(x),p\rangle+f_{i}(t,x,u(x))\leq 0$},$ for
$(t,x)\in(0,T)\times\partial\Omega,(a,p,X)\in\bar{\mathcal{P}}^{2,+}_{\bar{\Omega}}u_{i}(t,x)$
$\displaystyle(iii)$ $u_{i}(0,x)\leq g_{i}(x)$, $x\in\bar{\Omega}$

Viscosity supersolutions are defined analogously with $USC$ replaced by $LSC$,
${\bar{\mathcal{P}}^{2,+}_{\cdot}}$ replaced by
${\bar{\mathcal{P}}^{2,-}_{\cdot}}$, $\vee$ replaced by $\wedge$, and $\leq$
replaced by $\geq$. A function $u\in C(\bar{\Omega})$ is a viscosity solution
to (1) if it is both a sub- and a supersolution.

###  2.2 Main results

With the above preliminaries set, we are ready to state our main results,
which concern comparison of sub- and super-solutions and existence and
uniqueness of viscosity solutions to (1).

###### Theorem 2.4

Assume that (D1), (F1) - (F3), (2.1) and (2.1) - (2.1) hold. If $u$ and $v$
are viscosity sub- and supersolutions to (1), respectively, then $u(t,x)\leq
v(t,x)$ for $(t,x)\in[0,T)\times\bar{\Omega}$

###### Theorem 2.5

Assume that (D1*), (F1)- (F3), (2.1) and (2.1) - (O3) and (I1) hold. Then,
there exists a unique viscosity solution to (1).

Our proofs rely on by now classical techniques in the theory of viscosity
solutions, using doubling of variables and the maximum principle for semi-
continuous functions for Theorem 2.4 and Perron’s method together with a
construction of certain sub- and supersolutions for Theorem 2.5. From the
proof of Theorem 2.4 we also get the following corollary, useful in its own
merit.

###### Corollary 2.6

Let $u$ and $v$ be viscosity sub- and supersolutions, respectively, to (1). If
$u$ and $v$ satisfy Definition 2.3 $(ii)$ on some open region
$G\subset(0,T)\times\partial\Omega$ and $u\leq v$ on
$\left((0,T)\times\partial\Omega\right)\setminus G$, then $u(t,x)\leq v(t,x)$
for all $(t,x)\in[0,T)\times\bar{\Omega}$.

###### Remark 2.7

We have chosen to present our results and proofs in a rather simplistic
setting, with directional derivative in the normal direction and a smooth,
stationary domain $\Omega$. However, the proofs presented here reveal that the
additional arguments needed for treating systems of PDEs with interconnected
obstacles instead of a single PDE are more or less decoupled from the standard
methods used in viscosity theory (and which follows the lines of Crandall-
Ishii-Lions [10]). As a consequence, adding the additional arguments presented
here to existence and uniqueness proofs in more general settings, one should
be able to prove existence and uniqueness for systems of PDEs with
interconnected obstacles in similar generality. For tractability, we refrain
from such a generalizations here.

##  3 Proof of Theorem 2.4: The comparison principle.

Throughout the section, we assume that the assumptions of Theorem 2.4 hold,
i.e., that (D1), (F1)- (F3), (2.1) and (2.1) - (O3) hold. Let
$u=(u_{1},u_{2},\dots,u_{m})$ and $v=(v_{1},v_{2},\dots,v_{m})$ be sub- and
supersolutions to (1), respectively. Our proofs follow the classical outline
of Crandall-Ishii-Lions [10] and consists of four major steps.

#### Step 1. An $\epsilon$-room on the boundary.

######  Lemma 3.1 (Lemma 7.6 of [10])

For any continuous $\nu(x):\partial\Omega\to\mathbb{R}^{n}$ satisfying
$\langle n(x),\nu(x)\rangle>0$ there exists a $C^{2}(\bar{\Omega})$ function
$\varphi(x)$ s.t.

$\langle\nu(x),D\varphi(x)\rangle\geq 1\mbox{ for
}x\in\partial\Omega\quad\mbox{and}\quad\varphi(x)\geq 0\mbox{ on
}\bar{\Omega}.$

Let

$u_{i}^{\eta}(t,x):=u_{i}(t,x)-\eta\varphi(x)-C_{\eta}\quad\mbox{and}\quad
v_{i}^{\eta}:=v_{i}(t,x)+\eta\varphi(x)+C_{\eta}$

where $\varphi(x)$ is as given by the lemma above (with $\nu(x)=n(x)$) and
$C_{\eta}>0$ is a constant to be specified later. Note that
$u_{i}^{\eta}<u_{i}$ so that for any
$(a,p,X)\in\bar{\mathcal{P}}^{2,+}_{\Omega}u_{i}^{\eta}(t,x)$ we have from
(F1) and Remark 2.1 (i.e., from (F1*)) that

$\displaystyle\gamma(\eta\varphi(x)+C_{\eta})\leq
F_{i}(t,x,u_{i}(t,x),p,X)-F_{i}(t,x,u_{i}^{\eta}(t,x),p,X)$

for some $\gamma>0$ and thus

$\displaystyle a+F_{i}(t,x,u^{\eta}(t,x),p,X)\leq$ $\displaystyle
a+F_{i}(t,x,u_{i}(t,x),p,X)-\gamma\eta\varphi(x)-\gamma C_{\eta}$
$\displaystyle\leq$ $\displaystyle a+F_{i}(t,x,u_{i}(t,x),p+\eta
D\varphi(x),X+\eta D^{2}\varphi(x))-\gamma\eta\varphi(x)-\gamma
C_{\eta}+\omega(\eta M)$

where $M=\sup_{\bar{\Omega}}\\{D\varphi(x)+||D^{2}\varphi(x)||\\}$ and where
the last inequality comes from (2.1). Since
$(a,p,X)\in\bar{\mathcal{P}}^{2,+}_{\Omega}u^{\eta}(t,x)$ and
$u^{\eta}=u-\eta\varphi(x)-\mathcal{C}_{\eta}$ we have

$(a,p+\eta D\varphi(x),X+\eta
D^{2}\varphi(x))\in\bar{\mathcal{P}}^{2,+}_{\Omega}u(t,x)$

and therefore choosing $C_{\eta}=\frac{\omega(\eta M)}{\gamma}$ we get that

$a+F_{i}(t,x,u_{i}^{\eta}(t,x),p,X)\leq-\gamma\eta\varphi(x)<0$

whenever $(t,x)\in(0,T)\times\Omega$ and $u_{i}(t,x)>\mathcal{M}_{i}u(t,x)$
(since $u$ is a subsolution). However, $-\eta\varphi(x)-C_{\eta}$ is
independent of $i$ and thus

$\displaystyle u_{i}(t,x)>\mathcal{M}_{i}u(t,x)$ $\displaystyle\iff
u^{\eta}_{i}(t,x)>\mathcal{M}_{i}u^{\eta}(t,x)$

and we can conclude that

$\max\\{a+F_{i}(t,x,u_{i}^{\eta}(t,x),p,X),u^{\eta}_{i}-\mathcal{M}_{i}u^{\eta}(t,x)\\}\leq
0$

whenever $(a,p,X)\in\bar{\mathcal{P}}^{2,+}_{\Omega}u^{\eta}_{i}(t,x)$,
$(t,x)\in(0,T)\times\Omega$. On the other hand, if $x\in\partial\Omega$, we
have by (2.1)

$\displaystyle B_{i}(t,x,u^{\eta}_{i}(t,x),p)=$ $\displaystyle
B_{i}(t,x,u_{i}^{\eta}(t,x),p+\eta D\varphi(x))-\eta\langle
n(x),D\varphi(x)\rangle$ $\displaystyle\leq$ $\displaystyle
B_{i}(t,x,u(t,x),p+\eta D\varphi(x))-\eta$

and thus $u^{\eta}$ is a subsolution to (1) with the boundary condition

$B_{i}(t,x,r,p):=\langle n(x),p\rangle+f_{i}(t,x,r)\leq 0\quad\mbox{replaced
by}\quad\check{B}_{i}(t,x,r,p):=B_{i}(t,x,r,p)+\eta\leq 0.$

A similar calculation shows that $v^{\eta}$ is a supersolution to (1) with
boundary condition $\hat{B}_{i}(t,x,r,u):=B_{i}(t,x,r,p)-\eta\geq 0$.
Consequently, it suffices to prove the comparison $u^{\eta}\leq v^{\eta}$ when
$u^{\eta}$ and $v^{\eta}$ are sub- and supersolutions to (1) with boundary
conditions $\check{B}_{i}(t,x,r,p)$ and $\hat{B}_{i}(t,x,r,p)$, respectively,
since we retrieve our result in the limit as $\eta\to 0$.

#### Step 2. Avoiding the Neumann boundary condition.

We now construct a test function which allows us to discard the Neumann
boundary condition in (1). We will need the following comparison principle
without boundary condition whose proof, which is similar to the current, is
postponed to the end of the section.

###### Proposition 3.2

Let $u$ and $v$ be viscosity sub- and supersolutions, respectively, to

$\displaystyle\max\\{{\partial_{t}u_{i}}+F_{i}(t,x,u_{i},Du_{i},D^{2}u_{i}),u_{i}(t,x)-\mathcal{M}_{i}u(t,x)\\}=0$
$\displaystyle u_{i}(0,x)=g_{i}(x)$

on $[0,T)\times\bar{\Omega}$ in the sense of Definition 2.3 $(i)$ and $(iii)$.
Then,

$\sup_{[0,T)\times\bar{\Omega}}(u_{i}-v_{i})\leq\max_{k\in\\{1,\dots,m\\}}\sup_{((0,T)\times\partial\Omega)\cup(\\{0\\}\times\bar{\Omega})}(u_{k}-v_{k})^{+}.$

Let us now assume the opposite of what we seek to prove, i.e., that there
exists a non-empty set $\mathcal{I}\subset\\{1,\dots,m\\}$ and
$(\hat{t},\hat{x})\in[0,T]\times\bar{\Omega}$ such that

$\displaystyle\max_{k\in\\{1,\dots,m\\}}\sup_{\Omega_{T}}(u_{k}-v_{k})=u_{i}(\hat{t},\hat{x})-v_{i}(\hat{t},\hat{x})=\delta>0$
(3.1)

for any $i\in\mathcal{I}$. By Proposition 3.2 we can assume
$\hat{x}\in\partial\Omega$ and since $u_{i}\leq g_{i}\leq v_{i}$ on
$\\{0\\}\times\bar{\Omega}$ by definition, we also have $\hat{t}>0$. Moreover,
if we set

$u^{\theta}(t,x):=u(t,x)-\frac{\theta}{T-t}$

for $\theta>0$ arbitrary we have $u^{\theta}<u$,

$(a,p,X)\in\bar{\mathcal{P}}^{2,+}_{\Omega}u^{\theta}(t,x)\iff(a+\frac{\theta}{(T-t)^{2}},p,X)\in\bar{\mathcal{P}}^{2,+}_{\Omega}u(t,x),$

and

$\displaystyle(i)$ $\displaystyle\,u_{i}(t,x)>\mathcal{M}_{i}u(t,x)\iff
u^{\theta}_{i}(t,x)>\mathcal{M}_{i}u^{\theta}(t,x)\quad\mbox{(since
$u^{\theta}_{i}-u_{i}$ is independent of $i$)},$ $\displaystyle(ii)$
$\displaystyle\,\langle n(x),p\rangle+f_{i}(t,x,u_{i}^{\theta}(x))\leq\langle
n(x),p\rangle+f_{i}(x,u_{i}(x))\quad\mbox{(by \eqref{ass:BC1})}$
$\displaystyle(iii)$ $\displaystyle\,a+F_{i}(t,x,u_{i}^{\theta}(t,x),p,X)\leq
a+F_{i}(t,x,u_{i}(t,x),p,X)\quad\mbox{(by \eqref{ass:F1})}.$

It follows immediately that $u^{\theta}$ is a subsolution to (1) with $F_{i}$
replaced by

$F_{i}^{\theta}(t,x,r,p,X)=F_{i}(t,x,r,p,X)+\frac{\theta}{T-t}$

and that $u^{\theta}\to-\infty$ as $t\to T$. We may therefore also assume that
$\hat{t}<T$, since if not, we can prove $u^{\theta}\leq v$ as follows and then
retrieve our result in the limit as $\theta\to 0$.

For $\epsilon>0$ (tending to $0$ in the final argument) and $i\in\mathcal{I}$
arbitrary but fixed, let

$\varphi_{\epsilon}(t,x,y)=\frac{1}{2\epsilon}|x-y|^{2}+|x-\hat{x}|^{4}+|y-\hat{x}|^{4}+|t-\hat{t}|^{2}-f_{i}(\hat{t},\hat{x},u_{i}(\hat{t},\hat{x}))\langle
n(\hat{x}),x-y\rangle$

and consider the function

$\Phi_{\epsilon}(t,x,y)=u_{i}(t,x)-v_{i}(t,y)-\varphi_{\epsilon}(t,x,y)$

which is USC by construction. Let $(t_{\epsilon},x_{\epsilon},y_{\epsilon})$
be the maximum point of $\Phi_{\epsilon}$ on
$[0,T]\times\bar{\Omega}\times\bar{\Omega}$. (This maximum point exists as
$\Phi_{\epsilon}$ is USC and the region of maximization is compact.) Clearly,
$|x_{\epsilon}-y_{\epsilon}|\to 0$ as $\epsilon\to 0$ as
$(t_{\epsilon},x_{\epsilon},y_{\epsilon})$ is a maximum point. Since

$2\Phi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon})\geq\Phi_{\epsilon}(t_{\epsilon},x_{\epsilon},x_{\epsilon})+\Phi_{\epsilon}(t_{\epsilon},y_{\epsilon},y_{\epsilon})$

we have

$\displaystyle\frac{1}{\epsilon}|x_{\epsilon}-y_{\epsilon}|^{2}-2f_{i}(\hat{t},\hat{x},u(\hat{t},\hat{x}))\langle
n(\hat{x}),x_{\epsilon}-y_{\epsilon}\rangle\leq
u_{i}(t_{\epsilon},x_{\epsilon})-u_{i}(t_{\epsilon},y_{\epsilon})+v_{i}(t_{\epsilon},x_{\epsilon})-v_{i}(t_{\epsilon},y_{\epsilon})<\infty$

where the last inequality holds since $u_{i}-v_{i}$ is USC. This gives that
also $\frac{1}{\epsilon}|x_{\epsilon}-y_{\epsilon}|^{2}\to 0$ as $\epsilon\to
0$ and $(t_{\epsilon},x_{\epsilon})\to(\hat{t},\hat{x})$ since
$u_{i}(t,x)-v_{i}(t,x)-\varphi_{\epsilon}(t,x,x)$ has a maximum at
$(\hat{t},\hat{x})$. Moreover, from the upper- and lower semi-continuity of
$u$ and $v$ we get

$u_{i}(t_{\epsilon},x_{\epsilon})\to
u_{i}(\hat{t},\hat{x})\quad\mbox{and}\quad v_{i}(t_{\epsilon},x_{\epsilon})\to
v_{i}(\hat{t},\hat{x}).$

In particular, from the definition of $\varphi_{\epsilon}$ and
$(t_{\epsilon},x_{\epsilon},y_{\epsilon})$ we get

$\displaystyle u_{i}(\hat{t},\hat{x})-v_{i}(\hat{t},\hat{x})=$
$\displaystyle\Phi_{\epsilon}(\hat{t},\hat{x},\hat{x})\leq\Phi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon})$
$\displaystyle\leq$ $\displaystyle
u_{i}(t_{\epsilon},x_{\epsilon})-v_{i}(t_{\epsilon},x_{\epsilon})+f_{i}(\hat{t},\hat{x},u_{i}(\hat{t},\hat{x}))\langle
n(\hat{x}),x_{\epsilon}-y_{\epsilon}\rangle.$ (3.2)

Note that $u_{i}\in USC(\bar{\Omega}_{T})$ so we have $\limsup_{\epsilon\to
0}u_{i}(t_{\epsilon},x_{\epsilon})\leq u_{i}(\hat{t},\hat{x})$. Since
$(t_{\epsilon},x_{\epsilon},y_{\epsilon})\to(\hat{t},\hat{x},\hat{x})$ as
$\epsilon\to 0$, this inequality cannot be strict; if it were, (3) shows that
we must necessarily have $\liminf_{\epsilon\to
0}v_{i}(t_{\epsilon},x_{\epsilon})<v(\hat{t},\hat{x})$ as well, but this
contradicts $v_{i}\in LSC(\bar{\Omega}_{T})$. An analogous argument shows
$v_{i}(t_{\epsilon},x_{\epsilon})\to v_{i}(\hat{t},\hat{x})$.

We now invoke the exterior sphere condition which implies the existence of
$r>0$ s.t.

$\langle
n(\hat{x}),\hat{x}-x\rangle>-\frac{1}{2r}|\hat{x}-x|^{2}\quad\mbox{for any
$x\in\Omega$}.$

Differentiating gives

$\displaystyle
D_{x}\varphi(t,x,y)=\frac{1}{\epsilon}(x-y)+4|x-\hat{x}|^{2}(x-\hat{x})-f_{i}(\hat{t},\hat{x},u_{i}(\hat{t},\hat{x}))n(\hat{x})$

and thus, if $x_{\epsilon}\in\partial\Omega$ we have

$\displaystyle
B_{i}(t_{\epsilon},x_{\epsilon},u_{i}(t_{\epsilon},x_{\epsilon}),D_{x}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}))=\langle
n(x_{\epsilon}),D_{x}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon})\rangle+f_{i}(t_{\epsilon},x_{\epsilon},u_{i}(t_{\epsilon},x_{\epsilon}))$
$\displaystyle=$ $\displaystyle\left\langle
n(x_{\epsilon}),\frac{1}{\epsilon}(x_{\epsilon}-y_{\epsilon})+4|x_{\epsilon}-\hat{x}|^{2}(x_{\epsilon}-\hat{x})-f_{i}(\hat{t},\hat{x},u_{i}(\hat{t},\hat{x}))n(\hat{x})\right\rangle+f_{i}(t_{\epsilon},x_{\epsilon},u_{i}(t_{\epsilon},x_{\epsilon}))$
$\displaystyle\geq$
$\displaystyle-\frac{1}{2r\epsilon}|x_{\epsilon}-y_{\epsilon}|^{2}+4|x_{\epsilon}-\hat{x}|^{2}\langle
n(x_{\epsilon}),x_{\epsilon}-\hat{x}\rangle-
f_{i}(\hat{t},\hat{x},u_{i}(\hat{t},\hat{x}))\langle
n(x_{\epsilon}),n(\hat{x})\rangle+f_{i}(t_{\epsilon},x_{\epsilon},u_{i}(t_{\epsilon},x_{\epsilon})).$

Hence, as $\epsilon\to 0$ we have

$B_{i}(t_{\epsilon},x_{\epsilon},u_{i}(t_{\epsilon},x_{\epsilon}),D_{x}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}))\to
D$ (3.3)

for some $D\geq 0$. Similarly, for the supersolution $v$ we get for
$y_{\epsilon}\in\partial\Omega$

$\displaystyle
B_{i}(t_{\epsilon},y_{\epsilon},v_{i}(t_{\epsilon},y_{\epsilon}),-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}))=\langle
n(y_{\epsilon}),-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon})\rangle+f_{i}(t_{\epsilon},y_{\epsilon},v_{i}(t_{\epsilon},y_{\epsilon}))$
$\displaystyle=$ $\displaystyle\left\langle
n(y_{\epsilon}),\frac{1}{\epsilon}(x_{\epsilon}-y_{\epsilon})-4|y_{\epsilon}-\hat{y}|^{2}(y_{\epsilon}-\hat{x})-f_{i}(\hat{t},\hat{x},u_{i}(\hat{t},\hat{x}))n(\hat{x})\right\rangle+f_{i}(t_{\epsilon},y_{\epsilon},v_{i}(t_{\epsilon},y_{\epsilon}))$
$\displaystyle\leq$
$\displaystyle\frac{1}{r\epsilon}|x_{\epsilon}-y_{\epsilon}|^{2}-4|y_{\epsilon}-\hat{x}|^{2}\langle
n(x_{\epsilon}),y_{\epsilon}-\hat{x}\rangle-
f_{i}(\hat{t},\hat{x},u_{i}(\hat{t},\hat{x}))\langle
n(y_{\epsilon}),n(\hat{x})\rangle+f_{i}(t_{\epsilon},y_{\epsilon},v_{i}(t_{\epsilon},y_{\epsilon}))$

and thus that, as $\epsilon\to 0$,

$B_{i}(t_{\epsilon},y_{\epsilon},v_{i}(t_{\epsilon},y_{\epsilon}),-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon})\to\tilde{D}$
(3.4)

for some $\tilde{D}\leq 0$ (since $u_{i}>v_{i}$ at $(\hat{t},\hat{x})$ and
$f_{i}$ is non-decreasing by assumption (2.1)). Hence, if

$u_{i}(\hat{t},\hat{x})-v_{i}(\hat{t},\hat{x})=\delta>0$

is a positive maximum of $u_{i}-v_{i}$ over $(0,T)\times\bar{\Omega}$ we must
have

$\min\left\\{a+{F_{i}}\left(t_{\epsilon},x_{\epsilon},u_{i}(t_{\epsilon},x_{\epsilon}),D_{x}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),X\right),u_{i}(t_{\epsilon},x_{\epsilon})-\mathcal{M}_{i}u(t_{\epsilon},x_{\epsilon})\right\\}\leq
0$ for
$(a,D_{x}\varphi_{\epsilon},X)\in\bar{\mathcal{P}}^{2,+}_{\Omega}u_{i}(t_{\epsilon},x_{\epsilon})$,
and
$\min\left\\{\tilde{a}+{F_{i}}\left(t_{\epsilon},y_{\epsilon},v_{i}(t_{\epsilon},y_{\epsilon}),-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),Y\right),v_{i}(t_{\epsilon},x_{\epsilon})-\mathcal{M}_{i}v(t_{\epsilon},x_{\epsilon})\right\\}\geq
0$ for
$(\tilde{a},-D_{y}\varphi_{\epsilon},Y)\in\bar{\mathcal{P}}^{2,-}_{\Omega}v_{i}(t_{\epsilon},x_{\epsilon})$

provided $\epsilon$ is small enough. Indeed, this holds by continuity of
$F_{i}$ and since, by Step 1, we can consider $u_{i}$ and $v_{i}$ to be sub-
and supersolutions to (1) with boundary conditions
$\check{B}_{i}:=B_{i}+\eta\leq 0$ and $\hat{B}_{i}:=B_{i}-\eta\geq 0$,
respectively. Thus, since we have (3.3) and (3.4), the boundary conditions
cannot be satisfied and therefore the equation must hold on the boundary (in
the sub- /supersolution sense).

#### Step 3. Avoiding the obstacle.

We will now argue as in Ishii-Koike [14] to ensure that the subsolution (more
precisely, at least one component of it) lies strictly above its obstacle at
$(\hat{t},\hat{x})$. To do this, recall the set $\mathcal{I}$ and assume that
$u_{i}(\hat{t},\hat{x})\leq\mathcal{M}_{i}u(\hat{t},\hat{x})$, i.e.,

$u_{i}(\hat{t},\hat{x})\leq\max_{i\neq
j}\\{{u_{j}(\hat{t},\hat{x})-c_{ij}(\hat{t},\hat{x})}\\},$

whenever $i\in\mathcal{I}$. This implies the existence of
$k\in\\{1,\dots,i-1,i+1,\dots,m\\}$ s.t.

$u_{i}(\hat{t},\hat{x})+c_{ik}(\hat{t},\hat{x})\leq u_{k}(\hat{t},\hat{x})$

Moreover, since $v$ is a supersolution we have

$v_{i}(\hat{t},\hat{x})\geq v_{k}(\hat{t},\hat{x})-c_{ik}(\hat{t},\hat{x}).$

Combining the above two inequalities yield

$u_{i}(\hat{t},\hat{x})-v_{i}(\hat{t},\hat{x})\leq
u_{k}(\hat{t},\hat{x})-v_{k}(\hat{t},\hat{x})$

but since $(\hat{t},\hat{x})$ is a maximum of $u_{i}-v_{i}$ and
$i\in\mathcal{I}$ this must in fact be an equality and $k\in I$ as well.
Repeating this as many times as necessary, we find the existence of a sequence
of indices $\\{i_{1},i_{2},\dots,i_{p},i_{1}\\}$, $i_{p}\neq i_{p+1}$ such
that

$u_{i_{1}}(\hat{t},\hat{x})+c_{i_{1}i_{2}}(\hat{t},\hat{x})+c_{i_{2}i_{3}}(\hat{t},\hat{x})+\dots
c_{i_{p}i_{1}}(\hat{t},\hat{x})\leq u_{i_{1}}(\hat{t},\hat{x})$

which implies

$c_{i_{1}i_{2}}(\hat{t},\hat{x})+c_{i_{2}i_{3}}(\hat{t},\hat{x})+\dots
c_{i_{p}i_{1}}(\hat{t},\hat{x})\leq 0,$

a contradiction to (2.1) $(iii)$. Thus, there exists at least one index
$i\in\mathcal{I}$ s.t.

$u_{i}(\hat{t},\hat{x})>\mathcal{M}_{i}u(\hat{t},\hat{x}).$

Since $u_{i}(x_{\epsilon},t_{\epsilon})\to u_{i}(\hat{t},\hat{x})$ and
$v_{i}(x_{\epsilon},t_{\epsilon})\to v_{i}(\hat{t},\hat{x})$ for all
$i\in\\{1,\dots,m\\}$, we can then conclude from this and Step 2 that

$a+{F_{i}}\left(t_{\epsilon},x_{\epsilon},u_{i}(t_{\epsilon},x_{\epsilon}),D_{x}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),X\right)\leq
0$ for
$(a,D_{x}\varphi_{\epsilon},X)\in\bar{\mathcal{P}}^{2,+}_{\Omega}u_{i}(t_{\epsilon},x_{\epsilon})$,
and
$\tilde{a}+{F_{i}}\left(t_{\epsilon},y_{\epsilon},v_{i}(t_{\epsilon},y_{\epsilon}),-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),Y\right)\geq
0$ for
$(\tilde{a},-D_{y}\varphi_{\epsilon},Y)\in\bar{\mathcal{P}}^{2,-}_{\Omega}v_{i}(t_{\epsilon},y_{\epsilon})$
(3.5)

for at least one $i\in\mathcal{I}$ and $\epsilon$ small enough.

#### Step 4. Reaching the contradiction

We are now ready to reach our final contradiction. To do this, we will use the
following lemma, the so called maximum principle for semi-continuous
functions. Lemma 3.3 corresponds to Theorem 8.3 of [10] in a less general, but
for our purposes sufficient, form.

###### Lemma 3.3

Suppose that $(t_{\epsilon},x_{\epsilon},y_{\epsilon})$ is a maximum point of

$u_{i}(t,x)-v_{i}(t,y)-\varphi_{\epsilon}(t,x,y)$

over $(0,T)\times\bar{\Omega}$. Then, for each $\theta>0$ there are
$X,Y\in\mathcal{S}(n)$ such that

$\displaystyle(i)$
$\displaystyle\,(a,D_{x}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),X)\in\bar{\mathcal{P}}^{2,+}_{\Omega}u_{i}(t\epsilon,x_{\epsilon})\quad\mbox{and}\quad$
$\displaystyle\,(\tilde{a},-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),Y)\in\bar{\mathcal{P}}^{2,-}_{\Omega}v_{i}(t_{\epsilon},y_{\epsilon}),$
$\displaystyle(ii)$ $\displaystyle\,\left(\begin{matrix}X&0\\\
0&-Y\end{matrix}\right)\leq A+\theta A^{2},$ $\displaystyle(iii)$
$\displaystyle\,a-\tilde{a}=\frac{\partial}{\partial
t}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),$

where $A:=D_{x}^{2}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon})$
is the Hessian matrix of $\varphi(t,x,y)$ (w.r.t. $x$ and $y$).

We first note that

$\displaystyle\frac{\partial}{\partial
t}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},x_{\epsilon})=$ $\displaystyle
2(t_{\epsilon}-\hat{t})$ $\displaystyle
D_{x}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon})=$
$\displaystyle\frac{1}{\epsilon}(x_{\epsilon}-y_{\epsilon})+4|x_{\epsilon}-\hat{x}|^{2}(x_{\epsilon}-\hat{x})-f_{i}(\hat{t},\hat{x},u_{i}(\hat{t},\hat{x}))n(\hat{x})$
$\displaystyle-
D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon})=$
$\displaystyle\frac{1}{\epsilon}(x_{\epsilon}-y_{\epsilon})-4|y_{\epsilon}-\hat{x}|^{2}(y_{\epsilon}-\hat{x})-f_{i}(\hat{t},\hat{x},u_{i}(\hat{t},\hat{x}))n(\hat{x})$
$\displaystyle
A:=D^{2}_{x}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon})=$
$\displaystyle\frac{1}{\epsilon}\left(\begin{matrix}I&-I\\\
-I&I\end{matrix}\right)+\mathcal{O}(|x_{\epsilon}-\hat{x}|^{2}+|y_{\epsilon}-\hat{x}|^{2})$

which gives

$A^{2}=\frac{2}{\epsilon^{2}}\left(\begin{matrix}I&-I\\\
-I&I\end{matrix}\right)+\mathcal{O}\left(\frac{1}{\epsilon}(|x_{\epsilon}-\hat{x}|^{2}+|y_{\epsilon}-\hat{y}|^{2})+|x_{\epsilon}-\hat{x}|^{4}+|y_{\epsilon}-\hat{x}|^{4}\right).$

Choosing $\theta=\epsilon$ in Lemma 3.3 $(ii)$ gives the existence of

$(a,D_{x}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},x_{\epsilon}),X)\in\bar{\mathcal{P}}^{2,+}_{\Omega}u_{i}(t_{\epsilon},x_{\epsilon})\quad\mbox{and}\quad(\tilde{a},-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},x_{\epsilon}),Y)\in\bar{\mathcal{P}}^{2,-}_{\Omega}v_{i}(t_{\epsilon},x_{\epsilon}),$

with

$\displaystyle\left(\begin{matrix}X&0\\\ 0&-Y\end{matrix}\right)\leq$
$\displaystyle\frac{3}{\epsilon}\left(\begin{matrix}I&-I\\\
-I&I\end{matrix}\right)+\mathcal{O}(|x_{\epsilon}-\hat{x}|^{2}+|y_{\epsilon}-\hat{x}|^{2}).$

Note in particular that this implies that for any $\xi>0$ fixed there exists
$\epsilon>0$ such that the above holds with

$\displaystyle\left(\begin{matrix}X&0\\\
0&-Y\end{matrix}\right)\leq\frac{3}{\epsilon}\left(\begin{matrix}I&-I\\\
-I&I\end{matrix}\right)+\xi\left(\begin{matrix}I&0\\\
0&I\end{matrix}\right)\iff\left(\begin{matrix}X-\xi I&0\\\ 0&-(Y+\xi
I)\end{matrix}\right)\leq\frac{3}{\epsilon}\left(\begin{matrix}I&-I\\\
-I&I\end{matrix}\right).$ (3.6)

Moreover, we have from (3) that

$a+{F_{i}}\left(t_{\epsilon},x_{\epsilon},u_{i}(t_{\epsilon},x_{\epsilon}),D_{x}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),X\right)\leq
0\quad\mbox{and}\quad\tilde{a}+{F_{i}}\left(t_{\epsilon},x_{\epsilon},v_{i}(t_{\epsilon},y_{\epsilon}),-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon}),Y\right)\geq
0$

which implies

$2(t_{\epsilon}-\hat{t})=a-\tilde{a}\leq{F_{i}}\left(t_{\epsilon},y_{\epsilon},v_{i}(t_{\epsilon},y_{\epsilon}),-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),Y\right)-{F_{i}}\left(t_{\epsilon},x_{\epsilon},u_{i}(t_{\epsilon},x_{\epsilon}),D_{x}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),X\right)$
(3.7)

by Lemma 3.3 $(iii)$.

What remains is to show that (3.7) is inconsistent with (3.1), (3.6) and the
assumptions (F1) - (F3). To see this, note that

$\displaystyle{F_{i}}\left(t_{\epsilon},y_{\epsilon},v_{i}(t_{\epsilon},y_{\epsilon}),-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),Y\right)-{F_{i}}\left(t_{\epsilon},x_{\epsilon},u_{i}(t_{\epsilon},x_{\epsilon}),D_{x}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),X\right)$
$\displaystyle\leq$
$\displaystyle{F_{i}}\left(t_{\epsilon},y_{\epsilon},v_{i}(t_{\epsilon},y_{\epsilon}),-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),Y\right)-{F_{i}}\left(t_{\epsilon},x_{\epsilon},u_{i}(t_{\epsilon},x_{\epsilon}),-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),X\right)$
$\displaystyle+\omega(4(|\hat{x}-x_{\epsilon}|^{3}+|\hat{x}-y_{\epsilon}|^{3}))$
$\displaystyle\leq$
$\displaystyle{F_{i}}\left(t_{\epsilon},y_{\epsilon},u_{i}(t_{\epsilon},x_{\epsilon}),-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),Y\right)-{F_{i}}\left(t_{\epsilon},x_{\epsilon},u_{i}(t_{\epsilon},x_{\epsilon}),-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}),X\right)$
$\displaystyle+\omega(4(|\hat{x}-x_{\epsilon}|^{3}+|\hat{x}-y_{\epsilon}|^{3}))-\gamma(u_{i}(t_{\epsilon},x_{\epsilon})-v_{i}(t_{\epsilon},y_{\epsilon}))$
(3.8)

where we have used, in turn, (2.1),

$|D_{x}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon})-(-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon}))|=4(|\hat{x}-x_{\epsilon}|^{2}(x_{\epsilon}-\hat{x})+|\hat{x}-y_{\epsilon}|^{2}(y_{\epsilon}-\hat{x})),$

and (F1) (more precisely, (F1*)). Since (3.6) holds we get from (F3) that

$\displaystyle F_{i}(t_{\epsilon},y_{\epsilon},r,p,Y+\xi
I)-F_{i}(t_{\epsilon},x_{\epsilon},r,p,X-\xi
I)\leq\omega(\frac{1}{\epsilon}|x_{\epsilon}-y_{\epsilon}|^{2}+|x_{\epsilon}-y_{\epsilon}|(|p|+1))$

and from (2.1) that

$\displaystyle F_{i}(t_{\epsilon},y_{\epsilon},r,p,Y+\xi
I)-F_{i}(t_{\epsilon},x_{\epsilon},r,p,X-\xi I)\geq
F_{i}(t_{\epsilon},y_{\epsilon},r,p,Y)-F_{i}(t_{\epsilon},x_{\epsilon},r,p,X)-2\omega(\xi)$

and thus, combining these displays, that

$F_{i}(t_{\epsilon},y_{\epsilon},r,p,Y)-F_{i}(t_{\epsilon},x_{\epsilon},r,p,X)\leq\omega(\frac{1}{\epsilon}|x_{\epsilon}-y_{\epsilon}|^{2}+|x_{\epsilon}-y_{\epsilon}|(|p|+1))+2\omega(\xi)$
(3.9)

Putting (3.7), (3), and (3.9) together gives

$\displaystyle 2(t_{\epsilon}-\hat{t})\leq$
$\displaystyle\,\omega(4(|\hat{x}-x_{\epsilon}|^{3}+|\hat{x}-y_{\epsilon}|^{3}))-\gamma(u_{i}(t_{\epsilon},x_{\epsilon})-v_{i}(t_{\epsilon},y_{\epsilon}))$
$\displaystyle+2\omega(\xi)+\omega(\frac{1}{\epsilon}|x_{\epsilon}-y_{\epsilon}|^{2}+|x_{\epsilon}-y_{\epsilon}|(|-D_{y}\varphi_{\epsilon}(t_{\epsilon},x_{\epsilon},y_{\epsilon})|+1)).$

Taking the limit as $\epsilon\to 0$ and recalling
$\frac{1}{\epsilon}|x_{\epsilon}-y_{\epsilon}|^{2}\to 0$ we arrive at

$\gamma\delta\leq 2\omega(\xi)$

which is a contradiction since $\xi>0$ was arbitrary and $\gamma\delta>0$.
$\,{}_{\blacksquare}$

Proof of Proposition 3.2. Assume first that $u_{i}\leq v_{i}$ on
$(0,T)\times\partial\Omega$ for all $i\in\\{1,\dots,m\\}$. As above, assume
the existence of $\mathcal{I}$ and $(\hat{t},\hat{x})$ such that

$0<\delta=u_{i}(\hat{t},\hat{x})-v_{i}(\hat{t},\hat{x})$

for all $i\in\mathcal{I}$. Now, let

$\varphi_{\epsilon}(t,x,y)=\frac{1}{2\epsilon}|x-y|^{2}+|x-\hat{x}|^{4}+|y-\hat{x}|^{4}+|t-\hat{t}|^{2}$

and construct
$\Phi_{\epsilon}(t,x,y):=u_{i}(t,x)-v_{i}(t,y)-\varphi_{\epsilon}(t,x,y)$.
Calculations analogous to those in the first half of Step 2 above shows

$\frac{1}{\epsilon}|x_{\epsilon}-y_{\epsilon}|\to 0,\quad
x_{\epsilon}\to\hat{x},\quad u_{i}(t_{\epsilon},x_{\epsilon})\to
u_{i}(\hat{t},\hat{x}),\quad\mbox{and}\quad
v_{i}(t_{\epsilon},y_{\epsilon})\to v_{i}(\hat{t},\hat{x})$

and we can thus simply repeat Step 3-4 above to get the desired contradiction.

For the general case, let

$K:=\max_{i\in\\{1,\dots,m\\}}\sup_{((0,T)\times\partial\Omega)\cup(\\{0\\}\times\bar{\Omega})}(u_{i}-v_{i})^{+}\geq
0$

and note that $\tilde{u}:=u-K\leq u$ is a subsolution to (1) in the sense of
Definition 2.3 $(i)$ and $(iii)$ since $\tilde{u}_{i}(0,\cdot)\leq
u_{i}(0,\cdot)\leq g_{i}$, $K$ is independent of $i$ and

$a+F(t,x,\tilde{u}_{i},p,X)\leq a+F(t,x,u_{i},p,X)$

by (F1). Moreover, $\tilde{u}\leq v$ on $(0,T)\times\partial\Omega$ so we can
apply the above result to conclude that

$\tilde{u}=u-K\leq v\iff u-v\leq K$

and we are done.

Proof of Corollary 2.6. If $u$ is a viscosity subsolution, then so is $u-K$
for all $K>0$. It thus suffices to prove that if $u\leq v$ on
$((0,T)\times\partial\Omega)\setminus G)$, then $u\leq v$ in
$[0,T)\times\bar{\Omega}$. If $G=(0,T)\times\partial\Omega$, then this
implication and its proof is identical to Theorem 2.4 and if $G=\emptyset$ it
is identical to Proposition 3.2. If $G\subset(0,T)\times\partial\Omega$ is a
non-empty proper subset, then we know by assumption that $u\leq v$ on
$((0,T)\times\partial\Omega)\setminus G$ and so the maximum point
$(\hat{t},\hat{x})$ defined in (3.1) must belong to the set $G$ where the
boundary condition is satisfied. Hence, we can follow the proof of Theorem 2.4
to conclude that $u\leq v$ in $[0,T)\times\bar{\Omega}$.

##  4 Proof of Theorem 2.5: Perron’s method and barrier construction.

Throughout the section, we assume that the assumptions of Theorem 2.5 hold,
i.e., that (D1*), (F1) - (F3), (2.1), (2.1) - (O3), and (I1) hold. Our proof
of existence follows the machinery of Perron’s method. In particular, we have
the following result.

###### Proposition 4.1

Assume that, for each $i\in\\{1,\dots,m\\}$ and $\hat{x}\in\bar{\Omega}$ there
exist a family of continuous viscosity sub- and supersolutions,
$\\{u^{i,\hat{x},\epsilon}\\}_{\epsilon>0}$ and
$\\{v^{i,\hat{x},\epsilon}\\}_{\epsilon>0}$, to (1) such that

$\sup_{\epsilon}u^{i,\hat{x},\epsilon}_{i}(0,\hat{x})=g_{i}(\hat{x})=\inf_{\epsilon}v^{i,\hat{x},\epsilon}_{i}(0,\hat{x}).$

Then,

$w(t,x)=\sup\\{u(t,x)\,:\,\mbox{$u$ is a subsolution to \eqref{problem}}\\}$

is a viscosity solution to (1).

With this result given, what remains is to construct appropriate barriers,
i.e., families of viscosity sub- and supersolutions taking on the correct
initial data. More specifically, we prove the following.

###### Proposition 4.2

There exists $\kappa>0$ s.t.
$U^{\hat{x},\epsilon}:=(U_{1}^{\hat{x},\epsilon},\ldots,U^{\hat{x},\epsilon}_{m})$
and
$V^{i,\hat{x},\epsilon}:=(V_{1}^{i,\hat{x},\epsilon},\dots,V^{i,\hat{x},\epsilon}_{m})$,

$\displaystyle U^{\hat{x},\epsilon}_{j}(t,x)$
$\displaystyle=g_{j}(\hat{x})-A(\varphi(x)-\varphi(\hat{x}))-B\exp(\kappa\varphi(x))|x-\hat{x}|^{2}-\epsilon-
Ct,$ $\displaystyle V^{i,\hat{x},\epsilon}_{j}(t,x)$
$\displaystyle=g_{i}(\hat{x})+A(\varphi(x)-\varphi(\hat{x}))+B\exp(\kappa\varphi(x))|x-\hat{x}|^{2}+\epsilon+Ct+c_{ij}(t,x),$

where $\varphi(x)$ is given in Lemma 3.1, are viscosity sub- and
supersolutions to (1), respectively. Moreover,

$\sup_{\epsilon}U^{i,\hat{x},\epsilon}_{i}(0,\hat{x})=g_{i}(\hat{x})=\inf_{\epsilon}V^{i,\hat{x},\epsilon}_{i}(0,\hat{x}).$

Combining Propositions 4.1 and 4.2 above proves the existence part of Theorem
2.5. Uniqueness follows immediately from Theorem 2.4 and the definition of
sub- and supersolutions. What needs to be done is thus to prove the above
propositions. Being the non-standard one, we start with Proposition 4.2.

Proof of Proposition 4.2. We prove only the supersolution property (the
subsolution property is proven analogously but without the need to deal with
the obstacle as in (4) below). To ease notation, we suppress the superindices
$i,\hat{x},\epsilon$. By definition, our function must satisfy condition
$(i)-(iii)$ of Definition 2.3.

We begin with condition $(iii)$. We can, for any $A$ given, ensure
$V_{j}(0,x)\geq g_{j}(x),\forall x\in\bar{\Omega}$ simply by choosing $B$ and
$\epsilon>0$ sufficiently large. Indeed, this is possible since $\varphi,g$,
and $c_{ij}$ are continuous and

$V_{j}(0,\hat{x})=g_{i}(\hat{x})+c_{ij}(0,\hat{x})\geq g_{j}(\hat{x})$

where the last inequality is due to Assumption (I1). Moreover, we can let
$\epsilon\to 0$ by taking $B\to\infty$ and thus, since $c_{ii}(t,x)\equiv 0$,
we also have that

$\inf_{\epsilon}V_{i}(0,\hat{x})=g_{i}(\hat{x}).$ (4.1)

Also note that the choice of $B$ can be made with $\kappa=0$; later increasing
$\kappa$ will only increases $V$ further while keeping (4.1).

We next turn to condition $(i)$ of Definition 2.3. Starting with the obstacle,
we have

$\displaystyle V_{j}(t,x)-\mathcal{M}_{j}V(t,x):=V_{j}(t,x)-\max_{k\neq
j}\\{V_{j}(t,x)-c_{ij}(t,x)\\}$ $\displaystyle=$ $\displaystyle
c_{ij}(t,x)-\max_{k\neq
j}\\{c_{ik}(t,x)-c_{jk}(t,x)\\}=c_{ij}(t,x)-c_{i\hat{k}}(t,x)+c_{j\hat{k}}(t,x)\geq
0$ (4.2)

where the last inequality is by assumption (O3). Concerning the second part,
we easily see that, with $B$ given, we can find $C$ such that

$\partial_{t}V_{i}(t,x)+F_{i}(t,x,V_{i}(t,x),D_{x}V_{i}(t,x),D^{2}_{xx}V_{i}(t,x))\geq
0$ (4.3)

for $(a,p,X)\in\mathcal{P}^{2,-}_{\Omega}V_{i}(t,x)$, for all
$(t,x)\in\Omega_{T}$ and all $i\in\mathcal{I}$. Indeed, this follows
immediately after noticing that $V$ smooth and $F_{i}$ continuous gives an
upper bound for $|F_{i}(t,x,V_{i}(t,x),D_{x}V_{i}(t,x),D^{2}_{xx}V_{i}(t,x))|$
on the compact region $\bar{\Omega}$ and that this bound can be made
independent from $C$ (and $\kappa$) since $F_{i}$ is decreasing with $V_{i}$.
Therefore, since $\partial_{t}V_{j}(t,x)=C+\partial_{t}c_{ij}(t,x)$ and the
latter term is bounded in $\bar{\Omega}_{T}$, we can choose C, depending on
$B$ such that (4.3) holds.

What remains to verify is now condition $(ii)$ of Definition 2.3. If
$\hat{x}\in\partial\Omega$, satisfaction of (4.3) in the classical sense does
not ensure ditto in the viscosity sense. We therefore instead focus on the
Neumann condition and intend to prove that

$\langle n(x),D_{x}V_{j}(t,x)\rangle+f_{i}(t,x,V_{j}(t,x))\geq 0$

(in the viscosity sense) for $(t,x)\in\partial\Omega_{T}$ and for all
$j\in\\{1,\dots,m\\}$.

Recall that we have chosen $B$ s.t. $V_{j}(0,x)\geq g_{j}(x)$ in
$\bar{\Omega}_{0}$. Since $\partial_{t}c_{ij}(t,x)$ is bounded from below, we
can also choose $C$ large enough to ensure that $V_{j}(t,x)\geq g_{j}(x)$
holds for all $(t,x)\in\bar{\Omega}_{T}$. By the monotonicity property of $f$
(non-decreasing in $r$) we then have

$f_{j}(t,x,V_{j}(t,x))\geq f_{j}(t,x,g_{j}(x)).$

Let $\tilde{A}$ be such that

$\min_{j\in\\{1,\dots,m\\}}\inf_{(t,x)\in\partial\bar{\Omega}_{T}}f_{j}(t,x,g_{j}(x))>-\tilde{A}.$

The Neumann boundary condition thus follows if we can show that

$\langle n(x),D_{x}V_{j}(t,x)\rangle\geq\tilde{A}$

for all $(t,x)\in\partial\Omega_{T}$. Differentiating $V_{j}(t,x)$ gives

$D_{x}V_{j}(t,x)=AD_{x}\varphi(x)+B\exp(\kappa\varphi(x))\left(2(x-\hat{x})+\kappa|x-\hat{x}|^{2}D_{x}\varphi(x)\right)+D_{x}c_{ij}(t,x)$

and thus

$\displaystyle\langle n(x),D_{x}V_{j}(t,x)\rangle=$ $\displaystyle\langle
n(x),AD_{x}\varphi(x)\rangle+\langle n(x),D_{x}c_{ij}(t,x)\rangle$
$\displaystyle+B\exp(\kappa\varphi(x))\langle
n(x),2(x-\hat{x})+\kappa|x-\hat{x}|^{2}D_{x}\varphi(x)\rangle$ (4.4)

where $|\langle n(x),D_{x}c_{ij}\rangle|$ is bounded since $c_{ij}$ is smooth.
The interior ball condition implies that

$\langle n(\hat{x}),x-\hat{x}\rangle>-\frac{1}{r}|\hat{x}-x|^{2}\quad\mbox{for
any $\hat{x}\in\partial\Omega$ and $x\in\partial{\Omega}$}.$

Thus, for $\kappa=\kappa(r)$ large enough, the last term in (4) is non-
negative.

What remains now is simply to pick $A$ so that
$A-\max_{i,j\in\\{1,\dots,m\\}}|D_{x}c_{ij}|\geq\tilde{A}$ and then, for any
$\epsilon>0$, choose $B$ and then $C$ with this $A$ given such that the above
calculations hold. Last, we note that the constructed barrier now satisfies
the boundary condition in the classical sense. This suffices as Proposition
7.2 of [10] and the specific form of the function $B_{i}$ (cf. $(7.4)$ of
[10]) then gives that the boundary condition also holds in the viscosity
sense.

Proof of Proposition 4.1. Note first that $w$ is well defined and bounded by
the assumption of existence of sub- and supersolutions. Let
$w_{\ast}:=(w_{\ast,1},\ldots,w_{\ast,m})$ and
$w^{\ast}:=(w^{\ast}_{1},\ldots,w^{\ast}_{m})$ denote the lower- and upper
semi-continuous envelopes of $w=(w_{1},\dots,w_{m})$, respectively, i.e., the
largest LSC function that is dominated by $w$ and the smallest USC function
that dominates $w$, respectively. By definition and Theorem 2.4 we have, for
any $i,\hat{x}$ and $\epsilon>0$ fixed,

$w_{\ast}\leq w^{\ast},\qquad u^{i,\hat{x},\epsilon}\leq
w^{\ast}\quad\mbox{and}\quad w_{\ast}\leq v^{i,\hat{x},\epsilon}.$

The essence of Perron’s method is to now prove that $w_{\ast}$ is a
supersolution and $w^{\ast}$ a subsolution to (1), implying that also
$w^{\ast}\leq w_{\ast}$ by Theorem 2.4 and thus that $w=w_{\ast}=w^{\ast}$ is
a solution to (1).

To establish the subsolution property, we need to show

$\displaystyle(i)$
$\min\left\\{a+{F_{i}}(t,x,w^{\ast}_{i}(t,x),p,X),w^{\ast}_{i}\left(x,t\right)-\mathcal{M}_{i}w^{\ast}(t,x)\right\\}\leq
0,$$(t,x)\in\Omega_{T},(a,p,X)\in\bar{\mathcal{P}}^{2,+}_{\Omega}w^{\ast}_{i}(t,x)$
$\displaystyle(ii)$
$\displaystyle\quad\mbox{$\min\left\\{a+{F_{i}}(t,x,w^{\ast}(t,x),p,X),w^{\ast}_{i}(t,x)-\mathcal{M}_{i}w^{\ast}(t,x)\right\\}$}\wedge\mbox{$\langle
n(x),p\rangle+f_{i}(t,x,w_{i}^{\ast}(x))\leq 0$},$ for
$(t,x)\in\partial\Omega_{T},(a,p,X)\in\bar{\mathcal{P}}^{2,+}_{\Omega}w^{\ast}_{i}(t,x)$
$\displaystyle(iii)$ $w^{\ast}_{i}(0,x)\leq g_{i}(x)$, $x\in\bar{\Omega}$

Statement $(iii)$ follows immediately from the assumptions and Theorem 2.4.
Indeed, $w_{i}\leq v^{i,\hat{x},\epsilon}_{i}$ for any $i,\hat{x},$ and
$\epsilon$ and thus
$w^{\ast}_{i}(0,\hat{x})\leq\inf_{\epsilon}(v_{i}^{i,\hat{x},\epsilon})^{\ast}(0,\hat{x})=g_{i}(\hat{x})$
(where the last equality is by assumption).

Concerning statement $(i)$, we first note that by the definition of
$w^{\ast}_{i}$ there exists a sequence

$(t_{n},x_{n},u_{i}^{n}(t_{n},x_{n}))\to(t,x,w_{i}^{\ast}(t,x))$ (4.5)

with each $u^{n}$ being a subsolution of (1). Assume now that
$(a,p,X)\in\bar{\mathcal{P}}^{2,+}_{\Omega}w^{\ast}_{i}(\hat{t},\hat{x})$ for
$(\hat{t},\hat{x})\in\Omega_{T}$. Then, by the existence of the sequence (4.5)
and the fact that $w_{i}^{\ast}$ is USC we get from Proposition 4.3 of [10]
that there exists a sequence

$(t_{n},x_{n},u^{n}_{i},a_{n},p_{n},X_{n})\to(t,x,w^{\ast}(t,x),a,p,X)\quad\mbox{with}\quad(a_{n},p_{n},X_{n})\in\bar{\mathcal{P}}^{2,+}_{\Omega}u^{n}_{i}(t_{n},x_{n}).$

Since $(\hat{t},\hat{x})\in\Omega_{T}$ we will have
$(t_{n},x_{n})\in\Omega_{T}$ as well for $n$ large enough and by the
subsolution property of $u^{n}$ and the fact that $F$ is continuous we get

$a+F_{i}(t,x,w_{i}^{\ast},p,X)=\lim_{n\to\infty}\left(a_{n}+F_{i}(t_{n},x_{n},u^{n}_{i}(t_{n},x_{n}),p_{n},X_{n})\right)\leq
0$

and thus $w^{\ast}$ satisfies $(i)$ above. If
$(a,p,X)\in\bar{\mathcal{P}}^{2,+}_{\Omega}w^{\ast}_{i}(\hat{t},\hat{x})$ for
$(\hat{t},\hat{x})\in\partial\Omega_{T}$, analogous reasoning gives the
existence of a sequence such that

$\left(a_{n}+F_{i}(t_{n},x_{n},u^{n}_{i}(t_{n},x_{n}),p_{n},X_{n})\right)\wedge
B_{i}(t_{n},x_{n},u_{i}^{n}(t_{n},x_{n}),p_{n})\leq 0$

for all $n$. Taking the limit as $n\to\infty$, now using also that $f_{i}$ is
continuous, we conclude that also $(ii)$ holds. In particular, we then have
$w^{\ast}=w$.

We now prove that $w_{\ast}$ is a supersolution following a classical argument
by contradiction. More precisely, we show that if $w_{\ast}$ is not a
supersolution, then there exists a subsolution strictly greater than
$w^{\ast}$, contradicting the very definition of $w$.

Starting with the initial condition $(iii)$ we have $w_{i}(0,\hat{x})\geq
u_{i}^{i,\hat{x},\epsilon}(0,\hat{x})$ for all $\epsilon>0$ and thus
$w_{\ast,i}(0,\hat{x})\geq\sup_{\epsilon}(u_{i}^{i,\hat{x},\epsilon})_{\ast}(0,\hat{x})=\sup_{\epsilon}u_{i}^{i,\hat{x},\epsilon}(0,\hat{x})=g_{i}(\hat{x})$.
Assume now that $w_{\ast}$ is not a supersolution by violating Definition 2.3
$(i)$, i.e., that for some $(\hat{t},\hat{x})\in\Omega_{T}$ and
$i\in\\{1,\dots,m\\}$ we have

$\displaystyle\min\\{a+F_{i}(\hat{t},\hat{x},w_{\ast,i}(\hat{t},\hat{x}),p,X),w_{\ast,i}(\hat{t},\hat{x})-\mathcal{M}_{i}w_{\ast,i}(\hat{t},\hat{x})\\}<0$

for some
$(a,p,X)\in\bar{\mathcal{P}}^{2,-}_{\Omega}w_{\ast,i}(\hat{t},\hat{x})$. For
$\delta>0$ and such $(a,p,X)$ fixed, construct the function

$\tilde{w}(t,x):=w_{\ast,i}(\hat{t},\hat{x})+\delta+a(t-\hat{t})+\langle
p,(x-\hat{x})\rangle+\frac{1}{2}\langle
X(x-\hat{x}),(x-\hat{x})\rangle-\beta(|t-\hat{t}|+|x-\hat{x}|^{2}).$

Since $\mathcal{M}_{i}w_{\ast}\leq\mathcal{M}_{i}w^{\ast}$ it follows from
continuity that the function $\tilde{w}(t,x)$ is a viscosity subsolution to

$\min\left\\{\partial_{t}\tilde{w}(t,x)+{F}_{i}\left(t,x,\tilde{w}(t,x),D\tilde{w},D^{2}\tilde{w}\right),\tilde{w}(t,x)_{i}-\mathcal{M}_{i}w^{\ast}(t,x)\right\\}=0$
(4.6)

for $(t,x)\in Q_{R}:=\\{(t,x):|t-\hat{t}|+|x-\hat{x}|^{2}<R\\}$ and $\delta$,
$\beta$ and $R$ sufficiently small. (If $t\neq\hat{t}$, $\tilde{w}$ satisfies
(4.6) in the classical sense. If $t=\hat{t}$,
$\bar{\mathcal{P}}^{2,+}_{\Omega}\tilde{w}(t,x)=\\{(a+\beta\eta,p,X):\eta\in[-1,1]\\}$
and the contribution from $\beta\eta$ is harmless if $\beta$ is small enough.)
By definition of $\bar{\mathcal{P}}^{2,-}_{\Omega}w_{\ast,i}(\hat{t},\hat{x})$
we have

$\displaystyle w_{i}^{\ast}(t,x)$ $\displaystyle\geq w_{\ast,i}(t,x)\geq
w_{\ast,i}(\hat{t},\hat{x})+a(t-\hat{t})+\langle
p,x-\hat{x}\rangle+\frac{1}{2}\langle
X(x-\hat{x}),x-\hat{x}\rangle+o(|t-\hat{t}|+|x-\hat{x}|^{2})$
$\displaystyle=\tilde{w}(t,x)-\delta+\beta(|t-\hat{t}|+|x-\hat{x}|^{2})+o(|t-\hat{t}|+|x-\hat{x}|^{2})$

and thus, if we let $\delta=\frac{\beta R}{4}$ and consider $(t,x)\in
Q_{R}\setminus Q_{\frac{R}{2}}$, we get

$\displaystyle w_{i}^{\ast}(t,x)$ $\displaystyle\geq\tilde{w}(t,x)-\frac{\beta
R}{4}+\beta(|t-\hat{t}|+|x-\hat{x}|^{2})+o(|t-\hat{t}|+|x-\hat{x}|^{2})$
$\displaystyle\geq\tilde{w}(t,x)-\frac{\beta R}{4}+\frac{\beta R}{2}+o(R).$
(4.7)

Now let $\check{u}=\\{\check{u}_{1},\dots,\check{u}_{m}\\}$ where

$\check{u}_{i}=\begin{cases}\max\\{w^{\ast}_{i}(t,x),\tilde{w}_{i}(t,x)\\}&$\mbox{if
$(t,x)\in Q_{R}$}$\\\
w^{\ast}_{i}(t,x)&\mbox{otherwise}\end{cases}\qquad\mbox{and}\qquad\mbox{$\check{u}_{j}(t,x)=w^{\ast}_{j}(t,x)$
if $j\neq i$}.$

Note that by (4), there is no jump in $\check{u}_{i}$ at $\partial Q_{R}$ if
$R$ is small enough. Since $\check{u}_{i}\geq w^{\ast}_{i}$ we have

$\check{u}_{j}-\mathcal{M}_{j}\check{u}\leq
w^{\ast}_{j}-\mathcal{M}_{j}w^{\ast}$

for any $j\neq i$. Recalling that $w^{\ast}_{i}$ is a subsolution, the above
shows that $\check{u}$ is a subsolution to (1) as well (after decreasing $R$
even further if necessary to ensure $Q_{R}\in\Omega_{T}$). We now note that,
since $(w^{\ast}_{i})_{\ast}=w_{\ast,i}$, there exists by definition a
sequence
$(t_{n},x_{n},w^{\ast}_{i}(t_{n},x_{n}))\to(\hat{t},\hat{x},w_{\ast,i}(\hat{t},\hat{x}))$.
If we follow this sequence we thus find that
$\check{u}_{i}(t_{n},x_{n})=\tilde{w}_{i}(t_{n},x_{n})>w^{\ast}_{i}$ for some
point $(t_{n},x_{n})$ sufficiently close to $(\hat{t},\hat{x})$ (since
$\tilde{w}_{i}\to w_{\ast,i}+\delta>w_{\ast,i}$). Thus, we have constructed a
subsolution which is strictly greater than $w$, a contradiction.

What remains is to consider if $w_{\ast}$ fails to be a supersolution by
violating condition $(ii)$, i.e., if there exists
$(\hat{t},\hat{x})\in\partial\Omega_{T}$ and
$(a,p,X)\in\bar{\mathcal{P}}^{2,-}_{\Omega}w_{\ast}(\hat{t},\hat{x})$ s.t.

$\displaystyle\min\\{a+F_{i}(\hat{t},\hat{x},w_{\ast,i}(\hat{t},\hat{x}),p,X),w_{\ast,i}(\hat{t},\hat{x})-\mathcal{M}_{i}w_{\ast,i}(\hat{t},\hat{x})\\}\vee
B_{i}(\hat{t},\hat{x},w_{\ast,i}(\hat{t},\hat{x}),p)<0.$ (4.8)

However, if (4.8) holds, continuity of $f_{i}$ and the smoothness of
$\partial\Omega$ gives that $B_{i}(t,x,\tilde{w}(t,x),p)\leq 0$ (in the
classical sense and thus in the viscosity sense by Proposition 7.2 of [10])
for $(t,x)\in\partial\Omega$ and sufficiently close to $(\hat{t},\hat{x})$. We
then conclude as above that there exists $\delta,\beta$, and $R$ s.t.
$\tilde{w}$ satisfies the subsolution property (4.6) for $(t,x)\in\Omega_{T}$
sufficiently close to $(\hat{t},\hat{x})$ and thus that $\check{u}$ is a
subsolution. Again, we have constructed a subsolution which dominates
$w^{\ast}$, contradicting the very definition of $w$. The proof is complete.

Acknowledgement. The work of Marcus Olofsson was financed by the Swedish
research council grant 2018-03743. The work of Niklas Lundström was partially
financed by the same grant.

## References

  * [1] Aikawa, H., Kilpeläinen, T., Shanmugalingam, N., Zhong, X.: _Boundary Harnack principle for pharmonic functions in smooth Euclidean domains_ , Potential Anal. 26 (2007), 281–301.
  * [2] Barkhudaryan, R, Gomes, D.A., Shahgholian, H., Salehi, M. _System of variational inequalities with interconnected obstacles_ , Applicable Analysis, DOI:10.1080/00036811.2020.1757076 (2020).
  * [3] Barles G., _Fully non-linear Neumann type boundary conditions for second-order elliptic and parabolic equations_ , J. Differential Equations 106 (1) (1993) 90–106
  * [4] Biswas I. H., Jakobsen E. R., Karlsen K. H. _Viscosity solutions for a system of integro-PDEs and connections to optimal switching and control of jump-diffusion processes_ , Appl. Math. Optim., 62 (2010), pp. 47–80.
  * [5] Bourgoing M., _Viscosity solutions of fully non-linear second order parabolic equations with $L^{1}$ dependence in time and Neumann boundary conditions_, Discrete Contin. Dyn. Syst. 21 (3) (2008) 763–800.
  * [6] Dupuis P., Ishii H., _On oblique derivative problems for fully non-linear second-order elliptic equations on non-smooth domains_ , Nonlinear Analysis: Theory, Methods and Applications 15, (1990), 1123–1138.
  * [7] Dupuis P., Ishii H., _On oblique derivative problems for fully non-linear second-order elliptic PDEs on domains with corners_ , Hokkaido Mathematical Journal, (1991), 135-164.
  * [8] El-Asri B., Hamadene S.,, _The finite horizon optimal multi-modes switching problem: The viscosity solution approach_ , Applied Mathematics and Optimization 60, (2009), 213–235.
  * [9] Fuhrman M., Morlais M–A. _Optimal switching problems with an infinite set of modes: an approach by randomization and constrained backward SDEs_. Stochastic Processes and their Applications 130.5 (2020): 3120–3153.
  * [10] Crandall, M. G., Ishii, H., Lions, P.-L. _User’s guide to viscosity solutions of second order partial differential equations_ , Bulletin of the American Mathematical Society, 27 (1992), 1–67.
  * [11] Djehiche B., Hamadene S., Popier A., _A Finite Horizon Optimal Multiple Switching Problem_ , SIAM Journal on Control and Optimization 48, (2010), 2751–2770.
  * [12] Hamadene S., Morlais M. A., _Viscosity Solutions of Systems of PDEs with Interconnected Obstacles and Switching Problem_ , Applied Mathematics and Optimization 67, (2013), 163–196.
  * [13] Hu Y., Tang S., Multi–dimensional BSDE with Oblique Reflection and Optimal Switching, Probability Theory and Related Fields 147, (2010), 89–121.
  * [14] Ishii, H., Koike, S., _Viscosity solutions of a system on non-linear second-order elliptic PDEs arising in switching games_ , Funkcialaj Ekvacioj, 34 (1991), 143–155.
  * [15] Ishii H., Sato M.-H., _Nonlinear oblique derivative problems for singular degenerate parabolic equations on a general domain_ , Nonlinear Analysis: Theory, Methods and Applications 57 (2004), 1077–1098.
  * [16] Kharroubi I., Optimal Switching in Finite Horizon under State Constraints, SIAM Journal on Control and Optimization 54 (2016), 2202–2233.
  * [17] Klimsiak, T., _Systems of quasi-variational inequalities related to the switching problem_ , Stochastic Processes and their Applications 129 (2019), 1259–1286,
  * [18] Lundström N. L. P., Nyström K., Olofsson M., Systems of variational inequlities for non-local operators related to optimal switching problems: existence and uniqueness, Manuscripta Mathematica 145, (2014), 407–432.
  * [19] Lundström N. L. P., Nyström K., Olofsson M., Systems of variational inequalities in the context of optimal switching problems and operators of Kolmogorov type, Annali di Mathematica Pura ed Applicata 193, (2014), 1213–1247.
  * [20] Lundström N. L. P., Olofsson M., Önskog T. _Existence, uniqueness and regularity of solutions to systems of nonlocal obstacle problems related to optimal switching_ , Journal of Mathematical Analysis and Applications 475.1 (2019): 13–31.
  * [21] Lundström N. L. P., Olofsson M., Önskog T. _Management strategies for run-of-river hydropower plants – an optimal switching approach_ , arXiv preprint arXiv:2009.10554 (2020).
  * [22] Lundström N. L. P., Önskog T. _Stochastic and partial differential equations on non-smooth time-dependent domains_ , Stochastic Processes and their Applications 129.4 (2019): 1097–1131.
  * [23] Reisinger C., Zhang Y., _Error estimates of penalty schemes for quasi-variational inequalities arising from impulse control problems_. SIAM Journal on Control and Optimization 58.1 (2020): 243–276.