From 6259014a4234a4d89abe228028d9c4610ee91b42 Mon Sep 17 00:00:00 2001 From: Dave Witte Morris Date: Thu, 26 Mar 2020 16:20:31 -0600 Subject: [PATCH] deprecate cotan --- src/sage/rings/complex_mpc.pyx | 6 +++--- src/sage/rings/complex_number.pyx | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/sage/rings/complex_mpc.pyx b/src/sage/rings/complex_mpc.pyx index 991eced6721..fa002160baa 100644 --- a/src/sage/rings/complex_mpc.pyx +++ b/src/sage/rings/complex_mpc.pyx @@ -83,6 +83,8 @@ from .real_mpfr import mpfr_prec_min, mpfr_prec_max from sage.structure.richcmp cimport rich_to_bool, richcmp from sage.categories.fields import Fields +from sage.misc.superseded import deprecated_function_alias + cimport gmpy2 gmpy2.import_gmpy2() @@ -1985,8 +1987,6 @@ cdef class MPComplexNumber(sage.structure.element.FieldElement): sage: MPC = MPComplexField(53) sage: (1+MPC(I)).cot() 0.217621561854403 - 0.868014142895925*I - sage: (1+MPC(I)).cotan() - 0.217621561854403 - 0.868014142895925*I sage: i = MPComplexField(200).0 sage: (1+i).cot() 0.21762156185440268136513424360523807352075436916785404091068 - 0.86801414289592494863584920891627388827343874994609327121115*I @@ -1996,7 +1996,7 @@ cdef class MPComplexNumber(sage.structure.element.FieldElement): """ return ~(self.tan()) - cotan = cot # provide this alias for backwards compatibility (2020-3-25) + cotan = deprecated_function_alias(29412, cot) ################################ # Other functions diff --git a/src/sage/rings/complex_number.pyx b/src/sage/rings/complex_number.pyx index c6b6ff241ad..cb657193885 100644 --- a/src/sage/rings/complex_number.pyx +++ b/src/sage/rings/complex_number.pyx @@ -43,6 +43,8 @@ import sage.rings.infinity as infinity from sage.libs.mpmath.utils cimport mpfr_to_mpfval from sage.rings.integer_ring import ZZ +from sage.misc.superseded import deprecated_function_alias + cimport gmpy2 gmpy2.import_gmpy2() @@ -1461,8 +1463,6 @@ cdef class ComplexNumber(sage.structure.element.FieldElement): sage: (1+CC(I)).cot() 0.217621561854403 - 0.868014142895925*I - sage: (1+CC(I)).cotan() - 0.217621561854403 - 0.868014142895925*I sage: i = ComplexField(200).0 sage: (1+i).cot() 0.21762156185440268136513424360523807352075436916785404091068 - 0.86801414289592494863584920891627388827343874994609327121115*I @@ -1479,7 +1479,7 @@ cdef class ComplexNumber(sage.structure.element.FieldElement): """ return ~(self.tan()) - cotan = cot # provide this alias for backwards compatibility (2020-3-25) + cotan = deprecated_function_alias(29412, cot) def cos(self): """