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.

A224269 Consider the spiral of Theodorus (A072895). This sequence gives the number of k successive triangles which is closer to 360 degrees than any previous k triangles.

Original entry on oeis.org

17, 53, 185, 396, 4926, 9086, 20291, 28083, 440835, 579644, 1819320, 3032895, 8305458, 15159436, 29824343, 46104922, 88019569, 89143145, 94929121, 107958869, 227428224, 402409536, 527154160
Offset: 1

Views

Author

Robert G. Wilson v, Apr 02 2013

Keywords

Comments

Any a(i) or a(i)+1 must belong to A072895.
These entries correspond to 1, 2, 4, 6, 22, 30, 45, 53, 211, 242, 429, 554, 917, 1239, 1738, 2161, 2986, 3005, 3101, 3307, 4800, 6385, 7308, ..., turns around the axis. Use the formula in A072895 to check the entries.
Search limit: 10000 turns about the axis.

Examples

			a(1) = 17 because the first 16 right triangles result in 351.15042° (8.84958° before the original axis) and the first 17 right triangles result in 364.78344°. 17 right triangles are within 4.78344° of the original axis.
a(2) = 53 because the first 54 right triangles result in 727.48834° and the first 53 right triangles result in 719.73897°.  This is closer to the original axis than 16 and is within 0.2610252°.
a(3) # 109 nor 110 because the first 109 right triangles result in 1079.12463° and the first 110 right triangles result in 1084.57110°. Neither angle is closer to the original axis (1080°) than 53. Therefore the third turn around the center is not close to the original axis than twice around.
a(3) = 185 because the first 186 right triangles result in 1444.08227° (4.08227° after the original axis) and the first 185 right triangles result in 1439.88864°.  This is closer to the original axis than 53 and is within 0.11136°.
		

Crossrefs

Cf. A072895.

Programs

  • Mathematica
    lmt = Infinity; lst = {}; k = n = 1; s = 0; While[n < 1001, While[s < 2Pi*n, s = N[s + ArcTan[ 1 / Sqrt@ k], 32]; k++]; a = s - 2Pi*n; b = 2Pi*n - (s - ArcTan[1/Sqrt[k - 1]]); If[Min[a, b] < lmt, lmt = Min[a, b]; If[a < b, AppendTo[lst, {n, k - 1}]; Print[{n, k - 1}], AppendTo[lst, {n, k - 2}]; Print[{n, k - 2}]]]; n++]; Last@ Transpose@ lst
    k=minDist=1;lst={};K=-2.1577829966594462209291427868295777235; num[n_]:=Module[{a=-(K/2)+n Pi,b},b=a^2-1/6;If[Floor[b]==Floor[b+1/(144 a^2)],Floor[b],Undefined]]; While[k<40000000,n=num[k];If[!NumberQ[n],Print[k," Stop"];Break[]]; a=2Pi-Mod[K+2 Sqrt[n]+1/(6 Sqrt[n]),2Pi]; b=Mod[K+2 Sqrt[n+1]+1/(6 Sqrt[n+1]),2Pi]; If[aHerbert Kociemba, Jul 18 2013 *)