# sum of 1/A007504(n)

Jack Brennen jb at brennen.net
Tue May 15 02:25:46 CEST 2007

```On 5/14/07, Jon Schoenfield <jonscho at hiwaay.net> wrote:
> I'm
> running a program now to extend A054214 a little, but I doubt that any
> additional terms I provide will really make any difference to anybody's
> research.  :-)

Actually, A054214 is easy to extend.
Let k be the decimal length of n, then
n*10^k + n-1 = t^2
implying that
n*(10^k+1) = t^2 + 1
and
t^2 == -1 (mod 10^k+1).
This congruence is easy to solve and derive the corresponding n (if any) as
n = (t^2 + 1) / (10^k+1).

This is my PARI/GP program consisting of two procedures:
asqrt(x,m) giving a sorted list of all square roots of x modulo m
(currently only square-free modules are supported but that is enough
for this problem);
and A054214(k) giving all elements of A054214 with the decimal length k.

{ asqrt(x, m) = local(p, r, t);
r=[];
if(!issquare(Mod(x,m)),return(r));
p=factorint(m);
t=[];
l=matsize(p)[1];
for(i=1,l,
if(p[i,2]>1,error("Unsupported"));
t=concat(t,[sqrt(Mod(x,p[i,1]))]);
);
forvec(s=vector(l,i,[0,1]),
r=concat(r,[lift(chinese(vector(l,i,t[i]*(2*s[i]-1))))])
);
vecsort(r)
}

{ A054214(k) = local(m, r, l, s, n);
n=[];
m=10^k+1;
if(!issquare(Mod(-1,m)),return(n));
r=asqrt(-1,m);
for(i=1,length(r),
s=r[i];
if(s^2>10^(2*k-1)+10^(k-1),n=concat(n,[(s^2+1)\(10^k+1)]))
);
n
}

These are all elements of A054214 with the decimal length k<=20:

k=1: []
k=2: [82]
k=3: []
k=4: [8242, 9802]
k=5: []
k=6: [538277, 998002]
k=7: []
k=8: [77837026, 99980002]
k=9: []
k=10: [7922547265, 8643251345, 9223797610, 9999800002]
k=11: []
k=12: [106710893290, 453378226757, 491023832065, 945958034530, 999998000002]
k=13: []
k=14: [11916002265170, 15790977390245, 24917378001937, 25082758752026,
36315251812570, 42876876357697, 55141667630626, 57494707565842,
71575429603525, 80380481474437, 99999980000002]
k=15: []
k=16: [1030108269842402, 1290758693216005, 1329116691842530,
1671179123920897, 1721747847053930, 2046821432916101,
2102745444245602, 2931604960651205, 2998459298438722,
3422957942365585, 3495167568349570, 4037706151096577,
4105332628699010, 4611048308002501, 5899343990282245,
5981028502966882, 6076358904122501, 6588396819907345,
7416976053117317, 7523091923276770, 8320220561266945,
9877598315186065, 9999999800000002]
k=17: []
k=18: [110667110889332890, 177894637542994177, 334343483094150626,
445333778222667557, 829722574396235665, 999999998000000002]
k=19: []
k=20: [14406734516622089617, 14711953454516794897,
23126733804375988762, 26946208115698265125, 37999624707393507226,
38494325737498002026, 57149621078770203602, 74039945217138528226,
74729847804686979026, 99201679691968801522, 99999999980000000002]

It is not surprising that there are no solutions for odd k. For odd k,
10^k+1 is divisible by 11 but -1 is square non-residue modulo 11.

Max

The OEIS search engine can sort results by relevance. The sequences
that come up near the top are likely to be high-value targets. This
isn't an entirely reliable test, but I think it's the best available.
I just searched for a few sequence titles with Google, and got no
hits. You could also search for A-numbers; this would be helpful only
if there are many OEIS users creating links to sequences they're
interested in.

I suggest reinterpreting the keywords "hard" and "more" as follows:

I apply the keyword "hard" to a sequence only if
1) I have expended at least an hour of computer time looking for the
next term, and
2) I've thought about it carefully, and I find it very unlikely that
there's another algorithm that could find it a lot faster than mine.

I apply "more" if I think a sequence is worthy of further
computation. This is a highly subjective balancing of the importance
of the sequence against the expected difficulty of finding more
terms. Keep in mind that the page http://www.research.att.com/~njas/
interpret that as a goal, that every sequence on this list should
eventually be removed from it. So I don't think we should have
terms.

Regards,
David

BTW, here's a bit of irony: there are 34 sequences with both the
keywords "more" and "less". Fortunately there are none with both
"hard" and "easy".

```