machine

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Oct 4, 2019 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidCountQubit = fmt.Errorf("Invalid count qubit in config and init state")
)
View Source
var (
	ErrInvalitSymbol = fmt.Errorf("Invalid symbol in state register, valid [0|1]")
)

Functions

func NewRegister

func NewRegister(cfg *config.Register, state []Bit) (r *register, err error)

Types

type Bit

type Bit int
var (
	One  Bit = 1
	Zero Bit = 0
)

func ParserRegisterState

func ParserRegisterState(state string) ([]Bit, error)

type Register

type Register interface {
	Probability() [][]float64
	Measure() []circuit.Qubiter
}

Jump to

Keyboard shortcuts

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