Skip to content

Latest commit

Β 

History

History
100 lines (63 loc) Β· 3.12 KB

File metadata and controls

100 lines (63 loc) Β· 3.12 KB

PyMAD-NG

Python interface to MAD-NG running as a subprocess

PyPI version Documentation Status License DOI


πŸš€ Installation

Install via pip from PyPI:

pip install pymadng

🧠 Getting Started

Before diving into PyMAD-NG, we recommend you:

  1. Familiarise yourself with MAD-NG β€” understanding MAD-NG is essential.
  2. Read the Quick Start Guide to see how to control MAD-NG from Python.

Explore Key Examples

If anything seems unclear:


πŸ“š Documentation

Full documentation and example breakdowns are hosted at: https://pymadng.readthedocs.io/en/latest/

To build locally:

git clone https://github.com/MethodicalAcceleratorDesign/MAD-NG.py.git
cd MAD-NG.py/docs
make html

πŸ§ͺ Running Examples

Examples are stored in the examples/ folder. Run any script with:

python3 examples/ex-fodos.py

You can also batch-run everything using:

python3 runall.py

πŸ’‘ Features

  • High-level Python interface to MAD-NG
  • Access to MAD-NG functions, sequences, optics, and tracking
  • Dynamic send() and recv() communication
  • Python-native handling of MAD tables and expressions
  • Optional integration with pandas and tfs-pandas

🀝 Contributing

We welcome contributions! See CONTRIBUTING.md or the Contributing Guide in the docs.

Bug reports, feature requests, and pull requests are encouraged.


πŸ“œ License

PyMAD-NG is licensed under the GNU General Public License v3.0.


πŸ™Œ Acknowledgements

Built on top of MAD-NG, developed at CERN. This interface aims to bring MAD's power to the Python ecosystem with minimal friction.