Solution (source code)

= Solution

An <associated prime of a module> is an <annihilator> of a nonzero element. Suppose $Q=\operatorname{Ann}_R(m)$ is prime and $Q\subseteq P$. Then $m/1\ne0$ in $M_P$: a denominator $s\notin P$ killing $m$ would belong to $Q\subseteq P$. Moreover
$$
\operatorname{Ann}_{R_P}(m/1)=QR_P.
$$
Indeed, if $(a/s)(m/1)=0$, some $t\notin P$ has $tam=0$, so $ta\in Q$; primeness and $t\notin Q$ imply $a\in Q$. The reverse containment is immediate. This proves one inclusion in the <localization of associated primes> formula.

For the other, let $\mathfrak q=\operatorname{Ann}_{R_P}(m/s)$ be an <associated prime> of $M_P$ and contract it to $Q$. By part (iii), $Q$ is prime, $Q\subseteq P$ and $QR_P=\mathfrak q$. Since $s$ is invertible, $\mathfrak q$ is also the <annihilator> of $m/1$. The <Noetherian ring> hypothesis makes $Q=(a_1,\ldots,a_r)$ finitely generated. For each $a_i$, the equality $(a_im)/1=0$ supplies $t_i\notin P$ with $t_ia_im=0$. Put $t=\prod_i t_i$, taking $t=1$ for the zero <ideal>. Then $Q$ annihilates $tm$, while $tm/1\ne0$ because $t/1$ is a <unit> and $m/1\ne0$.

If $b(tm)=0$, then $b/1$ annihilates $m/1$, so $b\in Q$. Therefore $\operatorname{Ann}_R(tm)=Q$, and $Q\in\operatorname{Ass}_R(M)$. We conclude
$$
\boxed{\operatorname{Ass}_{R_P}(M_P)=\{QR_P:Q\in\operatorname{Ass}_R(M),\ Q\subseteq P\}.}
$$
The single common denominator $t$ is the key point: one must turn a localized <annihilator> into the <annihilator> of one actual nonzero element of $M$, not merely assert that <annihilators> commute with <localization>.