% r = fnval(pp,x) or r = fnval(x,pp) % Compute the value of the piece-wise polynomial pp at points x.