cos2 (problem 3.4.1)

Time bar (total: 1.9s)

start0.0ms (0%)

Memory
0.0MiB live, 0.0MiB allocated

analyze1.0ms (0.1%)

Memory
1.3MiB live, 1.3MiB allocated
Algorithm
search
Search
ProbabilityValidUnknownPreconditionInfiniteDomainCan'tIter
0%0%100%0%0%0%0%0
0%0%100%0%0%0%0%1
50%50%50%0%0%0%0%2
75%75%25%0%0%0%0%3
87.5%87.5%12.5%0%0%0%0%4
93.8%93.7%6.2%0%0%0%0%5
96.9%96.8%3.1%0%0%0%0%6
98.4%98.4%1.6%0%0%0%0%7
99.2%99.2%0.8%0%0%0%0%8
99.6%99.6%0.4%0%0%0%0%9
99.8%99.8%0.2%0%0%0%0%10
99.9%99.9%0.1%0%0%0%0%11
100%99.9%0%0%0%0%0%12
Compiler

Compiled 10 to 8 computations (20% saved)

sample1.5s (77.4%)

Memory
65.5MiB live, 1 133.3MiB allocated
Samples
596.0ms2 264×2valid
323.0ms4 157×0valid
198.0ms577×3valid
132.0ms1 258×1valid
Precisions
Click to see histograms. Total time spent on operations: 1.0s
ival-cos: 684.0ms (65.7% of total)
ival-div: 99.0ms (9.5% of total)
adjust: 97.0ms (9.3% of total)
ival-sub: 84.0ms (8.1% of total)
ival-mult: 61.0ms (5.9% of total)
ival-true: 6.0ms (0.6% of total)
exact: 5.0ms (0.5% of total)
ival-assert: 3.0ms (0.3% of total)
Bogosity

explain129.0ms (6.6%)

