Given series is is written as
$S_n=3+7+13+21+31+.................+t_n+0$..........(i)
$S_n=0+3+7+13+21+31+.................+t_n$.........(ii)
Subtracting (i) - (ii) we get
$0=3+(4+6+8+10+............(n-1)\: terms)-t_n$
$\Rightarrow\:t_n=3+(4+6+8+10+.........(n-1)\:terms)$
$4+6+8+..........(n-1) \:terms$ is an A.P.
with $1^{st}$ term $=a=4$ common difference $=d=2$ and no. of terms $=n-1$
We know that sum of $n-1$ terms of an A.P. $=\large\frac{n-1}{2}$$[2a+(n-2)d]$
$\therefore 4+6+8+......=\large\frac{n-1}{2}$$\big [2\times 4+(n-1-1)2\big]$
$\qquad\:=\large \frac{n-1}{2}$$[8+(n-2)2]=(n-1)(2+n)=n^2+n-2$
Substituting this value in $t_n$ we get
$\Rightarrow\:t_n=3+(n^2+n-2)$
$i.e.,$ $t_n=n^2+n+1$
Step 2
Now for any series Sum of $n$ terms $=S_n=\sum t_n$
$\Rightarrow\:S_n=\sum (n^2+n+1)$
$\qquad =\sum n^2+\sum n+\sum 1$
$\qquad \:=\large\frac{n(n+1)(2n+1)}{6}+\frac{n(n+1)}{2}+$$n$
$\qquad\:=n\bigg[\large\frac{(n+1)(2n+1)}{6}+\large\frac{n+1}{2}+$$1\bigg]$
$\Rightarrow\:S_n=\large\frac{n}{6}$$\big[2n^2+3n+1+3n+3+6\big]$.
$\Rightarrow\:S_n=\large\frac{n}{6}$$\big[2n^2+6n+10\big]=\large\frac{n}{3}$$\big[n^2+3n+5\big]$