Skip to main content

passagemath: Convex polyhedra in arbitrary dimension, mixed integer linear optimization

Project description

About SageMath

“Creating a Viable Open Source Alternative to

Magma, Maple, Mathematica, and MATLAB”

Copyright (C) 2005-2024 The Sage Development Team

https://www.sagemath.org

SageMath fully supports all major Linux distributions, recent versions of macOS, and Windows (Windows Subsystem for Linux).

See https://doc.sagemath.org/html/en/installation/index.html for general installation instructions.

About this pip-installable source distribution

This pip-installable source distribution passagemath-polyhedra is a distribution of a part of the Sage Library. It provides a small subset of the modules of the Sage library (“sagelib”, passagemath-standard), sufficient for computations with convex polyhedra in arbitrary dimension (in exact rational arithmetic), and linear and mixed integer linear optimization (in floating point arithmetic).

What is included

Examples

A quick way to try it out interactively:

$ pipx run --pip-args="--prefer-binary" --spec "passagemath-polyhedra[test]" ipython

In [1]: from sage.all__sagemath_polyhedra import *

Available as extras, from other distributions

Additional features:

pip install “passagemath-polyhedra[graphs]”

Face lattices, combinatorial polyhedra, graph-theoretic constructions

pip install “passagemath-polyhedra[groups]”

Constructing symmetric polyhedra, computing automorphisms, lattice point counting modulo group actions

pip install “passagemath-polyhedra[toric]”

Toric Varieties

Other backends for polyhedral computations can be installed:

pip install “passagemath-polyhedra[normaliz]”

Normaliz, via PyNormaliz, provides very fast computations in particular for polyhedra with data in algebraic number fields.

$ pipx run --pip-args="--prefer-binary" --spec "passagemath-polyhedra[normaliz,test]" ipython

In [1]: from sage.all__sagemath_polyhedra import *

In [2]: gap_norm = polytopes.grand_antiprism(backend='normaliz'); gap_norm

In [3]: gap_norm.f_vector()
pip install “passagemath-polyhedra[cddlib]”

cddlib provides support for computations with polyhedra in floating-point arithmetic.

passagemath-polyhedra also provides integration with other packages for additional functionality:

pip install “passagemath-polyhedra[latte]” installs LattE integrale for lattice point counting and volume computation using generating functions.

$ pipx run --pip-args="--prefer-binary" --spec "passagemath-polyhedra[latte,test]" ipython

In [1]: from sage.all__sagemath_polyhedra import *

In [2]: P = polytopes.cube()

In [3]: P.integral_points_count()
Out[3]:
27

In [4]: (1000000000*P).integral_points_count(verbose=True)
This is LattE integrale...
...
Total time:...
Out[4]:
8000000012000000006000000001
pip install “passagemath-polyhedra[polymake]”

Polymake, via JuPyMake

lrslib

Optional backends for optimization:

pip install “passagemath-polyhedra[cbc]”

COIN/OR CBC Mixed Integer Linear Optimization solver, via sage_numerical_backends_coin

pip install “passagemath-polyhedra[cplex]”

CPLEX Mixed Integer Optimization solver (proprietary; requires licensed installation), via sage_numerical_backends_cplex

pip install “passagemath-polyhedra[cvxpy]”

CVXPy as middle-end for various backends

pip install “passagemath-polyhedra[gurobi]”

Gurobi Mixed Integer Optimization solver (proprietary; requires licensed installation), via sage_numerical_backends_gurobi

pip install “passagemath-polyhedra[scip]”

SCIP Mixed Integer Optimization solver, via PySCIPOpt

Development

$ git clone --origin passagemath https://github.com/passagemath/passagemath.git
$ cd passagemath
passagemath $ ./bootstrap
passagemath $ python3 -m venv polyhedra-venv
passagemath $ source polyhedra-venv/bin/activate
(polyhedra-venv) passagemath $ pip install -v -e pkgs/sagemath-polyhedra

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

passagemath_polyhedra-10.4.62.tar.gz (986.2 kB view details)

Uploaded Source

Built Distributions

passagemath_polyhedra-10.4.62-cp312-cp312-musllinux_1_2_x86_64.whl (13.3 MB view details)

Uploaded CPython 3.12 musllinux: musl 1.2+ x86-64

passagemath_polyhedra-10.4.62-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (12.4 MB view details)

Uploaded CPython 3.12 manylinux: glibc 2.17+ x86-64

passagemath_polyhedra-10.4.62-cp312-cp312-macosx_14_0_arm64.whl (6.9 MB view details)

Uploaded CPython 3.12 macOS 14.0+ ARM64

passagemath_polyhedra-10.4.62-cp312-cp312-macosx_13_0_x86_64.whl (3.0 MB view details)

Uploaded CPython 3.12 macOS 13.0+ x86-64

passagemath_polyhedra-10.4.62-cp311-cp311-musllinux_1_2_x86_64.whl (13.5 MB view details)

Uploaded CPython 3.11 musllinux: musl 1.2+ x86-64

passagemath_polyhedra-10.4.62-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (12.5 MB view details)

Uploaded CPython 3.11 manylinux: glibc 2.17+ x86-64

passagemath_polyhedra-10.4.62-cp311-cp311-macosx_14_0_arm64.whl (6.9 MB view details)

Uploaded CPython 3.11 macOS 14.0+ ARM64

passagemath_polyhedra-10.4.62-cp311-cp311-macosx_13_0_x86_64.whl (3.0 MB view details)

Uploaded CPython 3.11 macOS 13.0+ x86-64

passagemath_polyhedra-10.4.62-cp310-cp310-musllinux_1_2_x86_64.whl (12.8 MB view details)

Uploaded CPython 3.10 musllinux: musl 1.2+ x86-64

passagemath_polyhedra-10.4.62-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (11.8 MB view details)

Uploaded CPython 3.10 manylinux: glibc 2.17+ x86-64

passagemath_polyhedra-10.4.62-cp310-cp310-macosx_14_0_arm64.whl (6.9 MB view details)

Uploaded CPython 3.10 macOS 14.0+ ARM64

passagemath_polyhedra-10.4.62-cp310-cp310-macosx_13_0_x86_64.whl (3.0 MB view details)

Uploaded CPython 3.10 macOS 13.0+ x86-64

passagemath_polyhedra-10.4.62-cp39-cp39-musllinux_1_2_x86_64.whl (12.8 MB view details)

Uploaded CPython 3.9 musllinux: musl 1.2+ x86-64

passagemath_polyhedra-10.4.62-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (11.8 MB view details)

Uploaded CPython 3.9 manylinux: glibc 2.17+ x86-64

passagemath_polyhedra-10.4.62-cp39-cp39-macosx_14_0_arm64.whl (6.9 MB view details)

Uploaded CPython 3.9 macOS 14.0+ ARM64

passagemath_polyhedra-10.4.62-cp39-cp39-macosx_13_0_x86_64.whl (3.0 MB view details)

Uploaded CPython 3.9 macOS 13.0+ x86-64

File details

