The following functions are used by the access and update routines to locate the bin which corresponds to a given (x,y) coordinate.
This function finds and sets the indices i and j to
the bin which covers the coordinates (x,y). The bin is
located using a binary search. The search includes an optimization for
histograms with uniform ranges, and will return the correct bin immediately
in this case. If (x,y) is found then the function sets the
indices (i,j) and returns
(x,y) lies outside the valid range of the histogram then the
GSL_EDOM and the error handler is invoked.