(FPCore (u v) :precision binary64 (+ 1.0 (* v (log (+ u (* (- 1.0 u) (exp (/ -2.0 v))))))))
double code(double u, double v) {
return 1.0 + (v * log((u + ((1.0 - u) * exp((-2.0 / v))))));
}
real(8) function code(u, v)
real(8), intent (in) :: u
real(8), intent (in) :: v
code = 1.0d0 + (v * log((u + ((1.0d0 - u) * exp(((-2.0d0) / v))))))
end function
public static double code(double u, double v) {
return 1.0 + (v * Math.log((u + ((1.0 - u) * Math.exp((-2.0 / v))))));
}
def code(u, v): return 1.0 + (v * math.log((u + ((1.0 - u) * math.exp((-2.0 / v))))))
function code(u, v) return Float64(1.0 + Float64(v * log(Float64(u + Float64(Float64(1.0 - u) * exp(Float64(-2.0 / v))))))) end
function tmp = code(u, v) tmp = 1.0 + (v * log((u + ((1.0 - u) * exp((-2.0 / v)))))); end
code[u_, v_] := N[(1.0 + N[(v * N[Log[N[(u + N[(N[(1.0 - u), $MachinePrecision] * N[Exp[N[(-2.0 / v), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
1 + v \cdot \log \left(u + \left(1 - u\right) \cdot e^{\frac{-2}{v}}\right)
Please include this information when filing a bug report:
herbie shell --seed 2023010
(FPCore (u v)
:name "HairBSDF, sample_f, cosTheta"
:precision binary64
:pre (and (and (<= 1e-5 u) (<= u 1.0)) (and (<= 0.0 v) (<= v 109.746574)))
(+ 1.0 (* v (log (+ u (* (- 1.0 u) (exp (/ -2.0 v))))))))
| map: contract violation expected: list? given: #<eof> | L | C | |
|---|---|---|---|
| gen-map | /usr/share/racket/collects/racket/private/map.rkt | 257 | 2 |
| run-egglog | /home/nightlies/herbie/oflatt-egglog-ctx/src/egglog/run-egglog.rkt | 1332 | 0 |
| batch-egg-rewrite | /home/nightlies/herbie/oflatt-egglog-ctx/src/core/matcher.rkt | 71 | 0 |
| rewrite-expressions | /home/nightlies/herbie/oflatt-egglog-ctx/src/core/matcher.rkt | 89 | 0 |
| gen-rewrites! | /home/nightlies/herbie/oflatt-egglog-ctx/src/patch.rkt | 167 | 0 |
| patch-table-run | /home/nightlies/herbie/oflatt-egglog-ctx/src/patch.rkt | 318 | 0 |
| (unnamed) | /usr/share/racket/collects/racket/contract/private/arrow-val-first.rkt | 486 | 18 |
| run-iter! | /home/nightlies/herbie/oflatt-egglog-ctx/src/mainloop.rkt | 262 | 0 |
| mutate! | /home/nightlies/herbie/oflatt-egglog-ctx/src/mainloop.rkt | 372 | 0 |
| run-improve! | /home/nightlies/herbie/oflatt-egglog-ctx/src/mainloop.rkt | 320 | 0 |
| (unnamed) | /home/nightlies/herbie/oflatt-egglog-ctx/src/sandbox.rkt | 55 | 6 |
| (unnamed) | /usr/share/racket/pkgs/profile-lib/main.rkt | 40 | 10 |
| profile-thunk | /usr/share/racket/pkgs/profile-lib/main.rkt | 9 | 0 |
| (unnamed) | /usr/share/racket/collects/racket/engine.rkt | 42 | 24 |