Library / SDK
QNLab-USTC/SimQN avatar
QNLab-USTC/SimQN

SimQN: A Discrete-Event Simulator That Treats Quantum Networks as Networks

Project brief: A network-layer simulator for the quantum network investigation. If you would like to follow our work or seek an easy-to-use quantum network simulator, you cannot miss SimQN!

1,040 stars18 forksPythonGPL-3.0

At a glance

What is it?
SimQN is a Python 3, discrete-event simulator for QKD and entanglement distribution networks. It targets researchers who want routing and protocol work without rebuilding a network stack from scratch.
Who is it for?
Adopt SimQN if you research QKD protocols, entanglement distribution, routing, or resource allocation at the network layer and want a Python library with built-in topology generators and protocol modules. Skip it if you need a GUI, practical quantum hardware models like repeaters or switches, or a simulator that enforces a specific network architecture.
Can I use it commercially?
Yes, with conditions. GPL-3.0 is a copyleft licence: if you distribute software that includes it, you must release that software's source code under the same licence. Running it internally without distributing it does not trigger that obligation.
Is it still maintained?
Yes. The repository last received commits 41 days ago.
What is it written in?
Mainly Python, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on September 19, 2026, and from our analysis. They are not legal advice.

DEEP OPEN-SOURCE ANALYSIS

What SimQN solves and who it is for

SimQN solves a specific pain: simulating quantum networks as networks, not just as physical-layer experiments. The README positions it as a network-layer simulator, like NS3 for quantum. It targets researchers who want to evaluate QKD protocols, entanglement distribution, routing algorithms, and resource allocation schemes. The core idea, stated in the README, is that SimQN makes no architecture assumption. Since no recognized quantum network architecture exists yet, the simulator stays flexible. That flexibility matters if you are designing a new routing protocol and do not want to commit to a particular stack. The intended user is someone who studies quantum networking and wants to reuse modules instead of implementing every layer from scratch. The README claims 22 peer-reviewed papers used SimQN, but that is a count, not a quality argument; treat it as evidence of adoption, not correctness.

The mechanism: discrete events, modular nodes, and a fidelity-based model

SimQN is a discrete-event simulator. That means time advances in steps, and events like entanglement generation or message passing are scheduled. The README highlights two performance mechanisms. First, Cython compiles critical code into C/C++ libraries. That is a concrete claim about speed, but the README gives no benchmark numbers. Second, SimQN offers a higher-layer fidelity-based entanglement physical model, as opposed to a full quantum state simulation. The trade-off is clear: fidelity-based models reduce computation overhead but lose the detailed quantum state information. If you need to simulate noise at the density-matrix level, you would use the quantum state-based model, which the README says is also available. The simulator provides network auxiliary models for building topologies, producing routing tables, and managing multiple session requests. The example code imports RandomTopology, DijkstraRouteAlgorithm, and EntanglementDistributionApp, which shows the intended workflow: define a topology, assign a routing algorithm, attach a protocol application, and run it on a Simulator instance.

Getting it running: installation and the first example

Installation is a single pip command: pip3 install -U qns. The package name is qns, not SimQN. The README's first example imports Simulator, RandomTopology, EntanglementDistributionApp, QuantumNetwork, DijkstraRouteAlgorithm, ClassicTopology, and logging utilities. It sets init_fidelity = 0.9 before the truncated part. That suggests you configure the initial fidelity of entangled states as a parameter. The example is short, but the pattern is clear: you create a simulator, build a network with a topology, add a routing algorithm, attach an entanglement distribution app, and run. The README does not show how to run the simulator or collect results; you would need the documentation at qnlab-ustc.github.io/SimQN for that. The installation is Python3-specific, so Python 2 is not supported. The use of Cython means you may need a C compiler when installing from source, but the pip package likely ships prebuilt wheels; the README does not clarify.

A real limitation: the roadmap reveals what is missing

The roadmap is the most honest part of the README. Version 0.2.x is still in development, and several features that a serious quantum network researcher might expect are not yet present. The roadmap lists practical quantum network entities like quantum repeaters, quantum switches, and quantum benchmarking devices as future work. That is a significant gap: repeaters are central to entanglement distribution over long distances. The roadmap also mentions support for quantum network stack protocols, including KM protocols and routing in QKD networks, as future. The current version includes some protocols, like EntanglementDistributionApp, but the README does not list a full stack. Also, the README says a GUI is planned. If you need to visualize your network or debug interactively, SimQN is not there yet. The README claims the simulator is general purpose, but the roadmap shows it is still evolving. For a production simulation of a repeater-based network, you would be waiting for future versions.

The wrong tool: when SimQN does not fit

SimQN is the wrong tool if your research focuses on the physical layer in detail. The fidelity-based model is a deliberate simplification, and the README admits it reduces computation overhead but at the cost of detailed quantum state information. If you need to simulate specific noise channels, decoherence dynamics, or error correction at the qubit level, a full state-vector simulator like QuNetSim or NetSquid might be more appropriate. Also, if you need a simulator that enforces a particular network architecture, SimQN's no-assumption design might feel too loose. The README emphasizes flexibility, but that flexibility means you have to build your own architecture on top. Finally, if you need a GUI or practical hardware models today, SimQN is not ready. The roadmap places those in future versions. The README also mentions distributed quantum computing as 'incoming', so if that is your focus, you should wait.

A real alternative: NetSquid and its different approach

A concrete alternative is NetSquid, a quantum network simulator that also uses discrete events but takes a different architectural approach. While SimQN emphasizes network-layer abstraction and no architecture assumption, NetSquid provides a component-based model with a strong focus on physical-layer realism, including quantum channels, noise models, and timing. NetSquid uses a Python-based scripting language and a discrete-event engine, but it is not GPL-3.0; it uses a proprietary license for the core, which is a key difference. SimQN is GPL-3.0, meaning you can modify and redistribute it, but any derivative work must also be GPL-3.0. NetSquid's license may restrict commercial use. The choice comes down to fidelity vs. flexibility. NetSquid gives you more detailed physics out of the box, but it may require more effort to implement network-layer protocols. SimQN gives you routing and topology utilities built in, but you may need to add your own physics. The README does not mention NetSquid, but this comparison is based on the known characteristics of both simulators.

Maintenance and license implications

SimQN is actively maintained. The last push was June 2026, and version 0.2.3 was released on the same date. The release cadence shows a version roughly every six months: v0.2.1 in April 2025, v0.2.2 in January 2026, and v0.2.3 in June 2026. That is a healthy update frequency, but it also means you should expect API changes between minor versions. The README says the developers are focusing on the 0.2.x series, so breaking changes are possible. The license is GPL-3.0. That is a strong copyleft license. If you use SimQN in your research and distribute your code, you must release your code under GPL-3.0 as well. For academic research that is not distributed, the license is less restrictive, but if you build a commercial product on SimQN, you must open-source your modifications. The README also lists platform extensions, with 7 simulation platforms or system extensions built on SimQN. That suggests a community, but the README does not detail those extensions. You should check the repository for the extension list before relying on them.

Editorial conclusion

Adopt SimQN if you research QKD protocols, entanglement distribution, routing, or resource allocation at the network layer and want a Python library with built-in topology generators and protocol modules. Skip it if you need a GUI, practical quantum hardware models like repeaters or switches, or a simulator that enforces a specific network architecture. Before adopting, verify that the fidelity-based entanglement model matches your accuracy needs, confirm the Cython-compiled core is easy to build in your environment, and check whether the version 0.2.x roadmap items you depend on, like multi-path routing or CASCADE, are already implemented in the current release.

Official sources

  1. Official documentation
  2. Official README
  3. Project repository
  4. Release notes
Community notes

Community notes