def Griewank(d):
    sum_1 = 0
    for i in d:
        sum_1 += ((i * i) / 4000)
    sum_2 = 1
    for i in range(len(d)):
        sum_2 *= np.cos((d[i] / math.sqrt((i + 1))))
    return ((sum_1 - sum_2) + 1)
def Griewank(d):
    sum_1 = 0
    for i in d:
        sum_1 += ((i * i) / 4000)
    sum_2 = 1
    for i in range(len(d)):
        sum_2 *= np.cos((d[i] / math.sqrt((i + 1))))
    return ((sum_1 - sum_2) + 1)