searching for +/-1 sequences
Mitchell Harris
harris at tcs.inf.tu-dresden.de
Thu Jan 20 17:07:33 CET 2005
On Thu, 20 Jan 2005, Eric W. Weisstein wrote:
>Perhaps a dumb question, but how do I search OEIS for sequences containing
>a given sequence of +1 and -1s? If I use superseeker, it matches every
>sequence in which the *absolute value* of the terms is 1. If I try to do
>a word search on OEIS including minus signs (e.g., "-1,-1") I get no hits.
>If I just search for 1,1,1,1,1,..., I get a maximum of 30 hits, so I have
>no guarantee that just because I don't *see* my sequence in the 30
>returned, mine isn't #31.
>
>Concrete example: is the following sequence in OEIS or not (it arises from
>Gauss's generalization of Wilson's theorem)?
>
>-1, -1, -1, -1, -1, -1, 1, -1, -1, -1, 1, -1, -1, 1, 1, -1, -1, -1, 1, 1,
>-1, -1, 1, -1, -1, -1, 1, -1, 1, -1, 1, 1, -1, 1, 1, -1, -1, 1, 1, -1, 1,
>-1, 1, 1, -1, -1, 1, -1, -1, 1, 1, -1, -1, 1, 1, 1, -1, -1, 1, -1, -1, 1,
>1, 1, 1, -1, 1, 1, 1, -1, 1, -1, -1, 1, 1, 1, 1, -1, 1, -1, -1, -1, 1, 1,
>-1, 1, 1, -1, 1, 1, 1, 1, -1, 1, 1, -1, -1, 1, 1
>
>If it is, how do I actually find that out besides downloading the entire
>database and searching it myself? I checked but didn't see this in the
>FAQ.
This is not exactly what you're looking for but it may give some leads:
do the transformation (a(n) + 1)/2. turns it into a 0,1 sequence and
searching I get A011675 and A011731.
Mitch
More information about the SeqFan
mailing list