@staticmethod
def translate_indexes(triangle_list, lut):
    """Translate the values of the list of 3-tuples according to the provided look-up table

        Is a generator.

        :param list triangle_list: a list of 3-tuples of integers
        :param dict lut: a dictionary mapping current to new values
        """
    for t0, t1, t2 in triangle_list:
        yield lut[t0], lut[t1], lut[t2]
