Hello, I asked this question already on StackExchange with no answer, maybe it will be better suited here. It is well known that $\operatorname{Ext}^1_\mathbb{Z}(\mathbb{Z}/p\mathbb{Z},A) \simeq A/pA$. Is there a generalization of this formula outside PIDs? I mean $\operatorname{Ext}^1_R(R/I,M) \simeq M/IM$ for maximal or prime ideals? Does it hold for Dedekind domains? The classic proof I know for abelian groups seem to depend on principality of the ideal and I was unable to either think of different way make it work or to find an counterexample. Thanks for any input.
In general $Ext^1_R(R/I,M) \not\cong M/IM$. As an example take a finite abelian group $G$ and set $R := \mathbb{Z}G$ and let $I:= I_G = \ker(\mathbb{Z}G \to \mathbb{Z},\; g \mapsto 1)$ be the augmentation ideal. $I_G$ is a prime ideal since $\mathbb{Z}G/I_G \cong \mathbb{Z}$. Then, with trivial coefficients $$Ext_R^1(R/I,\mathbb{Z})=Ext_{ZG}^1(\mathbb{Z},\mathbb{Z})=H^1(G;\mathbb{Z})=Hom(G,\mathbb{Z})=0$$ while $\mathbb{Z}/I_G\mathbb{Z}=\mathbb{Z}$. The latter holds because $I_G$ is generated by $g1$ $(g \in G)$ and $(g1) \cdot 1 = 0$. In general, the following holds: $$Ext^1_R(R/I,M)=\dfrac{Hom_R(I,M)}{i(M)}$$ where $i: M \to Hom_R(I,M),\; m \mapsto (x \mapsto xm)$. If $I$ is finitely generated by $a_1,...,a_n$ we can choose a presentation $R^n \to I \to 0$ that induces an embedding $0 \to Hom_R(I,M) \to Hom_R(R^n,M) \cong M^n$. Thus $$Ext_R^1(R/I,M) \le \dfrac{M^n}{\lbrace (a_1m,...,a_nm) \mid m \in M \rbrace}.$$ 


Interesting question! Here is a generalization which includes the Dedekind domain case:
(when $R$ is Dedekind $R/I$ is locally a quotient of a DVR, so it is locally a hypersurface, thus Gorenstein). Proof. It is enough to prove for $M=R$ because of the following
Here's why: We have $pd_RN = n$. Let $P_{\bullet}: 0\to P_n \to \cdots \to P_0$ be a projective resolution of $N$. Then one compute the LHS by taking the cohomology at the end of $Hom(P_{\bullet},R)$ and tensor with $M$, and the RHS by taking cohomology at the end of $Hom(P_{\bullet},M)$. But tensor product is rightexact, proving that we get the same answer. Assuming we can prove for $M=R$, then apply the claim with $N=R/I$ completes the proof. Now we prove it for $M=R$. Since $R/I$ is artinian, we only need to prove it after localizing at each maximal ideal containing $I$. Thus we can assume $(R,m)$ is local. But by Local Duality $Ext^n(R/I,R)$ is isomorphic to the Matlis dual of $H^0_m(R/I) =R/I$. But since $R/I$ is Gorenstein this dual is actually isomorphic to $R/I$. QED 


Let $(R,\mathfrak m, k)$ be an arbitrary (say Noetherian) local ring of dimension at least $2$ and $M$ an arbitrary nonzero (say finitely generated) $R$module of $\mathrm {depth}_R M\geq 2$. Then $\mathrm{Ext}^1_R(R/\mathfrak m,M)=0$, but $M/\mathfrak m M\neq 0$ by Nakayama. 

