Beispiel #1
0
 def parser(self, ):
     s = System()
     s.name = self.name
     s.methods = self.__parse_keyword()
     s.spin = self.spin
     s.charge = self.charge
     for i in self.redundant:
         s.redundant.append(i.strip().split())
     for i in self.atoms:
         a = Atom()
         a.name = ELEMENT[int(i[1])]
         a.x[0] = float(i[3])
         a.x[1] = float(i[4])
         a.x[2] = float(i[5])
         s.atoms.append(a)
     return s
Beispiel #2
0
 def parser(self,):
     s = System()
     s.name = self.name
     s.methods = self.__parse_keyword()
     s.spin = self.spin
     s.charge = self.charge
     for i in self.redundant:
         s.redundant.append(i.strip().split())
     for i in self.atoms:
         a = Atom()
         a.name = ELEMENT[int(i[1])]
         a.x[0] = float(i[3])
         a.x[1] = float(i[4])
         a.x[2] = float(i[5])
         s.atoms.append(a)
     return s
Beispiel #3
0
 def parser(self, ):
     s = System()
     s.options = self.options
     s.methods = self.methods
     for i in self.redundant:
         s.redundant.append(i.strip().split())
     s.connect = self.connect
     s.spin = self.spin
     s.charge = self.charge
     s.name = self.title.strip()
     for i in self.atoms:
         a = Atom()
         a.name = i[0]
         a.x[0] = float(i[1])
         a.x[1] = float(i[2])
         a.x[2] = float(i[3])
         s.atoms.append(a)
     return s
Beispiel #4
0
 def parser(self,):
     s = System()
     s.options = self.options
     s.methods = self.methods
     for i in self.redundant:
         s.redundant.append(i.strip().split())
     s.connect = self.connect
     s.spin = self.spin
     s.charge = self.charge
     s.name = self.title.strip()
     for i in self.atoms:
         a = Atom()
         a.name = i[0]
         a.x[0] = float(i[1])
         a.x[1] = float(i[2])
         a.x[2] = float(i[3])
         s.atoms.append(a)
     return s