Skip to content

Commit

Permalink
Removing unused dirac kernel #12
Browse files Browse the repository at this point in the history
  • Loading branch information
zachmprince authored and dschwen committed Sep 2, 2022
1 parent aacc681 commit 67b9b43
Show file tree
Hide file tree
Showing 5 changed files with 62 additions and 126 deletions.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,12 @@ function_vals = '100 1 -10 -10'

[DiracKernels]
[pt]
type = OptimizationDataPointSource
type = ReporterPointSource
variable = temperature
points = misfit/measurement_points
values = misfit/misfit_values
x_coord_name = misfit/measurement_xcoord
y_coord_name = misfit/measurement_ycoord
z_coord_name = misfit/measurement_zcoord
value_name = misfit/misfit_values
[]
[]

Expand Down Expand Up @@ -143,6 +145,13 @@ function_vals = '100 1 -10 -10'
[]

[VectorPostprocessors]
[point_source]
type = ConstantVectorPostprocessor
vector_names = 'x y z value'
# value = '0.2 0.5 1.5 1.8; 0.5 0.5 0.5 0.5; 0 0 0 0; 10 10 10 10'
value = '0.2 0.5 1.5 1.8 0.3 0.6 0.9 1.2;0.5 0.5 0.5 0.5 1.1 1.1 1.1 1.1;0 0 0 0 0 0 0 0;10 10 10 10 10 10 10 10'
execute_on = LINEAR
[]
[adjoint_pt]
type = VectorOfPostprocessors
postprocessors = 'adjoint_pt_0 adjoint_pt_1 adjoint_pt_2 adjoint_pt_3'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@
variable = temperature
[]
[./heat_source]
type = MatHeatSource
material_property = volumetric_heat
type = HeatSource
function = volumetric_heat_func
variable = temperature
[../]
[]
Expand Down Expand Up @@ -66,11 +66,6 @@
prop_names = thermal_conductivity
prop_values = 5
[]
[volumetric_heat]
type = GenericFunctionMaterial
prop_names = 'volumetric_heat'
prop_values = volumetric_heat_func
[]
[]

[Executioner]
Expand All @@ -82,6 +77,36 @@
petsc_options_value = 'hypre boomeramg'
[]

[VectorPostprocessors]
[data_pt]
type = VppPointValueSampler
variable = temperature
reporter_name = measure_data
[]
[horizontal]
type = LineValueSampler
variable = 'temperature'
start_point = '0 0.5 0'
end_point = '2 0.5 0'
num_points = 21
sort_by = x
[../]
[horizontal2]
type = LineValueSampler
variable = 'temperature'
start_point = '0 1.1 0'
end_point = '2 1.1 0'
num_points = 21
sort_by = x
[../]
[]

[Reporters]
[measure_data]
type=OptimizationData
[]
[]

[Outputs]
exodus = true
file_base = 'forward'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@
parameter_names = 'parameter_results'
num_values = '4'
initial_condition = '100 1 -10 -10'
points = '0.2 0.2 0
0.8 0.6 0
0.2 1.4 0
0.8 1.8 0'
measured_values = '209 218 164 121'
measurement_points = '0.2 0.2 0
0.8 0.6 0
0.2 1.4 0
0.8 1.8 0'
measurement_values = '209 218 164 121'
[]

[Executioner]
Expand Down Expand Up @@ -59,22 +59,29 @@
multi_app = forward
direction = from_multiapp
#the second vector in the reporterTransfer just writes to teh constantReporter below for the csvDiff in the test file
from_reporters = 'data_pt/temperature data_pt/temperature'
to_reporters = 'OptimizationReporter/simulation_values receiver/measured'
from_reporters = 'data_pt/temperature'
to_reporters = 'OptimizationReporter/simulation_values'
[]
[toAdjoint]
type = MultiAppReporterTransfer
multi_app = adjoint
direction = to_multiapp
from_reporters = 'OptimizationReporter/measurement_points OptimizationReporter/misfit_values'
to_reporters = 'misfit/measurement_points misfit/misfit_values'
from_reporters = 'OptimizationReporter/measurement_xcoord OptimizationReporter/measurement_ycoord OptimizationReporter/measurement_zcoord OptimizationReporter/misfit_values'
to_reporters = 'misfit/measurement_xcoord misfit/measurement_ycoord misfit/measurement_zcoord misfit/misfit_values'
[]
[fromAdjoint]
[toForward_measument]
type = MultiAppReporterTransfer
multi_app = forward
direction = to_multiapp
from_reporters = 'OptimizationReporter/measurement_xcoord OptimizationReporter/measurement_ycoord OptimizationReporter/measurement_zcoord'
to_reporters = 'measure_data/measurement_xcoord measure_data/measurement_ycoord measure_data/measurement_zcoord'
[]
[fromadjoint]
type = MultiAppReporterTransfer
multi_app = adjoint
direction = from_multiapp
from_reporters = 'adjoint_pt/adjoint_pt'
to_reporters = 'OptimizationReporter/adjoint'
direction = from_multiapp
[]
[]

Expand Down

0 comments on commit 67b9b43

Please sign in to comment.