Skip to main content

Polytope operations --- limited functionality

Project description

pytope

Package with a limited set of operations for polytopes, zonotopes, and invariant sets.

The currently implemented features include

  • constructing polytopes from inequalities (halfspace representation), vertices, and upper and lower bounds,
  • linear mapping (multiplying a matrix M and a polytope P: M P),
  • the Minkowski sum and Pontryagin difference of polytopes,
  • the intersection of polytopes, and
  • simple plotting.

The figures below are generated with pytope. The first two illustrate the currently implemented operations (see demo.py); the third uses pytope to plot a robust MPC trajectory (implemented in CasADi, combining Figures 1 and 2 from Mayne et al. (2005)) (with a rough approximation of the disturbance sequence); the fourth shows an outer ε-approximation of a minimal robust positively invariant (or MRPI) set (computed with pytope), reproducing the example from Raković et al. (2005).

Most of pytope is experimental, fragile, largely untested, and buggy.

Illustration of various polytope operations
Figure: Illustration of various polytope operations.

The Minkowski sum of two polytopes
Figure: The Minkowski sum of two polytopes.

Robust MPC trajectory from Mayne et al. (2005)
Figure: Robust MPC trajectory from Mayne et al. (2005), combining Figures 1 and 2.

Outer ε-approximation of a minimal RPI
Figure: Outer ε-approximation of a minimal robust positively invariant (MRPI) set – a reproduction of the example in Raković et al. (2005).

References

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for pytope, version 0.0.4
Filename, size File type Python version Upload date Hashes
Filename, size pytope-0.0.4-py3-none-any.whl (11.7 kB) File type Wheel Python version py3 Upload date Hashes View hashes
Filename, size pytope-0.0.4.tar.gz (12.0 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page