
Show HN: Interactive factorization diagrams - sharkdp
http://david-peter.de/factorization-diagrams/
======
mcnamaratw
It's awesome. That's really nice.

One thing, when I pick a number with an annoyingly large prime factor (e.g.
1655=5*331), it seems to drop the large factor. At some point that probably
makes as much sense as drawing 331 pentagons. But does it indicate somewhere
that a factor isn't displayed?

EDIT: Ohhh, the dots are just very small. Thanks for the explanation!

~~~
sharkdp
Huge prime factors are indeed a problem (in the sense that the simply look
like circles). I think I can work a little bit on the scaling of the diagrams
(there is still some free space). Maybe this would help to see larger prime
factors. Thanks for the feedback!

~~~
mcnamaratw
Ohhhh, so when I do 1655 I'm not just getting a pentagon, I'm getting five
circles, each made out of 311 little tiny dots? (Or however many dots it is
:P)

~~~
sharkdp
Exactly. Maybe a Retina display with super-resolution on the canvas would help
;-)

------
amelius
Slightly offtopic: if I type "123456" the UI becomes unresponsive (cannot type
backspace for instance). It may be that the language Purescript is "lazy", but
somehow this does not seem to work out for the user. Any comments?

~~~
bjz_
Purescript is eager - not lazy. Didn't have trouble with 123456... the key-
presses did seem a tad slower though. I'm on Firefox Developer.

~~~
sharkdp
Yes, thanks for clarifying: Purescript is eager. But the slow response time is
not related to Purescript being eager or lazy, it's related to the slow prime
factorization algorithm.

------
amelius
Why do 13 and 19 look so much different?

~~~
sharkdp
Thanks for the feedback. Apart from the background color, they look the same
(polygons with 13 or 19 vertices). The color is different because only small
prime factors (≤ 13) have a dedicated color. But that's something that I can
certainly improve.

