Question on a principal ideal domain Let $A$ be a principal ideal domain and $S = \{a_1,...,a_n \}$ a subset of $A$ and let $(S)$ be the ideal generated by the elements of $S$. Define
$T_S = \{t \in  A \ \vert \ \forall i =1,...,n, t \mid a_i \}$.
Show that $(S) = A \Leftrightarrow T_S \subset A^\times$, where $A^\times$ denotes the group of units.
$\Leftarrow:$ If $T_S \subset A^\times$ then for $t \in T_S$, we have that $t \in A^\times$. Thus $t$ is invertible and from the definition of $T_S$ we know that $t \vert a_i, \forall i$.
From here I don't know how to proceed.
 A: Let the ideal generated by $S$ be given by $(f)$ for some $f \in A$.
Note that $f \in T_S$ so if $T_S \subseteq A^\times$, then $f$ is a unit so $(f) = (1) = A$. Conversely, if $\langle S\rangle = (1)$, then we can write $1 = \sum_{i = 1}^n c_i a_i$ by the definition of the ideal generated by $S$.  Hence, if some $t$ divides all $a_i$, it divides every $c_i a_i$ so that $t$ divides the sum, which is 1. Hence, $t$ is a unit so $T_S \subseteq A^\times$.
A: Conceptually it can be viewed as the special coprime case of the general fact that  PIDs are gcd domains, whose ideals are generated by any gcd of their generators, since
$$\begin{align}
\overbrace{(a_1,\,\ldots,\,a_n)}^{\large (a_1)\,+\cdots +\, (a_n)} &\,=\, D,\ \ \ \text{wich means, by def'n of ideal sum, that}\\[.2em]
\iff\ \ \ C\supseteq (a_1),..,(a_n) &\iff \, C\,\supseteq\,  D,\ \ \ \text{for all ideals $\,C\subseteq A$}\\[.2em]
\iff\ \ \ (c) \!\supseteq \!(a_1),..,(a_n) &\iff (c)\supseteq  (d)\ \ \ \text{by $A$ is a PID} \\[.2em]
\iff\ \ \ \ \  c\ \ \mid\ \ a_1,\ldots,a_n\,\ &\iff\ \  c\ \ \mid\ \   d,\,\  \ \ \text{by contains = divides in a PID}\\[.2em]
\iff\ \ \ \ \ \ \  \gcd(a_1,\cdots, a_n)\! &\ \ \sim\ d,\ \ \ \text{where $\,\sim\,$ means associate}
\end{align}\qquad$$
where the final $\!\iff\!$ uses the gcd universal property, and the first is the universal property of the ideal sum $\,C\supseteq A_1+A_2\!\!\iff\! C\supseteq A_1,A_2,\, $ where $(a_1,\ldots,a_n) = (a_1)+\cdots (a_n)\,$ by definition.
As is often the case, the proof is straightforward - practically writing itself - when we employ the basic  universal properties that define the objects.
For motivation see here for the case when the PID $=\Bbb Z$.
