I am programming a script to an online store and a serious mathematical problem happened, and I cannot solve it!
This is the problem: if a person has only 10 cents (on any monetary currency, I will use US Dollar for example) it's the same as say that this person has $ 0.1 right?
I mean 10 cents = $ 0.1 , right?
Now, lets square it. The 10 cents becomes 100 cents, which is 1 dolar. Right? But 0.1*0.1 = $0.01.
I am very sure I can do this math using cents OR using any other unit I want and the result should be the same. If I have the same example and I want to make the square with a number that is in meters and other is in kilometer. The result should be the same, but it is not! What is the issue here?
EDIT:
One final question, a function with $x^3$ should increase faster than $x^2$ right?
For example, $2^2 = 4$ and $2^3 = 8$ $10^2 = 100$ and $10^3 = 100$
So the $x^3$ graphic should always be on top of $x^2$. Why doesnt that happen all the time?
OBS: this edit looks not related to my main question but it is completely, depending on the answer.
The problem is you aren't keeping track of the units properly. $(10\textrm{ cents})^2=100\textrm{ cents}^2$ whereas $(\$0.1)^2=\$^20.01$. Note that since $100\textrm{ cents}=\$1$, we have that $10000\textrm{ cents}^2=\$^21$. Using this unit conversion, the equality that looked weird to you holds.