Patch to qp() to support extra arg specifying maximum iterations

Joshua Redstone redstone at gmail.com
Sun Feb 1 20:15:25 CST 2009


Yeah, it'd be great if 'export' somehow took multiple changesets.
In the meantime, are the simple tests I added to qp.m what you were looking
for?
I just made sure the the maxit did something useful and didn't break the old
call signature.
Josh

On Sun, Feb 1, 2009 at 6:07 PM, Ben Abbott <bpabbott at mac.com> wrote:

>
> On Feb 1, 2009, at 8:45 PM, Joshua Redstone wrote:
>
>  On Sun, Feb 1, 2009 at 4:51 PM, Ben Abbott <bpabbott at mac.com> wrote:
>>
>>  On Feb 1, 2009, at 6:43 PM, Joshua Redstone wrote:
>>>
>>> Hi,
>>> Attached is a patch to eliminate a FIXME in qp.m.  This adds an extra arg
>>> to qp() to specify the maximum number of iterations.
>>> The old hard-coded value of 200 iterations is sometimes insufficient for
>>> convergence.
>>>
>>> I originally posted this 3 months ago, but perhaps sent it to the wrong
>>> list.  I've update the diff to the current repository version.
>>> I haven't contributed before, so please let me know if there's something
>>> else I should do.
>>> Thanks,
>>> Josh
>>>
>>> <qp.diff>
>>>
>>> Josh,
>>>
>>> I'm unfamiliar with qp(). Is it possible to add some tests that validate
>>> this change?
>>>
>>> Ben
>>>
>>>
>> I attached a diff of a followon changeset that adds a few tests to qp.m to
>> exercise the maxit argument.
>> I actually don't understand qp.m internals so the examples are pretty
>> contrived.
>> Also, I have mercurial 1.0.1 and I couldn't figure out how to generate a
>> single 'export' style patch that included both changesets.
>> Josh
>>
>
> I don't know if it is possible to export a patch that includes two
> changesets. What I tend to do is create a changeset for each, and import
> them into a virgin mercurial archive and then produce a changeset (I hope
> that makes sense). The only caveat is that the 2nd Changelog entry may not
> apply, so I edit the Changelog manually and then generate a combined
> changeset.
>
> I expect someone with a better understanding of mercurial will educate us
> sometime tomorrow :-)
>
> Regarding the Changelog, you should add the change to the Changelog file in
> the scripts directory. Thus the changeset should include something like what
> is below ...
>
> --- a/scripts/ChangeLog Sun Feb 01 20:40:10 2009 +0100
> +++ b/scripts/ChangeLog Sun Feb 01 15:40:19 2009 -0800
> @@ -1,3 +1,8 @@
> +2009-02-01  Joshua Redstone <redstone at gmail.com>
> +
> +       * scripts/optimization/qp.m: Add extra argument, max_iter, to qp(),
> +       specifying the maximum number of iterations.
> +
>
> Ben
>
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://www-old.cae.wisc.edu/pipermail/octave-maintainers/attachments/20090201/79185410/attachment.html 


More information about the Octave-maintainers mailing list