Debian Codegraph @

packages/seacas/applications/nem_spread/rf_io_const.h

raw
1 /*
2 * Copyright(C) 1999-2020, 2022 National Technology & Engineering Solutions
3 * of Sandia, LLC (NTESS). Under the terms of Contract DE-NA0003525 with
4 * NTESS, the U.S. Government retains certain rights in this software.
5 *
6 * See packages/seacas/LICENSE for details
7 */
8 #pragma once
9
10 #include <string>
11 #include <vector>
12
13 /*********** rf_io_const.h -- constants for external IO purposes**************/
14
15 /* Restart structure */
16 template <typename T> struct Restart_Description
17 {
18 Restart_Description() = default;
19
20 int Flag{-1}; /* Indicates whether restart info is to be processed */
21
22 int Num_Times{-1}; /* The number of time indices to spread */
23 std::vector<int> Time_Idx{}; /* Time indices to read, need to keep track of all */
24 T Time{}; /* time value */
25
26 int NVar_Glob{-1}; /* Number of global variables read */
27 int NVar_Elem{-1}; /* Number of elemental variables read */
28 int NVar_Node{-1}; /* Number of nodal variables read */
29 int NVar_Nset{-1}; /* Number of nodeset variables read */
30 int NVar_Sset{-1}; /* Number of sideset variables read */
31
32 std::vector<int> GElem_TT{}; /* Global Elemental variable truth table */
33 std::vector<int> GNset_TT{}; /* Global Elemental variable truth table */
34 std::vector<int> GSset_TT{}; /* Global Elemental variable truth table */
35
36 /*
37 * To be able to support single or double precision exodus files,
38 * need to have both float and double pointers here.
39 */
40 std::vector<T> Glob_Vals{}; /* Global variable values, only one per variable *
41 * and processor */
42 std::vector<std::vector<T>> Elem_Vals; /* Element variable values for each processor */
43 std::vector<std::vector<T>> Node_Vals; /* Nodal variable values for each processor */
44 std::vector<std::vector<T>> Nset_Vals; /* Nodeset variable values for each processor */
45 std::vector<std::vector<T>> Sset_Vals; /* Sideset variable values for each processor */
46
47 char **NV_Name{nullptr}; /* Names of the nodal variables */
48 char **EV_Name{nullptr}; /* Names of the elemental variables */
49 char **GV_Name{nullptr}; /* Names of the global variables */
50 char **NSV_Name{nullptr}; /* Names of the nodeset variables */
51 char **SSV_Name{nullptr}; /* Names of the sideset variables */
52 };
53
54 /*****************************************************************************/
55 /* EXTERN STATEMENTS for GLOBALS USED IN I/O ROUTINES */
56 /*****************************************************************************/
57
58 /**Extern statements for parameters in rf_io.h */
59
60 extern std::string ExoFile; /* Exodus II File containing problem definition. */
61 /* This name is the root name. */
62 extern std::string Output_File_Base_Name; /* Base name of output file. If it has a suffix, it will
63 be stripped */
64
65 extern std::string Exo_LB_File;
66 /* Exodus II file containing the mesh load-balance */
67 /* information */
68 extern std::string Exo_Res_File;
69 /* Exodus II file containing the mesh result */
70 /* information */
71 extern int Debug_Flag; /* Flag to specify debug info is to be printed out.
72 The value of this flag determines the level of
73 diagnostic info which is printed to stdout
74 Debug_Flag == 0 No output
75 .
76 .
77 9 maximum output */
78 extern int Gen_Flag; /* Flag used by nem_join to determine if the user
79 wants to use an existing genesis file rather
80 than generating one from the parallel files */
81
82 extern int Num_Nod_Var; /* The number of nodal variables to reserve */
83 /* space in the output file for. */
84 extern int Num_Elem_Var; /* The number of elemental variables to */
85 /* reserve space in the output file for. */
86
87 extern int Num_Glob_Var; /* The number of global variables to reserve */
88 /* space in the output file for. */
89 extern int Num_Nset_Var; /* The number of nodeset variables to reserve */
90 /* space in the output file for. */
91
92 extern int Num_Sset_Var; /* The number of sideset variables to reserve */
93 /* space in the output file for. */