Piecewise sanitize

This fix allows common subexpression eliminate (cse) to work on Piecewise functions.

There is also a minor documentation fix for pde.py