Numerical Multiplication in MATLAB
Mostra commenti meno recenti
Using MATLAB as a simple calculator, we get the results
2 * 0.155 * 100 = 31,
2 * 0.165 * 100 = 33,
2 * 0.135 * 100 = 27,
2 * 0.125 * 100 = 25
but the moment I compute the following
2 * 0.145 * 100 = 29.0000
I didn't have any variables in the memory, nor any settings enabled. These were on a blank canvas, but this particular value of 0.145 yields 29.0000 with four decimal places. I am a little unsure of why this value of 0.145 yields an answer with decimals, whereas the other calculations yield integers. Does anyone have an answer?
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Logical in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!