Currently b doesn't support doubles, and use the the absolute value for negatives when converting an array back to a number. If they are supported it can be a generic polynomial evaluation operator.
For real bases, one way is to find the maximum power of the base which is less than the number, and set that digit accodingly. This leaves only the rightmost digit a real number.
For negative bases, find the maximum (k^(2k+2)-1)/(k^2-1) for even k instead, for positive numbers, and do it similarly for negative numbers. This makes the result all positive. See also: http://en.wikipedia.org/wiki/Negative_base
APL seemed just using mod everywhere, and returns an all negative array for negative bases, which makes less sense to me.
Or to make it simpler: just leave it unimplemented.
Installed the form recovery addon for posting on sourceforge...
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
How would that work for converting a number to that base?
For real bases, one way is to find the maximum power of the base which is less than the number, and set that digit accodingly. This leaves only the rightmost digit a real number.
For negative bases, find the maximum (k^(2k+2)-1)/(k^2-1) for even k instead, for positive numbers, and do it similarly for negative numbers. This makes the result all positive. See also: http://en.wikipedia.org/wiki/Negative_base
APL seemed just using mod everywhere, and returns an all negative array for negative bases, which makes less sense to me.
Or to make it simpler: just leave it unimplemented.
Installed the form recovery addon for posting on sourceforge...