modify math expression