Products & Services Solutions Academia Support User Community Company

Learn more about Communications Toolbox   

oct2dec - Convert octal to decimal numbers

Syntax

d = oct2dec(c)

Description

d = oct2dec(c) converts an octal matrix c to a decimal matrix d, element by element. In both octal and decimal representations, the rightmost digit is the least significant.

Examples

The command below converts a 2-by-2 octal matrix.

d = oct2dec([12 144;0 25])

d =

    10   100
     0    21

For instance, the octal number 144 is equivalent to the decimal number 100 because 144 (octal) = 1*82 + 4*81 + 4*80 = 64 + 32 + 4 = 100.

See Also

bi2de

  


Free Early Verification Kit

Learn how to apply early verification to your development process through these technical resources.

How much time do you spend on testing to ensure implementation meets system-level requirements?

 © 1984-2009- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS