A216473 a(n) = smallest m such that 2n-1 | (10^m-1)/9, or 0 if no such m exists.
1, 3, 0, 6, 9, 2, 6, 0, 16, 18, 6, 22, 0, 27, 28, 15, 6, 0, 3, 6, 5, 21, 0, 46, 42, 48, 13, 0, 18, 58, 60, 18, 0, 33, 66, 35, 8, 0, 6, 13, 81, 41, 0, 84, 44, 6, 15, 0, 96, 18, 4, 34, 0, 53, 108, 3, 112, 0, 18, 48, 22, 15, 0, 42, 21, 130, 18, 0, 8, 46, 138, 6, 0
Offset: 1
Keywords
Crossrefs
Cf. A002326.
Programs
-
Mathematica
Table[s = MultiplicativeOrder[10, 9*(2*n - 1)]; If[! IntegerQ[s], 0, s], {n, 100}] (* T. D. Noe, Sep 20 2012 *)
-
PARI
A216473(n)=if(n%5-3,znorder(Mod(10,18*n-9))) \\ M. F. Hasler, Sep 29 2012
-
PARI
for(i=0,200,i++;if(i%5==0,print1(0","),print1(znorder(Mod(10,9*i))","))) \\ V. Raman, Nov 22 2012
-
PARI
for(i=0,200,i++;m=0;for(x=1,i,if(((10^x-1)/9)%i==0,m=x;break));print1(m",")) \\ V. Raman, Nov 22 2012
Extensions
Definition corrected by V. Raman, Sep 20 2012
Comments