This repository contains the source code for OpenSATQKD, a framework for modeling and evaluating satellite QKD missions. The simulator calculates all key quantities from realistic experimental parameters and open-source tools, integrating orbital propagation, free-space link losses, optical hardware characterization, noisy quantum channel simulation, post-processing, and secret key rate estimation in a single platform. It’s designed to support mission planning, performance studies, and verbose protocol demonstrations in satellite-based quantum communication.
Requirements:
- Python 3.10 (we recommend using Conda to create a virtual environment)
- Linux is recommended (Libradtran is only officially supported in Linux). Windows can work via WSL.
- MATLAB (with CVX and QETLAB libraries) and the MATLAB Python API
Steps:
- Clone the repository:
git clone https://github.com/fjlc-73/OpenSATQKD.git
cd OpenSATQKD
git submodule update --init --recursive
- Create and activate a virtual environment:
conda create -n opensatqkd python=3.10.18
conda activate opensatqkd
- Install Python dependencies:
pip install -r requirements.txt
- Install libRadtran and its Python wrapper following the instructions on the GitHub page.
- Install openQKDsecurity for MATLAB-based computations:
- Install MATLAB libraries CVX and QETLAB.
- Install the MATLAB Python API by opening MATLAB and running:
cd (fullfile(matlabroot,'extern','engines','python'))
system('python -m pip install .')
Other external dependencies:
- Cascade Python is used but not included as a submodule because minor modifications were made for compatibility with this project.
- Activate the virtual environment.
- Set the
PYTHONPATH
environment variable to the project root folder:
env:PYTHONPATH="C:\path\to\project_root"
- Navigate to the simulator folder:
cd C:\path\to\project_root\simulator
- Run the GUI:
python main.py
Optional: Recreate Micius experiments
To do this, click Load Preset in the GUI and select any pass from the micius_data
folder (.json
files).
⚠️ Note: To automatically recreate past mission passes with realistic weather, make sure to enable the optional automatic weather feature by setting up the Copernicus CDS and ADS API keys as described below.
Optional: Recreate passes from past missions using automatic weather
To use this feature, you need API access from Copernicus Climate and Atmosphere Data Stores:
- Create an account at Copernicus CDS, accept the terms of use for ERA5 Single Levels, and get your API key from your profile.
- Create an account at Copernicus ADS, accept the terms for CAMS Global Reanalysis EAC4, and get your API key.
- Create a
.env
file in the project root and add your keys as:
CDS_API_KEY=<your_cds_api_key>
ADS_API_KEY=<your_ads_api_key>
- Open two separate PowerShell windows.
- In both, navigate to the tracing folder:
cd C:\path\to\project_root\tracing
- Set the
PYTHONPATH
environment variable to the project root folder:
env:PYTHONPATH="C:\path\to\project_root"
- In the first window, run the ground station simulation:
python ground.py"
- In the second window, run the satellite simulation:
python satellite.py
Note: Simulation parameters can be modified in
config_educ.py
located inside thetracing
folder before running the scripts.
We recommend using Space-Track for both historic and new satellite TLE data. An account is required to access TLE information.
A manuscript related to this repository has been submitted to the
IEEE Journal on Selected Areas in Communications (JSAC).
Authors: Javier López-Cerezo, Cristina Alcaraz, and Javier López
Status: Submitted (under review)