cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A257897 Numbers n such that n = concat(a,b) and n | a^b + b^a , with a>0 and b>0.

Original entry on oeis.org

63, 103, 128, 147, 155, 212, 272, 292, 351, 452, 486, 497, 525, 527, 537, 584, 607, 624, 648, 729, 979, 999, 1024, 1296, 1323, 1359, 1533, 1541, 1575, 1809, 1872, 2048, 2050, 2107, 2187, 2448, 2512, 2537, 2564, 2763, 2793, 2886, 3072, 3357, 3927, 4096, 4263, 4284
Offset: 1

Views

Author

Paolo P. Lava, May 12 2015

Keywords

Comments

We can have different solutions for the same number. E.g.: 2048 divides both (20^48 + 48^20) and (204^8 + 8^204). The same occurs for 4096, 4263, 16807, 32768, 96957, 156672, 186624, 252081, 262144, 270729, 352947, 390624 … The first number with 3 different concatenations is 186624 that divides (18^6624 + 6624^18), (186^624 + 624^186) and (1866^24 + 24^1866).

Examples

			6^3 + 3^6 = 945 and 945 / 63 = 15;
10^3 + 3^10 = 60049 and 60049 / 103 = 583;
12^8 + 8^12 = 69149458432 and 69149458432 / 128 = 540230144; etc.
		

Crossrefs

Programs

  • Maple
    with(numtheory); P:=proc(q) local a,b,i,n; for n from 1 to q do
    for i from 1 to ilog10(n) do a:=trunc(n/10^i); b:=n-a*10^i;
    if a>0 and b>0 then if type((a^b+b^a)/n,integer)
    then print(n); break; fi; fi; od; od; end: P(10^9);
  • Mathematica
    tst[n_]:=Catch@Block[{a,b}, Do[a=Floor[n/10^k]; b=Mod[n,10^k]; If[Mod[ PowerMod[a, b, n] + PowerMod[b, a, n], n]==0, Throw@True], {k, IntegerLength[n]-1}]; False]; Select[Range@1000, tst] (* Giovanni Resta, May 12 2015 *)