Discrete valuations on function fields#

AUTHORS:

  • Julian Rüth (2016-10-16): initial version

EXAMPLES:

We can create classical valuations that correspond to finite and infinite places on a rational function field:

sage: K.<x> = FunctionField(QQ)
sage: v = K.valuation(1); v
(x - 1)-adic valuation
sage: v = K.valuation(x^2 + 1); v
(x^2 + 1)-adic valuation
sage: v = K.valuation(1/x); v
Valuation at the infinite place
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> v = K.valuation(Integer(1)); v
(x - 1)-adic valuation
>>> v = K.valuation(x**Integer(2) + Integer(1)); v
(x^2 + 1)-adic valuation
>>> v = K.valuation(Integer(1)/x); v
Valuation at the infinite place

Note that we can also specify valuations which do not correspond to a place of the function field:

sage: R.<x> = QQ[]
sage: w = valuations.GaussValuation(R, QQ.valuation(2))
sage: v = K.valuation(w); v
2-adic valuation
>>> from sage.all import *
>>> R = QQ['x']; (x,) = R._first_ngens(1)
>>> w = valuations.GaussValuation(R, QQ.valuation(Integer(2)))
>>> v = K.valuation(w); v
2-adic valuation

Valuations on a rational function field can then be extended to finite extensions:

sage: v = K.valuation(x - 1); v
(x - 1)-adic valuation
sage: R.<y> = K[]
sage: L.<y> = K.extension(y^2 - x)                                                  # needs sage.rings.function_field
sage: w = v.extensions(L); w                                                        # needs sage.rings.function_field
[[ (x - 1)-adic valuation, v(y + 1) = 1 ]-adic valuation,
 [ (x - 1)-adic valuation, v(y - 1) = 1 ]-adic valuation]
>>> from sage.all import *
>>> v = K.valuation(x - Integer(1)); v
(x - 1)-adic valuation
>>> R = K['y']; (y,) = R._first_ngens(1)
>>> L = K.extension(y**Integer(2) - x, names=('y',)); (y,) = L._first_ngens(1)# needs sage.rings.function_field
>>> w = v.extensions(L); w                                                        # needs sage.rings.function_field
[[ (x - 1)-adic valuation, v(y + 1) = 1 ]-adic valuation,
 [ (x - 1)-adic valuation, v(y - 1) = 1 ]-adic valuation]

REFERENCES:

An overview of some computational tools relating to valuations on function fields can be found in Section 4.6 of [Rüt2014]. Most of this was originally developed for number fields in [Mac1936I] and [Mac1936II].

class sage.rings.function_field.valuation.ClassicalFunctionFieldValuation_base(parent)[source]#

Bases: DiscreteFunctionFieldValuation_base

Base class for discrete valuations on rational function fields that come from points on the projective line.

class sage.rings.function_field.valuation.DiscreteFunctionFieldValuation_base(parent)[source]#

Bases: DiscreteValuation

Base class for discrete valuations on function fields.

extensions(L)[source]#

Return the extensions of this valuation to L.

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: v = K.valuation(x)
sage: R.<y> = K[]
sage: L.<y> = K.extension(y^2 - x)                                          # needs sage.rings.function_field
sage: v.extensions(L)                                                       # needs sage.rings.function_field
[(x)-adic valuation]
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> v = K.valuation(x)
>>> R = K['y']; (y,) = R._first_ngens(1)
>>> L = K.extension(y**Integer(2) - x, names=('y',)); (y,) = L._first_ngens(1)# needs sage.rings.function_field
>>> v.extensions(L)                                                       # needs sage.rings.function_field
[(x)-adic valuation]
class sage.rings.function_field.valuation.FiniteRationalFunctionFieldValuation(parent, base_valuation)[source]#

Bases: InducedRationalFunctionFieldValuation_base, ClassicalFunctionFieldValuation_base, RationalFunctionFieldValuation_base

Valuation of a finite place of a function field.

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: v = K.valuation(x + 1); v  # indirect doctest
(x + 1)-adic valuation
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> v = K.valuation(x + Integer(1)); v  # indirect doctest
(x + 1)-adic valuation

