MPQC 2.3.1
MPQC_ChemistryOpt_CoordinateModel_Impl.hh
1//
2// File: MPQC_ChemistryOpt_CoordinateModel_Impl.hh
3// Symbol: MPQC.ChemistryOpt_CoordinateModel-v0.2
4// Symbol Type: class
5// Babel Version: 0.10.2
6// Description: Server-side implementation for MPQC.ChemistryOpt_CoordinateModel
7//
8// WARNING: Automatically generated; only changes within splicers preserved
9//
10// babel-version = 0.10.2
11//
12
13#ifndef included_MPQC_ChemistryOpt_CoordinateModel_Impl_hh
14#define included_MPQC_ChemistryOpt_CoordinateModel_Impl_hh
15
16#ifndef included_sidl_cxx_hh
17#include "sidl_cxx.hh"
18#endif
19#ifndef included_MPQC_ChemistryOpt_CoordinateModel_IOR_h
20#include "MPQC_ChemistryOpt_CoordinateModel_IOR.h"
21#endif
22//
23// Includes for all method dependencies.
24//
25#ifndef included_Chemistry_QC_Model_hh
26#include "Chemistry_QC_Model.hh"
27#endif
28#ifndef included_MPQC_ChemistryOpt_CoordinateModel_hh
29#include "MPQC_ChemistryOpt_CoordinateModel.hh"
30#endif
31#ifndef included_gov_cca_CCAException_hh
32#include "gov_cca_CCAException.hh"
33#endif
34#ifndef included_gov_cca_Services_hh
35#include "gov_cca_Services.hh"
36#endif
37#ifndef included_sidl_BaseInterface_hh
38#include "sidl_BaseInterface.hh"
39#endif
40#ifndef included_sidl_ClassInfo_hh
41#include "sidl_ClassInfo.hh"
42#endif
43
44
45// DO-NOT-DELETE splicer.begin(MPQC.ChemistryOpt_CoordinateModel._includes)
46#include <Chemistry_MoleculeViewer.hh>
47#include <Chemistry_QC_ModelFactory.hh>
48#include <chemistry/molecule/coor.h>
49#include "CoordinateModel.h"
50#include "Chemistry_Chemistry_Molecule.hh"
51#include "cca.h"
52#include "dc/babel/babel-cca/server/ccaffeine_TypeMap.hh"
53#include "dc/babel/babel-cca/server/ccaffeine_ports_PortTranslator.hh"
54#include "util/IO.h"
55#include "jc++/jc++.h"
56#include "jc++/util/jc++util.h"
57#include "parameters/parametersStar.h"
58#include "port/portInterfaces.h"
59#include "port/supportInterfaces.h"
60// DO-NOT-DELETE splicer.end(MPQC.ChemistryOpt_CoordinateModel._includes)
61
62namespace MPQC {
63
68 // DO-NOT-DELETE splicer.begin(MPQC.ChemistryOpt_CoordinateModel._inherits)
69 : public CcaChemGeneric::CoordinateModel
70
118 // DO-NOT-DELETE splicer.end(MPQC.ChemistryOpt_CoordinateModel._inherits)
119 {
120
121 private:
122 // Pointer back to IOR.
123 // Use this to dispatch back through IOR vtable.
124 ChemistryOpt_CoordinateModel self;
125
126 // DO-NOT-DELETE splicer.begin(MPQC.ChemistryOpt_CoordinateModel._implementation)
127 gov::cca::Services services_;
128 CcaChemGeneric::CoordinateModel genericModel_;
129 Chemistry::QC::Model model_;
130 Chemistry::Chemistry_Molecule molecule_;
135 sc::RefSymmSCMatrix ihess_;
136 DoubleParameter *grad_rms_, *grad_max_, *disp_rms_, *disp_max_;
137 BoolParameter *multiple_guess_h_, *use_current_geom_;
138 StringParameter *coordinates_;
139 StringParameter *extra_bonds_;
140 double convFrom_;
141 bool have_guess_h_;
142 enum {cart,symm,redund};
143 int coorType_;
144 int numCoor_;
145 int natom3_;
146
147 ConfigurableParameterPort*
148 setup_parameters(ConfigurableParameterFactory *);
149
150 void draw();
151 // DO-NOT-DELETE splicer.end(MPQC.ChemistryOpt_CoordinateModel._implementation)
152
153 private:
154 // private default constructor (required)
156 {}
157
158 public:
159 // sidl constructor (required)
160 // Note: alternate Skel constructor doesn't call addref()
161 // (fixes bug #275)
163 MPQC_ChemistryOpt_CoordinateModel__object * s ) : self(s,
164 true) { _ctor(); }
165
166 // user defined construction
167 void _ctor();
168
169 // virtual destructor (required)
170 virtual ~ChemistryOpt_CoordinateModel_impl() { _dtor(); }
171
172 // user defined destruction
173 void _dtor();
174
175 // static class initializer
176 static void _load();
177
178 public:
179
180
186 int32_t
187 initialize() throw ()
188 ;
189
194 int32_t
195 finalize() throw ()
196 ;
197
204 void
206 /* in */ ::Chemistry::QC::Model model
207 )
208 throw ()
209 ;
210
211
216 ::Chemistry::QC::Model
217 get_model() throw ()
218 ;
219
224 int32_t
225 get_n_coor() throw ()
226 ;
227
233 ::sidl::array<double>
234 get_coor() throw ()
235 ;
236
247 double
249 /* in */ ::sidl::array<double> x
250 )
251 throw ()
252 ;
253
254
266 ::sidl::array<double>
268 /* in */ ::sidl::array<double> x
269 )
270 throw ()
271 ;
272
273
285 ::sidl::array<double>
287 /* in */ ::sidl::array<double> x
288 )
289 throw ()
290 ;
291
292
306 void
308 /* in */ ::sidl::array<double> x,
309 /* out */ double& f,
310 /* in */ ::sidl::array<double> g
311 )
312 throw ()
313 ;
314
315
327 void
329 /* in */ ::sidl::array<double> effective_grad,
330 /* in */ ::sidl::array<double> effective_step,
331 /* in */ void* first_geom
332 )
333 throw ()
334 ;
335
336
342 void
344 /* inout */ int32_t& flag
345 )
346 throw ()
347 ;
348
349
356 void
357 monitor() throw ()
358 ;
359
377 void
379 /* in */ ::gov::cca::Services services
380 )
381 throw (
382 ::gov::cca::CCAException
383 );
384
385 }; // end class ChemistryOpt_CoordinateModel_impl
386
387} // end namespace MPQC
388
389// DO-NOT-DELETE splicer.begin(MPQC.ChemistryOpt_CoordinateModel._misc)
390// Put miscellaneous things here...
391// DO-NOT-DELETE splicer.end(MPQC.ChemistryOpt_CoordinateModel._misc)
392
393#endif
Symbol "MPQC.ChemistryOpt_CoordinateModel" (version 0.2)
Definition MPQC_ChemistryOpt_CoordinateModel_Impl.hh:119
int32_t get_n_coor()
Returns the number of coordinates.
int32_t finalize()
Releases and unregisters ports.
void monitor()
For visualization, possibly unused (?).
void set_model(::Chemistry::QC::Model model)
Sets the contained chemistry Model object (currently unused as the chemistry Model object is normally...
::sidl::array< double > get_gradient(::sidl::array< double > x)
Returns the energy gradient of the currently contained model with the values of the optimization coor...
void setServices(::gov::cca::Services services)
Starts up a component presence in the calling framework.
::sidl::array< double > get_hessian(::sidl::array< double > x)
Returns the energy Hessian of the currently contained model with the values of the optimization coord...
::Chemistry::QC::Model get_model()
Returns the contained chemistry Model object.
::sidl::array< double > get_coor()
Returns the array of (cartesian or internal) coordinates which are being optimized.
int32_t initialize()
Registers and gets ports, and requests Model object(s) from the ModelFactory component(s).
void guess_hessian_solve(::sidl::array< double > effective_grad, ::sidl::array< double > effective_step, void *first_geom)
Returns the product of the guess hessian inverse and an effective gradient.
void get_energy_and_gradient(::sidl::array< double > x, double &f, ::sidl::array< double > g)
Sets f and g to the energy and energy gradient, respectively, of the chemistry model at x.
double get_energy(::sidl::array< double > x)
Returns the energy of the currently contained model with the values of the optimization coordinates g...
void checkConvergence(int32_t &flag)
Determines if the optimization has converged, flag is set to 1 if convergence has been achieved and 0...
The RefSymmSCMatrix class is a smart pointer to an SCSymmSCMatrix specialization.
Definition matrix.h:261
A template class that maintains references counts.
Definition ref.h:332

Generated at Thu Jul 20 2023 00:00:00 for MPQC 2.3.1 using the documentation package Doxygen 1.9.7.