35 use json_module,
only: json_file
37 use vector,
only: vector_t
38 use utils,
only: neko_error
122 module subroutine design_factory(object, parameters,
simulation)
123 class(design_t),
allocatable,
intent(inout) :: object
124 type(json_file),
intent(inout) :: parameters
125 type(simulation_t),
intent(inout),
optional :: simulation
126 end subroutine design_factory
127 end interface design_factory
134 subroutine design_free(this)
136 class(design_t),
intent(inout) :: this
137 end subroutine design_free
139 function design_get_design(this)
result(x)
140 import design_t, vector_t
141 class(design_t),
intent(in) :: this
143 end function design_get_design
145 subroutine design_update_design(this, x)
146 import design_t, vector_t
147 class(design_t),
intent(inout) :: this
148 type(vector_t),
intent(inout) :: x
149 end subroutine design_update_design
151 subroutine design_map_forward(this)
153 class(design_t),
intent(inout) :: this
154 end subroutine design_map_forward
156 subroutine design_map_backward(this, sensitivity)
157 import design_t, vector_t
158 class(design_t),
intent(inout) :: this
159 type(vector_t),
intent(in) :: sensitivity
160 end subroutine design_map_backward
162 subroutine design_write(this, idx)
164 class(design_t),
intent(inout) :: this
165 integer,
intent(in) :: idx
166 end subroutine design_write
169 public :: design_t, design_factory
173 subroutine design_init_from_json(this, parameters)
174 class(design_t),
intent(inout) :: this
175 type(json_file),
intent(inout) :: parameters
177 call neko_error(
"Design type does not support initialization &
178 &without simulation")
179 end subroutine design_init_from_json
182 subroutine design_init_from_json_sim(this, parameters, simulation)
183 class(design_t),
intent(inout) :: this
184 type(json_file),
intent(inout) :: parameters
187 call neko_error(
"Design type does not support initialization &
189 end subroutine design_init_from_json_sim
192 subroutine design_init_base(this, n)
193 class(design_t),
intent(inout) :: this
194 integer,
intent(in) :: n
196 end subroutine design_init_base
199 subroutine design_free_base(this)
200 class(design_t),
intent(inout) :: this
202 end subroutine design_free_base
205 pure function design_size(this)
result(n)
206 class(design_t),
intent(in) :: this
209 end function design_size
Factory function for the design object.
pure integer function design_size(this)
Return the number of design variables.
subroutine design_init_from_json_sim(this, parameters, simulation)
Dummy initialization from JSON.
subroutine design_free_base(this)
Free the base design.
subroutine design_init_base(this, n)
Initialize the base design.
subroutine design_init_from_json(this, parameters)
Dummy initialization from JSON.
Implements the steady_problem_t type.