- directionThe direction of the layers (x, y, or z)
C++ Type:MooseEnum
Controllable:No
Description:The direction of the layers (x, y, or z)
- num_layersThe number of layers between the bounding box of the domain
C++ Type:unsigned int
Controllable:No
Description:The number of layers between the bounding box of the domain
LayeredBin
Creates a unique spatial bin for layers in a specified direction
Description
This user object bins the spatial domain according to uniform-size layers in a specified direction according to the bounding box of the mesh. Layers are numbered increasing in the positive direction.
Example Input Syntax
Below is an example input file that constructs layered bins in each of the three coordinate directions.
[UserObjects]
[x_bins]
type = LayeredBin
num_layers = 4
direction = x
[]
[y_bins]
type = LayeredBin
num_layers = 5
direction = y
[]
[z_bins]
type = LayeredBin
num_layers = 6
direction = z
[]
[]
(test/tests/userobjects/layered_bin/layered.i)The bins in the direction are shown below, colored by bin ID.
Input Parameters
- execute_onTIMESTEP_ENDThe list of flag(s) indicating when this object should be executed, the available options include NONE, INITIAL, LINEAR, NONLINEAR, POSTCHECK, TIMESTEP_END, TIMESTEP_BEGIN, MULTIAPP_FIXED_POINT_END, MULTIAPP_FIXED_POINT_BEGIN, FINAL, CUSTOM.
Default:TIMESTEP_END
C++ Type:ExecFlagEnum
Options:NONE, INITIAL, LINEAR, NONLINEAR, POSTCHECK, TIMESTEP_END, TIMESTEP_BEGIN, MULTIAPP_FIXED_POINT_END, MULTIAPP_FIXED_POINT_BEGIN, FINAL, CUSTOM
Controllable:No
Description:The list of flag(s) indicating when this object should be executed, the available options include NONE, INITIAL, LINEAR, NONLINEAR, POSTCHECK, TIMESTEP_END, TIMESTEP_BEGIN, MULTIAPP_FIXED_POINT_END, MULTIAPP_FIXED_POINT_BEGIN, FINAL, CUSTOM.
- prop_getter_suffixAn optional suffix parameter that can be appended to any attempt to retrieve/get material properties. The suffix will be prepended with a '_' character.
C++ Type:MaterialPropertyName
Controllable:No
Description:An optional suffix parameter that can be appended to any attempt to retrieve/get material properties. The suffix will be prepended with a '_' character.
- use_interpolated_stateFalseFor the old and older state use projected material properties interpolated at the quadrature points. To set up projection use the ProjectedStatefulMaterialStorageAction.
Default:False
C++ Type:bool
Controllable:No
Description:For the old and older state use projected material properties interpolated at the quadrature points. To set up projection use the ProjectedStatefulMaterialStorageAction.
Optional Parameters
- allow_duplicate_execution_on_initialFalseIn the case where this UserObject is depended upon by an initial condition, allow it to be executed twice during the initial setup (once before the IC and again after mesh adaptivity (if applicable).
Default:False
C++ Type:bool
Controllable:No
Description:In the case where this UserObject is depended upon by an initial condition, allow it to be executed twice during the initial setup (once before the IC and again after mesh adaptivity (if applicable).
- control_tagsAdds user-defined labels for accessing object parameters via control logic.
C++ Type:std::vector<std::string>
Controllable:No
Description:Adds user-defined labels for accessing object parameters via control logic.
- enableTrueSet the enabled status of the MooseObject.
Default:True
C++ Type:bool
Controllable:Yes
Description:Set the enabled status of the MooseObject.
- execution_order_group0Execution order groups are executed in increasing order (e.g., the lowest number is executed first). Note that negative group numbers may be used to execute groups before the default (0) group. Please refer to the user object documentation for ordering of user object execution within a group.
Default:0
C++ Type:int
Controllable:No
Description:Execution order groups are executed in increasing order (e.g., the lowest number is executed first). Note that negative group numbers may be used to execute groups before the default (0) group. Please refer to the user object documentation for ordering of user object execution within a group.
- force_postauxFalseForces the UserObject to be executed in POSTAUX
Default:False
C++ Type:bool
Controllable:No
Description:Forces the UserObject to be executed in POSTAUX
- force_preauxFalseForces the UserObject to be executed in PREAUX
Default:False
C++ Type:bool
Controllable:No
Description:Forces the UserObject to be executed in PREAUX
- force_preicFalseForces the UserObject to be executed in PREIC during initial setup
Default:False
C++ Type:bool
Controllable:No
Description:Forces the UserObject to be executed in PREIC during initial setup
- use_displaced_meshFalseWhether or not this object should use the displaced mesh for computation. Note that in the case this is true but no displacements are provided in the Mesh block the undisplaced mesh will still be used.
Default:False
C++ Type:bool
Controllable:No
Description:Whether or not this object should use the displaced mesh for computation. Note that in the case this is true but no displacements are provided in the Mesh block the undisplaced mesh will still be used.
Advanced Parameters
Input Files
- (test/tests/userobjects/sideset_layered/z_bins_by_centroid.i)
- (test/tests/userobjects/hexagonal_gap_layered/type_error.i)
- (tutorials/subchannel/nek.i)
- (tutorials/gas_compact_cht/nek.i)
- (test/tests/userobjects/interval/nek.i)
- (test/tests/userobjects/sideset_layered/z_bins.i)
- (test/tests/userobjects/radial_layered/2d.i)
- (test/tests/userobjects/layered_layered/duplicate_directions.i)
- (test/tests/userobjects/hexagonal_gap_layered/nek.i)
- (test/tests/userobjects/subchannel_layered/user_component.i)
- (test/tests/auxkernels/nek_spatial_bin_component_aux/invalid_field.i)
- (tutorials/pebble_cht/nek.i)
- (test/tests/userobjects/layered_layered/1d.i)
- (test/tests/userobjects/layered_bin/layered.i)
- (test/tests/userobjects/hexagonal_gap_layered/user_component.i)
- (test/tests/userobjects/sideset_layered/side_average.i)
- (test/tests/userobjects/gap/nondimensional/nek.i)
- (tutorials/standalone/nek.i)
- (test/tests/userobjects/layered_layered/nek.i)
- (test/tests/userobjects/volume/dimensional/nek.i)
- (test/tests/userobjects/side/dimensional/nek.i)
- (test/tests/userobjects/layered_layered/3d.i)
- (test/tests/userobjects/subchannel_layered/nek.i)
- (test/tests/userobjects/side/nondimensional/nek.i)
- (test/tests/userobjects/subchannel_layered/duplicate_directions.i)
- (test/tests/userobjects/subchannel_layered/wrong_type.i)
- (test/tests/userobjects/volume/nondimensional/nek.i)
- (test/tests/userobjects/hexagonal_gap_layered/normals/nek.i)
- (test/tests/userobjects/sideset_layered/invalid_boundary.i)
- (test/tests/userobjects/gap/dimensional/nek.i)
(test/tests/userobjects/layered_bin/layered.i)
[Mesh]
type = GeneratedMesh
dim = 3
nx = 8
ny = 8
nz = 8
[]
[Problem]
solve = false
type = FEProblem
[]
[AuxVariables]
[x_bins]
family = MONOMIAL
order = CONSTANT
[]
[y_bins]
family = MONOMIAL
order = CONSTANT
[]
[z_bins]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[x_bins]
type = SpatialUserObjectAux
variable = x_bins
user_object = x_bins
[]
[y_bins]
type = SpatialUserObjectAux
variable = y_bins
user_object = y_bins
[]
[z_bins]
type = SpatialUserObjectAux
variable = z_bins
user_object = z_bins
[]
[]
[UserObjects]
[x_bins]
type = LayeredBin
num_layers = 4
direction = x
[]
[y_bins]
type = LayeredBin
num_layers = 5
direction = y
[]
[z_bins]
type = LayeredBin
num_layers = 6
direction = z
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
exodus = true
[]
(test/tests/userobjects/sideset_layered/z_bins_by_centroid.i)
[GlobalParams]
check_boundary_restricted = false
map_space_by_qp = false
[]
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature'
[]
[AuxVariables]
[T1_bin3]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[T1_bin3]
type = SpatialUserObjectAux
variable = T1_bin3
user_object = T1_bin3
boundary = '1'
[]
[]
[UserObjects]
[z3]
type = LayeredBin
direction = z
num_layers = 3
[]
[T1_bin3]
type = NekBinnedSideIntegral
bins = 'z3'
field = temperature
boundary = '1'
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[VectorPostprocessors]
[T]
type = SpatialUserObjectVectorPostprocessor
userobject = T1_bin3
[]
[]
[Outputs]
exodus = true
# remove from output to get smaller gold file
hide = 'temp'
[]
(test/tests/userobjects/hexagonal_gap_layered/type_error.i)
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature'
[]
[AuxVariables]
[axial_bins]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[bins2]
type = SpatialUserObjectAux
variable = axial_bins
user_object = axial_binning
[]
[]
[UserObjects]
[axial_binning]
type = LayeredBin
direction = z
num_layers = 6
[]
[vol_avg]
type = NekBinnedPlaneIntegral
bins = 'axial_binning'
field = unity
gap_thickness = 0.01
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
[]
(tutorials/subchannel/nek.i)
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature velocity'
[]
[UserObjects]
[subchannel_binning]
type = HexagonalSubchannelBin
bundle_pitch = 0.02583914354890463
pin_pitch = 0.0089656996
pin_diameter = 7.646e-3
n_rings = 2
[]
[subchannel_gap_binning]
type = HexagonalSubchannelGapBin
bundle_pitch = 0.02583914354890463
pin_pitch = 0.0089656996
pin_diameter = 7.646e-3
n_rings = 2
[]
[axial_binning]
type = LayeredBin
direction = z
num_layers = 7
[]
[average_T]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = temperature
map_space_by_qp = true
[]
[average_T_gaps]
type = NekBinnedPlaneAverage
bins = 'subchannel_gap_binning axial_binning'
field = temperature
map_space_by_qp = true
gap_thickness = ${fparse 0.05 * 7.646e-3}
[]
[avg_gap_velocity]
type = NekBinnedPlaneAverage
bins = 'subchannel_gap_binning axial_binning'
field = velocity_component
velocity_component = normal
map_space_by_qp = true
gap_thickness = ${fparse 0.05 * 7.646e-3}
[]
[]
[AuxVariables]
# These are just for visualizing the average velocity component with Glyphs in paraview;
# the result of the 'avg_gap_velocity' user object will be represented as a vector "uo_" with 3 components
[uo_x]
family = MONOMIAL
order = CONSTANT
[]
[uo_y]
family = MONOMIAL
order = CONSTANT
[]
[uo_z]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[uo_x]
type = NekSpatialBinComponentAux
variable = uo_x
user_object = avg_gap_velocity
component = 0
[]
[uo_y]
type = NekSpatialBinComponentAux
variable = uo_y
user_object = avg_gap_velocity
component = 1
[]
[uo_z]
type = NekSpatialBinComponentAux
variable = uo_z
user_object = avg_gap_velocity
component = 2
[]
[]
[MultiApps]
[subchannel]
type = TransientMultiApp
input_files = 'subchannel.i'
execute_on = timestep_end
sub_cycling = true
[]
[subchannel_gap]
type = TransientMultiApp
input_files = 'subchannel_gap.i'
execute_on = timestep_end
sub_cycling = true
[]
[]
[Transfers]
[uo_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = average_T
to_multi_app = subchannel
variable = average_T
[]
[uo_to_sub2]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = average_T_gaps
to_multi_app = subchannel_gap
variable = average_T
[]
[uo1_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_gap_velocity
to_multi_app = subchannel_gap
variable = avg_gap_velocity
[]
[uox_to_sub]
type = MultiAppGeneralFieldNearestLocationTransfer
to_multi_app = subchannel_gap
source_variable = uo_x
variable = uo_x
[]
[uoy_to_sub]
type = MultiAppGeneralFieldNearestLocationTransfer
to_multi_app = subchannel_gap
source_variable = uo_y
variable = uo_y
[]
[]
[VectorPostprocessors]
[avg_T]
type = SpatialUserObjectVectorPostprocessor
userobject = average_T
[]
[avg_T_gaps]
type = SpatialUserObjectVectorPostprocessor
userobject = average_T_gaps
[]
[avg_v_gaps]
type = SpatialUserObjectVectorPostprocessor
userobject = avg_gap_velocity
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
csv = true
[]
(tutorials/gas_compact_cht/nek.i)
# copy-pasta from common_input.i
channel_diameter = 0.016 # diameter of the coolant channels (m)
height = 6.343 # height of the full core (m)
inlet_T = 598.0 # inlet fluid temperature (K)
power = 200e6 # full core power (W)
mdot = 117.3 # fluid mass flowrate (kg/s)
fluid_density = 5.5508 # fluid density (kg/m3)
fluid_Cp = 5189.0 # fluid isobaric specific heat (J/kg/K)
n_bundles = 12 # number of bundles in the full core
n_coolant_channels_per_block = 108 # number of coolant channels per assembly
unit_cell_height = 1.6 # unit cell height - arbitrarily selected
num_layers_for_plots = 50 # number of layers to average fields over for plotting
[Mesh]
type = NekRSMesh
boundary = '3'
volume = true
scaling = ${channel_diameter}
[]
[Problem]
type = NekRSProblem
casename = 'ranstube'
has_heat_source = false
nondimensional = true
U_ref = ${fparse mdot / (n_bundles * n_coolant_channels_per_block) / fluid_density / (pi * channel_diameter * channel_diameter / 4.0)}
T_ref = ${inlet_T}
dT_ref = ${fparse power / mdot / fluid_Cp * unit_cell_height / height}
L_ref = ${channel_diameter}
rho_0 = ${fluid_density}
Cp_0 = ${fluid_Cp}
synchronization_interval = parent_app
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
min_dt = 1e-10
[]
[]
[Outputs]
exodus = true
[screen]
type = Console
hide = 'boundary_flux inlet_T outlet_T max_T flux_integral transfer_in'
[]
[csv]
file_base = 'csv/nek'
type = CSV
[]
[]
[Postprocessors]
[boundary_flux]
type = NekHeatFluxIntegral
boundary = '3'
[]
[inlet_T]
type = NekSideAverage
field = temperature
boundary = '1'
[]
[outlet_T]
type = NekSideAverage
field = temperature
boundary = '2'
[]
[max_T]
type = NekVolumeExtremeValue
field = temperature
value_type = max
[]
[]
[UserObjects]
active = '' # simply comment out this line to evaluate these user objects
[layered_bin]
type = LayeredBin
num_layers = ${num_layers_for_plots}
direction = z
[]
[wall_temp]
type = NekBinnedSideAverage
bins = 'layered_bin'
boundary = '3'
field = temperature
map_space_by_qp = true
[]
[bulk_temp]
type = NekBinnedVolumeAverage
bins = 'layered_bin'
field = temperature
map_space_by_qp = true
[]
[]
[VectorPostprocessors]
active = '' # simply comment out this line to evaluate these user objects
[wall]
type = SpatialUserObjectVectorPostprocessor
userobject = wall_temp
[]
[bulk]
type = SpatialUserObjectVectorPostprocessor
userobject = bulk_temp
[]
[]
(test/tests/userobjects/interval/nek.i)
[Problem]
type = NekRSStandaloneProblem
casename = 'brick'
nondimensional = true
L_ref = 2.0
U_ref = 1.0
rho_0 = 834.5
Cp_0 = 1228.0
T_ref = 573.0
dT_ref = 10.0
[]
[Mesh]
type = NekRSMesh
volume = true
scaling = 2.0
[]
[UserObjects]
[x_bins]
type = LayeredBin
direction = x
num_layers = 3
[]
[avg_v]
type = NekBinnedVolumeAverage
bins = 'x_bins'
field = velocity_z
interval = 3
[]
[]
[VectorPostprocessors]
[v]
type = SpatialUserObjectVectorPostprocessor
userobject = avg_v
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
csv = true
interval = 3
[]
(test/tests/userobjects/sideset_layered/z_bins.i)
[GlobalParams]
check_boundary_restricted = false
map_space_by_qp = true
[]
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature'
[]
[AuxVariables]
[uo1_bin1]
family = MONOMIAL
order = CONSTANT
[]
[uo1_bin3]
family = MONOMIAL
order = CONSTANT
[]
[uo2_bin1]
family = MONOMIAL
order = CONSTANT
[]
[uo2_bin3]
family = MONOMIAL
order = CONSTANT
[]
[uo_1_2_bin3]
family = MONOMIAL
order = CONSTANT
[]
[T1_bin1]
family = MONOMIAL
order = CONSTANT
[]
[T1_bin3]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[T1_bin1]
type = SpatialUserObjectAux
variable = T1_bin1
user_object = T1_bin1
boundary = '1'
[]
[T1_bin3]
type = SpatialUserObjectAux
variable = T1_bin3
user_object = T1_bin3
boundary = '1'
[]
[uo1_bin1]
type = SpatialUserObjectAux
variable = uo1_bin1
user_object = side1_bin1
boundary = '1'
[]
[uo2_bin1]
type = SpatialUserObjectAux
variable = uo2_bin1
user_object = side2_bin1
boundary = '2'
[]
[uo1_bin3]
type = SpatialUserObjectAux
variable = uo1_bin3
user_object = side1_bin3
boundary = '1'
[]
[uo2_bin3]
type = SpatialUserObjectAux
variable = uo2_bin3
user_object = side2_bin3
boundary = '2'
[]
[uo_1_2_bin3]
type = SpatialUserObjectAux
variable = uo_1_2_bin3
user_object = side_1_2_bin3
boundary = '1 2'
[]
[]
[UserObjects]
[z1]
type = LayeredBin
direction = z
num_layers = 1
[]
[side1_bin1]
type = NekBinnedSideIntegral
bins = 'z1'
field = unity
boundary = '1'
[]
[side2_bin1]
type = NekBinnedSideIntegral
bins = 'z1'
field = unity
boundary = '2'
[]
[side_1_2_bin1] # should equal the sum of side1_bin1 and side1_bin2
type = NekBinnedSideIntegral
bins = 'z1'
field = unity
boundary = '1 2'
[]
[T1_bin1]
type = NekBinnedSideIntegral
bins = 'z1'
field = temperature
boundary = '1'
[]
[z3]
type = LayeredBin
direction = z
num_layers = 3
[]
[side1_bin3]
type = NekBinnedSideIntegral
bins = 'z3'
field = unity
boundary = '1'
[]
[side2_bin3]
type = NekBinnedSideIntegral
bins = 'z3'
field = unity
boundary = '2'
[]
[side_1_2_bin3] # should equal the sum of side1_bin3 and side2_bin3
type = NekBinnedSideIntegral
bins = 'z3'
field = unity
boundary = '1 2'
[]
[T1_bin3]
type = NekBinnedSideIntegral
bins = 'z3'
field = temperature
boundary = '1'
[]
[]
[Postprocessors]
[area1] # should match the value of the side1_bin1 user object
type = NekSideIntegral
field = unity
boundary = '1'
[]
[area_divided1] # should match the value of the side1_bin3 user object
type = LinearCombinationPostprocessor
pp_names = 'area1'
pp_coefs = '${fparse 1.0 / 3.0}'
[]
[area2] # should match the value of the side2_bin1 user object
type = NekSideIntegral
field = unity
boundary = '2'
[]
[area_divided2] # should match the value of the side2_bin3 user object
type = LinearCombinationPostprocessor
pp_names = 'area2'
pp_coefs = '${fparse 1.0 / 3.0}'
[]
[T1] # should match the value of the T1_bin1 user object
type = NekSideIntegral
field = temperature
boundary = '1'
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
execute_on = 'final'
exodus = true
# removed from output to get a smaller gold file
hide = 'temp'
[]
(test/tests/userobjects/radial_layered/2d.i)
[Problem]
type = NekRSStandaloneProblem
casename = 'cylinder'
output = 'pressure'
nondimensional = true
L_ref = 5.0
U_ref = 1.0
rho_0 = 834.5
Cp_0 = 1228.0
T_ref = 573.0
dT_ref = 10.0
[]
[Mesh]
type = NekRSMesh
volume = true
scaling = 5.0
[]
[AuxVariables]
[uo]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[uo]
type = SpatialUserObjectAux
variable = uo
user_object = vol_integral
[]
[]
[UserObjects]
[r_bins]
type = RadialBin
vertical_axis = z
nr = 5
rmin = 0.0
rmax = 1.0
[]
[z_bins]
type = LayeredBin
direction = z
num_layers = 5
[]
[vol_integral]
type = NekBinnedVolumeIntegral
bins = 'r_bins z_bins'
field = pressure
[]
[]
[VectorPostprocessors]
# from_uo gives exactly the same results as manually specifying the points in 'manually_provided'
[from_uo]
type = SpatialUserObjectVectorPostprocessor
userobject = vol_integral
[]
[manually_provided]
type = SpatialUserObjectVectorPostprocessor
userobject = vol_integral
points = '0.1 0.0 -2.0
0.1 0.0 -1.0
0.1 0.0 0.0
0.1 0.0 1.0
0.1 0.0 2.0
0.3 0.0 -2.0
0.3 0.0 -1.0
0.3 0.0 0.0
0.3 0.0 1.0
0.3 0.0 2.0
0.5 0.0 -2.0
0.5 0.0 -1.0
0.5 0.0 0.0
0.5 0.0 1.0
0.5 0.0 2.0
0.7 0.0 -2.0
0.7 0.0 -1.0
0.7 0.0 0.0
0.7 0.0 1.0
0.7 0.0 2.0
0.9 0.0 -2.0
0.9 0.0 -1.0
0.9 0.0 0.0
0.9 0.0 1.0
0.9 0.0 2.0'
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
csv = true
exodus = true
execute_on = 'final'
[]
(test/tests/userobjects/layered_layered/duplicate_directions.i)
[Problem]
type = NekRSStandaloneProblem
casename = 'brick'
output = 'pressure'
nondimensional = true
L_ref = 2.0
U_ref = 1.0
rho_0 = 834.5
Cp_0 = 1228.0
T_ref = 573.0
dT_ref = 10.0
[]
[Mesh]
type = NekRSMesh
volume = true
scaling = 2.0
[]
[UserObjects]
[x_bins]
type = LayeredBin
direction = x
num_layers = 3
[]
[y_bins]
type = LayeredBin
direction = y
num_layers = 3
[]
[x_bins2]
type = LayeredBin
direction = x
num_layers = 12
[]
# should error because weve specified two x-direction bins
[vol_integral]
type = NekBinnedVolumeIntegral
bins = 'x_bins y_bins x_bins2'
field = unity
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
[]
(test/tests/userobjects/hexagonal_gap_layered/nek.i)
gap_thickness = ${fparse 0.05 * 7.646e-3}
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature'
[]
[AuxVariables]
[gap_bins]
family = MONOMIAL
order = CONSTANT
[]
[avg_temp]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[gap_bins]
type = SpatialUserObjectAux
variable = gap_bins
user_object = subchannel_binning
[]
[avg_temp]
type = SpatialUserObjectAux
variable = avg_temp
user_object = gap_avg
[]
[]
[UserObjects]
[subchannel_binning]
type = HexagonalSubchannelGapBin
bundle_pitch = 0.02583914354890463
pin_pitch = 0.0089656996
pin_diameter = 7.646e-3
n_rings = 2
[]
[axial_binning]
type = LayeredBin
direction = z
num_layers = 6
[]
[gap_avg]
type = NekBinnedPlaneAverage
bins = 'subchannel_binning axial_binning'
field = temperature
gap_thickness = ${gap_thickness}
map_space_by_qp = true
[]
[gap_area]
type = NekBinnedPlaneIntegral
bins = 'subchannel_binning axial_binning'
field = unity
gap_thickness = ${gap_thickness}
map_space_by_qp = true
[]
[]
[MultiApps]
[subchannel]
type = TransientMultiApp
input_files = 'subchannel.i'
execute_on = timestep_end
[]
[]
[Transfers]
[uo1_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = gap_avg
to_multi_app = subchannel
variable = gap_avg
[]
[uo2_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = gap_area
to_multi_app = subchannel
variable = gap_area
[]
[temp_to_sub]
type = MultiAppGeneralFieldNearestLocationTransfer
to_multi_app = subchannel
variable = temp
source_variable = temp
search_value_conflicts = false
[]
[]
[VectorPostprocessors]
[avg_temp]
type = SpatialUserObjectVectorPostprocessor
userobject = gap_avg
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
csv = true
[]
(test/tests/userobjects/subchannel_layered/user_component.i)
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'velocity'
[]
[AuxVariables]
[velocity_component]
[]
# These are just for visualizing the average velocity component with Glyphs in paraview;
# the result of the 'vol_avg' user object will be represented as a vector "uo_" with 3 components
[uo_x]
family = MONOMIAL
order = CONSTANT
[]
[uo_y]
family = MONOMIAL
order = CONSTANT
[]
[uo_z]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[velocity_component] # actual velocity component computed directly from interpolated nekRS velocity fields
type = ParsedAux
variable = velocity_component
expression = '(0.1*vel_x-0.2*vel_y+0.3*vel_z)/sqrt(0.1*0.1+0.2*0.2+0.3*0.3)'
coupled_variables = 'vel_x vel_y vel_z'
execute_on = 'timestep_end nonlinear linear'
[]
[uo_x]
type = NekSpatialBinComponentAux
variable = uo_x
user_object = vol_avg
component = 0
[]
[uo_y]
type = NekSpatialBinComponentAux
variable = uo_y
user_object = vol_avg
component = 1
[]
[uo_z]
type = NekSpatialBinComponentAux
variable = uo_z
user_object = vol_avg
component = 2
[]
[]
[UserObjects]
[subchannel_binning]
type = HexagonalSubchannelBin
bundle_pitch = 0.02583914354890463
pin_pitch = 0.0089656996
pin_diameter = 7.646e-3
n_rings = 2
[]
[axial_binning]
type = LayeredBin
direction = z
num_layers = 6
[]
[vol_avg]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = velocity_component
velocity_component = user
velocity_direction = '0.1 -0.2 0.3'
[]
[]
[MultiApps]
[subchannel]
type = TransientMultiApp
input_files = 'subchannel_b.i'
execute_on = timestep_end
[]
[]
[Transfers]
[uo1_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = vol_avg
to_multi_app = subchannel
variable = vol_avg
[]
[uox_to_sub]
type = MultiAppGeneralFieldNearestLocationTransfer
source_variable = uo_x
to_multi_app = subchannel
variable = uo_x
search_value_conflicts = false
[]
[uoy_to_sub]
type = MultiAppGeneralFieldNearestLocationTransfer
source_variable = uo_y
to_multi_app = subchannel
variable = uo_y
search_value_conflicts = false
[]
[uoz_to_sub]
type = MultiAppGeneralFieldNearestLocationTransfer
source_variable = uo_z
to_multi_app = subchannel
variable = uo_z
search_value_conflicts = false
[]
[analytic_to_sub]
type = MultiAppGeneralFieldNearestLocationTransfer
source_variable = velocity_component
to_multi_app = subchannel
variable = velocity_component
search_value_conflicts = false
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
# unhide and turn the number of time steps in the .par file to greater than 1 in order to see this
# match the user object
hide = 'velocity_component'
[]
(test/tests/auxkernels/nek_spatial_bin_component_aux/invalid_field.i)
[Problem]
type = NekRSStandaloneProblem
casename = 'brick'
output = 'pressure'
[]
[Mesh]
type = NekRSMesh
volume = true
[]
[AuxVariables]
[uo]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[uo]
type = NekSpatialBinComponentAux
variable = uo
user_object = vol_integral
component = 0
[]
[]
[UserObjects]
[x_bins]
type = LayeredBin
direction = x
num_layers = 3
[]
[vol_integral]
type = NekBinnedVolumeIntegral
bins = 'x_bins'
field = pressure
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
(tutorials/pebble_cht/nek.i)
[Mesh]
type = NekRSMesh
# This is the boundary we are coupling via conjugate heat transfer to MOOSE
boundary = '3'
[]
[Problem]
type = NekRSProblem
casename = 'pebble'
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[UserObjects]
[layered_bin]
type = LayeredBin
num_layers = 5
direction = z
[]
[wall_temp]
type = NekBinnedSideAverage
bins = 'layered_bin'
boundary = '3'
field = temperature
map_space_by_qp = true
interval = 10
[]
[bulk_temp]
type = NekBinnedVolumeAverage
bins = 'layered_bin'
field = temperature
map_space_by_qp = true
interval = 10
[]
[]
[VectorPostprocessors]
[wall]
type = SpatialUserObjectVectorPostprocessor
userobject = wall_temp
[]
[bulk]
type = SpatialUserObjectVectorPostprocessor
userobject = bulk_temp
[]
[]
[Outputs]
exodus = true
csv = true
interval = 10
hide = 'flux_integral'
[]
(test/tests/userobjects/layered_layered/1d.i)
[Problem]
type = NekRSStandaloneProblem
casename = 'brick'
output = 'pressure'
nondimensional = true
L_ref = 2.0
U_ref = 1.0
rho_0 = 834.5
Cp_0 = 1228.0
T_ref = 573.0
dT_ref = 10.0
[]
[Mesh]
type = NekRSMesh
volume = true
scaling = 2.0
[]
[AuxVariables]
[uo]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[uo]
type = SpatialUserObjectAux
variable = uo
user_object = vol_integral
[]
[]
[UserObjects]
[x_bins]
type = LayeredBin
direction = x
num_layers = 3
[]
[x_bins_gaps]
type = LayeredGapBin
direction = x
num_layers = 3
[]
[vol_integral]
type = NekBinnedVolumeIntegral
bins = 'x_bins'
field = pressure
[]
[face_avg]
type = NekBinnedPlaneAverage
bins = 'x_bins_gaps'
gap_thickness = 0.1
map_space_by_qp = true
field = pressure
[]
[]
[VectorPostprocessors]
# from_uo gives exactly the same results as manually specifying the points in 'manually_provided'
[from_uo]
type = SpatialUserObjectVectorPostprocessor
userobject = vol_integral
[]
[manually_provided]
type = SpatialUserObjectVectorPostprocessor
userobject = vol_integral
points = '-0.66666667 0.0 0.0
0.0 0.0 0.0
0.66666667 0.0 0.0'
[]
[from_uo_gap]
type = SpatialUserObjectVectorPostprocessor
userobject = face_avg
[]
[manually_provided_gap]
type = SpatialUserObjectVectorPostprocessor
userobject = face_avg
points = '-1.0 0.0 0.0
-0.33333 0.0 0.0
0.33333 0.0 0.0
1.0 0.0 0.0'
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
csv = true
exodus = true
execute_on = 'final'
[]
(test/tests/userobjects/layered_bin/layered.i)
[Mesh]
type = GeneratedMesh
dim = 3
nx = 8
ny = 8
nz = 8
[]
[Problem]
solve = false
type = FEProblem
[]
[AuxVariables]
[x_bins]
family = MONOMIAL
order = CONSTANT
[]
[y_bins]
family = MONOMIAL
order = CONSTANT
[]
[z_bins]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[x_bins]
type = SpatialUserObjectAux
variable = x_bins
user_object = x_bins
[]
[y_bins]
type = SpatialUserObjectAux
variable = y_bins
user_object = y_bins
[]
[z_bins]
type = SpatialUserObjectAux
variable = z_bins
user_object = z_bins
[]
[]
[UserObjects]
[x_bins]
type = LayeredBin
num_layers = 4
direction = x
[]
[y_bins]
type = LayeredBin
num_layers = 5
direction = y
[]
[z_bins]
type = LayeredBin
num_layers = 6
direction = z
[]
[]
[Executioner]
type = Steady
[]
[Outputs]
exodus = true
[]
(test/tests/userobjects/hexagonal_gap_layered/user_component.i)
gap_thickness = ${fparse 0.05 * 7.646e-3}
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'velocity'
[]
[AuxVariables]
[velocity_component]
[]
# These are just for visualizing the average velocity component with Glyphs in paraview;
# the result of the 'vol_avg' user object will be represented as a vector "uo_" with 3 components
[uo_x]
family = MONOMIAL
order = CONSTANT
[]
[uo_y]
family = MONOMIAL
order = CONSTANT
[]
[uo_z]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[velocity_component] # actual velocity component computed directly from interpolated nekRS velocity fields
type = ParsedAux
variable = velocity_component
expression = '(0.1*vel_x+0.2*vel_y+0.3*vel_z)/sqrt(0.1*0.1+0.2*0.2+0.3*0.3)'
coupled_variables = 'vel_x vel_y vel_z'
execute_on = 'timestep_end nonlinear linear'
[]
[uo_x]
type = NekSpatialBinComponentAux
variable = uo_x
user_object = avg_velocity_component
component = 0
[]
[uo_y]
type = NekSpatialBinComponentAux
variable = uo_y
user_object = avg_velocity_component
component = 1
[]
[uo_z]
type = NekSpatialBinComponentAux
variable = uo_z
user_object = avg_velocity_component
component = 2
[]
[]
[UserObjects]
[subchannel_binning]
type = HexagonalSubchannelGapBin
bundle_pitch = 0.02583914354890463
pin_pitch = 0.0089656996
pin_diameter = 7.646e-3
n_rings = 2
[]
[axial_binning]
type = LayeredBin
direction = z
num_layers = 6
[]
[avg_velocity_component]
type = NekBinnedPlaneAverage
bins = 'subchannel_binning axial_binning'
field = velocity_component
velocity_component = user
velocity_direction = '0.1 0.2 0.3'
gap_thickness = ${gap_thickness}
map_space_by_qp = true
[]
[]
[MultiApps]
[subchannel]
type = TransientMultiApp
input_files = 'subchannel_b.i'
execute_on = timestep_end
[]
[]
[Transfers]
[uo1_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_velocity_component
to_multi_app = subchannel
variable = avg_velocity_component
[]
[uox_to_sub]
type = MultiAppGeneralFieldNearestLocationTransfer
to_multi_app = subchannel
source_variable = uo_x
variable = uo_x
search_value_conflicts = false
[]
[uoy_to_sub]
type = MultiAppGeneralFieldNearestLocationTransfer
to_multi_app = subchannel
source_variable = uo_y
variable = uo_y
search_value_conflicts = false
[]
[uoz_to_sub]
type = MultiAppGeneralFieldNearestLocationTransfer
to_multi_app = subchannel
source_variable = uo_z
variable = uo_z
search_value_conflicts = false
[]
[actual_velocity_component]
type = MultiAppGeneralFieldNearestLocationTransfer
to_multi_app = subchannel
source_variable = velocity_component
variable = velocity_component
search_value_conflicts = false
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
[]
(test/tests/userobjects/sideset_layered/side_average.i)
[GlobalParams]
map_space_by_qp = true
check_boundary_restricted = false
[]
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature'
[]
[AuxVariables]
[avg_T_duct_wall]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[avg_T_duct_wall]
type = SpatialUserObjectAux
variable = avg_T_duct_wall
user_object = avg_T_duct_wall
boundary = '2'
[]
[]
[UserObjects]
[x]
type = LayeredBin
direction = x
num_layers = 2
[]
[y]
type = LayeredBin
direction = y
num_layers = 2
[]
[z]
type = LayeredBin
direction = z
num_layers = 3
[]
[avg_T_duct_wall]
type = NekBinnedSideAverage
bins = 'x y z'
field = temperature
boundary = '2'
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[VectorPostprocessors]
[temp_duct]
type = SpatialUserObjectVectorPostprocessor
userobject = avg_T_duct_wall
[]
[]
[Outputs]
csv = true
exodus = true
[]
(test/tests/userobjects/gap/nondimensional/nek.i)
[Mesh]
type = NekRSMesh
volume = true
scaling = 7.646e-3
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature pressure velocity'
nondimensional = true
L_ref = 7.646e-3
T_ref = 100.0
dT_ref = 50.0
U_ref = 2.0
rho_0 = 834.5
Cp_0 = 1228.0
[]
[AuxVariables]
[avg_T]
family = MONOMIAL
order = CONSTANT
[]
[avg_p]
family = MONOMIAL
order = CONSTANT
[]
[avg_v]
family = MONOMIAL
order = CONSTANT
[]
[integral_T]
family = MONOMIAL
order = CONSTANT
[]
[integral_p]
family = MONOMIAL
order = CONSTANT
[]
[integral_v]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[avg_T]
type = SpatialUserObjectAux
variable = avg_T
user_object = avg_T
[]
[avg_p]
type = SpatialUserObjectAux
variable = avg_p
user_object = avg_p
[]
[avg_v]
type = SpatialUserObjectAux
variable = avg_v
user_object = avg_v
[]
[integral_T]
type = SpatialUserObjectAux
variable = integral_T
user_object = integral_T
[]
[integral_p]
type = SpatialUserObjectAux
variable = integral_p
user_object = integral_p
[]
[integral_v]
type = SpatialUserObjectAux
variable = integral_v
user_object = integral_v
[]
[]
[UserObjects]
[subchannel_binning]
type = HexagonalSubchannelBin
bundle_pitch = 0.02583914354890463
pin_pitch = 0.0089656996
pin_diameter = 7.646e-3
n_rings = 2
[]
[axial_binning]
type = LayeredBin
direction = z
num_layers = 6
[]
[avg_T]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = temperature
[]
[avg_p]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = pressure
[]
[avg_v]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = velocity
[]
[integral_T]
type = NekBinnedVolumeIntegral
bins = 'subchannel_binning axial_binning'
field = temperature
[]
[integral_p]
type = NekBinnedVolumeIntegral
bins = 'subchannel_binning axial_binning'
field = pressure
[]
[integral_v]
type = NekBinnedVolumeIntegral
bins = 'subchannel_binning axial_binning'
field = velocity
[]
[]
[MultiApps]
[subchannel]
type = TransientMultiApp
input_files = 'subchannel.i'
execute_on = timestep_end
[]
[]
[Transfers]
[uo1_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_T
to_multi_app = subchannel
variable = avg_T
[]
[uo2_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_p
to_multi_app = subchannel
variable = avg_p
[]
[uo3_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_v
to_multi_app = subchannel
variable = avg_v
[]
[uo4_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = integral_T
to_multi_app = subchannel
variable = integral_T
[]
[uo5_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = integral_p
to_multi_app = subchannel
variable = integral_p
[]
[uo6_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = integral_v
to_multi_app = subchannel
variable = integral_v
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
[]
(tutorials/standalone/nek.i)
[Mesh]
type = NekRSMesh
volume = true
order = SECOND
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'turbPipe'
output = 'pressure velocity'
[]
[Postprocessors]
[outlet_p]
type = NekSideAverage
boundary = '2'
field = pressure
[]
[inlet_p]
type = NekSideAverage
boundary = '1'
field = pressure
[]
[mdot]
type = NekMassFluxWeightedSideIntegral
boundary = '1'
field = unity
[]
# subtracts the two pressure postprocessors
[dP]
type = DifferencePostprocessor
value1 = outlet_p
value2 = inlet_p
[]
[]
[UserObjects]
[axial_bins]
type = LayeredBin
direction = z
num_layers = 20
[]
[radial_bins]
type = RadialBin
vertical_axis = z
rmax = 0.5
nr = 12
growth_r = 0.9
[]
[volume_averages]
type = NekBinnedVolumeAverage
bins = 'radial_bins axial_bins'
field = velocity_z
map_space_by_qp = true
[]
[]
[AuxVariables]
[volume_averages]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[volume_averages]
type = SpatialUserObjectAux
variable = volume_averages
user_object = volume_averages
[]
[]
[MultiApps]
[sub]
type = TransientMultiApp
input_files = sub.i
execute_on = timestep_end
[]
[]
[Transfers]
[uo_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
to_multi_app = sub
source_user_object = volume_averages
variable = avg_velocity
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
csv = true
# this hides these values from the screen for neater output
hide = 'outlet_p inlet_p'
[]
(test/tests/userobjects/layered_layered/nek.i)
[Problem]
type = NekRSStandaloneProblem
casename = 'brick'
output = 'pressure'
nondimensional = true
L_ref = 2.0
U_ref = 1.0
rho_0 = 834.5
Cp_0 = 1228.0
T_ref = 573.0
dT_ref = 10.0
[]
[Mesh]
type = NekRSMesh
volume = true
scaling = 2.0
[]
[AuxVariables]
[bin_volumes]
family = MONOMIAL
order = CONSTANT
[]
[avg_p]
family = MONOMIAL
order = CONSTANT
[]
[total_volume]
family = MONOMIAL
order = CONSTANT
[]
[total_average_p]
family = MONOMIAL
order = CONSTANT
[]
# just for visualization of the binning
[x_bins]
family = MONOMIAL
order = CONSTANT
[]
[y_bins]
family = MONOMIAL
order = CONSTANT
[]
[z_bins]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
# just for visualization of the binning
[x_bins]
type = SpatialUserObjectAux
variable = x_bins
user_object = x_bins
execute_on = INITIAL
[]
[y_bins]
type = SpatialUserObjectAux
variable = y_bins
user_object = y_bins
execute_on = INITIAL
[]
[z_bins]
type = SpatialUserObjectAux
variable = z_bins
user_object = z_bins
execute_on = INITIAL
[]
[bin_volumes]
type = SpatialUserObjectAux
variable = bin_volumes
user_object = vol_integral
execute_on = 'INITIAL TIMESTEP_END'
[]
[avg_p]
type = SpatialUserObjectAux
variable = avg_p
user_object = avg_p
execute_on = 'INITIAL TIMESTEP_END'
[]
[total_volume]
type = SpatialUserObjectAux
variable = total_volume
user_object = reference_vol_integral
execute_on = 'INITIAL TIMESTEP_END'
[]
[total_average_p]
type = SpatialUserObjectAux
variable = total_average_p
user_object = reference_pressure_avg
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[UserObjects]
[x_bins]
type = LayeredBin
direction = x
num_layers = 3
[]
[y_bins]
type = LayeredBin
direction = y
num_layers = 3
[]
[z_bins]
type = LayeredBin
direction = z
num_layers = 12
[]
[vol_integral]
type = NekBinnedVolumeIntegral
bins = 'x_bins y_bins z_bins'
field = unity
[]
[avg_p]
type = NekBinnedVolumeAverage
bins = 'x_bins y_bins z_bins'
field = pressure
[]
[one_bin]
type = LayeredBin
direction = z
num_layers = 1
[]
[reference_vol_integral]
type = NekBinnedVolumeIntegral
bins = 'one_bin'
field = unity
[]
[reference_pressure_avg]
type = NekBinnedVolumeAverage
bins = 'one_bin'
field = pressure
[]
[]
[Postprocessors]
# we compare the integral (with a single bin) with an already-verified postprocessor
# to make sure the actual internals of the binned volume integral are done correctly
[volume_ref] # should match the value in 'total_volume' (computed with 1 bin)
type = NekVolumeIntegral
field = unity
[]
[avg_p_ref] # should match the value in 'total_average_p' (computed with 1 bin)
type = NekVolumeAverage
field = pressure
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
[]
(test/tests/userobjects/volume/dimensional/nek.i)
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature pressure velocity'
[]
[AuxVariables]
[avg_T]
family = MONOMIAL
order = CONSTANT
[]
[avg_p]
family = MONOMIAL
order = CONSTANT
[]
[avg_v]
family = MONOMIAL
order = CONSTANT
[]
[integral_T]
family = MONOMIAL
order = CONSTANT
[]
[integral_p]
family = MONOMIAL
order = CONSTANT
[]
[integral_v]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[avg_T]
type = SpatialUserObjectAux
variable = avg_T
user_object = avg_T
[]
[avg_p]
type = SpatialUserObjectAux
variable = avg_p
user_object = avg_p
[]
[avg_v]
type = SpatialUserObjectAux
variable = avg_v
user_object = avg_v
[]
[integral_T]
type = SpatialUserObjectAux
variable = integral_T
user_object = integral_T
[]
[integral_p]
type = SpatialUserObjectAux
variable = integral_p
user_object = integral_p
[]
[integral_v]
type = SpatialUserObjectAux
variable = integral_v
user_object = integral_v
[]
[]
[UserObjects]
[subchannel_binning]
type = HexagonalSubchannelBin
bundle_pitch = 0.02583914354890463
pin_pitch = 0.0089656996
pin_diameter = 7.646e-3
n_rings = 2
[]
[axial_binning]
type = LayeredBin
direction = z
num_layers = 6
[]
[avg_T]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = temperature
[]
[avg_p]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = pressure
[]
[avg_v]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = velocity
[]
[integral_T]
type = NekBinnedVolumeIntegral
bins = 'subchannel_binning axial_binning'
field = temperature
[]
[integral_p]
type = NekBinnedVolumeIntegral
bins = 'subchannel_binning axial_binning'
field = pressure
[]
[integral_v]
type = NekBinnedVolumeIntegral
bins = 'subchannel_binning axial_binning'
field = velocity
[]
[]
[MultiApps]
[subchannel]
type = TransientMultiApp
input_files = 'subchannel.i'
execute_on = timestep_end
[]
[]
[Transfers]
[uo1_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_T
to_multi_app = subchannel
variable = avg_T
[]
[uo2_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_p
to_multi_app = subchannel
variable = avg_p
[]
[uo3_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_v
to_multi_app = subchannel
variable = avg_v
[]
[uo4_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = integral_T
to_multi_app = subchannel
variable = integral_T
[]
[uo5_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = integral_p
to_multi_app = subchannel
variable = integral_p
[]
[uo6_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = integral_v
to_multi_app = subchannel
variable = integral_v
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
file_base = nek_dim
[]
(test/tests/userobjects/side/dimensional/nek.i)
[GlobalParams]
check_boundary_restricted = false
[]
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature pressure velocity'
[]
[AuxVariables]
[avg_T]
family = MONOMIAL
order = CONSTANT
[]
[avg_p]
family = MONOMIAL
order = CONSTANT
[]
[avg_v]
family = MONOMIAL
order = CONSTANT
[]
[integral_T]
family = MONOMIAL
order = CONSTANT
[]
[integral_p]
family = MONOMIAL
order = CONSTANT
[]
[integral_v]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[avg_T]
type = SpatialUserObjectAux
variable = avg_T
user_object = avg_T
boundary = '2'
[]
[avg_p]
type = SpatialUserObjectAux
variable = avg_p
user_object = avg_p
boundary = '2'
[]
[avg_v]
type = SpatialUserObjectAux
variable = avg_v
user_object = avg_v
boundary = '2'
[]
[integral_T]
type = SpatialUserObjectAux
variable = integral_T
user_object = integral_T
boundary = '2'
[]
[integral_p]
type = SpatialUserObjectAux
variable = integral_p
user_object = integral_p
boundary = '2'
[]
[integral_v]
type = SpatialUserObjectAux
variable = integral_v
user_object = integral_v
boundary = '2'
[]
[]
[UserObjects]
[x]
type = LayeredBin
direction = x
num_layers = 2
[]
[y]
type = LayeredBin
direction = y
num_layers = 2
[]
[z]
type = LayeredBin
direction = z
num_layers = 3
[]
[avg_T]
type = NekBinnedSideAverage
bins = 'x y z'
field = temperature
boundary = '2'
[]
[avg_p]
type = NekBinnedSideAverage
bins = 'x y z'
field = pressure
boundary = '2'
[]
[avg_v]
type = NekBinnedSideAverage
bins = 'x y z'
field = velocity
boundary = '2'
[]
[integral_T]
type = NekBinnedSideIntegral
bins = 'x y z'
field = temperature
boundary = '2'
[]
[integral_p]
type = NekBinnedSideIntegral
bins = 'x y z'
field = pressure
boundary = '2'
[]
[integral_v]
type = NekBinnedSideIntegral
bins = 'x y z'
field = velocity
boundary = '2'
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
file_base = nek_dim
[]
(test/tests/userobjects/layered_layered/3d.i)
[Problem]
type = NekRSStandaloneProblem
casename = 'brick'
output = 'pressure'
nondimensional = true
L_ref = 2.0
U_ref = 1.0
rho_0 = 834.5
Cp_0 = 1228.0
T_ref = 573.0
dT_ref = 10.0
[]
[Mesh]
type = NekRSMesh
volume = true
scaling = 2.0
[]
[AuxVariables]
[uo]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[uo]
type = SpatialUserObjectAux
variable = uo
user_object = vol_integral
[]
[]
[UserObjects]
[x_bins]
type = LayeredBin
direction = x
num_layers = 3
[]
[y_bins]
type = LayeredBin
direction = y
num_layers = 3
[]
[z_bins]
type = LayeredBin
direction = z
num_layers = 4
[]
[vol_integral]
type = NekBinnedVolumeIntegral
bins = 'x_bins y_bins z_bins'
field = pressure
[]
[]
[VectorPostprocessors]
# from_uo gives exactly the same results as manually specifying the points in 'manually_provided'
[from_uo]
type = SpatialUserObjectVectorPostprocessor
userobject = vol_integral
[]
[manually_provided]
type = SpatialUserObjectVectorPostprocessor
userobject = vol_integral
points = '-0.66666667 -0.66666667 -3.0
-0.66666667 -0.66666667 -1.0
-0.66666667 -0.66666667 1.0
-0.66666667 -0.66666667 3.0
-0.66666667 0.0 -3.0
-0.66666667 0.0 -1.0
-0.66666667 0.0 1.0
-0.66666667 0.0 3.0
-0.66666667 0.66666667 -3.0
-0.66666667 0.66666667 -1.0
-0.66666667 0.66666667 1.0
-0.66666667 0.66666667 3.0
0.0 -0.66666667 -3.0
0.0 -0.66666667 -1.0
0.0 -0.66666667 1.0
0.0 -0.66666667 3.0
0.0 0.0 -3.0
0.0 0.0 -1.0
0.0 0.0 1.0
0.0 0.0 3.0
0.0 0.66666667 -3.0
0.0 0.66666667 -1.0
0.0 0.66666667 1.0
0.0 0.66666667 3.0
0.66666667 -0.66666667 -3.0
0.66666667 -0.66666667 -1.0
0.66666667 -0.66666667 1.0
0.66666667 -0.66666667 3.0
0.66666667 0.0 -3.0
0.66666667 0.0 -1.0
0.66666667 0.0 1.0
0.66666667 0.0 3.0
0.66666667 0.66666667 -3.0
0.66666667 0.66666667 -1.0
0.66666667 0.66666667 1.0
0.66666667 0.66666667 3.0'
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
csv = true
exodus = true
execute_on = 'final'
[]
(test/tests/userobjects/subchannel_layered/nek.i)
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature'
[]
[AuxVariables]
[subchannel_bins]
family = MONOMIAL
order = CONSTANT
[]
[axial_bins]
family = MONOMIAL
order = CONSTANT
[]
[total_volume]
family = MONOMIAL
order = CONSTANT
[]
[total_average_T]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[bins1]
type = SpatialUserObjectAux
variable = subchannel_bins
user_object = subchannel_binning
[]
[bins2]
type = SpatialUserObjectAux
variable = axial_bins
user_object = axial_binning
[]
[total_volume]
type = SpatialUserObjectAux
variable = total_volume
user_object = reference_vol_integral
execute_on = 'INITIAL TIMESTEP_END'
[]
[total_average_T]
type = SpatialUserObjectAux
variable = total_average_T
user_object = reference_T_avg
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[UserObjects]
[subchannel_binning]
type = HexagonalSubchannelBin
bundle_pitch = 0.02583914354890463
pin_pitch = 0.0089656996
pin_diameter = 7.646e-3
n_rings = 2
[]
[axial_binning]
type = LayeredBin
direction = z
num_layers = 6
[]
[vol_avg]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = temperature
[]
[vol_integral]
type = NekBinnedVolumeIntegral
bins = 'subchannel_binning axial_binning'
field = unity
[]
[one_bin]
type = LayeredBin
direction = z
num_layers = 1
[]
[reference_vol_integral]
type = NekBinnedVolumeIntegral
bins = 'one_bin'
field = unity
[]
[reference_T_avg]
type = NekBinnedVolumeAverage
bins = 'one_bin'
field = temperature
[]
[]
[MultiApps]
[subchannel]
type = TransientMultiApp
input_files = 'subchannel.i'
execute_on = timestep_end
[]
[]
[Transfers]
[uo1_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = vol_avg
to_multi_app = subchannel
variable = vol_avg
[]
[uo2_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = vol_integral
to_multi_app = subchannel
variable = vol_integral
[]
[]
[Postprocessors]
# we compare the integral (with a single bin) with an already-verified postprocessor
# to make sure the actual internals of the binned volume integral are done correctly
[volume_ref] # should match the value in 'total_volume' (computed with 1 bin)
type = NekVolumeIntegral
field = unity
[]
[avg_T_ref] # should match the value in 'total_average_T' (computed with 1 bin)
type = NekVolumeAverage
field = temperature
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
hide = 'temp'
[]
(test/tests/userobjects/side/nondimensional/nek.i)
[GlobalParams]
check_boundary_restricted = false
[]
[Mesh]
type = NekRSMesh
volume = true
scaling = 7.646e-3
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature pressure velocity'
nondimensional = true
L_ref = 7.646e-3
T_ref = 100.0
dT_ref = 50.0
U_ref = 2.0
rho_0 = 834.5
Cp_0 = 1228.0
[]
[AuxVariables]
[avg_T]
family = MONOMIAL
order = CONSTANT
[]
[avg_p]
family = MONOMIAL
order = CONSTANT
[]
[avg_v]
family = MONOMIAL
order = CONSTANT
[]
[integral_T]
family = MONOMIAL
order = CONSTANT
[]
[integral_p]
family = MONOMIAL
order = CONSTANT
[]
[integral_v]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[avg_T]
type = SpatialUserObjectAux
variable = avg_T
user_object = avg_T
boundary = '2'
[]
[avg_p]
type = SpatialUserObjectAux
variable = avg_p
user_object = avg_p
boundary = '2'
[]
[avg_v]
type = SpatialUserObjectAux
variable = avg_v
user_object = avg_v
boundary = '2'
[]
[integral_T]
type = SpatialUserObjectAux
variable = integral_T
user_object = integral_T
boundary = '2'
[]
[integral_p]
type = SpatialUserObjectAux
variable = integral_p
user_object = integral_p
boundary = '2'
[]
[integral_v]
type = SpatialUserObjectAux
variable = integral_v
user_object = integral_v
boundary = '2'
[]
[]
[UserObjects]
[x]
type = LayeredBin
direction = x
num_layers = 2
[]
[y]
type = LayeredBin
direction = y
num_layers = 2
[]
[z]
type = LayeredBin
direction = z
num_layers = 3
[]
[avg_T]
type = NekBinnedSideAverage
bins = 'x y z'
field = temperature
boundary = '2'
[]
[avg_p]
type = NekBinnedSideAverage
bins = 'x y z'
field = pressure
boundary = '2'
[]
[avg_v]
type = NekBinnedSideAverage
bins = 'x y z'
field = velocity
boundary = '2'
[]
[integral_T]
type = NekBinnedSideIntegral
bins = 'x y z'
field = temperature
boundary = '2'
[]
[integral_p]
type = NekBinnedSideIntegral
bins = 'x y z'
field = pressure
boundary = '2'
[]
[integral_v]
type = NekBinnedSideIntegral
bins = 'x y z'
field = velocity
boundary = '2'
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
[]
(test/tests/userobjects/subchannel_layered/duplicate_directions.i)
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
[]
[UserObjects]
[subchannel_binning]
type = HexagonalSubchannelBin
bundle_pitch = 0.02583914354890463
pin_pitch = 0.0089656996
pin_diameter = 7.646e-3
n_rings = 2
[]
[axial_binning]
type = LayeredBin
direction = z
num_layers = 6
[]
[x_bins]
type = LayeredBin
direction = x
num_layers = 3
[]
# should error due to duplicate bins
[vol_avg]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning x_bins'
field = temperature
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
[]
(test/tests/userobjects/subchannel_layered/wrong_type.i)
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature'
[]
[UserObjects]
[subchannel_binning]
type = HexagonalSubchannelGapBin
bundle_pitch = 0.02583914354890463
pin_pitch = 0.0089656996
pin_diameter = 7.646e-3
n_rings = 2
[]
[axial_binning]
type = LayeredBin
direction = z
num_layers = 6
[]
[vol_avg]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = temperature
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
[]
(test/tests/userobjects/volume/nondimensional/nek.i)
[Mesh]
type = NekRSMesh
volume = true
scaling = 7.646e-3
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature pressure velocity'
nondimensional = true
L_ref = 7.646e-3
T_ref = 100.0
dT_ref = 50.0
U_ref = 2.0
rho_0 = 834.5
Cp_0 = 1228.0
[]
[AuxVariables]
[avg_T]
family = MONOMIAL
order = CONSTANT
[]
[avg_p]
family = MONOMIAL
order = CONSTANT
[]
[avg_v]
family = MONOMIAL
order = CONSTANT
[]
[integral_T]
family = MONOMIAL
order = CONSTANT
[]
[integral_p]
family = MONOMIAL
order = CONSTANT
[]
[integral_v]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[avg_T]
type = SpatialUserObjectAux
variable = avg_T
user_object = avg_T
[]
[avg_p]
type = SpatialUserObjectAux
variable = avg_p
user_object = avg_p
[]
[avg_v]
type = SpatialUserObjectAux
variable = avg_v
user_object = avg_v
[]
[integral_T]
type = SpatialUserObjectAux
variable = integral_T
user_object = integral_T
[]
[integral_p]
type = SpatialUserObjectAux
variable = integral_p
user_object = integral_p
[]
[integral_v]
type = SpatialUserObjectAux
variable = integral_v
user_object = integral_v
[]
[]
[UserObjects]
[subchannel_binning]
type = HexagonalSubchannelBin
bundle_pitch = 0.02583914354890463
pin_pitch = 0.0089656996
pin_diameter = 7.646e-3
n_rings = 2
[]
[axial_binning]
type = LayeredBin
direction = z
num_layers = 6
[]
[avg_T]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = temperature
[]
[avg_p]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = pressure
[]
[avg_v]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = velocity
[]
[integral_T]
type = NekBinnedVolumeIntegral
bins = 'subchannel_binning axial_binning'
field = temperature
[]
[integral_p]
type = NekBinnedVolumeIntegral
bins = 'subchannel_binning axial_binning'
field = pressure
[]
[integral_v]
type = NekBinnedVolumeIntegral
bins = 'subchannel_binning axial_binning'
field = velocity
[]
[]
[MultiApps]
[subchannel]
type = TransientMultiApp
input_files = 'subchannel.i'
execute_on = timestep_end
[]
[]
[Transfers]
[uo1_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_T
to_multi_app = subchannel
variable = avg_T
[]
[uo2_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_p
to_multi_app = subchannel
variable = avg_p
[]
[uo3_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_v
to_multi_app = subchannel
variable = avg_v
[]
[uo4_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = integral_T
to_multi_app = subchannel
variable = integral_T
[]
[uo5_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = integral_p
to_multi_app = subchannel
variable = integral_p
[]
[uo6_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = integral_v
to_multi_app = subchannel
variable = integral_v
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
[]
(test/tests/userobjects/hexagonal_gap_layered/normals/nek.i)
gap_thickness = ${fparse 0.05 * 7.646e-3}
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'velocity'
[]
[AuxVariables]
# These are just for visualizing the average velocity component with Glyphs in paraview;
# the result of the 'vol_avg' user object will be represented as a vector "uo_" with 3 components
[uo_x]
family = MONOMIAL
order = CONSTANT
[]
[uo_y]
family = MONOMIAL
order = CONSTANT
[]
[uo_z]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[uo_x]
type = NekSpatialBinComponentAux
variable = uo_x
user_object = avg_velocity_component
component = 0
[]
[uo_y]
type = NekSpatialBinComponentAux
variable = uo_y
user_object = avg_velocity_component
component = 1
[]
[uo_z]
type = NekSpatialBinComponentAux
variable = uo_z
user_object = avg_velocity_component
component = 2
[]
[]
[UserObjects]
[subchannel_binning]
type = HexagonalSubchannelGapBin
bundle_pitch = 0.02583914354890463
pin_pitch = 0.0089656996
pin_diameter = 7.646e-3
n_rings = 2
[]
[axial_binning]
type = LayeredBin
direction = z
num_layers = 6
[]
[avg_velocity_component]
type = NekBinnedPlaneAverage
bins = 'subchannel_binning'
field = velocity_component
velocity_component = normal
gap_thickness = ${gap_thickness}
map_space_by_qp = true
[]
[]
[MultiApps]
[subchannel]
type = TransientMultiApp
input_files = 'subchannel.i'
execute_on = timestep_end
[]
[]
[Transfers]
[uo1_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_velocity_component
to_multi_app = subchannel
variable = avg_velocity_component
[]
[uox_to_sub]
type = MultiAppGeneralFieldNearestLocationTransfer
to_multi_app = subchannel
source_variable = uo_x
variable = uo_x
search_value_conflicts = false
[]
[uoy_to_sub]
type = MultiAppGeneralFieldNearestLocationTransfer
to_multi_app = subchannel
source_variable = uo_y
variable = uo_y
search_value_conflicts = false
[]
[uoz_to_sub]
type = MultiAppGeneralFieldNearestLocationTransfer
to_multi_app = subchannel
source_variable = uo_z
variable = uo_z
search_value_conflicts = false
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
[]
(test/tests/userobjects/sideset_layered/invalid_boundary.i)
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature'
[]
[UserObjects]
[x]
type = LayeredBin
direction = x
num_layers = 3
[]
[vol_avg]
type = NekBinnedSideIntegral
bins = 'x'
field = temperature
boundary = '5'
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
[]
(test/tests/userobjects/gap/dimensional/nek.i)
[Mesh]
type = NekRSMesh
volume = true
[]
[Problem]
type = NekRSStandaloneProblem
casename = 'sfr_7pin'
output = 'temperature pressure velocity'
[]
[AuxVariables]
[area]
family = MONOMIAL
order = CONSTANT
[]
[avg_T]
family = MONOMIAL
order = CONSTANT
[]
[avg_p]
family = MONOMIAL
order = CONSTANT
[]
[avg_v]
family = MONOMIAL
order = CONSTANT
[]
[integral_T]
family = MONOMIAL
order = CONSTANT
[]
[integral_p]
family = MONOMIAL
order = CONSTANT
[]
[integral_v]
family = MONOMIAL
order = CONSTANT
[]
[]
[AuxKernels]
[area]
type = SpatialUserObjectAux
variable = area
user_object = area
[]
[avg_T]
type = SpatialUserObjectAux
variable = avg_T
user_object = avg_T
[]
[avg_p]
type = SpatialUserObjectAux
variable = avg_p
user_object = avg_p
[]
[avg_v]
type = SpatialUserObjectAux
variable = avg_v
user_object = avg_v
[]
[integral_T]
type = SpatialUserObjectAux
variable = integral_T
user_object = integral_T
[]
[integral_p]
type = SpatialUserObjectAux
variable = integral_p
user_object = integral_p
[]
[integral_v]
type = SpatialUserObjectAux
variable = integral_v
user_object = integral_v
[]
[]
[UserObjects]
[subchannel_binning]
type = HexagonalSubchannelBin
bundle_pitch = 0.02583914354890463
pin_pitch = 0.0089656996
pin_diameter = 7.646e-3
n_rings = 2
[]
[axial_binning]
type = LayeredBin
direction = z
num_layers = 6
[]
[area]
type = NekBinnedVolumeIntegral
bins = 'subchannel_binning axial_binning'
field = unity
[]
[avg_T]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = temperature
[]
[avg_p]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = pressure
[]
[avg_v]
type = NekBinnedVolumeAverage
bins = 'subchannel_binning axial_binning'
field = velocity
[]
[integral_T]
type = NekBinnedVolumeIntegral
bins = 'subchannel_binning axial_binning'
field = temperature
[]
[integral_p]
type = NekBinnedVolumeIntegral
bins = 'subchannel_binning axial_binning'
field = pressure
[]
[integral_v]
type = NekBinnedVolumeIntegral
bins = 'subchannel_binning axial_binning'
field = velocity
[]
[]
[MultiApps]
[subchannel]
type = TransientMultiApp
input_files = 'subchannel.i'
execute_on = timestep_end
[]
[]
[Transfers]
[uo1_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_T
to_multi_app = subchannel
variable = avg_T
[]
[uo2_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_p
to_multi_app = subchannel
variable = avg_p
[]
[uo3_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = avg_v
to_multi_app = subchannel
variable = avg_v
[]
[uo4_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = integral_T
to_multi_app = subchannel
variable = integral_T
[]
[uo5_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = integral_p
to_multi_app = subchannel
variable = integral_p
[]
[uo6_to_sub]
type = MultiAppGeneralFieldUserObjectTransfer
source_user_object = integral_v
to_multi_app = subchannel
variable = integral_v
[]
[]
[Executioner]
type = Transient
[TimeStepper]
type = NekTimeStepper
[]
[]
[Outputs]
exodus = true
file_base = nek_dim
[]