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.

Previous Showing 11-20 of 21 results. Next

A006755 The generalized Conway-Guy sequence w^{1}.

Original entry on oeis.org

0, 2, 3, 4, 8, 14, 25, 47, 86, 164, 314, 603, 1159, 2271, 4456, 8748, 17182, 33761, 66919, 132679, 263087
Offset: 0

Views

Author

Keywords

Comments

See Lunnon for precise definition.

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

The sequences in Lunnon's Table 1 are A005318, A006754, A006755, A006756, A006757, A195683, A195684.

A006756 The generalized Conway-Guy sequence w^{2}.

Original entry on oeis.org

0, 4, 5, 6, 8, 16, 27, 49, 92, 168, 320, 613, 1177, 2262, 4432, 8696, 17072, 33531, 65885, 130593, 258924
Offset: 0

Views

Author

Keywords

Comments

See Lunnon for precise definition.

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

The sequences in Lunnon's Table 1 are A005318, A006754, A006755, A006756, A006757, A195683, A195684.

A006757 The generalized Conway-Guy sequence w^{3}.

Original entry on oeis.org

0, 8, 10, 11, 12, 16, 32, 54, 97, 183, 334, 636, 1218, 2339, 4495, 8807, 17280, 33924, 66630, 130921, 259503
Offset: 0

Views

Author

Keywords

Comments

See Lunnon for precise definition.

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

The sequences in Lunnon's Table 1 are A005318, A006754, A006755,A006756, A006757, A195683, A195684.

A195683 The generalized Conway-Guy sequence w^{4}.

Original entry on oeis.org

0, 16, 20, 21, 22, 24, 32, 64, 107, 193, 364, 664, 1264, 2421, 4649, 8934, 17504, 34344, 67424, 132427, 260205
Offset: 0

Views

Author

N. J. A. Sloane, Sep 22 2011

Keywords

Comments

See Lunnon for precise definition.

Crossrefs

The sequences in Lunnon's Table 1 are A005318, A006754, A006755, A006756, A006757, A195683, A195684.

A195684 The generalized Conway-Guy sequence w^{-6}.

Original entry on oeis.org

0, 5, 9, 10, 11, 18, 31, 57, 104, 192, 366, 701, 1353, 2649, 5194, 10196, 20026, 39686, 79006, 157316, 313279
Offset: 0

Views

Author

N. J. A. Sloane, Sep 22 2011

Keywords

Comments

See Lunnon for precise definition.

Crossrefs

The sequences in Lunnon's Table 1 are A005318, A006754, A006755, A006756, A006757, A195683, A195684.

A037254 Triangle read by rows: T(n,k) (n >= 1, 1 <= k< = n) gives number of non-distorting tie-avoiding integer vote weights.

Original entry on oeis.org

1, 1, 2, 2, 3, 4, 3, 5, 6, 7, 6, 9, 11, 12, 13, 11, 17, 20, 22, 23, 24, 22, 33, 39, 42, 44, 45, 46, 42, 64, 75, 81, 84, 86, 87, 88, 84, 126, 148, 159, 165, 168, 170, 171, 172, 165, 249, 291, 313, 324, 330, 333, 335, 336, 337, 330, 495, 579, 621, 643, 654, 660, 663, 665
Offset: 1

Views

Author

Keywords

Comments

T(n,1) = T(n,floor(n/2)+1) = A002083(n+2). - Reinhard Zumkeller, Nov 18 2012

Examples

			Triangle:
  1;
  1,  2;
  2,  3,  4;
  3,  5,  6,  7;
  6,  9, 11, 12, 13;
  ...
		

References

  • Author?, Solution to Board of Directors Problem, J. Rec. Math., 9 (No. 3, 1977), 240.
  • T. V. Narayana, Lattice Path Combinatorics with Statistical Applications. Univ. Toronto Press, 1979, pp. 100-101.

Crossrefs

Row sums give A005254. A002083 is a column. See also A005318, A096858.

