(FPCore (x y z) :precision binary64 (/ (* x y) (* (* z z) (+ z 1.0))))
↓
(FPCore (x y z)
:precision binary64
(if (<= z 2.35e-209)
(/ (/ y (* (/ z x) (+ z 1.0))) z)
(if (<= z 3.85e-94) (* x (/ (/ y z) z)) (/ (* (/ y (+ z 1.0)) (/ x z)) z))))
double code(double x, double y, double z) {
double tmp;
if (z <= 2.35e-209) {
tmp = (y / ((z / x) * (z + 1.0))) / z;
} else if (z <= 3.85e-94) {
tmp = x * ((y / z) / z);
} else {
tmp = ((y / (z + 1.0)) * (x / z)) / z;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = (x * y) / ((z * z) * (z + 1.0d0))
end function
↓
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if (z <= 2.35d-209) then
tmp = (y / ((z / x) * (z + 1.0d0))) / z
else if (z <= 3.85d-94) then
tmp = x * ((y / z) / z)
else
tmp = ((y / (z + 1.0d0)) * (x / z)) / z
end if
code = tmp
end function
public static double code(double x, double y, double z) {
return (x * y) / ((z * z) * (z + 1.0));
}
↓
public static double code(double x, double y, double z) {
double tmp;
if (z <= 2.35e-209) {
tmp = (y / ((z / x) * (z + 1.0))) / z;
} else if (z <= 3.85e-94) {
tmp = x * ((y / z) / z);
} else {
tmp = ((y / (z + 1.0)) * (x / z)) / z;
}
return tmp;
}
def code(x, y, z):
return (x * y) / ((z * z) * (z + 1.0))
↓
def code(x, y, z):
tmp = 0
if z <= 2.35e-209:
tmp = (y / ((z / x) * (z + 1.0))) / z
elif z <= 3.85e-94:
tmp = x * ((y / z) / z)
else:
tmp = ((y / (z + 1.0)) * (x / z)) / z
return tmp
function code(x, y, z)
return Float64(Float64(x * y) / Float64(Float64(z * z) * Float64(z + 1.0)))
end
↓
function code(x, y, z)
tmp = 0.0
if (z <= 2.35e-209)
tmp = Float64(Float64(y / Float64(Float64(z / x) * Float64(z + 1.0))) / z);
elseif (z <= 3.85e-94)
tmp = Float64(x * Float64(Float64(y / z) / z));
else
tmp = Float64(Float64(Float64(y / Float64(z + 1.0)) * Float64(x / z)) / z);
end
return tmp
end
function tmp = code(x, y, z)
tmp = (x * y) / ((z * z) * (z + 1.0));
end
↓
function tmp_2 = code(x, y, z)
tmp = 0.0;
if (z <= 2.35e-209)
tmp = (y / ((z / x) * (z + 1.0))) / z;
elseif (z <= 3.85e-94)
tmp = x * ((y / z) / z);
else
tmp = ((y / (z + 1.0)) * (x / z)) / z;
end
tmp_2 = tmp;
end
herbie shell --seed 2023121
(FPCore (x y z)
:name "Statistics.Distribution.Beta:$cvariance from math-functions-0.1.5.2"
:precision binary64
:herbie-target
(if (< z 249.6182814532307) (/ (* y (/ x z)) (+ z (* z z))) (/ (* (/ (/ y z) (+ 1.0 z)) x) z))
(/ (* x y) (* (* z z) (+ z 1.0))))