ENH: flexible polynomial degree