Imaginary base numbers: Difference between revisions

Content added Content deleted
m (→‎{{header|Perl 6}}: fix some spacing issues, minor rewording)
m (Some further exposition and clean-up)
Line 1:
{{draft task}}
 
Imaginary base numbers are a non-standard positional numeral system which uses an imaginary number as its radix. The most common is quater-imaginary whichwith usesradix 2i as it base. The quater-imaginary numeral system was first proposed by [https://en.wikipedia.org/wiki/Donald_Knuth| Donald Knuth] in 1955 as a submission for a high school science talent search. [http://www.fact-index.com/q/qu/quater_imaginary_base.html| [Ref.]]
 
Other imaginary bases are possible too but are not as widely discussed and aren't named.
 
'''Task:''' Write a set of procedures (functions, subroutines, however they are referred to in youyour language) to convert base 10 numbers to imaginary and back. At a minimum, support quater-imaginary (base 2i).
 
See [https://en.wikipedia.org/wiki/Quater-imaginary_base| Wikipedia: Quater-imaginary_base] for more details.
 
HereFor reference, here are some some decimal and complex numbers converted to quater-imaginary.
<table class="multicol" role="presentation" style="border-collapse: collapse; padding: 0; border: 0; background:transparent; width:100%;">
<tr>