Ticket #6064 (closed enhancement: fixed)
[with patch; with positive review] allow rationals in kronecker_symbol and legendre_symbol
| Reported by: | tornaria | Owned by: | tornaria |
|---|---|---|---|
| Priority: | major | Milestone: | sage-4.0 |
| Component: | number theory | Keywords: | |
| Cc: | Work issues: | ||
| Report Upstream: | Reviewers: | John Cremona | |
| Authors: | Gonzalo Tornaria | Merged in: | 4.0.rc0 |
| Dependencies: | Stopgaps: |
Description
With sage-4.0.alpha0:
sage: kronecker(2/3,7) ... TypeError: no conversion of this rational to integer
Same for kronecker_symbol and legendre_symbol. However, it does make sense for these to be defined on rationals.
This is actually used by is_padic_square when used with rationals, and triggered by some of the new quadratic form doctests.
Attachments
Change History
comment:1 Changed 4 years ago by tornaria
- Summary changed from allow rationals in kronecker_symbol and legendre_symbol to [with patch; needs review] allow rationals in kronecker_symbol and legendre_symbol
Changed 4 years ago by tornaria
-
attachment
trac_6064.patch
added
allow rationals in kronecker_symbol and legendre_symbol
comment:2 Changed 4 years ago by cremona
- Summary changed from [with patch; needs review] allow rationals in kronecker_symbol and legendre_symbol to [with patch; with positive review] allow rationals in kronecker_symbol and legendre_symbol
Joint review with #6062: applied both patches, both are fine and tests pass.
Note: See
TracTickets for help on using
tickets.

Note: this is needed to fix doctests in quadratic forms (#5954, #6037, #6040).