00001 00002 00003 // 00012 // 00013 00014 // ----------------------------------------------------------------------------- 00015 // Licence pertaining to sobol.cc and the accompanying sets of direction numbers 00016 00017 // ----------------------------------------------------------------------------- 00018 // Copyright (c) 2008, Frances Y. Kuo and Stephen Joe 00019 // All rights reserved. 00020 00021 // Redistribution and use in source and binary forms, with or without 00022 // modification, are permitted provided that the following conditions are met: 00023 // 00024 // * Redistributions of source code must retain the above copyright 00025 // notice, this list of conditions and the following disclaimer. 00026 // 00027 // * Redistributions in binary form must reproduce the above copyright 00028 // notice, this list of conditions and the following disclaimer in the 00029 // documentation and/or other materials provided with the distribution. 00030 00031 // * Neither the names of the copyright holders nor the names of the 00032 // University of New South Wales and the University of Waikato 00033 // and its contributors may be used to endorse or promote products derived 00034 // from this software without specific prior written permission. 00035 // 00036 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS ``AS IS'' AND ANY 00037 // EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 00038 // WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 00039 // DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY 00040 // DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 00041 // (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 00042 // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 00043 // ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 00044 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 00045 // SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 00046 00047 #ifndef _SOBOL_SEQUENCES_H 00048 #define _SOBOL_SEQUENCES_H 00049 00050 #include <cstdlib> 00051 #include <cmath> 00052 #include <iostream> 00053 #include <iomanip> 00054 #include <fstream> 00055 #include "gsl_matrix_double.h" 00056 00057 using namespace std; 00058 00060 // 00061 00062 class sobol : public matrix 00063 00064 { 00065 00066 public: 00067 00069 // 00072 // 00073 00074 sobol(size_t N, size_t D); 00075 00077 // 00084 // 00085 00086 sobol sobol_points(size_t N, size_t D, const char *dir_file); 00087 00088 private: 00089 00091 // 00092 00093 matrix sobol_pts; 00094 00095 }; 00096 00097 #endif // _SOBOL_SEQUENCES_H