Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
ds2-notes
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
datovky
ds2-notes
Commits
dbb630e7
Commit
dbb630e7
authored
3 years ago
by
Filip Stedronsky
Browse files
Options
Downloads
Patches
Plain Diff
Succinct: SOLE diagrams
parent
b160f3eb
No related branches found
No related tags found
No related merge requests found
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
fs-succinct/Makefile
+1
-0
1 addition, 0 deletions
fs-succinct/Makefile
fs-succinct/sole.asy
+18
-0
18 additions, 0 deletions
fs-succinct/sole.asy
fs-succinct/sole_even.asy
+8
-0
8 additions, 0 deletions
fs-succinct/sole_even.asy
fs-succinct/succinct.tex
+28
-0
28 additions, 0 deletions
fs-succinct/succinct.tex
with
55 additions
and
0 deletions
fs-succinct/Makefile
+
1
−
0
View file @
dbb630e7
TOP
=
..
TOP
=
..
PICS
=
sole sole_even
include
../Makerules
include
../Makerules
This diff is collapsed.
Click to expand it.
fs-succinct/sole.asy
0 → 100644
+
18
−
0
View file @
dbb630e7
import sole_common;
blocks(0 ... concat(array(6,"B"), new string[] {"...", "B", "EOF"}));
thruarrows(0,0,6);
thruarrows(0,7,2);
blocks(1 ... concat(array(6, "B+1"), array(1, "..."), array(2, "B+1")) );
mixarrows(1,0,6);
mixarrow(1, 7);
block(1, 9, "0");
blocks(2, "B", "B+3", "B-3", "B+6", "B-6", "B+9", "...", "B-i","B+j", "B-j");
thruarrow(2, 0);
mixarrows(2, 1, 6);
mixarrow(2, 8);
thruarrow(1, 9);
blocks(3 ... concat(array(6,"B"), array(1, "..."), array(3, "B")));
passlabel(0, "Add EOF");
passlabel(1, "Pass 1");
passlabel(2, "Pass 2");
This diff is collapsed.
Click to expand it.
fs-succinct/sole_even.asy
0 → 100644
+
8
−
0
View file @
dbb630e7
import sole_common;
blocks(0, "...", "B", "B", "EOF");
mixarrow(0, 1);
thruarrow(0,3);
blocks(1, "...", "B+i", "B-i", "B+j");
mixarrows(1, 0, 4);
blocks(2, "...", "B", "B", "B");
This diff is collapsed.
Click to expand it.
fs-succinct/succinct.tex
+
28
−
0
View file @
dbb630e7
...
@@ -156,6 +156,34 @@ possible input combinations).
...
@@ -156,6 +156,34 @@ possible input combinations).
We will use this kind of alphabet re-encoding by pair heavily in the SOLE
We will use this kind of alphabet re-encoding by pair heavily in the SOLE
encoding. The best way to explain the exact scheme is with a diagram:
encoding. The best way to explain the exact scheme is with a diagram:
\figure
[sole]
{
sole.pdf
}{}{
SOLE alphabet re-encoding scheme
}
There are two re-encoding phases. The first transforms blocks with alphabet
$
[
B
+
1
]
$
into blocks with variable alphabet sizes (of the form of alternating
$
[
B
+
3
k
]
$
,
$
[
B
-
3
k
]
$
). The second phase runs phase shifted by one block and converts
the variable-alphabet blocks into blocks with alphabet
$
[
B
]
$
.
What is the redundancy of this scheme? That depends on whether the original
number of blocks (after padding) is even or odd. Figure
\figref
{
sole
}
showed
the case for an odd number. For an even number, the ending is a little bit different
(fig.
\figref
{
sole
_
even
}
).
You can easily check that this is reversible: after decoding phase 2, the last block
will always be either 0 (for the odd case) or EOF (for the even case).
\figure
[sole_even]
{
sole
_
even.pdf
}{}{
SOLE alphabet re-encoding scheme
}
Now we can finally analyze redundancy. Let us count how the number of blocks
increases throughout the encoding passes.
\tightlist
{
o
}
\:
If the original length was a multiple of
$
b
$
, we must add one block to complete padding.
\:
We always add one block with EOF character.
\:
In the first pass, number of blocks does not increase.
\:
In the second pass, we may need to add an extra padding block to make number of blocks odd.
\endlist
In total, we add at most 3 blocks. Thus
$
r
(
n
)
\le
3
B
$
. That is a constant
and thus we have a succinct scheme.
\section
{
Succinct representation of arbitrary-alphabet strings
}
\section
{
Succinct representation of arbitrary-alphabet strings
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment