Namespaces | Functions

src/random.h File Reference

Helper functions for taking random samples and seeding RNGs from the system clock. More...

#include <sys/time.h>
Include dependency graph for random.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  cluster
 

Namespace for everything in the cluster library.


Functions

template<class OutputIterator , class Random >
void random_subset (size_t numElements, size_t sample_size, OutputIterator out, Random &random)
 This is Knuth's algorithm R for taking a sample of indices from 0 to numElements.
long get_time_seed ()
 Returns a reasonably distributed seed for random number generators.

Detailed Description

Helper functions for taking random samples and seeding RNGs from the system clock.

Author:
Todd Gamblin tgamblin@llnl.gov

Definition in file random.h.

Muster. Copyright © 2010, Lawrence Livermore National Laboratory, LLNL-CODE-433662.
Distribution of Muster and its documentation is subject to terms of the Muster LICENSE.
Generated on Mon Dec 20 2010 using Doxygen 1.7.2