### Multi-dimensional double-entry accounting?

Although double-entry bookkeeping (DEB) has been used in the business world for 5 centuries, the mathematical formulation of the double entry method is almost completely unknown. In this post, the mathematical treatment of double-entry bookkeeping using scalars given in Part I is generalized to the multi-dimensional case using vectors. The success in maintaining the two-sided accounts, debits and credits, the double-entry principle, and the trial balance in both cases shows that the formulation captures the double-entry method in mathematical form.

One acid test of a mathematical formulation of a theory is the question of whether or not it facilitates the generalization of the theory. Normal bookkeeping does not deal with incommensurate physical quantities; everything is expressed in the common units of money. Hence the question has previously arisen of a generalization of DEB to deal with multi-dimensional incommensurates with no common measure of value.

In the literature on the “mathematics” of accounting, there is a proposed “solution” to this question, a system of multi-dimensional physical accounting published by Yuji Ijiri at least three times in 1965, 1966, and 1967. In this system, most of the normal structure of DEB was lost:

• there was no balance sheet equation,

• there were no equity or proprietorship accounts,

• the temporary or nominal accounts could not be closed, and

• the “trial balance” did not balance.

It is common for certain aspects of a theory to be lost in a generalization of the theory.

For instance, the convenient idea of an accounting identity is lost since the dimensional and metric comparability it assumes is no longer present except under special circumstances. [Ijiri 1967, 333]

The accounting community has apparently accepted the failure of all these features of DEB as the necessary price to be paid to generalize DEB to incommensurate physical quantities. The other papers on “Double-entry multidimensional accounting” published in the accounting literature [e.g., Charnes et al. 1976, or Haseman and Whinston 1976] acquiesced in the absence of the balance-sheet equation.

Yet when DEB is mathematically formulated using the group of differences from undergraduate algebra, then the generalization to vectors of incommensurate physical quantities is immediate and trivial. *All* of the normal features of DEB—such as the balance-sheet equation, the equity account, the temporary accounts, and the trial balance—are preserved in the generalization [see Ellerman 1982, 1985, 1986, 2009]. Thus the model of multidimensional DEB “accepted” in the accounting community was simply a failed attempt at generalization which had been “received” as a successful generalization that unfortunately had to “sacrifice” certain features of DEB.

Due to the remarkable intellectual insulation between mathematics and accounting, the successful mathematical treatment and generalization of double-entry bookkeeping (first published over a quarter-century ago in 1982) will take many more years to become known and understood in the accounting literature.

### The double-entry method: general vector case

