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 "SCMHTCDittusBoelter.h" 11 : 12 : registerMooseObject("SubChannelApp", SCMHTCDittusBoelter); 13 : 14 : InputParameters 15 313 : SCMHTCDittusBoelter::validParams() 16 : { 17 : // Enumerations 18 626 : MooseEnum factors("Presser Weisman none", "Presser"); 19 313 : InputParameters params = SCMHTCClosureBase::validParams(); 20 313 : params.addClassDescription( 21 : "Class that computes the convective heat transfer coefficient using the " 22 : "Dittus Boelter correlation."); 23 626 : params.addParam<MooseEnum>( 24 : "correction_factor", 25 : factors, 26 : "Correction factor modeling the effect of the fuel-pin bundle. Default is Presser"); 27 313 : return params; 28 313 : } 29 : 30 166 : SCMHTCDittusBoelter::SCMHTCDittusBoelter(const InputParameters & parameters) 31 : : SCMHTCClosureBase(parameters), 32 166 : _is_tri_lattice(dynamic_cast<const TriSubChannelMesh *>(&_subchannel_mesh) != nullptr), 33 498 : _correction_factor(getParam<MooseEnum>("correction_factor")) 34 : { 35 166 : } 36 : 37 : Real 38 268208 : SCMHTCDittusBoelter::computeNusseltNumber(const FrictionStruct & /*friction_args*/, 39 : const NusseltStruct & nusselt_args) const 40 : { 41 268208 : const auto pre = computeNusseltNumberPreInfo(nusselt_args); 42 : 43 268208 : if (pre.Pr < 0.7 || pre.Pr > 1.6e2) 44 0 : flagSolutionWarning("Prandtl number (Pr) out of range for the Dittus-Boelter correlation."); 45 : 46 268208 : const auto corr = computeCorrectionFactor(pre.poD); 47 268208 : const Real psi = corr.psi; 48 268208 : const Real b = corr.b; 49 268208 : auto NuT = 0.023 * std::pow(pre.Re, 0.8) * std::pow(pre.Pr, b); 50 268208 : NuT *= psi; 51 : 52 268208 : return blendTurbulentNusseltNumber(pre, NuT); 53 : } 54 : 55 : SCMHTCDittusBoelter::CorrectionResult 56 268208 : SCMHTCDittusBoelter::computeCorrectionFactor(const Real poD) const 57 : { 58 : CorrectionResult result; 59 : 60 268208 : switch (_correction_factor) 61 : { 62 130752 : case 0: // Presser 63 : { 64 : result.b = 0.4; 65 : 66 130752 : if (_is_tri_lattice) 67 : { 68 59976 : if (poD < 1.05 || poD > 2.2) 69 0 : flagSolutionWarning("P/D out of range for Presser correction factor (triangular)."); 70 : 71 59976 : result.psi = 0.9090 + 0.0783 * poD - 0.1283 * std::exp(-2.4 * (poD - 1.0)); 72 : } 73 : else 74 : { 75 70776 : if (poD < 1.05 || poD > 1.9) 76 4490 : flagSolutionWarning("P/D out of range for Presser correction factor (square)."); 77 : 78 70776 : result.psi = 0.9217 + 0.1478 * poD - 0.1130 * std::exp(-7.0 * (poD - 1.0)); 79 : } 80 130752 : return result; 81 : } 82 : 83 59976 : case 1: // Weisman 84 : { 85 : result.b = 0.333; 86 : 87 59976 : if (_is_tri_lattice) 88 : { 89 59976 : if (poD < 1.1 || poD > 1.5) 90 0 : flagSolutionWarning("P/D out of range for Weisman correction factor (triangular)."); 91 : 92 59976 : result.psi = 1.130 * poD - 0.2609; 93 : } 94 : else 95 : { 96 0 : if (poD < 1.1 || poD > 1.3) 97 0 : flagSolutionWarning("P/D out of range for Weisman correction factor (square)."); 98 : 99 0 : result.psi = 1.826 * poD - 1.0430; 100 : } 101 59976 : return result; 102 : } 103 : 104 77480 : case 2: // "none": no bundle correction, keep classical Dittus-Boelter exponent (b = 0.4) 105 : default: 106 : { 107 : result.psi = 1.0; 108 : result.b = 0.4; 109 77480 : return result; 110 : } 111 : } 112 : }