minimal sum