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.

A340592 a(n) is the concatenation of the prime factors (with multiplicity) of n mod n.

This page as a plain text file.
%I A340592 #16 Jul 17 2023 17:01:30
%S A340592 0,0,2,0,5,0,6,6,5,0,7,0,13,5,14,0,17,0,5,16,13,0,15,5,5,9,3,0,25,0,
%T A340592 14,14,13,22,1,0,29,1,25,0,27,0,11,20,39,0,47,28,5,11,29,0,11,16,43,
%U A340592 34,55,0,15,0,45,22,14,58,1,0,41,47,47,0,57,0,15,55,15,18,51,0,65,12,77,0,53,7
%N A340592 a(n) is the concatenation of the prime factors (with multiplicity) of n mod n.
%C A340592 a(n) = 0 if n is prime.
%C A340592 The first composite n for which a(n)=0 is 28749. Are there others?
%C A340592 There are no other composite n terms for which a(n)=0 up to 5 million. - _Harvey P. Dale_, Jul 17 2023
%H A340592 Robert Israel, <a href="/A340592/b340592.txt">Table of n, a(n) for n = 2..10000</a>
%F A340592 a(n) = A037276(n) mod n.
%e A340592 For n = 20 = 2*2*5, a(20) = 225 mod 20 = 5.
%p A340592 dcat:= proc(L) local i,x;
%p A340592   x:= L[-1];
%p A340592   for i from nops(L)-1 to 1 by -1 do
%p A340592     x:= 10^(1+ilog10(x))*L[i]+x
%p A340592   od;
%p A340592   x
%p A340592 end proc:
%p A340592 f:= proc(n) local F;
%p A340592   F:= sort(ifactors(n)[2],(a,b) -> a[1] < b[1]);
%p A340592   dcat(map(t -> t[1]$t[2], F)) mod n;
%p A340592 end proc:
%p A340592 map(f, [$2..100]);
%t A340592 Table[Mod[FromDigits[Flatten[IntegerDigits/@Table[#[[1]],#[[2]]]&/@FactorInteger[n]]],n],{n,2,100}] (* _Harvey P. Dale_, Jul 17 2023 *)
%o A340592 (Python)
%o A340592 from sympy import factorint
%o A340592 def a(n):
%o A340592     if n == 1: return 0
%o A340592     return int("".join(str(f) for f in factorint(n, multiple=True)))%n
%o A340592 print([a(n) for n in range(2, 86)]) # _Michael S. Branicky_, Jan 18 2022
%Y A340592 Cf. A037276, A340594, A340595.
%K A340592 nonn,base
%O A340592 2,3
%A A340592 _J. M. Bergot_ and _Robert Israel_, Jan 12 2021