The *Pacioli group* P^{n} consists of the ordered pairs [x // y] of non-negative n-dimensional vectors, with the usual definitions of componentwise addition and equality (equality of cross-sums). The Pacioli group P^{n} is isomorphic with all of **R**^{n} (the set of all real n-vectors with positive and negative components) under two isomorphisms: the *debit isomorphism*, which associates [w // x] with w–x, and the *credit isomorphism*, which associates [w // x] with x–w. In order to translate a T-account [x // y] back and forth to a general vector z, one needs to specify whether to use the debit or credit isomorphism. This will be done by labeling the T-account as *debit balance* (DB) or *credit balance* (CB). Thus if a T-account [x // y] is debit balance, the corresponding vector is x–y, and if it is credit balance, then the corresponding vector is y–x.

The general case of the double-entry method starts with an equation between sums of n-dimensional vectors. Vector equations are first *encoded* in the Pacioli group constructed from the non-negative n-dimensional vectors. Since the vectors in a T-account must be non-negative, we must first develop a way to separate out the positive and negative components of a vector. The*positive part *of a vector x is x^{+} = max(x,0), the componentwise maximum of x and the zero vector [note that “0” is used, depending on the context, to refer to the zero scalar or the zero vector]. The *negative part *of x is x^{–} = –min(x,0), the componentwise negative of the minimum of x and the zero vector. Both the positive and negative parts of a vector x are non-negative vectors. Every vector x has a “Jordan decomposition” x = x^{+} – x^{–}. The two isomorphisms that map vectors to T-accounts of non-negative vectors are the debit isomorphism that maps x to the T-account [x^{+} // x^{–}] and the credit isomorphism that maps x to [x^{–} // x^{+}]. A T-account of non-negative vectors is in reduced form if it is in reduced form componentwise.

Given any vector equation in **R**^{n}, w + … + x = y + … + z, each left-hand side (LHS) vector x is encoded via the debit isomorphism as a debit-balance T-account [x^{+} // x^{–}] and each right-hand side (RHS) vector y is encoded via the credit isomorphism as a credit-balance T-account [y^{–} // y^{+}]. Then the original equation holds if and only the sum of the encoded T-accounts is a zero-account:

w + … + x = y + … + z

if and only if

[w^{+} // w^{–}] + … + [x^{+} // x^{–}] + [y^{–} // y^{+}] + … + [z^{–} // z^{+}]

is a zero-account.

Given the equation, the sum of the encoded T-accounts is the *equation zero-account* of the equation. Since only plus signs can appear between the T-accounts in an equational zero-account, the plus signs can be left implicit. The listing of the T-accounts in an equational zero-account (without the plus signs) is the *ledger*.

Changes in the various terms or “accounts” in the beginning equation are recorded as *transactions*. Transactions must be recorded as valid algebraic operations which transform equations into equations. Since equations encode as zero-accounts, a valid algebraic operation would transform zero-accounts into zero-accounts. There is only one such operation in the Pacioli group: add on a zero-account. Zero plus zero equals zero. The zero-accounts representing transactions are called *transaction zero-accounts*. The listing of the transactional zero-accounts is the *journal*.

A series of valid additive operations on a vector equation can then be presented in the following standard scheme:

Beginning Equation Zero-Account

+ Transaction Zero-Accounts

= Ending Equation Zero-Account

or, in more conventional terminology,

Beginning Ledger

+ Journal

= Ending Ledger.

The process of adding the transaction zero-accounts to the initial ledger to obtain the ledger at the end of the accounting period is called *posting the journal to the ledger*. The fact that a transaction zero-account is equal to [0 // 0] is traditionally expressed as the *double-entry principle* that transactions are recorded with equal debits and credits. The summing of the debit and credit sides of what should be an equation zero-account to check that it is indeed a zero-account is traditionally called the *trial balance*. *All* those features from scalar case of DEB carry over effortlessly to the general vector case.

At the end of the cycle, the ending equational zero-account is decoded to obtain the equation that results from the algebraic operations represented in the transactions. The T-accounts in an equational zero-account can be arbitrarily partitioned into two sets: DB (debit balance) and CB (credit balance). T-accounts [w // x] in DB are decoded as w–x on the left side of the equation, and T-accounts [w // x] in CB are decoded as x–w on the right side of the equation. Given a zero-account, this algorithm yields an equation. In an accounting application, the T-accounts in the final equation zero-account would be partitioned into sets DB and CB according to the side of the initial equation from which they were encoded.

### Simple example of double-entry vector accounting

Consider the following initial vector equation:

(6, –3, 10) + (–2, 5, –2) = (4, 2, 8).

*Sample Vector Equation to be Encoded*

It encodes as the equation zero-account (taking the LHS vectors as DB accounts and the RHS vectors as CB accounts):

[(6, 0, 10) // (0, 3, 0)] + [(0, 5, 0) // (2, 0, 2)] + [(0, 0, 0) // (4, 2, 8)].

*Equation Encoded as a Zero T-Account*

Suppose that the transaction would subtract the vector (–2, –9, 1) from the first vector on the LHS and from the vector on the RHS side of the original equation to obtain the ending equation:

(8, 6, 9) + (–2, 5, –2) = (6, 11, 7).

*Ending Vector Equation*

To perform this operation using the double-entry method, the subtracting of the vector (–2, –9, 1) from the first LHS term is encoded using the credit isomorphism to get [(2,9,0) // (0,0,1)] which is added to the first LHS or debit-balance term in the T-account version of the original equation. In more traditional terminology, we would say that (–2, –9, 1) is “credited” to that debit-balance account. For the subtraction from the RHS term, the vector is encoded using the debit isomorphism to obtain [(0,0,1) // (2,9,0)] and added to the credit-balance T-account version of the RHS term. That is, (–2, –9, 1) is “debited” to that credit-balance account.

In the scalar case, a T-account will always have a reduced form either as [d // 0] or [0 // c] so that adding [d // 0] to an account (a term in the equational zero-account) can be described as “debiting d to the account” and similarly for “crediting c to the account.” For vector T-accounts, the reduced form of a T-account does not necessarily have the zero vector on one side or the other. In this case, the reduced form of the T-account encoding of (–2, –9, 1) would be “mixed.” The “debit” takes the form of adding the T-account [(0,0,1) // (2,9,0)] obtained by applying the debit isomorphism to the term (–2, –9, 1), and the “credit” takes the form of adding the inverse [(2,9,0) // (0,0,1)] obtained by applying the credit isomorphism to the term. This yields another equational zero-account:

Original Eq. zero-account: | [(6,0,10) // (0,3,0)] | [(0,5,0) // (2,0,2)] | [(0,0, 0) // (4,2,8)] |

+ Transaction zero-account: | [(2,9,0) // (0,0,1)] | [(0,0,1) // (2,9,0)] | |

——————————— | ——————— | ——————— | ——————— |

= Ending eq. zero-account | [(8,9,10) // (0,3,1)] | [(0,5,0) // (2,0,2)] | [(0,0,1) // (6,11,8)] |

= (reduced form) | [(8,6,9) // (0,0,0)] | [(0,5,0) // (2,0,2)] | [(0,0,0) // (6,11,7)] |

*Beginning Ledger + Journal = Ending Ledger*

After a number of such transactions, the ending equation zero-account is then decoded to obtain an equation back in **R**^{n}. In this case, let the first two T-accounts be debit-balance and the third one credit-balance (as they were originally encoded). Then the ending equational zero-account decodes as the correct vector equation:

(8, 6, 9) + (–2, 5, –2) = (6, 11, 7).

*Decoded Ending Equation*

### References

Charnes, A., C. Colantoni and W. W. Cooper. 1976. A futurological justification for historical cost and multidimensional accounting. *Accounting, Organizations, and Society *1, no. 4: 315-37.

Ellerman, David. 1982. *Economics, Accounting, and Property Theory*. Lexington, Mass.: D. C. Heath.

Ellerman, David. 1985. The Mathematics of Double Entry Bookkeeping. *Mathematics Magazine*. 58 (September): 226-33.

Ellerman, David. 1986. Double Entry Multidimensional Accounting. *Omega, International Journal of Management Science* 14, no. 1: 13-22.

Ellerman, David 2009. Double-Entry Accounting: The Mathematical Formulation and Generalization. *FSR Forum (Financial Studies Association Rotterdam).* February: 17-22.

Haseman, W., and A. Whinston. 1976. Design of a multidimensional accounting system. *Accounting Review* 51, no. 1: 65-79.

Ijiri, Y. 1965. *Management Goals and Accounting for Control*. Amsterdam: North-Holland.

Ijiri, Y. 1966. Physical Measures and Multi-dimensional Accounting. In *Research in Accounting Measurement*. ed. R. K. Jaedicke, Y. Ijiri, and O. Nielsen, 150-64. Sarasota Fla.: American Accounting Association,

Ijiri, Y. 1967. *The Foundations of Accounting Measurement: A Mathematical, Economic, and Behavioural Inquiry*. Englewood Cliffs, N.J.: Prentice-Hall.