remove unnecessary terms