%I #24 Aug 29 2024 01:19:11
%S 1,2,5,10,22,32,62,91,183,188,190,196,258,276,330,671,710,1130,1210,
%T 1570,2644,2998,3292,4214,17055,20035,53015,70315,101010,108947,
%U 199245,233606,309665,323232,356421,483405,626262,919191,1743599
%N Integers k that divide LS(k), where LS is the "Look and Say" function (A045918).
%C Infinite since s^i is a term for all odd i and s = 10, 32, 62, 91, 183, 190, 196, 258, 276, 671, 710, 1210, 1570, ..., where ^ denotes repeated concatenation of digits. - _Michael S. Branicky_, Aug 28 2024
%H Michael S. Branicky, <a href="/A079342/b079342.txt">Table of n, a(n) for n = 1..82</a> (all terms <= 10^10)
%e E.g. LS(1)=11, LS(2)=12, LS(10)=1110, LS(188)=1128 etc. and in each case LS(n) is a multiple of n.
%e 122918=0 mod 2998, so 2998 is in the sequence.
%e But 13 == 1 mod 3, so 3 is not in the sequence.
%p # Implementation by _R. J. Mathar_, May 08 2019:
%p A045918 := proc(n)
%p local a,f,pd,dgs,i ;
%p a := [] ;
%p f := 0 ;
%p pd := -1 ;
%p dgs := convert(n,base,10) ;
%p for i from 1 to nops(dgs) do
%p if op(-i,dgs) <> pd then
%p if pd >= 0 then
%p a := [op(a),f,pd] ;
%p end if;
%p pd := op(-i,dgs) ;
%p f := 1 ;
%p else
%p f:= f+1 ;
%p end if;
%p end do:
%p a := [op(a),f,pd] ;
%p digcatL(%) ;
%p end proc:
%p isA079342 := proc(n)
%p simplify( modp(A045918(n) ,n) = 0 ) ;
%p end proc:
%p for n from 1 to 30000 do
%p if isA079342(n) then
%p print(n) ;
%p end if;
%p end do:
%o (Python)
%o def LS(n): return int(''.join(str(len(list(g)))+k for k, g in groupby(str(n))))
%o def ok(n): return LS(n)%n == 0
%o print([k for k in range(1, 10**4) if ok(k)]) # _Michael S. Branicky_, Aug 28 2024
%Y Cf. A056815, A005150, A079562.
%Y Cf. A152957. - _David Wasserman_, Dec 15 2008
%K base,nonn,changed
%O 1,2
%A Mark Hudson (mrmarkhudson(AT)hotmail.com), Feb 13 2003
|