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.

A183132 Successive integers produced by Conway's PRIMEGAME using Kilminster's Fractran program with only nine fractions.

This page as a plain text file.
%I A183132 #39 Feb 16 2025 08:33:13
%S A183132 10,5,36,858,234,5577,1521,3549,8281,910,100,50,25,180,3388,924,252,
%T A183132 6006,1638,39039,10647,24843,57967,6370,700,300,7150,1950,46475,12675,
%U A183132 29575,3250,360,6776,1848,504,12012,3276,78078,21294,507507,138411,322959,753571
%N A183132 Successive integers produced by Conway's PRIMEGAME using Kilminster's Fractran program with only nine fractions.
%C A183132 The exponents of exact powers of 10 in this sequence are 1, followed by the successive primes (A008578).
%D A183132 D. Olivastro, Ancient Puzzles. Bantam Books, NY, 1993, p. 21.
%H A183132 Alois P. Heinz, <a href="/A183132/b183132.txt">Table of n, a(n) for n = 1..10547</a>
%H A183132 J. H. Conway, <a href="http://dx.doi.org/10.1007/978-1-4612-4808-8_2">FRACTRAN: a simple universal programming language for arithmetic</a>, in T. M. Cover and Gopinath, eds., Open Problems in Communication and Computation, Springer, NY 1987, pp. 4-26.
%H A183132 Esolang wiki, <a href="http://www.esolangs.org/wiki/Fractran">Fractran</a>
%H A183132 Chaim Goodman-Strauss, <a href="http://www.ams.org/notices/201003/rtx100300343p.pdf">Can’t Decide? Undecide!</a>, Notices of the AMS, Volume 57, Number 3, pp. 343-356, March 2010.
%H A183132 R. K. Guy, <a href="http://www.jstor.org/stable/2690263">Conway's prime producing machine</a>, Math. Mag. 56 (1983), no. 1, 26-33.
%H A183132 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/FRACTRAN.html">FRACTRAN</a>.
%H A183132 Wikipedia, <a href="https://en.wikipedia.org/wiki/FRACTRAN">FRACTRAN</a>.
%p A183132 l:= [3/11, 847/45, 143/6, 7/3, 10/91, 3/7, 36/325, 1/2, 36/5]:
%p A183132 a:= proc(n) option remember;
%p A183132       global l;
%p A183132       local p, k;
%p A183132       if n=1 then 10
%p A183132              else p:= a(n-1);
%p A183132                   for k while not type(p*l[k], integer)
%p A183132                   do od; p*l[k]
%p A183132       fi
%p A183132     end:
%p A183132 seq(a(n), n=1..50);
%t A183132 l = {3/11, 847/45, 143/6, 7/3, 10/91, 3/7, 36/325, 1/2, 36/5};
%t A183132 a[n_] := a[n] = Module[{p, k}, If[n == 1, 10, p = a[n - 1]; For[k = 1, !IntegerQ[p*l[[k]]], k++]; p*l[[k]]]];
%t A183132 Array[a, 50] (* _Jean-François Alcover_, May 28 2018, from Maple *)
%o A183132 (Python)
%o A183132 from fractions import Fraction
%o A183132 nums = [ 3, 847, 143, 7, 10, 3,  36, 1, 36]
%o A183132 dens = [11,  45,   6, 3, 91, 7, 325, 2,  5]
%o A183132 PRIMEGAME = [Fraction(num, den) for num, den in zip(nums, dens)]
%o A183132 def succ(n, program):
%o A183132     for i in range(len(program)):
%o A183132       if (n*program[i]).denominator == 1: return (n*program[i]).numerator
%o A183132 def orbit(start, program, steps):
%o A183132     orb = [start]
%o A183132     for s in range(1, steps): orb.append(succ(orb[-1], program))
%o A183132     return orb
%o A183132 print(orbit(10, PRIMEGAME, steps=44)) # _Michael S. Branicky_, Oct 05 2021
%Y A183132 Cf. A183133, A008578, A007542, A007546, A007547.
%K A183132 easy,look,nonn
%O A183132 1,1
%A A183132 _Alois P. Heinz_, Dec 26 2010