A067045 Duplicate of A061807.
2, 2, 6, 4, 20, 6, 28, 8, 288, 20, 22, 24, 26, 28, 60, 48, 68, 288, 228, 20, 42, 22, 46, 24
Offset: 1
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.
a(9) = 288 = 32 * 9 is the smallest multiple of 9 which contains only even digits.
a[n_] := Module[{k = 2*n}, While[! AllTrue[IntegerDigits[k], EvenQ], k += n]; k]; Array[a, 60] (* Amiram Eldar, Jan 05 2022 *)
a(n) = my(k=2); while(#select(x->((x%2) == 1), digits(k*n)), k++); k*n; \\ Michel Marcus, Jan 12 2022
def a(n): m, inc = 2*n, n if n%2 == 0 else 2*n while not set(str(m)) <= set("02468"): m += inc return m print([a(n) for n in range(1, 60)]) # Michael S. Branicky, Jan 05 2022
from itertools import count, product def A350538(n): for l in count(len(str(n))-1): for a in '2468': for b in product('02468',repeat=l): k = int(a+''.join(b)) if k > n and k % n == 0: return k # Chai Wah Wu, Jan 12 2022
a:=[]; for n in [1..120 by 2] do k:=1; while not Set(Intseq(n*k)) subset {1,3,5,7,9} do k:=k+2; end while; Append(~a,k*n); end for; a; // Marius A. Burtea, Sep 20 2019
Ad[1]:= [1,3,5,7,9]: for n from 2 to 9 do Ad[n]:= map(t -> seq(10*t+j,j=[1,3,5,7,9]), Ad[n-1]) od: Aod:= [seq(op(Ad[i]),i=1..9)]: f:= proc(n) local k; for k from 1 to nops(Aod) do if Aod[k] mod (2*n-1) = 0 then return(Aod[k]) fi od; NotFound end proc: map(f, [$1..100]); # Robert Israel, Feb 15 2017
Table[Block[{k = 2 n - 1}, While[Nand[AllTrue[IntegerDigits@ k, OddQ], Divisible[k, 2 n - 1]], k += 2]; k], {n, 59}] (* Michael De Vlieger, Dec 02 2017 *)
isoddd(n) = #select(x->((x%2) == 0), digits(n)) == 0; a(n) = {my(m = 2*n-1, k = 1); while(!isoddd(k*m), k++); k*m;} \\ Michel Marcus, Sep 20 2019
apply( {A061808(n)=forstep(k=n*2-1,oo,n*4-2,vecmin(digits(k)%2)&& return(k))}, [1..99])
A061808 = lambda n: next(m for m in range(2*n-1,9<<99,4*n-2) if all(int(d)&1 for d in str(m))) # M. F. Hasler, Mar 05 2025
a(7) = 4 as among the multiples of 7 (i.e., 7, 14, 21, 28...), 28 is the smallest multiple with only even digits and a(7)= 28/7 = 4. a(16) = 3 is the first odd term > 1, a(n = 54, 58, 74, 76, 92, 94, 96, 98, ...) are the next examples, cf. A380874. - _M. F. Hasler_, Mar 03 2025
Table[k = n; While[Length[Intersection[{1, 3, 5, 7, 9}, IntegerDigits[k]]] > 0, k = k + n]; k/n, {n, 100}] (* T. D. Noe, Jun 03 2013 *) sk[n_]:=Module[{k=1},While[!AllTrue[IntegerDigits[k*n],EvenQ],k++];k]; Array[sk,100] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Mar 27 2015 *)
apply( {A067044(n, f=1+n%2)=forstep(a=f*n, oo, f*n, digits(a)%2||return(a/n))}, [1..99]) \\ M. F. Hasler, Mar 03 2025
A067044 = lambda n: next(k for k in range(1+n%2, 9<<99, 1+n%2)if not any(int(d)&1 for d in str(n*k))) # M. F. Hasler, Mar 03 2025
The smallest proper multiple of 9 with only even digits is A350538(9) = 288, as 288 = 9 * 32, a(9) = 32.
a[n_] := Module[{k = 2*n}, While[! AllTrue[IntegerDigits[k], EvenQ], k += n]; k/n]; Array[a, 100] (* Amiram Eldar, Jan 12 2022 *)
a(n) = my(k=2); while(#select(x->((x%2) == 1), digits(k*n)), k++); k; \\ Michel Marcus, Jan 12 2022
a(4) = 16 is the least nontrivial multiple of 8 with only one even digit. a(5) = 30 is the least nontrivial multiple of 10 with only one even digit. a(10) = 40 because 40 is the least nontrivial multiple of 20, and all multiples of 20 will always have (at least) the last two digits even. a(41) = 574 is the least positive multiple of 82 that has only one even digit.
apply( {A381699(n, o=valuation(5*n*=2,10))=for(k=2, oo, #[0|d<-digits(n*k)%2, !d]>o|| return(k*n))}, [1..99]) \\ M. F. Hasler, Mar 04 2025
Comments