queso-0.51.1
StatisticalInverseProblem.C
Go to the documentation of this file.
1 //-----------------------------------------------------------------------bl-
2 //--------------------------------------------------------------------------
3 //
4 // QUESO - a library to support the Quantification of Uncertainty
5 // for Estimation, Simulation and Optimization
6 //
7 // Copyright (C) 2008,2009,2010,2011,2012,2013 The PECOS Development Team
8 //
9 // This library is free software; you can redistribute it and/or
10 // modify it under the terms of the Version 2.1 GNU Lesser General
11 // Public License as published by the Free Software Foundation.
12 //
13 // This library is distributed in the hope that it will be useful,
14 // but WITHOUT ANY WARRANTY; without even the implied warranty of
15 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 // Lesser General Public License for more details.
17 //
18 // You should have received a copy of the GNU Lesser General Public
19 // License along with this library; if not, write to the Free Software
20 // Foundation, Inc. 51 Franklin Street, Fifth Floor,
21 // Boston, MA 02110-1301 USA
22 //
23 //-----------------------------------------------------------------------el-
24 
25 #include <queso/StatisticalInverseProblem.h>
26 #include <queso/GslVector.h>
27 #include <queso/GslMatrix.h>
28 #include <queso/GPMSA.h>
29 #include <queso/GslOptimizer.h>
30 
31 namespace QUESO {
32 
33 // Default constructor -----------------------------
34 template <class P_V,class P_M>
35 StatisticalInverseProblem<P_V,P_M>::StatisticalInverseProblem( const char* prefix, const SipOptionsValues* alternativeOptionsValues, // dakota const BaseVectorRV <P_V,P_M>& priorRv, const BaseScalarFunction<P_V,P_M>& likelihoodFunction, GenericVectorRV <P_V,P_M>& postRv)
41  :
42  m_env (priorRv.env()),
43  m_priorRv (priorRv),
44  m_likelihoodFunction (likelihoodFunction),
45  m_postRv (postRv),
46  m_solutionDomain (NULL),
47  m_solutionPdf (NULL),
48  m_subSolutionMdf (NULL),
49  m_subSolutionCdf (NULL),
50  m_solutionRealizer (NULL),
51  m_mhSeqGenerator (NULL),
52  m_mlSampler (NULL),
53  m_chain (NULL),
54  m_logLikelihoodValues (NULL),
55  m_logTargetValues (NULL),
56  m_alternativeOptionsValues(),
57  m_optionsObj (NULL),
58  m_seedWithMAPEstimator (false)
59 {
60 #ifdef QUESO_MEMORY_DEBUGGING
61  std::cout << "Entering Sip" << std::endl;
62 #endif
63  if (m_env.subDisplayFile()) {
64  *m_env.subDisplayFile() << "Entering StatisticalInverseProblem<P_V,P_M>::constructor()"
65  << ": prefix = " << prefix
66  << ", alternativeOptionsValues = " << alternativeOptionsValues
67  << ", m_env.optionsInputFileName() = " << m_env.optionsInputFileName()
68  << std::endl;
69  }
70 
71  if (alternativeOptionsValues) m_alternativeOptionsValues = *alternativeOptionsValues;
72  if (m_env.optionsInputFileName() == "") {
73  m_optionsObj = new StatisticalInverseProblemOptions(m_env,prefix,m_alternativeOptionsValues);
74  }
75  else {
76  m_optionsObj = new StatisticalInverseProblemOptions(m_env,prefix);
77  m_optionsObj->scanOptionsValues();
78  }
79 #ifdef QUESO_MEMORY_DEBUGGING
80  std::cout << "In Sip, finished scanning options" << std::endl;
81 #endif
82 
83  UQ_FATAL_TEST_MACRO(priorRv.imageSet().vectorSpace().dimLocal() != likelihoodFunction.domainSet().vectorSpace().dimLocal(),
84  m_env.worldRank(),
85  "StatisticalInverseProblem<P_V,P_M>::constructor()",
86  "'priorRv' and 'likelihoodFunction' are related to vector spaces of different dimensions");
87 
88  UQ_FATAL_TEST_MACRO(priorRv.imageSet().vectorSpace().dimLocal() != postRv.imageSet().vectorSpace().dimLocal(),
89  m_env.worldRank(),
90  "StatisticalInverseProblem<P_V,P_M>::constructor()",
91  "'priorRv' and 'postRv' are related to vector spaces of different dimensions");
92 
93  if (m_env.subDisplayFile()) {
94  *m_env.subDisplayFile() << "Leaving StatisticalInverseProblem<P_V,P_M>::constructor()"
95  << ": prefix = " << m_optionsObj->m_prefix
96  << std::endl;
97  }
98 
99  return;
100 }
101 
102 template <class P_V,class P_M>
104  const char * prefix,
105  const SipOptionsValues * alternativeOptionsValues,
106  const GPMSAFactory<P_V, P_M> & gpmsaFactory,
107  GenericVectorRV <P_V,P_M> & postRv)
108  :
109  m_env (gpmsaFactory.m_totalPrior->env()),
110  m_priorRv (*(gpmsaFactory.m_totalPrior)),
111  m_likelihoodFunction (gpmsaFactory.getGPMSAEmulator()),
112  m_postRv (postRv),
113  m_solutionDomain (NULL),
114  m_solutionPdf (NULL),
115  m_subSolutionMdf (NULL),
116  m_subSolutionCdf (NULL),
117  m_solutionRealizer (NULL),
118  m_mhSeqGenerator (NULL),
119  m_mlSampler (NULL),
120  m_chain (NULL),
121  m_logLikelihoodValues (NULL),
122  m_logTargetValues (NULL),
123  m_alternativeOptionsValues(),
124  m_optionsObj (NULL),
125  m_seedWithMAPEstimator (false)
126 {
127  if (m_env.subDisplayFile()) {
128  *m_env.subDisplayFile() << "Entering StatisticalInverseProblem<P_V,P_M>::constructor()"
129  << ": prefix = " << prefix
130  << ", alternativeOptionsValues = " << alternativeOptionsValues
131  << ", m_env.optionsInputFileName() = " << m_env.optionsInputFileName()
132  << std::endl;
133  }
134 
135  if (alternativeOptionsValues) m_alternativeOptionsValues = *alternativeOptionsValues;
136  if (m_env.optionsInputFileName() == "") {
138  }
139  else {
142  }
143 
145  m_env.worldRank(),
146  "StatisticalInverseProblem<P_V,P_M>::constructor()",
147  "'priorRv' and 'likelihoodFunction' are related to vector spaces of different dimensions");
148 
149  UQ_FATAL_TEST_MACRO(m_priorRv.imageSet().vectorSpace().dimLocal() != postRv.imageSet().vectorSpace().dimLocal(),
150  m_env.worldRank(),
151  "StatisticalInverseProblem<P_V,P_M>::constructor()",
152  "'priorRv' and 'postRv' are related to vector spaces of different dimensions");
153 
154  if (m_env.subDisplayFile()) {
155  *m_env.subDisplayFile() << "Leaving StatisticalInverseProblem<P_V,P_M>::constructor()"
156  << ": prefix = " << m_optionsObj->m_prefix
157  << std::endl;
158  }
159 
160  return;
161 }
162 
163 // Destructor --------------------------------------
164 template <class P_V,class P_M>
166 {
167  if (m_chain) {
168  m_chain->clear();
169  delete m_chain;
170  }
171  if (m_logLikelihoodValues) {
172  m_logLikelihoodValues->clear();
173  delete m_logLikelihoodValues;
174  }
175  if (m_logTargetValues) {
176  m_logTargetValues->clear();
177  delete m_logTargetValues;
178  }
179  if (m_mlSampler ) delete m_mlSampler;
180  if (m_mhSeqGenerator ) delete m_mhSeqGenerator;
181  if (m_solutionRealizer) delete m_solutionRealizer;
182  if (m_subSolutionCdf ) delete m_subSolutionCdf;
183  if (m_subSolutionMdf ) delete m_subSolutionMdf;
184  if (m_solutionPdf ) delete m_solutionPdf;
185  if (m_solutionDomain ) delete m_solutionDomain;
186  if (m_optionsObj ) delete m_optionsObj;
187 }
188 // Statistical methods -----------------------------
189 template <class P_V,class P_M>
190 void
192  const MhOptionsValues* alternativeOptionsValues, // dakota
193  const P_V& initialValues,
194  const P_M* initialProposalCovMatrix)
195 {
196  //grvy_timer_begin("BayesMetropolisHastings"); TODO: revisit timing output
197  //std::cout << "proc " << m_env.fullRank() << ", HERE sip 000" << std::endl;
198  m_env.fullComm().Barrier();
199  //std::cout << "proc " << m_env.fullRank() << ", HERE sip 001" << std::endl;
200  m_env.fullComm().syncPrintDebugMsg("Entering StatisticalInverseProblem<P_V,P_M>::solveWithBayesMetropolisHastings()",1,3000000);
201 
202  if (m_optionsObj->m_ov.m_computeSolution == false) {
203  if ((m_env.subDisplayFile())) {
204  *m_env.subDisplayFile() << "In StatisticalInverseProblem<P_V,P_M>::solveWithBayesMetropolisHastings()"
205  << ": avoiding solution, as requested by user"
206  << std::endl;
207  }
208  return;
209  }
210  if ((m_env.subDisplayFile())) {
211  *m_env.subDisplayFile() << "In StatisticalInverseProblem<P_V,P_M>::solveWithBayesMetropolisHastings()"
212  << ": computing solution, as requested by user"
213  << std::endl;
214  }
215 
216  UQ_FATAL_TEST_MACRO(m_priorRv.imageSet().vectorSpace().dimLocal() != initialValues.sizeLocal(),
217  m_env.worldRank(),
218  "StatisticalInverseProblem<P_V,P_M>::solveWithBayesMetropolisHastings()",
219  "'m_priorRv' and 'initialValues' should have equal dimensions");
220 
221  if (initialProposalCovMatrix) {
222  UQ_FATAL_TEST_MACRO(m_priorRv.imageSet().vectorSpace().dimLocal() != initialProposalCovMatrix->numRowsLocal(),
223  m_env.worldRank(),
224  "StatisticalInverseProblem<P_V,P_M>::solveWithBayesMetropolisHastings()",
225  "'m_priorRv' and 'initialProposalCovMatrix' should have equal dimensions");
226  UQ_FATAL_TEST_MACRO(initialProposalCovMatrix->numCols() != initialProposalCovMatrix->numRowsGlobal(),
227  m_env.worldRank(),
228  "StatisticalInverseProblem<P_V,P_M>::solveWithBayesMetropolisHastings()",
229  "'initialProposalCovMatrix' should be a square matrix");
230  }
231 
232  if (m_mlSampler ) delete m_mlSampler;
233  if (m_mhSeqGenerator ) delete m_mhSeqGenerator;
234  if (m_solutionRealizer) delete m_solutionRealizer;
235  if (m_subSolutionCdf ) delete m_subSolutionCdf;
236  if (m_subSolutionMdf ) delete m_subSolutionMdf;
237  if (m_solutionPdf ) delete m_solutionPdf;
238  if (m_solutionDomain ) delete m_solutionDomain;
239 
240  P_V numEvaluationPointsVec(m_priorRv.imageSet().vectorSpace().zeroVector());
241  numEvaluationPointsVec.cwSet(250.);
242 
243  // Compute output pdf up to a multiplicative constant: Bayesian approach
244  m_solutionDomain = InstantiateIntersection(m_priorRv.pdf().domainSet(),m_likelihoodFunction.domainSet());
245 
246  m_solutionPdf = new BayesianJointPdf<P_V,P_M>(m_optionsObj->m_prefix.c_str(),
247  m_priorRv.pdf(),
248  m_likelihoodFunction,
249  1.,
250  *m_solutionDomain);
251 
252  m_postRv.setPdf(*m_solutionPdf);
253  m_chain = new SequenceOfVectors<P_V,P_M>(m_postRv.imageSet().vectorSpace(),0,m_optionsObj->m_prefix+"chain");
254 
255  // Decide whether or not to create a MetropolisHastingsSG instance from the
256  // user-provided initial seed, or use the user-provided seed for a
257  // deterministic optimisation instead and seed the chain with the result of
258  // the optimisation
259  if (this->m_seedWithMAPEstimator) {
260  // Do optimisation before sampling
261  GslOptimizer optimizer(*m_solutionPdf);
262  optimizer.setInitialPoint(dynamic_cast<const GslVector &>(initialValues));
263  optimizer.minimize();
264 
265  // Compute output realizer: Metropolis-Hastings approach
266  m_mhSeqGenerator = new MetropolisHastingsSG<P_V, P_M>(
267  m_optionsObj->m_prefix.c_str(), alternativeOptionsValues,
268  m_postRv, optimizer.minimizer(), initialProposalCovMatrix);
269  }
270  else {
271  // Compute output realizer: Metropolis-Hastings approach
272  m_mhSeqGenerator = new MetropolisHastingsSG<P_V, P_M>(
273  m_optionsObj->m_prefix.c_str(), alternativeOptionsValues, m_postRv,
274  initialValues, initialProposalCovMatrix);
275  }
276 
277 
278  m_logLikelihoodValues = new ScalarSequence<double>(m_env, 0,
279  m_optionsObj->m_prefix +
280  "logLike");
281 
282  m_logTargetValues = new ScalarSequence<double>(m_env, 0,
283  m_optionsObj->m_prefix +
284  "logTarget");
285 
286  // m_logLikelihoodValues and m_logTargetValues may be NULL
287  m_mhSeqGenerator->generateSequence(*m_chain, m_logLikelihoodValues,
288  m_logTargetValues);
289 
290  m_solutionRealizer = new SequentialVectorRealizer<P_V,P_M>(m_optionsObj->m_prefix.c_str(),
291  *m_chain);
292 
293  m_postRv.setRealizer(*m_solutionRealizer);
294 
295  m_env.fullComm().syncPrintDebugMsg("In StatisticalInverseProblem<P_V,P_M>::solveWithBayesMetropolisHastings(), code place 1",3,3000000);
296  //m_env.fullComm().Barrier();
297 
298  // Compute output mdf: uniform sampling approach
299 #ifdef UQ_ALSO_COMPUTE_MDFS_WITHOUT_KDE
300  m_subMdfGrids = new ArrayOfOneDGrids <P_V,P_M>((m_optionsObj->m_prefix+"Mdf_").c_str(),m_postRv.imageSet().vectorSpace());
301  m_subMdfValues = new ArrayOfOneDTables<P_V,P_M>((m_optionsObj->m_prefix+"Mdf_").c_str(),m_postRv.imageSet().vectorSpace());
302  m_chain->subUniformlySampledMdf(numEvaluationPointsVec, // input
303  *m_subMdfGrids, // output
304  *m_subMdfValues); // output
305  m_subSolutionMdf = new SampledVectorMdf<P_V,P_M>(m_optionsObj->m_prefix.c_str(),
306  *m_subMdfGrids,
307  *m_subMdfValues);
308  m_postRv.setMdf(*m_subSolutionMdf);
309 
310  if ((m_optionsObj->m_ov.m_dataOutputFileName != UQ_SIP_FILENAME_FOR_NO_FILE ) &&
311  (m_optionsObj->m_ov.m_dataOutputAllowedSet.find(m_env.subId()) != m_optionsObj->m_ov.m_dataOutputAllowedSet.end())) {
312  if (m_env.subRank() == 0) {
313  // Write data output file
314  if (m_env.subDisplayFile()) {
315  *m_env.subDisplayFile() << "Opening data output file '" << m_optionsObj->m_ov.m_dataOutputFileName
316  << "' for calibration problem with problem with prefix = " << m_optionsObj->m_prefix
317  << std::endl;
318  }
319 
320  // Open file
321  // Always write at the end of an eventual pre-existing file
322  std::ofstream* ofsvar = new std::ofstream((m_optionsObj->m_ov.m_dataOutputFileName+"_sub"+m_env.subIdString()+".m").c_str(), std::ofstream::out | std::ofstream::in | std::ofstream::ate);
323  if ((ofsvar == NULL ) ||
324  (ofsvar->is_open() == false)) {
325  delete ofsvar;
326  ofsvar = new std::ofstream((m_optionsObj->m_ov.m_dataOutputFileName+"_sub"+m_env.subIdString()+".m").c_str(), std::ofstream::out | std::ofstream::trunc);
327  }
328  UQ_FATAL_TEST_MACRO((ofsvar && ofsvar->is_open()) == false,
329  m_env.worldRank(),
330  "StatisticalInverseProblem<P_V,P_M>::solveWithBayesMetropolisHastings()",
331  "failed to open file");
332 
333  m_postRv.mdf().print(*ofsvar);
334 
335  // Close file
336  //ofsvar->close();
337  delete ofsvar;
338  if (m_env.subDisplayFile()) {
339  *m_env.subDisplayFile() << "Closed data output file '" << m_optionsObj->m_ov.m_dataOutputFileName
340  << "' for calibration problem with problem with prefix = " << m_optionsObj->m_prefix
341  << std::endl;
342  }
343  }
344  }
345 #endif
346  if (m_env.subDisplayFile()) {
347  *m_env.subDisplayFile() << std::endl;
348  }
349 
350  m_env.fullComm().syncPrintDebugMsg("Leaving StatisticalInverseProblem<P_V,P_M>::solveWithBayesMetropolisHastings()",1,3000000);
351  m_env.fullComm().Barrier();
352  // grvy_timer_end("BayesMetropolisHastings"); TODO: revisit timers
353  return;
354 }
355 
356 template <class P_V, class P_M>
357 void
359 {
360  this->m_seedWithMAPEstimator = true;
361 }
362 
363 template <class P_V,class P_M>
364 void
366 {
367  m_env.fullComm().Barrier();
368  m_env.fullComm().syncPrintDebugMsg("Entering StatisticalInverseProblem<P_V,P_M>::solveWithBayesMLSampling()",1,3000000);
369 
370  if (m_optionsObj->m_ov.m_computeSolution == false) {
371  if ((m_env.subDisplayFile())) {
372  *m_env.subDisplayFile() << "In StatisticalInverseProblem<P_V,P_M>::solveWithBayesMLSampling()"
373  << ": avoiding solution, as requested by user"
374  << std::endl;
375  }
376  return;
377  }
378  if ((m_env.subDisplayFile())) {
379  *m_env.subDisplayFile() << "In StatisticalInverseProblem<P_V,P_M>::solveWithBayesMLSampling()"
380  << ": computing solution, as requested by user"
381  << std::endl;
382  }
383 
384  if (m_mlSampler ) delete m_mlSampler;
385  if (m_mhSeqGenerator ) delete m_mhSeqGenerator;
386  if (m_solutionRealizer) delete m_solutionRealizer;
387  if (m_subSolutionCdf ) delete m_subSolutionCdf;
388  if (m_subSolutionMdf ) delete m_subSolutionMdf;
389  if (m_solutionPdf ) delete m_solutionPdf;
390  if (m_solutionDomain ) delete m_solutionDomain;
391 
392  P_V numEvaluationPointsVec(m_priorRv.imageSet().vectorSpace().zeroVector());
393  numEvaluationPointsVec.cwSet(250.);
394 
395  // Compute output pdf up to a multiplicative constant: Bayesian approach
396  m_solutionDomain = InstantiateIntersection(m_priorRv.pdf().domainSet(),m_likelihoodFunction.domainSet());
397 
398  m_solutionPdf = new BayesianJointPdf<P_V,P_M>(m_optionsObj->m_prefix.c_str(),
399  m_priorRv.pdf(),
400  m_likelihoodFunction,
401  1.,
402  *m_solutionDomain);
403 
404  m_postRv.setPdf(*m_solutionPdf);
405 
406  // Compute output realizer: ML approach
407  m_chain = new SequenceOfVectors<P_V,P_M>(m_postRv.imageSet().vectorSpace(),0,m_optionsObj->m_prefix+"chain");
408  m_mlSampler = new MLSampling<P_V,P_M>(m_optionsObj->m_prefix.c_str(),
409  //m_postRv,
410  m_priorRv,
411  m_likelihoodFunction);
412  // initialValues,
413  // initialProposalCovMatrix);
414 
415  m_mlSampler->generateSequence(*m_chain,
416  NULL,
417  NULL);
418 
419  m_solutionRealizer = new SequentialVectorRealizer<P_V,P_M>(m_optionsObj->m_prefix.c_str(),
420  *m_chain);
421 
422  m_postRv.setRealizer(*m_solutionRealizer);
423 
424  if (m_env.subDisplayFile()) {
425  *m_env.subDisplayFile() << std::endl;
426  }
427 
428  m_env.fullComm().syncPrintDebugMsg("Leaving StatisticalInverseProblem<P_V,P_M>::solveWithBayesMLSampling()",1,3000000);
429  m_env.fullComm().Barrier();
430 
431  return;
432 }
433 
434 template <class P_V, class P_M>
437 {
438  return *m_mhSeqGenerator;
439 }
440 
441 //--------------------------------------------------
442 template <class P_V,class P_M>
445 {
446  return m_priorRv;
447 }
448 //--------------------------------------------------
449 template <class P_V,class P_M>
452 {
453  return m_postRv;
454 }
455 //--------------------------------------------------
456 template <class P_V,class P_M>
458 {
459  UQ_FATAL_TEST_MACRO(m_mlSampler == NULL,
460  m_env.worldRank(),
461  "StatisticalInverseProblem<P_V,P_M>::logEvidence()",
462  "m_mlSampler is NULL");
463  return m_mlSampler->logEvidence();
464 }
465 //--------------------------------------------------
466 template <class P_V,class P_M>
468 {
469  UQ_FATAL_TEST_MACRO(m_mlSampler == NULL,
470  m_env.worldRank(),
471  "StatisticalInverseProblem<P_V,P_M>::meanLogLikelihood()",
472  "m_mlSampler is NULL");
473  return m_mlSampler->meanLogLikelihood();
474 }
475 //--------------------------------------------------
476 template <class P_V,class P_M>
478 {
479  UQ_FATAL_TEST_MACRO(m_mlSampler == NULL,
480  m_env.worldRank(),
481  "StatisticalInverseProblem<P_V,P_M>::eig()",
482  "m_mlSampler is NULL");
483  return m_mlSampler->eig();
484 }
485 // I/O methods--------------------------------------
486 template <class P_V,class P_M>
487 void
489 {
490  return;
491 }
492 
493 } // End namespace QUESO
494 
unsigned int dimLocal() const
Definition: VectorSpace.C:199
void solveWithBayesMetropolisHastings(const MhOptionsValues *alternativeOptionsValues, const P_V &initialValues, const P_M *initialProposalCovMatrix)
Solves the problem via Bayes formula and a Metropolis-Hastings algorithm.
Class to accommodate arrays of one-dimensional grid.
A class for handling sampled vector MDFs.
void scanOptionsValues()
It scans the option values from the options input file.
double logEvidence() const
Returns the logarithm value of the evidence. Related to ML.
int worldRank() const
Returns the process world rank.
Definition: Environment.C:235
const BaseVectorRV< P_V, P_M > & m_priorRv
std::ofstream * subDisplayFile() const
Access function for m_subDisplayFile (displays file on stream).
Definition: Environment.C:305
void seedWithMAPEstimator()
Seeds the chain with the result of a deterministic optimisation.
StatisticalInverseProblem(const char *prefix, const SipOptionsValues *alternativeOptionsValues, const BaseVectorRV< P_V, P_M > &priorRv, const BaseScalarFunction< P_V, P_M > &likelihoodFunction, GenericVectorRV< P_V, P_M > &postRv)
Constructor.
const VectorSet< V, M > & domainSet() const
Access to the protected attribute m_domainSet: domain set of the scalar function. ...
A templated class that represents a Multilevel generator of samples.
Definition: MLSampling.h:120
VectorSet< V, M > * InstantiateIntersection(const VectorSet< V, M > &domain1, const VectorSet< V, M > &domain2)
This method calculates the intersection of domain1 and domain2.
double meanLogLikelihood() const
Returns the mean of the logarithm value of the likelihood. Related to ML.
A templated class that represents a Metropolis-Hastings generator of samples.
std::string optionsInputFileName() const
Access to the attribute m_optionsInputFileName, which stores the name of the input file passed by the...
Definition: Environment.C:341
#define UQ_SIP_FILENAME_FOR_NO_FILE
const BaseVectorRV< P_V, P_M > & priorRv() const
Returns the Prior RV; access to private attribute m_priorRv.
virtual void minimize(OptimizerMonitor *monitor=NULL)
Minimize the objective function, starting at m_initialPoint.
Definition: GslOptimizer.C:182
A class for handling sequential draws (sampling) from probability density distributions.
const BaseScalarFunction< P_V, P_M > & m_likelihoodFunction
void solveWithBayesMLSampling()
Solves with Bayes Multi-Level (ML) sampling.
void setInitialPoint(const GslVector &intialPoint)
Set the point at which the optimization starts.
Definition: GslOptimizer.C:217
const VectorSet< V, M > & imageSet() const
Image set of the vector RV; access to private attribute m_imageSet.
Definition: VectorRV.C:79
This class reads option values for a Statistical Inverse Problem from an input file.
Class to accommodate arrays of one-dimensional tables.
const GslVector & minimizer() const
Return the point that minimizes the objective function.
Definition: GslOptimizer.C:225
A base class for handling optimisation of scalar functions.
Definition: GslOptimizer.h:50
void print(std::ostream &os) const
TODO: Prints the sequence.
Class for handling vector samples (sequence of vectors).
StatisticalInverseProblemOptions * m_optionsObj
virtual const VectorSpace< V, M > & vectorSpace() const =0
Vector space to which this set belongs to. See template specialization.
#define UQ_FATAL_TEST_MACRO(test, givenRank, where, what)
Definition: Defines.h:223
This templated class represents a Statistical Inverse Problem.
This class provides options for the Metropolis-Hastings generator of samples if no input file is avai...
const MetropolisHastingsSG< P_V, P_M > & sequenceGenerator() const
Return the underlying MetropolisHastingSG object.
This class provides options for a Statistical Inverse Problem if no input file is available...
const GenericVectorRV< P_V, P_M > & postRv() const
Returns the Posterior RV; access to private attribute m_postrRv.

Generated on Thu Apr 23 2015 19:26:16 for queso-0.51.1 by  doxygen 1.8.5