User talk:Thundergnat: Difference between revisions

no edit summary
No edit summary
Line 444:
 
:: Added the [https://rosettacode.org/wiki/Ramanujan%27s_constant draft task]... Regarding ntheory: I'd be happy if <code>use ntheory:from<Perl5></code> worked reliably, but it's hit-and-miss in my experience so far. --[[User:SqrtNegInf|SqrtNegInf]] ([[User talk:SqrtNegInf|talk]]) 04:05, 25 April 2019 (UTC)
==First perfect square in base N with N unique digits==
you said " 25, # very slow"
Win Calculator can't calculate these values, so i did online.
My runtime is ~43 seconds
<pre>base
25
1011E109GHMMM # 0 //Start value dec: 59705969332701822
1023456789ABD5AHDHG370GC9 # 0 //Start value sqr dec:3564802773957530451841538362119684
solution:
1011E145FHGHM
102345DOECKJ6GFB8LIAM7NH9 937.105.500 -> steps
 
42.851 s
3.7 Ghz -> 42.851/937105500*3.7e9= 169.2 cpu cycles per one complete number test
n-> n+1 => sqr(n) -> spr(n+1) -> examine digits
</pre>
i think doing bigint base conversion takes much to long time.<br>
I now have to include bigint, to find the start values.
Anonymous user