login
This site is supported by donations to The OEIS Foundation.
Logo

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A002330 Value of y in the solution to p = x^2 + y^2, x <= y, with prime p = A002313(n).
(Formerly M0462 N0169)
22
1, 2, 3, 4, 5, 6, 5, 7, 6, 8, 8, 9, 10, 10, 8, 11, 10, 11, 13, 10, 12, 14, 15, 13, 15, 16, 13, 14, 16, 17, 13, 14, 16, 18, 17, 18, 17, 19, 20, 20, 15, 17, 20, 21, 19, 22, 20, 21, 19, 20, 24, 23, 24, 18, 19, 25, 22, 25, 23, 26, 26, 22, 27, 26, 20, 25, 22, 26, 28, 25 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

COMMENTS

Equals A096029(n) + A096030(n) + 1, for entries after the first. - Lekraj Beedassy, Jul 21 2004

a(n+1) = MAX(A002972(n), 2*A002973(n)). [From Reinhard Zumkeller, Feb 16 2010]

REFERENCES

A. J. C. Cunningham, Quadratic Partitions. Hodgson, London, 1904, p. 1.

N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).

N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

J. Todd, A problem on arc tangent relations, Amer. Math. Monthly, 56 (1949), 517-528.

LINKS

T. D. Noe and Charles R Greathouse IV, Table of n, a(n) for n = 1..10000 (first 1000 terms from Noe)

John Brillhart, Note on representing a prime as a sum of two squares, Math. Comp. 26 (1972), pp. 1011-1013.

K. Matthews, Serret's algorithm Server

Eric Weisstein's World of Mathematics, Fermat's 4n Plus 1 Theorem

EXAMPLE

The following table shows the relationship

between several closely related sequences:

Here p = A002144 = primes == 1 mod 4, p = a^2+b^2 with a < b;

a = A002331, b = A002330, t_1 = ab/2 = A070151;

p^2 = c^2+d^2 with c < d; c = A002366, d = A002365,

t_2 = 2ab = A145046, t_3 = b^2-a^2 = A070079,

with {c,d} = {t_2, t_3}, t_4 = cd/2 = ab(b^2-a^2).

---------------------------------

.p..a..b..t_1..c...d.t_2.t_3..t_4

---------------------------------

.5..1..2...1...3...4...4...3....6

13..2..3...3...5..12..12...5...30

17..1..4...2...8..15...8..15...60

29..2..5...5..20..21..20..21..210

37..1..6...3..12..35..12..35..210

41..4..5..10...9..40..40...9..180

53..2..7...7..28..45..28..45..630

.................................

MAPLE

a := []; for x from 0 to 50 do for y from x to 50 do p := x^2+y^2; if isprime(p) then a := [op(a), [p, x, y]]; fi; od: od: writeto(trans); for i from 1 to 158 do lprint(a[i]); od: # then sort the triples in "trans"

MATHEMATICA

Flatten[#, 1]&[Table[PowersRepresentations[Prime[k], 2, 2], {k, 1, 142}]][[All, 2]] (* From Jean-François Alcover, Jul 05 2011 *)

PROG

(PARI) f(p)=my(s=lift(sqrt(Mod(-1, p))), x=p, t); if(s>p/2, s=p-s); while(s^2>p, t=s; s=x%s; x=t); s

forprime(p=2, 1e3, if(p%4-3, print1(f(p)", "))) \\ Charles R Greathouse IV, Apr 24 2012

CROSSREFS

Cf. A002331, A002313, A002144.

Sequence in context: A165597 A099033 A187786 * A091951 A063283 A036055

Adjacent sequences:  A002327 A002328 A002329 * A002331 A002332 A002333

KEYWORD

nonn

AUTHOR

N. J. A. Sloane.

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified June 20 05:50 EDT 2013. Contains 226419 sequences.