-
Notifications
You must be signed in to change notification settings - Fork 73
Kute Matching Algorithm
-
One of the basic requirement while creating a pooling solution be it any resource is to create an algorithm which matches the people who can efficiently pool resources.
-
Thus here at KUTE,We created this matching algorithm that would match people's trips based on the geographies of their starting and end points
-
Let Us Assume we have two users one is the person with the car travelling from point 1 to point 2,lets call him A and the other one who wishes to pool with this guy,is travelling from 3 to 4,lets call him B.
-
The conditioned discussed above should be a perfect match since A's Route is a superset of B's route.
-
We compare these paths by breaking their respective route polylines into set of co-ordinates or route steps and then compare the respective points keeping a small offset.
-
The Decision whether the two routes are compatible is taken by comparing the first matched co-ordinate with the first co-ordinate the Rider's Trip,if its less than 500m that is the rider has to travel a maximum of 500m to reach out to the host we declare it as a match
-
The Algorithm Currently runs in O(MxN) run time(Where M and N are the number of co-ordinate pairs in the step set of the route) and we seek to improve on that
