Toniolo and Linder, Equation (2)

Percentage Accurate: 83.6% → 98.3%
Time: 16.9s
Alternatives: 17
Speedup: 1.9×

Specification

?
\[\begin{array}{l} \\ \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (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 - pow((Om / Omc), 2.0)) / (1.0 + (2.0 * pow((t / l), 2.0))))));
}
real(8) function code(t, l, om, omc)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: omc
    code = asin(sqrt(((1.0d0 - ((om / omc) ** 2.0d0)) / (1.0d0 + (2.0d0 * ((t / l) ** 2.0d0))))))
end function
public static double code(double t, double l, double Om, double Omc) {
	return Math.asin(Math.sqrt(((1.0 - Math.pow((Om / Omc), 2.0)) / (1.0 + (2.0 * Math.pow((t / l), 2.0))))));
}
def code(t, l, Om, Omc):
	return math.asin(math.sqrt(((1.0 - math.pow((Om / Omc), 2.0)) / (1.0 + (2.0 * math.pow((t / l), 2.0))))))
function code(t, l, Om, Omc)
	return asin(sqrt(Float64(Float64(1.0 - (Float64(Om / Omc) ^ 2.0)) / Float64(1.0 + Float64(2.0 * (Float64(t / l) ^ 2.0))))))
end
function tmp = code(t, l, Om, Omc)
	tmp = asin(sqrt(((1.0 - ((Om / Omc) ^ 2.0)) / (1.0 + (2.0 * ((t / l) ^ 2.0))))));
end
code[t_, l_, Om_, Omc_] := N[ArcSin[N[Sqrt[N[(N[(1.0 - N[Power[N[(Om / Omc), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] / N[(1.0 + N[(2.0 * N[Power[N[(t / l), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]
\begin{array}{l}

\\
\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)
\end{array}

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

The average percentage accuracy by input value. Horizontal axis shows value of an input variable; the variable is choosen in the title. Vertical axis is accuracy; higher is better. Red represent the original program, while blue represents Herbie's suggestion. These can be toggled with buttons below the plot. The line is an average while dots represent individual samples.

Accuracy vs Speed?

Herbie found 17 alternatives:

AlternativeAccuracySpeedup
The accuracy (vertical axis) and speed (horizontal axis) of each alternatives. Up and to the right is better. The red square shows the initial program, and each blue circle shows an alternative.The line shows the best available speed-accuracy tradeoffs.

Initial Program: 83.6% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (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 - pow((Om / Omc), 2.0)) / (1.0 + (2.0 * pow((t / l), 2.0))))));
}
real(8) function code(t, l, om, omc)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: omc
    code = asin(sqrt(((1.0d0 - ((om / omc) ** 2.0d0)) / (1.0d0 + (2.0d0 * ((t / l) ** 2.0d0))))))
end function
public static double code(double t, double l, double Om, double Omc) {
	return Math.asin(Math.sqrt(((1.0 - Math.pow((Om / Omc), 2.0)) / (1.0 + (2.0 * Math.pow((t / l), 2.0))))));
}
def code(t, l, Om, Omc):
	return math.asin(math.sqrt(((1.0 - math.pow((Om / Omc), 2.0)) / (1.0 + (2.0 * math.pow((t / l), 2.0))))))
function code(t, l, Om, Omc)
	return asin(sqrt(Float64(Float64(1.0 - (Float64(Om / Omc) ^ 2.0)) / Float64(1.0 + Float64(2.0 * (Float64(t / l) ^ 2.0))))))
end
function tmp = code(t, l, Om, Omc)
	tmp = asin(sqrt(((1.0 - ((Om / Omc) ^ 2.0)) / (1.0 + (2.0 * ((t / l) ^ 2.0))))));
end
code[t_, l_, Om_, Omc_] := N[ArcSin[N[Sqrt[N[(N[(1.0 - N[Power[N[(Om / Omc), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] / N[(1.0 + N[(2.0 * N[Power[N[(t / l), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]
\begin{array}{l}

\\
\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)
\end{array}

Alternative 1: 98.3% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \sin^{-1} \left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{\sqrt{2} \cdot t}{\ell}\right)}\right) \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (asin
  (/ (sqrt (- 1.0 (pow (/ Om Omc) 2.0))) (hypot 1.0 (/ (* (sqrt 2.0) t) l)))))
double code(double t, double l, double Om, double Omc) {
	return asin((sqrt((1.0 - pow((Om / Omc), 2.0))) / hypot(1.0, ((sqrt(2.0) * t) / l))));
}
public static double code(double t, double l, double Om, double Omc) {
	return Math.asin((Math.sqrt((1.0 - Math.pow((Om / Omc), 2.0))) / Math.hypot(1.0, ((Math.sqrt(2.0) * t) / l))));
}
def code(t, l, Om, Omc):
	return math.asin((math.sqrt((1.0 - math.pow((Om / Omc), 2.0))) / math.hypot(1.0, ((math.sqrt(2.0) * t) / l))))
function code(t, l, Om, Omc)
	return asin(Float64(sqrt(Float64(1.0 - (Float64(Om / Omc) ^ 2.0))) / hypot(1.0, Float64(Float64(sqrt(2.0) * t) / l))))
end
function tmp = code(t, l, Om, Omc)
	tmp = asin((sqrt((1.0 - ((Om / Omc) ^ 2.0))) / hypot(1.0, ((sqrt(2.0) * t) / l))));
end
code[t_, l_, Om_, Omc_] := N[ArcSin[N[(N[Sqrt[N[(1.0 - N[Power[N[(Om / Omc), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / N[Sqrt[1.0 ^ 2 + N[(N[(N[Sqrt[2.0], $MachinePrecision] * t), $MachinePrecision] / l), $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}

\\
\sin^{-1} \left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{\sqrt{2} \cdot t}{\ell}\right)}\right)
\end{array}
Derivation
  1. Initial program 82.2%

    \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
  2. Step-by-step derivation
    1. sqrt-div82.1%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
    2. div-inv82.1%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
    3. add-sqr-sqrt82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + \color{blue}{\sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}}}\right) \]
    4. hypot-1-def82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\color{blue}{\mathsf{hypot}\left(1, \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}\right)}}\right) \]
    5. *-commutative82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{{\left(\frac{t}{\ell}\right)}^{2} \cdot 2}}\right)}\right) \]
    6. sqrt-prod82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\sqrt{{\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2}}\right)}\right) \]
    7. unpow282.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{\frac{t}{\ell} \cdot \frac{t}{\ell}}} \cdot \sqrt{2}\right)}\right) \]
    8. sqrt-prod50.4%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\left(\sqrt{\frac{t}{\ell}} \cdot \sqrt{\frac{t}{\ell}}\right)} \cdot \sqrt{2}\right)}\right) \]
    9. add-sqr-sqrt98.0%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\frac{t}{\ell}} \cdot \sqrt{2}\right)}\right) \]
  3. Applied egg-rr98.0%

    \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
  4. Step-by-step derivation
    1. unpow298.0%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    2. times-frac84.3%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om \cdot Om}{Omc \cdot Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    3. unpow284.3%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{{Om}^{2}}}{Omc \cdot Omc}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    4. unpow284.3%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{{Om}^{2}}{\color{blue}{{Omc}^{2}}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    5. associate-*r/84.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot 1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    6. *-rgt-identity84.3%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    7. unpow284.3%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    8. unpow284.3%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    9. times-frac98.0%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    10. unpow298.0%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
  5. Simplified98.0%

    \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
  6. Taylor expanded in t around 0 98.0%

    \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \color{blue}{\frac{\sqrt{2} \cdot t}{\ell}}\right)}\right) \]
  7. Final simplification98.0%

    \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{\sqrt{2} \cdot t}{\ell}\right)}\right) \]

Alternative 2: 98.3% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \sin^{-1} \left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \sqrt{2} \cdot \frac{t}{\ell}\right)}\right) \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (asin
  (/ (sqrt (- 1.0 (pow (/ Om Omc) 2.0))) (hypot 1.0 (* (sqrt 2.0) (/ t l))))))
double code(double t, double l, double Om, double Omc) {
	return asin((sqrt((1.0 - pow((Om / Omc), 2.0))) / hypot(1.0, (sqrt(2.0) * (t / l)))));
}
public static double code(double t, double l, double Om, double Omc) {
	return Math.asin((Math.sqrt((1.0 - Math.pow((Om / Omc), 2.0))) / Math.hypot(1.0, (Math.sqrt(2.0) * (t / l)))));
}
def code(t, l, Om, Omc):
	return math.asin((math.sqrt((1.0 - math.pow((Om / Omc), 2.0))) / math.hypot(1.0, (math.sqrt(2.0) * (t / l)))))
function code(t, l, Om, Omc)
	return asin(Float64(sqrt(Float64(1.0 - (Float64(Om / Omc) ^ 2.0))) / hypot(1.0, Float64(sqrt(2.0) * Float64(t / l)))))
end
function tmp = code(t, l, Om, Omc)
	tmp = asin((sqrt((1.0 - ((Om / Omc) ^ 2.0))) / hypot(1.0, (sqrt(2.0) * (t / l)))));
end
code[t_, l_, Om_, Omc_] := N[ArcSin[N[(N[Sqrt[N[(1.0 - N[Power[N[(Om / Omc), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / N[Sqrt[1.0 ^ 2 + N[(N[Sqrt[2.0], $MachinePrecision] * N[(t / l), $MachinePrecision]), $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}

\\
\sin^{-1} \left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \sqrt{2} \cdot \frac{t}{\ell}\right)}\right)
\end{array}
Derivation
  1. Initial program 82.2%

    \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
  2. Step-by-step derivation
    1. sqrt-div82.1%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
    2. div-inv82.1%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
    3. add-sqr-sqrt82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + \color{blue}{\sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}}}\right) \]
    4. hypot-1-def82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\color{blue}{\mathsf{hypot}\left(1, \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}\right)}}\right) \]
    5. *-commutative82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{{\left(\frac{t}{\ell}\right)}^{2} \cdot 2}}\right)}\right) \]
    6. sqrt-prod82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\sqrt{{\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2}}\right)}\right) \]
    7. unpow282.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{\frac{t}{\ell} \cdot \frac{t}{\ell}}} \cdot \sqrt{2}\right)}\right) \]
    8. sqrt-prod50.4%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\left(\sqrt{\frac{t}{\ell}} \cdot \sqrt{\frac{t}{\ell}}\right)} \cdot \sqrt{2}\right)}\right) \]
    9. add-sqr-sqrt98.0%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\frac{t}{\ell}} \cdot \sqrt{2}\right)}\right) \]
  3. Applied egg-rr98.0%

    \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
  4. Step-by-step derivation
    1. unpow298.0%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    2. times-frac84.3%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om \cdot Om}{Omc \cdot Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    3. unpow284.3%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{{Om}^{2}}}{Omc \cdot Omc}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    4. unpow284.3%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{{Om}^{2}}{\color{blue}{{Omc}^{2}}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    5. associate-*r/84.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot 1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    6. *-rgt-identity84.3%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    7. unpow284.3%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    8. unpow284.3%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    9. times-frac98.0%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    10. unpow298.0%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
  5. Simplified98.0%

    \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
  6. Final simplification98.0%

    \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \sqrt{2} \cdot \frac{t}{\ell}\right)}\right) \]

Alternative 3: 97.7% accurate, 1.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -5 \cdot 10^{+159}:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot \left(1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\right)}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 10^{+154}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right)}}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\frac{\mathsf{fma}\left(Om \cdot \frac{Om}{Omc \cdot Omc}, -0.5, 1\right)}{\sqrt{2} \cdot \frac{t}{\ell}}\right)\\ \end{array} \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (if (<= (/ t l) -5e+159)
   (- (asin (* l (/ (sqrt (* 0.5 (- 1.0 (/ (/ Om Omc) (/ Omc Om))))) t))))
   (if (<= (/ t l) 1e+154)
     (asin
      (sqrt
       (/ (- 1.0 (pow (/ Om Omc) 2.0)) (+ 1.0 (* 2.0 (* (/ t l) (/ t l)))))))
     (asin
      (/ (fma (* Om (/ Om (* Omc Omc))) -0.5 1.0) (* (sqrt 2.0) (/ t l)))))))
double code(double t, double l, double Om, double Omc) {
	double tmp;
	if ((t / l) <= -5e+159) {
		tmp = -asin((l * (sqrt((0.5 * (1.0 - ((Om / Omc) / (Omc / Om))))) / t)));
	} else if ((t / l) <= 1e+154) {
		tmp = asin(sqrt(((1.0 - pow((Om / Omc), 2.0)) / (1.0 + (2.0 * ((t / l) * (t / l)))))));
	} else {
		tmp = asin((fma((Om * (Om / (Omc * Omc))), -0.5, 1.0) / (sqrt(2.0) * (t / l))));
	}
	return tmp;
}
function code(t, l, Om, Omc)
	tmp = 0.0
	if (Float64(t / l) <= -5e+159)
		tmp = Float64(-asin(Float64(l * Float64(sqrt(Float64(0.5 * Float64(1.0 - Float64(Float64(Om / Omc) / Float64(Omc / Om))))) / t))));
	elseif (Float64(t / l) <= 1e+154)
		tmp = asin(sqrt(Float64(Float64(1.0 - (Float64(Om / Omc) ^ 2.0)) / Float64(1.0 + Float64(2.0 * Float64(Float64(t / l) * Float64(t / l)))))));
	else
		tmp = asin(Float64(fma(Float64(Om * Float64(Om / Float64(Omc * Omc))), -0.5, 1.0) / Float64(sqrt(2.0) * Float64(t / l))));
	end
	return tmp
end
code[t_, l_, Om_, Omc_] := If[LessEqual[N[(t / l), $MachinePrecision], -5e+159], (-N[ArcSin[N[(l * N[(N[Sqrt[N[(0.5 * N[(1.0 - N[(N[(Om / Omc), $MachinePrecision] / N[(Omc / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), If[LessEqual[N[(t / l), $MachinePrecision], 1e+154], N[ArcSin[N[Sqrt[N[(N[(1.0 - N[Power[N[(Om / Omc), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] / N[(1.0 + N[(2.0 * N[(N[(t / l), $MachinePrecision] * N[(t / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision], N[ArcSin[N[(N[(N[(Om * N[(Om / N[(Omc * Omc), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * -0.5 + 1.0), $MachinePrecision] / N[(N[Sqrt[2.0], $MachinePrecision] * N[(t / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;\frac{t}{\ell} \leq -5 \cdot 10^{+159}:\\
\;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot \left(1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\right)}}{t}\right)\\

\mathbf{elif}\;\frac{t}{\ell} \leq 10^{+154}:\\
\;\;\;\;\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right)}}\right)\\

\mathbf{else}:\\
\;\;\;\;\sin^{-1} \left(\frac{\mathsf{fma}\left(Om \cdot \frac{Om}{Omc \cdot Omc}, -0.5, 1\right)}{\sqrt{2} \cdot \frac{t}{\ell}}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 t l) < -5.00000000000000003e159

    1. Initial program 32.9%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around -inf 89.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \left(\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg89.3%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
      2. *-commutative89.3%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}}\right) \]
      3. unpow289.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      4. unpow289.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      5. times-frac99.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      6. unpow299.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      7. associate-/l*99.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\frac{\sqrt{0.5}}{\frac{t}{\ell}}}\right) \]
    4. Simplified99.4%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    5. Step-by-step derivation
      1. expm1-log1p-u99.4%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-udef32.9%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
      3. asin-neg32.9%

        \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{-\sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      4. associate-*r/32.9%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      5. pow1/232.9%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      6. pow1/232.9%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5} \cdot \color{blue}{{0.5}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      7. pow-prod-down32.9%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
    6. Applied egg-rr32.9%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
    7. Step-by-step derivation
      1. expm1-def99.3%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-log1p99.3%

        \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)} \]
      3. associate-/r/99.6%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{t} \cdot \ell\right)} \]
      4. unpow1/299.6%

        \[\leadsto -\sin^{-1} \left(\frac{\color{blue}{\sqrt{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5}}}{t} \cdot \ell\right) \]
      5. *-commutative99.6%

        \[\leadsto -\sin^{-1} \left(\frac{\sqrt{\color{blue}{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}}{t} \cdot \ell\right) \]
    8. Simplified99.6%

      \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}{t} \cdot \ell\right)} \]
    9. Step-by-step derivation
      1. unpow23.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      2. clear-num3.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}}\right) \]
      3. un-div-inv3.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]
    10. Applied egg-rr99.6%

      \[\leadsto -\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)}}{t} \cdot \ell\right) \]

    if -5.00000000000000003e159 < (/.f64 t l) < 1.00000000000000004e154

    1. Initial program 98.3%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Step-by-step derivation
      1. unpow298.3%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right)}}}\right) \]
    3. Applied egg-rr98.3%

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

    if 1.00000000000000004e154 < (/.f64 t l)

    1. Initial program 52.0%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Step-by-step derivation
      1. sqrt-div52.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      2. div-inv52.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      3. add-sqr-sqrt52.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + \color{blue}{\sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}}}\right) \]
      4. hypot-1-def52.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\color{blue}{\mathsf{hypot}\left(1, \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}\right)}}\right) \]
      5. *-commutative52.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{{\left(\frac{t}{\ell}\right)}^{2} \cdot 2}}\right)}\right) \]
      6. sqrt-prod52.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\sqrt{{\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2}}\right)}\right) \]
      7. unpow252.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{\frac{t}{\ell} \cdot \frac{t}{\ell}}} \cdot \sqrt{2}\right)}\right) \]
      8. sqrt-prod95.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\left(\sqrt{\frac{t}{\ell}} \cdot \sqrt{\frac{t}{\ell}}\right)} \cdot \sqrt{2}\right)}\right) \]
      9. add-sqr-sqrt95.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\frac{t}{\ell}} \cdot \sqrt{2}\right)}\right) \]
    3. Applied egg-rr95.4%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    4. Step-by-step derivation
      1. unpow295.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      2. times-frac77.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om \cdot Om}{Omc \cdot Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      3. unpow277.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{{Om}^{2}}}{Omc \cdot Omc}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      4. unpow277.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{{Om}^{2}}{\color{blue}{{Omc}^{2}}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      5. associate-*r/77.8%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot 1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
      6. *-rgt-identity77.8%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      7. unpow277.8%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      8. unpow277.8%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      9. times-frac95.4%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      10. unpow295.4%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    5. Simplified95.4%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    6. Taylor expanded in Om around 0 77.8%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    7. Step-by-step derivation
      1. unpow22.8%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}\right) \]
      2. unpow22.8%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}\right) \]
    8. Simplified77.8%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    9. Step-by-step derivation
      1. times-frac3.4%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{Om}{Omc} \cdot \frac{Om}{Omc}\right)}\right) \]
      2. clear-num3.4%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \left(\frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}\right)\right) \]
      3. div-inv3.4%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right) \]
      4. associate-/r/3.4%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}\right) \]
    10. Applied egg-rr95.4%

      \[\leadsto \sin^{-1} \left(\frac{1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    11. Taylor expanded in t around inf 81.9%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\left(1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}\right) \cdot \ell}{\sqrt{2} \cdot t}\right)} \]
    12. Step-by-step derivation
      1. associate-/l*77.8%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}{\frac{\sqrt{2} \cdot t}{\ell}}\right)} \]
      2. +-commutative77.8%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{-0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}} + 1}}{\frac{\sqrt{2} \cdot t}{\ell}}\right) \]
      3. *-commutative77.8%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\frac{{Om}^{2}}{{Omc}^{2}} \cdot -0.5} + 1}{\frac{\sqrt{2} \cdot t}{\ell}}\right) \]
      4. unpow277.8%

        \[\leadsto \sin^{-1} \left(\frac{\frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}} \cdot -0.5 + 1}{\frac{\sqrt{2} \cdot t}{\ell}}\right) \]
      5. associate-*r/89.6%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\left(Om \cdot \frac{Om}{{Omc}^{2}}\right)} \cdot -0.5 + 1}{\frac{\sqrt{2} \cdot t}{\ell}}\right) \]
      6. unpow289.6%

        \[\leadsto \sin^{-1} \left(\frac{\left(Om \cdot \frac{Om}{\color{blue}{Omc \cdot Omc}}\right) \cdot -0.5 + 1}{\frac{\sqrt{2} \cdot t}{\ell}}\right) \]
      7. fma-udef89.6%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\mathsf{fma}\left(Om \cdot \frac{Om}{Omc \cdot Omc}, -0.5, 1\right)}}{\frac{\sqrt{2} \cdot t}{\ell}}\right) \]
      8. associate-*r/89.6%

        \[\leadsto \sin^{-1} \left(\frac{\mathsf{fma}\left(Om \cdot \frac{Om}{Omc \cdot Omc}, -0.5, 1\right)}{\color{blue}{\sqrt{2} \cdot \frac{t}{\ell}}}\right) \]
    13. Simplified89.6%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\mathsf{fma}\left(Om \cdot \frac{Om}{Omc \cdot Omc}, -0.5, 1\right)}{\sqrt{2} \cdot \frac{t}{\ell}}\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification97.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -5 \cdot 10^{+159}:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot \left(1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\right)}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 10^{+154}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right)}}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\frac{\mathsf{fma}\left(Om \cdot \frac{Om}{Omc \cdot Omc}, -0.5, 1\right)}{\sqrt{2} \cdot \frac{t}{\ell}}\right)\\ \end{array} \]

