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-10 of 13 results. Next

A324929 Numbers whose product of prime indices is even.

Original entry on oeis.org

3, 6, 7, 9, 12, 13, 14, 15, 18, 19, 21, 24, 26, 27, 28, 29, 30, 33, 35, 36, 37, 38, 39, 42, 43, 45, 48, 49, 51, 52, 53, 54, 56, 57, 58, 60, 61, 63, 65, 66, 69, 70, 71, 72, 74, 75, 76, 77, 78, 79, 81, 84, 86, 87, 89, 90, 91, 93, 95, 96, 98, 99, 101, 102, 104
Offset: 1

Views

Author

Gus Wiseman, Mar 21 2019

Keywords

Comments

A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798, with product A003963(n).
Also Heinz numbers of integer partitions whose product of parts is even (counted by A047967), where the Heinz number of an integer partition (y_1,...,y_k) is prime(y_1) * ... * prime(y_k).

Examples

			The sequence of terms together with their prime indices begins:
   3: {2}
   6: {1,2}
   7: {4}
   9: {2,2}
  12: {1,1,2}
  13: {6}
  14: {1,4}
  15: {2,3}
  18: {1,2,2}
  19: {8}
  21: {2,4}
  24: {1,1,1,2}
  26: {1,6}
  27: {2,2,2}
  28: {1,1,4}
  29: {10}
  30: {1,2,3}
  33: {2,5}
  35: {3,4}
  36: {1,1,2,2}
		

Crossrefs

