This is a numerical-answer question. The correct answer is shown below.
[Solution by Dr. Abubacker] An equivalence relation containing $R$ must link $1\sim2$, $2\sim3$ and $1\sim4$, so by symmetry and transitivity all four elements are in one class. Hence $S=A\times A$ and the minimum $n=4\times4=16$. Answer: 16.