- argument_columnVectorPostprocessor column tabulating the abscissa of the sampled function
C++ Type:std::string
Controllable:No
Description:VectorPostprocessor column tabulating the abscissa of the sampled function
- value_columnVectorPostprocessor column tabulating the ordinate (function values) of the sampled function
C++ Type:std::string
Controllable:No
Description:VectorPostprocessor column tabulating the ordinate (function values) of the sampled function
- vectorpostprocessor_nameThe name of the VectorPostprocessor that you want to use
C++ Type:VectorPostprocessorName
Unit:(no unit assumed)
Controllable:No
Description:The name of the VectorPostprocessor that you want to use
PiecewiseLinearFromVectorPostprocessor
Provides piecewise linear interpolation of from two columns of a VectorPostprocessor
Description
The PiecewiseLinearFromVectorPostprocessor
function performs linear interpolations between pairs of data generated by a vector post-processor object. The abscissa ("argument_column") and the ordinate ("value_column") values should correspond to the names of member vectors of the object specified for the "vectorpostprocessor_name" parameter. By default, the abscissa values correspond to time, and the data will be interpolated at the actual simulation time-step values. However, it is possible to interpolate over spatial (x, y, or z) coordinates by specifying a direction with the "component" parameter, where the inputs, 0
, 1
, and 2
, correspond to the x
, y
, and z
directions, respectively.
Example Input Syntax
In this example, three PiecewiseLinearFromVectorPostprocessor
s are created and take data from three distinct vector postprocessors. All three functions use a "component" parameter, which is set so they are functions of space rather than time (y for first two, x for the last one).
[Functions<<<{"href": "../../syntax/Functions/index.html"}>>>]
[ramp_u]
type = ParsedFunction<<<{"description": "Function created by parsing a string", "href": "MooseParsedFunction.html"}>>>
expression<<<{"description": "The user defined function."}>>> = 't'
[]
[point_value_function_u]
type = VectorPostprocessorFunction<<<{"description": "Provides piecewise linear interpolation of from two columns of a VectorPostprocessor", "href": "PiecewiseLinearFromVectorPostprocessor.html"}>>>
component<<<{"description": "Component of the function evaluation point used to sample the VectorPostprocessor"}>>> = y
argument_column<<<{"description": "VectorPostprocessor column tabulating the abscissa of the sampled function"}>>> = y
value_column<<<{"description": "VectorPostprocessor column tabulating the ordinate (function values) of the sampled function"}>>> = u
vectorpostprocessor_name<<<{"description": "The name of the VectorPostprocessor that you want to use"}>>> = point_value_vector_postprocessor_u
[]
[line_value_function_v]
type = VectorPostprocessorFunction<<<{"description": "Provides piecewise linear interpolation of from two columns of a VectorPostprocessor", "href": "PiecewiseLinearFromVectorPostprocessor.html"}>>>
component<<<{"description": "Component of the function evaluation point used to sample the VectorPostprocessor"}>>> = y
argument_column<<<{"description": "VectorPostprocessor column tabulating the abscissa of the sampled function"}>>> = y
value_column<<<{"description": "VectorPostprocessor column tabulating the ordinate (function values) of the sampled function"}>>> = v
vectorpostprocessor_name<<<{"description": "The name of the VectorPostprocessor that you want to use"}>>> = line_value_vector_postprocessor_v
[]
[test_parallel_func]
type = VectorPostprocessorFunction<<<{"description": "Provides piecewise linear interpolation of from two columns of a VectorPostprocessor", "href": "PiecewiseLinearFromVectorPostprocessor.html"}>>>
component<<<{"description": "Component of the function evaluation point used to sample the VectorPostprocessor"}>>> = x
argument_column<<<{"description": "VectorPostprocessor column tabulating the abscissa of the sampled function"}>>> = xx
value_column<<<{"description": "VectorPostprocessor column tabulating the ordinate (function values) of the sampled function"}>>> = qq
vectorpostprocessor_name<<<{"description": "The name of the VectorPostprocessor that you want to use"}>>> = test_parallel_vpp
[]
[function_v]
type = PiecewiseLinear<<<{"description": "Linearly interpolates between pairs of x-y data", "href": "PiecewiseLinear.html"}>>>
x<<<{"description": "The abscissa values"}>>> = '0 0.008'
y<<<{"description": "The ordinate values"}>>> = '1 2'
axis<<<{"description": "The axis used (x, y, or z) if this is to be a function of position"}>>> = y
[]
[]
[VectorPostprocessors<<<{"href": "../../syntax/VectorPostprocessors/index.html"}>>>]
[point_value_vector_postprocessor_u]
type = PointValueSampler<<<{"description": "Sample a variable at specific points.", "href": "../vectorpostprocessors/PointValueSampler.html"}>>>
variable<<<{"description": "The names of the variables that this VectorPostprocessor operates on"}>>> = u
points<<<{"description": "The points where you want to evaluate the variables"}>>> = '0 0.001 0 0 0.004 0 0 0.008 0'
#points = '0.001 0 0 0.002 0 0'
sort_by<<<{"description": "What to sort the samples by"}>>> = y
execute_on<<<{"description": "The list of flag(s) indicating when this object should be executed. For a description of each flag, see https://mooseframework.inl.gov/source/interfaces/SetupInterface.html."}>>> = linear
[]
[line_value_vector_postprocessor_v]
type = LineValueSampler<<<{"description": "Samples variable(s) along a specified line", "href": "../vectorpostprocessors/LineValueSampler.html"}>>>
variable<<<{"description": "The names of the variables that this VectorPostprocessor operates on"}>>> = v
start_point<<<{"description": "The beginning of the line"}>>> = '0 0.001 0'
end_point<<<{"description": "The ending of the line"}>>> = '0 0.008 0'
num_points<<<{"description": "The number of points to sample along the line"}>>> = 5
sort_by<<<{"description": "What to sort the samples by"}>>> = y
execute_on<<<{"description": "The list of flag(s) indicating when this object should be executed. For a description of each flag, see https://mooseframework.inl.gov/source/interfaces/SetupInterface.html."}>>> = linear
[]
[test_parallel_vpp]
type = ConstantVectorPostprocessor<<<{"description": "Populate constant VectorPostprocessorValue directly from input file.", "href": "../vectorpostprocessors/ConstantVectorPostprocessor.html"}>>>
vector_names<<<{"description": "Names of the column vectors in this object"}>>> = 'xx qq'
value<<<{"description": "Vector values this object will have. Leading dimension must be equal to leading dimension of vector_names parameter."}>>> = '0 1;
1000 1000'
execute_on<<<{"description": "The list of flag(s) indicating when this object should be executed. For a description of each flag, see https://mooseframework.inl.gov/source/interfaces/SetupInterface.html."}>>> = 'initial timestep_begin'
[]
[]
(moose/test/tests/functions/piecewise_linear_from_vectorpostprocessor/vector_postprocessor_function.i)Input Parameters
- componenttimeComponent of the function evaluation point used to sample the VectorPostprocessor
Default:time
C++ Type:MooseEnum
Controllable:No
Description:Component of the function evaluation point used to sample the VectorPostprocessor
- parallel_syncTrueWhether or not this Function should be synced to all processors when running in parallel.
Default:True
C++ Type:bool
Controllable:No
Description:Whether or not this Function should be synced to all processors when running in parallel.
Optional Parameters
- 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:No
Description:Set the enabled status of the MooseObject.