Displaying 1-10 of 85 results found.
Number of numbers <= n having distinct digits in their decimal representation, cf. A010784.
+20
4
1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 61, 62, 63, 64, 65, 66
COMMENTS
a(m)<=a(n) for m<n and a(n)=8877690 for n>=9876543210;
LINKS
Eric Weisstein's World of Mathematics, Digit
EXAMPLE
a(12) = #{0,1,2,3,4,5,6,7,8,9,10,12} = 12;
a(24) = a(12) + #{13,14,15,16,17,18,19,20,21,23,24} = 23.
PROG
(Haskell)
a178787 n = a178787_list !! n
a178787_list = scanl1 (+) a178788_list
a(1) = 102735, a(n) = prime(n-1)*a(n-1) but products that are not in A010784 are first reduced as in A320486 (see comments); continue until zero is reached.
+20
2
102735, 2547, 7641, 38205, 267435, 2941785, 8405, 1425, 205, 4715, 1675, 192, 7104, 9164, 394052, 18520, 981560, 579124, 24, 1608, 468, 316, 296, 24568, 186, 18042, 184, 18952, 7864, 8516, 962308, 36
COMMENTS
At each step, integers that contain duplicated digits are reduced to terms of A010784 by erasing all digits that appear more than once and bunching up the digits that remain. Leading zeros are ignored and any number that disappears entirely becomes 0. See A320486.
102735 is the smallest of 785 A010784 terms that result in a 362-term sequence, the longest possible.
EXAMPLE
2 * 102735 = [205470] => 2547
3 * 2547 = 7641
5 * 7641 = 38205
7 * 38205 = 267435
11 * 267435 = 2941785
13 * 2941785 = [38243205] => 8405
17 * 8405 = [142885] => 1425
19 * 1425 = [27075] => 205
...
2417 * 40 = [96680] => 980
2423 * 980 = [2374540] => 23750
2437 * 23750 = [57878750] => 0
a(1) = 24603, a(n) = n*a(n-1) but products that are not in A010784 are first reduced as in A320486 (see comments); continue until zero is reached.
+20
1
24603, 49206, 4768, 19072, 95360, 572160, 4512, 309, 2781, 27810, 3591, 43092, 5019, 702, 153, 28, 476, 56, 1064, 180, 3780, 83160, 92680, 430, 175, 40, 18, 504, 4, 120, 3720, 94, 3102, 105468, 69180, 298, 26, 9, 351, 1, 41, 17, 731, 32164, 17380, 7480, 3160, 5680, 7830, 3915, 15, 780, 130, 72, 3960, 1760, 132, 75, 25, 15, 915, 56730, 570, 36480, 371, 286, 962, 541, 729, 513, 642, 6, 438, 341, 27, 5, 385, 0
COMMENTS
At each step, integers that contain duplicated digits are reduced to terms of A010784 by erasing all digits that appear more than once and bunching up the digits that remain. Leading zeros are ignored and any number that disappears entirely becomes 0. See A320486.
24603 is the smallest of 1746 A010784 terms that result in a 78-term sequence, the longest possible.
EXAMPLE
2 * 24603 = 49206
3 * 49206 = [147618] => 4768
4 * 4768 = 19072
5 * 19072 = 95360
6 * 95360 = 572160
7 * 572160 = [4005120] => 4512
8 * 4512 = [36096] => 309
...
76 * 27 = [2052] => 5
77 * 5 = 385
78 * 385 = [30030] => 0
Numbers k such that the two closest numbers above and below k, which are in A010784 and which have no common digit with k, have the same distance to k.
+20
0
1, 2, 3, 4, 5, 6, 7, 8, 9, 89, 394, 605, 894, 3944, 6055, 8944, 15111, 84888, 89444, 894444
COMMENTS
For each integer k, define the smallest upper neighbor k+d with d > 0 such that k+d contains each digit at most once (see A010784) and has none of the digits of k. Define also the largest lower neighbor k-b with b > 0 such that k-b contains each digit at most once and has none of the digits of k.
The sequence consists of those k where d=b, that is, where these two neighbors are equidistant from k.
15111 has neighbors 9876 and 20346, distance 5235.
84888 has neighbors 79653 and 90123, distance 5235.
89444 has neighbors 76532 and 102356, distance 12912.
894444 has neighbors 765321 and 1023567, distance 129123.
Sequence is complete.
(End)
EXAMPLE
6 has neighbors 5 and 7, common distance 1.
89 has neighbors 76 and 102, common distance 13.
394 has neighbors 287 and 501, distance 107.
605 has neighbors 498 and 712, distance 107.
894 has neighbors 765 and 1023, distance 129.
3944 has neighbors 2876 and 5012, distance 1068.
6055 has neighbors 4987 and 7123, distance 1068.
8944 has neighbors 7653 and 10235, distance 1291.
94 is not in the sequence because 87 and 102 have distances 7 and 8.
Numbers in which every pair of adjacent digits are distinct.
+10
57
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 101, 102, 103, 104, 105, 106, 107, 108, 109, 120, 121, 123, 124, 125, 126, 127, 128, 129
EXAMPLE
11 is the first number not in the sequence, since it has a pair of identical adjacent digits.
MAPLE
isA034096 := proc(n)
local dgs ;
dgs := convert(n, base, 10) ;
for i from 2 to nops(dgs) do
if op(i, dgs) = op(i-1, dgs) then
return false;
end if;
end do:
true ;
end proc:
for n from 0 to 150 do
if isA034096(n) then
printf("%d, ", n) ;
end if;
MATHEMATICA
t={}; Do[If[!MemberQ[Differences[IntegerDigits[n]], 0], AppendTo[t, n]], {n, 0, 69}]; t (* Jayanta Basu, May 04 2013 *)
PROG
(Haskell)
import Data.List (elemIndices)
a043096 n = a043096_list !! n
a043096_list = elemIndices 1 a196368_list
(Python)
def ok(n): s = str(n); return all(s[i] != s[i+1] for i in range(len(s)-1))
Primes with distinct digits.
+10
32
2, 3, 5, 7, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 103, 107, 109, 127, 137, 139, 149, 157, 163, 167, 173, 179, 193, 197, 239, 241, 251, 257, 263, 269, 271, 281, 283, 293, 307, 317, 347, 349, 359, 367, 379, 389
MATHEMATICA
t={}; Do[p=Prime[n]; If[Select[Transpose[Tally[IntegerDigits[p]]][[2]], #>1 &]=={}, AppendTo[t, p]], {n, 77}]; t (* Jayanta Basu, May 04 2013 *)
Select[Prime[Range[80]], Max[DigitCount[#]]<2&] (* Harvey P. Dale, Sep 13 2020 *)
PROG
(Haskell)
a029743 n = a029743_list !! (n-1)
a029743_list = filter ((== 1) . a010051) a010784_list
(Python)
from sympy import isprime
from itertools import permutations as P
dist = [p for d in range(1, 11) for p in P("0123456789", d) if p[0] != "0"]
afull = [t for t in (int("".join(p)) for p in dist) if isprime(t)]
Characteristic function of numbers having distinct digits in their decimal representation.
+10
19
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1
LINKS
Eric Weisstein's World of Mathematics, Digit
MATHEMATICA
lst = {}; Do[If[Select[Tally[IntegerDigits[n]][[All, 2]], # > 1 &] == {}, AppendTo[lst, 1], AppendTo[lst, 0]], {n, 0, 104}]; lst (* Arkadiusz Wesolowski, May 10 2012 *)
PROG
(Haskell)
import Data.List (nub)
a178788 n = fromEnum $ nub (show n) == show n
Numbers in decimal representation with distinct digits, such that in Dutch their digits are in alphabetic order.
+10
18
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 16, 17, 19, 24, 25, 26, 27, 30, 32, 34, 35, 36, 37, 39, 45, 46, 47, 56, 57, 67, 80, 81, 82, 83, 84, 85, 86, 87, 89, 90, 92, 94, 95, 96, 97, 102, 104, 105, 106, 107, 124, 125, 126, 127, 130, 132, 134, 135, 136
COMMENTS
List of decimal digits, alphabetically sorted by their names in Dutch:
8 _ acht, 1 _ een, 3 _ drie, 9 _ negen, 0 _ nul, 2 _ twee, 4 _ vier, 5 _ vijf, 6 _ zes, 7 _ zeven;
finite sequence with last and largest term a(992) = 8139024567.
PROG
(Haskell)
import Data.IntSet (fromList, deleteFindMin, union)
import qualified Data.IntSet as Set (null)
a247802 n = a247802_list !! (n-1)
a247802_list = 0 : f (fromList [1..9]) where
f s | Set.null s = []
| otherwise = x : f (s' `union`
fromList (map (+ 10 * x) $ tail $ dropWhile (/= mod x 10) digs))
where (x, s') = deleteFindMin s
digs = [8, 1, 3, 9, 0, 2, 4, 5, 6, 7]
CROSSREFS
Cf. A247800 (Czech), A247801 (Danish), A053433 (English), A247803 (Finnish), A247804 (French), A247805 (German), A247806 (Hungarian), A247807 (Italian), A247808 (Latin), A247809 (Norwegian), A247810 (Polish), A247807 (Portuguese), A247811 (Russian), A247812 (Slovak), A247813 (Spanish), A247809 (Swedish), A247814 (Turkish).
Numbers in decimal representation with distinct digits, such that in Czech their digits are in alphabetic order.
+10
17
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 13, 15, 16, 17, 18, 20, 21, 23, 25, 26, 27, 28, 40, 41, 42, 43, 45, 46, 47, 48, 49, 53, 56, 57, 63, 73, 76, 83, 85, 86, 87, 90, 91, 92, 93, 95, 96, 97, 98, 103, 105, 106, 107, 108, 153, 156, 157, 163, 173, 176, 183, 185, 186
COMMENTS
List of decimal digits, alphabetically sorted by their names in Czech:
4 _ čtyři, 9 _ devět, 2 _ dva/dvě, 1 _ jeden/jedna/jedno, 0 _ nula, 8 _ osm, 5 _ pět, 7 _ sedm, 6 _ šest, 3 _ tři;
finite sequence with last and largest term a(992) = 4921085673.
PROG
(Haskell)
import Data.IntSet (fromList, deleteFindMin, union)
import qualified Data.IntSet as Set (null)
a247800 n = a247800_list !! (n-1)
a247800_list = 0 : f (fromList [1..9]) where
f s | Set.null s = []
| otherwise = x : f (s' `union`
fromList (map (+ 10 * x) $ tail $ dropWhile (/= mod x 10) digs))
where (x, s') = deleteFindMin s
digs = [4, 9, 2, 1, 0, 8, 5, 7, 6, 3]
CROSSREFS
Cf. A247801 (Danish), A247802 (Dutch), A053433 (English), A247803 (Finnish), A247804 (French), A247805 (German), A247806 (Hungarian), A247807 (Italian), A247808 (Latin), A247809 (Norwegian), A247810 (Polish), A247807 (Portuguese), A247811 (Russian), A247812 (Slovak), A247813 (Spanish), A247809 (Swedish), A247814 (Turkish).
Numbers in decimal representation with distinct digits, such that in Danish their digits are in alphabetic order.
+10
17
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 16, 17, 18, 19, 23, 40, 42, 43, 46, 47, 48, 49, 50, 52, 53, 54, 56, 57, 58, 59, 62, 63, 67, 72, 73, 82, 83, 86, 87, 90, 92, 93, 96, 97, 98, 102, 103, 106, 107, 108, 123, 140, 142, 143, 146, 147, 148, 149, 150
COMMENTS
List of decimal digits, alphabetically sorted by their names in Danish:
1 _ en/et, 5 _ fem, 4 _ fire, 9 _ ni, 0 _ nul, 8 _ otte, 6 _ seks, 7 _ syv, 2 _ to, 3 _ tre;
finite sequence with last and largest term a(992) = 1549086723.
PROG
(Haskell)
import Data.IntSet (fromList, deleteFindMin, union)
import qualified Data.IntSet as Set (null)
a247801 n = a247801_list !! (n-1)
a247801_list = 0 : f (fromList [1..9]) where
f s | Set.null s = []
| otherwise = x : f (s' `union`
fromList (map (+ 10 * x) $ tail $ dropWhile (/= mod x 10) digs))
where (x, s') = deleteFindMin s
digs = [1, 5, 4, 9, 0, 8, 6, 7, 2, 3]
CROSSREFS
Cf. A247800 (Czech), A247802 (Dutch), A053433 (English), A247803 (Finnish), A247804 (French), A247805 (German), A247806 (Hungarian), A247807 (Italian), A247808 (Latin), A247809 (Norwegian), A247810 (Polish), A247807 (Portuguese), A247811 (Russian), A247812 (Slovak), A247813 (Spanish), A247809 (Swedish), A247814 (Turkish).
Search completed in 0.070 seconds
|