Main Page
Modules
Namespaces
Classes
Files
File List
File Members
external
Diameter
src
rand.cpp
Go to the documentation of this file.
1
// ========================================================================================
2
// ApproxMVBB
3
// Copyright (C) 2014 by Gabriel Nützi <nuetzig (at) imes (d0t) mavt (d0t) ethz (døt) ch>
4
//
5
// This Source Code Form is subject to the terms of the Mozilla Public
6
// License, v. 2.0. If a copy of the MPL was not distributed with this
7
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
8
// ========================================================================================
9
10
#include "
ApproxMVBB/Diameter/Utils/rand.hpp
"
11
12
namespace
ApproxMVBB
{
13
14
//
15
// static long int _random_calls_ = 0;
16
// static long int _random_seed_ = 0;
17
//
18
// long int _GetRandomCalls()
19
// {
20
// return( _random_calls_ );
21
// }
22
//
23
// long int _GetRandomSeed()
24
// {
25
// return( _random_seed_ );
26
// }
27
//
28
//
29
//
30
// #if defined _WIN32 || defined __CYGWIN__ || defined WIN32 // WIN32 is for legacy CMake
31
// void _SetRandomSeed( unsigned int seed )
32
// {
33
// srand( seed );
34
// _random_seed_ = seed;
35
// _random_calls_ = 0;
36
// }
37
// #else
38
// void _SetRandomSeed( long int seed )
39
// {
40
// srand48( seed );
41
// //_random_seed_ = seed;
42
// _random_calls_ = 0;
43
// }
44
// #endif
45
//
46
//
47
//
48
// #if defined _WIN32 || defined __CYGWIN__ || defined WIN32 // WIN32 is for legacy CMake
49
// double _GetRandomDoubleNb( )
50
// {
51
// //_random_calls_ ++;
52
// return( (double)rand()/(double)RAND_MAX );
53
// }
54
// #else
55
// double _GetRandomDoubleNb( )
56
//{
57
//_random_calls_ ++;
58
// return( drand48() );
59
// }
60
// #endif
61
//
62
//
63
// int _GetRandomIntNb( int min, int max )
64
// {
65
// if ( min <= max )
66
// return( (int)(floor( min + _GetRandomDoubleNb()*(double)(max-min+1.0) )) );
67
// return( (int)(floor( max + _GetRandomDoubleNb()*(double)(min-max+1.0) )) );
68
// }
69
70
}
ApproxMVBB
These are some container definitions.
Definition:
EstimateDiameter.hpp:17
rand.hpp
asr_approx_mvbb
Author(s): Gassner Nikolai
autogenerated on Mon Jun 10 2019 12:38:08