Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.
%I #26 Nov 14 2024 14:56:12
%S 1,2,6,3,3,6,6,3,3,6,3,3,3,6,6,3,6,3,3,3,6,6,6,3,6,6,3,3,6,6,3,3,6,3,
%T 3,6,6,6,6,3,6,3,3,6,6,3,3,3,3,6,6,3,6,6,3,6,3,6,6,6,3,3,6,6,3,3,6,6,
%U 6,3,3,6,3,3,3,3,6,3,3,6,6,3,3,6,6,6,3,6
%N The n-th primorial number reduced modulo 9.
%C a(n) is the fixed point reached by decimal-digit-sum-function (A007953), when starting the iteration from the value of the n-th primorial, A002110(n). - The (edited) original definition of the sequence, which is equal to a simple definition a(n) = A002110(n) mod 9, because taking the decimal digit sum preserves congruence modulo 9. - _Antti Karttunen_, Nov 14 2024
%C Only a(0)=1 and a(1)=2; each subsequent term is either a 3 or a 6.
%H Antti Karttunen, <a href="/A086360/b086360.txt">Table of n, a(n) for n = 0..19683</a> (terms 1..10000 from Nathaniel Johnston)
%H <a href="/index/Pri#primorial_numbers">Index entries for sequences related to primorial numbers</a>
%F a(n) = A010878(A002110(n)) = A002110(n) mod 9.
%F a(n) = A010888(A002110(n)).
%e For n=7, 7th primorial = 510510, list of iterated digit sums is {510510,12,3}, thus a(7)=3.
%p A086360 := proc(n) option remember: if(n=1)then return 2:fi: return ithprime(n)*procname(n-1) mod 9: end: seq(A086360(n), n=1..100); # _Nathaniel Johnston_, May 04 2011
%t sud[x_] := Apply[Plus, DeleteCases[IntegerDigits[x], 0]] q[x_] := Apply[Times, Table[Prime[w], {w, 1, x}]] Table[FixedPoint[sud, q[w]], {w, 1, 128}]
%o (PARI)
%o up_to = 19683;
%o A086360list(up_to_n) = { my(m=9, v=vector(1+up_to_n), pr=1); v[1] = 1; for(n=1, up_to_n, pr = (pr*prime(n))%m; v[1+n] = pr); (v); };
%o v086360 = A086360list(up_to);
%o A086360(n) = v086360[1+n]; \\ _Antti Karttunen_, Nov 14 2024
%Y Cf. A002110, A007953, A010878, A010888, A029898, A038194, A086353-A086361.
%Y Cf. also A377876, A377877.
%K easy,nonn
%O 0,2
%A _Labos Elemer_, Jul 21 2003
%E Term a(0)=1 prepended, old definition moved to comments and replaced with one of the formulas, keyword:base removed because not really base-dependent - _Antti Karttunen_, Nov 14 2024