Comsol -leaderboard other pages

Topics

The Swiss Army knife of beam simulation

23 July 2026

Szymon Łopaciuk, Giacomo Broggi, Frederik Van der Veken and John Salvesen explain how Xsuite drew CERN’s fragmented beam-simulation tools into a single framework used to operate and optimise existing colliders, design future ones and model medical accelerators.

Beams in bits
Beams in bits An artistic view of the proposed FCC-ee collider. Xsuite, the open-source framework that brought together the capabilities of several beam-simulation tools, now helps design such future machines and optimise those already running. Credit: CERN/M Brice/I Snozzi

Particle accelerators are complex engineering marvels, with thousands of components working in concert. Magnets bend, focus and shape particle beams, while radio-frequency cavities accelerate them and keep the bunches dense. Feedback systems stabilise their motion, collimators intercept stray particles to protect the machine and the detectors, and injection and extraction devices guide them into and out of the accelerator. In addition to these external fields, beams are shaped by their own collective effects, in which particles influence one another directly or through the electromagnetic fields they generate in the surrounding beam pipe and accelerator structures.

Faced with these intricate effects, physicists have long relied on computer simulations to design, study and operate particle accelerators. At CERN, the development of computer programs to calculate the orbit and optics of synchrotrons, transfer lines and experimental lines dates back to the late 1960s (see “Hello, world” image). The Methodical Accelerator Design program, better known as MAD, was developed in the 1980s as part of the design effort for the Large Electron–Positron Collider (LEP). It later evolved into MAD-X, which became the de facto standard for optics calculations and accelerator operation at CERN throughout the LHC era.

Hello, world

With the growth of computing power, it became possible to follow individual particle trajectories over thousands, and later millions, of revolutions. This opened the door to more detailed studies of beam-quality preservation in the presence of non-linear forces and magnet imperfections. At CERN, much of this work was carried out with SixTrack, inspired by an earlier tool created for DESY’s HERA collider. Like MAD-X, SixTrack became one of the standard simulation tools of the LHC era. Further programs were tailored over the years to specific phenomena. For example, HEADTAIL and the later PyHEADTAIL became workhorses for studying transverse collective instabilities, in which the electromagnetic fields induced by a bunch in its surroundings act back on the bunch itself. Together, these programs distilled decades of accumulated expertise in accelerator physics, from which the community still benefits on a day-to-day basis.

As studies became more sophisticated, however, legacy tools began to show their limitations. Developed by separate teams to analyse different physical phenomena, they were not easy to combine when studying their interplay, often requiring slow, ad hoc interfaces. Many had not been designed with long-term extensibility in mind, and some of the experts familiar with the original technologies had since moved on. At the same time, the promise of workflows accelerated by GPUs was becoming increasingly attractive for accelerator physics, but difficult to retrofit into software architectures designed for a different computing era. The Xsuite framework was developed to pull all these threads together (see “Enter Xsuite” panel).

Enter Xsuite

Xsuite aims to bring together the functionality of MAD-X, SixTrack and PyHEADTAIL in a modern, extensible, Python-based toolkit, with GPU acceleration and collective effects included by design. Its architecture is modular, with clean, well-defined interfaces between components. The main building blocks include Xtrack, Xpart, Xfields, Xcoll and Xwakes, supported by the lower-level packages Xdeps and Xobjects (see “Division of labour” figure).

Division of labour

This modular structure helps keep the individual components manageable as the framework grows, while making the code easier to understand, extend and contribute to. Development has been user-centric from the start, with features implemented in response to concrete needs and tested on real-use cases. A major investment in automated testing supports a fast release cycle, with new versions appearing several times a month. Comprehensive tests run every night on all supported platforms, helping to catch errors from developers and third-party dependencies early.

Much of Xsuite’s value lies in how readily it connects to other codes, allowing a single study to combine effects that would otherwise sit in separate programs. Integration with FLUKA and BDSIM-Geant4, for example, enables precise modelling of particle–matter interactions across the accelerator environment, while interfaces with RF-Track and BLonD extend simulations to include complex electromagnetic fields and RF feedback systems. An interface to MAD-NG adds methods to perform high-order non-linear optimisation.

Launched in 2021, within the Accelerators and Beam Physics group at CERN, Xsuite brings accelerator-specific tools for design and simulation into a modern, integrated computing environment, connected to the wider scientific Python ecosystem for data analysis, visualisation, optimisation and machine learning. This transition is particularly important for future accelerator projects. Machines such as the Future Circular Collider (FCC) push accelerator modelling to its limits: the underlying physics calls for detailed simulations, while their scale and complexity demand the full exploitation of modern computing hardware.

Xsuite now serves as a core tool for beam-dynamics simulations in all synchrotrons operating at CERN (see “Four crossings” figure), as well as in upgrade projects and future design studies. Beyond CERN, it is used by teams at GSI, the Heidelberg Ion–Beam Therapy Center (HIT), MedAustron and DESY in Europe, Fermilab and Brookhaven in the US, the Canadian Light Source, and J-PARC and KEK in Japan. A clear sign of Xsuite’s growing adoption is the steady rise in mentions in recent proceedings of the International Particle Accelerator Conference (IPAC), which now exceed those of MAD-X, for many years one of the most widely used accelerator codes.

