From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.50.20.227 with SMTP id q3mr26467395ige.11.1444908219725; Thu, 15 Oct 2015 04:23:39 -0700 (PDT) X-Received: by 10.182.255.225 with SMTP id at1mr84207obd.14.1444908219705; Thu, 15 Oct 2015 04:23:39 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!feeder.eternal-september.org!feeder.erje.net!us.feeder.erje.net!news.glorb.com!kq10no21605074igb.0!news-out.google.com!n2ni30893igy.0!nntp.google.com!kq10no18738403igb.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Thu, 15 Oct 2015 04:23:39 -0700 (PDT) In-Reply-To: <41a7f7f9-65b4-43a3-b817-f5d9c6a3d015@googlegroups.com> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=20.133.0.13; posting-account=9gDAAwoAAACNb2IeoWuUI1mQDA83utl6 NNTP-Posting-Host: 20.133.0.13 References: <4187f92b-770a-4d76-85c0-14f2eba2dee8@googlegroups.com> <41a7f7f9-65b4-43a3-b817-f5d9c6a3d015@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: Issue with SPARK 2014 From: Stuart Injection-Date: Thu, 15 Oct 2015 11:23:39 +0000 Content-Type: text/plain; charset=ISO-8859-1 Xref: news.eternal-september.org comp.lang.ada:27981 Date: 2015-10-15T04:23:39-07:00 List-Id: On Thursday, 15 October 2015 09:44:39 UTC+1, Phil Thornley wrote: ... > Stuart's explanation is quite correct. [Thank you :-)] > In the first version try changing the bound on Count1 to: > Integer (Columns'Pred (Column) - J) > so that it starts at 0 and increments by 1 on each loop. ... Having thought about it a bit more (but still no opportunity to test) I thought that example 1 could use the invariant: Count1 = Integer(J-Columns'First) This seems to capture the essence of the loop (always a good sign for a loop invariant) In the absence of the full code getting a definitive useful loop invariant is not possible!