Opened 3 years ago
Last modified 2 months ago
#28912 new defect
Function math.log10 fails on large Sage integers while ok on Python ints
Reported by: | İsmail Dönmez | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | sage-9.8 |
Component: | numerical | Keywords: | |
Cc: | Samuel Lelièvre | Merged in: | |
Authors: | Reviewers: | ||
Report Upstream: | N/A | Work issues: | |
Branch: | Commit: | ||
Dependencies: | Stopgaps: |
Description (last modified by )
Change History (12)
comment:1 Changed 3 years ago by
Cc: | Samuel Lelièvre added |
---|---|
Component: | packages: standard → numerical |
comment:2 Changed 3 years ago by
Summary: | sage.rings.integer.Integer is problematic → Function math.log10 fails on large Sage integers while ok on Python ints |
---|
More descriptive ticket title.
comment:3 Changed 3 years ago by
More of the same problem:
sage: math.log2(a) inf sage: math.log(a) inf sage: math.isinf(a) True
comment:4 Changed 3 years ago by
Milestone: | sage-9.0 → sage-9.1 |
---|
Ticket retargeted after milestone closed
comment:5 Changed 3 years ago by
Milestone: | sage-9.1 → sage-9.2 |
---|
Moving tickets to milestone sage-9.2 based on a review of last modification date, branch status, and severity.
comment:6 Changed 2 years ago by
Milestone: | sage-9.2 → sage-9.3 |
---|
comment:7 Changed 20 months ago by
Description: | modified (diff) |
---|
comment:8 Changed 19 months ago by
Milestone: | sage-9.3 → sage-9.4 |
---|
Moving to 9.4, as 9.3 has been released.
comment:9 Changed 16 months ago by
Milestone: | sage-9.4 → sage-9.5 |
---|
comment:10 Changed 12 months ago by
Milestone: | sage-9.5 → sage-9.6 |
---|
comment:11 Changed 7 months ago by
Milestone: | sage-9.6 → sage-9.7 |
---|
comment:12 Changed 2 months ago by
Milestone: | sage-9.7 → sage-9.8 |
---|
Note: See
TracTickets for help on using
tickets.
Confirmed in Sage 9.0.beta10.
Smallest Sage integers where this fails:
Import
log10
from themath
module:Computing
log10(aa)
works, but notlog10(a)
:No problem with
a - 1
as a Sage integer:Workaround:
Note that Sage has a built-in method for the "number of digits" of an integer (a common reason for taking the base ten logarithm):