Added a function that returns the index of a key in a simplex set.