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.

A089020 First value y satisfying x^2 - 3*y^2 = d^2, where d=A072330(n).

This page as a plain text file.
%I A089020 #12 Mar 07 2020 05:08:34
%S A089020 1,4,3,7,5,8,11,16,20,7,13,20,12,44,9,51,17,52,57,55,19,11,16,28,72,
%T A089020 91,36,65,69,13,23,68,20,25,105,15,88,76,44,120,145,40,87,119,29,85,
%U A089020 24,17,155,132,93,31,44,104,52,92,95,19,140,200,28,105,231,35,100,185,105,120
%N A089020 First value y satisfying x^2 - 3*y^2 = d^2, where d=A072330(n).
%H A089020 Jean-François Alcover, <a href="/A089020/b089020.txt">Table of n, a(n) for n = 1..1000</a>
%t A089020 terms = 1000;
%t A089020 nmax = 12 terms;
%t A089020 okQ[n_] := AllTrue[FactorInteger[n][[All, 1]], MatchQ[Mod[#, 12], 1|11]&];
%t A089020 A072330 = Select[Range[nmax], okQ];
%t A089020 a[n_] := Module[{a, b, c, d, p}, d = If[n <= Length[A072330], A072330[[n]], Print["nmax = ", nmax, " insufficient"]; Exit[]]; If[n == 1, 1, For[b = 2 d, True, b++, a = b - d; c = b + d; p = (a + b + c)/2; If[IntegerQ[p] && IntegerQ[Sqrt[p (p - a) (p - b) (p - c)]] && GCD[a, b, c] == 1, Return[ Sqrt[b^2 - 4 d^2]/(2 Sqrt[3])]]]]];
%t A089020 a /@ Range[terms] (* _Jean-François Alcover_, Mar 07 2020 *)
%Y A089020 For corresponding x see A089019.
%Y A089020 Cf. A072330, A072360, A086909, A089019, A096672, A096673, A096674.
%K A089020 nonn
%O A089020 1,2
%A A089020 _Lekraj Beedassy_, Nov 04 2003
%E A089020 Extended by _Ray Chandler_, Jul 03 2004