mirror of
				https://github.com/saitohirga/WSJT-X.git
				synced 2025-11-03 21:40:52 -05:00 
			
		
		
		
	git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6561 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
		
			
				
	
	
		
			30 lines
		
	
	
		
			493 B
		
	
	
	
		
			C++
		
	
	
	
	
	
			
		
		
	
	
			30 lines
		
	
	
		
			493 B
		
	
	
	
		
			C++
		
	
	
	
	
	
 | 
						|
#ifndef RANDOM
 | 
						|
#define RANDOM 1
 | 
						|
 | 
						|
#include <cstdlib>
 | 
						|
// #include <iostream>
 | 
						|
 | 
						|
class Random{
 | 
						|
 private:
 | 
						|
 | 
						|
  unsigned long int seed;  //previously LONG INT
 | 
						|
  unsigned long int seed_u;
 | 
						|
  
 | 
						|
 public:
 | 
						|
 | 
						|
  Random(void) {
 | 
						|
    this->seed=987654321u;
 | 
						|
    this->seed_u=123456789lu;
 | 
						|
  }
 | 
						|
  ~Random(void){;}
 | 
						|
  void bubbleSort(int a[], int size);
 | 
						|
  double gauss(double sdev, double mean);
 | 
						|
  double uniform(double a, double b);
 | 
						|
  int uniform(int  a, int b); // [a, b)
 | 
						|
  int nonUniform(int  a, int b);
 | 
						|
 | 
						|
}; 
 | 
						|
 | 
						|
#endif
 |