Opened 12 months ago
Closed 8 months ago
#30786 closed defect (fixed)
Multiplying and dividing by 3 hangs
Reported by:  ghGMS103  Owned by:  

Priority:  minor  Milestone:  sage9.3 
Component:  symbolics  Keywords:  
Cc:  Merged in:  
Authors:  Dave Morris  Reviewers:  Travis Scrimshaw, Dima Pasechnik 
Report Upstream:  N/A  Work issues:  
Branch:  6ee3113 (Commits, GitHub, GitLab)  Commit:  6ee3113a288a36519ed1a4b0adbd19250404874b 
Dependencies:  #30446  Stopgaps: 
Description
Tested with https://sagecell.sagemath.org
sage: version() 'SageMath version 9.1, Release Date: 20200520'
All of these work as expected:
sage: exp(ln(x)) sage: exp(3*ln(x)/3) sage: exp(ln(9*x))
However this hangs:
sage: exp(3*ln(9*x)/3)
In case you are curious, this is what I was doing (the expressions were a bit more complex, of course):
sage: a=var('a') sage: y=exp(3*x) sage: x0=ln(9*a)/3 sage: y(x=x0)
Change History (12)
comment:1 Changed 12 months ago by
comment:2 Changed 12 months ago by
DaveWitteMorris is correct. I checked and this is the same issue as #30446. If you look on that ticket, I submitted a pull request with pynac
that will fix the issue.
comment:3 Changed 12 months ago by
Thanks for the feedback, I was really surprised by this bug. Glad to know it will be fixed.
comment:4 Changed 10 months ago by
 Component changed from basic arithmetic to symbolics
 Dependencies set to #30446
 Milestone changed from sage9.1.1 to sage9.4
 Priority changed from major to minor
comment:5 Changed 10 months ago by
 Branch set to public/30786
comment:6 Changed 10 months ago by
 Commit set to 4a5d0536a91fd3ef538c3430e3b668c75272225d
 Milestone changed from sage9.4 to sage9.3
 Status changed from new to needs_review
The PR adds doctests for the bugs on this ticket, #28620, and #30304. All were fixed by the patch to pynac at #30446 (which has positive review). These doctests are in the _pow_
method, and I moved the doctest of #30446 to the same place. (It was in the _latex_
method, which does not seem like such a good place.)
New commits:
dc073df  fixes for trac #30446

4a5d053  doctests for trac 28620, 30304, 30786

comment:7 Changed 10 months ago by
 Reviewers set to Travis Scrimshaw
 Status changed from needs_review to positive_review
LGTM.
comment:8 Changed 10 months ago by
Thanks!
comment:9 Changed 9 months ago by
 Status changed from positive_review to needs_work
rebase over new #30446
comment:10 Changed 9 months ago by
 Commit changed from 4a5d0536a91fd3ef538c3430e3b668c75272225d to 6ee3113a288a36519ed1a4b0adbd19250404874b
Branch pushed to git repo; I updated commit sha1. This was a forced push. New commits:
9d747fc  sage package updatelatest: Distinguish pypi package name and spkg name

f74f66c  sage package updatelatest: Accept package classes :standard:, :optional: etc., restrict to normal Python packages

182b3d2  sage package fixchecksum: Handle package classes, ignore nonnormal packages

9a57cf6  pynac update

563940e  doctest from #30446

51def3c  sane version name

4834dc8  remove upstreamed patch

214712d  tarball update

6ee3113  doctests for trac 28620, 30304, 30786

comment:11 Changed 9 months ago by
 Reviewers changed from Travis Scrimshaw to Travis Scrimshaw, Dima Pasechnik
 Status changed from needs_work to positive_review
OK, done
comment:12 Changed 8 months ago by
 Branch changed from public/30786 to 6ee3113a288a36519ed1a4b0adbd19250404874b
 Resolution set to fixed
 Status changed from positive_review to closed
I confirm that there is a problem.
CoCalc
ran out of memory. My laptop (9.2rc2 on MacOS 10.15.7) completed eventually (I think it took about half an hour). The output is a 4GB string of nonsense that seems to be almost entirely digits, but starts with1/34723950083
and ends with91987451449/x
.These symptoms are somewhat similar to #30446.