eval 5.93 KB
Newer Older
Mans Rullgard's avatar
Mans Rullgard committed
1 2 3
Evaluating ''
'' -> nan

4
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
Evaluating '1;2'
'1;2' -> 2.000000

Evaluating '-20'
'-20' -> -20.000000

Evaluating '-PI'
'-PI' -> -3.141593

Evaluating '+PI'
'+PI' -> 3.141593

Evaluating '1+(5-2)^(3-1)+1/2+sin(PI)-max(-2.2,-3.1)'
'1+(5-2)^(3-1)+1/2+sin(PI)-max(-2.2,-3.1)' -> 12.700000

20 21 22 23 24
Evaluating '80G/80Gi'
'80G/80Gi' -> 0.931323

Evaluating '1k'
'1k' -> 1000.000000
Mans Rullgard's avatar
Mans Rullgard committed
25 26 27 28 29 30 31

Evaluating '1Gi'
'1Gi' -> 1073741824.000000

Evaluating '1gi'
'1gi' -> nan

32
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
33 34 35
Evaluating '1GiFoo'
'1GiFoo' -> nan

36
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
37 38 39 40 41 42
Evaluating '1k+1k'
'1k+1k' -> 2000.000000

Evaluating '1Gi*3foo'
'1Gi*3foo' -> nan

43
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
44 45 46
Evaluating 'foo'
'foo' -> nan

47
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
48 49 50
Evaluating 'foo('
'foo(' -> nan

51
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
52 53 54
Evaluating 'foo()'
'foo()' -> nan

55
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
56 57 58
Evaluating 'foo)'
'foo)' -> nan

59
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
60 61 62
Evaluating 'sin'
'sin' -> nan

63
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
64 65 66
Evaluating 'sin('
'sin(' -> nan

67
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
68 69 70
Evaluating 'sin()'
'sin()' -> nan

71
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
72 73 74
Evaluating 'sin)'
'sin)' -> nan

75
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
76 77 78
Evaluating 'sin 10'
'sin 10' -> nan

79
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
80 81 82
Evaluating 'sin(1,2,3)'
'sin(1,2,3)' -> nan

83
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
84 85 86 87 88 89 90 91 92
Evaluating 'sin(1 )'
'sin(1 )' -> 0.841471

Evaluating '1'
'1' -> 1.000000

Evaluating '1foo'
'1foo' -> nan

93
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
94 95 96
Evaluating 'bar + PI + E + 100f*2 + foo'
'bar + PI + E + 100f*2 + foo' -> nan

97
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
98 99 100
Evaluating '13k + 12f - foo(1, 2)'
'13k + 12f - foo(1, 2)' -> nan

101
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
102 103 104
Evaluating '1gi'
'1gi' -> nan

105
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
106 107 108 109 110 111 112 113 114
Evaluating '1Gi'
'1Gi' -> 1073741824.000000

Evaluating 'st(0, 123)'
'st(0, 123)' -> 123.000000

Evaluating 'st(1, 123); ld(1)'
'st(1, 123); ld(1)' -> 123.000000

115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138
Evaluating 'lte(0, 1)'
'lte(0, 1)' -> 1.000000

Evaluating 'lte(1, 1)'
'lte(1, 1)' -> 1.000000

Evaluating 'lte(1, 0)'
'lte(1, 0)' -> 0.000000

Evaluating 'lt(0, 1)'
'lt(0, 1)' -> 1.000000

Evaluating 'lt(1, 1)'
'lt(1, 1)' -> 0.000000

Evaluating 'gt(1, 0)'
'gt(1, 0)' -> 1.000000

Evaluating 'gt(2, 7)'
'gt(2, 7)' -> 0.000000

Evaluating 'gte(122, 122)'
'gte(122, 122)' -> 1.000000

Mans Rullgard's avatar
Mans Rullgard committed
139
Evaluating 'st(0, 1); while(lte(ld(0), 100), st(1, ld(1)+ld(0));st(0, ld(0)+1)); ld(1)'
140
'st(0, 1); while(lte(ld(0), 100), st(1, ld(1)+ld(0));st(0, ld(0)+1)); ld(1)' -> 5050.000000
Mans Rullgard's avatar
Mans Rullgard committed
141 142

Evaluating 'st(1, 1); st(2, 2); st(0, 1); while(lte(ld(0),10), st(3, ld(1)+ld(2)); st(1, ld(2)); st(2, ld(3)); st(0, ld(0)+1)); ld(3)'
143
'st(1, 1); st(2, 2); st(0, 1); while(lte(ld(0),10), st(3, ld(1)+ld(2)); st(1, ld(2)); st(2, ld(3)); st(0, ld(0)+1)); ld(3)' -> 233.000000
Mans Rullgard's avatar
Mans Rullgard committed
144 145 146 147

Evaluating 'while(0, 10)'
'while(0, 10)' -> nan

148
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
149
Evaluating 'st(0, 1); while(lte(ld(0),100), st(1, ld(1)+ld(0)); st(0, ld(0)+1))'
150
'st(0, 1); while(lte(ld(0),100), st(1, ld(1)+ld(0)); st(0, ld(0)+1))' -> 101.000000
Mans Rullgard's avatar
Mans Rullgard committed
151 152 153 154 155 156 157

Evaluating 'isnan(1)'
'isnan(1)' -> 0.000000

Evaluating 'isnan(NAN)'
'isnan(NAN)' -> 1.000000

158 159 160 161 162 163 164 165 166 167 168 169
Evaluating 'isnan(INF)'
'isnan(INF)' -> 0.000000

Evaluating 'isinf(1)'
'isinf(1)' -> 0.000000

Evaluating 'isinf(NAN)'
'isinf(NAN)' -> 0.000000

Evaluating 'isinf(INF)'
'isinf(INF)' -> 1.000000

Mans Rullgard's avatar
Mans Rullgard committed
170 171 172
Evaluating 'floor(NAN)'
'floor(NAN)' -> nan

173
av_expr_parse_and_eval failed
Mans Rullgard's avatar
Mans Rullgard committed
174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191
Evaluating 'floor(123.123)'
'floor(123.123)' -> 123.000000

Evaluating 'floor(-123.123)'
'floor(-123.123)' -> -124.000000

Evaluating 'trunc(123.123)'
'trunc(123.123)' -> 123.000000

Evaluating 'trunc(-123.123)'
'trunc(-123.123)' -> -123.000000

Evaluating 'ceil(123.123)'
'ceil(123.123)' -> 124.000000

Evaluating 'ceil(-123.123)'
'ceil(-123.123)' -> -123.000000

192 193 194
Evaluating 'sqrt(1764)'
'sqrt(1764)' -> 42.000000

195 196
Evaluating 'isnan(sqrt(-1))'
'isnan(sqrt(-1))' -> 1.000000
197 198 199 200 201 202 203 204 205 206

Evaluating 'not(1)'
'not(1)' -> 0.000000

Evaluating 'not(NAN)'
'not(NAN)' -> 0.000000

Evaluating 'not(0)'
'not(0)' -> 1.000000

207 208 209 210 211 212
Evaluating '6.0206dB'
'6.0206dB' -> 2.000000

Evaluating '-3.0103dB'
'-3.0103dB' -> 0.707107

213 214 215 216 217 218 219 220 221 222
Evaluating 'pow(0,1.23)'
'pow(0,1.23)' -> 0.000000

Evaluating 'pow(PI,1.23)'
'pow(PI,1.23)' -> 4.087844

Evaluating 'PI^1.23'
'PI^1.23' -> 4.087844

Evaluating 'pow(-1,1.23)'
223
'pow(-1,1.23)' -> nan
224

225
av_expr_parse_and_eval failed
226 227 228
Evaluating 'if(1, 2)'
'if(1, 2)' -> 2.000000

229 230 231 232 233 234
Evaluating 'if(1, 1, 2)'
'if(1, 1, 2)' -> 1.000000

Evaluating 'if(0, 1, 2)'
'if(0, 1, 2)' -> 2.000000

235 236 237 238 239 240
Evaluating 'ifnot(0, 23)'
'ifnot(0, 23)' -> 23.000000

Evaluating 'ifnot(1, NaN) + if(0, 1)'
'ifnot(1, NaN) + if(0, 1)' -> 0.000000

241 242 243 244 245 246
Evaluating 'ifnot(1, 1, 2)'
'ifnot(1, 1, 2)' -> 2.000000

Evaluating 'ifnot(0, 1, 2)'
'ifnot(0, 1, 2)' -> 1.000000

247 248 249
Evaluating 'taylor(1, 1)'
'taylor(1, 1)' -> 2.718282

250 251
Evaluating 'taylor(eq(mod(ld(1),4),1)-eq(mod(ld(1),4),3), PI/2, 1)'
'taylor(eq(mod(ld(1),4),1)-eq(mod(ld(1),4),3), PI/2, 1)' -> 1.000000
252

253 254 255 256 257 258
Evaluating 'root(sin(ld(0))-1, 2)'
'root(sin(ld(0))-1, 2)' -> 1.570796

Evaluating 'root(sin(ld(0))+6+sin(ld(0)/12)-log(ld(0)), 100)'
'root(sin(ld(0))+6+sin(ld(0)/12)-log(ld(0)), 100)' -> 60.965601

259 260 261 262 263 264 265 266 267 268 269 270
Evaluating '7000000B*random(0)'
'7000000B*random(0)' -> 0.003078

Evaluating 'squish(2)'
'squish(2)' -> 0.000335

Evaluating 'gauss(0.1)'
'gauss(0.1)' -> 0.396953

Evaluating 'hypot(4,3)'
'hypot(4,3)' -> 5.000000

271 272
Evaluating 'gcd(30,55)*print(min(9,1))'
'gcd(30,55)*print(min(9,1))' -> 5.000000
273

274 275 276 277 278 279 280 281
Evaluating 'bitor(42, 12)'
'bitor(42, 12)' -> 46.000000

Evaluating 'bitand(42, 12)'
'bitand(42, 12)' -> 8.000000

Evaluating 'bitand(NAN, 1)'
'bitand(NAN, 1)' -> nan
282

283
av_expr_parse_and_eval failed
284 285 286 287 288 289 290 291 292
Evaluating 'between(10, -3, 10)'
'between(10, -3, 10)' -> 1.000000

Evaluating 'between(-4, -2, -1)'
'between(-4, -2, -1)' -> 0.000000

Evaluating 'between(1,2)'
'between(1,2)' -> nan

293
av_expr_parse_and_eval failed
294 295 296
Evaluating 'clip(0, 2, 1)'
'clip(0, 2, 1)' -> nan

297
av_expr_parse_and_eval failed
298 299 300
Evaluating 'clip(0/0, 1, 2)'
'clip(0/0, 1, 2)' -> nan

301
av_expr_parse_and_eval failed
302 303 304
Evaluating 'clip(0, 0/0, 1)'
'clip(0, 0/0, 1)' -> nan

305
av_expr_parse_and_eval failed
306 307
12.700000 == 12.7
0.931323 == 0.931322575