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 16 results. Next

A153829 Index sequence to A089840: positions of bijections that preserve A153835, or equivalently, A127302 (the non-oriented form of binary trees).

Original entry on oeis.org

0, 1, 3, 7, 15, 21, 27, 46, 68, 73, 74, 83, 84, 87, 88, 92, 114, 149, 169, 183, 184, 189, 190, 199, 202, 203, 225, 251, 252, 254, 261, 262, 268, 269, 270, 271, 299, 400, 515, 537, 539, 573, 575, 591, 593, 638, 753, 871, 894, 895, 990, 995, 996, 1110, 1132
Offset: 0

Views

Author

Antti Karttunen, Jan 07 2009

Keywords

Comments

These elements form a subgroup in A089840 (A089839). Such elements consists of only such clauses where each vertex stays at the same distance from the root of the binary tree and in the image tree will still be sibling to its original sibling in the pre-image tree.
Because A127302 can be computed as a fold and most of the recursive derivations of A089840 (i.e. tables A122201-A122204, A122283-A122290, A130400-A130403) are also folds, this sequence gives also the indices to those derived tables where bijections preserving A127302 occur.

Crossrefs

Superset of A153830. Apart from 0, has no other elements common with A153826. Cf. also A153831, A153827, A153829, A153832, A153833.

A153830 Index sequence to A089840: positions of bijections that preserve A127302 (the non-oriented form of binary trees) and whose behavior does not depend on whether there are internal or terminal nodes (leaves) in the neighborhood of any vertex.

Original entry on oeis.org

0, 1, 3, 7, 15, 21, 27, 46, 92, 114, 149, 169, 225, 251, 299, 400, 638, 753, 1233, 1348, 1705, 1823, 1992, 2097, 2335, 2451, 2995, 3128, 3485, 3607, 3677, 3771, 4214, 4307, 4631, 5254, 6692, 7393, 10287, 10988, 13145, 13860, 20353, 21054
Offset: 0

Views

Author

Antti Karttunen, Jan 07 2009

Keywords

Comments

These elements form a subgroup in A089840 (A089839) isomorphic to a group consisting of all finitely iterated wreath products of the form S_2 wr S_2 wr ... wr S_2 and each is an image of some finitary automorphism of an infinite binary tree. E.g. A089840(1) = *A069770 is an image of the generator A of Grigorchuk Group. See comments at A153246 and A153141.
The defining properties are propagated by all recursive transformations of A089840 which themselves do not behave differently depending whether there are internal or terminal vertices in the neighborhood of any vertex (at least the ones given in A122201-A122204, A122283-A122290, A130400-A130403), so this sequence gives also the corresponding positions in those tables.

Crossrefs

A057163 Signature-permutation of a Catalan automorphism: Reflect a rooted plane binary tree; Deutsch's 1998 involution on Dyck paths.

Original entry on oeis.org

0, 1, 3, 2, 8, 7, 6, 5, 4, 22, 21, 20, 18, 17, 19, 16, 15, 13, 12, 14, 11, 10, 9, 64, 63, 62, 59, 58, 61, 57, 55, 50, 49, 54, 48, 46, 45, 60, 56, 53, 47, 44, 52, 43, 41, 36, 35, 40, 34, 32, 31, 51, 42, 39, 33, 30, 38, 29, 27, 26, 37, 28, 25, 24, 23, 196, 195, 194, 190, 189
Offset: 0

Views

Author

Antti Karttunen, Aug 18 2000

Keywords

Comments

Deutsch shows in his 1999 paper that this automorphism maps the number of doublerises of Dyck paths to number of valleys and height of the first peak to the number of returns, i.e., that A126306(n) = A127284(a(n)) and A126307(n) = A057515(a(n)) hold for all n.
The A000108(n-2) n-gon triangularizations can be reflected over n axes of symmetry, which all can be generated by appropriate compositions of the permutations A057161/A057162 and A057163.
Composition with A057164 gives signature permutation for Donaghey's Map M (A057505/A057506). Embeds into itself in scale n:2n+1 as a(n) = A083928(a(A080298(n))). A127302(a(n)) = A127302(n) and A057123(A057163(n)) = A057164(A057123(n)) hold for all n.

