Den söndag 21 juni 2015 kl. 10:09:55 UTC+2 skrev Evertjan.:
> jonas.thornvall@gmail.com wrote on 21 Jun 2015 in comp.lang.javascript:
>
> >> P.S. Have you learned yet how USENET works?
> >
> > Of course the best case for ......
>
> As Usenet is a platform of discussion-lists,
> you should bring in argumentation for your statements.
>
> Your 'of course' just means:
> 'I trust you fall for my unforgivable lack of argumentation'.
>
> And please stop responding to yourself and answering yourself,
> Usenet is not a platform for monologues.
>
> --
> Evertjan.
> The Netherlands.
> (Please change the x'es to dots in my emailaddress)
Well i must say i find it hard to calculate the time complexity, especially since the base used seem to matter.
The weight of the operands seem to be vital, and really should be taken into account when doing comparissons.
If i have an algorithm performing division by a min max search, i am a bit lost about what really is the timecomplexity. Because there is numerous different operations performed. If one take the actual min max search for a digit, it follows naturally that the weight of digit is dependent upon the base.
So the higher the base the less total operations is performed doing the divisions. There is a number of operations performed to do the division, but which one is the actual time complexity.
1. Search and store the multiples for base x -> x^1,x^2,x^3... and so on.
Loop until number exhausted or specified precision reached.
Loop until multiple found
2. Use the min max search and find the polynomial multiplier for digit y*x^z
3. Compare the result of the multiplication with the number.
End.
4. Subtract the product from the number.
End.
I have a hard time to conclude what the actual time complexity is when using this algorithm doing division and it also seem dependent upon the size of base x.