Memory
-8.6MiB live, 112.4MiB allocated
FPErrors
Click to see full error table
Ground TruthOverpredictionsExampleUnderpredictionsExampleSubexpression
721(1.0062900105500921e+36)1(-8.260084990238072e+145)(-.f64 #s(literal 1 binary64) (cos.f64 x))
612(-2.7727536760449067e+161)2(-3.6646562051866966e-156)(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
00-0-#s(literal 1 binary64)
00-0-(cos.f64 x)
00-0-(*.f64 x x)
00-0-x
Explanations
Click to see full explanations table
OperatorSubexpressionExplanationCount
-.f64(-.f64 #s(literal 1 binary64) (cos.f64 x))cancellation722
/.f64(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))u/u540
(-.f64 #s(literal 1 binary64) (cos.f64 x))underflow54
(*.f64 x x)underflow54
/.f64(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))n/o70
(*.f64 x x)overflow69
Confusion
Predicted +Predicted -
+1281
-5122
Precision
0.9624060150375939
Recall
0.9922480620155039
Confusion?
Predicted +Predicted MaybePredicted -
+12810
-51121
Precision?
0.9555555555555556
Recall?
1.0
Freqs
test
numberfreq
0123
1133
Total Confusion?
Predicted +Predicted MaybePredicted -
+100
-000
Precision?
1.0
Recall?
1.0
Samples
33.0ms124×2valid
29.0ms270×0valid
11.0ms34×3valid
9.0ms84×1valid
Compiler

Compiled 69 to 28 computations (59.4% saved)

Precisions
Click to see histograms. Total time spent on operations: 66.0ms
ival-cos: 45.0ms (68.5% of total)
adjust: 6.0ms (9.1% of total)
ival-div: 5.0ms (7.6% of total)
ival-sub: 5.0ms (7.6% of total)
ival-mult: 4.0ms (6.1% 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
2.8MiB live, 2.8MiB allocated
Algorithm
egg-herbie
Calls
Call 1
Inputs
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
Outputs
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
Compiler

Compiled 8 to 6 computations (25% saved)

eval0.0ms (0%)

Memory
0.1MiB live, 0.1MiB allocated
Compiler

Compiled 0 to 1 computations (-∞% saved)

prune0.0ms (0%)

Memory
0.5MiB live, 0.5MiB allocated
Alt Table
Click to see full alt table
StatusAccuracyProgram
52.1%
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
Compiler

Compiled 8 to 6 computations (25% saved)

simplify0.0ms (0%)

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

Found 4 expressions of interest:

NewMetricScoreProgram
cost-diff0
(*.f64 x x)
cost-diff0
(cos.f64 x)
cost-diff0
(-.f64 #s(literal 1 binary64) (cos.f64 x))
cost-diff0
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
Calls
Call 1
Inputs
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
(-.f64 #s(literal 1 binary64) (cos.f64 x))
#s(literal 1 binary64)
(cos.f64 x)
x
(*.f64 x x)
Outputs
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
(-.f64 #s(literal 1 binary64) (cos.f64 x))
#s(literal 1 binary64)
(cos.f64 x)
x
(*.f64 x x)

localize46.0ms (2.3%)

Memory
-1.2MiB live, 36.6MiB allocated
Localize:

Found 4 expressions of interest:

NewMetricScoreProgram
accuracy0.0
(*.f64 x x)
accuracy0.0
(cos.f64 x)
accuracy14.035061389727238
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
accuracy15.725532592442665
(-.f64 #s(literal 1 binary64) (cos.f64 x))
Samples
16.0ms62×2valid
10.0ms135×0valid
8.0ms17×3valid
4.0ms42×1valid
Compiler

Compiled 40 to 14 computations (65% saved)

Precisions
Click to see histograms. Total time spent on operations: 31.0ms
ival-cos: 21.0ms (68.1% of total)
ival-div: 3.0ms (9.7% of total)
adjust: 3.0ms (9.7% of total)
ival-mult: 2.0ms (6.5% of total)
ival-sub: 2.0ms (6.5% of total)
ival-assert: 0.0ms (0% of total)
ival-true: 0.0ms (0% of total)
exact: 0.0ms (0% of total)

series3.0ms (0.1%)

Memory
2.8MiB live, 2.8MiB allocated
Counts
4 → 16
Calls
Call 1
Inputs
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
(-.f64 #s(literal 1 binary64) (cos.f64 x))
(cos.f64 x)
(*.f64 x x)
Outputs
1/2
(+ 1/2 (* -1/24 (pow x 2)))
(+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24)))
(+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24)))
(* 1/2 (pow x 2))
(* (pow x 2) (+ 1/2 (* -1/24 (pow x 2))))
(* (pow x 2) (+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24))))
(* (pow x 2) (+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24))))
1
(+ 1 (* -1/2 (pow x 2)))
(+ 1 (* (pow x 2) (- (* 1/24 (pow x 2)) 1/2)))
(+ 1 (* (pow x 2) (- (* (pow x 2) (+ 1/24 (* -1/720 (pow x 2)))) 1/2)))
(pow x 2)
(/ (- 1 (cos x)) (pow x 2))
(- 1 (cos x))
(cos x)
Calls

3 calls:

TimeVariablePointExpression
1.0ms
x
@-inf
((/ (- 1 (cos x)) (* x x)) (- 1 (cos x)) (cos x) (* x x))
1.0ms
x
@0
((/ (- 1 (cos x)) (* x x)) (- 1 (cos x)) (cos x) (* x x))
1.0ms
x
@inf
((/ (- 1 (cos x)) (* x x)) (- 1 (cos x)) (cos x) (* x x))

simplify0.0ms (0%)

Memory
0.5MiB live, 0.5MiB allocated
Algorithm
egg-herbie
Counts
16 → 4
Calls
Call 1
Inputs
1/2
(+ 1/2 (* -1/24 (pow x 2)))
(+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24)))
(+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24)))
(* 1/2 (pow x 2))
(* (pow x 2) (+ 1/2 (* -1/24 (pow x 2))))
(* (pow x 2) (+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24))))
(* (pow x 2) (+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24))))
1
(+ 1 (* -1/2 (pow x 2)))
(+ 1 (* (pow x 2) (- (* 1/24 (pow x 2)) 1/2)))
(+ 1 (* (pow x 2) (- (* (pow x 2) (+ 1/24 (* -1/720 (pow x 2)))) 1/2)))
(pow x 2)
(/ (- 1 (cos x)) (pow x 2))
(- 1 (cos x))
(cos x)
Outputs
1/2
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
(+ 1/2 (* -1/24 (pow x 2)))
(-.f64 #s(literal 1 binary64) (cos.f64 x))
(+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24)))
(cos.f64 x)
(+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24)))
(*.f64 x x)

