|
Stokhos Package Browser (Single Doxygen Collection)
Version of the Day
|
Nonlinear, stochastic Galerkin ModelEvaluator that constructs an adapted Jacobian. More...
#include <Stokhos_SGModelEvaluator_Adaptive.hpp>
Inherits ModelEvaluator.
Overridden from EpetraExt::ModelEvaluator . | |
| Teuchos::RCP< const Epetra_Map > | get_x_map () const |
| Return solution vector map. More... | |
| Teuchos::RCP< const Epetra_Map > | get_p_map (int l) const |
| Return parameter vector map. More... | |
| Teuchos::RCP< const Teuchos::Array< std::string > > | get_p_names (int l) const |
| Return array of parameter names. More... | |
| Teuchos::RCP< const Epetra_Vector > | get_x_init () const |
| Return initial solution. More... | |
| Teuchos::RCP< const Epetra_Vector > | get_p_init (int l) const |
| Return initial parameters. More... | |
| Teuchos::RCP< const Epetra_Map > | get_f_map () const |
| Return residual vector map. More... | |
| Teuchos::RCP< const Epetra_Map > | get_g_map (int l) const |
| Return response map. More... | |
| Teuchos::RCP< Epetra_Operator > | create_W () const |
| Create W = alpha*M + beta*J matrix. More... | |
| InArgs | createInArgs () const |
| Create InArgs. More... | |
| OutArgs | createOutArgs () const |
| Create OutArgs. More... | |
| void | evalModel (const InArgs &inArgs, const OutArgs &outArgs) const |
| Evaluate model on InArgs. More... | |
Nonlinear, stochastic Galerkin ModelEvaluator that constructs an adapted Jacobian.
SGModelEvaluator_Adaptive is an implementation of EpetraExt::ModelEvaluator that generates a nonlinear problem from a stochastic Galerkin expansion, the Jacobian and solution vectors are interlaced. It wraps a supplied ModelEvaluator that supports the SG versions of p, x, and possibly x_dot InArgs, and f and W OutArgs, and translates those into a new nonlinear problem. It does so by concatenating all of the SG components of p, x, x_dot, and f into extended block vectors that form the parameters, solution vector, time derivative vector and residual for the new nonlinear problem. Only forming a fully-assembled SG matrix is possible. The W operator of the underlying model evaluator must be an Epetra_CrsMatrix.
Definition at line 81 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
| Stokhos::SGModelEvaluator_Adaptive::SGModelEvaluator_Adaptive | ( | const Teuchos::RCP< EpetraExt::ModelEvaluator > & | me_, |
| const Teuchos::RCP< Stokhos::AdaptivityManager > & | am, | ||
| const Teuchos::RCP< const Stokhos::Quadrature< int, double > > & | sg_quad_, | ||
| const Teuchos::RCP< Stokhos::OrthogPolyExpansion< int, double > > & | sg_exp_, | ||
| const Teuchos::RCP< const Stokhos::ParallelData > & | sg_parallel_data_, | ||
| bool | onlyUseLinear_, | ||
| int | kExpOrder_, | ||
| const Teuchos::RCP< Teuchos::ParameterList > & | params_ | ||
| ) |
Definition at line 56 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Stokhos::SGModelEvaluator_Adaptive::SGModelEvaluator_Adaptive | ( | const Teuchos::RCP< EpetraExt::ModelEvaluator > & | me, |
| const Teuchos::RCP< const Stokhos::OrthogPolyBasis< int, double > > & | sg_master_basis, | ||
| const std::vector< Teuchos::RCP< const Stokhos::ProductBasis< int, double > > > & | sg_row_dof_basis, | ||
| const Teuchos::RCP< const Stokhos::Quadrature< int, double > > & | sg_quad, | ||
| const Teuchos::RCP< Stokhos::OrthogPolyExpansion< int, double > > & | sg_exp, | ||
| const Teuchos::RCP< const Stokhos::ParallelData > & | sg_parallel_data, | ||
| bool | onlyUseLinear, | ||
| int | kExpOrder, | ||
| const Teuchos::RCP< Teuchos::ParameterList > & | params, | ||
| bool | scaleOP = true |
||
| ) |
Definition at line 271 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< const Epetra_Map > Stokhos::SGModelEvaluator_Adaptive::get_x_map | ( | ) | const |
Return solution vector map.
Definition at line 493 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< const Epetra_Map > Stokhos::SGModelEvaluator_Adaptive::get_p_map | ( | int | l | ) | const |
Return parameter vector map.
Definition at line 505 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< const Teuchos::Array< std::string > > Stokhos::SGModelEvaluator_Adaptive::get_p_names | ( | int | l | ) | const |
Return array of parameter names.
Definition at line 526 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< const Epetra_Vector > Stokhos::SGModelEvaluator_Adaptive::get_x_init | ( | ) | const |
Return initial solution.
Definition at line 539 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< const Epetra_Vector > Stokhos::SGModelEvaluator_Adaptive::get_p_init | ( | int | l | ) | const |
Return initial parameters.
Definition at line 549 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< const Epetra_Map > Stokhos::SGModelEvaluator_Adaptive::get_f_map | ( | ) | const |
Return residual vector map.
Definition at line 499 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< const Epetra_Map > Stokhos::SGModelEvaluator_Adaptive::get_g_map | ( | int | l | ) | const |
Return response map.
Definition at line 518 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< Epetra_Operator > Stokhos::SGModelEvaluator_Adaptive::create_W | ( | ) | const |
Create W = alpha*M + beta*J matrix.
Definition at line 562 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| EpetraExt::ModelEvaluator::InArgs Stokhos::SGModelEvaluator_Adaptive::createInArgs | ( | ) | const |
Create InArgs.
Definition at line 583 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| EpetraExt::ModelEvaluator::OutArgs Stokhos::SGModelEvaluator_Adaptive::createOutArgs | ( | ) | const |
Create OutArgs.
Definition at line 605 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| void Stokhos::SGModelEvaluator_Adaptive::evalModel | ( | const InArgs & | inArgs, |
| const OutArgs & | outArgs | ||
| ) | const |
Evaluate model on InArgs.
Definition at line 636 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| void Stokhos::SGModelEvaluator_Adaptive::set_x_sg_init | ( | const Stokhos::EpetraVectorOrthogPoly & | x_sg_in | ) |
Set initial solution polynomial.
Definition at line 908 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< const Stokhos::EpetraVectorOrthogPoly > Stokhos::SGModelEvaluator_Adaptive::get_x_sg_init | ( | ) | const |
Return initial SG x.
Definition at line 915 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| void Stokhos::SGModelEvaluator_Adaptive::set_p_sg_init | ( | int | i, |
| const Stokhos::EpetraVectorOrthogPoly & | p_sg_in | ||
| ) |
Set initial parameter polynomial.
Definition at line 921 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< const Stokhos::EpetraVectorOrthogPoly > Stokhos::SGModelEvaluator_Adaptive::get_p_sg_init | ( | int | l | ) | const |
Return initial SG parameters.
Definition at line 928 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::Array< int > Stokhos::SGModelEvaluator_Adaptive::get_p_sg_map_indices | ( | ) | const |
Get indices of SG parameters.
These indices determine which parameter vectors support SG
Definition at line 934 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::Array< int > Stokhos::SGModelEvaluator_Adaptive::get_g_sg_map_indices | ( | ) | const |
Get indices of SG responses.
These indices determine which response vectors support SG
Definition at line 940 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::Array< Teuchos::RCP< const Epetra_Map > > Stokhos::SGModelEvaluator_Adaptive::get_g_sg_base_maps | ( | ) | const |
Get base maps of SG responses.
Definition at line 946 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< const Epetra_BlockMap > Stokhos::SGModelEvaluator_Adaptive::get_overlap_stochastic_map | ( | ) | const |
Return overlap stochastic map.
Definition at line 955 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< const Epetra_BlockMap > Stokhos::SGModelEvaluator_Adaptive::get_x_sg_overlap_map | ( | ) | const |
Return x sg overlap map.
Definition at line 961 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< const Epetra_Import > Stokhos::SGModelEvaluator_Adaptive::get_x_sg_importer | ( | ) | const |
Return x sg importer.
Definition at line 967 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< Stokhos::EpetraVectorOrthogPoly > Stokhos::SGModelEvaluator_Adaptive::create_x_sg | ( | ) | const |
Create vector orthog poly using x map and owned sg map.
Definition at line 973 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< Stokhos::EpetraVectorOrthogPoly > Stokhos::SGModelEvaluator_Adaptive::create_x_sg_overlap | ( | ) | const |
Create vector orthog poly using x map and overlap sg map.
Definition at line 982 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< Stokhos::EpetraMultiVectorOrthogPoly > Stokhos::SGModelEvaluator_Adaptive::create_x_mv_sg | ( | int | num_vecs | ) | const |
Create vector orthog poly using x map and owned sg map.
Definition at line 988 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< Stokhos::EpetraMultiVectorOrthogPoly > Stokhos::SGModelEvaluator_Adaptive::create_x_mv_sg_overlap | ( | int | num_vecs | ) | const |
Create vector orthog poly using x map and overlap sg map.
Definition at line 997 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< Stokhos::EpetraVectorOrthogPoly > Stokhos::SGModelEvaluator_Adaptive::create_p_sg | ( | int | l, |
| Epetra_DataAccess | CV = Copy, |
||
| const Epetra_Vector * | v = 0 |
||
| ) | const |
Create vector orthog poly using p map.
Definition at line 1004 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< Stokhos::EpetraVectorOrthogPoly > Stokhos::SGModelEvaluator_Adaptive::create_f_sg | ( | ) | const |
Create vector orthog poly using f map and owned sg map.
Definition at line 1026 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< Stokhos::EpetraVectorOrthogPoly > Stokhos::SGModelEvaluator_Adaptive::create_f_sg_overlap | ( | ) | const |
Create vector orthog poly using f map and overlap sg map.
Definition at line 1035 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< Stokhos::EpetraMultiVectorOrthogPoly > Stokhos::SGModelEvaluator_Adaptive::create_f_mv_sg | ( | int | num_vecs | ) | const |
Create multi-vector orthog poly using f map and owned sg map.
Definition at line 1041 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< Stokhos::EpetraMultiVectorOrthogPoly > Stokhos::SGModelEvaluator_Adaptive::create_f_mv_sg_overlap | ( | int | num_vecs | ) | const |
Create multi-vector orthog poly using f map and overlap sg map.
Definition at line 1051 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< Stokhos::EpetraVectorOrthogPoly > Stokhos::SGModelEvaluator_Adaptive::create_g_sg | ( | int | l, |
| Epetra_DataAccess | CV = Copy, |
||
| const Epetra_Vector * | v = NULL |
||
| ) | const |
Create vector orthog poly using g map.
Definition at line 1058 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
| Teuchos::RCP< Stokhos::EpetraMultiVectorOrthogPoly > Stokhos::SGModelEvaluator_Adaptive::create_g_mv_sg | ( | int | l, |
| int | num_vecs, | ||
| Epetra_DataAccess | CV = Copy, |
||
| const Epetra_MultiVector * | v = NULL |
||
| ) | const |
Create multi-vector orthog poly using g map.
Definition at line 1082 of file Stokhos_SGModelEvaluator_Adaptive.cpp.
|
inline |
Definition at line 236 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Underlying model evaluator.
Definition at line 242 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Stochastic Galerkin basis.
Definition at line 245 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Definition at line 247 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Stochastic Galerkin quadrature.
Definition at line 250 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Stochastic Galerkin expansion.
Definition at line 253 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Algorithmic parameters.
Definition at line 256 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Number of stochastic blocks.
Definition at line 259 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Number of W stochastic blocks (may be smaller than num_sg_blocks)
Definition at line 262 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Number of p stochastic blocks (may be smaller than num_sg_blocks)
Definition at line 265 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Whether we support x (and thus f and W)
Definition at line 268 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Underlying unknown map.
Definition at line 271 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Underlying residual map.
Definition at line 274 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Parallel SG data.
Definition at line 277 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Parallel SG communicator.
Definition at line 280 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Epetra Cijk.
Definition at line 283 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Serial Epetra Cijk for dgdx*.
Definition at line 286 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Definition at line 288 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Map for stochastic blocks.
Definition at line 291 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Overlapped map for stochastic blocks (local map)
Definition at line 294 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Overlapped map for p stochastic blocks (local map)
Definition at line 297 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Block SG unknown map.
Definition at line 300 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Block SG overlapped unknown map.
Definition at line 303 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Block SG residual map.
Definition at line 306 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Block SG overlapped residual map.
Definition at line 309 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Importer from SG to SG-overlapped maps.
Definition at line 312 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Exporter from SG-overlapped to SG maps.
Definition at line 315 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Number of parameter vectors of underlying model evaluator.
Definition at line 318 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Number of stochastic parameter vectors.
Definition at line 321 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Index map between block-p and p_sg maps.
Definition at line 324 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Block SG parameter map.
Definition at line 327 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
SG coefficient parameter names.
Definition at line 330 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Number of response vectors of underlying model evaluator.
Definition at line 333 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Number of stochastic response vectors.
Definition at line 336 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Index map between block-g and g_sg maps.
Definition at line 339 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Block SG response map.
Definition at line 342 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
x_dot stochastic Galerkin components
Definition at line 345 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
x stochastic Galerkin components
Definition at line 348 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
mutableprotected |
f stochastic Galerkin components
Definition at line 351 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
mutableprotected |
W stochastic Galerkin components.
Definition at line 354 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
mutableprotected |
Definition at line 356 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
mutableprotected |
dg/dxdot stochastic Galerkin components
Definition at line 359 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
mutableprotected |
dg/dx stochastic Galerkin components
Definition at line 362 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
SG initial x.
Definition at line 365 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
SG initial p.
Definition at line 368 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Whether to always evaluate W with f.
Definition at line 371 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Definition at line 373 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Definition at line 374 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
mutableprotected |
W pointer for evaluating W with f.
Definition at line 377 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
mutableprotected |
x pointer for evaluating preconditioner
Definition at line 380 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
protected |
Definition at line 382 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
|
mutableprotected |
Definition at line 384 of file Stokhos_SGModelEvaluator_Adaptive.hpp.
1.8.14