Hi,,is there anyone who could tell me,how to generate a 10 bit binary data with only ONE in the first position and rest is zero?
1 次查看(过去 30 天)
显示 更早的评论
The data stream should be like this, A=[1 0 0 0 0 0 0 0 0 0]
0 个评论
采纳的回答
Star Strider
2016-5-20
If you want to be compatible with the MATLAB binary data representation convention, this works:
n = dec2bin(0, 10);
n(1) = '1';
2 个评论
更多回答(1 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Logical 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!