Laurent Series Rings#

EXAMPLES:

sage: R = LaurentSeriesRing(QQ, "x")
sage: R.base_ring()
Rational Field
sage: S = LaurentSeriesRing(GF(17)['x'], 'y')
sage: S
Laurent Series Ring in y over
 Univariate Polynomial Ring in x over Finite Field of size 17
sage: S.base_ring()
Univariate Polynomial Ring in x over Finite Field of size 17
class sage.rings.laurent_series_ring.LaurentSeriesRing(power_series)#

Bases: UniqueRepresentation, CommutativeRing

Univariate Laurent Series Ring.

EXAMPLES:

sage: R = LaurentSeriesRing(QQ, 'x'); R
Laurent Series Ring in x over Rational Field
sage: x = R.0
sage: g = 1 - x + x^2 - x^4 + O(x^8); g
1 - x + x^2 - x^4 + O(x^8)
sage: g = 10*x^(-3) + 2006 - 19*x + x^2 - x^4 +O(x^8); g
10*x^-3 + 2006 - 19*x + x^2 - x^4 + O(x^8)

You can also use more mathematical notation when the base is a field:

sage: Frac(QQ[['x']])
Laurent Series Ring in x over Rational Field
sage: Frac(GF(5)['y'])
Fraction Field of Univariate Polynomial Ring in y over Finite Field of size 5

When the base ring is a domain, the fraction field is the Laurent series ring over the fraction field of the base ring:

sage: Frac(ZZ[['t']])
Laurent Series Ring in t over Rational Field

Laurent series rings are determined by their variable and the base ring, and are globally unique:

sage: # needs sage.rings.padics
sage: K = Qp(5, prec=5)
sage: L = Qp(5, prec=200)
sage: R.<x> = LaurentSeriesRing(K)
sage: S.<y> = LaurentSeriesRing(L)
sage: R is S
False
sage: T.<y> = LaurentSeriesRing(Qp(5, prec=200))
sage: S is T
True
sage: W.<y> = LaurentSeriesRing(Qp(5, prec=199))
sage: W is T
False

sage: K = LaurentSeriesRing(CC, 'q'); K                                         # needs sage.rings.real_mpfr
Laurent Series Ring in q over Complex Field with 53 bits of precision
sage: loads(K.dumps()) == K                                                     # needs sage.rings.real_mpfr
True
sage: P = QQ[['x']]
sage: F = Frac(P)
sage: TestSuite(F).run()

When the base ring \(k\) is a field, the ring \(k((x))\) is a CDVF, that is a field equipped with a discrete valuation for which it is complete. The appropriate (sub)category is automatically set in this case:

sage: k = GF(11)
sage: R.<x> = k[[]]
sage: F = Frac(R)
sage: F.category()
Join of
 Category of complete discrete valuation fields and
 Category of commutative algebras over (finite enumerated fields and
 subquotients of monoids and quotients of semigroups) and
 Category of infinite sets
sage: TestSuite(F).run()
Element#

alias of LaurentSeries

base_extend(R)#

Return the Laurent series ring over R in the same variable as self, assuming there is a canonical coerce map from the base ring of self to R.

EXAMPLES:

sage: K.<x> = LaurentSeriesRing(QQ, default_prec=4)
sage: K.base_extend(QQ['t'])
Laurent Series Ring in x over Univariate Polynomial Ring in t over Rational Field
change_ring(R)#

EXAMPLES:

sage: K.<x> = LaurentSeriesRing(QQ, default_prec=4)
sage: R = K.change_ring(ZZ); R
Laurent Series Ring in x over Integer Ring
sage: R.default_prec()
4
characteristic()#

EXAMPLES:

sage: R.<x> = LaurentSeriesRing(GF(17))
sage: R.characteristic()
17
construction()#

Return the functorial construction of this Laurent power series ring.

The construction is given as the completion of the Laurent polynomials.

EXAMPLES:

sage: L.<t> = LaurentSeriesRing(ZZ, default_prec=42)
sage: phi, arg = L.construction()
sage: phi
Completion[t, prec=42]
sage: arg
Univariate Laurent Polynomial Ring in t over Integer Ring
sage: phi(arg) is L
True

Because of this construction, pushout is automatically available:

sage: 1/2 * t
1/2*t
sage: parent(1/2 * t)
Laurent Series Ring in t over Rational Field

sage: QQbar.gen() * t                                                       # needs sage.rings.number_field
I*t
sage: parent(QQbar.gen() * t)                                               # needs sage.rings.number_field
Laurent Series Ring in t over Algebraic Field
default_prec()#

