Avoid division by 0 when there are no contract samples.
This commit is contained in:
parent
a662f72c9e
commit
a9504825ea
|
@ -151,7 +151,7 @@
|
||||||
(define total-contract-time
|
(define total-contract-time
|
||||||
(max 1e-20 (for/sum ([b (in-list all-boundaries)]) (boundary-time b))))
|
(max 1e-20 (for/sum ([b (in-list all-boundaries)]) (boundary-time b))))
|
||||||
(define max-self%
|
(define max-self%
|
||||||
(/ (for/fold ([m 0]) ([b (in-list all-boundaries)])
|
(/ (for/fold ([m 1e-20]) ([b (in-list all-boundaries)])
|
||||||
(max m (boundary-time b)))
|
(max m (boundary-time b)))
|
||||||
total-contract-time))
|
total-contract-time))
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user