rewrite0.0ms (0%)

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

eval1.0ms (0%)

Memory
1.1MiB live, 1.1MiB allocated
Compiler

Compiled 85 to 15 computations (82.4% saved)

prune2.0ms (0.1%)

Memory
2.2MiB live, 2.2MiB allocated
Pruning

4 alts after pruning (3 fresh and 1 done)

PrunedKeptTotal
New538
Fresh000
Picked011
Done000
Total549
Accuracy
60.2%
Counts
9 → 4
Alt Table
Click to see full alt table
StatusAccuracyProgram
52.1%
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
3.6%
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
3.3%
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
10.7%
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
Compiler

Compiled 44 to 32 computations (27.3% saved)

simplify0.0ms (0%)

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

Found 7 expressions of interest:

NewMetricScoreProgram
cost-diff0
(cos.f64 x)
cost-diff0
(-.f64 #s(literal 1 binary64) (cos.f64 x))
cost-diff0
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
cost-diff0
(*.f64 x x)
cost-diff0
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
cost-diff0
(cos.f64 x)
cost-diff0
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
Calls
Call 1
Inputs
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
(cos.f64 x)
x
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
(*.f64 x x)
x
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
(-.f64 #s(literal 1 binary64) (cos.f64 x))
#s(literal 1 binary64)
(cos.f64 x)
x
Outputs
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
(cos.f64 x)
x
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
(*.f64 x x)
x
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
(-.f64 #s(literal 1 binary64) (cos.f64 x))
#s(literal 1 binary64)
(cos.f64 x)
x

localize48.0ms (2.5%)

Memory
1.7MiB live, 39.6MiB allocated
Localize:

Found 7 expressions of interest:

NewMetricScoreProgram
accuracy0.0
(cos.f64 x)
accuracy15.725532592442665
(-.f64 #s(literal 1 binary64) (cos.f64 x))
accuracy61.388251516586145
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
accuracy0.0
(*.f64 x x)
accuracy61.911408015743696
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
accuracy0.0
(cos.f64 x)
accuracy57.1587659210607
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
Samples
19.0ms62×2valid
11.0ms135×0valid
6.0ms17×3valid
5.0ms42×1valid
Compiler

Compiled 92 to 21 computations (77.2% saved)

Precisions
Click to see histograms. Total time spent on operations: 30.0ms
ival-cos: 20.0ms (65.7% of total)
ival-div: 3.0ms (9.9% of total)
adjust: 3.0ms (9.9% of total)
ival-mult: 2.0ms (6.6% of total)
ival-sub: 2.0ms (6.6% 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.9MiB live, 1.9MiB allocated
Counts
6 → 16
Calls
Call 1
Inputs
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
(cos.f64 x)
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
(*.f64 x x)
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
(-.f64 #s(literal 1 binary64) (cos.f64 x))
Outputs
1/2
(+ 1/2 (* -1/24 (pow x 2)))
(+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24)))
(+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24)))
1
(+ 1 (* -1/2 (pow x 2)))
(+ 1 (* (pow x 2) (- (* 1/24 (pow x 2)) 1/2)))
(+ 1 (* (pow x 2) (- (* (pow x 2) (+ 1/24 (* -1/720 (pow x 2)))) 1/2)))
(pow x 2)
(* 1/2 (pow x 2))
(* (pow x 2) (+ 1/2 (* -1/24 (pow x 2))))
(* (pow x 2) (+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24))))
(* (pow x 2) (+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24))))
(/ (- 1 (cos x)) (pow x 2))
(cos x)
(- 1 (cos x))
Calls

3 calls:

