42 #ifndef EPETRA_EXT_MODEL_EVALUATOR_HPP 43 #define EPETRA_EXT_MODEL_EVALUATOR_HPP 47 #include "Teuchos_RCP.hpp" 48 #include "Teuchos_Describable.hpp" 49 #include "Teuchos_Polynomial.hpp" 50 #include "Teuchos_Array.hpp" 52 #ifdef HAVE_PYTRILINOS 55 typedef _object PyObject;
61 class Epetra_Operator;
65 class EpetraVectorOrthogPoly;
66 class EpetraMultiVectorOrthogPoly;
67 class EpetraOperatorOrthogPoly;
69 template <
typename ordinal_type,
typename scalar_type>
class Quadrature;
73 class ProductEpetraVector;
74 class ProductEpetraMultiVector;
75 class ProductEpetraOperator;
93 typedef Teuchos::RCP<Stokhos::ProductEpetraVector>
mp_vector_t;
111 ,IN_ARG_x_dotdot_poly
116 ,IN_ARG_sg_quadrature
119 static const int NUM_E_IN_ARGS_MEMBERS=19;
141 std::string modelEvalDescription()
const;
145 void set_x_dot(
const Teuchos::RCP<const Epetra_Vector> &x_dot );
147 void set_x_dotdot(
const Teuchos::RCP<const Epetra_Vector> &x_dotdot );
149 Teuchos::RCP<const Epetra_Vector> get_x_dot()
const;
151 Teuchos::RCP<const Epetra_Vector> get_x_dotdot()
const;
153 void set_x(
const Teuchos::RCP<const Epetra_Vector> &x );
155 Teuchos::RCP<const Epetra_Vector> get_x()
const;
157 const Teuchos::RCP<
const Teuchos::Polynomial<Epetra_Vector> > &x_poly
160 Teuchos::RCP<const Teuchos::Polynomial<Epetra_Vector> > get_x_poly()
const;
163 const Teuchos::RCP<
const Teuchos::Polynomial<Epetra_Vector> > &x_dot_poly
165 void set_x_dotdot_poly(
166 const Teuchos::RCP<
const Teuchos::Polynomial<Epetra_Vector> > &x_dotdot_poly
169 Teuchos::RCP<const Teuchos::Polynomial<Epetra_Vector> > get_x_dot_poly()
const;
170 Teuchos::RCP<const Teuchos::Polynomial<Epetra_Vector> > get_x_dotdot_poly()
const;
172 void set_x_sg(
const sg_const_vector_t &x_sg);
174 sg_const_vector_t get_x_sg()
const;
176 void set_x_dot_sg(
const sg_const_vector_t &x_dot_sg);
177 void set_x_dotdot_sg(
const sg_const_vector_t &x_dotdot_sg);
179 sg_const_vector_t get_x_dot_sg()
const;
180 sg_const_vector_t get_x_dotdot_sg()
const;
182 void set_x_mp(
const mp_const_vector_t &x_mp);
184 mp_const_vector_t get_x_mp()
const;
186 void set_x_dot_mp(
const mp_const_vector_t &x_dot_mp);
187 void set_x_dotdot_mp(
const mp_const_vector_t &x_dotdot_mp);
189 mp_const_vector_t get_x_dot_mp()
const;
190 mp_const_vector_t get_x_dotdot_mp()
const;
192 void set_p(
int l,
const Teuchos::RCP<const Epetra_Vector> &p_l );
194 Teuchos::RCP<const Epetra_Vector> get_p(
int l)
const;
196 void set_p_sg(
int l,
const sg_const_vector_t &p_sg_l );
198 sg_const_vector_t get_p_sg(
int l)
const;
200 void set_p_mp(
int l,
const mp_const_vector_t &p_mp_l );
202 mp_const_vector_t get_p_mp(
int l)
const;
204 void set_t(
double t );
206 double get_alpha()
const;
208 void set_alpha(
double alpha );
211 double get_omega()
const;
213 void set_omega(
double omega );
214 double get_beta()
const;
216 void set_beta(
double beta );
218 double get_t()
const;
220 Teuchos::RCP<const Stokhos::OrthogPolyBasis<int,double> > get_sg_basis()
const;
224 Teuchos::RCP<const Stokhos::Quadrature<int,double> > get_sg_quadrature()
const;
228 Teuchos::RCP<Stokhos::OrthogPolyExpansion<int,double,Stokhos::StandardStorage<int,double> > > get_sg_expansion()
const;
239 void _setModelEvalDescription(
const std::string &modelEvalDescription );
241 void _set_Np(
int Np);
245 void _setSupports(
EInArgs_p_sg arg,
int l,
bool supports );
247 void _setSupports(
EInArgs_p_mp arg,
int l,
bool supports );
250 typedef Teuchos::Array<Teuchos::RCP<const Epetra_Vector> > p_t;
251 typedef Teuchos::Array<sg_const_vector_t > p_sg_t;
252 typedef Teuchos::Array<mp_const_vector_t > p_mp_t;
253 typedef Teuchos::Array<bool> supports_p_sg_t;
255 std::string modelEvalDescription_;
256 Teuchos::RCP<const Epetra_Vector> x_dot_;
257 Teuchos::RCP<const Epetra_Vector> x_dotdot_;
258 Teuchos::RCP<const Epetra_Vector> x_;
259 Teuchos::RCP<const Teuchos::Polynomial<Epetra_Vector> > x_dot_poly_;
260 Teuchos::RCP<const Teuchos::Polynomial<Epetra_Vector> > x_dotdot_poly_;
261 Teuchos::RCP<const Teuchos::Polynomial<Epetra_Vector> > x_poly_;
262 sg_const_vector_t x_dot_sg_;
263 sg_const_vector_t x_dotdot_sg_;
264 sg_const_vector_t x_sg_;
265 mp_const_vector_t x_dot_mp_;
266 mp_const_vector_t x_dotdot_mp_;
267 mp_const_vector_t x_mp_;
275 Teuchos::RCP<const Stokhos::OrthogPolyBasis<int,double> > sg_basis_;
276 Teuchos::RCP<const Stokhos::Quadrature<int,double> > sg_quad_;
277 Teuchos::RCP<Stokhos::OrthogPolyExpansion<int,double,Stokhos::StandardStorage<int,double> > > sg_exp_;
278 bool supports_[NUM_E_IN_ARGS_MEMBERS];
279 supports_p_sg_t supports_p_sg_;
280 supports_p_sg_t supports_p_mp_;
285 void assert_l(
int l)
const;
291 ,EVAL_TYPE_APPROX_DERIV
292 ,EVAL_TYPE_VERY_APPROX_DERIV
296 template<
class ObjType>
303 :
Teuchos::RCP<ObjType>(obj), evalType_(EVAL_TYPE_EXACT) {}
306 :
Teuchos::RCP<ObjType>(obj), evalType_(evalType) {}
311 { this->operator=(obj); evalType_ = evalType; }
319 ,DERIV_TRANS_MV_BY_ROW
330 :supportsLinearOp_(false), supportsMVByCol_(false), supportsTransMVByRow_(false)
334 :supportsLinearOp_(true), supportsMVByCol_(false), supportsTransMVByRow_(false)
338 :supportsLinearOp_(false), supportsMVByCol_(mvOrientation==DERIV_MV_BY_COL)
339 ,supportsTransMVByRow_(mvOrientation==DERIV_TRANS_MV_BY_ROW)
344 :supportsLinearOp_(true), supportsMVByCol_(mvOrientation==DERIV_MV_BY_COL)
345 ,supportsTransMVByRow_(mvOrientation==DERIV_TRANS_MV_BY_ROW)
352 :supportsLinearOp_(false)
354 mvOrientation1==DERIV_MV_BY_COL||mvOrientation2==DERIV_MV_BY_COL )
355 ,supportsTransMVByRow_(
356 mvOrientation1==DERIV_TRANS_MV_BY_ROW||mvOrientation2==DERIV_TRANS_MV_BY_ROW )
360 { supportsLinearOp_ =
true;
return *
this; }
364 switch(mvOrientation) {
365 case DERIV_MV_BY_COL: supportsMVByCol_ =
true;
break;
366 case DERIV_TRANS_MV_BY_ROW: supportsTransMVByRow_ =
true;
break;
367 default: TEUCHOS_TEST_FOR_EXCEPT(
true);
373 {
return ( !supportsLinearOp_ && !supportsMVByCol_ && !supportsTransMVByRow_ ); }
376 {
return supportsLinearOp_; }
380 switch(mvOrientation) {
381 case DERIV_MV_BY_COL:
return supportsMVByCol_;
382 case DERIV_TRANS_MV_BY_ROW:
return supportsTransMVByRow_;
383 default: TEUCHOS_TEST_FOR_EXCEPT(
true);
388 bool supportsLinearOp_;
389 bool supportsMVByCol_;
390 bool supportsTransMVByRow_;
396 DERIV_LINEARITY_UNKNOWN
397 ,DERIV_LINEARITY_CONST
398 ,DERIV_LINEARITY_NONCONST
404 ,DERIV_RANK_DEFICIENT
417 :linearity(DERIV_LINEARITY_UNKNOWN),rank(DERIV_RANK_UNKNOWN),supportsAdjoint(false) {}
421 ):linearity(in_linearity),rank(in_rank),supportsAdjoint(in_supportsAdjoint) {}
433 const Teuchos::RCP<Epetra_MultiVector> &mv
435 ,
const Teuchos::Array<int> ¶mIndexes = Teuchos::Array<int>()
436 ) : mv_(mv), orientation_(orientation), paramIndexes_(paramIndexes) {}
439 { orientation_ = orientation; };
445 {
return orientation_; }
448 {
return paramIndexes_; }
450 Teuchos::RCP<Epetra_MultiVector> mv_;
452 Teuchos::Array<int> paramIndexes_;
467 const Teuchos::RCP<Epetra_MultiVector> &mv
469 ) : dmv_(mv,orientation) {}
478 {
return dmv_.getMultiVector(); }
481 {
return dmv_.getOrientation(); }
487 {
return !lo_.get() && !dmv_.getMultiVector().get(); }
489 Teuchos::RCP<Epetra_Operator> lo_;
501 bool isAlreadyInverted_ )
502 : PrecOp(PrecOp_), isAlreadyInverted(isAlreadyInverted_) {}
521 const Teuchos::RCP< Stokhos::EpetraMultiVectorOrthogPoly > &mv
523 ,
const Teuchos::Array<int> ¶mIndexes = Teuchos::Array<int>()
524 ) : mv_(mv), orientation_(orientation), paramIndexes_(paramIndexes) {}
527 { orientation_ = orientation; };
533 {
return orientation_; }
536 {
return paramIndexes_; }
538 Teuchos::RCP< Stokhos::EpetraMultiVectorOrthogPoly > mv_;
540 Teuchos::Array<int> paramIndexes_;
551 SGDerivative(
const Teuchos::RCP< Stokhos::EpetraOperatorOrthogPoly > &lo )
555 const Teuchos::RCP< Stokhos::EpetraMultiVectorOrthogPoly > &mv
557 ) : dmv_(mv,orientation) {}
562 Teuchos::RCP< Stokhos::EpetraOperatorOrthogPoly >
getLinearOp()
const 566 {
return dmv_.getMultiVector(); }
569 {
return dmv_.getOrientation(); }
575 {
return !lo_.get() && !dmv_.getMultiVector().get(); }
577 Teuchos::RCP< Stokhos::EpetraOperatorOrthogPoly > lo_;
591 const mp_multivector_t &mv
593 ,
const Teuchos::Array<int> ¶mIndexes = Teuchos::Array<int>()
594 ) : mv_(mv), orientation_(orientation), paramIndexes_(paramIndexes) {}
597 { orientation_ = orientation; };
603 {
return orientation_; }
606 {
return paramIndexes_; }
608 mp_multivector_t mv_;
610 Teuchos::Array<int> paramIndexes_;
626 const mp_multivector_t &mv
628 ) : dmv_(mv,orientation) {}
637 {
return dmv_.getMultiVector(); }
640 {
return dmv_.getOrientation(); }
646 {
return !lo_.get() && !dmv_.getMultiVector().get(); }
663 static const int NUM_E_OUT_ARGS_MEMBERS=9;
707 OUT_ARG_DgDx_dotdot_sg
737 OUT_ARG_DgDx_dotdot_mp
755 typedef Teuchos::RCP<Stokhos::EpetraVectorOrthogPoly>
sg_vector_t;
763 std::string modelEvalDescription()
const;
806 void set_f_sg(
const sg_vector_t& f_sg );
808 sg_vector_t get_f_sg()
const;
810 void set_f_mp(
const mp_vector_t& f_mp );
812 mp_vector_t get_f_mp()
const;
819 void set_g_sg(
int j,
const sg_vector_t &g_sg_j );
822 sg_vector_t get_g_sg(
int j)
const;
825 void set_g_mp(
int j,
const mp_vector_t &g_mp_j );
828 mp_vector_t get_g_mp(
int j)
const;
830 void set_W(
const Teuchos::RCP<Epetra_Operator> &W );
831 void set_WPrec(
const Teuchos::RCP<Epetra_Operator> &WPrec );
833 Teuchos::RCP<Epetra_Operator> get_W()
const;
834 Teuchos::RCP<Epetra_Operator> get_WPrec()
const;
839 void set_W_sg(
const sg_operator_t& W_sg );
841 sg_operator_t get_W_sg()
const;
843 void set_W_mp(
const mp_operator_t& W_sg );
845 mp_operator_t get_W_mp()
const;
847 void set_DfDp(
int l,
const Derivative &DfDp_l);
865 void set_DgDx_dot(
int j,
const Derivative &DgDx_dot_j);
866 void set_DgDx_dotdot(
int j,
const Derivative &DgDx_dotdot_j);
874 void set_DgDx_dot_sg(
int j,
const SGDerivative &DgDx_dot_j);
875 void set_DgDx_dotdot_sg(
int j,
const SGDerivative &DgDx_dotdot_j);
883 void set_DgDx_dot_mp(
int j,
const MPDerivative &DgDx_dot_j);
884 void set_DgDx_dotdot_mp(
int j,
const MPDerivative &DgDx_dotdot_j);
892 void set_DgDx(
int j,
const Derivative &DgDx_j);
910 void set_DgDp(
int j,
int l,
const Derivative &DgDp_j_l );
916 void set_DgDp_sg(
int j,
int l,
const SGDerivative &DgDp_sg_j_l );
922 void set_DgDp_mp(
int j,
int l,
const MPDerivative &DgDp_mp_j_l );
929 void set_f_poly(
const Teuchos::RCP<Teuchos::Polynomial<Epetra_Vector> > &f_poly );
931 Teuchos::RCP<Teuchos::Polynomial<Epetra_Vector> > get_f_poly()
const;
942 void setFailed()
const;
948 bool isFailed()
const;
952 void _setModelEvalDescription(
const std::string &modelEvalDescription );
954 void _set_Np_Ng(
int Np,
int Ng);
967 void _setSupports(
EOutArgs_g_sg arg,
int j,
bool supports );
979 void _setSupports(
EOutArgs_g_mp arg,
int j,
bool supports );
1022 typedef Teuchos::Array<Evaluation<Epetra_Vector> > g_t;
1023 typedef Teuchos::Array<sg_vector_t > g_sg_t;
1024 typedef Teuchos::Array<mp_vector_t > g_mp_t;
1025 typedef Teuchos::Array<Derivative> deriv_t;
1026 typedef Teuchos::Array<SGDerivative> sg_deriv_t;
1027 typedef Teuchos::Array<MPDerivative> mp_deriv_t;
1028 typedef Teuchos::Array<DerivativeProperties> deriv_properties_t;
1029 typedef Teuchos::Array<DerivativeSupport> supports_t;
1030 typedef Teuchos::Array<bool> supports_g_sg_t;
1032 std::string modelEvalDescription_;
1033 mutable bool isFailed_;
1034 bool supports_[NUM_E_OUT_ARGS_MEMBERS];
1035 supports_t supports_DfDp_;
1036 supports_t supports_DgDx_dot_;
1037 supports_t supports_DgDx_dotdot_;
1038 supports_t supports_DgDx_;
1039 supports_t supports_DgDp_;
1040 supports_g_sg_t supports_g_sg_;
1041 supports_t supports_DfDp_sg_;
1042 supports_t supports_DgDx_dot_sg_;
1043 supports_t supports_DgDx_dotdot_sg_;
1044 supports_t supports_DgDx_sg_;
1045 supports_t supports_DgDp_sg_;
1046 supports_g_sg_t supports_g_mp_;
1047 supports_t supports_DfDp_mp_;
1048 supports_t supports_DgDx_dot_mp_;
1049 supports_t supports_DgDx_dotdot_mp_;
1050 supports_t supports_DgDx_mp_;
1051 supports_t supports_DgDp_mp_;
1056 Teuchos::RCP<Epetra_Operator> W_;
1057 Teuchos::RCP<Epetra_Operator> WPrec_;
1061 deriv_properties_t DfDp_properties_;
1063 deriv_t DgDx_dotdot_;
1065 deriv_properties_t DgDx_dot_properties_;
1066 deriv_properties_t DgDx_dotdot_properties_;
1067 deriv_properties_t DgDx_properties_;
1069 deriv_properties_t DgDp_properties_;
1070 Teuchos::RCP<Teuchos::Polynomial<Epetra_Vector> > f_poly_;
1072 sg_operator_t W_sg_;
1073 sg_deriv_t DfDp_sg_;
1074 deriv_properties_t DfDp_sg_properties_;
1075 sg_deriv_t DgDx_dot_sg_;
1076 sg_deriv_t DgDx_dotdot_sg_;
1077 sg_deriv_t DgDx_sg_;
1078 deriv_properties_t DgDx_dot_sg_properties_;
1079 deriv_properties_t DgDx_dotdot_sg_properties_;
1080 deriv_properties_t DgDx_sg_properties_;
1081 sg_deriv_t DgDp_sg_;
1082 deriv_properties_t DgDp_sg_properties_;
1084 mp_operator_t W_mp_;
1085 mp_deriv_t DfDp_mp_;
1086 deriv_properties_t DfDp_mp_properties_;
1087 mp_deriv_t DgDx_dot_mp_;
1088 mp_deriv_t DgDx_dotdot_mp_;
1089 mp_deriv_t DgDx_mp_;
1090 deriv_properties_t DgDx_dot_mp_properties_;
1091 deriv_properties_t DgDx_dotdot_mp_properties_;
1092 deriv_properties_t DgDx_mp_properties_;
1093 mp_deriv_t DgDp_mp_;
1094 deriv_properties_t DgDp_mp_properties_;
1101 void assert_supports(
EOutArgsDgDp arg,
int j,
int l)
const;
1114 void assert_l(
int l)
const;
1115 void assert_j(
int j)
const;
1132 virtual Teuchos::RCP<const Epetra_Map> get_x_map()
const = 0;
1135 virtual Teuchos::RCP<const Epetra_Map> get_f_map()
const = 0;
1138 virtual Teuchos::RCP<const Epetra_Map> get_p_map(
int l)
const;
1154 virtual Teuchos::RCP<const Teuchos::Array<std::string> > get_p_names(
int l)
const;
1157 virtual Teuchos::RCP<const Epetra_Map> get_g_map(
int j)
const;
1173 virtual Teuchos::ArrayView<const std::string> get_g_names(
int j)
const;
1181 virtual Teuchos::RCP<const Epetra_Vector> get_x_init()
const;
1184 virtual Teuchos::RCP<const Epetra_Vector> get_x_dot_init()
const;
1187 virtual Teuchos::RCP<const Epetra_Vector> get_x_dotdot_init()
const;
1190 virtual Teuchos::RCP<const Epetra_Vector> get_p_init(
int l)
const;
1193 virtual double get_t_init()
const;
1204 virtual double getInfBound()
const;
1207 virtual Teuchos::RCP<const Epetra_Vector> get_x_lower_bounds()
const;
1210 virtual Teuchos::RCP<const Epetra_Vector> get_x_upper_bounds()
const;
1213 virtual Teuchos::RCP<const Epetra_Vector> get_p_lower_bounds(
int l)
const;
1216 virtual Teuchos::RCP<const Epetra_Vector> get_p_upper_bounds(
int l)
const;
1219 virtual double get_t_lower_bound()
const;
1222 virtual double get_t_upper_bound()
const;
1235 virtual Teuchos::RCP<Epetra_Operator> create_W()
const;
1236 virtual Teuchos::RCP<EpetraExt::ModelEvaluator::Preconditioner> create_WPrec()
const;
1239 virtual Teuchos::RCP<Epetra_Operator> create_DfDp_op(
int l)
const;
1242 virtual Teuchos::RCP<Epetra_Operator> create_DgDx_dot_op(
int j)
const;
1245 virtual Teuchos::RCP<Epetra_Operator> create_DgDx_dotdot_op(
int j)
const;
1248 virtual Teuchos::RCP<Epetra_Operator> create_DgDx_op(
int j)
const;
1251 virtual Teuchos::RCP<Epetra_Operator> create_DgDp_op(
int j,
int l )
const;
1259 virtual InArgs createInArgs()
const = 0;
1262 virtual OutArgs createOutArgs()
const = 0;
1265 virtual void evalModel(
const InArgs& inArgs,
const OutArgs& outArgs )
const = 0;
1267 #ifdef HAVE_PYTRILINOS 1269 friend InArgs convertInArgsFromPython(PyObject * source);
1272 friend OutArgs convertOutArgsFromPython(PyObject * source);
1285 void setModelEvalDescription(
const std::string &modelEvalDescription );
1287 void set_Np(
int Np);
1291 void setSupports(
EInArgs_p_sg arg,
int l,
bool supports );
1293 void setSupports(
EInArgs_p_mp arg,
int l,
bool supports );
1300 void setModelEvalDescription(
const std::string &modelEvalDescription );
1302 void set_Np_Ng(
int Np,
int Ng);
1315 void setSupports(
EOutArgs_g_sg arg,
int j,
bool supports );
1326 void setSupports(
EOutArgs_g_mp arg,
int j,
bool supports );
1385 Teuchos::RCP<Epetra_Operator>
1387 const std::string &modelEvalDescription,
1389 const std::string &derivName
1393 Teuchos::RCP<Epetra_MultiVector>
1395 const std::string &modelEvalDescription,
1397 const std::string &derivName,
1402 Teuchos::RCP<Epetra_Operator>
1409 Teuchos::RCP<Epetra_MultiVector>
1416 Teuchos::RCP<Epetra_MultiVector>
1424 Teuchos::RCP<Epetra_MultiVector>
1432 Teuchos::RCP<Epetra_MultiVector>
1440 Teuchos::RCP<Epetra_MultiVector>
1456 std::string ModelEvaluator::InArgs::modelEvalDescription()
const 1457 {
return modelEvalDescription_; }
1460 int ModelEvaluator::InArgs::Np()
const 1461 {
return p_.size(); }
1464 void ModelEvaluator::InArgs::set_x_dot(
const Teuchos::RCP<const Epetra_Vector> &x_dot )
1465 { assert_supports(IN_ARG_x_dot); x_dot_ = x_dot; }
1468 void ModelEvaluator::InArgs::set_x_dotdot(
const Teuchos::RCP<const Epetra_Vector> &x_dotdot )
1469 { assert_supports(IN_ARG_x_dotdot); x_dotdot_ = x_dotdot; }
1472 Teuchos::RCP<const Epetra_Vector> ModelEvaluator::InArgs::get_x_dot()
const 1473 { assert_supports(IN_ARG_x_dot);
return x_dot_; }
1476 Teuchos::RCP<const Epetra_Vector> ModelEvaluator::InArgs::get_x_dotdot()
const 1477 { assert_supports(IN_ARG_x_dotdot);
return x_dotdot_; }
1480 void ModelEvaluator::InArgs::set_x(
const Teuchos::RCP<const Epetra_Vector> &x )
1481 { assert_supports(IN_ARG_x); x_ = x; }
1484 Teuchos::RCP<const Epetra_Vector> ModelEvaluator::InArgs::get_x()
const 1485 { assert_supports(IN_ARG_x);
return x_; }
1488 void ModelEvaluator::InArgs::set_x_dot_poly(
const Teuchos::RCP<
const Teuchos::Polynomial<Epetra_Vector> > &x_dot_poly )
1489 { assert_supports(IN_ARG_x_dot_poly); x_dot_poly_ = x_dot_poly; }
1492 void ModelEvaluator::InArgs::set_x_dotdot_poly(
const Teuchos::RCP<
const Teuchos::Polynomial<Epetra_Vector> > &x_dotdot_poly )
1493 { assert_supports(IN_ARG_x_dotdot_poly); x_dotdot_poly_ = x_dotdot_poly; }
1496 Teuchos::RCP<const Teuchos::Polynomial<Epetra_Vector> >
1497 ModelEvaluator::InArgs::get_x_dot_poly()
const 1498 { assert_supports(IN_ARG_x_dot_poly);
return x_dot_poly_; }
1501 Teuchos::RCP<const Teuchos::Polynomial<Epetra_Vector> >
1502 ModelEvaluator::InArgs::get_x_dotdot_poly()
const 1503 { assert_supports(IN_ARG_x_dotdot_poly);
return x_dotdot_poly_; }
1506 void ModelEvaluator::InArgs::set_x_poly(
const Teuchos::RCP<
const Teuchos::Polynomial<Epetra_Vector> > &x_poly )
1507 { assert_supports(IN_ARG_x_poly); x_poly_ = x_poly; }
1510 Teuchos::RCP<const Teuchos::Polynomial<Epetra_Vector> >
1511 ModelEvaluator::InArgs::get_x_poly()
const 1512 { assert_supports(IN_ARG_x_poly);
return x_poly_; }
1516 { assert_supports(IN_ARG_x_dot_sg); x_dot_sg_ = x_dot_sg; }
1520 { assert_supports(IN_ARG_x_dotdot_sg); x_dotdot_sg_ = x_dotdot_sg; }
1524 ModelEvaluator::InArgs::get_x_dot_sg()
const 1525 { assert_supports(IN_ARG_x_dot_sg);
return x_dot_sg_; }
1529 ModelEvaluator::InArgs::get_x_dotdot_sg()
const 1530 { assert_supports(IN_ARG_x_dotdot_sg);
return x_dotdot_sg_; }
1534 { assert_supports(IN_ARG_x_dot_mp); x_dot_mp_ = x_dot_mp; }
1538 { assert_supports(IN_ARG_x_dotdot_mp); x_dotdot_mp_ = x_dotdot_mp; }
1542 ModelEvaluator::InArgs::get_x_dot_mp()
const 1543 { assert_supports(IN_ARG_x_dot_mp);
return x_dot_mp_; }
1547 ModelEvaluator::InArgs::get_x_dotdot_mp()
const 1548 { assert_supports(IN_ARG_x_dotdot_mp);
return x_dotdot_mp_; }
1552 { assert_supports(IN_ARG_x_sg); x_sg_ = x_sg; }
1556 ModelEvaluator::InArgs::get_x_sg()
const 1557 { assert_supports(IN_ARG_x_sg);
return x_sg_; }
1561 { assert_supports(IN_ARG_x_mp); x_mp_ = x_mp; }
1565 ModelEvaluator::InArgs::get_x_mp()
const 1566 { assert_supports(IN_ARG_x_mp);
return x_mp_; }
1569 void ModelEvaluator::InArgs::set_p(
int l,
const Teuchos::RCP<const Epetra_Vector> &p_l )
1570 { assert_l(l); p_[l] = p_l; }
1573 Teuchos::RCP<const Epetra_Vector> ModelEvaluator::InArgs::get_p(
int l)
const 1574 { assert_l(l);
return p_[l]; }
1577 void ModelEvaluator::InArgs::set_p_sg(
int l,
1579 { assert_supports(IN_ARG_p_sg, l); p_sg_[l] = p_sg_l; }
1583 ModelEvaluator::InArgs::get_p_sg(
int l)
const 1584 { assert_supports(IN_ARG_p_sg, l);
return p_sg_[l]; }
1587 void ModelEvaluator::InArgs::set_p_mp(
int l,
1589 { assert_supports(IN_ARG_p_mp, l); p_mp_[l] = p_mp_l; }
1593 ModelEvaluator::InArgs::get_p_mp(
int l)
const 1594 { assert_supports(IN_ARG_p_mp, l);
return p_mp_[l]; }
1597 void ModelEvaluator::InArgs::set_t(
double t )
1598 { assert_supports(IN_ARG_t); t_ = t; }
1601 double ModelEvaluator::InArgs::get_t()
const 1602 { assert_supports(IN_ARG_t);
return t_; }
1605 void ModelEvaluator::InArgs::set_alpha(
double alpha )
1606 { assert_supports(IN_ARG_alpha); alpha_ = alpha; }
1609 double ModelEvaluator::InArgs::get_alpha()
const 1610 { assert_supports(IN_ARG_alpha);
return alpha_; }
1613 void ModelEvaluator::InArgs::set_omega(
double omega )
1614 { assert_supports(IN_ARG_omega); omega_ = omega; }
1617 double ModelEvaluator::InArgs::get_omega()
const 1618 { assert_supports(IN_ARG_omega);
return omega_; }
1621 void ModelEvaluator::InArgs::set_beta(
double beta )
1622 { assert_supports(IN_ARG_beta); beta_ = beta; }
1625 double ModelEvaluator::InArgs::get_beta()
const 1626 { assert_supports(IN_ARG_beta);
return beta_; }
1630 { assert_supports(IN_ARG_sg_basis); sg_basis_ = basis; }
1633 Teuchos::RCP<const Stokhos::OrthogPolyBasis<int,double> >
1634 ModelEvaluator::InArgs::get_sg_basis()
const 1635 { assert_supports(IN_ARG_sg_basis);
return sg_basis_; }
1639 { assert_supports(IN_ARG_sg_quadrature); sg_quad_ = quad; }
1642 Teuchos::RCP<const Stokhos::Quadrature<int,double> >
1643 ModelEvaluator::InArgs::get_sg_quadrature()
const 1644 { assert_supports(IN_ARG_sg_quadrature);
return sg_quad_; }
1648 { assert_supports(IN_ARG_sg_expansion); sg_exp_ = exp; }
1651 Teuchos::RCP<Stokhos::OrthogPolyExpansion<int,double,Stokhos::StandardStorage<int,double> > >
1652 ModelEvaluator::InArgs::get_sg_expansion()
const 1653 { assert_supports(IN_ARG_sg_expansion);
return sg_exp_; }
1656 void ModelEvaluator::InArgs::_setModelEvalDescription(
const std::string &new_modelEvalDescription )
1658 modelEvalDescription_ = new_modelEvalDescription;
1662 void ModelEvaluator::InArgs::_set_Np(
int new_Np)
1665 p_sg_.resize(new_Np);
1666 p_mp_.resize(new_Np);
1667 supports_p_sg_.resize(new_Np);
1668 supports_p_mp_.resize(new_Np);
1676 std::string ModelEvaluator::OutArgs::modelEvalDescription()
const 1677 {
return modelEvalDescription_; }
1680 int ModelEvaluator::OutArgs::Np()
const 1682 return DfDp_.size();
1686 int ModelEvaluator::OutArgs::Ng()
const 1696 ModelEvaluator::OutArgs::get_f()
const {
return f_; }
1707 ModelEvaluator::OutArgs::get_g(
int j)
const 1714 void ModelEvaluator::OutArgs::set_g_sg(
int j,
const sg_vector_t &g_sg_j )
1716 assert_supports(OUT_ARG_g_sg, j);
1722 ModelEvaluator::OutArgs::get_g_sg(
int j)
const 1724 assert_supports(OUT_ARG_g_sg, j);
1729 void ModelEvaluator::OutArgs::set_g_mp(
int j,
const mp_vector_t &g_mp_j )
1731 assert_supports(OUT_ARG_g_mp, j);
1737 ModelEvaluator::OutArgs::get_g_mp(
int j)
const 1739 assert_supports(OUT_ARG_g_mp, j);
1744 void ModelEvaluator::OutArgs::set_W(
const Teuchos::RCP<Epetra_Operator> &W ) { W_ = W; }
1746 void ModelEvaluator::OutArgs::set_WPrec(
const Teuchos::RCP<Epetra_Operator> &WPrec ) { WPrec_ = WPrec; }
1749 Teuchos::RCP<Epetra_Operator> ModelEvaluator::OutArgs::get_W()
const {
return W_; }
1751 Teuchos::RCP<Epetra_Operator> ModelEvaluator::OutArgs::get_WPrec()
const {
return WPrec_; }
1755 {
return W_properties_; }
1758 {
return WPrec_properties_; }
1761 void ModelEvaluator::OutArgs::set_DfDp(
int l,
const Derivative &DfDp_l )
1763 assert_supports(OUT_ARG_DfDp,l);
1769 ModelEvaluator::OutArgs::get_DfDp(
int l)
const 1771 assert_supports(OUT_ARG_DfDp,l);
1777 ModelEvaluator::OutArgs::get_DfDp_properties(
int l)
const 1779 assert_supports(OUT_ARG_DfDp,l);
1780 return DfDp_properties_[l];
1784 void ModelEvaluator::OutArgs::set_DfDp_sg(
int l,
const SGDerivative &DfDp_sg_l )
1786 assert_supports(OUT_ARG_DfDp_sg,l);
1787 DfDp_sg_[l] = DfDp_sg_l;
1792 ModelEvaluator::OutArgs::get_DfDp_sg(
int l)
const 1794 assert_supports(OUT_ARG_DfDp_sg,l);
1800 ModelEvaluator::OutArgs::get_DfDp_sg_properties(
int l)
const 1802 assert_supports(OUT_ARG_DfDp_sg,l);
1803 return DfDp_sg_properties_[l];
1807 void ModelEvaluator::OutArgs::set_DfDp_mp(
int l,
const MPDerivative &DfDp_mp_l )
1809 assert_supports(OUT_ARG_DfDp_mp,l);
1810 DfDp_mp_[l] = DfDp_mp_l;
1815 ModelEvaluator::OutArgs::get_DfDp_mp(
int l)
const 1817 assert_supports(OUT_ARG_DfDp_mp,l);
1823 ModelEvaluator::OutArgs::get_DfDp_mp_properties(
int l)
const 1825 assert_supports(OUT_ARG_DfDp_mp,l);
1826 return DfDp_mp_properties_[l];
1830 void ModelEvaluator::OutArgs::set_DgDx_dot(
int j,
const Derivative &DgDx_dot_j )
1832 assert_supports(OUT_ARG_DgDx_dot,j);
1833 DgDx_dot_[j] = DgDx_dot_j;
1838 ModelEvaluator::OutArgs::get_DgDx_dot(
int j)
const 1840 assert_supports(OUT_ARG_DgDx_dot,j);
1841 return DgDx_dot_[j];
1846 ModelEvaluator::OutArgs::get_DgDx_dot_properties(
int j)
const 1848 assert_supports(OUT_ARG_DgDx_dot,j);
1849 return DgDx_dot_properties_[j];
1853 void ModelEvaluator::OutArgs::set_DgDx_dot_sg(
int j,
const SGDerivative &DgDx_dot_sg_j )
1855 assert_supports(OUT_ARG_DgDx_dot_sg,j);
1856 DgDx_dot_sg_[j] = DgDx_dot_sg_j;
1861 ModelEvaluator::OutArgs::get_DgDx_dot_sg(
int j)
const 1863 assert_supports(OUT_ARG_DgDx_dot_sg,j);
1864 return DgDx_dot_sg_[j];
1869 ModelEvaluator::OutArgs::get_DgDx_dot_sg_properties(
int j)
const 1871 assert_supports(OUT_ARG_DgDx_dot_sg,j);
1872 return DgDx_dot_sg_properties_[j];
1876 void ModelEvaluator::OutArgs::set_DgDx_dot_mp(
int j,
const MPDerivative &DgDx_dot_mp_j )
1878 assert_supports(OUT_ARG_DgDx_dot_mp,j);
1879 DgDx_dot_mp_[j] = DgDx_dot_mp_j;
1884 ModelEvaluator::OutArgs::get_DgDx_dot_mp(
int j)
const 1886 assert_supports(OUT_ARG_DgDx_dot_mp,j);
1887 return DgDx_dot_mp_[j];
1892 ModelEvaluator::OutArgs::get_DgDx_dot_mp_properties(
int j)
const 1894 assert_supports(OUT_ARG_DgDx_dot_mp,j);
1895 return DgDx_dot_mp_properties_[j];
1899 void ModelEvaluator::OutArgs::set_DgDx_dotdot(
int j,
const Derivative &DgDx_dotdot_j )
1901 assert_supports(OUT_ARG_DgDx_dotdot,j);
1902 DgDx_dotdot_[j] = DgDx_dotdot_j;
1907 ModelEvaluator::OutArgs::get_DgDx_dotdot(
int j)
const 1909 assert_supports(OUT_ARG_DgDx_dotdot,j);
1910 return DgDx_dotdot_[j];
1915 ModelEvaluator::OutArgs::get_DgDx_dotdot_properties(
int j)
const 1917 assert_supports(OUT_ARG_DgDx_dotdot,j);
1918 return DgDx_dotdot_properties_[j];
1922 void ModelEvaluator::OutArgs::set_DgDx_dotdot_sg(
int j,
const SGDerivative &DgDx_dotdot_sg_j )
1924 assert_supports(OUT_ARG_DgDx_dotdot_sg,j);
1925 DgDx_dotdot_sg_[j] = DgDx_dotdot_sg_j;
1930 ModelEvaluator::OutArgs::get_DgDx_dotdot_sg(
int j)
const 1932 assert_supports(OUT_ARG_DgDx_dotdot_sg,j);
1933 return DgDx_dotdot_sg_[j];
1938 ModelEvaluator::OutArgs::get_DgDx_dotdot_sg_properties(
int j)
const 1940 assert_supports(OUT_ARG_DgDx_dotdot_sg,j);
1941 return DgDx_dotdot_sg_properties_[j];
1945 void ModelEvaluator::OutArgs::set_DgDx_dotdot_mp(
int j,
const MPDerivative &DgDx_dotdot_mp_j )
1947 assert_supports(OUT_ARG_DgDx_dotdot_mp,j);
1948 DgDx_dotdot_mp_[j] = DgDx_dotdot_mp_j;
1953 ModelEvaluator::OutArgs::get_DgDx_dotdot_mp(
int j)
const 1955 assert_supports(OUT_ARG_DgDx_dotdot_mp,j);
1956 return DgDx_dotdot_mp_[j];
1961 ModelEvaluator::OutArgs::get_DgDx_dotdot_mp_properties(
int j)
const 1963 assert_supports(OUT_ARG_DgDx_dotdot_mp,j);
1964 return DgDx_dotdot_mp_properties_[j];
1968 void ModelEvaluator::OutArgs::set_DgDx(
int j,
const Derivative &DgDx_j )
1970 assert_supports(OUT_ARG_DgDx,j);
1976 ModelEvaluator::OutArgs::get_DgDx(
int j)
const 1978 assert_supports(OUT_ARG_DgDx,j);
1984 ModelEvaluator::OutArgs::get_DgDx_properties(
int j)
const 1986 assert_supports(OUT_ARG_DgDx,j);
1987 return DgDx_properties_[j];
1991 void ModelEvaluator::OutArgs::set_DgDx_sg(
int j,
const SGDerivative &DgDx_sg_j )
1993 assert_supports(OUT_ARG_DgDx_sg,j);
1994 DgDx_sg_[j] = DgDx_sg_j;
1999 ModelEvaluator::OutArgs::get_DgDx_sg(
int j)
const 2001 assert_supports(OUT_ARG_DgDx_sg,j);
2007 ModelEvaluator::OutArgs::get_DgDx_sg_properties(
int j)
const 2009 assert_supports(OUT_ARG_DgDx_sg,j);
2010 return DgDx_sg_properties_[j];
2014 void ModelEvaluator::OutArgs::set_DgDx_mp(
int j,
const MPDerivative &DgDx_mp_j )
2016 assert_supports(OUT_ARG_DgDx_mp,j);
2017 DgDx_mp_[j] = DgDx_mp_j;
2022 ModelEvaluator::OutArgs::get_DgDx_mp(
int j)
const 2024 assert_supports(OUT_ARG_DgDx_mp,j);
2030 ModelEvaluator::OutArgs::get_DgDx_mp_properties(
int j)
const 2032 assert_supports(OUT_ARG_DgDx_mp,j);
2033 return DgDx_mp_properties_[j];
2037 void ModelEvaluator::OutArgs::set_DgDp(
int j,
int l,
const Derivative &DgDp_j_l )
2039 assert_supports(OUT_ARG_DgDp,j,l);
2040 DgDp_[ j*Np() + l ] = DgDp_j_l;
2045 ModelEvaluator::OutArgs::get_DgDp(
int j,
int l)
const 2047 assert_supports(OUT_ARG_DgDp,j,l);
2048 return DgDp_[ j*Np() + l ];
2053 ModelEvaluator::OutArgs::get_DgDp_properties(
int j,
int l)
const 2055 assert_supports(OUT_ARG_DgDp,j,l);
2056 return DgDp_properties_[ j*Np() + l ];
2060 void ModelEvaluator::OutArgs::set_DgDp_sg(
int j,
int l,
const SGDerivative &DgDp_sg_j_l )
2062 assert_supports(OUT_ARG_DgDp_sg,j,l);
2063 DgDp_sg_[ j*Np() + l ] = DgDp_sg_j_l;
2068 ModelEvaluator::OutArgs::get_DgDp_sg(
int j,
int l)
const 2070 assert_supports(OUT_ARG_DgDp_sg,j,l);
2071 return DgDp_sg_[ j*Np() + l ];
2076 ModelEvaluator::OutArgs::get_DgDp_sg_properties(
int j,
int l)
const 2078 assert_supports(OUT_ARG_DgDp_sg,j,l);
2079 return DgDp_sg_properties_[ j*Np() + l ];
2083 void ModelEvaluator::OutArgs::set_DgDp_mp(
int j,
int l,
const MPDerivative &DgDp_mp_j_l )
2085 assert_supports(OUT_ARG_DgDp_mp,j,l);
2086 DgDp_mp_[ j*Np() + l ] = DgDp_mp_j_l;
2091 ModelEvaluator::OutArgs::get_DgDp_mp(
int j,
int l)
const 2093 assert_supports(OUT_ARG_DgDp_mp,j,l);
2094 return DgDp_mp_[ j*Np() + l ];
2099 ModelEvaluator::OutArgs::get_DgDp_mp_properties(
int j,
int l)
const 2101 assert_supports(OUT_ARG_DgDp_mp,j,l);
2102 return DgDp_mp_properties_[ j*Np() + l ];
2106 void ModelEvaluator::OutArgs::set_f_poly(
const Teuchos::RCP<Teuchos::Polynomial<Epetra_Vector> > &f_poly )
2107 { f_poly_ = f_poly; }
2110 Teuchos::RCP<Teuchos::Polynomial<Epetra_Vector> >
2111 ModelEvaluator::OutArgs::get_f_poly()
const 2120 ModelEvaluator::OutArgs::get_f_sg()
const 2135 ModelEvaluator::OutArgs::get_f_mp()
const 2149 void ModelEvaluator::InArgsSetup::setModelEvalDescription(
const std::string &new_modelEvalDescription )
2151 this->_setModelEvalDescription(new_modelEvalDescription);
2155 void ModelEvaluator::InArgsSetup::set_Np(
int new_Np)
2156 { this->_set_Np(new_Np); }
2159 void ModelEvaluator::InArgsSetup::setSupports(
EInArgsMembers arg,
bool new_supports )
2160 { this->_setSupports(arg,new_supports); }
2163 void ModelEvaluator::InArgsSetup::setSupports(
EInArgs_p_sg arg,
int l,
bool new_supports )
2164 { this->_setSupports(arg,l,new_supports); }
2167 void ModelEvaluator::InArgsSetup::setSupports(
EInArgs_p_mp arg,
int l,
bool new_supports )
2168 { this->_setSupports(arg,l,new_supports); }
2175 void ModelEvaluator::OutArgsSetup::setModelEvalDescription(
const std::string &new_modelEvalDescription )
2177 this->_setModelEvalDescription(new_modelEvalDescription);
2181 void ModelEvaluator::OutArgsSetup::set_Np_Ng(
int new_Np,
int new_Ng)
2182 { this->_set_Np_Ng(new_Np,new_Ng); }
2186 { this->_setSupports(arg,new_supports); }
2190 { this->_setSupports(arg,l,new_supports); }
2194 { this->_setSupports(arg,j,new_supports); }
2198 { this->_setSupports(arg,j,new_supports); }
2202 { this->_setSupports(arg,j,new_supports); }
2206 { this->_setSupports(arg,j,l,new_supports); }
2209 void ModelEvaluator::OutArgsSetup::setSupports(
EOutArgs_g_sg arg,
int j,
bool new_supports )
2210 { this->_setSupports(arg,j,new_supports); }
2214 { this->_setSupports(arg,l,new_supports); }
2218 { this->_setSupports(arg,j,new_supports); }
2222 { this->_setSupports(arg,j,new_supports); }
2226 { this->_setSupports(arg,j,new_supports); }
2230 { this->_setSupports(arg,j,l,new_supports); }
2233 void ModelEvaluator::OutArgsSetup::setSupports(
EOutArgs_g_mp arg,
int j,
bool new_supports )
2234 { this->_setSupports(arg,j,new_supports); }
2238 { this->_setSupports(arg,l,new_supports); }
2242 { this->_setSupports(arg,j,new_supports); }
2246 { this->_setSupports(arg,j,new_supports); }
2250 { this->_setSupports(arg,j,new_supports); }
2254 { this->_setSupports(arg,j,l,new_supports); }
2258 { this->_set_W_properties(properties); }
2261 { this->_set_WPrec_properties(properties); }
2266 this->_set_DfDp_properties(l,properties);
2272 this->_set_DgDx_dot_properties(j,properties);
2278 this->_set_DgDx_dotdot_properties(j,properties);
2284 this->_set_DgDx_properties(j,properties);
2290 this->_set_DgDp_properties(j,l,properties);
2296 this->_set_DfDp_sg_properties(l,properties);
2302 this->_set_DgDx_dot_sg_properties(j,properties);
2308 this->_set_DgDx_dotdot_sg_properties(j,properties);
2314 this->_set_DgDx_sg_properties(j,properties);
2320 this->_set_DgDp_sg_properties(j,l,properties);
2326 this->_set_DfDp_mp_properties(l,properties);
2332 this->_set_DgDx_dot_mp_properties(j,properties);
2338 this->_set_DgDx_dotdot_mp_properties(j,properties);
2344 this->_set_DgDx_mp_properties(j,properties);
2350 this->_set_DgDp_mp_properties(j,l,properties);
2355 #endif // EPETRA_EXT_MODEL_EVALUATOR_HPP Simple aggregate class that stores a derivative object as a general linear operator or as a multi-vec...
DerivativeMultiVector getDerivativeMultiVector() const
EDerivativeMultiVectorOrientation getMultiVectorOrientation() const
MPDerivative(const mp_operator_t &lo)
MPDerivativeMultiVector(const mp_multivector_t &mv, const EDerivativeMultiVectorOrientation orientation=DERIV_MV_BY_COL, const Teuchos::Array< int > ¶mIndexes=Teuchos::Array< int >())
EEvalType getType() const
Preconditioner()
Default constructor of null Operatir.
bool supports(EDerivativeLinearOp) const
Teuchos::RCP< Stokhos::EpetraOperatorOrthogPoly > sg_operator_t
Short-hand for stochastic Galerkin operator type.
MPDerivativeMultiVector()
bool isAlreadyInverted
Bool flag.
Preconditioner(const Teuchos::RCP< Epetra_Operator > &PrecOp_, bool isAlreadyInverted_)
Usable constructor to set the (Epetra_Operator,bool) pair.
Teuchos::RCP< Epetra_Operator > getLinearOp(const std::string &modelEvalDescription, const ModelEvaluator::Derivative &deriv, const std::string &derivName)
Teuchos::RCP< Epetra_MultiVector > get_DgDp_mv(const int j, const int l, const ModelEvaluator::OutArgs &outArgs, const ModelEvaluator::EDerivativeMultiVectorOrientation mvOrientation)
mp_multivector_t getMultiVector() const
SGDerivativeMultiVector(const Teuchos::RCP< Stokhos::EpetraMultiVectorOrthogPoly > &mv, const EDerivativeMultiVectorOrientation orientation=DERIV_MV_BY_COL, const Teuchos::Array< int > ¶mIndexes=Teuchos::Array< int >())
std::string toString(ModelEvaluator::EOutArgsMembers outArg)
Teuchos::RCP< Epetra_MultiVector > get_DgDx_dot_mv(const int j, const ModelEvaluator::OutArgs &outArgs, const ModelEvaluator::EDerivativeMultiVectorOrientation mvOrientation)
Teuchos::RCP< Stokhos::ProductEpetraMultiVector > mp_multivector_t
Teuchos::RCP< Stokhos::EpetraMultiVectorOrthogPoly > getMultiVector() const
Teuchos::RCP< Stokhos::ProductEpetraOperator > mp_operator_t
Teuchos::RCP< const Stokhos::ProductEpetraMultiVector > mp_const_multivector_t
SGDerivativeMultiVector getDerivativeMultiVector() const
Teuchos::RCP< Epetra_Operator > PrecOp
Accessor for the Epetra_Operator.
DerivativeSupport(EDerivativeMultiVectorOrientation mvOrientation)
const Teuchos::Array< int > & getParamIndexes() const
Teuchos::RCP< Epetra_Operator > getLinearOp() const
bool supports(EDerivativeMultiVectorOrientation mvOrientation) const
Simple aggregate class that stores a derivative object as a general linear operator or as a multi-vec...
EDerivativeMultiVectorOrientation getOrientation() const
Teuchos::RCP< Epetra_MultiVector > getMultiVector(const std::string &modelEvalDescription, const ModelEvaluator::Derivative &deriv, const std::string &derivName, const ModelEvaluator::EDerivativeMultiVectorOrientation mvOrientation)
void changeOrientation(const EDerivativeMultiVectorOrientation orientation)
EpetraExt::BlockCrsMatrix: A class for constructing a distributed block matrix.
Simple aggregate class that stores a derivative object as a general linear operator or as a multi-vec...
EDerivativeLinearity linearity
DerivativeSupport(EDerivativeLinearOp)
Teuchos::RCP< Stokhos::EpetraOperatorOrthogPoly > getLinearOp() const
Simple aggregate class for a derivative object represented as a column-wise multi-vector or its trans...
MPDerivativeMultiVector getDerivativeMultiVector() const
Teuchos::RCP< Stokhos::EpetraVectorOrthogPoly > sg_vector_t
Short-hand for stochastic Galerkin vector type.
Teuchos::RCP< Epetra_MultiVector > getMultiVector() const
Evaluation(const Teuchos::RCP< ObjType > &obj)
Teuchos::RCP< const Stokhos::EpetraVectorOrthogPoly > sg_const_vector_t
Short-hand for stochastic Galerkin vector type.
Teuchos::RCP< Epetra_MultiVector > get_DfDp_mv(const int l, const ModelEvaluator::OutArgs &outArgs)
Derivative(const DerivativeMultiVector &dmv)
Simple aggregate class for a derivative object represented as a column-wise multi-vector or its trans...
Teuchos::RCP< Epetra_MultiVector > getMultiVector() const
const Teuchos::Array< int > & getParamIndexes() const
SGDerivativeMultiVector()
Teuchos::RCP< Epetra_Operator > get_DfDp_op(const int l, const ModelEvaluator::OutArgs &outArgs)
MPDerivative(const MPDerivativeMultiVector &dmv)
DerivativeSupport & plus(EDerivativeMultiVectorOrientation mvOrientation)
MPDerivative(const mp_multivector_t &mv, const EDerivativeMultiVectorOrientation orientation=DERIV_MV_BY_COL)
Teuchos::RCP< const Stokhos::ProductEpetraVector > mp_const_vector_t
EDerivativeMultiVectorOrientation getOrientation() const
Teuchos::RCP< Epetra_MultiVector > get_DgDx_mv(const int j, const ModelEvaluator::OutArgs &outArgs, const ModelEvaluator::EDerivativeMultiVectorOrientation mvOrientation)
Derivative(const Teuchos::RCP< Epetra_Operator > &lo)
mp_operator_t getLinearOp() const
EDerivativeMultiVectorOrientation
DerivativeProperties(EDerivativeLinearity in_linearity, ERankStatus in_rank, bool in_supportsAdjoint)
SGDerivative(const Teuchos::RCP< Stokhos::EpetraOperatorOrthogPoly > &lo)
Teuchos::RCP< Stokhos::EpetraMultiVectorOrthogPoly > getMultiVector() const
EDerivativeMultiVectorOrientation getMultiVectorOrientation() const
Derivative(const Teuchos::RCP< Epetra_MultiVector > &mv, const EDerivativeMultiVectorOrientation orientation=DERIV_MV_BY_COL)
DerivativeMultiVector(const Teuchos::RCP< Epetra_MultiVector > &mv, const EDerivativeMultiVectorOrientation orientation=DERIV_MV_BY_COL, const Teuchos::Array< int > ¶mIndexes=Teuchos::Array< int >())
void changeOrientation(const EDerivativeMultiVectorOrientation orientation)
void reset(const Teuchos::RCP< ObjType > &obj, EEvalType evalType)
Simple aggregate struct that stores a preconditioner as an Epetra_Operator and a bool, about whether it is inverted or not.
EDerivativeMultiVectorOrientation getOrientation() const
Teuchos::RCP< Epetra_MultiVector > get_DgDx_dotdot_mv(const int j, const ModelEvaluator::OutArgs &outArgs, const ModelEvaluator::EDerivativeMultiVectorOrientation mvOrientation)
SGDerivative(const Teuchos::RCP< Stokhos::EpetraMultiVectorOrthogPoly > &mv, const EDerivativeMultiVectorOrientation orientation=DERIV_MV_BY_COL)
DerivativeSupport(EDerivativeLinearOp, EDerivativeMultiVectorOrientation mvOrientation)
EDerivativeMultiVectorOrientation getMultiVectorOrientation() const
mp_multivector_t getMultiVector() const
Teuchos::RCP< Stokhos::ProductEpetraVector > mp_vector_t
Simple aggregate class for a derivative object represented as a column-wise multi-vector or its trans...
SGDerivative(const SGDerivativeMultiVector &dmv)
const Teuchos::Array< int > & getParamIndexes() const
void changeOrientation(const EDerivativeMultiVectorOrientation orientation)
DerivativeSupport(EDerivativeMultiVectorOrientation mvOrientation1, EDerivativeMultiVectorOrientation mvOrientation2)
DerivativeSupport & plus(EDerivativeLinearOp)
Base interface for evaluating a stateless "model".
Teuchos::RCP< const Stokhos::ProductEpetraOperator > mp_const_operator_t
Evaluation(const Teuchos::RCP< ObjType > &obj, EEvalType evalType)