23
23
import math
24
24
25
25
from sage .misc .lazy_import import lazy_import
26
- from sage .misc .superseded import deprecation
27
26
28
27
lazy_import ('sage.rings.complex_double' , 'CDF' )
29
28
lazy_import ('sage.rings.real_double' , ['RDF' , 'RealDoubleElement' ])
@@ -589,11 +588,10 @@ def symbolic_sum(expression, *args, **kwds):
589
588
"""
590
589
if hasattr (expression , 'sum' ):
591
590
return expression .sum (* args , ** kwds )
592
- elif max (len (args ),len (kwds )) <= 1 :
591
+ if max (len (args ), len (kwds )) <= 1 :
593
592
return sum (expression , * args , ** kwds )
594
- else :
595
- from sage .symbolic .ring import SR
596
- return SR (expression ).sum (* args , ** kwds )
593
+ from sage .symbolic .ring import SR
594
+ return SR (expression ).sum (* args , ** kwds )
597
595
598
596
599
597
def symbolic_prod (expression , * args , ** kwds ):
@@ -848,22 +846,6 @@ def xinterval(a, b):
848
846
return range (a , b + 1 )
849
847
850
848
851
- def is_commutative (x ):
852
- """
853
- Return whether or not ``x`` is commutative.
854
-
855
- EXAMPLES::
856
-
857
- sage: R = PolynomialRing(QQ, 'x')
858
- sage: is_commutative(R)
859
- doctest:...DeprecationWarning: use X.is_commutative() or X in Rings().Commutative()
860
- See https://github.com/sagemath/sage/issues/32347 for details.
861
- True
862
- """
863
- deprecation (32347 , "use X.is_commutative() or X in Rings().Commutative()" )
864
- return x .is_commutative ()
865
-
866
-
867
849
def is_even (x ):
868
850
"""
869
851
Return whether or not an integer ``x`` is even, e.g., divisible by 2.
@@ -883,45 +865,6 @@ def is_even(x):
883
865
return x % 2 == 0
884
866
885
867
886
- def is_integrally_closed (x ):
887
- """
888
- Return whether ``x`` is integrally closed.
889
-
890
- EXAMPLES::
891
-
892
- sage: is_integrally_closed(QQ)
893
- doctest:...DeprecationWarning: use X.is_integrally_closed()
894
- See https://github.com/sagemath/sage/issues/32347 for details.
895
- True
896
- sage: x = polygen(ZZ, 'x')
897
- sage: K.<a> = NumberField(x^2 + 189*x + 394) # needs sage.rings.number_field
898
- sage: R = K.order(2*a) # needs sage.rings.number_field
899
- sage: is_integrally_closed(R) # needs sage.rings.number_field
900
- False
901
- """
902
- deprecation (32347 , "use X.is_integrally_closed()" )
903
- return x .is_integrally_closed ()
904
-
905
-
906
- def is_field (x , proof = True ):
907
- """
908
- Return whether or not ``x`` is a field.
909
-
910
- Alternatively, one can use ``x in Fields()``.
911
-
912
- EXAMPLES::
913
-
914
- sage: R = PolynomialRing(QQ, 'x')
915
- sage: F = FractionField(R)
916
- sage: is_field(F)
917
- doctest:...DeprecationWarning: use X.is_field() or X in Fields()
918
- See https://github.com/sagemath/sage/issues/32347 for details.
919
- True
920
- """
921
- deprecation (32347 , "use X.is_field() or X in Fields()" )
922
- return x .is_field (proof = proof )
923
-
924
-
925
868
def is_odd (x ):
926
869
"""
927
870
Return whether or not ``x`` is odd.
0 commit comments