APEMoST
|
00001 /* 00002 APEMoST - Automated Parameter Estimation and Model Selection Toolkit 00003 Copyright (C) 2009 Johannes Buchner 00004 00005 This program is free software: you can redistribute it and/or modify 00006 it under the terms of the GNU General Public License as published by 00007 the Free Software Foundation, either version 3 of the License, or 00008 (at your option) any later version. 00009 00010 This program is distributed in the hope that it will be useful, 00011 but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00013 GNU General Public License for more details. 00014 00015 You should have received a copy of the GNU General Public License 00016 along with this program. If not, see <http://www.gnu.org/licenses/>. 00017 */ 00018 00023 #ifndef MCMC 00024 #define MCMC 00025 00026 #include <stdio.h> 00027 #include <stdlib.h> 00028 00035 #define DUMP_FORMAT "%.15e" 00036 00037 #ifdef __NEVER_SET_FOR_DOCUMENTATION_ONLY 00038 00044 #define NOASSERT 00045 #endif 00046 00047 #ifdef NOASSERT 00048 #define assert(cond) 00049 #else 00050 #include <assert.h> 00051 #endif 00052 00053 #include "mcmc_struct.h" 00054 00061 mcmc * mcmc_load(const char * filename, const char * datafilename); 00062 00068 mcmc * mcmc_load_params(const char * filename); 00069 00075 void mcmc_load_data(mcmc * m, const char * datafilename); 00076 00083 void mcmc_reuse_data(mcmc * m, const mcmc * m_orig); 00089 mcmc * mcmc_free(mcmc * m); 00090 00094 void mcmc_check(const mcmc * m); 00095 00101 void mcmc_append_current_parameters(mcmc * m); 00102 00103 void mcmc_dump_y_dat(mcmc * m, const gsl_vector * y_dat, const char * filename); 00107 void mcmc_dump_flush(const mcmc * m); 00108 00112 void mcmc_dump_close(mcmc * m); 00113 00123 void 00124 mcmc_open_dump_files(mcmc * m, const char * suffix, int index, 00125 char * mode); 00126 00130 void mcmc_dump_current(const mcmc * m); 00131 00143 void mcmc_dump_probabilities(const mcmc * m, int n_values, const char * suffix); 00144 00149 void mcmc_check_best(mcmc * m); 00150 00151 #include "markov_chain.h" 00152 00153 #include "mcmc_gettersetter.h" 00154 00155 /* calculations done by the application */ 00156 00164 void calc_model(mcmc * m, const gsl_vector * old_values); 00173 void calc_model_for(mcmc * m, const unsigned int i, const double old_value); 00174 00175 #endif 00176