Show HN: Interactive polynomial roots toy

by duetosymmetryon 12/17/2017, 5:13 PMwith 9 comments

by raverbashingon 12/17/2017, 8:32 PM

For those curious what practical usage this might have, there is a control technique that uses the position of roots to determine how a system will behave as the feedback gain is changed https://en.wikipedia.org/wiki/Root_locus

Or basically, how loud can you crank an amplifier before you hear feedback (and how does it behave with different levels of feedback)

by BucketSorton 12/18/2017, 1:10 AM

This is GREAT! Reminds me of the http://explorabl.es/ project. The library it links to is very cool as well - http://jsxgraph.uni-bayreuth.de/wp/

by lancebeeton 12/18/2017, 10:49 AM

Cool, really enjoyable to play around with. This made me notice a cute (probably trivial) phenomenon that I haven't seen before. If you take x^n+...+1 and move one of the roots to 1 (equivalently, divide x^(n+1)-1 by (x-z) where z is some nth root of unity), then the resulting polynomial's coefficients seem to be the nth roots of unity.

By the way, it doesn't seem to prevent you from entering a degree higher than 7 if you enter the number manually even though it gives off a warning. Not sure if this is intentional.

by Aditya_Gargon 12/18/2017, 10:49 PM

Could you open source the code? I think this tool would be really helpful for one of my professors in explaining gain margin for feedback systems.

by anigbrowlon 12/17/2017, 9:37 PM

This is unreasonably enjoyable. Would also make a great musical toy...

by ttoinouon 12/17/2017, 9:29 PM

Very cool to see one graph moving when changing the other graph. I must find a way to make cools fractals with that concept