Skip to content

Commit

Permalink
added test for min/max limiting parameters of PIDTransientControl ida…
Browse files Browse the repository at this point in the history
  • Loading branch information
jthano committed Feb 5, 2024
1 parent 972d3b7 commit 936c27c
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 1 deletion.
12 changes: 12 additions & 0 deletions test/tests/controls/pid_control/gold/min_max_limits.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
time,integral,left_boundary_average
0,0,0
1,2.5,4
2,2.2000000004855,3.4
3,1.7149999973564,2.4299999989804
4,1.4999999999331,2
5,1.5,2
6,1.5,2
7,1.5,2
8,1.5,2
9,1.5,2
10,1.5,2
6 changes: 6 additions & 0 deletions test/tests/controls/pid_control/pid_control.i
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,12 @@ c = 0
variable = u
execute_on = 'initial timestep_end'
[]
[left_boundary_average]
type = SideAverageValue
variable = u
boundary = 3
execute_on = 'initial timestep_end'
[]
[]

[Controls]
Expand Down
14 changes: 13 additions & 1 deletion test/tests/controls/pid_control/tests
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,19 @@
input = 'pid_control.i'
csvdiff = 'out.csv'
recover = false
# Not ouputting left_boundary_average to avoid regold
cli_args = 'Postprocessors/left_boundary_average/outputs=none'
detail = 'using the principle of Proportional Integral Derivative control,'
[]
[min_max_limits]
type = 'CSVDiff'
input = 'pid_control.i'
csvdiff = 'min_max_limits.csv'
recover = false
# Not ouputting left_boundary_average to avoid regold
cli_args = 'Outputs/file_base=min_max_limits Controls/integral_value/maximum_output_value=4.0 Controls/integral_value/minimum_output_value=2.0 Executioner/nl_abs_tol=1e-12 Executioner/end_time=10'
detail = 'allowing the Proportional Integral Derivative control to have limits for its maximum and minimum output,'
[]
[basic_postprocessor]
type = 'CSVDiff'
input = 'pid_pp_control.i'
Expand All @@ -23,7 +34,8 @@
input = 'pid_control.i'
csvdiff = 'windup_out.csv'
recover = false
cli_args = 'Outputs/file_base=windup_out Controls/integral_value/reset_integral_windup=true'
# Not ouputting left_boundary_average to avoid regold
cli_args = 'Outputs/file_base=windup_out Controls/integral_value/reset_integral_windup=true Postprocessors/left_boundary_average/outputs=none'
detail = 'with integral windup control, resetting the integral term if the error crosses zero,'
[]
[picard]
Expand Down

0 comments on commit 936c27c

Please sign in to comment.