Convert decimal to octal number
In earlier post, we have seen the procedure for converting a given decimal number to its equivalent binary number.
In this post, we will see the step-by-step procedure to convert given decimal number to its equivalent in the octal number system.
As discussed earlier, we will implement the same division method used earlier, to convert decimal to octal and all the steps will be very much similar to the steps shown in decimal to binary conversion except for the change in the radix from 2 to 8 since here the target number system is octal number system.
- Integer part of the given decimal number is successively divided by the radix(base) of the target number system 8(octal) until we reach a stage where the quotient becomes zero(0).
- The reminder obtained at the end of each division step, becomes a part of the octal number.
- The reminders that obtained at the end of each step are assigned weights in the octal number system starting from the reminder obtained at the last division iteration to the first division iteration in decreasing order.
- The reminder in the last division iteration has the highest weight (MSD) and the reminder obtained in the first division iteration has the lowest weight (LSD) in the octal number system.
- The procedure is illustrated in the example below:
Ex1: Convert (83)10 decimal number to octal number (?)8 using division method
1st Division Iteration
Divide 83 by 8
83 ÷ 8 = 10(Quotient) Reminder:3
2nd Division Iteration
Divide 10 by 8
3rd Division Iteration
Divide 1 by 8
Remainder from the last division iteration becomes MSD and reminder from 1st iteration becomes LSD.
Hence, the octal equivalent of the decimal number 83 is (123).