Nalu
Nalu: a generalized unstructured massively parallel low Mach flow code designed to support a variety of energy applications of interest (most notably Wind ECP) built on the Sierra Toolkit and Trilinos solver Tpetra/Epetra stack. The open source BSD, clause 3 license model has been chosen for the code base. See LICENSE for more information. http://NaluCFD.org
SolutionNormPostProcessing.h
Go to the documentation of this file.
1 /*------------------------------------------------------------------------*/
2 /* Copyright 2014 Sandia Corporation. */
3 /* This software is released under the license detailed */
4 /* in the file, LICENSE, which is located in the top-level Nalu */
5 /* directory structure */
6 /*------------------------------------------------------------------------*/
7 
8 
9 #ifndef SolutionNormPostProcessing_h
10 #define SolutionNormPostProcessing_h
11 
12 #include <NaluParsing.h>
13 
14 #include <string>
15 #include <vector>
16 #include <utility>
17 
18 // stk forwards
19 namespace stk {
20  namespace mesh {
21  class BulkData;
22  class FieldBase;
23  class MetaData;
24  class Part;
25  typedef std::vector<Part*> PartVector;
26  }
27 }
28 
29 namespace sierra{
30 namespace nalu{
31 
32 class AuxFunctionAlgorithm;
33 class Realm;
34 
36 {
37 public:
38 
40  Realm &realm,
41  const YAML::Node &node);
43 
44  // load all of the options
45  void load(
46  const YAML::Node & node);
47 
48  // setup nodal field registration; algorithms
49  void setup();
50 
51  // create the algorithm to populate the exact field
52  void analytical_function_factory(
53  const std::string functionName,
54  stk::mesh::FieldBase *exactDofField,
55  stk::mesh::Part *part);
56 
57  // populate nodal field and output norms (if appropriate)
58  void execute();
59 
60  // hold the realm
62 
63  // how often to output norms
65 
66  // keep track of total dof component size
68 
69  // for each dof, save off field size
70  std::vector<int> sizeOfEachField_;
71 
72  // file name
73  std::string outputFileName_;
74 
75  // spacing
76  int w_;
77 
78  // percision
80 
81  // hold the dofName, functionName in a vector
82  std::vector<std::pair<std::string, std::string> > dofFunctionVec_;
83 
84  // hold the dofField and exactDofField
85  std::vector<std::pair<const stk::mesh::FieldBase*, stk::mesh::FieldBase*> > fieldPairVec_;
86 
87  // vector of parts for post processing
89 
90  // vector of algorithms that process the analytical field
91  std::vector<AuxFunctionAlgorithm *> populateExactNodalFieldAlg_;
92 };
93 
94 } // namespace nalu
95 } // namespace Sierra
96 
97 #endif
stk::mesh::PartVector partVec_
Definition: SolutionNormPostProcessing.h:88
std::vector< Part * > PartVector
Definition: Algorithm.h:16
std::vector< std::pair< const stk::mesh::FieldBase *, stk::mesh::FieldBase * > > fieldPairVec_
Definition: SolutionNormPostProcessing.h:85
Definition: ABLForcingAlgorithm.C:26
Definition: SolutionNormPostProcessing.h:35
int outputFrequency_
Definition: SolutionNormPostProcessing.h:64
Definition: Algorithm.h:14
std::string outputFileName_
Definition: SolutionNormPostProcessing.h:73
std::vector< AuxFunctionAlgorithm * > populateExactNodalFieldAlg_
Definition: SolutionNormPostProcessing.h:91
int totalDofCompSize_
Definition: SolutionNormPostProcessing.h:67
int percision_
Definition: SolutionNormPostProcessing.h:79
Tpetra::Map< LocalOrdinal, GlobalOrdinal >::node_type Node
Definition: LinearSolver.h:32
Realm & realm_
Definition: SolutionNormPostProcessing.h:61
Definition: Realm.h:82
std::vector< int > sizeOfEachField_
Definition: SolutionNormPostProcessing.h:70
std::vector< std::pair< std::string, std::string > > dofFunctionVec_
Definition: SolutionNormPostProcessing.h:82
int w_
Definition: SolutionNormPostProcessing.h:76