logistic_rand.c File Reference

A Random Number Generator based on coupled chaotic Logistic lattice. More...

#include "logistic_rand.h"
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
Include dependency graph for logistic_rand.c:
This graph shows which files directly or indirectly include this file:

Defines

#define R_PI   0.318309886183791f
#define INIT_LOGISTIC   100
#define INIT_MULT   1812433253u
#define FUN(x)   (4.f*(x)*(1.f-(x)))
#define NU   1e-8f
#define NU2   (1.f-2.f*NU)
#define MIN_INVERSE_LIMIT   1e-7f
#define logistic_uniform(v)   (acosf(1.f-2.f*(v))*R_PI)
#define R_MAX_C_RAND   (0.5f/RAND_MAX)
#define LOG_MT_MAX   22.1807097779182f
#define RING_FUN(x, y, z)   (NU2*(x)+NU*((y)+(z)))

Functions

__device__ void logistic_step (RandType *t, RandType *tnew, int len_1)
__device__ void rand_need_more (RandType t[RAND_BUF_LEN], RandType tbuf[RAND_BUF_LEN])
__device__ void logistic_init (RandType *t, RandType *tnew, uint n_seed[], uint idx)
__device__ RandType rand_uniform01 (RandType v)
__device__ void rng_init (RandType t[RAND_BUF_LEN], RandType tnew[RAND_BUF_LEN], uint *n_seed, int idx)
__device__ float rand_next_scatlen (RandType t[RAND_BUF_LEN])
__device__ float rand_next_aangle (RandType t[RAND_BUF_LEN])
__device__ float rand_next_zangle (RandType t[RAND_BUF_LEN])
__device__ float rand_next_reflect (RandType t[RAND_BUF_LEN])
__device__ float rand_do_roulette (RandType t[RAND_BUF_LEN])

Detailed Description

A Random Number Generator based on coupled chaotic Logistic lattice.

A Pseudo-RNG using the SIMD-oriented Fast Mersenne Twister (SFMT) * *

Author:
Qianqian Fang <fangq at nmr.mgh.harvard.edu> * *
 All Classes Files Functions Variables
Generated on Wed Dec 15 18:02:15 2010 by  doxygen 1.6.3