\[x \cdot \frac{\frac{y}{z} \cdot t}{t}\]
Test:
Graphics.Rendering.Chart.Backend.Diagrams:calcFontMetrics from Chart-diagrams-1.5.1
Bits:
128 bits
Bits error versus x
Bits error versus y
Bits error versus z
Bits error versus t
Time: 6.9 s
Input Error: 14.3
Output Error: 2.4
Log:
Profile: 🕒
\(\begin{cases} x \cdot \frac{y}{z} & \text{when } \frac{\frac{y}{z} \cdot t}{t} \le -1.8704206502295046 \cdot 10^{-243} \\ \left(x \cdot y\right) \cdot \frac{1}{z} & \text{when } \frac{\frac{y}{z} \cdot t}{t} \le 0.0 \\ x \cdot \frac{y}{z} & \text{when } \frac{\frac{y}{z} \cdot t}{t} \le 1.204511383671618 \cdot 10^{+236} \\ \frac{y \cdot x}{z} & \text{otherwise} \end{cases}\)

    if (/ (* (/ y z) t) t) < -1.8704206502295046e-243 or 0.0 < (/ (* (/ y z) t) t) < 1.204511383671618e+236

    1. Started with
      \[x \cdot \frac{\frac{y}{z} \cdot t}{t}\]
      5.7
    2. Applied simplify to get
      \[\color{red}{x \cdot \frac{\frac{y}{z} \cdot t}{t}} \leadsto \color{blue}{x \cdot \frac{y}{z}}\]
      2.6

    if -1.8704206502295046e-243 < (/ (* (/ y z) t) t) < 0.0

    1. Started with
      \[x \cdot \frac{\frac{y}{z} \cdot t}{t}\]
      26.7
    2. Applied simplify to get
      \[\color{red}{x \cdot \frac{\frac{y}{z} \cdot t}{t}} \leadsto \color{blue}{x \cdot \frac{y}{z}}\]
      11.3
    3. Using strategy rm
      11.3
    4. Applied div-inv to get
      \[x \cdot \color{red}{\frac{y}{z}} \leadsto x \cdot \color{blue}{\left(y \cdot \frac{1}{z}\right)}\]
      11.3
    5. Applied associate-*r* to get
      \[\color{red}{x \cdot \left(y \cdot \frac{1}{z}\right)} \leadsto \color{blue}{\left(x \cdot y\right) \cdot \frac{1}{z}}\]
      1.5

    if 1.204511383671618e+236 < (/ (* (/ y z) t) t)

    1. Started with
      \[x \cdot \frac{\frac{y}{z} \cdot t}{t}\]
      51.5
    2. Applied simplify to get
      \[\color{red}{x \cdot \frac{\frac{y}{z} \cdot t}{t}} \leadsto \color{blue}{x \cdot \frac{y}{z}}\]
      21.1
    3. Applied taylor to get
      \[x \cdot \frac{y}{z} \leadsto \frac{y \cdot x}{z}\]
      4.3
    4. Taylor expanded around 0 to get
      \[\color{red}{\frac{y \cdot x}{z}} \leadsto \color{blue}{\frac{y \cdot x}{z}}\]
      4.3

  1. Removed slow pow expressions

Original test:


(lambda ((x default) (y default) (z default) (t default))
  #:name "Graphics.Rendering.Chart.Backend.Diagrams:calcFontMetrics from Chart-diagrams-1.5.1"
  (* x (/ (* (/ y z) t) t)))