bug333 (missed optimization)

Time bar (total: 1.9s)

start0.0ms (0%)

Memory
0.0MiB live, 0.0MiB allocated

analyze0.0ms (0%)

Memory
0.3MiB live, 0.3MiB allocated
Algorithm
search
Search
ProbabilityValidUnknownPreconditionInfiniteDomainCan'tIter
0%0%50%50%0%0%0%0
100%50%0%50%0%0%0%1
Compiler

Compiled 17 to 12 computations (29.4% saved)

sample1.5s (81%)

Memory
-14.7MiB live, 1 854.9MiB allocated
Samples
586.0ms4 839×1valid
578.0ms3 161×2valid
13.0ms256×0valid
Precisions
Click to see histograms. Total time spent on operations: 929.0ms
ival-sqrt: 296.0ms (31.9% of total)
adjust: 238.0ms (25.6% of total)
ival-sub: 182.0ms (19.6% of total)
ival-add: 141.0ms (15.2% of total)
ival-<=: 48.0ms (5.2% of total)
ival-and: 11.0ms (1.2% of total)
exact: 10.0ms (1.1% of total)
ival-assert: 3.0ms (0.3% of total)
Bogosity

explain131.0ms (6.9%)

Memory
-4.4MiB live, 172.2MiB allocated
FPErrors
Click to see full error table
Ground TruthOverpredictionsExampleUnderpredictionsExampleSubexpression
2550-0-(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
00-0-(sqrt.f64 (+.f64 #s(literal 1 binary64) x))
00-0-(+.f64 #s(literal 1 binary64) x)
00-0-(-.f64 #s(literal 1 binary64) x)
00-0-#s(literal 1 binary64)
00-0-(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
00-0-x
Explanations
Click to see full explanations table
OperatorSubexpressionExplanationCount
-.f64(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))cancellation2550
Confusion
Predicted +Predicted -
+2550
-01
Precision
1.0
Recall
1.0
Confusion?
Predicted +Predicted MaybePredicted -
+25500
-001
Precision?
1.0
Recall?
1.0
Freqs
test
numberfreq
01
1255
Total Confusion?
Predicted +Predicted MaybePredicted -
+100
-000
Precision?
1.0
Recall?
1.0
Samples
39.0ms312×1valid
36.0ms190×2valid
1.0ms10×0valid
Compiler

Compiled 88 to 32 computations (63.6% saved)

Precisions
Click to see histograms. Total time spent on operations: 51.0ms
ival-sqrt: 17.0ms (33.2% of total)
adjust: 13.0ms (25.4% of total)
ival-sub: 12.0ms (23.4% of total)
ival-add: 8.0ms (15.6% of total)
ival-assert: 0.0ms (0% of total)
ival-true: 0.0ms (0% of total)
exact: 0.0ms (0% of total)

preprocess2.0ms (0.1%)

Memory
3.0MiB live, 3.0MiB allocated
Algorithm
egg-herbie
Calls
Call 1
Inputs
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
Outputs
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
Compiler

Compiled 9 to 7 computations (22.2% saved)

eval0.0ms (0%)

Memory
0.1MiB live, 0.1MiB allocated
Compiler

Compiled 0 to 1 computations (-∞% saved)

prune0.0ms (0%)

Memory
0.6MiB live, 0.6MiB allocated
Alt Table
Click to see full alt table
StatusAccuracyProgram
7.1%
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
Compiler

Compiled 9 to 7 computations (22.2% saved)

simplify0.0ms (0%)

Memory
0.5MiB live, 0.5MiB allocated
Algorithm
egg-herbie
Localize:

Found 4 expressions of interest:

NewMetricScoreProgram
cost-diff0
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
cost-diff0
(+.f64 #s(literal 1 binary64) x)
cost-diff0
(sqrt.f64 (+.f64 #s(literal 1 binary64) x))
cost-diff0
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
Calls
Call 1
Inputs
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
(sqrt.f64 (+.f64 #s(literal 1 binary64) x))
(+.f64 #s(literal 1 binary64) x)
#s(literal 1 binary64)
x
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
(-.f64 #s(literal 1 binary64) x)
Outputs
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
(sqrt.f64 (+.f64 #s(literal 1 binary64) x))
(+.f64 #s(literal 1 binary64) x)
#s(literal 1 binary64)
x
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
(-.f64 #s(literal 1 binary64) x)

localize65.0ms (3.4%)

Memory
15.1MiB live, 51.0MiB allocated
Localize:

Found 4 expressions of interest:

NewMetricScoreProgram
accuracy0.0
(+.f64 #s(literal 1 binary64) x)
accuracy0.0
(sqrt.f64 (+.f64 #s(literal 1 binary64) x))
accuracy0.00390625
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
accuracy59.46320209457001
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
Samples
33.0ms156×1valid
21.0ms95×2valid
0.0ms0valid
Compiler

Compiled 52 to 16 computations (69.2% saved)

Precisions
Click to see histograms. Total time spent on operations: 41.0ms
ival-sub: 15.0ms (36.5% of total)
ival-sqrt: 13.0ms (31.7% of total)
adjust: 8.0ms (19.5% of total)
ival-add: 4.0ms (9.7% of total)
ival-assert: 0.0ms (0% of total)
ival-true: 0.0ms (0% of total)
exact: 0.0ms (0% of total)

series11.0ms (0.6%)

Memory
-31.1MiB live, 5.3MiB allocated
Counts
4 → 37
Calls
Call 1
Inputs
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
(sqrt.f64 (+.f64 #s(literal 1 binary64) x))
(+.f64 #s(literal 1 binary64) x)
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
Outputs
x
(* x (+ 1 (* 1/8 (pow x 2))))
(* x (+ 1 (* (pow x 2) (+ 1/8 (* 7/128 (pow x 2))))))
(* x (+ 1 (* (pow x 2) (+ 1/8 (* (pow x 2) (+ 7/128 (* 33/1024 (pow x 2))))))))
1
(+ 1 (* 1/2 x))
(+ 1 (* x (+ 1/2 (* -1/8 x))))
(+ 1 (* x (+ 1/2 (* x (- (* 1/16 x) 1/8)))))
(+ 1 x)
(+ 1 (* -1/2 x))
(+ 1 (* x (- (* -1/8 x) 1/2)))
(+ 1 (* x (- (* x (- (* -1/16 x) 1/8)) 1/2)))
(* x (- (sqrt (/ 1 x)) (* (sqrt (/ 1 x)) (sqrt -1))))
(* x (- (+ (sqrt (/ 1 x)) (* 1/2 (sqrt (/ 1 (pow x 3))))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* x (- (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (* 1/2 (sqrt (/ 1 (pow x 3)))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* x (- (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (+ (* 1/16 (sqrt (/ 1 (pow x 7)))) (* 1/2 (sqrt (/ 1 (pow x 3))))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 5)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
(sqrt x)
(* x (+ (sqrt (/ 1 x)) (* 1/2 (sqrt (/ 1 (pow x 3))))))
(* x (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (* 1/2 (sqrt (/ 1 (pow x 3)))))))
(* x (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (+ (* 1/16 (sqrt (/ 1 (pow x 7)))) (* 1/2 (sqrt (/ 1 (pow x 3))))))))
(* x (+ 1 (/ 1 x)))
(* (sqrt x) (sqrt -1))
(* x (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1))))
(* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 5)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* -1 (* x (- (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* -1 (* x (- (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* -1 (* x (- (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
(* -1 (* x (- (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 4)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))))
(* -1 (* (sqrt x) (pow (sqrt -1) 2)))
(* -1 (* x (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)))))
(* -1 (* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2))))))
(* -1 (* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 4)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)))))))
(* -1 (* (sqrt x) (sqrt -1)))
(* -1 (* x (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* -1 (* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* -1 (* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
Calls

3 calls:

TimeVariablePointExpression
8.0ms
x
@inf
((- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt (+ 1 x)) (+ 1 x) (sqrt (- 1 x)))
2.0ms
x
@-inf
((- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt (+ 1 x)) (+ 1 x) (sqrt (- 1 x)))
1.0ms
x
@0
((- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt (+ 1 x)) (+ 1 x) (sqrt (- 1 x)))

simplify1.0ms (0%)

Memory
1.1MiB live, 1.1MiB allocated
Algorithm
egg-herbie
Counts
37 → 4
Calls
Call 1
Inputs
x
(* x (+ 1 (* 1/8 (pow x 2))))
(* x (+ 1 (* (pow x 2) (+ 1/8 (* 7/128 (pow x 2))))))
(* x (+ 1 (* (pow x 2) (+ 1/8 (* (pow x 2) (+ 7/128 (* 33/1024 (pow x 2))))))))
1
(+ 1 (* 1/2 x))
(+ 1 (* x (+ 1/2 (* -1/8 x))))
(+ 1 (* x (+ 1/2 (* x (- (* 1/16 x) 1/8)))))
(+ 1 x)
(+ 1 (* -1/2 x))
(+ 1 (* x (- (* -1/8 x) 1/2)))
(+ 1 (* x (- (* x (- (* -1/16 x) 1/8)) 1/2)))
(* x (- (sqrt (/ 1 x)) (* (sqrt (/ 1 x)) (sqrt -1))))
(* x (- (+ (sqrt (/ 1 x)) (* 1/2 (sqrt (/ 1 (pow x 3))))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* x (- (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (* 1/2 (sqrt (/ 1 (pow x 3)))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* x (- (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (+ (* 1/16 (sqrt (/ 1 (pow x 7)))) (* 1/2 (sqrt (/ 1 (pow x 3))))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 5)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
(sqrt x)
(* x (+ (sqrt (/ 1 x)) (* 1/2 (sqrt (/ 1 (pow x 3))))))
(* x (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (* 1/2 (sqrt (/ 1 (pow x 3)))))))
(* x (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (+ (* 1/16 (sqrt (/ 1 (pow x 7)))) (* 1/2 (sqrt (/ 1 (pow x 3))))))))
(* x (+ 1 (/ 1 x)))
(* (sqrt x) (sqrt -1))
(* x (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1))))
(* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 5)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* -1 (* x (- (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* -1 (* x (- (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* -1 (* x (- (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
(* -1 (* x (- (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 4)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))))
(* -1 (* (sqrt x) (pow (sqrt -1) 2)))
(* -1 (* x (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)))))
(* -1 (* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2))))))
(* -1 (* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 4)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)))))))
(* -1 (* (sqrt x) (sqrt -1)))
(* -1 (* x (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* -1 (* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* -1 (* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
Outputs
x
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
(* x (+ 1 (* 1/8 (pow x 2))))
(sqrt.f64 (+.f64 #s(literal 1 binary64) x))
(* x (+ 1 (* (pow x 2) (+ 1/8 (* 7/128 (pow x 2))))))
(+.f64 #s(literal 1 binary64) x)
(* x (+ 1 (* (pow x 2) (+ 1/8 (* (pow x 2) (+ 7/128 (* 33/1024 (pow x 2))))))))
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))

rewrite0.0ms (0%)

Memory
0.5MiB live, 0.5MiB allocated
Counts
4 → 4
Calls
Call 1
Inputs
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
(sqrt.f64 (+.f64 #s(literal 1 binary64) x))
(+.f64 #s(literal 1 binary64) x)
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
Outputs
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
(sqrt.f64 (+.f64 #s(literal 1 binary64) x))
(+.f64 #s(literal 1 binary64) x)
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))

eval1.0ms (0%)

Memory
1.2MiB live, 1.2MiB allocated
Compiler

Compiled 96 to 17 computations (82.3% saved)

prune1.0ms (0.1%)

Memory
2.0MiB live, 2.0MiB allocated
Pruning

3 alts after pruning (2 fresh and 1 done)

PrunedKeptTotal
New628
Fresh000
Picked011
Done000
Total639
Accuracy
7.6%
Counts
9 → 3
Alt Table
Click to see full alt table
StatusAccuracyProgram
7.1%
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
3.6%
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
3.6%
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
Compiler

Compiled 36 to 28 computations (22.2% saved)

simplify0.0ms (0%)

Memory
0.6MiB live, 0.6MiB allocated
Algorithm
egg-herbie
Localize:

Found 5 expressions of interest:

NewMetricScoreProgram
cost-diff0
(+.f64 #s(literal 1 binary64) x)
cost-diff0
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
cost-diff0
(-.f64 #s(literal 1 binary64) x)
cost-diff0
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
cost-diff0
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
Calls
Call 1
Inputs
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
(-.f64 #s(literal 1 binary64) x)
#s(literal 1 binary64)
x
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
(+.f64 #s(literal 1 binary64) x)
#s(literal 1 binary64)
x
Outputs
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
(-.f64 #s(literal 1 binary64) x)
#s(literal 1 binary64)
x
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
(+.f64 #s(literal 1 binary64) x)
#s(literal 1 binary64)
x

localize48.0ms (2.5%)

Memory
5.8MiB live, 42.9MiB allocated
Localize:

Found 5 expressions of interest:

NewMetricScoreProgram
accuracy0.0
(+.f64 #s(literal 1 binary64) x)
accuracy61.69285527184973
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
accuracy0.0
(-.f64 #s(literal 1 binary64) x)
accuracy0.00390625
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
accuracy61.692857547357804
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
Samples
21.0ms95×2valid
18.0ms156×1valid
0.0ms0valid
Compiler

Compiled 75 to 22 computations (70.7% saved)

Precisions
Click to see histograms. Total time spent on operations: 28.0ms
ival-sqrt: 12.0ms (42.9% of total)
adjust: 6.0ms (21.4% of total)
ival-sub: 5.0ms (17.9% of total)
ival-add: 3.0ms (10.7% of total)
ival-assert: 0.0ms (0% of total)
ival-true: 0.0ms (0% of total)
exact: 0.0ms (0% of total)

series2.0ms (0.1%)

Memory
1.8MiB live, 1.8MiB allocated
Counts
5 → 30
Calls
Call 1
Inputs
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
(-.f64 #s(literal 1 binary64) x)
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
(+.f64 #s(literal 1 binary64) x)
Outputs
x
(* x (+ 1 (* 1/8 (pow x 2))))
(* x (+ 1 (* (pow x 2) (+ 1/8 (* 7/128 (pow x 2))))))
(* x (+ 1 (* (pow x 2) (+ 1/8 (* (pow x 2) (+ 7/128 (* 33/1024 (pow x 2))))))))
1
(+ 1 (* -1/2 x))
(+ 1 (* x (- (* -1/8 x) 1/2)))
(+ 1 (* x (- (* x (- (* -1/16 x) 1/8)) 1/2)))
(+ 1 (* -1 x))
(+ 1 x)
(* x (- (sqrt (/ 1 x)) (* (sqrt (/ 1 x)) (sqrt -1))))
(* x (- (+ (sqrt (/ 1 x)) (* 1/2 (sqrt (/ 1 (pow x 3))))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* x (- (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (* 1/2 (sqrt (/ 1 (pow x 3)))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* x (- (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (+ (* 1/16 (sqrt (/ 1 (pow x 7)))) (* 1/2 (sqrt (/ 1 (pow x 3))))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 5)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
(* (sqrt x) (sqrt -1))
(* x (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1))))
(* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 5)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* -1 x)
(* x (- (/ 1 x) 1))
(* x (+ 1 (/ 1 x)))
(* -1 (* x (- (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* -1 (* x (- (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* -1 (* x (- (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
(* -1 (* x (- (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 4)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))))
(* -1 (* (sqrt x) (sqrt -1)))
(* -1 (* x (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* -1 (* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* -1 (* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
(* -1 (* x (- 1 (/ 1 x))))
Calls

3 calls:

TimeVariablePointExpression
0.0ms
x
@-inf
((- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt (- 1 x)) (- 1 x) (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+ 1 x))
0.0ms
x
@inf
((- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt (- 1 x)) (- 1 x) (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+ 1 x))
0.0ms
x
@0
((- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt (- 1 x)) (- 1 x) (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+ 1 x))

simplify1.0ms (0%)

Memory
0.8MiB live, 0.8MiB allocated
Algorithm
egg-herbie
Counts
30 → 5
Calls
Call 1
Inputs
x
(* x (+ 1 (* 1/8 (pow x 2))))
(* x (+ 1 (* (pow x 2) (+ 1/8 (* 7/128 (pow x 2))))))
(* x (+ 1 (* (pow x 2) (+ 1/8 (* (pow x 2) (+ 7/128 (* 33/1024 (pow x 2))))))))
1
(+ 1 (* -1/2 x))
(+ 1 (* x (- (* -1/8 x) 1/2)))
(+ 1 (* x (- (* x (- (* -1/16 x) 1/8)) 1/2)))
(+ 1 (* -1 x))
(+ 1 x)
(* x (- (sqrt (/ 1 x)) (* (sqrt (/ 1 x)) (sqrt -1))))
(* x (- (+ (sqrt (/ 1 x)) (* 1/2 (sqrt (/ 1 (pow x 3))))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* x (- (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (* 1/2 (sqrt (/ 1 (pow x 3)))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* x (- (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (+ (* 1/16 (sqrt (/ 1 (pow x 7)))) (* 1/2 (sqrt (/ 1 (pow x 3))))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 5)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
(* (sqrt x) (sqrt -1))
(* x (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1))))
(* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 5)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* -1 x)
(* x (- (/ 1 x) 1))
(* x (+ 1 (/ 1 x)))
(* -1 (* x (- (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* -1 (* x (- (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* -1 (* x (- (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
(* -1 (* x (- (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 4)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))))
(* -1 (* (sqrt x) (sqrt -1)))
(* -1 (* x (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* -1 (* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* -1 (* x (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
(* -1 (* x (- 1 (/ 1 x))))
Outputs
x
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
(* x (+ 1 (* 1/8 (pow x 2))))
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
(* x (+ 1 (* (pow x 2) (+ 1/8 (* 7/128 (pow x 2))))))
(-.f64 #s(literal 1 binary64) x)
(* x (+ 1 (* (pow x 2) (+ 1/8 (* (pow x 2) (+ 7/128 (* 33/1024 (pow x 2))))))))
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
1
(+.f64 #s(literal 1 binary64) x)

rewrite0.0ms (0%)

Memory
0.5MiB live, 0.5MiB allocated
Counts
5 → 5
Calls
Call 1
Inputs
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
(-.f64 #s(literal 1 binary64) x)
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
(+.f64 #s(literal 1 binary64) x)
Outputs
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
(sqrt.f64 (-.f64 #s(literal 1 binary64) x))
(-.f64 #s(literal 1 binary64) x)
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
(+.f64 #s(literal 1 binary64) x)

eval1.0ms (0.1%)

Memory
1.5MiB live, 1.5MiB allocated
Compiler

Compiled 146 to 18 computations (87.7% saved)

prune2.0ms (0.1%)

Memory
2.9MiB live, 2.9MiB allocated
Pruning

3 alts after pruning (1 fresh and 2 done)

PrunedKeptTotal
New819
Fresh000
Picked112
Done011
Total9312
Accuracy
7.6%
Counts
12 → 3
Alt Table
Click to see full alt table
StatusAccuracyProgram
7.1%
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
3.6%
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (-.f64 #s(literal 1 binary64) x))
3.6%
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
Compiler

Compiled 35 to 27 computations (22.9% saved)

simplify0.0ms (0%)

Memory
0.5MiB live, 0.5MiB allocated
Algorithm
egg-herbie
Localize:

Found 2 expressions of interest:

NewMetricScoreProgram
cost-diff0
(-.f64 #s(literal 1 binary64) x)
cost-diff0
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (-.f64 #s(literal 1 binary64) x))
Calls
Call 1
Inputs
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (-.f64 #s(literal 1 binary64) x))
(-.f64 #s(literal 1 binary64) x)
#s(literal 1 binary64)
x
Outputs
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (-.f64 #s(literal 1 binary64) x))
(-.f64 #s(literal 1 binary64) x)
#s(literal 1 binary64)
x

localize46.0ms (2.4%)

Memory
5.3MiB live, 48.8MiB allocated
Localize:

Found 2 expressions of interest:

NewMetricScoreProgram
accuracy0.0
(-.f64 #s(literal 1 binary64) x)
accuracy61.69285803191179
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (-.f64 #s(literal 1 binary64) x))
Samples
22.0ms95×2valid
17.0ms156×1valid
0.0ms0valid
Compiler

Compiled 34 to 19 computations (44.1% saved)

Precisions
Click to see histograms. Total time spent on operations: 30.0ms
ival-add: 10.0ms (33.1% of total)
ival-sqrt: 8.0ms (26.5% of total)
adjust: 6.0ms (19.8% of total)
ival-sub: 5.0ms (16.5% of total)
ival-assert: 0.0ms (0% of total)
ival-true: 0.0ms (0% of total)
exact: 0.0ms (0% of total)

series1.0ms (0.1%)

Memory
1.9MiB live, 1.9MiB allocated
Counts
2 → 17
Calls
Call 1
Inputs
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (-.f64 #s(literal 1 binary64) x))
(-.f64 #s(literal 1 binary64) x)
Outputs
x
(* x (+ 1 (* 1/8 (pow x 2))))
(* x (+ 1 (* (pow x 2) (+ 1/8 (* 7/128 (pow x 2))))))
(* x (+ 1 (* (pow x 2) (+ 1/8 (* (pow x 2) (+ 7/128 (* 33/1024 (pow x 2))))))))
1
(+ 1 (* -1 x))
(* x (- (sqrt (/ 1 x)) (* (sqrt (/ 1 x)) (sqrt -1))))
(* x (- (+ (sqrt (/ 1 x)) (* 1/2 (sqrt (/ 1 (pow x 3))))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* x (- (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (* 1/2 (sqrt (/ 1 (pow x 3)))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* x (- (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (+ (* 1/16 (sqrt (/ 1 (pow x 7)))) (* 1/2 (sqrt (/ 1 (pow x 3))))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 5)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
(* -1 x)
(* x (- (/ 1 x) 1))
(* -1 (* x (- (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* -1 (* x (- (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* -1 (* x (- (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
(* -1 (* x (- (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 4)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))))
(* -1 (* x (- 1 (/ 1 x))))
Calls

3 calls:

TimeVariablePointExpression
0.0ms
x
@inf
((- (sqrt (+ 1 x)) (sqrt (- 1 x))) (- 1 x))
0.0ms
x
@-inf
((- (sqrt (+ 1 x)) (sqrt (- 1 x))) (- 1 x))
0.0ms
x
@0
((- (sqrt (+ 1 x)) (sqrt (- 1 x))) (- 1 x))

simplify1.0ms (0%)

Memory
0.9MiB live, 0.9MiB allocated
Algorithm
egg-herbie
Counts
17 → 2
Calls
Call 1
Inputs
x
(* x (+ 1 (* 1/8 (pow x 2))))
(* x (+ 1 (* (pow x 2) (+ 1/8 (* 7/128 (pow x 2))))))
(* x (+ 1 (* (pow x 2) (+ 1/8 (* (pow x 2) (+ 7/128 (* 33/1024 (pow x 2))))))))
1
(+ 1 (* -1 x))
(* x (- (sqrt (/ 1 x)) (* (sqrt (/ 1 x)) (sqrt -1))))
(* x (- (+ (sqrt (/ 1 x)) (* 1/2 (sqrt (/ 1 (pow x 3))))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* x (- (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (* 1/2 (sqrt (/ 1 (pow x 3)))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* x (- (+ (sqrt (/ 1 x)) (+ (* -1/8 (sqrt (/ 1 (pow x 5)))) (+ (* 1/16 (sqrt (/ 1 (pow x 7)))) (* 1/2 (sqrt (/ 1 (pow x 3))))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 3)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 5)))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (/ 1 (sqrt -1)))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
(* -1 x)
(* x (- (/ 1 x) 1))
(* -1 (* x (- (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)) (* (sqrt (/ 1 x)) (sqrt -1)))))
(* -1 (* x (- (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))
(* -1 (* x (- (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2)))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1)))))))
(* -1 (* x (- (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (/ 1 (pow (sqrt -1) 2)))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (/ 1 (pow (sqrt -1) 4)))) (+ (* 1/2 (sqrt (/ 1 (pow x 3)))) (* (sqrt (/ 1 x)) (pow (sqrt -1) 2))))) (+ (* -1/8 (* (sqrt (/ 1 (pow x 5))) (sqrt -1))) (+ (* 1/16 (* (sqrt (/ 1 (pow x 7))) (sqrt -1))) (+ (* 1/2 (* (sqrt (/ 1 (pow x 3))) (sqrt -1))) (* (sqrt (/ 1 x)) (sqrt -1))))))))
(* -1 (* x (- 1 (/ 1 x))))
Outputs
x
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (-.f64 #s(literal 1 binary64) x))
(* x (+ 1 (* 1/8 (pow x 2))))
(-.f64 #s(literal 1 binary64) x)

rewrite0.0ms (0%)

Memory
0.7MiB live, 0.7MiB allocated
Counts
2 → 2
Calls
Call 1
Inputs
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (-.f64 #s(literal 1 binary64) x))
(-.f64 #s(literal 1 binary64) x)
Outputs
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (-.f64 #s(literal 1 binary64) x))
(-.f64 #s(literal 1 binary64) x)

eval0.0ms (0%)

Memory
0.9MiB live, 0.9MiB allocated
Compiler

Compiled 49 to 11 computations (77.6% saved)

prune2.0ms (0.1%)

Memory
4.5MiB live, 4.5MiB allocated
Pruning

3 alts after pruning (0 fresh and 3 done)

PrunedKeptTotal
New303
Fresh000
Picked011
Done022
Total336
Accuracy
7.6%
Counts
6 → 3
Alt Table
Click to see full alt table
StatusAccuracyProgram
7.1%
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
3.6%
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (-.f64 #s(literal 1 binary64) x))
3.6%
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
Compiler

Compiled 84 to 43 computations (48.8% saved)

regimes5.0ms (0.3%)

Memory
-30.4MiB live, 8.3MiB allocated
Counts
4 → 1
Calls
Call 1
Inputs
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (-.f64 #s(literal 1 binary64) x))
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
Outputs
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
Calls

2 calls:

3.0ms
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
2.0ms
x
Results
AccuracySegmentsBranch
7.1%1x
7.1%1(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
Compiler

Compiled 10 to 8 computations (20% saved)

regimes3.0ms (0.2%)

Memory
9.6MiB live, 9.6MiB allocated
Accuracy

Total -0.0b remaining (-0%)

Threshold costs -0b (-0%)

Counts
3 → 1
Calls
Call 1
Inputs
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (-.f64 #s(literal 1 binary64) x))
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
Outputs
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
Calls

2 calls:

2.0ms
x
1.0ms
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
Results
AccuracySegmentsBranch
3.6%1x
3.6%1(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
Compiler

Compiled 10 to 8 computations (20% saved)

simplify5.0ms (0.2%)

Memory
12.9MiB live, 12.9MiB allocated
Algorithm
egg-herbie
Calls
Call 1
Inputs
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))
Outputs
(-.f64 (sqrt.f64 (+.f64 #s(literal 1 binary64) x)) (sqrt.f64 (-.f64 #s(literal 1 binary64) x)))
#s(approx (- (sqrt (+ 1 x)) (sqrt (- 1 x))) (+.f64 #s(literal 1 binary64) x))

soundness0.0ms (0%)

Memory
1.3MiB live, 1.3MiB allocated
Stop Event
done
Compiler

Compiled 22 to 14 computations (36.4% saved)

preprocess27.0ms (1.4%)

Memory
-25.9MiB live, 51.7MiB allocated
Compiler

Compiled 88 to 62 computations (29.5% saved)

end0.0ms (0%)

Memory
0.0MiB live, 0.0MiB allocated

Profiling

Loading profile data...