login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A265705 Triangle read by rows: T(n,k) = k IMPL n, 0 <= k <= n, bitwise logical IMPL. 13
0, 1, 1, 3, 2, 3, 3, 3, 3, 3, 7, 6, 5, 4, 7, 7, 7, 5, 5, 7, 7, 7, 6, 7, 6, 7, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 15, 14, 13, 12, 11, 10, 9, 8, 15, 15, 15, 13, 13, 11, 11, 9, 9, 15, 15, 15, 14, 15, 14, 11, 10, 11, 10, 15, 14, 15, 15, 15, 15, 15, 11, 11, 11, 11, 15 (list; table; graph; refs; listen; history; text; internal format)
OFFSET

0,4

LINKS

Reinhard Zumkeller, Rows n = 0..255 of triangle, flattened

Eric Weisstein's World of Mathematics, Implies

FORMULA

T(n,0) = T(n,n) = A003817(n).

T(2*n,n) = A265716(n).

Let m = A089633(n): T(m,k) = T(m,m-k), k = 0..m.

Let m = A158582(n): T(m,k) != T(m,m-k) for at least one k <= n.

Let m = A247648(n): T(2*m,m) = 2*m.

For n > 0: A029578(n+2) = number of odd terms in row n; no even terms in odd-indexed rows.

A265885(n) = T(prime(n),n).

A053644(n) = smallest k such that row k contains n.

EXAMPLE

.          10 | 1010                            12 | 1100

.           4 |  100                             6 |  110

.   ----------+-----                     ----------+-----

.   4 IMPL 10 | 1011 -> T(10,4)=11       6 IMPL 12 | 1101 -> T(12,6)=13

.

First 16 rows of the triangle, where non-symmetrical rows are marked, see comment concerning A158582 and A089633:

.   0:                                 0

.   1:                               1   1

.   2:                             3   2   3

.   3:                           3   3   3   3

.   4:                         7   6   5   4   7    X

.   5:                       7   7   5   5   7   7

.   6:                     7   6   7   6   7   6   7

.   7:                   7   7   7   7   7   7   7   7

.   8:                15  14  13  12  11  10   9   8  15    X

.   9:              15  15  13  13  11  11   9   9  15  15    X

.  10:            15  14  15  14  11  10  11  10  15  14  15    X

.  11:          15  15  15  15  11  11  11  11  15  15  15  15

.  12:        15  14  13  12  15  14  13  12  15  14  13  12  15    X

.  13:      15  15  13  13  15  15  13  13  15  15  13  13  15  15

.  14:    15  14  15  14  15  14  15  14  15  14  15  14  15  14  15

.  15:  15  15  15  15  15  15  15  15  15  15  15  15  15  15  15  15 .

MAPLE

A265705 := (n, k) -> Bits:-Implies(k, n):

seq(seq(A265705(n, k), k=0..n), n=0..11); # Peter Luschny, Sep 23 2019

MATHEMATICA

T[n_, k_] := If[n == 0, 0, BitOr[2^Length[IntegerDigits[n, 2]]-1-k, n]];

Table[T[n, k], {n, 0, 11}, {k, 0, n}] // Flatten (* Jean-Fran├žois Alcover, Sep 25 2021, after David A. Corneth's PARI code *)

PROG

(Haskell)

a265705_tabl = map a265705_row [0..]

a265705_row n = map (a265705 n) [0..n]

a265705 n k = k `bimpl` n where

   bimpl 0 0 = 0

   bimpl p q = 2 * bimpl p' q' + if u <= v then 1 else 0

               where (p', u) = divMod p 2; (q', v) = divMod q 2

(PARI) T(n, k) = if(n==0, return(0)); bitor((2<<logint(n, 2))-1-k, n) \\ David A. Corneth, Sep 24 2021

(Julia)

using IntegerSequences

for n in 0:15 println(n == 0 ? [0] : [Bits("IMP", k, n) for k in 0:n]) end  # Peter Luschny, Sep 25 2021

CROSSREFS

Cf. A003817, A007088, A029578, A051933 (XOR), A080098 (OR), A080099 (AND), A089633, A158582, A247648, A265716 (central terms), A265736 (row sums).

Cf. A053644, A265885, A327490.

Sequence in context: A079790 A098726 A065801 * A205237 A086920 A182021

Adjacent sequences:  A265702 A265703 A265704 * A265706 A265707 A265708

KEYWORD

nonn,tabl,look

AUTHOR

Reinhard Zumkeller, Dec 15 2015

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified October 26 08:00 EDT 2021. Contains 348267 sequences. (Running on oeis4.)