Introduction

In this practical work, you will familiarize with a Particle in Cell (PIC) code ([BirdsallLangdon], [Lapenta]), learn how to set up and run a basic PIC simulation to study laser wakefield acceleration of electrons, and how to analyze the results. The PIC code used for this tutorial, Smilei ([Derouillat2018]), is not a simplified version but a full PIC code that you can use for your future studies.

Summary of this practical

In the case study of this practical work, an intense laser pulse is injected into a plasma, exciting a relativistic plasma wave that can be used to accelerate relativistic electrons. This plasma acceleration scheme is known as laser wakefield acceleration, or LWFA ([Esarey2009], [Malka2012]). In the case considered in this practical, an externally injected relativistic electron bunch is injected in the plasma waves.

The practical will consist in four parts:

  • Exploring the Input Namelist (Exercises 1-2): we will explore the Python InputNamelist.py file to understand the basic set-up of the problem (simulation window size, resolution, ...). In this part the simulation window is empty.

  • Laser pulse in vacuum (Exercises 4-6): we will add a laser laser pulse propagating in vacuum and check that its diffraction follows the one predicted for a Gaussian beam.

  • Laser wakefield excitation (Exercises 7-11): we will add a pre-ionized plasma and visualize how the laser pulse excites plasma waves in its wake, also checking the results against the analytical theory in the linear regime.

  • Laser wakefield acceleration of an electron bunch (Exercises 12-20): we will add a relativistic electron bunch, injecting it into the plasma waves and studying its acceleration.

We will arrive progressively to the full laser wakefield acceleration simulation set-up, familiarizing with the postprocessing using the Python postprocessing library happi and adding step by step all the necessary blocks to the input namelist file called InputNamelist.py .

To add the physical elements or required additional outputs, you just need to decomment (i.e. remove the symbol # in front of the) lines with the relative variables and blocks, as will be described in the exercises. For example, to activate a block that introduces a laser in the simulation, you only need to remove the symbol # in front the LaserEnvelopeGaussianAM block and the lines defining the variables used by that block.

Prerequisites

Although the InputNamelist.py is written in Python, no extensive knowledge of that language is required to understand its contents. The first exercises will use pre-made Python scripts and commands for the analysis of simulations, while the last exercises will ask to modify these scripts to extend their scope. These exercises include basic numpy array manipulation and plotting of 1D and 2D arrays.

This practical work assumes that the reader knows how to navigate in a directory tree, create folders, and copy files from the command line (for a quick recap, see Sections 4-9, 13-14, and 17 in [ShawCommandLineCrashCourse]).

Some clarifications

Warning Although external injection of an electron bunch in a plasma wave is not the most common nor easy laser plasma acceleration scheme to realize experimentally, it was chosen due its conceptual simplicity, which allows to easily study some basic concepts underlying laser wakefield acceleration. The interested reader can find here a tutorial which includes laser wakefield acceleration with ionization injection, a more common laser wakefield acceleration scheme.

Warning: Many parameters of the simulation were chosen as a compromise between having a quick and simple simulation, and being able to describe the basic physical phenomena underlying laser wakefield acceleration of electrons. More realistic simulations of this phenomenon would require a larger number of mesh cells, a different space-time resolution, more realistic laser field distributions and plasma density distributions etc., that would require longer and more complex simulations, less suited for a basic tutorial.

A quick word on Smilei

As previously stated, the numerical tool you will use for this practical is the PIC code Smilei [Derouillat2018]. A prior knowledge of Smilei is not mandatory for the purposes of the practical exercises. Yet, feel free to check Smilei’s website on GitHub . The interested reader can also find additional tutorials focusing on physical processes not covered by this practical.

Smilei is an open-source and collaborative code freely distributed under a CeCILL-B license (equivalent to the GPL license for free-softwares). It can be run in 1D,2D,3D and cylindrical geometry with azimuthal modes decomposition, with a diverse suite of physical models and numerical techniques, from a laptop to supercomputers.

Acknowledgements

The simulations in this practical use many features in Smilei that would not exist without the teamwork of the code developers, maintainers and collaborators, to whom we extend our gratitude.

We are grateful to all the students who attend this TP each year since 2019, contributing to the improvement of its material through their invaluable feedback.

The authors also wish to thank the engineers of the cluster Ruche in the Moulon Mesocentre and the engineers of the LLR HPC clusters for computer resources and help.

Computing time has been granted by the École polytechnique through the 3Lab Computing infrastructure.


References