My MATLAB code is giving me following double
answer: 1.727287951101063e+04
. I know its about 0, but how can I round/convert it into a better readab
Use format long g
:
>> A = 1.727287951101063e+04;
>> format long g;
>> A
A =
17272.8795110106
You can check out the docs on how format
works: http://www.mathworks.com/help/matlab/ref/format.html. However, format long g
essentially represents your number with 15 digits, fitting all of the digits that make the significant part of your number (without the decimal place), and filling in the rest of the spots with the decimal numbers (those that follow after the decimal place).