def get_atom_number(self, name):
    atom_numbers = {'h': 1, 'he': 2, 'li': 3, 'be': 4, 'b': 5, 'c': 6, 'n': 7, 'o': 8, 'f': 9, 'ne': 10, 'na': 11, 'mg': 12, 'al': 13, 'si': 14, 'ph': 15, 's': 16, 'cl': 17, 'ar': 18}
    if (name.lower() in atom_numbers):
        return atom_numbers[name.lower()]
    try:
        import periodictable as pt
        atom = name.lower()
        atom[0] = atom[0].upper()
        element = pt.elements.symbol(atom)
        return element.number()
    except:
        raise TequilaException('can not assign atomic number to element {}\npip install periodictable will fix it'.format(atom))
def get_atom_number(self, name):
    atom_numbers = {'h': 1, 'he': 2, 'li': 3, 'be': 4, 'b': 5, 'c': 6, 'n': 7, 'o': 8, 'f': 9, 'ne': 10, 'na': 11, 'mg': 12, 'al': 13, 'si': 14, 'ph': 15, 's': 16, 'cl': 17, 'ar': 18}
    if (name.lower() in atom_numbers):
        return atom_numbers[name.lower()]
    try:
        import periodictable as pt
        atom = name.lower()
        atom[0] = atom[0].upper()
        element = pt.elements.symbol(atom)
        return element.number()
    except:
        raise TequilaException('can not assign atomic number to element {}\npip install periodictable will fix it'.format(atom))