Tiered tax table - refined solution?

JamesonMH

Board Regular
Joined
Apr 17, 2018
Messages
120
Office Version
  1. 365
Platform
  1. Windows
Hi all,

I'm trying to refine this formula that calculates the total taxes off of a tiered table. Assume $10,000 income. Notice the 2nd row has to be blank for formula to work, which I don't like.

E.g.
Bracket Min $ (cell A1)Bracket Max $ (cell B1)Tax % (cell C1)
$0$4,7400.00%
4,740.016,06720.00%
6,067.01100,00036.00%

<tbody>
</tbody>

I use array formula = {SUM(--((C3:C5-C2:C4)*
(10,000-A3:A5)*N(10,000>A3:A5))}
=$1,681.28 in taxes

Is there a clever way I can tweak the formula so I don't have to have a blank row above the data? Right now the blank row facilitates the first part of the formula (calculating the difference in tax rate at each tier.

Thanks for your time!

James
 

Excel Facts

Spell Check in Excel
Press F7 to start spell check in Excel. Be careful, by default, Excel does not check Capitalized Werds (whoops)
You could add another column with the difference in the tax rate:

Excel 2012
ABCDEF
1Bracket Min $Bracket Max $Tax %DeltaTaxes
2$0 $4,740 0.00%0.00%1681.276
34,740.016,06720.00%20.00%
46,067.01100,00036.00%16.00%

<colgroup><col style="width: 25pxpx"><col><col><col><col><col><col></colgroup><thead>
</thead><tbody>
</tbody>
Sheet1

Worksheet Formulas
CellFormula
D2=C2-N(C1)
F2=SUMPRODUCT(D2:D4,(10000-A2:A4),--(10000>A2:A4))

<thead>
</thead><tbody>
</tbody>

<tbody>
</tbody>
 
Upvote 0
Thanks for your reply Eric. I like your solution better b/c it makes it clear how the tax differential drives the solution. It also avoids the blank row which was what I was after.

With the original formula it of course needs that blank row since you can't subtract text from a %. Are there any other workarounds to turn a text into say, zero so I could avoid the extra column? E.g. subtract this range from this range and treat any text values in either range to a zero...thanks again.
 
Upvote 0
You could (much as it is more difficult to manage) hard code the differences in the formula (then again if manageability is an issue I would also put the total earnings in a cell).
Btw you should lose the .01 in the bands as the sumproduct is doing a greater than.

Excel Workbook
AB
1Bracket Min $
201681.28
34740
46067
Sheet1
 
Last edited:
Upvote 0
You could try this array formula:

=SUM(IFERROR(C2:C4-C1:C3,0)*(10000-A2:A4)*(10000>A2:A4))

confirmed with Control+Shift+Enter.
 
Upvote 0
Thanks Eric for your help. I just tried with the IFERROR but unfortunately the formula won't work if there is ever a tax rate in the 1st bracket.

Right now I show 0% in my example for the first bracket, but if it were say 10% from $0 - $4,740 it would still return $0 b/c of the IFERROR.
 
Upvote 0
You could (much as it is more difficult to manage) hard code the differences in the formula (then again if manageability is an issue I would also put the total earnings in a cell).
Btw you should lose the .01 in the bands as the sumproduct is doing a greater than.

Sheet1

AB
1Bracket Min $
201681.28
34740
46067

<colgroup><col style="font-weight:bold; width:30px; "><col style="width:103px;"><col style="width:93px;"></colgroup><tbody>
</tbody>

Spreadsheet Formulas
CellFormula
B2=SUMPRODUCT({0;0.2;0.16},(10000-$A$2:$A$4),--(10000>$A$2:$A$4))

<tbody>
</tbody>

<tbody>
</tbody>


Excel tables to the web >> Excel Jeanie HTML 4

Thanks Mark, I didn't even realize using that array within SUMPRODUCT was an option! I do agree on linking of the income number - I was just hard coding it for my question as I couldn't figure out how to insert a real looking spreadsheet like many of you do on here.

Is there any way to make those hard-coded numbers (0, 0.2, 0.16) dynamic to avoid the hard-coding?

And noted on the $0.01.

Thanks for your help, much appreciated!

James
 
Upvote 0
Try this one instead:

=SUM((C2:C4-IFERROR(C1:C3+0,0))*(10000-A2:A4)*(10000>A2:A4))

with Control+Shift+Enter.

And there's no way to make a hard-coded array dynamic - you need to put those values in cells to do that.
 
Upvote 0
Try this one instead:

=SUM((C2:C4-IFERROR(C1:C3+0,0))*(10000-A2:A4)*(10000>A2:A4))

with Control+Shift+Enter.

And there's no way to make a hard-coded array dynamic - you need to put those values in cells to do that.

Eric - amazing as usual! You wouldn't believe how many other variations I tried that were much longer. I've never seen that trick before where you add zero to the end of a range.

As for the hard-coded array, what I meant was can you link those values inside the curly brackets within the SUMPRODUCT, somehow so you don't have to hard code? Excel just gives you a pop-up window when you try to link so I couldn't figure it out. But I'm good either way now that I have this solution of yours. Thanks again Eric!

James
 
Upvote 0

Forum statistics

Threads
1,215,477
Messages
6,125,031
Members
449,205
Latest member
Eggy66

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top