$$an=(-3)^{n-1}$$
$a=-\frac{\left(-3\right)^{n}}{3n}$
$n\neq 0$
$a=-\frac{\left(-3\right)^{n}}{3n}$
$n\neq 0\text{ and }Denominator(n)\text{bmod}2=1$