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.

A321683 Numbers with distinct digits in primorial base.

This page as a plain text file.
%I A321683 #22 Mar 13 2024 01:50:20
%S A321683 0,1,2,4,5,10,13,14,19,20,22,23,25,26,28,29,52,58,79,80,85,86,95,100,
%T A321683 103,104,115,116,118,119,125,130,133,134,139,140,142,143,155,160,163,
%U A321683 164,169,170,172,173,175,176,178,179,185,190,193,194,199,200,202,203
%N A321683 Numbers with distinct digits in primorial base.
%C A321683 This sequence is a variant of A010784 (numbers with distinct digits in decimal). The final term of that sequence is 9876543210. This sequence, by contrast, has infinitely many terms (for example, all the terms of A057588 belong to this sequence).
%H A321683 Rémy Sigrist, <a href="/A321683/b321683.txt">Table of n, a(n) for n = 1..10000</a>
%H A321683 <a href="/index/Pri#primorialbase">Index entries for sequences related to primorial base</a>.
%e A321683 13 in primorial base is 201, which has no repeated digits, hence 13 is in the sequence.
%e A321683 14 in primorial base is 210, which has no repeated digits, hence 14 is also in the sequence.
%e A321683 15 in primorial base is 211, so 15 is not in the sequence on account of the digit 1 appearing twice in its primorial base representation.
%t A321683 q[n_] := Module[{k = n, p = 2, s = {}, r}, While[{k, r} = QuotientRemainder[k, p]; k != 0 || r != 0, AppendTo[s, r]; p = NextPrime[p]]; UnsameQ @@ s]; Select[Range[0, 210], q] (* _Amiram Eldar_, Mar 13 2024 *)
%o A321683 (PARI) is(n) = my (s=0); forprime (p=2, oo, if (n==0, return (1)); my (d=n%p); if (bittest(s,d), return (0), s+=2^d; n\=p))
%Y A321683 See A321682 for the factorial base variant.
%Y A321683 Cf. A049345, A057588, A276150, A321682.
%K A321683 nonn,base
%O A321683 1,3
%A A321683 _Rémy Sigrist_, Nov 17 2018