0 Members and 1 Guest are viewing this topic.
1+y/x→a1-1/a+a>>2→a{xa,y/a}→{x,y}
{max(Ans),min(Ans→L1int(log(L1(1)/L1(2))/log(4L1{2^-Ans,2^Ans→L12^int(log(Ans(1))/log(2→PL1/Ans→L1While E-10<abs(max(deltaList(L1 ;engineering E1+L1(2)/L1(11-Ans^-1+.25AnsL1{Ans,Ans^-1→L1EndPmean(L1
{976,587→L11+L1(2)/L1(1:1-Ans^-1+.25Ans:L1{Ans,Ans^-1→L1
;think of all values here as 2.m fixed point numbers. INPUTS: X,Y are on [1,4) c=1 iterate n times a=y-x if underflow a=-a (x,y) = (y,x) //swap x and y, so x<y n=-2+intlg(a) //intlg(a) basically finds the negative of the index of the first '1' bit in the binary expansion of a. Basically, the "clz" instruction for some processors. c-=c>>2n x+=x>>n x+=x>>n y-=y>>n y-=y>>n return x/c
You're just a math goddess. I don't understand 50% of what you're saying here but whatever, might come in handy one time