splines, constant extrapolation

continues, supersedes and closes gh-3697.
Adds a constant extrapolation mode to UniveriateSpline.
Basically, this is just a rebase of gh-3697 on master now that gh-3773 has been merged.