avoid name clash with math.h

expf clashed with the expf function from math.h, and the compiler
actually used the standard library function which caused the creation
of NANs and INFs right and left.
add min parameter to vocab_shrink