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.

Showing 1-3 of 3 results.

A300219 Number of ways to write n^2 as x^2 + y^2 + z^2 + w^2 with x,y,z,w nonnegative integers and z <= w such that both x and 4*x - 3*y are powers of 4 (including 4^0 = 1).

Original entry on oeis.org

1, 1, 1, 1, 1, 3, 2, 1, 5, 2, 2, 1, 3, 3, 1, 1, 2, 2, 2, 1, 8, 3, 2, 3, 4, 3, 4, 2, 8, 5, 4, 1, 7, 6, 4, 5, 1, 3, 6, 2, 9, 6, 3, 2, 8, 4, 2, 1, 5, 3, 7, 3, 4, 6, 3, 3, 7, 4, 5, 1, 3, 5, 3, 1, 2, 9, 4, 2, 11, 3, 6, 2, 6, 7, 3, 2, 4, 5, 4, 1
Offset: 1

Views

Author

Zhi-Wei Sun, Feb 28 2018

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 0, and a(n) = 1 only for n = 4^k*m (k = 0,1,2,... and m = 1, 2, 3, 5, 15, 37, 83, 263). Also, for each n = 2,3,... we can write n^2 as x^2 + y^2 + z^2 + w^2 with x,y,z,w nonnegative integers such that both x and 4*x - 3*y lie in the set {2^(2k+1): k = 0,1,...}.
(ii) Let r be 0 or 1, and let n > r. Then n^2 can be written as x^2 + y^2 + z^2 + w^2 with x,y,z,w nonnegative integers such that both x and x + 3*y belong to the set {2^(2k+r): k = 0,1,2,...}, unless n has the form 2^(2k+r)*81503 with k a nonnegative integer and hence n^2 = (2^(2k+r)*28^2)^2 + (2^(2k+r)*80)^2 + (2^(2k+r)*55937)^2 + (2^(2k+r)*59272)^2 with 2^(2k+r)*28^2 = 2^r*(2^k*28)^2 and 2^(2k+r)*28^2 + 3*(2^(2k+r)*80) = 2^(2(k+5)+r). So we always can write n^2 as x^2 + y^2 + z^2 + w^2 with x,y,z,w nonnegative integers such that x/2^r is a square and (x+3*y)/2^r is a power of 4.
In arXiv:1701.05868 the author proved that for each r = 0,1 and n > r we can write n^2 as (2^(2k+r))^2 + x^2 + y^2 + z^2 with k,x,y,z nonnegative integers.
We have verified both parts of the conjecture for n up to 10^7.

Examples

			a(2) = 1 since 2^2 = 1^2 + 1^2 + 1^2 + 1^2 with 1 = 4^0 and 4*1 - 3*1 = 4^0.
a(3) = 1 since 3^2 = 1^2 + 0^2 + 2^2 + 2^2 with 1 = 4^0 and 4*1 - 3*0 = 4^1.
a(5) = 1 since 5^2 = 4^2 + 0^2 + 0^2 + 3^2 with 4 = 4^1 and 4*4 - 3*0 = 4^2.
a(15) = 1 since 15^2 = 4^2 + 4^2 + 7^2 + 12^2 with 4 = 4^1 and 4*4 - 3*4 = 4^1.
a(37) = 1 since 37^2 = 16^2 + 16^2 + 4^2 + 29^2 with 16 = 4^2 and 4*16 - 3*16 = 4^2.
a(83) = 1 since 83^2 = 4^2 + 4^2 + 56^2 + 61^2 with 4 = 4^1 and 4*4 - 3*4 = 4^1.
a(263) = 1 since 263^2 = 4^2 + 5^2 + 22^2 + 262^2 with 4 = 4^1 and 4*4 - 3*5 = 4^0.
		

Crossrefs

Programs

  • Mathematica
    SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]];
    Do[r=0;Do[If[SQ[n^2-16^k-((4^(k+1)-4^m)/3)^2-z^2],r=r+1],{k,0,Log[4,n]},{m,Ceiling[Log[4,Max[1,4^(k+1)-3*Sqrt[n^2-16^k]]]],k+1},{z,0,Sqrt[(n^2-16^k-((4^(k+1)-4^m)/3)^2)/2]}];Print[n," ",r];Label[aa],{n,1,80}]

A300364 Balanced primes of order thirteen.

Original entry on oeis.org

353, 2351, 3673, 3863, 4759, 6271, 8539, 8821, 11261, 12073, 17839, 26711, 32797, 33769, 34679, 41357, 53269, 60217, 64879, 64891, 68713, 88493, 90121, 91811, 101347, 101411, 101641, 108139, 108203, 114659, 122029, 123637, 127843, 128237, 130447, 133279
Offset: 1

Views

Author

Muniru A Asiru, Mar 04 2018

Keywords

Examples

			353 is a member because 353 = 271 + 277 + 281 + 283 + 293 + 307 + 311 + 313 + 317 + 331 + 337 + 347 + 349 + 353 + 359 + 367 + 373 + 379 + 383 + 389 + 397 + 401 + 409 + 419 + 421 + 431 + 433 = 9531/27.
		

Crossrefs

Cf. Balanced primes of order b: A006562 (b=1), A082077 (b=2), A082078 (b=3), A082079 (b=4), A096697 (b=5), A096698 (b=6), A096699 (b=7), A096700 (b=8), A096701 (b=9), A096702 (b=10), A096703 (b=11), A096704 (b=12), this sequence (b=13), A300365 (b=14).

Programs

  • GAP
    P:=Filtered([1..150000],IsPrime);;
    a:=List(Filtered(List([0..13000],k->List([1..27],j->P[j+k])),i->Sum(i)/27=i[14]),m->m[14]);

A363168 Balanced primes of order 100.

Original entry on oeis.org

27947, 111337, 193283, 197341, 197621, 347063, 809821, 955193, 1029803, 1184269, 1292971, 1609163, 1630859, 1656019, 1752449, 1883381, 1935517, 1969661, 2120221, 2156383, 2238959, 2287133, 2548631, 2592089, 2750903, 2866403, 3165769, 3257941, 3590299, 3889423
Offset: 1

Views

Author

Harvey P. Dale, Jul 07 2023

Keywords

Comments

A prime p is in this sequence if the sum of the 100 consecutive primes just less than p, plus p, plus the sum of the 100 consecutive primes just greater than p, divided by 201 equals p.

Crossrefs

Cf. Balanced primes of order b: A006562 (b=1), A082077 (b=2), A082078 (b=3), A082079 (b=4), A096697 (b=5), A096698 (b=6), A096699 (b=7), A096700 (b=8), A096701 (b=9), A096702 (b=10), A096703 (b=11), A096704 (b=12), A300364 (b=13), A300365 (b=14).

Programs

  • Mathematica
    Module[{bal=100,nn=300000},Select[Partition[Prime[Range[nn]],2bal+1,1],Mean[#]== #[[bal+1]]&]] [[;;,101]]
Showing 1-3 of 3 results.