What are rings good for? It's not a homework question or something, but I was wondering: groups are useful in physics and can be applied to many symmetry holding problems, fields can be used to construct vector spaces over the field. But what use do general rings have? Is it to construct modules?
Or more concretely, can someone give me an example of application of a ring.
Thanks in advance.
EDIT: Of course I know the trivial examples like $\mathbb{R}$, but since this is also a field it has its applications as a vector space or as a ground field for a vector space. What about $\mathbb{Z}[i]$ for example?
 A: Decomposition into prime numbers in $\mathbb{Z}$ is simply a consequence of a the fact that $\mathbb{Z}$ is an UFD.
Decomposition of a matrix into Jordan blocks is an application of structure theorem for finitely generated modules over PID.
Rings often occur as rings of functions. For example, the ring of smooth functions $M \rightarrow \mathbb{R}$ (where $M$ is a smooth manifold) can be used to define the tangent space.
The list is endless.
A: Rings are objects so you don't really 'apply' them, but if you notice something you're working with admits a ring structure then all of a sudden you know a TON about it because of all the theory that's known about rings in general.  
A good example which uses a property of the Gaussian integers mentioned by Ennar in the comments to your question is found at the beginning of Chapter 1 in Neukirch's Algebraic Number Theory (you can find the PDF online), where he proves that:
For all prime numbers $p\neq 2$, one has:
$$p=a^2+b^2\;\; \Leftrightarrow\;\; p\equiv 1\;\text{mod}\; 4 $$
for $a,b\in\mathbb{Z}$.
A: A ring is a good generalization of the integers $\mathbb Z$ (we can do addition, subtraction, multiplication but not always division), and so one of the applications is to perform some kind of arithmetic.
For example, $\mathbb R[X]$ is a ring and share a lot of "arithmetic" properties with $\mathbb Z$: we have gcd, lcm, a unique "prime" decomposition of each element (although we call that "irreductible" for polynomials) that comes from the fact that both are Euclidean rings.
Ring is also a good concept in order to study multivariable polynomials: when you're studying $\mathbb R[X, Y, Z]$ (polynomials in three variables with coefficients in the field $\mathbb R$), you can see it as $(\mathbb R[X,Y])[Z]$ (polynomials in one variable $Z$ with coefficient in the ring $\mathbb R[X, Y]$). So you have in fact to study polynomials over a ring instead of over a field (and it changes a lot of things: for instance, we can not always make Euclidean division in $\mathbb Z[X]$).
A: Rings are important for many areas, but in particular for number theory and its methods from commutative algebra and algebraic geometry. The rings of integers in number fields are used, say, for Diophantine equations, e.g., for FLT.
The quadratic number field $\mathbb{Q}(i)$ has ring of integers $\mathbb{Z}[i]$, and is one of the most basic examples, besides the trivial case of $\mathbb{Q}$ and $\mathbb{Z}$.
Furthermore, polynomial rings $K[x_1,\ldots, x_n]$ are very important, not only for algebraic geometry, but also for applications, like Gröbner bases etc.
A: The other answers have pointed out many applications of rings themselves, particularly to number theory. But by considering modules, rings can also shed a lot of light on vector spaces and on groups! They are a fantastic example of how, by making something more general (a ring is a generalisation of a field), we can gain a lot.
Let $M$ be a finitely generated module over a ring $R$ which is a PID. The structure theorem states that

There are uniquely determined ideals of $R$ $$I_1 \supset I_2\supset\cdots\supset I_n$$such that $$M\cong \bigoplus_{i=1}^nR/I_i$$

Two applications of this theorem are:


*

*Taking $R = \mathbb Z$, we obtain the structure theorem for finitely generated abelian groups

*Taking $R= \mathbb C[X]$, we obtain a neat and streamlined proof of Jordan normal form for complex matrices.

