login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A322489 Numbers k such that k^k ends with 4. 3
2, 18, 22, 38, 42, 58, 62, 78, 82, 98, 102, 118, 122, 138, 142, 158, 162, 178, 182, 198, 202, 218, 222, 238, 242, 258, 262, 278, 282, 298, 302, 318, 322, 338, 342, 358, 362, 378, 382, 398, 402, 418, 422, 438, 442, 458, 462, 478, 482, 498, 502, 518, 522, 538, 542, 558 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
Also numbers k == 2 (mod 4) such that 2^k and k^2 end with the same digit.
Numbers congruent to {2, 18} mod 20. - Amiram Eldar, Feb 27 2023
LINKS
FORMULA
O.g.f.: 2*x*(1 + 8*x + x^2)/((1 + x)*(1 - x)^2).
E.g.f.: 2 + 3*exp(-x) + 5*(2*x - 1)*exp(x).
a(n) = -a(-n+1) = a(n-1) + a(n-2) - a(n-3).
a(n) = 10*n + 3*(-1)^n - 5. Therefore:
a(n) = 10*n - 8 for odd n;
a(n) = 10*n - 2 for even n.
a(n+2*k) = a(n) + 20*k.
Sum_{n>=1} (-1)^(n+1)/a(n) = tan(2*Pi/5)*Pi/20 = sqrt(5+2*sqrt(5))*Pi/20. - Amiram Eldar, Feb 27 2023
MAPLE
select(n->n^n mod 10=4, [$1..558]); # Paolo P. Lava, Dec 18 2018
MATHEMATICA
Table[10 n + 3 (-1)^n - 5, {n, 1, 60}]
PROG
(Sage) [10*n+3*(-1)^n-5 for n in (1..70)]
(Maxima) makelist(10*n+3*(-1)^n-5, n, 1, 70);
(GAP) List([1..70], n -> 10*n+3*(-1)^n-5);
(Magma) [10*n+3*(-1)^n-5: n in [1..70]];
(Python) [10*n+3*(-1)**n-5 for n in range(1, 70)]
(Julia) [10*n+3*(-1)^n-5 for n in 1:70] |> println
(PARI) apply(A322489(n)=10*n+3*(-1)^n-5, [1..70]) \\ M. F. Hasler, Dec 14 2018
(PARI) Vec(2*x*(1 + 8*x + x^2) / ((1 - x)^2*(1 + x)) + O(x^70)) \\ Colin Barker, Dec 13 2018
CROSSREFS
Subsequence of A139544, A235700.
Numbers k such that k^k ends with d: A008592 (d=0), A017281 (d=1), A067870 (d=3), this sequence (d=4), A017329 (d=5), A271346 (d=6), A322490 (d=7), A017377 (d=9).
Sequence in context: A092587 A247457 A015787 * A063430 A031104 A115042
KEYWORD
nonn,base,easy
AUTHOR
Bruno Berselli, Dec 12 2018
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 04:42 EDT 2024. Contains 371964 sequences. (Running on oeis4.)