#10960: Better product error messages when can't multiply
--------------------------------+-------------------------------------------
Reporter: kcrisman | Owner: AlexGhitza
Type: defect | Status: new
Priority: minor | Milestone:
Component: basic arithmetic | Keywords: multiply, arithmetic, coercion,
incompatible
Author: | Upstream: N/A
Reviewer: | Merged:
Work_issues: |
--------------------------------+-------------------------------------------
See #10683, where the following less-than-helpful message was discovered.
{{{
sage: k.<b> = FiniteField(9); k
Finite Field in b of size 3^2
sage: vector([1,i]).dot_product(vector(k,[1,b]))
---------------------------------------------------------
ArithmeticError:
}}}
Of course you can't multiply elements of the symbolic ring and this finite
field. But if this happened buried deep in some other code, it could take
a long time to track down.
This actually happens when you just multiply as well, unsurprisingly, so
that's where it would have to be caught.
{{{
sage: k.<b> = FiniteField(9)
sage: i*b
<boom>
}}}
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/10960>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.