def split_name(input):
    """
    Split Gekko syntax name
    Return symbol name and a list of elements
    Example:
        >>> split_name("qI[#i,CON]")
        "qI", ["#i", "'CON'"]
    """
    if "[" in input:
        name, elements = input.split("[", 1)
        elements = elements[:-1].split(",")
        elements = [e[1:] if (e[0] == "#") else f"'{e}'" for e in elements]
    else:
        name = input
        elements = []
    return name, elements