coq-club AT inria.fr
Subject: The Coq mailing list
List archive
- From: Adam Chlipala <adamc AT csail.mit.edu>
- To: coq-club AT inria.fr
- Subject: Re: [Coq-Club] meaning of formal specifications
- Date: Tue, 26 Jan 2021 19:36:00 -0500
- Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None smtp.pra=adamc AT csail.mit.edu; spf=Pass smtp.mailfrom=adamc AT csail.mit.edu; spf=None smtp.helo=postmaster AT outgoing-stata.csail.mit.edu
- Ironport-phdr: 9a23:6cPQsB/X2Fjhyv9uRHKM819IXTAuvvDOBiVQ1KB31egcTK2v8tzYMVDF4r011RmVBNSdsa0P07We8/i5HzBZvtDZ6DFKWacPfidNsd8RkQ0kDZzNImzAB9muURYHGt9fXkRu5XCxPBsdMs//Y1rPvi/6tmZKSV3wOgVvO+v6BJPZgdip2OCu4Z3TZBhDiCagbb9oIxi6sAHcutMIjYZgJao91hnEqWZMd+hK2G9kP12ekwv+68uq4JJv7yFcsO89+sBdVqn3Y742RqFCAjQ8NGA16szrtR3dQgaK+3ARTGYYnAdWDgbc9B31UYv/vSX8tupmxSmVJtb2QqwuWTSj9KhkVhnlgzoaOjEj8WHXjstwjL9HoB+kuhdyzZLYbJ2TOfFjeK7WYNEUSndbXstJSiJPHI28YYsMAeQPM+lXoIvyqEcBoxalGQmhB/nixiNUinL436A31fkqHwHc3AwnGtIDqGjZo8jvO6cXTOu40qnIzTHCb/NOwzj97JLHeQ0mrP6WQL1/a8/RxlU0GgzZlVWfs43lPzeP2uQIsmib8/BsWvyyhG46sgx8pCWkycgwhIfTnI0V1kzE+jtjwIYzPdC1VFJ3bMOmHZZTty+XNZV6T8c+Tm11pCo3y7IItJ2lcCUWxpopxx3SZfOafoWM7B/uWuifLDN4in95Zb+yhwu+/E69weP/Tsm5yEtGojRGn9XWuH0Bywbf5tadRvdj40utxS6D2gLd5+1eP0w4iK7WJ4Qgz7MwjJYfrFrPEjPwlU7rlqGZbF8k9fKt6+n/YrXpuJucN4hshwH5L6QuhsO/AeM5MggIUGiX4P+81KH58k3lWrpGlOE5krLDv5DbIcQXvKu5Aw5J0oo59RmwEiqm3MwZnXkBMl1FZAqKg5X3N1zNOvz1A+uzj06ynDtx2fzKI6HtDo3ILnfZkbfhebh961RbyAo21d1Q/Y9bBasEIP3vQUL+qMfYAQU4Mwyw2ernDdR91p8EVW2RH6CZLbvesUWU6eI3P+mMeIgVtS7hJPgi/v7ilGM2mVsAfaayxpYXc3C5HvF+I0qDe3bsg9EBEX0LvgUkVuDqhkeCAnZvYCO5WLt57TUmAqqnC53CT8ajmu+vxiC+S7Rab2UOIVCIEG/hc4zMD/4AYSeZCsR6mz0AE72gV8ks2Qz451yy8KZuMueBon5QjpnkztUgv7SCxyF3ziR9CoGm60/ISmh1mm0SQDpvgfJ0ukV8zhGG0LQ+jvBFR4UKu6F5FzwiPJuZ9NRUTsjoU1ucLNySQVeiBNCnHXc8Qs9jm4ZTMXY4IM2ri1X45wTvA7IRkOfTVpsp7q3b3n7+Yt1hwmrPkqI6hlgiBM5OKSurirMtrwU=
On 1/25/21 1:03 PM, Michael Soegtrop wrote:
I think that kind of explanation only makes sense with respect to particular verification systems or even particular verifications. It's not possible, in general, to look at some code and answer "is that a specification or an implementation?". I've come to see relational "specifications" as just programs written in a different language/style, with fundamental nondeterminism and lack of an obvious algorithm to run them directly. That is probably the key difference in our perspectives.My opinion is that a lot of people think they agree on what "formal specification" means, but it actually means almost nothing and is best to avoid using! Instead, formal methods is all about proving connections between systems, often where one system is markedly simpler than the other and thus easier to build confidence in.
I don't agree with this view. The specifications are supposed to define desirable properties of a system, not how these are achieved. These specified properties are those which a larger system requires from a subsystem.
A specification of a C function doing minimization states that there is a tuple of input parameters which may be varied and a goal function which maps this tuple to a real number. One can then abstractly define the minimum (or infimum) of the goal function over all possible parameter tuple values. Then one can specify that the goal function applied to the set of parameters the C function returns shall not be worse than a well defined increase over this abstract minimum. Such a specification has nothing to do with refinement, simplified systems or possible implementations. It simply states what it means to minimize something and what deviation from perfection is tolerable. In a larger context such a specification is more interesting than stating that the optimization function behaves approximately like some simplified prototype algorithm. To the reader of the specification it tells exactly what (s)he can expect from the C code. A comparison with a simplified reference implementation wouldn't tell that, unless one analyzes this simplified algorithm in detail.
But your chosen specification here could easily be part of a refinement process that started with a broader specification, like maybe a set of differential equations for a dynamical system, from which you drew a connection to a particular algorithm and its associated helper functions, one that calls for computing a minimum within some floating-point tolerance. I didn't at all mean to argue for executable reference implementations as the only appropriate kinds of specifications / intermediate steps in derivations!
- [Coq-Club] meaning of formal specifications, Fritjof, 01/25/2021
- Re: [Coq-Club] meaning of formal specifications, Ian Atol, 01/25/2021
- Re: [Coq-Club] meaning of formal specifications, Benoît Viguier, 01/25/2021
- Re: [Coq-Club] meaning of formal specifications, Abhishek Anand, 01/26/2021
- Re: [Coq-Club] meaning of formal specifications, Benoît Viguier, 01/25/2021
- Re: [Coq-Club] meaning of formal specifications, Agnishom Chattopadhyay, 01/25/2021
- Re: [Coq-Club] meaning of formal specifications, Adam Chlipala, 01/25/2021
- Re: [Coq-Club] meaning of formal specifications, Michael Soegtrop, 01/25/2021
- Re: [Coq-Club] meaning of formal specifications, Adam Chlipala, 01/27/2021
- Re: [Coq-Club] meaning of formal specifications, Michael Soegtrop, 01/25/2021
- Re: [Coq-Club] meaning of formal specifications, Xavier Leroy, 01/25/2021
- Re: [Coq-Club] meaning of formal specifications, Vincent Semeria, 01/25/2021
- Re: [Coq-Club] meaning of formal specifications, Adam Chlipala, 01/27/2021
- Re: [Coq-Club] meaning of formal specifications, Vincent Semeria, 01/27/2021
- Re: [Coq-Club] meaning of formal specifications, Fritjof, 01/29/2021
- Re: [Coq-Club] meaning of formal specifications, Vincent Semeria, 01/27/2021
- Re: [Coq-Club] meaning of formal specifications, Adam Chlipala, 01/27/2021
- Re: [Coq-Club] meaning of formal specifications, Vincent Semeria, 01/25/2021
- Re: [Coq-Club] meaning of formal specifications, Milad Ketabii, 01/25/2021
- Re: [Coq-Club] meaning of formal specifications, Pierre Courtieu, 01/26/2021
- Re: [Coq-Club] meaning of formal specifications, Ian Atol, 01/25/2021
Archive powered by MHonArc 2.6.19+.