
(FPCore (s r) :precision binary32 (+ (/ (* 0.25 (exp (/ (- r) s))) (* (* (* 2.0 (PI)) s) r)) (/ (* 0.75 (exp (/ (- r) (* 3.0 s)))) (* (* (* 6.0 (PI)) s) r))))
\begin{array}{l}
\\
\frac{0.25 \cdot e^{\frac{-r}{s}}}{\left(\left(2 \cdot \mathsf{PI}\left(\right)\right) \cdot s\right) \cdot r} + \frac{0.75 \cdot e^{\frac{-r}{3 \cdot s}}}{\left(\left(6 \cdot \mathsf{PI}\left(\right)\right) \cdot s\right) \cdot r}
\end{array}
Sampling outcomes in binary32 precision:
Herbie found 18 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (s r) :precision binary32 (+ (/ (* 0.25 (exp (/ (- r) s))) (* (* (* 2.0 (PI)) s) r)) (/ (* 0.75 (exp (/ (- r) (* 3.0 s)))) (* (* (* 6.0 (PI)) s) r))))
\begin{array}{l}
\\
\frac{0.25 \cdot e^{\frac{-r}{s}}}{\left(\left(2 \cdot \mathsf{PI}\left(\right)\right) \cdot s\right) \cdot r} + \frac{0.75 \cdot e^{\frac{-r}{3 \cdot s}}}{\left(\left(6 \cdot \mathsf{PI}\left(\right)\right) \cdot s\right) \cdot r}
\end{array}
(FPCore (s r)
:precision binary32
(let* ((t_0 (* (PI) s)))
(+
(* (/ (exp (/ (- r) s)) (* t_0 r)) 0.125)
(/ (* 0.75 (exp (* -0.3333333333333333 (/ r s)))) (* t_0 (* 6.0 r))))))\begin{array}{l}
\\
\begin{array}{l}
t_0 := \mathsf{PI}\left(\right) \cdot s\\
\frac{e^{\frac{-r}{s}}}{t\_0 \cdot r} \cdot 0.125 + \frac{0.75 \cdot e^{-0.3333333333333333 \cdot \frac{r}{s}}}{t\_0 \cdot \left(6 \cdot r\right)}
\end{array}
\end{array}
Initial program 99.7%
Taylor expanded in s around 0
lower-*.f32N/A
lower-/.f3299.8
Applied rewrites99.8%
lift-*.f32N/A
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f32N/A
associate-*l*N/A
*-commutativeN/A
*-commutativeN/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
associate-*l*N/A
lift-PI.f32N/A
lift-*.f32N/A
*-commutativeN/A
lower-*.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
lower-*.f3299.8
Applied rewrites99.8%
Taylor expanded in s around 0
*-commutativeN/A
lower-*.f32N/A
mul-1-negN/A
distribute-frac-negN/A
lower-/.f32N/A
lift-/.f32N/A
lift-neg.f32N/A
lift-exp.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
*-commutativeN/A
lift-*.f3299.8
Applied rewrites99.8%
(FPCore (s r) :precision binary32 (+ (* (/ (exp (/ (- r) s)) (* (* (PI) s) r)) 0.125) (/ (* 0.75 (exp (* -0.3333333333333333 (/ r s)))) (* (PI) (* s (* 6.0 r))))))
\begin{array}{l}
\\
\frac{e^{\frac{-r}{s}}}{\left(\mathsf{PI}\left(\right) \cdot s\right) \cdot r} \cdot 0.125 + \frac{0.75 \cdot e^{-0.3333333333333333 \cdot \frac{r}{s}}}{\mathsf{PI}\left(\right) \cdot \left(s \cdot \left(6 \cdot r\right)\right)}
\end{array}
Initial program 99.7%
Taylor expanded in s around 0
lower-*.f32N/A
lower-/.f3299.8
Applied rewrites99.8%
lift-*.f32N/A
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f32N/A
associate-*l*N/A
*-commutativeN/A
*-commutativeN/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
associate-*l*N/A
lift-PI.f32N/A
lift-*.f32N/A
*-commutativeN/A
lower-*.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
lower-*.f3299.8
Applied rewrites99.8%
Taylor expanded in s around 0
*-commutativeN/A
lower-*.f32N/A
mul-1-negN/A
distribute-frac-negN/A
lower-/.f32N/A
lift-/.f32N/A
lift-neg.f32N/A
lift-exp.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
*-commutativeN/A
lift-*.f3299.8
Applied rewrites99.8%
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f32N/A
lift-*.f32N/A
associate-*l*N/A
lower-*.f32N/A
lift-PI.f32N/A
lower-*.f32N/A
lift-*.f3299.8
Applied rewrites99.8%
(FPCore (s r)
:precision binary32
(let* ((t_0 (* (PI) s)))
(fma
0.75
(/ (exp (* (/ r s) -0.3333333333333333)) (* (* t_0 6.0) r))
(* (/ (exp (/ (- r) s)) (* t_0 r)) 0.125))))\begin{array}{l}
\\
\begin{array}{l}
t_0 := \mathsf{PI}\left(\right) \cdot s\\
\mathsf{fma}\left(0.75, \frac{e^{\frac{r}{s} \cdot -0.3333333333333333}}{\left(t\_0 \cdot 6\right) \cdot r}, \frac{e^{\frac{-r}{s}}}{t\_0 \cdot r} \cdot 0.125\right)
\end{array}
\end{array}
Initial program 99.7%
Taylor expanded in s around 0
lower-*.f32N/A
lower-/.f3299.8
Applied rewrites99.8%
lift-*.f32N/A
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f32N/A
associate-*l*N/A
*-commutativeN/A
*-commutativeN/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
associate-*l*N/A
lift-PI.f32N/A
lift-*.f32N/A
*-commutativeN/A
lower-*.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
lower-*.f3299.8
Applied rewrites99.8%
Taylor expanded in s around 0
*-commutativeN/A
lower-*.f32N/A
mul-1-negN/A
distribute-frac-negN/A
lower-/.f32N/A
lift-/.f32N/A
lift-neg.f32N/A
lift-exp.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
*-commutativeN/A
lift-*.f3299.8
Applied rewrites99.8%
lift-+.f32N/A
+-commutativeN/A
lift-/.f32N/A
lift-*.f32N/A
associate-/l*N/A
Applied rewrites99.7%
(FPCore (s r)
:precision binary32
(+
(/ (* 0.25 (exp (/ (- r) s))) (* (* (* 2.0 (PI)) s) r))
(/
(*
0.75
(fma
(/ (fma 0.05555555555555555 r (* -0.3333333333333333 s)) (* s s))
r
1.0))
(* (* (* 6.0 (PI)) s) r))))\begin{array}{l}
\\
\frac{0.25 \cdot e^{\frac{-r}{s}}}{\left(\left(2 \cdot \mathsf{PI}\left(\right)\right) \cdot s\right) \cdot r} + \frac{0.75 \cdot \mathsf{fma}\left(\frac{\mathsf{fma}\left(0.05555555555555555, r, -0.3333333333333333 \cdot s\right)}{s \cdot s}, r, 1\right)}{\left(\left(6 \cdot \mathsf{PI}\left(\right)\right) \cdot s\right) \cdot r}
\end{array}
Initial program 99.7%
Taylor expanded in r around 0
+-commutativeN/A
*-commutativeN/A
lower-fma.f32N/A
lower--.f32N/A
*-commutativeN/A
lower-*.f32N/A
lower-/.f32N/A
unpow2N/A
lower-*.f32N/A
associate-*r/N/A
metadata-evalN/A
lower-/.f328.2
Applied rewrites8.2%
Taylor expanded in s around 0
lower-/.f32N/A
+-commutativeN/A
lower-fma.f32N/A
lower-*.f32N/A
pow2N/A
lift-*.f328.2
Applied rewrites8.2%
(FPCore (s r)
:precision binary32
(let* ((t_0 (* (PI) s)))
(+
(* (/ (exp (/ (- r) s)) (* t_0 r)) 0.125)
(/
(fma (- (* (/ r (* s s)) 0.041666666666666664) (/ 0.25 s)) r 0.75)
(* t_0 (* 6.0 r))))))\begin{array}{l}
\\
\begin{array}{l}
t_0 := \mathsf{PI}\left(\right) \cdot s\\
\frac{e^{\frac{-r}{s}}}{t\_0 \cdot r} \cdot 0.125 + \frac{\mathsf{fma}\left(\frac{r}{s \cdot s} \cdot 0.041666666666666664 - \frac{0.25}{s}, r, 0.75\right)}{t\_0 \cdot \left(6 \cdot r\right)}
\end{array}
\end{array}
Initial program 99.7%
Taylor expanded in s around 0
lower-*.f32N/A
lower-/.f3299.8
Applied rewrites99.8%
lift-*.f32N/A
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f32N/A
associate-*l*N/A
*-commutativeN/A
*-commutativeN/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
associate-*l*N/A
lift-PI.f32N/A
lift-*.f32N/A
*-commutativeN/A
lower-*.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
lower-*.f3299.8
Applied rewrites99.8%
Taylor expanded in s around 0
*-commutativeN/A
lower-*.f32N/A
mul-1-negN/A
distribute-frac-negN/A
lower-/.f32N/A
lift-/.f32N/A
lift-neg.f32N/A
lift-exp.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
*-commutativeN/A
lift-*.f3299.8
Applied rewrites99.8%
Taylor expanded in r around 0
+-commutativeN/A
*-commutativeN/A
lower-fma.f32N/A
lower--.f32N/A
*-commutativeN/A
lower-*.f32N/A
lower-/.f32N/A
unpow2N/A
lower-*.f32N/A
associate-*r/N/A
metadata-evalN/A
lower-/.f328.2
Applied rewrites8.2%
(FPCore (s r) :precision binary32 (+ (/ (* 0.25 (exp (/ (- r) s))) (* (* (* 2.0 (PI)) s) r)) (/ (* 0.75 1.0) (* (* (* (PI) s) 6.0) r))))
\begin{array}{l}
\\
\frac{0.25 \cdot e^{\frac{-r}{s}}}{\left(\left(2 \cdot \mathsf{PI}\left(\right)\right) \cdot s\right) \cdot r} + \frac{0.75 \cdot 1}{\left(\left(\mathsf{PI}\left(\right) \cdot s\right) \cdot 6\right) \cdot r}
\end{array}
Initial program 99.7%
Taylor expanded in r around 0
+-commutativeN/A
*-commutativeN/A
lower-fma.f32N/A
lower--.f32N/A
*-commutativeN/A
lower-*.f32N/A
lower-/.f32N/A
unpow2N/A
lower-*.f32N/A
associate-*r/N/A
metadata-evalN/A
lower-/.f328.2
Applied rewrites8.2%
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f32N/A
associate-*l*N/A
*-commutativeN/A
*-commutativeN/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f328.2
Applied rewrites8.2%
Taylor expanded in s around inf
Applied rewrites8.1%
(FPCore (s r) :precision binary32 (fma 0.25 (/ (exp (/ (- r) s)) (* (* (* (PI) 2.0) s) r)) (/ (/ 0.125 r) (* (PI) s))))
\begin{array}{l}
\\
\mathsf{fma}\left(0.25, \frac{e^{\frac{-r}{s}}}{\left(\left(\mathsf{PI}\left(\right) \cdot 2\right) \cdot s\right) \cdot r}, \frac{\frac{0.125}{r}}{\mathsf{PI}\left(\right) \cdot s}\right)
\end{array}
Initial program 99.7%
Taylor expanded in s around 0
lower-*.f32N/A
lower-/.f3299.8
Applied rewrites99.8%
Taylor expanded in s around inf
Applied rewrites8.1%
Applied rewrites8.1%
lift-/.f32N/A
lift-/.f32N/A
associate-/l/N/A
*-commutativeN/A
lift-PI.f32N/A
lift-*.f32N/A
*-commutativeN/A
associate-/r*N/A
lower-/.f32N/A
lower-/.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f328.1
Applied rewrites8.1%
Final simplification8.1%
(FPCore (s r) :precision binary32 (let* ((t_0 (* (PI) s))) (+ (* (/ (exp (/ (- r) s)) (* t_0 r)) 0.125) (/ 0.75 (* t_0 (* 6.0 r))))))
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \mathsf{PI}\left(\right) \cdot s\\
\frac{e^{\frac{-r}{s}}}{t\_0 \cdot r} \cdot 0.125 + \frac{0.75}{t\_0 \cdot \left(6 \cdot r\right)}
\end{array}
\end{array}
Initial program 99.7%
Taylor expanded in s around 0
lower-*.f32N/A
lower-/.f3299.8
Applied rewrites99.8%
lift-*.f32N/A
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f32N/A
associate-*l*N/A
*-commutativeN/A
*-commutativeN/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
associate-*l*N/A
lift-PI.f32N/A
lift-*.f32N/A
*-commutativeN/A
lower-*.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
lower-*.f3299.8
Applied rewrites99.8%
Taylor expanded in s around 0
*-commutativeN/A
lower-*.f32N/A
mul-1-negN/A
distribute-frac-negN/A
lower-/.f32N/A
lift-/.f32N/A
lift-neg.f32N/A
lift-exp.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
*-commutativeN/A
lift-*.f3299.8
Applied rewrites99.8%
Taylor expanded in s around inf
Applied rewrites8.1%
(FPCore (s r) :precision binary32 (let* ((t_0 (* (* (PI) s) r))) (+ (* (/ (exp (/ (- r) s)) t_0) 0.125) (/ 0.125 t_0))))
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \left(\mathsf{PI}\left(\right) \cdot s\right) \cdot r\\
\frac{e^{\frac{-r}{s}}}{t\_0} \cdot 0.125 + \frac{0.125}{t\_0}
\end{array}
\end{array}
Initial program 99.7%
Taylor expanded in s around 0
lower-*.f32N/A
lower-/.f3299.8
Applied rewrites99.8%
Taylor expanded in s around inf
Applied rewrites8.1%
Taylor expanded in s around 0
*-commutativeN/A
lower-*.f32N/A
mul-1-negN/A
distribute-frac-negN/A
lower-/.f32N/A
lift-/.f32N/A
lift-neg.f32N/A
lift-exp.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f32N/A
*-commutativeN/A
lift-*.f328.1
Applied rewrites8.1%
(FPCore (s r)
:precision binary32
(+
(/
(/
(fma (/ (/ r s) (PI)) -0.06944444444444445 (/ 0.16666666666666666 (PI)))
s)
(- s))
(/ (/ 0.25 (* (PI) r)) s)))\begin{array}{l}
\\
\frac{\frac{\mathsf{fma}\left(\frac{\frac{r}{s}}{\mathsf{PI}\left(\right)}, -0.06944444444444445, \frac{0.16666666666666666}{\mathsf{PI}\left(\right)}\right)}{s}}{-s} + \frac{\frac{0.25}{\mathsf{PI}\left(\right) \cdot r}}{s}
\end{array}
Initial program 99.7%
Taylor expanded in s around -inf
Applied rewrites7.4%
Taylor expanded in s around inf
lower-/.f32N/A
*-commutativeN/A
lower-fma.f32N/A
associate-/r*N/A
lower-/.f32N/A
lift-/.f32N/A
lift-PI.f32N/A
associate-*r/N/A
metadata-evalN/A
lift-/.f32N/A
lift-PI.f327.9
Applied rewrites7.9%
lift-/.f32N/A
lift--.f32N/A
div-subN/A
Applied rewrites7.9%
Final simplification7.9%
(FPCore (s r)
:precision binary32
(/
(-
(/
(fma (/ (/ r s) (PI)) -0.06944444444444445 (/ 0.16666666666666666 (PI)))
s)
(/ 0.25 (* (PI) r)))
(- s)))\begin{array}{l}
\\
\frac{\frac{\mathsf{fma}\left(\frac{\frac{r}{s}}{\mathsf{PI}\left(\right)}, -0.06944444444444445, \frac{0.16666666666666666}{\mathsf{PI}\left(\right)}\right)}{s} - \frac{0.25}{\mathsf{PI}\left(\right) \cdot r}}{-s}
\end{array}
Initial program 99.7%
Taylor expanded in s around -inf
Applied rewrites7.4%
Taylor expanded in s around inf
lower-/.f32N/A
*-commutativeN/A
lower-fma.f32N/A
associate-/r*N/A
lower-/.f32N/A
lift-/.f32N/A
lift-PI.f32N/A
associate-*r/N/A
metadata-evalN/A
lift-/.f32N/A
lift-PI.f327.9
Applied rewrites7.9%
Final simplification7.9%
(FPCore (s r)
:precision binary32
(/
(-
(fma
(/ r (* (* s s) (PI)))
-0.06944444444444445
(/ 0.16666666666666666 (* (PI) s)))
(/ 0.25 (* (PI) r)))
(- s)))\begin{array}{l}
\\
\frac{\mathsf{fma}\left(\frac{r}{\left(s \cdot s\right) \cdot \mathsf{PI}\left(\right)}, -0.06944444444444445, \frac{0.16666666666666666}{\mathsf{PI}\left(\right) \cdot s}\right) - \frac{0.25}{\mathsf{PI}\left(\right) \cdot r}}{-s}
\end{array}
Initial program 99.7%
Taylor expanded in s around -inf
Applied rewrites7.4%
Taylor expanded in s around inf
lower-/.f32N/A
*-commutativeN/A
lower-fma.f32N/A
associate-/r*N/A
lower-/.f32N/A
lift-/.f32N/A
lift-PI.f32N/A
associate-*r/N/A
metadata-evalN/A
lift-/.f32N/A
lift-PI.f327.9
Applied rewrites7.9%
Taylor expanded in r around 0
*-commutativeN/A
associate-*r/N/A
metadata-evalN/A
lower-fma.f32N/A
lower-/.f32N/A
lower-*.f32N/A
unpow2N/A
lower-*.f32N/A
lift-PI.f32N/A
lower-/.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f327.9
Applied rewrites7.9%
Final simplification7.9%
(FPCore (s r) :precision binary32 (/ (- (fma (/ r (* (* s s) (PI))) 0.06944444444444445 (/ 0.25 (* (PI) r))) (/ 0.16666666666666666 (* (PI) s))) s))
\begin{array}{l}
\\
\frac{\mathsf{fma}\left(\frac{r}{\left(s \cdot s\right) \cdot \mathsf{PI}\left(\right)}, 0.06944444444444445, \frac{0.25}{\mathsf{PI}\left(\right) \cdot r}\right) - \frac{0.16666666666666666}{\mathsf{PI}\left(\right) \cdot s}}{s}
\end{array}
Initial program 99.7%
Taylor expanded in s around -inf
Applied rewrites7.4%
Taylor expanded in s around inf
lower-/.f32N/A
*-commutativeN/A
lower-fma.f32N/A
associate-/r*N/A
lower-/.f32N/A
lift-/.f32N/A
lift-PI.f32N/A
associate-*r/N/A
metadata-evalN/A
lift-/.f32N/A
lift-PI.f327.9
Applied rewrites7.9%
Taylor expanded in s around inf
lower-/.f32N/A
Applied rewrites7.8%
(FPCore (s r) :precision binary32 (/ (/ 0.25 (* s r)) (PI)))
\begin{array}{l}
\\
\frac{\frac{0.25}{s \cdot r}}{\mathsf{PI}\left(\right)}
\end{array}
Initial program 99.7%
Taylor expanded in s around inf
lower-/.f32N/A
*-commutativeN/A
lower-*.f32N/A
*-commutativeN/A
lower-*.f32N/A
lift-PI.f327.8
Applied rewrites7.8%
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f32N/A
*-commutativeN/A
*-commutativeN/A
associate-*r*N/A
lower-*.f32N/A
*-commutativeN/A
lower-*.f32N/A
lift-PI.f327.8
Applied rewrites7.8%
lift-/.f32N/A
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f32N/A
associate-/r*N/A
lower-/.f32N/A
*-commutativeN/A
lower-/.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f327.8
Applied rewrites7.8%
(FPCore (s r) :precision binary32 (/ (/ 0.25 s) (* (PI) r)))
\begin{array}{l}
\\
\frac{\frac{0.25}{s}}{\mathsf{PI}\left(\right) \cdot r}
\end{array}
Initial program 99.7%
Taylor expanded in s around inf
lower-/.f32N/A
*-commutativeN/A
lower-*.f32N/A
*-commutativeN/A
lower-*.f32N/A
lift-PI.f327.8
Applied rewrites7.8%
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f32N/A
*-commutativeN/A
*-commutativeN/A
associate-*r*N/A
lower-*.f32N/A
*-commutativeN/A
lower-*.f32N/A
lift-PI.f327.8
Applied rewrites7.8%
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f32N/A
associate-*l*N/A
lower-*.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f327.8
Applied rewrites7.8%
lift-/.f32N/A
lift-*.f32N/A
associate-/r*N/A
metadata-evalN/A
associate-*r/N/A
lift-PI.f32N/A
lift-*.f32N/A
*-commutativeN/A
lower-/.f32N/A
associate-*r/N/A
metadata-evalN/A
lower-/.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f327.8
Applied rewrites7.8%
(FPCore (s r) :precision binary32 (/ (/ 0.25 r) (* (PI) s)))
\begin{array}{l}
\\
\frac{\frac{0.25}{r}}{\mathsf{PI}\left(\right) \cdot s}
\end{array}
Initial program 99.7%
Taylor expanded in s around inf
lower-/.f32N/A
*-commutativeN/A
lower-*.f32N/A
*-commutativeN/A
lower-*.f32N/A
lift-PI.f327.8
Applied rewrites7.8%
lift-/.f32N/A
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f32N/A
*-commutativeN/A
*-commutativeN/A
associate-/r*N/A
lower-/.f32N/A
lower-/.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f327.8
Applied rewrites7.8%
(FPCore (s r) :precision binary32 (/ 0.25 (* (* (PI) s) r)))
\begin{array}{l}
\\
\frac{0.25}{\left(\mathsf{PI}\left(\right) \cdot s\right) \cdot r}
\end{array}
Initial program 99.7%
Taylor expanded in s around inf
lower-/.f32N/A
*-commutativeN/A
lower-*.f32N/A
*-commutativeN/A
lower-*.f32N/A
lift-PI.f327.8
Applied rewrites7.8%
(FPCore (s r) :precision binary32 (/ 0.25 (* s (* (PI) r))))
\begin{array}{l}
\\
\frac{0.25}{s \cdot \left(\mathsf{PI}\left(\right) \cdot r\right)}
\end{array}
Initial program 99.7%
Taylor expanded in s around inf
lower-/.f32N/A
*-commutativeN/A
lower-*.f32N/A
*-commutativeN/A
lower-*.f32N/A
lift-PI.f327.8
Applied rewrites7.8%
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f32N/A
*-commutativeN/A
*-commutativeN/A
associate-*r*N/A
lower-*.f32N/A
*-commutativeN/A
lower-*.f32N/A
lift-PI.f327.8
Applied rewrites7.8%
lift-*.f32N/A
lift-PI.f32N/A
lift-*.f32N/A
associate-*l*N/A
lower-*.f32N/A
*-commutativeN/A
lift-*.f32N/A
lift-PI.f327.8
Applied rewrites7.8%
herbie shell --seed 2025073
(FPCore (s r)
:name "Disney BSSRDF, PDF of scattering profile"
:precision binary32
:pre (and (and (<= 0.0 s) (<= s 256.0)) (and (< 1e-6 r) (< r 1000000.0)))
(+ (/ (* 0.25 (exp (/ (- r) s))) (* (* (* 2.0 (PI)) s) r)) (/ (* 0.75 (exp (/ (- r) (* 3.0 s)))) (* (* (* 6.0 (PI)) s) r))))