Exemplo n.º 1
0
int main()
{
	char cells[NUM_CELLS];
	int i, j;
	
	for (i=0; i<NUM_CELLS; i++) cells[i] = (char)0;
	cells[(NUM_CELLS-1)/2] = (char)1;
	
	for (i=1; i<=NUM_GENERATIONS; i++)
	{
		for (j=0; j<NUM_CELLS; j++)
		{
			putchar(cells[j] ? char_ON:char_OFF);
		}
		printf("\n");
		do_generation(cells, NUM_CELLS);
	}
	
	return 0;
}
Exemplo n.º 2
0
 return_type
 operator()() const noexcept
 {
     return static_cast<return_type>(do_generation( n_, c_, k_, r_ ));
 }
Exemplo n.º 3
0
 return_type
 operator()() const
 {
     return do_generation( mu1_, mu2_ );
 }
 return_type
 operator()() const
 {
     return do_generation();
 }
 return_type
 operator()() const
 {
     return do_generation( a_, b_, c_ );
 }
Exemplo n.º 6
0
 return_type
 operator()()
 {
     return do_generation( zeta_, sigma_ );
 }
Exemplo n.º 7
0
 return_type
 operator()()
 {
     return do_generation( delta_ );
 }
Exemplo n.º 8
0
 return_type
 operator()()
 {
     return do_generation( a_, b_ );
 }
 return_type
 operator()() const 
 {
     return do_generation( variance_, mean_ );
 }
Exemplo n.º 10
0
 return_type
 operator()()
 {
     return do_generation( lambda_, mu_ );
 }
 return_type
 operator()() const
 {
     return do_generation( beta_, theta_, lambda_ );
 }
 return_type
 operator()() const
 {
     return do_generation( c_, k_, r_ );
 }
Exemplo n.º 13
0
 return_type
 operator()() const
 {
     return do_generation( c_, alpha_ );
 }
Exemplo n.º 14
0
 /*
     testing [bernoulli] engine with n = 10000000, with parameter 0.5
     |        |  Theory  |   Pseudo  |
     |  Mean  |  0.5     |   0.499889|
     |Variance|  0.25    |   0.25    |
     |Skewness|  0       |   0.000442|
 */
 return_type
 operator()() const noexcept
 {
     return do_generation( p_ );
 }
Exemplo n.º 15
0
 return_type
 operator()() const
 {
     return do_generation( a_, variance_ );
 }