'Convert the formula into A1 notation.
The formula is converted into A1 assuming it is assigned to the cell
whose address is `dest` (no worksheet name).'

def translate_formula(self, dest):

    tokens = self.get_tokens()
    if (not tokens):
        return ''
    elif (tokens[0].type == Token.LITERAL):
        return tokens[0].value
    out = ['=']
    (dcol, drow) = coordinate_from_string(dest)
    dcol = column_index_from_string(dcol)
    row_delta = (drow - self.row)
    col_delta = (dcol - self.col)
    for token in tokens:
        if ((token.type == Token.OPERAND) and (token.subtype == Token.RANGE)):
            out.append(self.translate_range(token.value, row_delta, col_delta))
        else:
            out.append(token.value)
    return ''.join(out)
