Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

You don't need variables in that sense. Note that

sage: PolynomialRing?

has very extensive documentation on constructing such rings. E.g., it has examples basically like what you want.

sage: R = PolynomialRing(ZZ, 'x', 5)
sage: R
Multivariate Polynomial Ring in x0, x1, x2, x3, x4 over Integer Ring
sage: x0
NameError: name 'x0' is not defined
sage: R.inject_variables()
Defining x0, x1, x2, x3, x4
sage: x0