TimeVariablePointExpression
1.0ms
x
@inf
((/ (- 1 (cos x)) (* x x)) (cos x) (/ (- 1 (cos x)) (* x x)) (* x x) (/ (- 1 (cos x)) (* x x)) (- 1 (cos x)))
1.0ms
x
@-inf
((/ (- 1 (cos x)) (* x x)) (cos x) (/ (- 1 (cos x)) (* x x)) (* x x) (/ (- 1 (cos x)) (* x x)) (- 1 (cos x)))
0.0ms
x
@0
((/ (- 1 (cos x)) (* x x)) (cos x) (/ (- 1 (cos x)) (* x x)) (* x x) (/ (- 1 (cos x)) (* x x)) (- 1 (cos x)))

simplify0.0ms (0%)

Memory
0.4MiB live, 0.4MiB allocated
Algorithm
egg-herbie
Counts
16 → 6
Calls
Call 1
Inputs
1/2
(+ 1/2 (* -1/24 (pow x 2)))
(+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24)))
(+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24)))
1
(+ 1 (* -1/2 (pow x 2)))
(+ 1 (* (pow x 2) (- (* 1/24 (pow x 2)) 1/2)))
(+ 1 (* (pow x 2) (- (* (pow x 2) (+ 1/24 (* -1/720 (pow x 2)))) 1/2)))
(pow x 2)
(* 1/2 (pow x 2))
(* (pow x 2) (+ 1/2 (* -1/24 (pow x 2))))
(* (pow x 2) (+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24))))
(* (pow x 2) (+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24))))
(/ (- 1 (cos x)) (pow x 2))
(cos x)
(- 1 (cos x))
Outputs
1/2
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
(+ 1/2 (* -1/24 (pow x 2)))
(cos.f64 x)
(+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24)))
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
(+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24)))
(*.f64 x x)
1
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
(+ 1 (* -1/2 (pow x 2)))
(-.f64 #s(literal 1 binary64) (cos.f64 x))

rewrite0.0ms (0%)

Memory
0.5MiB live, 0.5MiB allocated
Counts
6 → 6
Calls
Call 1
Inputs
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
(cos.f64 x)
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
(*.f64 x x)
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
(-.f64 #s(literal 1 binary64) (cos.f64 x))
Outputs
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
(cos.f64 x)
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
(*.f64 x x)
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
(-.f64 #s(literal 1 binary64) (cos.f64 x))

eval1.0ms (0.1%)

Memory
2.0MiB live, 2.0MiB allocated
Compiler

Compiled 212 to 23 computations (89.2% saved)

prune57.0ms (2.9%)

Memory
-54.8MiB live, 3.4MiB allocated
Pruning

5 alts after pruning (1 fresh and 4 done)

PrunedKeptTotal
New12113
Fresh000
Picked033
Done011
Total12517
Accuracy
60.2%
Counts
17 → 5
Alt Table
Click to see full alt table
StatusAccuracyProgram
52.1%
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
3.6%
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
10.7%
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))))
3.3%
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
10.7%
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
Compiler

Compiled 62 to 44 computations (29% saved)

simplify0.0ms (0%)

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

Found 4 expressions of interest:

NewMetricScoreProgram
cost-diff0
(-.f64 #s(literal 1 binary64) (cos.f64 x))
cost-diff0
#s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
cost-diff0
(-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x))))
cost-diff0
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))))
Calls
Call 1
Inputs
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))))
(-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x))))
#s(literal 1 binary64)
#s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
(-.f64 #s(literal 1 binary64) (cos.f64 x))
(cos.f64 x)
x
Outputs
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))))
(-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x))))
#s(literal 1 binary64)
#s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
(-.f64 #s(literal 1 binary64) (cos.f64 x))
(cos.f64 x)
x

localize46.0ms (2.3%)

Memory
9.8MiB live, 46.3MiB allocated
Localize:

Found 4 expressions of interest:

NewMetricScoreProgram
accuracy15.725532592442665
(-.f64 #s(literal 1 binary64) (cos.f64 x))
accuracy15.725532592442665
(-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x))))
accuracy59.54925496934346
#s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
accuracy61.388251516586145
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))))
Samples
17.0ms62×2valid
11.0ms135×0valid
6.0ms17×3valid
5.0ms42×1valid
Compiler

