Ramer–Douglas–Peucker algorithm: Difference between revisions

Content deleted Content added
Simplify complexity prose
Removed idea section, it is unsourced since "big copy edit" revision in 2008, it is inaccurate as the algorithm does not use Hausdorff distance, in the algorithm the simplified curve is treated as a curve but the original curve is only treated using its vertices and the farthest point is always selected from the original curve, even if the idea section is correct it is still unnecessarily abstract and more confusing than the algorithm itself, feel free to discuss at my talk page
Line 2:
 
The '''Ramer–Douglas–Peucker algorithm''', also known as the '''Douglas–Peucker algorithm''' and '''iterative end-point fit algorithm''', is an algorithm that [[Decimation (signal processing)|decimates]] a curve composed of line segments to a similar curve with fewer points. It was one of the earliest successful algorithms developed for [[cartographic generalization]]. It produces the most accurate generalization, but it is also more time-consuming.<ref>{{cite journal |last1=Shi |first1=Wenzhong |last2=Cheung |first2=ChuiKwan |title=Performance Evaluation of Line Simplification Algorithms for Vector Generalization |journal=The Cartographic Journal |date=2006 |volume=43 |issue=1 |pages=27-44 |doi=10.1179/000870406x93490}}</ref>
 
== Idea ==
The purpose of the algorithm is, given a [[Polygonal chain|curve composed of line segments]] (which is also called a ''Polyline'' in some contexts), to find a similar curve with fewer points. The algorithm defines 'dissimilar' based on the maximum distance between the original curve and the simplified curve (i.e., the [[Hausdorff distance]] between the curves). The simplified curve consists of a subset of the points that defined the original curve.
 
== Algorithm ==