\documentclass[english, twocolumn, 10pt, aps, superscriptaddress, floatfix, prb, citeautoscript]{revtex4-1}
\pdfoutput=1
\usepackage{xr}
\externaldocument{zigzag}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{verbatim}
\usepackage{units}
\usepackage{mathtools}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{graphicx}
\usepackage{wasysym}
\usepackage{layouts}
\usepackage{siunitx}
\usepackage{bm}
\usepackage{xcolor}
\usepackage[colorlinks, citecolor={blue!50!black}, urlcolor={blue!50!black}, linkcolor={red!50!black}]{hyperref}
\usepackage{bookmark}
\usepackage{tabularx}
\usepackage{microtype}
\usepackage{babel}
\hypersetup{pdfauthor={Quantum Tinkerer},pdftitle={Enhanced proximity effect in zigzag-shaped Majorana Josephson junctions.}}

\setcounter{secnumdepth}{4}
\setcounter{tocdepth}{4}

\DeclareMathOperator{\e}{e}
\DeclareMathOperator{\de}{d\!}
\DeclareMathOperator{\Tr}{Tr}
\DeclareMathOperator{\diag}{diag}
\DeclareMathOperator{\Res}{Res}
\DeclareMathOperator{\sgn}{sgn}
\DeclareMathOperator{\Pf}{Pf}
\DeclareMathOperator{\Det}{Det}
\DeclareMathOperator{\rank}{rank}
\DeclareMathOperator{\im}{Im}
\DeclareMathOperator{\re}{Re}

