i have number i need save only integer without any point or 'e'

3 ビュー (過去 30 日間)
Muhannad Saleh
Muhannad Saleh 2021 年 3 月 2 日
回答済み: Jan 2021 年 3 月 2 日
i have a ' x = ATRTIMED(c) * 360 ' the result is '3.700000e+02' i dont need this only i need integer 370 like this

回答 (3 件)

Star Strider
Star Strider 2021 年 3 月 2 日
I am not certain what you want to do.
To change the way the numbers are displayed, change the format options to display the numbers as you want them.

Hernia Baby
Hernia Baby 2021 年 3 月 2 日
format
% x = ATRTIMED(c) * 360
x = 3.700000e+02;
x

Jan
Jan 2021 年 3 月 2 日
To get an integer value use round, floor or ceil.
If you only want to hide the fractional part, which can contain small numbers due to the limited precision of doubles, see:
doc format

カテゴリ

Help Center および File ExchangeMultidimensional Arrays についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by