Rewrite some formulas.