We define the gravitation action as an integral over the four-dimensional
space of the total curvature density. Integrating by parts, we obtain the Lagrangian
density as a function of the Christoffel symbols. From a variation of this Lagrangian
density with the metric elements, we obtain the Einstein law of gravitation for
vacuum. We define the matter action as an integral over the four-dimensional space
of the mass scalar density. With the momentum four-vector, we obtain a Lagrangian
density variation with the metric elements and the time-space coordinates. From the
total variation of the matter action in a gravitational field, we obtain the Einstein law
of gravitation in matter, and the geodesic equations. According to the Maxwell
equations, we obtain the electric and magnetic fields as an electromagnetic tensor. We
define the electromagnetic action as an integral over the four-dimensional space of
the amplitude scalar of this tensor, and obtain a variation of this action with metric
elements and the electromagnetic potentials. At the same time, we consider the
electric charge action as the scalar product of the charge flux four-vector with the
electromagnetic potential four-vector, and obtain its variation with electromagnetic
potentials and the time-space coordinates. We obtain a matter-field action variation
with three terms: for the variations of the metric elements, of the time-space
coordinates, and of the electromagnetic potentials. From the first term, we obtain the
matter dynamics in a gravitational-electromagnetic field; from the second term, we
obtain the Lorentz force in a gravitational field, and from the third term, the Maxwell
equations in the gravitational field.
Keywords: Action, Curvature tensor, Ricci tensor, Christoffel symbol, Metric tensor, Lagrangian density, Variation, Fundamental equation, Covariant acceleration, Geodesic equation, Maxwell equations, Momentum four-vector, Electric field, Magnetic field, Electromagnetic potential, Electric potential, Pseudoenergy tensor, Vector potential, Electromagnetic field tensor, Charge density, Current density, Scalar density, Electromagnetic energy density, Poynting vector, Strength energy tensor.