Alternative 4: 95.9% accurate, 1.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := 1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\\ \mathbf{if}\;\frac{t}{\ell} \leq -5.5 \cdot 10^{+25}:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot t_1}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 10^{+154}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{\frac{t_1}{1 + 2 \cdot \frac{t \cdot \frac{t}{\ell}}{\ell}}}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{1 - \frac{Om \cdot Om}{Omc \cdot Omc}} \cdot \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\right)\\ \end{array} \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (let* ((t_1 (- 1.0 (/ (/ Om Omc) (/ Omc Om)))))
   (if (<= (/ t l) -5.5e+25)
     (- (asin (* l (/ (sqrt (* 0.5 t_1)) t))))
     (if (<= (/ t l) 1e+154)
       (asin (sqrt (/ t_1 (+ 1.0 (* 2.0 (/ (* t (/ t l)) l))))))
       (asin
        (*
         (sqrt (- 1.0 (/ (* Om Om) (* Omc Omc))))
         (* l (/ (sqrt 0.5) t))))))))
double code(double t, double l, double Om, double Omc) {
	double t_1 = 1.0 - ((Om / Omc) / (Omc / Om));
	double tmp;
	if ((t / l) <= -5.5e+25) {
		tmp = -asin((l * (sqrt((0.5 * t_1)) / t)));
	} else if ((t / l) <= 1e+154) {
		tmp = asin(sqrt((t_1 / (1.0 + (2.0 * ((t * (t / l)) / l))))));
	} else {
		tmp = asin((sqrt((1.0 - ((Om * Om) / (Omc * Omc)))) * (l * (sqrt(0.5) / t))));
	}
	return tmp;
}
real(8) function code(t, l, om, omc)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: omc
    real(8) :: t_1
    real(8) :: tmp
    t_1 = 1.0d0 - ((om / omc) / (omc / om))
    if ((t / l) <= (-5.5d+25)) then
        tmp = -asin((l * (sqrt((0.5d0 * t_1)) / t)))
    else if ((t / l) <= 1d+154) then
        tmp = asin(sqrt((t_1 / (1.0d0 + (2.0d0 * ((t * (t / l)) / l))))))
    else
        tmp = asin((sqrt((1.0d0 - ((om * om) / (omc * omc)))) * (l * (sqrt(0.5d0) / t))))
    end if
    code = tmp
end function
public static double code(double t, double l, double Om, double Omc) {
	double t_1 = 1.0 - ((Om / Omc) / (Omc / Om));
	double tmp;
	if ((t / l) <= -5.5e+25) {
		tmp = -Math.asin((l * (Math.sqrt((0.5 * t_1)) / t)));
	} else if ((t / l) <= 1e+154) {
		tmp = Math.asin(Math.sqrt((t_1 / (1.0 + (2.0 * ((t * (t / l)) / l))))));
	} else {
		tmp = Math.asin((Math.sqrt((1.0 - ((Om * Om) / (Omc * Omc)))) * (l * (Math.sqrt(0.5) / t))));
	}
	return tmp;
}
def code(t, l, Om, Omc):
	t_1 = 1.0 - ((Om / Omc) / (Omc / Om))
	tmp = 0
	if (t / l) <= -5.5e+25:
		tmp = -math.asin((l * (math.sqrt((0.5 * t_1)) / t)))
	elif (t / l) <= 1e+154:
		tmp = math.asin(math.sqrt((t_1 / (1.0 + (2.0 * ((t * (t / l)) / l))))))
	else:
		tmp = math.asin((math.sqrt((1.0 - ((Om * Om) / (Omc * Omc)))) * (l * (math.sqrt(0.5) / t))))
	return tmp
function code(t, l, Om, Omc)
	t_1 = Float64(1.0 - Float64(Float64(Om / Omc) / Float64(Omc / Om)))
	tmp = 0.0
	if (Float64(t / l) <= -5.5e+25)
		tmp = Float64(-asin(Float64(l * Float64(sqrt(Float64(0.5 * t_1)) / t))));
	elseif (Float64(t / l) <= 1e+154)
		tmp = asin(sqrt(Float64(t_1 / Float64(1.0 + Float64(2.0 * Float64(Float64(t * Float64(t / l)) / l))))));
	else
		tmp = asin(Float64(sqrt(Float64(1.0 - Float64(Float64(Om * Om) / Float64(Omc * Omc)))) * Float64(l * Float64(sqrt(0.5) / t))));
	end
	return tmp
end
function tmp_2 = code(t, l, Om, Omc)
	t_1 = 1.0 - ((Om / Omc) / (Omc / Om));
	tmp = 0.0;
	if ((t / l) <= -5.5e+25)
		tmp = -asin((l * (sqrt((0.5 * t_1)) / t)));
	elseif ((t / l) <= 1e+154)
		tmp = asin(sqrt((t_1 / (1.0 + (2.0 * ((t * (t / l)) / l))))));
	else
		tmp = asin((sqrt((1.0 - ((Om * Om) / (Omc * Omc)))) * (l * (sqrt(0.5) / t))));
	end
	tmp_2 = tmp;
end
code[t_, l_, Om_, Omc_] := Block[{t$95$1 = N[(1.0 - N[(N[(Om / Omc), $MachinePrecision] / N[(Omc / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(t / l), $MachinePrecision], -5.5e+25], (-N[ArcSin[N[(l * N[(N[Sqrt[N[(0.5 * t$95$1), $MachinePrecision]], $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), If[LessEqual[N[(t / l), $MachinePrecision], 1e+154], N[ArcSin[N[Sqrt[N[(t$95$1 / N[(1.0 + N[(2.0 * N[(N[(t * N[(t / l), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision], N[ArcSin[N[(N[Sqrt[N[(1.0 - N[(N[(Om * Om), $MachinePrecision] / N[(Omc * Omc), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[(l * N[(N[Sqrt[0.5], $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := 1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\\
\mathbf{if}\;\frac{t}{\ell} \leq -5.5 \cdot 10^{+25}:\\
\;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot t_1}}{t}\right)\\

\mathbf{elif}\;\frac{t}{\ell} \leq 10^{+154}:\\
\;\;\;\;\sin^{-1} \left(\sqrt{\frac{t_1}{1 + 2 \cdot \frac{t \cdot \frac{t}{\ell}}{\ell}}}\right)\\

\mathbf{else}:\\
\;\;\;\;\sin^{-1} \left(\sqrt{1 - \frac{Om \cdot Om}{Omc \cdot Omc}} \cdot \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 t l) < -5.50000000000000018e25

    1. Initial program 58.3%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around -inf 88.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \left(\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg88.3%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
      2. *-commutative88.3%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}}\right) \]
      3. unpow288.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      4. unpow288.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      5. times-frac99.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      6. unpow299.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      7. associate-/l*99.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\frac{\sqrt{0.5}}{\frac{t}{\ell}}}\right) \]
    4. Simplified99.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    5. Step-by-step derivation
      1. expm1-log1p-u99.3%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-udef21.8%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
      3. asin-neg21.8%

        \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{-\sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      4. associate-*r/21.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      5. pow1/221.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      6. pow1/221.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5} \cdot \color{blue}{{0.5}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      7. pow-prod-down21.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
    6. Applied egg-rr21.8%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
    7. Step-by-step derivation
      1. expm1-def99.3%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-log1p99.3%

        \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)} \]
      3. associate-/r/99.5%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{t} \cdot \ell\right)} \]
      4. unpow1/299.5%

        \[\leadsto -\sin^{-1} \left(\frac{\color{blue}{\sqrt{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5}}}{t} \cdot \ell\right) \]
      5. *-commutative99.5%

        \[\leadsto -\sin^{-1} \left(\frac{\sqrt{\color{blue}{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}}{t} \cdot \ell\right) \]
    8. Simplified99.5%

      \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}{t} \cdot \ell\right)} \]
    9. Step-by-step derivation
      1. unpow24.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      2. clear-num4.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}}\right) \]
      3. un-div-inv4.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]
    10. Applied egg-rr99.5%

      \[\leadsto -\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)}}{t} \cdot \ell\right) \]

    if -5.50000000000000018e25 < (/.f64 t l) < 1.00000000000000004e154

    1. Initial program 98.1%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Step-by-step derivation
      1. unpow298.1%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right)}}}\right) \]
      2. associate-*r/98.1%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\frac{\frac{t}{\ell} \cdot t}{\ell}}}}\right) \]
    3. Applied egg-rr98.1%

      \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\frac{\frac{t}{\ell} \cdot t}{\ell}}}}\right) \]
    4. Step-by-step derivation
      1. unpow277.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      2. clear-num77.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}}\right) \]
      3. un-div-inv77.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]
    5. Applied egg-rr98.1%

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

    if 1.00000000000000004e154 < (/.f64 t l)

    1. Initial program 52.0%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Step-by-step derivation
      1. unpow252.0%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right)}}}\right) \]
      2. associate-*r/52.0%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\frac{\frac{t}{\ell} \cdot t}{\ell}}}}\right) \]
    3. Applied egg-rr52.0%

      \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\frac{\frac{t}{\ell} \cdot t}{\ell}}}}\right) \]
    4. Taylor expanded in t around inf 82.1%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
    5. Step-by-step derivation
      1. associate-/l*77.8%

        \[\leadsto \sin^{-1} \left(\color{blue}{\frac{\sqrt{0.5}}{\frac{t}{\ell}}} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right) \]
      2. *-commutative77.8%

        \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
      3. unpow277.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right) \]
      4. unpow277.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right) \]
      5. times-frac95.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right) \]
      6. unpow295.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right) \]
      7. associate-/r/99.6%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\left(\frac{\sqrt{0.5}}{t} \cdot \ell\right)}\right) \]
      8. *-commutative99.6%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)}\right) \]
      9. unpow299.6%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\right) \]
      10. times-frac82.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om \cdot Om}{Omc \cdot Omc}}} \cdot \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\right) \]
    6. Simplified82.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - \frac{Om \cdot Om}{Omc \cdot Omc}} \cdot \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification96.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -5.5 \cdot 10^{+25}:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot \left(1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\right)}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 10^{+154}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{\frac{1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}{1 + 2 \cdot \frac{t \cdot \frac{t}{\ell}}{\ell}}}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{1 - \frac{Om \cdot Om}{Omc \cdot Omc}} \cdot \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\right)\\ \end{array} \]

Alternative 5: 96.4% accurate, 1.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := 1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\\ \mathbf{if}\;\frac{t}{\ell} \leq -5.5 \cdot 10^{+25}:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot t_1}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 10^{+154}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{\frac{t_1}{1 + 2 \cdot \frac{t \cdot \frac{t}{\ell}}{\ell}}}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\frac{\mathsf{fma}\left(Om \cdot \frac{Om}{Omc \cdot Omc}, -0.5, 1\right)}{\sqrt{2} \cdot \frac{t}{\ell}}\right)\\ \end{array} \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (let* ((t_1 (- 1.0 (/ (/ Om Omc) (/ Omc Om)))))
   (if (<= (/ t l) -5.5e+25)
     (- (asin (* l (/ (sqrt (* 0.5 t_1)) t))))
     (if (<= (/ t l) 1e+154)
       (asin (sqrt (/ t_1 (+ 1.0 (* 2.0 (/ (* t (/ t l)) l))))))
       (asin
        (/
         (fma (* Om (/ Om (* Omc Omc))) -0.5 1.0)
         (* (sqrt 2.0) (/ t l))))))))
double code(double t, double l, double Om, double Omc) {
	double t_1 = 1.0 - ((Om / Omc) / (Omc / Om));
	double tmp;
	if ((t / l) <= -5.5e+25) {
		tmp = -asin((l * (sqrt((0.5 * t_1)) / t)));
	} else if ((t / l) <= 1e+154) {
		tmp = asin(sqrt((t_1 / (1.0 + (2.0 * ((t * (t / l)) / l))))));
	} else {
		tmp = asin((fma((Om * (Om / (Omc * Omc))), -0.5, 1.0) / (sqrt(2.0) * (t / l))));
	}
	return tmp;
}
function code(t, l, Om, Omc)
	t_1 = Float64(1.0 - Float64(Float64(Om / Omc) / Float64(Omc / Om)))
	tmp = 0.0
	if (Float64(t / l) <= -5.5e+25)
		tmp = Float64(-asin(Float64(l * Float64(sqrt(Float64(0.5 * t_1)) / t))));
	elseif (Float64(t / l) <= 1e+154)
		tmp = asin(sqrt(Float64(t_1 / Float64(1.0 + Float64(2.0 * Float64(Float64(t * Float64(t / l)) / l))))));
	else
		tmp = asin(Float64(fma(Float64(Om * Float64(Om / Float64(Omc * Omc))), -0.5, 1.0) / Float64(sqrt(2.0) * Float64(t / l))));
	end
	return tmp