Programs

  • Mathematica
    Select[Range[100],EvenQ[Times@@PrimePi/@If[#==1,{},FactorInteger[#]][[All,1]]]&]
  • PARI
    isok(n) = my(f=factor(n)[,1]); !(prod(k=1, #f, primepi(f[k])) % 2); \\ Michel Marcus, Mar 22 2019

A102378 a(n) = a(n-1) + a([n/2]) + 1, a(1) = 1.

Original entry on oeis.org

1, 3, 5, 9, 13, 19, 25, 35, 45, 59, 73, 93, 113, 139, 165, 201, 237, 283, 329, 389, 449, 523, 597, 691, 785, 899, 1013, 1153, 1293, 1459, 1625, 1827, 2029, 2267, 2505, 2789, 3073, 3403, 3733, 4123, 4513, 4963, 5413, 5937, 6461, 7059, 7657, 8349
Offset: 1

Views

Author

Mitch Harris, Jan 05 2005

Keywords

Comments

From Gus Wiseman, Mar 23 2019: (Start)
The offset could safely be changed to zero by setting the boundary condition to a(0) = 0.
Also the number of integer partitions of 2n into powers of 2 with at least one part > 1. The Heinz numbers of these partitions are given by A324927. For example, the a(1) = 1 through a(5) = 13 integer partitions are:
(2) (4) (42) (8) (82)
(22) (222) (44) (442)
(211) (411) (422) (811)
(2211) (2222) (4222)
(21111) (4211) (4411)
(22211) (22222)
(41111) (42211)
(221111) (222211)
(2111111) (421111)
(2221111)
(4111111)
(22111111)
(211111111)
(End)

Crossrefs

Programs

  • Mathematica
    Table[Length[Select[IntegerPartitions[n],And[Max@@#>1,And@@IntegerQ/@Log[2,#]]&]],{n,0,30,2}] (* Gus Wiseman, Mar 23 2019 *)
  • Python
    from itertools import islice
    from collections import deque
    def A102378_gen(): # generator of terms
        aqueue, f, b, a = deque([2]), True, 1, 2
        yield from (1, 3)
        while True:
            a += b
            yield 2*a - 1
            aqueue.append(a)
            if f: b = aqueue.popleft()
            f = not f
    A102378_list = list(islice(A102378_gen(),40)) # Chai Wah Wu, Jun 08 2022

Formula

a(n) - a(n-1) = A018819(n+1)
G.f. A(x) satisfies (1-x)*A(x) = 2(1 + x)*B(x^2), where B(x) is the gf of A033485
a(n) = A000123(n) - 1. - Gus Wiseman, Mar 23 2019
G.f. A(x) satisfies: A(x) = (x + (1 - x^2) * A(x^2)) / (1 - x)^2. - Ilya Gutkovskiy, Aug 11 2021

A366322 Heinz numbers of integer partitions containing at least one odd part. Numbers divisible by at least one prime of odd index.

Original entry on oeis.org

2, 4, 5, 6, 8, 10, 11, 12, 14, 15, 16, 17, 18, 20, 22, 23, 24, 25, 26, 28, 30, 31, 32, 33, 34, 35, 36, 38, 40, 41, 42, 44, 45, 46, 47, 48, 50, 51, 52, 54, 55, 56, 58, 59, 60, 62, 64, 65, 66, 67, 68, 69, 70, 72, 73, 74, 75, 76, 77, 78, 80, 82, 83, 84, 85, 86
Offset: 1

Views

Author

Gus Wiseman, Oct 14 2023

Keywords

Comments

The Heinz number of a partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k). This gives a bijective correspondence between positive integers and integer partitions.

Examples

			The terms together with their prime indices begin:
    2: {1}
    4: {1,1}
    5: {3}
    6: {1,2}
    8: {1,1,1}
   10: {1,3}
   11: {5}
   12: {1,1,2}
   14: {1,4}
   15: {2,3}
   16: {1,1,1,1}
   17: {7}
   18: {1,2,2}
   20: {1,1,3}
   22: {1,5}
   23: {9}
   24: {1,1,1,2}
		

Crossrefs

The complement is A066207, counted by A035363.
For all odd parts we have A066208, counted by A000009.
Partitions of this type are counted by A086543.
For even instead of odd we have A324929, counted by A047967.
A031368 lists primes of odd index.
A112798 list prime indices, sum A056239.
A257991 counts odd prime indices, distinct A324966.

Programs

  • Mathematica
    Select[Range[100],Or@@OddQ/@PrimePi/@First/@FactorInteger[#]&]

Formula

A257991(a(n)) > 0.

A325094 Write n as a sum of distinct powers of 2, then take the primes of those powers of 2 and multiply them together.

Original entry on oeis.org

1, 2, 3, 6, 7, 14, 21, 42, 19, 38, 57, 114, 133, 266, 399, 798, 53, 106, 159, 318, 371, 742, 1113, 2226, 1007, 2014, 3021, 6042, 7049, 14098, 21147, 42294, 131, 262, 393, 786, 917, 1834, 2751, 5502, 2489, 4978, 7467, 14934, 17423, 34846, 52269, 104538, 6943
Offset: 0

Views

Author

Gus Wiseman, Mar 27 2019

Keywords

Comments

The sorted sequence is A325093.
For example, 11 = 1 + 2 + 8, so a(11) = prime(1) * prime(2) * prime(8) = 114.

Examples

			The sequence of terms together with their prime indices begins:
    1: {}
    2: {1}
    3: {2}
    6: {1,2}
    7: {4}
   14: {1,4}
   21: {2,4}
   42: {1,2,4}
   19: {8}
   38: {1,8}
   57: {2,8}
  114: {1,2,8}
  133: {4,8}
  266: {1,4,8}
  399: {2,4,8}
  798: {1,2,4,8}
   53: {16}
  106: {1,16}
  159: {2,16}
  318: {1,2,16}
  371: {4,16}
		

Crossrefs

Programs

  • Maple
    P:= [seq(ithprime(2^i),i=0..10)]:
    f:= proc(n) local L,i;
      L:= convert(n,base,2);
      mul(P[i]^L[i],i=1..nops(L))
    end proc:
    map(f, [$0..100]); # Robert Israel, Mar 28 2019
  • Mathematica
    Table[Times@@MapIndexed[If[#1==0,1,Prime[2^(#2[[1]]-1)]]&,Reverse[IntegerDigits[n,2]]],{n,0,100}]

A324927 Matula-Goebel numbers of rooted trees of depth 2. Numbers that are not powers of 2 but whose prime indices are all powers of 2.

Original entry on oeis.org

3, 6, 7, 9, 12, 14, 18, 19, 21, 24, 27, 28, 36, 38, 42, 48, 49, 53, 54, 56, 57, 63, 72, 76, 81, 84, 96, 98, 106, 108, 112, 114, 126, 131, 133, 144, 147, 152, 159, 162, 168, 171, 189, 192, 196, 212, 216, 224, 228, 243, 252, 262, 266, 288, 294, 304, 311, 318
Offset: 1

Views

Author

Gus Wiseman, Mar 21 2019

Keywords

Comments

Numbers n such that A109082(n) = 2.
A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.
Also Heinz numbers of integer partitions into powers of 2 with at least one part > 1 (counted by A102378).

Examples

			The sequence of terms together with their prime indices begins:
   3: {2}
   6: {1,2}
   7: {4}
   9: {2,2}
  12: {1,1,2}
  14: {1,4}
  18: {1,2,2}
  19: {8}
  21: {2,4}
  24: {1,1,1,2}
  27: {2,2,2}
  28: {1,1,4}
  36: {1,1,2,2}
  38: {1,8}
  42: {1,2,4}
  48: {1,1,1,1,2}
  49: {4,4}
  53: {16}
  54: {1,2,2,2}
  56: {1,1,1,4}
		

Crossrefs

Programs

  • Mathematica
    Select[Range[100],And[!IntegerQ[Log[2,#]],And@@Cases[FactorInteger[#],{p_,_}:>IntegerQ[Log[2,PrimePi[p]]]]]&]

A324928 Matula-Goebel numbers of rooted trees of depth 3.

Original entry on oeis.org

5, 10, 13, 15, 17, 20, 23, 25, 26, 30, 34, 35, 37, 39, 40, 43, 45, 46, 50, 51, 52, 60, 61, 65, 67, 68, 69, 70, 73, 74, 75, 78, 80, 85, 86, 89, 90, 91, 92, 95, 100, 102, 103, 104, 105, 107, 111, 115, 117, 119, 120, 122, 125, 129, 130, 134, 135, 136, 138, 140
Offset: 1

Views

Author

Gus Wiseman, Mar 21 2019

Keywords

Comments

Numbers n such that A109082(n) = 3.

Examples

			The sequence of all rooted trees of depth 3 together with their Matula-Goebel numbers begins:
   5: (((o)))
  10: (o((o)))
  13: ((o(o)))
  15: ((o)((o)))
  17: (((oo)))
  20: (oo((o)))
  23: (((o)(o)))
  25: (((o))((o)))
  26: (o(o(o)))
  30: (o(o)((o)))
  34: (o((oo)))
  35: (((o))(oo))
  37: ((oo(o)))
  39: ((o)(o(o)))
  40: (ooo((o)))
  43: ((o(oo)))
  45: ((o)(o)((o)))
  46: (o((o)(o)))
  50: (o((o))((o)))
  51: ((o)((oo)))
  52: (oo(o(o)))
  60: (oo(o)((o)))
		

Crossrefs

Programs

  • Mathematica
    Select[Range[100],Length[NestWhileList[Times@@PrimePi/@FactorInteger[#][[All,1]]&,#,#>1&]]-1==3&]

A325093 Heinz numbers of integer partitions into distinct powers of 2.

Original entry on oeis.org

1, 2, 3, 6, 7, 14, 19, 21, 38, 42, 53, 57, 106, 114, 131, 133, 159, 262, 266, 311, 318, 371, 393, 399, 622, 719, 742, 786, 798, 917, 933, 1007, 1113, 1438, 1619, 1834, 1866, 2014, 2157, 2177, 2226, 2489, 2751, 3021, 3238, 3671, 4314, 4354, 4857, 4978, 5033
Offset: 1

Views

Author

Gus Wiseman, Mar 27 2019

Keywords

Comments

The Heinz number of an integer partition (y_1,...,y_k) is prime(y_1) * ... * prime(y_k), so these are squarefree numbers whose prime indices are powers of 2. A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.

Examples

			The sequence of terms together with their prime indices begins:
    1: {}
    2: {1}
    3: {2}
    6: {1,2}
    7: {4}
   14: {1,4}
   19: {8}
   21: {2,4}
   38: {1,8}
   42: {1,2,4}
   53: {16}
   57: {2,8}
  106: {1,16}
  114: {1,2,8}
  131: {32}
  133: {4,8}
  159: {2,16}
  262: {1,32}
  266: {1,4,8}
  311: {64}
		

Crossrefs

Programs

  • Maple
    P:= [seq(ithprime(2^i),i=0..20)]:f:= proc(S,N) option remember;
      if S = [] or S[1]>N then return {1} fi;
      procname(S[2..-1],N) union
        map(t -> S[1]*t, procname(S[2..-1], floor(N/S[1])))end proc:
    sort(convert(f(P, P[20]),list));  # Robert Israel, Mar 28 2019
  • Mathematica
    Select[Range[1000],SquareFreeQ[#]&&And@@IntegerQ/@Log[2,Cases[If[#==1,{},FactorInteger[#]],{p_,_}:>PrimePi[p]]]&]
  • PARI
    isp2(q) = (q == 1) || (q == 2) || (ispower(q,,&p) && (p==2));
    isok(n) = {if (issquarefree(n), my(f=factor(n)[,1]); for (k=1, #f, if (! isp2(primepi(f[k])), return (0));); return (1);); return (0);} \\ Michel Marcus, Mar 28 2019

A325091 Heinz numbers of integer partitions of powers of 2.

Original entry on oeis.org

1, 2, 3, 4, 7, 9, 10, 12, 16, 19, 34, 39, 49, 52, 53, 55, 63, 66, 70, 75, 81, 84, 88, 90, 94, 100, 108, 112, 120, 129, 131, 144, 160, 172, 192, 205, 246, 254, 256, 259, 311, 328, 333, 339, 341, 361, 370, 377, 391, 434, 444, 452, 465, 545, 558, 592, 598, 609, 614
Offset: 1

Views

Author

Gus Wiseman, Mar 27 2019

Keywords

Comments

The Heinz number of an integer partition (y_1,...,y_k) is prime(y_1) * ... * prime(y_k), so these are numbers whose sum of prime indices is a power of 2. A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.
1 is in the sequence because it has prime indices {} with sum 0 = 2^(-infinity).

Examples

			The sequence of terms together with their prime indices begins:
   1: {}
   2: {1}
   3: {2}
   4: {1,1}
   7: {4}
   9: {2,2}
  10: {1,3}
  12: {1,1,2}
  16: {1,1,1,1}
  19: {8}
  34: {1,7}
  39: {2,6}
  49: {4,4}
  52: {1,1,6}
  53: {16}
  55: {3,5}
  63: {2,2,4}
  66: {1,2,5}
  70: {1,3,4}
  75: {2,3,3}
  81: {2,2,2,2}
		

Crossrefs

Programs

  • Maple
    q:= n-> (t-> t=2^ilog2(t))(add(numtheory[pi](i[1])*i[2], i=ifactors(n)[2])):
    select(q, [$1..1000])[];  # Alois P. Heinz, Mar 28 2019
  • Mathematica
    Select[Range[100],#==1||IntegerQ[Log[2,Total[Cases[FactorInteger[#],{p_,k_}:>k*PrimePi[p]]]]]&]

A325092 Heinz numbers of integer partitions of powers of 2 into powers of 2.

Original entry on oeis.org

1, 2, 3, 4, 7, 9, 12, 16, 19, 49, 53, 63, 81, 84, 108, 112, 131, 144, 192, 256, 311, 361, 719, 931, 1197, 1539, 1596, 1619, 2052, 2128, 2401, 2736, 2809, 3087, 3648, 3671, 3969, 4116, 4864, 5103, 5292, 5488, 6561, 6804, 7056, 8161, 8748, 9072, 9408, 11664, 12096
Offset: 1

Views

Author

Gus Wiseman, Mar 27 2019

Keywords

Comments

The Heinz number of an integer partition (y_1,...,y_k) is prime(y_1) * ... * prime(y_k), so these are numbers whose prime indices are powers of 2 and whose sum of prime indices is also a power of 2. A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.
1 is in the sequence because it has prime indices {} with sum 0 = 2^(-infinity).

Examples

			The sequence of terms together with their prime indices begins:
    1: {}
    2: {1}
    3: {2}
    4: {1,1}
    7: {4}
    9: {2,2}
   12: {1,1,2}
   16: {1,1,1,1}
   19: {8}
   49: {4,4}
   53: {16}
   63: {2,2,4}
   81: {2,2,2,2}
   84: {1,1,2,4}
  108: {1,1,2,2,2}
  112: {1,1,1,1,4}
  131: {32}
  144: {1,1,1,1,2,2}
  192: {1,1,1,1,1,1,2}
  256: {1,1,1,1,1,1,1,1}
  311: {64}
		

Crossrefs

Programs

  • Maple
    q:= n-> andmap(t-> t=2^ilog2(t), (l-> [l[], add(i, i=l)])(
          map(i-> numtheory[pi](i[1])$i[2], ifactors(n)[2]))):
    select(q, [$1..15000])[];  # Alois P. Heinz, Mar 28 2019
  • Mathematica
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    pow2Q[n_]:=IntegerQ[Log[2,n]];
    Select[Range[1000],#==1||pow2Q[Total[primeMS[#]]]&&And@@pow2Q/@primeMS[#]&]

A371449 Numbers whose prime indices are not powers of 2.

Original entry on oeis.org

1, 5, 11, 13, 17, 23, 25, 29, 31, 37, 41, 43, 47, 55, 59, 61, 65, 67, 71, 73, 79, 83, 85, 89, 97, 101, 103, 107, 109, 113, 115, 121, 125, 127, 137, 139, 143, 145, 149, 151, 155, 157, 163, 167, 169, 173, 179, 181, 185, 187, 191, 193, 197, 199, 205, 211, 215
Offset: 1

Views

Author

Gus Wiseman, Mar 31 2024

Keywords

Comments

A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.

Examples

			The terms together with their prime indices begin:
     1: {}        85: {3,7}      169: {6,6}     253: {5,9}
     5: {3}       89: {24}       173: {40}      257: {55}
    11: {5}       97: {25}       179: {41}      263: {56}
    13: {6}      101: {26}       181: {42}      269: {57}
    17: {7}      103: {27}       185: {3,12}    271: {58}
    23: {9}      107: {28}       187: {5,7}     275: {3,3,5}
    25: {3,3}    109: {29}       191: {43}      277: {59}
    29: {10}     113: {30}       193: {44}      281: {60}
    31: {11}     115: {3,9}      197: {45}      283: {61}
    37: {12}     121: {5,5}      199: {46}      289: {7,7}
    41: {13}     125: {3,3,3}    205: {3,13}    293: {62}
    43: {14}     127: {31}       211: {47}      295: {3,17}
    47: {15}     137: {33}       215: {3,14}    299: {6,9}
    55: {3,5}    139: {34}       221: {6,7}     305: {3,18}
    59: {17}     143: {5,6}      223: {48}      307: {63}
    61: {18}     145: {3,10}     227: {49}      313: {65}
    65: {3,6}    149: {35}       229: {50}      317: {66}
    67: {19}     151: {36}       233: {51}      319: {5,10}
    71: {20}     155: {3,11}     235: {3,15}    325: {3,3,6}
    73: {21}     157: {37}       239: {52}      331: {67}
    79: {22}     163: {38}       241: {53}      335: {3,19}
    83: {23}     167: {39}       251: {54}      337: {68}
		

Crossrefs

Partitions of this type are counted by A101417.
For binary indices instead of prime indices we have A326781.
Requiring powers of two gives A318400, for binary indices A253317.
An opposite version is A371443.
For primes instead of powers of 2 we have A320628.
A000040 lists prime numbers, complement A018252.
A000961 lists prime-powers.
A048793 lists binary indices, reverse A272020, length A000120, sum A029931.
A057716 lists non-powers of 2.
A070939 gives length of binary expansion.
A112798 lists prime indices, reverse A296150, length A001222, sum A056239.

Programs

  • Mathematica
    Select[Range[100],And@@Not/@IntegerQ/@Log[2, PrimePi/@First/@FactorInteger[#]]&]
Showing 1-10 of 13 results. Next