A016032
Least positive integer that is the sum of two squares of positive integers in exactly n ways.
Original entry on oeis.org
2, 50, 325, 1105, 8125, 5525, 105625, 27625, 71825, 138125, 5281250, 160225, 1221025, 2442050, 1795625, 801125, 446265625, 2082925, 41259765625, 4005625, 44890625, 30525625, 61051250, 5928325, 303460625, 53955078125, 35409725, 100140625, 1289367675781250
Offset: 1
a(0) = 1 as 1 is the least positive integer not expressible as the sum of two squared positives.
a(1) = 2 from 2 = 1^2 + 1^2.
a(2) = 50 from 50 = 1^2 + 7^2 = 5^2 + 5^2.
- A. Beiler, Recreations in the Theory of Numbers, Dover, pp. 140-141.
-
Array[Block[{k = 1}, While[Length@ DeleteCases[PowersRepresentations[k, 2, 2], ?(! FreeQ[#, 0] &)] != #, k++]; k] &, 6] (* _Michael De Vlieger, Mar 31 2019 *)
-
b(k)=my(c=0);for(i=1,sqrtint(k\2),if(issquare(k-i^2),c+=1));c \\ A025426
for(n=1,10,k=1;while(k,if(b(k)==n,print1(k,", ");break);k+=1)) \\ Derek Orr, Mar 20 2019
Definition improved by several correspondents, Nov 12 2007
A093195
Least number which is the sum of two distinct nonzero squares in exactly n ways.
Original entry on oeis.org
5, 65, 325, 1105, 8125, 5525, 105625, 27625, 71825, 138125, 126953125, 160225, 1221025, 3453125, 1795625, 801125, 446265625, 2082925, 41259765625, 4005625, 44890625, 30525625, 30994415283203125, 5928325, 303460625, 53955078125, 35409725, 100140625
Offset: 1
-
b(k)=my(c=0);for(i=1,sqrtint((k-1)\2),if(issquare(k-i^2),c+=1));c \\ A025441
for(n=1,10,k=1;while(k,if(b(k)==n,print1(k,", ");break);k+=1)) \\ Derek Orr, Mar 20 2019
More terms from
Ant King, Dec 14 2009 and Feb 07 2010
A018782
Smallest k such that circle x^2 + y^2 = k passes through exactly 4n integer points.
Original entry on oeis.org
1, 5, 25, 65, 625, 325, 15625, 1105, 4225, 8125, 9765625, 5525, 244140625, 203125, 105625, 27625, 152587890625, 71825, 3814697265625, 138125, 2640625, 126953125, 2384185791015625, 160225, 17850625, 3173828125, 1221025, 3453125
Offset: 1
4225 = 5^2 * 13^2 is the smallest number all of whose prime factors are congruent to 1 modulo 4 with exactly 9 divisors, so a(9) = 4225. - _Jianing Song_, Apr 24 2021
-
(* This program is not convenient to compute huge terms - A054994 is assumed to be computed with maxTerm = 10^16 *) a[n_] := Catch[ For[k = 1, k <= Length[A054994], k++, If[DivisorSigma[0, A054994[[k]]] == n, Throw[A054994[[k]]]]]]; Table[a[n], {n, 1, 28}] (* Jean-François Alcover, Jan 21 2013, after Ray Chandler *)
-
primelist(d,r,l) = my(v=vector(l), i=0); if(l>0, forprime(p=2, oo, if(Mod(p,d)==r, i++; v[i]=p; if(i==l, break())))); v
prodR(n, maxf)=my(dfs=divisors(n), a=[], r); for(i=2, #dfs, if( dfs[i]<=maxf, if(dfs[i]==n, a=concat(a, [[n]]), r=prodR(n/dfs[i], min(dfs[i], maxf)); for(j=1, #r, a=concat(a, [concat(dfs[i], r[j])]))))); a
A018782(n)=my(pf=prodR(n, n), a=1, b, v=primelist(4, 1, bigomega(n))); for(i=1, #pf, b=prod(j=1, length(pf[i]), v[j]^(pf[i][j]-1)); if(bJianing Song, Apr 25 2021, following R. J. Mathar's program for A005179.
A000446
Smallest number that is the sum of 2 squares (allowing zeros) in exactly n ways.
Original entry on oeis.org
0, 25, 325, 1105, 4225, 5525, 203125, 27625, 71825, 138125, 2640625, 160225, 17850625, 1221025, 1795625, 801125, 1650390625, 2082925, 49591064453125, 4005625, 44890625, 2158203125, 30525625, 5928325, 303460625, 53955078125
Offset: 1
a(1) = 0 because 0 is the smallest integer which is uniquely a unique sum of two squares, namely 0^2 + 0^2.
a(2) = 25 from 25 = 5^2 + 0^2 = 3^2 + 4^2.
a(3) = 325 from 325 = 1^2 + 18^2 = 6^2 + 17^2 = 10^2 + 15^2.
a(4) = 1105 from 1105 = 4^2 + 33^2 = 9^2 + 32^2 = 12^2 + 31^2 = 23^2 + 24^2.
Cf.
A000448 (similar, but "in at least n ways").
Definition improved by several correspondents, Nov 12 2007
Showing 1-4 of 4 results.
Comments