3 ms·
> Godel's incompleteness theorem say that a system of sufficient complexity can not be both complete and consistent You've made an important and very common mi
by irq-1 3y ago
> Godel's incompleteness theorem say that a system of sufficient complexity can not be both complete and consistent
You've made an important and very common mistake of not qualifying this: it only holds true within the system. If you are using the same logical/mathematical system to evaluate its own completeness or consistency, then Godels results apply. Using other systems we can examine and understand the truth of sentences; which is to say, a systems completeness and consistency.
Wikipedia includes this constraint:
> For any such consistent formal system, there will always be statements about natural numbers that are true, but that are unprovable within the system.
Few programmers and other on the internet understand the significance, often making reasoning about it wrong.
> Practically, this means that there will never be a compiler that will tell you whether you program has a bug.
TLA+ and other "external" systems can evaluate whether a program has a bug.
- hwayne 3y agoThe GP had a few misconceptions about Godel and halting problems and stuff, but one nitpick here: >> Practically, this means that there will never be a compiler that will tell you whether you program has a bug. > > TLA+ and other "external" systems can evaluate whether a program has a bug. The main TLA+ model checker is TLC. It's pretty easy to write a TLA+ spec with a bug that TLC can't find (ironically by exploiting unbound model spaces, which are the Does Not Halt of model checking)
- abetusk 3y ago> You've made an important and very common mistake of not qualifying this: it only holds true within the system. It's not a mistake. I've stated it clearly. You're effectively qualifying it by saying you can add more axioms to extend the mathematical system to render previously incomplete statements complete. This comes at the cost of adding more incomplete statements. I can add the "The Riemmann hypothesis is true" as an axiom, say, and, assuming it's consistent with other axioms and actually adds some power that other axioms didn't, that might be fine, but this will create other statements that are also incomplete. > TLA+ and other "external" systems can evaluate whether a program has a bug. No, it won't. From the Wikipedia entry [0]: > The model checker finds all possible system behaviours up to some number of execution steps, and examines them for violations of desired invariance properties such as safety and liveness. From this, at best this only does it out to a finite number of execution steps. I suspect this comes at the cost of exponential resources. So not only does it not find all bugs, the bugs it does find come at an increasingly intractable cost. [0] https://en.wikipedia.org/wiki/TLA%2B https://en.wikipedia.org/wiki/TLA%2B