|
2024-02-15
| ||
| 20:33 | Fix [578b7e273c03]: Round computed end value to match precision of given arguments check-in: d99d025a45 user: jan.nijtmans tags: core-8-branch | |
| 16:30 | • Closed ticket [578b7e273c]: Arithmetic Series Objects get wrong precision in som... artifact: b3446db221 user: griffin | |
|
2024-02-14
| ||
| 02:00 | • Ticket [578b7e273c]: 4 changes artifact: 041be3d7e6 user: griffin | |
|
2024-02-12
| ||
| 18:22 | • New ticket [578b7e273c]. artifact: 27edee8f62 user: dkf | |
Arithmetic Series Objects get wrong precision in some cases
Closed / Fixed578b7e273c03c913a82de4d314f30c883a19615fCreated 3 years agoUpdated 3 years ago
Descriptionmarkdown2024-02-12 18:22:01
I would expect that if the first command below finds the element, the second would also do so. Apparently not.
% expr {2.8 in [lseq 0 count 100 by .1]}
1
% expr {2.8 in [lseq 0 count 200 by .1]}
0
The problem appears to be that cumulative error in the projected forward end value (in turn used to compute the number of values, which we provide) is resulting in the precision being estimated to be 15 instead of 1. Probably ought to have an alternate way of building ArithSeries objects that takes start/count/step instead of start/end/step to avoid the systematic error...
griffinmarkdown2024-02-14 02:00:24
Oops. The intent is to define the precision solely on the provided arguments only, as you've alluded to.
Thanks for reporting this!
griffinplain2024-02-15 16:30:59
Fixed with 855a2f171c
Log in (anonymous is fine) to add a comment.