The crystal structure and electrical properties of K2NiF4-type (Ca2−xSmx)MnO4