Library impelmenting the (binary) MaxSum algorithm