# This can probably be extracted from:
# https://pypi.python.org/pypi/mendeleev/0.2.8#downloads

ptable = {
    1: {"Group": 1, "Name": "Hydrogen", "Period": 1, "Symbol": "H"},
    2: {"Group": 18, "Name": "Helium", "Period": 1, "Symbol": "He"},
    3: {"Group": 1, "Name": "Lithium", "Period": 2, "Symbol": "Li"},
    4: {"Group": 2, "Name": "Beryllium", "Period": 2, "Symbol": "Be"},
    5: {"Group": 13, "Name": "Boron", "Period": 2, "Symbol": "B"},
    6: {"Group": 14, "Name": "Carbon", "Period": 2, "Symbol": "C"},
    7: {"Group": 15, "Name": "Nitrogen", "Period": 2, "Symbol": "N"},
    8: {"Group": 16, "Name": "Oxygen", "Period": 2, "Symbol": "O"},
    9: {"Group": 17, "Name": "Fluorine", "Period": 2, "Symbol": "F"},
    10: {"Group": 18, "Name": "Neon", "Period": 2, "Symbol": "Ne"},
    11: {"Group": 1, "Name": "Sodium", "Period": 3, "Symbol": "Na"},
    12: {"Group": 2, "Name": "Magnesium", "Period": 3, "Symbol": "Mg"},
    13: {"Group": 13, "Name": "Aluminum", "Period": 3, "Symbol": "Al"},
    14: {"Group": 14, "Name": "Silicon", "Period": 3, "Symbol": "Si"},
    15: {"Group": 15, "Name": "Phosphorus", "Period": 3, "Symbol": "P"},
    16: {"Group": 16, "Name": "Sulfur", "Period": 3, "Symbol": "S"},
    17: {"Group": 17, "Name": "Chlorine", "Period": 3, "Symbol": "Cl"},
    18: {"Group": 18, "Name": "Argon", "Period": 3, "Symbol": "Ar"},
    19: {"Group": 1, "Name": "Potassium", "Period": 4, "Symbol": "K"},
    20: {"Group": 2, "Name": "Calcium", "Period": 4, "Symbol": "Ca"},
    21: {"Group": 3, "Name": "Scandium", "Period": 4, "Symbol": "Sc"},
    22: {"Group": 4, "Name": "Titanium", "Period": 4, "Symbol": "Ti"},
    23: {"Group": 5, "Name": "Vanadium", "Period": 4, "Symbol": "V"},
    24: {"Group": 6, "Name": "Chromium", "Period": 4, "Symbol": "Cr"},
    25: {"Group": 7, "Name": "Manganese", "Period": 4, "Symbol": "Mn"},
    26: {"Group": 8, "Name": "Iron", "Period": 4, "Symbol": "Fe"},
    27: {"Group": 9, "Name": "Cobalt", "Period": 4, "Symbol": "Co"},
    28: {"Group": 10, "Name": "Nickel", "Period": 4, "Symbol": "Ni"},
    29: {"Group": 11, "Name": "Copper", "Period": 4, "Symbol": "Cu"},
    30: {"Group": 12, "Name": "Zinc", "Period": 4, "Symbol": "Zn"},
    31: {"Group": 13, "Name": "Gallium", "Period": 4, "Symbol": "Ga"},
    32: {"Group": 14, "Name": "Germanium", "Period": 4, "Symbol": "Ge"},
    33: {"Group": 15, "Name": "Arsenic", "Period": 4, "Symbol": "As"},
    34: {"Group": 16, "Name": "Selenium", "Period": 4, "Symbol": "Se"},
    35: {"Group": 17, "Name": "Bromine", "Period": 4, "Symbol": "Br"},
    36: {"Group": 18, "Name": "Krypton", "Period": 4, "Symbol": "Kr"},
    37: {"Group": 1, "Name": "Rubidium", "Period": 5, "Symbol": "Rb"},
    38: {"Group": 2, "Name": "Strontium", "Period": 5, "Symbol": "Sr"},
    39: {"Group": 3, "Name": "Yttrium", "Period": 5, "Symbol": "Y"},
    40: {"Group": 4, "Name": "Zirconium", "Period": 5, "Symbol": "Zr"},
    41: {"Group": 5, "Name": "Niobium", "Period": 5, "Symbol": "Nb"},
    42: {"Group": 6, "Name": "Molybdenum", "Period": 5, "Symbol": "Mo"},
    43: {"Group": 7, "Name": "Technetium", "Period": 5, "Symbol": "Tc"},
    44: {"Group": 8, "Name": "Ruthenium", "Period": 5, "Symbol": "Ru"},
    45: {"Group": 9, "Name": "Rhodium", "Period": 5, "Symbol": "Rh"},
    46: {"Group": 10, "Name": "Palladium", "Period": 5, "Symbol": "Pd"},
    47: {"Group": 11, "Name": "Silver", "Period": 5, "Symbol": "Ag"},
    48: {"Group": 12, "Name": "Cadmium", "Period": 5, "Symbol": "Cd"},
    49: {"Group": 13, "Name": "Indium", "Period": 5, "Symbol": "In"},
    50: {"Group": 14, "Name": "Tin", "Period": 5, "Symbol": "Sn"},
    51: {"Group": 15, "Name": "Antimony", "Period": 5, "Symbol": "Sb"},
    52: {"Group": 16, "Name": "Tellurium", "Period": 5, "Symbol": "Te"},
    53: {"Group": 17, "Name": "Iodine", "Period": 5, "Symbol": "I"},
    54: {"Group": 18, "Name": "Xenon", "Period": 5, "Symbol": "Xe"},
    55: {"Group": 1, "Name": "Cesium", "Period": 6, "Symbol": "Cs"},
    56: {"Group": 2, "Name": "Barium", "Period": 6, "Symbol": "Ba"},
    57: {"Group": None, "Name": "Lanthanum", "Period": 6, "Symbol": "La"},
    58: {"Group": None, "Name": "Cerium", "Period": 6, "Symbol": "Ce"},
    59: {"Group": None, "Name": "Praseodymium", "Period": 6, "Symbol": "Pr"},
    60: {"Group": None, "Name": "Neodymium", "Period": 6, "Symbol": "Nd"},
    61: {"Group": None, "Name": "Promethium", "Period": 6, "Symbol": "Pm"},
    62: {"Group": None, "Name": "Samarium", "Period": 6, "Symbol": "Sm"},
    63: {"Group": None, "Name": "Europium", "Period": 6, "Symbol": "Eu"},
    64: {"Group": None, "Name": "Gadolinium", "Period": 6, "Symbol": "Gd"},
    65: {"Group": None, "Name": "Terbium", "Period": 6, "Symbol": "Tb"},
    66: {"Group": None, "Name": "Dysprosium", "Period": 6, "Symbol": "Dy"},
    67: {"Group": None, "Name": "Holmium", "Period": 6, "Symbol": "Ho"},
    68: {"Group": None, "Name": "Erbium", "Period": 6, "Symbol": "Er"},
    69: {"Group": None, "Name": "Thulium", "Period": 6, "Symbol": "Tm"},
    70: {"Group": None, "Name": "Ytterbium", "Period": 6, "Symbol": "Yb"},
    71: {"Group": 3, "Name": "Lutetium", "Period": 6, "Symbol": "Lu"},
    72: {"Group": 4, "Name": "Hafnium", "Period": 6, "Symbol": "Hf"},
    73: {"Group": 5, "Name": "Tantalum", "Period": 6, "Symbol": "Ta"},
    74: {"Group": 6, "Name": "Tungsten", "Period": 6, "Symbol": "W"},
    75: {"Group": 7, "Name": "Rhenium", "Period": 6, "Symbol": "Re"},
    76: {"Group": 8, "Name": "Osmium", "Period": 6, "Symbol": "Os"},
    77: {"Group": 9, "Name": "Iridium", "Period": 6, "Symbol": "Ir"},
    78: {"Group": 10, "Name": "Platinum", "Period": 6, "Symbol": "Pt"},
    79: {"Group": 11, "Name": "Gold", "Period": 6, "Symbol": "Au"},
    80: {"Group": 12, "Name": "Mercury", "Period": 6, "Symbol": "Hg"},
    81: {"Group": 13, "Name": "Thallium", "Period": 6, "Symbol": "Tl"},
    82: {"Group": 14, "Name": "Lead", "Period": 6, "Symbol": "Pb"},
    83: {"Group": 15, "Name": "Bismuth", "Period": 6, "Symbol": "Bi"},
    84: {"Group": 16, "Name": "Polonium", "Period": 6, "Symbol": "Po"},
    85: {"Group": 17, "Name": "Astatine", "Period": 6, "Symbol": "At"},
    86: {"Group": 18, "Name": "Radon", "Period": 6, "Symbol": "Rn"},
    87: {"Group": 1, "Name": "Francium", "Period": 7, "Symbol": "Fr"},
    88: {"Group": 2, "Name": "Radium", "Period": 7, "Symbol": "Ra"},
    89: {"Group": None, "Name": "Actinium", "Period": 7, "Symbol": "Ac"},
    90: {"Group": None, "Name": "Thorium", "Period": 7, "Symbol": "Th"},
    91: {"Group": None, "Name": "Protactinium", "Period": 7, "Symbol": "Pa"},
    92: {"Group": None, "Name": "Uranium", "Period": 7, "Symbol": "U"},
    93: {"Group": None, "Name": "Neptunium", "Period": 7, "Symbol": "Np"},
    94: {"Group": None, "Name": "Plutonium", "Period": 7, "Symbol": "Pu"},
    95: {"Group": None, "Name": "Americium", "Period": 7, "Symbol": "Am"},
    96: {"Group": None, "Name": "Curium", "Period": 7, "Symbol": "Cm"},
    97: {"Group": None, "Name": "Berkelium", "Period": 7, "Symbol": "Bk"},
    98: {"Group": None, "Name": "Californium", "Period": 7, "Symbol": "Cf"},
    99: {"Group": None, "Name": "Einsteinium", "Period": 7, "Symbol": "Es"},
    100: {"Group": None, "Name": "Fermium", "Period": 7, "Symbol": "Fm"},
    101: {"Group": None, "Name": "Mendelevium", "Period": 7, "Symbol": "Md"},
    102: {"Group": None, "Name": "Nobelium", "Period": 7, "Symbol": "No"},
    103: {"Group": 3, "Name": "Lawrencium", "Period": 7, "Symbol": "Lr"},
    104: {"Group": 4, "Name": "Rutherfordium", "Period": 7, "Symbol": "Rf"},
    105: {"Group": 5, "Name": "Dubnium", "Period": 7, "Symbol": "Db"},
    106: {"Group": 6, "Name": "Seaborgium", "Period": 7, "Symbol": "Sg"},
    107: {"Group": 7, "Name": "Bohrium", "Period": 7, "Symbol": "Bh"},
    108: {"Group": 8, "Name": "Hassium", "Period": 7, "Symbol": "Hs"},
    109: {"Group": 9, "Name": "Meitnerium", "Period": 7, "Symbol": "Mt"},
    110: {"Group": 10, "Name": "Darmstadtium", "Period": 7, "Symbol": "Ds"},
    111: {"Group": 11, "Name": "Roentgenium", "Period": 7, "Symbol": "Rg"},
    112: {"Group": 12, "Name": "Copernicium", "Period": 7, "Symbol": "Cn"},
    113: {"Group": 13, "Name": "Nihonium", "Period": 7, "Symbol": "Nh"},
    114: {"Group": 14, "Name": "Flerovium", "Period": 7, "Symbol": "Fl"},
    115: {"Group": 15, "Name": "Moscovium", "Period": 7, "Symbol": "Mc"},
    116: {"Group": 16, "Name": "Livermorium", "Period": 7, "Symbol": "Lv"},
    117: {"Group": 17, "Name": "Tennessine", "Period": 7, "Symbol": "Ts"},
    118: {"Group": 18, "Name": "Oganesson", "Period": 7, "Symbol": "Og"},
}