end
code[t_, l_, Om_, Omc_] := Block[{t$95$1 = N[(1.0 - N[(N[(Om / Omc), $MachinePrecision] / N[(Omc / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(t / l), $MachinePrecision], -5.5e+25], (-N[ArcSin[N[(l * N[(N[Sqrt[N[(0.5 * t$95$1), $MachinePrecision]], $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), If[LessEqual[N[(t / l), $MachinePrecision], 1e+154], N[ArcSin[N[Sqrt[N[(t$95$1 / N[(1.0 + N[(2.0 * N[(N[(t * N[(t / l), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision], N[ArcSin[N[(N[(N[(Om * N[(Om / N[(Omc * Omc), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * -0.5 + 1.0), $MachinePrecision] / N[(N[Sqrt[2.0], $MachinePrecision] * N[(t / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := 1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\\
\mathbf{if}\;\frac{t}{\ell} \leq -5.5 \cdot 10^{+25}:\\
\;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot t_1}}{t}\right)\\

\mathbf{elif}\;\frac{t}{\ell} \leq 10^{+154}:\\
\;\;\;\;\sin^{-1} \left(\sqrt{\frac{t_1}{1 + 2 \cdot \frac{t \cdot \frac{t}{\ell}}{\ell}}}\right)\\

\mathbf{else}:\\
\;\;\;\;\sin^{-1} \left(\frac{\mathsf{fma}\left(Om \cdot \frac{Om}{Omc \cdot Omc}, -0.5, 1\right)}{\sqrt{2} \cdot \frac{t}{\ell}}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 t l) < -5.50000000000000018e25

    1. Initial program 58.3%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around -inf 88.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \left(\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg88.3%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
      2. *-commutative88.3%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}}\right) \]
      3. unpow288.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      4. unpow288.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      5. times-frac99.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      6. unpow299.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      7. associate-/l*99.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\frac{\sqrt{0.5}}{\frac{t}{\ell}}}\right) \]
    4. Simplified99.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    5. Step-by-step derivation
      1. expm1-log1p-u99.3%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-udef21.8%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
      3. asin-neg21.8%

        \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{-\sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      4. associate-*r/21.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      5. pow1/221.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      6. pow1/221.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5} \cdot \color{blue}{{0.5}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      7. pow-prod-down21.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
    6. Applied egg-rr21.8%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
    7. Step-by-step derivation
      1. expm1-def99.3%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-log1p99.3%

        \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)} \]
      3. associate-/r/99.5%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{t} \cdot \ell\right)} \]
      4. unpow1/299.5%

        \[\leadsto -\sin^{-1} \left(\frac{\color{blue}{\sqrt{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5}}}{t} \cdot \ell\right) \]
      5. *-commutative99.5%

        \[\leadsto -\sin^{-1} \left(\frac{\sqrt{\color{blue}{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}}{t} \cdot \ell\right) \]
    8. Simplified99.5%

      \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}{t} \cdot \ell\right)} \]
    9. Step-by-step derivation
      1. unpow24.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      2. clear-num4.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}}\right) \]
      3. un-div-inv4.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]
    10. Applied egg-rr99.5%

      \[\leadsto -\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)}}{t} \cdot \ell\right) \]

    if -5.50000000000000018e25 < (/.f64 t l) < 1.00000000000000004e154

    1. Initial program 98.1%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Step-by-step derivation
      1. unpow298.1%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right)}}}\right) \]
      2. associate-*r/98.1%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\frac{\frac{t}{\ell} \cdot t}{\ell}}}}\right) \]
    3. Applied egg-rr98.1%

      \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\frac{\frac{t}{\ell} \cdot t}{\ell}}}}\right) \]
    4. Step-by-step derivation
      1. unpow277.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      2. clear-num77.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}}\right) \]
      3. un-div-inv77.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]
    5. Applied egg-rr98.1%

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

    if 1.00000000000000004e154 < (/.f64 t l)

    1. Initial program 52.0%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Step-by-step derivation
      1. sqrt-div52.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      2. div-inv52.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      3. add-sqr-sqrt52.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + \color{blue}{\sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}}}\right) \]
      4. hypot-1-def52.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\color{blue}{\mathsf{hypot}\left(1, \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}\right)}}\right) \]
      5. *-commutative52.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{{\left(\frac{t}{\ell}\right)}^{2} \cdot 2}}\right)}\right) \]
      6. sqrt-prod52.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\sqrt{{\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2}}\right)}\right) \]
      7. unpow252.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{\frac{t}{\ell} \cdot \frac{t}{\ell}}} \cdot \sqrt{2}\right)}\right) \]
      8. sqrt-prod95.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\left(\sqrt{\frac{t}{\ell}} \cdot \sqrt{\frac{t}{\ell}}\right)} \cdot \sqrt{2}\right)}\right) \]
      9. add-sqr-sqrt95.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\frac{t}{\ell}} \cdot \sqrt{2}\right)}\right) \]
    3. Applied egg-rr95.4%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    4. Step-by-step derivation
      1. unpow295.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      2. times-frac77.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om \cdot Om}{Omc \cdot Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      3. unpow277.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{{Om}^{2}}}{Omc \cdot Omc}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      4. unpow277.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{{Om}^{2}}{\color{blue}{{Omc}^{2}}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      5. associate-*r/77.8%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot 1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
      6. *-rgt-identity77.8%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      7. unpow277.8%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      8. unpow277.8%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      9. times-frac95.4%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      10. unpow295.4%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    5. Simplified95.4%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    6. Taylor expanded in Om around 0 77.8%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    7. Step-by-step derivation
      1. unpow22.8%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}\right) \]
      2. unpow22.8%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}\right) \]
    8. Simplified77.8%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    9. Step-by-step derivation
      1. times-frac3.4%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{Om}{Omc} \cdot \frac{Om}{Omc}\right)}\right) \]
      2. clear-num3.4%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \left(\frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}\right)\right) \]
      3. div-inv3.4%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right) \]
      4. associate-/r/3.4%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}\right) \]
    10. Applied egg-rr95.4%

      \[\leadsto \sin^{-1} \left(\frac{1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    11. Taylor expanded in t around inf 81.9%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\left(1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}\right) \cdot \ell}{\sqrt{2} \cdot t}\right)} \]
    12. Step-by-step derivation
      1. associate-/l*77.8%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}{\frac{\sqrt{2} \cdot t}{\ell}}\right)} \]
      2. +-commutative77.8%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{-0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}} + 1}}{\frac{\sqrt{2} \cdot t}{\ell}}\right) \]
      3. *-commutative77.8%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\frac{{Om}^{2}}{{Omc}^{2}} \cdot -0.5} + 1}{\frac{\sqrt{2} \cdot t}{\ell}}\right) \]
      4. unpow277.8%

        \[\leadsto \sin^{-1} \left(\frac{\frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}} \cdot -0.5 + 1}{\frac{\sqrt{2} \cdot t}{\ell}}\right) \]
      5. associate-*r/89.6%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\left(Om \cdot \frac{Om}{{Omc}^{2}}\right)} \cdot -0.5 + 1}{\frac{\sqrt{2} \cdot t}{\ell}}\right) \]
      6. unpow289.6%

        \[\leadsto \sin^{-1} \left(\frac{\left(Om \cdot \frac{Om}{\color{blue}{Omc \cdot Omc}}\right) \cdot -0.5 + 1}{\frac{\sqrt{2} \cdot t}{\ell}}\right) \]
      7. fma-udef89.6%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\mathsf{fma}\left(Om \cdot \frac{Om}{Omc \cdot Omc}, -0.5, 1\right)}}{\frac{\sqrt{2} \cdot t}{\ell}}\right) \]
      8. associate-*r/89.6%

        \[\leadsto \sin^{-1} \left(\frac{\mathsf{fma}\left(Om \cdot \frac{Om}{Omc \cdot Omc}, -0.5, 1\right)}{\color{blue}{\sqrt{2} \cdot \frac{t}{\ell}}}\right) \]
    13. Simplified89.6%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\mathsf{fma}\left(Om \cdot \frac{Om}{Omc \cdot Omc}, -0.5, 1\right)}{\sqrt{2} \cdot \frac{t}{\ell}}\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification97.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -5.5 \cdot 10^{+25}:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot \left(1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\right)}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 10^{+154}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{\frac{1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}{1 + 2 \cdot \frac{t \cdot \frac{t}{\ell}}{\ell}}}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\frac{\mathsf{fma}\left(Om \cdot \frac{Om}{Omc \cdot Omc}, -0.5, 1\right)}{\sqrt{2} \cdot \frac{t}{\ell}}\right)\\ \end{array} \]

Alternative 6: 97.8% accurate, 1.3× speedup?

\[\begin{array}{l} \\ \sin^{-1} \left(\frac{1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)}{\mathsf{hypot}\left(1, \sqrt{2} \cdot \frac{t}{\ell}\right)}\right) \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (asin
  (/
   (+ 1.0 (* -0.5 (* Om (/ (/ Om Omc) Omc))))
   (hypot 1.0 (* (sqrt 2.0) (/ t l))))))
double code(double t, double l, double Om, double Omc) {
	return asin(((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))) / hypot(1.0, (sqrt(2.0) * (t / l)))));
}
public static double code(double t, double l, double Om, double Omc) {
	return Math.asin(((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))) / Math.hypot(1.0, (Math.sqrt(2.0) * (t / l)))));
}
def code(t, l, Om, Omc):
	return math.asin(((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))) / math.hypot(1.0, (math.sqrt(2.0) * (t / l)))))
function code(t, l, Om, Omc)
	return asin(Float64(Float64(1.0 + Float64(-0.5 * Float64(Om * Float64(Float64(Om / Omc) / Omc)))) / hypot(1.0, Float64(sqrt(2.0) * Float64(t / l)))))
end
function tmp = code(t, l, Om, Omc)
	tmp = asin(((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))) / hypot(1.0, (sqrt(2.0) * (t / l)))));
end
code[t_, l_, Om_, Omc_] := N[ArcSin[N[(N[(1.0 + N[(-0.5 * N[(Om * N[(N[(Om / Omc), $MachinePrecision] / Omc), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[Sqrt[1.0 ^ 2 + N[(N[Sqrt[2.0], $MachinePrecision] * N[(t / l), $MachinePrecision]), $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}

\\
\sin^{-1} \left(\frac{1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)}{\mathsf{hypot}\left(1, \sqrt{2} \cdot \frac{t}{\ell}\right)}\right)
\end{array}
Derivation
  1. Initial program 82.2%

    \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
  2. Step-by-step derivation
    1. sqrt-div82.1%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
    2. div-inv82.1%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
    3. add-sqr-sqrt82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + \color{blue}{\sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}}}\right) \]
    4. hypot-1-def82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\color{blue}{\mathsf{hypot}\left(1, \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}\right)}}\right) \]
    5. *-commutative82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{{\left(\frac{t}{\ell}\right)}^{2} \cdot 2}}\right)}\right) \]
    6. sqrt-prod82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\sqrt{{\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2}}\right)}\right) \]
    7. unpow282.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{\frac{t}{\ell} \cdot \frac{t}{\ell}}} \cdot \sqrt{2}\right)}\right) \]
    8. sqrt-prod50.4%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\left(\sqrt{\frac{t}{\ell}} \cdot \sqrt{\frac{t}{\ell}}\right)} \cdot \sqrt{2}\right)}\right) \]
    9. add-sqr-sqrt98.0%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\frac{t}{\ell}} \cdot \sqrt{2}\right)}\right) \]
  3. Applied egg-rr98.0%

    \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
  4. Step-by-step derivation
    1. unpow298.0%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    2. times-frac84.3%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om \cdot Om}{Omc \cdot Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    3. unpow284.3%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{{Om}^{2}}}{Omc \cdot Omc}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    4. unpow284.3%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{{Om}^{2}}{\color{blue}{{Omc}^{2}}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    5. associate-*r/84.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot 1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    6. *-rgt-identity84.3%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    7. unpow284.3%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    8. unpow284.3%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    9. times-frac98.0%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    10. unpow298.0%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
  5. Simplified98.0%

    \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
  6. Taylor expanded in Om around 0 84.2%

    \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
  7. Step-by-step derivation
    1. unpow242.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}\right) \]
    2. unpow242.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}\right) \]
  8. Simplified84.2%

    \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
  9. Step-by-step derivation
    1. times-frac49.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{Om}{Omc} \cdot \frac{Om}{Omc}\right)}\right) \]
    2. clear-num49.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \left(\frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}\right)\right) \]
    3. div-inv49.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right) \]
    4. associate-/r/49.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}\right) \]
  10. Applied egg-rr97.4%

    \[\leadsto \sin^{-1} \left(\frac{1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
  11. Final simplification97.4%

    \[\leadsto \sin^{-1} \left(\frac{1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)}{\mathsf{hypot}\left(1, \sqrt{2} \cdot \frac{t}{\ell}\right)}\right) \]

Alternative 7: 97.8% accurate, 1.3× speedup?

\[\begin{array}{l} \\ \sin^{-1} \left(\frac{1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)}{\mathsf{hypot}\left(1, \frac{\sqrt{2} \cdot t}{\ell}\right)}\right) \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (asin
  (/
   (+ 1.0 (* -0.5 (* Om (/ (/ Om Omc) Omc))))
   (hypot 1.0 (/ (* (sqrt 2.0) t) l)))))
double code(double t, double l, double Om, double Omc) {
	return asin(((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))) / hypot(1.0, ((sqrt(2.0) * t) / l))));
}
public static double code(double t, double l, double Om, double Omc) {
	return Math.asin(((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))) / Math.hypot(1.0, ((Math.sqrt(2.0) * t) / l))));
}
def code(t, l, Om, Omc):
	return math.asin(((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))) / math.hypot(1.0, ((math.sqrt(2.0) * t) / l))))
function code(t, l, Om, Omc)
	return asin(Float64(Float64(1.0 + Float64(-0.5 * Float64(Om * Float64(Float64(Om / Omc) / Omc)))) / hypot(1.0, Float64(Float64(sqrt(2.0) * t) / l))))
end
function tmp = code(t, l, Om, Omc)
	tmp = asin(((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))) / hypot(1.0, ((sqrt(2.0) * t) / l))));
end
code[t_, l_, Om_, Omc_] := N[ArcSin[N[(N[(1.0 + N[(-0.5 * N[(Om * N[(N[(Om / Omc), $MachinePrecision] / Omc), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[Sqrt[1.0 ^ 2 + N[(N[(N[Sqrt[2.0], $MachinePrecision] * t), $MachinePrecision] / l), $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}

\\
\sin^{-1} \left(\frac{1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)}{\mathsf{hypot}\left(1, \frac{\sqrt{2} \cdot t}{\ell}\right)}\right)
\end{array}
Derivation
  1. Initial program 82.2%

    \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
  2. Step-by-step derivation
    1. sqrt-div82.1%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
    2. div-inv82.1%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
    3. add-sqr-sqrt82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + \color{blue}{\sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}}}\right) \]
    4. hypot-1-def82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\color{blue}{\mathsf{hypot}\left(1, \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}\right)}}\right) \]
    5. *-commutative82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{{\left(\frac{t}{\ell}\right)}^{2} \cdot 2}}\right)}\right) \]
    6. sqrt-prod82.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\sqrt{{\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2}}\right)}\right) \]
    7. unpow282.1%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{\frac{t}{\ell} \cdot \frac{t}{\ell}}} \cdot \sqrt{2}\right)}\right) \]
    8. sqrt-prod50.4%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\left(\sqrt{\frac{t}{\ell}} \cdot \sqrt{\frac{t}{\ell}}\right)} \cdot \sqrt{2}\right)}\right) \]
    9. add-sqr-sqrt98.0%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\frac{t}{\ell}} \cdot \sqrt{2}\right)}\right) \]
  3. Applied egg-rr98.0%

    \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
  4. Step-by-step derivation
    1. unpow298.0%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    2. times-frac84.3%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om \cdot Om}{Omc \cdot Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    3. unpow284.3%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{{Om}^{2}}}{Omc \cdot Omc}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    4. unpow284.3%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{{Om}^{2}}{\color{blue}{{Omc}^{2}}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    5. associate-*r/84.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot 1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    6. *-rgt-identity84.3%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    7. unpow284.3%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    8. unpow284.3%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    9. times-frac98.0%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    10. unpow298.0%

      \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
  5. Simplified98.0%

    \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
  6. Taylor expanded in Om around 0 84.2%

    \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
  7. Step-by-step derivation
    1. unpow242.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}\right) \]
    2. unpow242.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}\right) \]
  8. Simplified84.2%

    \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
  9. Step-by-step derivation
    1. times-frac49.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{Om}{Omc} \cdot \frac{Om}{Omc}\right)}\right) \]
    2. clear-num49.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \left(\frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}\right)\right) \]
    3. div-inv49.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right) \]
    4. associate-/r/49.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}\right) \]
  10. Applied egg-rr97.4%

    \[\leadsto \sin^{-1} \left(\frac{1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
  11. Taylor expanded in t around 0 97.4%

    \[\leadsto \sin^{-1} \left(\frac{1 + -0.5 \cdot \left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}{\mathsf{hypot}\left(1, \color{blue}{\frac{\sqrt{2} \cdot t}{\ell}}\right)}\right) \]
  12. Final simplification97.4%

    \[\leadsto \sin^{-1} \left(\frac{1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)}{\mathsf{hypot}\left(1, \frac{\sqrt{2} \cdot t}{\ell}\right)}\right) \]

Alternative 8: 95.9% accurate, 1.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := 1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\\ \mathbf{if}\;\frac{t}{\ell} \leq -5.5 \cdot 10^{+25}:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot t_1}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 10^{+154}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{\frac{t_1}{1 + 2 \cdot \frac{t \cdot \frac{t}{\ell}}{\ell}}}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\frac{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}{\sqrt{2}} \cdot \frac{\ell}{t}\right)\\ \end{array} \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (let* ((t_1 (- 1.0 (/ (/ Om Omc) (/ Omc Om)))))
   (if (<= (/ t l) -5.5e+25)
     (- (asin (* l (/ (sqrt (* 0.5 t_1)) t))))
     (if (<= (/ t l) 1e+154)
       (asin (sqrt (/ t_1 (+ 1.0 (* 2.0 (/ (* t (/ t l)) l))))))
       (asin
        (*
         (/ (+ 1.0 (* -0.5 (/ (* Om Om) (* Omc Omc)))) (sqrt 2.0))
         (/ l t)))))))
double code(double t, double l, double Om, double Omc) {
	double t_1 = 1.0 - ((Om / Omc) / (Omc / Om));
	double tmp;
	if ((t / l) <= -5.5e+25) {
		tmp = -asin((l * (sqrt((0.5 * t_1)) / t)));
	} else if ((t / l) <= 1e+154) {
		tmp = asin(sqrt((t_1 / (1.0 + (2.0 * ((t * (t / l)) / l))))));
	} else {
		tmp = asin((((1.0 + (-0.5 * ((Om * Om) / (Omc * Omc)))) / sqrt(2.0)) * (l / t)));
	}
	return tmp;
}
real(8) function code(t, l, om, omc)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: omc
    real(8) :: t_1
    real(8) :: tmp
    t_1 = 1.0d0 - ((om / omc) / (omc / om))
    if ((t / l) <= (-5.5d+25)) then
        tmp = -asin((l * (sqrt((0.5d0 * t_1)) / t)))
    else if ((t / l) <= 1d+154) then
        tmp = asin(sqrt((t_1 / (1.0d0 + (2.0d0 * ((t * (t / l)) / l))))))
    else
        tmp = asin((((1.0d0 + ((-0.5d0) * ((om * om) / (omc * omc)))) / sqrt(2.0d0)) * (l / t)))
    end if
    code = tmp
