%I #25 Jun 09 2015 04:19:00
%S 11,22,0,410,5125,620,735,816,975,0,0,1280,0,14200,0,0,17200,1872,
%T 19250,2015625,21109375,222500,0,24150,251250,262000,0,0,291450,
%U 305000,0,0,0,0,0,0,37115625,0,0,402500,0,42336,0,442750,45703125,46920,0,4850000,4912500,0,515100
%N Least k formed by the concatenation of two numbers n and d such that d is the n-th divisor of k, or 0 if no such k exists.
%C Some semiprime near-misses for a(3): 35, 323, 365, 3103, 3173, 3493, 3755, 31673, 34993, 37495, 349993, 3166673, 34999993, 31666666673. - _Michel Marcus_, May 08 2015
%H Robert Israel, <a href="/A257491/b257491.txt">Table of n, a(n) for n = 1..80</a>
%e a(4) = 410 because the divisors of 410 are {1, 2, 5, 10, 41, 82, 205, 410} and 10 is the 4th divisor of 410.
%p # this program tests k < 150000; results of 0 may be incorrect.
%p with(numtheory):nn:=51:
%p for n from 1 to nn do:
%p ii:=0:
%p for k from n to 150000 while(ii=0)do:
%p i:=length(k):p:=n*10^i+k:
%p x:=divisors(p):n0:=nops(x):
%p if n<=n0 then
%p d:=x[n]:j:=length(d):q:=n*10^j+d:
%p if p=q then
%p ii:=1:printf ( "%d %d \n",n,p):
%p else
%p fi:fi:
%p od:
%p if ii=0 then printf ( "%d %d \n",n,0):
%p else
%p fi:
%p od:
%p # Alternative
%p f:= proc(n)
%p local F, m, t, primes, enum, cands, d, divs;
%p F:= ifactors(n)[2];
%p primes:= {seq(t[1],t=F)} union {2,5};
%p for t in F do m[t[1]]:= t[2] od;
%p m[2]:= n; m[5]:= n;
%p enum:= proc(pr,t)
%p local p,r;
%p if pr = {} or t <= 1 then return [1] fi;
%p p:= pr[1];
%p r:= pr[2..-1];
%p [seq(op(map(`*`,procname(r,floor(t/(1+j))), p^j)), j=0..m[p])]
%p end proc;
%p cands:= sort(enum(primes,n));
%p for d in cands do
%p divs:= sort(convert(numtheory:-divisors(n*10^(1+ilog10(d))+d),list));
%p if nops(divs) >= n and divs[n] = d then return(n*10^(1+ilog10(d))+d) fi;
%p od;
%p 0
%p end proc:
%p seq(f(n), n=1..60); # _Robert Israel_, Jun 08 2015
%Y Cf. A000012 (1st divisor of n), A020639 (2nd divisor of n).
%K nonn,base,hard
%O 1,1
%A _Michel Lagneau_, Apr 26 2015
%E a(21), a(45) and a(48) from _Robert Israel_, Jun 08 2015
|