returns input term if alle terms are eliminated
adds braces to if