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 "Closures1PhaseNone.h" 11 : #include "FlowChannel1Phase.h" 12 : #include "HeatTransfer1PhaseBase.h" 13 : 14 : registerMooseObject("ThermalHydraulicsApp", Closures1PhaseNone); 15 : 16 : InputParameters 17 36 : Closures1PhaseNone::validParams() 18 : { 19 36 : InputParameters params = Closures1PhaseBase::validParams(); 20 72 : params.addParam<bool>("add_wall_temperature_property", 21 72 : true, 22 : "If true, create a material property for the wall temperature (average if " 23 : "multiple heat transfers)"); 24 36 : params.addClassDescription("No 1-phase closures. Useful for testing with one-time correlations."); 25 36 : return params; 26 0 : } 27 : 28 18 : Closures1PhaseNone::Closures1PhaseNone(const InputParameters & params) : Closures1PhaseBase(params) 29 : { 30 36 : if (getParam<bool>("add_wall_temperature_property")) 31 18 : mooseDeprecated("'Closures1PhaseNone' is deprecated. Since 'add_wall_temperature_property' was " 32 : "set to 'true', change the type of the 'Closures1PhaseNone' object to " 33 : "'WallTemperature1PhaseClosures'."); 34 : else 35 0 : mooseDeprecated( 36 : "'Closures1PhaseNone' is deprecated. The 'closures' parameter now takes an arbitrary-sized " 37 : "list of closures objects, defaulting to an empty list, so to transition, delete the " 38 : "'Closures1PhaseNone' block and the 'closures' parameter from your input file."); 39 18 : } 40 : 41 : void 42 18 : Closures1PhaseNone::checkFlowChannel(const FlowChannelBase & /*flow_channel*/) const 43 : { 44 18 : } 45 : 46 : void 47 18 : Closures1PhaseNone::checkHeatTransfer(const HeatTransferBase & /*heat_transfer*/, 48 : const FlowChannelBase & /*flow_channel*/) const 49 : { 50 18 : } 51 : 52 : void 53 18 : Closures1PhaseNone::addMooseObjectsFlowChannel(const FlowChannelBase & flow_channel) 54 : { 55 36 : if (getParam<bool>("add_wall_temperature_property")) 56 : { 57 : const FlowChannel1Phase & flow_channel_1phase = 58 18 : dynamic_cast<const FlowChannel1Phase &>(flow_channel); 59 : 60 : const unsigned int n_ht_connections = flow_channel_1phase.getNumberOfHeatTransferConnections(); 61 18 : if ((n_ht_connections > 0) && (flow_channel.getTemperatureMode())) 62 : { 63 18 : if (flow_channel.getNumberOfHeatTransferConnections() > 1) 64 0 : addAverageWallTemperatureMaterial(flow_channel_1phase); 65 : else 66 18 : addWallTemperatureFromAuxMaterial(flow_channel_1phase); 67 : } 68 : } 69 18 : } 70 : 71 : void 72 18 : Closures1PhaseNone::addMooseObjectsHeatTransfer(const HeatTransferBase & /*heat_transfer*/, 73 : const FlowChannelBase & /*flow_channel*/) 74 : { 75 18 : }