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

Commit

Permalink
src/sage/rings: Remove remaining imports from sage.rings.all
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthias Koeppe committed Jul 16, 2022
1 parent 6df82e3 commit 3e420f7
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions src/sage/rings/lazy_series.py
Original file line number Diff line number Diff line change
Expand Up @@ -2972,12 +2972,12 @@ def approximate_series(self, prec, name=None):
name = S.variable_name()

if self.valuation() < 0:
from sage.rings.all import LaurentSeriesRing
from sage.rings.laurent_series_ring import LaurentSeriesRing
R = LaurentSeriesRing(S.base_ring(), name=name)
n = self.valuation()
return R([self[i] for i in range(n, prec)], n).add_bigoh(prec)
else:
from sage.rings.all import PowerSeriesRing
from sage.rings.power_series_ring import PowerSeriesRing
R = PowerSeriesRing(S.base_ring(), name=name)
return R([self[i] for i in range(prec)]).add_bigoh(prec)

Expand Down
4 changes: 2 additions & 2 deletions src/sage/rings/polynomial/infinite_polynomial_ring.py
Original file line number Diff line number Diff line change
Expand Up @@ -1337,7 +1337,7 @@ def krull_dimension(self, *args, **kwds):
sage: R.krull_dimension()
+Infinity
"""
from sage.rings.all import Infinity
from sage.rings.infinity import Infinity
return Infinity

def order(self):
Expand All @@ -1351,7 +1351,7 @@ def order(self):
sage: R.order()
+Infinity
"""
from sage.rings.all import Infinity
from sage.rings.infinity import Infinity
return Infinity


Expand Down
2 changes: 1 addition & 1 deletion src/sage/rings/valuation/valuation_space.py
Original file line number Diff line number Diff line change
Expand Up @@ -761,7 +761,7 @@ def separating_element(self, others):
else: # others[i](ret) > 0
# construct an element which approximates a unit with respect to others[i]
# and has negative valuation with respect to others[:i]
from sage.rings.all import NN
from sage.rings.semirings.non_negative_integer_semiring import NN
for r in iter(NN):
# When we enter this loop we are essentially out of
# luck. The size of the coefficients is likely going
Expand Down
4 changes: 2 additions & 2 deletions src/sage/rings/valuation/value_group.py
Original file line number Diff line number Diff line change
Expand Up @@ -471,7 +471,7 @@ def __classcall__(cls, generators):
for h in generators:
if g == h:
continue
from sage.rings.all import NN
from sage.rings.semirings.non_negative_integer_semiring import NN
if h/g in NN:
simplified_generators.remove(h)
break
Expand Down Expand Up @@ -525,7 +525,7 @@ def _solve_linear_program(self, target):
return None

if len(self._generators) == 1:
from sage.rings.all import NN
from sage.rings.semirings.non_negative_integer_semiring import NN
exp = target / self._generators[0]
if exp not in NN:
return None
Expand Down

0 comments on commit 3e420f7

Please sign in to comment.