symboltoint = {
    "R": 0,
    "Ac": 89,
    "Ag": 47,
    "Al": 13,
    "Am": 95,
    "Ar": 18,
    "As": 33,
    "At": 85,
    "Au": 79,
    "B": 5,
    "Ba": 56,
    "Be": 4,
    "Bh": 107,
    "Bi": 83,
    "Bk": 97,
    "Br": 35,
    "C": 6,
    "Ca": 20,
    "Cd": 48,
    "Ce": 58,
    "Cf": 98,
    "Cl": 17,
    "Cm": 96,
    "Cn": 112,
    "Co": 27,
    "Cr": 24,
    "Cs": 55,
    "Cu": 29,
    "Db": 105,
    "Ds": 110,
    "Dy": 66,
    "Er": 68,
    "Es": 99,
    "Eu": 63,
    "F": 9,
    "Fe": 26,
    "Fl": 114,
    "Fm": 100,
    "Fr": 87,
    "Ga": 31,
    "Gd": 64,
    "Ge": 32,
    "H": 1,
    "He": 2,
    "Hf": 72,
    "Hg": 80,
    "Ho": 67,
    "Hs": 108,
    "I": 53,
    "In": 49,
    "Ir": 77,
    "K": 19,
    "Kr": 36,
    "La": 57,
    "Li": 3,
    "Lr": 103,
    "Lu": 71,
    "Lv": 116,
    "Mc": 115,
    "Md": 101,
    "Mg": 12,
    "Mn": 25,
    "Mo": 42,
    "Mt": 109,
    "N": 7,
    "Na": 11,
    "Nb": 41,
    "Nd": 60,
    "Ne": 10,
    "Nh": 113,
    "Ni": 28,
    "No": 102,
    "Np": 93,
    "O": 8,
    "Og": 118,
    "Os": 76,
    "P": 15,
    "Pa": 91,
    "Pb": 82,
    "Pd": 46,
    "Pm": 61,
    "Po": 84,
    "Pr": 59,
    "Pt": 78,
    "Pu": 94,
    "Ra": 88,
    "Rb": 37,
    "Re": 75,
    "Rf": 104,
    "Rg": 111,
    "Rh": 45,
    "Rn": 86,
    "Ru": 44,
    "S": 16,
    "Sb": 51,
    "Sc": 21,
    "Se": 34,
    "Sg": 106,
    "Si": 14,
    "Sm": 62,
    "Sn": 50,
    "Sr": 38,
    "Ta": 73,
    "Tb": 65,
    "Tc": 43,
    "Te": 52,
    "Th": 90,
    "Ti": 22,
    "Tl": 81,
    "Tm": 69,
    "Ts": 117,
    "U": 92,
    "V": 23,
    "W": 74,
    "Xe": 54,
    "Y": 39,
    "Yb": 70,
    "Zn": 30,
    "Zr": 40,
}
