The Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Math Forum » Discussions » Software » comp.soft-sys.matlab

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: conversion from double to char
Replies: 1   Last Post: Mar 11, 2013 3:57 AM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View  
James Tursa

Posts: 2,326
Registered: 8/5/09
Re: conversion from double to char
Posted: Mar 11, 2013 3:57 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

"Timothy Koh" <> wrote in message <khk1ff$eur$>...
> Hi
> Anyone know how to convert 1 1 1 0 0 0 <1x6 double> to 111000 <1x6 char>?

d = [1 1 1 0 0 0];
c = char(d+'0');

James Tursa

Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum at NCTM 1994-2018. All Rights Reserved.