differentiator: visitor-optimize: add a visitor which flattens stacked fractions after simplification.
differentiator: visitor-print: parenthesize nested nodes of same priority.

Without this, "x / (y * z)" becomes "x / y * z" since multiplication is the same
priority as division.

Note: this may need further tuning (wrt. functions and their arguments) or even
an idea change.