Can i multiply a binary one with a decimal number?
Ältere Kommentare anzeigen
I was trying to convert a decimal number into binary vector. I was assuming i could use those vectors in the equation next and store the values but it gives me weird answers? How can i tackle this problem?

Antworten (1)
Star Strider
am 27 Apr. 2017
You can ‘cheat’ and convert ‘str’ to numeric by subtracting the character '0' from it:
str = dec2bin(j,8) - '0';
Kategorien
Mehr zu Programmatic Model Editing finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!