Base converter with fractions?
|
01-22-2017, 11:22 PM
Post: #3
|
|||
|
|||
RE: Base converter with fractions?
Thanks, Jan. That's pretty much how my "hex" program works: http://www.hpmuseum.org/forum/thread-720.html
But my "hex" program only works in base 16 (obviously). So I guess what I need to do is generalize that program by changing the hard-coded "16" to be a variable. The fraction expansion for CAS values can be expressed exactly for any base that is an exact power of 2, but all other bases will need to stop at some arbitrary number of digits. Smith's BASECALC sets the number of fraction digits to IP(12/log10(base)). Prime's CAS might allow a higher value than 12 without losing accuracy. A perfect programming mini-challenge on this rainy day! <0|ΙΈ|0> -Joe- |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)