We are currently working on new rules for what content should and shouldn't be allowed on this website, and are looking for feedback! See Esolang:2026 topicality proposal to view and give feedback on the current draft.

Dubbelweal

From Esolang
Jump to navigation Jump to search

Dubbelweal is a two-dimensional turning tarpit by User:ChuckEsoteric08.

Description

The language works on a right-infinite tape which stores a single base-4 digit, from 0 to 3. It has two wheels, instruction wheel which is manipulated by the code and tape wheel which is manipulated by the instruction wherl. There are two types of commands: @ and everything else. If a character other than @ is executed it advances the instruction wheel once. If @ is executed it executes instruction on the instruction wheel. Instruction wheel has following commands:

  • turn - turn instruction pointer 45 degrees clockwise times the value of a current cell.
  • rot - rotates the Tape Wheel once.
  • exec - executes instruction at the tape wheel.

Tape wheel has following commands:

  • right - move tape pointer right.
  • left - move tape pointer left.
  • inc - increment current cell, wrapping around to 0 if it was 3.
  • out - output current cell's value as an integer
  • inp - input a single 4-bit digit into the current cell

Computational class

Dubbelweal is Turing-complete as it can simulate 4-bit Reversible Brainfuck. Program consist of insttructions translated as concatenated diagonal patterns.

  • Program starts with:
-@@-@-@
       \
        @
         @
          @
           \
            \          
  • > becomes:
\
 \
  @
   \
  • < becomes:
\
 @
  \
   @
    \
     \
      @
       @
        @
         @
          \
           \
  • + becomes:
\
 @
  @
   \
    @
     \
      \
       @
        @
         @
          \
           \
  • - becomes:
\
 @
  @
   \
    @
     @
      @
       \
        \
         @
          @
           @
            \
             \
  • . becomes:
\
 @
  @
   @
    \
     @
      \
       \
        @
         @
          \
           \
  • , (unless done on nonzero cell) becomes:
\
 @
  @
   @
    @
     \
      @
       \
        \
         @
          \
           \

Loops are a lot more harder to do (mainly due to it's large size) and you should wait for a bit until the translation of them would be put here.