Orientation-independent Rubik cube model in strictly typed Python
This project has been archived.
The maintainers of this project have marked this project as archived. No new releases are expected.
Project description
rubik-cube-model
A Poetry-based Python package that models a Rubik's Cube using linked sticker objects and per-face clockwise adjacency mappings.
Highlights
- Strict typing (
mypy --strict) - Orientation-independent cube state
ColorandSideare enumsCornerStickerobjects form circular linked lists of size 3EdgeStickerobjects form circular linked lists of size 2Cube.next_edgeandCube.next_cornerencode clockwise sticker order on faces
Install
poetry install
Example
from rubik_cube_model import Color, Cube
cube = Cube.solved(front_color=Color.GREEN, top_color=Color.WHITE)
assert cube.home.color is Color.GREEN
Project details
Release history Release notifications | RSS feed
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 rubik_model-1.0.0.tar.gz.
File metadata
- Download URL: rubik_model-1.0.0.tar.gz
- Upload date:
- Size: 11.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
45cda6f2450bc46ba6e9cf2c0c0014febbc6a8ec56071845cefa8e46dae4c93d
|
|
| MD5 |
f8d3e93a99072b5b25ead688e6b3a777
|
|
| BLAKE2b-256 |
b08cbedf6de79da0ebb482aee84fb5c98fc49cf8b811009b29bcef8c7acbd102
|
File details
Details for the file rubik_model-1.0.0-py3-none-any.whl.
File metadata
- Download URL: rubik_model-1.0.0-py3-none-any.whl
- Upload date:
- Size: 14.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
34c49d1947d085d6f117007bcdf17defef7af8d42cf1839114ca80336077f182
|
|
| MD5 |
d6e13e451d59bcd70c9e2b6b7789562f
|
|
| BLAKE2b-256 |
cc9e610d403dd4aa0fa1fbf33dc46439cdb0d792d172c306cfd39ea696ea2d10
|