Average Error: 0.5 → 0.5
Time: 12.7s
Precision: 64
\[\sin a + \tan a\]
\[\frac{\sin a}{\cos a} + \sin a\]
\sin a + \tan a
\frac{\sin a}{\cos a} + \sin a
double f(double a) {
        double r32435 = a;
        double r32436 = sin(r32435);
        double r32437 = tan(r32435);
        double r32438 = r32436 + r32437;
        return r32438;
}

double f(double a) {
        double r32439 = a;
        double r32440 = sin(r32439);
        double r32441 = cos(r32439);
        double r32442 = r32440 / r32441;
        double r32443 = r32442 + r32440;
        return r32443;
}

Error

Bits error versus a

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.5

    \[\sin a + \tan a\]
  2. Taylor expanded around inf 0.5

    \[\leadsto \color{blue}{\frac{\sin a}{\cos a} + \sin a}\]
  3. Final simplification0.5

    \[\leadsto \frac{\sin a}{\cos a} + \sin a\]

Reproduce

herbie shell --seed 1 
(FPCore (a)
  :name "sin(a) + tan(a)"
  :precision binary64
  (+ (sin a) (tan a)))