Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

>I'd love to know who left those comments

The legend himself, John Carmack.

Fast inverse square root is really the perfect example of black magic in programming.



I always thought of this bit of code as a great example of applied numerical methods techniques, rather than “Black Magic” The magic constant is derivable from standard methods and one can even choose to optimize other measures of error.

http://www.lomont.org/Math/Papers/2003/InvSqrt.pdf


Isn't it what black magic is all about?

Unorthodox technique, that you can explain if you try hard enough (in a sense, everything that reliably work could be explained and someone has to came up with in the first place), used by people who don't really understand it.

What do you think is a better example?


I would consider “black magic” to be something that works reliably due to some specific and idiosyncratic property of the environment that it operates within. Basically, something that is exceptionally tightly coupled. I think the novel FPGA solutions that genetic algorithms can create fall into this category; they often didn’t work on different boards, or even when the same board was plugged into a different power supply because the solution was overfit.

“A Story About Magic” is black magic in action. http://catb.org/jargon/html/magic-story.html

“The Story of Mel” is not black magic even though no one else understood his program. http://www.catb.org/jargon/html/story-of-mel.html


Yes, it is derivable, but it takes a certain amount of (reckless) genius to put all together

In the world where FizzBuzz is hard, applying the Newton Method is a rare thing.




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

Search: