image-in-browser
Version:
Package for encoding / decoding images, transforming images, applying filters, drawing primitives on images on the client side (no need for server Node.js)
29 lines (28 loc) • 1.11 kB
TypeScript
/** @format */
/**
* Abstract class providing various random utility methods.
*/
export declare abstract class RandomUtils {
/**
* Returns a random number between [-1, 1].
* @returns {number} A random number between -1 and 1.
*/
static crand(): number;
/**
* Returns a random number following a Gaussian distribution with a standard deviation of 1.
* @returns {number} A random number following a Gaussian distribution.
*/
static grand(): number;
/**
* Returns a random variable following a Poisson distribution with the given parameter.
* @param {number} z - The parameter of the Poisson distribution.
* @returns {number} A random variable following a Poisson distribution.
*/
static prand(z: number): number;
/**
* Generates a non-negative random integer in the range from 0, inclusive, to the specified max, exclusive.
* @param {number} max - The upper bound (exclusive) for the random integer.
* @returns {number} A non-negative random integer less than max.
*/
static intrand(max: number): number;
}