diff --git a/docs/paper/the-karl-code/figures/ionization_test.pdf b/docs/paper/the-karl-code/figures/ionization_test.pdf new file mode 100644 index 0000000..12b3081 Binary files /dev/null and b/docs/paper/the-karl-code/figures/ionization_test.pdf differ diff --git a/docs/paper/the-karl-code/figures/recombination_e_only.pdf b/docs/paper/the-karl-code/figures/recombination_e_only.pdf new file mode 100644 index 0000000..ff8671b Binary files /dev/null and b/docs/paper/the-karl-code/figures/recombination_e_only.pdf differ diff --git a/docs/paper/the-karl-code/figures/recombination_ne_nt2p.pdf b/docs/paper/the-karl-code/figures/recombination_ne_nt2p.pdf new file mode 100644 index 0000000..7441f12 Binary files /dev/null and b/docs/paper/the-karl-code/figures/recombination_ne_nt2p.pdf differ diff --git a/docs/paper/the-karl-code/figures/recombination_t2p_only.pdf b/docs/paper/the-karl-code/figures/recombination_t2p_only.pdf new file mode 100644 index 0000000..7ab4582 Binary files /dev/null and b/docs/paper/the-karl-code/figures/recombination_t2p_only.pdf differ diff --git a/docs/paper/the-karl-code/paper.tex b/docs/paper/the-karl-code/paper.tex index 5870581..b8ea7b8 100755 --- a/docs/paper/the-karl-code/paper.tex +++ b/docs/paper/the-karl-code/paper.tex @@ -106,7 +106,7 @@ \changed{A new parallelized simulation code is presented, which uses a semi classical Monte Carlo method to determine particle spectra in the KATRIN source. Reaction chains are generated from the decay of tritium within the source. The code includes all relevant processes: elastic scattering, ionization, excitation (electric, vibrational, rotational), recombination and various clustering processes. The main emphasis of the code is the calculation of particle spectra and particle densities and currents at specific points within the source. It features a new technique to determine these quantities. It also calculates target fields for the interaction of particles with each other as it is needed for recombination processes.\\ The code has been designed for the KATRIN experiment but is easily adaptable for other tritium based experiments like Project 8. Geometry and background tritium gas flow can be given as user input.\\ -The code is parallelized using MPI and writes output using HDF5. Input to the simulation is read from a JSON description that provides general information on the simulation (resolution of the simulation domain) and the various optional features of the code, namely user defined species with their own terminator, interaction types, movers and initialization. +The code is parallelized using MPI and writes output using HDF5. Input to the simulation is read from a JSON description that provides general information on the simulation (resolution of the simulation domain).% and the various optional features of the code, namely user defined species with their own terminator, interaction types, movers and initialization. } %A new parallelized simulation code is presented, which uses a semi classical Monte Carlo method to determine particle spectra in the KATRIN source by tracking single particles from interaction to interaction. The moved distance is determined from the mean free path (MFP) and subsequently from cross sections and particle densities. Particle densities can be provided by the user, or are calculated during simulation from the movement of the simulated particles. This enables also the inclusion of recombination effects in the calculation. The implemented interaction types include elastic scattering, ionization, clustering and excitation (electric, vibrational, rotational) and recombination. Initial particles are created using the neutral gas density and known $\upbeta$-decay spectrum. The code is optimized for the conditions in the KATRIN source, being able to cope with a large density gradient, neutral gas flow and many different particle species in a Tritium environment. @@ -692,7 +692,16 @@ It can be seen that the data is well described by the fit with little deviations \end{figure} \paragraph{Ionization} -\changed{One way to test the validity of the ionization process is by injecting monoenergetic particles and taking a look at the energy distribution after they interact with the background gas. In case of a high injection energy there is a high likelihood for multiple ionization processes to occur, which would complicate the prediction of the shape of the energy spectrum. In order to guarantee only a single ionization event per particle can take place the energy has to be chosen below twice the ionization threshold.\\\\ TODO: expl. of setup and figures} +\changed{One way to test the validity of the ionization process is by injecting monoenergetic particles and taking a look at the energy distribution after they interact with the background gas. In case of a high injection energy there is a high likelihood for multiple ionization processes to occur, which would complicate the prediction of the shape of the energy spectrum. In order to guarantee only a single ionization event per particle can take place the energy has to be chosen below twice the ionization threshold. Since the energy distribution of one of the electrons after the ionization process is known it is possible to calculate the expected energy distribution of the electrons. However, due to the different angle distributions the population of scattered and ejected electrons have different velocities in $z$-direction and thus influence the density in a different way, which complicates the calculation for the expectation. In order to remedy this problem it was decided that no magnetic field will be used in the simulation, which simply lets electrons with a low $z$ velocity escape in radial direction.\\ +For the test an energy of \SI{30}{eV} has been chosen, since it is close to the maximum value of the cross section as well as only allowing for a single ionization event to take place. Electrons are injected in the middle of the simulation domain with an isotropic velocity direction. The density of the target gas was set to \SI{2.7e21}{\per\cubic\m} with an uniform distribution across the whole domain. In total a number of \num{1.2e5} primary electrons were simulated.\\ +Figure~\ref{fig:ionization_test} shows the electron spectrum at two different $z$-positions some distance away from the injection site as well as the expectation for the shape of the electron energy spectrum. It can be seen, that while the expectation is met, the results are quite noisy. Simulations in which the angle distribution were set isotropically for both electron populations lead to a much smoother result, from which it can be inferred that the noise must be attributed to the used scattering angle distributions.} + +\begin{figure} +\centering +\includegraphics[width=1\textwidth]{figures/ionization_test.pdf} +\caption{Energy spectrum for electrons being injected in the middle of the simulation domain at positions symmetrically placed around the injection site. The electrons were injected with an energy of \SI{30}{eV}. The black dashed curve shows the expectation for the spectrum.} +\label{fig:ionization_test} +\end{figure} \paragraph{Excitation} \changed{Is currently done test case enough?} @@ -767,11 +776,34 @@ The energy spectrum for the ions is shown in Figure~\ref{fig:charge_exchange} cl \end{equation} Since only the equilibrium is of interest, the time derivative will vanish. This lead to \begin{equation} +\label{eq:ne_nt2p} n_e = \frac{\sigma(E_e)}{\sigma(E_i)}n_i + c \commaeq \end{equation} -where $c$ is an integration constant. Ideally the fraction of the cross sections is one. However due to different simplifications taken in the code to speed up calculation of the cross section for both the electron and ion species this is not the case, but it is nonetheless close to one.\\\\ -TODO: description setup, figures +where $c$ is an integration constant. Ideally the fraction of the cross sections is one. However due to different simplifications taken in the code to speed up calculation of the cross section for both the electron and ion species this is not the case, but it is nonetheless close to one.\\ +The three test case simulations all share the same setup. The electrons and ions are both injected from the left side of the simulation domain and propagate to the right. The ion energy was set to \SI{1e-1}{eV} and the electron energy to \SI{9.1e-6}{eV} in order to achieve a similar density in the absence of any interaction. In total a number of 80000 events were simulated.\\ +The densities and their corresponding expectations are shown in Figures~\ref{fig:recombination_e_only} and \ref{fig:recombination_t2p_only}. It can be seen that fit quite well and only small statistical uncertainty. From the simulation results the cross sections can be inferred as well. These deviate less than 2\% for both cases from the expected values.\\ +The dependence of the electron density on the ion density are shown in Figure~\ref{fig:recombination_ne_nt2p}. Both the ideal slope and the expected slope as defined in equation~\ref{eq:ne_nt2p} can be seen and it is apparent that the data points follow this relation quite well. The expected value of the slope is $\sigma_e/\sigma_{\text{T}_2^+} = 0.973$. } +\begin{figure} +\centering +\includegraphics[width=1\textwidth]{figures/recombination_e_only.pdf} +\caption{Particle densities for recombination of e$^-$ with T$_2^+$. Only electrons experience recombination, while the ions act as a constant background.} +\label{fig:recombination_e_only} +\end{figure} + +\begin{figure} +\centering +\includegraphics[width=1\textwidth]{figures/recombination_t2p_only.pdf} +\caption{Particle densities for recombination of e$^-$ with T$_2^+$. Only ions experience recombination, while the electrons act as a constant background.} +\label{fig:recombination_t2p_only} +\end{figure} + +\begin{figure} +\centering +\includegraphics[width=1\textwidth]{figures/recombination_ne_nt2p.pdf} +\caption{Particle densities for recombination of e$^-$ with T$_2^+$. Dependence between the two particle densities follow the expected linear relationship. The slope of the red line is determined from the way the cross sections are calculated within the code with $\sigma_e/\sigma_{\text{T}_2^+} = 0.973$.} +\label{fig:recombination_ne_nt2p} +\end{figure} \section{Results} \label{sec:results}