Thierry wrote: >> parent(A) is parent(B) >> but >> type(A) is not type(B) > > Here is an example: > > sage: A = cos(x) > sage: B = units.charge.coulomb > sage: parent(A) is parent(B) > True > sage: type(A) is not type(B) > True
More examples: sage: parent(-infinity) is parent(infinity) True sage: type(infinity) <class 'sage.rings.infinity.PlusInfinity'> sage: type(-infinity) <class 'sage.rings.infinity.MinusInfinity'> sage: two = RLF(2) sage: type(two) <type 'sage.rings.real_lazy.LazyWrapper'> sage: type(exp(two)) <type 'sage.rings.real_lazy.LazyNamedUnop'> sage: parent(two) is parent(exp(two)) True -- Marc -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.