1.0

1.0 | 1 rating Rate this file 2 Downloads (last 30 days) File Size: 3.89 KB File ID: #13737

Binary to Decimal

by Moatasem Chehaiber

 

22 Jan 2007 (Updated 23 Jan 2007)

Converts binary data of any format in a string to floating point

| Watch this File

File Information
Description

Converts binary data of any format in a string to floating point decimal of a defined fraction size. The "intsize" input parameter defines the size of the exponent and sets the fixed point location in the binary number. se accompanied matlab program for test of this function

MATLAB release MATLAB 7.2 (R2006a)
Other requirements No restrictions
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Comments and Ratings (2)
23 Jan 2007 J Wagberg

Got documentation, but no H1 line.
No vectorization.
No error checking.

A simple wrapper around standard "bin2dec" would give the same functionality, i.e. twos-complement.

23 Jan 2007 J Wagberg

OK, realized that it does a bit more than two's-complement. Still think a wrapper around bin2dec would be a much better choice.

Please login to add a comment or rating.
Tag Activity for this File
Tag Applied By Date/Time
wireless Moatasem Chehaiber 22 Oct 2008 08:58:10
fixed point Moatasem Chehaiber 22 Oct 2008 08:58:10
floating point decimal Moatasem Chehaiber 22 Oct 2008 08:58:10
binary Moatasem Chehaiber 22 Oct 2008 08:58:10
floating point decimal Julien 07 Apr 2009 11:18:01

Contact us at files@mathworks.com