?

Average Accuracy: 73.8% → 92.8%
Time: 25.0s
Precision: binary64
Cost: 1865

?

\[\mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, z\right), t\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\right)\right) \]
\[\begin{array}{l} t_1 := \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\\ \mathbf{if}\;\mathsf{<=.f64}\left(t_1, -9999999999999999378499396381163974664505251594389679853757253159226858588823650024928554969640430609348999796218942130031825270939086493357629899207015514012385280\right) \lor \neg \mathsf{<=.f64}\left(t_1, 19999999999999998743069049246737528200546615119793746550412501356903849205370206764075153567638181693469097644589800066324224103680915737659228242480356123926769783926845079552\right):\\ \;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), y\right), z\right), b\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(z, \mathsf{/.f64}\left(t, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(b, \mathsf{/.f64}\left(t, y\right)\right)\right)\right)\\ \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (/.f64
  (+.f64 x (/.f64 (*.f64 y z) t))
  (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))))
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (/.f64 (*.f64 y b) t)))
   (if (or (<=.f64
            t_1
            -9999999999999999378499396381163974664505251594389679853757253159226858588823650024928554969640430609348999796218942130031825270939086493357629899207015514012385280)
           (not
            (<=.f64
             t_1
             19999999999999998743069049246737528200546615119793746550412501356903849205370206764075153567638181693469097644589800066324224103680915737659228242480356123926769783926845079552)))
     (/.f64 (+.f64 (/.f64 (*.f64 t x) y) z) b)
     (/.f64
      (+.f64 x (/.f64 z (/.f64 t y)))
      (+.f64 (+.f64 a 1) (/.f64 b (/.f64 t y)))))))
\mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, z\right), t\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\right)\right)
\begin{array}{l}
t_1 := \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\\
\mathbf{if}\;\mathsf{<=.f64}\left(t_1, -9999999999999999378499396381163974664505251594389679853757253159226858588823650024928554969640430609348999796218942130031825270939086493357629899207015514012385280\right) \lor \neg \mathsf{<=.f64}\left(t_1, 19999999999999998743069049246737528200546615119793746550412501356903849205370206764075153567638181693469097644589800066324224103680915737659228242480356123926769783926845079552\right):\\
\;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), y\right), z\right), b\right)\\

\mathbf{else}:\\
\;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(z, \mathsf{/.f64}\left(t, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(b, \mathsf{/.f64}\left(t, y\right)\right)\right)\right)\\


\end{array}

Error?

Target

Original73.8%
Target78.9%
Herbie92.8%
\[\begin{array}{l} \mathbf{if}\;\mathsf{<.f64}\left(t, \frac{-1707385670788761}{12500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000}\right):\\ \;\;\;\;\mathsf{*.f64}\left(1, \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, t\right), z\right)\right), \mathsf{/.f64}\left(1, \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, t\right), b\right)\right)\right)\right)\right)\\ \mathbf{elif}\;\mathsf{<.f64}\left(t, \frac{1518483551868623}{5000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000}\right):\\ \;\;\;\;\mathsf{/.f64}\left(z, b\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{*.f64}\left(1, \mathsf{*.f64}\left(\mathsf{+.f64}\left(x, \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, t\right), z\right)\right), \mathsf{/.f64}\left(1, \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, t\right), b\right)\right)\right)\right)\right)\\ \end{array} \]

Derivation?

  1. Split input into 2 regimes
  2. if (/.f64 (*.f64 y b) t) < -9.9999999999999994e162 or 1.9999999999999999e175 < (/.f64 (*.f64 y b) t)

    1. Initial program 36.6%

      \[\mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, z\right), t\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\right)\right) \]
    2. Taylor expanded in y around inf 33.7%

      \[\leadsto \mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, z\right), t\right)\right), \color{blue}{\mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)}\right) \]
    3. Simplified34.0%

      \[\leadsto \mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, z\right), t\right)\right), \color{blue}{\mathsf{*.f64}\left(y, \mathsf{/.f64}\left(b, t\right)\right)}\right) \]
      Proof

      [Start]33.7

      \[ \mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, z\right), t\right)\right), \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\right) \]

      associate-*r/ [<=]34.0

      \[ \mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, z\right), t\right)\right), \color{blue}{\mathsf{*.f64}\left(y, \mathsf{/.f64}\left(b, t\right)\right)}\right) \]
    4. Taylor expanded in x around 0 85.7%

      \[\leadsto \color{blue}{\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), \mathsf{*.f64}\left(y, b\right)\right), \mathsf{/.f64}\left(z, b\right)\right)} \]
    5. Taylor expanded in b around 0 88.3%

      \[\leadsto \color{blue}{\mathsf{/.f64}\left(\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), y\right), z\right), b\right)} \]

    if -9.9999999999999994e162 < (/.f64 (*.f64 y b) t) < 1.9999999999999999e175

    1. Initial program 91.8%

      \[\mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, z\right), t\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\right)\right) \]
    2. Simplified94.6%

      \[\leadsto \color{blue}{\mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(z, \mathsf{/.f64}\left(t, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, t\right), b\right)\right)\right)} \]
      Proof

      [Start]91.8

      \[ \mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, z\right), t\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\right)\right) \]

      *-commutative [=>]91.8

      \[ \mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(\color{blue}{\mathsf{*.f64}\left(z, y\right)}, t\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\right)\right) \]

      associate-/l* [=>]94.9

      \[ \mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \color{blue}{\mathsf{/.f64}\left(z, \mathsf{/.f64}\left(t, y\right)\right)}\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\right)\right) \]

      associate-*l/ [<=]94.6

      \[ \mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(z, \mathsf{/.f64}\left(t, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \color{blue}{\mathsf{*.f64}\left(\mathsf{/.f64}\left(y, t\right), b\right)}\right)\right) \]
    3. Applied egg-rr94.9%

      \[\leadsto \mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(z, \mathsf{/.f64}\left(t, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \color{blue}{\mathsf{/.f64}\left(b, \mathsf{/.f64}\left(t, y\right)\right)}\right)\right) \]
      Proof

      [Start]94.6

      \[ \mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(z, \mathsf{/.f64}\left(t, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, t\right), b\right)\right)\right) \]

      *-commutative [=>]94.6

      \[ \mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(z, \mathsf{/.f64}\left(t, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \color{blue}{\mathsf{*.f64}\left(b, \mathsf{/.f64}\left(y, t\right)\right)}\right)\right) \]

      clear-num [=>]94.6

      \[ \mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(z, \mathsf{/.f64}\left(t, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{*.f64}\left(b, \color{blue}{\mathsf{/.f64}\left(1, \mathsf{/.f64}\left(t, y\right)\right)}\right)\right)\right) \]

      un-div-inv [=>]94.9

      \[ \mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(z, \mathsf{/.f64}\left(t, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \color{blue}{\mathsf{/.f64}\left(b, \mathsf{/.f64}\left(t, y\right)\right)}\right)\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification92.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\mathsf{<=.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right), -9999999999999999378499396381163974664505251594389679853757253159226858588823650024928554969640430609348999796218942130031825270939086493357629899207015514012385280\right) \lor \neg \mathsf{<=.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right), 19999999999999998743069049246737528200546615119793746550412501356903849205370206764075153567638181693469097644589800066324224103680915737659228242480356123926769783926845079552\right):\\ \;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), y\right), z\right), b\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(z, \mathsf{/.f64}\left(t, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(b, \mathsf{/.f64}\left(t, y\right)\right)\right)\right)\\ \end{array} \]

Alternatives

Alternative 1
Accuracy73.6%
Cost2256
\[\begin{array}{l} t_1 := \mathsf{/.f64}\left(x, \mathsf{+.f64}\left(a, 1\right)\right)\\ t_2 := \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\\ \mathbf{if}\;\mathsf{<=.f64}\left(t_2, -10000000000000000000\right):\\ \;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), y\right), z\right), b\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_2, \frac{8424983333484575}{1684996666696914987166688442938726917102321526408785780068975640576}\right):\\ \;\;\;\;t_1\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_2, \frac{1742245718635205}{174224571863520493293247799005065324265472}\right):\\ \;\;\;\;\mathsf{/.f64}\left(y, \mathsf{/.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(z, t\right)\right)\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_2, 1000000000000000000000\right):\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), \mathsf{*.f64}\left(y, b\right)\right), \mathsf{/.f64}\left(z, b\right)\right)\\ \end{array} \]
Alternative 2
Accuracy74.4%
Cost2256
\[\begin{array}{l} t_1 := \mathsf{/.f64}\left(x, \mathsf{+.f64}\left(1, \mathsf{+.f64}\left(a, \mathsf{/.f64}\left(y, \mathsf{/.f64}\left(t, b\right)\right)\right)\right)\right)\\ t_2 := \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\\ \mathbf{if}\;\mathsf{<=.f64}\left(t_2, -4999999999999999965699095179735106473829597184\right):\\ \;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), y\right), z\right), b\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_2, \frac{8424983333484575}{1684996666696914987166688442938726917102321526408785780068975640576}\right):\\ \;\;\;\;t_1\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_2, \frac{1742245718635205}{174224571863520493293247799005065324265472}\right):\\ \;\;\;\;\mathsf{/.f64}\left(y, \mathsf{/.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(z, t\right)\right)\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_2, 99999999999999991611392\right):\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), \mathsf{*.f64}\left(y, b\right)\right), \mathsf{/.f64}\left(z, b\right)\right)\\ \end{array} \]
Alternative 3
Accuracy74.4%
Cost2256
\[\begin{array}{l} t_1 := \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\\ \mathbf{if}\;\mathsf{<=.f64}\left(t_1, -4999999999999999965699095179735106473829597184\right):\\ \;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), y\right), z\right), b\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_1, \frac{8424983333484575}{1684996666696914987166688442938726917102321526408785780068975640576}\right):\\ \;\;\;\;\mathsf{/.f64}\left(x, \mathsf{+.f64}\left(1, \mathsf{+.f64}\left(t_1, a\right)\right)\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_1, \frac{1742245718635205}{174224571863520493293247799005065324265472}\right):\\ \;\;\;\;\mathsf{/.f64}\left(y, \mathsf{/.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(z, t\right)\right)\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_1, 99999999999999991611392\right):\\ \;\;\;\;\mathsf{/.f64}\left(x, \mathsf{+.f64}\left(1, \mathsf{+.f64}\left(a, \mathsf{/.f64}\left(y, \mathsf{/.f64}\left(t, b\right)\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), \mathsf{*.f64}\left(y, b\right)\right), \mathsf{/.f64}\left(z, b\right)\right)\\ \end{array} \]
Alternative 4
Accuracy73.8%
Cost2128
\[\begin{array}{l} t_1 := \mathsf{/.f64}\left(x, \mathsf{+.f64}\left(a, 1\right)\right)\\ t_2 := \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\\ t_3 := \mathsf{/.f64}\left(\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), y\right), z\right), b\right)\\ \mathbf{if}\;\mathsf{<=.f64}\left(t_2, -10000000000000000000\right):\\ \;\;\;\;t_3\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_2, \frac{8424983333484575}{1684996666696914987166688442938726917102321526408785780068975640576}\right):\\ \;\;\;\;t_1\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_2, \frac{1742245718635205}{174224571863520493293247799005065324265472}\right):\\ \;\;\;\;\mathsf{/.f64}\left(y, \mathsf{/.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(z, t\right)\right)\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_2, 1000000000000000000000\right):\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_3\\ \end{array} \]
Alternative 5
Accuracy67.3%
Cost1872
\[\begin{array}{l} t_1 := \mathsf{/.f64}\left(x, \mathsf{+.f64}\left(a, 1\right)\right)\\ t_2 := \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\\ \mathbf{if}\;\mathsf{<=.f64}\left(t_2, -10000000000000000000\right):\\ \;\;\;\;\mathsf{/.f64}\left(z, b\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_2, \frac{8424983333484575}{1684996666696914987166688442938726917102321526408785780068975640576}\right):\\ \;\;\;\;t_1\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_2, \frac{1742245718635205}{174224571863520493293247799005065324265472}\right):\\ \;\;\;\;\mathsf{/.f64}\left(y, \mathsf{/.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{/.f64}\left(z, t\right)\right)\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_2, 1000000000000000000000\right):\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\mathsf{/.f64}\left(z, b\right)\\ \end{array} \]
Alternative 6
Accuracy92.6%
Cost1865
\[\begin{array}{l} t_1 := \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\\ \mathbf{if}\;\mathsf{<=.f64}\left(t_1, -9999999999999999378499396381163974664505251594389679853757253159226858588823650024928554969640430609348999796218942130031825270939086493357629899207015514012385280\right) \lor \neg \mathsf{<=.f64}\left(t_1, 19999999999999998743069049246737528200546615119793746550412501356903849205370206764075153567638181693469097644589800066324224103680915737659228242480356123926769783926845079552\right):\\ \;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), y\right), z\right), b\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(z, \mathsf{/.f64}\left(t, y\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{*.f64}\left(b, \mathsf{/.f64}\left(y, t\right)\right)\right)\right)\\ \end{array} \]
Alternative 7
Accuracy88.3%
Cost1864
\[\begin{array}{l} t_1 := \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\\ \mathbf{if}\;\mathsf{<=.f64}\left(t_1, -49999999999999999661047433718081398823085422097203200\right):\\ \;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), y\right), z\right), b\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_1, 199999999999999995409902653049067325689368543984830001225999194946398690436157982260652258896302309376\right):\\ \;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{*.f64}\left(y, \mathsf{/.f64}\left(z, t\right)\right)\right), \mathsf{+.f64}\left(\mathsf{+.f64}\left(a, 1\right), \mathsf{*.f64}\left(b, \mathsf{/.f64}\left(y, t\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), \mathsf{*.f64}\left(y, b\right)\right), \mathsf{/.f64}\left(z, b\right)\right)\\ \end{array} \]
Alternative 8
Accuracy87.0%
Cost1480
\[\begin{array}{l} t_1 := \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\\ \mathbf{if}\;\mathsf{<=.f64}\left(t_1, -10000000000000000000\right):\\ \;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), y\right), z\right), b\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_1, 1000000000000000000000\right):\\ \;\;\;\;\mathsf{/.f64}\left(\mathsf{+.f64}\left(x, \mathsf{/.f64}\left(z, \mathsf{/.f64}\left(t, y\right)\right)\right), \mathsf{+.f64}\left(a, 1\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(t, x\right), \mathsf{*.f64}\left(y, b\right)\right), \mathsf{/.f64}\left(z, b\right)\right)\\ \end{array} \]
Alternative 9
Accuracy67.6%
Cost1096
\[\begin{array}{l} t_1 := \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, b\right), t\right)\\ \mathbf{if}\;\mathsf{<=.f64}\left(t_1, -10000000000000000000\right):\\ \;\;\;\;\mathsf{/.f64}\left(z, b\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(t_1, 1000000000000000000000\right):\\ \;\;\;\;\mathsf{/.f64}\left(x, \mathsf{+.f64}\left(a, 1\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{/.f64}\left(z, b\right)\\ \end{array} \]
Alternative 10
Accuracy41.4%
Cost984
\[\begin{array}{l} \mathbf{if}\;\mathsf{<=.f64}\left(a, -600000000000000043518861828917541075695024645787913173310926093287424\right):\\ \;\;\;\;\mathsf{/.f64}\left(x, a\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(a, \frac{-3161260813162947}{8543948143683640329580086824678208458410818089426611079788166431288878903122562200091848347746304}\right):\\ \;\;\;\;\mathsf{/.f64}\left(z, b\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(a, \frac{-3058964957112499}{1747979975492856518824388667826833403974715525645181428798916607807071777670465341756914322865272727992514618482604963383447074020817466839626771608982213111603568988524121832413745194182066575698549805189925857389888339453536229468710863470854144}\right):\\ \;\;\;\;x\\ \mathbf{elif}\;\mathsf{<=.f64}\left(a, \frac{-541942639517149}{47125446914534694131579097993419809976955095716785201420286055195012674566357244479460731079205201122720511132925006540350105785156086431086764996857554304860885586653967937772270969055149056096849908977391371752266308172471982589601097478449614615258949356272900190565812730839296826751014759649673012612226351104}\right):\\ \;\;\;\;\mathsf{/.f64}\left(z, b\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(a, \frac{2671230065510023}{7029552803973744348141466418259346654483901747346744739219930582205996219799199797373501072037329464296751422864876398630012915711709843264075804970101818523648}\right):\\ \;\;\;\;x\\ \mathbf{elif}\;\mathsf{<=.f64}\left(a, \frac{2271629875608987}{81129638414606681695789005144064}\right):\\ \;\;\;\;\mathsf{/.f64}\left(z, b\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{/.f64}\left(x, a\right)\\ \end{array} \]
Alternative 11
Accuracy41.7%
Cost456
\[\begin{array}{l} \mathbf{if}\;\mathsf{<=.f64}\left(a, \frac{-7378697629483821}{36893488147419103232}\right):\\ \;\;\;\;\mathsf{/.f64}\left(x, a\right)\\ \mathbf{elif}\;\mathsf{<=.f64}\left(a, \frac{5312662293228351}{295147905179352825856}\right):\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;\mathsf{/.f64}\left(x, a\right)\\ \end{array} \]
Alternative 12
Accuracy19.8%
Cost64
\[x \]

Error

Reproduce?

herbie shell --seed 2023144 
(FPCore (x y z t a b)
  :name "Diagrams.Solve.Tridiagonal:solveCyclicTriDiagonal from diagrams-solve-0.1, B"
  :precision binary64

  :herbie-target
  (if (< t -1.3659085366310088e-271) (* 1.0 (* (+ x (* (/ y t) z)) (/ 1.0 (+ (+ a 1.0) (* (/ y t) b))))) (if (< t 3.036967103737246e-130) (/ z b) (* 1.0 (* (+ x (* (/ y t) z)) (/ 1.0 (+ (+ a 1.0) (* (/ y t) b)))))))

  (/ (+ x (/ (* y z) t)) (+ (+ a 1.0) (/ (* y b) t))))