Average Error: 0.2 → 0
Time: 7.9s
Precision: 64
\[\frac{\sin x}{\cos x}\]
\[\tan x\]
\frac{\sin x}{\cos x}
\tan x
double f(double x) {
        double r54178026 = x;
        double r54178027 = sin(r54178026);
        double r54178028 = cos(r54178026);
        double r54178029 = r54178027 / r54178028;
        return r54178029;
}

double f(double x) {
        double r54178030 = x;
        double r54178031 = tan(r54178030);
        return r54178031;
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.2

    \[\frac{\sin x}{\cos x}\]
  2. Using strategy rm
  3. Applied quot-tan0

    \[\leadsto \color{blue}{\tan x}\]
  4. Final simplification0

    \[\leadsto \tan x\]

Reproduce

herbie shell --seed 1 
(FPCore (x)
  :name "sin(x) / cos(x)"
  (/ (sin x) (cos x)))