Differentiation to solve modified sum of binomial coefficients