If I have $20 at 7% tax, I get a total of $21.40. If I use this equation:

$21.40/1.07 = $20, it will give me by base amount before the tax was added on.

What I need to know is if I have ($10 + ($10 + (10 * 7%))), I get a total of $20.70. How do I find out what the base amount of this is? I cant use $20.70/1.07 to get my base amount of $20 because only $10 of it is figured at the 7% rate. I need to know if there is a way to get the base amount om this scenario? Any help would be greatly appreciated.