I have a more or less complex formula in my sheet to calculate the remaining amounts of an asset after a transaction happened. As of right now, unfortunately, instead of showing 0 after selling all of this asset, it shows -3.63798E-12
When I run through the formula, I can see the sum of all amounts ever bought is exactly the same as the sum of all the amounts ever sold. See here.
If I go a step further however, the result of this calculation is this.
If I take all the same values and calculate them "manually" it equals 0 perfectly. See here.
Does anybody know what is going on here?
Thanks!