source: src/Parser/MpqcParser_Parameters.hpp@ 50e4e5

Action_Thermostats Add_AtomRandomPerturbation Add_FitFragmentPartialChargesAction Add_RotateAroundBondAction Add_SelectAtomByNameAction Added_ParseSaveFragmentResults AddingActions_SaveParseParticleParameters Adding_Graph_to_ChangeBondActions Adding_MD_integration_tests Adding_ParticleName_to_Atom Adding_StructOpt_integration_tests AtomFragments Automaking_mpqc_open AutomationFragmentation_failures Candidate_v1.5.4 Candidate_v1.6.0 Candidate_v1.6.1 ChangeBugEmailaddress ChangingTestPorts ChemicalSpaceEvaluator CombiningParticlePotentialParsing Combining_Subpackages Debian_Package_split Debian_package_split_molecuildergui_only Disabling_MemDebug Docu_Python_wait EmpiricalPotential_contain_HomologyGraph EmpiricalPotential_contain_HomologyGraph_documentation Enable_parallel_make_install Enhance_userguide Enhanced_StructuralOptimization Enhanced_StructuralOptimization_continued Example_ManyWaysToTranslateAtom Exclude_Hydrogens_annealWithBondGraph FitPartialCharges_GlobalError Fix_BoundInBox_CenterInBox_MoleculeActions Fix_ChargeSampling_PBC Fix_ChronosMutex Fix_FitPartialCharges Fix_FitPotential_needs_atomicnumbers Fix_ForceAnnealing Fix_IndependentFragmentGrids Fix_ParseParticles Fix_ParseParticles_split_forward_backward_Actions Fix_PopActions Fix_QtFragmentList_sorted_selection Fix_Restrictedkeyset_FragmentMolecule Fix_StatusMsg Fix_StepWorldTime_single_argument Fix_Verbose_Codepatterns Fix_fitting_potentials Fixes ForceAnnealing_goodresults ForceAnnealing_oldresults ForceAnnealing_tocheck ForceAnnealing_with_BondGraph ForceAnnealing_with_BondGraph_continued ForceAnnealing_with_BondGraph_continued_betteresults ForceAnnealing_with_BondGraph_contraction-expansion FragmentAction_writes_AtomFragments FragmentMolecule_checks_bonddegrees GeometryObjects Gui_Fixes Gui_displays_atomic_force_velocity ImplicitCharges IndependentFragmentGrids IndependentFragmentGrids_IndividualZeroInstances IndependentFragmentGrids_IntegrationTest IndependentFragmentGrids_Sole_NN_Calculation JobMarket_RobustOnKillsSegFaults JobMarket_StableWorkerPool JobMarket_unresolvable_hostname_fix MoreRobust_FragmentAutomation ODR_violation_mpqc_open PartialCharges_OrthogonalSummation PdbParser_setsAtomName PythonUI_with_named_parameters QtGui_reactivate_TimeChanged_changes Recreated_GuiChecks Rewrite_FitPartialCharges RotateToPrincipalAxisSystem_UndoRedo SaturateAtoms_findBestMatching SaturateAtoms_singleDegree StoppableMakroAction Subpackage_CodePatterns Subpackage_JobMarket Subpackage_LinearAlgebra Subpackage_levmar Subpackage_mpqc_open Subpackage_vmg Switchable_LogView ThirdParty_MPQC_rebuilt_buildsystem TrajectoryDependenant_MaxOrder TremoloParser_IncreasedPrecision TremoloParser_MultipleTimesteps TremoloParser_setsAtomName Ubuntu_1604_changes stable
Last change on this file since 50e4e5 was 7f570c, checked in by Frederik Heber <heber@…>, 13 years ago

Moved operator<<() and operator>>() from Mpqc/Psi3Parser_Parameters into FormatParser_Parameters.

  • setting and getting of values are generalized.
  • Property mode set to 100644
