Changeset 26593
- Timestamp:
- 11/10/21 14:33:27 (3 years ago)
- Location:
- issm/trunk-jpl/src/c/shared/Random
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/shared/Random/randomgenerator.cpp
r26589 r26593 5 5 #include <iostream> 6 6 #include "./randomgenerator.h" 7 8 9 rnd_uniform_distribution::~rnd_uniform_distribution(){} 10 11 rnd_normal_distribution::~rnd_normal_distribution(){} -
issm/trunk-jpl/src/c/shared/Random/randomgenerator.h
r26591 r26593 25 25 rnd_uniform_distribution() : _seed( 0 ), a( 1103515245 ), c( 12345 ), m( 2147483648 ), lbound(0.0), ubound(1.0) {} 26 26 rnd_uniform_distribution(double a_1,double a_2) : _seed( 0 ), a( 1103515245 ), c( 12345 ), m( 2147483648 ), lbound(a_1), ubound(a_2) {} 27 ~rnd_uniform_distribution(){} 27 ~rnd_uniform_distribution(); 28 28 29 void seed( unsigned int s ) { _seed = s; } 29 30 unsigned int get_seed() { return _seed; } … … 44 45 45 46 public: 47 48 /*constructors, destructors: */ 46 49 rnd_normal_distribution() : _seed( 0 ), mean( 0), sdev(1.0) {} 47 50 rnd_normal_distribution(double m,double s) : _seed( 0 ), mean( m ), sdev(s) {} 48 ~rnd_normal_distribution(){} 51 ~rnd_normal_distribution(); 52 49 53 void seed( unsigned int s ) { _seed = s; } 50 54 double generator()
Note:
See TracChangeset
for help on using the changeset viewer.