Finding common difference.
Let a be the first term and d be the common difference of given A.P.
Given:
Sum of n terms Sn=nP+12(n)(n−1)Q
S1=a1=P, S2=a1+a2=2P+Q
a2=S2−S1=P+Q
Now common difference,
d=a2−a1
d=P+Q−P=Q
Hence, the common difference of given A.P. is equal to Q.