math.abs on complex

Time bar (total: 3.1s)

start0.0ms (0%)

Memory
0.0MiB live, 0.0MiB allocated; 0ms collecting garbage

analyze0.0ms (0%)

Memory
0.7MiB live, 0.7MiB allocated; 0ms collecting garbage
Algorithm
search
Search
ProbabilityValidUnknownPreconditionInfiniteDomainCan'tIter
0%0%99.9%0.1%0%0%0%0
100%99.9%0%0.1%0%0%0%1
Compiler

Compiled 10 to 5 computations (50% saved)

sample776.0ms (25.1%)

Memory
-2.9MiB live, 1 068.8MiB allocated; 329ms collecting garbage
Samples
451.0ms8 256×0valid
Precisions
Click to see histograms. Total time spent on operations: 203.0ms
ival-hypot: 192.0ms (94.4% of total)
ival-true: 6.0ms (2.9% of total)
ival-assert: 3.0ms (1.5% of total)
adjust: 2.0ms (1% of total)
Bogosity

explain187.0ms (6%)

Memory
-49.2MiB live, 149.0MiB allocated; 56ms collecting garbage
FPErrors
Click to see full error table
Ground TruthOverpredictionsExampleUnderpredictionsExampleSubexpression
1030-0-(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
00-0-(+.f64 (*.f64 re re) (*.f64 im im))
00-0-(*.f64 re re)
00-0-re
00-0-(*.f64 im im)
00-0-im
Explanations
Click to see full explanations table
OperatorSubexpressionExplanationCount
sqrt.f64(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))oflow-rescue950
(+.f64 (*.f64 re re) (*.f64 im im))overflow95
(*.f64 re re)overflow59
(*.f64 im im)overflow54
sqrt.f64(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))uflow-rescue80
(+.f64 (*.f64 re re) (*.f64 im im))underflow8
(*.f64 re re)underflow58
(*.f64 im im)underflow49
Confusion
Predicted +Predicted -
+1030
-0153
Precision
1.0
Recall
1.0
Confusion?
Predicted +Predicted MaybePredicted -
+10300
-00153
Precision?
1.0
Recall?
1.0
Freqs
test
numberfreq
0153
1103
Total Confusion?
Predicted +Predicted MaybePredicted -
+100
-000
Precision?
1.0
Recall?
1.0
Samples
33.0ms512×0valid
Compiler

Compiled 58 to 22 computations (62.1% saved)

Precisions
Click to see histograms. Total time spent on operations: 19.0ms
ival-hypot: 9.0ms (46.2% of total)
ival-mult: 7.0ms (35.9% of total)
ival-add: 2.0ms (10.3% of total)
ival-true: 0.0ms (0% of total)
adjust: 0.0ms (0% of total)
ival-assert: 0.0ms (0% of total)

preprocess16.0ms (0.5%)

Memory
31.8MiB live, 31.8MiB allocated; 0ms collecting garbage
Algorithm
egg-herbie
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
01642
14242
29242
311742
415542
068
0108
1218
2608
31178
41548
01543
Stop Event
iter limit
saturated
iter limit
saturated
Calls
Call 1
Inputs
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
Outputs
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
(hypot.f64 im re)
Symmetry

(abs im)

(abs re)

(sort re im)

Compiler

Compiled 8 to 6 computations (25% saved)

eval0.0ms (0%)

Memory
0.2MiB live, 0.2MiB allocated; 0ms collecting garbage
Compiler

Compiled 0 to 2 computations (-∞% saved)

prune0.0ms (0%)

Memory
1.1MiB live, 1.1MiB allocated; 0ms collecting garbage
Alt Table
Click to see full alt table
StatusAccuracyProgram
62.7%
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
Compiler

Compiled 8 to 6 computations (25% saved)

simplify5.0ms (0.2%)

Memory
11.2MiB live, 11.2MiB allocated; 0ms collecting garbage
Algorithm
egg-herbie
Localize:

Found 4 expressions of interest:

NewMetricScoreProgram
cost-diff0
(*.f64 im im)
cost-diff0
(*.f64 re re)
cost-diff1
(+.f64 (*.f64 re re) (*.f64 im im))
cost-diff4
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
0623
01023
12123
26023
311723
415423
015417
Stop Event
iter limit
saturated
iter limit
Calls
Call 1
Inputs
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
(+.f64 (*.f64 re re) (*.f64 im im))
(*.f64 re re)
re
(*.f64 im im)
im
Outputs
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
(hypot.f64 im re)
(+.f64 (*.f64 re re) (*.f64 im im))
(fma.f64 im im (*.f64 re re))
(*.f64 re re)
re
(*.f64 im im)
im

localize64.0ms (2.1%)

Memory
-29.9MiB live, 59.6MiB allocated; 10ms collecting garbage
Localize:

Found 4 expressions of interest:

NewMetricScoreProgram
accuracy0.0
(+.f64 (*.f64 re re) (*.f64 im im))
accuracy0.0
(*.f64 re re)
accuracy0.0
(*.f64 im im)
accuracy23.893038109698477
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
Samples
39.0ms256×0valid
Compiler

Compiled 25 to 8 computations (68% saved)

Precisions
Click to see histograms. Total time spent on operations: 9.0ms
ival-hypot: 5.0ms (53.8% of total)
ival-mult: 3.0ms (32.3% of total)
ival-add: 1.0ms (10.8% of total)
ival-true: 0.0ms (0% of total)
adjust: 0.0ms (0% of total)
ival-assert: 0.0ms (0% of total)

series5.0ms (0.2%)

Memory
15.6MiB live, 15.6MiB allocated; 0ms collecting garbage
Counts
4 → 27
Calls
Call 1
Inputs
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
(+.f64 (*.f64 re re) (*.f64 im im))
(*.f64 re re)
(*.f64 im im)
Outputs
im
(+ im (* 1/2 (/ (pow re 2) im)))
(+ im (* (pow re 2) (+ (* -1/8 (/ (pow re 2) (pow im 3))) (* 1/2 (/ 1 im)))))
(+ im (* (pow re 2) (+ (* (pow re 2) (- (* 1/16 (/ (pow re 2) (pow im 5))) (* 1/8 (/ 1 (pow im 3))))) (* 1/2 (/ 1 im)))))
(pow im 2)
(+ (pow im 2) (pow re 2))
(pow re 2)
re
(* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2)))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2))))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* (pow re 2) (+ 1 (/ (pow im 2) (pow re 2))))
(* -1 re)
(* -1 (* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2))))))))
(+ re (* 1/2 (/ (pow im 2) re)))
(+ re (* (pow im 2) (+ (* -1/8 (/ (pow im 2) (pow re 3))) (* 1/2 (/ 1 re)))))
(+ re (* (pow im 2) (+ (* (pow im 2) (- (* 1/16 (/ (pow im 2) (pow re 5))) (* 1/8 (/ 1 (pow re 3))))) (* 1/2 (/ 1 re)))))
(* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2)))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2))))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* (pow im 2) (+ 1 (/ (pow re 2) (pow im 2))))
(* -1 im)
(* -1 (* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2))))))))
Calls

6 calls:

