MAQ is a revolutionary quantum computing programming language designed to handle simulations and operations on a massive scale, with support for up to 150 trillion qubits. This repository provides the compiler, runtime, and examples needed to explore the potential of MAQ.
- Custom Quantum Compiler: Tokenization, parsing, and transpilation to Qiskit circuits.
- Distributed Simulations: Leverages Dask for large-scale quantum simulations.
- Predefined Quantum Algorithms: Includes Shor's Algorithm, quantum teleportation, and more.
- Interactive Visualizations: Analyze results of quantum computations interactively using Streamlit and Plotly.
git clone https://github.com/marciolscoutinho/maq.git
cd maq
Ensure you have Python 3.8+ installed. Install the required Python packages:
pip install -r requirements.txt
Run the following command to ensure the setup works:
python cli/main.py examples/teleport.qp
Execute MAQ programs using the CLI:
python cli/main.py <path_to_file.qp>
Example:
python cli/main.py examples/teleport.qp
Use the provided implementation of Shor's Algorithm:
python algorithms/shors_algorithm.py <number_to_factor>
Example:
python algorithms/shors_algorithm.py 15
The examples/teleport.qp
file demonstrates quantum teleportation using MAQ:
H(0);
CNOT(0, 1);
MEASURE(0);
MEASURE(1);
IF(0) THEN X(2);
IF(1) THEN Z(2);
Run it with:
python cli/main.py examples/teleport.qp
The examples/distributed_simulation.py
script showcases distributed simulation for large quantum circuits:
python examples/distributed_simulation.py
We welcome contributions to MAQ! Follow these steps to contribute:
- Fork the repository.
- Create a new branch:
git checkout -b feature/your-feature
- Commit your changes:
git commit -m "Add your feature"
- Push to your branch:
git push origin feature/your-feature
- Open a pull request on GitHub.
MAQ is licensed under the MIT License. See the LICENSE
file for details.
- Built using Qiskit for quantum circuit simulations.
- Inspired by advancements in quantum computing and scalable programming languages.