Numeric.SpecFunctions:invIncompleteBetaWorker from math-functions-0.1.5.2, B

Specification

?
\[\begin{array}{l} \\ \left(x \cdot \log y + z \cdot \log \left(1 - y\right)\right) - t \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (- (+ (* x (log y)) (* z (log (- 1.0 y)))) t))
double code(double x, double y, double z, double t) {
	return ((x * log(y)) + (z * log((1.0 - y)))) - t;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = ((x * log(y)) + (z * log((1.0d0 - y)))) - t
end function
public static double code(double x, double y, double z, double t) {
	return ((x * Math.log(y)) + (z * Math.log((1.0 - y)))) - t;
}
def code(x, y, z, t):
	return ((x * math.log(y)) + (z * math.log((1.0 - y)))) - t
function code(x, y, z, t)
	return Float64(Float64(Float64(x * log(y)) + Float64(z * log(Float64(1.0 - y)))) - t)
end
function tmp = code(x, y, z, t)
	tmp = ((x * log(y)) + (z * log((1.0 - y)))) - t;
end
code[x_, y_, z_, t_] := N[(N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + N[(z * N[Log[N[(1.0 - y), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t), $MachinePrecision]
\begin{array}{l}

\\
\left(x \cdot \log y + z \cdot \log \left(1 - y\right)\right) - t
\end{array}

Reproduce

?
herbie shell --seed 2025093 
(FPCore (x y z t)
  :name "Numeric.SpecFunctions:invIncompleteBetaWorker from math-functions-0.1.5.2, B"
  :precision binary64

  :alt
  (! :herbie-platform default (- (* (- z) (+ (+ (* 1/2 (* y y)) y) (* (/ 1/3 (* 1 (* 1 1))) (* y (* y y))))) (- t (* x (log y)))))

  (- (+ (* x (log y)) (* z (log (- 1.0 y)))) t))

Please file a bug report with this information.

Backtrace

result arity mismatch; expected number of values not received expected: 2 received: 1 in: local-binding form arguments...: '((-9.269976604710966e-10 8.982443820555286e-242 6.372096302865717e-43 -2.085438580215686e+40 2.2582441317265587e-95) . #f)LC
batch-prepare-points/home/nightlies/herbie/random-cleanup/src/core/sampling.rkt1230
prepend-argument/home/nightlies/herbie/random-cleanup/src/core/bsearch.rkt970
hash-ref!/usr/share/racket/collects/racket/private/more-scheme.rkt3772
pred/home/nightlies/herbie/random-cleanup/src/core/bsearch.rkt1404
binary-search-floats/home/nightlies/herbie/random-cleanup/src/core/bsearch.rkt690
sindices->spoints/home/nightlies/herbie/random-cleanup/src/core/bsearch.rkt1210
(unnamed)/usr/share/racket/collects/racket/contract/private/arrow-higher-order.rkt37933
f11.../match/compiler.rkt55940
make-regime!/home/nightlies/herbie/random-cleanup/src/core/mainloop.rkt2620
extract!/home/nightlies/herbie/random-cleanup/src/core/mainloop.rkt610
run-improve!/home/nightlies/herbie/random-cleanup/src/core/mainloop.rkt370
get-alternatives/home/nightlies/herbie/random-cleanup/src/api/sandbox.rkt610
(unnamed)/home/nightlies/herbie/random-cleanup/src/api/sandbox.rkt1936
(unnamed)/usr/share/racket/pkgs/profile-lib/main.rkt4010
profile-thunk/usr/share/racket/pkgs/profile-lib/main.rkt90
in-engine/home/nightlies/herbie/random-cleanup/src/api/sandbox.rkt2092
(unnamed)/usr/share/racket/collects/racket/engine.rkt4224