Refactor to ABCheck and ArithGeo