https://mooseframework.inl.gov
FluidPropertiesApp.C
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://mooseframework.inl.gov
3 //*
4 //* All rights reserved, see COPYRIGHT for full restrictions
5 //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6 //*
7 //* Licensed under LGPL 2.1, please see LICENSE for details
8 //* https://www.gnu.org/licenses/lgpl-2.1.html
9 
10 #include "FluidPropertiesApp.h"
11 #include "Moose.h"
12 #include "AppFactory.h"
13 #include "MooseSyntax.h"
14 
15 #ifdef AIR_FP_ENABLED
16 #include "AirApp.h"
17 #endif
18 #ifdef CARBON_DIOXIDE_FP_ENABLED
19 #include "CarbonDioxideApp.h"
20 #endif
21 #ifdef HELIUM_FP_ENABLED
22 #include "HeliumApp.h"
23 #endif
24 #ifdef NITROGEN_FP_ENABLED
25 #include "NitrogenApp.h"
26 #endif
27 #ifdef POTASSIUM_FP_ENABLED
28 #include "PotassiumApp.h"
29 #endif
30 #ifdef SODIUM_FP_ENABLED
31 #include "SodiumApp.h"
32 #endif
33 
36 {
38  params.set<bool>("use_legacy_material_output") = false;
39  params.set<bool>("use_legacy_initial_residual_evaluation_behavior") = false;
40  return params;
41 }
42 
43 registerKnownLabel("FluidPropertiesApp");
44 
46 {
48 }
49 
51 
52 void
54 {
55  const std::string doc = "Saline thermophysical fluid properties ";
56 #ifdef SALINE_ENABLED
57  addCapability("saline", true, doc + "are available.");
58 #else
59  addCapability("saline", false, doc + "are not available.");
60 #endif
61 
62  registerApp(FluidPropertiesApp);
63 #ifdef AIR_FP_ENABLED
64  registerApp(AirApp);
65 #endif
66 #ifdef CARBON_DIOXIDE_FP_ENABLED
67  registerApp(CarbonDioxideApp);
68 #endif
69 #ifdef HELIUM_FP_ENABLED
70  registerApp(HeliumApp);
71 #endif
72 #ifdef NITROGEN_FP_ENABLED
73  registerApp(NitrogenApp);
74 #endif
75 #ifdef POTASSIUM_FP_ENABLED
76  registerApp(PotassiumApp);
77 #endif
78 #ifdef SODIUM_FP_ENABLED
79  registerApp(SodiumApp);
80 #endif
81 }
82 
83 void
85 {
86 #ifdef AIR_FP_ENABLED
87  AirApp::registerAll(f, af, syntax);
88 #endif
89 #ifdef CARBON_DIOXIDE_FP_ENABLED
90  CarbonDioxideApp::registerAll(f, af, syntax);
91 #endif
92 #ifdef HELIUM_FP_ENABLED
93  HeliumApp::registerAll(f, af, syntax);
94 #endif
95 #ifdef NITROGEN_FP_ENABLED
96  NitrogenApp::registerAll(f, af, syntax);
97 #endif
98 #ifdef POTASSIUM_FP_ENABLED
99  PotassiumApp::registerAll(f, af, syntax);
100 #endif
101 #ifdef SODIUM_FP_ENABLED
102  SodiumApp::registerAll(f, af, syntax);
103 #endif
104 
105  Registry::registerObjectsTo(f, {"FluidPropertiesApp"});
106  Registry::registerActionsTo(af, {"FluidPropertiesApp"});
107 
108  registerSyntaxTask(
109  "AddFluidPropertiesDeprecatedAction", "Modules/FluidProperties/*", "add_fluid_properties");
110  registerSyntaxTask("AddFluidPropertiesAction", "FluidProperties/*", "add_fluid_properties");
111  registerMooseObjectTask("add_fluid_properties", FluidProperties, false);
112  registerMooseObjectTask("add_fp_output", Output, false);
113 
114  // Fluid properties depend on variables
115  syntax.addDependency("add_aux_variable", "add_fluid_properties");
116  syntax.addDependency("add_variable", "add_fluid_properties");
117  syntax.addDependency("add_elemental_field_variable", "add_fluid_properties");
118  syntax.addDependency("add_external_aux_variables", "add_fluid_properties");
119  syntax.addDependency("add_fp_output", "add_output");
120  syntax.addDependency("add_postprocessor", "add_fp_output");
121 
122  syntax.registerActionSyntax("AddFluidPropertiesInterrogatorAction",
123  "FluidPropertiesInterrogator");
124 }
125 
126 extern "C" void
128 {
130 }
131 extern "C" void
133 {
135 }
static void registerApps()
registerKnownLabel("FluidPropertiesApp")
void addDependency(const std::string &task, const std::string &pre_req)
T & set(const std::string &name, bool quiet_mode=false)
void registerActionSyntax(const std::string &action, const std::string &syntax, const std::string &task="", const std::string &file="", int line=-1)
static void registerObjectsTo(Factory &f, const std::set< std::string > &labels)
Syntax _syntax
Syntax & syntax()
static InputParameters validParams()
static void registerActionsTo(ActionFactory &f, const std::set< std::string > &labels)
void FluidPropertiesApp__registerApps()
Real f(Real x)
Test function for Brents method.
ActionFactory _action_factory
FluidPropertiesApp(const InputParameters &parameters)
Factory _factory
void FluidPropertiesApp__registerAll(Factory &f, ActionFactory &af, Syntax &s)
static void addCapability(const std::string &capability, CapabilityUtils::Type value, const std::string &doc)
static void registerAll(Factory &f, ActionFactory &af, Syntax &s)
static InputParameters validParams()