Added functions to compute combinations