TimeVariablePointExpression
1.0ms
re
@0
((sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (* re re) (* im im))
1.0ms
re
@inf
((sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (* re re) (* im im))
1.0ms
im
@inf
((sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (* re re) (* im im))
1.0ms
re
@-inf
((sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (* re re) (* im im))
1.0ms
im
@0
((sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (* re re) (* im im))

simplify247.0ms (8%)

Memory
-11.6MiB live, 176.9MiB allocated; 25ms collecting garbage
Algorithm
egg-herbie
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
0104441
1323441
21323435
36816435
08219396
Stop Event
iter limit
node limit
Counts
27 → 25
Calls
Call 1
Inputs
im
(+ im (* 1/2 (/ (pow re 2) im)))
(+ im (* (pow re 2) (+ (* -1/8 (/ (pow re 2) (pow im 3))) (* 1/2 (/ 1 im)))))
(+ im (* (pow re 2) (+ (* (pow re 2) (- (* 1/16 (/ (pow re 2) (pow im 5))) (* 1/8 (/ 1 (pow im 3))))) (* 1/2 (/ 1 im)))))
(pow im 2)
(+ (pow im 2) (pow re 2))
(pow re 2)
re
(* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2)))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2))))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* (pow re 2) (+ 1 (/ (pow im 2) (pow re 2))))
(* -1 re)
(* -1 (* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2))))))))
(+ re (* 1/2 (/ (pow im 2) re)))
(+ re (* (pow im 2) (+ (* -1/8 (/ (pow im 2) (pow re 3))) (* 1/2 (/ 1 re)))))
(+ re (* (pow im 2) (+ (* (pow im 2) (- (* 1/16 (/ (pow im 2) (pow re 5))) (* 1/8 (/ 1 (pow re 3))))) (* 1/2 (/ 1 re)))))
(* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2)))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2))))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* (pow im 2) (+ 1 (/ (pow re 2) (pow im 2))))
(* -1 im)
(* -1 (* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2))))))))
Outputs
im
(+ im (* 1/2 (/ (pow re 2) im)))
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(+ im (* (pow re 2) (+ (* -1/8 (/ (pow re 2) (pow im 3))) (* 1/2 (/ 1 im)))))
(fma.f64 (/.f64 (fma.f64 (/.f64 (/.f64 #s(literal -1/8 binary64) im) im) (*.f64 re re) #s(literal 1/2 binary64)) im) (*.f64 re re) im)
(+ im (* (pow re 2) (+ (* (pow re 2) (- (* 1/16 (/ (pow re 2) (pow im 5))) (* 1/8 (/ 1 (pow im 3))))) (* 1/2 (/ 1 im)))))
(fma.f64 (pow.f64 re #s(literal 4 binary64)) (fma.f64 (*.f64 #s(literal 1/16 binary64) re) (/.f64 re (pow.f64 im #s(literal 5 binary64))) (/.f64 #s(literal -1/8 binary64) (pow.f64 im #s(literal 3 binary64)))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
(pow im 2)
(*.f64 im im)
(+ (pow im 2) (pow re 2))
(fma.f64 im im (*.f64 re re))
(pow re 2)
(*.f64 re re)
re
(* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2)))))
(fma.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) im) (/.f64 (/.f64 im re) re) re)
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2))))))
(*.f64 (fma.f64 (pow.f64 im #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 4 binary64))) (fma.f64 (*.f64 #s(literal 1/2 binary64) (/.f64 im re)) (/.f64 im re) #s(literal 1 binary64))) re)
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(*.f64 (fma.f64 (pow.f64 im #s(literal 6 binary64)) (/.f64 #s(literal 1/16 binary64) (pow.f64 re #s(literal 6 binary64))) (fma.f64 (pow.f64 im #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 4 binary64))) (fma.f64 (*.f64 #s(literal 1/2 binary64) (/.f64 im re)) (/.f64 im re) #s(literal 1 binary64)))) re)
(* (pow re 2) (+ 1 (/ (pow im 2) (pow re 2))))
(*.f64 (fma.f64 (/.f64 (/.f64 im re) re) im #s(literal 1 binary64)) (*.f64 re re))
(* -1 re)
(neg.f64 re)
(* -1 (* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2))))))
(*.f64 (fma.f64 (/.f64 #s(literal -1/2 binary64) re) (/.f64 (*.f64 im im) re) #s(literal -1 binary64)) re)
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(*.f64 (fma.f64 (/.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 re #s(literal 4 binary64))) #s(literal 1/8 binary64) (fma.f64 (/.f64 #s(literal -1/2 binary64) re) (/.f64 (*.f64 im im) re) #s(literal -1 binary64))) re)
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2))))))))
(*.f64 (fma.f64 #s(literal -1/16 binary64) (/.f64 (pow.f64 im #s(literal 6 binary64)) (pow.f64 re #s(literal 6 binary64))) (fma.f64 (/.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 re #s(literal 4 binary64))) #s(literal 1/8 binary64) (fma.f64 (/.f64 #s(literal -1/2 binary64) re) (/.f64 (*.f64 im im) re) #s(literal -1 binary64)))) re)
(+ re (* 1/2 (/ (pow im 2) re)))
(fma.f64 (/.f64 #s(literal 1/2 binary64) re) (*.f64 im im) re)
(+ re (* (pow im 2) (+ (* -1/8 (/ (pow im 2) (pow re 3))) (* 1/2 (/ 1 re)))))
(fma.f64 (/.f64 (fma.f64 (/.f64 (/.f64 #s(literal -1/8 binary64) re) re) (*.f64 im im) #s(literal 1/2 binary64)) re) (*.f64 im im) re)
(+ re (* (pow im 2) (+ (* (pow im 2) (- (* 1/16 (/ (pow im 2) (pow re 5))) (* 1/8 (/ 1 (pow re 3))))) (* 1/2 (/ 1 re)))))
(fma.f64 (fma.f64 (fma.f64 (*.f64 #s(literal 1/16 binary64) im) (/.f64 im (pow.f64 re #s(literal 5 binary64))) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 3 binary64)))) (*.f64 im im) (/.f64 #s(literal 1/2 binary64) re)) (*.f64 im im) re)
(* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2)))))
(*.f64 (fma.f64 (/.f64 (/.f64 (*.f64 re re) im) im) #s(literal 1/2 binary64) #s(literal 1 binary64)) im)
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2))))))
(*.f64 (fma.f64 (/.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64))) #s(literal -1/8 binary64) (fma.f64 (/.f64 (/.f64 (*.f64 re re) im) im) #s(literal 1/2 binary64) #s(literal 1 binary64))) im)
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(*.f64 (fma.f64 (pow.f64 re #s(literal 6 binary64)) (/.f64 #s(literal 1/16 binary64) (pow.f64 im #s(literal 6 binary64))) (fma.f64 (/.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64))) #s(literal -1/8 binary64) (fma.f64 (/.f64 (/.f64 (*.f64 re re) im) im) #s(literal 1/2 binary64) #s(literal 1 binary64)))) im)
(* (pow im 2) (+ 1 (/ (pow re 2) (pow im 2))))
(*.f64 (fma.f64 (/.f64 (/.f64 (*.f64 re re) im) im) im im) im)
(* -1 im)
(neg.f64 im)
(* -1 (* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2))))))
(*.f64 (fma.f64 (/.f64 #s(literal -1/2 binary64) im) (/.f64 (*.f64 re re) im) #s(literal -1 binary64)) im)
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(*.f64 (fma.f64 (/.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64))) #s(literal 1/8 binary64) (fma.f64 (/.f64 #s(literal -1/2 binary64) im) (/.f64 (*.f64 re re) im) #s(literal -1 binary64))) im)
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2))))))))
(*.f64 (fma.f64 #s(literal -1/16 binary64) (/.f64 (pow.f64 re #s(literal 6 binary64)) (pow.f64 im #s(literal 6 binary64))) (fma.f64 (/.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64))) #s(literal 1/8 binary64) (fma.f64 (/.f64 #s(literal -1/2 binary64) im) (/.f64 (*.f64 re re) im) #s(literal -1 binary64)))) im)

rewrite48.0ms (1.6%)

Memory
39.8MiB live, 83.7MiB allocated; 6ms collecting garbage
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
0621
01021
13921
034615
Stop Event
iter limit
iter limit
iter limit
unsound
iter limit
Counts
4 → 171
Calls
Call 1
Inputs
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
(+.f64 (*.f64 re re) (*.f64 im im))
(*.f64 re re)
(*.f64 im im)
Outputs
(*.f64 (pow.f64 (fma.f64 im im (*.f64 re re)) #s(literal 1/4 binary64)) (pow.f64 (fma.f64 im im (*.f64 re re)) #s(literal 1/4 binary64)))
(pow.f64 (fma.f64 im im (*.f64 re re)) #s(literal 1/2 binary64))
(/.f64 (sqrt.f64 (-.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64)))) (sqrt.f64 (*.f64 (+.f64 re im) (-.f64 re im))))
(/.f64 (hypot.f64 (pow.f64 im #s(literal 3 binary64)) (pow.f64 re #s(literal 3 binary64))) (sqrt.f64 (+.f64 (-.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 (*.f64 re im) #s(literal 2 binary64))) (pow.f64 re #s(literal 4 binary64)))))
(sqrt.f64 (fma.f64 im im (*.f64 re re)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (neg.f64 (neg.f64 re)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (neg.f64 (fabs.f64 re)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (neg.f64 re))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (fabs.f64 re))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) re)
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (neg.f64 (neg.f64 im)))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (neg.f64 (fabs.f64 im)))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (neg.f64 im))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (fabs.f64 im))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) im)
(hypot.f64 (neg.f64 (neg.f64 re)) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (neg.f64 (neg.f64 re)) (neg.f64 (neg.f64 im)))
(hypot.f64 (neg.f64 (neg.f64 re)) (neg.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 (neg.f64 re)) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 (neg.f64 re)) (neg.f64 im))
(hypot.f64 (neg.f64 (neg.f64 re)) (fabs.f64 im))
(hypot.f64 (neg.f64 (neg.f64 re)) im)
(hypot.f64 (neg.f64 (fabs.f64 re)) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (neg.f64 (fabs.f64 re)) (neg.f64 (neg.f64 im)))
(hypot.f64 (neg.f64 (fabs.f64 re)) (neg.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 (fabs.f64 re)) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 (fabs.f64 re)) (neg.f64 im))
(hypot.f64 (neg.f64 (fabs.f64 re)) (fabs.f64 im))
(hypot.f64 (neg.f64 (fabs.f64 re)) im)
(hypot.f64 (neg.f64 (neg.f64 im)) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (neg.f64 (neg.f64 im)) (neg.f64 (neg.f64 re)))
(hypot.f64 (neg.f64 (neg.f64 im)) (neg.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 (neg.f64 im)) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 (neg.f64 im)) (neg.f64 re))
(hypot.f64 (neg.f64 (neg.f64 im)) (fabs.f64 re))
(hypot.f64 (neg.f64 (neg.f64 im)) re)
(hypot.f64 (neg.f64 (fabs.f64 im)) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (neg.f64 (fabs.f64 im)) (neg.f64 (neg.f64 re)))
(hypot.f64 (neg.f64 (fabs.f64 im)) (neg.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 (fabs.f64 im)) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 (fabs.f64 im)) (neg.f64 re))
(hypot.f64 (neg.f64 (fabs.f64 im)) (fabs.f64 re))
(hypot.f64 (neg.f64 (fabs.f64 im)) re)
(hypot.f64 (fabs.f64 (fabs.f64 re)) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (neg.f64 (neg.f64 im)))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (neg.f64 (fabs.f64 im)))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (neg.f64 im))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (fabs.f64 im))
(hypot.f64 (fabs.f64 (fabs.f64 re)) im)
(hypot.f64 (fabs.f64 (fabs.f64 im)) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (neg.f64 (neg.f64 re)))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (neg.f64 (fabs.f64 re)))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (neg.f64 re))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (fabs.f64 re))
(hypot.f64 (fabs.f64 (fabs.f64 im)) re)
(hypot.f64 (neg.f64 im) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (neg.f64 im) (neg.f64 (neg.f64 re)))
(hypot.f64 (neg.f64 im) (neg.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 im) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 im) (neg.f64 re))
(hypot.f64 (neg.f64 im) (fabs.f64 re))
(hypot.f64 (neg.f64 im) re)
(hypot.f64 (neg.f64 re) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (neg.f64 re) (neg.f64 (neg.f64 im)))
(hypot.f64 (neg.f64 re) (neg.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 re) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 re) (neg.f64 im))
(hypot.f64 (neg.f64 re) (fabs.f64 im))
(hypot.f64 (neg.f64 re) im)
(hypot.f64 (fabs.f64 im) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (fabs.f64 im) (neg.f64 (neg.f64 re)))
(hypot.f64 (fabs.f64 im) (neg.f64 (fabs.f64 re)))
(hypot.f64 (fabs.f64 im) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (fabs.f64 im) (neg.f64 re))
(hypot.f64 (fabs.f64 im) (fabs.f64 re))
(hypot.f64 (fabs.f64 im) re)
(hypot.f64 (fabs.f64 re) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (fabs.f64 re) (neg.f64 (neg.f64 im)))
(hypot.f64 (fabs.f64 re) (neg.f64 (fabs.f64 im)))
(hypot.f64 (fabs.f64 re) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (fabs.f64 re) (neg.f64 im))
(hypot.f64 (fabs.f64 re) (fabs.f64 im))
(hypot.f64 (fabs.f64 re) im)
(hypot.f64 im (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 im (neg.f64 (neg.f64 re)))
(hypot.f64 im (neg.f64 (fabs.f64 re)))
(hypot.f64 im (fabs.f64 (fabs.f64 re)))
(hypot.f64 im (neg.f64 re))
(hypot.f64 im (fabs.f64 re))
(hypot.f64 im re)
(hypot.f64 re (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 re (neg.f64 (neg.f64 im)))
(hypot.f64 re (neg.f64 (fabs.f64 im)))
(hypot.f64 re (fabs.f64 (fabs.f64 im)))
(hypot.f64 re (neg.f64 im))
(hypot.f64 re (fabs.f64 im))
(hypot.f64 re im)
(exp.f64 (*.f64 (log.f64 (fma.f64 im im (*.f64 re re))) #s(literal 1/2 binary64)))
(/.f64 (-.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 re #s(literal 4 binary64))) (-.f64 (*.f64 im im) (*.f64 re re)))
(/.f64 (-.f64 (pow.f64 re #s(literal 6 binary64)) (pow.f64 (*.f64 (neg.f64 im) im) #s(literal 3 binary64))) (+.f64 (pow.f64 re #s(literal 4 binary64)) (+.f64 (pow.f64 im #s(literal 4 binary64)) (*.f64 (*.f64 re re) (*.f64 (neg.f64 im) im)))))
(/.f64 (neg.f64 (-.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64)))) (neg.f64 (*.f64 (+.f64 re im) (-.f64 re im))))
(/.f64 (neg.f64 (+.f64 (pow.f64 im #s(literal 6 binary64)) (pow.f64 re #s(literal 6 binary64)))) (neg.f64 (+.f64 (-.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 (*.f64 re im) #s(literal 2 binary64))) (pow.f64 re #s(literal 4 binary64)))))
(/.f64 (-.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64))) (*.f64 (+.f64 re im) (-.f64 re im)))
(/.f64 (+.f64 (pow.f64 im #s(literal 6 binary64)) (pow.f64 re #s(literal 6 binary64))) (+.f64 (pow.f64 im #s(literal 4 binary64)) (-.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 (*.f64 re im) #s(literal 2 binary64)))))
(/.f64 (+.f64 (pow.f64 im #s(literal 6 binary64)) (pow.f64 re #s(literal 6 binary64))) (+.f64 (-.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 (*.f64 re im) #s(literal 2 binary64))) (pow.f64 re #s(literal 4 binary64))))
(fma.f64 (pow.f64 im #s(literal 1 binary64)) (pow.f64 im #s(literal 1 binary64)) (*.f64 re re))
(fma.f64 (pow.f64 re #s(literal 1 binary64)) (pow.f64 re #s(literal 1 binary64)) (*.f64 (neg.f64 (neg.f64 im)) im))
(fma.f64 (pow.f64 re #s(literal 1 binary64)) (pow.f64 re #s(literal 1 binary64)) (*.f64 im im))
(fma.f64 (neg.f64 (neg.f64 re)) (neg.f64 (neg.f64 re)) (*.f64 (neg.f64 (neg.f64 im)) im))
(fma.f64 (neg.f64 (neg.f64 re)) (neg.f64 (neg.f64 re)) (*.f64 im im))
(fma.f64 (neg.f64 (fabs.f64 re)) (neg.f64 (fabs.f64 re)) (*.f64 (neg.f64 (neg.f64 im)) im))
(fma.f64 (neg.f64 (fabs.f64 re)) (neg.f64 (fabs.f64 re)) (*.f64 im im))
(fma.f64 (neg.f64 (neg.f64 im)) (neg.f64 (neg.f64 im)) (*.f64 re re))
(fma.f64 (neg.f64 (fabs.f64 im)) (neg.f64 (fabs.f64 im)) (*.f64 re re))
(fma.f64 (fabs.f64 (fabs.f64 re)) (fabs.f64 (fabs.f64 re)) (*.f64 (neg.f64 (neg.f64 im)) im))
(fma.f64 (fabs.f64 (fabs.f64 re)) (fabs.f64 (fabs.f64 re)) (*.f64 im im))
(fma.f64 (fabs.f64 (fabs.f64 im)) (fabs.f64 (fabs.f64 im)) (*.f64 re re))
(fma.f64 (neg.f64 im) (neg.f64 im) (*.f64 re re))
(fma.f64 (neg.f64 re) (neg.f64 re) (*.f64 (neg.f64 (neg.f64 im)) im))
(fma.f64 (neg.f64 re) (neg.f64 re) (*.f64 im im))
(fma.f64 (fabs.f64 im) (fabs.f64 im) (*.f64 re re))
(fma.f64 (fabs.f64 re) (fabs.f64 re) (*.f64 (neg.f64 (neg.f64 im)) im))
(fma.f64 (fabs.f64 re) (fabs.f64 re) (*.f64 im im))
(fma.f64 im im (*.f64 re re))
(fma.f64 re re (*.f64 (neg.f64 (neg.f64 im)) im))
(fma.f64 re re (*.f64 im im))
(-.f64 (/.f64 (pow.f64 re #s(literal 4 binary64)) (*.f64 (+.f64 re im) (-.f64 re im))) (/.f64 (pow.f64 im #s(literal 4 binary64)) (*.f64 (+.f64 re im) (-.f64 re im))))
(-.f64 (*.f64 im im) (*.f64 (neg.f64 (neg.f64 re)) (neg.f64 re)))
(-.f64 (*.f64 im im) (*.f64 (neg.f64 (fabs.f64 re)) (fabs.f64 re)))
(-.f64 (*.f64 im im) (*.f64 (neg.f64 re) re))
(-.f64 (*.f64 im im) (*.f64 re (neg.f64 re)))
(-.f64 (*.f64 re re) (*.f64 (neg.f64 (neg.f64 im)) (neg.f64 im)))
(-.f64 (*.f64 re re) (*.f64 (neg.f64 (fabs.f64 im)) (fabs.f64 im)))
(-.f64 (*.f64 re re) (*.f64 (neg.f64 im) im))
(+.f64 (/.f64 (pow.f64 re #s(literal 6 binary64)) (+.f64 (-.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 (*.f64 re im) #s(literal 2 binary64))) (pow.f64 re #s(literal 4 binary64)))) (/.f64 (pow.f64 im #s(literal 6 binary64)) (+.f64 (-.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 (*.f64 re im) #s(literal 2 binary64))) (pow.f64 re #s(literal 4 binary64)))))
(+.f64 (*.f64 im im) (*.f64 re re))
(+.f64 (*.f64 re re) (*.f64 (neg.f64 (neg.f64 im)) im))
(+.f64 (*.f64 re re) (*.f64 im im))
(*.f64 (pow.f64 re #s(literal 1 binary64)) (pow.f64 re #s(literal 1 binary64)))
(*.f64 (neg.f64 (neg.f64 re)) (neg.f64 (neg.f64 re)))
(*.f64 (neg.f64 (fabs.f64 re)) (neg.f64 (fabs.f64 re)))
(*.f64 (fabs.f64 (fabs.f64 re)) (fabs.f64 (fabs.f64 re)))
(*.f64 (neg.f64 re) (neg.f64 re))
(*.f64 (fabs.f64 re) (fabs.f64 re))
(*.f64 re re)
(pow.f64 (neg.f64 re) #s(literal 2 binary64))
(pow.f64 (fabs.f64 re) #s(literal 2 binary64))
(pow.f64 re #s(literal 2 binary64))
(neg.f64 (*.f64 (neg.f64 re) re))
(neg.f64 (*.f64 re (neg.f64 re)))
(fabs.f64 (*.f64 re re))
(exp.f64 (*.f64 (log.f64 re) #s(literal 2 binary64)))
(*.f64 (pow.f64 im #s(literal 1 binary64)) (pow.f64 im #s(literal 1 binary64)))
(*.f64 (neg.f64 (neg.f64 im)) (neg.f64 (neg.f64 im)))
(*.f64 (neg.f64 (fabs.f64 im)) (neg.f64 (fabs.f64 im)))
(*.f64 (fabs.f64 (fabs.f64 im)) (fabs.f64 (fabs.f64 im)))
(*.f64 (neg.f64 im) (neg.f64 im))
(*.f64 (fabs.f64 im) (fabs.f64 im))
(*.f64 im im)
(pow.f64 (neg.f64 im) #s(literal 2 binary64))
(pow.f64 (fabs.f64 im) #s(literal 2 binary64))
(pow.f64 im #s(literal 2 binary64))
(neg.f64 (*.f64 (neg.f64 im) im))
(fabs.f64 (*.f64 im im))
(exp.f64 (*.f64 (log.f64 im) #s(literal 2 binary64)))

eval94.0ms (3%)

Memory
-39.5MiB live, 59.9MiB allocated; 18ms collecting garbage
Compiler

Compiled 2 070 to 446 computations (78.5% saved)

prune5.0ms (0.2%)

Memory
16.8MiB live, 16.8MiB allocated; 0ms collecting garbage
Pruning

5 alts after pruning (5 fresh and 0 done)

PrunedKeptTotal
New1915196
Fresh000
Picked101
Done000
Total1925197
Accuracy
100.0%
Counts
197 → 5
Alt Table
Click to see full alt table
StatusAccuracyProgram
100.0%
(hypot.f64 re im)
62.7%
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
62.2%
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
93.0%
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
1.8%
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
Compiler

Compiled 100 to 70 computations (30% saved)

simplify12.0ms (0.4%)

Memory
17.6MiB live, 17.6MiB allocated; 0ms collecting garbage
Algorithm
egg-herbie
Localize:

Found 13 expressions of interest:

NewMetricScoreProgram
cost-diff0
(*.f64 re re)
cost-diff0
(/.f64 #s(literal 1/2 binary64) im)
cost-diff0
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
cost-diff0
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
cost-diff0
(*.f64 im im)
cost-diff0
(fma.f64 re re (*.f64 im im))
cost-diff4
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
cost-diff0
(*.f64 im im)
cost-diff0
#s(approx (+ (* re re) (* im im)) (*.f64 im im))
cost-diff0
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
cost-diff0
(neg.f64 re)
cost-diff0
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
cost-diff0
(hypot.f64 re im)
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
01982
02882
14482
211482
327682
449382
565082
667482
067482
Stop Event
iter limit
saturated
iter limit
Calls
Call 1
Inputs
(hypot.f64 re im)
re
im
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
(neg.f64 re)
re
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
#s(approx (+ (* re re) (* im im)) (*.f64 im im))
(*.f64 im im)
im
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
(fma.f64 re re (*.f64 im im))
re
(*.f64 im im)
im
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(/.f64 #s(literal 1/2 binary64) im)
#s(literal 1/2 binary64)
im
(*.f64 re re)
re
Outputs
(hypot.f64 re im)
(hypot.f64 im re)
re
im
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
(neg.f64 re)
re
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
#s(approx (+ (* re re) (* im im)) (*.f64 im im))
(*.f64 im im)
im
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
(hypot.f64 im re)
(fma.f64 re re (*.f64 im im))
re
(*.f64 im im)
im
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 re re) (/.f64 #s(literal 1/2 binary64) im) im))
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(fma.f64 (*.f64 re re) (/.f64 #s(literal 1/2 binary64) im) im)
(/.f64 #s(literal 1/2 binary64) im)
#s(literal 1/2 binary64)
im
(*.f64 re re)
re

localize55.0ms (1.8%)

Memory
-26.2MiB live, 61.7MiB allocated; 12ms collecting garbage
Localize:

Found 13 expressions of interest:

NewMetricScoreProgram
accuracy0.0
(/.f64 #s(literal 1/2 binary64) im)
accuracy0.0
(*.f64 re re)
accuracy0.24891111047018818
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
accuracy4.220252537594762
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
accuracy0.0
(fma.f64 re re (*.f64 im im))
accuracy0.0
(*.f64 im im)
accuracy23.893038109698477
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
accuracy0.0
(*.f64 im im)
accuracy0.3378522272758019
#s(approx (+ (* re re) (* im im)) (*.f64 im im))
accuracy23.893038109698477
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
accuracy0.0
(neg.f64 re)
accuracy62.87124598366688
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
accuracy0.0
(hypot.f64 re im)
Samples
46.0ms256×0valid
Compiler

Compiled 88 to 13 computations (85.2% saved)

Precisions
Click to see histograms. Total time spent on operations: 19.0ms
ival-mult: 5.0ms (26.3% of total)
ival-hypot: 5.0ms (26.3% of total)
ival-neg: 5.0ms (26.3% of total)
ival-div: 2.0ms (10.5% of total)
ival-add: 2.0ms (10.5% of total)
adjust: 0.0ms (0% of total)
ival-assert: 0.0ms (0% of total)
ival-true: 0.0ms (0% of total)
exact: 0.0ms (0% of total)

series7.0ms (0.2%)

Memory
20.0MiB live, 20.0MiB allocated; 0ms collecting garbage
Counts
12 → 32
Calls
Call 1
Inputs
(hypot.f64 re im)
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
(neg.f64 re)
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
#s(approx (+ (* re re) (* im im)) (*.f64 im im))
(*.f64 im im)
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
(fma.f64 re re (*.f64 im im))
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(/.f64 #s(literal 1/2 binary64) im)
(*.f64 re re)
Outputs
im
(+ im (* 1/2 (/ (pow re 2) im)))
(+ im (* (pow re 2) (+ (* -1/8 (/ (pow re 2) (pow im 3))) (* 1/2 (/ 1 im)))))
(+ im (* (pow re 2) (+ (* (pow re 2) (- (* 1/16 (/ (pow re 2) (pow im 5))) (* 1/8 (/ 1 (pow im 3))))) (* 1/2 (/ 1 im)))))
(* -1 re)
(pow im 2)
(+ (pow im 2) (pow re 2))
(pow re 2)
re
(* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2)))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2))))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* (pow re 2) (+ 1 (/ (pow im 2) (pow re 2))))
(* 1/2 (/ (pow re 2) im))
(* (pow re 2) (+ (* 1/2 (/ 1 im)) (/ im (pow re 2))))
(* -1 (* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2))))))))
(+ re (* 1/2 (/ (pow im 2) re)))
(+ re (* (pow im 2) (+ (* -1/8 (/ (pow im 2) (pow re 3))) (* 1/2 (/ 1 re)))))
(+ re (* (pow im 2) (+ (* (pow im 2) (- (* 1/16 (/ (pow im 2) (pow re 5))) (* 1/8 (/ 1 (pow re 3))))) (* 1/2 (/ 1 re)))))
(/ (+ (* 1/2 (pow re 2)) (pow im 2)) im)
(/ 1/2 im)
(* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2)))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2))))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* (pow im 2) (+ 1 (/ (pow re 2) (pow im 2))))
(* -1 im)
(* -1 (* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2))))))))
(* -1 (* im (- (* -1/2 (/ (pow re 2) (pow im 2))) 1)))
Calls

6 calls:

TimeVariablePointExpression
1.0ms
re
@inf
((sqrt (+ (* re re) (* im im))) (sqrt (+ (* re re) (* im im))) (neg re) (sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (* im im) (sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (/ 1/2 im) (* re re))
1.0ms
im
@-inf
((sqrt (+ (* re re) (* im im))) (sqrt (+ (* re re) (* im im))) (neg re) (sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (* im im) (sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (/ 1/2 im) (* re re))
1.0ms
im
@inf
((sqrt (+ (* re re) (* im im))) (sqrt (+ (* re re) (* im im))) (neg re) (sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (* im im) (sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (/ 1/2 im) (* re re))
1.0ms
im
@0
((sqrt (+ (* re re) (* im im))) (sqrt (+ (* re re) (* im im))) (neg re) (sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (* im im) (sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (/ 1/2 im) (* re re))
1.0ms
re
@-inf
((sqrt (+ (* re re) (* im im))) (sqrt (+ (* re re) (* im im))) (neg re) (sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (* im im) (sqrt (+ (* re re) (* im im))) (+ (* re re) (* im im)) (sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (/ 1/2 im) (* re re))

simplify212.0ms (6.9%)

Memory
-19.9MiB live, 127.3MiB allocated; 19ms collecting garbage
Algorithm
egg-herbie
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
0116478
1349478
21401460
35767459
08119421
Stop Event
iter limit
node limit
Counts
32 → 30
Calls
Call 1
Inputs
im
(+ im (* 1/2 (/ (pow re 2) im)))
(+ im (* (pow re 2) (+ (* -1/8 (/ (pow re 2) (pow im 3))) (* 1/2 (/ 1 im)))))
(+ im (* (pow re 2) (+ (* (pow re 2) (- (* 1/16 (/ (pow re 2) (pow im 5))) (* 1/8 (/ 1 (pow im 3))))) (* 1/2 (/ 1 im)))))
(* -1 re)
(pow im 2)
(+ (pow im 2) (pow re 2))
(pow re 2)
re
(* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2)))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2))))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* (pow re 2) (+ 1 (/ (pow im 2) (pow re 2))))
(* 1/2 (/ (pow re 2) im))
(* (pow re 2) (+ (* 1/2 (/ 1 im)) (/ im (pow re 2))))
(* -1 (* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2))))))))
(+ re (* 1/2 (/ (pow im 2) re)))
(+ re (* (pow im 2) (+ (* -1/8 (/ (pow im 2) (pow re 3))) (* 1/2 (/ 1 re)))))
(+ re (* (pow im 2) (+ (* (pow im 2) (- (* 1/16 (/ (pow im 2) (pow re 5))) (* 1/8 (/ 1 (pow re 3))))) (* 1/2 (/ 1 re)))))
(/ (+ (* 1/2 (pow re 2)) (pow im 2)) im)
(/ 1/2 im)
(* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2)))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2))))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* (pow im 2) (+ 1 (/ (pow re 2) (pow im 2))))
(* -1 im)
(* -1 (* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2))))))))
(* -1 (* im (- (* -1/2 (/ (pow re 2) (pow im 2))) 1)))
Outputs
im
(+ im (* 1/2 (/ (pow re 2) im)))
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(+ im (* (pow re 2) (+ (* -1/8 (/ (pow re 2) (pow im 3))) (* 1/2 (/ 1 im)))))
(fma.f64 (/.f64 (fma.f64 (/.f64 (/.f64 #s(literal -1/8 binary64) im) im) (*.f64 re re) #s(literal 1/2 binary64)) im) (*.f64 re re) im)
(+ im (* (pow re 2) (+ (* (pow re 2) (- (* 1/16 (/ (pow re 2) (pow im 5))) (* 1/8 (/ 1 (pow im 3))))) (* 1/2 (/ 1 im)))))
(fma.f64 (pow.f64 re #s(literal 4 binary64)) (fma.f64 (*.f64 #s(literal 1/16 binary64) re) (/.f64 re (pow.f64 im #s(literal 5 binary64))) (/.f64 #s(literal -1/8 binary64) (pow.f64 im #s(literal 3 binary64)))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
(* -1 re)
(neg.f64 re)
(pow im 2)
(*.f64 im im)
(+ (pow im 2) (pow re 2))
(fma.f64 im im (*.f64 re re))
(pow re 2)
(*.f64 re re)
re
(* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2)))))
(fma.f64 (/.f64 re re) (*.f64 (/.f64 (*.f64 im im) re) #s(literal 1/2 binary64)) re)
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2))))))
(*.f64 (fma.f64 (pow.f64 im #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 4 binary64))) (fma.f64 (/.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) re) im) re) im #s(literal 1 binary64))) re)
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(*.f64 (fma.f64 (pow.f64 im #s(literal 6 binary64)) (/.f64 #s(literal 1/16 binary64) (pow.f64 re #s(literal 6 binary64))) (fma.f64 (pow.f64 im #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 4 binary64))) (fma.f64 (/.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) re) im) re) im #s(literal 1 binary64)))) re)
(* (pow re 2) (+ 1 (/ (pow im 2) (pow re 2))))
(*.f64 (fma.f64 (/.f64 im re) (/.f64 im re) #s(literal 1 binary64)) (*.f64 re re))
(* 1/2 (/ (pow re 2) im))
(*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))
(* (pow re 2) (+ (* 1/2 (/ 1 im)) (/ im (pow re 2))))
(*.f64 (*.f64 (-.f64 (/.f64 im (*.f64 re re)) (/.f64 #s(literal -1/2 binary64) im)) re) re)
(* -1 (* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2))))))
(*.f64 (fma.f64 (/.f64 #s(literal -1/2 binary64) re) (/.f64 (*.f64 im im) re) #s(literal -1 binary64)) re)
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(*.f64 (fma.f64 (/.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 re #s(literal 4 binary64))) #s(literal 1/8 binary64) (fma.f64 (/.f64 #s(literal -1/2 binary64) re) (/.f64 (*.f64 im im) re) #s(literal -1 binary64))) re)
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2))))))))
(*.f64 (fma.f64 (pow.f64 im #s(literal 6 binary64)) (/.f64 #s(literal 1/16 binary64) (pow.f64 re #s(literal 6 binary64))) (fma.f64 (pow.f64 im #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 4 binary64))) (fma.f64 (/.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) re) im) re) im #s(literal 1 binary64)))) (neg.f64 re))
(+ re (* 1/2 (/ (pow im 2) re)))
(fma.f64 (/.f64 #s(literal 1/2 binary64) re) (*.f64 im im) re)
(+ re (* (pow im 2) (+ (* -1/8 (/ (pow im 2) (pow re 3))) (* 1/2 (/ 1 re)))))
(fma.f64 (/.f64 (fma.f64 (/.f64 (/.f64 #s(literal -1/8 binary64) re) re) (*.f64 im im) #s(literal 1/2 binary64)) re) (*.f64 im im) re)
(+ re (* (pow im 2) (+ (* (pow im 2) (- (* 1/16 (/ (pow im 2) (pow re 5))) (* 1/8 (/ 1 (pow re 3))))) (* 1/2 (/ 1 re)))))
(fma.f64 (fma.f64 (fma.f64 (*.f64 #s(literal 1/16 binary64) im) (/.f64 im (pow.f64 re #s(literal 5 binary64))) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 3 binary64)))) (*.f64 im im) (/.f64 #s(literal 1/2 binary64) re)) (*.f64 im im) re)
(/ (+ (* 1/2 (pow re 2)) (pow im 2)) im)
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(/ 1/2 im)
(/.f64 #s(literal 1/2 binary64) im)
(* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2)))))
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2))))))
(fma.f64 (*.f64 (pow.f64 re #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 im #s(literal 4 binary64)))) im (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(fma.f64 (fma.f64 (pow.f64 re #s(literal 6 binary64)) (/.f64 #s(literal 1/16 binary64) (pow.f64 im #s(literal 6 binary64))) (fma.f64 (pow.f64 re #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 im #s(literal 4 binary64))) #s(literal 1 binary64))) im (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64)))
(* (pow im 2) (+ 1 (/ (pow re 2) (pow im 2))))
(fma.f64 (/.f64 (*.f64 re re) im) im (*.f64 im im))
(* -1 im)
(neg.f64 im)
(* -1 (* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2))))))
(fma.f64 #s(literal -1/2 binary64) (/.f64 (*.f64 re re) im) (neg.f64 im))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(neg.f64 (fma.f64 (*.f64 (pow.f64 re #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 im #s(literal 4 binary64)))) im (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2))))))))
(fma.f64 (fma.f64 (pow.f64 re #s(literal 6 binary64)) (/.f64 #s(literal 1/16 binary64) (pow.f64 im #s(literal 6 binary64))) (fma.f64 (pow.f64 re #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 im #s(literal 4 binary64))) #s(literal 1 binary64))) (neg.f64 im) (*.f64 #s(literal -1/2 binary64) (/.f64 (*.f64 re re) im)))
(* -1 (* im (- (* -1/2 (/ (pow re 2) (pow im 2))) 1)))
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)

rewrite59.0ms (1.9%)

Memory
-9.2MiB live, 36.9MiB allocated; 4ms collecting garbage
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
01970
02870
17670
056670
Stop Event
iter limit
iter limit
node limit
iter limit
Counts
12 → 310
Calls
Call 1
Inputs
(hypot.f64 re im)
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
(neg.f64 re)
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
#s(approx (+ (* re re) (* im im)) (*.f64 im im))
(*.f64 im im)
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
(fma.f64 re re (*.f64 im im))
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(/.f64 #s(literal 1/2 binary64) im)
(*.f64 re re)
Outputs
(*.f64 (pow.f64 (fma.f64 re re (*.f64 im im)) #s(literal 1/4 binary64)) (pow.f64 (fma.f64 re re (*.f64 im im)) #s(literal 1/4 binary64)))
(pow.f64 (fma.f64 re re (*.f64 im im)) #s(literal 1/2 binary64))
(/.f64 (sqrt.f64 (-.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64)))) (sqrt.f64 (*.f64 (+.f64 re im) (-.f64 re im))))
(/.f64 (hypot.f64 (pow.f64 re #s(literal 3 binary64)) (pow.f64 im #s(literal 3 binary64))) (sqrt.f64 (+.f64 (-.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 (*.f64 re im) #s(literal 2 binary64))) (pow.f64 re #s(literal 4 binary64)))))
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (neg.f64 (fabs.f64 re)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (neg.f64 (neg.f64 re)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (fabs.f64 re))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (neg.f64 re))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) re)
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (neg.f64 (neg.f64 im)))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (neg.f64 (fabs.f64 im)))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (neg.f64 im))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (fabs.f64 im))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) im)
(hypot.f64 (neg.f64 (neg.f64 im)) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (neg.f64 (neg.f64 im)) (neg.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 (neg.f64 im)) (neg.f64 (neg.f64 re)))
(hypot.f64 (neg.f64 (neg.f64 im)) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 (neg.f64 im)) (fabs.f64 re))
(hypot.f64 (neg.f64 (neg.f64 im)) (neg.f64 re))
(hypot.f64 (neg.f64 (neg.f64 im)) re)
(hypot.f64 (neg.f64 (fabs.f64 im)) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (neg.f64 (fabs.f64 im)) (neg.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 (fabs.f64 im)) (neg.f64 (neg.f64 re)))
(hypot.f64 (neg.f64 (fabs.f64 im)) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 (fabs.f64 im)) (fabs.f64 re))
(hypot.f64 (neg.f64 (fabs.f64 im)) (neg.f64 re))
(hypot.f64 (neg.f64 (fabs.f64 im)) re)
(hypot.f64 (neg.f64 (fabs.f64 re)) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (neg.f64 (fabs.f64 re)) (neg.f64 (neg.f64 im)))
(hypot.f64 (neg.f64 (fabs.f64 re)) (neg.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 (fabs.f64 re)) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 (fabs.f64 re)) (neg.f64 im))
(hypot.f64 (neg.f64 (fabs.f64 re)) (fabs.f64 im))
(hypot.f64 (neg.f64 (fabs.f64 re)) im)
(hypot.f64 (neg.f64 (neg.f64 re)) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (neg.f64 (neg.f64 re)) (neg.f64 (neg.f64 im)))
(hypot.f64 (neg.f64 (neg.f64 re)) (neg.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 (neg.f64 re)) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 (neg.f64 re)) (neg.f64 im))
(hypot.f64 (neg.f64 (neg.f64 re)) (fabs.f64 im))
(hypot.f64 (neg.f64 (neg.f64 re)) im)
(hypot.f64 (fabs.f64 (fabs.f64 im)) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (neg.f64 (fabs.f64 re)))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (neg.f64 (neg.f64 re)))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (fabs.f64 re))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (neg.f64 re))
(hypot.f64 (fabs.f64 (fabs.f64 im)) re)
(hypot.f64 (fabs.f64 (fabs.f64 re)) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (neg.f64 (neg.f64 im)))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (neg.f64 (fabs.f64 im)))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (neg.f64 im))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (fabs.f64 im))
(hypot.f64 (fabs.f64 (fabs.f64 re)) im)
(hypot.f64 (neg.f64 im) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (neg.f64 im) (neg.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 im) (neg.f64 (neg.f64 re)))
(hypot.f64 (neg.f64 im) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 im) (fabs.f64 re))
(hypot.f64 (neg.f64 im) (neg.f64 re))
(hypot.f64 (neg.f64 im) re)
(hypot.f64 (fabs.f64 im) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (fabs.f64 im) (neg.f64 (fabs.f64 re)))
(hypot.f64 (fabs.f64 im) (neg.f64 (neg.f64 re)))
(hypot.f64 (fabs.f64 im) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (fabs.f64 im) (fabs.f64 re))
(hypot.f64 (fabs.f64 im) (neg.f64 re))
(hypot.f64 (fabs.f64 im) re)
(hypot.f64 (fabs.f64 re) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (fabs.f64 re) (neg.f64 (neg.f64 im)))
(hypot.f64 (fabs.f64 re) (neg.f64 (fabs.f64 im)))
(hypot.f64 (fabs.f64 re) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (fabs.f64 re) (neg.f64 im))
(hypot.f64 (fabs.f64 re) (fabs.f64 im))
(hypot.f64 (fabs.f64 re) im)
(hypot.f64 (neg.f64 re) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (neg.f64 re) (neg.f64 (neg.f64 im)))
(hypot.f64 (neg.f64 re) (neg.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 re) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 re) (neg.f64 im))
(hypot.f64 (neg.f64 re) (fabs.f64 im))
(hypot.f64 (neg.f64 re) im)
(hypot.f64 im (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 im (neg.f64 (fabs.f64 re)))
(hypot.f64 im (neg.f64 (neg.f64 re)))
(hypot.f64 im (fabs.f64 (fabs.f64 re)))
(hypot.f64 im (fabs.f64 re))
(hypot.f64 im (neg.f64 re))
(hypot.f64 im re)
(hypot.f64 re (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 re (neg.f64 (neg.f64 im)))
(hypot.f64 re (neg.f64 (fabs.f64 im)))
(hypot.f64 re (fabs.f64 (fabs.f64 im)))
(hypot.f64 re (neg.f64 im))
(hypot.f64 re (fabs.f64 im))
(hypot.f64 re im)
(exp.f64 (*.f64 (log.f64 (fma.f64 re re (*.f64 im im))) #s(literal 1/2 binary64)))
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
(neg.f64 re)
(*.f64 (pow.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)) #s(literal 1/4 binary64)) (pow.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)) #s(literal 1/4 binary64)))
(pow.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)) #s(literal 1/2 binary64))
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
(exp.f64 (*.f64 (log.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im))) #s(literal 1/2 binary64)))
#s(approx (+ (* re re) (* im im)) (*.f64 im im))
(*.f64 (pow.f64 im #s(literal 1 binary64)) (pow.f64 im #s(literal 1 binary64)))
(*.f64 (neg.f64 (neg.f64 im)) (neg.f64 (neg.f64 im)))
(*.f64 (neg.f64 (fabs.f64 im)) (neg.f64 (fabs.f64 im)))
(*.f64 (fabs.f64 (fabs.f64 im)) (fabs.f64 (fabs.f64 im)))
(*.f64 (neg.f64 im) (neg.f64 im))
(*.f64 (fabs.f64 im) (fabs.f64 im))
(*.f64 im im)
(pow.f64 (neg.f64 im) #s(literal 2 binary64))
(pow.f64 (fabs.f64 im) #s(literal 2 binary64))
(pow.f64 im #s(literal 2 binary64))
(neg.f64 (*.f64 (neg.f64 im) im))
(fabs.f64 (*.f64 im im))
(exp.f64 (*.f64 (log.f64 im) #s(literal 2 binary64)))
(*.f64 (pow.f64 (fma.f64 re re (*.f64 im im)) #s(literal 1/4 binary64)) (pow.f64 (fma.f64 re re (*.f64 im im)) #s(literal 1/4 binary64)))
(pow.f64 (fma.f64 re re (*.f64 im im)) #s(literal 1/2 binary64))
(/.f64 (sqrt.f64 (-.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64)))) (sqrt.f64 (*.f64 (+.f64 re im) (-.f64 re im))))
(/.f64 (hypot.f64 (pow.f64 re #s(literal 3 binary64)) (pow.f64 im #s(literal 3 binary64))) (sqrt.f64 (+.f64 (-.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 (*.f64 re im) #s(literal 2 binary64))) (pow.f64 re #s(literal 4 binary64)))))
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (neg.f64 (fabs.f64 re)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (neg.f64 (neg.f64 re)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (fabs.f64 re))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) (neg.f64 re))
(hypot.f64 (pow.f64 im #s(literal 1 binary64)) re)
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (neg.f64 (neg.f64 im)))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (neg.f64 (fabs.f64 im)))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (neg.f64 im))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) (fabs.f64 im))
(hypot.f64 (pow.f64 re #s(literal 1 binary64)) im)
(hypot.f64 (neg.f64 (neg.f64 im)) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (neg.f64 (neg.f64 im)) (neg.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 (neg.f64 im)) (neg.f64 (neg.f64 re)))
(hypot.f64 (neg.f64 (neg.f64 im)) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 (neg.f64 im)) (fabs.f64 re))
(hypot.f64 (neg.f64 (neg.f64 im)) (neg.f64 re))
(hypot.f64 (neg.f64 (neg.f64 im)) re)
(hypot.f64 (neg.f64 (fabs.f64 im)) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (neg.f64 (fabs.f64 im)) (neg.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 (fabs.f64 im)) (neg.f64 (neg.f64 re)))
(hypot.f64 (neg.f64 (fabs.f64 im)) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 (fabs.f64 im)) (fabs.f64 re))
(hypot.f64 (neg.f64 (fabs.f64 im)) (neg.f64 re))
(hypot.f64 (neg.f64 (fabs.f64 im)) re)
(hypot.f64 (neg.f64 (fabs.f64 re)) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (neg.f64 (fabs.f64 re)) (neg.f64 (neg.f64 im)))
(hypot.f64 (neg.f64 (fabs.f64 re)) (neg.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 (fabs.f64 re)) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 (fabs.f64 re)) (neg.f64 im))
(hypot.f64 (neg.f64 (fabs.f64 re)) (fabs.f64 im))
(hypot.f64 (neg.f64 (fabs.f64 re)) im)
(hypot.f64 (neg.f64 (neg.f64 re)) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (neg.f64 (neg.f64 re)) (neg.f64 (neg.f64 im)))
(hypot.f64 (neg.f64 (neg.f64 re)) (neg.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 (neg.f64 re)) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 (neg.f64 re)) (neg.f64 im))
(hypot.f64 (neg.f64 (neg.f64 re)) (fabs.f64 im))
(hypot.f64 (neg.f64 (neg.f64 re)) im)
(hypot.f64 (fabs.f64 (fabs.f64 im)) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (neg.f64 (fabs.f64 re)))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (neg.f64 (neg.f64 re)))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (fabs.f64 re))
(hypot.f64 (fabs.f64 (fabs.f64 im)) (neg.f64 re))
(hypot.f64 (fabs.f64 (fabs.f64 im)) re)
(hypot.f64 (fabs.f64 (fabs.f64 re)) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (neg.f64 (neg.f64 im)))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (neg.f64 (fabs.f64 im)))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (neg.f64 im))
(hypot.f64 (fabs.f64 (fabs.f64 re)) (fabs.f64 im))
(hypot.f64 (fabs.f64 (fabs.f64 re)) im)
(hypot.f64 (neg.f64 im) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (neg.f64 im) (neg.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 im) (neg.f64 (neg.f64 re)))
(hypot.f64 (neg.f64 im) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (neg.f64 im) (fabs.f64 re))
(hypot.f64 (neg.f64 im) (neg.f64 re))
(hypot.f64 (neg.f64 im) re)
(hypot.f64 (fabs.f64 im) (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 (fabs.f64 im) (neg.f64 (fabs.f64 re)))
(hypot.f64 (fabs.f64 im) (neg.f64 (neg.f64 re)))
(hypot.f64 (fabs.f64 im) (fabs.f64 (fabs.f64 re)))
(hypot.f64 (fabs.f64 im) (fabs.f64 re))
(hypot.f64 (fabs.f64 im) (neg.f64 re))
(hypot.f64 (fabs.f64 im) re)
(hypot.f64 (fabs.f64 re) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (fabs.f64 re) (neg.f64 (neg.f64 im)))
(hypot.f64 (fabs.f64 re) (neg.f64 (fabs.f64 im)))
(hypot.f64 (fabs.f64 re) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (fabs.f64 re) (neg.f64 im))
(hypot.f64 (fabs.f64 re) (fabs.f64 im))
(hypot.f64 (fabs.f64 re) im)
(hypot.f64 (neg.f64 re) (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 (neg.f64 re) (neg.f64 (neg.f64 im)))
(hypot.f64 (neg.f64 re) (neg.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 re) (fabs.f64 (fabs.f64 im)))
(hypot.f64 (neg.f64 re) (neg.f64 im))
(hypot.f64 (neg.f64 re) (fabs.f64 im))
(hypot.f64 (neg.f64 re) im)
(hypot.f64 im (pow.f64 re #s(literal 1 binary64)))
(hypot.f64 im (neg.f64 (fabs.f64 re)))
(hypot.f64 im (neg.f64 (neg.f64 re)))
(hypot.f64 im (fabs.f64 (fabs.f64 re)))
(hypot.f64 im (fabs.f64 re))
(hypot.f64 im (neg.f64 re))
(hypot.f64 im re)
(hypot.f64 re (pow.f64 im #s(literal 1 binary64)))
(hypot.f64 re (neg.f64 (neg.f64 im)))
(hypot.f64 re (neg.f64 (fabs.f64 im)))
(hypot.f64 re (fabs.f64 (fabs.f64 im)))
(hypot.f64 re (neg.f64 im))
(hypot.f64 re (fabs.f64 im))
(hypot.f64 re im)
(exp.f64 (*.f64 (log.f64 (fma.f64 re re (*.f64 im im))) #s(literal 1/2 binary64)))
(/.f64 (-.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 re #s(literal 4 binary64))) (-.f64 (*.f64 im im) (*.f64 re re)))
(/.f64 (-.f64 (pow.f64 re #s(literal 6 binary64)) (pow.f64 (*.f64 (neg.f64 im) im) #s(literal 3 binary64))) (+.f64 (pow.f64 re #s(literal 4 binary64)) (+.f64 (pow.f64 im #s(literal 4 binary64)) (*.f64 (*.f64 re re) (*.f64 (neg.f64 im) im)))))
(/.f64 (neg.f64 (-.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64)))) (neg.f64 (*.f64 (+.f64 re im) (-.f64 re im))))
(/.f64 (neg.f64 (+.f64 (pow.f64 im #s(literal 6 binary64)) (pow.f64 re #s(literal 6 binary64)))) (neg.f64 (+.f64 (-.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 (*.f64 re im) #s(literal 2 binary64))) (pow.f64 re #s(literal 4 binary64)))))
(/.f64 (-.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64))) (*.f64 (+.f64 re im) (-.f64 re im)))
(/.f64 (+.f64 (pow.f64 im #s(literal 6 binary64)) (pow.f64 re #s(literal 6 binary64))) (+.f64 (pow.f64 im #s(literal 4 binary64)) (-.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 (*.f64 re im) #s(literal 2 binary64)))))
(/.f64 (+.f64 (pow.f64 im #s(literal 6 binary64)) (pow.f64 re #s(literal 6 binary64))) (+.f64 (-.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 (*.f64 re im) #s(literal 2 binary64))) (pow.f64 re #s(literal 4 binary64))))
(fma.f64 (pow.f64 im #s(literal 1 binary64)) (pow.f64 im #s(literal 1 binary64)) (*.f64 re re))
(fma.f64 (pow.f64 re #s(literal 1 binary64)) (pow.f64 re #s(literal 1 binary64)) (*.f64 (neg.f64 (neg.f64 im)) im))
(fma.f64 (pow.f64 re #s(literal 1 binary64)) (pow.f64 re #s(literal 1 binary64)) (*.f64 im im))
(fma.f64 (neg.f64 (neg.f64 im)) (neg.f64 (neg.f64 im)) (*.f64 re re))
(fma.f64 (neg.f64 (fabs.f64 im)) (neg.f64 (fabs.f64 im)) (*.f64 re re))
(fma.f64 (neg.f64 (fabs.f64 re)) (neg.f64 (fabs.f64 re)) (*.f64 (neg.f64 (neg.f64 im)) im))
(fma.f64 (neg.f64 (fabs.f64 re)) (neg.f64 (fabs.f64 re)) (*.f64 im im))
(fma.f64 (neg.f64 (neg.f64 re)) (neg.f64 (neg.f64 re)) (*.f64 (neg.f64 (neg.f64 im)) im))
(fma.f64 (neg.f64 (neg.f64 re)) (neg.f64 (neg.f64 re)) (*.f64 im im))
(fma.f64 (fabs.f64 (fabs.f64 im)) (fabs.f64 (fabs.f64 im)) (*.f64 re re))
(fma.f64 (fabs.f64 (fabs.f64 re)) (fabs.f64 (fabs.f64 re)) (*.f64 (neg.f64 (neg.f64 im)) im))
(fma.f64 (fabs.f64 (fabs.f64 re)) (fabs.f64 (fabs.f64 re)) (*.f64 im im))
(fma.f64 (neg.f64 im) (neg.f64 im) (*.f64 re re))
(fma.f64 (fabs.f64 im) (fabs.f64 im) (*.f64 re re))
(fma.f64 (fabs.f64 re) (fabs.f64 re) (*.f64 (neg.f64 (neg.f64 im)) im))
(fma.f64 (fabs.f64 re) (fabs.f64 re) (*.f64 im im))
(fma.f64 (neg.f64 re) (neg.f64 re) (*.f64 (neg.f64 (neg.f64 im)) im))
(fma.f64 (neg.f64 re) (neg.f64 re) (*.f64 im im))
(fma.f64 im im (*.f64 re re))
(fma.f64 re re (*.f64 (neg.f64 (neg.f64 im)) im))
(fma.f64 re re (*.f64 im im))
(-.f64 (/.f64 (pow.f64 re #s(literal 4 binary64)) (*.f64 (+.f64 re im) (-.f64 re im))) (/.f64 (pow.f64 im #s(literal 4 binary64)) (*.f64 (+.f64 re im) (-.f64 re im))))
(-.f64 (*.f64 re re) (*.f64 (neg.f64 (neg.f64 im)) (neg.f64 im)))
(-.f64 (*.f64 re re) (*.f64 (neg.f64 (fabs.f64 im)) (fabs.f64 im)))
(-.f64 (*.f64 re re) (*.f64 (neg.f64 im) im))
(-.f64 (*.f64 im im) (*.f64 (neg.f64 (fabs.f64 re)) (fabs.f64 re)))
(-.f64 (*.f64 im im) (*.f64 (neg.f64 (neg.f64 re)) (neg.f64 re)))
(-.f64 (*.f64 im im) (*.f64 (neg.f64 re) re))
(-.f64 (*.f64 im im) (*.f64 re (neg.f64 re)))
(+.f64 (/.f64 (pow.f64 re #s(literal 6 binary64)) (+.f64 (-.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 (*.f64 re im) #s(literal 2 binary64))) (pow.f64 re #s(literal 4 binary64)))) (/.f64 (pow.f64 im #s(literal 6 binary64)) (+.f64 (-.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 (*.f64 re im) #s(literal 2 binary64))) (pow.f64 re #s(literal 4 binary64)))))
(+.f64 (*.f64 re re) (*.f64 (neg.f64 (neg.f64 im)) im))
(+.f64 (*.f64 re re) (*.f64 im im))
(+.f64 (*.f64 im im) (*.f64 re re))
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 re re) (/.f64 #s(literal 1/2 binary64) im) im))
(/.f64 (-.f64 (*.f64 im im) (pow.f64 (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re) #s(literal 2 binary64))) (-.f64 im (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)))
(/.f64 (neg.f64 (-.f64 (pow.f64 (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re) #s(literal 2 binary64)) (*.f64 im im))) (neg.f64 (-.f64 (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re) im)))
(/.f64 (neg.f64 (fma.f64 (pow.f64 (/.f64 #s(literal 1/2 binary64) im) #s(literal 3 binary64)) (pow.f64 re #s(literal 6 binary64)) (pow.f64 im #s(literal 3 binary64)))) (neg.f64 (fma.f64 im (-.f64 im (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)) (pow.f64 (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re) #s(literal 2 binary64)))))
(/.f64 (-.f64 (pow.f64 (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re) #s(literal 2 binary64)) (*.f64 im im)) (-.f64 (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re) im))
(/.f64 (fma.f64 (pow.f64 (/.f64 #s(literal 1/2 binary64) im) #s(literal 3 binary64)) (pow.f64 re #s(literal 6 binary64)) (pow.f64 im #s(literal 3 binary64))) (fma.f64 im im (-.f64 (pow.f64 (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re) #s(literal 2 binary64)) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) (*.f64 re im)))))
(/.f64 (fma.f64 (pow.f64 (/.f64 #s(literal 1/2 binary64) im) #s(literal 3 binary64)) (pow.f64 re #s(literal 6 binary64)) (pow.f64 im #s(literal 3 binary64))) (fma.f64 im (-.f64 im (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)) (pow.f64 (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re) #s(literal 2 binary64))))
(fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) (fabs.f64 re)) (fabs.f64 re) im)
(fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) (neg.f64 re)) (neg.f64 re) im)
(fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im)
(fma.f64 (fabs.f64 re) (*.f64 (fabs.f64 re) (/.f64 #s(literal 1/2 binary64) im)) im)
(fma.f64 (*.f64 re re) (/.f64 #s(literal 1/2 binary64) im) im)
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(fma.f64 #s(literal 1/2 binary64) (/.f64 (*.f64 re re) im) im)
(fma.f64 (neg.f64 re) (*.f64 (neg.f64 re) (/.f64 #s(literal 1/2 binary64) im)) im)
(fma.f64 re (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) im)
(-.f64 (/.f64 (pow.f64 (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re) #s(literal 2 binary64)) (-.f64 (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re) im)) (/.f64 (*.f64 im im) (-.f64 (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re) im)))
(-.f64 im (*.f64 (neg.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re)) re))
(-.f64 im (*.f64 (neg.f64 (*.f64 re re)) (/.f64 #s(literal 1/2 binary64) im)))
(-.f64 im (*.f64 (neg.f64 (/.f64 #s(literal 1/2 binary64) im)) (*.f64 re re)))
(+.f64 (/.f64 (*.f64 (pow.f64 (/.f64 #s(literal 1/2 binary64) im) #s(literal 3 binary64)) (pow.f64 re #s(literal 6 binary64))) (fma.f64 im (-.f64 im (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)) (pow.f64 (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re) #s(literal 2 binary64)))) (/.f64 (pow.f64 im #s(literal 3 binary64)) (fma.f64 im (-.f64 im (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)) (pow.f64 (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re) #s(literal 2 binary64)))))
(+.f64 (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re) im)
(+.f64 im (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re))
(/.f64 #s(literal -1/2 binary64) (neg.f64 im))
(/.f64 #s(literal 1/2 binary64) (neg.f64 (neg.f64 im)))
(/.f64 #s(literal 1/2 binary64) im)
(neg.f64 (/.f64 #s(literal -1/2 binary64) im))
(neg.f64 (/.f64 #s(literal 1/2 binary64) (neg.f64 im)))
(*.f64 (pow.f64 re #s(literal 1 binary64)) (pow.f64 re #s(literal 1 binary64)))
(*.f64 (neg.f64 (fabs.f64 re)) (neg.f64 (fabs.f64 re)))
(*.f64 (neg.f64 (neg.f64 re)) (neg.f64 (neg.f64 re)))
(*.f64 (fabs.f64 (fabs.f64 re)) (fabs.f64 (fabs.f64 re)))
(*.f64 (fabs.f64 re) (fabs.f64 re))
(*.f64 (neg.f64 re) (neg.f64 re))
(*.f64 re re)
(pow.f64 (fabs.f64 re) #s(literal 2 binary64))
(pow.f64 (neg.f64 re) #s(literal 2 binary64))
(pow.f64 re #s(literal 2 binary64))
(neg.f64 (*.f64 (neg.f64 re) re))
(neg.f64 (*.f64 re (neg.f64 re)))
(fabs.f64 (*.f64 re re))
(exp.f64 (*.f64 (log.f64 re) #s(literal 2 binary64)))

eval65.0ms (2.1%)

Memory
5.5MiB live, 70.5MiB allocated; 12ms collecting garbage
Compiler

Compiled 3 238 to 574 computations (82.3% saved)

prune6.0ms (0.2%)

Memory
16.3MiB live, 16.2MiB allocated; 0ms collecting garbage
Pruning

6 alts after pruning (2 fresh and 4 done)

PrunedKeptTotal
New2442246
Fresh000
Picked145
Done000
Total2456251
Accuracy
100.0%
Counts
251 → 6
Alt Table
Click to see full alt table
StatusAccuracyProgram
100.0%
(hypot.f64 re im)
62.7%
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
62.2%
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
99.6%
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im))
1.8%
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
3.9%
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))))
Compiler

Compiled 76 to 51 computations (32.9% saved)

simplify17.0ms (0.5%)

Memory
-35.3MiB live, 10.1MiB allocated; 5ms collecting garbage
Algorithm
egg-herbie
Localize:

Found 8 expressions of interest:

NewMetricScoreProgram
cost-diff0
(/.f64 #s(literal 1/2 binary64) im)
cost-diff0
(*.f64 (/.f64 #s(literal 1/2 binary64) im) re)
cost-diff0
(fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im)
cost-diff0
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im))
cost-diff0
(/.f64 (*.f64 re re) im)
cost-diff0
(*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))
cost-diff0
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64)))
cost-diff0
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))))
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
01997
02695
15195
213395
330495
452895
565395
666295
066285
Stop Event
iter limit
saturated
iter limit
Calls
Call 1
Inputs
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64)))
(*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))
(/.f64 (*.f64 re re) im)
(*.f64 re re)
re
im
#s(literal 1/2 binary64)
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im))
(fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im)
(*.f64 (/.f64 #s(literal 1/2 binary64) im) re)
(/.f64 #s(literal 1/2 binary64) im)
#s(literal 1/2 binary64)
im
re
Outputs
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 re im) (*.f64 #s(literal 1/2 binary64) re))))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64)))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 re im) (*.f64 #s(literal 1/2 binary64) re)))
(*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))
(*.f64 (/.f64 re im) (*.f64 #s(literal 1/2 binary64) re))
(/.f64 (*.f64 re re) im)
(*.f64 re re)
re
im
#s(literal 1/2 binary64)
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im))
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (/.f64 re im) (*.f64 #s(literal 1/2 binary64) re) im))
(fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im)
(fma.f64 (/.f64 re im) (*.f64 #s(literal 1/2 binary64) re) im)
(*.f64 (/.f64 #s(literal 1/2 binary64) im) re)
(/.f64 #s(literal 1/2 binary64) im)
#s(literal 1/2 binary64)
im
re

localize35.0ms (1.1%)

Memory
39.0MiB live, 39.0MiB allocated; 0ms collecting garbage
Localize:

Found 8 expressions of interest:

NewMetricScoreProgram
accuracy0.0
(fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im)
accuracy0.0
(/.f64 #s(literal 1/2 binary64) im)
accuracy0.2265625
(*.f64 (/.f64 #s(literal 1/2 binary64) im) re)
accuracy0.24891111047018818
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im))
accuracy0.0
(*.f64 re re)
accuracy0.24891111047018818
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))))
accuracy7.389555136764294
(/.f64 (*.f64 re re) im)
accuracy61.55891673594043
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64)))
Samples
27.0ms256×0valid
Compiler

Compiled 65 to 15 computations (76.9% saved)

Precisions
Click to see histograms. Total time spent on operations: 18.0ms
ival-mult: 7.0ms (39.8% of total)
ival-hypot: 5.0ms (28.4% of total)
ival-div: 3.0ms (17.1% of total)
ival-add: 2.0ms (11.4% of total)
ival-true: 0.0ms (0% of total)
adjust: 0.0ms (0% of total)
exact: 0.0ms (0% of total)
ival-assert: 0.0ms (0% of total)

series10.0ms (0.3%)

Memory
5.2MiB live, 5.2MiB allocated; 0ms collecting garbage
Counts
9 → 30
Calls
Call 1
Inputs
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64)))
(*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))
(/.f64 (*.f64 re re) im)
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im))
(fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im)
(*.f64 (/.f64 #s(literal 1/2 binary64) im) re)
(/.f64 #s(literal 1/2 binary64) im)
(*.f64 re re)
Outputs
im
(+ im (* 1/2 (/ (pow re 2) im)))
(+ im (* (pow re 2) (+ (* -1/8 (/ (pow re 2) (pow im 3))) (* 1/2 (/ 1 im)))))
(+ im (* (pow re 2) (+ (* (pow re 2) (- (* 1/16 (/ (pow re 2) (pow im 5))) (* 1/8 (/ 1 (pow im 3))))) (* 1/2 (/ 1 im)))))
(* 1/2 (/ (pow re 2) im))
(/ (pow re 2) im)
(* 1/2 (/ re im))
(pow re 2)
re
(* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2)))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2))))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* (pow re 2) (+ (* 1/2 (/ 1 im)) (/ im (pow re 2))))
(* -1 re)
(* -1 (* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2))))))))
(+ re (* 1/2 (/ (pow im 2) re)))
(+ re (* (pow im 2) (+ (* -1/8 (/ (pow im 2) (pow re 3))) (* 1/2 (/ 1 re)))))
(+ re (* (pow im 2) (+ (* (pow im 2) (- (* 1/16 (/ (pow im 2) (pow re 5))) (* 1/8 (/ 1 (pow re 3))))) (* 1/2 (/ 1 re)))))
(/ (+ (* 1/2 (pow re 2)) (pow im 2)) im)
(/ 1/2 im)
(* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2)))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2))))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* -1 im)
(* -1 (* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2))))))))
(* -1 (* im (- (* -1/2 (/ (pow re 2) (pow im 2))) 1)))
Calls

6 calls:

TimeVariablePointExpression
3.0ms
im
@inf
((sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (/ (* re re) im) 1/2) (/ (* re re) im) (sqrt (+ (* re re) (* im im))) (+ (* (* (/ 1/2 im) re) re) im) (* (/ 1/2 im) re) (/ 1/2 im) (* re re))
2.0ms
re
@inf
((sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (/ (* re re) im) 1/2) (/ (* re re) im) (sqrt (+ (* re re) (* im im))) (+ (* (* (/ 1/2 im) re) re) im) (* (/ 1/2 im) re) (/ 1/2 im) (* re re))
2.0ms
re
@-inf
((sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (/ (* re re) im) 1/2) (/ (* re re) im) (sqrt (+ (* re re) (* im im))) (+ (* (* (/ 1/2 im) re) re) im) (* (/ 1/2 im) re) (/ 1/2 im) (* re re))
1.0ms
im
@-inf
((sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (/ (* re re) im) 1/2) (/ (* re re) im) (sqrt (+ (* re re) (* im im))) (+ (* (* (/ 1/2 im) re) re) im) (* (/ 1/2 im) re) (/ 1/2 im) (* re re))
1.0ms
im
@0
((sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (/ (* re re) im) 1/2) (/ (* re re) im) (sqrt (+ (* re re) (* im im))) (+ (* (* (/ 1/2 im) re) re) im) (* (/ 1/2 im) re) (/ 1/2 im) (* re re))

simplify277.0ms (8.9%)

Memory
-27.3MiB live, 243.4MiB allocated; 44ms collecting garbage
Algorithm
egg-herbie
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
0113457
1332457
21346437
36764437
08626402
Stop Event
iter limit
node limit
Counts
30 → 28
Calls
Call 1
Inputs
im
(+ im (* 1/2 (/ (pow re 2) im)))
(+ im (* (pow re 2) (+ (* -1/8 (/ (pow re 2) (pow im 3))) (* 1/2 (/ 1 im)))))
(+ im (* (pow re 2) (+ (* (pow re 2) (- (* 1/16 (/ (pow re 2) (pow im 5))) (* 1/8 (/ 1 (pow im 3))))) (* 1/2 (/ 1 im)))))
(* 1/2 (/ (pow re 2) im))
(/ (pow re 2) im)
(* 1/2 (/ re im))
(pow re 2)
re
(* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2)))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2))))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* (pow re 2) (+ (* 1/2 (/ 1 im)) (/ im (pow re 2))))
(* -1 re)
(* -1 (* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2))))))))
(+ re (* 1/2 (/ (pow im 2) re)))
(+ re (* (pow im 2) (+ (* -1/8 (/ (pow im 2) (pow re 3))) (* 1/2 (/ 1 re)))))
(+ re (* (pow im 2) (+ (* (pow im 2) (- (* 1/16 (/ (pow im 2) (pow re 5))) (* 1/8 (/ 1 (pow re 3))))) (* 1/2 (/ 1 re)))))
(/ (+ (* 1/2 (pow re 2)) (pow im 2)) im)
(/ 1/2 im)
(* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2)))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2))))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* -1 im)
(* -1 (* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2))))))))
(* -1 (* im (- (* -1/2 (/ (pow re 2) (pow im 2))) 1)))
Outputs
im
(+ im (* 1/2 (/ (pow re 2) im)))
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(+ im (* (pow re 2) (+ (* -1/8 (/ (pow re 2) (pow im 3))) (* 1/2 (/ 1 im)))))
(fma.f64 (/.f64 (fma.f64 (/.f64 (/.f64 (*.f64 re re) im) im) #s(literal -1/8 binary64) #s(literal 1/2 binary64)) im) (*.f64 re re) im)
(+ im (* (pow re 2) (+ (* (pow re 2) (- (* 1/16 (/ (pow re 2) (pow im 5))) (* 1/8 (/ 1 (pow im 3))))) (* 1/2 (/ 1 im)))))
(fma.f64 (pow.f64 re #s(literal 4 binary64)) (fma.f64 (*.f64 #s(literal 1/16 binary64) re) (/.f64 re (pow.f64 im #s(literal 5 binary64))) (/.f64 #s(literal -1/8 binary64) (pow.f64 im #s(literal 3 binary64)))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
(* 1/2 (/ (pow re 2) im))
(*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))
(/ (pow re 2) im)
(/.f64 (*.f64 re re) im)
(* 1/2 (/ re im))
(*.f64 (/.f64 re im) #s(literal 1/2 binary64))
(pow re 2)
(*.f64 re re)
re
(* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2)))))
(fma.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) im) (/.f64 im (*.f64 re re)) re)
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2))))))
(*.f64 (fma.f64 (pow.f64 im #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 4 binary64))) (fma.f64 (/.f64 (*.f64 (/.f64 im re) #s(literal 1/2 binary64)) re) im #s(literal 1 binary64))) re)
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(*.f64 (fma.f64 (pow.f64 im #s(literal 6 binary64)) (/.f64 #s(literal 1/16 binary64) (pow.f64 re #s(literal 6 binary64))) (fma.f64 (pow.f64 im #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 4 binary64))) (fma.f64 (/.f64 (*.f64 (/.f64 im re) #s(literal 1/2 binary64)) re) im #s(literal 1 binary64)))) re)
(* (pow re 2) (+ (* 1/2 (/ 1 im)) (/ im (pow re 2))))
(*.f64 (*.f64 (-.f64 (/.f64 im (*.f64 re re)) (/.f64 #s(literal -1/2 binary64) im)) re) re)
(* -1 re)
(neg.f64 re)
(* -1 (* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2))))))
(*.f64 (fma.f64 (/.f64 #s(literal -1/2 binary64) re) (/.f64 (*.f64 im im) re) #s(literal -1 binary64)) re)
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(*.f64 (fma.f64 (/.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 re #s(literal 4 binary64))) #s(literal 1/8 binary64) (fma.f64 (/.f64 #s(literal -1/2 binary64) re) (/.f64 (*.f64 im im) re) #s(literal -1 binary64))) re)
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2))))))))
(*.f64 (neg.f64 re) (fma.f64 (pow.f64 im #s(literal 6 binary64)) (/.f64 #s(literal 1/16 binary64) (pow.f64 re #s(literal 6 binary64))) (fma.f64 (pow.f64 im #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 4 binary64))) (fma.f64 (/.f64 (*.f64 (/.f64 im re) #s(literal 1/2 binary64)) re) im #s(literal 1 binary64)))))
(+ re (* 1/2 (/ (pow im 2) re)))
(fma.f64 (/.f64 #s(literal 1/2 binary64) re) (*.f64 im im) re)
(+ re (* (pow im 2) (+ (* -1/8 (/ (pow im 2) (pow re 3))) (* 1/2 (/ 1 re)))))
(fma.f64 (/.f64 (fma.f64 (/.f64 (/.f64 #s(literal -1/8 binary64) re) re) (*.f64 im im) #s(literal 1/2 binary64)) re) (*.f64 im im) re)
(+ re (* (pow im 2) (+ (* (pow im 2) (- (* 1/16 (/ (pow im 2) (pow re 5))) (* 1/8 (/ 1 (pow re 3))))) (* 1/2 (/ 1 re)))))
(fma.f64 (fma.f64 (fma.f64 (*.f64 #s(literal 1/16 binary64) im) (/.f64 im (pow.f64 re #s(literal 5 binary64))) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 3 binary64)))) (*.f64 im im) (/.f64 #s(literal 1/2 binary64) re)) (*.f64 im im) re)
(/ (+ (* 1/2 (pow re 2)) (pow im 2)) im)
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(/ 1/2 im)
(/.f64 #s(literal 1/2 binary64) im)
(* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2)))))
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2))))))
(fma.f64 (*.f64 #s(literal -1/8 binary64) im) (/.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(fma.f64 (fma.f64 (pow.f64 re #s(literal 6 binary64)) (/.f64 #s(literal 1/16 binary64) (pow.f64 im #s(literal 6 binary64))) (fma.f64 (pow.f64 re #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 im #s(literal 4 binary64))) #s(literal 1 binary64))) im (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64)))
(* -1 im)
(neg.f64 im)
(* -1 (* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2))))))
(fma.f64 #s(literal -1/2 binary64) (/.f64 (*.f64 re re) im) (neg.f64 im))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(neg.f64 (fma.f64 (*.f64 #s(literal -1/8 binary64) im) (/.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2))))))))
(fma.f64 (fma.f64 (pow.f64 re #s(literal 6 binary64)) (/.f64 #s(literal 1/16 binary64) (pow.f64 im #s(literal 6 binary64))) (fma.f64 (pow.f64 re #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 im #s(literal 4 binary64))) #s(literal 1 binary64))) (neg.f64 im) (*.f64 #s(literal -1/2 binary64) (/.f64 (*.f64 re re) im)))
(* -1 (* im (- (* -1/2 (/ (pow re 2) (pow im 2))) 1)))
(neg.f64 (fma.f64 #s(literal -1/2 binary64) (/.f64 (*.f64 re re) im) (neg.f64 im)))

rewrite65.0ms (2.1%)

Memory
-7.9MiB live, 98.1MiB allocated; 15ms collecting garbage
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
01991
02689
19789
062079
Stop Event
iter limit
iter limit
node limit
iter limit
Counts
9 → 81
Calls
Call 1
Inputs
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64)))
(*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))
(/.f64 (*.f64 re re) im)
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im))
(fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im)
(*.f64 (/.f64 #s(literal 1/2 binary64) im) re)
(/.f64 #s(literal 1/2 binary64) im)
(*.f64 re re)
Outputs
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)))
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) (neg.f64 re)) (neg.f64 re))
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) (fabs.f64 re)) (fabs.f64 re))
(*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))
(*.f64 (neg.f64 re) (*.f64 (neg.f64 re) (/.f64 #s(literal 1/2 binary64) im)))
(*.f64 (fabs.f64 re) (*.f64 (fabs.f64 re) (/.f64 #s(literal 1/2 binary64) im)))
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)
(*.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re))
(*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))
(*.f64 #s(literal 1/2 binary64) (/.f64 (*.f64 re re) im))
(*.f64 (*.f64 re re) (/.f64 #s(literal 1/2 binary64) im))
(*.f64 re (*.f64 (/.f64 re im) #s(literal 1/2 binary64)))
(*.f64 re (*.f64 (/.f64 #s(literal 1/2 binary64) im) re))
(/.f64 (*.f64 (*.f64 (neg.f64 re) re) #s(literal 1/2 binary64)) (neg.f64 im))
(/.f64 (*.f64 #s(literal -1/2 binary64) (*.f64 re re)) (neg.f64 im))
(/.f64 (*.f64 #s(literal 1/2 binary64) (*.f64 (neg.f64 re) re)) (neg.f64 im))
(/.f64 (*.f64 (*.f64 re re) #s(literal -1/2 binary64)) (neg.f64 im))
(/.f64 (neg.f64 (*.f64 #s(literal 1/2 binary64) (*.f64 re re))) (neg.f64 im))
(/.f64 (*.f64 #s(literal 1/2 binary64) (*.f64 re re)) im)
(*.f64 (/.f64 re im) re)
(*.f64 (neg.f64 re) (/.f64 (neg.f64 re) im))
(*.f64 (fabs.f64 re) (/.f64 (fabs.f64 re) im))
(*.f64 re (/.f64 re im))
(/.f64 (*.f64 (neg.f64 re) re) (neg.f64 im))
(/.f64 (*.f64 re re) (neg.f64 (neg.f64 im)))
(/.f64 (*.f64 re re) im)
(neg.f64 (/.f64 (*.f64 (neg.f64 re) re) im))
(neg.f64 (/.f64 (*.f64 re re) (neg.f64 im)))
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im) im))
(/.f64 (-.f64 (*.f64 im im) (pow.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)) #s(literal 2 binary64))) (-.f64 im (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))))
(/.f64 (neg.f64 (-.f64 (pow.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)) #s(literal 2 binary64)) (*.f64 im im))) (neg.f64 (-.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)) im)))
(/.f64 (neg.f64 (fma.f64 (pow.f64 (/.f64 #s(literal 1/2 binary64) im) #s(literal 3 binary64)) (pow.f64 re #s(literal 6 binary64)) (pow.f64 im #s(literal 3 binary64)))) (neg.f64 (fma.f64 im (-.f64 im (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))) (pow.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)) #s(literal 2 binary64)))))
(/.f64 (-.f64 (pow.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)) #s(literal 2 binary64)) (*.f64 im im)) (-.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)) im))
(/.f64 (fma.f64 (pow.f64 (/.f64 #s(literal 1/2 binary64) im) #s(literal 3 binary64)) (pow.f64 re #s(literal 6 binary64)) (pow.f64 im #s(literal 3 binary64))) (fma.f64 im im (-.f64 (pow.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)) #s(literal 2 binary64)) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) (*.f64 re im)))))
(/.f64 (fma.f64 (pow.f64 (/.f64 #s(literal 1/2 binary64) im) #s(literal 3 binary64)) (pow.f64 re #s(literal 6 binary64)) (pow.f64 im #s(literal 3 binary64))) (fma.f64 im (-.f64 im (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))) (pow.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)) #s(literal 2 binary64))))
(fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) (neg.f64 re)) (neg.f64 re) im)
(fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) (fabs.f64 re)) (fabs.f64 re) im)
(fma.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im) im)
(fma.f64 (neg.f64 re) (*.f64 (neg.f64 re) (/.f64 #s(literal 1/2 binary64) im)) im)
(fma.f64 (fabs.f64 re) (*.f64 (fabs.f64 re) (/.f64 #s(literal 1/2 binary64) im)) im)
(fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im)
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(fma.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64) im)
(fma.f64 #s(literal 1/2 binary64) (/.f64 (*.f64 re re) im) im)
(fma.f64 (*.f64 re re) (/.f64 #s(literal 1/2 binary64) im) im)
(fma.f64 re (*.f64 (/.f64 re im) #s(literal 1/2 binary64)) im)
(fma.f64 re (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) im)
(-.f64 (/.f64 (pow.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)) #s(literal 2 binary64)) (-.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)) im)) (/.f64 (*.f64 im im) (-.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)) im)))
(-.f64 im (*.f64 (neg.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re)) re))
(-.f64 im (*.f64 (neg.f64 (/.f64 #s(literal 1/2 binary64) im)) (*.f64 re re)))
(-.f64 im (*.f64 (*.f64 (neg.f64 re) re) (/.f64 #s(literal 1/2 binary64) im)))
(-.f64 im (*.f64 (neg.f64 re) (*.f64 (/.f64 #s(literal 1/2 binary64) im) re)))
(+.f64 (/.f64 (*.f64 (pow.f64 (/.f64 #s(literal 1/2 binary64) im) #s(literal 3 binary64)) (pow.f64 re #s(literal 6 binary64))) (fma.f64 im (-.f64 im (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))) (pow.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)) #s(literal 2 binary64)))) (/.f64 (pow.f64 im #s(literal 3 binary64)) (fma.f64 im (-.f64 im (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))) (pow.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)) #s(literal 2 binary64)))))
(+.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)) im)
(+.f64 im (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)))
(*.f64 (/.f64 #s(literal 1/2 binary64) im) re)
(*.f64 #s(literal 1/2 binary64) (/.f64 re im))
(*.f64 re (/.f64 #s(literal 1/2 binary64) im))
(/.f64 (*.f64 #s(literal -1/2 binary64) re) (neg.f64 im))
(/.f64 (*.f64 re #s(literal -1/2 binary64)) (neg.f64 im))
(/.f64 (neg.f64 (*.f64 #s(literal 1/2 binary64) re)) (neg.f64 im))
(/.f64 (*.f64 #s(literal 1/2 binary64) re) im)
(/.f64 #s(literal -1/2 binary64) (neg.f64 im))
(/.f64 #s(literal 1/2 binary64) (neg.f64 (neg.f64 im)))
(/.f64 #s(literal 1/2 binary64) im)
(neg.f64 (/.f64 #s(literal -1/2 binary64) im))
(neg.f64 (/.f64 #s(literal 1/2 binary64) (neg.f64 im)))
(*.f64 (pow.f64 re #s(literal 1 binary64)) (pow.f64 re #s(literal 1 binary64)))
(*.f64 (neg.f64 (neg.f64 re)) (neg.f64 (neg.f64 re)))
(*.f64 (neg.f64 (fabs.f64 re)) (neg.f64 (fabs.f64 re)))
(*.f64 (fabs.f64 (fabs.f64 re)) (fabs.f64 (fabs.f64 re)))
(*.f64 (neg.f64 re) (neg.f64 re))
(*.f64 (fabs.f64 re) (fabs.f64 re))
(*.f64 re re)
(pow.f64 (neg.f64 re) #s(literal 2 binary64))
(pow.f64 (fabs.f64 re) #s(literal 2 binary64))
(pow.f64 re #s(literal 2 binary64))
(neg.f64 (*.f64 (neg.f64 re) re))
(fabs.f64 (*.f64 re re))
(exp.f64 (*.f64 (log.f64 re) #s(literal 2 binary64)))

eval12.0ms (0.4%)

Memory
35.2MiB live, 35.1MiB allocated; 0ms collecting garbage
Compiler

Compiled 2 773 to 432 computations (84.4% saved)

prune8.0ms (0.2%)

Memory
-28.7MiB live, 18.0MiB allocated; 2ms collecting garbage
Pruning

7 alts after pruning (2 fresh and 5 done)

PrunedKeptTotal
New1062108
Fresh000
Picked112
Done044
Total1077114
Accuracy
100.0%
Counts
114 → 7
Alt Table
Click to see full alt table
StatusAccuracyProgram
100.0%
(hypot.f64 re im)
62.7%
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
62.2%
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
99.6%
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im))
1.8%
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
3.8%
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))))
3.8%
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)))
Compiler

Compiled 102 to 67 computations (34.3% saved)

simplify12.0ms (0.4%)

Memory
13.2MiB live, 13.2MiB allocated; 0ms collecting garbage
Algorithm
egg-herbie
Localize:

Found 8 expressions of interest:

NewMetricScoreProgram
cost-diff0
(*.f64 (/.f64 re im) re)
cost-diff0
(*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))
cost-diff0
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64)))
cost-diff0
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))))
cost-diff0
(*.f64 (/.f64 #s(literal 1/2 binary64) im) re)
cost-diff0
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)
cost-diff0
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re))
cost-diff0
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)))
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
020122
026122
151122
2131122
3307122
4531122
5656122
6665122
0665108
Stop Event
iter limit
saturated
iter limit
Calls
Call 1
Inputs
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re))
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)
(*.f64 (/.f64 #s(literal 1/2 binary64) im) re)
(/.f64 #s(literal 1/2 binary64) im)
#s(literal 1/2 binary64)
im
re
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64)))
(*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))
(*.f64 (/.f64 re im) re)
(/.f64 re im)
re
im
#s(literal 1/2 binary64)
Outputs
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)))
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)
(*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))
(*.f64 (/.f64 #s(literal 1/2 binary64) im) re)
(/.f64 #s(literal 1/2 binary64) im)
#s(literal 1/2 binary64)
im
re
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64)))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)))
(*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))
(*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))
(*.f64 (/.f64 re im) re)
(/.f64 re im)
re
im
#s(literal 1/2 binary64)

localize40.0ms (1.3%)

Memory
3.3MiB live, 50.0MiB allocated; 1ms collecting garbage
Localize:

Found 8 expressions of interest:

NewMetricScoreProgram
accuracy0.0
(*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))
accuracy0.15234375
(*.f64 (/.f64 re im) re)
accuracy0.24891111047018818
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))))
accuracy61.55891673594043
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64)))
accuracy0.15234375
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)
accuracy0.2265625
(*.f64 (/.f64 #s(literal 1/2 binary64) im) re)
accuracy0.24891111047018818
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)))
accuracy61.55891673594043
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re))
Samples
31.0ms256×0valid
Compiler

Compiled 72 to 15 computations (79.2% saved)

Precisions
Click to see histograms. Total time spent on operations: 21.0ms
ival-mult: 11.0ms (51.8% of total)
ival-hypot: 5.0ms (23.5% of total)
ival-div: 3.0ms (14.1% of total)
ival-add: 1.0ms (4.7% of total)
ival-true: 0.0ms (0% of total)
adjust: 0.0ms (0% of total)
exact: 0.0ms (0% of total)
ival-assert: 0.0ms (0% of total)

series7.0ms (0.2%)

Memory
10.9MiB live, 10.9MiB allocated; 0ms collecting garbage
Counts
8 → 28
Calls
Call 1
Inputs
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re))
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)
(*.f64 (/.f64 #s(literal 1/2 binary64) im) re)
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64)))
(*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))
(*.f64 (/.f64 re im) re)
Outputs
im
(+ im (* 1/2 (/ (pow re 2) im)))
(+ im (* (pow re 2) (+ (* -1/8 (/ (pow re 2) (pow im 3))) (* 1/2 (/ 1 im)))))
(+ im (* (pow re 2) (+ (* (pow re 2) (- (* 1/16 (/ (pow re 2) (pow im 5))) (* 1/8 (/ 1 (pow im 3))))) (* 1/2 (/ 1 im)))))
(* 1/2 (/ (pow re 2) im))
(* 1/2 (/ re im))
(/ (pow re 2) im)
re
(* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2)))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2))))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* (pow re 2) (+ (* 1/2 (/ 1 im)) (/ im (pow re 2))))
(* -1 re)
(* -1 (* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2))))))))
(+ re (* 1/2 (/ (pow im 2) re)))
(+ re (* (pow im 2) (+ (* -1/8 (/ (pow im 2) (pow re 3))) (* 1/2 (/ 1 re)))))
(+ re (* (pow im 2) (+ (* (pow im 2) (- (* 1/16 (/ (pow im 2) (pow re 5))) (* 1/8 (/ 1 (pow re 3))))) (* 1/2 (/ 1 re)))))
(/ (+ (* 1/2 (pow re 2)) (pow im 2)) im)
(* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2)))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2))))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* -1 im)
(* -1 (* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2))))))))
(* -1 (* im (- (* -1/2 (/ (pow re 2) (pow im 2))) 1)))
Calls

6 calls:

TimeVariablePointExpression
1.0ms
re
@inf
((sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (* (/ 1/2 im) re) re) (* (/ 1/2 im) re) (sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (* (/ re im) re) 1/2) (* (/ re im) re))
1.0ms
re
@-inf
((sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (* (/ 1/2 im) re) re) (* (/ 1/2 im) re) (sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (* (/ re im) re) 1/2) (* (/ re im) re))
1.0ms
im
@-inf
((sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (* (/ 1/2 im) re) re) (* (/ 1/2 im) re) (sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (* (/ re im) re) 1/2) (* (/ re im) re))
1.0ms
im
@inf
((sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (* (/ 1/2 im) re) re) (* (/ 1/2 im) re) (sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (* (/ re im) re) 1/2) (* (/ re im) re))
1.0ms
re
@0
((sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (* (/ 1/2 im) re) re) (* (/ 1/2 im) re) (sqrt (+ (* re re) (* im im))) (+ (* (/ 1/2 im) (* re re)) im) (* (* (/ re im) re) 1/2) (* (/ re im) re))

simplify172.0ms (5.6%)

Memory
16.2MiB live, 199.5MiB allocated; 22ms collecting garbage
Algorithm
egg-herbie
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
0112451
1332451
21346431
36754431
08616396
Stop Event
iter limit
node limit
Counts
28 → 26
Calls
Call 1
Inputs
im
(+ im (* 1/2 (/ (pow re 2) im)))
(+ im (* (pow re 2) (+ (* -1/8 (/ (pow re 2) (pow im 3))) (* 1/2 (/ 1 im)))))
(+ im (* (pow re 2) (+ (* (pow re 2) (- (* 1/16 (/ (pow re 2) (pow im 5))) (* 1/8 (/ 1 (pow im 3))))) (* 1/2 (/ 1 im)))))
(* 1/2 (/ (pow re 2) im))
(* 1/2 (/ re im))
(/ (pow re 2) im)
re
(* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2)))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2))))))
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* (pow re 2) (+ (* 1/2 (/ 1 im)) (/ im (pow re 2))))
(* -1 re)
(* -1 (* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2))))))))
(+ re (* 1/2 (/ (pow im 2) re)))
(+ re (* (pow im 2) (+ (* -1/8 (/ (pow im 2) (pow re 3))) (* 1/2 (/ 1 re)))))
(+ re (* (pow im 2) (+ (* (pow im 2) (- (* 1/16 (/ (pow im 2) (pow re 5))) (* 1/8 (/ 1 (pow re 3))))) (* 1/2 (/ 1 re)))))
(/ (+ (* 1/2 (pow re 2)) (pow im 2)) im)
(* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2)))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2))))))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* -1 im)
(* -1 (* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2))))))))
(* -1 (* im (- (* -1/2 (/ (pow re 2) (pow im 2))) 1)))
Outputs
im
(+ im (* 1/2 (/ (pow re 2) im)))
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(+ im (* (pow re 2) (+ (* -1/8 (/ (pow re 2) (pow im 3))) (* 1/2 (/ 1 im)))))
(fma.f64 (/.f64 (fma.f64 (/.f64 (/.f64 (*.f64 re re) im) im) #s(literal -1/8 binary64) #s(literal 1/2 binary64)) im) (*.f64 re re) im)
(+ im (* (pow re 2) (+ (* (pow re 2) (- (* 1/16 (/ (pow re 2) (pow im 5))) (* 1/8 (/ 1 (pow im 3))))) (* 1/2 (/ 1 im)))))
(fma.f64 (pow.f64 re #s(literal 4 binary64)) (fma.f64 (*.f64 #s(literal 1/16 binary64) re) (/.f64 re (pow.f64 im #s(literal 5 binary64))) (/.f64 #s(literal -1/8 binary64) (pow.f64 im #s(literal 3 binary64)))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
(* 1/2 (/ (pow re 2) im))
(*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))
(* 1/2 (/ re im))
(*.f64 (/.f64 re im) #s(literal 1/2 binary64))
(/ (pow re 2) im)
(/.f64 (*.f64 re re) im)
re
(* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2)))))
(fma.f64 (*.f64 (*.f64 #s(literal 1/2 binary64) re) im) (/.f64 im (*.f64 re re)) re)
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2))))))
(*.f64 (fma.f64 (pow.f64 im #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 4 binary64))) (fma.f64 (/.f64 (*.f64 (/.f64 im re) #s(literal 1/2 binary64)) re) im #s(literal 1 binary64))) re)
(* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(*.f64 (fma.f64 (pow.f64 im #s(literal 6 binary64)) (/.f64 #s(literal 1/16 binary64) (pow.f64 re #s(literal 6 binary64))) (fma.f64 (pow.f64 im #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 4 binary64))) (fma.f64 (/.f64 (*.f64 (/.f64 im re) #s(literal 1/2 binary64)) re) im #s(literal 1 binary64)))) re)
(* (pow re 2) (+ (* 1/2 (/ 1 im)) (/ im (pow re 2))))
(*.f64 (*.f64 (-.f64 (/.f64 im (*.f64 re re)) (/.f64 #s(literal -1/2 binary64) im)) re) re)
(* -1 re)
(neg.f64 re)
(* -1 (* re (+ 1 (* 1/2 (/ (pow im 2) (pow re 2))))))
(*.f64 (fma.f64 (/.f64 #s(literal -1/2 binary64) re) (/.f64 (*.f64 im im) re) #s(literal -1 binary64)) re)
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (* 1/2 (/ (pow im 2) (pow re 2)))))))
(*.f64 (fma.f64 (/.f64 (pow.f64 im #s(literal 4 binary64)) (pow.f64 re #s(literal 4 binary64))) #s(literal 1/8 binary64) (fma.f64 (/.f64 #s(literal -1/2 binary64) re) (/.f64 (*.f64 im im) re) #s(literal -1 binary64))) re)
(* -1 (* re (+ 1 (+ (* -1/8 (/ (pow im 4) (pow re 4))) (+ (* 1/16 (/ (pow im 6) (pow re 6))) (* 1/2 (/ (pow im 2) (pow re 2))))))))
(*.f64 (neg.f64 re) (fma.f64 (pow.f64 im #s(literal 6 binary64)) (/.f64 #s(literal 1/16 binary64) (pow.f64 re #s(literal 6 binary64))) (fma.f64 (pow.f64 im #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 4 binary64))) (fma.f64 (/.f64 (*.f64 (/.f64 im re) #s(literal 1/2 binary64)) re) im #s(literal 1 binary64)))))
(+ re (* 1/2 (/ (pow im 2) re)))
(fma.f64 (/.f64 #s(literal 1/2 binary64) re) (*.f64 im im) re)
(+ re (* (pow im 2) (+ (* -1/8 (/ (pow im 2) (pow re 3))) (* 1/2 (/ 1 re)))))
(fma.f64 (/.f64 (fma.f64 (/.f64 (/.f64 #s(literal -1/8 binary64) re) re) (*.f64 im im) #s(literal 1/2 binary64)) re) (*.f64 im im) re)
(+ re (* (pow im 2) (+ (* (pow im 2) (- (* 1/16 (/ (pow im 2) (pow re 5))) (* 1/8 (/ 1 (pow re 3))))) (* 1/2 (/ 1 re)))))
(fma.f64 (fma.f64 (fma.f64 (*.f64 #s(literal 1/16 binary64) im) (/.f64 im (pow.f64 re #s(literal 5 binary64))) (/.f64 #s(literal -1/8 binary64) (pow.f64 re #s(literal 3 binary64)))) (*.f64 im im) (/.f64 #s(literal 1/2 binary64) re)) (*.f64 im im) re)
(/ (+ (* 1/2 (pow re 2)) (pow im 2)) im)
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2)))))
(fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2))))))
(fma.f64 (*.f64 #s(literal -1/8 binary64) im) (/.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
(* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(fma.f64 (fma.f64 (pow.f64 re #s(literal 6 binary64)) (/.f64 #s(literal 1/16 binary64) (pow.f64 im #s(literal 6 binary64))) (fma.f64 (pow.f64 re #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 im #s(literal 4 binary64))) #s(literal 1 binary64))) im (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64)))
(* -1 im)
(neg.f64 im)
(* -1 (* im (+ 1 (* 1/2 (/ (pow re 2) (pow im 2))))))
(fma.f64 #s(literal -1/2 binary64) (/.f64 (*.f64 re re) im) (neg.f64 im))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (* 1/2 (/ (pow re 2) (pow im 2)))))))
(neg.f64 (fma.f64 (*.f64 #s(literal -1/8 binary64) im) (/.f64 (pow.f64 re #s(literal 4 binary64)) (pow.f64 im #s(literal 4 binary64))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im)))
(* -1 (* im (+ 1 (+ (* -1/8 (/ (pow re 4) (pow im 4))) (+ (* 1/16 (/ (pow re 6) (pow im 6))) (* 1/2 (/ (pow re 2) (pow im 2))))))))
(fma.f64 (fma.f64 (pow.f64 re #s(literal 6 binary64)) (/.f64 #s(literal 1/16 binary64) (pow.f64 im #s(literal 6 binary64))) (fma.f64 (pow.f64 re #s(literal 4 binary64)) (/.f64 #s(literal -1/8 binary64) (pow.f64 im #s(literal 4 binary64))) #s(literal 1 binary64))) (neg.f64 im) (*.f64 #s(literal -1/2 binary64) (/.f64 (*.f64 re re) im)))
(* -1 (* im (- (* -1/2 (/ (pow re 2) (pow im 2))) 1)))
(neg.f64 (fma.f64 #s(literal -1/2 binary64) (/.f64 (*.f64 re re) im) (neg.f64 im)))

rewrite78.0ms (2.5%)

Memory
-33.6MiB live, 25.6MiB allocated; 23ms collecting garbage
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
020110
026110
183110
060196
Stop Event
iter limit
iter limit
node limit
iter limit
Counts
8 → 57
Calls
Call 1
Inputs
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re))
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)
(*.f64 (/.f64 #s(literal 1/2 binary64) im) re)
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64)))
(*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))
(*.f64 (/.f64 re im) re)
Outputs
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)))
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) (neg.f64 re)) (neg.f64 re))
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) (fabs.f64 re)) (fabs.f64 re))
(*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))
(*.f64 (neg.f64 re) (*.f64 (neg.f64 re) (/.f64 #s(literal 1/2 binary64) im)))
(*.f64 (fabs.f64 re) (*.f64 (fabs.f64 re) (/.f64 #s(literal 1/2 binary64) im)))
(*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))
(*.f64 (/.f64 re im) (*.f64 #s(literal 1/2 binary64) re))
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)
(*.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re))
(*.f64 #s(literal 1/2 binary64) (*.f64 (/.f64 re im) re))
(*.f64 (*.f64 re re) (/.f64 #s(literal 1/2 binary64) im))
(*.f64 re (*.f64 (/.f64 re im) #s(literal 1/2 binary64)))
(*.f64 re (*.f64 (/.f64 #s(literal 1/2 binary64) im) re))
(/.f64 (*.f64 #s(literal -1/2 binary64) (*.f64 re re)) (neg.f64 im))
(/.f64 (*.f64 (neg.f64 re) (*.f64 #s(literal 1/2 binary64) re)) (neg.f64 im))
(/.f64 (*.f64 (*.f64 re re) #s(literal -1/2 binary64)) (neg.f64 im))
(/.f64 (*.f64 re (*.f64 #s(literal 1/2 binary64) re)) im)
(/.f64 (neg.f64 (*.f64 #s(literal 1/2 binary64) (*.f64 re re))) (neg.f64 im))
(/.f64 (*.f64 #s(literal 1/2 binary64) (*.f64 re re)) im)
(*.f64 (/.f64 #s(literal 1/2 binary64) im) re)
(*.f64 #s(literal 1/2 binary64) (/.f64 re im))
(*.f64 re (/.f64 #s(literal 1/2 binary64) im))
(/.f64 (*.f64 #s(literal -1/2 binary64) re) (neg.f64 im))
(/.f64 (*.f64 re #s(literal -1/2 binary64)) (neg.f64 im))
(/.f64 (neg.f64 (*.f64 #s(literal 1/2 binary64) re)) (neg.f64 im))
(/.f64 (*.f64 #s(literal 1/2 binary64) re) im)
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))))
#s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im)))
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) (neg.f64 re)) (neg.f64 re))
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) (fabs.f64 re)) (fabs.f64 re))
(*.f64 (*.f64 #s(literal 1/2 binary64) re) (/.f64 re im))
(*.f64 (neg.f64 re) (*.f64 (neg.f64 re) (/.f64 #s(literal 1/2 binary64) im)))
(*.f64 (fabs.f64 re) (*.f64 (fabs.f64 re) (/.f64 #s(literal 1/2 binary64) im)))
(*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))
(*.f64 (/.f64 re im) (*.f64 #s(literal 1/2 binary64) re))
(*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)
(*.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re))
(*.f64 #s(literal 1/2 binary64) (*.f64 (/.f64 re im) re))
(*.f64 (*.f64 re re) (/.f64 #s(literal 1/2 binary64) im))
(*.f64 re (*.f64 (/.f64 re im) #s(literal 1/2 binary64)))
(*.f64 re (*.f64 (/.f64 #s(literal 1/2 binary64) im) re))
(/.f64 (*.f64 #s(literal -1/2 binary64) (*.f64 re re)) (neg.f64 im))
(/.f64 (*.f64 (neg.f64 re) (*.f64 #s(literal 1/2 binary64) re)) (neg.f64 im))
(/.f64 (*.f64 (*.f64 re re) #s(literal -1/2 binary64)) (neg.f64 im))
(/.f64 (*.f64 re (*.f64 #s(literal 1/2 binary64) re)) im)
(/.f64 (neg.f64 (*.f64 #s(literal 1/2 binary64) (*.f64 re re))) (neg.f64 im))
(/.f64 (*.f64 #s(literal 1/2 binary64) (*.f64 re re)) im)
(*.f64 (neg.f64 re) (/.f64 (neg.f64 re) im))
(*.f64 (fabs.f64 re) (/.f64 (fabs.f64 re) im))
(*.f64 (/.f64 re im) re)
(*.f64 re (/.f64 re im))
(/.f64 (*.f64 (neg.f64 re) re) (neg.f64 im))
(/.f64 (*.f64 re (neg.f64 re)) (neg.f64 im))
(/.f64 (neg.f64 (*.f64 re re)) (neg.f64 im))
(/.f64 (*.f64 re re) im)

eval7.0ms (0.2%)

Memory
9.8MiB live, 9.8MiB allocated; 0ms collecting garbage
Compiler

Compiled 1 659 to 268 computations (83.8% saved)

prune6.0ms (0.2%)

Memory
8.6MiB live, 8.6MiB allocated; 0ms collecting garbage
Pruning

7 alts after pruning (0 fresh and 7 done)

PrunedKeptTotal
New61061
Fresh000
Picked022
Done055
Total61768
Accuracy
100.0%
Counts
68 → 7
Alt Table
Click to see full alt table
StatusAccuracyProgram
100.0%
(hypot.f64 re im)
62.7%
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
62.2%
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
99.6%
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im))
1.8%
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
3.8%
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))))
3.8%
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)))
Compiler

Compiled 255 to 107 computations (58% saved)

regimes27.0ms (0.9%)

Memory
-22.0MiB live, 24.9MiB allocated; 3ms collecting garbage
Counts
10 → 1
Calls
Call 1
Inputs
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))))
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im))
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
(hypot.f64 re im)
Outputs
(hypot.f64 re im)
Calls

6 calls:

5.0ms
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
3.0ms
re
3.0ms
im
3.0ms
(*.f64 im im)
3.0ms
(+.f64 (*.f64 re re) (*.f64 im im))
Results
AccuracySegmentsBranch
100.0%1(*.f64 im im)
100.0%1(*.f64 re re)
100.0%1(+.f64 (*.f64 re re) (*.f64 im im))
100.0%1(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
100.0%1re
100.0%1im
Compiler

Compiled 23 to 21 computations (8.7% saved)

regimes17.0ms (0.6%)

Memory
23.1MiB live, 23.1MiB allocated; 0ms collecting garbage
Counts
9 → 1
Calls
Call 1
Inputs
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))))
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im))
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (/.f64 #s(literal 1/2 binary64) im) (*.f64 re re) im))
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
Outputs
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im))
Calls

6 calls:

3.0ms
re
3.0ms
im
3.0ms
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
3.0ms
(*.f64 im im)
3.0ms
(+.f64 (*.f64 re re) (*.f64 im im))
Results
AccuracySegmentsBranch
99.6%1(*.f64 im im)
99.6%1(*.f64 re re)
99.6%1(+.f64 (*.f64 re re) (*.f64 im im))
99.6%1(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
99.6%1re
99.6%1im
Compiler

Compiled 23 to 21 computations (8.7% saved)

regimes36.0ms (1.2%)

Memory
-27.0MiB live, 19.6MiB allocated; 3ms collecting garbage
Counts
6 → 1
Calls
Call 1
Inputs
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))))
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
Outputs
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
Calls

6 calls:

24.0ms
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
2.0ms
im
2.0ms
re
2.0ms
(+.f64 (*.f64 re re) (*.f64 im im))
2.0ms
(*.f64 im im)
Results
AccuracySegmentsBranch
62.7%1(*.f64 im im)
62.7%1(*.f64 re re)
62.7%1(+.f64 (*.f64 re re) (*.f64 im im))
62.7%1(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
62.7%1re
62.7%1im
Compiler

Compiled 23 to 21 computations (8.7% saved)

regimes12.0ms (0.4%)

Memory
17.5MiB live, 17.5MiB allocated; 0ms collecting garbage
Counts
5 → 1
Calls
Call 1
Inputs
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re)))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (*.f64 (/.f64 re im) re) #s(literal 1/2 binary64))))
#s(approx (sqrt (+ (* re re) (* im im))) #s(approx (+ (* (/ 1/2 im) (* re re)) im) (*.f64 (/.f64 (*.f64 re re) im) #s(literal 1/2 binary64))))
Outputs
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
Calls

6 calls:

2.0ms
im
2.0ms
re
2.0ms
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
2.0ms
(+.f64 (*.f64 re re) (*.f64 im im))
2.0ms
(*.f64 im im)
Results
AccuracySegmentsBranch
62.2%1(*.f64 re re)
62.2%1re
62.2%1(*.f64 im im)
62.2%1(+.f64 (*.f64 re re) (*.f64 im im))
62.2%1(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
62.2%1im
Compiler

Compiled 23 to 21 computations (8.7% saved)

regimes6.0ms (0.2%)

Memory
12.0MiB live, 12.0MiB allocated; 0ms collecting garbage
Accuracy

Total -0.0b remaining (-0%)

Threshold costs -0b (-0%)

Counts
1 → 1
Calls
Call 1
Inputs
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
Outputs
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
Calls

6 calls:

1.0ms
im
1.0ms
(*.f64 im im)
1.0ms
re
1.0ms
(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
1.0ms
(+.f64 (*.f64 re re) (*.f64 im im))
Results
AccuracySegmentsBranch
1.8%1(*.f64 re re)
1.8%1re
1.8%1(*.f64 im im)
1.8%1(+.f64 (*.f64 re re) (*.f64 im im))
1.8%1(sqrt.f64 (+.f64 (*.f64 re re) (*.f64 im im)))
1.8%1im
Compiler

Compiled 23 to 21 computations (8.7% saved)

simplify41.0ms (1.3%)

Memory
-34.5MiB live, 12.4MiB allocated; 2ms collecting garbage
Algorithm
egg-herbie
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
01950
13450
27450
313150
416850
Stop Event
saturated
Calls
Call 1
Inputs
(hypot.f64 re im)
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im))
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))
Outputs
(hypot.f64 re im)
#s(approx (sqrt (+ (* re re) (* im im))) (fma.f64 (*.f64 (/.f64 #s(literal 1/2 binary64) im) re) re im))
(sqrt.f64 (fma.f64 re re (*.f64 im im)))
(sqrt.f64 #s(approx (+ (* re re) (* im im)) (*.f64 im im)))
#s(approx (sqrt (+ (* re re) (* im im))) (neg.f64 re))

derivations300.0ms (9.7%)

Memory
30.0MiB live, 168.6MiB allocated; 20ms collecting garbage
Iterations

Useful iterations: 0 (0.0ms)

IterNodesCost
0104441
1323441
21323435
36816435
08219396
0621
01021
13921
034615
01970
02870
17670
056670
Stop Event
done
iter limit
iter limit
node limit
iter limit
iter limit
iter limit
iter limit
unsound
iter limit
iter limit
node limit
Compiler

Compiled 50 to 19 computations (62% saved)

preprocess45.0ms (1.4%)

Memory
-23.9MiB live, 22.0MiB allocated; 4ms collecting garbage
Remove

(sort re im)

(abs re)

(abs im)

Compiler

Compiled 134 to 68 computations (49.3% saved)

end0.0ms (0%)

Memory
0.0MiB live, 0.0MiB allocated; 0ms collecting garbage

Profiling

Loading profile data...