A finite place with residual degree:

sage: w = K.valuation(x^2 + 1); w
(x^2 + 1)-adic valuation
>>> from sage.all import *
>>> w = K.valuation(x**Integer(2) + Integer(1)); w
(x^2 + 1)-adic valuation

A finite place with ramification:

sage: K.<t> = FunctionField(GF(3))
sage: L.<x> = FunctionField(K)
sage: u = L.valuation(x^3 - t); u
(x^3 + 2*t)-adic valuation
>>> from sage.all import *
>>> K = FunctionField(GF(Integer(3)), names=('t',)); (t,) = K._first_ngens(1)
>>> L = FunctionField(K, names=('x',)); (x,) = L._first_ngens(1)
>>> u = L.valuation(x**Integer(3) - t); u
(x^3 + 2*t)-adic valuation

A finite place with residual degree and ramification:

sage: q = L.valuation(x^6 - t); q
(x^6 + 2*t)-adic valuation
>>> from sage.all import *
>>> q = L.valuation(x**Integer(6) - t); q
(x^6 + 2*t)-adic valuation
class sage.rings.function_field.valuation.FunctionFieldExtensionMappedValuation(parent, base_valuation, to_base_valuation_domain, from_base_valuation_domain)[source]#

Bases: FunctionFieldMappedValuationRelative_base

A valuation on a finite extensions of function fields \(L=K[y]/(G)\) where \(K\) is another function field which redirects to another base_valuation on an isomorphism function field \(M=K[y]/(H)\).

The isomorphisms must be trivial on K.

EXAMPLES:

sage: K.<x> = FunctionField(GF(2))
sage: R.<y> = K[]
sage: L.<y> = K.extension(y^2 + y + x^3)                                        # needs sage.rings.function_field
sage: v = K.valuation(1/x)
sage: w = v.extension(L)                                                        # needs sage.rings.function_field

sage: w(x)                                                                      # needs sage.rings.function_field
-1
sage: w(y)                                                                      # needs sage.rings.function_field
-3/2
sage: w.uniformizer()                                                           # needs sage.rings.function_field
1/x^2*y
>>> from sage.all import *
>>> K = FunctionField(GF(Integer(2)), names=('x',)); (x,) = K._first_ngens(1)
>>> R = K['y']; (y,) = R._first_ngens(1)
>>> L = K.extension(y**Integer(2) + y + x**Integer(3), names=('y',)); (y,) = L._first_ngens(1)# needs sage.rings.function_field
>>> v = K.valuation(Integer(1)/x)
>>> w = v.extension(L)                                                        # needs sage.rings.function_field

>>> w(x)                                                                      # needs sage.rings.function_field
-1
>>> w(y)                                                                      # needs sage.rings.function_field
-3/2
>>> w.uniformizer()                                                           # needs sage.rings.function_field
1/x^2*y
restriction(ring)[source]#

Return the restriction of this valuation to ring.

EXAMPLES:

sage: # needs sage.rings.function_field
sage: K.<x> = FunctionField(GF(2))
sage: R.<y> = K[]
sage: L.<y> = K.extension(y^2 + y + x^3)
sage: v = K.valuation(1/x)
sage: w = v.extension(L)
sage: w.restriction(K) is v
True
>>> from sage.all import *
>>> # needs sage.rings.function_field
>>> K = FunctionField(GF(Integer(2)), names=('x',)); (x,) = K._first_ngens(1)
>>> R = K['y']; (y,) = R._first_ngens(1)
>>> L = K.extension(y**Integer(2) + y + x**Integer(3), names=('y',)); (y,) = L._first_ngens(1)
>>> v = K.valuation(Integer(1)/x)
>>> w = v.extension(L)
>>> w.restriction(K) is v
True
class sage.rings.function_field.valuation.FunctionFieldFromLimitValuation(parent, approximant, G, approximants)[source]#

Bases: FiniteExtensionFromLimitValuation, DiscreteFunctionFieldValuation_base

