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.

Showing 1-7 of 7 results.

A050218 Sums of digits of Smith numbers A006753.

Original entry on oeis.org

4, 4, 9, 13, 13, 13, 4, 13, 4, 13, 13, 13, 13, 13, 18, 13, 13, 15, 13, 15, 13, 13, 13, 13, 18, 21, 15, 13, 15, 15, 18, 15, 15, 18, 15, 13, 17, 18, 15, 22, 15, 15, 15, 22, 13, 15, 13, 22, 22, 15, 4, 13, 13, 13, 13, 15, 17, 18, 13, 15, 15, 13, 13, 22, 17, 18, 21, 22, 13, 15
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    d[n_]:=IntegerDigits[n]; tr[n_]:=Transpose[FactorInteger[n]]; t={}; Do[If[!PrimeQ[n]&&(x=Total[d[n]])==Total[d@tr[n][[1]]*tr[n][[2]],2],AppendTo[t,x]],{n,4,1850}]; t (* Jayanta Basu, Jun 04 2013 *)

Formula

a(n) = A007953(A006753(n)).

Extensions

Offset corrected by Reinhard Zumkeller, Dec 19 2011

A050220 Larger of Smith brothers.

Original entry on oeis.org

729, 2965, 3865, 4960, 5936, 6188, 9387, 9634, 11696, 13765, 16537, 16592, 20785, 25429, 28809, 29624, 32697, 33633, 35806, 39586, 43737, 44734, 49028, 55345, 56337, 57664, 58306, 62635, 65913, 65975, 66651, 67068, 67729, 69280, 69836, 73616, 73617, 74169
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Maple
    issmith:= proc(n)
      if isprime(n) then return false fi;
      convert(convert(n,base,10),`+`) = add(t[2]*convert(convert(t[1],base,10),`+`),t=ifactors(n)[2])
    end proc:
    S:= select(issmith, {$4..10^5}):
    sort(convert(S intersect map(`+`,S,1), list)); # Robert Israel, Jan 15 2018
  • Mathematica
    smithQ[n_] := n > 1 && !PrimeQ[n] && Total[Flatten[IntegerDigits[Table[#[[1]], {#[[2]]}]& /@ FactorInteger[n]]]] == Total[IntegerDigits[n]];
    Select[Range[10^5], smithQ[#] && smithQ[#-1]&] (* Jean-François Alcover, Jun 07 2020 *)
  • PARI
    isone(n) = {if (!isprime(n), f = factor(n); sumdigits(n) == sum(k=1, #f~, f[k,2]*sumdigits(f[k,1])););}
    isok(n) =  isone(n) && isone(n-1); \\ Michel Marcus, Jul 17 2015
    
  • Python
    from sympy import factorint
    from itertools import count, islice
    def sd(n): return sum(map(int, str(n)))
    def smith():
        for k in count(1):
            f = factorint(k)
            if sum(f[p] for p in f) > 1 and sd(k) == sum(sd(p)*f[p] for p in f):
                yield k
    def agen():
        prev = -1
        for s in smith():
            if s == prev + 1: yield s
            prev = s
    print(list(islice(agen(), 38))) # Michael S. Branicky, Dec 23 2022

Extensions

Offset corrected by Arkadiusz Wesolowski, May 08 2012

A331464 Numbers k such that k and k + 1 are both binary Smith numbers (A278909).

Original entry on oeis.org

1369, 1370, 1390, 1630, 1929, 2525, 2526, 2930, 3013, 3309, 3501, 3502, 3686, 3805, 3953, 3954, 4043, 4726, 4854, 5620, 5621, 5917, 6068, 6682, 6774, 6838, 7025, 7089, 7115, 7671, 7738, 7786, 8075, 9654, 9915, 10366, 10982, 11166, 11227, 11506, 11673, 11740, 11763
Offset: 1

Views

Author

Amiram Eldar, Jan 17 2020

Keywords

Examples

			1369 is in the sequence since both 1369 and 1369 + 1 = 1370 are binary Smith numbers.
		

Crossrefs

Programs

  • Mathematica
    binWt[n_] := Total @ IntegerDigits[n, 2]; binSmithQ[n_] := CompositeQ[n] && Plus @@ (Last@# * binWt[ First@# ] & /@ FactorInteger[n]) == binWt[n]; seq = {}; isSmith1 = binSmithQ[1]; Do[isSmith2 = binSmithQ[n]; If[isSmith1 && isSmith2, AppendTo[seq, n-1]]; isSmith1 = isSmith2, {n, 2, 12000}]; seq

A105648 Smallest member of a set of Smith triples.

Original entry on oeis.org

73615, 209065, 225951, 283745, 305455, 342879, 656743, 683670, 729066, 747948, 774858, 879221, 954590, 1185547, 1262722, 1353955, 1369374, 1495718, 1622495, 1666434, 1790480, 2197579, 2299772, 2428854, 2561678, 2576441, 2580367, 2636516, 2665480, 2707580, 2741816
Offset: 1

Views

Author

Shyam Sunder Gupta, May 03 2005

Keywords

Comments

If there are 3 consecutive numbers which are Smith numbers, these can be called a Smith triple.

Examples

			a(1) = 73615 because 73615 is the smallest of 3 consecutive integers which are Smith numbers, i.e., the three consecutive numbers 73615, 73616, 73617 are all Smith numbers.
		

Crossrefs

Programs

  • Mathematica
    digSum[n_] := Plus @@ IntegerDigits[n]; smithQ[n_] := CompositeQ[n] && Plus @@ (Last@#*digSum[First@#] & /@ FactorInteger[n]) == digSum[n]; sm = smithQ /@ Range[3]; seq = {}; Do[sm = Join[Rest[sm], {smithQ[k]}]; If[And @@ sm, AppendTo[seq, k - 2]], {k, 4, 10^6}]; seq (* Amiram Eldar, Aug 18 2020 *)

Extensions

More terms from Amiram Eldar, Aug 18 2020

A105649 Smallest member of set of 4 consecutive numbers which are Smith numbers.

Original entry on oeis.org

4463535, 6356910, 8188933, 9425550, 11148564, 15966114, 15966115, 18542654, 21673542, 22821992, 23767287, 28605144, 36615667, 39227466, 47096634, 47395362, 48072396, 54054264, 55464835, 57484614, 57756450, 57761165, 58418508, 61843387, 62577157, 64572186, 65484066
Offset: 1

Views

Author

Shyam Sunder Gupta, May 03 2005

Keywords

Examples

			a(1) = 4463535 because 4463535 is the smallest member of a set of 4 consecutive numbers which are Smith numbers i.e. four consecutive numbers 4463535, 4463536, 4463537, 4463538 are all Smith numbers.
		

Crossrefs

Programs

  • Mathematica
    digSum[n_] := Plus @@ IntegerDigits[n]; smithQ[n_] := CompositeQ[n] && Plus @@ (Last @#* digSum[First@#] & /@ FactorInteger[n]) == digSum[n]; sm = smithQ /@ Range[4]; seq = {}; Do[sm = Join[Rest[sm], {smithQ[k]}]; If[And @@ sm, AppendTo[seq, k - 3]], {k, 5, 10^7}]; seq (* Amiram Eldar, Aug 18 2020 *)

Extensions

a(7) inserted and more terms added by Amiram Eldar, Aug 18 2020

A329935 Numbers k such that k and k+1 are both hoax numbers (A019506).

Original entry on oeis.org

84, 516, 644, 860, 2325, 3344, 4188, 4980, 5268, 5484, 6259, 6603, 6692, 6980, 7051, 7195, 8076, 8420, 9716, 10704, 11774, 12795, 12955, 12956, 13747, 14475, 14715, 14724, 16473, 17148, 17149, 17225, 17661, 19175, 21828, 22143, 22347, 24259, 24272, 24980
Offset: 1

Views

Author

Amiram Eldar, Nov 24 2019

Keywords

Comments

Analogous to A050219 (smaller of Smith brothers) as A019506 (hoax numbers) is analogous to A006753 (Smith numbers).

Examples

			84 is in the sequence since 84 is a hoax number: 84 = 2^2 * 3 * 7 and 8 + 4 = 2 + 3 + 7 = 12, and 85 = 84 + 1 is also a hoax number: 85 = 5 * 17 and 8 + 5 = 5 + 1 + 7 = 13.
		

Crossrefs

Programs

  • Mathematica
    digitSum[n_]  := Total @ IntegerDigits[n]; hoaxQ[n_] := CompositeQ[n] && Total[ digitSum /@ FactorInteger[n][[;; , 1]] ] == digitSum[n]; seq = {}; isHoax1 = hoaxQ[1]; Do[isHoax2 = hoaxQ[n]; If[isHoax1 && isHoax2, AppendTo[seq, n-1]]; isHoax1 = isHoax2, {n, 2, 25000}]; seq

A331463 Numbers k such that k and k + 1 are both binary hoax numbers (A329936).

Original entry on oeis.org

8, 15, 49, 50, 252, 489, 699, 725, 755, 799, 951, 979, 980, 988, 989, 1023, 1134, 1350, 1351, 1370, 1390, 1599, 1629, 1630, 1660, 1690, 1694, 1763, 1854, 1908, 1929, 1939, 1940, 1960, 2006, 2015, 2166, 2312, 2358, 2645, 2700, 2779, 2787, 2862, 2923, 2930, 2988
Offset: 1

Views

Author

Amiram Eldar, Jan 17 2020

Keywords

Examples

			8 is a term since both 8 and 8 + 1 = 9 are binary hoax numbers: 8 = 2^3 in binary representation is 1000 = 10^3 and 1 + 0 + 0 + 0 = 1 + 0, and 9 = 3^2 in binary representation is 1001 = 11^2 and 1 + 0 + 0 + 1 = 1 + 1.
		

Crossrefs

Programs

  • Magma
    hoax:=func; [k:k in [2..3000]|hoax(k) and hoax(k+1)]; // Marius A. Burtea, Jan 17 2020
  • Mathematica
    binWt[n_] := Total @ IntegerDigits[n, 2]; binHoaxQ[n_] := CompositeQ[n] && Total[binWt /@ FactorInteger[n][[;; , 1]]] == binWt[n]; seq = {}; isHoax1 = binHoaxQ[1]; Do[isHoax2 = binHoaxQ[n]; If[isHoax1 && isHoax2, AppendTo[seq, n-1]]; isHoax1 = isHoax2, {n, 2, 3000}]; seq
Showing 1-7 of 7 results.