Want to truncate an array
3 次查看(过去 30 天)
显示 更早的评论
Suppose i have an array of [8.5766662529*10^22; 5.354353982*10^22;5.289634*10^22]. Now i want to truncate the array upto 4 decimal and power will remain same how i will do that?
0 个评论
回答(2 个)
Walter Roberson
2024-3-6
format long g
A = [8.5766662529*10^22; 5.354353982*10^22;5.289634*10^22]
round(A, 4, 'significant')
0 个评论
Star Strider
2024-3-6
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!