Solve equations with variable exponents