queso-0.53.0
SimulationModelOptions.h
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-2015 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 #ifndef UQ_SIMULATION_MODEL_OPTIONS_H
26 #define UQ_SIMULATION_MODEL_OPTIONS_H
27 
28 #include <queso/Environment.h>
29 #include <queso/BoostInputOptionsParser.h>
30 
31 #define UQ_SIMULATION_MODEL_FILENAME_FOR_NO_FILE "."
32 
33 // _ODV = option default value
34 #define UQ_SIMULATION_MODEL_DATA_OUTPUT_FILE_NAME_ODV UQ_SIMULATION_MODEL_FILENAME_FOR_NO_FILE
35 #define UQ_SIMULATION_MODEL_DATA_OUTPUT_ALLOW_ALL_ODV 0
36 #define UQ_SIMULATION_MODEL_DATA_OUTPUT_ALLOWED_SET_ODV ""
37 #define UQ_SIMULATION_MODEL_P_ETA_ODV 1
38 #define UQ_SIMULATION_MODEL_ZERO_RELATIVE_SINGULAR_VALUE_ODV 0.
39 #define UQ_SIMULATION_MODEL_CDF_THRESHOLD_FOR_P_ETA_ODV 1.
40 #define UQ_SIMULATION_MODEL_A_W_ODV 0.
41 #define UQ_SIMULATION_MODEL_B_W_ODV 0.
42 #define UQ_SIMULATION_MODEL_A_RHO_W_ODV 0.
43 #define UQ_SIMULATION_MODEL_B_RHO_W_ODV 0.
44 #define UQ_SIMULATION_MODEL_A_ETA_ODV 0.
45 #define UQ_SIMULATION_MODEL_B_ETA_ODV 0.
46 #define UQ_SIMULATION_MODEL_A_S_ODV 0.
47 #define UQ_SIMULATION_MODEL_B_S_ODV 0.
48 
49 namespace boost {
50  namespace program_options {
51  class options_description;
52  }
53 }
54 
55 namespace QUESO {
56 
58 {
59 public:
61  SmOptionsValues(const BaseEnvironment * env, const char * prefix);
62  SmOptionsValues(const SmOptionsValues& src);
64  virtual ~SmOptionsValues();
65 
66  std::string m_prefix;
67 
68  std::string m_dataOutputFileName;
70  std::set<unsigned int> m_dataOutputAllowedSet;
71  unsigned int m_p_eta;
74  double m_a_w;
75  double m_b_w;
76  double m_a_rho_w;
77  double m_b_rho_w;
78  double m_a_eta;
79  double m_b_eta;
80  double m_a_s;
81  double m_b_s;
82 
83 private:
85 
86  std::string m_option_help;
90  std::string m_option_p_eta;
93  std::string m_option_a_w;
94  std::string m_option_b_w;
95  std::string m_option_a_rho_w;
96  std::string m_option_b_rho_w;
97  std::string m_option_a_eta;
98  std::string m_option_b_eta;
99  std::string m_option_a_s;
100  std::string m_option_b_s;
101 
102  void copy(const SmOptionsValues& src);
103 };
104 
106 
108 {
109 public:
110  SimulationModelOptions(const BaseEnvironment& env, const char* prefix);
111  SimulationModelOptions(const BaseEnvironment& env, const char* prefix, const SmOptionsValues& alternativeOptionsValues);
113 
114  void scanOptionsValues();
115  void print (std::ostream& os) const;
116 
118  std::string m_prefix;
119 
120 private:
121  void defineMyOptions (boost::program_options::options_description& optionsDesc) const;
122  void getMyOptionValues(boost::program_options::options_description& optionsDesc);
123 
125 
126  boost::program_options::options_description* m_optionsDesc;
127  std::string m_option_help;
131  std::string m_option_p_eta;
134  std::string m_option_a_w;
135  std::string m_option_b_w;
136  std::string m_option_a_rho_w;
137  std::string m_option_b_rho_w;
138  std::string m_option_a_eta;
139  std::string m_option_b_eta;
140  std::string m_option_a_s;
141  std::string m_option_b_s;
142 };
143 
144 std::ostream& operator<<(std::ostream& os, const SimulationModelOptions& obj);
145 
146 } // End namespace QUESO
147 
148 #endif // UQ_SIMULATION_MODEL_OPTIONS_H
std::set< unsigned int > m_dataOutputAllowedSet
std::ostream & operator<<(std::ostream &os, const BaseEnvironment &obj)
std::string m_option_zeroRelativeSingularValue
BoostInputOptionsParser * m_parser
void copy(const SmOptionsValues &src)
SimulationModelOptions(const BaseEnvironment &env, const char *prefix)
boost::program_options::options_description * m_optionsDesc
void print(std::ostream &os) const
This (virtual) class sets up the environment underlying the use of the QUESO library by an executable...
Definition: Environment.h:193
void getMyOptionValues(boost::program_options::options_description &optionsDesc)
SmOptionsValues & operator=(const SmOptionsValues &rhs)
void defineMyOptions(boost::program_options::options_description &optionsDesc) const

Generated on Thu Jun 11 2015 13:52:32 for queso-0.53.0 by  doxygen 1.8.5