end function
public static double code(double t, double l, double Om, double Omc) {
	double t_1 = 1.0 - ((Om / Omc) / (Omc / Om));
	double tmp;
	if ((t / l) <= -5.5e+25) {
		tmp = -Math.asin((l * (Math.sqrt((0.5 * t_1)) / t)));
	} else if ((t / l) <= 1e+154) {
		tmp = Math.asin(Math.sqrt((t_1 / (1.0 + (2.0 * ((t * (t / l)) / l))))));
	} else {
		tmp = Math.asin((((1.0 + (-0.5 * ((Om * Om) / (Omc * Omc)))) / Math.sqrt(2.0)) * (l / t)));
	}
	return tmp;
}
def code(t, l, Om, Omc):
	t_1 = 1.0 - ((Om / Omc) / (Omc / Om))
	tmp = 0
	if (t / l) <= -5.5e+25:
		tmp = -math.asin((l * (math.sqrt((0.5 * t_1)) / t)))
	elif (t / l) <= 1e+154:
		tmp = math.asin(math.sqrt((t_1 / (1.0 + (2.0 * ((t * (t / l)) / l))))))
	else:
		tmp = math.asin((((1.0 + (-0.5 * ((Om * Om) / (Omc * Omc)))) / math.sqrt(2.0)) * (l / t)))
	return tmp
function code(t, l, Om, Omc)
	t_1 = Float64(1.0 - Float64(Float64(Om / Omc) / Float64(Omc / Om)))
	tmp = 0.0
	if (Float64(t / l) <= -5.5e+25)
		tmp = Float64(-asin(Float64(l * Float64(sqrt(Float64(0.5 * t_1)) / t))));
	elseif (Float64(t / l) <= 1e+154)
		tmp = asin(sqrt(Float64(t_1 / Float64(1.0 + Float64(2.0 * Float64(Float64(t * Float64(t / l)) / l))))));
	else
		tmp = asin(Float64(Float64(Float64(1.0 + Float64(-0.5 * Float64(Float64(Om * Om) / Float64(Omc * Omc)))) / sqrt(2.0)) * Float64(l / t)));
	end
	return tmp
end
function tmp_2 = code(t, l, Om, Omc)
	t_1 = 1.0 - ((Om / Omc) / (Omc / Om));
	tmp = 0.0;
	if ((t / l) <= -5.5e+25)
		tmp = -asin((l * (sqrt((0.5 * t_1)) / t)));
	elseif ((t / l) <= 1e+154)
		tmp = asin(sqrt((t_1 / (1.0 + (2.0 * ((t * (t / l)) / l))))));
	else
		tmp = asin((((1.0 + (-0.5 * ((Om * Om) / (Omc * Omc)))) / sqrt(2.0)) * (l / t)));
	end
	tmp_2 = tmp;
end
code[t_, l_, Om_, Omc_] := Block[{t$95$1 = N[(1.0 - N[(N[(Om / Omc), $MachinePrecision] / N[(Omc / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(t / l), $MachinePrecision], -5.5e+25], (-N[ArcSin[N[(l * N[(N[Sqrt[N[(0.5 * t$95$1), $MachinePrecision]], $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), If[LessEqual[N[(t / l), $MachinePrecision], 1e+154], N[ArcSin[N[Sqrt[N[(t$95$1 / N[(1.0 + N[(2.0 * N[(N[(t * N[(t / l), $MachinePrecision]), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision], N[ArcSin[N[(N[(N[(1.0 + N[(-0.5 * N[(N[(Om * Om), $MachinePrecision] / N[(Omc * Omc), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[(l / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := 1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\\
\mathbf{if}\;\frac{t}{\ell} \leq -5.5 \cdot 10^{+25}:\\
\;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot t_1}}{t}\right)\\

\mathbf{elif}\;\frac{t}{\ell} \leq 10^{+154}:\\
\;\;\;\;\sin^{-1} \left(\sqrt{\frac{t_1}{1 + 2 \cdot \frac{t \cdot \frac{t}{\ell}}{\ell}}}\right)\\

\mathbf{else}:\\
\;\;\;\;\sin^{-1} \left(\frac{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}{\sqrt{2}} \cdot \frac{\ell}{t}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 t l) < -5.50000000000000018e25

    1. Initial program 58.3%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around -inf 88.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \left(\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg88.3%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
      2. *-commutative88.3%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}}\right) \]
      3. unpow288.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      4. unpow288.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      5. times-frac99.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      6. unpow299.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      7. associate-/l*99.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\frac{\sqrt{0.5}}{\frac{t}{\ell}}}\right) \]
    4. Simplified99.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    5. Step-by-step derivation
      1. expm1-log1p-u99.3%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-udef21.8%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
      3. asin-neg21.8%

        \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{-\sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      4. associate-*r/21.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      5. pow1/221.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      6. pow1/221.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5} \cdot \color{blue}{{0.5}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      7. pow-prod-down21.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
    6. Applied egg-rr21.8%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
    7. Step-by-step derivation
      1. expm1-def99.3%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-log1p99.3%

        \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)} \]
      3. associate-/r/99.5%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{t} \cdot \ell\right)} \]
      4. unpow1/299.5%

        \[\leadsto -\sin^{-1} \left(\frac{\color{blue}{\sqrt{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5}}}{t} \cdot \ell\right) \]
      5. *-commutative99.5%

        \[\leadsto -\sin^{-1} \left(\frac{\sqrt{\color{blue}{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}}{t} \cdot \ell\right) \]
    8. Simplified99.5%

      \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}{t} \cdot \ell\right)} \]
    9. Step-by-step derivation
      1. unpow24.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      2. clear-num4.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}}\right) \]
      3. un-div-inv4.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]
    10. Applied egg-rr99.5%

      \[\leadsto -\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)}}{t} \cdot \ell\right) \]

    if -5.50000000000000018e25 < (/.f64 t l) < 1.00000000000000004e154

    1. Initial program 98.1%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Step-by-step derivation
      1. unpow298.1%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right)}}}\right) \]
      2. associate-*r/98.1%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\frac{\frac{t}{\ell} \cdot t}{\ell}}}}\right) \]
    3. Applied egg-rr98.1%

      \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\frac{\frac{t}{\ell} \cdot t}{\ell}}}}\right) \]
    4. Step-by-step derivation
      1. unpow277.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      2. clear-num77.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}}\right) \]
      3. un-div-inv77.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]
    5. Applied egg-rr98.1%

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

    if 1.00000000000000004e154 < (/.f64 t l)

    1. Initial program 52.0%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Step-by-step derivation
      1. sqrt-div52.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      2. div-inv52.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      3. add-sqr-sqrt52.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + \color{blue}{\sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}}}\right) \]
      4. hypot-1-def52.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\color{blue}{\mathsf{hypot}\left(1, \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}\right)}}\right) \]
      5. *-commutative52.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{{\left(\frac{t}{\ell}\right)}^{2} \cdot 2}}\right)}\right) \]
      6. sqrt-prod52.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\sqrt{{\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2}}\right)}\right) \]
      7. unpow252.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{\frac{t}{\ell} \cdot \frac{t}{\ell}}} \cdot \sqrt{2}\right)}\right) \]
      8. sqrt-prod95.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\left(\sqrt{\frac{t}{\ell}} \cdot \sqrt{\frac{t}{\ell}}\right)} \cdot \sqrt{2}\right)}\right) \]
      9. add-sqr-sqrt95.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\frac{t}{\ell}} \cdot \sqrt{2}\right)}\right) \]
    3. Applied egg-rr95.4%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    4. Step-by-step derivation
      1. unpow295.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      2. times-frac77.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om \cdot Om}{Omc \cdot Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      3. unpow277.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{{Om}^{2}}}{Omc \cdot Omc}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      4. unpow277.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{{Om}^{2}}{\color{blue}{{Omc}^{2}}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      5. associate-*r/77.8%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot 1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
      6. *-rgt-identity77.8%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      7. unpow277.8%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      8. unpow277.8%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      9. times-frac95.4%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      10. unpow295.4%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    5. Simplified95.4%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    6. Taylor expanded in Om around 0 77.8%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    7. Step-by-step derivation
      1. unpow22.8%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}\right) \]
      2. unpow22.8%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}\right) \]
    8. Simplified77.8%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    9. Taylor expanded in t around inf 81.9%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\left(1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}\right) \cdot \ell}{\sqrt{2} \cdot t}\right)} \]
    10. Step-by-step derivation
      1. times-frac82.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}{\sqrt{2}} \cdot \frac{\ell}{t}\right)} \]
      2. unpow282.0%

        \[\leadsto \sin^{-1} \left(\frac{1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}{\sqrt{2}} \cdot \frac{\ell}{t}\right) \]
      3. unpow282.0%

        \[\leadsto \sin^{-1} \left(\frac{1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}{\sqrt{2}} \cdot \frac{\ell}{t}\right) \]
    11. Simplified82.0%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -5.5 \cdot 10^{+25}:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot \left(1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\right)}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 10^{+154}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{\frac{1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}{1 + 2 \cdot \frac{t \cdot \frac{t}{\ell}}{\ell}}}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\frac{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}{\sqrt{2}} \cdot \frac{\ell}{t}\right)\\ \end{array} \]

Alternative 9: 94.8% accurate, 1.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := 1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\\ \mathbf{if}\;\frac{t}{\ell} \leq -40000:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot t_1}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 10^{-7}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{t_1}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\frac{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}{\sqrt{2}} \cdot \frac{\ell}{t}\right)\\ \end{array} \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (let* ((t_1 (- 1.0 (/ (/ Om Omc) (/ Omc Om)))))
   (if (<= (/ t l) -40000.0)
     (- (asin (* l (/ (sqrt (* 0.5 t_1)) t))))
     (if (<= (/ t l) 1e-7)
       (asin (sqrt t_1))
       (asin
        (*
         (/ (+ 1.0 (* -0.5 (/ (* Om Om) (* Omc Omc)))) (sqrt 2.0))
         (/ l t)))))))
double code(double t, double l, double Om, double Omc) {
	double t_1 = 1.0 - ((Om / Omc) / (Omc / Om));
	double tmp;
	if ((t / l) <= -40000.0) {
		tmp = -asin((l * (sqrt((0.5 * t_1)) / t)));
	} else if ((t / l) <= 1e-7) {
		tmp = asin(sqrt(t_1));
	} else {
		tmp = asin((((1.0 + (-0.5 * ((Om * Om) / (Omc * Omc)))) / sqrt(2.0)) * (l / t)));
	}
	return tmp;
}
real(8) function code(t, l, om, omc)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: omc
    real(8) :: t_1
    real(8) :: tmp
    t_1 = 1.0d0 - ((om / omc) / (omc / om))
    if ((t / l) <= (-40000.0d0)) then
        tmp = -asin((l * (sqrt((0.5d0 * t_1)) / t)))
    else if ((t / l) <= 1d-7) then
        tmp = asin(sqrt(t_1))
    else
        tmp = asin((((1.0d0 + ((-0.5d0) * ((om * om) / (omc * omc)))) / sqrt(2.0d0)) * (l / t)))
    end if
    code = tmp
end function
public static double code(double t, double l, double Om, double Omc) {
	double t_1 = 1.0 - ((Om / Omc) / (Omc / Om));
	double tmp;
	if ((t / l) <= -40000.0) {
		tmp = -Math.asin((l * (Math.sqrt((0.5 * t_1)) / t)));
	} else if ((t / l) <= 1e-7) {
		tmp = Math.asin(Math.sqrt(t_1));
	} else {
		tmp = Math.asin((((1.0 + (-0.5 * ((Om * Om) / (Omc * Omc)))) / Math.sqrt(2.0)) * (l / t)));
	}
	return tmp;
}
def code(t, l, Om, Omc):
	t_1 = 1.0 - ((Om / Omc) / (Omc / Om))
	tmp = 0
	if (t / l) <= -40000.0:
		tmp = -math.asin((l * (math.sqrt((0.5 * t_1)) / t)))
	elif (t / l) <= 1e-7:
		tmp = math.asin(math.sqrt(t_1))
	else:
		tmp = math.asin((((1.0 + (-0.5 * ((Om * Om) / (Omc * Omc)))) / math.sqrt(2.0)) * (l / t)))
	return tmp
function code(t, l, Om, Omc)
	t_1 = Float64(1.0 - Float64(Float64(Om / Omc) / Float64(Omc / Om)))
	tmp = 0.0
	if (Float64(t / l) <= -40000.0)
		tmp = Float64(-asin(Float64(l * Float64(sqrt(Float64(0.5 * t_1)) / t))));
	elseif (Float64(t / l) <= 1e-7)
		tmp = asin(sqrt(t_1));
	else
		tmp = asin(Float64(Float64(Float64(1.0 + Float64(-0.5 * Float64(Float64(Om * Om) / Float64(Omc * Omc)))) / sqrt(2.0)) * Float64(l / t)));
	end
	return tmp
end
function tmp_2 = code(t, l, Om, Omc)
	t_1 = 1.0 - ((Om / Omc) / (Omc / Om));
	tmp = 0.0;
	if ((t / l) <= -40000.0)
		tmp = -asin((l * (sqrt((0.5 * t_1)) / t)));
	elseif ((t / l) <= 1e-7)
		tmp = asin(sqrt(t_1));
	else
		tmp = asin((((1.0 + (-0.5 * ((Om * Om) / (Omc * Omc)))) / sqrt(2.0)) * (l / t)));
	end
	tmp_2 = tmp;
end
code[t_, l_, Om_, Omc_] := Block[{t$95$1 = N[(1.0 - N[(N[(Om / Omc), $MachinePrecision] / N[(Omc / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(t / l), $MachinePrecision], -40000.0], (-N[ArcSin[N[(l * N[(N[Sqrt[N[(0.5 * t$95$1), $MachinePrecision]], $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), If[LessEqual[N[(t / l), $MachinePrecision], 1e-7], N[ArcSin[N[Sqrt[t$95$1], $MachinePrecision]], $MachinePrecision], N[ArcSin[N[(N[(N[(1.0 + N[(-0.5 * N[(N[(Om * Om), $MachinePrecision] / N[(Omc * Omc), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[(l / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := 1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\\
\mathbf{if}\;\frac{t}{\ell} \leq -40000:\\
\;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot t_1}}{t}\right)\\

\mathbf{elif}\;\frac{t}{\ell} \leq 10^{-7}:\\
\;\;\;\;\sin^{-1} \left(\sqrt{t_1}\right)\\

\mathbf{else}:\\
\;\;\;\;\sin^{-1} \left(\frac{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}{\sqrt{2}} \cdot \frac{\ell}{t}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 t l) < -4e4

    1. Initial program 62.4%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around -inf 87.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \left(\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg87.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
      2. *-commutative87.0%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}}\right) \]
      3. unpow287.0%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      4. unpow287.0%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      5. times-frac98.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      6. unpow298.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      7. associate-/l*98.5%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\frac{\sqrt{0.5}}{\frac{t}{\ell}}}\right) \]
    4. Simplified98.5%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    5. Step-by-step derivation
      1. expm1-log1p-u98.5%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-udef23.8%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
      3. asin-neg23.8%

        \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{-\sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      4. associate-*r/23.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      5. pow1/223.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      6. pow1/223.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5} \cdot \color{blue}{{0.5}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      7. pow-prod-down23.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
    6. Applied egg-rr23.8%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
    7. Step-by-step derivation
      1. expm1-def98.4%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-log1p98.4%

        \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)} \]
      3. associate-/r/98.6%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{t} \cdot \ell\right)} \]
      4. unpow1/298.6%

        \[\leadsto -\sin^{-1} \left(\frac{\color{blue}{\sqrt{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5}}}{t} \cdot \ell\right) \]
      5. *-commutative98.6%

        \[\leadsto -\sin^{-1} \left(\frac{\sqrt{\color{blue}{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}}{t} \cdot \ell\right) \]
    8. Simplified98.6%

      \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}{t} \cdot \ell\right)} \]
    9. Step-by-step derivation
      1. unpow25.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      2. clear-num5.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}}\right) \]
      3. un-div-inv5.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]
    10. Applied egg-rr98.6%

      \[\leadsto -\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)}}{t} \cdot \ell\right) \]

    if -4e4 < (/.f64 t l) < 9.9999999999999995e-8

    1. Initial program 97.7%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around 0 82.8%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
    3. Step-by-step derivation
      1. unpow282.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}\right) \]
      2. unpow282.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}\right) \]
      3. times-frac97.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      4. unpow297.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}\right) \]
    4. Simplified97.4%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}\right)} \]
    5. Step-by-step derivation
      1. unpow297.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      2. clear-num97.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}}\right) \]
      3. un-div-inv97.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]
    6. Applied egg-rr97.4%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]

    if 9.9999999999999995e-8 < (/.f64 t l)

    1. Initial program 73.5%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Step-by-step derivation
      1. sqrt-div73.4%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      2. div-inv73.4%

        \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      3. add-sqr-sqrt73.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + \color{blue}{\sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}}}\right) \]
      4. hypot-1-def73.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\color{blue}{\mathsf{hypot}\left(1, \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}\right)}}\right) \]
      5. *-commutative73.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{{\left(\frac{t}{\ell}\right)}^{2} \cdot 2}}\right)}\right) \]
      6. sqrt-prod73.3%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\sqrt{{\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2}}\right)}\right) \]
      7. unpow273.3%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{\frac{t}{\ell} \cdot \frac{t}{\ell}}} \cdot \sqrt{2}\right)}\right) \]
      8. sqrt-prod96.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\left(\sqrt{\frac{t}{\ell}} \cdot \sqrt{\frac{t}{\ell}}\right)} \cdot \sqrt{2}\right)}\right) \]
      9. add-sqr-sqrt97.1%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\frac{t}{\ell}} \cdot \sqrt{2}\right)}\right) \]
    3. Applied egg-rr97.1%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    4. Step-by-step derivation
      1. unpow297.1%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      2. times-frac82.6%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om \cdot Om}{Omc \cdot Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      3. unpow282.6%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{{Om}^{2}}}{Omc \cdot Omc}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      4. unpow282.6%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{{Om}^{2}}{\color{blue}{{Omc}^{2}}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      5. associate-*r/82.6%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot 1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
      6. *-rgt-identity82.6%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      7. unpow282.6%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      8. unpow282.6%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      9. times-frac97.1%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      10. unpow297.1%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    5. Simplified97.1%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    6. Taylor expanded in Om around 0 82.7%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    7. Step-by-step derivation
      1. unpow24.8%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}\right) \]
      2. unpow24.8%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}\right) \]
    8. Simplified82.7%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    9. Taylor expanded in t around inf 83.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\left(1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}\right) \cdot \ell}{\sqrt{2} \cdot t}\right)} \]
    10. Step-by-step derivation
      1. times-frac83.2%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}{\sqrt{2}} \cdot \frac{\ell}{t}\right)} \]
      2. unpow283.2%

        \[\leadsto \sin^{-1} \left(\frac{1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}{\sqrt{2}} \cdot \frac{\ell}{t}\right) \]
      3. unpow283.2%

        \[\leadsto \sin^{-1} \left(\frac{1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}{\sqrt{2}} \cdot \frac{\ell}{t}\right) \]
    11. Simplified83.2%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -40000:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot \left(1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\right)}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 10^{-7}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\frac{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}{\sqrt{2}} \cdot \frac{\ell}{t}\right)\\ \end{array} \]

