add option to restrict the number of minima in the database

the option is added to addMinimum() and minimum_adder()