Scenario:
I want to buy a share in a company.
Cost per share = 50,000USD
Number of shares to buy = 0.5
Transaction fees = 0.2%
Calculations:
Convert fee percentage to a decimal : 0.2 / 100 = 0.002
Convert decimal fee to amount to subtract from shares : 1 - 0.002 = 0.998
Calculate shares bought after fees : 0.5 * 0.998 = 0.499
Two part question:
- Is the calculation correct?
- Is there a better, simpler way of doing this?
Suppose you want to spend $d$ dollars for shares and that amount should include the commission $c$ (expressed as a fraction, not a percent). Let $s$ be the amount that will go to shares. Then $$ (1+c)s = d $$ so $$ s = \frac{d}{1+c}. $$
That is not the same as what you calculated, which is $s(1-c)$. But when $c$ is very small (as it is in this case) they are very close. You can check the difference numerically.