Coercion problem

20 views
Skip to first unread message

micha...@gmail.com

unread,
Jan 15, 2015, 2:49:03 PM1/15/15
to sage-s...@googlegroups.com
I recently sumbled at following behaviour:
sage: P.<x> = PolynomialRing(QQ)
sage: w = x + 1
sage: w(oo)
+ Infinity
sage: v = 5
sage: v(oo)
A positive finite number

This behaviour is strange (altough works as desined). For nonconstant polynomial it has the same effect as calculating limit, for constant polynomial it gives (seemingly) non-sensical result. Could the default behaviour be changed so in case of constant polynomial instead of coercing operands it would return simply the value of the polynomial (5 in this example)?

Regards,
MG

Robert Bradshaw

unread,
Jan 16, 2015, 1:10:48 AM1/16/15
to sage-s...@googlegroups.com
I assume you meant

sage: v = P(5)
sage: v(oo)
A positive finite number

This is because the elements of QQ coerce to the parent of oo, which
is the "signed infinity ring." This is so we have

sage: P.<x> = PolynomialRing(QQ)
sage: w = x + 5
sage: v = w - x
w(1.0)
6.00000000000000
sage: v(1.0)
5.00000000000000
sage: parent(w(1.0)) is parent(v(1.0))
True

I suppose now that we have pushouts we could let the result lie in the
(affine) extension of the rationals. Manipulation with the unsigned
infinity would yield the projective extension. There is the open
question of what the parent of oo should be though. Some kind of
affine extension of ZZ?
> --
> You received this message because you are subscribed to the Google Groups
> "sage-support" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to sage-support...@googlegroups.com.
> To post to this group, send email to sage-s...@googlegroups.com.
> Visit this group at http://groups.google.com/group/sage-support.
> For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages