Stokhos Package Browser (Single Doxygen Collection)  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Stokhos_SGQuadMPModelEvaluator.hpp
Go to the documentation of this file.
1 // @HEADER
2 // *****************************************************************************
3 // Stokhos Package
4 //
5 // Copyright 2009 NTESS and the Stokhos contributors.
6 // SPDX-License-Identifier: BSD-3-Clause
7 // *****************************************************************************
8 // @HEADER
9 
10 #ifndef STOKHOS_SGQUADMPMODELEVALUATOR_HPP
11 #define STOKHOS_SGQUADMPMODELEVALUATOR_HPP
12 
13 #include "EpetraExt_ModelEvaluator.h"
14 #include "EpetraExt_MultiComm.h"
15 
16 #include "Teuchos_RCP.hpp"
17 #include "Teuchos_Array.hpp"
18 
19 namespace Stokhos {
20 
32  class SGQuadMPModelEvaluator : public EpetraExt::ModelEvaluator {
33  public:
34 
35  // Constructor
40 
43 
46 
49 
52 
55 
58  get_p_names(int l) const;
59 
62 
65 
68 
70  InArgs createInArgs() const;
71 
73  OutArgs createOutArgs() const;
74 
76  void evalModel(const InArgs& inArgs, const OutArgs& outArgs) const;
77 
79 
80  protected:
81 
84 
87 
90 
93 
95  int num_p;
96 
98  int num_g;
99 
101  int num_p_mp;
102 
104  int num_g_mp;
105 
108 
111 
113  mp_vector_t x_dot_mp;
114 
116  mp_vector_t x_mp;
117 
120 
122  mp_vector_t f_mp;
123 
125  mp_operator_t W_mp;
126 
129 
132 
135 
138 
141 
142  };
143 
144 }
145 
146 #endif // STOKHOS_SGQUADMPMODELEVALUATOR_HPP
mp_vector_t x_dot_mp
Time derivative vector.
Teuchos::RCP< const Stokhos::Quadrature< int, double > > sg_quad
SG quadrature.
Teuchos::RCP< Epetra_Operator > create_W() const
Create W = alpha*M + beta*J matrix.
Teuchos::Array< mp_vector_t > p_mp
Parameter vectors.
Teuchos::RCP< const Teuchos::Array< std::string > > get_p_names(int l) const
Return array of parameter names.
SGQuadMPModelEvaluator(const Teuchos::RCP< EpetraExt::ModelEvaluator > &me, const Teuchos::RCP< const EpetraExt::MultiComm > &mp_comm, const Teuchos::RCP< const Epetra_Map > &mp_block_map)
OutArgs createOutArgs() const
Create OutArgs.
Teuchos::Array< int > mp_p_index_map
Index map between block-p and p_mp maps.
Teuchos::RCP< const EpetraExt::MultiComm > mp_comm
Parallel MP communicator.
Teuchos::RCP< const Epetra_Vector > get_p_init(int l) const
Return initial parameters.
Teuchos::RCP< const Epetra_Vector > get_x_init() const
Return initial solution.
Teuchos::Array< MPDerivative > dgdx_dot_mp
Response derivative.
Teuchos::RCP< const Epetra_Map > get_f_map() const
Return residual vector map.
Teuchos::RCP< const Epetra_Map > get_x_map() const
Return solution vector map.
int num_g_mp
Number of multipoint response vectors.
Teuchos::Array< MPDerivative > dfdp_mp
Residual derivatives.
Teuchos::RCP< const Epetra_Map > mp_block_map
Map for layout of parallel MP blocks.
ModelEvaluator adaptor that implements the stochastic Galerkin residual and Jacobian computations usi...
Teuchos::Array< int > mp_g_index_map
Index map between block-g and g_mp maps.
Teuchos::RCP< const Epetra_Map > get_g_map(int l) const
Return observation vector map.
Teuchos::RCP< const Epetra_Map > get_p_map(int l) const
Return parameter vector map.
Teuchos::RCP< EpetraExt::ModelEvaluator > me
Underlying model evaluator.
int num_p_mp
Number of multipoint parameter vectors.
Teuchos::Array< mp_vector_t > g_mp
Response vectors.
Teuchos::Array< MPDerivative > dgdx_mp
Response derivative.
void evalModel(const InArgs &inArgs, const OutArgs &outArgs) const
Evaluate model on InArgs.
int num_p
Number of parameter vectors.
Teuchos::Array< Teuchos::Array< MPDerivative > > dgdp_mp
Response sensitivities.