Create weights.
During creation the weights are also computed.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(optimal_weights), | intent(inout) | :: | self | Optimal weights. |
||
class(base_object_constructor), | intent(in) | :: | constructor | Optimal weights constructor. |
pure subroutine create(self, constructor)
!< Create weights.
!<
!< @note During creation the weights are also computed.
class(optimal_weights), intent(inout) :: self !< Optimal weights.
class(base_object_constructor), intent(in) :: constructor !< Optimal weights constructor.
call self%destroy
select type(constructor)
class is(optimal_weights_constructor)
allocate(self%opt(1:2, 0:constructor%S - 1))
call self%compute(S=constructor%S)
class default
! @TODO add error handling
endselect
endsubroutine create