Average Error: 0.1 → 0.1
Time: 21.9s
Precision: 64
\[x \cdot \frac{\sin y}{y}\]
\[\frac{\sin y}{y} \cdot x\]
x \cdot \frac{\sin y}{y}
\frac{\sin y}{y} \cdot x
double f(double x, double y) {
        double r107187 = x;
        double r107188 = y;
        double r107189 = sin(r107188);
        double r107190 = r107189 / r107188;
        double r107191 = r107187 * r107190;
        return r107191;
}

double f(double x, double y) {
        double r107192 = y;
        double r107193 = sin(r107192);
        double r107194 = r107193 / r107192;
        double r107195 = x;
        double r107196 = r107194 * r107195;
        return r107196;
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.1

    \[x \cdot \frac{\sin y}{y}\]
  2. Using strategy rm
  3. Applied *-commutative0.1

    \[\leadsto \color{blue}{\frac{\sin y}{y} \cdot x}\]
  4. Final simplification0.1

    \[\leadsto \frac{\sin y}{y} \cdot x\]

Reproduce

herbie shell --seed 2019323 +o rules:numerics
(FPCore (x y)
  :name "Linear.Quaternion:$cexp from linear-1.19.1.3"
  :precision binary64
  (* x (/ (sin y) y)))