Debian Codegraph @

/

debian golang-github-zeebo-pcg 1.0.1-2debian golang-github-zeebo-pcg-dev gomod github.com/zeebo/pcg debiangoinimakefileshellyaml 17 files · 133 symbols
View dependency graph

Depends on

README (full)
PACKAGE DOCUMENTATION

package pcg
    import "github.com/zeebo/pcg"


FUNCTIONS

func Float32() float32
    Float32 returns a float32 uniformly in [0, 1). Safe for concurrent
    callers.

func Float64() float64
    Float64 returns a float64 uniformly in [0, 1). Safe for concurrent
    callers.

func Uint32() uint32
    Uint32 returns a random uint32. Safe for concurrent callers.

func Uint32n(n uint32) uint32
    Uint32n returns a uint32 uniformly in [0, n). Safe for concurrent
    callers.

func Uint64() uint64
    Uint64 returns a random uint64. Safe for concurrent callers.

TYPES

type PT struct {
    // contains filtered or unexported fields
}
    PT is a thread safe pcg generator. The output is non-deterministic, even
    if all of the calls are single threaded. The zero value is valid.

func NewParallel(state uint64) PT
    New constructs a parallel pcg with the given state.

func (p *PT) Float32() float32
    Float32 returns a float32 uniformly in [0, 1). Safe for concurrent
    callers.

func (p *PT) Float64() float64
    Float64 returns a float64 uniformly in [0, 1). Safe for concurrent
    callers.

func (p *PT) Uint32() uint32
    Uint32 returns a random uint32. Safe for concurrent callers.

func (p *PT) Uint32n(n uint32) uint32
    Uint32n returns a uint32 uniformly in [0, n). Safe for concurrent
    callers.

func (p *PT) Uint64() uint64
    Uint64 returns a random uint64. Safe for concurrent callers.

type T struct {
    // contains filtered or unexported fields
}
    T is a pcg generator. The zero value is valid.

func New(state uint64) T
    New constructs a pcg with the given state.

func (p *T) Float32() float32
    Float32 returns a float32 uniformly in [0, 1). Not safe for concurrent
    callers.

func (p *T) Float64() float64
    Float64 returns a float64 uniformly in [0, 1). Not safe for concurrent
    callers.

func (p *T) Uint32() uint32
    Uint32 returns a random uint32. Not safe for concurrent callers.

func (p *T) Uint32n(n uint32) uint32
    Uint32n returns a uint32 uniformly in [0, n). Not safe for concurrent
    callers.

func (p *T) Uint64() uint64
    Uint64 returns a random uint64. Not safe for concurrent callers.
dir debian/
file LICENSE
file README.txt
file go.mod
file go.sum
file package.go
file par_pcg.go
file par_pcg_test.go
file pcg.go
file pcg_test.go
file tid.go
file tid_test.go