Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

Commit

Permalink
sage.dynamics: Fix up replacement of is_{Real,Complex}[Double]Field
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthias Koeppe committed Oct 2, 2021
1 parent 45cc21a commit e003603
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/sage/dynamics/arithmetic_dynamics/projective_ds.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,8 @@ class initialization directly.
from sage.rings.qqbar import QQbar, number_field_elements_from_algebraics
from sage.rings.quotient_ring import QuotientRing_generic
from sage.rings.rational_field import QQ
from sage.rings.real_double import RDF
from sage.rings.real_mpfr import (RealField, is_RealField)
import sage.rings.abc
from sage.rings.real_mpfr import RealField
from sage.schemes.generic.morphism import SchemeMorphism_polynomial
from sage.schemes.projective.projective_subscheme import AlgebraicScheme_subscheme_projective
from sage.schemes.projective.projective_morphism import (
Expand Down Expand Up @@ -2062,10 +2062,10 @@ def canonical_height(self, P, **kwds):

# Archimedean local heights
# :: WARNING: If places is fed the default Sage precision of 53 bits,
# it uses Real or Complex Double Field in place of RealField(prec) or ComplexField(prec)
# the function is_RealField does not identify RDF as real, so we test for that ourselves.
# it uses Real or Complex Double Field in place of RealField(prec) or ComplexField(prec).
# RDF is an instance of a separate class.
for v in emb:
if isinstance(v.codomain(, sage.rings.abc.RealField)) or v.codomain() is RDF:
if isinstance(v.codomain(), (sage.rings.abc.RealField, sage.rings.abc.RealDoubleField)):
dv = R.one()
else:
dv = R(2)
Expand Down

0 comments on commit e003603

Please sign in to comment.