A valuation on a finite extensions of function fields \(L=K[y]/(G)\) where \(K\) is another function field.

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: R.<y> = K[]
sage: L.<y> = K.extension(y^2 - (x^2 + x + 1))                                  # needs sage.rings.function_field
sage: v = K.valuation(x - 1)  # indirect doctest                                # needs sage.rings.function_field
sage: w = v.extension(L); w                                                     # needs sage.rings.function_field
(x - 1)-adic valuation
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> R = K['y']; (y,) = R._first_ngens(1)
>>> L = K.extension(y**Integer(2) - (x**Integer(2) + x + Integer(1)), names=('y',)); (y,) = L._first_ngens(1)# needs sage.rings.function_field
>>> v = K.valuation(x - Integer(1))  # indirect doctest                                # needs sage.rings.function_field
>>> w = v.extension(L); w                                                     # needs sage.rings.function_field
(x - 1)-adic valuation
scale(scalar)[source]#

Return this valuation scaled by scalar.

EXAMPLES:

sage: # needs sage.rings.function_field
sage: K.<x> = FunctionField(QQ)
sage: R.<y> = K[]
sage: L.<y> = K.extension(y^2 - (x^2 + x + 1))
sage: v = K.valuation(x - 1) # indirect doctest
sage: w = v.extension(L)
sage: 3*w
3 * (x - 1)-adic valuation
>>> from sage.all import *
>>> # needs sage.rings.function_field
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> R = K['y']; (y,) = R._first_ngens(1)
>>> L = K.extension(y**Integer(2) - (x**Integer(2) + x + Integer(1)), names=('y',)); (y,) = L._first_ngens(1)
>>> v = K.valuation(x - Integer(1)) # indirect doctest
>>> w = v.extension(L)
>>> Integer(3)*w
3 * (x - 1)-adic valuation
class sage.rings.function_field.valuation.FunctionFieldMappedValuationRelative_base(parent, base_valuation, to_base_valuation_domain, from_base_valuation_domain)[source]#

Bases: FunctionFieldMappedValuation_base

A valuation on a function field which relies on a base_valuation on an isomorphic function field and which is such that the map from and to the other function field is the identity on the constant field.

EXAMPLES:

sage: K.<x> = FunctionField(GF(2))
sage: v = K.valuation(1/x); v
Valuation at the infinite place
>>> from sage.all import *
>>> K = FunctionField(GF(Integer(2)), names=('x',)); (x,) = K._first_ngens(1)
>>> v = K.valuation(Integer(1)/x); v
Valuation at the infinite place
restriction(ring)[source]#

Return the restriction of this valuation to ring.

EXAMPLES:

sage: K.<x> = FunctionField(GF(2))
sage: K.valuation(1/x).restriction(GF(2))
Trivial valuation on Finite Field of size 2
>>> from sage.all import *
>>> K = FunctionField(GF(Integer(2)), names=('x',)); (x,) = K._first_ngens(1)
>>> K.valuation(Integer(1)/x).restriction(GF(Integer(2)))
Trivial valuation on Finite Field of size 2
class sage.rings.function_field.valuation.FunctionFieldMappedValuation_base(parent, base_valuation, to_base_valuation_domain, from_base_valuation_domain)[source]#

Bases: FunctionFieldValuation_base, MappedValuation_base

A valuation on a function field which relies on a base_valuation on an isomorphic function field.

EXAMPLES:

sage: K.<x> = FunctionField(GF(2))
sage: v = K.valuation(1/x); v
Valuation at the infinite place
>>> from sage.all import *
>>> K = FunctionField(GF(Integer(2)), names=('x',)); (x,) = K._first_ngens(1)
>>> v = K.valuation(Integer(1)/x); v
Valuation at the infinite place
is_discrete_valuation()[source]#

Return whether this is a discrete valuation.

EXAMPLES:

sage: # needs sage.rings.function_field
sage: K.<x> = FunctionField(QQ)
sage: R.<y> = K[]
sage: L.<y> = K.extension(y^2 - x^4 - 1)
sage: v = K.valuation(1/x)
sage: w0,w1 = v.extensions(L)
sage: w0.is_discrete_valuation()
True
>>> from sage.all import *
>>> # needs sage.rings.function_field
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> R = K['y']; (y,) = R._first_ngens(1)
>>> L = K.extension(y**Integer(2) - x**Integer(4) - Integer(1), names=('y',)); (y,) = L._first_ngens(1)
>>> v = K.valuation(Integer(1)/x)
>>> w0,w1 = v.extensions(L)
>>> w0.is_discrete_valuation()
True
scale(scalar)[source]#

