nativeprng

0.1.0 • Public • Published

nativeprng

Native Mulberry32, SplitMix32, and Thrust (64) PRNG functions.

Installation

npm install nativeprng

Usage

import { Mulberry32, SplitMix32, Thrust } from 'nativeprng'

Mulberry32.setState(1985)
Mulberry32.getUint32() // 3527837133
Mulberry32.getUint32() // 3112574143

SplitMix32.setState(1985)
SplitMix32.getUint32() // 3153990299
SplitMix32.getUint32() // 2826677777

Thrust.setState(1985n)
Thrust.getUint64() // 13609337976186286977n
Thrust.getUint64() // 14715940130426179720n

/nativeprng/

    Package Sidebar

    Install

    npm i nativeprng

    Weekly Downloads

    2

    Version

    0.1.0

    License

    SEE LICENSE IN LICENSE

    Unpacked Size

    17.8 kB

    Total Files

    11

    Last publish

    Collaborators

    • mvasilkov