Deciphering Skelet's BL_Proof

Background:
Skelet’s bbfind is the Swiss-Army Gun of decider programs.
One of its methods, BL_Proof, gets two beavers of extreme difficulty. (The Finite Automata Reduction decider is either too slow or useless, HS/CPS are useless, and zoology-based deciders besides this Skelet one don’t apply.)

bbfind be tested via @Wizord’s adaptation: something like fpc -O3 bbfind-stdin.pp to build it with the Free Pascal Compiler, and echo 1RB0RB_1RC0LB_1LD1RE_1LB0LD_0RA--- | ./bbfind-stdin > 4049716.out to run it and capture the proof. It is then necessary to clean up the inconsistent usage of carriage-return characters, and to carefully undo the line breaking if the next step is to parse rather than print it.

Skelet describes the method as follows:

linear-binary sequence: In this case k is unlimited, there is only 1 exone, number of different intrones is limited by some small constant B.
If we ignore exone sequences (e|n), the remaining part of the tape form some B-nary counter during the tape transitions.
Infinitness of these machines is proved by the procedure TryBL_Proof.

It’s a nice explanation, except for being false, so actually let’s ignore it. Once a proof is fully reverse engineered, a “besides those exons, which don’t count” interpretation of these words, which is not false, may become available.

The non-status output for https://bbchallenge.org/4049716 starts with

List of the Special  rules:
 ind   p   c               pattern1       pattern2
   7   2   8:           *--+C>(--)* -> *(++)--+C>*          sp> 
   9  -2   2:              *(++)<B* -> *<B(--)*             sp> 

These represent rewrite-rules which you can get by composing multiple TM transitions, are chainable, and are used below. The rule-index numbers in the “ind” are reused below to show where these rules are applied. Here, - means 0 and + means 1. The C> and <B are widespread oriented-head notations. Parentheses are simply grouping, but they also show what repeats n times when you form the n-fold composition of the rule. The symbol * just means arbitrary tape content (so long as it’s consistent on both sides of the ->) — for now. In other words, these are infix rewrite rules for the TM.

Next, First 400 macro steps are given. A macro step is the application of one of the above rules (if possible) or else a direct TM transition. This section is not essential to the proof, but it illustrates some features of Skelet’s simulation.
It also shows a notational point, literally: the . is notation for an edge of a config. (We’re no longer dealing with infixes.)
Anyway, first it introduces something Skelet mentions on the homepage: “Notation ‘(a|n)’ means that word a is repeated n times on tape.” This notation is used on-demand, when one of “the Special rules” leaves an instance behind. Second, there’s a curious variation, where it’s instead written like (n|a) in left-of-head occurrences. This is an internal implementation detail leaking out: the program internally stores tape content with a consistent head-to-edge ordering. Outputting it that way is out of the question, since there’s a clear orthography for TM configs, so this is “fixed” using mirror-writing on the left side. It’s mainly important to understand this quirk in other settings, where the “n” expressions can involve multi-digit numbers or non-commutative operations, and you’re fucked if you take the notation at face value.

Next up, the victorious BL_Proof succeed ! and some definitions:

Left * consists of the expressions:  
  a=+-++++--(++|p+3)  
  b=--(++|p+3)  

Right * consists of the expressions:  
  a=+--+-+(--|p+3)  
  b=+----+-(--|p+3)  
  c=+-+-+--++-(--|p+3)  
  d=+-+-(--|p+2)  

So now the * notation will refer to a repetition. Like a Kleene-star, though based on what follows the * pattern means one or more occurrences.
Remember how I said that violating the orthography is out of the question, and internally reversed left-tape configs will be “fixed” by mirror-writing? Well, not here, because fuck you.
So: from now on, a * symbol on the head’s left stands for the same pattern as the regexp ((11){3,}00111101 | (11){3,}00)+, and a * symbol on the head’s right stands for the same pattern as the regexp (100101(00){3,} | 1000010(00){3,} | 1010100110(00){3,} | 1010(00){2,})+.

Next, Closed transition graph proof follows:
I believe this can pretty much be taken at face value.
Once the * definition is figured out, the only real decision to make is where to start building a closed language.
Skelet’s program found this to be an advantageous choice:

 ind rule                      LsdR
   0   -1:                       .<A.  -->  .*<B(--|p+3)+--+-+--+--+.

