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.

A242466 A term in this sequence a(n) is such that n and n+1 have isomorphic factor decomposition binary trees.

This page as a plain text file.
%I A242466 #27 Mar 27 2017 03:42:04
%S A242466 2,9,14,21,25,33,34,38,57,85,86,93,94,116,118,121,122,133,141,142,145,
%T A242466 158,170,171,177,201,202,205,213,214,217,218,253,284,298,301,302,326,
%U A242466 332,334,361,369,381,387,393,394,434,435,445,446,453,481,501,514,526
%N A242466 A term in this sequence a(n) is such that n and n+1 have isomorphic factor decomposition binary trees.
%C A242466 Integral Fission (consecutive isomorphic trees): For a natural number, n, make it the root node of a binary tree. The left child node (L) is the largest divisor of n which is greater than 1 but less than or equal to the square root of n, if this exists. The right child node is n/L, if the left node exists. Thus if n is a prime it is a leaf node; otherwise if it is composite then it is the product of its two children. If n = 1 then we have an empty tree.
%H A242466 Alois P. Heinz, <a href="/A242466/b242466.txt">Table of n, a(n) for n = 1..10000</a>
%H A242466 Gordon Hamilton, <a href="http://youtu.be/1fpY8WU_DJI">Integral Fission</a>, Video for grade 7 teachers
%p A242466 with(numtheory):
%p A242466 t:= proc(n) option remember; `if`(n=1, "0",
%p A242466       `if`(isprime(n), "10", (d-> cat("1", t(d), t(n/d), "0"))(
%p A242466        max(select(x-> is(x<=sqrt(n)), divisors(n))[]))))
%p A242466     end:
%p A242466 a:= proc(n) option remember; local k;
%p A242466       for k from 1 +`if`(n=1, 0, a(n-1))
%p A242466       while t(k)<>t(k+1) do od; k
%p A242466     end:
%p A242466 seq(a(n), n=1..60);  # _Alois P. Heinz_, Aug 09 2014
%t A242466 t[n_] := t[n] = If[n == 1, "0", If[PrimeQ[n], "10", ("1" <> t[#] <> t[n/#] <> "0"&)[Max[Select[Divisors[n], # <= Sqrt[n]&]]]]];
%t A242466 a[n_] := a[n] = (For[k = 1 + If[n == 1, 0, a[n-1]], t[k] != t[k+1], k++]; k);
%t A242466 Array[a, 60] (* _Jean-François Alcover_, Mar 27 2017, after _Alois P. Heinz_ *)
%o A242466 (PARI) isok(n) = eqvec(empty(fiss(n)), empty(fiss(n+1))); \\ using A125508 scripts; _Michel Marcus_, May 25 2014
%Y A242466 Cf. A125508.
%K A242466 nonn
%O A242466 1,1
%A A242466 _Gordon Hamilton_, May 15 2014
%E A242466 More terms from _Michel Marcus_, May 25 2014