Is it possible to have a ring UndeterminedCoefficientRing(R) which, for every functorial construction F(R) has pushout F(UndeterminedCoefficientRing(R)).
I am not sure whether the phrasing of the question is correct - it reflects my current understanding of the situation. For example, I'd like to have the following:
sage: R.<a,b,c> = QQ[]
sage: U = UndeterminedCoefficientRing(R)
sage: M = MatrixSpace(R, 2)
sage: m = M.matrix([[a, b], [0, c]])
sage: f = U.an_element(); f
u_1*a
sage: (f*m).parent() == MatrixSpace(U, 2)
True
sage: f*m
[u_1*a^2 u_1*a*b]
[0 u_1*a*c]
# similarly:
sage: s = SymmetricFunctions(R).s()
sage: Q = PolynomialRing(s, ["x", "y"])
sage: Q.inject_variables()
Defining x, y
sage: m = x*s[2,1] + y*s[3] + y*s[1,1,1]; m
(s[2, 1])*x + (s[1, 1, 1] + s[3])*y
sage: f*x + m
(u_1*a + s[2, 1])*x + (s[1, 1, 1] + s[3])*y
I am guessing that, to make this work, `SymmetricFunctions` must become at least a functorial construction.
Help is greatly appreciated,
Martin
PS: to give you an idea where this is heading, the following already works:
sage: R.<z,q> = LazyPowerSeriesRing(QQ)
sage: g = R.undefined()
sage: R.define_implicitly([g], [g - (z*q + z*g*~(1-g))])
sage: g
z*q + z^2*q + z^3*q + (z^4*q+z^3*q^2) + (z^5*q+3*z^4*q^2) + O(z,q)^7
but I want, that the following also works - and it doesn't, because of coercion issues:
sage: R.<x,y,t> = LazyPowerSeriesRing(QQ)
sage: M1 = R.undefined()
sage: M2 = R.undefined()
sage: eq1 = -t*(x - y)*M1(0, 0, t)*x + t*(x - 1)*(x + 1)*(y^2 + 1)*M1(0, y, t) + (t*x^2*y^2 + t*x*y + t*y^2 + t - x*y)*M1(x, y, t) + t*M2(0, 0, t)*x*y + x*y
sage: eq2 = -t*M1(0, 0, t)*x + t*(x - 1)*(y + 1)*M1(0, y, t) + t*(x*y + y + 1)*M1(x, y, t) - t*M2(0, 0, t)*x + t*(x - 1)*(y^2 + y^2 + y + 1)*M2(0, y, t) + (t*x^2*y^2 + t*x*y^2 + t*x*y + t*y^2 + t*y^2 + t*y + t - x*y)*M2(x, y, t)
sage: R.define_implicitly([M1, M2], [eq1, eq2])
sage: M1