Re: Troolean operators




Kilgore Trout wrote:
Although I think I understand your point, two-value logic has great
strength and utility. For instance, that computer you are using is
made possible because of this system of 0/1 - on/off - t/f logic.



Yes, but it crashes all the time, because the programmers, never said,
true false or something else, they always say, true false or error out,
and often, they don't even say error out, the computer just crashes,
because they said true or false, and the value of the variable
was undefined, and so then if it was meant to be a word value, a
positive
whole niumber, and it ends up being a negative number like an integer,
then well crashola, bad memory assignment or whatever.

It is being applied now, by error checking which says, if the value is
nil,
then do this or that.

Because there is a difference between something not being assigned and
a value.

for instance, you ask the computer if this number is greater than or
equal to 0
do this, else do that.

You think you have it covered no?


Well the problem is that an undefined variable can be any value,
whatever happens
to be at that memory address, so it is outside of your equasion.

You have written code, and are assuming that you will get a math
result,
which is greater to or equal to 0, but since the value was nil, not
assigned,
it referenced what was in that memory, pulled out a negative number not
related at all to the function result you were expecting.

It is almost like a random number has been pulled from the air, because
you have no idea, what the value happened to be that was sitting in
that register.

Hence you have a problem, that does not appear until the computer
crashes.

There used to also be a problem with division by 0. But that has been
fixed.
Or at least it doesn't crash the CPU, it will still cause an error and
your program
whatever it might be then will handle that error.

So the design of computers, with 0's and 1's is flawed from the get go,
and it
still amazes me, how we useed to have to reboot win 95 and win 98 like
10
times a day, .and people accepted it. They didn't have any choice
because there
was no real alternative. You couldn't just go and ask for your money
back
like you certainly would, if the washing machine you just bought, had
to be
unplugged and plugged back in 10 times a day.
(sorry for the wordy response)


Now, if your point is that these logical systems are incomplete, well,
perhaps you have heard of Gödel.

In the strictest sense, it is perhaps true that this logic simply
mimics our experiences (thus making it more inductive than deductive)
in the real-world, without saying anything really deep about that
world.

My understanding is that Gödel showed that within any deductive system
we can produce statements that basically claim to be decidable iff they
are not decided.

A rough (and somewhat crappy) analogy is the old statement: "This
statement is false", which cannot be assigned a truth-value.

Anyways, it's been a long time since my last logic class, so I am
probably garbling some of this. But the basic idea that these systems
and even the meta-systems which analyze them are flawed is pretty much
accepted at this point.

And of course there has been extensive work in "many-value" systems of
various forms.


Well I think an improvement would be the troolean operator, in computer
logic.

This would force the programmer, to consider the what if's, and make
more
reliable systems overall. I am sure that in any scientific endeavor, at
least
being consciously aware of quantum fluctuations, has improved things,
yet there is no formalized method of applying it short of just saying
statistically
the result will be so.

.



Relevant Pages

  • Re: Identity Matrix
    ... This is not what programmers said that they needed in the 80's when the semantics of the feature were being discussed, and the feature was not added to f90 because of this disagreement between the programers and the compiler writers. ... or the order of assignment after the values have been determined. ... This makes FORALL less useful and more prone to inefficiencies than it should have been. ...
    (comp.lang.fortran)
  • Re: why the usage of gets() is dangerous.
    ... Without fat pointer and checking you get memory corruption, ... Those who bother to attach a debugger and see where it crashes will immediately know where it crashes and why. ... Most programmers also find tools that pinpoint the bugs more accurately by causing the failure to happen earlier to to be useful. ... By your argument we should not do any testing of any libraries or any SW because then it will be VALIDATED and the programmer will assume something else must be wrong when it crashes. ...
    (comp.lang.c)
  • Constructor Generic Type Inference
    ... Most programmers seem to agree that it is tedious to have to type long ... Various suggestions have been made to add some form of type inference ... Using ellipsis like this saves typing. ... ellipsis is present on the left hand side of the assignment. ...
    (comp.lang.java.programmer)
  • Re: security issues with forth
    ... Crashes are instructive. ... but these were students writing student exercises. ... a difference between that and professionals writing code that will be ... I see experienced application programmers do this all the time! ...
    (comp.lang.forth)
  • Re: fclose(0)
    ... Some programmers never even see ... the crashes, let alone fix their causes. ... I have a web browser ...
    (comp.lang.c)