https://mooseframework.inl.gov
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | Protected Member Functions | Static Protected Member Functions | Protected Attributes | Static Protected Attributes | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
SCMMixingChenTodreas Class Reference

Class that calculates turbulent mixing and sweep-flow coefficients for wire-wrapped triangular lattices. More...

#include <SCMMixingChenTodreas.h>

Inheritance diagram for SCMMixingChenTodreas:
[legend]

Public Types

typedef SubChannel1PhaseProblem::FrictionStruct FrictionStruct
 
typedef DataFileName DataFileParameterType
 

Public Member Functions

 SCMMixingChenTodreas (const InputParameters &parameters)
 
Real computeMixingParameter (const unsigned int i_gap, const unsigned int iz) const override
 Computes the turbulent mixing coefficient for the local conditions around gap(i_gap) and axial level(iz)
 
Real computeSweepFlowMixingParameter (const unsigned int i_gap, const unsigned int iz) const override
 Computes the wire-wrap sweep-flow coefficient for peripheral gaps.
 
void computeBulkMixingParameters () const override
 Precomputes the mixing coefficients that depend only on the bulk flow.
 
void computeBlockMixingParameters (const unsigned int first_node, const unsigned int last_node) const override
 Precomputes the mixing coefficients that depend on the flow solution of the axial levels first_node to last_node.
 
virtual Real getCT () const
 Return the Turbulent modeling parameter.
 
virtual void execute () final
 
virtual void initialize () final
 
virtual void finalize () final
 
virtual void threadJoin (const UserObject &) final
 
virtual void subdomainSetup () final
 
bool needThreadedCopy () const override final
 
virtual Real spatialValue (const Point &) const
 
virtual const std::vector< Point > spatialPoints () const
 
void setPrimaryThreadCopy (UserObject *primary)
 
UserObject * primaryThreadCopy ()
 
SubProblem & getSubProblem () const
 
bool shouldDuplicateInitialExecution () const
 
void gatherSum (T &value)
 
void gatherMax (T &value)
 
void gatherMin (T &value)
 
void gatherProxyValueMax (T1 &proxy, T2 &value)
 
void gatherProxyValueMin (T1 &proxy, T2 &value)
 
std::set< UserObjectName > getDependObjects () const
 
const std::set< std::string > & getRequestedItems () override
 
const std::set< std::string > & getSuppliedItems () override
 
unsigned int systemNumber () const
 
virtual bool enabled () const
 
std::shared_ptr< MooseObject > getSharedPtr ()
 
std::shared_ptr< const MooseObject > getSharedPtr () const
 
bool isKokkosObject () const
 
MooseApp & getMooseApp () const
 
const std::string & type () const
 
const std::string & name () const
 
std::string typeAndName () const
 
MooseObjectParameterName uniqueParameterName (const std::string &parameter_name) const
 
MooseObjectName uniqueName () const
 
const InputParameters & parameters () const
 
const hit::Node * getHitNode () const
 
bool hasBase () const
 
const std::string & getBase () const
 
const T & getParam (const std::string &name) const
 
std::vector< std::pair< T1, T2 > > getParam (const std::string &param1, const std::string &param2) const
 
const T * queryParam (const std::string &name) const
 
const T & getRenamedParam (const std::string &old_name, const std::string &new_name) const
 
T getCheckedPointerParam (const std::string &name, const std::string &error_string="") const
 
bool isParamValid (const std::string &name) const
 
bool isParamSetByUser (const std::string &name) const
 
void connectControllableParams (const std::string &parameter, const std::string &object_type, const std::string &object_name, const std::string &object_parameter) const
 
void paramError (const std::string &param, Args... args) const
 
void paramWarning (const std::string &param, Args... args) const
 
void paramWarning (const std::string &param, Args... args) const
 
void paramInfo (const std::string &param, Args... args) const
 
std::string messagePrefix (const bool hit_prefix=true) const
 
std::string errorPrefix (const std::string &) const
 
void mooseError (Args &&... args) const
 
void mooseDocumentedError (const std::string &repo_name, const unsigned int issue_num, Args &&... args) const
 
void mooseErrorNonPrefixed (Args &&... args) const
 
void mooseWarning (Args &&... args) const
 
void mooseWarning (Args &&... args) const
 
void mooseWarningNonPrefixed (Args &&... args) const
 
void mooseWarningNonPrefixed (Args &&... args) const
 
void mooseDeprecated (Args &&... args) const
 
void mooseDeprecated (Args &&... args) const
 
void mooseDeprecatedNoTrace (Args &&... args) const
 
void mooseInfo (Args &&... args) const
 
void callMooseError (std::string msg, const bool with_prefix, const hit::Node *node=nullptr, const bool show_trace=true) const
 
std::string getDataFileName (const std::string &param) const
 
std::string getDataFileNameByName (const std::string &relative_path) const
 
std::string getDataFilePath (const std::string &relative_path) const
 
virtual void initialSetup ()
 
virtual void timestepSetup ()
 
virtual void jacobianSetup ()
 
virtual void residualSetup ()
 
virtual void customSetup (const ExecFlagType &)
 
const ExecFlagEnum & getExecuteOnEnum () const
 
UserObjectName getUserObjectName (const std::string &param_name) const
 
const T & getUserObject (const std::string &param_name, bool is_dependency=true) const
 
const T & getUserObjectByName (const UserObjectName &object_name, bool is_dependency=true) const
 
const UserObjectBase & getUserObjectBase (const std::string &param_name, bool is_dependency=true) const
 
const UserObjectBase & getUserObjectBaseByName (const UserObjectName &object_name, bool is_dependency=true) const
 
const std::vector< MooseVariableScalar * > & getCoupledMooseScalarVars ()
 
const std::set< TagID > & getScalarVariableCoupleableVectorTags () const
 
const std::set< TagID > & getScalarVariableCoupleableMatrixTags () const
 
const GenericMaterialProperty< T, is_ad > & getGenericMaterialProperty (const std::string &name, MaterialData &material_data, const unsigned int state=0)
 
const GenericMaterialProperty< T, is_ad > & getGenericMaterialProperty (const std::string &name, const unsigned int state=0)
 
const GenericMaterialProperty< T, is_ad > & getGenericMaterialProperty (const std::string &name, const unsigned int state=0)
 
const MaterialProperty< T > & getMaterialProperty (const std::string &name, MaterialData &material_data, const unsigned int state=0)
 
const MaterialProperty< T > & getMaterialProperty (const std::string &name, const unsigned int state=0)
 
const MaterialProperty< T > & getMaterialProperty (const std::string &name, const unsigned int state=0)
 
const ADMaterialProperty< T > & getADMaterialProperty (const std::string &name, MaterialData &material_data)
 
const ADMaterialProperty< T > & getADMaterialProperty (const std::string &name)
 
const ADMaterialProperty< T > & getADMaterialProperty (const std::string &name)
 
const MaterialProperty< T > & getMaterialPropertyOld (const std::string &name, MaterialData &material_data)
 
const MaterialProperty< T > & getMaterialPropertyOld (const std::string &name)
 
const MaterialProperty< T > & getMaterialPropertyOld (const std::string &name)
 
const MaterialProperty< T > & getMaterialPropertyOlder (const std::string &name, MaterialData &material_data)
 
const MaterialProperty< T > & getMaterialPropertyOlder (const std::string &name)
 
const MaterialProperty< T > & getMaterialPropertyOlder (const std::string &name)
 
const GenericMaterialProperty< T, is_ad > & getGenericMaterialPropertyByName (const MaterialPropertyName &name, MaterialData &material_data, const unsigned int state)
 
const GenericMaterialProperty< T, is_ad > & getGenericMaterialPropertyByName (const MaterialPropertyName &name, const unsigned int state=0)
 
const GenericMaterialProperty< T, is_ad > & getGenericMaterialPropertyByName (const MaterialPropertyName &name, const unsigned int state=0)
 
const MaterialProperty< T > & getMaterialPropertyByName (const MaterialPropertyName &name, MaterialData &material_data, const unsigned int state=0)
 
const MaterialProperty< T > & getMaterialPropertyByName (const MaterialPropertyName &name, const unsigned int state=0)
 
const MaterialProperty< T > & getMaterialPropertyByName (const MaterialPropertyName &name, const unsigned int state=0)
 
const ADMaterialProperty< T > & getADMaterialPropertyByName (const MaterialPropertyName &name, MaterialData &material_data)
 
const ADMaterialProperty< T > & getADMaterialPropertyByName (const MaterialPropertyName &name)
 
const ADMaterialProperty< T > & getADMaterialPropertyByName (const MaterialPropertyName &name)
 
const MaterialProperty< T > & getMaterialPropertyOldByName (const MaterialPropertyName &name, MaterialData &material_data)
 
const MaterialProperty< T > & getMaterialPropertyOldByName (const MaterialPropertyName &name)
 