Programs

  • Haskell
    a037254 n k = a037254_tabl !! (n-1) !! (k-1)
    a037254_row n = a037254_tabl !! (n-1)
    a037254_tabl = map fst $ iterate f ([1], drop 2 a002083_list) where
       f (row, (x:xs)) = (map (+ x) (0 : row), xs)
    -- Reinhard Zumkeller, Nov 18 2012
    
  • Mathematica
    a[1, 1] = 1; a[n_, 1] := a[n, 1] = a[n - 1, Floor[(n + 1)/2]]; a[n_, k_ /; k > 1] := a[n, k] = a[n, 1] + a[n - 1, k - 1]; A037254 = Flatten[ Table[ a[n, k], {n, 1, 11}, {k, 1, n}]] (* Jean-François Alcover, Apr 03 2012, after given recurrence *)
  • Python
    def T(n, k):
        if k==1:
            if n==1: return 1
            else: return T(n - 1, (n + 1)//2)
        return T(n, 1) + T(n - 1, k - 1)
    for n in range(1, 12): print([T(n, k) for k in range(1, n + 1)]) # Indranil Ghosh, Jun 03 2017

Formula

T(1,1) = 1;
T(n,1) = T(n-1, floor((n+1)/2));
T(n,k) = T(n,1) + T(n-1,k-1) for k > 1.

Extensions

More terms from (and formula corrected by) James Sellers, Feb 04 2000

A201052 a(n) is the maximal number c of integers that can be chosen from {1,2,...,n} so that all 2^c subsets have distinct sums.

Original entry on oeis.org

1, 2, 2, 3, 3, 3, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8
Offset: 1

Views

Author

N. J. A. Sloane, Nov 26 2011

Keywords

Comments

In the count 2^c of the cardinality of subsets of a set with cardinality c, the empty set - with sum 0 - is included; 2^c is just the row sum of the c-th row in the Pascal triangle.
Conjecture (confirmed through k=7): a(n)=k for all n in the interval A005318(k) <= n < A005318(k+1). - Jon E. Schoenfield, Nov 28 2013 [Note: This conjecture is false; see A276661 for a counterexample (n=34808712605260918463) in which n is in the interval A005318(66) <= n < A005318(67), yet a(n)=67, not 66. - Jon E. Schoenfield, Nov 05 2016]
A276661 is the main entry for the distinct subset sums problem. - N. J. A. Sloane, Apr 24 2024

Examples

			Numbers n and an example of a subset of {1..n} exhibiting the maximum cardinality c=a(n):
1, {1}
2, {1, 2}
3, {1, 2}
4, {1, 2, 4}
5, {1, 2, 4}
6, {1, 2, 4}
7, {3, 5, 6, 7}
8, {1, 2, 4, 8}
9, {1, 2, 4, 8}
10, {1, 2, 4, 8}
11, {1, 2, 4, 8}
12, {1, 2, 4, 8}
13, {3, 6, 11, 12, 13}
14, {1, 6, 10, 12, 14}
15, {1, 6, 10, 12, 14}
16, {1, 2, 4, 8, 16}
17, {1, 2, 4, 8, 16}
18, {1, 2, 4, 8, 16}
For examples of maximum-cardinality subsets at values of n where a(n) > a(n-1), see A096858. - _Jon E. Schoenfield_, Nov 28 2013
		

Crossrefs

Programs

  • Maple
    # is any subset of L uniquely determined by its total weight?
    iswts := proc(L)
        local wtset,s,c,subL,thiswt ;
        # the weight sums are to be unique, so sufficient to remember the set
        wtset := {} ;
        # loop over all subsets of weights generated by L
        for s from 1 to nops(L) do
            c := combinat[choose](L,s) ;
            for subL in c do
                # compute the weight sum in this subset
                thiswt := add(i,i=subL) ;
                # if this weight sum already appeared: not a candidate
                if thiswt in wtset then
                    return false;
                else
                    wtset := wtset union {thiswt} ;
                end if;
            end do:
        end do:
        # All different subset weights were different: success
        return true;
    end proc:
    # main sequence: given grams 1 to n, determine a subset L
    # such that each subset of this subset has a different sum.
    wts := proc(n)
        local s,c,L ;
        # select sizes from n (largest size first) down to 1,
        # so the largest is detected first as required by the puzzle.
        for s from n to 1 by -1 do
            # all combinations of subsets of s different grams
            c := combinat[choose]([seq(i,i=1..n)],s) ;
            for L in c do
                # check if any of these meets the requir, print if yes
                # and return
                if iswts(L) then
                    print(n,L) ;
                    return nops(L) ;
                end if;
            end do:
        end do:
        print(n,"-") ;
    end proc:
    # loop for weights with maximum n
    for n from 1 do
        wts(n) ;
    end do: # R. J. Mathar, Aug 24 2010

Extensions

More terms from Alois P. Heinz, Nov 27 2011
More terms from Jon E. Schoenfield, Nov 28 2013

A096796 a(n) = n for n <= 2; for n > 2, a(n) = 2a(n-1) - a(n - floor( 1/2 + sqrt(2n) )).

Original entry on oeis.org

0, 1, 2, 3, 5, 8, 13, 23, 41, 74, 135, 257, 491, 941, 1808, 3481, 6827, 13397, 26303, 51665, 101522, 199563, 395645, 784463, 1555529, 3084755, 6117845, 12134168, 24068773, 47937983, 95480321, 190176179, 378796829, 754508903, 1502899961
Offset: 0

Views

Author

N. J. A. Sloane, Aug 17 2004

Keywords

Crossrefs

Programs

  • Haskell
    a096796 n = a096796_list !! n
    a096796_list = 0 : 1 : zipWith (-)
       (map (* 2) $ tail a096796_list) (map a096796 $ tail a083920_list)
    -- Reinhard Zumkeller, Feb 12 2012
  • Mathematica
    a[n_] := a[n] = If[n < 3, a[n] = n, 2a[n - 1] - a[n - Floor[1/2 + Sqrt[2n]] ]]; Table[ a[n], {n, 0, 35}] (* Robert G. Wilson v *)
  • PARI
    {m=35;v=vector(m+1);for(n=0,m,if(n<=2,a=n,k=n-floor(1/2+sqrt(2*n));a=2*v[n]-v[k+1]);v[n+1]=a;print1(a,","))} \\ Klaus Brockhaus, Aug 20 2004
    

Extensions

More terms from Klaus Brockhaus and Robert G. Wilson v, Aug 20 2004

A096824 a(n) = n for n <= 2; for n > 2, a(n) = 2a(n-1) - a(n - floor(1/2 + sqrt(2(n-1)))).

Original entry on oeis.org

0, 1, 2, 3, 4, 6, 9, 14, 24, 42, 75, 136, 258, 492, 942, 1809, 3482, 6828, 13398, 26304, 51666, 101523, 199564, 395646, 784464, 1555530, 3084756, 6117846, 12134169, 24068774, 47937984, 95480322, 190176180, 378796830, 754508904, 1502899962
Offset: 0

Views

Author

N. J. A. Sloane, Aug 17 2004

Keywords

Crossrefs

Programs

  • Haskell
    a096824 n = a096824_list !! n
    a096824_list = 0 : 1 : 2 : zipWith (-)
       (map (* 2) $ drop 2 a096824_list) (map a096824 $ tail a122797_list)
    -- Reinhard Zumkeller, Feb 12 2012
  • Mathematica
    a[n_] := a[n] = If[n < 3, a[n] = n, 2a[n - 1] - a[n - Floor[1/2 + Sqrt[2(n - 1)]]]]; Table[ a[n], {n, 0, 35}] (* Robert G. Wilson v, Aug 20 2004 *)
  • PARI
    {m=36;v=vector(m+1);for(n=0,m,if(n<=2,a=n,k=n-floor(1/2+sqrt(2*(n-1)));a=2*v[n]-v[k+1]);v[n+1]=a;print1(a,","))} \\ Klaus Brockhaus, Aug 20 2004
    

Extensions

More terms from Klaus Brockhaus and Robert G. Wilson v, Aug 20 2004

A349777 Lexicographically first sequence of positive integers such that all disjoint equivalent sets of K terms have distinct sums for 1 <= K <= 4.

Original entry on oeis.org

1, 2, 3, 5, 8, 14, 25, 45, 85, 162, 310, 595, 1107, 2052, 3515, 5925, 9798, 16169, 23295, 34303, 53259, 72215, 112624, 153552, 198523, 283570, 370114, 497383, 700022, 840817, 1145415, 1398434, 1717972, 2279969, 2819186, 3436864, 4299205, 5239007, 6335442, 7650495, 9219214
Offset: 1

Views

Author

Santanu Banerjee, Nov 29 2021

Keywords

Crossrefs

Cf. A011185 (k=1..2), A036241 (k=1..3).
A005318 and A276661 are similar sequences.

Programs

  • Mathematica
    a={};k=1;Do[While[(t=1;While[t<=4&&DuplicateFreeQ[Total/@Subsets[Join[a,{k}],{t}]],t++];t)<=4,k++];AppendTo[a,k];Print@k,30] (* Giorgos Kalogeropoulos, Dec 02 2021 *)
  • Python
    # See links.

Extensions

a(13)-a(26) from Alois P. Heinz, Dec 01 2021
a(27)-a(41) from Gleb Ivanov, Dec 02 2021
Previous Showing 11-20 of 21 results. Next