Abstract algebra studies algebraic structures like groups, ring, fields and algebras.

A **group** $(X,\cdot)$ is a set with a binary operation that satisfies:

- Closure: $\forall a,b \in X, a\cdot b \in X$
- Associativity: $\forall a,b,c \in X, (a \cdot b) \cdot c = a \cdot (b \cdot c)$
- Identity element: $\exists e \in X, \forall a \in X, e \cdot a = a \cdot e = a$
- Inverse element: $\forall a \in X, \exists b \in X, b \cdot a = a \cdot b = e$

Basic properties:

- The additive identity and the additive inverse of each element are unique.

Examples of groups:

- Integers $(\mathbb{Z},+)$, where the identity element is 0 and the inverse element of $a$ is $-a$.
- Dihedral groups have underlying sets consisting of symmetries like rotations and flections, and composition as group operation.

An algebraic structure satisfying:

- condition 1 is a
**groupoid**. - conditions 1-2 is a
**semigroup**. - conditions 1-3 is a
**monoid**.

Group operation need not be commutative.
A group with commutative operation is call an **abelian group**.

A **ring** $(X,+,\cdot)$ is a set with two binary operations called addition and multiplication, such that:

- $(X,+)$ is an abelian group with identity element (denoted by) 0.
- $(X,\cdot)$ is a monoid with identity element (denoted by) 1.
- Multiplication left and right distributes over addition:
- $a \cdot (b + c) = (a \cdot b) + (a \cdot c)$
- $(a + b) \cdot c = (a \cdot c) + (b \cdot c)$

Basic properties:

- Multiplication by 0 annihilates $X$: $0 \cdot a = a \cdot 0 = 0$
- $-1 \cdot a = -a$
- If $0 = 1$ in a ring, then the ring has only one element.

Examples of rings:

- Integers $(\mathbb{Z},+,\cdot)$, where the additive identity element is 0, the additive inverse element of $a$ is $-a$, and the multiplicative identity element is 1.
- Modular arithmetic $\mathbb{Z}/n\mathbb{Z}$
- $\mathcal{M}_n(R)$, where the underlying set is all n-by-n matrices over an arbitrary ring $R$, with matrix addition and matrix multiplication as corresponding operations. It is a special case of matrix ring.
- Polynomial ring over $R$, $R[t]$, consists of the set of polynomials in one or more variables $t$ with coefficients in another ring $R$, often a field.

Ring multiplication is not required to be commutative. Rings that also satisfy commutativity for multiplication are called commutative rings.

A semiring is a similar algebraic structure to a ring, without additive inverse elements.

A **field** $(X,+,\cdot)$ is a set with two binary operations called addition and multiplication, such that:

- $(X,+)$ is an abelian group with identity element (denoted by) 0.
- $(X \smallsetminus {0},\cdot)$ is an abelian group with identity element (denoted by) 1.
- Multiplication left and right distributes over addition.

Note:

- A field is equivalent to a commutative ring, with multiplicative inverses for every element except the additive identity element 0.
- Subtraction and division are defined implicitly in terms of the inverse operations of addition and multiplication.

Examples of fields:

- Rational numbers $(\mathbb{Q},+,\cdot)$
- Finite field with four elements.