EpetraExt Package Browser (Single Doxygen Collection)
Development
|
A simple serial example model which includes a parameter subvector and a response function that can be used to define an optimization problem. More...
#include <EpetraModelEval4DOpt.hpp>
Public Member Functions | |
EpetraModelEval4DOpt (const double xt0=1.0, const double xt1=1.0, const double pt0=2.0, const double pt1=0.0, const double d=10.0, const double x00=1.0, const double x01=1.0, const double p00=2.0, const double p01=0.0) | |
void | setSupportDerivs (bool supportDerivs) |
void | set_p_bounds (double pL0, double pL1, double pU0, double pU1) |
void | set_x_bounds (double xL0, double xL1, double xU0, double xU1) |
![]() | |
virtual | ~ModelEvaluator () |
virtual Teuchos::RCP< const Teuchos::Array< std::string > > | get_p_names (int l) const |
Get the names of the parameters associated with parameter subvector l if available. More... | |
virtual Teuchos::ArrayView < const std::string > | get_g_names (int j) const |
Get the names of the response functions associated with response subvector j if available. More... | |
virtual Teuchos::RCP< const Epetra_Vector > | get_x_dot_init () const |
virtual Teuchos::RCP< const Epetra_Vector > | get_x_dotdot_init () const |
virtual double | get_t_init () const |
virtual double | getInfBound () const |
Return the value of an infinite bound. More... | |
virtual double | get_t_lower_bound () const |
virtual double | get_t_upper_bound () const |
virtual Teuchos::RCP < EpetraExt::ModelEvaluator::Preconditioner > | create_WPrec () const |
virtual Teuchos::RCP < Epetra_Operator > | create_DfDp_op (int l) const |
virtual Teuchos::RCP < Epetra_Operator > | create_DgDx_dot_op (int j) const |
virtual Teuchos::RCP < Epetra_Operator > | create_DgDx_dotdot_op (int j) const |
virtual Teuchos::RCP < Epetra_Operator > | create_DgDx_op (int j) const |
virtual Teuchos::RCP < Epetra_Operator > | create_DgDp_op (int j, int l) const |
![]() | |
DescribableStreamManipulatorState | describe (const Describable &describable, const EVerbosityLevel verbLevel=Describable::verbLevel_default) |
std::ostream & | operator<< (std::ostream &os, const DescribableStreamManipulatorState &d) |
virtual std::string | description () const |
virtual void | describe (FancyOStream &out, const EVerbosityLevel verbLevel=verbLevel_default) const |
void | describe (std::ostream &out, const EVerbosityLevel verbLevel=verbLevel_default) const |
virtual | ~Describable () |
LabeledObject () | |
virtual | ~LabeledObject () |
virtual void | setObjectLabel (const std::string &objectLabel) |
virtual std::string | getObjectLabel () const |
Private Member Functions | |
EpetraModelEval4DOpt () | |
Private Attributes | |
double | xt0_ |
double | xt1_ |
double | pt0_ |
double | pt1_ |
double | d_ |
bool | isInitialized_ |
bool | supportDerivs_ |
Teuchos::RCP< const Epetra_Comm > | epetra_comm_ |
Teuchos::RCP< const Epetra_Map > | map_x_ |
Teuchos::RCP< const Epetra_Map > | map_p_ |
Teuchos::RCP< const Epetra_Map > | map_g_ |
Teuchos::RCP< Epetra_Vector > | xL_ |
Teuchos::RCP< Epetra_Vector > | xU_ |
Teuchos::RCP< Epetra_Vector > | pL_ |
Teuchos::RCP< Epetra_Vector > | pU_ |
Teuchos::RCP< Epetra_Vector > | gL_ |
Teuchos::RCP< Epetra_Vector > | gU_ |
Teuchos::RCP< Epetra_Vector > | x0_ |
Teuchos::RCP< Epetra_Vector > | p0_ |
Teuchos::RCP< Epetra_CrsGraph > | W_graph_ |
Overridden from EpetraExt::ModelEvaluator . | |
Teuchos::RCP< const Epetra_Map > | get_x_map () const |
Teuchos::RCP< const Epetra_Map > | get_f_map () const |
Teuchos::RCP< const Epetra_Map > | get_p_map (int l) const |
. More... | |
Teuchos::RCP< const Epetra_Map > | get_g_map (int j) const |
. More... | |
Teuchos::RCP< const Epetra_Vector > | get_x_init () const |
Teuchos::RCP< const Epetra_Vector > | get_p_init (int l) const |
Teuchos::RCP< const Epetra_Vector > | get_x_lower_bounds () const |
Teuchos::RCP< const Epetra_Vector > | get_x_upper_bounds () const |
Teuchos::RCP< const Epetra_Vector > | get_p_lower_bounds (int l) const |
Teuchos::RCP< const Epetra_Vector > | get_p_upper_bounds (int l) const |
Teuchos::RCP< Epetra_Operator > | create_W () const |
InArgs | createInArgs () const |
OutArgs | createOutArgs () const |
void | evalModel (const InArgs &inArgs, const OutArgs &outArgs) const |
A simple serial example model which includes a parameter subvector and a response function that can be used to define an optimization problem.
Represents the model:
f[0] = x[0] + x[1]*x[1] - p[0]; f[1] = d_ * ( x[0]*x[0] - x[1] - p[1] ); g[0] = 0.5 * ( sqr(x[0]-xt0_) + sqr(x[1]-xt1_) + sqr(p[0]-pt0_) + sqr(p[1]-pt1_) );
where there is just one state vector x = [ x[0], x[1] ]
and one parameter subvector p = [ p[0], p[1] ]
.
See the function evalModel()
for more details.
Definition at line 72 of file EpetraModelEval4DOpt.hpp.
EpetraModelEval4DOpt::EpetraModelEval4DOpt | ( | const double | xt0 = 1.0 , |
const double | xt1 = 1.0 , |
||
const double | pt0 = 2.0 , |
||
const double | pt1 = 0.0 , |
||
const double | d = 10.0 , |
||
const double | x00 = 1.0 , |
||
const double | x01 = 1.0 , |
||
const double | p00 = 2.0 , |
||
const double | p01 = 0.0 |
||
) |
Definition at line 61 of file EpetraModelEval4DOpt.cpp.
|
private |
void EpetraModelEval4DOpt::setSupportDerivs | ( | bool | supportDerivs | ) |
Definition at line 111 of file EpetraModelEval4DOpt.cpp.
void EpetraModelEval4DOpt::set_p_bounds | ( | double | pL0, |
double | pL1, | ||
double | pU0, | ||
double | pU1 | ||
) |
Definition at line 117 of file EpetraModelEval4DOpt.cpp.
void EpetraModelEval4DOpt::set_x_bounds | ( | double | xL0, |
double | xL1, | ||
double | xU0, | ||
double | xU1 | ||
) |
Definition at line 127 of file EpetraModelEval4DOpt.cpp.
|
virtual |
Implements EpetraExt::ModelEvaluator.
Definition at line 140 of file EpetraModelEval4DOpt.cpp.
|
virtual |
Implements EpetraExt::ModelEvaluator.
Definition at line 146 of file EpetraModelEval4DOpt.cpp.
|
virtual |
.
Reimplemented from EpetraExt::ModelEvaluator.
Definition at line 152 of file EpetraModelEval4DOpt.cpp.
|
virtual |
.
Reimplemented from EpetraExt::ModelEvaluator.
Definition at line 159 of file EpetraModelEval4DOpt.cpp.
|
virtual |
Reimplemented from EpetraExt::ModelEvaluator.
Definition at line 166 of file EpetraModelEval4DOpt.cpp.
|
virtual |
Reimplemented from EpetraExt::ModelEvaluator.
Definition at line 172 of file EpetraModelEval4DOpt.cpp.
|
virtual |
Reimplemented from EpetraExt::ModelEvaluator.
Definition at line 179 of file EpetraModelEval4DOpt.cpp.
|
virtual |
Reimplemented from EpetraExt::ModelEvaluator.
Definition at line 185 of file EpetraModelEval4DOpt.cpp.
|
virtual |
Reimplemented from EpetraExt::ModelEvaluator.
Definition at line 191 of file EpetraModelEval4DOpt.cpp.
|
virtual |
Reimplemented from EpetraExt::ModelEvaluator.
Definition at line 198 of file EpetraModelEval4DOpt.cpp.
|
virtual |
Reimplemented from EpetraExt::ModelEvaluator.
Definition at line 205 of file EpetraModelEval4DOpt.cpp.
|
virtual |
Implements EpetraExt::ModelEvaluator.
Definition at line 211 of file EpetraModelEval4DOpt.cpp.
|
virtual |
Implements EpetraExt::ModelEvaluator.
Definition at line 221 of file EpetraModelEval4DOpt.cpp.
|
virtual |
Implements EpetraExt::ModelEvaluator.
Definition at line 265 of file EpetraModelEval4DOpt.cpp.
|
private |
Definition at line 136 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 137 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 138 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 139 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 140 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 142 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 143 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 145 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 146 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 147 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 148 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 150 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 151 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 152 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 153 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 154 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 155 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 156 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 157 of file EpetraModelEval4DOpt.hpp.
|
private |
Definition at line 159 of file EpetraModelEval4DOpt.hpp.