限界 · Genkai
Structural cross-sections, pushed to the limit.
Genkai (限界, "the limit") is a pure-Rust engine for structural cross-section analysis, exposed through a Python API and a desktop GUI.
It computes the geometric, elastic, plastic, and warping/torsion properties of arbitrary cross-sections (massive or thin-walled, with holes, single- or multi-material), and has grown into a reinforced and prestressed concrete (RC/PSC) section design and verification engine to the Eurocodes (EN 1992).
Why the name. In structural engineering, 限界状態 (genkai jōtai) is the limit state — the ultimate and serviceability limits that the whole of Eurocode design is built around. Every section this engine touches is checked against its limit. And もう限界 (mou genkai, "I'm at my limit") is, roughly, how it felt to name the thing. The name stuck for both reasons.
Status: pre-alpha. Phases 1–5 are shipped (geometry/elastic/plastic/warping replacing
sectionproperties, multi-material, thin-wall shear/torsion, and an EN 1992 RC/PSC design
engine); Phases 6 (EN 1992 conformance hardening) and 7 (design feature-parity) are
outstanding. See the releases for shipped versions.
📖 Documentation: Theory book · Python API guide — pip install genkai.
Why
- Performance — a native, parallel Rust core (single sparse factorization reused across right-hand sides, GIL-free assembly) instead of interpreted Python.
- Independence — a fully owned, permissively licensed computation stack with no third-party analysis engine.
- Scope — multi-material sections and RC/PSC design to the Eurocodes, an area not covered by existing open tools.
Architecture
crates/genkai-core— pure Rust computation core: geometry, meshing, finite-element warping, and section properties. No Python, no GUI.crates/genkai-py— PyO3 bindings exposing thegenkai._genkaiextension module.crates/genkai-gui— Tauri v2 desktop backend over the core (serde DTOs). The frontend lives ingui/(React + Vite + TypeScript).python/genkai— the Python package surface.docs/theory— the theory manual (mdBook): derivations and validation references — read online.docs/api— the Python API guide (mdBook): how to drive the engine, with runnable examples — read online.
At a glance
import genkai
g = genkai.Geometry(outers=[[(0, 0), (100, 0), (100, 60), (0, 60)]])
sec = genkai.Section(g, material=genkai.Material("steel", 200e3, 0.3, 355, 7.85e-9))
geo = sec.geometric() # frozen results: .area, .ixx_c, .perimeter, …
solved = sec.analyze(mesh_size=5.0) # mesh + warping solve, once
warp = solved.warping() # .j, .cw, .x_se, …
stress = solved.stress(mxx=1e6, mzz=5e4)
Technology stack
Permissive licenses only, enforced in CI by deny.toml:
| Concern | Crate |
|---|---|
| Polygon boolean ops | geo / i_overlay |
| Quality meshing | spade (constrained Delaunay + Ruppert refinement) |
| Sparse direct solver | faer |
| Python bindings / packaging | pyo3, rust-numpy, maturin |
| Desktop GUI | tauri |
Build (developer)
Requires Rust (stable, MSRV 1.83). Building the GUI backend (crates/genkai-gui) additionally
needs the frontend bundle, which Tauri embeds at compile time — build it first:
cd gui && npm ci && npm run build # produces gui/dist (required by `cargo build --workspace`)
cd ..
Then the Rust workspace:
cargo build --workspace # build the Rust core, bindings, and GUI backend
cargo test --workspace # run the Rust test suite
cargo deny check # license and advisory gate
The Python extension is built and installed into the active virtual environment with maturin — the recommended developer loop:
maturin develop # build + install `genkai` (editable) into the active venv
pytest python/tests # run the Python test suite
To rebuild the extension manually without maturin, build the crate and copy the artifact next to the package using the name for your platform:
cargo build -p genkai-py
# Linux: cp target/debug/lib_genkai.so python/genkai/_genkai.so
# macOS: cp target/debug/lib_genkai.dylib python/genkai/_genkai.so
# Windows: copy target\debug\_genkai.dll python\genkai\_genkai.pyd
License
Genkai is licensed under the Apache License 2.0. You are free to use, modify, and distribute it, including for commercial purposes, provided you retain the copyright and NOTICE attribution as required by the License.
Citation
If you use Genkai in academic, professional, or commercial work, please cite it. GitHub renders a "Cite this repository" button from CITATION.cff; attribution in any derived product, publication, or report is requested.
Release files for genkai 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| genkai-0.1.1.tar.gz | 427.1 kB | Details |
Built distributions (wheels)
| File | Reset | |||
|---|---|---|---|---|
| genkai-0.1.1-cp39-abi3-win_amd64.whl | CPython 3.9 | abi3 | Windows x86-64 | Details |
| genkai-0.1.1-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl | CPython 3.9 | abi3 | Linux glibc 2.17+ x86-64 | Details |
| genkai-0.1.1-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl | CPython 3.9 | abi3 | Linux glibc 2.17+ ARM64 | Details |
| genkai-0.1.1-cp39-abi3-macosx_11_0_x86_64.whl | CPython 3.9 | abi3 | macOS 11.0+ x86-64 | Details |
| genkai-0.1.1-cp39-abi3-macosx_11_0_arm64.whl | CPython 3.9 | abi3 | macOS 11.0+ ARM64 | Details |
Total release size: 10.5 MB
Release files / genkai-0.1.1.tar.gz
| Download URL | genkai-0.1.1.tar.gz |
|---|---|
| Size | 427.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c191ba2273acb97c0f69e44d6b31d0ef53321702bb69c6bfcc4a024ea6b48738
|
|
BLAKE2b-256 checksum How to use checksums |
eef18778aab7d5ac94cae1eff7b6880e6ba22ab44f4940f31be965d2cf31f8fe
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 23, 2026.
Transparency logRelease files / genkai-0.1.1-cp39-abi3-win_amd64.whl
| Download URL | genkai-0.1.1-cp39-abi3-win_amd64.whl |
|---|---|
| Size | 2.0 MB |
| Tags | CPython 3.9 Windows x86-64 abi3 |
|
SHA-256 checksum How to use checksums |
e023c866ca8d133f27a0e5e38b1fbd393f1b539976d6dd844487e1f94917fbca
|
|
BLAKE2b-256 checksum How to use checksums |
3d7facce9f91555cf769b4e1401f8d0133b4502ee2deac463766258ff828e60b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 23, 2026.
Transparency logRelease files / genkai-0.1.1-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | genkai-0.1.1-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 2.3 MB |
| Tags | CPython 3.9 Linux glibc 2.17+ x86-64 abi3 |
|
SHA-256 checksum How to use checksums |
a420d1cbad152e3282813405eb86cf7df186b8f1fe590603c8db7e676aa51722
|
|
BLAKE2b-256 checksum How to use checksums |
af8b83c3024117162239b4a65e3675392b1261feceb16cc8af7b223ae08ebf50
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 23, 2026.
Transparency logRelease files / genkai-0.1.1-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
| Download URL | genkai-0.1.1-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl |
|---|---|
| Size | 1.9 MB |
| Tags | CPython 3.9 Linux glibc 2.17+ ARM64 abi3 |
|
SHA-256 checksum How to use checksums |
9a331a82f06be5ec1da91b6e30008e6be7cb509c2ddbef8113fc342e18e79af4
|
|
BLAKE2b-256 checksum How to use checksums |
4a8e0c65aae02cfa1af54470f41b865e61f11fc7d05fab5c42b81be90a0562f1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 23, 2026.
Transparency logRelease files / genkai-0.1.1-cp39-abi3-macosx_11_0_x86_64.whl
| Download URL | genkai-0.1.1-cp39-abi3-macosx_11_0_x86_64.whl |
|---|---|
| Size | 2.1 MB |
| Tags | CPython 3.9 abi3 macOS 11.0+ x86-64 |
|
SHA-256 checksum How to use checksums |
589f11471c8cb9b8df1a4d05cf59878b9b785c046b7882939e0a9300584ecc17
|
|
BLAKE2b-256 checksum How to use checksums |
a6789a9ef639b04ca9409849a5229c67e7f0a806a291a40cc2b0e8e6bcc38741
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 23, 2026.
Transparency logRelease files / genkai-0.1.1-cp39-abi3-macosx_11_0_arm64.whl
| Download URL | genkai-0.1.1-cp39-abi3-macosx_11_0_arm64.whl |
|---|---|
| Size | 1.8 MB |
| Tags | CPython 3.9 abi3 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
a44a52df45920ca87e07e640392f4644f5bcecbec17fce09af0c306972ced815
|
|
BLAKE2b-256 checksum How to use checksums |
66b3c233236175d9cef116a8d8477d5c3e8d911ee269fe854ddd010b366d9262
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 23, 2026.
Transparency log