Four crossings

Xsuite’s open-source model has been central to this success. Free availability invites scrutiny, builds trust by allowing users to inspect the source code, and lowers the barrier to contribution. The teams that use Xsuite increasingly help to shape it, returning improvements and new features to the shared codebase. Xsuite is used for student training in schools such as the CERN Accelerator School, the Joint Universities Accelerator School and the US Particle Accelerator School, where it gives students hands-on experience with tools directly applicable to the machines they will go on to build and operate.

Testing future limits

Proposed future colliders present daunting but exciting challenges for accelerator physicists, making simulation tools more important than ever. Following the success of the integrated LEP and LHC programme, the leading proposals for the next high-energy facility are once again electron–positron colliders, potentially followed by larger hadron machines. Among them are the FCC study at CERN (see “CERN Council updates the European Strategy”) and the CEPC study at IHEP in China (CERN Courier November/December 2025 p7).

The most luminous lepton collider currently operating is SuperKEKB at the KEK laboratory in Tsukuba, Japan. Its three-kilometre electron–positron rings hold the world record for the highest collider luminosity, and set the benchmark the next generation aims to pass (see “At the luminosity frontier” figure). As SuperKEKB works towards its design parameters, simulation has been central to understanding observations and optimising the machine configuration. This work has, in turn, driven the development of Xsuite and strengthened collaboration between CERN and KEK, supported by exchange schemes such as the European Union’s Europe–America–Japan Accelerator Development Exchange Programme (EAJADE).

At the luminosity frontier

The clean way Xsuite’s components fit together enables integrated studies of several beam-dynamics effects at once – a capability that is increasingly important for the FCC-ee design. A faithful model must include thousands of magnetic and radio-frequency elements, together with synchrotron-radiation emission, the tapering of magnet strengths to follow the local beam energy, beam–beam interactions, beamstrahlung and scattering in collimators. Xsuite can treat these effects together, in a self-consistent and flexible way, making it possible to study how they influence one another in realistic machine configurations. The loss distribution around the FCC-ee ring, for example, was obtained from such integrated simulations (see “On the safe side” figure). These studies test whether the machine can operate safely while delivering its target luminosity, and help guide key design decisions early in the project’s life cycle.

Built for multi-tracking

Particle accelerators usually accelerate one kind of particle at a time. Nevertheless, secondary particle species are produced whenever beam particles hit the surface of beam pipes or collimators, and following them matters for the protection of sensitive components such as superconducting magnets and cavities, as well as detectors. Xsuite was therefore built to track more than one particle species at once. This feature is regularly used for collimation studies for the LHC complex and for the FCC design, and it is also proving valuable for advanced studies in hadron therapy, where carbon and helium ions are a case in point.

On the safe side

The charge-to-mass ratios of the two species are close enough that the two species can be accelerated together in one ring. At MedAustron, in Austria, researchers are studying mixed carbon–helium beams for “online range verification” during patient irradiation (see “Tag team” figure). In practice, while the carbon ions deposit their energy in the area to be treated, the helium ones pass through the patient and can be used to precisely localise the beam. Xsuite is used to simulate and optimise how the two ion species are injected, accelerated and extracted together in the synchrotron (CERN Courier November/December 2025 p45).

Shared expertise

Xsuite has by now become the working tool of hundreds of accelerator physicists. The advantages of having a large and diverse community working with the same toolkit are tangible, including synergies across projects, shared expertise, community support for new users, and collective validation of results. The current effort is to bring it into the control room. Connecting Xsuite to the CERN layout database and to the accelerator control system would let operators use the same simulation models to read, build and adjust machine configurations directly. Early control-room tests have been very positive – including a machine-development session where a full proof-of-concept LHC cycle was designed entirely with Xsuite and tested in the machine.

Tag team

These steps towards operational readiness coincide with a broader shift in how accelerators are studied and controlled. Machine-learning methods and AI are becoming increasingly present in accelerator workflows, from beam tuning and injection optimisation to anomaly detection and correction of slow drifts across CERN’s complex (CERN Courier May/June 2025 p35). Their development benefits from simulation tools that can generate realistic scenarios, explore many configurations efficiently and connect naturally to modern data-analysis environments. By combining fast-tracking, GPU capabilities and Python integration, Xsuite is well placed to support this growing convergence of beam-dynamics modelling, machine learning and accelerator operation.

Built to bring established accelerator modelling capabilities into a modern, integrated framework, Xsuite now spans applications from future-collider design and accelerator operation to the synchrotrons used in cancer therapy. If Xsuite is relevant for your work, give it a try – the team is eager to hear your feedback!

Further reading

http://xsuite.web.cern.ch.
G Iadarola, R De Maria et al. 2024 JACoW HB2023, TUA2I1.
F Van der Veken et al. 2024 JACoW HB2023, THBP13.

CERN Courier Jobs

Events

bright-rec iop pub iop-science physcis connect