Alternative 10: 84.4% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -40000:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 5 \cdot 10^{-10}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{\frac{1}{1 + 2 \cdot \frac{t \cdot t}{\ell \cdot \ell}}}\right)\\ \end{array} \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (if (<= (/ t l) -40000.0)
   (- (asin (* l (/ (sqrt 0.5) t))))
   (if (<= (/ t l) 5e-10)
     (asin (sqrt (- 1.0 (/ (/ Om Omc) (/ Omc Om)))))
     (asin (sqrt (/ 1.0 (+ 1.0 (* 2.0 (/ (* t t) (* l l))))))))))
double code(double t, double l, double Om, double Omc) {
	double tmp;
	if ((t / l) <= -40000.0) {
		tmp = -asin((l * (sqrt(0.5) / t)));
	} else if ((t / l) <= 5e-10) {
		tmp = asin(sqrt((1.0 - ((Om / Omc) / (Omc / Om)))));
	} else {
		tmp = asin(sqrt((1.0 / (1.0 + (2.0 * ((t * t) / (l * l)))))));
	}
	return tmp;
}
real(8) function code(t, l, om, omc)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: omc
    real(8) :: tmp
    if ((t / l) <= (-40000.0d0)) then
        tmp = -asin((l * (sqrt(0.5d0) / t)))
    else if ((t / l) <= 5d-10) then
        tmp = asin(sqrt((1.0d0 - ((om / omc) / (omc / om)))))
    else
        tmp = asin(sqrt((1.0d0 / (1.0d0 + (2.0d0 * ((t * t) / (l * l)))))))
    end if
    code = tmp
end function
public static double code(double t, double l, double Om, double Omc) {
	double tmp;
	if ((t / l) <= -40000.0) {
		tmp = -Math.asin((l * (Math.sqrt(0.5) / t)));
	} else if ((t / l) <= 5e-10) {
		tmp = Math.asin(Math.sqrt((1.0 - ((Om / Omc) / (Omc / Om)))));
	} else {
		tmp = Math.asin(Math.sqrt((1.0 / (1.0 + (2.0 * ((t * t) / (l * l)))))));
	}
	return tmp;
}
def code(t, l, Om, Omc):
	tmp = 0
	if (t / l) <= -40000.0:
		tmp = -math.asin((l * (math.sqrt(0.5) / t)))
	elif (t / l) <= 5e-10:
		tmp = math.asin(math.sqrt((1.0 - ((Om / Omc) / (Omc / Om)))))
	else:
		tmp = math.asin(math.sqrt((1.0 / (1.0 + (2.0 * ((t * t) / (l * l)))))))
	return tmp
function code(t, l, Om, Omc)
	tmp = 0.0
	if (Float64(t / l) <= -40000.0)
		tmp = Float64(-asin(Float64(l * Float64(sqrt(0.5) / t))));
	elseif (Float64(t / l) <= 5e-10)
		tmp = asin(sqrt(Float64(1.0 - Float64(Float64(Om / Omc) / Float64(Omc / Om)))));
	else
		tmp = asin(sqrt(Float64(1.0 / Float64(1.0 + Float64(2.0 * Float64(Float64(t * t) / Float64(l * l)))))));
	end
	return tmp
end
function tmp_2 = code(t, l, Om, Omc)
	tmp = 0.0;
	if ((t / l) <= -40000.0)
		tmp = -asin((l * (sqrt(0.5) / t)));
	elseif ((t / l) <= 5e-10)
		tmp = asin(sqrt((1.0 - ((Om / Omc) / (Omc / Om)))));
	else
		tmp = asin(sqrt((1.0 / (1.0 + (2.0 * ((t * t) / (l * l)))))));
	end
	tmp_2 = tmp;
end
code[t_, l_, Om_, Omc_] := If[LessEqual[N[(t / l), $MachinePrecision], -40000.0], (-N[ArcSin[N[(l * N[(N[Sqrt[0.5], $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), If[LessEqual[N[(t / l), $MachinePrecision], 5e-10], N[ArcSin[N[Sqrt[N[(1.0 - N[(N[(Om / Omc), $MachinePrecision] / N[(Omc / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision], N[ArcSin[N[Sqrt[N[(1.0 / N[(1.0 + N[(2.0 * N[(N[(t * t), $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;\frac{t}{\ell} \leq -40000:\\
\;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\

\mathbf{elif}\;\frac{t}{\ell} \leq 5 \cdot 10^{-10}:\\
\;\;\;\;\sin^{-1} \left(\sqrt{1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)\\

\mathbf{else}:\\
\;\;\;\;\sin^{-1} \left(\sqrt{\frac{1}{1 + 2 \cdot \frac{t \cdot t}{\ell \cdot \ell}}}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 t l) < -4e4

    1. Initial program 62.4%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around -inf 87.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \left(\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg87.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
      2. *-commutative87.0%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}}\right) \]
      3. unpow287.0%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      4. unpow287.0%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      5. times-frac98.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      6. unpow298.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      7. associate-/l*98.5%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\frac{\sqrt{0.5}}{\frac{t}{\ell}}}\right) \]
    4. Simplified98.5%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    5. Step-by-step derivation
      1. expm1-log1p-u98.5%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-udef23.8%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
      3. asin-neg23.8%

        \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{-\sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      4. associate-*r/23.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      5. pow1/223.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      6. pow1/223.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5} \cdot \color{blue}{{0.5}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      7. pow-prod-down23.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
    6. Applied egg-rr23.8%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
    7. Step-by-step derivation
      1. expm1-def98.4%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-log1p98.4%

        \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)} \]
      3. associate-/r/98.6%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{t} \cdot \ell\right)} \]
      4. unpow1/298.6%

        \[\leadsto -\sin^{-1} \left(\frac{\color{blue}{\sqrt{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5}}}{t} \cdot \ell\right) \]
      5. *-commutative98.6%

        \[\leadsto -\sin^{-1} \left(\frac{\sqrt{\color{blue}{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}}{t} \cdot \ell\right) \]
    8. Simplified98.6%

      \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}{t} \cdot \ell\right)} \]
    9. Taylor expanded in Om around 0 98.0%

      \[\leadsto -\sin^{-1} \left(\color{blue}{\frac{\sqrt{0.5}}{t}} \cdot \ell\right) \]

    if -4e4 < (/.f64 t l) < 5.00000000000000031e-10

    1. Initial program 97.9%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around 0 83.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
    3. Step-by-step derivation
      1. unpow283.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}\right) \]
      2. unpow283.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}\right) \]
      3. times-frac97.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      4. unpow297.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}\right) \]
    4. Simplified97.7%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}\right)} \]
    5. Step-by-step derivation
      1. unpow297.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      2. clear-num97.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}}\right) \]
      3. un-div-inv97.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]
    6. Applied egg-rr97.7%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]

    if 5.00000000000000031e-10 < (/.f64 t l)

    1. Initial program 73.4%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Step-by-step derivation
      1. unpow273.4%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\left(\frac{t}{\ell} \cdot \frac{t}{\ell}\right)}}}\right) \]
      2. associate-*r/73.4%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\frac{\frac{t}{\ell} \cdot t}{\ell}}}}\right) \]
    3. Applied egg-rr73.4%

      \[\leadsto \sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot \color{blue}{\frac{\frac{t}{\ell} \cdot t}{\ell}}}}\right) \]
    4. Taylor expanded in Om around 0 62.2%

      \[\leadsto \sin^{-1} \left(\sqrt{\color{blue}{\frac{1}{1 + 2 \cdot \frac{{t}^{2}}{{\ell}^{2}}}}}\right) \]
    5. Step-by-step derivation
      1. associate-*r/62.2%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \color{blue}{\frac{2 \cdot {t}^{2}}{{\ell}^{2}}}}}\right) \]
      2. rem-square-sqrt62.0%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{\color{blue}{\left(\sqrt{2} \cdot \sqrt{2}\right)} \cdot {t}^{2}}{{\ell}^{2}}}}\right) \]
      3. unpow262.0%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{\color{blue}{{\left(\sqrt{2}\right)}^{2}} \cdot {t}^{2}}{{\ell}^{2}}}}\right) \]
      4. unpow262.0%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{\color{blue}{\left(\sqrt{2} \cdot \sqrt{2}\right)} \cdot {t}^{2}}{{\ell}^{2}}}}\right) \]
      5. rem-square-sqrt62.2%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{\color{blue}{2} \cdot {t}^{2}}{{\ell}^{2}}}}\right) \]
      6. associate-*r/62.2%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \color{blue}{2 \cdot \frac{{t}^{2}}{{\ell}^{2}}}}}\right) \]
      7. unpow262.2%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + 2 \cdot \frac{\color{blue}{t \cdot t}}{{\ell}^{2}}}}\right) \]
      8. unpow262.2%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + 2 \cdot \frac{t \cdot t}{\color{blue}{\ell \cdot \ell}}}}\right) \]
    6. Simplified62.2%

      \[\leadsto \sin^{-1} \left(\sqrt{\color{blue}{\frac{1}{1 + 2 \cdot \frac{t \cdot t}{\ell \cdot \ell}}}}\right) \]
  3. Recombined 3 regimes into one program.
  4. Final simplification89.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -40000:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 5 \cdot 10^{-10}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{\frac{1}{1 + 2 \cdot \frac{t \cdot t}{\ell \cdot \ell}}}\right)\\ \end{array} \]

Alternative 11: 85.9% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -40000:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 5 \cdot 10^{-10}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{2}{\ell} \cdot \frac{t \cdot t}{\ell}}}\right)\\ \end{array} \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (if (<= (/ t l) -40000.0)
   (- (asin (* l (/ (sqrt 0.5) t))))
   (if (<= (/ t l) 5e-10)
     (asin (sqrt (- 1.0 (/ (/ Om Omc) (/ Omc Om)))))
     (asin (sqrt (/ 1.0 (+ 1.0 (* (/ 2.0 l) (/ (* t t) l)))))))))
double code(double t, double l, double Om, double Omc) {
	double tmp;
	if ((t / l) <= -40000.0) {
		tmp = -asin((l * (sqrt(0.5) / t)));
	} else if ((t / l) <= 5e-10) {
		tmp = asin(sqrt((1.0 - ((Om / Omc) / (Omc / Om)))));
	} else {
		tmp = asin(sqrt((1.0 / (1.0 + ((2.0 / l) * ((t * t) / l))))));
	}
	return tmp;
}
real(8) function code(t, l, om, omc)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: omc
    real(8) :: tmp
    if ((t / l) <= (-40000.0d0)) then
        tmp = -asin((l * (sqrt(0.5d0) / t)))
    else if ((t / l) <= 5d-10) then
        tmp = asin(sqrt((1.0d0 - ((om / omc) / (omc / om)))))
    else
        tmp = asin(sqrt((1.0d0 / (1.0d0 + ((2.0d0 / l) * ((t * t) / l))))))
    end if
    code = tmp
end function
public static double code(double t, double l, double Om, double Omc) {
	double tmp;
	if ((t / l) <= -40000.0) {
		tmp = -Math.asin((l * (Math.sqrt(0.5) / t)));
	} else if ((t / l) <= 5e-10) {
		tmp = Math.asin(Math.sqrt((1.0 - ((Om / Omc) / (Omc / Om)))));
	} else {
		tmp = Math.asin(Math.sqrt((1.0 / (1.0 + ((2.0 / l) * ((t * t) / l))))));
	}
	return tmp;
}
def code(t, l, Om, Omc):
	tmp = 0
	if (t / l) <= -40000.0:
		tmp = -math.asin((l * (math.sqrt(0.5) / t)))
	elif (t / l) <= 5e-10:
		tmp = math.asin(math.sqrt((1.0 - ((Om / Omc) / (Omc / Om)))))
	else:
		tmp = math.asin(math.sqrt((1.0 / (1.0 + ((2.0 / l) * ((t * t) / l))))))
	return tmp
function code(t, l, Om, Omc)
	tmp = 0.0
	if (Float64(t / l) <= -40000.0)
		tmp = Float64(-asin(Float64(l * Float64(sqrt(0.5) / t))));
	elseif (Float64(t / l) <= 5e-10)
		tmp = asin(sqrt(Float64(1.0 - Float64(Float64(Om / Omc) / Float64(Omc / Om)))));
	else
		tmp = asin(sqrt(Float64(1.0 / Float64(1.0 + Float64(Float64(2.0 / l) * Float64(Float64(t * t) / l))))));
	end
	return tmp
end
function tmp_2 = code(t, l, Om, Omc)
	tmp = 0.0;
	if ((t / l) <= -40000.0)
		tmp = -asin((l * (sqrt(0.5) / t)));
	elseif ((t / l) <= 5e-10)
		tmp = asin(sqrt((1.0 - ((Om / Omc) / (Omc / Om)))));
	else
		tmp = asin(sqrt((1.0 / (1.0 + ((2.0 / l) * ((t * t) / l))))));
	end
	tmp_2 = tmp;
end
code[t_, l_, Om_, Omc_] := If[LessEqual[N[(t / l), $MachinePrecision], -40000.0], (-N[ArcSin[N[(l * N[(N[Sqrt[0.5], $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), If[LessEqual[N[(t / l), $MachinePrecision], 5e-10], N[ArcSin[N[Sqrt[N[(1.0 - N[(N[(Om / Omc), $MachinePrecision] / N[(Omc / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision], N[ArcSin[N[Sqrt[N[(1.0 / N[(1.0 + N[(N[(2.0 / l), $MachinePrecision] * N[(N[(t * t), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;\frac{t}{\ell} \leq -40000:\\
\;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\

\mathbf{elif}\;\frac{t}{\ell} \leq 5 \cdot 10^{-10}:\\
\;\;\;\;\sin^{-1} \left(\sqrt{1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)\\

\mathbf{else}:\\
\;\;\;\;\sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{2}{\ell} \cdot \frac{t \cdot t}{\ell}}}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 t l) < -4e4

    1. Initial program 62.4%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around -inf 87.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \left(\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg87.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
      2. *-commutative87.0%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}}\right) \]
      3. unpow287.0%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      4. unpow287.0%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      5. times-frac98.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      6. unpow298.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      7. associate-/l*98.5%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\frac{\sqrt{0.5}}{\frac{t}{\ell}}}\right) \]
    4. Simplified98.5%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    5. Step-by-step derivation
      1. expm1-log1p-u98.5%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-udef23.8%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
      3. asin-neg23.8%

        \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{-\sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      4. associate-*r/23.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      5. pow1/223.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      6. pow1/223.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5} \cdot \color{blue}{{0.5}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      7. pow-prod-down23.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
    6. Applied egg-rr23.8%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
    7. Step-by-step derivation
      1. expm1-def98.4%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-log1p98.4%

        \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)} \]
      3. associate-/r/98.6%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{t} \cdot \ell\right)} \]
      4. unpow1/298.6%

        \[\leadsto -\sin^{-1} \left(\frac{\color{blue}{\sqrt{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5}}}{t} \cdot \ell\right) \]
      5. *-commutative98.6%

        \[\leadsto -\sin^{-1} \left(\frac{\sqrt{\color{blue}{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}}{t} \cdot \ell\right) \]
    8. Simplified98.6%

      \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}{t} \cdot \ell\right)} \]
    9. Taylor expanded in Om around 0 98.0%

      \[\leadsto -\sin^{-1} \left(\color{blue}{\frac{\sqrt{0.5}}{t}} \cdot \ell\right) \]

    if -4e4 < (/.f64 t l) < 5.00000000000000031e-10

    1. Initial program 97.9%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around 0 83.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
    3. Step-by-step derivation
      1. unpow283.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}\right) \]
      2. unpow283.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}\right) \]
      3. times-frac97.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      4. unpow297.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}\right) \]
    4. Simplified97.7%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}\right)} \]
    5. Step-by-step derivation
      1. unpow297.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      2. clear-num97.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}}\right) \]
      3. un-div-inv97.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]
    6. Applied egg-rr97.7%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]

    if 5.00000000000000031e-10 < (/.f64 t l)

    1. Initial program 73.4%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Step-by-step derivation
      1. sqrt-div73.4%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      2. div-inv73.4%

        \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      3. add-sqr-sqrt73.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + \color{blue}{\sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}}}\right) \]
      4. hypot-1-def73.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\color{blue}{\mathsf{hypot}\left(1, \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}\right)}}\right) \]
      5. *-commutative73.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{{\left(\frac{t}{\ell}\right)}^{2} \cdot 2}}\right)}\right) \]
      6. sqrt-prod73.2%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\sqrt{{\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2}}\right)}\right) \]
      7. unpow273.2%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{\frac{t}{\ell} \cdot \frac{t}{\ell}}} \cdot \sqrt{2}\right)}\right) \]
      8. sqrt-prod96.3%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\left(\sqrt{\frac{t}{\ell}} \cdot \sqrt{\frac{t}{\ell}}\right)} \cdot \sqrt{2}\right)}\right) \]
      9. add-sqr-sqrt96.6%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\frac{t}{\ell}} \cdot \sqrt{2}\right)}\right) \]
    3. Applied egg-rr96.6%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    4. Step-by-step derivation
      1. unpow296.6%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      2. times-frac82.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om \cdot Om}{Omc \cdot Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      3. unpow282.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{{Om}^{2}}}{Omc \cdot Omc}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      4. unpow282.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{{Om}^{2}}{\color{blue}{{Omc}^{2}}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      5. associate-*r/82.4%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot 1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
      6. *-rgt-identity82.4%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      7. unpow282.4%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      8. unpow282.4%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      9. times-frac96.6%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      10. unpow296.6%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    5. Simplified96.6%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    6. Taylor expanded in Om around 0 82.4%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    7. Step-by-step derivation
      1. unpow25.5%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}\right) \]
      2. unpow25.5%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}\right) \]
    8. Simplified82.4%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    9. Step-by-step derivation
      1. times-frac6.2%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{Om}{Omc} \cdot \frac{Om}{Omc}\right)}\right) \]
      2. clear-num6.2%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \left(\frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}\right)\right) \]
      3. div-inv6.2%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right) \]
      4. associate-/r/6.2%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}\right) \]
    10. Applied egg-rr96.7%

      \[\leadsto \sin^{-1} \left(\frac{1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    11. Taylor expanded in Om around 0 62.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{\frac{1}{1 + \frac{{\left(\sqrt{2}\right)}^{2} \cdot {t}^{2}}{{\ell}^{2}}}}\right)} \]
    12. Step-by-step derivation
      1. associate-/l*62.0%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \color{blue}{\frac{{\left(\sqrt{2}\right)}^{2}}{\frac{{\ell}^{2}}{{t}^{2}}}}}}\right) \]
      2. unpow262.0%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{\color{blue}{\sqrt{2} \cdot \sqrt{2}}}{\frac{{\ell}^{2}}{{t}^{2}}}}}\right) \]
      3. rem-square-sqrt62.2%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{\color{blue}{2}}{\frac{{\ell}^{2}}{{t}^{2}}}}}\right) \]
      4. associate-/l*62.2%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \color{blue}{\frac{2 \cdot {t}^{2}}{{\ell}^{2}}}}}\right) \]
      5. unpow262.2%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{2 \cdot {t}^{2}}{\color{blue}{\ell \cdot \ell}}}}\right) \]
      6. times-frac64.9%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \color{blue}{\frac{2}{\ell} \cdot \frac{{t}^{2}}{\ell}}}}\right) \]
      7. unpow264.9%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{2}{\ell} \cdot \frac{\color{blue}{t \cdot t}}{\ell}}}\right) \]
    13. Simplified64.9%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -40000:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 5 \cdot 10^{-10}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{2}{\ell} \cdot \frac{t \cdot t}{\ell}}}\right)\\ \end{array} \]