Return this valuation scaled by scalar.

EXAMPLES:

sage: K.<x> = FunctionField(GF(2))
sage: R.<y> = K[]
sage: L.<y> = K.extension(y^2 + y + x^3)                                    # needs sage.rings.function_field
sage: v = K.valuation(1/x)
sage: w = v.extension(L)                                                    # needs sage.rings.function_field
sage: 3*w                                                                   # needs sage.rings.function_field
3 * (x)-adic valuation (in Rational function field in x over Finite Field of size 2 after x |--> 1/x)
>>> from sage.all import *
>>> K = FunctionField(GF(Integer(2)), names=('x',)); (x,) = K._first_ngens(1)
>>> R = K['y']; (y,) = R._first_ngens(1)
>>> L = K.extension(y**Integer(2) + y + x**Integer(3), names=('y',)); (y,) = L._first_ngens(1)# needs sage.rings.function_field
>>> v = K.valuation(Integer(1)/x)
>>> w = v.extension(L)                                                    # needs sage.rings.function_field
>>> Integer(3)*w                                                                   # needs sage.rings.function_field
3 * (x)-adic valuation (in Rational function field in x over Finite Field of size 2 after x |--> 1/x)
class sage.rings.function_field.valuation.FunctionFieldValuationFactory[source]#

Bases: UniqueFactory

Create a valuation on domain corresponding to prime.

INPUT:

  • domain – a function field

  • prime – a place of the function field, a valuation on a subring, or a valuation on another function field together with information for isomorphisms to and from that function field

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: v = K.valuation(1); v  # indirect doctest
(x - 1)-adic valuation
sage: v(x)
0
sage: v(x - 1)
1
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> v = K.valuation(Integer(1)); v  # indirect doctest
(x - 1)-adic valuation
>>> v(x)
0
>>> v(x - Integer(1))
1

See sage.rings.function_field.function_field.FunctionField.valuation() for further examples.

create_key_and_extra_args(domain, prime)[source]#

Create a unique key which identifies the valuation given by prime on domain.

create_key_and_extra_args_from_place(domain, generator)[source]#

Create a unique key which identifies the valuation at the place specified by generator.

create_key_and_extra_args_from_valuation(domain, valuation)[source]#

Create a unique key which identifies the valuation which extends valuation.

create_key_and_extra_args_from_valuation_on_isomorphic_field(domain, valuation, to_valuation_domain, from_valuation_domain)[source]#

Create a unique key which identifies the valuation which is valuation after mapping through to_valuation_domain.

create_object(version, key, **extra_args)[source]#

Create the valuation specified by key.

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: R.<x> = QQ[]
sage: w = valuations.GaussValuation(R, QQ.valuation(2))
sage: v = K.valuation(w); v  # indirect doctest
2-adic valuation
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> R = QQ['x']; (x,) = R._first_ngens(1)
>>> w = valuations.GaussValuation(R, QQ.valuation(Integer(2)))
>>> v = K.valuation(w); v  # indirect doctest
2-adic valuation
class sage.rings.function_field.valuation.FunctionFieldValuation_base(parent)[source]#

Bases: DiscretePseudoValuation

Abstract base class for any discrete (pseudo-)valuation on a function field.

class sage.rings.function_field.valuation.InducedRationalFunctionFieldValuation_base(parent, base_valuation)[source]#

Bases: FunctionFieldValuation_base

Base class for function field valuation induced by a valuation on the underlying polynomial ring.

extensions(L)[source]#

Return all extensions of this valuation to L which has a larger constant field than the domain of this valuation.

EXAMPLES:

