def get_slope (points, i):
	"""
        Returns the slope at a certain point in %

        Parameters
        ----------
        points: list of points
        i: 		point no to calculate slope from

        """

	if i == 0 or points[i].distance_3d(points[i-1]) == 0:
		return 0

	return 100 * (points[i].elevation - points[i - 1].elevation) / points[i].distance_3d(points[i - 1])