Petrology is a section of geology which involves the study of rockss and the conditions by which they form. There are three branches of petrology, corresponding to the three types of rocks: igneous, metamorphic, and sedimentary.
Igneous petrology focuses on the genesis of rocks that crystallized from a magma.
Metamorphic petrology focusses on the changes that a rock undergoes as a result primarly of changing conditions of pressure and temperature.
Sedimentary petrology focusses on the processes by which sedimentary rocks are produced.
In modern usage, the terms petrology and geochemistry are often used interchangeably; however, petrologists (those studying petrology) tend to place a greater emphasis on petrographic (thin section) mineral and textural studies, while geochemists tend to focus on geochemical analyses of rocks and whole earth geochemical cycles.