Why when i convert Cell2mat than to double the values changes ?

2 views (last 30 days)
i am having this cell array
% bsh=busdata(:,17);
bsh={'Shunt susceptance B'
0
0
0
0
0
0
0
0
0.1900000
0
0
0
0
0}
I am converting to mat with
bsh=cell2mat(bsh(2:nbus+1)); % nbus=14 to exclude first cell
and if i want to convert to double with
bsh= double(bsh);
in the 0.19000 value i get 0.189999997615814
how is this possible?
Thanks a lot !!

Answers (1)

José-Luis
José-Luis on 6 May 2013

Categories

Find more on Data Type Conversion in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!