Replace mate with atom