Skip to content

Commit df032fb

Browse files
committed
Make hypot depend on the current power mode
1 parent 4550d7d commit df032fb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/intervals/arithmetic/power.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -288,9 +288,9 @@ Compute the hypotenuse.
288288
289289
Implement the `hypot` function of the IEEE Standard 1788-2015 (Table 10.5).
290290
"""
291-
Base.hypot(x::BareInterval, y::BareInterval) = sqrt(pown(x, 2) + pown(y, 2))
291+
Base.hypot(x::BareInterval, y::BareInterval) = sqrt(_select_pown(power_mode(), x, 2) + _select_pown(power_mode(), y, 2))
292292

293-
Base.hypot(x::Interval, y::Interval) = sqrt(pown(x, 2) + pown(y, 2))
293+
Base.hypot(x::Interval, y::Interval) = sqrt(_select_pown(power_mode(), x, 2) + _select_pown(power_mode(), y, 2))
294294

295295
"""
296296
fastpow(x, y)

0 commit comments

Comments
 (0)