MCPcopy Create free account
hub / github.com/google-deepmind/alphageometry / midpoint

Method midpoint

numericals.py:84–85  ·  view source on GitHub ↗
(self, p: Point)

Source from the content-addressed store, hash-verified

82 return abs(self.x - point.x) < tol and abs(self.y - point.y) < tol
83
84 def midpoint(self, p: Point) -> Point:
85 return Point(0.5 * (self.x + p.x), 0.5 * (self.y + p.y))
86
87 def distance(self, p: Union[Point, Line, Circle]) -> float:
88 if isinstance(p, Line):

Callers

nothing calls this directly

Calls 1

PointClass · 0.70

Tested by

no test coverage detected