const MaterialProperty< T > & getMaterialPropertyOldByName (const MaterialPropertyName &name)
 
const MaterialProperty< T > & getMaterialPropertyOlderByName (const MaterialPropertyName &name, MaterialData &material_data)
 
const MaterialProperty< T > & getMaterialPropertyOlderByName (const MaterialPropertyName &name)
 
const MaterialProperty< T > & getMaterialPropertyOlderByName (const MaterialPropertyName &name)
 
Moose::Kokkos::MaterialProperty< T, dimension > getKokkosMaterialPropertyByName (const std::string &prop_name_in)
 
Moose::Kokkos::MaterialProperty< T, dimension > getKokkosMaterialPropertyOldByName (const std::string &prop_name)
 
Moose::Kokkos::MaterialProperty< T, dimension > getKokkosMaterialPropertyOlderByName (const std::string &prop_name)
 
Moose::Kokkos::MaterialProperty< T, dimension > getKokkosMaterialProperty (const std::string &name)
 
Moose::Kokkos::MaterialProperty< T, dimension > getKokkosMaterialPropertyOld (const std::string &name)
 
Moose::Kokkos::MaterialProperty< T, dimension > getKokkosMaterialPropertyOlder (const std::string &name)
 
std::pair< const MaterialProperty< T > *, std::set< SubdomainID > > getBlockMaterialProperty (const MaterialPropertyName &name)
 
std::pair< Moose::Kokkos::MaterialProperty< T, dimension >, std::set< SubdomainID > > getKokkosBlockMaterialProperty (const MaterialPropertyName &name)
 
const GenericMaterialProperty< T, is_ad > & getGenericZeroMaterialProperty (const std::string &name)
 
const GenericMaterialProperty< T, is_ad > & getGenericZeroMaterialProperty ()
 
const GenericMaterialProperty< T, is_ad > & getGenericZeroMaterialPropertyByName (const std::string &prop_name)
 
const MaterialProperty< T > & getZeroMaterialProperty (Ts... args)
 
std::set< SubdomainID > getMaterialPropertyBlocks (const std::string &name)
 
std::vector< SubdomainName > getMaterialPropertyBlockNames (const std::string &name)
 
std::set< BoundaryID > getMaterialPropertyBoundaryIDs (const std::string &name)
 
std::vector< BoundaryName > getMaterialPropertyBoundaryNames (const std::string &name)
 
void checkBlockAndBoundaryCompatibility (std::shared_ptr< MaterialBase > discrete)
 
std::unordered_map< SubdomainID, std::vector< MaterialBase * > > buildRequiredMaterials (bool allow_stateful=true)
 
void statefulPropertiesAllowed (bool)
 
virtual bool getMaterialPropertyCalled () const
 
virtual const std::unordered_set< unsigned int > & getMatPropDependencies () const
 
virtual void resolveOptionalProperties ()
 
const GenericMaterialProperty< T, is_ad > & getPossiblyConstantGenericMaterialPropertyByName (const MaterialPropertyName &prop_name, MaterialData &material_data, const unsigned int state)
 
bool isImplicit ()
 
Moose::StateArg determineState () const
 
bool hasUserObject (const std::string &param_name) const
 
bool hasUserObject (const std::string &param_name) const
 
bool hasUserObject (const std::string &param_name) const
 
bool hasUserObject (const std::string &param_name) const
 
bool hasUserObjectByName (const UserObjectName &object_name) const
 
bool hasUserObjectByName (const UserObjectName &object_name) const
 
bool hasUserObjectByName (const UserObjectName &object_name) const
 
bool hasUserObjectByName (const UserObjectName &object_name) const
 
const GenericOptionalMaterialProperty< T, is_ad > & getGenericOptionalMaterialProperty (const std::string &name, const unsigned int state=0)
 
const GenericOptionalMaterialProperty< T, is_ad > & getGenericOptionalMaterialProperty (const std::string &name, const unsigned int state=0)
 
const OptionalMaterialProperty< T > & getOptionalMaterialProperty (const std::string &name, const unsigned int state=0)
 
const OptionalMaterialProperty< T > & getOptionalMaterialProperty (const std::string &name, const unsigned int state=0)
 
const OptionalADMaterialProperty< T > & getOptionalADMaterialProperty (const std::string &name)
 
const OptionalADMaterialProperty< T > & getOptionalADMaterialProperty (const std::string &name)
 
const OptionalMaterialProperty< T > & getOptionalMaterialPropertyOld (const std::string &name)
 
const OptionalMaterialProperty< T > & getOptionalMaterialPropertyOld (const std::string &name)
 
const OptionalMaterialProperty< T > & getOptionalMaterialPropertyOlder (const std::string &name)
 
const OptionalMaterialProperty< T > & getOptionalMaterialPropertyOlder (const std::string &name)
 
MaterialBase & getMaterial (const std::string &name)
 
MaterialBase & getMaterial (const std::string &name)
 
MaterialBase & getMaterialByName (const std::string &name, bool no_warn=false)
 
MaterialBase & getMaterialByName (const std::string &name, bool no_warn=false)
 
bool hasMaterialProperty (const std::string &name)
 
bool hasMaterialProperty (const std::string &name)
 
bool hasMaterialPropertyByName (const std::string &name)
 
bool hasMaterialPropertyByName (const std::string &name)
 
bool hasADMaterialProperty (const std::string &name)
 
bool hasADMaterialProperty (const std::string &name)
 
bool hasADMaterialPropertyByName (const std::string &name)
 
bool hasADMaterialPropertyByName (const std::string &name)
 
bool hasKokkosMaterialProperty (const std::string &name)
 
bool hasKokkosMaterialProperty (const std::string &name)
 
bool hasKokkosMaterialPropertyByName (const std::string &name)
 
bool hasKokkosMaterialPropertyByName (const std::string &name)
 
bool hasGenericMaterialProperty (const std::string &name)
 
bool hasGenericMaterialProperty (const std::string &name)
 
bool hasGenericMaterialPropertyByName (const std::string &name)
 
bool hasGenericMaterialPropertyByName (const std::string &name)
 
const Function & getFunction (const std::string &name) const
 
const Function & getFunctionByName (const FunctionName &name) const
 
bool hasFunction (const std::string &param_name) const
 
bool hasFunctionByName (const FunctionName &name) const
 
Moose::Kokkos::Function getKokkosFunction (const std::string &name) const
 
const T & getKokkosFunction (const std::string &name) const
 
Moose::Kokkos::Function getKokkosFunctionByName (const FunctionName &name) const
 
const T & getKokkosFunctionByName (const FunctionName &name) const
 
bool hasKokkosFunction (const std::string &param_name) const
 
bool hasKokkosFunctionByName (const FunctionName &name) const
 
bool isDefaultPostprocessorValue (const std::string &param_name, const unsigned int index=0) const
 
bool hasPostprocessor (const std::string &param_name, const unsigned int index=0) const
 
bool hasPostprocessorByName (const PostprocessorName &name) const
 
std::size_t coupledPostprocessors (const std::string &param_name) const
 
const PostprocessorName & getPostprocessorName (const std::string &param_name, const unsigned int index=0) const
 
const VectorPostprocessorValue & getVectorPostprocessorValue (const std::string &param_name, const std::string &vector_name) const
 
const VectorPostprocessorValue & getVectorPostprocessorValue (const std::string &param_name, const std::string &vector_name, bool needs_broadcast) const
 
const VectorPostprocessorValue & getVectorPostprocessorValueByName (const VectorPostprocessorName &name, const std::string &vector_name) const
 
const VectorPostprocessorValue & getVectorPostprocessorValueByName (const VectorPostprocessorName &name, const std::string &vector_name, bool needs_broadcast) const
 
const VectorPostprocessorValue & getVectorPostprocessorValueOld (const std::string &param_name, const std::string &vector_name) const
 
const VectorPostprocessorValue & getVectorPostprocessorValueOld (const std::string &param_name, const std::string &vector_name, bool needs_broadcast) const
 
const VectorPostprocessorValue & getVectorPostprocessorValueOldByName (const VectorPostprocessorName &name, const std::string &vector_name) const
 
const VectorPostprocessorValue & getVectorPostprocessorValueOldByName (const VectorPostprocessorName &name, const std::string &vector_name, bool needs_broadcast) const
 
const ScatterVectorPostprocessorValue & getScatterVectorPostprocessorValue (const std::string &param_name, const std::string &vector_name) const
 
const ScatterVectorPostprocessorValue & getScatterVectorPostprocessorValueByName (const VectorPostprocessorName &name, const std::string &vector_name) const
 
const ScatterVectorPostprocessorValue & getScatterVectorPostprocessorValueOld (const std::string &param_name, const std::string &vector_name) const
 
const ScatterVectorPostprocessorValue & getScatterVectorPostprocessorValueOldByName (const VectorPostprocessorName &name, const std::string &vector_name) const
 
bool hasVectorPostprocessor (const std::string &param_name, const std::string &vector_name) const
 
bool hasVectorPostprocessor (const std::string &param_name) const
 
bool hasVectorPostprocessorByName (const VectorPostprocessorName &name, const std::string &vector_name) const
 
bool hasVectorPostprocessorByName (const VectorPostprocessorName &name) const
 
const VectorPostprocessorName & getVectorPostprocessorName (const std::string &param_name) const
 
T & getSampler (const std::string &name)
 
Sampler & getSampler (const std::string &name)
 
T & getSamplerByName (const SamplerName &name)
 
Sampler & getSamplerByName (const SamplerName &name)
 
virtual void meshChanged ()
 
virtual void meshDisplaced ()
 
PerfGraph & perfGraph ()
 
const PostprocessorValue & getPostprocessorValue (const std::string &param_name, const unsigned int index=0) const
 
const PostprocessorValue & getPostprocessorValue (const std::string &param_name, const unsigned int index=0) const
 
const PostprocessorValue & getPostprocessorValueOld (const std::string &param_name, const unsigned int index=0) const
 
const PostprocessorValue & getPostprocessorValueOld (const std::string &param_name, const unsigned int index=0) const
 
const PostprocessorValue & getPostprocessorValueOlder (const std::string &param_name, const unsigned int index=0) const
 
const PostprocessorValue & getPostprocessorValueOlder (const std::string &param_name, const unsigned int index=0) const
 
virtual const PostprocessorValue & getPostprocessorValueByName (const PostprocessorName &name) const
 
virtual const PostprocessorValue & getPostprocessorValueByName (const PostprocessorName &name) const
 
const PostprocessorValue & getPostprocessorValueOldByName (const PostprocessorName &name) const
 
const PostprocessorValue & getPostprocessorValueOldByName (const PostprocessorName &name) const
 
const PostprocessorValue & getPostprocessorValueOlderByName (const PostprocessorName &name) const
 
const PostprocessorValue & getPostprocessorValueOlderByName (const PostprocessorName &name) const
 
bool isVectorPostprocessorDistributed (const std::string &param_name) const
 
bool isVectorPostprocessorDistributed (const std::string &param_name) const
 
bool isVectorPostprocessorDistributedByName (const VectorPostprocessorName &name) const
 
bool isVectorPostprocessorDistributedByName (const VectorPostprocessorName &name) const
 
const Distribution & getDistribution (const std::string &name) const
 
const T & getDistribution (const std::string &name) const
 
const Distribution & getDistribution (const std::string &name) const
 
const T & getDistribution (const std::string &name) const
 
const Distribution & getDistributionByName (const DistributionName &name) const
 
const T & getDistributionByName (const std::string &name) const
 
const Distribution & getDistributionByName (const DistributionName &name) const
 
const T & getDistributionByName (const std::string &name) const
 
const Parallel::Communicator & comm () const
 
processor_id_type n_processors () const
 
processor_id_type processor_id () const
 

Static Public Member Functions

static InputParameters validParams ()
 
static void callMooseError (MooseApp *const app, const InputParameters &params, std::string msg, const bool with_prefix, const hit::Node *node, const bool show_trace=true)
 
static void sort (typename std::vector< T > &vector)
 
static void sortDFS (typename std::vector< T > &vector)
 
static void cyclicDependencyError (CyclicDependencyException< T2 > &e, const std::string &header, NameFunc &&name_func)
 
static void cyclicDependencyError (CyclicDependencyException< T2 > &e, const std::string &header)
 

Public Attributes

const Real _CT
 Turbulent modeling parameter used in axial momentum equation.
 
 usingCombinedWarningSolutionWarnings
 
const ConsoleStream _console
 

Static Public Attributes

static const std::string type_param
 
static const std::string name_param
 
static const std::string unique_name_param
 
static const std::string app_param
 
static const std::string moose_base_param
 
static const std::string kokkos_object_param
 
static constexpr PropertyValue::id_type default_property_id
 
static constexpr PropertyValue::id_type zero_property_id
 
static constexpr auto SYSTEM
 
static constexpr auto NAME
 

Protected Member Functions

Real computePacioMixingParameter (const Real Xi, const Real Xj, const Real perimeter_ratio) const
 Pacio mixing parameter of a gap between subchannels with flow splits Xi and Xj, including the ratio of the Pacio contact perimeter per gap to the gap width.
 
virtual void addPostprocessorDependencyHelper (const PostprocessorName &name) const override
 
virtual void addVectorPostprocessorDependencyHelper (const VectorPostprocessorName &name) const override
 
virtual void addUserObjectDependencyHelper (const UserObjectBase &uo) const override
 
void addReporterDependencyHelper (const ReporterName &reporter_name) override
 
void flagInvalidSolutionInternal (const InvalidSolutionID invalid_solution_id) const
 
InvalidSolutionID registerInvalidSolutionInternal (const std::string &message, const bool warning) const
 
const ReporterContextBase & getReporterContextBaseByName (const ReporterName &reporter_name) const
 
const ReporterName & getReporterName (const std::string &param_name) const
 
T & declareRestartableData (const std::string &data_name, Args &&... args)
 
ManagedValue< T > declareManagedRestartableDataWithContext (const std::string &data_name, void *context, Args &&... args)
 
const T & getRestartableData (const std::string &data_name) const
 
T & declareRestartableDataWithContext (const std::string &data_name, void *context, Args &&... args)
 
T & declareRecoverableData (const std::string &data_name, Args &&... args)
 
T & declareRestartableDataWithObjectName (const std::string &data_name, const std::string &object_name, Args &&... args)
 
T & declareRestartableDataWithObjectNameWithContext (const std::string &data_name, const std::string &object_name, void *context, Args &&... args)
 
std::string restartableName (const std::string &data_name) const
 
const T & getMeshProperty (const std::string &data_name, const std::string &prefix)
 
const T & getMeshProperty (const std::string &data_name)
 
bool hasMeshProperty (const std::string &data_name, const std::string &prefix) const
 
bool hasMeshProperty (const std::string &data_name, const std::string &prefix) const
 
bool hasMeshProperty (const std::string &data_name) const
 
bool hasMeshProperty (const std::string &data_name) const
 
std::string meshPropertyName (const std::string &data_name) const
 
PerfID registerTimedSection (const std::string &section_name, const unsigned int level) const
 
PerfID registerTimedSection (const std::string &section_name, const unsigned int level, const std::string &live_message, const bool print_dots=true) const
 
std::string timedSectionName (const std::string &section_name) const
 
bool isCoupledScalar (const std::string &var_name, unsigned int i=0) const
 
unsigned int coupledScalarComponents (const std::string &var_name) const
 
unsigned int coupledScalar (const std::string &var_name, unsigned int comp=0) const
 
libMesh::Order coupledScalarOrder (const std::string &var_name, unsigned int comp=0) const
 
const VariableValue & coupledScalarValue (const std::string &var_name, unsigned int comp=0) const
 
const ADVariableValue & adCoupledScalarValue (const std::string &var_name, unsigned int comp=0) const
 
const GenericVariableValue< is_ad > & coupledGenericScalarValue (const std::string &var_name, unsigned int comp=0) const
 
const GenericVariableValue< false > & coupledGenericScalarValue (const std::string &var_name, const unsigned int comp) const
 
const GenericVariableValue< true > & coupledGenericScalarValue (const std::string &var_name, const unsigned int comp) const
 
const VariableValue & coupledVectorTagScalarValue (const std::string &var_name, const std::string &tag_param_name, unsigned int comp=0) const
 
const VariableValue & coupledMatrixTagScalarValue (const std::string &var_name, const std::string &tag_param_name, unsigned int comp=0) const
 
const VariableValue & coupledScalarValueOld (const std::string &var_name, unsigned int comp=0) const
 
const VariableValue & coupledScalarValueOlder (const std::string &var_name, unsigned int comp=0) const
 
const VariableValue & coupledScalarDot (const std::string &var_name, unsigned int comp=0) const
 
const ADVariableValue & adCoupledScalarDot (const std::string &var_name, unsigned int comp=0) const
 
const VariableValue & coupledScalarDotDot (const std::string &var_name, unsigned int comp=0) const
 
const VariableValue & coupledScalarDotOld (const std::string &var_name, unsigned int comp=0) const
 
const VariableValue & coupledScalarDotDotOld (const std::string &var_name, unsigned int comp=0) const
 
const VariableValue & coupledScalarDotDu (const std::string &var_name, unsigned int comp=0) const
 
const VariableValue & coupledScalarDotDotDu (const std::string &var_name, unsigned int comp=0) const
 
Moose::Kokkos::VariableValue kokkosCoupledVectorTagScalarValueByName (const std::string &var_name, const std::string &tag_name, unsigned int comp=0) const
 
Moose::Kokkos::VariableValue kokkosCoupledVectorTagScalarValue (const std::string &var_name, const std::string &tag_param_name, unsigned int comp=0) const
 
Moose::Kokkos::VariableValue kokkosCoupledScalarValue (const std::string &var_name, unsigned int comp=0) const
 
Moose::Kokkos::VariableValue kokkosCoupledScalarValueOld (const std::string &var_name, unsigned int comp=0) const
 
Moose::Kokkos::VariableValue kokkosCoupledScalarValueOlder (const std::string &var_name, unsigned int comp=0) const
 
Moose::Kokkos::VariableValue kokkosCoupledScalarDot (const std::string &var_name, unsigned int comp=0) const
 
Moose::Kokkos::Scalar< const Real > kokkosCoupledScalarDotDu (const std::string &var_name, unsigned int comp=0) const
 
const MooseVariableScalar * getScalarVar (const std::string &var_name, unsigned int comp) const
 
virtual void checkMaterialProperty (const std::string &name, const unsigned int state)
 
virtual void getKokkosMaterialPropertyHook (const std::string &, const unsigned int)
 
void markMatPropRequested (const std::string &)
 
MaterialPropertyName getMaterialPropertyName (const std::string &name) const
 
void checkExecutionStage ()
 
const T & getReporterValue (const std::string &param_name, const std::size_t time_index=0)
 
const T & getReporterValue (const std::string &param_name, ReporterMode mode, const std::size_t time_index=0)
 
const T & getReporterValue (const std::string &param_name, const std::size_t time_index=0)
 
const T & getReporterValue (const std::string &param_name, ReporterMode mode, const std::size_t time_index=0)
 
const T & getReporterValueByName (const ReporterName &reporter_name, const std::size_t time_index=0)
 
const T & getReporterValueByName (const ReporterName &reporter_name, ReporterMode mode, const std::size_t time_index=0)
 
const T & getReporterValueByName (const ReporterName &reporter_name, const std::size_t time_index=0)
 
const T & getReporterValueByName (const ReporterName &reporter_name, ReporterMode mode, const std::size_t time_index=0)
 
bool hasReporterValue (const std::string &param_name) const
 
bool hasReporterValue (const std::string &param_name) const
 
bool hasReporterValue (const std::string &param_name) const
 
bool hasReporterValue (const std::string &param_name) const
 
bool hasReporterValueByName (const ReporterName &reporter_name) const
 
bool hasReporterValueByName (const ReporterName &reporter_name) const
 
bool hasReporterValueByName (const ReporterName &reporter_name) const
 
bool hasReporterValueByName (const ReporterName &reporter_name) const
 
const GenericMaterialProperty< T, is_ad > * defaultGenericMaterialProperty (const std::string &name)
 
const GenericMaterialProperty< T, is_ad > * defaultGenericMaterialProperty (const std::string &name)
 
const MaterialProperty< T > * defaultMaterialProperty (const std::string &name)
 
const MaterialProperty< T > * defaultMaterialProperty (const std::string &name)
 
const ADMaterialProperty< T > * defaultADMaterialProperty (const std::string &name)
 
const ADMaterialProperty< T > * defaultADMaterialProperty (const std::string &name)
 

Static Protected Member Functions

static std::string meshPropertyName (const std::string &data_name, const std::string &prefix)
 

Protected Attributes

bool _is_tri_lattice
 Keep track of the lattice type.
 
const TriSubChannelMesh *const _tri_sch_mesh
 Pointer to the triangular lattice mesh.
 
const MooseEnum & _mixing_model
 Chen-Todreas mixing-model parameterization.
 
SolutionHandle _S_soln
 
SolutionHandle _mdot_soln
 
SolutionHandle _rho_soln
 
Real _beta_1986
 Cheng-Todreas (1986) mixing parameter of the gaps next to a center subchannel, which depends only on the geometry and the bulk Reynolds number.
 
Real _beta_sweep
 Cheng-Todreas (1986) sweep-flow coefficient of the peripheral gaps, which depends only on the geometry and the bulk Reynolds number.
 
std::vector< Real > _beta_pacio_center_edge
 Pacio mixing parameter of the center-edge and edge-corner gaps per axial level, from the flow split of each subchannel type lumped over the axial level.
 
std::vector< Real > _beta_pacio_edge_corner
 
const SubChannelMesh & _subchannel_mesh
 Reference to the subchannel mesh.
 
const SubChannel1PhaseProblem & _scm_problem
 Reference to the subchannel problem.
 
const Moose::CoordinateSystemType & _coord_sys
 
const THREAD_ID _tid
 
SubProblem & _subproblem
 
FEProblemBase & _fe_problem
 
SystemBase & _sys
 
Assembly & _assembly
 
const bool _duplicate_initial_execution
 
std::set< std::string > _depend_uo
 
const bool & _enabled
 
MooseApp & _app
 
Factory & _factory
 
ActionFactory & _action_factory
 
const std::string & _type
 
const std::string & _name
 
const InputParameters & _pars
 
const ExecFlagEnum & _execute_enum
 
const ExecFlagType & _current_execute_flag
 
MooseApp & _restartable_app
 
const std::string _restartable_system_name
 
const THREAD_ID _restartable_tid
 
const bool _restartable_read_only
 
FEProblemBase & _mci_feproblem
 
FEProblemBase & _mdi_feproblem
 
MooseApp & _pg_moose_app
 
const std::string _prefix
 
FEProblemBase & _sc_fe_problem
 
const THREAD_ID _sc_tid
 
const Real & _real_zero
 
const VariableValue & _scalar_zero
 
const Point & _point_zero
 
const InputParameters & _mi_params
 
const std::string _mi_name
 
const MooseObjectName _mi_moose_object_name
 
FEProblemBase & _mi_feproblem
 
SubProblem & _mi_subproblem
 
const THREAD_ID _mi_tid
 
const bool _is_kokkos_object
 
const Moose::MaterialDataType _material_data_type
 
MaterialData & _material_data
 
bool _stateful_allowed
 
bool _get_material_property_called
 
std::vector< std::unique_ptr< PropertyValue > > _default_properties
 
std::unordered_set< unsigned int > _material_property_dependencies
 
const MaterialPropertyName _get_suffix
 
const bool _use_interpolated_state
 
const InputParameters & _ti_params
 
FEProblemBase & _ti_feproblem
 
bool _is_implicit
 
Real & _t
 
const Real & _t_old
 
int & _t_step
 
Real & _dt
 
Real & _dt_old
 
bool _is_transient
 
const Parallel::Communicator & _communicator
 

Static Protected Attributes

static const std::string _interpolated_old
 
static const std::string _interpolated_older
 

Private Member Functions

const Moose::FunctionBase * getKokkosFunctionByNameHelper (const FunctionName &name) const
 
const UserObjectBase & getUserObjectFromFEProblem (const UserObjectName &object_name, const THREAD_ID tid=0) const
 
const T & castUserObject (const UserObjectBase &uo_base, const std::string &param_name="") const
 
void mooseObjectError (const std::string &param_name, std::stringstream &oss) const
 
const std::string & userObjectType (const UserObjectBase &uo) const
 
const std::string & userObjectName (const UserObjectBase &uo) const
 
const PostprocessorName & getPostprocessorNameInternal (const std::string &param_name, const unsigned int index, const bool allow_default_value=true) const
 
bool isDefaultPostprocessorValueByName (const PostprocessorName &name) const
 
PostprocessorValue getDefaultPostprocessorValueByName (const PostprocessorName &name) const
 
void checkParam (const std::string &param_name, const unsigned int index=std::numeric_limits< unsigned int >::max()) const
 
bool postprocessorsAdded () const
 
const VectorPostprocessorValue & getVectorPostprocessorByNameHelper (const VectorPostprocessorName &name, const std::string &vector_name, bool broadcast, std::size_t t_index) const
 
const VectorPostprocessorContext< VectorPostprocessorValue > & getVectorPostprocessorContextByNameHelper (const VectorPostprocessorName &name, const std::string &vector_name) const
 
bool vectorPostprocessorsAdded () const
 
bool reportersAdded () const
 
void possiblyCheckHasReporter (const ReporterName &reporter_name, const std::string &param_name="") const
 
RestartableDataValue & registerRestartableDataOnApp (std::unique_ptr< RestartableDataValue > data, THREAD_ID tid) const
 
void registerRestartableNameWithFilterOnApp (const std::string &name, Moose::RESTARTABLE_FILTER filter)
 
RestartableData< T > & declareRestartableDataHelper (const std::string &data_name, void *context, Args &&... args) const
 
virtual std::string meshPropertyPrefix (const std::string &data_name) const
 
const RestartableDataValue & getMeshPropertyInternal (const std::string &data_name, const std::string &prefix) const
 
void mooseErrorInternal (Args &&... args) const
 
const VariableValue * getDefaultValue (const std::string &var_name) const
 
const ADVariableValue * getADDefaultValue (const std::string &var_name) const
 
void checkVar (const std::string &var_name) const
 
void validateExecutionerType (const std::string &name, const std::string &fn_name) const
 
Moose::Kokkos::Variable kokkosCoupledVectorTagScalarVariable (const std::string &var_name, const std::string &tag_name, unsigned int comp) const
 
Moose::MaterialDataType getMaterialDataType (const std::set< BoundaryID > &boundary_ids) const
 
unsigned int getMaxQps () const
 
void addConsumedPropertyName (const MooseObjectName &obj_name, const std::string &prop_name)
 
const PostprocessorValue & getPostprocessorValueInternal (const std::string &param_name, unsigned int index, std::size_t t_index) const
 
const PostprocessorValue & getPostprocessorValueInternal (const std::string &param_name, unsigned int index, std::size_t t_index) const
 
const PostprocessorValue & getPostprocessorValueByNameInternal (const PostprocessorName &name, std::size_t t_index) const
 
const PostprocessorValue & getPostprocessorValueByNameInternal (const PostprocessorName &name, std::size_t t_index) const
 
void possiblyCheckHasVectorPostprocessor (const std::string &param_name, const std::string &vector_name) const
 
void possiblyCheckHasVectorPostprocessor (const std::string &param_name, const std::string &vector_name) const
 
void possiblyCheckHasVectorPostprocessorByName (const VectorPostprocessorName &name, const std::string &vector_name) const
 
void possiblyCheckHasVectorPostprocessorByName (const VectorPostprocessorName &name, const std::string &vector_name) const
 

Static Private Member Functions

static const hit::Node * getHitNode (const InputParameters &params)
 
static std::string messagePrefix (const InputParameters &params, const bool hit_prefix)
 

Private Attributes

UserObject * _primary_thread_copy
 
std::set< std::string > _supplied_uo
 
const ParallelParamObject & _parent
 
const MooseBase & _si_moose_base
 
const FEProblemBase * _si_problem
 
ExecFlagEnum _empty_execute_enum
 
const MooseObject & _fni_object
 
const InputParameters & _fni_params
 
FEProblemBase & _fni_feproblem
 
const THREAD_ID _fni_tid
 
const MooseObject & _uoi_moose_object
 
const FEProblemBase & _uoi_feproblem
 
const THREAD_ID _uoi_tid
 
const MooseObject & _ppi_moose_object
 
const InputParameters & _ppi_params
 
const FEProblemBase & _ppi_feproblem
 
std::map< PostprocessorName, std::unique_ptr< PostprocessorValue > > _default_values
 
const bool _broadcast_by_default
 
const MooseObject & _vpi_moose_object
 
const FEProblemBase & _vpi_feproblem
 
const THREAD_ID _vpi_tid
 
const InputParameters & _ri_params
 
FEProblemBase & _ri_fe_problem_base
 
const ReporterData & _ri_reporter_data
 
const MooseObject & _ri_moose_object
 
const InputParameters & _dni_params
 
FEProblemBase & _dni_feproblem
 
const MooseObject *const _dni_moose_object_ptr
 
const InputParameters & _si_params
 
FEProblemBase & _si_feproblem
 
THREAD_ID _si_tid
 
const RestartableDataMapName _metaname
 
std::string _restartable_name
 
MooseApp & _meta_data_app
 
const MooseObject *const _meta_data_object
 
const InputParameters & _sc_parameters
 
const std::string & _sc_name
 
const bool _sc_is_implicit
 
std::unordered_map< std::string, std::vector< MooseVariableScalar * > > _coupled_scalar_vars
 
std::unordered_map< std::string, std::unique_ptr< VariableValue > > _default_value
 
std::unordered_map< std::string, std::unique_ptr< ADVariableValue > > _dual_default_value
 
std::vector< MooseVariableScalar * > _coupled_moose_scalar_vars
 
std::unordered_map< std::string, std::vector< MooseVariableFieldBase * > > _sc_coupled_vars
 
std::set< TagID > _sc_coupleable_vector_tags
 
std::set< TagID > _sc_coupleable_matrix_tags
 
const MooseObject & _mi_moose_object
 
const bool _mi_boundary_restricted
 
const std::set< SubdomainID > & _mi_block_ids
 
const std::set< BoundaryID > & _mi_boundary_ids
 
std::vector< std::unique_ptr< OptionalMaterialPropertyProxyBase< MaterialPropertyInterface > > > _optional_property_proxies
 
const std::string _ti_name
 

Detailed Description

Class that calculates turbulent mixing and sweep-flow coefficients for wire-wrapped triangular lattices.

The user may select either the Cheng-Todreas (1986) or Pacio parameterization.

Definition at line 20 of file SCMMixingChenTodreas.h.

Member Typedef Documentation

◆ FrictionStruct

Definition at line 25 of file SCMMixingClosureBase.h.

Constructor & Destructor Documentation

◆ SCMMixingChenTodreas()

SCMMixingChenTodreas::SCMMixingChenTodreas ( const InputParameters &  parameters)

Definition at line 32 of file SCMMixingChenTodreas.C.

34 _is_tri_lattice(dynamic_cast<const TriSubChannelMesh *>(&_subchannel_mesh) != nullptr),
35 _tri_sch_mesh(dynamic_cast<const TriSubChannelMesh *>(&_subchannel_mesh)),
36 _mixing_model(getParam<MooseEnum>("mixing_model")),
40 // Not a number until computeBulkMixingParameters, so that the problem rejects any use before
41 _beta_1986(std::numeric_limits<Real>::quiet_NaN()),
42 _beta_sweep(std::numeric_limits<Real>::quiet_NaN())
43{
44 if (!_is_tri_lattice)
45 mooseError("This correlation applies only for triangular assemblies");
46
48 mooseError("This correlation applies only for wire-wrapped assemblies");
49
50 const auto pitch = _subchannel_mesh.getPitch();
51 const auto pin_diameter = _subchannel_mesh.getPinDiameter();
52 const auto p_over_d = pitch / pin_diameter;
53 const auto wire_lead_to_diameter = _tri_sch_mesh->getWireLeadLength() / pin_diameter;
54 const unsigned int Nr = _tri_sch_mesh->getNumOfRings();
55 const unsigned int num_pins = 1 + 3 * Nr * (Nr - 1);
56
57 // Cheng and Todreas (1986), Table 3, reports the mixing parameter data range as
58 // 1.07 <= P/D <= 1.30, 4 <= H/D <= 52, and 400 <= Reb <= 1.0e6. Their Tables 1 and 2 list
59 // the mixing experiments, which span 7 <= Npin <= 217.
60 // Pacio et al. (2022), Table 1, reports the PCTD range of validity as
61 // 19 <= Npin <= 217, 1.02 <= P/D <= 1.42, 7.5 <= H/D <= 54, and 10 <= Reb <= 3.0e5.
62 if (_mixing_model == "1986")
63 {
64 if (p_over_d < 1.07 || p_over_d > 1.30)
65 flagSolutionWarning("Pitch-over-pin diameter ratio (P/D) outside the 1986 "
66 "Cheng-Todreas mixing correlation data range.");
67 if (wire_lead_to_diameter < 4.0 || wire_lead_to_diameter > 52.0)
68 flagSolutionWarning("Wire lead length-over-pin diameter ratio (H/D) outside the 1986 "
69 "Cheng-Todreas mixing correlation data range.");
70 if (num_pins < 7 || num_pins > 217)
71 flagSolutionWarning("Number of pins outside the 1986 Cheng-Todreas mixing correlation "
72 "data range.");
73 }
74 else
75 {
76 if (p_over_d < 1.02 || p_over_d > 1.42)
77 flagSolutionWarning("Pitch-over-pin diameter ratio (P/D) outside the "
78 "Pacio-Chen-Todreas mixing correlation data range.");
79 if (wire_lead_to_diameter < 7.5 || wire_lead_to_diameter > 54.0)
80 flagSolutionWarning("Wire lead length-over-pin diameter ratio (H/D) outside the "
81 "Pacio-Chen-Todreas mixing correlation data range.");
82 if (num_pins < 19 || num_pins > 217)
83 flagSolutionWarning("Number of pins outside the Pacio-Chen-Todreas mixing correlation "
84 "data range.");
85 }
86}
const InputParameters & parameters() const
void mooseError(Args &&... args) const
const SubChannelMesh & _subchannel_mesh
Reference to the subchannel mesh.
const MooseEnum & _mixing_model
Chen-Todreas mixing-model parameterization.
Real _beta_1986
Cheng-Todreas (1986) mixing parameter of the gaps next to a center subchannel, which depends only on ...
Real _beta_sweep
Cheng-Todreas (1986) sweep-flow coefficient of the peripheral gaps, which depends only on the geometr...
bool _is_tri_lattice
Keep track of the lattice type.
const TriSubChannelMesh *const _tri_sch_mesh
Pointer to the triangular lattice mesh.
Base class for turbulent mixing closures used in SCM.
virtual const Real & getPitch() const
Return the undeformed pitch between 2 subchannels.
virtual const Real & getPinDiameter() const
Return undeformed Pin diameter.
virtual const MooseVariableFieldBase & getVariable(const THREAD_ID tid, const std::string &var_name, Moose::VarKindType expected_var_type=Moose::VarKindType::VAR_ANY, Moose::VarFieldType expected_var_field_type=Moose::VarFieldType::VAR_FIELD_ANY) const=0
Mesh class for triangular, edge and corner subchannels for hexagonal lattice fuel assemblies.
const Real & getWireDiameter() const
Return wire diameter.
const Real & getWireLeadLength() const
Return the wire lead length.
const unsigned int & getNumOfRings() const
Return the number of fuel-pin rings, counting the center pin as the first ring.

Member Function Documentation

◆ computeBlockMixingParameters()

void SCMMixingChenTodreas::computeBlockMixingParameters ( const unsigned int  ,
const unsigned int   
) const
overridevirtual

Precomputes the mixing coefficients that depend on the flow solution of the axial levels first_node to last_node.

Called before the turbulent crossflow of a block is computed; does nothing by default.

Reimplemented from SCMMixingClosureBase.

Definition at line 227 of file SCMMixingChenTodreas.C.

229{
230 if (_mixing_model != "Pacio")
231 return;
232
233 if (_beta_pacio_center_edge.size() < last_node + 1)
234 {
235 _beta_pacio_center_edge.resize(last_node + 1);
236 _beta_pacio_edge_corner.resize(last_node + 1);
237 }
238
239 const Real pitch = _subchannel_mesh.getPitch();
240 const Real pin_diameter = _subchannel_mesh.getPinDiameter();
241 const Real wire_diameter = _tri_sch_mesh->getWireDiameter();
242 const Real dpgap = _tri_sch_mesh->getDuctToPinGap();
243 const Real bulk_V = _scm_problem.getBulkVelocity();
244
245 // Pacio et al. (2022) Eq. (30) multiplies beta by the contact perimeter between all subchannels
246 // of two types, Eqs. (A.24) and (A.25), while SCM multiplies beta by the width of each gap.
247 // Scale beta by the ratio of the contact perimeter per gap to the gap width, so that the sum
248 // over the gaps of SCM gives the crossflow of Pacio:
249 // - center-edge: Pi12 = 6 n (P - D - Dw / 6) over the 6 n pin-pin gaps of width P - D;
250 // - edge-corner: Pi23 = [6 (W - D) 2 - Dw / 6] / 2 over the 12 pin-duct gaps of width W - D.
251 // Eq. (A.25) subtracts Dw / 6 once from the whole edge-corner perimeter, while Eq. (A.24)
252 // subtracts it from every center-edge gap. The corrigendum of Pacio et al., Nucl. Eng. Des. 395
253 // (2022) 111846, corrects their implementation to be consistent with Eq. (A.25) as printed.
254 const Real perimeter_ratio_center_edge =
255 (pitch - pin_diameter - wire_diameter / 6.0) / (pitch - pin_diameter);
256 const Real perimeter_ratio_edge_corner = (0.5 * dpgap - wire_diameter / 144.0) / dpgap;
257
258 for (unsigned int iz = first_node; iz < last_node + 1; iz++)
259 {
260 // Flow split of each subchannel type lumped over the axial cell, as in the PCTD model,
261 // where the flow split is defined per subchannel type: sum of the mass flow rates over sum of
262 // the density times flow area, averaged over the inlet and outlet of the cell. In the
263 // transition regime, Eq. (36) of Pacio et al. (2022) uses the turbulent flow split instead;
264 // the flow-split term varies as about X^(-0.18), so this changes the mixing by less than 1%.
265 Real mdot_sum[3] = {0.0, 0.0, 0.0};
266 Real rhoS_sum[3] = {0.0, 0.0, 0.0};
267 Real S_sum[3] = {0.0, 0.0, 0.0};
268 for (const auto i_ch : make_range(_subchannel_mesh.getNumOfChannels()))
269 {
270 const Node * const node_in = _subchannel_mesh.getChannelNode(i_ch, iz - 1);
271 const Node * const node_out = _subchannel_mesh.getChannelNode(i_ch, iz);
272 const auto type = _subchannel_mesh.getSubchannelType(i_ch);
273 const unsigned int i_type =
274 type == EChannelType::CENTER ? 0 : (type == EChannelType::EDGE ? 1 : 2);
275 mdot_sum[i_type] += 0.5 * (_mdot_soln(node_in) + _mdot_soln(node_out));
276 rhoS_sum[i_type] += 0.25 * (_rho_soln(node_in) + _rho_soln(node_out)) *
277 (_S_soln(node_in) + _S_soln(node_out));
278 S_sum[i_type] += 0.5 * (_S_soln(node_in) + _S_soln(node_out));
279 }
280 // Velocity of each type relative to the inlet bulk velocity. The density drops along a heated
281 // assembly, so the local bulk velocity rises above bulk_V; normalize so that the area-weighted
282 // flow splits sum to one, Pacio et al. (2022) Eq. (11), with S the fraction of the flow area
283 const Real V_center = mdot_sum[0] / rhoS_sum[0] / bulk_V;
284 const Real V_edge = mdot_sum[1] / rhoS_sum[1] / bulk_V;
285 const Real V_corner = mdot_sum[2] / rhoS_sum[2] / bulk_V;
286 const Real S_total = S_sum[0] + S_sum[1] + S_sum[2];
287 const Real norm = (S_sum[0] * V_center + S_sum[1] * V_edge + S_sum[2] * V_corner) / S_total;
288 const Real X_center = V_center / norm;
289 const Real X_edge = V_edge / norm;
290 const Real X_corner = V_corner / norm;
291
293 computePacioMixingParameter(X_center, X_edge, perimeter_ratio_center_edge);
295 computePacioMixingParameter(X_edge, X_corner, perimeter_ratio_edge_corner);
296 }
297}
const std::string & type() const
const SubChannel1PhaseProblem & _scm_problem
Reference to the subchannel problem.
std::vector< Real > _beta_pacio_center_edge
Pacio mixing parameter of the center-edge and edge-corner gaps per axial level, from the flow split o...
std::vector< Real > _beta_pacio_edge_corner
Real computePacioMixingParameter(const Real Xi, const Real Xj, const Real perimeter_ratio) const
Pacio mixing parameter of a gap between subchannels with flow splits Xi and Xj, including the ratio o...
virtual EChannelType getSubchannelType(unsigned int index) const =0
Return the type of the subchannel for given subchannel index.
virtual Node * getChannelNode(unsigned int i_chan, unsigned int iz) const =0
Get the subchannel mesh node for a given channel index and elevation index.
const Real & getDuctToPinGap() const
Return the the gap thickness between the duct and peripheral fuel pins.
auto norm(const T &a)
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
IntRange< T > make_range(T beg, T end)

◆ computeBulkMixingParameters()

void SCMMixingChenTodreas::computeBulkMixingParameters ( ) const
overridevirtual

Precomputes the mixing coefficients that depend only on the bulk flow.

Called after the bulk Reynolds number and velocity are updated; does nothing by default.

Reimplemented from SCMMixingClosureBase.

Definition at line 89 of file SCMMixingChenTodreas.C.

