SUM OF 'N' TERMS IN ARITHEMETIC PROGRESSION

a=first term in Arithemetic Progression

n= number of terms in A.P

d= common difference between the terms

a = 1 (slider from -5 to 15, step 1)
n = 20 (slider from 1 to 20, step 1)
d = 1 (slider from -5 to 5, step 1)
A: n / 2
B: (2 * a)
C: n - 1
D: (C * d)
E: B + D
F: (A * E)
text1: "Sn=n/2(2a+(n-1)d)
    =" + n + "(2*" + a + "+(" + n + "-1)" + d + ")
   =" + A + "(" + B + "+(" + C + ")" + d + ")
   =" + A + "(" + B + "+(" + D + "))
  =" + A + "(" + E + ")
  =" + F + ""