Home | Develop | Download | Contact
pdspoisson.h
1 /*
2  * pdspoisson.h
3  *
4  * Copyright 2011 Fernando Pujaico Rivera <fernando.pujaico.rivera@gmail.com>
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2 of the License, or
9  * (at your option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
19  * MA 02110-1301, USA.
20  *
21  */
22 
34 #ifndef __PDSPOISSON_H__
35 #define __PDSPOISSON_H__
36 
37 #include <stdio.h>
38 #include <pds/pdsrvglobal.h>
39 #include <pds/pdsuniform.h>
40 #include <pds/pdsvector.h>
41 
42 #ifdef __cplusplus
43 extern "C" {
44 #endif
45 
63 typedef struct
64 {
67 
70 
75 }PdsPoisson;
76 
86 
87 
97 
98 
112 
113 
125 
126 
134 
135 
143 
148 #ifdef __cplusplus
149 }
150 #endif
151 
152 #endif /* __PDSPOISSON_H__ */
153 
void pds_poisson_destroy(PdsPoisson **X)
Libera la variable aleatoria de tipo puntero PdsPoisson, y la carga con NULL.
float PdsRvReal
Definition: pdsrvglobal.h:59
PdsUniform * X1
Definition: pdspoisson.h:66
La estructura tipo PdsPoisson. Esta estructura genera una variable aleatoria poissoniana, Poisson(lambda) . Para usar incluir pdsrv/pdsrv.h. La función de densidad de probabilidad es: f_k(k;lambda)= e^{-lambda} lambda^k / k!, k en [0,oo) .
Definition: pdspoisson.h:63
PdsPoisson * pds_poisson_new(PdsRvReal Lambda)
Crea una variable aleatoria de tipo PdsPoisson.
int pds_poisson_get_value(PdsPoisson *X, PdsRvInteger *x)
Retorna un número pseudo aleatorio poissoniano, Poisson(lambda) .
La estructura tipo PdsUniform. Esta estructura genera una variable aleatoria uniformemente distribuid...
Definition: pdsuniform.h:69
PdsRvInteger k
Definition: pdspoisson.h:74
PdsRvReal Lambda
Definition: pdspoisson.h:69
void pds_poisson_free(PdsPoisson *X)
Libera la variable aleatoria de tipo puntero PdsPoisson.
int pds_poisson_get_last_value(PdsPoisson *X, PdsRvInteger *x)
Retorna el último número pseudo aleatorio de la R.V. poissoniana, Poisson(lambda) ...
int PdsRvInteger
Definition: pdsrvglobal.h:73
int pds_poisson_init(PdsPoisson *X, PdsRvInteger k0)
Inicia la variable aleatoria Poisson,.

Enlaces de interés

HomePage Bazaar Download Bug report Ayuda Developer Feed