This article page is a stub, please help by expanding it.
This article needs more work.
Please help by expanding it!
The
shell enumeration of
is a bijection (one-to-one and onto mapping) from
to
, where
.
[1]
If the
shell enumeration goes from
(0, 0) to
(1, 0) instead of
(0, 1), we just get the mirror image through the rising diagonal, thus swapping the
and
coordinates.
Points on the
-th shell:
[s (k ) .. s (k + 1) − 1] = [k 2 .. (k + 1) 2 − 1], k ≥ 0, |
- -th shell (first points):
[s (k ) .. o (k ) − 1] = [k 2 .. k (k + 1) − 1], k ≥ 1, |
- -th shell (last points):
[o (k ) .. s (k + 1) − 1] = [k (k + 1) .. (k + 1) 2 − 1], k ≥ 1, |
where
are
square numbers and
are
oblong numbers.
Shell enumeration of
⮝
⮞
⮟
⮞
⮝
⮝
⮜
⮜
⮝
⮞
⮞
⮞
⮟
⮟
⮟
⮞
⮝
⮝
⮝
⮝
⮜
⮜
⮜
⮜
⮝
⮞
⮞
⮞
⮞
⮞
⮟
⮟
⮟
⮟
⮟
⮞
⮝
⮝
⮝
⮝
⮝
⮝
⮜
⮜
⮜
⮜
⮜
⮜
⮝
⮞
⮞
⮞
⮞
⮞
⮞
⮞
⮟
⮟
⮟
⮟
⮟
⮟
⮟
⮞
⮝
⮝
⮝
⮝
⮝
⮝
⮝
⮝
⮜
⮜
⮜
⮜
⮜
⮜
⮜
⮜
⮝
⮞
⮞
⮞
⮞
⮞
⮞
⮞
⮞
⮞
⮟
⮟
⮟
⮟
⮟
⮟
⮟
⮟
⮟
|
|
|
The
-th shell has
points, giving a total of
points for the first
shells,
.
{{(0, 0)}, {(0, 1), (1, 1), (1, 0)}, {(2, 0), (2, 1), (2, 2), (1, 2), (0, 2)}, {(0, 3), (1, 3), (2, 3), (3, 3), (3, 2), (3, 1), (3, 0)}, {(4, 0), (4, 1), (4, 2), (4, 3), (4, 4), (3, 4), (2, 4), (1, 4), (0, 4)}, {(0, 5), (1, 5), (2, 5), (3, 5), (4, 5), (5, 5), (5, 4), (5, 3), (5, 2), (5, 1), (5, 0)}, {(6, 0), (6, 1), (6, 2), (6, 3), (6, 4), (6, 5), (6, 6), (5, 6), (4, 6), (3, 6), (2, 6), (1, 6), (0, 6)}, ...}
Zero indexed sequence of
pairs of the
shell enumeration of
.
{(0, 0), (0, 1), (1, 1), (1, 0), (2, 0), (2, 1), (2, 2), (1, 2), (0, 2), (0, 3), (1, 3), (2, 3), (3, 3), (3, 2), (3, 1), (3, 0), (4, 0), (4, 1), (4, 2), (4, 3), (4, 4), (3, 4), (2, 4), (1, 4), (0, 4), (0, 5), (1, 5), (2, 5), (3, 5), (4, 5), (5, 5), (5, 4), (5, 3), (5, 2), (5, 1), (5, 0), (6, 0), (6, 1), (6, 2), (6, 3), (6, 4), (6, 5), (6, 6), (5, 6), (4, 6), (3, 6), (2, 6), (1, 6), (0, 6), ...}
A319514 The shell enumeration of
where
, also called boustrophedonic Rosenberg-Strong function. Terms are interleaved
and
coordinates.
-
{0, 0, 0, 1, 1, 1, 1, 0, 2, 0, 2, 1, 2, 2, 1, 2, 0, 2, 0, 3, 1, 3, 2, 3, 3, 3, 3, 2, 3, 1, 3, 0, 4, 0, 4, 1, 4, 2, 4, 3, 4, 4, 3, 4, 2, 4, 1, 4, 0, 4, 0, 5, 1, 5, 2, 5, 3, 5, 4, 5, 5, 5, 5, 4, 5, 3, 5, 2, 5, 1, 5, 0, 6, 0, 6, 1, 6, 2, 6, 3, 6, 4, 6, 5, 6, 6, 5, ...}
Sequences pertaining to pairs of the shell enumeration of
|
Sequence |
A-number
|
|
{0, 0, 1, 1, 2, 2, 2, 1, 0, 0, 1, 2, 3, 3, 3, 3, 4, 4, 4, 4, 4, 3, 2, 1, 0, 0, 1, 2, 3, 4, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 5, 4, 3, 2, 1, 0, 0, 1, 2, 3, 4, 5, 6, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 7, 6, 5, 4, 3, 2, 1, 0, 0, 1, 2, 3, 4, 5, ...}
|
A319289
|
|
{0, 1, 1, 0, 0, 1, 2, 2, 2, 3, 3, 3, 3, 2, 1, 0, 0, 1, 2, 3, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 4, 3, 2, 1, 0, 0, 1, 2, 3, 4, 5, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 6, 5, 4, 3, 2, 1, 0, 0, 1, 2, 3, 4, 5, 6, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, ...}
|
A319290
|
|
{0, 1, 0, 1, 0, 0, −1, −1, 0, 1, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, −1, −1, −1, −1, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, ...}
|
A??????
|
|
{1, 0, −1, 0, 1, 1, 0, 0, 1, 0, 0, 0, −1, −1, −1, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, −1, −1, −1, −1, −1, 0, ...}
|
A??????
|
Pairing function
ℕ → ℕ × ℕ
For
:
(0, 0);
For
:
- (first points):
- (last points):
- (first points):
- (last points):
where
is the shell index,
t (n) = ⌊ n / o (k (n)) ⌋ |
yields either
0 (first
points of shell) or
1 (last
points of shell).
This can be rewritten in a one liner as (where the row vector is right-multiplied by [either identity or swap] matrix)
( x, y) = (0, 0) + [n ≥ 1] { [t (n) = 0] (n mod s (k (n)), k (n)) + [t (n) = 1] (k (n), k (n) − {n − o (k (n))}) } k (n) mod 2 | | 1 − {k (n) mod 2} |
1 − {k (n) mod 2} | | k (n) mod 2 |
, |
where
is the
Iverson bracket.
ℕ × ℕ → ℕ
With nonnegative shell index given by
:
- If
x = k : n = (k + 1) 2 − 1 − y |
;
- If ;
- If : (even indexed shell)
- If ;
- If
y = k : n = (k + 1) 2 − 1 − x |
.
This can be rewritten in a one liner as
n = [k mod 2 ≡ 1] { [x = k ] ((k + 1) 2 − 1 − y) + [ y = k ] (k 2 + x) } + [k mod 2 ≡ 0] { [x = k ] (k 2 + y) + [ y = k ] ((k + 1) 2 − 1 − x) }, |
where
and
is the
Iverson bracket.
Shell enumeration path
Shell enumeration path expressed with absolute headings
As the shell enumeration of all complex numbers with nonnegative integer real part and imaginary part.
We can have the sequence of absolute headings before each move along the
shell enumeration path expressed by the exponents
{0, 1, 2, 3} = {right, up, left, down}, i.e. exponents
{0, 1, 2, 3} of
:
.
For each shell
, sequence of absolute headings before each move along path of
shell enumeration of all complex numbers with nonnegative integer real part and imaginary part.
- {{1, 0, 3}, {0, 1, 1, 2, 2}, {1, 0, 0, 0, 3, 3, 3}, {0, 1, 1, 1, 1, 2, 2, 2, 2}, {1, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3}, {0, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2}, {1, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 3, 3}, ...}
A?????? Zero indexed sequence of absolute headings before each move along path of shell enumeration of all complex numbers with nonnegative integer real part and imaginary part.
-
{1, 0, 3, 0, 1, 1, 2, 2, 1, 0, 0, 0, 3, 3, 3, 0, 1, 1, 1, 1, 2, 2, 2, 2, 1, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 0, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 1, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, 3, 3, 3, ...}
Shell enumeration path expressed with relative headings
As the shell enumeration of all complex numbers with nonnegative integer real part and imaginary part.
We can have the sequence of relative headings before each move along the
shell enumeration path expressed by the exponents
{ − 1, 0, +1} = {clockwise, forward, counterclockwise}, i.e. exponents
{ − 1, 0, + 1} of
:
used as multiplicand.
If we consider the absolute heading to be initially to the left (
) when at initial point
(0, 0), and see
(0, 0) as the completed
0-th shell, then
- for , when the -th shell is completed, the 2 successive relative headings after completing points are
{( − 1) n +1, ( − 1) n +1}, n ≥ 0 |
;
- for , after completing
(n + 1) 2 − n = n 2 + n + 1 |
points, the relative heading for next move is ;
- for all other points, the relative headings are 0.
For each shell
, sequence of relative headings before each move along path of
shell enumeration of all complex numbers with nonnegative integer real part and imaginary part. (We consider the absolute heading to be initially to the left (
) when at
(0, 0).)
- {{ − 1, − 1, − 1}, {1, 1, 0, 1, 0}, { − 1, − 1, 0, 0, − 1, 0, 0}, {1, 1, 0, 0, 0, 1, 0, 0, 0}, { − 1, − 1, 0, 0, 0, 0, − 1, 0, 0, 0, 0}, {1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0}, { − 1, − 1, 0, 0, 0, 0, 0, 0, − 1, 0, 0, 0, 0, 0, 0}, ...}
A?????? Zero indexed sequence of relative headings before each move along path of
shell enumeration of all complex numbers with nonnegative integer real part and imaginary part. (We consider the absolute heading to be initially to the left (
) when at
(0, 0).)
-
{−1, −1, −1, 1, 1, 0, 1, 0, −1, −1, 0, 0, −1, 0, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, −1, −1, 0, 0, 0, 0, −1, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, −1, −1, 0, 0, 0, 0, 0, 0, −1, 0, 0, 0, 0, 0, 0, ...}
Shell enumeration of ℕ × ℕ × ℕ
Is it possible to do a
shell enumeration of
as a bijection (one-to-one and onto mapping) from
to
, where
?
See also
Notes