Three-Dimensional Homogeneous Spaces and their Application in General Relativity