Determining if a set of points represents a function