added failing NaN test for fmin
fixed agrad/rev/fmin so gradients return NaN when input is NaN