sage: # needs sage.rings.number_field
sage: K.<x> = FunctionField(QQ)
sage: v = K.valuation(x^2 + 1)
sage: L.<x> = FunctionField(GaussianIntegers().fraction_field())
sage: v.extensions(L)  # indirect doctest
[(x - I)-adic valuation, (x + I)-adic valuation]
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> v = K.valuation(x**Integer(2) + Integer(1))
>>> L = FunctionField(GaussianIntegers().fraction_field(), names=('x',)); (x,) = L._first_ngens(1)
>>> v.extensions(L)  # indirect doctest
[(x - I)-adic valuation, (x + I)-adic valuation]
lift(F)[source]#

Return a lift of F to the domain of this valuation such that reduce() returns the original element.

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: v = K.valuation(x)
sage: v.lift(0)
0
sage: v.lift(1)
1
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> v = K.valuation(x)
>>> v.lift(Integer(0))
0
>>> v.lift(Integer(1))
1
reduce(f)[source]#

Return the reduction of f in residue_ring().

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: v = K.valuation(x^2 + 1)
sage: v.reduce(x)                                                           # needs sage.rings.number_field
u1
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> v = K.valuation(x**Integer(2) + Integer(1))
>>> v.reduce(x)                                                           # needs sage.rings.number_field
u1
residue_ring()[source]#

Return the residue field of this valuation.

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: K.valuation(x).residue_ring()
Rational Field
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> K.valuation(x).residue_ring()
Rational Field
restriction(ring)[source]#

Return the restriction of this valuation to ring.

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: K.valuation(x).restriction(QQ)
Trivial valuation on Rational Field
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> K.valuation(x).restriction(QQ)
Trivial valuation on Rational Field
simplify(f, error=None, force=False)[source]#

Return a simplified version of f.

Produce an element which differs from f by an element of valuation strictly greater than the valuation of f (or strictly greater than error if set.)

If force is not set, then expensive simplifications may be avoided.

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: v = K.valuation(2)
sage: f = (x + 1)/(x - 1)
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> v = K.valuation(Integer(2))
>>> f = (x + Integer(1))/(x - Integer(1))

As the coefficients of this fraction are small, we do not simplify as this could be very costly in some cases:

sage: v.simplify(f)
(x + 1)/(x - 1)
>>> from sage.all import *
>>> v.simplify(f)
(x + 1)/(x - 1)

However, simplification can be forced:

sage: v.simplify(f, force=True)
3
>>> from sage.all import *
>>> v.simplify(f, force=True)
3
uniformizer()[source]#

Return a uniformizing element for this valuation.

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: K.valuation(x).uniformizer()
x
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> K.valuation(x).uniformizer()
x
value_group()[source]#

Return the value group of this valuation.

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: K.valuation(x).value_group()
Additive Abelian Group generated by 1
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> K.valuation(x).value_group()
Additive Abelian Group generated by 1
class sage.rings.function_field.valuation.InfiniteRationalFunctionFieldValuation(parent)[source]#

Bases: FunctionFieldMappedValuationRelative_base, RationalFunctionFieldValuation_base, ClassicalFunctionFieldValuation_base

Valuation of the infinite place of a function field.

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: v = K.valuation(1/x)  # indirect doctest
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> v = K.valuation(Integer(1)/x)  # indirect doctest
class sage.rings.function_field.valuation.NonClassicalRationalFunctionFieldValuation(parent, base_valuation)[source]#

Bases: InducedRationalFunctionFieldValuation_base, RationalFunctionFieldValuation_base

Valuation induced by a valuation on the underlying polynomial ring which is non-classical.

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: v = GaussValuation(QQ['x'], QQ.valuation(2))
sage: w = K.valuation(v); w  # indirect doctest
2-adic valuation
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> v = GaussValuation(QQ['x'], QQ.valuation(Integer(2)))
>>> w = K.valuation(v); w  # indirect doctest
2-adic valuation
residue_ring()[source]#

Return the residue field of this valuation.

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: v = valuations.GaussValuation(QQ['x'], QQ.valuation(2))
sage: w = K.valuation(v)
sage: w.residue_ring()
Rational function field in x over Finite Field of size 2