\renewcommand{\comment}[2]{#2}
% Uncomment the following line for paragraph descriptions to appear in the file.
% \renewcommand{\comment}{\paragraph}

\DeclarePairedDelimiter\abs{\lvert}{\rvert}
\DeclarePairedDelimiter\norm{\lVert}{\rVert}

\makeatletter
\let\oldabs\abs
\def\abs{\@ifstar{\oldabs}{\oldabs*}}
\let\oldnorm\norm
\def\norm{\@ifstar{\oldnorm}{\oldnorm*}}
\makeatother

\newcommand{\ev}[1]{\langle#1\rangle}
\newcommand{\bra}[1]{\langle#1|}
\newcommand{\ket}[1]{|#1\rangle}
\newcommand{\bracket}[2]{\langle#1|#2\rangle}

\newcolumntype{L}[1]{>{\raggedright\arraybackslash}p{#1}}
\newcolumntype{C}[1]{>{\centering\arraybackslash}p{#1}}
\newcolumntype{R}[1]{>{\raggedleft\arraybackslash}p{#1}}

\begin{document}

\appendix

\section{Zigzag devices and disorder}\label{appendix:mfp_vs_gap}

\comment{We compare $E_\textrm{gap}(l_e)$ for zigzag and straight systems at $\phi=0$ and $\phi=\pi$; and confirm that the zigzag and disorder both increase $E_\textrm{gap}$ through a similar mechanism.}
The right amount of disorder improves the Majorana properties~\cite{Haim2019} and scatters long trajectories in a similar fashion to the zigzag geometry cutting off long trajectories.
We simulate devices with disorder---parameterized by its mean free path $l_e$---and calculate $E_\textrm{gap}(l_e)$ for straight and zigzag devices at different phases and magnetic fields, see Fig.~\ref{fig:mfp_vs_gap}.
For the parameters we chose, at $\phi=0$ we observe that an optimal value of $l_e$ results in an enhancement that is at best equal to that of the zigzag device.
At $\phi=\pi$ we observe that zigzag geometry outperforms disorder.

\begin{figure}[!htb]
\centering
\includegraphics[width=0.9\columnwidth]{figures/mfp_vs_gap.pdf}
\caption{Comparison of the gap of zigzag devices (dashed lines) and straight devices (solid lines) as function of mean free path $l_e$.
Each $E_\textrm{gap}$ value is averaged over 40 disorder realizations and is calculated using a translationally invariant system where the unit-cell is $L_x=3z_x$, with $z_x=\SI{1300}{\nm}$.
\label{fig:mfp_vs_gap}}
\end{figure}

\section{Zigzag device with a single superconductor}\label{appendix:NS_junction}

\comment{We run the simulation and observe that the phase diagrams are the same but the zigzag device is still better.}
A zigzag-shaped device with a single superconductor shows a similar enhancement of the superconducting gap as the Josephson junction devices.
We demonstrate this by simulating a straight and a zigzag device and computing $E_\textrm{gap}(B_x, \; \mu)$ in Fig.~\ref{fig:ns_junction}.
We observe that the order of magnitude increase of $E_\textrm{gap}$ also occurs upon the introduction of a zigzag geometry.

\begin{figure}[!htb]
\centering
\includegraphics[width=0.9\columnwidth]{figures/phasediagrams_NS.pdf}
\caption{Same as Fig.~\ref{fig:phasediagrams} (c) and (d) but with one superconductor instead of two.
We observe that the zigzag geometry also increases the gap in this case.
\label{fig:ns_junction}}
\end{figure}

\section{Direction of the magnetic field}\label{appendix:direction_B}

\comment{Zigzag geometry removes the need for precise field alignment.}
Because the zigzag geometry cuts off long trajectories---leaving only short trajectories---this device requires a less precise alignment of the magnetic field.
To show this, we perform a simulation of a straight and zigzag device with a rotated field (see Fig.~\ref{fig:tilted_angle_phase_diagram}).
We observe that the zigzag device still has a sizeable gap with a $10^\circ$ misaligned magnetic field, wherea a $1^\circ$ misalignment makes a straight device gapless.

\comment{Likewise a inhomogeneous magnetic field does not matter.}
Strong screening of the magnetic field by the superconductors may distort the magnetic field pattern.
To determine whether this effect degrades the device quality, we simulate a device with the magnetic field parallel to the NS interface, shown in Fig.~\ref{fig:syst_snaking_magnetic_field}.
We find that the resulting gap is comparable to that of a device with the magnetic field purely in the $x$-direction, as shown in Fig.~\ref{fig:snaking_magnetic_field}.

\begin{figure}[!htb]
\centering
\includegraphics[width=0.9\columnwidth]{figures/tilted_angle_phase_diagram.pdf}
\caption{The topological gap as a function of the magnetic field magnitude $B$ and its angle $\theta=\arctan{B_y/B_x}$ for a straight device (a) and a zigzag device (b).
Note that the colormaps and the $\theta$-axes differ between panels: the zigzag-shaped device becomes gapless at $\theta$ an order of magnitude larger compared to the straight device.
\label{fig:tilted_angle_phase_diagram}}
\end{figure}

\begin{figure}[!htb]
\centering
\includegraphics{figures/syst_snaking_magnetic_field.pdf}
\caption{
The magnetic field pattern emulating strong screening by the superconductors.
\label{fig:syst_snaking_magnetic_field}}
\end{figure}

\begin{figure}[!htb]
\centering
\includegraphics{figures/snaking_magnetic_field.pdf}
\caption{
Comparison of the zigzag device's band structures with the magnetic field following the shape of the junction (orange) (see Fig.~\ref{fig:syst_snaking_magnetic_field}) and a magnetic field in the $x$-direction (blue) for different values of $z_y$.
\label{fig:snaking_magnetic_field}}
\end{figure}

\section{Interface transparency vs.~path length cut-off}

The zigzag geometry both increases the interface transparency (because particles typically hit the superconductor
closer to normal incidence) as well as sets an upper limit to the trajectory length.
The change in the interface transparency alone is not sufficient to explain the increase of the topological gap.
To verify this, we compute the dispersion of a system with $z_x = z_y = \SI{80}{\nm}$ comparable to the Fermi wavelength $\lambda_\textrm{F}$ and $W=\SI{400}{\nm}$, so that the angle of the boundaries is sufficiently large, but the boundary modulation is much smaller than the width.
We observe that $E_\textrm{gap}$ becomes $\SI{6.1}{\mu \eV}$, a two-fold increase compared to the straight system, not the order of magnitude increase resulting from the cutting off of long trajectories.

\bibliographystyle{apsrev4-1}
\bibliography{zigzag}

\end{document}


%\index{M7!history}
The documented aerosol modules (Sulphate, BCOC, DUST, SALT) produce
aerosols independent of each other. Nitrate is somewhat special since
it depends on SALT and sulphate, and sulphate depends on the
tropospheric chemistry.

M7 tries to put the aerosol packages together. The inclusion of M7
builds on this approach in the following way:
\begin{enumerate}
  \item All the separate modules are left untouched.
  \item If M7 is activated the emissions of the components which
    are concerned by M7 are transferred to a new array and the
    original emission arrays become irrelevant.
  \item All the M7 tracers have their own loss terms depending
    on the microphysics.
\end{enumerate}

You turn on the M7 application by setting \verb#M7 := Y# in
\makefile. Running the aerosol modules separately is of coarse good if
you want to save CPU time and only want to run 8 carbon tracers
instead of full chemistry/sulfate/M7 run.

% Physics
\subsection{Physics}
\index{M7!physics}
M7 is a microphysical model. This means that it's purpose is to
calculate interaction between different types of aerosols. The output
is the size of the aerosols and their mixing state (i.e. water soluble
or insoluble). M7 splits the aerosol size distribution into the
following size distributed modes
\begin{itemize2}
  \item Nucleation mode, water soluble, size: $\sim 1 nm$
  \item Aitken mode, water soluble,  size: $\sim 0.01 {\mu}m$
  \item Accumulation mode, water soluble, size: $\sim 0.1 {\mu}m$
  \item Coarse mode, water soluble, size: $\sim 1 {\mu}m$
  \item Aitken mode, insoluble,  size: $\sim 0.01 {\mu}m$
  \item Accumulation insoluble, size: $\sim 0.1 {\mu}m$
  \item Coarse mode, insoluble, size: $\sim 1 {\mu}m$
\end{itemize2}

{\bf Important}\\
{\bf M7 does not treat semivolatile aerosol species} like nitrate or
secondary organics. This is both a good thing and a bad thing. It is
good because it greatly  reduces the complexity of the problem, and it
is bad because.. well... you can not calculate the effect these
tracers would have on aerosol microphysics.

% M7 tracers
\subsection{M7 tracers}
\index{M7!tracers}
The M7 tracers are listed in Table \ref{tbl:m7tracers}.

\begin{table*}
\caption{Tracers included in the M7 model. All the aerosol species
  (250--274) have lifetimes of days-weeks and they all need to be
  transported. Water species (275--278) are in equilibrium (see below)
  and should not be transported. Soluble species (except water) are
  washed out in convection. There are 17 soluble species in M7.}
\label{tbl:m7tracers}
\begin{minipage}{\linewidth}
\begin{tabular}{|c|l|l|c|c|}
\hline
Nr  & Component name & Remarks                 & Soluble   &  Transport \\
\hline \hline
80  & SO4GAS     &  Gas phase sulf. acid       &  N/A (No) & No\\
\hline
250 & SO4NUC     &    nucleation mode sulphate &  Yes      &  Yes\\
\hline
251 & SO4AT      &    aitken mode sulphate     &  Yes      &  Yes\\
\hline
252 & SO4AC      &    accumulation mode sulphate &  Yes    &  Yes\\
\hline
253 & SO4CRS     &    coarse mode sulphate  &  Yes       &  Yes\\
\hline
254 & BCKS       &  aitken mode soluble BC  &  Yes       &  Yes\\
\hline
255 & BCAS       &    accumulation mode BC  &  Yes       &  Yes\\
\hline
256 & BCCS       &    coarse mode BC        &  Yes       &  Yes\\
\hline
257 & BCKI       &    aitken mode BC        &  No        &  Yes\\
\hline
258 & OCKS       &    aitken mode OC        &  Yes       &  Yes\\
\hline
259 & OCAS       &    accumulation mode OC  &  Yes       &  Yes\\
\hline
260 & OCCS       &    coarse mode OC        &  Yes       &  Yes\\
\hline
261 & OCKI       &    aitken mode OC        &  No        &  Yes\\
\hline
262 & SSAS       & accumulation mode Seasalt &  Yes      &  Yes\\
\hline
263 & SSCS       &  coarse mode seasalt      &  Yes      &  Yes\\
\hline
264 & DUAS       &    accumulation mode dust  &  Yes     &  Yes\\
\hline
265 & DUCS       &    coarse mode dust        &  Yes     &  Yes\\
\hline
266 & DUAI       &    accumulation mode dust  &  No      &  Yes\\
\hline
267 & DUCI       &   coarse mode dust        &  No       &  Yes\\
\hline
268 & NNUC       &    Nucleation mode number &  Yes      &  Yes\\
\hline
269 & NKS        &    Aitken mode number      &  Yes     &  Yes\\
\hline
270 & NAS        &    Accumulation mode number  &  Yes   &  Yes\\
\hline
271 & NCS        &   coarse mode number        &  Yes    &  Yes\\
\hline
272 & NKI        &   aikten mode number      &  No       &  Yes\\
\hline
273 & NAI        &    accumulation mode number  &  No    &  Yes\\
\hline
274 & NCI        &   Coarse mode number         & No     &  Yes\\
\hline
275 & H2ONUC     &   nucleation mode water      &  Yes   &  No\\
\hline
276 & H2OKS      &  aitken mode water           &  Yes   &  No \\
\hline
277 & H2OAS      &  accumulation mode water     & Yes    &  No\\
\hline
278 & H2OCS      &  coarse mode water           & Yes    &  No \\
\hline
\end{tabular}
\end{minipage}
\end{table*}

Thus, when running M7, you need 51 tracers from tropospheric
chemistry, 7 from sulfate and one extra (\verb#SO4GAS#), and further
you need the 8 BC/OC species, which are not transported or washed
out. The tracers washed out in convection are all the
water-soluble. Table \ref{tbl:tracerm7} shows in more detail the
tracers need for running M7.

\begin{table}
\caption{Explanation of the number of tracers needed for running
  M7. Note that several tracers are dummy tracers (the 8 of BCOC, the
  2 of dust, the 2 of salt). These tracers are handled by the 25 M7
  tracers when running M7. The sulphate species are converted
  immediately to M7 species. The number in parenthesis for
  Transport indicates the  number of tracers if you exclude the
  tracers labeled \textcolor{red}{\it Maybe} in Table
  \ref{tbl:tropcomp}.}
 \label{tbl:tracerm7}
\begin{minipage}{\linewidth}
\begin{tabular}{|l|c|c|c|}
\hline
Application      & Tracers  & Transport  & Washout \\
\hline
TROPCHEM         &  51      &  40 (35)   &  8 \\
\hline
SALT             &  2\footnote{dummy tracers} &  0   &  0 \\
\hline
DUST             &  2\footnote{dummy tracers} &  0   &  0 \\
\hline
SULPHATE\footnote{no transport or washout of old $SO_4$}
                 & 7        &  4          &  3 \\
\hline
SO4GAS           &  1       &  0          &  0 \\
\hline
BCOC             &  8\footnote{dummy tracers}  &  0   &  0 \\
\hline
M7               &  25      &  25         &  17 \\
\hline
M7(water)        &  4       &  0          &  0 \\
\hline
\hline
SUM              & 100      &  69 (64)    &  28 \\
\hline
\end{tabular}
\end{minipage}
\end{table}

\subsection{Technical information}
\index{M7!technical information}

The M7 model is activated by the logical switch LM7. This logical
variable currently has to be set in the main program. When this
logical switch is activated, the emissions calculated for the
M7-relevant components are removed from the \verb#POLLX# array and put
in the \verb#PRODM7# array.

The idea is that the old aerosols tracers still exist in the
model. However, they are in a way irrelevant if M7 is used and there
is no need for transporting them.

\subsection{Interaction with other parts of aerosol codes}
\index{M7!aerosol code interaction}

\subsubsection{Carbon particles}
\index{M7!carbon particles}
The carbon particles in their old form should not be transported if M7
is used. However, they should be included as tracers in the \inptrctm\
file.

If the logical LM7 is recognized by the model, the emissions of BC
and OC are put into the \verb#prodm7# array and enters the M7 tracer
list. They are not put into the places they have as BC/OC tracers as
described in section \ref{sxn:bcoc}.

\subsubsection{Sulphate model}
\index{M7!sulphate model}
M7 needs explicit input about how much sulphate is formed in gas phase
and how much is formed in the aqueous phase. Therefore, another
tracer, number 80, \verb#SO4gas# is used when M7 is used.
The tracer which represents sulphate in the sulphate application (see
chapter \ref{sxn:sulphate}) which is tracer number 73 is only
representing aqueous phase sulphate when M7 is used.

There is no need for transporting the sulphate tracers since the mass
produced in the sulphate tracers are moved to the M7-tracers in the
same timestep. These tracers are later the ones being transported and
being lost by dry- and wet deposition.

\subsubsection{Dust and Seasalt models}
\index{M7!dust and seasalt models}

The dust and seasalt models are activated when it finds tracers
named \verb#SALTXX# or \verb#DUSTXX# (where \verb#XX# is bin number)
in the standard version (see more description in section
\ref{sxn:dust} and \ref{sxn:salt}. To not re-organize the code too
much, this feature is kept, and you still need tracers called
\verb#DUST01# and \verb#SALT01# to be able to run these modules.

However, when running M7, the standard versions of these codes are
no longer relevant. Therefore, you need 2 dust species and 2 salt
species to activate the model. These species have to be listed in
\inptrctm\ {\bf but they do not need to be transported}.

\subsubsection{Salt model}
\label{sxn:salt2m7}\index{M7!seasalt model}

The logical variable LM7 is sent directly into the salt model.
If the salt model recognizes this variable as TRUE, it will
not care about fall speeds and dry deposition, but only output
the emissions into the \verb#prodm7# array.

In the case of LM7 being true in the seasalt application, a production
routine giving modal emissions are being activated. This is different
from the standard model in the way that in the standard model,
the production routines distributes the production to size bins.

\subsubsection{Dust model}
\index{M7!dust model}

When using M7, the whole DUST model (DEAD) is still run. This is
strictly not necessary since M7 does not really care about what
happens in DEAD except for one thing: It wants the emissions.

It would have been possible to send the logical LM7 to the dust model
and only output the emissions if M7 is used, and not call the
deposition routines in a similar way to what is done for the salt
model (section \ref{sxn:salt2m7}. However: In the case of dust,
the complete call to DEAD  kept because of the following reasons
\begin{itemize}
  \item The dust code is more complicated than the salt code and
    sending around the logical LM7 in it could be messy.
  \item DEAD is not developed at UiO, and if anyone wants to upgrade
    to a more recent version of DEAD, it would be easier not having to
    re-code it using the variable LM7 also.
\end{itemize}

The code to DEAD will update the concentrations of the tracer
\verb#DUST01# which should not transported in CTM2. However, DEAD also
puts the emissions in a 2D field which can be accessed with the
subroutine \verb#dustfield2main#.

All that is needed to include dust in M7 is the call to
\verb#dustfield2main# and fetch the emissions. These are then
processed in the \verb#prodm7# variable.


\subsection{Excitation laser power optimization}
\label{subsec:power_optim}

Firstly, we tried to establish the optimal laser power for excitation in
right-angle geometry using a spinning cell.
We used commercial samples of polyU (Sigma) dissolved in 80\,mM cacodylate
buffer with ph 6.4 to the concentration of 500\,\g{m}M per nucleobase.
We chose 244\,nm excitation laser wavelength with 10, 2, and 1 mW at samples.
The 150\,\g{m}L of the sample was rotated at 9600\,rpm during the measurement.
The spectral series were measured with 30\,s (10 and 2\,mW excitation) and
60\,s (1\,mW excitation) accumulation time per spectrum.
The beginning of each measurement was slightly delayed from the start of
the exposure to the laser because the samples needed to be adjusted for
optimal signal.
The adjustment took 26\,s for 10\,mW excitation, 90\,s for 2\,mW, and 69\,s
for 1\,mW excitation.

Further analysis was performed on the integral intensity of measured Raman
bands.
The band shapes were modeled as described in
\cref{band_intensities}
with the experimentally estimated Lorentzian curve fraction coefficient
$c_\text{L} = 0.5$, which visually gave the best band shape fit.
The linear function $a_0 + a_1\wn$ was added to the shape function
\eqnref{band_intensities:shape}
as the model of the spectral background.

The analysis was performed on the polyU integral intensity represented by
its band at 1231\,\icm{} compared to the intensity of the cacodylate band at
607\,\icm{} to account for the excitation laser power and sample adjustment
variations during the measurement.
\Figref{power_optim:triplexes_pU}
clearly shows that the polyU band also contains a shoulder at 1248\,\icm{}, and
is overlapping with the cacodylate band at 1276\,\icm.
Therefore, the band was modeled by the shape function
(\eqnref{band_intensities:shape})
with three components, but its intensity was calculated as a sum of the pulyU
bands without the cacodylate one.
The cacodylate band was modeled as having two components, at 607 and 640\,\icm,
but only the first one was used for the integral intensity calculation.

\begin{figure}
	\centering
	\input{results_and_discussion/assets/power_optimization_triplexes/%
		power_optimization_triplexes_pU}
	\caption[%
		Example UV RR spectrum of polyU dissolved in cacodylate buffer.%
	]{%
		\captiontitle{%
			Example UV RR spectrum of polyU dissolved in cacodylate buffer.%
		}
		The fits of shape functions
		(\eqnref{band_intensities:shape})
		to the bands of polyU and cacodylate used in intensity estimation fit are
		marked by green, and red lines, respectively, and the areas used for
		intensity calculation are filled with the corresponding colors.
	}
	\label{\figlabel{power_optim:triplexes_pU}}
\end{figure}

The time dependence of the intensity of polyU band at 1231\,\icm{} (normalized
to the intensity of cacodylate band at 607\,\icm) was modeled by the
exponential decay curve
\begin{equation}
	I = I_0 \text{e}^{-\lambda t} + b,
	\label{\eqnlabel{power_optim:decay}}
\end{equation}
where $I_0$ is initial intensity, $\lambda$ is the decay constant, and $b$ is
the baseline constant.
The normalized results (subtracted by $b$) can be seen in
\figref{power_optim:triplexes}.

\begin{figure}
	\centering
	\input{results_and_discussion/assets/power_optimization_triplexes/%
		power_optimization_triplexes}
	\caption[%
		Decrease of the integral intensity of polyU band at 1231\,\icm{} for
		different excitation laser powers in raw spectra.%
	]{%
		\captiontitle{%
			Decrease of the integral intensity of polyU band at 1231\,\icm{} for
			different excitation laser powers in raw spectra.%
		}
		It was normalized to the integral intensity of the cacodylate band at
		607\,\icm{}, which was used as the internal intensity standard.
		The values were fitted by exponential decay curves
		\eqnref{power_optim:decay}
		and the baseline constant $b$ from the fit was subtracted from the plots.
	}
	\label{\figlabel{power_optim:triplexes}}
\end{figure}

We can see, that the lines intersect almost at the same point, which is
expected outcome, but this point is not at 0\,s.
This is caused by the fact that the time axis denotes the ends of the spectrum
accumulation, whereas the intensity comes from the whole time period of the
spectrum acquisition, which is even more enhanced by the fact that band's
intensity lowers during the measurement.
The lifetimes $\tau$ can be calculated from decay constants $\lambda$ from
\eqnref{power_optim:decay}
\begin{equation}
	\tau = \frac{1}{\lambda}.
	\label{\eqnlabel{power_optim:lifetime}}
\end{equation}
We can also calculate total accumulated relative energy from the decay curve
by
\begin{equation*}
	E_{0,\text{r}}
		= \int_0^{\infty}{I_0 \text{e}^{-\lambda t}\text{d}t}
		= \frac{I_0}{\lambda}
\end{equation*}
and energy accumulated from time $T_0$ by
\begin{equation*}
	E_r	= \int_{T_0}^{\infty}{I_0 \text{e}^{-\lambda t}\text{d}t}
		= \frac{I_0}{\lambda} \text{e}^{-\lambda T_0}.
\end{equation*}
Energy fractions can then be calculated by dividing the relative energies by
the maximal total relative energy. The resulting lifetimes, total accumulated
energy fractions $E_0$, and energy fractions $E$ accumulated from time
$T = 60\pm20$\,s, which was regarded as reasonable approximate for the time
needed for adjustment of the sample before measurement could start, can be
seen in
\tabref{power_optim:lifetimes_triplexes}.

\begin{table}
	\centering
	\input{results_and_discussion/assets/power_lifetimes_triplexes}
	\caption[%
		Lifetimes of polyU in dependence on excitation power estimated from raw
		spectra.%
	]{%
		\captiontitle{%
			Lifetimes $\tau$ of the polyU in dependence on excitation power $P$
			estimated from raw spectra.%
		}
		$E_0$ are total energies accumulated by detector divided by maximal value
		across all the excitation powers $P$, and $E$ are energies accumulated from
		time $T = 60\pm20$\,s, which was needed for the adjustment of the
		samples before the acquisition can even start, but the sample needs to be
		irradiated by the excitation laser.
		The last column contains fractions of the samples $r$ which were not
		destroyed by photodecomposition after the time $T$.
	}
	\label{\tablabel{power_optim:lifetimes_triplexes}}
\end{table}

The results show that the 10\,mW power gave the best results if we do not take
into account adjustment of the samples, but as you can see in
\figref{power_optim:triplexes},
the signal intensity quickly lowers with time.
The lifetimes can also vary significantly in dependence on a sample which can
lower the reliability of the band intensity estimations.
The table shows that, after 1-minute adjustment of the sample, the 10\,mW
excitation photodecomposes about 35\% of the sample, whereas, with the 1\,mW
excitation, only around 6\% of the sample is destroyed.
The accumulated energies are calculated as integral to infinity, but we can
effectively measure only smaller portions of the decay with lower powers,
favoring measurements with higher powers.

Further investigation of the spectral decay behavior shows that this simple
approach does not reveal that a single decay curve cannot model such a complex
system.
This effect is clearly visible if we subtract the cacodylate buffer background
from the spectra.
The resulting spectrum can be seen in
\figref{power_optim:triplexes2_pU}.

\begin{figure}
	\centering
	\input{results_and_discussion/assets/power_optimization_triplexes2/%
		power_optimization_triplexes2_pU}
	\caption[%
		Example UV RR spectrum of polyU dissolved in cacodylate buffer with
	  the cacodylate buffer background subtracted.%
	]{%
		\captiontitle{%
			Example UV RR spectrum of polyU dissolved in cacodylate buffer with
			the cacodylate buffer background subtracted.%
		}
		The fit of shape function
		(\eqnref{band_intensities:shape})
		to the band of polyU used in intensity estimation fit is marked by a green
		line together with the area used for the intensity calculation.
	}
	\label{\figlabel{power_optim:triplexes2_pU}}
\end{figure}

The polyU band at 1230\,\icm{} can then be modeled directly without the
interference of the cacodylate band at 1276\,\icm{}.
It can be seen from the polyU band intensity dependence plot in
\figref{power_optim:triplexes2}
that the background subtraction process slightly obscures the intensity
normalization so that the fast decay curves cannot be modeled here.
However, we can also see a slower decay trend which is not evident from the fit
to the intensities of the polyU band calculated from the spectra without
subtracted background.
This is caused by the fact that it is harder to reliably decouple
the contribution of the overlapping polyU and cacodylate bands with the
lowering polyU band intensity.

\begin{figure}
	\centering
	\input{results_and_discussion/assets/power_optimization_triplexes2/%
		power_optimization_triplexes2}
	\caption[%
		Decrease of the integral intensity of the polyU band at 1231\,\icm{}
		for different excitation powers in background-corrected spectra.%
	]{%
		\captiontitle{%
			Decrease of the integral intensity of the polyU band at 1231\,\icm{}
			for different excitation powers in background-corrected spectra.%
		}
		The intensity was normalized to the subtracted spectrum of cacodylate
		buffer, which was used as the internal intensity standard.
		The values were fitted by exponential decay curves
		\eqnref{power_optim:decay}.
		The baseline constant $b$ from the fit was subtracted from the plots.
	}
	\label{\figlabel{power_optim:triplexes2}}
\end{figure}

For analysis of the optimal measurement conditions, we ignored the first 3, 3,
and 10 spectra for excitations at 1, 2, and 10\,mW, respectively, which visibly
deviated from the slow decay curves.
We used
\eqnref{power_optim:decay}
to estimate the lifetime $\tau$, total accumulated energy fractions $E_0$, and
energy fractions $E$ accumulated from time $T = 60\pm20$\,s the same way as
for the samples without subtracted background (see
\tabref{power_optim:lifetimes_triplexes2}).
The baseline constant $b$ was used only for the power of 10 mW, where it
decayed quickly to constant noise caused by the fit for an almost undetectable
band.
The table clearly shows that the slow decay process depends linearly on
excitation power.
In other words, the total accumulated energy is the same for all the
excitation powers, and that the lifetime is inversely related to the excitation
power.

\begin{table}
	\centering
	\input{results_and_discussion/assets/power_lifetimes_triplexes2}
	\caption[%
		Lifetimes of the polyU in dependence on excitation power estimated from
		the background-corrected spectra.%
	]{%
		\captiontitle{%
			Lifetimes $\tau$ of the polyU in dependence on excitation power $P$
			estimated from the background-corrected spectra.%
		}
		$E_0$ are total energies accumulated by detector divided by maximal value
		across all the excitation powers $P$, and $E$ are energies accumulated from
		the time $T = 60\pm20$\,s, which was needed for the adjustment of the
		samples before the acquisition can even start, but the sample needs to
		be irradiated by the excitation laser.
		The last column contains fractions of the samples $r$ that were not
		destroyed by photodecomposition after time $T$.
	}
	\label{\tablabel{power_optim:lifetimes_triplexes2}}
\end{table}

We can see that the system is complex, and our current methods cannot correctly
analyze the underlying processes.
Photoproducts can influence the resulting spectra, and therefore we
decided to use relatively lower excitation powers like 1\,mW or 0.5\,mW even
though the higher excitation power could probably give higher quality spectra.

We also tried to optimize the excitation laser power for the backscattering
measurements in thermostated cell holder.
We used 3\,mL of 125\,\g{m}M polyU samples dissolved in 40\,mM cacodylate
buffer with pH 6.8.
257\,nm was used as an excitation laser wavelength and a magnetic stirred
stirred the samples.
The spectral series was measured in 20\,s accumulation time per
spectrum.
The measurements in the thermostated cell holder were easier to set up
because the backscattering geometry and robust construction of the holder
were less sensitive to displacements which meant that the adjustments could be
performed on helper samples and, the real samples weren't exposed to the
laser power before measurement.

The analysis of the results was performed with the same steps as the analysis
of the measurements with a spinning cell using the integral intensity of the
polyU band at 1231\,\icm{} and the cacodylate band at 607\,\icm{}.
As we used 20 times
larger volumes of samples and 4 times lower concentrations, we should roughly
expect 5 times longer lifetimes, which means that we could observe only the
fast decay components, (see
\figref{power_optim:hairpins}
and
\tabref{power_optim:lifetimes_hairpins}).

\begin{figure}
	\centering
	\input{results_and_discussion/assets/power_optimization_hairpins/%
		power_optimization_hairpins}
	\caption[%
		Decrease of the integral intensity of the polyU band at 1231\,\icm{}
		for different excitation laser powers in raw spectra using
		backscattering geometry.%
	]{%
		\captiontitle{%
			Decrease of the integral intensity of the polyU band at 1231\,\icm{}
			for different excitation laser powers in raw spectra using
			backscattering geometry.%
		}
		It was normalized to the integral intensity of the cacodylate band at
		607\,\icm{}, which was used as the internal intensity standard.
		The values were fitted by exponential decay curves
		\eqnref{power_optim:decay}.
		The baseline constant $b$ from the fit was subtracted from the plots.
	}
	\label{\figlabel{power_optim:hairpins}}
\end{figure}

\begin{table}
	\centering
	\input{results_and_discussion/assets/power_lifetimes_hairpins}
	\caption[%
		Lifetimes of the polyU in dependence on excitation power
		estimated from raw spectra in backscattering geometry.%
	]{%
		\captiontitle{%
			Lifetimes $\tau$ of the polyU in dependence on excitation power $P$
			estimated from raw spectra in backscattering geometry.%
		}
		$E_0$ are total energies accumulated by detector divided by maximal value
		across all the excitation powers $P$.
	}
	\label{\tablabel{power_optim:lifetimes_hairpins}}
\end{table}

It can be seen that the lifetimes are proportionally longer with lower
excitation laser power and no further special effects are observable.
The lifetimes are slightly lower than the expected 5 times longer lifetimes as
compared to the
\tabref{power_optim:lifetimes_triplexes}
but almost in the range of estimated errors.
It can be caused by many effects like underestimated errors, different
excitation laser wavelength (257\,nm instead of 244\,nm), less effective
stirring in larger volumes, or longer laser path in the samples.
We can also see that higher intensity gives more reliable results with
lower errors because of a better SNR.
We decided to perform further measurements with 4\,mW of excitation power at
257\,nm and 5\,mW at 244\,nm.


% !TEX root = ../zeth-protocol-specification.tex

\section{Generating the inputs of the $\mix$ function (\inp{\mix})}\label{zeth-protocol:mix-inp}

In the following section, we assume that the system is initialized. In other words, we assume that a ledger $\ledger$ is available (i.e.~an \ethereum~network is operated by a set of miners), the $\mixer$ contract is deployed on $\ledger$. Likewise, we assume that the public parameters $\pparams_{\zksnark} \gets \zksnark.\kgen(\secparam, \RELCIRC)$ are available to $\mixer$ and to all parties willing to call the $\mix$ function of $\mixer$. Furthermore, we assume that there exists a set of \ethereum~and \zeth~users, and that the \emph{payment address} of each \zeth~user is easily discoverable. In the rest of this section, the set of \emph{payment addresses} discovered by a zeth user $\zparty{U}$ is represented as a list attribute $\zparty{U}.\keystore$ indexed by usernames.

\medskip

In order for $\zparty{U}$ to transact via \zeth, $\zparty{U}$ needs to create an object $\inp{\mix}$ of type $\mixInputDType$ to pass to the $\mix$ function of $\mixer$:
\begin{enumerate}
    \item Create an object $\priminputs$ of type $\primInputDType$ to represent the primary input, and an object $\auxinputs$ of type $\auxInputDType$ to represent the auxiliary input, where:
    \begin{enumerate}
        \item $\priminputs.\mkroot \in \rootset$, where $\rootset$ is the set of \emph{all} Merkle roots corresponding to one of the state of the Merkle tree on $\mixer$ containing \emph{all} the commitments to the input notes, in $\auxinputs.\jsins{}$, in its set of leaves.
        \item $\auxinputs.\znotes{j}.\noter \sample \BB^{\noterLen}, \forall j \in [\jsout]$, and $\auxinputs.\pphi \sample \BB^{\phiLen}$
        \item The public values $(\auxinputs.\vin, \auxinputs.\vout) \in {(\BB^{\zvalueLen})}^{2}$, $\auxinputs.\znotes{j}.\notev$ and $\auxinputs.\znotes{j}.\apk\ \forall j \in [\jsout]$ are all set by the sender, $\zparty{U}$, as desired as long as they satisfy the \gls{joinsplit-eq}.
        \item All attributes of the $\priminputs$ and $\auxinputs$ objects should be derived as specified in the statement (see~\cref{zeth-protocol:statement}), alongside a signature hash ($\auxinputs.\hsig$) that is generated as the hash of the nullifiers and a one-time signing verification key (non-malleability, see~\cref{appendix:trnm}), using the desired signature scheme $\otsigscheme$ (see~\cref{instantiation:otsig}):
            \begin{align}
                & (\sk_{\otsig}, \vk_{\otsig}) = \otsigscheme.\kgen(\secparam) \label{zeth-protocol:otsig-generation} \\
                & \auxinputs.\hsig = \crhhsig{\indexedset{\auxinputs.\jsins{i}.\nf{}}{i \in [\jsin]}, \vk_{\otsig}}
            \end{align}
        \item $\inp{\mix}.\primInp \gets \priminputs$
    \end{enumerate}
    \begin{notebox}
        If one of the attributes of $\priminputs$ and $\auxinputs$ is not correctly generated, then the proof of computational integrity generated in the next step will be rejected on $\mixer$, and the state of $\mixer$ will not be modified.
    \end{notebox}
\item Generate a zk-SNARK proof \zkp~to prove, in zero-knowledge, that the relation $\RELCIRC$ (\cref{zeth-protocol:statement}) holds on the primary and auxiliary inputs, using the desired zk-SNARK scheme $\zksnark$ (see~\cref{instantiation:zksnark}):
    \begin{enumerate}
        \item $\zkp \gets \zksnark.\prover(\pparams_{\zksnark}, \priminputs, \auxinputs)$
        \item $\inp{\mix}.\zkproof \gets \zkp$
    \end{enumerate}

\item Encrypt all the $\auxinputs.\znotes{}$ using the recipient's \emph{payment address}, using the encryption scheme $\encscheme$ (see~\cref{instantiation:enc}).
    \begin{enumerate}
        \item For all $j \in [\jsout]$, do:
        \begin{align*}
            & \ct_j \gets \encscheme.\enc(\auxinputs.\znotes{j}, \zparty{U}.\keystore[\varstyle{recipient}_j].\pubaddr.\pkenc)
        \end{align*}
        \item $\inp{\mix}.\ciphers \gets \indexedset{\ct_j}{j \in [\jsout]}$
    \end{enumerate}
\item Generate a signature $\otsSigma$ on the inputs of the \mix~function, in order to prevent any malleability attacks~(c.f.~\cref{appendix:trnm}), using the desired signature scheme $\otsigscheme$ (see~\cref{instantiation:otsig}):
    \begin{enumerate}
        \item\label{zeth-protocol:mix-inp:create-otsig} Using the one-time signature keypair generated in~\cref{zeth-protocol:otsig-generation}, do:
            \begin{align*}
                & \datatobesigned = \eparty{S}.\addr \concat \inp{\mix}.\primInp \concat \inp{\mix}.\zkp \concat \inp{\mix}.\ciphers \\
                & \otsSigma = \otsigscheme.\sig(\sk_{\otsig}, \crhots{\datatobesigned})
            \end{align*}
        \item $\inp{\mix}.\otssig \gets \otsSigma$
        \item $\inp{\mix}.\otsvk \gets \vk_{\otsig}$
    \end{enumerate}
    Here, $\eparty{S}.\addr$ represents the address of the $\ethereum{}$ user $\eparty{S}$ who must sign the transaction (see~\cref{zeth-protocol:create-tx}). In general, this is likely to be owned by the holder $\zparty{U}$ of the $\zeth{}$ notes to be spent, but this is not a requirement.
\end{enumerate}

\begin{remark}\label{zeth-protocol:mix-inp:otsig-for-dispatch-call}
  \cref{zeth-protocol:process-tx:dispatch-call} describes a situation in which the proof data $\inp{\mix}.\zkp$ is not available (having been verified by some external mechanism). In such cases, $\datatobesigned$ in \cref{zeth-protocol:mix-inp:create-otsig} \MAY{} be replaced with:
  \[
  \datatobesigned = \eparty{S}.\addr \concat \inp{\mix}.\primInp \concat \inp{\mix}.\ciphers
  \]
  This modification, mentioned here for completeness, \MUSTNOT{} be used except as described in \cref{zeth-protocol:process-tx:dispatch-call}.
\end{remark}


\subsection{Jets}
\label{sec:jet}

Jets are another important features for many physics analyses at the LHC, and especially the key signatures for vector boson fusion/scattering (VBF/VBS) processes.
In ATLAS detector, jets are reconstructed as groups of topologically associated energy deposits in the calorimeters,
tracks associated with charged particles measured in the inner tacking detector, or simulated particles.
This section introduces the jet reconstruction, jet energy scale (JES) calibration and the b-jet tagging techniques.

\textbf{Jet reconstruction}

Jets are reconstructed using anti-$k_{t}$ algorithm~\cite{Cacciari_2008} within various radius parameter $R$,
and usually $R = 0.4$, namely small-$R$ jets, are used in most cases.
The \textsc{FastJet} software package\cite{Cacciari2012} is utilized for jet finding and reconstruction.
A collection of four-momentum vectors are used as inputs at each combination step in jet clustering,
the total four-momentum is therefore computed as the sum of four-vector of all its constituents.
There are three types of jets in ATLAS:
\begin{itemize}
	\item \textit{Truth jets:} use stable simulated particles as the inputs to jet algorithm.
	\item \textit{Track jets:} use charged tracks measured from inner detector as inputs to jet algorithm.
	\item \textit{Calorimeter jets:} make use of the energy deposits in calorimeters as inputs to jet algorithm.
\end{itemize}
Figure~\ref{fig:jet_reco_overview} shows the schematic of ATLAS jet reconstruction.
\begin{figure}[!htb]
  \centering
  \includegraphics[width=1.0\textwidth]{figures/Simulation/threetypes_jet_reco.png}
  \caption{A overview schematic of ATLAS jet reconstruction~\cite{Aad:2014bia}.}
  \label{fig:jet_reco_overview}
\end{figure}

The \textit{truth jets} are reconstructed using anti-$k_{t}$ algorithm with $R = 0.4$ by using final-state, stable particles from MC simulation as inputs.
It requires the candidate particles with lifetime $c_{\tau}$ > 10 mm and excludes the particles from pile-up.
Truth jets with $p_{T} > 7 GeV$ and $|\eta| < 4.5$ are then used for jets calibration described later.

The \textit{track jets} are reconstructed from charged particles within the full acceptance of inner detector ($|\eta| < 2.5$).
The track reconstruction has been introduced in section~\ref{sec:track}.
Reconstructed jets with $p_{T} > 500 MeV$ and associated with primary vertex are then selected.
Tracks are assigned to jets using ghost association\cite{CACCIARI2008119}, a procedure that treats selected tracks as four-vectors of infinitesimal magnitude during the jet reconstruction and assigns them to the jet which they are clustered with.
In addition, muon track segments are used as a compensation for those uncaptured jet energy carried by energetic particles passing through the calorimeters without being completely absorbed.
Similar to the ID track, muon segments are assigned to jets using the method of ghost association mentioned above as well.

The \textit{calorimeter jets} are reconstructed using a set of three-dimensional, positive-energy topological clusters (topo-clusters) made of calorimeter cell energies as input to the anti-$k_{t}$ algorithm\cite{Aaboud:2017jcu}.
Topo-clusters are built from nearby calorimeter cells that contains a significant energy above a noise threshold,
which is estimated from measurements of calorimeter electronic noise and simulated pile-up noise.
Those calorimeter cell energies are measured at electromagnetic energy scale (EM scale) corresponding to the energy deposited by electromagnetically interacting particles.
And jets passing a \pt threshold of 7 GeV are reconstructed with the anti-$k_{t}$ algorithm.

\textbf{Jet energy scale calibration}

Figure~\ref{fig:jet_cali} elaborates an overview of ATLAS jet calibration scheme for EM-scale calorimeter jets.
In this procedure, the jet energies are scaled to truth jets, which is reconstructed at the particle-level.
Each step of the calibration corrects the full four-momentum unless otherwise stated, scaling the jet \pt, energy, and mass.
\begin{figure}[!htb]
  \centering
  \includegraphics[width=1.0\textwidth]{figures/Simulation/jet_calibration.png}
  \caption{A overview schematic of ATLAS jet calibration\cite{Aaboud:2017jcu}.}
  \label{fig:jet_cali}
\end{figure}

First of all, the origin correction recompute the four-momentum of jets to point them to the hard-scatter primary vertex instead of the centre of detector, and in the meantime keep the jet energy unchanged.
This correction improves the $\eta$ resolution of jets by roughly 25\% at a jet $p_{T}$ of 20~\gev~ and > 5 times improvement for jet with $p_{T}$ above 200~\gev,
as measured from the difference between reconstructed jets and truth jets in MC simulation.
Secondly, the pile-up correction is adopted to remove the excess energy due to in-time and out-of-time pile-up,
which consists of two processes: an area-based $p_{T}$ density subtraction applied on the top of each event; and a residual correction derived from the simulation.
Thirdly, the absolute JES calibration corrects the jet four-momentum to the particle-level energy scale, using truth jets in di-jet MC events.
Furthermore, the step of global sequential calibration uses calorimeter, track and MS-based variables to reduce the flavor dependence and energy leakage effects.
Finally, the residual in situ calibration is utilized to correct jets in data by using well-measured objects such as photons, Z bosons and calibrated jets.

\textbf{B-jet tagging}

Tagging of b-jets plays a important role in many physics analyses involving b- or t- quark.
In the meantime, lots of analyses need to apply b-jet veto to suppress \ttbar process.
There are three major types of algorithms that have been developed to distinguish b-quark jets from light-quark (u,d,s) jets~\cite{ATL-PHYS-PUB-2016-012}:
\begin{itemize}
	\item \textbf{Impact parameter based algorithms (IP2D and IP3D):} b-hadrons usually have long lifetime ($\sim$1.5 ps, $c_{\tau}\sim450~\mu$m), which leads to large impact parameter for tracks produced from b-hadron decay. The impact parameter taggers are developed based on these variables. The IP2D tagger makes use of the transverse impact parameter significance $d_{0}/\sigma(d_{0})$ as discriminant, while IP3D tagger uses two-dimensional discriminant of both transverse and longitudinal impact parameter significances: $d_{0}/\sigma(d_{0})$ and $z_{0}sin\theta/\sigma(z_{0})$.
	\item \textbf{Secondary vertex finding algorithm (SV1)} makes use of the secondary vertex formed by decay products of b-hadron within the jet. All track pairs within a jet are tested for a two-track vertex hypothesis, and removed if they are likely to originate from a long-live particle decay (eg. $K_{s}$ or $\Lambda$), hadronic interactions or photon conversions. After that, a new vertex is fitted with all tracks from remaining two-track vertices, and the outliers are removed from this set of tracks.
	\item \textbf{Decay chain multi-vertex algorithm (JetFitter)}\cite{Piacquadio_2008} exploits the topological structure of weak b- and c- hadron decays inside the jet and tries to reconstruct the full b-hadron decay chain. A Kalman filter is adopted to find a common line between primary vertex and b-/c- vertices, as well as their position in this line, which gives a approximated flight path for the b-hadron. In this approach, the b- and c-hadron vertices, whenever resolution allows, can be resolved, even when there is only a single track associated to them.
\end{itemize}
The final discrimination commonly used in many physics analyses is called \textbf{Multivariate Algorithm (MV2)}, which is based on Boosted Decision Tree (BDT) implemented in the TMVA package\cite{Speckmayer_2010} by combining the outputs from underlying taggers mentioned above.
The MV2 was trained using jets in $t\bar{t}$ sample, where the b-jets are treated as signal while the c- and light-flavor jets are treated as backgrounds.
There are three kinds of MV2 depending on the fraction of c-jets in background for training: \textit{MV2c00}, \textit{MV2c10} and \textit{MV2c20}.
Figure~\ref{fig:jet_mv2} presents the output score of MV2c10 for different flavor jets.
\begin{figure}[!htb]
  \centering
  \includegraphics[width=0.5\textwidth]{figures/Simulation/jet_mv2c10.png}
  \caption{MV2c10 BDT output for b- (solid blue), c- (dashed green) and light-flavour (dotted red) jets in $t\bar{t}$ events\cite{ATL-PHYS-PUB-2016-012}.}
  \label{fig:jet_mv2}
\end{figure}


\chapter{The Transition to Planet Formation}
\label{ch:planets}

\marginnote{
\textbf{Suggested background reading:}
\begin{itemize}
\item \href{http://adsabs.harvard.edu/abs/2014prpl.conf..547J}{Johansen, A., et al. 2014, in "Protostars and Planets VI", ed.~H.~Beuther et al., pp.~547-570} \nocite{johansen14a}
\end{itemize}
\textbf{Suggested literature:}
\begin{itemize}
\item \href{http://adsabs.harvard.edu/abs/2010ApJ...722.1437B}{Bai, X.-N., \& Stone, J.~M. 2010, ApJ, 722, 1437} \nocite{bai10a}
\end{itemize}
}

In this final chapter, we will finish our discussion of the transition from star formation to planet formation. We have already seen in chapter \ref{ch:late_disk} that the interstellar dust grains that are captured in a star's disk will begin to collide with one another and grow, and that they will reach macroscopic size on time scales shorter than the observed disk lifetime. We now seek to sharpen our understanding of how these solids will evolve. We will continue to make use of fiducial numbers from the minimum mass Solar nebula (MMSN) that we introduced in chapter \ref{ch:late_disk}.

\section{Dynamics of Solid Particles in a Disk}

\subsection{Forces on Solids}

We begin our discussion by attempting to determine the dynamics of solid particles orbiting in a protoplanetary disk. Consider such a particle. Because the mass of the disk is very small compared that of the star, we can neglect the gravitational force it exerts in the radial direction, and thus the radial gravitational acceleration felt by the particle is simply $g_\varpi = G M/\varpi^2$, where $M$ is the star's mass and $\varpi$ is the distance from the star.

In the vertical direction we have the gravitational pull of both the star and the disk itself, and we have to think a bit more. However, one can show fairly easily that, for material distributed with the thermal scale height of the disk, the star's vertical gravity must dominate as well. The star's vertical gravitational force is
\begin{equation}
g_{z,*} = \frac{z}{\varpi} g_\varpi = \Omega^2 z,
\end{equation}
where $z$ is the distance above the disk midplane and $\Omega$ is the angular velocity of a Keplerian orbit. We can approximate the disk as an infinite slab of surface density $\Sigma$; the gravitational force per unit mass exerted by such a slab is
\begin{equation}
g_{z,d} = 2\pi G \Sigma.
\end{equation}
The ratio of the stellar force to the disk force at a distance $H$ off the midplane, the typical disk height, is
\begin{equation}
\frac{g_{z,*}}{g_{z,d}} = \frac{\Omega^2 H}{2\pi G \Sigma} = \frac{c_g \Omega}{2\pi G \Sigma} = \frac{Q}{2},
\end{equation}
where in the last step we substituted in the Toomre $Q=\Omega c_g/(\pi G \Sigma)$ for a Keplerian disk.

Thus the vertical gravity of the disk is negligible as long as it is Toomre stable, $Q\gg 1$. For our MMSN,
\begin{equation}
\label{eq:QMMSN}
Q=55 \varpi_0^{-1/4},
\end{equation}
so unless we are {\it very} far out, stellar gravity completely dominates. As a caveat, it is worth noting that we implicitly assumed that the scale height $H$ applies to both the gas and the dust, even though we calculated it only for the gas. In fact, the motion of the dust is more complex, and, as we will see shortly, the assumption that the dust scale height is the same as that of the gas is not a good one. Nonetheless, neglecting the self-gravity of the disk is a reasonable approximation until significant gas-dust separation has occurred.

The other force on the solids that we have to consider is drag. Aerodynamic drag is a complicated topic, but we can get an estimate of the drag force for a small, slowly moving particle that is good to order unity fairly easily. Consider a spherical particle of size $s$ moving through a gas of density $\rho$ and sound speed $c_g$ at a velocity $v$ relative to the mean velocity of the gas. First note that for small particles the mean free path of a gas molecule is larger than the particle size -- Problem Set 5 contains a computation of the size scale up to which this remains the case.

For such small grains it is a reasonable approximation to neglect collective behavior of the gas and view it as simply a sea of particles whose velocity distribution does not change in response to the dust grain moving through it. If the particle is moving slowly compared to the molecules, which will be the case for most grains, then the rate at which molecules strike the grain surface will be
\begin{equation}
\mbox{collision rate} \approx 4\pi s^2 \frac{\rho}{\mu m_{\rm H}} c_g,
\end{equation}
where $\mu$ is the mean mass per molecule, so $\rho/\mu m_{\rm H}$ is the number density. This formula simply asserts that the collision rate is roughly equal to the grain area times the number density of molecules times their mean speed.

If the grain were at rest the mean momentum transferred by these collisions would be zero. However, because it is moving, collisions on the forward face happen at a mean velocity of $\sim c_g+v$, and those on the backward face have a mean velocity $\sim c_g-v$. Thus, averaging over many collisions, there will be a net momentum transfer per collision of $\mu m_{\rm H} v$. The net rate of momentum transfer, the drag force, is therefore the product of this with the collision rate:
\begin{equation}
F_D = C_D s^2 \rho v c_g,
\end{equation}
where $C_D$ is a constant of order unity.

Integrating over the Boltzmann distribution and assuming that all collisions are elastic and that the reflectance is in random directions (so-called diffuse reflection), appropriate for a rough surface, gives $C_D = 4\pi/3$. With this value of $C_D$, this formula is known as the Epstein drag law. It becomes exact in the limit $s\ll \mbox{mean free path}$, $v \ll c_g$, and for pure elastic, diffuse reflection. Larger bodies experience Stokes drag, in which the dependence changes from $s^2 \rho v c_g$ to $s^2 \rho v^2$, but we will not worry about that for now. Finally, note that solid particles will not experience significant pressure forces, since they are so much more massive than the molecules that provide pressure.

\subsection{Settling}

Now let us consider what the combination of vertical gravity and drag implies. The vertical equation of motion for a particle is
\begin{equation}
\frac{d^2 z}{dt^2} = -g_z - \frac{F_D}{\frac{4}{3}\pi s^3 \rho_s} = -\Omega^2 z - \frac{\rho c_g}{\rho_s s} \frac{dz}{dt}
\end{equation}
where $\rho_s$ is the density of the solid particle. This ODE represents a damped harmonic oscillator: the gravitational term is the linear restoring force, and the drag term is the damping term. Within one gas scale height of the midplane $\rho$ is roughly constant, $\rho \approx \Sigma/H = 3\times 10^{-9} \varpi_0^{-11/4}$ g cm$^{-3}$. For constant $\rho$ the ODE can be solved analytically:
\begin{equation}
z = z_0 e^{-t/\tau},
\end{equation}
where
\begin{equation}
\tau = 2\frac{\rho_s s}{\rho c_g} \left[1 - \left(1 - \frac{4 s^2 \rho_s^2 \Omega^2}{\rho^2 c_g^2}\right)^{1/2}\right]^{-1}.
\end{equation}

If the term in the square root is negative, which is the case when $s$ is large, the damping is not strong enough to stop particles before they reach the midplane, and they instead perform a vertical oscillation of decreasing magnitude. If it is positive, they simply drift downward, approaching the midplane exponentially. The minimum time to reach the midplane occurs when the particles are critically damped, corresponding to the case where the square root term vanishes exactly. Critical damping occurs for particles of size
\begin{equation}
s_c = \frac{\rho c_g}{2 \rho_s \Omega} = 850 \varpi_0^{-3/2} \rho_{s,0}^{-1}\mbox{ cm},
\end{equation}
where $\rho_{s,0} = \rho_s/(1\mbox{ g cm}^{-3})$.

Thus all objects smaller than $\sim 10$ m boulders will slowly drift down to the midplane without oscillating. For $s\ll s_c$, we can expand the square root term in a series to obtain
\begin{equation}
\tau \approx 4 \frac{\rho_s s}{\rho c_g} \left(\frac{s}{s_c}\right)^{-2} = \frac{\rho c_g}{\rho_s \Omega^2 s} = 270 \varpi_0^{11/4} \rho_{s,0}^{-1} s_0^{-1}\mbox{ yr},
\end{equation}
where $s_0 = s/(1\mbox{ cm})$.

Thus 1 cm grains will settle to the midplane almost immediately, while interstellar grains, those $\sim 1$ $\mu$m in size, will take several Myr to reach the midplane. Of course these very small grains will also collide with one another and grow to larger sizes, which will let them sediment more rapidly. In practice coagulation and sedimentation occur simultaneously, and each enhances the other: growth helps particle sediment faster, and sedimentation raises the density, letting them collide more often.

\subsection{Radial Drift}

We have just considered the consequences of the forces acting on solid particles in the vertical direction. Next let us consider the radial direction. The homework includes a detailed solution to this problem for small particles, so we will not go through the calculation, just the qualitative result. The basic idea is that gas in the disk is mostly supported by rotation, but it also has some pressure support. As a result, it orbits at a slightly sub-Keplerian velocity. Solid bodies, on the other hand, do not feel gas pressure, so they can only remain in orbit at constant radius if they orbit at the Keplerian velocity. The problem is that this means that they are moving faster than the gas, and thus experience a drag force.

Problem Set 5 contains a calculation showing that the difference in velocity between the Keplerian speed and the speed with which a particle orbits is
\begin{equation}
\Delta v = \frac{n c_g^2}{2 v_K} = \eta v_K
\end{equation}
where the pressure in the disk is assumed to vary with distance from the star as $P\propto \varpi^{-n}$, $c_g$ is the gas sound speed, and the dimensionless quantity $\eta = n c_g^2/2 v_K^2$, which depends only on the local properties of the disk, has been defined for future convenience. At 1 AU for our minimum mass solar nebula model, this velocity is about $70 n$ m s$^{-1}$.

Drag takes away angular momentum, in turn causing the bodies to spiral inward. We can parameterize this effect in terms of the stopping time
\begin{equation}
t_s = \frac{mv}{F_D},
\end{equation}
where $m$ and $v$ are the body's mass and velocity, and $F_D$ is the drag force it experiences. The stopping time is simply the characteristic time scale required for drag to stop the body.

Consider a spherical solid body of size $s$. For the Epstein law, which we discussed last time, $F_D \propto s^2$, while for Stokes drag, which describes larger bodies, $F_D \propto s^2$ at low Reynolds and $s$ at high Reynolds number. On the other hand, for a body of fixed density the mass varies as $s^3$, so the acceleration produced by drag must be a decreasing function of $s$. The stopping time is therefore an increasing function of $s$. Intuitively, big things have a lot of inertia per unit area, so they are hard to stop. Little things have little inertia per unit area, so they are easy to stop.

Now consider two limiting cases. Very small bodies will have stopping times $t_s$ much smaller then their orbital periods $t_p$, so they will always be forced into co-rotation with the gas. Since this makes their rotation sub-Keplerian, they will want to drift inward. The rate at which they can drift, however, will also be limited by gas drag, since to move inward they must also move through the gas. Thus we expect that the inward drift velocity will also decrease as the stopping time decreases, and thus as the particle size decreases. To summarize, then, for $t_s/t_p \ll 1$, we expect $v_{\rm drift} \propto s^p$, where $p$ is a positive number. Small particles drift inward very slowly, and the drift speed increases with particle size for small $s$.

Now consider the opposite limit, $t_s \gg t_p$. In this case, the drag is unable to force the solid body into co-rotation on anything like the orbital period, so the body is always in a near-Keplerian orbit, and just slowly loses angular momentum to drag. Clearly in this case the rate at which this causes the particle to drift inward will decrease as the stopping time increases, and thus as the particle size increases. Summarizing this case, then, for $t_s/t_p \gg 1$, we expect $v_{\rm drift} \propto s^{-q}$, where $q$ is a positive number.

Since the inward drift speed rises with particle size at small sizes and decreases with particle size at large sizes, there must be some intermediate size with it reaches a maximum. Conversely, the time required for drag to take away all of a body's angular momentum, so that it spirals into the star, must reach a minimum at some intermediate size. Problem set 5 contains a calculation showing that even for 1 cm pebbles the loss time is a bit shorter than the disk lifetime, and 1 cm pebbles are in the regime where $t_s \ll t_p$. The drift rate reaches a maximum for $\sim 1$ m radius objects, and for them the loss time can be as short as $\sim 100$ yr. For km-sized objects the drift rate is back down to the point where the loss time is $\sim 10^5$ to $10^6$ yr.

\section{From Pebbles to Planetesimals}

The calculation we have just completed reveals a serious problem in how we can continue the process of growing the solids to larger sizes, forming planets and clearing away disks: it seems that once growth reaches $\sim 1$ m sizes, all those bodies should be dragged into the star in a very short amount of time. We therefore next consider how to overcome this barrier.

\subsection{Gravitational Growth}

One solution is to skip over this size range using a mechanism that allows particles to go directly from cm to km sizes, while spending essentially no time at intermediate sizes. A natural candidate mechanism for this is gravitational instability, so we begin with a discussion of whether this might work. As noted above, the gas in the MMSN is very gravitationally stable, $Q \sim 50$. However, we also saw that solids will tend to settle toward the midplane, and the solids have a much smaller velocity dispersion than the gas. The Toomre $Q$ for the solid material alone is
\begin{equation}
Q_s = \frac{\Omega c_s}{\pi G \Sigma_s}
\end{equation}
where $c_s$ and $\Sigma_s$ are the velocity dispersion and surface density of the solid material. To see what velocity dispersion is required, note that this definition of $Q$ lets use write $Q_s$ in terms of $Q_g$ as
\begin{equation}
Q_s = Q_g \left(\frac{\Sigma_g}{\Sigma_s}\right) \left(\frac{c_s}{c_g}\right) \approx(240, 60) Q_g \left(\frac{c_s}{c_g}\right),
\end{equation}
where the factors of 240 or 60 are for regions without and with solid ices, respectively.

Using equation (\ref{eq:QMMSN}) for $Q_g$ and equation (\ref{eq:TMMSN}) for the gas temperature, we have $Q_g\approx 55$ and $c_g\approx 1$ km s$^{-1}$ at 1 AU. Thus, gravitational instability for the solids, $Q_s<1$, requires that $c_s \lesssim (30, 7)$ cm s$^{-1}$, depending on whether ice is present or not. If such an instability were to occur, the characteristic mass of the resulting object would be set by the Toomre mass
\begin{equation}
M_T = \frac{4 c_s^4}{G^2 \Sigma_s} = (2\times 10^{19}, 3\times 10^{17})\mbox{ g},
\end{equation}
where the two numbers are again for the cases with and without ices in solid form. If we adopt $\rho_{\rm i,r} = (1,3)$ g cm$^{-3}$ as the characteristic densities of (icy, rocky) material, the corresponding sizes of spheres with this mass are $(20, 3)$ km. This is large enough to avoid the size range where rapid loss occurs.

To see whether this condition can be met, it is more convenient to phrase the instability criterion in terms of a density. If we use $H_s=c_s/\Omega$ in the Toomre condition, where $H_s$ is the scale height of the solids, and we take the midplane density of the solids to be $\rho_s \approx \Sigma_s/H_s$, then we have
\begin{equation}
Q_s  = \frac{\Omega^2 H_s}{\pi G \Sigma_s} \approx \frac{M_*}{\varpi^3 \rho_s},
\end{equation}
where $M_*$ is the mass of the star. A detailed stability analysis by \citet{Sekiya83a} of the behavior of a stratified self-gravitating disk shows that the instability condition turns out to be
\begin{equation}
\rho > 0.62\frac{M_*}{\varpi^3} = 4\times 10^{-7} M_{*,0} \varpi_0^{-3} \mbox{ g cm}^{-3},
\end{equation}
where $\rho = \rho_s + \rho_g$ is the total (gas plus solid) surface density and $M_{*,0}=M_*/\msun$. For our minimum mass solar nebula, recall that the midplane density of the gas is roughly $3\times 10^{-9}$ g cm$^{-3}$, a factor of 100 too small for instability to set in. The question then is whether the density of solids at the midplane can rise to 100 times that of the gas.

The discussion followed here closely follows that of \citet{youdin02a}. We have seen that drag causes solid particles to drift down to the midplane, and if this were the only force acting on them, then the density could rise to arbitrarily high values. However, there is a countervailing effect that will limit how high the midplane density can rise. If the midplane density of solids is large enough so that the solid density greatly exceeds the gas density, then the solid-dominated layer will rotate at the Keplerian speed rather than the sub-Keplerian speed that results from gas pressure. It is fairly straightforward to show (and a slight extension of one of the problems in Problem Set 5) that the rotation velocity required for radial hydrostatic balance is
\begin{equation}
v_{\phi} = \left(1-\eta \frac{\rho_g}{\rho}\right) v_K,
\end{equation}
where $\rho = \rho_g + \rho_s$ which approaches $v_K$ for $\rho_g \ll \rho_s$, and $(1-\eta) v_K$ for $\rho_g \gg \rho_s$. Since $\rho_s / \rho_g$ rises toward the midplane, this velocity profile has shear in it, with $v_{\phi}$ reaching a maximum at the midplane and dropping above it.

The shear can generate Kelvin-Helmholtz instability, which will in turn create turbulence that will dredge up the dust out of the midplane, halting settling and preventing the density from continuing to rise. A useful analogy to think about, which I borrow from \citet{youdin02a}, is a sandstorm in the desert. Since the midplane full of dust is trying to rotating faster than the gas-dominated layer above it, there is effectively a wind blowing above the dusty midplane layer, like a wind blowing over the desert. If the wind blows too fast, it will start picking up dust, preventing it from falling back to the desert floor.

In the case of a disk, this process will self-regulate, since reducing the amount of dust in the midplane brings its rotation velocity closer to that of the gas, thereby reducing the strength of the wind. This process of self-regulation can be calculated in terms of the condition required for KH instability. To understand how the criterion for KH instability is set, it is easiest to think about the case of a physical interface -- the results are not significantly different for a continuous medium. The most common example is a pond of water with wind blowing across its surface. Imagine that there is a small ripple in the water that causes the surface to rise a little. The wind will strike the bit of the water above the surface and try to push it horizontally. At the same time gravity will try to drag the water downward.

If the wind is strong, it will push the water horizontally faster than gravity can drag it downward. The moving water will displace the surface even more, creating a growing wave, the signature of KH instability. If it is weak, gravity will drag the ripple downward before the wind is able to displace it significantly. Thus we expect the critical condition for KH instability to involve a balance between the restoring force of gravity and the destabilizing force of shear. For a continuous medium, it turns out that the condition for instability can be stated in terms of the Richardson number
\begin{equation}
\mbox{Ri} = \frac{(g_z/\rho) (\partial \rho/\partial z)}{\left(\partial v_\phi/\partial z\right)^2} < \mbox{Ri}_c,
\end{equation}
where $z$ is the vertical distance, $g_z$ is the gravitational acceleration in the vertical direction, and the critical Richardson number for instability $\mbox{Ri}_c\approx 1/4$.\footnote{Note that the quantity in the numerator has units of one over time squared, so it is the square of a frequency. In fact, it is a frequency that is familiar from stellar structure: $(g_z/\rho) (\partial \rho/\partial z)$ is the square of the Brunt-V\"{a}is\"{a}l\"{a} frequency, the characteristic oscillation frequency for vertical displacements in a stratified medium, such as stellar atmosphere.}

The numerator here represents the stabilizing effects of gravity, which depends on both the gravitational acceleration and how quickly the density drops with height. The gravitational acceleration is
\begin{equation}
g_z = \Omega^2 z + 4\pi G \int_0^z \rho(z') \, dz',
\end{equation}
where the first term represents the gravitational pull of the star and the second represents the self-gravity of the disk. The denominator represents the amount of destabilizing velocity shear.

A reasonable approximation is that the KH instability will stop any further settling once it turns on, so the density of the solids will become as centrally peaked as possible while keeping the disk marginally stable against KH. Thus, we expect the equilibrium density profile for the solids to be the one that gives $\mbox{Ri}=1/4$. If $\rho_g(z)$ is known at a given radius, then the condition $\mbox{Ri} =1/4$ fully specifies the total density profile $\rho(z)$, since both $g_z$ and $v_\phi$ are known functions of $\rho$ and $\rho_g$. Given $\rho(z)$, it is obviously trivial to deduce the density of solids $\rho_s(z)$. The equation can be solved numerically fairly easily, but we can gain additional insight by proceeding via analytic approximations.

First, note that we are interested in whether a self-gravitating layer of particles can develop at all, and that until one does then we can ignore the self-gravity of the disk in $g_z$. Thus, we can set $g_z\approx \Omega^2 z$ for our analytic approximation. If we now differentiate the velocity profile $v_{\phi}$ with respect to $z$, we get
\begin{equation}
\frac{\partial v_\phi}{\partial z} = -\eta \left(\frac{1}{\rho} \frac{\partial \rho_g}{\partial z} - \frac{\rho_g}{\rho^2}\frac{\partial \rho}{\partial z}\right) v_K.
\end{equation}
Substituting this into the condition that the Richardson number is roughly $1/4$, and noting the $v_K = \varpi\Omega$, we have
\begin{eqnarray}
\mbox{Ri}_c \approx \frac{1}{4}
& \approx &
\frac{z}{\eta^2 \varpi^2} \frac{\rho^3 (\partial \rho/\partial z)}{\left[\rho (\partial \rho_g/\partial z) - \rho_g (\partial \rho/\partial z)\right]^2} \\
& = &
\frac{z}{\eta^2 \varpi^2} \frac{\rho^3 (\partial \rho/\partial z)}{\left[\rho_s (\partial \rho_g/ \partial z) - \rho_g (\partial \rho_s/\partial z)\right]^2}.
\end{eqnarray}

Now we make our second approximation: if we focus our attention near the midplane where solids are trying to sediment out, and are being stirred up by KH instability, the density of solids should be changing much more quickly than the density of gas. In other words, we will focus our attention at heights $z$ much smaller than the gas scale height, so we can set $\partial \rho/\partial z \approx \partial \rho_s/\partial z$, and drop $\partial \rho_g/\partial z$ in comparison to $\partial \rho_s/\partial z$. Doing so gives
\begin{equation}
\mbox{Ri}_c \approx \frac{z}{\eta^2 \varpi^2} \frac{\rho^3}{\rho_g^2 (\partial\rho_s/\partial z)}
\end{equation}

To see what this implies, consider a layer of solids with scale height $H_s$ and surface density $\Sigma_s$ that marginally satisfies this equation. Plugging in $z\sim H_s$ and $\rho_s \sim \Sigma_s/H_s$ gives
\begin{equation}
\mbox{Ri}_c \sim \frac{H_s}{\eta^2 \varpi^2} \frac{(\rho_g + \Sigma_s/H_s)^3}{\rho_g^2 (\Sigma_s/H_s^2)} = \frac{(\rho_g H_s + \Sigma_s)^3}{(\eta r \rho_g)^2 \Sigma_s}
\end{equation}
Clearly this equation cannot be satisfied for arbitrarily large $\Sigma_s$, since the RHS scales as $\Sigma_s^2$ in this case. Physically, this indicates that our assumption that the KH instability can keep the Richardson number at the critical value must break down if the surface density of solids is too high. If we think about it, it makes sense that there is a maximum amount of solid material that the gas can keep aloft. To continue the sandstorm analogy, the wind can only keep a certain amount of sand aloft in the desert. It cannot pick up the entire desert.

Thus, we expect there to be a critical column density $\Sigma_p$ at which it becomes impossible to satisfy the condition that the Richardson number is $1/4$. If $\Sigma_p$ exceeds this critical value, the surface density at the midplane will rise arbitrarily, and gravitational instability becomes inevitable. For the case $\Sigma_s \gg \rho_g H_s$, this critical value is clearly given by
\begin{equation}
\Sigma_s \sim \sqrt{\mbox{Ri}_c} \eta \varpi \rho_g = 2 n \sqrt{\mbox{Ri}_c} \left(\frac{c_g}{v_K}\right)^2 \varpi \rho_g.
\end{equation}
For the conditions of our MMSN at 1 AU, using $n=1$ and $\mbox{Ri}_c=1/4$, this evaluates to $70$ g cm$^{-2}$. The numerical solution for the critical surface density is $\Sigma_s=94$ g cm$^{-2}$; the increase relative to our simple analytic estimate mostly comes from the self-gravity of the dust, which increases the shear and thus strengthens the KH instability.

This is clearly larger than the surface density of solids we have available in the MMSN, even using ices. Moreover, just increasing the total mass of the disk does not help, because $\rho_g$ will rise along with $\Sigma_s$, and thus the condition will not be any easier to meet. We therefore conclude that gravitational instability cannot be a viable mechanism to jump from cm to km sizes unless a way can be found to enhance the solid to gas ratio in the disk by a factor of $\sim 3$ in the icy part of the disk, or $\sim 10$ in the rocky part.

\subsection{Hydrodynamic Concentration Mechanisms}

Gravitational instability by itself will not solve the problem of the meter-size barrier, but if some other mechanism can be found to increase the solid-to-gas ratio by a factor of $\sim 3-10$, then gravitational instability will take over and manufacture planetestimals. We therefore turn for the final topic in this chapter to what mechanisms might be able increase the solid to gas ratio by the required amount.

\begin{figure}
\includegraphics[width=\linewidth]{eddies_johansen14}
\caption[Schematic of particle concentration by eddies in a protoplanetary disk]{
\label{fig:eddies_johansen14a}
Schematic diagram of three mechanisms to concentrate particles in a protoplanetary disk, taken from \citet{johansen14a}. The left panel shows how small-scale turbulent eddies expel particles to their outskirts. The middle panel shows how zonal flows associated with large-scale pressure bumps concentrate particles. The right panel shows concentration by streaming instabilities. In each panel, black arrows show the velocity field, and the caption indicates the characteristic length scale of the structures shown, where $H$ is the disk scale height.
}
\end{figure}

The first mechanism we will examine is concentration of small particles by eddies in a disk (Figure \ref{fig:eddies_johansen14a}). Consider a rotating eddy in a disk. By an eddy here we mean a structure where the gas moves on circular trajectories in the frame co-rotating with the disk at angular velocity $\Omega$. Suppose that the gas at some distance $r$ from the center of an eddy is rotating at some speed $v_e$. In the rotating reference frame, there are two forces acting on the gas: pressure gradients and Coriolis forces. For the eddy to remain static, the sum of these two forces must produce an acceleration per unit mass equal to the centripetal acceleration associated with the circular motion of the eddy. Specifically, we must have
\begin{equation}
2\Omega v_e - \frac{1}{\rho} \frac{dP}{dr} = -\frac{v_e^2}{r},
\end{equation}
where the first term is the Coriolis force per unit mass, the second is the pressure force per unit mass, and the right hand side is the centripetal acceleration. For a slowly-rotating eddy, $v_e /r \ll \Omega$, we can ignore the right hand side, and simply approximate that the sum of the two terms on the left is zero. Thus for slow eddies, the eddy rotation speed is given by
\begin{equation}
v_e = \frac{1}{2\rho\Omega} \frac{dP}{dr}.
\end{equation}
We see that if the eddy is associated with a pressure maximum, $dP/dr < 0$, then $v_e < 0$ as well, indicating that rotation is clockwise; eddies associated with pressure minima, $dP/dr > 0$, produce counter-clockwise rotation.

Now let us consider the dynamics of a solid particle moving through the eddy. Returning to the inertial frame, if the eddy is rotating clockwise, $v_e < 0$, then the material that is further from the star is orbiting somewhat more slowly, while the material that is closer to the star is orbiting somewhat more rapidly. This means that the material farther from the star will have a smaller velocity difference with the sub-Keplerian solids, while the material that is closer to the star will have a somewhat larger velocity difference. The drag force is therefore smaller on the far side of the eddy, and larger on the near side. The net effect is that, as solids drift from large radii inward and encounter the eddy, their rate of drift slows down, and they tend to pile up at the location of the eddy. This is a potential mechanism to raise the local ratio of solids to gas, and thus to set off gravitational instability.

The final step in this argument is to have something that provides a pressure jump and thus can produce clockwise eddies. There are a number of possible mechanisms, including a build-up of gas at the edge of a dead zone where MRI shuts off, or simply the turbulence driven by the MRI itself. Whether this actually happens in practice is still an unsolved problem, but the mechanism is at least potentially viable.

Another possible mechanism to concentrate particles is known as the streaming instability. We will not derive this rigorously, but we can describe it qualitatively. Streaming instability operates as follows: suppose that, in some region of the disk, for whatever reason, the local density of solids relative to gas is slightly enhanced. Because we are in a mid-plane layer that is at least partly sedimented, the inertia of the solids is non-negligible. Thus while we have focused on the drag force exerted by the gas on the solids, the corresponding force on gas is not entirely negligible. This force tries to make the gas rotate faster, and thus closer to Keplerian. This in turn reduces the difference in gas and solid velocities.

Now consider the implications of this: where the solid to gas ratio is enhanced, the solids force the gas to rotate closer to their velocity, which in turn reduces the drag force and thus the inward drift speed. Thus if solid particles are drifting inward, when the encounter a region of enhanced solid density, they will slow down and linger in that region. This constitutes an instability, because the slowing down of the drift enhances the solid density even further, potentially leading to a runaway instead in the gas to solid ratio. If this mechanism is able to increase the ratio enough, gravitational instability will take over and produce planetesimals.


\chapter{Results}

%\section{Comparing the CNN to the currently used Random Forest}
After the optimizing process \num{20} CNNs were trained with the gained insights.
A \enquote{\texttt{6c\_4f}} architecture was trained with the mentioned dropout rates
and \num{5000} batches of pretraining for every layer.
The hyperparameters were set by a random grid search.

For reviewing the best, trained network, a so far unused simulated dataset has been used.
As a result, the separation of hadrons and gamma rays through the CNN's processing can be observed and evaluated.
By processing \num{500000} events of both classes and plotting the resulting predictions,
a separation of those classes can be observed.
Although many events overlap and are therefore not separable,
both curves are slightly skewed to their respective end of the axes.
With this dataset, a ROC-AUC score of \num{0.817} can be achieved.

\begin{figure}
    \centering
    \includegraphics[scale=1]{Plots/CNN_MC_Evaluation.pdf}
    \caption{Using an unseen, simulated dataset for the evaluation of the CNN's performance, a separation of the two classes is visible.}
    \label{fig:cnn_mc_evaluation}
\end{figure}

In the best case a real-image dataset displays a similar distribution of the classes,
only distinguished from the simulated events by the ratio of hadrons to gamma rays.
The real-image dataset consists of data,
which has been recorded between \num{2013} and \num{2014} and shows the activity of the Crab nebula.
It contains roughly \num{20000000} events.

By comparing the histograms of the simulated and real datasets,
a distinctly smaller occurrence of gamma rays can be noted.
This could arise from a small ratio in the cosmic radiation
or a poor performance of the CNN caused by a mismatch between the real and simulated datasets.

\begin{figure}
    \centering
    \includegraphics[scale=1]{Plots/CNN_Real_Evaluation.pdf}
    \caption{Using a real dataset of the Crab nebula, the predictions imply a high rate of hadrons and a small rate of gamma rays in the cosmic radiation.}
    \label{fig:cnn_real_evaluation}
\end{figure}

Since the Crab nebula is a well surveyed source by many telescopes around the globe,
it should be detectable with the newly predicted gamma rays at its position.
Since every gamma ray can be retraced to its origin,
the gamma ray activity of six opposing positions in FACT's field of view will be compared.
The first position (\enquote{On}) is the calculated position of the Crab nebula
and contains activities of the source and the background radiation.
The five other positions (\enquote{Off}) lie circular and equally spaced next to the first one
and therefore contain only background radiation.
In this way a difference of activity at the Crab nebula position can be detected.

The positions will be compared using a Theta-plot.
Both position's centers are placed at zero on the x-axis.
The x-axis measures the angular distance to this position,
while the y-axis depicts the activity of the cosmic region.
The crucial significance value summarizes this difference.
In this case, the Crab nebula can be detected with \num{24.4}\,$\sigma$.
Since comparable approaches with currently used Random Forest classifiers reach \num{39.89}\,$\sigma$ \cite{significance},
a poor performance of the CNN can be assumed.

\begin{figure}
    \centering
    \includegraphics[scale=0.8]{Plots/Theta_Plot.pdf}
    \caption{After \num{83.7}\,\si{\hour} of observation time the Crab nebula can be seen with the CNN with a significance of \num{24.4}\,$\sigma$. To optimize the significance, an angular cut at \num{0.026} and a threshold of \num{0.766} have been used for this plot.}
    \label{fig:theta_plot}
\end{figure}

This poor performance can derive from two distinct origins:
either the network can be optimized to overcome the performance difference
or the simulated input data contains features which the CNN utilizes,
that are absent in the real images (Monte Carlo Mismatch).
Since much effort has been put into optimizing the network,
only small prospective improvements can be expected from further optimization.
Therefore, the big performance difference seems to emerge from a mismatch between the training dataset and the real images.

\chapter{Conclusion}
\section{Potential Improvements}
To enhance the network's performance, there are two different approaches:
on the one hand, there is the possibility of changing the input data;
on the other hand, there are further options to improve the network's structure and data handling.
Options to improve results will be described in the following paragraph.
The order follows the data's pathway through the network and its programs.

First and foremost a simulated dataset has been used and the downside of this has been described.
The mismatch between simulated and real data seems to arise a malfunction when predicting real images.
Improving this dataset would be a complex and time-consuming task without any improvement guarantees.
As this may not solve the problem,
a more promising approach could be to switch from generated images to real images.
The current classifier could predict labels for each real image, and these labels
and images would form the training data for the network.
In contrast to the first approach, uncertain labels would be the main challenge to overcome.

Additionally, the flat hexagonal structure has been skewed to fit into a flat square structure.
Alternatively, a two-dimensional hexagonal structure could be transformed to a three-dimensional cubic structure
without losing any neighborhood information at all.
Furthermore, the time series information has been lost in this thesis by summing it up.
In contrast to a two-dimensional convolution with loss of information, as performed in this thesis,
a four-dimensional convolution with all information could be performed for the feature generation.
For this, the library \texttt{TensorFlow} will not be sufficient as such high dimensional convolutions are not yet supported.

Although many architectures have been implemented and many hyperparameters have been independently evaluated,
only a small feature space could be investigated in this thesis.
Naturally, expanding the hyperparameter optimization could yield better results.
Since all hyperparameters form a feature space themselves, a machine learning algorithm could be designed to predict
a network's performance by using the hyperparameters as input.
To optimize a network's performance during the training,
a reinforcement learning algorithm (Q-Learning) could increase the network's performance.
Rewarding the reinforcement learner for increasing the best performance,
could achieve a more optimized network overall \cite{q_learning}.

As the mismatch in the data will not be overcome by increasing the performance of the network itself,
the training data must first of all be exchanged.
After that, the network proposed in this thesis could investigate the performance using the new data
instead to the simulated data used here.
Once this has been successful, the other suggestions could be implemented.

\section{Outlook}
To classify images originating from cosmic radiation, a Convolutional Neural Network has been trained on a simulated dataset.
This network has been optimized, evaluated and performs comparably to the currently-used Random Forest on this task.
By predicting real images and computing the significance of the Crab nebula, a crucial performance difference between
the CNN and the other classifiers emerges.
Since CNNs have outperformed other classifiers in image classification tasks in the past,
this gap cannot be explained by a poorly optimized network alone.
The known mismatch in the simulated training dataset and the real images can be again confirmed.
To overcome this problem, an improved training dataset is the most promising option.
As simulated datasets contain the threat of mismatches every time,
training the CNN on real images could be the solution.
This introduces the challenge of creating a dataset containing real images with reliable labels.
As a first step, the current classifiers could be used to label the images.
The most reliable images could serve as the training data for a CNN.
This CNN's performance could yield new insights as to whether this approach is encouraging.