[
https://issues.apache.org/jira/browse/MATH-655?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13095987#comment-13095987
]
Sébastien Brisard commented on MATH-655:
----------------------------------------
No, sorry I wasn't very clear.
I just mean that for the time being, {{IterativeLinearSolver}} extends
{{IterativeAlgorithm}}. What I'll do, is copy/paste all methods from
{{IterativeAlgorithm}} into {{IterativeLinearSolver}}, and remove the abstract
class {{IterativeAlgorithm}}.
So {{IterativeLinearSolver}} would still have methods to fire events, update
the iteration count, etc... Only these methods would be part of
{{IterativeLinearSolver}}, and not of a (too-general) super-class.
Then, I think it will always be possible to go back at a later point, and
re-extract those methods so as to re-create a super-class.
Am I wrong? I think the event handling is fairly lightweight, but you're right,
it might be utterly wrong in the end. I could just set this aside for the time
being, as well as custom stopping criteria (as you suggested, a default
stopping criterion is now hard-coded in the linear solver itself).
> General framework for iterative algorithms
> ------------------------------------------
>
> Key: MATH-655
> URL: https://issues.apache.org/jira/browse/MATH-655
> Project: Commons Math
> Issue Type: New Feature
> Affects Versions: 3.0
> Reporter: Sébastien Brisard
> Priority: Minor
> Labels: algorithm, events
> Attachments: iterative-algorithm.zip
>
>
> Following the thread [Monitoring iterative
> algorithms|http://mail-archives.apache.org/mod_mbox/commons-dev/201108.mbox/%3CCAGRH7HrgcgoBA=jcoKovjiQU=TjpQHnspBkOGNCu7oDdKk=k...@mail.gmail.com%3E],
> here is a first attempt at defining a general enough framework for iterative
> algorithms at large. At the moment, the classes provide support for
> * maximum number of iterations
> * events handling
> ** initialization event (prior to entering the main loop),
> ** iteration event (after completion of one iteration),
> ** termination event (after termination of the main loop).
> These classes do not yet provide support for a stopping criterion.
> Some points worth to note
> * For the time being, the classes are part of the o.a.c.m.linear package.
> * For the time being, {{IterativeAlgorithm.incrementIterationCount()}} throws
> a {{TooManyEvaluationsException}}. If the proposed new feature is integrated
> into CM, then a proper {{TooManyIterationsException}} should be created, from
> which the former could derive.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira