Skip to main content

An Object-Oriented Python Interface to Singular

Project description

A Python Interface & Extension to Singular

Continuous Integration Status Coverage PyPI Downloads Binder

The syngular library is a Python 3 package for algebraic geometry computations. It provides an intuitive and object-oriented interface to Singular. Furthermore, it extends the numerical capabilities of Singular, providing a numerical solver for arbitrary systems of polynomial equations in tandem with pyadic, and its applicaibility to physics computations, where generic algorithms may be insufficient.

Interface

Python classes for 'Ideal', 'Ring' and 'QuotientRing'. Several related functions accessible as attributes or methods. Intuitive operations through magic methods, e.g. Ideal addition '+' and intersection '&'.

Extension

Points on varieties over $\mathbb{F}_p$, $\mathbb{Q}_p$ and $\mathbb{C}$.

The function ideal.point_on_variety allows generate numerical solutions to arbirary systems of polynomial equations in arbitrary polynomial quotient rings, over any of the three above mentioned fields. The system of equations may be underconstrained, i.e. the ideal may have any dimension. The $p$-adic and complex solutions can be requested as not exact. I.e. the point may lie close to but not exactly on the associated variety. This is essential for numerical computations where otherwise division-by-zero erros may occur. The limitation is that Singular must be able to compute an indepednent set for the ideal, in order to reduce it to a zero dimensional sub-variety.

Primality test (lighter than a primary decomposition).

The function ideal.test_primality allows to test whether an ideal is prime or not, without performing a full primary decomposition. The algorithm can run also with successively looser degree bounds. It returns True if the idea is prime, False if it is not, or raises an Inconclusive exception if it cannot decide. The latter case happens, for instance, if the ideal is not radical, since the algorithm may not be able to find a linear projection. Inconclusive cases include when the ideal is primary but not prime.

Requirements

numpy, sympy, mutableint, Singular

Installation

pip install -e path/to/repo

Testing

pytest --cov syngular/ --cov-report html tests/ --verbose

Quick Start

from syngular import Ideal, Ring
I = Ideal(Ring('0', ('x1', 'x2'), 'dp'), ['x1*x2'])

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

syngular-0.2.1.tar.gz (30.8 kB view hashes)

Uploaded Source

Built Distribution

syngular-0.2.1-py3-none-any.whl (29.4 kB view hashes)

Uploaded Python 3

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