The (composite) transitions between configs in the closed language are numbered here, with an indicator of “the Special rule” used (if any). LsdR hopefully stands for left/state/direction/right.
When you add a transition, the “after” side of it should always show the head entering a *.
If this * pattern “consists of” B expressions—in this case B=2, based on the Left * definition—we need to have transitions defined for 2B specific patterns that * can represent (depending on which sub-expression the head is running into, and whether or not there additional repetitions beyond that).
Indeed, 4 lines follow, with
.*(3+p|++)--++++-+<B(--|p+3)+--+-+--+--+.,
. (3+p|++)--++++-+<B(--|p+3)+--+-+--+--+.,
.*(3+p|++)-- <B(--|p+3)+--+-+--+--+.,
. (3+p|++)-- <B(--|p+3)+--+-+--+--+.
before the -->. (Spacing added to show the pattern.)
Each time we need to add a transition, we should be able to simulate the “before” side until the head is about to enter a *, making that the “after” side and continuing until the transition graph is closed.

Note that this process (expanding a *, in particular) may add a pattern like (++|p+3) onto a tape which already contains a pattern using the variable p. An example in this proof is the line
178 7: .(3+p|++)--+C>+-+-+--++-(--|p+3)+-+-+--++---+--+-+--+--+. --> .*(3+p|++)--++++-+<B(--|p+3)+----+---+--+.
Because of where these expressions came from, we should understand the 2 p variables on the same tape to be independent. (Of course, the first p on the “before” side corresponds to the first p on the “after” side, ditto the second.)

For the 2 machines which (so far) need this, I’m seeking to translate this output into a CTL representation which will be hundreds of times easier to parse and verify.

And finally, does Skelet’s homepage description of the method work better in hindsight?
Maybe, if the one-exon-B-introns description is understood to apply independently to the two sides of the tape. So (++) would be the one exon on the left, and (--) would be the one exon on the right.
Pursuing the interpretation further might make sense for anyone trying to get a rule-proving decider to handle these critters… which could have a greater benefit than 2 TMs if CPSable TMs also count, or for going beyond BB5.

1 Like

I was able to verify Skelet’s proofs for these machines… enough.
For posterity, here is a garbage Python script for converting the Closed Transition Graph section of these TMs in particular.
parse_bl_proof.py (8.9 KB)
There shouldn’t be any obstacle to adapting it for other machines, after teaching it to parse “the Special rules” sections or otherwise figure that part out instead of hard-coding it.
Fortunately, it verified every transition in the graphs emitted by Skelet’s program, outputting files in the SymbolicTM format for verification of closure properties.
Unfortunately, the output doesn’t actually pass SymbolicTM’s validation.
Fortunately, my frans_faase_to_dfa utility can translate these output files to MitM-DFA pairs.
Unfortunately, these DFA pairs were definitely wrong.
Fortunately, they were only half-broken: in each case, one side was fine, and the “FAR direct” algorithm was able to complete the proof. I then determinized and reduced to get proper MitM-DFA proofs.

Edited to add: By mistake, the below aren’t good DFA pairs, but rather, best working left- and right-DFA. (The sides each complete to a good FAR solution, and actual MitM-DFA solutions will be given in a later reply.)

Beaver: https://bbchallenge.org/3844064
Left-side DFA transition table: [0, 1, 2, 3, 4, 3, 3, 3, 5, 6, 3, 7, 8, 3, 3, 3, 9, 10, 11, 12, 13, 3, 14, 15, 15, 3, 3, 16, 3, 3, 17, 18, 19, 12, 20, 21, 22, 3, 16, 23, 23, 3, 24, 3, 25, 3, 26, 27, 28, 3, 3, 29, 30, 31, 32, 3, 33, 3, 34, 3, 22, 3, 35, 3, 36, 3, 3, 37, 38, 23, 39, 28, 3, 6, 3, 3, 19, 12, 40, 3, 38, 41, 42, 3, 3, 31]
Right-side DFA transition table: [0, 1, 2, 3, 2, 2, 4, 5, 6, 7, 2, 8, 2, 9, 2, 10, 11, 12, 2, 13, 2, 14, 15, 16, 2, 17, 18, 19, 20, 21, 2, 22, 2, 23, 24, 25, 6, 26, 2, 8, 2, 27, 2, 2 , 2, 3, 2, 28, 15, 29, 2, 17, 2, 10, 2, 2, 30, 31, 2, 32, 33, 34, 27, 35, 2, 14, 2, 1, 2, 10, 36, 5, 6, 29]

Beaver: https://bbchallenge.org/4049716
Left-side DFA transition table: [0, 1, 2, 3, 4, 4, 5, 6, 4, 4, 7, 8, 9, 10, 4, 11, 4, 12, 4, 13, 14, 15, 4, 16, 4, 17, 4, 4, 18, 19, 4, 20, 21, 22, 23, 24, 4, 25, 4, 26, 27, 28, 7, 29, 4, 30, 4, 31, 4, 4, 4, 32, 4, 33, 18, 34, 4, 20, 4, 12, 14, 15, 4, 31, 35, 36, 37, 38, 4, 39, 7, 40, 4, 30, 41, 42, 4, 43, 4, 44, 4, 12, 4, 2, 2, 12, 45, 6, 9, 24, 7, 34]
Right-side DFA transition table: [0, 1, 2, 3, 4, 5, 3, 3, 6, 7, 8, 9, 10, 11, 12, 3, 13, 14, 15, 3, 3, 3, 8, 9, 16, 17, 18, 3, 19, 3, 20, 3, 21, 22, 23, 3, 24, 3, 25, 26, 3, 27, 10, 28, 29, 3, 3, 30, 3, 31, 32, 3, 33, 3, 34, 3, 35, 36, 37, 36, 38, 39, 40, 3, 41, 42, 3, 43, 44, 18, 45, 46, 18, 3, 47, 46, 30, 5, 28, 3, 41, 5, 38, 39, 48, 3 , 3, 3, 3, 3, 5, 3, 49, 3, 5, 43, 3, 14, 26, 3]

This is indeed hundreds of times simpler than the BL_Proof data, so I’m not too fussed about what caused the recoverable errors above. Today I’m happy moving on to filing my taxes – a comparatively peaceful and relaxing activity.
I may come back later with graphics showing the DFA pairs and colorized spacetime diagrams (like on this Discord thread).

3 Likes

I tried to verify these MitM-DFA proofs and was unable to do it. For the first pointy machine I manually verified a path from A0,0,0 to halt that was found by my verifier.

Allows for the path

A0,0,0
B0,1,0
C1,0,1
D0,0,3
E0,0,4
B0,0,7
C0,0,10
A1,1,26
A1,2,18
A0,4,13
B1,6,9
B1,8,6
B0,9,4
C0,8,7
A1,10,4
A0,13,3
B1,16,22
B1,19,15
B0,16,11
C1,13,16
D0,10,23
E1,8,2
B0,6,2
C1,4,2
D0,2,2
E0,1,2
B1,0,2
B0,0,27
C0,0,2
A0,1,33
B0,3,30
C1,3,34
D1,3,10
halt

So have I made a mistake somewhere or are the DFAs here wrong?

I noticed a mistake this morning: the left and right DFAs are individually good but not compatible with each other. (I called a MitM validator function wrong before posting.)
I can’t compute full pairs until after work.
Meanwhile, either half can be chucked into a DVF and verified. (That can be determinized to give a pair, but it will result in hundreds of states on the 2nd side, whereas ~50 should be enough.)

Wow, @Iijil, so far I’m only getting successful MitM-DFA solutions that are badly pessimized on one of the two sides. (I suspect that means there’s a lot of room for improvement, but the search space is intimidating.)
So I’ll just give two pairs per beaver.

I think I’ll hold off on diagramming until I’m sure I can’t bait @mateon1 (or myself) into optimizing more thoroughly.

  • 3844064

    • Solution A (shortest side overall):

      /*@241*/ [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 3, 11, 12, 13, 7, 14, 15, 16, 7, 17, 5, 18, 19, 20, 21, 22, 23, 24, 1, 6, 7, 25, 26, 8, 27, 28, 29, 30, 7, 31, 32, 33, 34, 35, 36, 37, 21, 38, 39, 40, 41, 42, 43, 44, 3, 45, 46, 47, 34, 48, 49, 50, 51, 52, 7, 53, 54, 34, 34, 55, 29, 56, 7, 57, 32, 58, 43, 59, 3, 60, 61, 62, 7, 63, 64, 65, 7, 66, 5, 67, 23, 68, 3, 69, 54, 70, 3, 71, 43, 72, 73, 74, 21, 75, 23, 76, 77, 78, 34, 79, 80, 81, 49, 50, 82, 83, 3, 84, 5, 52, 46, 85, 29, 86, 12, 87, 27, 88, 3, 89, 12, 90, 41, 91, 7, 92, 39, 76, 93, 94, 61, 95, 64, 96, 29, 97, 7, 98, 32, 35, 99, 100, 34, 101, 34, 102, 34, 103, 21, 104, 3, 105, 106, 107, 34, 38, 108, 8, 109, 110, 111, 112, 113, 58, 106, 114, 5, 18, 115, 116, 117, 75, 118, 119, 120, 121, 34, 35, 80, 87, 109, 79, 122, 123, 23, 124, 125, 126, 3, 127, 128, 100, 34, 34, 129, 130, 7, 131, 39, 132, 133, 65, 7, 134, 54, 59, 3, 135, 7, 136, 21, 137, 7, 138, 23, 139, 7, 140, 27, 141, 7, 142, 1, 2, 3, 37, 21, 83, 15, 143, 7, 144, 145, 104, 3, 35, 100, 146, 122, 147, 34, 38, 39, 148, 149, 150, 34, 151, 21, 123, 118, 119, 106, 79, 80, 152, 128, 153, 154, 155, 12, 130, 156, 157, 23, 52, 46, 158, 49, 14, 3, 159, 23, 0, 117, 160, 26, 161, 29, 162, 100, 163, 29, 164, 54, 78, 34, 165, 21, 166, 34, 167, 100, 168, 169, 170, 149, 171, 34, 112, 172, 13, 7, 173, 73, 70, 174, 52, 156, 175, 109, 176, 61, 177, 178, 179, 180, 153, 181, 182, 100, 34, 183, 151, 21, 184, 93, 185, 34, 186, 128, 187, 34, 188, 7, 55, 189, 190, 7, 191, 133, 78, 34, 167, 73, 192, 21, 67, 118, 68, 3, 193, 34, 177, 21, 194, 34, 195, 128, 196, 34, 197, 198, 127, 199, 200, 23, 47, 34, 201, 26, 45, 46, 202, 32, 203, 145, 204, 145, 197, 205, 206, 129, 207, 208, 209, 21, 210, 34, 52, 211, 175, 9, 212, 82, 161, 213, 214, 21, 209, 21, 34, 215, 195, 128, 165, 21, 216, 100, 217, 145, 218, 7, 72, 100, 219, 34, 220, 221, 34, 34, 177, 222, 214, 222, 223, 49, 224, 225, 34, 34, 226, 128, 227, 34, 105, 120, 228, 229, 230, 100, 148, 231, 232, 225, 233, 221, 234, 34, 235, 178, 236, 34, 228, 82, 127, 128, 237, 225, 167, 99, 238, 34, 239, 125, 206, 34, 240, 61, 186, 128],
      /*@37*/ [0, 1, 2, 3, 2, 2, 4, 5, 6, 7, 2, 8, 2, 9, 2, 10, 11, 12, 2, 13, 2, 14, 15, 16, 2, 17, 18, 19, 20, 21, 2, 22, 2, 23, 24, 25, 6, 26, 2, 8, 2, 27, 2, 2, 2, 3, 2, 28, 15, 29, 2, 17, 2, 10, 2, 2, 30, 31, 2, 32, 33, 34, 27, 35, 2, 14, 2, 1, 2, 10, 36, 5, 6, 29],
      
    • Solution B (better balance):

      /*@43*/ [0, 1, 2, 3, 4, 3, 3, 3, 5, 6, 3, 7, 8, 3, 3, 3, 9, 10, 11, 12, 13, 3, 14, 15, 15, 3, 3, 16, 3, 3, 17, 18, 19, 12, 20, 21, 22, 3, 16, 23, 23, 3, 24, 3, 25, 3, 26, 27, 28, 3, 3, 29, 30, 31, 32, 3, 33, 3, 34, 3, 22, 3, 35, 3, 36, 3, 3, 37, 38, 23, 39, 28, 3, 6, 3, 3, 19, 12, 40, 3, 38, 41, 42, 3, 3, 31],
      /*@74*/ [0, 1, 2, 3, 2, 2, 4, 5, 6, 7, 2, 8, 2, 9, 10, 11, 12, 13, 2, 14, 2, 2, 15, 16, 17, 18, 2, 19, 20, 21, 22, 2, 23, 24, 2, 25, 2, 26, 27, 28, 29, 30, 2, 8, 2, 31, 32, 33, 33, 34, 2, 35, 15, 36, 17, 37, 2, 19, 38, 39, 10, 40, 2, 41, 2, 42, 2, 43, 15, 44, 45, 46, 47, 48, 2, 49, 50, 28, 2, 51, 2, 2, 52, 53, 2, 2, 2, 54, 2, 55, 29, 56, 2, 8, 57, 58, 33, 59, 15, 16, 60, 61, 62, 63, 2, 10, 2, 2, 2, 38, 33, 64, 10, 40, 2, 65, 10, 40, 66, 5, 2, 67, 10, 40, 22, 68, 2, 55, 2, 2, 2, 69, 6, 37, 2, 69, 10, 70, 71, 72, 2, 2, 22, 73, 2, 55, 10, 70],
      
  • 4049716

    • Solution A (shortest side overall):

      /*@46*/ [0, 1, 2, 3, 4, 4, 5, 6, 4, 4, 7, 8, 9, 10, 4, 11, 4, 12, 4, 13, 14, 15, 4, 16, 4, 17, 4, 4, 18, 19, 4, 20, 21, 22, 23, 24, 4, 25, 4, 26, 27, 28, 7, 29, 4, 30, 4, 31, 4, 4, 4, 32, 4, 33, 18, 34, 4, 20, 4, 12, 14, 15, 4, 31, 35, 36, 37, 38, 4, 39, 7, 40, 4, 30, 41, 42, 4, 43, 4, 44, 4, 12, 4, 2, 2, 12, 45, 6, 9, 24, 7, 34],
      /*@253*/ [0, 1, 2, 3, 4, 5, 6, 3, 7, 8, 9, 10, 11, 12, 13, 14, 15, 3, 16, 17, 18, 3, 19, 20, 21, 22, 23, 24, 25, 3, 26, 27, 28, 29, 30, 10, 31, 12, 32, 33, 34, 3, 35, 36, 22, 22, 37, 38, 25, 3, 39, 5, 40, 41, 42, 10, 43, 44, 45, 3, 46, 17, 47, 22, 48, 49, 50, 22, 51, 52, 53, 54, 55, 10, 37, 24, 25, 3, 56, 57, 58, 59, 60, 3, 61, 62, 63, 64, 65, 3, 66, 5, 67, 29, 68, 69, 70, 54, 71, 3, 72, 73, 74, 44, 75, 10, 76, 77, 78, 22, 53, 79, 80, 81, 82, 3, 83, 84, 85, 69, 86, 27, 87, 88, 30, 10, 89, 90, 91, 3, 92, 93, 94, 95, 43, 96, 31, 97, 98, 22, 99, 3, 100, 101, 102, 103, 104, 22, 105, 106, 107, 62, 108, 54, 18, 3, 109, 73, 110, 22, 111, 24, 91, 3, 112, 27, 113, 114, 115, 3, 116, 117, 118, 119, 43, 44, 120, 3, 43, 96, 121, 3, 122, 93, 123, 124, 125, 22, 13, 38, 126, 3, 65, 3, 21, 22, 127, 22, 128, 129, 130, 44, 131, 10, 132, 22, 133, 22, 134, 22, 48, 49, 135, 69, 87, 136, 76, 10, 102, 137, 138, 139, 140, 141, 40, 95, 142, 84, 143, 22, 144, 101, 145, 146, 147, 10, 58, 59, 148, 3, 149, 5, 150, 5, 123, 151, 152, 33, 153, 3, 154, 139, 155, 93, 22, 156, 76, 10, 157, 22, 63, 81, 107, 17, 158, 69, 159, 160, 22, 161, 162, 163, 164, 3, 165, 22, 166, 167, 168, 10, 169, 64, 71, 3, 170, 129, 171, 139, 130, 172, 173, 174, 175, 22, 176, 79, 177, 27, 178, 179, 56, 179, 180, 3, 181, 84, 182, 12, 183, 184, 185, 186, 187, 22, 188, 139, 31, 12, 189, 54, 190, 10, 191, 22, 47, 103, 192, 22, 193, 93, 194, 22, 195, 10, 196, 22, 197, 79, 198, 24, 19, 49, 183, 146, 199, 3, 170, 129, 6, 3, 200, 201, 202, 203, 204, 205, 80, 206, 207, 3, 208, 52, 209, 12, 210, 77, 195, 77, 211, 22, 212, 114, 213, 3, 214, 160, 183, 167, 215, 216, 53, 217, 218, 36, 219, 22, 220, 124, 221, 22, 222, 33, 223, 73, 76, 203, 89, 90, 224, 27, 225, 167, 226, 10, 108, 227, 228, 3, 229, 230, 231, 3, 91, 3, 232, 93, 233, 44, 173, 3, 32, 234, 235, 139, 83, 84, 236, 52, 237, 54, 22, 22, 238, 69, 110, 22, 108, 54, 239, 22, 152, 234, 22, 240, 48, 141, 241, 137, 242, 136, 243, 216, 197, 217, 78, 22, 244, 101, 181, 84, 135, 69, 245, 27, 185, 246, 105, 230, 50, 22, 247, 167, 233, 172, 215, 248, 31, 163, 22, 249, 22, 22, 132, 240, 229, 106, 158, 69, 43, 44, 204, 136, 250, 3, 195, 251, 238, 69, 22, 22, 252, 12, 18, 3, 210, 20],
      
    • Solution B (better balance):

      /*@80*/ [0, 1, 2, 3, 2, 2, 4, 5, 6, 7, 2, 8, 2, 9, 2, 10, 11, 12, 2, 13, 14, 15, 16, 17, 2, 18, 19, 5, 20, 2, 21, 22, 2, 23, 2, 24, 25, 26, 27, 28, 2, 29, 30, 31, 32, 33, 2, 34, 14, 35, 16, 36, 2, 18, 2, 37, 2, 38, 2, 39, 2, 40, 2, 41, 2, 42, 14, 43, 44, 45, 46, 47, 2, 48, 2, 49, 2, 2, 50, 51, 2, 2, 2, 2, 30, 52, 2, 53, 27, 54, 2, 8, 55, 56, 32, 57, 14, 58, 59, 60, 2, 61, 2, 2, 2, 62, 32, 63, 2, 38, 2, 64, 2, 65, 66, 67, 68, 22, 20, 69, 2, 53, 2, 2, 70, 26, 2, 2, 2, 71, 2, 2, 6, 36, 2, 8, 30, 72, 2, 73, 74, 75, 76, 77, 2, 2, 2, 2, 2, 78, 2, 65, 20, 79, 2, 53, 2, 71, 2, 73],
      /*@50*/ [0, 1, 2, 3, 4, 5, 3, 3, 6, 7, 8, 9, 10, 11, 12, 3, 13, 14, 15, 3, 3, 3, 8, 9, 16, 17, 18, 3, 19, 3, 20, 3, 21, 22, 23, 3, 24, 3, 25, 26, 3, 27, 10, 28, 29, 3, 3, 30, 3, 31, 32, 3, 33, 3, 34, 3, 35, 36, 37, 36, 38, 39, 40, 3, 41, 42, 3, 43, 44, 18, 45, 46, 18, 3, 47, 46, 30, 5, 28, 3, 41, 5, 38, 39, 48, 3, 3, 3, 3, 3, 5, 3, 49, 3, 5, 43, 3, 14, 26, 3],

Thanks for the effort!

3 of the new solutions work for me as well. The balanced 4049716 solution B doesn’t work. Looks like you missed the end of the right side DFA when you copied it to the forum.

Edit: The rest of the right side DFA appeared in the post above, now that solution works as well :slight_smile:

1 Like