TITLE: A subring may have a different identity,why?
QUESTION [5 upvotes]: Let $R$ be a ring with unity $1_R$. Suppose $S$ is a subring but it does not contain $1_R$. But still it may contain a subring unity $1_S$. For example $R=M_2(\mathbb R)$ and $S$ be the set of all matrices with first entry in $\mathbb R$ and the rest three $0$. Then the element with first entry $1$ and rest three zero is identity of $S$. Why is this happening?It seems a bit weird to me. We can also take the example of $\mathbb Z_6$ and its subring $\{0,3\}$.
I have searched for the answer to this question in stack exchange but the answers, although they have no problem, is out of my scope of understanding as I am a beginner of Ring theory.

REPLY [5 votes]: I really like Arturo Magidin's excellent answer, but I think there is another interesting perspective on what's going on here.
Idempotents
What's the relevant key difference between say groups and monoids, or groups and rings, or  integral domains and rings, that explains why the first has no "nontrivial" "unitless subobjects" which have an identity different from the large object identity? I'm using "unitless subobject" to mean 
a nonempty subset closed under all operations except multiplicative identity. I'll explain what I mean by nontrivial later.
From my perspective, the answer is existence of "nontrivial" idempotents.
So what's an idempotent?

An idempotent element $e$ is an element such that $e^2=e$. 

Example: In any monoid or ring or group, $1^2=1$, so the identity is an idempotent. In a ring $0^2=0$ is also an idempotent. These are the "trivial" idempotents, in the sense that these idempotents are forced to exist by the axioms of the object in question. 
So why are idempotents relevant?
Well, if $S\subseteq R$ is a subring of a ring $R$ with a different unit $1_S\ne 1_R$, then $1_S^2=1_S$, so $1_S$ is an idempotent in $R$. Similarly for $N\subseteq M$ a subsemigroup of a monoid or group which has its own identity $1_N\ne 1_M$, we must have $1_N^2=1_N$. 
Conversely, if $e\in R$ is an idempotent, you can check that 
$eRe = \{ere : r\in R\}$ is a subring of $R$ with unit $e$. 
(Similarly, in the monoid case, if $e$ is an idempotent, then $eMe$ is a subsemigroup with unit $e$).
Note that if $S$ has identity $1_S$, then for all $s\in S$, $1_Ss1_S=s\in 1_SR1_S$, so for any idempotent $e$, $eRe$ is essentially the largest subring on which the idempotent $e$ behaves like a unit element. (Same for monoids)
In the case of the trivial idempotents, we get the subrings $1R1=R$ and $0R0=0$. 
If there are no nontrivial idempotents, then the object can't have any interesting "unitless subobjects" which have units different than the unit of the whole object.
In the case of groups, the equation $e^2=e$ implies $e=1$, since $e$ is invertible, 
and for rings $e^2=e$ implies $e(e-1)=0$, which if $R$ is an integral domain implies $e=0$ or $e=1$.
In your particular example, $1_S = \begin{pmatrix} 1 & 0 \\ 0 & 0\end{pmatrix}$ and $S=1_SR1_S$, so this is an example of the general pattern.
Rings, idempotents, and projections
For rings we actually have more interesting behaviour. A common source of idempotents is the following situation:
Perhaps our ring $R$ is the product of two rings $S$ and $T$, so $R=S\times T$.
The identity of $R$ is $(1,1)$, and we have two idempotents, the identity of $S$, 
$(1,0)$, and the identity of $T$, $(0,1)$, and $S=(1,0)R(1,0)$ and $T=(0,1)R(0,1)$.
We might ask, when is the converse true? I.e., if $e$ is an idempotent of $R$, when 
does $e$ arise as the image of $(1,0)$ under some isomorphism $R\cong S\times T$ for some 
rings $S$ and $T$.
Well, first notice that there are two necessary conditions, $e$ is central, since $(1,0)$ would be in $S\times T$, and that $1-e$ is also a central idempotent.
You can check that $1-e$ is always an idempotent, and if $e$ is central, then so is $1-e$. 
In fact this is sufficient as well.

If $e$ is a central idempotent, then $R\cong (Re)\times (R(1-e))$, via the map 
  $r\mapsto (re,r-re)$, which has inverse $(ae,b(1-e))\mapsto ae+b(1-e)$.

Proof sketch/notes:
Checking that these maps are inverse bijections is straightforward and doesn't use centrality. Additivity of $r\mapsto (re,r-re)$ also doesn't require centrality of $e$, so in general we always get a decomposition of $R$ as the direct sum of left $R$-ideals $Re\oplus R(1-e)$, which can be useful. However, when $e$ is central, then 
$$(re,r(1-e))(se,s(1-e)) = (rese,r(1-e)s(1-e)) = (rsee,rs(1-e)(1-e))=(rse,rs(1-e)),$$
which is what's required to show that the homomorphism $R\to Re\times R(1-e)$ is multiplicative.