This chapter shows how Einstein has developed and described the mathematical apparatus that is necessary to formulate the physical contents of the general theory of gravity. It first discusses the transition from the special to the general relativity principle. According to Einstein's understanding of such a general relativity principle, physical laws are independent of the state of motion of the reference space in which they are described. The chapter argues that such a generalization of the relativity principle to include accelerated reference frames is possible because all inertial effects caused by acceleration can be alternatively attributed to the presence of a gravitational field. The model of a rotating disk is then used to show that general relativity implies non-Euclidean geometry and that the gravitational field is represented by curved spacetime. After the introduction of these basic concepts and principles, the chapter presents the mathematical formulation of the theory.