High-performance route optimizer using Lambda_G geometric energy minimization. 3-8% better than standard algorithms.
Project description
Lambda_G Optimizer
High-performance route optimization using geometric energy minimization.
Performance
| Metric | Result |
|---|---|
| vs Pure Greedy | +12% improvement |
| vs Standard 2-Opt | +3-8% improvement |
| Win Rate | 8/9 test cases |
Installation
pip install lambda-g-optimizer
Quick Start
Command Line
# Optimize a route from CSV (x,y coordinates per line)
lambda-g --file delivery_stops.csv
Python API
from lambda_g.solver import LambdaGSolver
import numpy as np
# Your coordinates (x, y)
coords = np.array([
[500, 500], # Depot
[120, 340], # Stop 1
[780, 220], # Stop 2
[450, 890], # Stop 3
])
solver = LambdaGSolver(coords)
optimal_path, distance = solver.optimize()
print(f"Optimal route: {optimal_path}")
print(f"Total distance: {distance:.2f}")
Input Format
CSV file with x,y coordinates (one per line):
500,500
120,340
780,220
450,890
Output
[*] Optimizing 60 nodes via Lambda_G Manifold...
[*] Phase 1: Multi-start greedy seeding...
[*] Phase 2: Refining top candidates via 2-opt...
[*] Results:
Standard (start=0): 5162.51
Lambda_G Hybrid: 5013.33
[✔] Lambda_G WINS by 2.89%
Final Path Distance: 5013.33
Optimized Sequence: [45, 10, 16, ...]
Use Cases
- Delivery Routing: Last-mile delivery optimization
- Fleet Management: Multi-vehicle route planning
- Warehouse: Picker path optimization
- Field Service: Technician routing
- Crypto/DeFi: DEX swap path optimization, validator routing
How It Works
Lambda_G uses a geometric energy function instead of just minimizing path length:
E = path_length + (angular_variance / φ) + (radial_variance / φ²)
Where φ (phi) is the Golden Ratio (1.618...).
This creates preference for geometrically coherent solutions that standard algorithms miss.
Author
Abhishek Srivastava
- ORCID: 0009-0006-7495-5039
- GitHub: @0x-auth
License
Dual Licensed:
- Open Source: AGPLv3 - Free for open-source projects
- Commercial: Commercial License - For proprietary use
If you use Lambda_G in a commercial product or SaaS without open-sourcing your code, you need a commercial license.
Contact: bits.abhi@gmail.com
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file lambda_g_optimizer-0.2.1.tar.gz.
File metadata
- Download URL: lambda_g_optimizer-0.2.1.tar.gz
- Upload date:
- Size: 17.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0851a34c5a675c66c0b1f3c264de3bee2e91c02e09248ee69e0d672371a9ec4e
|
|
| MD5 |
d1c7bded175b49b5468c4002c857917f
|
|
| BLAKE2b-256 |
375b9d85347edb21eb9f1909cbaef43521497e0c779640e721cbf59af0bbd11b
|
File details
Details for the file lambda_g_optimizer-0.2.1-py3-none-any.whl.
File metadata
- Download URL: lambda_g_optimizer-0.2.1-py3-none-any.whl
- Upload date:
- Size: 17.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3d5da79395fe3e168927e1ae3cc3cc9fc330806f98649c9ad5fed508a672a3f8
|
|
| MD5 |
ec1a5fb965d2f890e066f058bed9a039
|
|
| BLAKE2b-256 |
8f0b61f5f6f1b96851cbaf6d0ae36b8e64261123e307b47b878c9e737fae94cf
|