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.

A337925 Digits of n rearranged to be the smallest number with the fewest possible prime factors, counted with multiplicity. Terms retain the same number of digits as n, i.e. leading digits may not be zero.

This page as a plain text file.
%I A337925 #27 Oct 22 2020 14:10:30
%S A337925 1,2,3,4,5,6,7,8,9,10,11,21,13,41,15,61,17,18,19,20,21,22,23,42,25,26,
%T A337925 27,82,29,30,13,23,33,43,53,63,37,83,39,40,41,42,43,44,45,46,47,84,49,
%U A337925 50,15,25,53,45,55,65,57,58,59,60,61,26,63,46,65,66,67,86,69,70,17,27,37,47,57,67,77
%N A337925 Digits of n rearranged to be the smallest number with the fewest possible prime factors, counted with multiplicity. Terms retain the same number of digits as n, i.e. leading digits may not be zero.
%H A337925 Rémy Sigrist, <a href="/A337925/b337925.txt">Table of n, a(n) for n = 1..10000</a>
%F A337925 a(a(n)) = a(n). - _Rémy Sigrist_, Oct 22 2020
%t A337925 a[n_] := Module[{p = FromDigits /@ Select[Permutations @ IntegerDigits[n], First[#] > 0 &]}, o = PrimeOmega[p]; Min[p[[Position[o, Min[o]] // Flatten]]]]; Array[a, 100] (* _Amiram Eldar_, Oct 19 2020 *)
%o A337925 (PARI) a(n) = {my(d = digits(n), v = select(x->#(digits(x))==#d, vector((#d)!, i, fromdigits(vector(#d, k, d[numtoperm(#d, i-1)[k]])))), b = vecmin(vector(#v, k, bigomega(v[k])))); vecmin(select(x->(bigomega(x)==b), v));} \\ _Michel Marcus_, Oct 19 2020
%Y A337925 Cf. A001222, A004186, A328447.
%K A337925 nonn,look,base
%O A337925 1,2
%A A337925 _Roderick Kimball_, Sep 30 2020