Dirk Laurie on Wed, 05 Sep 2012 16:13:26 +0200


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: polroots stack overflow


2012/8/13 SÃren Lennart Berg <soeren.berg@st.ovgu.de>:

> the input
> polroots(94.500000000000000000000000000000000000*z^12 - 5652.0000000000000000000000000000000000*z^11 + 144408.00000000000000000000000000000000*z^10 - 2045344.0000000000000000000000000000000*z^9 + 17354184.000000000000000000000000000000*z^8 - 87874688.000000000000000000000000000000*z^7 + 238393856.00000000000000000000000000000*z^6 - 191892480.00000000000000000000000000000*z^5 - 384723072.00000000000000000000000000000*z^4 - 589317120.00000000000000000000000000000*z^3 + 5892556800.0000000000000000000000000000*z^2 - 6157312000.0000000000000000000000000000*z - 3262720000.0000000000000000000000000000)
>
> results in a stack overflow even when using almost a gigabyte for the stack.

The easy workaround is to use factor() instead.