Alternative 12: 86.1% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := 1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\\ \mathbf{if}\;\frac{t}{\ell} \leq -40000:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot t_1}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 5 \cdot 10^{-10}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{t_1}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{2}{\ell} \cdot \frac{t \cdot t}{\ell}}}\right)\\ \end{array} \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (let* ((t_1 (- 1.0 (/ (/ Om Omc) (/ Omc Om)))))
   (if (<= (/ t l) -40000.0)
     (- (asin (* l (/ (sqrt (* 0.5 t_1)) t))))
     (if (<= (/ t l) 5e-10)
       (asin (sqrt t_1))
       (asin (sqrt (/ 1.0 (+ 1.0 (* (/ 2.0 l) (/ (* t t) l))))))))))
double code(double t, double l, double Om, double Omc) {
	double t_1 = 1.0 - ((Om / Omc) / (Omc / Om));
	double tmp;
	if ((t / l) <= -40000.0) {
		tmp = -asin((l * (sqrt((0.5 * t_1)) / t)));
	} else if ((t / l) <= 5e-10) {
		tmp = asin(sqrt(t_1));
	} else {
		tmp = asin(sqrt((1.0 / (1.0 + ((2.0 / l) * ((t * t) / l))))));
	}
	return tmp;
}
real(8) function code(t, l, om, omc)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: omc
    real(8) :: t_1
    real(8) :: tmp
    t_1 = 1.0d0 - ((om / omc) / (omc / om))
    if ((t / l) <= (-40000.0d0)) then
        tmp = -asin((l * (sqrt((0.5d0 * t_1)) / t)))
    else if ((t / l) <= 5d-10) then
        tmp = asin(sqrt(t_1))
    else
        tmp = asin(sqrt((1.0d0 / (1.0d0 + ((2.0d0 / l) * ((t * t) / l))))))
    end if
    code = tmp
end function
public static double code(double t, double l, double Om, double Omc) {
	double t_1 = 1.0 - ((Om / Omc) / (Omc / Om));
	double tmp;
	if ((t / l) <= -40000.0) {
		tmp = -Math.asin((l * (Math.sqrt((0.5 * t_1)) / t)));
	} else if ((t / l) <= 5e-10) {
		tmp = Math.asin(Math.sqrt(t_1));
	} else {
		tmp = Math.asin(Math.sqrt((1.0 / (1.0 + ((2.0 / l) * ((t * t) / l))))));
	}
	return tmp;
}
def code(t, l, Om, Omc):
	t_1 = 1.0 - ((Om / Omc) / (Omc / Om))
	tmp = 0
	if (t / l) <= -40000.0:
		tmp = -math.asin((l * (math.sqrt((0.5 * t_1)) / t)))
	elif (t / l) <= 5e-10:
		tmp = math.asin(math.sqrt(t_1))
	else:
		tmp = math.asin(math.sqrt((1.0 / (1.0 + ((2.0 / l) * ((t * t) / l))))))
	return tmp
function code(t, l, Om, Omc)
	t_1 = Float64(1.0 - Float64(Float64(Om / Omc) / Float64(Omc / Om)))
	tmp = 0.0
	if (Float64(t / l) <= -40000.0)
		tmp = Float64(-asin(Float64(l * Float64(sqrt(Float64(0.5 * t_1)) / t))));
	elseif (Float64(t / l) <= 5e-10)
		tmp = asin(sqrt(t_1));
	else
		tmp = asin(sqrt(Float64(1.0 / Float64(1.0 + Float64(Float64(2.0 / l) * Float64(Float64(t * t) / l))))));
	end
	return tmp
end
function tmp_2 = code(t, l, Om, Omc)
	t_1 = 1.0 - ((Om / Omc) / (Omc / Om));
	tmp = 0.0;
	if ((t / l) <= -40000.0)
		tmp = -asin((l * (sqrt((0.5 * t_1)) / t)));
	elseif ((t / l) <= 5e-10)
		tmp = asin(sqrt(t_1));
	else
		tmp = asin(sqrt((1.0 / (1.0 + ((2.0 / l) * ((t * t) / l))))));
	end
	tmp_2 = tmp;
end
code[t_, l_, Om_, Omc_] := Block[{t$95$1 = N[(1.0 - N[(N[(Om / Omc), $MachinePrecision] / N[(Omc / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(t / l), $MachinePrecision], -40000.0], (-N[ArcSin[N[(l * N[(N[Sqrt[N[(0.5 * t$95$1), $MachinePrecision]], $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), If[LessEqual[N[(t / l), $MachinePrecision], 5e-10], N[ArcSin[N[Sqrt[t$95$1], $MachinePrecision]], $MachinePrecision], N[ArcSin[N[Sqrt[N[(1.0 / N[(1.0 + N[(N[(2.0 / l), $MachinePrecision] * N[(N[(t * t), $MachinePrecision] / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := 1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\\
\mathbf{if}\;\frac{t}{\ell} \leq -40000:\\
\;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot t_1}}{t}\right)\\

\mathbf{elif}\;\frac{t}{\ell} \leq 5 \cdot 10^{-10}:\\
\;\;\;\;\sin^{-1} \left(\sqrt{t_1}\right)\\

\mathbf{else}:\\
\;\;\;\;\sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{2}{\ell} \cdot \frac{t \cdot t}{\ell}}}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 t l) < -4e4

    1. Initial program 62.4%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around -inf 87.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \left(\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg87.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
      2. *-commutative87.0%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}}\right) \]
      3. unpow287.0%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      4. unpow287.0%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      5. times-frac98.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      6. unpow298.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      7. associate-/l*98.5%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\frac{\sqrt{0.5}}{\frac{t}{\ell}}}\right) \]
    4. Simplified98.5%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    5. Step-by-step derivation
      1. expm1-log1p-u98.5%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-udef23.8%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
      3. asin-neg23.8%

        \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{-\sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      4. associate-*r/23.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      5. pow1/223.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      6. pow1/223.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5} \cdot \color{blue}{{0.5}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      7. pow-prod-down23.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
    6. Applied egg-rr23.8%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
    7. Step-by-step derivation
      1. expm1-def98.4%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-log1p98.4%

        \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)} \]
      3. associate-/r/98.6%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{t} \cdot \ell\right)} \]
      4. unpow1/298.6%

        \[\leadsto -\sin^{-1} \left(\frac{\color{blue}{\sqrt{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5}}}{t} \cdot \ell\right) \]
      5. *-commutative98.6%

        \[\leadsto -\sin^{-1} \left(\frac{\sqrt{\color{blue}{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}}{t} \cdot \ell\right) \]
    8. Simplified98.6%

      \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}{t} \cdot \ell\right)} \]
    9. Step-by-step derivation
      1. unpow25.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      2. clear-num5.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}}\right) \]
      3. un-div-inv5.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]
    10. Applied egg-rr98.6%

      \[\leadsto -\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)}}{t} \cdot \ell\right) \]

    if -4e4 < (/.f64 t l) < 5.00000000000000031e-10

    1. Initial program 97.9%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around 0 83.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
    3. Step-by-step derivation
      1. unpow283.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}\right) \]
      2. unpow283.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}\right) \]
      3. times-frac97.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      4. unpow297.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}\right) \]
    4. Simplified97.7%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}\right)} \]
    5. Step-by-step derivation
      1. unpow297.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      2. clear-num97.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}}\right) \]
      3. un-div-inv97.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]
    6. Applied egg-rr97.7%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]

    if 5.00000000000000031e-10 < (/.f64 t l)

    1. Initial program 73.4%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Step-by-step derivation
      1. sqrt-div73.4%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      2. div-inv73.4%

        \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      3. add-sqr-sqrt73.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + \color{blue}{\sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}}}\right) \]
      4. hypot-1-def73.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\color{blue}{\mathsf{hypot}\left(1, \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}\right)}}\right) \]
      5. *-commutative73.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{{\left(\frac{t}{\ell}\right)}^{2} \cdot 2}}\right)}\right) \]
      6. sqrt-prod73.2%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\sqrt{{\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2}}\right)}\right) \]
      7. unpow273.2%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{\frac{t}{\ell} \cdot \frac{t}{\ell}}} \cdot \sqrt{2}\right)}\right) \]
      8. sqrt-prod96.3%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\left(\sqrt{\frac{t}{\ell}} \cdot \sqrt{\frac{t}{\ell}}\right)} \cdot \sqrt{2}\right)}\right) \]
      9. add-sqr-sqrt96.6%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\frac{t}{\ell}} \cdot \sqrt{2}\right)}\right) \]
    3. Applied egg-rr96.6%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    4. Step-by-step derivation
      1. unpow296.6%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      2. times-frac82.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om \cdot Om}{Omc \cdot Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      3. unpow282.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{{Om}^{2}}}{Omc \cdot Omc}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      4. unpow282.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{{Om}^{2}}{\color{blue}{{Omc}^{2}}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      5. associate-*r/82.4%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot 1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
      6. *-rgt-identity82.4%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      7. unpow282.4%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      8. unpow282.4%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      9. times-frac96.6%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      10. unpow296.6%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    5. Simplified96.6%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    6. Taylor expanded in Om around 0 82.4%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    7. Step-by-step derivation
      1. unpow25.5%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}\right) \]
      2. unpow25.5%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}\right) \]
    8. Simplified82.4%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    9. Step-by-step derivation
      1. times-frac6.2%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{Om}{Omc} \cdot \frac{Om}{Omc}\right)}\right) \]
      2. clear-num6.2%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \left(\frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}\right)\right) \]
      3. div-inv6.2%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right) \]
      4. associate-/r/6.2%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}\right) \]
    10. Applied egg-rr96.7%

      \[\leadsto \sin^{-1} \left(\frac{1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    11. Taylor expanded in Om around 0 62.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{\frac{1}{1 + \frac{{\left(\sqrt{2}\right)}^{2} \cdot {t}^{2}}{{\ell}^{2}}}}\right)} \]
    12. Step-by-step derivation
      1. associate-/l*62.0%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \color{blue}{\frac{{\left(\sqrt{2}\right)}^{2}}{\frac{{\ell}^{2}}{{t}^{2}}}}}}\right) \]
      2. unpow262.0%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{\color{blue}{\sqrt{2} \cdot \sqrt{2}}}{\frac{{\ell}^{2}}{{t}^{2}}}}}\right) \]
      3. rem-square-sqrt62.2%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{\color{blue}{2}}{\frac{{\ell}^{2}}{{t}^{2}}}}}\right) \]
      4. associate-/l*62.2%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \color{blue}{\frac{2 \cdot {t}^{2}}{{\ell}^{2}}}}}\right) \]
      5. unpow262.2%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{2 \cdot {t}^{2}}{\color{blue}{\ell \cdot \ell}}}}\right) \]
      6. times-frac64.9%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \color{blue}{\frac{2}{\ell} \cdot \frac{{t}^{2}}{\ell}}}}\right) \]
      7. unpow264.9%

        \[\leadsto \sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{2}{\ell} \cdot \frac{\color{blue}{t \cdot t}}{\ell}}}\right) \]
    13. Simplified64.9%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{\frac{1}{1 + \frac{2}{\ell} \cdot \frac{t \cdot t}{\ell}}}\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification89.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -40000:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5 \cdot \left(1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}\right)}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 5 \cdot 10^{-10}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{\frac{1}{1 + \frac{2}{\ell} \cdot \frac{t \cdot t}{\ell}}}\right)\\ \end{array} \]

Alternative 13: 80.2% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -40000:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 2 \cdot 10^{+184}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)\\ \mathbf{else}:\\ \;\;\;\;-\sin^{-1} \left(\frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\\ \end{array} \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (if (<= (/ t l) -40000.0)
   (- (asin (* l (/ (sqrt 0.5) t))))
   (if (<= (/ t l) 2e+184)
     (asin (sqrt (- 1.0 (/ (/ Om Omc) (/ Omc Om)))))
     (- (asin (/ (sqrt 0.5) (/ t l)))))))
double code(double t, double l, double Om, double Omc) {
	double tmp;
	if ((t / l) <= -40000.0) {
		tmp = -asin((l * (sqrt(0.5) / t)));
	} else if ((t / l) <= 2e+184) {
		tmp = asin(sqrt((1.0 - ((Om / Omc) / (Omc / Om)))));
	} else {
		tmp = -asin((sqrt(0.5) / (t / l)));
	}
	return tmp;
}
real(8) function code(t, l, om, omc)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: omc
    real(8) :: tmp
    if ((t / l) <= (-40000.0d0)) then
        tmp = -asin((l * (sqrt(0.5d0) / t)))
    else if ((t / l) <= 2d+184) then
        tmp = asin(sqrt((1.0d0 - ((om / omc) / (omc / om)))))
    else
        tmp = -asin((sqrt(0.5d0) / (t / l)))
    end if
    code = tmp
end function
public static double code(double t, double l, double Om, double Omc) {
	double tmp;
	if ((t / l) <= -40000.0) {
		tmp = -Math.asin((l * (Math.sqrt(0.5) / t)));
	} else if ((t / l) <= 2e+184) {
		tmp = Math.asin(Math.sqrt((1.0 - ((Om / Omc) / (Omc / Om)))));
	} else {
		tmp = -Math.asin((Math.sqrt(0.5) / (t / l)));
	}
	return tmp;
}
def code(t, l, Om, Omc):
	tmp = 0
	if (t / l) <= -40000.0:
		tmp = -math.asin((l * (math.sqrt(0.5) / t)))
	elif (t / l) <= 2e+184:
		tmp = math.asin(math.sqrt((1.0 - ((Om / Omc) / (Omc / Om)))))
	else:
		tmp = -math.asin((math.sqrt(0.5) / (t / l)))
	return tmp
function code(t, l, Om, Omc)
	tmp = 0.0
	if (Float64(t / l) <= -40000.0)
		tmp = Float64(-asin(Float64(l * Float64(sqrt(0.5) / t))));
	elseif (Float64(t / l) <= 2e+184)
		tmp = asin(sqrt(Float64(1.0 - Float64(Float64(Om / Omc) / Float64(Omc / Om)))));
	else
		tmp = Float64(-asin(Float64(sqrt(0.5) / Float64(t / l))));
	end
	return tmp
end
function tmp_2 = code(t, l, Om, Omc)
	tmp = 0.0;
	if ((t / l) <= -40000.0)
		tmp = -asin((l * (sqrt(0.5) / t)));
	elseif ((t / l) <= 2e+184)
		tmp = asin(sqrt((1.0 - ((Om / Omc) / (Omc / Om)))));
	else
		tmp = -asin((sqrt(0.5) / (t / l)));
	end
	tmp_2 = tmp;
