how to convert the fraction part into intger?
2 次查看(过去 30 天)
显示 更早的评论
r = 3.342448;
L(1)= 0.234;
for i=2:4
L(i) = r*L(i-1)*(1-L(i-1));
end
mm=min(L);
nn=max(L);
oo=nn-mm;
Z=uint8(254*((L-mm)/oo))+1;
K = mod((abs (L)-floor (abs (L))) *10e8 , 256)
how i converting the K into intger?
0 个评论
回答(2 个)
TADA
2019-7-16
What about
K = round(mod((abs (L)-floor (abs (L))) *10e8 , 256))
Or
K = floor(mod((abs (L)-floor (abs (L))) *10e8 , 256))
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Logical 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!