# # 开发时间 2024/9/27 14:59
import math

import torch
import torch.nn.functional as F
#

C = math.sqrt((15 + math.sqrt(65)) / 8)
m = 1000
W = torch.tensor([[1,1/m],
                  [1/m,1]]).float()
b = torch.tensor([C,C])

X = torch.tensor([2,1.497])

def activate(x):
    return -(2/5)*x**4 + (8/5)*C*x**3+(3/2-(12/5)*C**2)*x**2+((8/5)*C**3-3*C)*x +1


tmp = 1
while(tmp<=10000):
    tmp+=1
    X = activate(torch.matmul(W,X)+b)
print(X)