end
code[t_, l_, Om_, Omc_] := If[LessEqual[N[(t / l), $MachinePrecision], -40000.0], (-N[ArcSin[N[(l * N[(N[Sqrt[0.5], $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), If[LessEqual[N[(t / l), $MachinePrecision], 2e+184], N[ArcSin[N[Sqrt[N[(1.0 - N[(N[(Om / Omc), $MachinePrecision] / N[(Omc / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision], (-N[ArcSin[N[(N[Sqrt[0.5], $MachinePrecision] / N[(t / l), $MachinePrecision]), $MachinePrecision]], $MachinePrecision])]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;\frac{t}{\ell} \leq -40000:\\
\;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\

\mathbf{elif}\;\frac{t}{\ell} \leq 2 \cdot 10^{+184}:\\
\;\;\;\;\sin^{-1} \left(\sqrt{1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)\\

\mathbf{else}:\\
\;\;\;\;-\sin^{-1} \left(\frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 t l) < -4e4

    1. Initial program 62.4%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around -inf 87.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \left(\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg87.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
      2. *-commutative87.0%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}}\right) \]
      3. unpow287.0%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      4. unpow287.0%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      5. times-frac98.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      6. unpow298.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      7. associate-/l*98.5%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\frac{\sqrt{0.5}}{\frac{t}{\ell}}}\right) \]
    4. Simplified98.5%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    5. Step-by-step derivation
      1. expm1-log1p-u98.5%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-udef23.8%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
      3. asin-neg23.8%

        \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{-\sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      4. associate-*r/23.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      5. pow1/223.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      6. pow1/223.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5} \cdot \color{blue}{{0.5}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      7. pow-prod-down23.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
    6. Applied egg-rr23.8%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
    7. Step-by-step derivation
      1. expm1-def98.4%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-log1p98.4%

        \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)} \]
      3. associate-/r/98.6%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{t} \cdot \ell\right)} \]
      4. unpow1/298.6%

        \[\leadsto -\sin^{-1} \left(\frac{\color{blue}{\sqrt{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5}}}{t} \cdot \ell\right) \]
      5. *-commutative98.6%

        \[\leadsto -\sin^{-1} \left(\frac{\sqrt{\color{blue}{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}}{t} \cdot \ell\right) \]
    8. Simplified98.6%

      \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}{t} \cdot \ell\right)} \]
    9. Taylor expanded in Om around 0 98.0%

      \[\leadsto -\sin^{-1} \left(\color{blue}{\frac{\sqrt{0.5}}{t}} \cdot \ell\right) \]

    if -4e4 < (/.f64 t l) < 2.00000000000000003e184

    1. Initial program 95.1%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around 0 66.8%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
    3. Step-by-step derivation
      1. unpow266.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}\right) \]
      2. unpow266.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}\right) \]
      3. times-frac78.5%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      4. unpow278.5%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}\right) \]
    4. Simplified78.5%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}\right)} \]
    5. Step-by-step derivation
      1. unpow278.5%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      2. clear-num78.5%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}}\right) \]
      3. un-div-inv78.5%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]
    6. Applied egg-rr78.5%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}}\right) \]

    if 2.00000000000000003e184 < (/.f64 t l)

    1. Initial program 60.1%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around -inf 48.5%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \left(\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg48.5%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
      2. *-commutative48.5%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}}\right) \]
      3. unpow248.5%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      4. unpow248.5%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      5. times-frac59.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      6. unpow259.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      7. associate-/l*59.6%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\frac{\sqrt{0.5}}{\frac{t}{\ell}}}\right) \]
    4. Simplified59.6%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    5. Step-by-step derivation
      1. expm1-log1p-u59.6%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-udef60.1%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
      3. asin-neg60.1%

        \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{-\sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      4. associate-*r/60.1%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      5. pow1/260.1%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      6. pow1/260.1%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5} \cdot \color{blue}{{0.5}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      7. pow-prod-down60.1%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
    6. Applied egg-rr60.1%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
    7. Step-by-step derivation
      1. expm1-def59.6%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-log1p59.6%

        \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)} \]
      3. associate-/r/59.3%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{t} \cdot \ell\right)} \]
      4. unpow1/259.3%

        \[\leadsto -\sin^{-1} \left(\frac{\color{blue}{\sqrt{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5}}}{t} \cdot \ell\right) \]
      5. *-commutative59.3%

        \[\leadsto -\sin^{-1} \left(\frac{\sqrt{\color{blue}{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}}{t} \cdot \ell\right) \]
    8. Simplified59.3%

      \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}{t} \cdot \ell\right)} \]
    9. Taylor expanded in Om around 0 59.3%

      \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{\sqrt{0.5} \cdot \ell}{t}\right)} \]
    10. Step-by-step derivation
      1. associate-/l*59.6%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    11. Simplified59.6%

      \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification81.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -40000:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 2 \cdot 10^{+184}:\\ \;\;\;\;\sin^{-1} \left(\sqrt{1 - \frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right)\\ \mathbf{else}:\\ \;\;\;\;-\sin^{-1} \left(\frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\\ \end{array} \]

Alternative 14: 80.0% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -40000:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 2 \cdot 10^{+184}:\\ \;\;\;\;\sin^{-1} \left(1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;-\sin^{-1} \left(\frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\\ \end{array} \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (if (<= (/ t l) -40000.0)
   (- (asin (* l (/ (sqrt 0.5) t))))
   (if (<= (/ t l) 2e+184)
     (asin (+ 1.0 (* -0.5 (* Om (/ (/ Om Omc) Omc)))))
     (- (asin (/ (sqrt 0.5) (/ t l)))))))
double code(double t, double l, double Om, double Omc) {
	double tmp;
	if ((t / l) <= -40000.0) {
		tmp = -asin((l * (sqrt(0.5) / t)));
	} else if ((t / l) <= 2e+184) {
		tmp = asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))));
	} else {
		tmp = -asin((sqrt(0.5) / (t / l)));
	}
	return tmp;
}
real(8) function code(t, l, om, omc)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: omc
    real(8) :: tmp
    if ((t / l) <= (-40000.0d0)) then
        tmp = -asin((l * (sqrt(0.5d0) / t)))
    else if ((t / l) <= 2d+184) then
        tmp = asin((1.0d0 + ((-0.5d0) * (om * ((om / omc) / omc)))))
    else
        tmp = -asin((sqrt(0.5d0) / (t / l)))
    end if
    code = tmp
end function
public static double code(double t, double l, double Om, double Omc) {
	double tmp;
	if ((t / l) <= -40000.0) {
		tmp = -Math.asin((l * (Math.sqrt(0.5) / t)));
	} else if ((t / l) <= 2e+184) {
		tmp = Math.asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))));
	} else {
		tmp = -Math.asin((Math.sqrt(0.5) / (t / l)));
	}
	return tmp;
}
def code(t, l, Om, Omc):
	tmp = 0
	if (t / l) <= -40000.0:
		tmp = -math.asin((l * (math.sqrt(0.5) / t)))
	elif (t / l) <= 2e+184:
		tmp = math.asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))))
	else:
		tmp = -math.asin((math.sqrt(0.5) / (t / l)))
	return tmp
function code(t, l, Om, Omc)
	tmp = 0.0
	if (Float64(t / l) <= -40000.0)
		tmp = Float64(-asin(Float64(l * Float64(sqrt(0.5) / t))));
	elseif (Float64(t / l) <= 2e+184)
		tmp = asin(Float64(1.0 + Float64(-0.5 * Float64(Om * Float64(Float64(Om / Omc) / Omc)))));
	else
		tmp = Float64(-asin(Float64(sqrt(0.5) / Float64(t / l))));
	end
	return tmp
end
function tmp_2 = code(t, l, Om, Omc)
	tmp = 0.0;
	if ((t / l) <= -40000.0)
		tmp = -asin((l * (sqrt(0.5) / t)));
	elseif ((t / l) <= 2e+184)
		tmp = asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))));
	else
		tmp = -asin((sqrt(0.5) / (t / l)));
	end
	tmp_2 = tmp;
end
code[t_, l_, Om_, Omc_] := If[LessEqual[N[(t / l), $MachinePrecision], -40000.0], (-N[ArcSin[N[(l * N[(N[Sqrt[0.5], $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), If[LessEqual[N[(t / l), $MachinePrecision], 2e+184], N[ArcSin[N[(1.0 + N[(-0.5 * N[(Om * N[(N[(Om / Omc), $MachinePrecision] / Omc), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], (-N[ArcSin[N[(N[Sqrt[0.5], $MachinePrecision] / N[(t / l), $MachinePrecision]), $MachinePrecision]], $MachinePrecision])]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;\frac{t}{\ell} \leq -40000:\\
\;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\

\mathbf{elif}\;\frac{t}{\ell} \leq 2 \cdot 10^{+184}:\\
\;\;\;\;\sin^{-1} \left(1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)\right)\\

\mathbf{else}:\\
\;\;\;\;-\sin^{-1} \left(\frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 t l) < -4e4

    1. Initial program 62.4%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around -inf 87.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \left(\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg87.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
      2. *-commutative87.0%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}}\right) \]
      3. unpow287.0%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      4. unpow287.0%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      5. times-frac98.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      6. unpow298.4%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      7. associate-/l*98.5%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\frac{\sqrt{0.5}}{\frac{t}{\ell}}}\right) \]
    4. Simplified98.5%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    5. Step-by-step derivation
      1. expm1-log1p-u98.5%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-udef23.8%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
      3. asin-neg23.8%

        \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{-\sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      4. associate-*r/23.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      5. pow1/223.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      6. pow1/223.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5} \cdot \color{blue}{{0.5}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      7. pow-prod-down23.8%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
    6. Applied egg-rr23.8%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
    7. Step-by-step derivation
      1. expm1-def98.4%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-log1p98.4%

        \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)} \]
      3. associate-/r/98.6%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{t} \cdot \ell\right)} \]
      4. unpow1/298.6%

        \[\leadsto -\sin^{-1} \left(\frac{\color{blue}{\sqrt{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5}}}{t} \cdot \ell\right) \]
      5. *-commutative98.6%

        \[\leadsto -\sin^{-1} \left(\frac{\sqrt{\color{blue}{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}}{t} \cdot \ell\right) \]
    8. Simplified98.6%

      \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}{t} \cdot \ell\right)} \]
    9. Taylor expanded in Om around 0 98.0%

      \[\leadsto -\sin^{-1} \left(\color{blue}{\frac{\sqrt{0.5}}{t}} \cdot \ell\right) \]

    if -4e4 < (/.f64 t l) < 2.00000000000000003e184

    1. Initial program 95.1%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around 0 66.8%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
    3. Step-by-step derivation
      1. unpow266.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}\right) \]
      2. unpow266.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}\right) \]
      3. times-frac78.5%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      4. unpow278.5%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}\right) \]
    4. Simplified78.5%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}\right)} \]
    5. Taylor expanded in Om around 0 66.5%

      \[\leadsto \sin^{-1} \color{blue}{\left(1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}\right)} \]
    6. Step-by-step derivation
      1. unpow266.5%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}\right) \]
      2. unpow266.5%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}\right) \]
    7. Simplified66.5%

      \[\leadsto \sin^{-1} \color{blue}{\left(1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}\right)} \]
    8. Step-by-step derivation
      1. times-frac77.5%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{Om}{Omc} \cdot \frac{Om}{Omc}\right)}\right) \]
      2. clear-num77.5%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \left(\frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}\right)\right) \]
      3. div-inv77.5%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right) \]
      4. associate-/r/77.5%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}\right) \]
    9. Applied egg-rr77.5%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}\right) \]

    if 2.00000000000000003e184 < (/.f64 t l)

    1. Initial program 60.1%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around -inf 48.5%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \left(\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg48.5%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
      2. *-commutative48.5%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}}\right) \]
      3. unpow248.5%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      4. unpow248.5%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      5. times-frac59.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      6. unpow259.3%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      7. associate-/l*59.6%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\frac{\sqrt{0.5}}{\frac{t}{\ell}}}\right) \]
    4. Simplified59.6%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    5. Step-by-step derivation
      1. expm1-log1p-u59.6%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-udef60.1%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
      3. asin-neg60.1%

        \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{-\sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      4. associate-*r/60.1%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      5. pow1/260.1%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      6. pow1/260.1%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5} \cdot \color{blue}{{0.5}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      7. pow-prod-down60.1%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
    6. Applied egg-rr60.1%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
    7. Step-by-step derivation
      1. expm1-def59.6%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-log1p59.6%

        \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)} \]
      3. associate-/r/59.3%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{t} \cdot \ell\right)} \]
      4. unpow1/259.3%

        \[\leadsto -\sin^{-1} \left(\frac{\color{blue}{\sqrt{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5}}}{t} \cdot \ell\right) \]
      5. *-commutative59.3%

        \[\leadsto -\sin^{-1} \left(\frac{\sqrt{\color{blue}{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}}{t} \cdot \ell\right) \]
    8. Simplified59.3%

      \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}{t} \cdot \ell\right)} \]
    9. Taylor expanded in Om around 0 59.3%

      \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{\sqrt{0.5} \cdot \ell}{t}\right)} \]
    10. Step-by-step derivation
      1. associate-/l*59.6%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    11. Simplified59.6%

      \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification81.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{t}{\ell} \leq -40000:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\ \mathbf{elif}\;\frac{t}{\ell} \leq 2 \cdot 10^{+184}:\\ \;\;\;\;\sin^{-1} \left(1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;-\sin^{-1} \left(\frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\\ \end{array} \]

Alternative 15: 62.4% accurate, 2.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -2 \cdot 10^{-43} \lor \neg \left(t \leq 1.35 \cdot 10^{+94}\right):\\ \;\;\;\;\sin^{-1} \left(\frac{-\ell}{\sqrt{2} \cdot t}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)\right)\\ \end{array} \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (if (or (<= t -2e-43) (not (<= t 1.35e+94)))
   (asin (/ (- l) (* (sqrt 2.0) t)))
   (asin (+ 1.0 (* -0.5 (* Om (/ (/ Om Omc) Omc)))))))
double code(double t, double l, double Om, double Omc) {
	double tmp;
	if ((t <= -2e-43) || !(t <= 1.35e+94)) {
		tmp = asin((-l / (sqrt(2.0) * t)));
	} else {
		tmp = asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))));
	}
	return tmp;
}
real(8) function code(t, l, om, omc)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: omc
    real(8) :: tmp
    if ((t <= (-2d-43)) .or. (.not. (t <= 1.35d+94))) then
        tmp = asin((-l / (sqrt(2.0d0) * t)))
    else
        tmp = asin((1.0d0 + ((-0.5d0) * (om * ((om / omc) / omc)))))
    end if
    code = tmp
end function
public static double code(double t, double l, double Om, double Omc) {
	double tmp;
	if ((t <= -2e-43) || !(t <= 1.35e+94)) {
		tmp = Math.asin((-l / (Math.sqrt(2.0) * t)));
	} else {
		tmp = Math.asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))));
	}
	return tmp;
}
def code(t, l, Om, Omc):
	tmp = 0
	if (t <= -2e-43) or not (t <= 1.35e+94):
		tmp = math.asin((-l / (math.sqrt(2.0) * t)))
	else:
		tmp = math.asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))))
	return tmp
function code(t, l, Om, Omc)
	tmp = 0.0
	if ((t <= -2e-43) || !(t <= 1.35e+94))
		tmp = asin(Float64(Float64(-l) / Float64(sqrt(2.0) * t)));
	else
		tmp = asin(Float64(1.0 + Float64(-0.5 * Float64(Om * Float64(Float64(Om / Omc) / Omc)))));
	end
	return tmp
end
function tmp_2 = code(t, l, Om, Omc)
	tmp = 0.0;
	if ((t <= -2e-43) || ~((t <= 1.35e+94)))
		tmp = asin((-l / (sqrt(2.0) * t)));
	else
		tmp = asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))));
	end
	tmp_2 = tmp;
end
code[t_, l_, Om_, Omc_] := If[Or[LessEqual[t, -2e-43], N[Not[LessEqual[t, 1.35e+94]], $MachinePrecision]], N[ArcSin[N[((-l) / N[(N[Sqrt[2.0], $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[ArcSin[N[(1.0 + N[(-0.5 * N[(Om * N[(N[(Om / Omc), $MachinePrecision] / Omc), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -2 \cdot 10^{-43} \lor \neg \left(t \leq 1.35 \cdot 10^{+94}\right):\\
\;\;\;\;\sin^{-1} \left(\frac{-\ell}{\sqrt{2} \cdot t}\right)\\

\mathbf{else}:\\
\;\;\;\;\sin^{-1} \left(1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -2.00000000000000015e-43 or 1.3500000000000001e94 < t

    1. Initial program 71.9%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Step-by-step derivation
      1. sqrt-div71.8%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      2. div-inv71.8%

        \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      3. add-sqr-sqrt71.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + \color{blue}{\sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}}}\right) \]
      4. hypot-1-def71.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\color{blue}{\mathsf{hypot}\left(1, \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}\right)}}\right) \]
      5. *-commutative71.8%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{{\left(\frac{t}{\ell}\right)}^{2} \cdot 2}}\right)}\right) \]
      6. sqrt-prod71.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\sqrt{{\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2}}\right)}\right) \]
      7. unpow271.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{\frac{t}{\ell} \cdot \frac{t}{\ell}}} \cdot \sqrt{2}\right)}\right) \]
      8. sqrt-prod37.7%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\left(\sqrt{\frac{t}{\ell}} \cdot \sqrt{\frac{t}{\ell}}\right)} \cdot \sqrt{2}\right)}\right) \]
      9. add-sqr-sqrt97.5%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\frac{t}{\ell}} \cdot \sqrt{2}\right)}\right) \]
    3. Applied egg-rr97.5%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    4. Step-by-step derivation
      1. unpow297.5%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      2. times-frac82.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om \cdot Om}{Omc \cdot Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      3. unpow282.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{{Om}^{2}}}{Omc \cdot Omc}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      4. unpow282.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{{Om}^{2}}{\color{blue}{{Omc}^{2}}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      5. associate-*r/82.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot 1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
      6. *-rgt-identity82.0%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      7. unpow282.0%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      8. unpow282.0%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      9. times-frac97.5%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      10. unpow297.5%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    5. Simplified97.5%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    6. Taylor expanded in Om around 0 82.0%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    7. Step-by-step derivation
      1. unpow218.6%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}\right) \]
      2. unpow218.6%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}\right) \]
    8. Simplified82.0%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    9. Taylor expanded in t around -inf 54.4%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \frac{\left(1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}\right) \cdot \ell}{\sqrt{2} \cdot t}\right)} \]
    10. Step-by-step derivation
      1. mul-1-neg54.4%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\left(1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}\right) \cdot \ell}{\sqrt{2} \cdot t}\right)} \]
      2. times-frac54.3%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\frac{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}{\sqrt{2}} \cdot \frac{\ell}{t}}\right) \]
      3. unpow254.3%

        \[\leadsto \sin^{-1} \left(-\frac{1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}{\sqrt{2}} \cdot \frac{\ell}{t}\right) \]
      4. unpow254.3%

        \[\leadsto \sin^{-1} \left(-\frac{1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}{\sqrt{2}} \cdot \frac{\ell}{t}\right) \]
    11. Simplified54.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}{\sqrt{2}} \cdot \frac{\ell}{t}\right)} \]
    12. Taylor expanded in Om around 0 61.6%

      \[\leadsto \sin^{-1} \left(-\color{blue}{\frac{\ell}{\sqrt{2} \cdot t}}\right) \]

    if -2.00000000000000015e-43 < t < 1.3500000000000001e94

    1. Initial program 91.6%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around 0 64.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
    3. Step-by-step derivation
      1. unpow264.3%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}\right) \]
      2. unpow264.3%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}\right) \]
      3. times-frac74.3%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      4. unpow274.3%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}\right) \]
    4. Simplified74.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}\right)} \]
    5. Taylor expanded in Om around 0 64.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}\right)} \]
    6. Step-by-step derivation
      1. unpow264.0%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}\right) \]
      2. unpow264.0%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}\right) \]
    7. Simplified64.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}\right)} \]
    8. Step-by-step derivation
      1. times-frac73.6%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{Om}{Omc} \cdot \frac{Om}{Omc}\right)}\right) \]
      2. clear-num73.6%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \left(\frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}\right)\right) \]
      3. div-inv73.6%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right) \]
      4. associate-/r/73.6%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}\right) \]
    9. Applied egg-rr73.6%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification67.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2 \cdot 10^{-43} \lor \neg \left(t \leq 1.35 \cdot 10^{+94}\right):\\ \;\;\;\;\sin^{-1} \left(\frac{-\ell}{\sqrt{2} \cdot t}\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)\right)\\ \end{array} \]

