A series of Python3 script to lower the barrier of computing and simulating molecular and material systems.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

15 lines
374 B

def poscar2gen(input):
fname = input.split(".")
vx = []
vy = []
vz = []
with open(input, 'r') as f:
next(f)
next(f)
for i in range(3):
arr = next(f).split()
vx.append(arr[0])
vy.append(arr[1])
vz.append(arr[2])
elem_type = next(f).split()
elem_num = next(f).split()