Grothendieck construction

The Grothendieck construction (named after Alexander Grothendieck) is a construction used in the mathematical field of category theory.
Definition.
Let formula_1 be a functor from any small category to the category of small categories. The Grothendieck construction for formula_2 is the category formula_3 (also written formula_4, formula_5 or formula_6), with
Composition of morphisms is defined by formula_16.
Slogan.
"The Grothendieck construction takes structured, tabulated data and flattens it by throwing it all into one big space. The projection functor is then tasked with remembering which box each datum originally came from." 
Example.
If formula_17 is a group, then it can be viewed as a category, formula_18 with one object and all morphisms invertible. Let formula_19 be a functor whose value at the sole object of formula_20 is the category formula_21 a category representing the group formula_22 in the same way. The requirement that formula_2 be a functor is then equivalent to specifying a group homomorphism formula_24 where formula_25 denotes the group of automorphisms of formula_26 Finally, the Grothendieck construction, formula_27 results in a category with one object, which can again be viewed as a group, and in this case, the resulting group is (isomorphic to) the semidirect product formula_28