
Soundness and Completeness: With Precision - mpweiher
https://bertrandmeyer.com/2019/04/21/soundness-completeness-precision/
======
bumbledraven

        > An analysis is sound if it reports all errors, and complete if it only reports errors.
    

This seems backwards. Soundness and completeness are terms from logic:

 _sound_ = every provable statement is true

 _complete_ = every true statement is provable

A statement is _provable_ if and only if it can be derived within the system.
For example, the statement "SS0 + SS0 = SSSS0" (i.e. 2+2=4) is provable in
Peano Arithmetic (PA) because it can be derived from the axioms of PA.

A statement is _true_ if and only if it is actually true. For example,
Goodstein's Theorem
([https://en.wikipedia.org/wiki/Goodstein%27s_theorem](https://en.wikipedia.org/wiki/Goodstein%27s_theorem))
is true. However, Goodstein's Theorem is not provable in PA.

By definition, a logical system that allows you to prove anything, even
nonsense, is complete. Also, a logical system that doesn't allow you to prove
anything is, by definition, sound.

In a comment at the bottom of the article, the author says:

    
    
        > Soundness means: passed => not erroneous
        > Completeness means: not erroneous => passed
        >
        > or equivalently, since rejected = (not passed):
        >
        > Soundness means: not rejected => not erroneous
        > Completeness means: not erroneous => not rejected
    

This seems wrong. For one thing, _rejected_ is not necessarily equivalent to
_not passed_ , because there is a third possibility: the algorithm might fail
to terminate. This is analogous to a statement which can neither be proved nor
disproved in a given logical system.

------
ericpauley
This article seems to confuse the concept of precision somewhat. Per Michael
Hicks’ post on the same topic [1], precision is generally approaching
soundness whereas recall or sensitivity is approaching completeness.
Admittedly, I’ve also seen the term precision used far more loosely, including
to describe approximate completeness (e.g. sound and precise).

[1] (also cited in linked article) [http://www.pl-
enthusiast.net/2017/10/23/what-is-soundness-in...](http://www.pl-
enthusiast.net/2017/10/23/what-is-soundness-in-static-analysis/)

