Skip to main content

3D Electromagnetic Time-Domain wake and impedance solver

Project description

wakis-logo-light-background

Open-source Wake and Impedance Solver

Documentation Status Tests badge codecov

PyPI - Version PyPI - License Tokei - LOC Zenodo DOI

wakis is a 3D Time-domain Electromagnetic solver that solves the Integral form of Maxwell's equations using the Finite Integration Technique (FIT) numerical method. It computes the longitudinal and transverse wake potential and beam-coupling impedance from the simulated electric and magnetic fields. It is also a multi-purpose solver, capable of simulating planewaves interaction with nano-structures, optical diffraction, and much more!

About

🚀 Some of wakis features:

  • Wake potential and impedance calculations for particle beams with different relativistic $\beta$
  • Material tensors: permittivity $\varepsilon$, permeability $\mu$, conductivity $\sigma$. Possibility of anisotropy.
  • CAD geometry importer (STL & STEP format) for definition of embedded boundaries and material regions, based on pyvista
  • Boundary conditions: PEC, PMC, Periodic, ABC-FOEXTRAP, Perfect Matched Layers (PML)
  • Different time-domain sources: particle beam, planewave, gaussian wavepacket
  • 100% python, fully exposed API (material tensors, fields $E$, $H$, $J$). Matrix operators based on numpy and scipy.sparse routines ensure fast calculations.
  • 1d, 2d, 3d built-in plotting on-the-fly
  • Optimized memory consumption
  • GPU acceleration using cupy/cupyx
  • CUDA-aware MPI parallelization with mpi4py and ipyparallel coming soon!

🧩 Other complementary tools in the ecosystem:

  • Wakefield extrapolation via broadband resonator fitting with PIML iddefix evolutionary algorithms
  • Non-equidistant Filon Fourier integration with neffint
  • Beam-induced heating estimation due to impedance with bihc

📣 Tag and version changes are decribed in each Wakis Github Release:

How to use

📖 Documentation, powered by sphinx, is available at wakis.readthedocs.io

Check 📁 examples/ and notebooks/ for different physical applications:

  • Planewave interacting with a PEC or dielectric sphere
  • Gaussian wavepacket travelling through vacuum / dielectric
  • Custom perturbation interacting with PEC geometry
  • Wakefield simulation of accelerator cavity on CPU, GPU and with MPI

Check 🌐📁 wakis-benchmarks/ for beam-coupling impedance calculations & comparisons to the commercial tool CST® Wakefield solver:

  • PEC cubic cavity below cutoff (mm) and above cutoff (cm)
  • Conductive cubic cavity below cutoff
  • Lossy pillbox cavity (cylindrical) above cutoff
  • Simulations using beams with different relativistic $\beta$

Check 🌐📁 CEI-logo/ for a fun & complete beam-coupling impedance workflow tutorial, including:

  • 001: Electromagnetic simulation preparation, inspection & 1d, 2d, 3d plotting.
  • 002: Wakefield simulation on GPU
  • 003: Extrapolation of wakefield simulation to fully decayed with iddefix. Conversion to wake function for beam dynamics simulation with neffint.
  • 004: Beam-induced heating estimation due to impedance with bihc

Installation

Wakis supports Python 3.9 - 3.11 and can be installed in any conda environment.

📖 For a detailed installation guide (GPU, MPI setup, FAQs), check our documentation.

Users: Install via PyPI

For basic usage, simply run:

pip install wakis

For additional features, including interactive 3D plots in Jupyter notebooks, use:

pip install wakis['notebook']

To install complementary tools in the Wakis ecosystem:

pip install neffint iddefix bihc

💡 Have a bug, feature request, or suggestion? Open a GitHub Issue so the community can track it.

Developers: Contribute to Wakis

First, Fork the repository and clone it from main:

# SSH:
git clone git@github.com:YourUserName/wakis.git

# or HTTPS:
git clone https://github.com/YourUserName/wakis.git

Create a dedicated conda environment and install dependencies:

cd wakis/
conda create --name wakis-env python=3.11
conda activate wakis-env
pip install -r requirements.txt
pip install neffint iddefix bihc  # Optional tools

🛠️ Want to contribute? To merge your changes into main, create a Pull Request (PR) following our PR template.

Motivation

🎯 The determination of electromagnetic wakefields and their impact on accelerator performance is a significant issue in current accelerator components. These wakefields, which are generated within the accelerator vacuum chamber as a result of the interaction between the structure and a passing beam, can have significant effects on the machine. These effects can be characterized through the beam coupling impedance in the frequency domain and wake potential in the time domain. Accurate evaluation of these properties is essential for predicting dissipated power and maintaining beam stability. wakis is an open-source tool that can compute wake potential and impedance for both longitudinal and transverse planes for general 3D structures.

Citing Wakis

🔖 Each Wakis release is linked to a Zenodo publication under a unique DOI. If you are using Wakis in your scientific research, please help our scientific visibility by citing this work:

[1] E. de la Fuente Garcia et. al., “Wakis”. Zenodo, Mar. 12, 2025. doi: 10.5281/zenodo.15011421.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

wakis-0.6.0.tar.gz (93.0 kB view details)

Uploaded Source

File details

Details for the file wakis-0.6.0.tar.gz.

File metadata

  • Download URL: wakis-0.6.0.tar.gz
  • Upload date:
  • Size: 93.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.3

File hashes

Hashes for wakis-0.6.0.tar.gz
Algorithm Hash digest
SHA256 13f24b9b5a35e16e8f580624b880c53c653e8cd20554eecfbe697787bb89ec5f
MD5 b5954269c1154838cb07d8d9e3981e6d
BLAKE2b-256 38490e27dd50065beea8fb902d5803c78cc05a8804094b27fd428f272d77f481

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page