File: rand32.h

package info (click to toggle)
zfp 1.0.1-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 4,744 kB
  • sloc: cpp: 20,656; ansic: 18,871; pascal: 1,231; f90: 907; python: 255; makefile: 183; sh: 79; fortran: 70
file content (22 lines) | stat: -rw-r--r-- 325 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#ifndef RAND_32_H
#define RAND_32_H

#include "include/zfp/internal/zfp/types.h"

// reset seed
void
resetRandGen();

// returns integer [0, 2^31 - 1]
uint32
nextUnsignedRand();

// returns integer [-(2^30), 2^30 - 1]
int32
nextSignedRandInt();

// returns float [-(2^11), 2^11 - 2^(-12)]
float
nextSignedRandFlPt();

#endif