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. = PolynomialRing(QQ)
sage: w = x + 5
sage: v = w - x
w(1.0)
6.00
sage: v(1.0)
5.0
I recently sumbled at following behaviour:
sage: P. = 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 consta
Hi All,
Can anyone think why my binary install (Sage4.5.2 on Ubuntu10.04)
should start intermittently having a coercion problem "rank =
int(rank) in free_module.py" when I haven't tried to install anything
else in Sage's python or modify Sage itself.
eg. I had:
V = VectorSpace(RR, 2)
v = V([3.0,
Hi all,
Is the following missing coercion known? I couldn't find anything on
trac, but there's a lot there related to coercion, so I may have missed it.
sage: a = float(1.0)
sage: QQ(a)
TypeError: Unable to coerce 1.0 () to Rational
Note that the following works:
Hi:
Possibly this is a problem with coercion but I don't know.
Does anyone know why the following takes so long?
sage: p = 5
sage: F = GF(p)
sage: E. = GF(p^2,"a")
sage: G = GL(2,p)
sage: M = MatrixSpace(E,2,2)
sage: V = VectorSpace(E,2)
sage: g = G.random_element()
sage: v = V([1,a]); v; g; M(