Switch polygonal generators to wrappers

The three generators of polygonal numbers, triangulars, pentagonals, and
hexagonals, are now wrappers around the generic polygonal generator:
polygonals

This allows us to remove duplicate logic from these functions and
instead keep only the unique constants they use.