Re-coding the add-regular-edges.