Alternative 16: 62.4% accurate, 2.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -9.5 \cdot 10^{-43}:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\ \mathbf{elif}\;t \leq 3.45 \cdot 10^{+95}:\\ \;\;\;\;\sin^{-1} \left(1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\frac{-\ell}{\sqrt{2} \cdot t}\right)\\ \end{array} \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (if (<= t -9.5e-43)
   (- (asin (* l (/ (sqrt 0.5) t))))
   (if (<= t 3.45e+95)
     (asin (+ 1.0 (* -0.5 (* Om (/ (/ Om Omc) Omc)))))
     (asin (/ (- l) (* (sqrt 2.0) t))))))
double code(double t, double l, double Om, double Omc) {
	double tmp;
	if (t <= -9.5e-43) {
		tmp = -asin((l * (sqrt(0.5) / t)));
	} else if (t <= 3.45e+95) {
		tmp = asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))));
	} else {
		tmp = asin((-l / (sqrt(2.0) * t)));
	}
	return tmp;
}
real(8) function code(t, l, om, omc)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: omc
    real(8) :: tmp
    if (t <= (-9.5d-43)) then
        tmp = -asin((l * (sqrt(0.5d0) / t)))
    else if (t <= 3.45d+95) then
        tmp = asin((1.0d0 + ((-0.5d0) * (om * ((om / omc) / omc)))))
    else
        tmp = asin((-l / (sqrt(2.0d0) * t)))
    end if
    code = tmp
end function
public static double code(double t, double l, double Om, double Omc) {
	double tmp;
	if (t <= -9.5e-43) {
		tmp = -Math.asin((l * (Math.sqrt(0.5) / t)));
	} else if (t <= 3.45e+95) {
		tmp = Math.asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))));
	} else {
		tmp = Math.asin((-l / (Math.sqrt(2.0) * t)));
	}
	return tmp;
}
def code(t, l, Om, Omc):
	tmp = 0
	if t <= -9.5e-43:
		tmp = -math.asin((l * (math.sqrt(0.5) / t)))
	elif t <= 3.45e+95:
		tmp = math.asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))))
	else:
		tmp = math.asin((-l / (math.sqrt(2.0) * t)))
	return tmp
function code(t, l, Om, Omc)
	tmp = 0.0
	if (t <= -9.5e-43)
		tmp = Float64(-asin(Float64(l * Float64(sqrt(0.5) / t))));
	elseif (t <= 3.45e+95)
		tmp = asin(Float64(1.0 + Float64(-0.5 * Float64(Om * Float64(Float64(Om / Omc) / Omc)))));
	else
		tmp = asin(Float64(Float64(-l) / Float64(sqrt(2.0) * t)));
	end
	return tmp
end
function tmp_2 = code(t, l, Om, Omc)
	tmp = 0.0;
	if (t <= -9.5e-43)
		tmp = -asin((l * (sqrt(0.5) / t)));
	elseif (t <= 3.45e+95)
		tmp = asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))));
	else
		tmp = asin((-l / (sqrt(2.0) * t)));
	end
	tmp_2 = tmp;
end
code[t_, l_, Om_, Omc_] := If[LessEqual[t, -9.5e-43], (-N[ArcSin[N[(l * N[(N[Sqrt[0.5], $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), If[LessEqual[t, 3.45e+95], N[ArcSin[N[(1.0 + N[(-0.5 * N[(Om * N[(N[(Om / Omc), $MachinePrecision] / Omc), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[ArcSin[N[((-l) / N[(N[Sqrt[2.0], $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -9.5 \cdot 10^{-43}:\\
\;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\

\mathbf{elif}\;t \leq 3.45 \cdot 10^{+95}:\\
\;\;\;\;\sin^{-1} \left(1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)\right)\\

\mathbf{else}:\\
\;\;\;\;\sin^{-1} \left(\frac{-\ell}{\sqrt{2} \cdot t}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -9.50000000000000044e-43

    1. Initial program 67.1%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around -inf 55.1%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \left(\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)\right)} \]
    3. Step-by-step derivation
      1. mul-1-neg55.1%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\sqrt{0.5} \cdot \ell}{t} \cdot \sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
      2. *-commutative55.1%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}}\right) \]
      3. unpow255.1%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      4. unpow255.1%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      5. times-frac61.7%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      6. unpow261.7%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}} \cdot \frac{\sqrt{0.5} \cdot \ell}{t}\right) \]
      7. associate-/l*61.7%

        \[\leadsto \sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \color{blue}{\frac{\sqrt{0.5}}{\frac{t}{\ell}}}\right) \]
    4. Simplified61.7%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)} \]
    5. Step-by-step derivation
      1. expm1-log1p-u61.7%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-udef21.9%

        \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(\sin^{-1} \left(-\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
      3. asin-neg21.9%

        \[\leadsto e^{\mathsf{log1p}\left(\color{blue}{-\sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{\sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      4. associate-*r/21.9%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)}\right)} - 1 \]
      5. pow1/221.9%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5}} \cdot \sqrt{0.5}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      6. pow1/221.9%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}^{0.5} \cdot \color{blue}{{0.5}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
      7. pow-prod-down21.9%

        \[\leadsto e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{\color{blue}{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}}{\frac{t}{\ell}}\right)\right)} - 1 \]
    6. Applied egg-rr21.9%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)} - 1} \]
    7. Step-by-step derivation
      1. expm1-def61.7%

        \[\leadsto \color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)\right)\right)} \]
      2. expm1-log1p61.7%

        \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{\frac{t}{\ell}}\right)} \]
      3. associate-/r/61.8%

        \[\leadsto -\sin^{-1} \color{blue}{\left(\frac{{\left(\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5\right)}^{0.5}}{t} \cdot \ell\right)} \]
      4. unpow1/261.8%

        \[\leadsto -\sin^{-1} \left(\frac{\color{blue}{\sqrt{\left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right) \cdot 0.5}}}{t} \cdot \ell\right) \]
      5. *-commutative61.8%

        \[\leadsto -\sin^{-1} \left(\frac{\sqrt{\color{blue}{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}}{t} \cdot \ell\right) \]
    8. Simplified61.8%

      \[\leadsto \color{blue}{-\sin^{-1} \left(\frac{\sqrt{0.5 \cdot \left(1 - {\left(\frac{Om}{Omc}\right)}^{2}\right)}}{t} \cdot \ell\right)} \]
    9. Taylor expanded in Om around 0 61.8%

      \[\leadsto -\sin^{-1} \left(\color{blue}{\frac{\sqrt{0.5}}{t}} \cdot \ell\right) \]

    if -9.50000000000000044e-43 < t < 3.45000000000000011e95

    1. Initial program 91.6%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Taylor expanded in t around 0 64.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
    3. Step-by-step derivation
      1. unpow264.3%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}\right) \]
      2. unpow264.3%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}\right) \]
      3. times-frac74.3%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
      4. unpow274.3%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}\right) \]
    4. Simplified74.3%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}\right)} \]
    5. Taylor expanded in Om around 0 64.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}\right)} \]
    6. Step-by-step derivation
      1. unpow264.0%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}\right) \]
      2. unpow264.0%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}\right) \]
    7. Simplified64.0%

      \[\leadsto \sin^{-1} \color{blue}{\left(1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}\right)} \]
    8. Step-by-step derivation
      1. times-frac73.6%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{Om}{Omc} \cdot \frac{Om}{Omc}\right)}\right) \]
      2. clear-num73.6%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \left(\frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}\right)\right) \]
      3. div-inv73.6%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right) \]
      4. associate-/r/73.6%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}\right) \]
    9. Applied egg-rr73.6%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}\right) \]

    if 3.45000000000000011e95 < t

    1. Initial program 80.0%

      \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
    2. Step-by-step derivation
      1. sqrt-div80.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      2. div-inv80.0%

        \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right)} \]
      3. add-sqr-sqrt80.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\sqrt{1 + \color{blue}{\sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}}}\right) \]
      4. hypot-1-def80.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\color{blue}{\mathsf{hypot}\left(1, \sqrt{2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}\right)}}\right) \]
      5. *-commutative80.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{{\left(\frac{t}{\ell}\right)}^{2} \cdot 2}}\right)}\right) \]
      6. sqrt-prod80.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\sqrt{{\left(\frac{t}{\ell}\right)}^{2}} \cdot \sqrt{2}}\right)}\right) \]
      7. unpow280.0%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \sqrt{\color{blue}{\frac{t}{\ell} \cdot \frac{t}{\ell}}} \cdot \sqrt{2}\right)}\right) \]
      8. sqrt-prod39.3%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\left(\sqrt{\frac{t}{\ell}} \cdot \sqrt{\frac{t}{\ell}}\right)} \cdot \sqrt{2}\right)}\right) \]
      9. add-sqr-sqrt96.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \color{blue}{\frac{t}{\ell}} \cdot \sqrt{2}\right)}\right) \]
    3. Applied egg-rr96.4%

      \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    4. Step-by-step derivation
      1. unpow296.4%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      2. times-frac76.5%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om \cdot Om}{Omc \cdot Omc}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      3. unpow276.5%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{{Om}^{2}}}{Omc \cdot Omc}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      4. unpow276.5%

        \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{{Om}^{2}}{\color{blue}{{Omc}^{2}}}} \cdot \frac{1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      5. associate-*r/76.5%

        \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}} \cdot 1}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
      6. *-rgt-identity76.5%

        \[\leadsto \sin^{-1} \left(\frac{\color{blue}{\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      7. unpow276.5%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      8. unpow276.5%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      9. times-frac96.4%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
      10. unpow296.4%

        \[\leadsto \sin^{-1} \left(\frac{\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    5. Simplified96.4%

      \[\leadsto \sin^{-1} \color{blue}{\left(\frac{\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right)} \]
    6. Taylor expanded in Om around 0 76.5%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    7. Step-by-step derivation
      1. unpow215.3%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}\right) \]
      2. unpow215.3%

        \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}\right) \]
    8. Simplified76.5%

      \[\leadsto \sin^{-1} \left(\frac{\color{blue}{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}}{\mathsf{hypot}\left(1, \frac{t}{\ell} \cdot \sqrt{2}\right)}\right) \]
    9. Taylor expanded in t around -inf 53.2%

      \[\leadsto \sin^{-1} \color{blue}{\left(-1 \cdot \frac{\left(1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}\right) \cdot \ell}{\sqrt{2} \cdot t}\right)} \]
    10. Step-by-step derivation
      1. mul-1-neg53.2%

        \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{\left(1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}\right) \cdot \ell}{\sqrt{2} \cdot t}\right)} \]
      2. times-frac53.2%

        \[\leadsto \sin^{-1} \left(-\color{blue}{\frac{1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}}{\sqrt{2}} \cdot \frac{\ell}{t}}\right) \]
      3. unpow253.2%

        \[\leadsto \sin^{-1} \left(-\frac{1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}{\sqrt{2}} \cdot \frac{\ell}{t}\right) \]
      4. unpow253.2%

        \[\leadsto \sin^{-1} \left(-\frac{1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}{\sqrt{2}} \cdot \frac{\ell}{t}\right) \]
    11. Simplified53.2%

      \[\leadsto \sin^{-1} \color{blue}{\left(-\frac{1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}}{\sqrt{2}} \cdot \frac{\ell}{t}\right)} \]
    12. Taylor expanded in Om around 0 61.4%

      \[\leadsto \sin^{-1} \left(-\color{blue}{\frac{\ell}{\sqrt{2} \cdot t}}\right) \]
  3. Recombined 3 regimes into one program.
  4. Final simplification67.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -9.5 \cdot 10^{-43}:\\ \;\;\;\;-\sin^{-1} \left(\ell \cdot \frac{\sqrt{0.5}}{t}\right)\\ \mathbf{elif}\;t \leq 3.45 \cdot 10^{+95}:\\ \;\;\;\;\sin^{-1} \left(1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\sin^{-1} \left(\frac{-\ell}{\sqrt{2} \cdot t}\right)\\ \end{array} \]

Alternative 17: 51.6% accurate, 3.7× speedup?

\[\begin{array}{l} \\ \sin^{-1} \left(1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)\right) \end{array} \]
(FPCore (t l Om Omc)
 :precision binary64
 (asin (+ 1.0 (* -0.5 (* Om (/ (/ Om Omc) Omc))))))
double code(double t, double l, double Om, double Omc) {
	return asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))));
}
real(8) function code(t, l, om, omc)
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: omc
    code = asin((1.0d0 + ((-0.5d0) * (om * ((om / omc) / omc)))))
end function
public static double code(double t, double l, double Om, double Omc) {
	return Math.asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))));
}
def code(t, l, Om, Omc):
	return math.asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))))
function code(t, l, Om, Omc)
	return asin(Float64(1.0 + Float64(-0.5 * Float64(Om * Float64(Float64(Om / Omc) / Omc)))))
end
function tmp = code(t, l, Om, Omc)
	tmp = asin((1.0 + (-0.5 * (Om * ((Om / Omc) / Omc)))));
end
code[t_, l_, Om_, Omc_] := N[ArcSin[N[(1.0 + N[(-0.5 * N[(Om * N[(N[(Om / Omc), $MachinePrecision] / Omc), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}

\\
\sin^{-1} \left(1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)\right)
\end{array}
Derivation
  1. Initial program 82.2%

    \[\sin^{-1} \left(\sqrt{\frac{1 - {\left(\frac{Om}{Omc}\right)}^{2}}{1 + 2 \cdot {\left(\frac{t}{\ell}\right)}^{2}}}\right) \]
  2. Taylor expanded in t around 0 42.5%

    \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - \frac{{Om}^{2}}{{Omc}^{2}}}\right)} \]
  3. Step-by-step derivation
    1. unpow242.5%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}}\right) \]
    2. unpow242.5%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}}\right) \]
    3. times-frac50.0%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{\frac{Om}{Omc} \cdot \frac{Om}{Omc}}}\right) \]
    4. unpow250.0%

      \[\leadsto \sin^{-1} \left(\sqrt{1 - \color{blue}{{\left(\frac{Om}{Omc}\right)}^{2}}}\right) \]
  4. Simplified50.0%

    \[\leadsto \sin^{-1} \color{blue}{\left(\sqrt{1 - {\left(\frac{Om}{Omc}\right)}^{2}}\right)} \]
  5. Taylor expanded in Om around 0 42.4%

    \[\leadsto \sin^{-1} \color{blue}{\left(1 + -0.5 \cdot \frac{{Om}^{2}}{{Omc}^{2}}\right)} \]
  6. Step-by-step derivation
    1. unpow242.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{\color{blue}{Om \cdot Om}}{{Omc}^{2}}\right) \]
    2. unpow242.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \frac{Om \cdot Om}{\color{blue}{Omc \cdot Omc}}\right) \]
  7. Simplified42.4%

    \[\leadsto \sin^{-1} \color{blue}{\left(1 + -0.5 \cdot \frac{Om \cdot Om}{Omc \cdot Omc}\right)} \]
  8. Step-by-step derivation
    1. times-frac49.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{Om}{Omc} \cdot \frac{Om}{Omc}\right)}\right) \]
    2. clear-num49.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \left(\frac{Om}{Omc} \cdot \color{blue}{\frac{1}{\frac{Omc}{Om}}}\right)\right) \]
    3. div-inv49.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\frac{\frac{Om}{Omc}}{\frac{Omc}{Om}}}\right) \]
    4. associate-/r/49.4%

      \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}\right) \]
  9. Applied egg-rr49.4%

    \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \color{blue}{\left(\frac{\frac{Om}{Omc}}{Omc} \cdot Om\right)}\right) \]
  10. Final simplification49.4%

    \[\leadsto \sin^{-1} \left(1 + -0.5 \cdot \left(Om \cdot \frac{\frac{Om}{Omc}}{Omc}\right)\right) \]

Reproduce

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