codezonediitj / pydatastructs

A python package for data structures and algorithms
https://pydatastructs.readthedocs.io/en/stable/
Other
199 stars 269 forks source link

Implementing Wrapping Algorithm(Jarvis March) #493

Open svenkat19 opened 2 years ago

svenkat19 commented 2 years ago

Description of the problem

To find convex hull using Wrapping algorithm

(I will be able to do this as a part of GSSoC'22)

Example of the problem

References/Other comments

https://www.youtube.com/watch?v=ZnTiWcIznEQ&ab_channel=LeiosLabs

czgdp1807 commented 2 years ago

What are the applications of convex hull algorithm? What will the API for finding convex hull? Any thoughts?

svenkat19 commented 2 years ago

APPLICATIONS OF CONVEX HULL

Collision avoidance: If the convex hull of a car avoids collision with obstacles then so does the car. Since the computation of paths that avoid collision is much easier with a convex car, then it is often used to plan paths. collision avoidance using convex hull

Smallest box: The smallest area rectangle that encloses a polygon has at least one side flush with the convex hull of the polygon, and so the hull is computed at the first step of minimum rectangle algorithms. Similarly, finding the smallest three-dimensional box surrounding an object depends on the 3D-convex hull.

Shape analysis: Shapes may be classified for the purposes of matching by their "convex deficiency trees", structures that depend for their computation on convex hulls.

czgdp1807 commented 2 years ago

N.B. https://en.wikipedia.org/wiki/Convex_hull#Applications

Now coming on to API of convex hull algorithm, how would the call to the function (which will find convex hull) look like?

svenkat19 commented 2 years ago

Get the vertices of the convex hull in a List during function call. Returns: vertices of the convex hull in a list.