xorshift64star

package
v1.2.2 Latest Latest
Warning

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

Go to latest
Published: May 2, 2020 License: MIT Imports: 0 Imported by: 0

Documentation

Overview

Package xorshift64star it's like other xorshift*, generators, but with a 2^64 - 1 period.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type XorShift64Star

type XorShift64Star struct {
	// contains filtered or unexported fields
}

XorShift64Star hold the state required by the XorShift64Star generator.

func NewSource

func NewSource(seed int64) *XorShift64Star

NewSource return a new XorShift64Star random number generator.

func (*XorShift64Star) Int63

func (x *XorShift64Star) Int63() int64

Int63 returns a non-negative pseudo-random 63-bit integer as an int64.

func (*XorShift64Star) Seed

func (x *XorShift64Star) Seed(seed int64)

Seed use the provvided seed value to init XorShift64Star internal state.

func (*XorShift64Star) Uint64

func (x *XorShift64Star) Uint64() uint64

Uint64 returns the next pseudo random number generated, before start you must provvide one 64 unsigned bit seed.

Jump to

Keyboard shortcuts

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