Average Error: 10.4 → 10.4
Time: 8.2s
Precision: 64
\[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)\]
\[\sin^{-1} \left(\sqrt{\frac{1 - \log \left(e^{{\left(\frac{Om}{Omc}\right)}^{2}}\right)}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)\]
\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)
\sin^{-1} \left(\sqrt{\frac{1 - \log \left(e^{{\left(\frac{Om}{Omc}\right)}^{2}}\right)}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)
double code(double t, double l, double Om, double Omc) {
	return asin(sqrt(((1.0 - pow((Om / Omc), 2.0)) / (1.0 + (2.0 * pow((t / l), 2.0))))));
}
double code(double t, double l, double Om, double Omc) {
	return asin(sqrt(((1.0 - log(exp(pow((Om / Omc), 2.0)))) / (1.0 + (2.0 * pow((t / l), 2.0))))));
}

Error

Bits error versus t

Bits error versus l

Bits error versus Om

Bits error versus Omc

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 10.4

    \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)\]
  2. Using strategy rm
  3. Applied add-log-exp10.4

    \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - \color{blue}{\log \left(e^{{\left(\frac{Om}{Omc}\right)}^{2}}\right)}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)\]
  4. Final simplification10.4

    \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - \log \left(e^{{\left(\frac{Om}{Omc}\right)}^{2}}\right)}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)\]

Reproduce

herbie shell --seed 2020091 
(FPCore (t l Om Omc)
  :name "Toniolo and Linder, Equation (2)"
  :precision binary64
  (asin (sqrt (/ (- 1 (pow (/ Om Omc) 2)) (+ 1 (* 2 (pow (/ t l) 2)))))))