src/source.c File Reference

#include <it/random.h>
#include <it/source.h>
#include <it/source_func.h>
#include <it/io.h>
#include <it/math.h>

Go to the source code of this file.

Functions

bvec source_binary (idx_t size, double p0)
vec source_uniform (idx_t size, double a, double b)
ivec source_uniform_int (idx_t size, int a, int b)
vec source_gaussian (idx_t size, double mean, double std)
vec source_pdf (idx_t size, double a, double b, it_function_t pdf, it_args_t args)
ivec source_memoryless (idx_t size, vec pdf)


Function Documentation

bvec source_binary ( idx_t  size,
double  p0 
)

Definition at line 34 of file source.c.

References bvec_new(), and it_rand().

Referenced by main().

vec source_gaussian ( idx_t  size,
double  mean,
double  std 
)

Definition at line 72 of file source.c.

References it_randn(), and vec_new().

Referenced by channel_awgn(), and main().

ivec source_memoryless ( idx_t  size,
vec  pdf 
)

Definition at line 102 of file source.c.

References is_valid_pdf(), it_assert, IT_EPSILON, it_rand(), ivec_new(), vec_cum_sum(), vec_delete(), vec_ins, and vec_length().

Referenced by main().

vec source_pdf ( idx_t  size,
double  a,
double  b,
it_function_t  pdf,
it_args_t  args 
)

Definition at line 88 of file source.c.

References it_randpdf(), and vec_new().

Referenced by main().

vec source_uniform ( idx_t  size,
double  a,
double  b 
)

Definition at line 47 of file source.c.

References it_rand(), and vec_new().

Referenced by main().

ivec source_uniform_int ( idx_t  size,
int  a,
int  b 
)

Definition at line 59 of file source.c.

References it_rand(), and ivec_new().


Hosted by
Copyright (C) 2005-2006 Hervé Jégou
Vivien Chappelier
Francois Cayre
libit logo courtesy of Jonathan Delhumeau