Line data Source code
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 "DimensionlessFlowNumbers.h"
11 : #include "MooseError.h"
12 :
13 : namespace fp
14 : {
15 :
16 : void
17 12 : deprecatedMessage()
18 : {
19 12 : mooseDoOnce(mooseDeprecated("This function has been moved a different file and namespace. "
20 : "Please replace inclusion of DimensionlessFlowNumbers.h "
21 : "with inclusion of HeatTransferUtils.h and then replace 'fp::' with "
22 : "'HeatTransferUtils::'."));
23 12 : }
24 :
25 : Real
26 2 : reynolds(Real rho, Real vel, Real L, Real mu)
27 : {
28 2 : deprecatedMessage();
29 2 : return rho * std::fabs(vel) * L / mu;
30 : }
31 :
32 : ADReal
33 0 : reynolds(const ADReal & rho, const ADReal & vel, const ADReal & L, const ADReal & mu)
34 : {
35 0 : deprecatedMessage();
36 0 : return rho * std::fabs(vel) * L / mu;
37 : }
38 :
39 : Real
40 2 : prandtl(Real cp, Real mu, Real k)
41 : {
42 2 : deprecatedMessage();
43 2 : return cp * mu / k;
44 : }
45 :
46 : ADReal
47 0 : prandtl(const ADReal & cp, const ADReal & mu, const ADReal & k)
48 : {
49 0 : deprecatedMessage();
50 0 : return cp * mu / k;
51 : }
52 :
53 : Real
54 2 : grashof(Real beta, Real T_s, Real T_bulk, Real L, Real rho, Real mu, Real gravity_magnitude)
55 : {
56 2 : deprecatedMessage();
57 2 : return gravity_magnitude * beta * std::abs(T_s - T_bulk) * std::pow(L, 3) * (rho * rho) /
58 2 : (mu * mu);
59 : }
60 :
61 : ADReal
62 0 : grashof(const ADReal & beta,
63 : const ADReal & T_s,
64 : const ADReal & T_bulk,
65 : const ADReal & L,
66 : const ADReal & rho,
67 : const ADReal & mu,
68 : const ADReal & gravity_magnitude)
69 : {
70 0 : deprecatedMessage();
71 0 : return gravity_magnitude * beta * std::abs(T_s - T_bulk) * std::pow(L, 3) * (rho * rho) /
72 0 : (mu * mu);
73 : }
74 :
75 : Real
76 2 : laplace(Real sigma, Real rho, Real L, Real mu)
77 : {
78 2 : deprecatedMessage();
79 2 : return sigma * rho * L / (mu * mu);
80 : }
81 :
82 : ADReal
83 0 : laplace(const ADReal & sigma, const ADReal & rho, const ADReal & L, const ADReal & mu)
84 : {
85 0 : deprecatedMessage();
86 0 : return sigma * rho * L / (mu * mu);
87 : }
88 :
89 : Real
90 2 : thermalDiffusivity(Real k, Real rho, Real cp)
91 : {
92 2 : deprecatedMessage();
93 2 : return k / (rho * cp);
94 : }
95 :
96 : ADReal
97 0 : thermalDiffusivity(const ADReal & k, const ADReal & rho, const ADReal & cp)
98 : {
99 0 : deprecatedMessage();
100 0 : return k / (rho * cp);
101 : }
102 :
103 : Real
104 2 : peclet(Real vel, Real L, Real diffusivity)
105 : {
106 2 : deprecatedMessage();
107 2 : return std::fabs(vel) * L / diffusivity;
108 : }
109 :
110 : ADReal
111 0 : peclet(const ADReal & vel, const ADReal & L, const ADReal & diffusivity)
112 : {
113 0 : deprecatedMessage();
114 0 : return std::fabs(vel) * L / diffusivity;
115 : }
116 :
117 : } // namespace fp
|