I'm trying to use baseform to convert numbers in base 10 to base n, how can I make the convertion between, say base 2 to base n?
Baseform seems to always think that the base in expr BaseForm[Expr, n] is always 10.
|
I'm trying to use baseform to convert numbers in base 10 to base n, how can I make the convertion between, say base 2 to base n? Baseform seems to always think that the base in expr |
|||
|
It should be possible to use notation of the form
There are some similar examples under Properties and Relations in the documentation for |
|||||||||||||||
|
|
Since numbers given in
Different ways to represent that number:
|
|||||
|
|
Here are the above elements wrapped up in function which pulls together the various, or user defined, output forms and lets you switch from any base to any base:
And some sample usage:
|
|||||||||
|
FromDigits? – b.gatessucks Jun 10 '12 at 12:09