Skip to content

Commit

Permalink
Update src/intervals/functions.jl
Browse files Browse the repository at this point in the history
Co-authored-by: lucaferranti <[email protected]>
  • Loading branch information
petvana and lucaferranti authored May 24, 2022
1 parent 153d749 commit d23df89
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/intervals/functions.jl
Original file line number Diff line number Diff line change
Expand Up @@ -381,5 +381,5 @@ function mod(x::Interval, y::Real)
@assert y > 0 "modulo is currently implemented only for a positive divisor."
division = x / y
fl = floor(division)
fl.lo < fl.hi ? 0..y : y * (division - fl)
fl.lo < fl.hi ? Interval(zero(y), y) : y * (division - fl)
end

0 comments on commit d23df89

Please sign in to comment.