Exploration of R2XM2 (R=Sc, Y, Ti, Zr, Hf, rare earth; X=main group element; M=transition metal, Si, Ge): structural motifs, the novel compound Gd2AlGe2 and analysis of the U3Si2 and Zr3Al2 structure types