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

Sure and there are a lot of simple ways to improve the accuracy of the simple approach before you go for the pure math sledgehammer here. It's all a question of how accurate the answer needs to be.

For example, It's pretty easy to come up with an FP64 error bound on the sum. And if the difference between the two sums is greater than that error bound you don't need to do anything more complicated. Where this would get complicated IMO is if you were dealing with 128-bit or higher integers.

Edit: I am learning so much about the mindset here and what triggers acute attacks of the heebie jeebies. This place has really changed in the past decade since I joined and not for the better. Yes good, good, more downvotes. Show your love with downvotes. I'm stuck at 2970 karma, only you can help me on the journey to zero. Can we beat -4? Let's find out.




Looking at your original reply, you started bringing in "job interviews" and "companies that ship". I imagine that's why people downvoted you -- this post (and replies) are about maths, not worrying about really companies.

The original post wasn't about practical software, or shipping products, or getting a "good enough answer". It was about an interesting (to many people) maths problem.

If you want ycombinator to just be about companies and shipping products, then indeed it "has changed". But many people (myself included) like a good pure maths puzzle, and are interested in if there is a "true answer".


And I admitted it's a cool pure math problem. The challenge in the tech industry is balancing the rigor of a pure but nearly intractable solution with using the theory to pump up an O(n) imperfect solution to acceptable reliability. I find the latter more interesting, YMMV.

But if that isn't as interesting as the original problem, maybe stay in academia? AI itself is an example of tailoring activation and pooling functions to deliver imperfect solutions that are "good enough" to ship. It's unfortunate these two viewpoints are seen as contradictory rather than complementary, but that does echo our political balkanization so I guess I shouldn't be surprised.


Making things hard sometimes leads to insights down the line. For instance, the formula for solving cubic equations seems kind of silly from a numerical point of view -- you can just use a general-purpose numerical algorithm to solve cubics. But the research into solving cubics using restricted operations led to the discovery of the complex numbers, group theory, and the theory of fields, etc. So it was worth doing things the hard way and sticking to the letter of the problem.

Likewise, the ideas people use to solve the problem in the article may have applications elsewhere.

I do sometimes have doubts about whether this is the most efficient way of discovering scientific ideas: Posing puzzles and seeing what tools people throw at them. So I can see the criticisms coming...


Not going to criticize you, I think it's a cool math problem, but I've experienced people throwing problems like this at me at job interviews in the past so it echoed. And in those cases, they weren't looking for an answer, they were looking for the answer they knew about and no other answer would do. I once ended an interview early over one of these questions.

I am relentlessly production focused but that doesn't mean I don't like math. But by the time you get to FP64 with this thing, the probability of finding a fail case seems insanely low and in fact for the most part you can provably bound the error of the sum and therefore likely prove you have found the solution. Anything beyond that is a corner case as the mathematicians love to say. And now I see the criticisms coming.


I think people are downvoting you because you seem like you're attacking a strawman. We all agree that 1) it's an interesting math problem 2) for real-life instances, the FP64 solution is good enough.

For e.g. when you say "anything beyond that is likely unnecessary gold plating", I know you mean "exact algorithms (like the PSPACE algorithm) are unnecessary for solving real-life instances", but without context it sounds like you're saying "there is no conceivable reason people should care about the exact algorithms"


Back in the day, the downvotes here would flow like a river at the suggestion that an engineering career behooved one to understand Calculus and Linear Algebra with Statistics and Differential Equations if possible thrown in for good measure because Peter Thiel said college degrees were worthless and he was even offering $100K to some lucky winners to prove his point. Admittedly, I would have probably taken that offer had I been 18 and then gone to college afterwards, but it seemed to deliver mixed results.

For the above math comes up again and again writing software. Pure math like real analysis, graduate level algebra, number theory and topology not so much. I'm guessing the rise of AI demonstrated the previous mindset against math was poppycock all along so now we've gone to the opposite extreme and made it a religion? I think people are bringing their own biases into that interpretation and you are right about which biases.

But, also, not my problem. My personal bias is that I recognize this problem as exactly the sort of thing that gets brought up as a gotcha interview question by people who couldn't come up with that exact solution themselves yet understand it just enough to use it to make an interviewee squirm.




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

Search: