Questions about the sisl tutorial
Hello Nick,
I met some problems running the sisl tutorials.
In TB_01:
#####
for ia, io in H:
#####
You intended to enumerate atomic and orbital indices, but actually when using "for i in H:", it enumerates the indices of nonzero terms in H, for example running:
#####
graphene = sisl.geom.
H = sisl.Hamiltonia
H[0, 0] = 0.0
H[1, 1] = 0.0
H[0, 1] = -2.7
H[1, 0] = -2.7
H[0, 1, (-1, 0)] = -2.7
H[0, 1, (0, -1)] = -2.7
H[1, 0, (1, 0)] = -2.7
H[1, 0, (0, 1)] = -2.7
for ia, io in H:
print(ia,io)
###
Output is:
0 0
0 1
0 9
0 5
1 1
1 0
1 10
1 14
In TB_04 about edge atom indice:
#####
for ia in device.
if len(device.
#####
Why do you use fortran indices in the following code? When you plot the edge atom DOS later, and call tbt.DOS(atom=edge, norm='atom'), should you use python indices here?
In TB_05,
#####
dangling = [ia for ia in H.geom.
if len(H.edges(ia)) < 2]
H = H.remove(dangling)
# + 1 to get fortran indices
edge = [ia + 1 for ia in H.geom.
if len(H.edges(ia)) < 3]
#####
Should the two inequality be <3 and <4, as in TB_04? Since H.edges(ia) returns itself too.
Thank you!
Question information
- Language:
- English Edit question
- Status:
- Answered
- For:
- Siesta Edit question
- Assignee:
- No assignee Edit question
- Last query:
- Last reply:
Can you help with this problem?
Provide an answer of your own, or ask Yuefei Huang for more information if necessary.