Implemented mode edge neighbourhood structure