Can I change how GnuCash calculates sales tax?

Derek Atkins warlord at MIT.EDU
Thu Apr 4 12:28:37 EDT 2013


Mike or Penny Novack <stepbystepfarm at mtdata.com> writes:

> This isn't a simple "rounding bug" problem.
>
> Each and every jurisdiction charging a "sales tax" (call it that, VAT,
> or what you will) gets to set its own rules as to how that is to be
> calculated. Do you add up the items and then compute the tax or is tax
> charged on each separately and then the tax added up? Do you round off
> by normal rules for rounding or do you always round up? There might be
> additional variants, but given just these two possibilities means FOUR
> different ways to calculate the tax.
>
> Needed would be a "table" of jurisdictions with the rule to use
> determining which of these four to use. Or more if supporting more
> rule variants (but I know we'd need at least these four).

There is also the question of whether tax is on top of the amount
(e.g. how it's done in the US), tax is included in the amount, or tax is
taken from the amount.  The difference between #2 and #3 is subtle.  In
#1 the equation is:

  Total = SubTotal + SubTotal*TaxRate = SubTotal * (1 + TaxRate)

In #2 you take the same equation but solve for SubTotal (because the
input is the Total):

  SubTotal = Total / (1 + TaxRate)

In other words, this is solving for the question:  what amount do I need
to charge such that the n% tax will result in the input total?

In #3 it is a completely different equation, because the tax is taken
off the top of the Total.  So you're inputting the Total like #2, not
SubTotal like #1, but you compute a tax off the top similar to #1:

  SubTotal = Total - (Total*TaxRate) = Total * (1 - TaxRate)

GnuCash does not support option #3 right now, but if we were going to
extend the way taxes are computed we should add this, too.

(Note that in all cases Tax = Total - SubTotal)

> Michael

-derek

-- 
       Derek Atkins, SB '93 MIT EE, SM '95 MIT Media Laboratory
       Member, MIT Student Information Processing Board  (SIPB)
       URL: http://web.mit.edu/warlord/    PP-ASEL-IA     N1NWH
       warlord at MIT.EDU                        PGP key available


More information about the gnucash-user mailing list