libmove3d  3.13.0
Defines | Functions
/home/slemaign/softs-local/BioMove3D-git/p3d/p3d_halton.c File Reference

Halton Set Generator. More...

#include "P3d-pkg.h"

Defines

#define NPRIME   1000

Functions

double p3d_hh_random (unsigned long int p_i, unsigned long int i)
 function r(p,i) used by Halton set generator
int p3d_getNextHHpoint (p3d_rob *rob, unsigned long int *hhCount, configPt q, int sample_passive)
int p3d_getNextHHpoint_for_q_in_box (p3d_rob *rob, configPt box_env[], unsigned long int *hhCount, configPt q, int sample_passive)

Detailed Description

Halton Set Generator.

Author:
E.Ferre
Date:
Sep 2001

Function Documentation

static double p3d_hh_random ( unsigned long int  p_i,
unsigned long int  i 
)

function r(p,i) used by Halton set generator

Parameters:
ppointer to an element of the prime array
inumber of the Halton point
Returns:
the result of the function

the function r(p,i) is obtained by writing the digits of the p-ary notation for i in the reserse order : for i = a0 + pa1 + pa2 + pa3+..., where aj is in {0,1,...,p-1}, we set :
r(p,i)=a0/p + a1/p + a2/p ...

 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines