>>> help(Line.perpendicular_segment)
Help on method perpendicular_segment in module sympy.geometry.line:
perpendicular_segment(self, p) unbound sympy.geometry.line.Line
method
Returns a new Segment which connects p to a point on this linear
entity and is also perpendicular to this line. Returns p itself
if p is on this linear entity.
>>> l=Line(Point(1,2), Point(2,3))
>>> l.perpendicular_segment(Point(0,0))
Segment(Point(Rational(-1, 2), Half(1, 2)), Point(Zero, Zero))
>>> p=Point(3,4)
>>> p in l
True
>>> l.perpendicular_segment(p)
Point(Integer(3), Integer(4))
Looks like your point in on the line.
--
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sympy?hl=en.