  A generalization of General Relativity is studied. The standard
Einstein-Hilbert action is considered in the Palatini formalism, where the
connection and the metric are independent variables, and the connection is not
symmetric. As a result of variation with respect to the metric Einstein
equations are obtained. A variation with respect to the connection leads to an
arbitrariness in the determination of connection, i.e. the presence of gauge
invariance. Then a matter in a form of point particle which interacts with
field of connection is introduced. Also the action is complemented by a kinetic
term for field of the connection to avoid incompatible equation of motion. Thus
after the variation procedures we obtain the Einstein equations, the geodesic
equation and the Maxwell`s equations for electromagnetism, where some
components of the connection play the role of the electromagnetic potential.
Thereby the electromagnetic potential is obtained from the geometry of
space-time.
