Hacker News new | past | comments | ask | show | jobs | submit login

It seems like we have an equation with a bunch of variables that are either extremely close to 1 or extremely close to zero. And really, these variables seem to group together into two essential variables, which are either almost 1 or almost 0. And we're trying to figure out whether, when you multiply them together, you get almost 1 or almost 0.

So, what does (almost_1 * almost_0) equal? It requires more knowledge about "almost" than are able to obtain.




Your question reminded me of MAYBE.

I often joke about the MAYBE logical operator with friends. It's based on the concept of three valued logic [1]. It always came up for me in SQL where you have a cell in a result that can be NULL, NOT NULL or a value. I also use it to refer to spaghetti or complex code where the outcome on first glance is "maybe this or maybe that, or maybe something in the middle". Again, I use it as a joke when it is a totally real concept.

It seems like increasingly we are trying to extract approximate answers from machine learning, statistics, etc. because in so many cases it seems difficult to get to TRUE or FALSE for a given hypothesis. We want "MAYBE" with enough accuracy to believe it is mostly TRUE or 100% TRUE (but often 95% confidence - heck even 85% is still amazingly valuable when you aren't sure at all).

I believe there is a programming language that handles this (I forget which one though - anyone?). I know quantum processors potentially could handle it since they have multiple states for a qubit which could represent different states of "in-between" TRUE and FALSE.

[1] https://en.wikipedia.org/wiki/Three-valued_logic


This basically exists in Haskell/Idris as the Maybe type.

It is used slightly differently than what you're saying but in essence it lets you say: - The thing doesn't exist, return Nothing (unit in a way) - The inputs produced Just the thing you wanted

You have to cover both "didn't work" and "here you go" but its highly useful to not have to worry about NULL versus NOT NULL.

https://stackoverflow.com/questions/29456824/what-is-the-may...

Your function that decides if something exists or not, could be the thing determining the percentage spiel.

Aka a function returning Maybe Bool could return: a Bool with true/false, or Nothing. Nothing being "its not a bool, your inputs are insane/nonsensical", but if it returns a Just Bool, you just unbox the Bool and voila. Just thought you might want to know this is a real thing and is super useful.


Ah, thank you. I knew it existed in some language, but I couldn't remember where I had seen it. I need to practice Haskell a bit more.. it's not one of the languages I ever seem to get around to.


Its fun! Also maddening, in the "this is computation in a totally different paradigm" way.

But Maybe as an example is one of those things that show you there are better ways than NULL.


From a purely mathematical perspective, without respect to the topic, almost_1 * almost_0 is almost_0 (example: 0.999 * 0.001 = 0.000999).


You’re absolutely correct, f(almost_1,almost_2) should not be “times” in the calculation I described. Or alternatively, it should be a massive number times a tiny number rather than almost 1 and 0.


In fact, it is __less than__ almost_0.

the product of any two numbers on (0,1) is smaller than either of those two numbers.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: