gh-37687: provide a construction functor using a single functor for families
We enable sage to find common parents also when symmetric functions are
involved. In particular, we provide a functorial construction that takes
a commutative (coefficient) ring and produces a (commutative) ring of
symmetric functions over this ring.
For Macdonald polynomials and other symmetric functions that involve
parameters we cheat a bit: the categories should actually be commutative
rings with distinguished elements (namely, the parameters). However,
having these is very likely overkill.
This is an alternative to #37220, relying on individual construction
functors instead of passing around strings, and #37686, which provides
an individual functor for each family.
URL: https://github.com/sagemath/sage/pull/37687
Reported by: Martin Rubey
Reviewer(s): Travis Scrimshaw