Questions tagged [formal-methods]

Formal methods are a particular kind of mathematically-based techniques for the specification, development and verification of software and hardware systems.

Formal methods are a particular kind of mathematically-based techniques for the specification, development and verification of software and hardware systems.

The use of formal methods for software and hardware design is motivated by the expectation that, as in other engineering disciplines, performing appropriate mathematical analysis can contribute to the reliability and robustness of a design.

Formal methods are best described as the application of a fairly broad variety of theoretical computer science fundamentals, in particular logic calculi, formal languages, automata theory, and program semantics, but also type systems and algebraic data types to problems in software and hardware specification and verification.

153 questions
104
votes
10 answers

What are the most interesting equivalences arising from the Curry-Howard Isomorphism?

I came upon the Curry-Howard Isomorphism relatively late in my programming life, and perhaps this contributes to my being utterly fascinated by it. It implies that for every programming concept there exists a precise analogue in formal logic, and…
Tom Crockett
  • 30,818
  • 8
  • 72
  • 90
94
votes
3 answers

What are the strengths and weaknesses of the Isabelle proof assistant compared to Coq?

Does Isabelle/HOL proof assistant have any weaknesses and strengths compared to Coq?
elysefaulkner
  • 973
  • 2
  • 8
  • 8
77
votes
11 answers

Can Haskell functions be proved/model-checked/verified with correctness properties?

Continuing on from ideas in: Are there any provable real-world languages? I don't know about you, but I'm sick of writing code that I can't guarantee. After asking the above question and getting a phenomenal response (Thanks all!) I have decided to…
31
votes
1 answer

Formal methods in C++ for safety critical software

Looking at C, C has good support for formal methods that can be used in-code(frama-c, VCC, verifast). C++ doesn't seem to have any comparable as far as I can tell. What formal methods are available for reasoning about safety-critical software…
willfredthebuel
  • 339
  • 2
  • 6
22
votes
7 answers

Teaching programming and formal methods

Here's a sort of odd question. I'm in the process of writing a book on learning to program using formal methods, and I'm going to target it toward people with some programming experience. The idea is to teach them to be high-quality…
Charlie Martin
  • 110,348
  • 25
  • 193
  • 263
22
votes
1 answer

Limits of SMT solvers

Traditionally most work with computational logic was either propositional, in which case you used a SAT (boolean satisfiability) solver, or first-order, in which case you used a first-order theorem prover. In recent years, a lot of progress has been…
rwallace
  • 31,405
  • 40
  • 123
  • 242
16
votes
5 answers

What is the best way of determining a loop invariant?

When using formal aspects to create some code is there a generic method of determining a loop invariant or will it be completely different depending on the problem?
filinep
  • 529
  • 2
  • 11
  • 17
16
votes
3 answers

Experiences with using Alloy in real-world projects

I have been interested in formal methods for some time. I have used formal methods to reason about some very specific sub-areas of a few projects I have been working on. I was never able to convince other team members to try the same let alone…
VoidPointer
  • 17,651
  • 15
  • 54
  • 58
12
votes
1 answer

Forall introduction in coq?

I'm trying to (classically) prove ~ (forall t : U, phi) -> exists t: U, ~phi in Coq. What I'm trying to do is prove it contrapositively: 1. Assume there is no such t (so ~(exists t: U, ~phi)) 2. Choose arbitrary t0:U 3. If ~phi[t/t0], then…
Maty
  • 223
  • 1
  • 7
11
votes
6 answers

Formal Methods and Enterprises

So... I teach formal methods in software engineering. I also teach "agile methodologies". Most people seem to think this is contradictory. I think it makes a lot of sense... I also work for a company, where we need to actually get things done :)…
Hugo Sereno Ferreira
  • 8,600
  • 7
  • 46
  • 92
6
votes
1 answer

Where does the KeY verification tool shine?

What are some code examples demonstrating KeY’s strength? Details With so many Formal Method tools available, I was wondering where KeY is better than its competition, and how? Some readable code examples would be quite helpful for comparison and…
6
votes
5 answers

What is your experience with software model checking?

What types of applications have you used model checking for? What model checking tool did you use? How would you summarize your experience w/ the technique, specifically in evaluating its effectiveness in delivering higher quality software? In…
5
votes
8 answers

Should I use formal methods on my software project?

Our client wants us to build a web-based, rich internet application for gathering software requirements. Basically it's a web-based case tool that follows a specific process for getting requirements from stakeholders. I'm the project manager and…
5
votes
1 answer

Proving equivalence of programs

The ultimate in optimizing compilers would be one that searched among the space of programs for a program equivalent to the original but faster. This has been done in practice for very small basic blocks:…
rwallace
  • 31,405
  • 40
  • 123
  • 242
5
votes
2 answers

Using forall within recursive Function definition

I'm trying to use Function to define a recursive definition using a measure, and I'm getting the error: Error: find_call_occs : Prod I'm posting the whole source code at the bottom, but my function is Function kripke_sat (M : kripke) (s : U) (p :…
Maty
  • 223
  • 1
  • 7
1
2 3
10 11