[go: up one dir, main page]

login
A047531
Numbers that are congruent to {2, 3, 7} mod 8.
1
2, 3, 7, 10, 11, 15, 18, 19, 23, 26, 27, 31, 34, 35, 39, 42, 43, 47, 50, 51, 55, 58, 59, 63, 66, 67, 71, 74, 75, 79, 82, 83, 87, 90, 91, 95, 98, 99, 103, 106, 107, 111, 114, 115, 119, 122, 123, 127, 130, 131, 135, 138, 139, 143, 146, 147, 151, 154, 155, 159
OFFSET
1,1
COMMENTS
From Richard R. Forberg, Mar 14 2016 : (Start)
Numbers m such that p^2 + q^2 + r^2 - m is a square, for distinct odd primes p, q, and r. This follows from the fact that the sum of the squares of three odd primes is 3 mod 8, and squares are {0,1,4} mod 8. Changing -m to +m leads to A047438.
The expression p^2 + q^2 + r^2 - m can equal the square of an odd number only when m == 2 mod 8 (because all odd squares are 1 mod 8).
This same expression only equals squares of primes for m in {2, 10, 26, 34} mod 48, because when m = {18, 42} mod 48, the expression is congruent to {9, 33} mod 48, which matches the values of (6*k-3)^2 mod 48.
(End)
FORMULA
From Chai Wah Wu, May 30 2016: (Start)
a(n) = a(n-1) + a(n-3) - a(n-4) for n > 4.
G.f.: x*(x^3 + 4*x^2 + x + 2)/(x^4 - x^3 - x + 1). (End)
a(n) = (24*n + 5*sqrt(3)*sin(2*Pi*n/3) + 3*cos(2*Pi*n/3) - 12)/9. - Ilya Gutkovskiy, May 30 2016
a(3k) = 8k-1, a(3k-1) = 8k-5, a(3k-2) = 8k-6. - Wesley Ivan Hurt, Jun 10 2016
MAPLE
A047531:=n->(24*n-12+3*cos(2*n*Pi/3)+5*sqrt(3)*sin(2*n*Pi/3))/9: seq(A047531(n), n=1..100); # Wesley Ivan Hurt, Jun 10 2016
MATHEMATICA
LinearRecurrence[{1, 0, 1, -1}, {2, 3, 7, 10}, 50] (* G. C. Greubel, May 30 2016 *)
Select[Range[200], MemberQ[{2, 3, 7}, Mod[#, 8]]&] (* Harvey P. Dale, Jan 18 2019 *)
PROG
(Magma) [n : n in [0..150] | n mod 8 in [2, 3, 7]]; // Wesley Ivan Hurt, Jun 10 2016
CROSSREFS
Cf. A047438.
Sequence in context: A051637 A051471 A140794 * A102808 A215937 A140512
KEYWORD
nonn,easy
STATUS
approved