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

I wrote some code to replicate this in the console, overlaying A054521 (in colors) onto their triangle (using _ and #) for any N. The output from running

  ./prime-triangle.py 74
is included as x_output_74.png. It's not fancy, but it could save you some time trying to figure out what the actual formulae are.

https://gist.github.com/mortehu/ccca0bafc7a9caa26d6008379057...

Edit: Other than 2, 14, 20, 30, 38, 44, 50, and 74, the two patterns match perfectly for every even N up to at least 600.

Edit 2: Looks like this is related to Linnik's theorem: https://en.wikipedia.org/wiki/Linnik%27s_theorem




Consider applying for YC's Spring batch! Applications are open till Feb 11.

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

Search: