Texts and tools for Neil Sloane's OEIS
The old advanced lookup was disabled, check out the
hints
for using the improved simple
lookup.
The Online Encyclopedia of Integer Sequences
(OEIS)
is an amazing collection with a community of SeqFans
in all parts of the world. Many of the contributors are professional
mathematicans, but there are also many amateurs and programmers like me. I'm
now starting to publish OEIS-related links, texts, and tools on this
page, in addition to the old Rexx scripts in
sources and Kedit macros in
Xedit structure.
The official URLs for sequences are very long. On my pages I use
shorter links like
http://purl.net/net/eisa/12345 for
sequence A012345.
See PURL for details about these redirections,
URLs containing # (aka fragments ) won't work as expected.
The following Rexx-scripts and KEDIT-macros are
more or less stable and documented. If you are a
SeqFan
and like Rexx you might be able to use some of these scripts on your system.
If you have Rexx but no Maple, Mathematica, or pari
see also my other sources: I used RxShell
and prime.cmd
(up to 1,000,000,000) to compute, check, or extend several sequences.
-
rxgeteis.cmd
loads the full
database
(May 2003: about 50 MB in 84 parts) extracting all lines between
(start) and (end). It creates files eis??.txt,
where ?? runs from 00 up to the last part. Additionally
you get eis-1.txt corresponding to
recent.txt
with the latest EIS additions. Please edit the download path for your
system, and replace
rxgeturl by a
similar invocation of wget, curl, or Lynx.
-
stu.cmd
translates a sequence into the
internal
format almost ready for a submission by mail. On an OS/2 system you should
have clipbrd.exe, or replace clipbrd by clipbrd2
distributed with Lynx. On other systems stu can also
write on the standard output device. There's an intentionally
"undocumented" feature, if stu gets only one term as
argument, then the term is formatted as continued fraction. If you trust
in stu's algorithm - a bad idea unless you have many digits - add
the keyword cofr manually.
-
eis.kex
allows to edit a local copy of the complete database in the form created
by rxgeteis. This is only interesting if
you have Kedit or a similar editor, something
like grep, and a local copy of the OEIS database
in one or more parts. For a very fast access on sequence numbers
eis.kex creates an index in ctags-style (May 2003:
about 3 MB). You can also search for regular expressions with
eis.kex, all matching lines are displayed in ctags-style
recognized by my version of the Alt-X macro.
The following tools can be used to check and optionally patch some obvious
problems in the complete database. Please modify the extension and header
#! /usr/common/bin/gawk -f for your system, e.g. rename
.awk to .cmd and use
EXTPROC gawk.exe -f on an OS/2 system. For details about
the keywords see the OEIS
FAQ.
If you're only interested in serious problems try something like...
testmore.awk file¦testsign.awk¦testterm.awk¦testlink.awk>/dev/null
...and then evaluate report_more, report_sign,
report_term, and report_link manually. This should also work
for small collections of sequences in any file.
-
testmore.awk
adds (removes) keyword bref in sequences with less
(more) than four terms ignoring dead
or dupe sequences. Keyword more is
not checked in hard, obscure, or
unknown sequences. It's automatically removed from
full sequences: there are no more terms.
It's also removed from remaining sequences, if the total length of all
terms in characters (signs, digits, and commata) plus the length
of the last term is greater than 200.
The code to add more in the opposite case exists, but is
still disabled. Almost 10,000 sequences (May 2003) are not marked as
dead, dupe, full,
hard, obsc, unkn,
or more, where the third line of terms is empty and no
term is longer than 30 digits. In some of these cases adding
more automatically would be no good idea, because the
next term might be known to execeed any reasonable line length limit.
-
testsign.awk
adds (removes) keywords nonnegative
(signed) in
sequences with(out) signed terms. The special case of a sequence without
signed terms marked as sign but not nonn
is only reported, because the signed terms may start later, see
A057752 resp. comparisons of
approximations
to pi(x). Again dead or dupe
sequences are not checked.
-
testterm.awk
strips leading zeros from all terms. If signed terms exist, their absolute
values are compared with the corresponding unsigned terms. All conflicts
are reported. The frequent and simple problem missing unsigned terms
at the end can be patched automatically.
-
testdead.awk
checks this new rule: Either an %Aline
(author) or keyword dead should exist.
Maybe I'll add this simple test to one of the other scripts later. For now
testdead.awk also reports very long lines. Found problems are
only reported, but you can still use this script in pipes, all input lines
are copied to stdout.
-
testlink.awk
extracts all different links found in %H A012345
lines, the result can be used to check links. Any link not starting with
either http:// or ftp:// is reported as error, there are
yet no other valid links in the database. Empty link texts (no hot spot)
are also reported as error. Valid links are listed with the A-number and
text of their first occurence, and show the total number of occurences.
-
test_eis.cmd is
a simple OS/2 REXX wrapper applying the five test????.awk scripts
on all parts of the database. The output file test_eis.html
created by the last filter gawk -f testlink.awk could
be used with a link checker.
-
showtabl.c was used
as CGI-program to display sequences with keyword tabl
formatted as triangle resp. array. The latest version is also used to show
constants and a simple table of all terms.
Below you find some external links formerly listed in my
bookmarks > fun > numbers section.
Last update: 30 Jul 2003 16:00 by F.Ellermann