# Slab rotation with ASE, unexpected behaviour [closed]

I am trying to generate the $$\sqrt{3}\times\sqrt{3}R30^\circ$$ representation of a Pt111 slab, I start by generating the $$1\times1$$ using ASE:

atoms = fcc111("Pt", size=(1, 1, 5), vacuum=20, orthogonal=False)


Then I apply a matrix transformation:

transformation_matrix = [[math.sqrt(3)*math.cos(math.pi/6), math.sqrt(3)*math.sin(math.pi/6), 0], [-math.sqrt(3)*math.sin(math.pi/6), math.sqrt(3)*math.cos(math.pi/6), 0], [0, 0, 1]]


Which gives the right unit cell when done manually using np.matmul. Now I use the make_supercell functional of ASE, but it gives me a weird unit cell:

np.matmul(atoms.cell, transformation_matrix) = [[4.20477064e+00 2.42762546e+00 0.00000000e+00] [5.35035667e-16 4.85525092e+00 0.00000000e+00] [0.00000000e+00 0.00000000e+00 4.00000000e+01]]

ase.build.make_supercell(atoms, transformation_matrix) = [5.418583372710122, 2.1023853208798973, 0.0] [-0.3252401410207554, 3.6414381928509796, 0.0] [0.0, 0.0, 40.0]


And thus the structure given by ASE is wrong, is this a bug, or am I missing something?

• I gave my +1 long ago, but I wonder if you figured out the answer to this over the last 6+ months? Is this still a problem for you? Please update us! Dec 31, 2022 at 3:38