QuantumOS is a decentralized blockchain protocol designed to simulate and verify real scientific computation tasks — especially quantum physics, gravitational fields, and spin dynamics — using a novel Proof of Useful Work (PoUW) mechanism.
- PoUW Protocol: Nodes earn QOS tokens by completing verified simulations
- Scientific Simulations: Quantum spin systems, statistical mechanics, quantum chemistry
- Zero-Knowledge Proofs: Cryptographic verification of computational results
- Decentralized Computing: Researchers submit jobs, miners compute, everyone earns
- IPFS Integration: Decentralized storage for simulation outputs
On-Chain Pallets:
- pallet-task - Task creation, assignment, and reward distribution
- pallet-verifier - ZKP verification, reputation system, penalties
Off-Chain Engine:
- physics-engine - 2D Ising model Monte Carlo simulation
- Statistical analysis (energy, magnetization, specific heat, susceptibility)
- JSON serialization for IPFS compatibility
- High performance (~200ms for 20x20 lattice, 10k steps)
Runtime Integration:
- Fully integrated Substrate runtime
- 44 passing tests across all components
- Complete build system with WASM support
- Miner daemon (TaskFetcher, IPFSUploader, Submitter)
- Actual ZK proof generation (Groth16/PLONK circuits)
- IPFS client integration
- Web dApp for task management
- Additional physics models (Heisenberg, XY, Potts)
- Quantum annealing simulations
- GPU acceleration
- Multi-chain deployment
┌─────────────────────────────────────────────────────┐
│ QuantumOS Blockchain (Substrate) │
│ ┌─────────────────┐ ┌──────────────────────────┐ │
│ │ pallet-task │ │ pallet-verifier │ │
│ │ • Create tasks │ │ • ZKP verification │ │
│ │ • Assignment │ │ • Reputation tracking │ │
│ │ • Rewards │ │ • Penalty enforcement │ │
│ └─────────────────┘ └──────────────────────────┘ │
└──────────────────┬──────────────────────────────────┘
│ Submit (CID + Proof)
│
┌──────────────────┴──────────────────────────────────┐
│ Miner Node (Off-chain) │
│ ┌─────────────────────────────────────────────┐ │
│ │ physics-engine (Rust Library) │ │
│ │ • Ising model simulation │ │
│ │ • Monte Carlo algorithms │ │
│ │ • Observable calculations │ │
│ │ • Result serialization │ │
│ └─────────────────────────────────────────────┘ │
│ │ │ │
│ ▼ ▼ │
│ ┌──────────┐ ┌──────────┐ │
│ │ IPFS │ │ ZK Prover│ │
│ │ Upload │ │ (Groth16)│ │
│ └──────────┘ └──────────┘ │
└─────────────────────────────────────────────────────┘
- Rust: Install from rustup.rs
- Substrate Dependencies: See Substrate docs
curl https://sh.rustup.rs -sSf | sh# Clone repository
git clone https://github.com/quantumos-tech/os
cd os
# Build entire workspace
cargo build --release
# Start development node
./target/release/quamtumos-node --dev
# In another terminal, purge chain data (optional)
./target/release/quamtumos-node purge-chain --dev# Run Ising model demo
cargo run --release -p physics-engine --example basic_isingExpected output:
QuantumOS Physics Engine - Ising Model Example
============================================================
Simulation Parameters:
Lattice size: 20x20
Temperature: T = 2.00 (Tc ≈ 2.269)
Monte Carlo steps: 10000
RESULTS:
Computation time: 199 ms
Average energy: -697.00 ± 33.56
Average |M|: 355.93 ± 16.84
Specific heat: C = 0.704
Susceptibility: χ = 0.354
# Test all components
cargo test --workspace
# Test specific pallets
cargo test -p pallet-task
cargo test -p pallet-verifier
cargo test -p physics-engine- Implementation Guide - Complete technical documentation
- Architecture - System design and component overview
- Physics Engine README - Simulation library docs
Task Lifecycle:
- Create - User submits task with parameters and reward
- Claim - Miner picks up available task
- Execute - Miner runs physics simulation off-chain
- Upload - Results stored on IPFS, CID obtained
- Prove - ZK proof generated for computation
- Submit - CID + proof sent to blockchain
- Verify - On-chain verification via pallet-verifier
- Reward - Funds distributed to miner if proof valid
Economic Model:
- Minimum task reward: 100 * EXISTENTIAL_DEPOSIT
- Invalid proof penalty: 50 * EXISTENTIAL_DEPOSIT
- Reputation: +5 for success, -10 for failure
- Max task duration: ~2 days (28,800 blocks)
use pallet_task::Call as TaskCall;
// Via extrinsic
api.tx.taskPallet.createTask(
"ising_2d", // simulation type
"{\"lattice_size\": 20, \"temp\": 2.0}", // parameters (JSON)
50, // complexity
28800, // deadline (blocks)
1000 // reward (tokens)
).signAndSend(alice);use physics_engine::{IsingModel, Simulation, SimulationParams};
let params = SimulationParams {
lattice_size: 20,
temperature: 2.0,
steps: 10_000,
..Default::default()
};
let mut model = IsingModel::new(params);
let result = model.run();
// Serialize for IPFS
let json = physics_engine::serialize_result(&result)?;// After IPFS upload and proof generation
api.tx.verifierPallet.submitProof(
task_id,
0, // Groth16 proof system
proof_data,
public_inputs
).signAndSend(miner);Physics Simulations:
- 10x10 Ising: ~50ms (5k steps)
- 20x20 Ising: ~200ms (10k steps)
- 50x50 Ising: ~2s (20k steps)
Blockchain:
- Block time: 6 seconds
- Task assignment: instant
- Proof verification: <100ms (simulated)
2D Ising Model
- Classical spin system (±1 spins)
- Metropolis Monte Carlo
- Phase transition at T_c ≈ 2.269
- Observables: E, M, C, χ
- Heisenberg Model - 3D spin vectors
- XY Model - 2D spin vectors
- Potts Model - q-state spins
- Quantum Annealing - Optimization problems
os/
├── node/ # Substrate node binary
├── runtime/ # Blockchain runtime
│ ├── src/
│ │ ├── lib.rs # Runtime assembly
│ │ └── configs/ # Pallet configurations
│ └── Cargo.toml
├── pallets/
│ ├── task/ # Task management pallet
│ │ ├── src/lib.rs
│ │ ├── src/tests.rs # 16 tests
│ │ └── Cargo.toml
│ └── verifier/ # ZKP verification pallet
│ ├── src/lib.rs
│ ├── src/tests.rs # 14 tests
│ └── Cargo.toml
├── physics-engine/ # Off-chain simulation library
│ ├── src/
│ │ ├── lib.rs
│ │ ├── models/ising.rs
│ │ └── monte_carlo.rs
│ ├── examples/
│ └── Cargo.toml
└── docs/
├── architecture.md
└── implementation-guide.md
- Create pallet in
pallets/ - Add to workspace in root
Cargo.toml - Configure in
runtime/src/configs/mod.rs - Add to runtime in
runtime/src/lib.rs
- Implement in
physics-engine/src/models/ - Implement
SimulationandSpinModeltraits - Add tests
- Update documentation
# Unit tests
cargo test --lib -p pallet-task
cargo test --lib -p pallet-verifier
cargo test --lib -p physics-engine
# Integration tests
cargo test --workspace
# Benchmarks (future)
cargo bench -p physics-engineTest Coverage:
- pallet-task: 16 tests (passing)
- pallet-verifier: 14 tests (passing)
- physics-engine: 14 tests (passing)
- Total: 44 tests, all passing
curl -H "Content-Type: application/json" \
-d '{"id":1, "jsonrpc":"2.0", "method":"state_call",
"params":["TaskPalletApi_pending_tasks", "0x"]}' \
http://localhost:9944import { ApiPromise, WsProvider } from '@polkadot/api';
const api = await ApiPromise.create({
provider: new WsProvider('ws://localhost:9944')
});
// Get all tasks
const tasks = await api.query.taskPallet.tasks.entries();
// Create task
const tx = api.tx.taskPallet.createTask(
'ising_2d',
'{"lattice_size": 20}',
50, 28800, 1000
);
await tx.signAndSend(alice);We welcome contributions! Areas of interest:
- Additional physics models
- ZK circuit implementations
- Miner daemon development
- Web UI/dApp
- Documentation improvements
- Performance optimization
This project is released into the public domain under the Unlicense.
- Documentation: Implementation Guide
- Substrate Docs: https://docs.substrate.io/
- Polkadot.js: https://polkadot.js.org/
- Issues: GitHub Issues
- Discussions: GitHub Discussions
Status: Phase 1 Complete - Production-ready foundation Version: 0.1.0 Last Updated: December 2025
Built using Substrate and Claude Code