Add vecmin and vecmax functions