90{
91 const Real pitch = _subchannel_mesh.getPitch();
92 const Real pin_diameter = _subchannel_mesh.getPinDiameter();
93 const Real p_over_d = pitch / pin_diameter;
94
95 const Real wire_lead_length = _tri_sch_mesh->getWireLeadLength();
96 const Real wire_diameter = _tri_sch_mesh->getWireDiameter();
97 const unsigned int Nr = _tri_sch_mesh->getNumOfRings();
98
99 const Real bulk_Re = _scm_problem.getBulkReynoldsNumber();
100
101 // The bulk Reynolds number is computed from the solution during the solve, so its
102 // applicability range (see constructor) can only be checked here rather than at construction
103 if (_mixing_model == "1986")
104 {
105 if (bulk_Re < 400.0 || bulk_Re > 1.0e6)
106 flagSolutionWarning("Bulk Reynolds number (Reb) outside the 1986 Cheng-Todreas mixing "
107 "correlation data range.");
108 }
109 else if (bulk_Re < 10.0 || bulk_Re > 3.0e5)
110 flagSolutionWarning("Bulk Reynolds number (Reb) outside the Pacio-Chen-Todreas mixing "
111 "correlation data range.");
112
113 const Real theta = std::acos(
114 wire_lead_length / std::sqrt(Utility::pow<2>(wire_lead_length) +
115 Utility::pow<2>(libMesh::pi * (pin_diameter + wire_diameter))));
116
117 const Real ReL = 320.0 * std::pow(10.0, p_over_d - 1.0);
118
119 const Real ReT = 10000.0 * std::pow(10.0, 0.7 * (p_over_d - 1.0));
120
121 //
122 // Original Cheng-Todreas (1986) mixing correlation.
123 //
124 // This remains active for center-center gaps even when Pacio is selected,
125 // while center-edge gaps and edge-corner gaps are replaced by the Pacio treatment.
126 // When Pacio is not selected: beta is defined for center-center, center-edge gaps.
127 // In edge-edge, edge-corner beta = zero.
128 {
129 // projected area of wire on center subchannel
130 const Real Ar1 = libMesh::pi * (pin_diameter + wire_diameter) * wire_diameter / 6.0;
131
132 // bare center-subchannel flow area
133 const Real A1prime = (std::sqrt(3.0) / 4.0) * Utility::pow<2>(pitch) -
134 libMesh::pi * Utility::pow<2>(pin_diameter) / 8.0;
135
136 Real CmL_constant;
137 Real CmT_constant;
138
139 if (Nr == 1)
140 {
141 CmT_constant = 0.1;
142 CmL_constant = 0.055;
143 }
144 else
145 {
146 CmT_constant = 0.14;
147 CmL_constant = 0.077;
148 }
149
150 const Real CmT = CmT_constant * std::pow((pitch - pin_diameter) / pin_diameter, -0.5);
151
152 const Real CmL = CmL_constant * std::pow((pitch - pin_diameter) / pin_diameter, -0.5);
153
154 Real Cm;
155
156 if (bulk_Re < ReL)
157 Cm = CmL;
158 else if (bulk_Re > ReT)
159 Cm = CmT;
160 else
161 {
162 // Intermittency factor from the bulk Reynolds number. Cheng and Todreas (1986) Eqs.
163 // (10a)-(10c) and (11) use one per subchannel type, with the bounds Re_bL and Re_bT scaled by
164 // the laminar and turbulent flow splits; see SCMMixingChenTodreas.md
165 const Real psi = std::log(bulk_Re / ReL) / std::log(ReT / ReL);
166
167 const Real gamma = 2.0 / 3.0;
168
169 Cm = CmL + (CmT - CmL) * std::pow(psi, gamma);
170 }
171
172 _beta_1986 = Cm * std::sqrt(Ar1 / A1prime) * std::tan(theta);
173 }
174
175 // Sweep flow always uses the original Cheng-Todreas (1986) correlation.
176 {
177 // distance from pin surface to duct
178 const Real dpgap = _tri_sch_mesh->getDuctToPinGap();
179
180 // Edge pitch parameter defined as pin diameter plus distance to duct wall
181 const Real w = pin_diameter + dpgap;
182
183 const Real Ar2 = libMesh::pi * (pin_diameter + wire_diameter) * wire_diameter / 4.0;
184
185 const Real A2prime =
186 pitch * (w - pin_diameter / 2.0) - libMesh::pi * Utility::pow<2>(pin_diameter) / 8.0;
187
188 Real CsL_constant;
189 Real CsT_constant;
190
191 if (Nr == 1)
192 {
193 CsT_constant = 0.6;
194 CsL_constant = 0.33;
195 }
196 else
197 {
198 CsT_constant = 0.75;
199 CsL_constant = 0.413;
200 }
201
202 const Real CsL = CsL_constant * std::pow(wire_lead_length / pin_diameter, 0.3);
203 const Real CsT = CsT_constant * std::pow(wire_lead_length / pin_diameter, 0.3);
204
205 Real Cs;
206 if (bulk_Re < ReL)
207 Cs = CsL;
208 else if (bulk_Re > ReT)
209 Cs = CsT;
210 else
211 {
212 // Intermittency factor from the bulk Reynolds number. Cheng and Todreas (1986) Eqs.
213 // (10a)-(10c) and (11) use one per subchannel type, with the bounds Re_bL and Re_bT scaled by
214 // the laminar and turbulent flow splits; see SCMMixingChenTodreas.md
215 const Real psi = std::log(bulk_Re / ReL) / std::log(ReT / ReL);
216 const Real gamma = 2.0 / 3.0;
217
218 Cs = CsL + (CsT - CsL) * std::pow(psi, gamma);
219 }
220
221 // Sweep-flow coefficient used only by the peripheral enthalpy calculation.
222 _beta_sweep = Cs * std::sqrt(Ar2 / A2prime) * std::tan(theta);
223 }
224}
const Real pi

◆ computeMixingParameter()

Real SCMMixingChenTodreas::computeMixingParameter ( const unsigned int  i_gap,
const unsigned int  iz 
) const
overridevirtual

Computes the turbulent mixing coefficient for the local conditions around gap(i_gap) and axial level(iz)

Parameters
i_gapindex of the gap
Returns
the mixing coefficient (beta)

Implements SCMMixingClosureBase.

Definition at line 390 of file SCMMixingChenTodreas.C.

391{
392 const auto chans = _subchannel_mesh.getGapChannels(i_gap);
393 const auto subch_type_i = _subchannel_mesh.getSubchannelType(chans.first);
394 const auto subch_type_j = _subchannel_mesh.getSubchannelType(chans.second);
395
396 // Pacio applicability
397 const bool center_edge =
398 (subch_type_i == EChannelType::CENTER && subch_type_j == EChannelType::EDGE) ||
399 (subch_type_i == EChannelType::EDGE && subch_type_j == EChannelType::CENTER);
400
401 const bool edge_corner =
402 (subch_type_i == EChannelType::EDGE && subch_type_j == EChannelType::CORNER) ||
403 (subch_type_i == EChannelType::CORNER && subch_type_j == EChannelType::EDGE);
404
405 // Pacio defines the mixing treatment across center-edge and edge-corner gaps.
406 // For all other applicable gaps, we retain the original Cheng-Todreas (1986) model.
407 if (_mixing_model == "Pacio" && center_edge)
408 return _beta_pacio_center_edge[iz];
409 else if (_mixing_model == "Pacio" && edge_corner)
410 return _beta_pacio_edge_corner[iz];
411 else if (subch_type_i == EChannelType::CENTER || subch_type_j == EChannelType::CENTER)
412 return _beta_1986;
413 else
414 return 0.0;
415}
virtual const std::pair< unsigned int, unsigned int > & getGapChannels(unsigned int i_gap) const =0
Return a pair of subchannel indices for a given gap index.

◆ computePacioMixingParameter()

Real SCMMixingChenTodreas::computePacioMixingParameter ( const Real  Xi,
const Real  Xj,
const Real  perimeter_ratio 
) const
protected

Pacio mixing parameter of a gap between subchannels with flow splits Xi and Xj, including the ratio of the Pacio contact perimeter per gap to the gap width.

Definition at line 300 of file SCMMixingChenTodreas.C.

303{
304 mooseAssert(_mixing_model == "Pacio", "The Pacio mixing parameter requires mixing_model = Pacio");
305
306 const Real pitch = _subchannel_mesh.getPitch();
307 const Real pin_diameter = _subchannel_mesh.getPinDiameter();
308 const Real wire_lead_length = _tri_sch_mesh->getWireLeadLength();
309 const Real wire_diameter = _tri_sch_mesh->getWireDiameter();
310 const Real bulk_Re = _scm_problem.getBulkReynoldsNumber();
311
312 const Real theta = std::acos(
313 wire_lead_length / std::sqrt(Utility::pow<2>(wire_lead_length) +
314 Utility::pow<2>(libMesh::pi * (pin_diameter + wire_diameter))));
315
316 const Real ReL = 700.0;
317 const Real ReT = 10000.0;
318
319 constexpr Real flow_split_exponent = 2.0 - 0.18;
320
321 // Flow-split term of the mixing parameter, Pacio et al. (2022) Eq. (31).
322 Real fraction;
323 if (MooseUtils::absoluteFuzzyEqual(Xi, Xj))
324 {
325 const Real Xavg = 0.5 * (Xi + Xj);
326
327 if (Xavg < 0.0)
328 mooseError("The Pacio mixing correlation does not support negative flow splits "
329 "when evaluating the fractional flow-split exponent.");
330
331 // The flow-split term diverges as X^(-m) at zero flow; the crossflow is zero there because
332 // SCM multiplies beta by the average mass flux of the gap, so any finite value works
333 if (MooseUtils::absoluteFuzzyEqual(Xavg, 0.0))
334 fraction = 0.0;
335 else
336 fraction = 0.5 * flow_split_exponent * std::pow(Xavg, flow_split_exponent - 2.0);
337 }
338 else
339 {
340 if (Xi < 0.0 || Xj < 0.0)
341 mooseError("The Pacio mixing correlation does not support negative flow splits "
342 "when evaluating the fractional flow-split exponent.");
343
344 fraction = (std::pow(Xi, flow_split_exponent) - std::pow(Xj, flow_split_exponent)) /
345 (Utility::pow<2>(Xi) - Utility::pow<2>(Xj));
346 }
347
348 // Laminar and turbulent wire mixing coefficients, Pacio et al. (2022) Table 5
349 const Real WmL = 0.0;
350 const Real WmT = 8.8;
351
352 // Mixing parameter without the geometric factors, Pacio et al. (2022) Eqs. (31) and (33):
353 // WmT fraction / Reb^m in the turbulent regime and WmL / Reb in the laminar regime
354 const Real Re_eff = std::max(bulk_Re, 1.0);
355 const Real Cm_L = WmL / Re_eff;
356 const Real Cm_T = WmT * fraction / std::pow(Re_eff, 0.18);
357
358 Real Cm;
359
360 if (bulk_Re < ReL)
361 Cm = Cm_L;
362 else if (bulk_Re > ReT)
363 Cm = Cm_T;
364 else
365 {
366 const Real psi = std::log(bulk_Re / ReL) / std::log(ReT / ReL);
367
368 // Same transition interpolation as the Pacio-Chen-Todreas friction factor, Pacio et al. (2022)
369 // Eq. (35), with gamma and lambda of Table 5
370 const Real gamma = 0.362;
371 const Real lambda = 6.7;
372
373 Cm = Cm_L * std::pow(1.0 - psi, gamma) * (1.0 - std::pow(psi, lambda)) +
374 Cm_T * std::pow(psi, gamma);
375 }
376
377 // Pacio uses the edge-subchannel projected wire area and bare flow area.
378 const Real dpgap = _tri_sch_mesh->getDuctToPinGap();
379 const Real w = pin_diameter + dpgap;
380
381 const Real Ar2 = libMesh::pi * (pin_diameter + wire_diameter) * wire_diameter / 4.0;
382
383 const Real A2prime =
384 pitch * (w - pin_diameter / 2.0) - libMesh::pi * Utility::pow<2>(pin_diameter) / 8.0;
385
386 return Cm * std::sqrt(Ar2 / A2prime) * std::tan(theta) * perimeter_ratio;
387}

Referenced by computeBlockMixingParameters().

◆ computeSweepFlowMixingParameter()

Real SCMMixingChenTodreas::computeSweepFlowMixingParameter ( const unsigned int  i_gap,
const unsigned int  iz 
) const
overridevirtual

Computes the wire-wrap sweep-flow coefficient for peripheral gaps.

Returns
the sweep-flow coefficient; defaults to zero for closures without sweep flow.

Reimplemented from SCMMixingClosureBase.

Definition at line 418 of file SCMMixingChenTodreas.C.

420{
421 const auto chans = _subchannel_mesh.getGapChannels(i_gap);
422 const auto subch_type_i = _subchannel_mesh.getSubchannelType(chans.first);
423 const auto subch_type_j = _subchannel_mesh.getSubchannelType(chans.second);
424
425 if ((subch_type_i == EChannelType::CORNER || subch_type_i == EChannelType::EDGE) &&
426 (subch_type_j == EChannelType::CORNER || subch_type_j == EChannelType::EDGE))
427 return _beta_sweep;
428 else
429 return 0.0;
430}

◆ execute()

virtual void SCMClosureBase::execute ( )
inlinefinalvirtualinherited

Implements ThreadedGeneralUserObject.

Definition at line 26 of file SCMClosureBase.h.

26{}

◆ finalize()

virtual void SCMClosureBase::finalize ( )
inlinefinalvirtualinherited

Implements ThreadedGeneralUserObject.

Definition at line 28 of file SCMClosureBase.h.

28{}

◆ getCT()

virtual Real SCMMixingClosureBase::getCT ( ) const
inlinevirtualinherited

Return the Turbulent modeling parameter.

Definition at line 55 of file SCMMixingClosureBase.h.

55{ return _CT; }
const Real _CT
Turbulent modeling parameter used in axial momentum equation.

Referenced by SubChannel1PhaseProblem::initialSetup().

◆ initialize()

virtual void SCMClosureBase::initialize ( )
inlinefinalvirtualinherited

Implements ThreadedGeneralUserObject.

Definition at line 27 of file SCMClosureBase.h.

27{}

◆ subdomainSetup()

virtual void SCMClosureBase::subdomainSetup ( )
inlinefinalvirtualinherited

Reimplemented from ThreadedGeneralUserObject.

Definition at line 31 of file SCMClosureBase.h.

31{}

◆ threadJoin()

virtual void SCMClosureBase::threadJoin ( const UserObject &  )
inlinefinalvirtualinherited

Reimplemented from ThreadedGeneralUserObject.

Definition at line 30 of file SCMClosureBase.h.

30{}

◆ validParams()

InputParameters SCMMixingChenTodreas::validParams ( )
static

Definition at line 19 of file SCMMixingChenTodreas.C.

20{
22 params.addClassDescription("Class that models the turbulent mixing coefficient for wire-wrapped "
23 "triangular assemblies using the Chen Todreas correlations.");
24 MooseEnum mixing_model("1986 Pacio", "1986");
25 params.addParam<MooseEnum>(
26 "mixing_model",
27 mixing_model,
28 "Mixing-model parameterization for triangular wire-wrapped Chen-Todreas correlations.");
29 return params;
30}
void addParam(const std::string &name, const std::initializer_list< typename T::value_type > &value, const std::string &doc_string)
void addClassDescription(const std::string &doc_string)
static InputParameters validParams()

Member Data Documentation

◆ _beta_1986

Real SCMMixingChenTodreas::_beta_1986
mutableprotected

Cheng-Todreas (1986) mixing parameter of the gaps next to a center subchannel, which depends only on the geometry and the bulk Reynolds number.

Definition at line 57 of file SCMMixingChenTodreas.h.

Referenced by computeBulkMixingParameters(), and computeMixingParameter().

◆ _beta_pacio_center_edge

std::vector<Real> SCMMixingChenTodreas::_beta_pacio_center_edge
mutableprotected

Pacio mixing parameter of the center-edge and edge-corner gaps per axial level, from the flow split of each subchannel type lumped over the axial level.

Definition at line 65 of file SCMMixingChenTodreas.h.

Referenced by computeBlockMixingParameters(), and computeMixingParameter().

◆ _beta_pacio_edge_corner

std::vector<Real> SCMMixingChenTodreas::_beta_pacio_edge_corner
mutableprotected

Definition at line 66 of file SCMMixingChenTodreas.h.

Referenced by computeBlockMixingParameters(), and computeMixingParameter().

◆ _beta_sweep

Real SCMMixingChenTodreas::_beta_sweep
mutableprotected

Cheng-Todreas (1986) sweep-flow coefficient of the peripheral gaps, which depends only on the geometry and the bulk Reynolds number.

Definition at line 61 of file SCMMixingChenTodreas.h.

Referenced by computeBulkMixingParameters(), and computeSweepFlowMixingParameter().

◆ _CT

const Real SCMMixingClosureBase::_CT
inherited

Turbulent modeling parameter used in axial momentum equation.

Definition at line 50 of file SCMMixingClosureBase.h.

Referenced by SCMMixingClosureBase::getCT().

◆ _is_tri_lattice

bool SCMMixingChenTodreas::_is_tri_lattice
protected

Keep track of the lattice type.

Definition at line 43 of file SCMMixingChenTodreas.h.

Referenced by SCMMixingChenTodreas().

◆ _mdot_soln

SolutionHandle SCMMixingChenTodreas::_mdot_soln
protected

Definition at line 52 of file SCMMixingChenTodreas.h.

Referenced by computeBlockMixingParameters().

◆ _mixing_model

const MooseEnum& SCMMixingChenTodreas::_mixing_model
protected

◆ _rho_soln

SolutionHandle SCMMixingChenTodreas::_rho_soln
protected

Definition at line 53 of file SCMMixingChenTodreas.h.

Referenced by computeBlockMixingParameters().

◆ _S_soln

SolutionHandle SCMMixingChenTodreas::_S_soln
protected

Definition at line 51 of file SCMMixingChenTodreas.h.

Referenced by computeBlockMixingParameters().

◆ _scm_problem

const SubChannel1PhaseProblem& SCMClosureBase::_scm_problem
protectedinherited

◆ _subchannel_mesh

const SubChannelMesh& SCMClosureBase::_subchannel_mesh
protectedinherited

◆ _tri_sch_mesh

const TriSubChannelMesh* const SCMMixingChenTodreas::_tri_sch_mesh
protected

Pointer to the triangular lattice mesh.

Definition at line 46 of file SCMMixingChenTodreas.h.

Referenced by computeBlockMixingParameters(), computeBulkMixingParameters(), computePacioMixingParameter(), and SCMMixingChenTodreas().


The documentation for this class was generated from the following files: