pyHarm.StepSizeRules.StepSizeAcceptance ======================================= .. py:module:: pyHarm.StepSizeRules.StepSizeAcceptance Classes ------- .. autoapisummary:: pyHarm.StepSizeRules.StepSizeAcceptance.StepSizeAcceptance Module Contents --------------- .. py:class:: StepSizeAcceptance(bounds: list[float, float], **kwargs) Bases: :py:obj:`pyHarm.StepSizeRules.ABCStepSizeRule.ABCStepSizeRule` Step size is divided by 2 if last solution is not accepted or multiplied by 2 if a number of consecutive accepted solutions is reached. .. attribute:: default_options contains default step size options concerning consecutive_accept if not provided during creation. :type: dict .. attribute:: consecutive_accept number of consecutive accept before increasing step size. :type: int .. py:attribute:: name :value: 'accepted step size adaptation' .. py:attribute:: factory_keyword :type: str :value: 'acceptance' Returns: str: keyword that is used to call the creation of this class in the system factory. .. py:attribute:: default_options .. py:attribute:: stepsize_options .. py:attribute:: consecutive_accept .. py:method:: getStepSize(ds: float, sollist: list[pyHarm.Solver.SystemSolution], **kwargs) -> float Returns the step size to be used for the prediction step of the analysis. :param ds: Current step size. :type ds: float :param sollist: list of SystemSolution returned during the analysis. :type sollist: list[SystemSolution] :returns: updated step size. :rtype: float