@@ -173,7 +173,7 @@ def distance_point_point_sqrd_xy(a, b):
173173
174174
175175def distance_point_line (point , line ):
176- """Compute the distance between a point and a line.
176+ """Compute the distance between a point and a line [wikipedia2017c]_ .
177177
178178 This implementation computes the *right angle distance* from a point P to a
179179 line defined by points A and B as twice the area of the triangle ABP divided
@@ -195,10 +195,6 @@ def distance_point_line(point, line):
195195 --------
196196 >>>
197197
198- References
199- ----------
200- https://en.wikipedia.org/wiki/Distance_from_a_point_to_a_line
201-
202198 """
203199 a , b = line
204200 ab = subtract_vectors (b , a )
@@ -210,7 +206,7 @@ def distance_point_line(point, line):
210206
211207
212208def distance_point_line_xy (point , line ):
213- """Compute the distance between a point and a line, assuming they lie in the XY-plane.
209+ """Compute the distance between a point and a line, assuming they lie in the XY-plane [wikipedia2017c]_ .
214210
215211 This implementation computes the orthogonal distance from a point P to a
216212 line defined by points A and B as twice the area of the triangle ABP divided
@@ -228,10 +224,6 @@ def distance_point_line_xy(point, line):
228224 float
229225 The distance between the point and the line.
230226
231- References
232- ----------
233- https://en.wikipedia.org/wiki/Distance_from_a_point_to_a_line
234-
235227 """
236228 a , b = line
237229 ab = subtract_vectors_xy (b , a )
@@ -243,7 +235,7 @@ def distance_point_line_xy(point, line):
243235
244236
245237def distance_point_line_sqrd (point , line ):
246- """Compute the squared distance between a point and a line.
238+ """Compute the squared distance between a point and a line [wikipedia2017c]_ .
247239
248240 Parameters
249241 ----------
@@ -257,9 +249,6 @@ def distance_point_line_sqrd(point, line):
257249 float
258250 The squared distance between the point and the line.
259251
260- References
261- ----------
262- https://en.wikipedia.org/wiki/Distance_from_a_point_to_a_line
263252
264253 """
265254 a , b = line
@@ -272,7 +261,7 @@ def distance_point_line_sqrd(point, line):
272261
273262
274263def distance_point_line_sqrd_xy (point , line ):
275- """Compute the squared distance between a point and a line lying in the XY-plane.
264+ """Compute the squared distance between a point and a line lying in the XY-plane [wikipedia2017c]_ .
276265
277266 This implementation computes the orthogonal squared distance from a point P to a
278267 line defined by points A and B as twice the area of the triangle ABP divided
@@ -290,10 +279,6 @@ def distance_point_line_sqrd_xy(point, line):
290279 float
291280 The squared distance between the point and the line.
292281
293- References
294- ----------
295- https://en.wikipedia.org/wiki/Distance_from_a_point_to_a_line
296-
297282 """
298283 a , b = line
299284 ab = subtract_vectors_xy (b , a )
@@ -305,7 +290,7 @@ def distance_point_line_sqrd_xy(point, line):
305290
306291
307292def distance_point_plane (point , plane ):
308- r"""Compute the distance from a point to a plane defined by three points.
293+ r"""Compute the distance from a point to a plane defined by three points [nykamp2012]_ .
309294
310295 The distance from a pioint to a planbe can be computed from the coefficients
311296 of the equation of the plane and the coordinates of the point.
@@ -350,18 +335,14 @@ def distance_point_plane(point, plane):
350335 --------
351336 >>>
352337
353- References
354- ----------
355- http://mathinsight.org/distance_point_plane
356-
357338 """
358339 base , normal = plane
359340 vector = subtract_vectors (point , base )
360341 return fabs (dot_vectors (vector , normal ))
361342
362343
363344def distance_line_line (l1 , l2 , tol = 0.0 ):
364- """Compute the shortest distance between two lines.
345+ """Compute the shortest distance between two lines [wisstein2017]_, [wikipedia2017d]_ .
365346
366347 The distance is the absolute value of the dot product of a unit vector that
367348 is perpendicular to the two lines, and the vector between two points on the lines.
@@ -386,11 +367,6 @@ def distance_line_line(l1, l2, tol=0.0):
386367 --------
387368 >>>
388369
389- References
390- ----------
391- http://mathworld.wolfram.com/Line-LineDistance.html
392- https://en.wikipedia.org/wiki/Skew_lines#Distance
393-
394370 """
395371 a , b = l1
396372 c , d = l2
@@ -763,7 +739,7 @@ def closest_point_on_polygon_xy(point, polygon):
763739
764740def closest_point_on_plane (point , plane ):
765741 """
766- Compute closest point on a plane to a given point.
742+ Compute closest point on a plane to a given point [wikipedia2017e]_ .
767743
768744 Parameters
769745 ----------
@@ -783,10 +759,6 @@ def closest_point_on_plane(point, plane):
783759 >>> point = [1.0, 2.0, 3.0]
784760 >>> closest_point_on_plane(point, plane)
785761
786- References
787- ----------
788- http://en.wikipedia.org/wiki/Distance_from_a_point_to_a_plane
789-
790762 """
791763 base , normal = plane
792764 x , y , z = base
0 commit comments