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-4 of 4 results.

A007321 Number of steps needed for modified juggler sequence (A094685) started at n to reach 1.

Original entry on oeis.org

0, 1, 6, 2, 5, 2, 13, 7, 10, 7, 4, 7, 6, 3, 9, 3, 9, 3, 12, 3, 9, 6, 9, 6, 19, 6, 9, 6, 9, 6, 16, 3, 5, 3, 8, 3, 16, 3, 5, 3, 14, 3, 11, 14, 11, 14, 5, 14, 14, 14, 14, 14, 5, 14, 5, 14, 11, 8, 11, 8, 8, 8, 8, 8, 11, 8, 11, 8, 8, 8, 8, 8, 21, 11, 21, 11, 8, 11, 8, 11, 19, 11, 11, 11, 8, 11, 11, 11, 11
Offset: 1

Views

Author

Keywords

Comments

It is not known if every starting value eventually reaches 1.

References

  • C. Pickover, Computers and the Imagination, St. Martin's Press, NY, 1991, p. 233.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Maple
    f:=proc(n) if n mod 2 = 0 then RETURN(round(sqrt(n))) else RETURN(round(n^(3/2))); fi; end; # corrected by R. J. Mathar, Jul 28 2007
  • Mathematica
    mjs[n_] := If[EvenQ[n], Round[Sqrt[n]], Round[Sqrt[n^3]]]; f[n_] := Length[NestWhileList[mjs, n, # != 1 &]] - 1; Table[ f[n], {n, 90}]

Extensions

More terms from N. J. A. Sloane, Jun 09 2004

A094725 Largest value in trajectory of n under the modified juggler map of A094685.

Original entry on oeis.org

0, 1, 2, 36, 4, 36, 6, 756, 36, 140, 36, 36, 36, 322, 14, 58, 16, 70, 18, 756, 20, 96, 36, 110, 36, 196070, 36, 140, 36, 156, 36, 213705634112, 32, 190, 34, 2978, 36, 196070, 38, 244, 40, 278534, 42, 282, 756, 302, 756, 322, 756, 6352, 756, 756, 756, 386, 756
Offset: 0

Views

Author

N. J. A. Sloane, Jun 10 2004

Keywords

Comments

a(549) has 1519 digits and a(5807) has 6022 digits. - Chai Wah Wu, Aug 18 2016
a(10327) has 7508 digits. - Vikram Prasad, Mar 02 2024

Crossrefs

Cf. A094685.

Programs

  • Mathematica
    smx={};Do[a=n;mx=n;While[a!=1,a=If[Mod[a,2]==0,Round[Sqrt[a]],Round[a^(3/2)]];If[a>mx,mx=a]];AppendTo[smx,mx],{n,54}];Join[{0},smx] (* James C. McMahon, Apr 15 2025 *)

Extensions

More terms from John W. Layman, Jun 15 2004

A094693 Records in A094685.

Original entry on oeis.org

0, 1, 5, 11, 19, 27, 36, 47, 58, 70, 83, 96, 110, 125, 140, 156, 173, 190, 207, 225, 244, 263, 282, 302, 322, 343, 364, 386, 408, 430, 453, 476, 500, 524, 548, 573, 598, 624, 650, 676, 702, 729, 756, 784, 811, 840, 868, 897, 926, 955, 985, 1015, 1045, 1076, 1107, 1138, 1169
Offset: 0

Views

Author

N. J. A. Sloane, Jun 09 2004

Keywords

A094683 Juggler sequence: if n mod 2 = 0 then floor(sqrt(n)) else floor(n^(3/2)).

Original entry on oeis.org

0, 1, 1, 5, 2, 11, 2, 18, 2, 27, 3, 36, 3, 46, 3, 58, 4, 70, 4, 82, 4, 96, 4, 110, 4, 125, 5, 140, 5, 156, 5, 172, 5, 189, 5, 207, 6, 225, 6, 243, 6, 262, 6, 281, 6, 301, 6, 322, 6, 343, 7, 364, 7, 385, 7, 407, 7, 430, 7, 453, 7, 476, 7, 500, 8, 524, 8, 548, 8, 573, 8, 598, 8, 623, 8, 649
Offset: 0

Views

Author

N. J. A. Sloane, Jun 09 2004

Keywords

Comments

Interspersion of A000093 and A000196. - Michel Marcus, Nov 11 2013

References

  • C. Pickover, Computers and the Imagination, St. Martin's Press, NY, 1991, p. 233.

Crossrefs

Programs

  • Maple
    A094683 :=proc(n) if n mod 2 = 0 then RETURN(floor(sqrt(n))) else RETURN(floor(n^(3/2))); end if; end proc;
  • Mathematica
    Table[If[EvenQ[n], Floor[Sqrt[n]], Floor[n^(3/2)]], {n, 0, 100}] (* Indranil Ghosh, Apr 07 2017 *)
  • PARI
    a(n) = if(n%2,sqrtint(n^3), sqrtint(n)); \\ Indranil Ghosh, Apr 08 2017
    
  • Python
    import math
    from sympy import sqrt
    def a(n): return int(math.floor(sqrt(n))) if n%2 == 0 else int(math.floor(n**(3/2)))
    print([a(n) for n in range(51)]) # Indranil Ghosh, Apr 08 2017
    
  • Python
    from math import isqrt
    def A094683(n): return isqrt(n**3 if n % 2 else n) # Chai Wah Wu, Feb 18 2022
Showing 1-4 of 4 results.