Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
Find zero of f(x)=x**x-N solution in Clear category for Super Root by oLeBeLo
def super_root(n,acc=0.001):
left,right = 0,1
i = 1
while right**right - n < 0:
left,right = 2**(i-1),2**i
i+=1
x = (left+right)/2
while abs(x**x-n) >= acc:
x = (left+right)/2
if x**x - n > 0:
right = x
else:
left = x
return x
Jan. 22, 2020
Comments: