Average Error: 10.3 → 5.7
Time: 52.7s
Precision: 64
Internal Precision: 576
\[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)\]
\[\begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \le 5.866463294174376 \cdot 10^{+125}:\\ \;\;\;\;(e^{\log_* (1 + \sin^{-1} \left(\sqrt{(e^{\log_* (1 + \frac{1 - \frac{Om}{Omc} \cdot \frac{Om}{Omc}}{(\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right) \cdot 2 + 1)_*})} - 1)^*}\right))} - 1)^*\\ \mathbf{else}:\\ \;\;\;\;(e^{\log_* (1 + \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om}{Omc} \cdot \frac{Om}{Omc}}}{\frac{t \cdot \sqrt{2}}{\ell}}\right))} - 1)^*\\ \end{array}\]

Error

Bits error versus t

Bits error versus l

Bits error versus Om

Bits error versus Omc

Derivation

  1. Split input into 2 regimes
  2. if (/ t l) < 5.866463294174376e+125

    1. Initial program 6.5

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)\]
    2. Initial simplification6.5

      \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - \frac{Om}{Omc} \cdot \frac{Om}{Omc}}{(\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right) \cdot 2 + 1)_*}}\right)\]
    3. Using strategy rm
    4. Applied expm1-log1p-u6.5

      \[\leadsto \color{blue}{(e^{\log_* (1 + \sin^{-1} \left(\sqrt{\frac{1 - \frac{Om}{Omc} \cdot \frac{Om}{Omc}}{(\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right) \cdot 2 + 1)_*}}\right))} - 1)^*}\]
    5. Using strategy rm
    6. Applied expm1-log1p-u6.5

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

    if 5.866463294174376e+125 < (/ t l)

    1. Initial program 30.8

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)\]
    2. Initial simplification30.8

      \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - \frac{Om}{Omc} \cdot \frac{Om}{Omc}}{(\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right) \cdot 2 + 1)_*}}\right)\]
    3. Using strategy rm
    4. Applied expm1-log1p-u30.8

      \[\leadsto \color{blue}{(e^{\log_* (1 + \sin^{-1} \left(\sqrt{\frac{1 - \frac{Om}{Omc} \cdot \frac{Om}{Omc}}{(\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right) \cdot 2 + 1)_*}}\right))} - 1)^*}\]
    5. Using strategy rm
    6. Applied sqrt-div30.8

      \[\leadsto (e^{\log_* (1 + \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - \frac{Om}{Omc} \cdot \frac{Om}{Omc}}}{\sqrt{(\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right) \cdot 2 + 1)_*}}\right)})} - 1)^*\]
    7. Taylor expanded around inf 1.3

      \[\leadsto (e^{\log_* (1 + \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om}{Omc} \cdot \frac{Om}{Omc}}}{\color{blue}{\frac{t \cdot \sqrt{2}}{\ell}}}\right))} - 1)^*\]
  3. Recombined 2 regimes into one program.
  4. Final simplification5.7

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \le 5.866463294174376 \cdot 10^{+125}:\\ \;\;\;\;(e^{\log_* (1 + \sin^{-1} \left(\sqrt{(e^{\log_* (1 + \frac{1 - \frac{Om}{Omc} \cdot \frac{Om}{Omc}}{(\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right) \cdot 2 + 1)_*})} - 1)^*}\right))} - 1)^*\\ \mathbf{else}:\\ \;\;\;\;(e^{\log_* (1 + \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om}{Omc} \cdot \frac{Om}{Omc}}}{\frac{t \cdot \sqrt{2}}{\ell}}\right))} - 1)^*\\ \end{array}\]

Runtime

Time bar (total: 52.7s)Debug logProfile

BaselineHerbieOracleSpan%
Regimes10.35.75.64.798.8%
herbie shell --seed 2018295 +o rules:numerics
(FPCore (t l Om Omc)
  :name "Toniolo and Linder, Equation (2)"
  (asin (sqrt (/ (- 1 (pow (/ Om Omc) 2)) (+ 1 (* 2 (pow (/ t l) 2)))))))