Changeset 7492:22c24fe79fcf
- Timestamp:
- 12/01/07 22:11:13 (5 years ago)
- Branch:
- default
- Location:
- sage
- Files:
-
- 5 edited
-
categories/pushout.py (modified) (2 diffs)
-
rings/complex_double.pyx (modified) (2 diffs)
-
rings/complex_field.py (modified) (2 diffs)
-
rings/real_double.pyx (modified) (1 diff)
-
rings/real_mpfr.pyx (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
sage/categories/pushout.py
r6689 r7492 40 40 return False 41 41 42 class Composit ConstructionFunctor(ConstructionFunctor):42 class CompositeConstructionFunctor(ConstructionFunctor): 43 43 def __init__(self, first, second): 44 44 Functor.__init__(self, first.domain(), second.codomain()) … … 254 254 c = cmp(self.poly, other.poly) 255 255 return c 256 257 class AlgebraicClosureFunctor(ConstructionFunctor): 258 def __init__(self): 259 Functor.__init__(self, Rings(), Rings()) 260 self.rank = 3 261 def __call__(self, R): 262 return R.algebraic_closure() 263 def merge(self, other): 264 # Algebraic Closure subsumes Algebraic Extension 265 return self 256 266 257 267 def BlackBoxConstructionFunctor(ConstructionFunctor): -
sage/rings/complex_double.pyx
r7435 r7492 277 277 sage: parent(a) 278 278 Symbolic Ring 279 280 sage: CDF(1) + RR(1) 281 2.0 279 282 """ 280 283 return self._coerce_try(x, [self.real_double_field(), … … 339 342 """ 340 343 return self(3.1415926535897932384626433832) 341 344 345 def construction(self): 346 """ 347 Returns the functorial construction of self, namely, 348 algebraic closure of the real double field. 349 350 EXAMPLES: 351 sage: c, S = CDF.construction(); S 352 Real Double Field 353 sage: CDF == c(S) 354 True 355 """ 356 from sage.categories.pushout import AlgebraicClosureFunctor 357 return (AlgebraicClosureFunctor(), self.real_double_field()) 342 358 343 359 def new_ComplexDoubleElement(): -
sage/rings/complex_field.py
r7428 r7492 213 213 * this MPFR complex field, or any other of higher precision 214 214 * anything that canonically coerces to the mpfr real field with this prec 215 216 EXAMPLES: 217 sage: ComplexField(200)(1) + RealField(90)(1) 218 2.0000000000000000000000000 215 219 """ 216 220 try: … … 258 262 """ 259 263 return False 264 265 def construction(self): 266 """ 267 Returns the functorial construction of self, namely, 268 algebraic closure of the real field with the same precision. 269 270 EXAMPLES: 271 sage: c, S = CC.construction(); S 272 Real Field with 53 bits of precision 273 sage: CC == c(S) 274 True 275 """ 276 from sage.categories.pushout import AlgebraicClosureFunctor 277 return (AlgebraicClosureFunctor(), self._real_field()) 278 260 279 261 280 def pi(self): -
sage/rings/real_double.pyx
r7319 r7492 145 145 {'type': 'RDF'}), 146 146 sage.rings.rational_field.QQ) 147 148 def algebraic_closure(self): 149 """ 150 Returns the algebraic closure of self, 151 ie, the complex double field. 152 153 EXAMPLES: 154 sage: RDF.algebraic_closure() 155 Complex Double Field 156 """ 157 from sage.rings.complex_double import CDF 158 return CDF 147 159 148 160 cdef coerce_map_from_c(self, S): -
sage/rings/real_mpfr.pyx
r7471 r7492 348 348 """ 349 349 return sage.rings.complex_field.ComplexField(self.prec()) 350 351 def algebraic_closure(self): 352 """ 353 Returns the algebraic closure of self, ie the 354 complex field with the same precision. 355 """ 356 return self.complex_field() 350 357 351 358 def ngens(self):
Note: See TracChangeset
for help on using the changeset viewer.
