Symbols

Implements geometric objects used in the graph representation.

class Symbol(name, symbols_graph, dep)

Bases: ABC

Symbol in the symbols graph.

Can be Point, Line, Circle, etc.

Each node maintains a merge history to other nodes if they are (found out to be) equivalent

a -> b -
        \
    c -> d -> e -> f -> g

d.merged_to = e d.rep = g d.merged_from = {a, b, c, d} d.equivs = {a, b, c, d, e, f, g} d.members = {a, b, c, d}

rep()
Return type:

Self

merge(nodes)

Merge all nodes.

Return type:

None

class Point(name, symbols_graph, dep)

Bases: Symbol

num: PointNum
property pretty_name: str
class Line(name, symbols_graph, dep)

Bases: Symbol

Symbol of type Line.

points: set[Point]
num: LineNum
classmethod check_coll(points)
Return type:

bool

classmethod make_coll(points, dep)
Return type:

tuple[Line, list[Line]]

classmethod why_coll(statement)
Return type:

Dependency

property pretty_name: str
class Circle(name, symbols_graph, dep)

Bases: Symbol

Symbol of type Circle.

points: set[Point]
num: CircleNum
classmethod check_cyclic(points)
Return type:

bool

classmethod make_cyclic(points, dep)
classmethod why_cyclic(statement)
Return type:

Dependency

property pretty_name: str