# Rings
## :rabbit: **Definition of Rings**
Ring is multiplication and addition applied on set satisfying the following properties.
*8 Properties*
- **Closure** If $a\in R$ and $b\in R$ then, $a+b\in R$.
- **Commutative** $a+b = b+a$
- **Associativity** $a+(b+c) = (a+b)+c$
- **Identity** $\exists O_R \in R$ s.t. $a+O_R = O_R + a= a$ where $a \in R$.
- **Solution** $\forall a \in R, a+ x = O_R$ has a solution in $R$.
- **Closure for Multiplication** If $a\in R$ and $b \in R$ then $ab \in R$.
- **Associativity for Multiplication** $(ab)c = a(bc)$.
- **Distribution** $a(b+c) = ab+ac$ and $(a+b)c = ac+bc$.
On top of these properties, if a ring satisfies ...
- **Commutative Multiplication** $ab = ba$ $\forall a,b \in R$, then we call this a **commutatitve ring**
On top of these properties, if a ring satisfies ...
- $a * I_R = a = I_R * a$, then we call this ring a **ring with identity**.
#### :panda_face: Examples
- $\mathbb{Z}$ and $\mathbb{R}$ are commutative rings with identity.
- $\mathbb{Z_n}$ is a commutative rings with identity. - - $\mathbb{Z_{2n}}$ is a ring but $\mathbb{Z_{2n+1}}$ is not.
- $\mathbb{Z_{2n}}$ is a subset of even elements. $\mathbb{Z_{2n}} = \{2,4,6,8,\cdots\}$. It satisfies all ring properties
- $\mathbb{Z_{2n+1}}$ fails the closure for addition since (odd) + (odd) = (even).
- Matrix $M(\mathbb{R})$ is a ring with identity but it is not a commutative ring since the matrix multiplication is **not** commutative.
- $(f+g)(x) = f(x)+g(x)$ and $(fg)(x) = f(x)g(x)$. Therefore, functions form a ring.
- Cartesian Product can also be a ring.
- Let R, S be a ring. Define + and * on RxS as the following:
- (r,s) + (r',s') = (r+r', s+s')
- (r,s) * (r',s') = (rr', ss')
- Then RxS forms a ring.
## :rabbit: **Definition of Integral Domain**
**Integral Ring** is a commutative ring with R with identity $I_R \neq O_R$ that satisfies the axiom "whenever $a,b \in \mathbb{R}$ and $ab=O_R$ then $a=O_R$ or $b=O_R$". In other words, integral domain is a nonzero commutative ring in which the *product of two nonzero is nozero*.
#### :panda_face: Examples
- $\mathbb{Z}_6$ is not an integral domain because $2*3 = 0$ but neither 2 nor 3 is a 0.
## :rabbit: **Definition of Field**
R is called a **field** if $\forall a \in \mathbb{R}$ $\exists x \in R$ such that $ax = 1a = xa$. Simply, $ax = 1$ and $xa =1$. In other words, if $a \neq 0$, then a **must be a unit**.
#### :panda_face: Examples
- $\mathbb{Z}_p$ where p is a prime.
- (Source:https://www.mathstat.dal.ca/~selinger/2135/handouts/handout1.pdf)
- $\mathbb{Z}_5$ is a field because every nonzero element is a unit.
- :grey_question: What is a unit? $a \in R$ is a unit if there exists $b \in R$ s.t. $ab =1$. (kind of like an inverse $aa^{-1} = 1$?)

- $\mathbb{Z}_6$ is not field.

- $\mathbb{R}$ is a field. For example, for 2, we have $1/2$, when multiplied together equals 1. Since for x that is not equal to 0, there is a $1/x$ such that $x * 1/x = 1$.
- $\mathbb{Z}$ is not a field since the only unit are -1 and 1.
:hamster: **ALL field is integeral domain. All Finite integral domain is a field.**
There is no zero divisor in the integral domain. (Zero divisor is a nonzero element in a ring x such that xy = 0.) This fact is quite obvious from the definition of integral domain. For integral domain, it should satisfy that if $xy = 0$ then either $x=0$ or $y=0$.
## :rabbit: **Definition of Subring**
If a subset of a set forms a ring, then we call this **subring**. Four conditions must be met for a subring.
Check that the subset is closed under the induced operations and that the additive inverse of an element is in the set.
:cow: **Theorem** Additive Inverse is unique! The proof is quite simple. (It is just like all other uniqueness proofs!)