piecewise_fold with Piecewise in a cond.