Get the precision to which exact elements are truncated when necessary (most frequently when inverting).

EXAMPLES:

sage: R.<x> = LaurentSeriesRing(QQ, default_prec=5)
sage: R.default_prec()
5
fraction_field()#

Return the fraction field of this ring of Laurent series.

If the base ring is a field, then Laurent series are already a field. If the base ring is a domain, then the Laurent series over its fraction field is returned. Otherwise, raise a ValueError.

EXAMPLES:

sage: R = LaurentSeriesRing(ZZ, 't', 30).fraction_field()
sage: R
Laurent Series Ring in t over Rational Field
sage: R.default_prec()
30

sage: LaurentSeriesRing(Zmod(4), 't').fraction_field()
Traceback (most recent call last):
...
ValueError: must be an integral domain
gen(n=0)#

EXAMPLES:

sage: R = LaurentSeriesRing(QQ, "x")
sage: R.gen()
x
is_dense()#

EXAMPLES:

sage: K.<x> = LaurentSeriesRing(QQ, sparse=True)
sage: K.is_dense()
False
is_exact()#

Laurent series rings are inexact.

EXAMPLES:

sage: R = LaurentSeriesRing(QQ, "x")
sage: R.is_exact()
False
is_field(proof=True)#

A Laurent series ring is a field if and only if the base ring is a field.

is_sparse()#

Return if self is a sparse implementation.

EXAMPLES:

sage: K.<x> = LaurentSeriesRing(QQ, sparse=True)
sage: K.is_sparse()
True
laurent_polynomial_ring()#

If this is the Laurent series ring \(R((t))\), return the Laurent polynomial ring \(R[t,1/t]\).

EXAMPLES:

sage: R = LaurentSeriesRing(QQ, "x")
sage: R.laurent_polynomial_ring()
Univariate Laurent Polynomial Ring in x over Rational Field
ngens()#

Laurent series rings are univariate.

EXAMPLES:

sage: R = LaurentSeriesRing(QQ, "x")
sage: R.ngens()
1
polynomial_ring()#

If this is the Laurent series ring \(R((t))\), return the polynomial ring \(R[t]\).

EXAMPLES:

sage: R = LaurentSeriesRing(QQ, "x")
sage: R.polynomial_ring()
Univariate Polynomial Ring in x over Rational Field
power_series_ring()#

If this is the Laurent series ring \(R((t))\), return the power series ring \(R[[t]]\).

EXAMPLES:

sage: R = LaurentSeriesRing(QQ, "x")
sage: R.power_series_ring()
Power Series Ring in x over Rational Field
random_element(algorithm='default')#

Return a random element of this Laurent series ring.

The optional algorithm parameter decides how elements are generated. Algorithms currently implemented:

  • 'default': Choose an integer shift using the standard distribution on the integers. Then choose a list of coefficients using the random_element function of the base ring, and construct a new element based on those coefficients, so that the i-th coefficient corresponds to the (i+shift)-th power of the uniformizer. The amount of coefficients is determined by the default_prec of the ring. Note that this method only creates non-exact elements.

EXAMPLES:

sage: S.<s> = LaurentSeriesRing(GF(3))
sage: S.random_element()  # random
s^-8 + s^-7 + s^-6 + s^-5 + s^-1 + s + s^3 + s^4
+ s^5 + 2*s^6 + s^7 + s^11 + O(s^12)
residue_field()#

Return the residue field of this Laurent series field if it is a complete discrete valuation field (i.e. if the base ring is a field, in which base it is also the residue field).

EXAMPLES:

sage: R.<x> = LaurentSeriesRing(GF(17))
sage: R.residue_field()
Finite Field of size 17

sage: R.<x> = LaurentSeriesRing(ZZ)
sage: R.residue_field()
Traceback (most recent call last):
...
TypeError: the base ring is not a field
uniformizer()#

Return a uniformizer of this Laurent series field if it is a discrete valuation field (i.e. if the base ring is actually a field). Otherwise, an error is raised.

EXAMPLES:

sage: R.<t> = LaurentSeriesRing(QQ)
sage: R.uniformizer()
t

sage: R.<t> = LaurentSeriesRing(ZZ)
sage: R.uniformizer()
Traceback (most recent call last):
...
TypeError: the base ring is not a field
sage.rings.laurent_series_ring.is_LaurentSeriesRing(x)#

Return True if this is a univariate Laurent series ring.

This is in keeping with the behavior of is_PolynomialRing versus is_MPolynomialRing.