Examples

			This involution (self-inverse permutation) of natural numbers is induced when we reflect the rooted plane binary trees encoded by A014486. E.g., we have A014486(5) = 44 (101100 in binary), A014486(7) = 52 (110100 in binary) and these encode the following rooted plane binary trees, which are reflections of each other:
    0   0             0   0
     \ /               \ /
      1   0         0   1
       \ /           \ /
    0   1             1   0
     \ /               \ /
      1                 1
thus a(5)=7 and a(7)=5.
		

Crossrefs

This automorphism conjugates between the car/cdr-flipped variants of other automorphisms, e.g., A057162(n) = a(A057161(a(n))), A069768(n) = a(A069767(a(n))), A069769(n) = a(A057508(a(n))), A069773(n) = a(A057501(a(n))), A069774(n) = a(A057502(a(n))), A069775(n) = a(A057509(a(n))), A069776(n) = a(A057510(a(n))), A069787(n) = a(A057164(a(n))).
Row 1 of tables A122201 and A122202, that is, obtained with FORK (and KROF) transformation from even simpler automorphism *A069770. Cf. A122351.

Programs

  • Maple
    a(n) = A080300(ReflectBinTree(A014486(n)))
    ReflectBinTree := n -> ReflectBinTree2(n)/2; ReflectBinTree2 := n -> (`if`((0 = n),n,ReflectBinTreeAux(A030101(n))));
    ReflectBinTreeAux := proc(n) local a,b; a := ReflectBinTree2(BinTreeLeftBranch(n)); b := ReflectBinTree2(BinTreeRightBranch(n)); RETURN((2^(A070939(b)+A070939(a))) + (b * (2^(A070939(a)))) + a); end;
    NextSubBinTree := proc(nn) local n,z,c; n := nn; c := 0; z := 0; while(c < 1) do z := 2*z + (n mod 2); c := c + (-1)^n; n := floor(n/2); od; RETURN(z); end;
    BinTreeLeftBranch := n -> NextSubBinTree(floor(n/2));
    BinTreeRightBranch := n -> NextSubBinTree(floor(n/(2^(1+A070939(BinTreeLeftBranch(n))))));
  • Mathematica
    A014486Q[0] = True; A014486Q[n_] := Catch[Fold[If[# < 0, Throw[False], If[#2 == 0, # - 1, # + 1]] &, 0, IntegerDigits[n, 2]] == 0]; tree[n_] := Block[{func, num = Append[IntegerDigits[n, 2], 0]}, func := If[num[[1]] == 0, num = Drop[num, 1]; 0, num = Drop[num, 1]; 1[func, func]]; func]; A057163L[n_] := Function[x, FirstPosition[x, FromDigits[Most@Cases[tree[#] /. 1 -> Reverse@*1, 0 | 1, All, Heads -> True], 2]][[1]] - 1 & /@ x][Select[Range[0, 2^n], A014486Q]]; A057163L[11] (* JungHwan Min, Dec 11 2016 *)

Formula

a(n) = A083927(A057164(A057123(n))).

Extensions

Equivalence with Deutsch's 1998 involution realized Dec 15 2006 and entry edited accordingly by Antti Karttunen, Jan 16 2007

A069770 Signature permutation of the first non-identity, nonrecursive Catalan automorphism in table A089840: swap the top branches of a binary tree. An involution of nonnegative integers.

Original entry on oeis.org

0, 1, 3, 2, 7, 8, 6, 4, 5, 17, 18, 20, 21, 22, 16, 19, 14, 9, 10, 15, 11, 12, 13, 45, 46, 48, 49, 50, 54, 55, 57, 58, 59, 61, 62, 63, 64, 44, 47, 53, 56, 60, 42, 51, 37, 23, 24, 38, 25, 26, 27, 43, 52, 39, 28, 29, 40, 30, 31, 32, 41, 33, 34, 35, 36, 129, 130, 132, 133, 134
Offset: 0

Views

Author

Antti Karttunen, Apr 16 2002

Keywords

Comments

This is the simplest possible Catalan automorphism after the identity bijection (A001477). It effects the following transformation on the unlabeled rooted plane binary trees (letters A and B refer to arbitrary subtrees located on those vectices):
A B B A
\ / --> \ /
x x
(a . b) -----> (b . a)
Applying this permutation recursively to the right hand side branch of the binary trees produces permutations A069767 and A069768 (that occur at the same index 1 in tables A122203 and A122204), and applying this recursively to the both branches of binary trees (as in pre- or postorder traversal) produces A057163 (which occurs at the same index 1 in tables A122201 and A122202) that reflects the whole binary tree.
For this permutation, A127302(a(n)) = A127302(n) for all n, [or equally, A153835(a(n)) = A153835(n)], and likewise for all such recursive derivations as mentioned above.

Examples

			To obtain the signature permutation, we apply these transformations to the binary trees as encoded and ordered by A014486 and for each n, a(n) will be the position of the tree to which the n-th tree is transformed to, as follows:
.
                   one tree of one internal
  empty tree         (non-leaf) node
      x                      \/
n=    0                      1
a(n)= 0                      1               (both are always fixed)
.
the next 7 trees, with 2-3 internal nodes, in range [A014137(1), A014137(2+1)-1] = [2,8] are:
.
                          \/     \/                 \/     \/
       \/     \/         \/       \/     \/ \/     \/       \/
      \/       \/       \/       \/       \_/       \/       \/
n=     2        3        4        5        6        7        8
.
and the new shapes after swapping their left and right hand subtrees are:
.
                        \/     \/                     \/     \/
     \/         \/     \/       \/       \/ \/       \/       \/
      \/       \/       \/       \/       \_/       \/       \/
a(n)=  3        2        7        8        6        4        5
thus we obtain the first nine terms of this sequence: 0, 1, 3, 2, 7, 8, 6, 4, 5.
		

Crossrefs

Row 1 of A089840.
The number of cycles and the number of fixed points in each subrange limited by terms of A014137 are given by A007595 and A097331.
Other related sequences: A014486, A057163, A069767, A069768, A089864, A123492, A154125, A154126.
Cf. also A127302, A153835.

Formula

Extensions

Entry revised by Antti Karttunen, Oct 11 2006 and Mar 30 2024

A069768 Signature-permutation of Catalan bijection "Knack".

Original entry on oeis.org

0, 1, 3, 2, 8, 7, 6, 4, 5, 22, 21, 20, 17, 18, 19, 16, 14, 9, 10, 15, 11, 12, 13, 64, 63, 62, 58, 59, 61, 57, 54, 45, 46, 55, 48, 49, 50, 60, 56, 53, 44, 47, 51, 42, 37, 23, 24, 38, 25, 26, 27, 52, 43, 39, 28, 29, 40, 30, 31, 32, 41, 33, 34, 35, 36, 196, 195, 194, 189, 190
Offset: 0

Views

Author

Antti Karttunen, Apr 16 2002; entry revised Dec 20 2008

Keywords

Comments

This automorphism of binary trees first swaps the left and right subtree of the root and then proceeds recursively to the (new) left subtree, to do the same operation there. This is one of those Catalan bijections which extend to a unique automorphism of the infinite binary tree, which in this case is A153142. See further comments there and in A153141.
This bijection, Knack, is a ENIPS-transformation of the simple swap: ENIPS(*A069770) (i.e., row 1 of A122204). Furthermore, Knack and Knick (the inverse, A069767) have a special property, that FORK and KROF transforms (explained in A122201 and A122202) transform them to their own inverses, i.e., to each other: FORK(Knick) = KROF(Knick) = Knack and FORK(Knack) = KROF(Knack) = Knick, thus this occurs also as row 1 in A122288 and naturally, the double-fork fixes both, e.g., FORK(FORK(Knack)) = Knack.
Note: the name in Finnish is "Naks".

References

  • A. Karttunen, paper in preparation.

Crossrefs

Inverse permutation: "Knick", A069767. "n-th powers" (i.e. n-fold applications), from n=2 to 6: A073291, A073293, A073295, A073297, A073299.
In range [A014137(n-1)..A014138(n-1)] of this permutation, the number of cycles is A073431, number of fixed points: A036987 (Fixed points themselves: A084108), Max. cycle size & LCM of all cycle sizes: A011782. See also: A074080.
A127302(a(n)) = A127302(n) for all n. a(n) = A057162(A057508(n)) = A069769(A057162(n))
Row 1 of A122204 and A122288, row 21 of A122285 and A130402, row 8 of A073200.
See also bijections A073287, A082346, A082347, A082350, A130342.

A069767 Signature-permutation of Catalan bijection "Knick".

Original entry on oeis.org

0, 1, 3, 2, 7, 8, 6, 5, 4, 17, 18, 20, 21, 22, 16, 19, 15, 12, 13, 14, 11, 10, 9, 45, 46, 48, 49, 50, 54, 55, 57, 58, 59, 61, 62, 63, 64, 44, 47, 53, 56, 60, 43, 52, 40, 31, 32, 41, 34, 35, 36, 42, 51, 39, 30, 33, 38, 29, 26, 27, 37, 28, 25, 24, 23, 129, 130, 132, 133, 134
Offset: 0

Views

Author

Antti Karttunen, Apr 16 2002; entry revised Dec 20 2008

Keywords

Comments

This automorphism of binary trees first swaps the left and right subtree of the root and then proceeds recursively to the (new) right subtree, to do the same operation there. This is one of those Catalan bijections which extend to a unique automorphism of the infinite binary tree, which in this case is A153141. See further comments there.
This bijection, Knick, is a SPINE-transformation of the simple swap: SPINE(*A069770) (i.e., row 1 of A122203). Furthermore, Knick and Knack (the inverse, *A069768) have a special property, that FORK and KROF transforms (explained in A122201 and A122202) transform them to their own inverses, i.e., to each other: FORK(Knick) = KROF(Knick) = Knack and FORK(Knack) = KROF(Knack) = Knick, thus this occurs also as a row 1 in A122287 and naturally, the double-fork fixes both, e.g., FORK(FORK(Knick)) = Knick. There are also other peculiar properties.
Note: the name in Finnish is "Niks".

References

  • A. Karttunen, paper in preparation.

Crossrefs

Inverse permutation: "Knack", A069768. "n-th powers" (i.e. n-fold applications), from n=2 to 6: A073290, A073292, A073294, A073296, A073298.
In range [A014137(n-1)..A014138(n-1)] of this permutation, the number of cycles is A073431, number of fixed points: A036987 (Fixed points themselves: A084108), Max. cycle size & LCM of all cycle sizes: A011782. See also: A074080.
A127302(a(n)) = A127302(n) for all n. a(n) = A057508(A057161(n)) = A057161(A069769(n)).
Row 1 of A122203 and A122287, row 15 of A122286 and A130403, row 6 of A073200.
See also bijections A073286, A082345, A082348, A082349, A130341.

A127301 Matula-Goebel signatures for plane general trees encoded by A014486.

Original entry on oeis.org

1, 2, 4, 3, 8, 6, 6, 7, 5, 16, 12, 12, 14, 10, 12, 9, 14, 19, 13, 10, 13, 17, 11, 32, 24, 24, 28, 20, 24, 18, 28, 38, 26, 20, 26, 34, 22, 24, 18, 18, 21, 15, 28, 21, 38, 53, 37, 26, 37, 43, 29, 20, 15, 26, 37, 23, 34, 43, 67, 41, 22, 29, 41, 59, 31, 64, 48, 48, 56, 40, 48, 36
Offset: 0

Views

Author

Antti Karttunen, Jan 16 2007

Keywords

Comments

This sequence maps A000108(n) oriented (plane) rooted general trees encoded in range [A014137(n-1)..A014138(n)] of A014486 to A000081(n+1) distinct non-oriented rooted general trees, encoded by their Matula-Goebel numbers. The latter encoding is explained in A061773.
A005517 and A005518 give the minimum and maximum value occurring in each such range.
Primes occur at positions given by A057548 (not in order, and with duplicates), and similarly, semiprimes, A001358, occur at positions given by A057518, and in general, A001222(a(n)) = A057515(n).
If the signature-permutation of a Catalan automorphism SP satisfies the condition A127301(SP(n)) = A127301(n) for all n, then it preserves the non-oriented form of a general tree, which implies also that it is Łukasiewicz-word permuting, satisfying A129593(SP(n)) = A129593(n) for all n >= 0. Examples of such automorphisms include A072796, A057508, A057509/A057510, A057511/A057512, A057164, A127285/A127286 and A127287/A127288.
A206487(n) tells how many times n occurs in this sequence. - Antti Karttunen, Jan 03 2013

Examples

			A000081(n+1) distinct values occur each range [A014137(n-1)..A014138(n-1)]. As an example, A014486(5) = 44 (= 101100 in binary = A063171(5)), encodes the following plane tree:
.....o
.....|
.o...o
..\./.
...*..
Matula-Goebel encoding for this tree gives a code number A000040(1) * A000040(A000040(1)) = 2*3 = 6, thus a(5)=6.
Likewise, A014486(6) = 50 (= 110010 in binary = A063171(6)) encodes the plane tree:
.o
.|
.o...o
..\./.
...*..
Matula-Goebel encoding for this tree gives a code number A000040(A000040(1)) * A000040(1) = 3*2 = 6, thus a(6) is also 6, which shows these two trees are identical if one ignores their orientation.
		

Crossrefs

a(A014138(n)) = A007097(n+1), a(A014137(n)) = A000079(n+1) for all n.
a(|A106191(n)|) = A033844(n-1) for all n >= 1.
For standard instead of binary encoding we have A358506.
A000108 counts ordered rooted trees, unordered A000081.
A014486 lists binary encodings of ordered rooted trees.

Programs

  • Mathematica
    mgnum[t_]:=If[t=={},1,Times@@Prime/@mgnum/@t];
    binbalQ[n_]:=n==0||With[{dig=IntegerDigits[n,2]},And@@Table[If[k==Length[dig],SameQ,LessEqual][Count[Take[dig,k],0],Count[Take[dig,k],1]],{k,Length[dig]}]];
    bint[n_]:=If[n==0,{},ToExpression[StringReplace[StringReplace[ToString[IntegerDigits[n,2]/.{1->"{",0->"}"}],","->""],"} {"->"},{"]]];
    Table[mgnum[bint[n]],{n,Select[Range[0,1000],binbalQ]}] (* Gus Wiseman, Nov 22 2022 *)
  • Scheme
    (define (A127301 n) (*A127301 (A014486->parenthesization (A014486 n)))) ;; A014486->parenthesization given in A014486.
    (define (*A127301 s) (if (null? s) 1 (fold-left (lambda (m t) (* m (A000040 (*A127301 t)))) 1 s)))

Formula

A001222(a(n)) = A057515(n) for all n.

A127377 Signature-permutation of a Catalan automorphism, auxiliary bijection for Callan's 2006 bijection on Dyck Paths.

Original entry on oeis.org

0, 1, 3, 2, 8, 7, 6, 4, 5, 22, 21, 20, 17, 18, 14, 15, 19, 9, 10, 16, 11, 13, 12, 64, 63, 62, 58, 59, 54, 55, 61, 45, 46, 57, 48, 50, 49, 37, 38, 39, 41, 40, 51, 52, 60, 23, 24, 56, 25, 27, 26, 42, 43, 53, 28, 29, 44, 33, 36, 35, 47, 30, 34, 31, 32, 196, 195, 194, 189, 190
Offset: 0

Views

Author

Antti Karttunen, Jan 16 2007

Keywords

Comments

Used to construct A127379.

Crossrefs

Inverse: A127378. The number of cycles and the number of fixed points in range [A014137(n-1)..A014138(n-1)] of this permutation are given by A127383 and A127389. The maximum cycles and LCM's of cycle sizes begin as 1, 1, 2, 4, 4, 8, 8, 8, 8, 16, 16, 16, 16, 16, ... A127387 shows a variant which is an involution. A127302(a(n)) = A127302(n) holds for all n.

A127379 Signature-permutation of Callan's 2006 bijection on Dyck Paths, mirrored version (A057164-conjugate).

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 8, 7, 9, 10, 11, 13, 12, 14, 15, 19, 22, 21, 16, 20, 17, 18, 23, 24, 25, 27, 26, 28, 29, 33, 36, 35, 30, 34, 31, 32, 37, 38, 39, 41, 40, 51, 52, 60, 64, 63, 56, 62, 58, 59, 42, 43, 53, 54, 55, 44, 61, 45, 46, 47, 57, 48, 50, 49, 65, 66, 67, 69, 68, 70, 71
Offset: 0

Views

Author

Antti Karttunen, Jan 16 2007

Keywords

Comments

It's much easier to implement Callan's 2006 bijection for S-expressions if one considers a mirror-image of the graphical description given by Callan (on page 3). Then this automorphism is just RIBS-transformation (explained in A122200) of the automorphism A127377 and Callan's original variant A127381 is obtained as A057164(a(A057164(n))).

Crossrefs

Inverse: A127380. a(n) = A057164(A127381(A057164(n))). The number of cycles and the number of fixed points in range [A014137(n-1)..A014138(n-1)] of this permutation are given by A127384 and A086625 shifted once right. The maximum cycles and LCM's of cycle sizes begin as 1, 1, 1, 2, 4, 4, 8, 8, 8, 8, 16, 16, 16, 16, ... A127302(a(n)) = A127302(n) holds for all n. A127388 shows a variant which is an involution.
Differs from A073289 and A122349 for the first time at n=54, where a(n)=54, while A073289(54) = A122349(54) = 61.

A127380 Signature-permutation of the inverse of Callan's 2006 bijection on Dyck Paths, mirrored version (A057164-conjugate).

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 8, 7, 9, 10, 11, 13, 12, 14, 15, 19, 21, 22, 16, 20, 18, 17, 23, 24, 25, 27, 26, 28, 29, 33, 35, 36, 30, 34, 32, 31, 37, 38, 39, 41, 40, 51, 52, 56, 58, 59, 60, 62, 64, 63, 42, 43, 53, 54, 55, 47, 61, 49, 50, 44, 57, 48, 46, 45, 65, 66, 67, 69, 68, 70, 71
Offset: 0

Views

Author

Antti Karttunen, Jan 16 2007

Keywords

Comments

This automorphism is RIBS-transformation (explained in A122200) of the automorphism A127378 and Callan's original variant A127382 is obtained as A057164(A127380(A057164(n))).

Crossrefs

Inverse: A127379. a(n) = A057164(A127382(A057164(n))). A127302(a(n)) = A127302(n) holds for all n.
Differs from A073288 for the first time at n=49, where a(n)=64, while A073288(49)=63 and differs from A122350 for the first time at n=54, where a(n)=54, while A122350(54)=57.
Showing 1-10 of 16 results. Next