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.

A237518 Least primes that together with prime(n) forms a Heronian triangle, starting at n = 2.

This page as a plain text file.
%I A237518 #12 Aug 26 2015 17:51:24
%S A237518 5,3,4729,13,5,17,37,5280071830550089,5,97,13,17,61,1824001,53,109,11,
%T A237518 3301,1009,19,241,241,17,11,29,409,6841,11,17,3169,181,41,157,3,457,
%U A237518 13,10369,231781748893580717709514473745694370721,173,277,19,7297,31,53,3049,373
%N A237518 Least primes that together with prime(n) forms a Heronian triangle, starting at n = 2.
%C A237518 It has been proved that for every integer i > 2 there exists an infinite series of side pairs (j, k) that together with i form a Heronian triangle. It is conjectured that for every prime(n) where n > 1 there exists an infinite series of side pairs (p, q) that together with prime(n) form a Heronian triangle such that either p or q is also prime. See A230666 and A233232 for prime(2) and prime(3). a(n) is the sequence of least such primes for prime(n).
%H A237518 Noam Elkies, <a href="http://mathoverflow.net/questions/153180/heronian-triangle-with-two-sides-that-are-prime">Heronian triangles with two sides that are prime</a>, Mathoverflow, 2013.
%H A237518 Eugen J. Ionascu, Florian Luca, Pantelimon Stanica, <a href="http://arxiv.org/abs/math/0608185">Heron triangles with two fixed sides</a>, arXiv:math/0608185 [math.NT], 2006.
%H A237518 Eugen J. Ionascu, Florian Luca, Pantelimon Stanica, <a href="http://dx.doi.org/10.1016/j.jnt.2006.12.004">Heron triangles with two fixed sides</a>, Journal of Number Theory, Volume 126, Issue 1, September 2007, Pages 52-67.
%H A237518 Pantelimon Stanica, Santanu Sarkar, Sourav Sen Gupta, Subhamoy Maitra, and Nirupam Kar, <a href="http://www.emis.de/journals/INTEGERS/papers/n3/n3.Abstract.html">Counting Heron triangles with Constraints</a>, Integers, Vol. 13, 2013.
%F A237518 Apart from searching through the first 150000 prime numbers for each prime(n) to form a Heronian triangle (1st Mathematica program), more difficult primes e.g. prime(9)=23 and prime(39)=167 require Pell-type equations to be solved and searched for these least primes (2nd and 3rd Mathematica programs). If a Heronian triangle has side length triples of the form (q, p, p+d) where q = prime(n) and d is odd such that 0 > d > p, then the Pell-type equation is of the form Y^2 - K*X^2 = -J with Y^2 = 4*Area^2/g, X = 2p+d, K = (q^2-d^2)/(4g), J = q^2(q^2-d^2)/(4g) and g = 4 if 16|(q^2-d^2) else g = 1. Other constraints on these primes (see Links) will only permit the following valid pairings:-
%F A237518   prime(n) == 3 mod 4 and a(n) == 1 mod 4
%F A237518   prime(n) == 1 mod 4 and a(n) == 3 mod 4 and prime(n) > a(n)
%F A237518   prime(n) == 1 mod 4 and a(n) == 1 mod 4.
%e A237518 a(18)=11 as prime(18)=61, the triple (11, 60, 61) is Heronian and right angled with area=330 and 61 is the least such prime. prime(18)=61==1 mod 4 and a(18)=11==3 mod 4 and prime(18)>a(18).
%t A237518 maxn = 150000; nn=Prime[Range[maxn]]; lst={}; nn1=Prime[Range[2, 100]]; Do[Do[s=(a+b+c)/2; If[IntegerQ[s], area2=s(s-a)(s-b)(s-c); If[area2>0 && IntegerQ[Sqrt[area2]], (AppendTo[lst, b]; Break[])]]; If[b==Prime[maxn], AppendTo[lst, 0]; Break[]], {b, nn}, {a, b-c+2, b+c-2, 2}], {c, nn1}]; lst
%t A237518 (* 1st Program *)
%t A237518 q=23; d=1; nextpair[{y0_, x0_}] := (y=23; x=4; y1=y*y0+x*x0*33; x1=x0*y+y0*x; {y1, x1}); pair=nextpair[{0, q}]; While[!PrimeQ[(pair[[2]]-d)/2] && !PrimeQ[(pair[[2]]-d)/2+d], pair=nextpair[pair]]; primepair={(pair[[2]]-d)/2, (pair[[2]]-d)/2+d}; primepair(* 2nd Program *)
%t A237518 q=167; d=25; y=88751; x=2150; nextpair[{y0_, x0_}] := (If[IntegerQ[(q^2-d^2)/16], k=(q^2-d^2)/16, k=(q^2-d^2)/4]; y1=y*y0+x*x0*k; x1=x0*y+y0*x; {y1, x1}); pair=nextpair[{0, q}]; While[!PrimeQ[(pair[[2]]-d)/2] && !PrimeQ[(pair[[2]]+d)/2], pair=nextpair[pair]]; primepair={(pair[[2]]-d)/2, (pair[[2]]+d)/2}; primepair(* 3rd Program *)
%Y A237518 Cf. A230666, A233232.
%K A237518 nonn
%O A237518 2,1
%A A237518 _Frank M Jackson_, Feb 08 2014