A037430 Positive numbers having the same set of digits in base 5 and base 7.
1, 2, 3, 4, 17, 51, 66, 102, 416, 423, 557, 687, 697, 739, 785, 842, 889, 1030, 1078, 1087, 1109, 1233, 1374, 1439, 1444, 1477, 1481, 1492, 1499, 1570, 2527, 2566, 2576, 2580, 2601, 2605, 2611, 2625, 2626, 2627, 2628, 2629, 2811, 2871, 2916
Offset: 1
Examples
423 is in the sequence because 423 in base 5 is 3413 and in base 7 it is 1143.
Links
- John Cerkan, Table of n, a(n) for n = 1..10000
Crossrefs
Subsequence of A037394.
Programs
-
Maple
a:=proc(n) if convert(convert(n,base,5),set)=convert(convert(n,base,7),set) then n else fi end: seq(a(n),n=1..3000); # Emeric Deutsch, Apr 30 2006
-
Mathematica
Select[Range[3000],Union[IntegerDigits[#,5]]==Union[IntegerDigits[#,7]]&] (* Harvey P. Dale, Mar 06 2012 *)
-
PARI
is(n)=Set(digits(n, 5))==Set(digits(n, 7)) \\ Charles R Greathouse IV, Feb 11 2017
Extensions
More terms from Don Reble, Apr 28 2006
Name edited by John Cerkan, Feb 09 2017