A useful way to illustrate how the three main types of rock are related to one another and how changes to rocks happen in a recurring sequence is the rock cycle. It can be presented in a diagram like the one below.
The concept of the rock cycle is attributed to James Hutton (1726—1797), the 18th-century founder of modern geology. The main idea is that rocks are continually changing from one type to another and back again, as forces inside the earth bring them closer to the surface (where they are weathered, eroded, and compacted) and forces on the earth sink them back down (where they are heated, pressed, and melted). So the elements that make up rocks are never created or destroyed — instead, they are constantly being recycled. The rock cycle helps us to see that the earth is like a giant rock recycling machine!
Explore the diagram by rolling your mouse over the names of the rock types and clicking on the images.