This question is from Hungerford's Algebra.
Let $R$ be a ring with identity and $S$ the ring of all $n\times n$ matrices over $R$. $J$ is an ideal of $S$ iff $J$ is the ring of all $n\times n$ matrices over $I$ for some ideal $I$ in $R$.[Hint: Given $J$ let $I$ be the set of all those elements of $R$ that appear as the row $1-$ column $1$ entry of some matrix in $J$. Use the matrices $E_{r,s}$ where $1\le r\le n, 1\le s \le n$ and $E_{r,s} $ has $1_R$ as the row $r-$ column $s$ entry and $0$ elsewhere. Observe that for a matrix $A=(a_{ij}), E_{p,r}AE_{s,q}$ is the matrix with $a_{r,s}$ in the row $p-$ column $q$ entry and $0$ elsewhere.
Here's my attempt:
Let $I=\{x\in R \ | \ a_{11}=x \ \text{for some} \ (a_{ij})=A\in J \} $. Suppose $a,b \in I$. Then $a=a_{11}$ for some $A \in J$ and $b=b_{11}$ for some $B\in J$. Then $A-B \in J $ since $J$ is an ideal so $(A-B)_{11}=a-b\in I.$
I'm having trouble proving the other condition.
Let $r \in R$ and $a \in I$. Let $R'$ denote the matrix in $S$ that has $r$ as the row $1-$ column $1$ entry and $0$ everywhere else and $A$ denote the matrix in $J$ for which $a=a_{11}$. Then $R'A$ has $ra$ as row $1-$ column $1$ entry and it must be in $J$ since $J$ is an ideal so $ra \in I$.
Is this correct? It can't be because I haven't used the fact that $R$ has an identity. Also, where do I use the hint?
Any hints, ideas are greatly appreciated.
There are really two things to prove:
(1) Given a ideal $I \subseteq R$, the subset $M_n(I) \subseteq M_n(R)$ is also a ideal.
(2) Given a ideal $J \subseteq S = M_n(R)$, then $J = M_n(I)$ for some ideal $I \subseteq R$.
In these statements, ideal means two-sided ideal.
There is really a map $$ \begin{align} \{ \text{ideals of } R \} \quad & \overset{F}{\to} \quad \{ \text{ideals of } S \} \\ I \quad &\mapsto \quad M_n(I) = \{ (a_{ij}) \mid a_{ij} \in I \text{ for all } i,j \}. \end{align} $$ Proving (1) is equivalent to showing that this map is well-defined, while proving (2) is equivalent to showing that this map onto. You actually have to show both of these, but (1) is more-or-less a straightforward application of the definition of ideals.
For (2), you have the right idea, but it's incomplete. First of all, the inclusion $$ \{ a_{11} \mid (a_{ij}) \in J \} \hookrightarrow \{ a_{ij} \mid (a_{ij}) \in J \} $$ is actually a bijection, provided that $J$ is an ideal. With matrix units $\{E_{ij}\} \in S$ and any matrix $A = (a_{ij}) \in J$, $$ E_{1i} A E_{j1} = a_{ij}E_{11}, $$ which is a matrix of all zeroes except for the $(1, 1)$-entry, which has the value $a_{ij}$. (This is a special case of Hungerford's hint.) The consequence is that if $x$ is any entry of a matrix in $J$, then it is also specifically the $(1, 1)$-entry of a (possibly different) matrix in $J$.
You lose nothing by only looking at the corner entry! (I must emphasize that this is demonstrably false if $J$ is not a $2$-sided ideal so the matrix unit "trick" is not available.) And you gain a more elegant way to find preimages of the map $F$ above.
Now, given an ideal $J \subseteq S$, define $$ I = \{ a_{11} \mid (a_{ij}) \in J \}. $$ You must show that this is an ideal. You have correctly argued that it's closed under addition, so it's an abelian group. To show that it's closed under scalars from $R$, let $x \in I$ and $r,r' \in R$.
In order to show that $rxr' \in I$, let $(a_{ij}) \in J$ such that $x = a_{11}$. Let $(\delta_{ij})$ denote the $n \times n$ identity matrix in $S$. Then, the scalar multiple $r(\delta_{ij}) = (r\delta_{ij})$ has $(1, 1)$-entry equal to $r$, and analogously, $(r'\delta_{ij})$ has $(1, 1)$-entry $r'$. Furthermore, $$ (r a_{ij} r') = (r\delta_{ij}) (a_{ij}) (r'\delta_{ij}) \in SJS = J, $$ and so it's $(1, 1)$-entry, namely $r x r'$, is in $I$.