|
|
A187719
|
|
Smallest number that when squared is congruent to 41 mod 10^n.
|
|
2
|
|
|
1, 21, 71, 1179, 2429, 47571, 1296179, 8703821, 26452429, 526452429, 13241296179, 19473547571, 2263241296179, 2480526452429, 67263241296179, 932736758703821, 4067263241296179, 38602480526452429, 461397519473547571
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
41 is the smallest number that is not a perfect square for which a sequence like this is well-defined. For 24, the sequence is 2,18,32 and then terminates because no square ends in 0024.
41 is the first term of A188173, which lists other numbers with this property. - T. D. Noe, Mar 23 2011
|
|
LINKS
|
Charles R Greathouse IV, Table of n, a(n) for n = 1..1000
|
|
EXAMPLE
|
71 qualifies because 71^2 is 5041 which ends in 041.
|
|
MATHEMATICA
|
Table[Solve[x^2 == 41 && Modulus == 10^n, x, Mode -> Modular][[1, 2, 2]], {n, 21}] (* T. D. Noe, Mar 22 2011 *)
|
|
PROG
|
(Sage)
def A187719(n):
bposs = [0]
works = lambda x, j: (x^2) % (10^j) == 41 % (10^j)
for w in [0..n]:
bposs = list((i*10**w+b) for i, b in cartesian_product([[0..9], bposs]))
bposs = list(b for b in bposs if works(b, w))
final = list(b for b in bposs if works(b, n))
if final: return min(final) # D. S. McNeil, Mar 22 2011
|
|
CROSSREFS
|
Cf. A188173.
Sequence in context: A296035 A102233 A309903 * A156285 A160435 A240824
Adjacent sequences: A187716 A187717 A187718 * A187720 A187721 A187722
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
J. Lowell, Mar 18 2011
|
|
STATUS
|
approved
|
|
|
|