Compiled 66 to 20 computations (69.7% saved)

Precisions
Click to see histograms. Total time spent on operations: 29.0ms
ival-cos: 19.0ms (66.5% of total)
ival-div: 3.0ms (10.5% of total)
adjust: 3.0ms (10.5% of total)
ival-mult: 2.0ms (7% of total)
ival-sub: 2.0ms (7% 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
2.5MiB live, 2.5MiB allocated
Counts
4 → 15
Calls
Call 1
Inputs
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))))
(-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x))))
#s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
(-.f64 #s(literal 1 binary64) (cos.f64 x))
Outputs
1/2
(+ 1/2 (* -1/24 (pow x 2)))
(+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24)))
(+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24)))
(* 1/2 (pow x 2))
(* (pow x 2) (+ 1/2 (* -1/24 (pow x 2))))
(* (pow x 2) (+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24))))
(* (pow x 2) (+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24))))
1
(+ 1 (* -1/2 (pow x 2)))
(+ 1 (* (pow x 2) (- (* 1/24 (pow x 2)) 1/2)))
(+ 1 (* (pow x 2) (- (* (pow x 2) (+ 1/24 (* -1/720 (pow x 2)))) 1/2)))
(/ (- 1 (cos x)) (pow x 2))
(- 1 (cos x))
(cos x)
Calls

3 calls:

TimeVariablePointExpression
0.0ms
x
@inf
((/ (- 1 (cos x)) (* x x)) (- 1 (cos x)) (cos x) (- 1 (cos x)))
0.0ms
x
@-inf
((/ (- 1 (cos x)) (* x x)) (- 1 (cos x)) (cos x) (- 1 (cos x)))
0.0ms
x
@0
((/ (- 1 (cos x)) (* x x)) (- 1 (cos x)) (cos x) (- 1 (cos x)))

simplify0.0ms (0%)

Memory
0.5MiB live, 0.5MiB allocated
Algorithm
egg-herbie
Counts
15 → 4
Calls
Call 1
Inputs
1/2
(+ 1/2 (* -1/24 (pow x 2)))
(+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24)))
(+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24)))
(* 1/2 (pow x 2))
(* (pow x 2) (+ 1/2 (* -1/24 (pow x 2))))
(* (pow x 2) (+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24))))
(* (pow x 2) (+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24))))
1
(+ 1 (* -1/2 (pow x 2)))
(+ 1 (* (pow x 2) (- (* 1/24 (pow x 2)) 1/2)))
(+ 1 (* (pow x 2) (- (* (pow x 2) (+ 1/24 (* -1/720 (pow x 2)))) 1/2)))
(/ (- 1 (cos x)) (pow x 2))
(- 1 (cos x))
(cos x)
Outputs
1/2
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))))
(+ 1/2 (* -1/24 (pow x 2)))
(-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x))))
(+ 1/2 (* (pow x 2) (- (* 1/720 (pow x 2)) 1/24)))
#s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
(+ 1/2 (* (pow x 2) (- (* (pow x 2) (+ 1/720 (* -1/40320 (pow x 2)))) 1/24)))
(-.f64 #s(literal 1 binary64) (cos.f64 x))

rewrite0.0ms (0%)

Memory
0.7MiB live, 0.7MiB allocated
Counts
4 → 4
Calls
Call 1
Inputs
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))))
(-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x))))
#s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
(-.f64 #s(literal 1 binary64) (cos.f64 x))
Outputs
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))))
(-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x))))
#s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
(-.f64 #s(literal 1 binary64) (cos.f64 x))

eval1.0ms (0%)

Memory
1.3MiB live, 1.3MiB allocated
Compiler

Compiled 128 to 15 computations (88.3% saved)

prune3.0ms (0.1%)

Memory
4.3MiB live, 4.3MiB allocated
Pruning

5 alts after pruning (0 fresh and 5 done)

PrunedKeptTotal
New707
Fresh000
Picked011
Done044
Total7512
Accuracy
60.2%
Counts
12 → 5
Alt Table
Click to see full alt table
StatusAccuracyProgram
52.1%
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
3.6%
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
10.7%
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))))
3.3%
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
10.7%
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
Compiler

Compiled 124 to 61 computations (50.8% saved)

regimes5.0ms (0.2%)

Memory
7.9MiB live, 7.9MiB allocated
Counts
5 → 3
Calls
Call 1
Inputs
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))))
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
Outputs
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
Calls

2 calls:

2.0ms
x
2.0ms
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
Results
AccuracySegmentsBranch
60.2%3x
56.1%2(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
Compiler

Compiled 9 to 7 computations (22.2% saved)

regimes4.0ms (0.2%)

Memory
7.0MiB live, 7.0MiB allocated
Counts
4 → 1
Calls
Call 1
Inputs
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) (cos.f64 x)))
#s(approx (/ (- 1 (cos x)) (* x x)) (-.f64 #s(literal 1 binary64) #s(approx (cos x) (-.f64 #s(literal 1 binary64) (cos.f64 x)))))
Outputs
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
Calls

2 calls:

2.0ms
x
2.0ms
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
Results
AccuracySegmentsBranch
10.7%1(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
10.7%1x
Compiler

Compiled 9 to 7 computations (22.2% saved)

regimes2.0ms (0.1%)

Memory
4.8MiB live, 4.8MiB allocated
Accuracy

Total -0.0b remaining (-0%)

Threshold costs -0b (-0%)

Counts
1 → 1
Calls
Call 1
Inputs
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
Outputs
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
Calls

2 calls:

1.0ms
x
1.0ms
(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
Results
AccuracySegmentsBranch
3.3%1(/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))
3.3%1x
Compiler

Compiled 9 to 7 computations (22.2% saved)

bsearch53.0ms (2.7%)

Memory
-19.6MiB live, 53.1MiB allocated
Algorithm
binary-search
Stop Event
narrow-enough
narrow-enough
Steps
TimeLeftRight
26.0ms
4.800512491520526e-16
78426720298.13364
23.0ms
-0.0013672554816697524
-5.96336074578724e-9
Samples
30.0ms288×1valid
2.0ms32×0valid
Compiler

Compiled 391 to 330 computations (15.6% saved)

Precisions
Click to see histograms. Total time spent on operations: 24.0ms
ival-sub: 8.0ms (33.8% of total)
ival-cos: 6.0ms (25.4% of total)
adjust: 4.0ms (16.9% of total)
ival-div: 3.0ms (12.7% of total)
ival-mult: 2.0ms (8.5% of total)
ival-assert: 0.0ms (0% of total)
ival-true: 0.0ms (0% of total)
exact: 0.0ms (0% of total)

simplify5.0ms (0.2%)

Memory
8.2MiB live, 8.3MiB allocated
Algorithm
egg-herbie
Calls
Call 1
Inputs
(if (<=.f64 x #s(literal -6346860552976803/604462909807314587353088 binary64)) (/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x)) (if (<=.f64 x #s(literal 6346860552976803/604462909807314587353088 binary64)) #s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x)) (/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))))
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))
Outputs
(if (<=.f64 x #s(literal -6346860552976803/604462909807314587353088 binary64)) (/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x)) (if (<=.f64 x #s(literal 6346860552976803/604462909807314587353088 binary64)) #s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x)) (/.f64 (-.f64 #s(literal 1 binary64) (cos.f64 x)) (*.f64 x x))))
#s(approx (/ (- 1 (cos x)) (* x x)) (cos.f64 x))
#s(approx (/ (- 1 (cos x)) (* x x)) (*.f64 x x))

soundness1.0ms (0%)

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

Compiled 58 to 19 computations (67.2% saved)

preprocess26.0ms (1.3%)

Memory
-14.1MiB live, 30.7MiB allocated
Compiler

Compiled 132 to 50 computations (62.1% saved)

end0.0ms (0%)

Memory
0.0MiB live, 0.0MiB allocated

Profiling

Loading profile data...