Details for the file passagemath_polyhedra-10.4.62.tar.gz.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62.tar.gz
Algorithm Hash digest
SHA256 ed24f654eb6febc727566678f42b22492fc289d9f9ae113dd366f92a1ebc86a2
MD5 41d7eeb0f3ec50800fe24302a58f9acf
BLAKE2b-256 a903c5c9bd54dc63f06c2072be3eb7ec3aef593444d9fb4725028341d3c3cc5c

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp312-cp312-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 8ae149ce9b5ddceee42165b70ca9ee947649ddf11f6858ed791d47c00dbef97f
MD5 a39a730bb92679e1294e356bf5128e96
BLAKE2b-256 6067f84f0d7cd72223056c6c71ee024019b9886193843e3b9fd5c98179ce5bc8

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 3b0b2327b253bc0bf194006a16c02bfe90afc07191ad10d0e0f618d96a80e618
MD5 9cc442219d095cd68876b9567d645eca
BLAKE2b-256 784d7d47ad9128f7cd2fddbcf928dc0286d8eb9042621298e1ce092d2aebab6b

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp312-cp312-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp312-cp312-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 2f85d0d2026ee31394563a372198d6fefd35ba77ac7972e472f07b74047bd623
MD5 a9ca2e0c343a642c1e59f4a1adc77e62
BLAKE2b-256 5a376e9f01e57f74fa345054ece4a7bf845800c104966716381d3c7006d52b26

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp312-cp312-macosx_13_0_x86_64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp312-cp312-macosx_13_0_x86_64.whl
Algorithm Hash digest
SHA256 01f21a4d8e6c43f4ea20170bb2568f683874dabc8b61e0bbbefcd8584e8b5797
MD5 8765062d0441283e159d345853cebdea
BLAKE2b-256 eafb7358f74c55f6f03f9d6a735ae1509ae2757d52c1c7d27fd122c060120bc8

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp311-cp311-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 9cc58335d6d146626b5a1c963fad4d60a0ee2d5f9d39a6fda334579fdc3598fc
MD5 df42bc6589a25f76729816bbbd223a8a
BLAKE2b-256 3a39e3f58ee65f3d391e1450ea00004b6815ef3babee67780b6a82f773e0a94d

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 5a4618b3accc91413018f8fcebfbe22e3f04ade4ed89c117d7b99fa66d1edd5e
MD5 8513564e93b6f3c7590df048e6c98afd
BLAKE2b-256 3cd832bb10d7e3766dff0eb0c368e04f36fd6ad225a91d0281556ab739cd6c2d

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp311-cp311-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp311-cp311-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 0614440b190666f1021126285fe5471b0231b6c84bfeb67a3e9538941ab44987
MD5 5c019eec64b560810a870917b0e28072
BLAKE2b-256 ec41c240298b7e10244206887a60ecfa6a9a422f53aa35cf54dd56d8015ee8b6

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp311-cp311-macosx_13_0_x86_64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp311-cp311-macosx_13_0_x86_64.whl
Algorithm Hash digest
SHA256 6f11317ccd9097145e1077405d48f9095d0d311285554402efc970e26b50aed7
MD5 bc99d64f44cebbc11dab67ea2a00d2c1
BLAKE2b-256 7446e9b2966079bbc912351525a8bc2c13d52f0952a013eb7a7fb384ac30a696

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp310-cp310-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 7c3451df33fc0fd29acf2c92416a9d0ff5737a58bb8a96bc1531d0e47dfde0b6
MD5 ac85bffb97e99e6e7282a8835d73957f
BLAKE2b-256 e1b5ecfd9b7df0d444141848e624923f4c81e2aefc7cb212f15a20428eaa02dd

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 dcdaa0aef31d4855cca994ace7eb52dc5760e290ebc21ffb347435fd346de018
MD5 0db1d281c4b712d06a41b3d95a5a109d
BLAKE2b-256 cb370481320628b94e3f60b344a5d29fc37d40efbc8f1c89ef9423267785a1bc

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp310-cp310-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp310-cp310-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 1557c9c0ce113fa22b61b778218dc0c1e35982770d94e833d533395f2ab04f4d
MD5 43c43e903784c1e510453a24ff2f9e00
BLAKE2b-256 2f1d8fccba4ded74d70bfd29cfc6ac32e9e663e75aaa4d2175a89fd001cd89e3

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp310-cp310-macosx_13_0_x86_64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp310-cp310-macosx_13_0_x86_64.whl
Algorithm Hash digest
SHA256 7c48adffa8ae10b5c6362e2d3965bf95166e6194aa3a0ee18798ab230d8076f2
MD5 d22c5a9f3530faa66a213d583e5392f2
BLAKE2b-256 ada92864a6474c853bd3bad73ab38e59bde07889de5e6e96701463b642f8bbbc

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp39-cp39-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp39-cp39-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 8762f523d8482c4593e5098624665d454d7b849b5a3a438a46fc9e260cd18f1f
MD5 8aa7683b0f0241a0f6ee43628c08d16c
BLAKE2b-256 6f5cf8d05590db0c93198d5fa9028b4dac55ba9d1ce4638b4f4e21c938464de6

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 72a175d9998fa39af6320180cf3e74571f6e255af6d90f01965a93a494657555
MD5 8af8be9d5d47dd8227d2473cb0b3ca73
BLAKE2b-256 466599206ec4fbb7ee187d741aadf9e8283513f7ded85e633654fe4736bff1e1

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp39-cp39-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp39-cp39-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 e7c600f3a853706f3b6553b83e66b60a78b864b18e386256030f88a384876d00
MD5 29cf9f105bc217c53e22043751ea79b8
BLAKE2b-256 970613efb7393927768fd1a2cd278d55e84e933d630ad389627f8727cbff0a52

See more details on using hashes here.

File details

Details for the file passagemath_polyhedra-10.4.62-cp39-cp39-macosx_13_0_x86_64.whl.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.62-cp39-cp39-macosx_13_0_x86_64.whl
Algorithm Hash digest
SHA256 a8eea90e8fc989b391eaa6aa314c255b913378831178f2062eb4e7279eeb7f0d
MD5 2f808137f3770f44f480d9cc6e979264
BLAKE2b-256 ee3cfd83329127a5c604349253ffe0a886984b560a17f69ebe602303e72e55ff

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page