turingmachines

package module
v0.0.0-...-6d97079 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 13, 2022 License: MIT Imports: 5 Imported by: 2

Documentation

Index

Constants

View Source
const DBENTRIES = 88664064
View Source
const DBFILEPATH = "all_5_states_undecided_machines_with_global_header"

Variables

This section is empty.

Functions

func CreateMacroMachine

func CreateMacroMachine(tm TuringMachine, blockSize int, backSymbols int, offset int) *macroMachine

func GetStandardTMFormat

func GetStandardTMFormat(tm TuringMachine) string

func GetTMTable

func GetTMTable(tm TuringMachine) string

Types

type Direction

type Direction bool
const (
	LEFT  Direction = false
	RIGHT Direction = true
)

func (Direction) String

func (d Direction) String() string

type State

type State interface {
	IsHalt() bool
	IsLoop() bool
	IsUndefined() bool
	String() string
	GetInt() int
}

type StateCollection

type StateCollection interface {
	NumStates() int
	GetState(int) State
	StartState() State
}

type Symbol

type Symbol interface {
	String() string
	GetInt() int
}

type SymbolCollection

type SymbolCollection interface {
	NumSymbols() int
	GetSymbol(int) Symbol
	Zero() Symbol
}

type TuringMachine

type TuringMachine interface {
	StateCollection
	SymbolCollection
	Transition(State, Symbol) (Symbol, Direction, State)
	NameString() string
}

func GetTMFromDBIndex

func GetTMFromDBIndex(dbFilePath string, index uint32) TuringMachine

func GetTuringMachineFromString

func GetTuringMachineFromString(tmString string) TuringMachine

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL