X-Git-Url: https://svn.cri.ensmp.fr/git/linpy.git/blobdiff_plain/0995f79a8db531aa3a2ca951af65f3f0fa4943e5..663316ddc03c19cf06e95bad67fd5ac2bb5e1dfc:/pypol/domains.py?ds=sidebyside diff --git a/pypol/domains.py b/pypol/domains.py index 3ab7d44..255c995 100644 --- a/pypol/domains.py +++ b/pypol/domains.py @@ -312,6 +312,12 @@ class Domain: points.append(Point(coordinates)) return points + def __contains__(self, point): + for polyhedron in self.polyhedra: + if point in polyhedron: + return True + return False + def subs(self, symbol, expression=None): polyhedra = [polyhedron.subs(symbol, expression) for polyhedron in self.polyhedra]