# Connection between the annihilator and the localization of a module

I want to prove that for $M$ an $R$-module and $\mathfrak p$ a prime ideal in $R$, $$M_{\mathfrak p}\ne0\iff \operatorname{Ann}M\subseteq \mathfrak p.$$

This is equivalent to $M_{\mathfrak p}=0 \iff R\setminus \mathfrak p \not\subset R\setminus \operatorname{Ann}M$. I have a problem with implication from left to right.

What I've done:

Note that

1. $M_{\mathfrak p}=0\iff \forall m \in M$ $\exists s \in R\setminus{\mathfrak p}$ s.t. $sm=0$
2. $R\setminus \mathfrak p \not\subset R\setminus \operatorname{Ann}M \iff \exists t\in R$ s.t. $t\in (R\setminus \mathfrak p)\cap \operatorname{Ann}M$

So if $R\setminus \mathfrak p \not\subset R\setminus \operatorname{Ann}M$, then we can take $t$ from $2.$ for $s$ in $1$. But the other way round seems to be false in general at a first glance, for these $s$ in fact depend on $m$, so I cannot conclude that they are in $\operatorname{Ann}M$ ($a$ is in $\operatorname{Ann}M$ if for every $m\in M$ we have $am=0$). How do I proceed?

• Unless $M$ is finitely generated the implication "$\Leftarrow$" is wrong: consider the $\mathbb Z$-module $M=\bigoplus_{n\ge1}\mathbb Z/2^n\mathbb Z$. Then $\operatorname{Ann} M=(0)$ and $M_P=0$ for $P=3\mathbb Z$. Oct 26, 2016 at 13:17

You need to assume that $M$ is finitely generated, say generated by $m_1,\ldots,m_n$. Then you find $s_1,\ldots,s_m\in R\setminus\mathfrak{p}$ such that $s_im_i=0$ for all $1\leq i\leq n$. Let $s=s_1\cdots s_n$. Then you obviously have $sm=0$ for all $m\in M$ which means $s\in\mathrm{Ann}(M)\setminus\mathfrak{p}$. In total, this proves $$M_\mathfrak{p}=0\implies\mathrm{Ann}(M)\not\subseteq\mathfrak{p}\,.$$ In general, if $M$ is not finitely generated, this implication might be false, while the other implication is always true.