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.60.tar.gz (986.1 kB view details)

Uploaded Source

Built Distributions

passagemath_polyhedra-10.4.60-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.60-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.60-cp312-cp312-macosx_14_0_arm64.whl (6.9 MB view details)

Uploaded CPython 3.12 macOS 14.0+ ARM64

passagemath_polyhedra-10.4.60-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.60-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.60-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.60-cp311-cp311-macosx_14_0_arm64.whl (6.9 MB view details)

Uploaded CPython 3.11 macOS 14.0+ ARM64

passagemath_polyhedra-10.4.60-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.60-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.60-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.60-cp310-cp310-macosx_14_0_arm64.whl (6.9 MB view details)

Uploaded CPython 3.10 macOS 14.0+ ARM64

passagemath_polyhedra-10.4.60-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.60-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.60-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.60-cp39-cp39-macosx_14_0_arm64.whl (6.9 MB view details)

Uploaded CPython 3.9 macOS 14.0+ ARM64

passagemath_polyhedra-10.4.60-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.60.tar.gz.

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60.tar.gz
Algorithm Hash digest
SHA256 c25c3c11ffc12817599d170b7415d847021668b2ea812700b1d76cab0db99f33
MD5 074b348dc7baf24d629f49372ad73798
BLAKE2b-256 1329f52a0f0e40d8f2c7cdeb25ea3607d020783d12f314476ac7ae32440b0f4f

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 f1cb448e4d5f68fa0eddda3e61937f3b7828336a634e33d216ab1d9ad6853ef9
MD5 497c094bbe8727b263cb06e7d666c6dd
BLAKE2b-256 31c6d6172f16e98294431bb0970004d35b0c6da75e811bf6d8d5370526db7127

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 ad97dde606d529de3ded5d6cbfd2d4ae429245149eca0c4da2272180a955d378
MD5 1533200f434868a6bd057caf342a73c1
BLAKE2b-256 65bd1c65883b15c48e95cf30b95a347b8809b45fdc69b1ed84ddb8ff95558951

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp312-cp312-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 3e3a0d08e27d78f137efb9839a25433056396855b1e46dd894eef7952b774a89
MD5 9fc87f9c139042209adb40dc2d510cb1
BLAKE2b-256 52491497822109424d10cd6424f301de3f6c21ed563e0242db5c279f159e22fc

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp312-cp312-macosx_13_0_x86_64.whl
Algorithm Hash digest
SHA256 2f19a5cb46b46bb4867c75de0227e4e364bdd63c647b241d3b23109cbd105135
MD5 963c71fe43303b5b74f2ed684f79e1bb
BLAKE2b-256 3f668d1c5aae35354931a38ccff7325dce73022986cda202665f5d6831b3549d

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 dce8f8b173252f8b55929c0392cc52094bdb24df2c6c69ebbcd3e3609a7634a7
MD5 2d238a7d7af37beabd519ea1749e0a6b
BLAKE2b-256 90a3a7304c0e22ffea721657d35efedff8f63ce047b87abccc4c91101f33e8d3

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 a7669f72e564c7ab0f494ddfa4d19667b3d6a2ae8ad64a27eb07c38a3374bea5
MD5 e52bdee9978fab746603ae048399274a
BLAKE2b-256 e3123c62aed77c9d66ea281f38499c1dd03fa2d86cb0ce3ad016f3fbbd19bc58

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp311-cp311-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 5bc4207da922b867605409a03c59dab69a9828843c3ba7bbaf079a0f9558563f
MD5 9e0e94a52f59fc8c3941aa19d63a78fe
BLAKE2b-256 d1e25b2df86d9ab4ebd3121979fa79257b4ea159fef8ec5fcd64a97e368133c3

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp311-cp311-macosx_13_0_x86_64.whl
Algorithm Hash digest
SHA256 e6d0afd42c5607141b3ae1b76e96090e23eeffbbd428fbb5d3e2e2e33e391e96
MD5 6f37544e65912c15cae6bc332ed398a4
BLAKE2b-256 d6cdb3b83ea2444a624f9341ebf042640d6e1de028fb1c6713a7fd2f6922b103

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 9c87295af2f44ca0f822fef3a91ee312f6de02b82ead727adb19c04188b0cbb7
MD5 de7ccda56fa424e5c0c042e3f363f282
BLAKE2b-256 de11d36351d06f7193744a75c10fd7525cdfc7c478344ea0564d0cefbbc2bef7

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 b26bfa23d1dbe5d832401d08575a1553eb9db72a1e96f9ccbd47a327a6e3d55c
MD5 e66ca4df4b32e0da66b7e5c08405e81e
BLAKE2b-256 45baebf62fb49b599a7d66204a65d4101211e810301106960eed0f260871ad60

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp310-cp310-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 2c256f883832b990e58a1990a496b21661d0a7aca67b98a5c2aa36e31367cb7d
MD5 a06a73301ace1ed90f17d609ecc8a4d9
BLAKE2b-256 4061587d278b4c75e7307a7e0c4e187572b7378cb3e23e3e77318f3b11345707

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp310-cp310-macosx_13_0_x86_64.whl
Algorithm Hash digest
SHA256 b6e092b29b4030af123109c958cd62438f0d81cd6549ed2948b5b02eba9da163
MD5 6795b5b658919c2cb02e255c75156b36
BLAKE2b-256 2844a03ea3e7b2c8c71db08e481ec56c00f7c483e9c2c0a19267700551203f21

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp39-cp39-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 c4089f9bdd24270bf5b54aac6a8c9b89d58f105110e7c2374e547bbe05da0139
MD5 acdac1afc765ebdac89ec0c516f9fede
BLAKE2b-256 1145f6cdfca704ad073fbcdb8b47cf6970deed2612d8f8401f42523216af126a

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 9c5f1456b5b3a6b0e800e6f069a2a64635ff8c760624db7e6c620a231d0cd9e3
MD5 2cefc8925956d00343c322dcdc5e6e11
BLAKE2b-256 c08d35da3f045977854f22e0f73c698965c66834fef01b354fa44e77f73e0b2f

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp39-cp39-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 4d30506721893ea711e002abd83fa0b4d894cd3b5cc15221d5d43435e8f7859f
MD5 3c26bf92598ab0bac8162b87702f83cd
BLAKE2b-256 b9e8c65e64ef14b2634307c57f3a60cee18a319a7480bacafa8d094a2f962455

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for passagemath_polyhedra-10.4.60-cp39-cp39-macosx_13_0_x86_64.whl
Algorithm Hash digest
SHA256 26667ae99288fdfc1b12f8c983d981db00e8e3fd3efa258c13793253a7e6b810
MD5 63620552af44be8190adde06f8637291
BLAKE2b-256 50d4bf2f3debbda6231ee2a45a0e5e91a865b2323187136ecd786406b213c70e

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