adding files to update the edge fliping logic