CoarsenedPiecewiseLinear

Perform a point reduction of the tabulated data upon initialization, then evaluate using a linear interpolation.

Description

The CoarsenedPiecewiseLinear performs preprocessing and linear interpolation on an x/y data set. The object acts like PiecewiseLinear except that it reduces the number of function point at the start of the simulation. It uses the Ramer-Douglas-Peucker algorithm for data reduction.

Example Input Syntax

[Functions]
  [./ic_function]
    type = PiecewiseLinear
    data_file = piecewise_linear_columns.csv #Will generate error because data is expected in rows
    scale_factor = 1.0
  [../]
[]
(moose/test/tests/misc/check_error/function_file_test1.i)

Input Parameters

  • epsilonSignificant distance in the function below which points are considered removable noise

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Significant distance in the function below which points are considered removable noise

Required Parameters

  • axisThe axis used (x, y, or z) if this is to be a function of position

    C++ Type:MooseEnum

    Unit:(no unit assumed)

    Options:x, y, z

    Controllable:No

    Description:The axis used (x, y, or z) if this is to be a function of position

  • scale_factor1Scale factor to be applied to the ordinate values

    Default:1

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:Yes

    Description:Scale factor to be applied to the ordinate values

  • x_scale1Scaling factor to apply to the function nodes for the purpose of computing distances in the Douglas-Peucker point reduction algorithm. This permits shifting the weight between x and y-direction distances.

    Default:1

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Scaling factor to apply to the function nodes for the purpose of computing distances in the Douglas-Peucker point reduction algorithm. This permits shifting the weight between x and y-direction distances.

  • y_scale1Scaling factor to apply to the function nodes for the purpose of computing distances in the Douglas-Peucker point reduction algorithm. This permits shifting the weight between x and y-direction distances.

    Default:1

    C++ Type:double

    Unit:(no unit assumed)

    Controllable:No

    Description:Scaling factor to apply to the function nodes for the purpose of computing distances in the Douglas-Peucker point reduction algorithm. This permits shifting the weight between x and y-direction distances.

Optional Parameters

  • control_tagsAdds user-defined labels for accessing object parameters via control logic.

    C++ Type:std::vector<std::string>

    Unit:(no unit assumed)

    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

    Unit:(no unit assumed)

    Controllable:No

    Description:Set the enabled status of the MooseObject.

Advanced Parameters

  • data_fileFile holding CSV data

    C++ Type:FileName

    Unit:(no unit assumed)

    Controllable:No

    Description:File holding CSV data

  • formatrowsFormat of csv data file that is in either in columns or rows

    Default:rows

    C++ Type:MooseEnum

    Unit:(no unit assumed)

    Options:columns, rows

    Controllable:No

    Description:Format of csv data file that is in either in columns or rows

  • x_index_in_file0The abscissa index in the data file

    Default:0

    C++ Type:unsigned int

    Unit:(no unit assumed)

    Controllable:No

    Description:The abscissa index in the data file

  • x_titleThe title of the column/row containing the x data in the data file

    C++ Type:std::string

    Unit:(no unit assumed)

    Controllable:No

    Description:The title of the column/row containing the x data in the data file

  • xy_in_file_onlyTrueIf the data file only contains abscissa and ordinate data

    Default:True

    C++ Type:bool

    Unit:(no unit assumed)

    Controllable:No

    Description:If the data file only contains abscissa and ordinate data

  • y_index_in_file1The ordinate index in the data file

    Default:1

    C++ Type:unsigned int

    Unit:(no unit assumed)

    Controllable:No

    Description:The ordinate index in the data file

  • y_titleThe title of the column/row containing the y data in the data file

    C++ Type:std::string

    Unit:(no unit assumed)

    Controllable:No

    Description:The title of the column/row containing the y data in the data file

Data From Csv File Parameters

  • json_uoJSONFileReader holding the data

    C++ Type:UserObjectName

    Unit:(no unit assumed)

    Controllable:No

    Description:JSONFileReader holding the data

  • x_keysOrdered vector of keys in the JSON tree to obtain the abscissa

    C++ Type:std::vector<std::string>

    Unit:(no unit assumed)

    Controllable:No

    Description:Ordered vector of keys in the JSON tree to obtain the abscissa

  • y_keysOrdered vector of keys in the JSON tree to obtain the ordinate

    C++ Type:std::vector<std::string>

    Unit:(no unit assumed)

    Controllable:No

    Description:Ordered vector of keys in the JSON tree to obtain the ordinate

Data From Json Parameters

  • xThe abscissa values

    C++ Type:std::vector<double>

    Unit:(no unit assumed)

    Controllable:No

    Description:The abscissa values

  • xy_dataAll function data, supplied in abscissa, ordinate pairs

    C++ Type:std::vector<double>

    Unit:(no unit assumed)

    Controllable:No

    Description:All function data, supplied in abscissa, ordinate pairs

  • yThe ordinate values

    C++ Type:std::vector<double>

    Unit:(no unit assumed)

    Controllable:No

    Description:The ordinate values

Data From Input File Parameters