Package

in.tamchow

turing

Permalink

package turing

Visibility
  1. Public
  2. All

Type Members

  1. final case class MoveDirection extends Product with Serializable

    Permalink

    Represents a direction in which the tape head can move

  2. final case class StepData(continue: Boolean, nextHead: Option[Int], nextState: String, tape: Seq[String]) extends Product with Serializable

    Permalink

    Contains the data for one step in the run of this UniversalTuringMachine

    Contains the data for one step in the run of this UniversalTuringMachine

    continue

    an indicator whether to continue for the next step

    nextHead

    the tape head index after this step

    nextState

    the state of this UniversalTuringMachine after this step

    tape

    the tape of this UniversalTuringMachine as soon as this step has completed

  3. final case class TuringCommand extends Product with Serializable

    Permalink

    Denotes a possible command of a UniversalTuringMachine

  4. final class UniversalTuringMachine extends AnyRef

    Permalink

    Represents an UniversalTuringMachine object

Value Members

  1. object MoveDirection extends Serializable

    Permalink

    Indicates the directions in which the tape head can move:

    Indicates the directions in which the tape head can move:

    1. MoveDirection.Left -> Left (head index - 1)

    2. MoveDirection.Right -> Right (head index + 1)

    3. MoveDirection.Neither -> Neither left nor right (head index +/- 0 = head index)

  2. object StringUtils

    Permalink

    Minor String utilities

  3. object TuringCommand extends Serializable

    Permalink

    Encapsulates a single possible operation of a Turing Machine, but here I call it the "Command"

  4. object TuringMain

    Permalink

    The Launcher for the Universal Turing Machine simulator

    The Launcher for the Universal Turing Machine simulator

    The parameters are, in order:

    1. The input file path

    2. The tape size

    3. The number of steps for which to run the program. Leave it negative to run it till it halts.

    4. The number of milliseconds to pause before starting the next step. Leave this negative to pause for user input before every step.

    All these parameters are required.

    Only supports program input as files.

  5. object UniversalTuringMachine

    Permalink

    Represents a universal Turing Machine

Ungrouped