![]() |
Octopus
|
Factory for optimal-control targets. More...
Factory for optimal-control targets.
This is the single place that knows about every concrete target kind: it reads OCTTargetOperator, allocates the matching target_t subclass, runs the common initialization (loading the reference states) and then dispatches to the kind-specific init. Keeping this select case in one small module means the rest of the code only ever sees the abstract target_t.
Functions/Subroutines | |
| class(target_t) function, pointer, public | target_factory_create (gr, kpoints, namespace, space, ions, qcs, td, w0, oct, ep, mc) |
| Create and initialize the optimal-control target. More... | |
| class(target_t) function, pointer, public target_factory_oct_m::target_factory_create | ( | type(grid_t), intent(in) | gr, |
| type(kpoints_t), intent(in) | kpoints, | ||
| type(namespace_t), intent(in) | namespace, | ||
| class(space_t), intent(in) | space, | ||
| type(ions_t), intent(in) | ions, | ||
| type(opt_control_state_t), intent(inout) | qcs, | ||
| type(td_t), intent(in) | td, | ||
| real(real64), intent(in) | w0, | ||
| type(oct_t), intent(in) | oct, | ||
| type(epot_t), intent(inout) | ep, | ||
| type(multicomm_t), intent(in) | mc | ||
| ) |
Create and initialize the optimal-control target.
Returns a polymorphic pointer to the concrete target selected through the OCTTargetOperator input variable.
Definition at line 170 of file target_factory.F90.