Differentiate 2(q - 1)(q^k + 1)/(q^(k+1) + q - 1) with respect to k