In this tutorial we will learn octal to decimal conversion for a floating point number i.e., a number with fractional part.

Before we dive into the main topic lets talk a little about Decimal and Octal Number System that we are going to work with in this tutorial.

A decimal number system consists of 10 digits: 0, 1, 2, 3, 4, 5, 6, 7, 8 and 9. So, any number that we use in our daily life is actually in decimal number system.

In Octal number system we use eight digits.

0, 1, 2, 3, 4, 5, 6 and 7

Octal implies base 8

To convert a octal number having integer and fractional part into decimal form we have to multiply the integer part

ones place with 8^{0}

tens place with 8^{1}

hundreds place with 8^{2}

ans so on...

and the fractional part

tenths place by 8^{-1}

hundredths place by 8^{-2}

and so on...

Convert octal number 0.01_{(base 8)} into decimal form.

The following table shows the places, octal number and the multipliers for the corresponding places.

place | ones | Decimal Point | tenths | hundredths |

octal | 0 | . | 0 | 1 |

multiplier | 8^{0} | 8^{-1} | 8^{-2} |

```
= 0x8
```^{0} + 0x8^{-1} + 0x8^{-2}
= 0 + 0 + 0.015625
= 0.015625

So, the required decimal number is

0.01_{(base 8)} = 0.015625_{(base 10)}

Alternatively, (0.01)_{8} = (0.015625)_{10}

Where, (base 10) means the number is in decimal number system and (base 8) means the number is in octal number system.

Convert octal number 7.12172_{(base 8)} into decimal form.

The following table shows the places, octal number and the multipliers for the corresponding places.

place | ones | Decimal Point | tenths | hundredths | thousandths | ten thousandths | hundred thousandths |

octal | 7 | . | 1 | 2 | 1 | 7 | 2 |

multiplier | 8^{0} | 8^{-1} | 8^{-2} | 8^{-3} | 8^{-4} | 8^{-5} |

```
= 7x8
```^{0} + 1x8^{-1} + 2x8^{-2} + 1x8^{-3} + 7x8^{-4} + 2x8^{-5}
= 7 + 0.125 + 0.03125 + 0.001953125 + 0.001708984375 + 0.00006103515624
= 10.1599...
= 10.16 (approx. value)

So, the required decimal number is

7.12172_{(base 8)} = 10.16_{(base 10)} (approx. value)

Alternatively, (7.12172)_{8} = (10.16)_{10} (approx. value)

Where, (base 10) means the number is in decimal number system and (base 8) means the number is in octal number system.

Recently Added

- CSS Table CSS
- JS Output JavaScript
- jQuery - AJAX method jQuery
- jQuery - Form jQuery
- jQuery - Fade and Slide methods jQuery
- jQuery - Animate method jQuery
- jQuery - Event propagation jQuery
- jQuery - Event delegation jQuery
- jQuery - Handling Events jQuery
- jQuery - Wrap elements and Remove elements jQuery