try to fix this arithmetic stuff