A and B are input bits
(Assumption: Nothing mentioned ,so any number of inputs are possible in and gate)
Generator function G = A.B
Propagation function P = A xor B
general equation for carry is C(i+1) = G(i) + P(i)C(i)
Therefore for C(0+1) = G(0) + P(0)C(0) requires 1 AND gate
C(1+1) = G(1) + P(1)C(1)
= G(1) + P(1)[G(0) + P(0)C(0)]
= G(1) + P(1)G(0) + P(1)P(0)C(0) requires 2 AND gate
Similarly 3 AND gate for C(1+ 2)
Therefore, for 8 bit no. of and gates required = 1+2+3...+8 = 36 (Hence n*(n+1)/2)