Opened 8 years ago
Closed 8 years ago
#13634 closed defect (fixed)
Fix to output of scientific notation for real interval field
Reported by: | tscrim | Owned by: | tscrim |
---|---|---|---|
Priority: | major | Milestone: | sage-5.5 |
Component: | misc | Keywords: | real interval field |
Cc: | Merged in: | sage-5.5.beta1 | |
Authors: | Travis Scrimshaw | Reviewers: | Robert Bradshaw |
Report Upstream: | N/A | Work issues: | |
Branch: | Commit: | ||
Dependencies: | Stopgaps: |
Description (last modified by )
Currently if you set scientific notation for the real interval field, it does not print in scientific notation.
sage: RIF.scientific_notation(True) sage: RIF(0.025) 0.025000000000000002? sage: RIF.scientific_notation() True sage: RIF(0.025) 0.025000000000000002? sage: RIF(0.025).str(no_sci=False) '2.5000000000000002?e-2'
This is caused by not checking when no_sci
option is None
(and then checking the parent). After patch:
sage: RIF(0.025) 0.025000000000000002? sage: RIF.scientific_notation(True) sage: RIF(0.025) 2.5000000000000002?e-2
Attachments (1)
Change History (8)
comment:1 Changed 8 years ago by
- Status changed from new to needs_review
comment:2 Changed 8 years ago by
- Description modified (diff)
comment:3 Changed 8 years ago by
Minor nit: I'd prefere "not no_sci" to "no_sci == False" in case the user passes a value like 0
. But other than that, looks good (including the nice docstring cleanups).
comment:4 Changed 8 years ago by
- Reviewers set to Robert Bradshaw
Changed 8 years ago by
comment:5 Changed 8 years ago by
Changed. Thank you.
comment:6 Changed 8 years ago by
- Status changed from needs_review to positive_review
comment:7 Changed 8 years ago by
- Merged in set to sage-5.5.beta1
- Resolution set to fixed
- Status changed from positive_review to closed
Note: See
TracTickets for help on using
tickets.
Please review.