Latin Hypercube Samples (lhs)
1.0
R, C++, and Rcpp code to generate Latin hypercube samples
|
Go to the documentation of this file.
21 #ifndef LHSCOMMONDEFINES_H
22 #define LHSCOMMONDEFINES_H
41 #define PRINT_MACRO Rcpp::Rcout
42 #define ERROR_MACRO Rcpp::Rcerr
45 #define PRINT_MACRO std::cout
47 #define ERROR_MACRO std::cerr
51 #define PRINT_RESULT 0
54 #define START_RNG Rcpp::RNGScope * tempRNG = new Rcpp::RNGScope(); // instantiate a pointer so that the destructor is not implicitly called
56 #define END_RNG delete tempRNG; // explicitly release the RNG state to avoid memory corruption
71 void improvedLHS(
int n,
int k,
int dup, bclib::matrix<int> & result,
81 void maximinLHS(
int n,
int k,
int dup, bclib::matrix<int> & result,
94 void optimumLHS(
int n,
int k,
int maxSweeps,
double eps,
95 bclib::matrix<int> & outlhs,
int optimalityRecordLength,
107 void optSeededLHS(
int n,
int k,
int maxSweeps,
double eps,
108 bclib::matrix<double> & oldHypercube,
int optimalityRecordLength,
bool bVerbose);
152 void geneticLHS(
int n,
int k,
int pop,
int gen,
double pMut,
const std::string & criterium,
void optimumLHS(int n, int k, int maxSweeps, double eps, bclib::matrix< int > &outlhs, int optimalityRecordLength, bclib::CRandom< double > &oRandom, bool bVerbose)
Definition: optimumLHS.cpp:49
Definition: geneticLHS.cpp:25
void improvedLHS(int n, int k, int dup, bclib::matrix< int > &result, bclib::CRandom< double > &oRandom)
Definition: improvedLHS.cpp:45
void maximinLHS(int n, int k, int dup, bclib::matrix< int > &result, bclib::CRandom< double > &oRandom)
Definition: maximinLHS.cpp:40
bclib::matrix< int >::size_type msize_type
Definition: LHSCommonDefines.h:114
std::vector< int >::size_type vsize_type
Definition: LHSCommonDefines.h:119
void randomLHS(int n, int k, bool bPreserveDraw, bclib::matrix< double > &result, bclib::CRandom< double > &oRandom)
Definition: randomLHS.cpp:44
void geneticLHS(int n, int k, int pop, int gen, double pMut, const std::string &criterium, bool bVerbose, bclib::matrix< double > &result, bclib::CRandom< double > &oRandom)
Definition: geneticLHS.cpp:27
void optSeededLHS(int n, int k, int maxSweeps, double eps, bclib::matrix< double > &oldHypercube, int optimalityRecordLength, bool bVerbose)
Definition: optSeededLHS.cpp:53