File size: 3.9 KB
Line 
1/*
2 * MpqcParser_Parameters.hpp
3 *
4 * Created on: Feb 3, 2011
5 * Author: heber
6 */
7
8#ifndef MPQCPARSER_PARAMETERS_HPP_
9#define MPQCPARSER_PARAMETERS_HPP_
10
11// include config.h
12#ifdef HAVE_CONFIG_H
13#include <config.h>
14#endif
15
16#include <list>
17#include <map>
18#include <vector>
19
20#include "CodePatterns/Clone.hpp"
21#include "CodePatterns/Log.hpp"
22
23#include "Parser/FormatParser_Parameters.hpp"
24
25#include "Parser/Parameters/ContinuousParameter.hpp"
26
27// specialization for bool (we want "yes/no" not "1/0")
28template <> const std::string ContinuousValue<bool>::get() const;
29template <> void ContinuousValue<bool>::set(const std::string _value);
30
31class MpqcParser;
32
33class MpqcParser_Parameters : public FormatParser_Parameters
34{
35 // MpqcParser should be friend to access params directly for types.
36 friend class MpqcParser;
37 // ParserMpqcUnitTest needs to be friend to check types contained in params.
38 friend class ParserMpqcUnitTest;
39
40public:
41 /** Constructor of MpqcParser_Parameters.
42 *
43 */
44 MpqcParser_Parameters();
45
46 /** Destructor of MpqcParser_Parameters.
47 *
48 */
49 virtual ~MpqcParser_Parameters();
50
51 /** Enumeration of all known Parameters to allow placing them in vectors, maps.
52 *
53 */
54 enum Parameters {
55 hessianParam, //!< HessianParam, whether hessian should be calculated or not
56 savestateParam, //!< savestateParam, whether intermediate/final states (wave function) should be stored
57 do_gradientParam,//!< do_gradientParam, whether a gradient should be calculated
58 maxiterParam, //!< maxiterParam, number of maximum iterations for CG
59 memoryParam, //!< memoryParam, maximum amount of memory to use
60 stdapproxParam, //!< stdapproxParam, standard approximation in MBPT2 R12
61 nfzcParam, //!< nfzcParam, nfzc parameter in MBPT2 R12
62 basisParam, //!< basisParam, basis set to use
63 aux_basisParam, //!< aux_basisParam, auxiliary baseis set to use in MBPT2 R12
64 integrationParam,//!< integrationParam, integration method to use in MBPT2 R12
65 theoryParam, //!< theoryParam, level of theory to use
66 unknownParam}; //!< unknownParam, designates an unknown parameter
67
68 /** Enumeration of all known theories.
69 *
70 */
71 enum Theory {
72 CLHF, //!< Closed Shell Hartree-Fock equations
73 CLKS, //!< Closed Shell Kohn-Sham equations
74 MBPT2, //!< Moeller Plesset Perturbation Theory second order
75 MBPT2_R12, //!< Moeller Plesset Perturbation Theory second order with R12 integral
76 unknownTheory //!< designates an unknown theory
77 };
78
79 /** Enumeration of all known integration methods
80 *
81 */
82 enum IntegrationMethod {
83 IntegralCints, //!< Integration method Cints in MBPT2 R12?
84 unknownIntegration //!< designates unknown integration method
85 };
86
87 // enum to string getters
88 const std::string getParameter(const enum Parameters param) const;
89 void setParameter(const enum Parameters param, const std::string &);
90 const std::string &getParameterName(const enum Parameters param) const;
91 const std::string &getTheoryName(const enum Theory theory) const;
92 const std::string &getIntegrationMethodName(const enum IntegrationMethod integration) const;
93
94private:
95
96
97 //!> vector with all available theories in same order as enum Theory.
98 std::vector<std::string> ValidTheories;
99
100 //!> vector with all available integration methods in same order as enum IntegrationMethod.
101 std::vector<std::string> ValidIntegrationMethods;
102
103 bool checkWorldElementsAgainstCurrentBasis() const;
104
105 /** Global initialization in cstor.
106 *
107 */
108 void Init();
109
110 /** Initializes BasisList.
111 *
112 */
113 void initBasis();
114
115 //!> vector with all parameter names in same order as enum Parameters
116 std::vector<std::string> ParamNames;
117
118 //!> typedef for the list of all available basis sets
119 typedef std::map<std::string, std::list<std::string> > BasisMapType;
120
121 //!> list of all basis along with their present element parametrization
122 BasisMapType BasisList;
123};
124
125#endif /* MPQCPARSER_PARAMETERS_HPP_ */
Note: See TracBrowser for help on using the repository browser.