Frama-C-discuss mailing list archives
This page gathers the archives of the old Frama-C-discuss archives, that was hosted by Inria's gforge before its demise at the end of 2020. To search for mails newer than September 2020, please visit the page of the new mailing list on Renater.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Frama-c-discuss] Preservation of base loop invariant not verified
- Subject: [Frama-c-discuss] Preservation of base loop invariant not verified
- From: Claude.Marche at inria.fr (Claude Marche)
- Date: Mon, 26 Jan 2015 12:26:02 +0100
- In-reply-to: <E49491B5-481A-45DC-97A7-A5D3C31476F0@cea.fr>
- References: <CA+Tazt7sOtQxyvgLwbFvWDQ=pniO2AQFh-xC216vEXd9aOprqQ@mail.gmail.com> <CA+Tazt76hoLNNnyXHo2TpXc7x41c8vT5+=0k4ughbbvoVpsCFQ@mail.gmail.com> <E49491B5-481A-45DC-97A7-A5D3C31476F0@cea.fr>
In fact, this does not seem to be the reason. It is not proved just because the trivial loop invariant below is missing loop invariant j >= 1; with this additional info, the preservation of the loop invariant loop invariant j == 1 ==> i == \at(i, LoopEntry) + loop(0); is a triviality, since j == 1 is false after any iteration of the loop. Anyway, I don't see why your loop invariant is splitted into two parts: this should work : /*@ loop invariant j >= 1; loop invariant i == \at(i, LoopEntry) + loop(j - 1); loop invariant j >= 8 ==> is_hello_printed == 1; loop assigns i, j, is_hello_printed; loop variant 10 - j ; */ Hope this helps, - Claude Le 26/01/2015 10:05, Lo?c Correnson a ?crit : > Your property P is not provable *by induction* ; it means that P(j+1) is not a logic consequence of P(j). > (read in the WP manual about the proof obligations generated for loop invariants). > Actually, there is nothing in your loop invariants about the value of (i) at any loop turn? > L. > > _______________________________________________ > Frama-c-discuss mailing list > Frama-c-discuss at lists.gforge.inria.fr > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/frama-c-discuss > -- Claude March? | tel: +33 1 72 92 59 69 INRIA Saclay - ?le-de-France | Universit? Paris-sud, Bat. 650 | http://www.lri.fr/~marche/ F-91405 ORSAY Cedex |
- Follow-Ups:
- [Frama-c-discuss] Preservation of base loop invariant not verified
- From: kazarmy at gmail.com (Khairul Azhar Kasmiran)
- [Frama-c-discuss] Preservation of base loop invariant not verified
- References:
- [Frama-c-discuss] Preservation of base loop invariant not verified
- From: kazarmy at gmail.com (Khairul Azhar Kasmiran)
- [Frama-c-discuss] Preservation of base loop invariant not verified
- From: kazarmy at gmail.com (Khairul Azhar Kasmiran)
- [Frama-c-discuss] Preservation of base loop invariant not verified
- From: loic.correnson at cea.fr (Loïc Correnson)
- [Frama-c-discuss] Preservation of base loop invariant not verified
- Prev by Date: [Frama-c-discuss] Preservation of base loop invariant not verified
- Next by Date: [Frama-c-discuss] Preservation of base loop invariant not verified
- Previous by thread: [Frama-c-discuss] Preservation of base loop invariant not verified
- Next by thread: [Frama-c-discuss] Preservation of base loop invariant not verified
- Index(es):