Opened 8 years ago
Closed 8 years ago
#2746 closed defect (done)
Overflow issues in binomial coefficient calculation
Reported by: | bburlacu | Owned by: | mkommend |
---|---|---|---|
Priority: | medium | Milestone: | HeuristicLab 3.3.15 |
Component: | Common | Version: | 3.3.14 |
Keywords: | Cc: |
Description
The EnumerableExtensions.BinomialCoefficient(n,k) method may silently overflow (for large n and k) returning the wrong results. This method should fail with an exception if the result is outside the long range.
Change History (7)
comment:1 Changed 8 years ago by bburlacu
- Status changed from new to accepted
comment:2 Changed 8 years ago by bburlacu
- Owner changed from bburlacu to mkommend
- Status changed from accepted to reviewing
comment:3 Changed 8 years ago by bburlacu
comment:4 Changed 8 years ago by mkommend
- Status changed from reviewing to readytorelease
comment:5 Changed 8 years ago by mkommend
- Owner changed from mkommend to bburlacu
- Status changed from readytorelease to reviewing
r14769: Made combinations extension methods thread-safe by avoiding lazy evaluation linq queries.
comment:6 Changed 8 years ago by bburlacu
- Owner changed from bburlacu to mkommend
- Status changed from reviewing to readytorelease
The code looks fine to me and I couldn't find any problems.
comment:7 Changed 8 years ago by mkommend
- Resolution set to done
- Status changed from readytorelease to closed
Note: See
TracTickets for help on using
tickets.
r14750: Enable explicit overflow checking in binomial coefficient calculation.