sage: R.<x> = QQ[]
sage: vv = v.augmentation(x, 1)
sage: w = K.valuation(vv)
sage: w.residue_ring()
Rational function field in x over Finite Field of size 2

sage: R.<y> = K[]
sage: L.<y> = K.extension(y^2 + 2*x)                                        # needs sage.rings.function_field
sage: w.extension(L).residue_ring()                                         # needs sage.rings.function_field
Function field in u2 defined by u2^2 + x
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> v = valuations.GaussValuation(QQ['x'], QQ.valuation(Integer(2)))
>>> w = K.valuation(v)
>>> w.residue_ring()
Rational function field in x over Finite Field of size 2

>>> R = QQ['x']; (x,) = R._first_ngens(1)
>>> vv = v.augmentation(x, Integer(1))
>>> w = K.valuation(vv)
>>> w.residue_ring()
Rational function field in x over Finite Field of size 2

>>> R = K['y']; (y,) = R._first_ngens(1)
>>> L = K.extension(y**Integer(2) + Integer(2)*x, names=('y',)); (y,) = L._first_ngens(1)# needs sage.rings.function_field
>>> w.extension(L).residue_ring()                                         # needs sage.rings.function_field
Function field in u2 defined by u2^2 + x
class sage.rings.function_field.valuation.RationalFunctionFieldMappedValuation(parent, base_valuation, to_base_valuation_doain, from_base_valuation_domain)[source]#

Bases: FunctionFieldMappedValuationRelative_base, RationalFunctionFieldValuation_base

Valuation on a rational function field that is implemented after a map to an isomorphic rational function field.

EXAMPLES:

sage: K.<x> = FunctionField(QQ)
sage: R.<x> = QQ[]
sage: w = GaussValuation(R, QQ.valuation(2)).augmentation(x, 1)
sage: w = K.valuation(w)
sage: v = K.valuation((w, K.hom([~K.gen()]), K.hom([~K.gen()]))); v
Valuation on rational function field induced by
[ Gauss valuation induced by 2-adic valuation, v(x) = 1 ]
(in Rational function field in x over Rational Field after x |--> 1/x)
>>> from sage.all import *
>>> K = FunctionField(QQ, names=('x',)); (x,) = K._first_ngens(1)
>>> R = QQ['x']; (x,) = R._first_ngens(1)
>>> w = GaussValuation(R, QQ.valuation(Integer(2))).augmentation(x, Integer(1))
>>> w = K.valuation(w)
>>> v = K.valuation((w, K.hom([~K.gen()]), K.hom([~K.gen()]))); v
Valuation on rational function field induced by
[ Gauss valuation induced by 2-adic valuation, v(x) = 1 ]
(in Rational function field in x over Rational Field after x |--> 1/x)
class sage.rings.function_field.valuation.RationalFunctionFieldValuation_base(parent)[source]#

Bases: FunctionFieldValuation_base

Base class for valuations on rational function fields.

element_with_valuation(s)[source]#

Return an element with valuation s.

EXAMPLES:

sage: # needs sage.rings.number_field
sage: x = polygen(ZZ, 'x')
sage: K.<a> = NumberField(x^3 + 6)
sage: v = K.valuation(2)
sage: R.<x> = K[]
sage: w = GaussValuation(R, v).augmentation(x, 1/123)
sage: K.<x> = FunctionField(K)
sage: w = w.extension(K)
sage: w.element_with_valuation(122/123)
2/x
sage: w.element_with_valuation(1)
2
>>> from sage.all import *
>>> # needs sage.rings.number_field
>>> x = polygen(ZZ, 'x')
>>> K = NumberField(x**Integer(3) + Integer(6), names=('a',)); (a,) = K._first_ngens(1)
>>> v = K.valuation(Integer(2))
>>> R = K['x']; (x,) = R._first_ngens(1)
>>> w = GaussValuation(R, v).augmentation(x, Integer(1)/Integer(123))
>>> K = FunctionField(K, names=('x',)); (x,) = K._first_ngens(1)
>>> w = w.extension(K)
>>> w.element_with_valuation(Integer(122)/Integer(123))
2/x
>>> w.element_with_valuation(Integer(1))
2