login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A121087 Number of primitive Pythagorean-like triples a^2+b^2=c^2+k for k=-5 with 0<c<=10^n. 3

%I #13 Dec 22 2015 10:18:26

%S 1,22,223,2217,22354,223667,2235713,22360389,223610157

%N Number of primitive Pythagorean-like triples a^2+b^2=c^2+k for k=-5 with 0<c<=10^n.

%C It is conjectured by the first author that a(n)/10^n as n->inf is 1/(2*sqrt(5)) = 0.22360...

%e a(1)=1 because there is one solution (a,b,c) as (2,4,5) with 0<c<=10^1.

%t (* Courtesy of Daniel Lichtblau of Wolfram Research *)

%t countTriples[m_, k_] := Module[ {c2, c2odd, total = 0, fax, g}, Do[ c2 = c^2 + k; If[c2 < 2, Continue[]]; c2odd = c2; While[EvenQ[c2odd], c2odd /= 2]; If [c2odd==1, If [OddQ[Log[2,c2]], total++ ]; Continue[]]; If[Mod[c2odd, 4] == 3, Continue[]]; g = GCD[c2odd, 100947]; If[g != 1 && g^2 != GCD[c2odd, 10190296809], Continue[]]; fax = Map[{Mod[ #[[1]],4],#[[2]]}&, FactorInteger[c2odd]]; If[Apply[Or, Map[ #[[1]] == 3 && OddQ[ #[[2]]] &, fax]], Continue []]; fax = Cases[fax, {1,aa_}:>aa+1]; fax = Ceiling[Apply[Times,fax]/2]; total += fax;, {c,m}]; total]

%Y Cf. A101931.

%K nonn

%O 1,2

%A _Tito Piezas III_, Aug 11 2006

%E First few terms found by _Tito Piezas III_, James Waldby (j-waldby(AT)pat7.com)

%E Subsequent terms found by Andrzej Kozlowski (akoz(AT)mimuw.edu.pl), Daniel Lichtblau (danl(AT)wolfram.com)

%E a(7) from _Max Alekseyev_, May 30 2007

%E a(8)-a(9) from _Lars Blomberg_, Dec 22 2015

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 11:06 EDT 2024. Contains 371967 sequences. (Running on oeis4.)