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 496 : SCMHTCDittusBoelter::validParams() 16 : { 17 : // Enumerations 18 992 : MooseEnum factors("Presser Weisman none", "Presser"); 19 496 : InputParameters params = SCMHTCClosureBase::validParams(); 20 496 : params.addClassDescription( 21 : "Class that computes the convective heat transfer coefficient using the " 22 : "Dittus Boelter correlation."); 23 992 : params.addParam<MooseEnum>( 24 : "correction_factor", 25 : factors, 26 : "Correction factor modeling the effect of the fuel-pin bundle. Default is Presser"); 27 496 : return params; 28 496 : } 29 : 30 261 : SCMHTCDittusBoelter::SCMHTCDittusBoelter(const InputParameters & parameters) 31 : : SCMHTCClosureBase(parameters), 32 261 : _is_tri_lattice(dynamic_cast<const TriSubChannelMesh *>(&_subchannel_mesh) != nullptr), 33 783 : _correction_factor(getParam<MooseEnum>("correction_factor")) 34 : { 35 261 : } 36 : 37 : Real 38 848916 : SCMHTCDittusBoelter::computeNusseltNumber(const FrictionStruct & /*friction_args*/, 39 : const NusseltStruct & nusselt_args) const 40 : { 41 848916 : const auto pre = computeNusseltNumberPreInfo(nusselt_args); 42 : 43 848916 : if (pre.Pr < 0.7 || pre.Pr > 1.6e2) 44 331956 : flagSolutionWarning("Prandtl number (Pr) out of range for the Dittus-Boelter correlation."); 45 : 46 848916 : const auto corr = computeCorrectionFactor(pre.poD); 47 848916 : const Real psi = corr.psi; 48 848916 : const Real b = corr.b; 49 848916 : auto NuT = 0.023 * std::pow(pre.Re, 0.8) * std::pow(pre.Pr, b); 50 848916 : NuT *= psi; 51 : 52 848916 : return blendTurbulentNusseltNumber(pre, NuT); 53 : } 54 : 55 : SCMHTCDittusBoelter::CorrectionResult 56 848916 : SCMHTCDittusBoelter::computeCorrectionFactor(const Real poD) const 57 : { 58 : CorrectionResult result; 59 : 60 848916 : switch (_correction_factor) 61 : { 62 711460 : case 0: // Presser 63 : { 64 : result.b = 0.4; 65 : 66 711460 : if (_is_tri_lattice) 67 : { 68 391884 : if (poD < 1.05 || poD > 2.2) 69 0 : flagSolutionWarning("P/D out of range for Presser correction factor (triangular)."); 70 : 71 391884 : result.psi = 0.9090 + 0.0783 * poD - 0.1283 * std::exp(-2.4 * (poD - 1.0)); 72 : } 73 : else 74 : { 75 319576 : if (poD < 1.05 || poD > 1.9) 76 4490 : flagSolutionWarning("P/D out of range for Presser correction factor (square)."); 77 : 78 319576 : result.psi = 0.9217 + 0.1478 * poD - 0.1130 * std::exp(-7.0 * (poD - 1.0)); 79 : } 80 711460 : 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 : }