Opened 8 years ago
Closed 7 years ago
#14320 closed enhancement (fixed)
More doctests from the book "Calcul mathématique avec Sage"
Reported by: | tdumont | Owned by: | mvngu |
---|---|---|---|
Priority: | minor | Milestone: | sage-5.13 |
Component: | doctest coverage | Keywords: | french book |
Cc: | Merged in: | sage-5.13.beta3 | |
Authors: | Thierry Dumont, Paul Zimmermann | Reviewers: | Frédéric Chapoton |
Report Upstream: | Completely fixed; Fix reported upstream | Work issues: | |
Branch: | Commit: | ||
Dependencies: | Stopgaps: |
Description (last modified by )
The attached file provides doctests for examples in the chapter "float" (floating point numbers). Tests pass with 5.11.
Apply only trac_14320_doctests_from_french_book.patch.
Attachments (2)
Change History (14)
Changed 8 years ago by
comment:1 Changed 8 years ago by
- Milestone changed from sage-5.11 to sage-5.12
comment:2 Changed 8 years ago by
- Description modified (diff)
- Status changed from new to needs_review
- Type changed from task to enhancement
I've attached a well-formed patch. I had to modify two things with respect to the book (which was with Sage 5.9), due to some recent changes in RDF:
- I added "abs tol 0.05" somewhere to avoid a failing test with 5.11
exact-sommation compensee
now gives 0.0 with 5.11 (instead of -0.001953125 with 5.9). I thus changed to 0.0 in the doctest. This will thus differ from the book, which should be updated to 5.11 (adding "abs tol" is not enough).
Paul
comment:3 Changed 8 years ago by
- Status changed from needs_review to needs_work
same remark about indentation: should be 4 spaces rather than 2
comment:4 Changed 8 years ago by
- Status changed from needs_work to needs_review
same remark about indentation: should be 4 spaces rather than 2
is it better with the new patch?
Paul
comment:5 Changed 7 years ago by
yes, it is much better that way.
comment:6 Changed 7 years ago by
- Keywords french book added
- Reviewers set to Frédéric Chapoton
- Status changed from needs_review to positive_review
Let me say that it is good to go.
comment:7 Changed 7 years ago by
- Status changed from positive_review to needs_work
On arando
(Linux 32-bit i686):
sage -t --long devel/sage/sage/tests/french_book/float_doctest.py ********************************************************************** File "devel/sage/sage/tests/french_book/float_doctest.py", line 206, in sage.tests.french_book.float_doctest Failed example: print "exact - sommation classique:", s-ii # abs tol 0.05 Expected: exact - sommation classique: -45.5 Got: exact - sommation classique: -45.591796875 Tolerance exceeded: 9e-02 > 5e-02 **********************************************************************
comment:8 Changed 7 years ago by
I will have a look next week, unless someone beats me. However I wonder why the patchbot did not find this before. Did it work before on arando?
Paul
comment:9 Changed 7 years ago by
It seems the patchbot is having trouble itself... Also, I don't know whether we have any patchbots running on 32-bit i686.
Changed 7 years ago by
comment:10 Changed 7 years ago by
- Status changed from needs_work to needs_review
I increased the tolerance to 0.1, it should be ok now.
Paul
comment:11 Changed 7 years ago by
- Description modified (diff)
- Status changed from needs_review to positive_review
Should be good.
comment:12 Changed 7 years ago by
- Merged in set to sage-5.13.beta3
- Resolution set to fixed
- Status changed from positive_review to closed
doctets auto generated.