Determining neighbors