I want to determine if a function
f[x] can take negative values.
f is expensive to compute and
x may be high-dimensional.
I thought to use
FindMinimum to minimize with respect to
x. If the minimum is positive I have an answer.
But I do not want to proceed with the costly minimization if, en route, an evaluation of
f produces a negative value.
I want to return to the calling program with the information:
fcan achieve a negative value.
How could I do this?