Key Points

Introduction to WarpX


๐Ÿ”ฎ The particle-in-cell method is used to simulate the self-consistent dynamics of relativistic charged particles

๐Ÿš€ WarpX is a open-source high-performance particle-in-cell code

โœจ WarpX is used in a variety of scientif domains

Install


๐ŸŽฏ WarpX is easy to install via Conda: conda -c conda-forge warpx

๐Ÿ” The documentation is the first place to look for answers, otherwise check out our issues and discussions and ask there.

Set Up a Simulation from Scratch


The WarpX examples and the documentation gallery are the best starting points for a new simulation.

Setting up a simulation is an iterative process: run, visualize, understand whatโ€™s wrong, fix it, repeat.

When the simulation doesnโ€™t show the expected physics, check the basics first: enough timesteps? resolved scales? adequate particles per cell? temperature not too high?

The documentation parameter reference is your constant companion for understanding and modifying input files.

A Two-stream Instability


๐Ÿ’ก The two-stream instability converts the kinetic energy of counter-streaming beams into electrostatic wave energy.

๐Ÿ”ฌ The instability growth rate depends on the ratio of drift velocity to thermal velocity: \(v_d / v_{\mathrm{th}} \gg 1\) is needed for the instability to develop.

๐Ÿ“Š Reduced diagnostics (FieldEnergy, FieldMaximum) let you track the instability growth in real time without post-processing full datasets.

๐Ÿ” The documentation is the first place to look for answers, otherwise check out our issues and discussions and ask there.

๐Ÿ“ท To analyze and visualize the simulation results in openPMD format, you can use the openPMD-viewer library for Python.

A Weibel Instability


๐Ÿ’ก The Weibel instability generates magnetic fields from a momentum anisotropy โ€“ unlike the two-stream instability, which generates electrostatic fields.

๐Ÿ”ฌ The instability produces current filaments with a characteristic size of order the plasma skin depth \(c/\omega_{pe}\).

๐Ÿ“Š Reduced diagnostics (FieldEnergy, FieldMaximum) are an efficient way to monitor the instability growth without storing large field dumps.

โšก Choosing parameters wisely (\(v_d \gg v_{\mathrm{th}}\), sufficient resolution and box size) is essential for observing the instability clearly.

๐Ÿ” The documentation is the first place to look for answers, otherwise check out our issues and discussions and ask there.

๐Ÿ“ท To analyze and visualize the simulation results in openPMD format, you can use the openPMD-viewer library for Python.

A Magnetic Mirror


๐Ÿ’ก The external B field is loaded from an openPMD file, while the protons are defined as test particles.

๐Ÿ“ท To analyze and visualize the simulation results in openPMD format, you can use the openPMD-viewer library for Python or you can open .pmd files directly in Paraview.

A FODO Cell


๐ŸŽฏ Particle tracking follows individual particles, while envelope tracking follows the beam envelope - particle tracking is more detailed but computationally expensive.

๐Ÿ”ฌ A FODO cell is a periodic focusing structure with alternating focusing and defocusing quadrupole magnets.

โšก WarpX allows you to turn space charge effects on/off and define arbitrary external fields.

๐Ÿš€ WarpX is a full PIC code best suited for strong space charge effects and complex electromagnetic interactions. For cases with negligible space charge, ImpactX may be a more efficient choice.

๐Ÿ” The documentation is the first place to look for answers, otherwise check out our issues and discussions and ask there.

๐Ÿ“ท To analyze and visualize the simulation results in openPMD format, you can use the openPMD-viewer library for Python.

A Laser-Driven Ion Accelerator


๐Ÿ’ก TNSA accelerates ions via a strong electrostatic sheath field created by hot electrons escaping the rear surface of a laser-irradiated thin target.

๐Ÿ”ฌ Key parameters controlling the maximum ion energy are the laser intensity (\(a_0\)), the target thickness, and the target density.

โš™๏ธ Charge-conserving current deposition (esirkepov) and proper boundary conditions (PML, absorbing) are essential for this type of simulation.

โšก This is a computationally expensive simulation โ€“ be prepared to iterate on resolution and target density to find a balance between physical fidelity and computational cost.

๐Ÿ” The documentation is the first place to look for answers, otherwise check out our issues and discussions and ask there.

๐Ÿ“ท To analyze and visualize the simulation results in openPMD format, you can use the openPMD-viewer library for Python.

A Beam-Beam Collision


๐Ÿ’… There are several details one needs to take care when setting up a beam-beam simulation

๐Ÿ” The documentation is the first place to look for answers, otherwise check out our issues and discussions and ask there.

๐Ÿ“ท To analyze and visualize the simulation results in openPMD format, you can use the openPMD-viewer library for Python.

OSSFE 2025 - Using WarpX, a general purpose particle-in-cell code


๐Ÿš€ WarpX is a open-source high-performance particle-in-cell code

๐ŸŽฏ WarpX is easy to install via Conda: conda -c conda-forge warpx

๐Ÿ” The documentation is the first place to look for answers, otherwise check out our issues and discussions and ask there.

๐Ÿ“ท To analyze and visualize the simulation results in openPMD format, you can use the openPMD-viewer library for Python or you can open .pmd files directly in Paraview.

UCB 2026 -- Two-Stream Instability Live Tutorial


Setting up a simulation is an iterative process: start from an existing example, modify, run, visualize, and refine.

The WarpX documentation and the examples gallery are the best starting points.

When things donโ€™t look right, check the basics: enough timesteps, adequate resolution, and appropriate temperature.